/* ============================================================================
   DiviseLavoro — Sartoria Modulare
   1:1 polish layer (complements theme.json tokens)
   ============================================================================ */

:root {
	--dl-chef-img: url("https://lh3.googleusercontent.com/aida-public/AB6AXuApWzKI7kqVo_wfTLEuWU8azW8E6rYnKyTWGpNuiWzxzL3-ST7OnZt8yk-VsKRYCPw7zkUvW1XGQ2ZFLvdCD5bfT0frRcEEOJ0NXBjaId9H8mlCWWpb_zarfnZEAE4CNYraoDoFBHsRIj1eT7uKg54dB5bq_8FJyxuR1pS-sbmEZgRxAH6qHVzfYFvgb6BYZXbfQTCsOufiEFkeTCQytyfdKwmSLBYhB-9txWb17EV_CtG8SmuXU3sJ0hvwBprHYG0Mc-zLuzwbUnPd");
	--dl-stylist-img: url("https://lh3.googleusercontent.com/aida-public/AB6AXuC9V7TFUjgSeDVuKPV__U0Cfad1ohvNSwXVth7g1O0StJZPpR56QmgP6g7naI82GxgA0aIlhKLXKq_uECpA5VaGP54kPesE9Rm9mgsQEvHecIvvGFmu4xy1O0GvqnGWLmEXcq3u6XxnyvkEh8bN72HoQn8eqDF-cfctU8UMJsfRAZC4de42V7v-DgG9ISY8UPBLNhxbelpryorwGZDnqjq5nRLlfG9wbAe_ezwd0GeaLjFrQvAqOsCOkTap7Jmp3Y6Ww3g6qS46mII6");
	--dl-ease: cubic-bezier(0.2, 0, 0, 1);
	--dl-r-md: 1rem;
	--dl-r-sm: 0.5rem;
}

/* --------------------------------------------------------------------------
   HEADER — Sticky surface-container-high bar with wordmark + nav + icons
   -------------------------------------------------------------------------- */
.dl-header.wp-block-group {
	position: sticky;
	top: 0;
	z-index: 50;
	width: 100%;
}

.dl-header .wp-block-site-title a {
	text-decoration: none;
	font-style: italic;
	font-weight: 700;
	letter-spacing: -0.02em;
	color: var(--wp--preset--color--primary);
}

.dl-primary-nav .wp-block-navigation__container {
	gap: 2rem;
}

.dl-primary-nav .wp-block-navigation-item__content {
	text-transform: uppercase;
	letter-spacing: 0.1em;
	font-size: 0.8125rem;
	color: color-mix(in srgb, var(--wp--preset--color--on-surface) 60%, transparent);
	padding-bottom: 0.25rem;
	transition: color 250ms var(--dl-ease), border-color 250ms var(--dl-ease);
	border-bottom: 2px solid transparent;
}

.dl-primary-nav .wp-block-navigation-item__content:hover,
.dl-primary-nav .current-menu-item .wp-block-navigation-item__content {
	color: var(--wp--preset--color--primary);
	border-bottom-color: var(--wp--preset--color--primary);
}

.dl-header-icons .wp-block-loginout a,
.dl-header-icons .wc-block-mini-cart__button {
	color: var(--wp--preset--color--primary);
}

/* --------------------------------------------------------------------------
   HERO — Dual-image background (chef | stylist) with glass panel overlay
   -------------------------------------------------------------------------- */
.dl-hero {
	position: relative;
	overflow: hidden;
	isolation: isolate;
}

.dl-hero::before,
.dl-hero::after {
	content: "";
	position: absolute;
	inset: 0;
	top: 0;
	bottom: 0;
	width: 50%;
	background-size: cover;
	background-position: center;
	filter: grayscale(0.2);
	z-index: 0;
}

.dl-hero::before {
	left: 0;
	background-image: var(--dl-chef-img);
}

.dl-hero::after {
	left: 50%;
	background-image: var(--dl-stylist-img);
}

/* Primary/10 tint overlay across both images */
.dl-hero .dl-hero-inner::before {
	content: "";
	position: absolute;
	inset: 0;
	background: color-mix(in srgb, var(--wp--preset--color--primary) 10%, transparent);
	z-index: 1;
	pointer-events: none;
}

.dl-hero .dl-hero-inner {
	position: relative;
	z-index: 2;
	width: 100%;
	display: flex;
	align-items: center;
	min-height: inherit;
}

.dl-hero .dl-glass-panel {
	position: relative;
	z-index: 3;
	background: color-mix(in srgb, var(--wp--preset--color--surface) 90%, transparent);
	backdrop-filter: blur(12px) saturate(1.05);
	-webkit-backdrop-filter: blur(12px) saturate(1.05);
	box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
	max-width: 640px;
}

.dl-hero .dl-hero-headline em {
	font-style: italic;
	font-weight: 400;
}

/* --------------------------------------------------------------------------
   BUTTONS — Gradient primary + Neutral surface-container-highest
   -------------------------------------------------------------------------- */
.wp-block-button.is-style-gradient .wp-block-button__link {
	background: linear-gradient(135deg, #113825 0%, #2D5A43 100%);
	color: var(--wp--preset--color--on-primary);
	padding: 1rem 2rem;
	border-radius: var(--dl-r-sm);
	font-family: var(--wp--preset--font-family--body);
	font-weight: 700;
	font-size: 0.8125rem;
	text-transform: uppercase;
	letter-spacing: 0.15em;
	transition: opacity 250ms var(--dl-ease);
}

.wp-block-button.is-style-gradient .wp-block-button__link:hover {
	opacity: 0.9;
}

.wp-block-button.is-style-neutral .wp-block-button__link {
	background: var(--wp--preset--color--surface-container-highest);
	color: var(--wp--preset--color--on-surface);
	padding: 1rem 2rem;
	border-radius: var(--dl-r-sm);
	font-family: var(--wp--preset--font-family--body);
	font-weight: 700;
	font-size: 0.8125rem;
	text-transform: uppercase;
	letter-spacing: 0.15em;
	transition: background 250ms var(--dl-ease);
}

.wp-block-button.is-style-neutral .wp-block-button__link:hover {
	background: var(--wp--preset--color--surface-dim);
}

/* --------------------------------------------------------------------------
   BENTO GRID — 4 columns × 2 rows, 600px tall on desktop
   Cucina (2×2) | Salone (2×1) on top-right | Medicale + Fatto in Italia bottom-right
   -------------------------------------------------------------------------- */
.dl-bento-header .dl-bento-cta a {
	color: inherit;
	text-decoration: none;
	transition: opacity 250ms var(--dl-ease);
}
.dl-bento-header .dl-bento-cta a:hover {
	opacity: 0.7;
}

.dl-bento-grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	grid-template-rows: repeat(2, 1fr);
	gap: 1.5rem;
	height: 600px;
}

.dl-bento-tile {
	position: relative;
	overflow: hidden;
	border-radius: var(--dl-r-md);
	cursor: pointer;
	display: block;
	text-decoration: none;
}

.dl-bento-tile--feature {
	grid-column: span 2;
	grid-row: span 2;
}

.dl-bento-tile--wide {
	grid-column: span 2;
	grid-row: span 1;
}

.dl-bento-tile img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 700ms var(--dl-ease);
	display: block;
}

.dl-bento-tile:hover img {
	transform: scale(1.05);
}

.dl-bento-tile::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(to top, color-mix(in srgb, var(--wp--preset--color--primary) 80%, transparent) 0%, transparent 60%);
	pointer-events: none;
}

.dl-bento-tile__content {
	position: absolute;
	bottom: 2rem;
	left: 2rem;
	z-index: 1;
}

.dl-bento-tile__content h3 {
	font-family: var(--wp--preset--font-family--headline);
	font-style: italic;
	font-weight: 400;
	font-size: 1.875rem;
	color: var(--wp--preset--color--surface);
	margin: 0 0 0.5rem 0;
	line-height: 1.1;
}

.dl-bento-tile__content span {
	font-family: var(--wp--preset--font-family--body);
	font-size: 0.8125rem;
	color: color-mix(in srgb, var(--wp--preset--color--surface) 80%, transparent);
	text-transform: uppercase;
	letter-spacing: 0.1em;
}

.dl-bento-tile:not(.dl-bento-tile--feature):not(.dl-bento-tile--wide) .dl-bento-tile__content {
	bottom: 1.5rem;
	left: 1.5rem;
}

.dl-bento-tile:not(.dl-bento-tile--feature):not(.dl-bento-tile--wide) .dl-bento-tile__content h3 {
	font-size: 1.5rem;
}

.dl-bento-tile:not(.dl-bento-tile--feature):not(.dl-bento-tile--wide) .dl-bento-tile__content span {
	font-size: 0.75rem;
	color: color-mix(in srgb, var(--wp--preset--color--surface) 60%, transparent);
}

@media (max-width: 900px) {
	.dl-bento-grid {
		grid-template-columns: 1fr;
		grid-template-rows: repeat(4, 260px);
		height: auto;
	}
	.dl-bento-tile--feature,
	.dl-bento-tile--wide {
		grid-column: span 1;
		grid-row: span 1;
	}
}

/* --------------------------------------------------------------------------
   ELEMENTI ESSENZIALI — Product cards on surface-container
   -------------------------------------------------------------------------- */
.dl-essentials-header .wp-block-separator.is-style-wide {
	height: 4px;
	border: 0;
	margin: 1rem auto 0;
}

.dl-essentials-grid .wp-block-woocommerce-product-template {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 3rem;
	list-style: none;
	padding: 0;
	margin: 0;
}

.dl-essentials-grid .wp-block-woocommerce-product-template > li {
	list-style: none;
}

.dl-product-card {
	display: flex;
	flex-direction: column;
}

.dl-product-card__media {
	position: relative;
	overflow: hidden;
}

.dl-product-card__media img {
	transition: transform 500ms var(--dl-ease);
}

.dl-product-card:hover .dl-product-card__media img {
	transform: scale(1.05);
}

.dl-product-card__body .wp-block-post-title a {
	text-decoration: none;
	color: var(--wp--preset--color--primary);
}

.dl-product-card__body .wp-block-woocommerce-product-price {
	font-weight: 700;
	color: var(--wp--preset--color--primary);
	margin-top: 0.5rem;
}

@media (max-width: 900px) {
	.dl-essentials-grid .wp-block-woocommerce-product-template {
		grid-template-columns: 1fr;
	}
}

/* --------------------------------------------------------------------------
   SPEC HIGHLIGHT — Grayscale image + bordered spec blocks
   -------------------------------------------------------------------------- */
.dl-spec .dl-spec-image img {
	filter: grayscale(1);
	border-radius: var(--dl-r-md);
	box-shadow: 0 20px 40px -16px rgba(0, 0, 0, 0.25);
	width: 100%;
	height: auto;
}

.dl-spec .dl-spec-item {
	border-left: 2px solid var(--wp--preset--color--primary-fixed);
	padding-left: 1.5rem;
}

.dl-cta-link a {
	color: inherit;
	text-decoration: none;
	transition: opacity 250ms var(--dl-ease);
}
.dl-cta-link a:hover {
	opacity: 0.7;
}

/* --------------------------------------------------------------------------
   CTA SECTION — Solid bg-primary with dark input + surface button
   -------------------------------------------------------------------------- */
.dl-cta {
	text-align: center;
}

.dl-cta-form {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 1rem;
	max-width: 540px;
	margin: 0 auto;
}

.dl-cta-form input[type="email"] {
	flex: 1 1 300px;
	min-width: 300px;
	background: var(--wp--preset--color--primary-container);
	color: var(--wp--preset--color--on-primary);
	border: 0;
	border-bottom: 2px solid color-mix(in srgb, var(--wp--preset--color--outline-variant) 20%, transparent);
	padding: 1rem 1.5rem;
	font-family: var(--wp--preset--font-family--body);
	font-size: 1rem;
	outline: none;
	transition: border-color 250ms var(--dl-ease);
}

.dl-cta-form input[type="email"]::placeholder {
	color: color-mix(in srgb, var(--wp--preset--color--on-primary) 60%, transparent);
}

.dl-cta-form input[type="email"]:focus {
	border-bottom-color: var(--wp--preset--color--on-primary);
}

.dl-cta-form button[type="submit"] {
	background: var(--wp--preset--color--surface);
	color: var(--wp--preset--color--primary);
	border: 0;
	padding: 1rem 2rem;
	border-radius: var(--dl-r-sm);
	font-family: var(--wp--preset--font-family--body);
	font-weight: 700;
	font-size: 0.8125rem;
	text-transform: uppercase;
	letter-spacing: 0.15em;
	cursor: pointer;
	transition: background 250ms var(--dl-ease);
}

.dl-cta-form button[type="submit"]:hover {
	background: var(--wp--preset--color--surface-dim);
}

/* --------------------------------------------------------------------------
   FOOTER — Simple single row
   -------------------------------------------------------------------------- */
.dl-footer .wp-block-site-title a {
	text-decoration: none;
	font-style: italic;
	font-weight: 700;
	color: var(--wp--preset--color--primary);
}

.dl-footer-nav .wp-block-navigation__container {
	gap: 2rem;
}

.dl-footer-nav .wp-block-navigation-item__content {
	text-transform: uppercase;
	letter-spacing: 0.15em;
	font-size: 0.6875rem;
	color: color-mix(in srgb, var(--wp--preset--color--on-surface) 50%, transparent);
	text-decoration: none;
	transition: color 250ms var(--dl-ease);
}

.dl-footer-nav .wp-block-navigation-item__content:hover {
	color: var(--wp--preset--color--primary);
}

/* --------------------------------------------------------------------------
   Accessibility
   -------------------------------------------------------------------------- */
.screen-reader-text {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

*:focus-visible {
	outline: 2px solid var(--wp--preset--color--primary);
	outline-offset: 2px;
}
