/*
Theme Name: ABBY Promotion
Description: A custom block theme scaffolded by Studio Code.
Requires at least: 6.7
Tested up to: 6.9
Requires PHP: 7.2
Version: 0.4.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: abby-promotion
Tags: full-site-editing, block-patterns, block-styles, wide-blocks, accessibility-ready, style-variations
*/

/* WordPress inserts a margin-block-start equal to the block gap (24px unless
   theme.json sets styles.spacing.blockGap) between the template's top-level
   sections (header part, main, footer part) — a gap that exists even when no
   markup asks for it. Zero it so sections butt edge-to-edge and own their
   vertical rhythm via padding; this does not affect block gaps inside nested
   layouts. */
.wp-site-blocks > * + * {
	margin-block-start: 0;
}

/* With that gap gone, main carries its own vertical padding so templates this
   theme does not author (WooCommerce shop, product, cart…) still clear the
   header and footer. A descendant selector, not a child one: WooCommerce wraps
   the single-product main in an extra group. Templates built from full-bleed
   sections opt out with is-flush and let the sections own the rhythm. */
.wp-site-blocks main {
	padding-block: var(--wp--preset--spacing--60) var(--wp--preset--spacing--70);
}
.wp-site-blocks main.is-flush {
	padding-block: 0;
}

:root{--abby-line:color-mix(in srgb,var(--wp--preset--color--deep) 18%,transparent);--abby-space:clamp(2.5rem,6vw,6rem)}
html{scroll-behavior:smooth}body{background:var(--wp--preset--color--pale);color:var(--wp--preset--color--deep)}a{text-underline-offset:.2em}a:hover{text-decoration-thickness:2px}.wp-block-site-title{font-weight:700;letter-spacing:.04em}.wp-block-navigation{font-size:.9rem}.wp-block-navigation a{text-decoration:none}.wp-block-navigation a:hover{text-decoration:underline}.wp-block-button__link{font-weight:600;transition:transform .18s ease,background-color .18s ease}.wp-block-button__link:hover{transform:translateY(-2px)}.abby-band{padding-block:var(--abby-space);padding-inline:var(--wp--style--root--padding-left)}.abby-hero{min-height:min(78vh,760px);display:flex;align-items:center}.abby-hero .wp-block-heading{max-width:900px}.abby-kicker{font-size:var(--wp--preset--font-size--label);font-weight:600;letter-spacing:.12em;text-transform:uppercase;color:var(--wp--preset--color--primary)}.abby-card{padding:1.25rem;border:1px solid var(--abby-line);background:var(--wp--preset--color--pale)}.abby-product-grid{gap:1rem}.abby-rfq-form{max-width:760px}.abby-rfq-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1rem}.abby-rfq-grid label{display:grid;gap:.4rem;font-weight:600}.abby-rfq-grid input,.abby-rfq-grid select,.abby-rfq-grid textarea{width:100%;padding:.8rem;border:1px solid var(--abby-line);background:#fff;color:var(--wp--preset--color--deep);font:inherit}.abby-rfq-grid .abby-rfq-full{grid-column:1/-1}.abby-rfq-grid .abby-rfq-consent{display:flex;align-items:flex-start;font-weight:400}.abby-rfq-grid .abby-rfq-consent input{width:auto;margin-top:.35rem}.abby-rfq-grid button{border:0;background:var(--wp--preset--color--primary);color:white;padding:.9rem 1.3rem;font:inherit;font-weight:700;cursor:pointer}.abby-rfq-success{padding:1rem;background:var(--wp--preset--color--tint);border-left:4px solid var(--wp--preset--color--primary)}.woocommerce ul.products li.product,.woocommerce div.product{color:var(--wp--preset--color--deep)}.woocommerce ul.products li.product img{background:var(--wp--preset--color--tint)}.wp-site-blocks>footer{background:var(--wp--preset--color--deep);color:var(--wp--preset--color--white);padding-block:2rem}.wp-site-blocks>footer a{color:inherit}@media(max-width:782px){.abby-rfq-grid{grid-template-columns:1fr}.abby-rfq-grid .abby-rfq-full{grid-column:auto}.abby-hero{min-height:65vh}}
@media(prefers-reduced-motion:reduce){html{scroll-behavior:auto}.wp-block-button__link{transition:none}}

/* Visual fixes from rendered-page inspection */
.abby-site-header{padding-block:1rem;border-bottom:1px solid var(--abby-line)}
.abby-hero{display:flex;flex-direction:column;align-items:stretch;justify-content:center}
.abby-hero,.abby-hero :where(h1,h2,p){color:var(--wp--preset--color--white)}
.abby-hero .abby-kicker{color:var(--wp--preset--color--tint)}
.abby-hero .wp-block-buttons>.wp-block-button:first-child .wp-element-button{background:var(--wp--preset--color--white);color:var(--wp--preset--color--deep)}
.abby-hero .wp-block-buttons>.wp-block-button:nth-child(2) .wp-element-button{background:transparent;color:var(--wp--preset--color--white);border-color:var(--wp--preset--color--white)}
.abby-band.has-deep-background-color{color:var(--wp--preset--color--white)}
.abby-band.has-deep-background-color :where(h1,h2,h3,p,li,a){color:var(--wp--preset--color--white)}
.abby-band.has-deep-background-color .wp-element-button{background:var(--wp--preset--color--white);color:var(--wp--preset--color--deep)}
.abby-rfq-grid input,.abby-rfq-grid select,.abby-rfq-grid textarea{box-sizing:border-box;min-width:0;max-width:100%}
.abby-band.has-primary-background-color{color:var(--wp--preset--color--white)}
.abby-band.has-primary-background-color :where(h1,h2,h3,p,li,a){color:var(--wp--preset--color--white)}
.abby-band.has-primary-background-color .wp-element-button{background:var(--wp--preset--color--white);color:var(--wp--preset--color--deep)}
.abby-site-header .wp-block-woocommerce-product-search{max-width:17rem}

/* Catalog and editorial additions use the existing theme palette. */
.abby-category-links {
	display: flex;
	flex-wrap: wrap;
	gap: .5rem;
	list-style: none;
	padding: 0;
}
.abby-category-links a {
	display: block;
	padding: .55rem .85rem;
	border: 1px solid var(--abby-line);
	text-decoration: none;
}
.abby-category-links a:hover,
.abby-category-links a:focus-visible {
	background: var(--wp--preset--color--tint);
}
.abby-quote-link {
	display: inline-block;
	text-decoration: none;
}
.abby-product-information {
	margin-block: 2rem;
}
.abby-specifications {
	display: grid;
	grid-template-columns: minmax(9rem, 1fr) 2fr;
}
.abby-specifications dt,
.abby-specifications dd {
	margin: 0;
	padding: .65rem .35rem;
	border-block-start: 1px solid var(--abby-line);
	overflow-wrap: anywhere;
}
.abby-specifications dt {
	font-weight: 600;
}
.abby-related-products {
	max-width: var(--wp--style--global--content-size);
	margin: 2rem auto 0;
	padding-inline: var(--wp--style--root--padding-left);
}
.abby-blog .wp-block-post {
	padding-block: 1.5rem;
	border-block-start: 1px solid var(--abby-line);
}
.abby-rfq-grid input[type=file] {
	font-size: .9rem;
}
@media (max-width: 520px) {
	.abby-specifications {
		grid-template-columns: 1fr;
	}
	.abby-specifications dd {
		border-block-start: 0;
		padding-block-start: 0;
	}
}
/* Keep catalog action sizes and media spacing consistent across layouts. */
.abby-quote-link,
.abby-rfq-grid button {
	box-sizing: border-box;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 44px;
	max-width: 100%;
	text-align: center;
}
.abby-quote-link:hover,
.abby-quote-link:focus-visible {
	color: var(--wp--preset--color--white);
	background: var(--wp--preset--color--deep);
}
.woocommerce ul.products li.product img {
	aspect-ratio: 1;
	object-fit: contain;
	box-sizing: border-box;
	padding: .5rem;
}
.woocommerce ul.products li.product h2 {
	line-height: 1.35;
}
.single-product .wp-block-woocommerce-product-meta {
	margin-top: 1rem;
}
.single-product .abby-product-information > h2 {
	margin-block: 1.5rem .75rem;
}
@media (max-width: 520px) {
	.woocommerce ul.products li.product .abby-quote-link {
		width: 100%;
		padding-inline: .5rem;
	}
}
.abby-blog-crumbs ol {
	display: flex;
	flex-wrap: wrap;
	gap: .4rem;
	padding: 0;
	list-style: none;
	font-size: .9rem;
}
.abby-blog-crumbs li + li::before {
	content: '/';
	margin-inline-end: .4rem;
}
