/**
 * Transparent overlay → solid sticky header (homepage only).
 * Loaded last so it wins over earlier phase CSS without scattering !important patches.
 *
 * States on .dinc-header:
 *   .is-at-top     — transparent overlay over hero (first paint)
 *   .is-scrolled   — solid white sticky/fixed
 */

/* Slim business announcement (not staging badge) */
html body.home .dinc-announce {
	position: relative;
	z-index: 110;
	background: #f7f7f7 !important;
	color: #111 !important;
	border-bottom: 1px solid #ececec;
	min-height: 2rem !important;
	padding: 0.35rem var(--dinc-gutter, 1rem);
}

html body.home .dinc-announce a {
	color: #111 !important;
	text-decoration: underline;
}

/* Non-home: keep solid sticky header from first paint */
body:not(.home) .dinc-header {
	position: sticky;
	top: 0;
	z-index: var(--dinc-z-header, 100);
	background: #fff;
	color: #111;
	border-bottom: 1px solid #e5e5e5;
}

/* Homepage header — single DOM, two states */
body.home .dinc-header {
	left: 0;
	right: 0;
	width: 100%;
	z-index: 105;
	transition: background-color 0.25s ease, border-color 0.25s ease, color 0.25s ease, box-shadow 0.25s ease;
	will-change: background-color;
}

body.home .dinc-header.is-at-top {
	position: absolute;
	top: var(--dinc-announce-h, 2rem);
	background: transparent !important;
	color: #fff !important;
	border-bottom-color: transparent !important;
	box-shadow: none !important;
}

body.home .dinc-header.is-scrolled {
	position: fixed;
	top: calc(var(--dinc-admin-offset, 0px) + var(--dinc-announce-h, 2rem));
	background: #fff !important;
	color: #111 !important;
	border-bottom: 1px solid #e5e5e5 !important;
	box-shadow: 0 1px 0 rgba(0, 0, 0, 0.04);
}

/* When announcement is sticky-stacked with scrolled header */
body.home.has-sticky-announce .dinc-announce {
	position: fixed;
	top: var(--dinc-admin-offset, 0px);
	left: 0;
	right: 0;
	width: 100%;
	z-index: 110;
}

body.home.has-sticky-announce .dinc-header.is-scrolled {
	top: calc(var(--dinc-admin-offset, 0px) + var(--dinc-announce-h, 2rem));
}

body.home.has-sticky-announce.is-at-top-page .dinc-announce {
	position: relative;
	top: auto;
}

/* Overlay: white controls + light logo */
body.home .dinc-header.is-at-top .dinc-menu-btn,
body.home .dinc-header.is-at-top .dinc-menu-btn__label,
body.home .dinc-header.is-at-top .dinc-icon-btn,
body.home .dinc-header.is-at-top .dinc-currency,
body.home .dinc-header.is-at-top .dinc-currency *,
body.home .dinc-header.is-at-top .dinc-primary-nav > ul > li > a,
body.home .dinc-header.is-at-top .dinc-logo__word {
	color: #fff !important;
}

body.home .dinc-header.is-at-top .dinc-menu-btn svg,
body.home .dinc-header.is-at-top .dinc-icon-btn svg {
	stroke: #fff !important;
	color: #fff !important;
}

body.home .dinc-header.is-at-top .dinc-logo__img {
	filter: brightness(0) invert(1);
}

/* Solid: dark controls + dark logo */
body.home .dinc-header.is-scrolled .dinc-menu-btn,
body.home .dinc-header.is-scrolled .dinc-menu-btn__label,
body.home .dinc-header.is-scrolled .dinc-icon-btn,
body.home .dinc-header.is-scrolled .dinc-currency,
body.home .dinc-header.is-scrolled .dinc-currency *,
body.home .dinc-header.is-scrolled .dinc-primary-nav > ul > li > a,
body.home .dinc-header.is-scrolled .dinc-logo__word {
	color: #111 !important;
}

body.home .dinc-header.is-scrolled .dinc-menu-btn svg,
body.home .dinc-header.is-scrolled .dinc-icon-btn svg {
	stroke: #111 !important;
	color: #111 !important;
}

body.home .dinc-header.is-scrolled .dinc-logo__img {
	filter: none;
}

/* Admin bar offsets (logged-in only; WP sets body.admin-bar) */
body.admin-bar.home {
	--dinc-admin-offset: 32px;
}

@media screen and (max-width: 782px) {
	body.admin-bar.home {
		--dinc-admin-offset: 46px;
	}
}

body.admin-bar.home .dinc-header.is-at-top {
	top: calc(var(--dinc-admin-offset, 0px) + var(--dinc-announce-h, 2rem));
}

body.admin-bar.home.has-sticky-announce .dinc-announce {
	top: var(--dinc-admin-offset, 0px);
}

body.admin-bar.home .dinc-header.is-scrolled {
	top: calc(var(--dinc-admin-offset, 0px) + var(--dinc-announce-h, 2rem));
}

/* Full-bleed homepage hero — break out of Storefront .col-full */
body.home .site-content,
body.home .site-content .col-full,
body.home #content.col-full,
body.home .content-area {
	max-width: none !important;
	width: 100% !important;
	padding-left: 0 !important;
	padding-right: 0 !important;
	margin-left: 0 !important;
	margin-right: 0 !important;
}

body.home #page,
body.home .site,
body.home .site-content {
	overflow-x: clip;
}

body.home .dinc-hero--campaign {
	position: relative;
	left: 50%;
	right: auto;
	width: 100vw;
	max-width: 100vw;
	margin-left: -50vw;
	margin-right: 0;
	min-height: min(100svh, 56rem);
	margin-top: 0 !important;
	padding-top: 0 !important;
}

body.home .dinc-hero--campaign .dinc-hero__media {
	inset: 0 !important;
	height: 100% !important;
	top: 0 !important;
}

body.home .dinc-hero--campaign .dinc-hero__media img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center 20%;
	display: block;
}

/* Multi-picture hero fade slider */
body.home .dinc-hero--slider .dinc-hero__media {
	overflow: hidden;
}

body.home .dinc-hero--slider .dinc-hero__slide {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center 20%;
	opacity: 0;
	transition: opacity 0.9s ease;
	z-index: 0;
}

body.home .dinc-hero--slider .dinc-hero__slide.is-active {
	opacity: 1;
	z-index: 1;
}

body.home .dinc-hero--slider .dinc-hero__shade {
	z-index: 2;
}

body.home .dinc-hero__dots {
	position: absolute;
	left: 50%;
	bottom: 1.25rem;
	transform: translateX(-50%);
	z-index: 4;
	display: flex;
	gap: 0.45rem;
	align-items: center;
}

body.home .dinc-hero__dot {
	width: 0.55rem;
	height: 0.55rem;
	padding: 0;
	border: 0;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.45);
	cursor: pointer;
	min-width: 0.55rem;
	min-height: 0.55rem;
}

body.home .dinc-hero__dot.is-active {
	background: #fff;
	width: 1.15rem;
}

/* Following rails keep horizontal gutter */
body.home .dinc-home--p10 .dinc-rail,
body.home .dinc-home--p10 .dinc-consult,
body.home .dinc-home--p10 .dinc-section {
	padding-left: var(--dinc-gutter, 1rem);
	padding-right: var(--dinc-gutter, 1rem);
}

body.home .dinc-home--p10 .dinc-campaign {
	padding-left: 0;
	padding-right: 0;
}

/* Elementor first section full-bleed when Elementor home is active */
body.home .dinc-home--elementor .elementor-section,
body.home .dinc-home--elementor .e-con.e-parent:first-child {
	width: 100vw;
	max-width: 100vw;
	margin-left: calc(50% - 50vw);
	margin-right: calc(50% - 50vw);
}

@media (prefers-reduced-motion: reduce) {
	body.home .dinc-header {
		transition: none;
	}
}
