/* === GLOBAL THEME TOKENS === */
:root {
	--scopione-gray: #bfbfbf; /* update to your exact gray */
}

/* GLOBAL VISIBILITY — JS should be able to override */
.sc-hidden {
	display: none; /* no !important */
}

/* RESPONSIVE UTILITIES — CSS rules override, NOT JS */
@media (min-width: 769px) {
	.hide-desktop { display: none !important; }
}

@media (max-width: 768.98px) {
	.hide-mobile { display: none !important; }
}

/* ====== STICKY HEADER WRAPPER ====== */
.site-header {
	background: #1f1f1f;
	border-top: 0;
	border-bottom: 1px solid rgba(255,255,255,0.12);
	box-shadow: 0 6px 16px rgba(0,0,0,0.7);
	position: -webkit-sticky;
	position: sticky;
	top: 0;
	left: 0;
	right: 0;
	z-index: 1000;
}

/* subtle seam between promo bar and header */
.site-header::before {
	content: "";
	position: absolute;
	top: -2px;
	left: 0;
	right: 0;
	height: 2px;
	background: linear-gradient(
		to bottom,
		rgba(255,255,255,0.08) 0%,
		rgba(0,0,0,0) 100%
	);
	pointer-events: none;
}

/* ====== HEADER LAYOUT BASE ======
   final layout is controlled entirely by media queries
*/
.site-header-inner {
	max-width: 1200px;
	margin: 0 auto;
	padding-top: 0;
	padding-bottom: 0;
	padding-left: 0.1rem;
	padding-right: 0.1rem;
}

/* ====== LEFT CLUSTER: burger + logo ====== */
.header-left-cluster {
	display: flex;
	flex-direction: row; /* ensure burger left, logo right */
	align-items: center;
	justify-content: flex-start;
	column-gap: 0.5rem;
	flex-shrink: 0;
}

/* burger button (base) */
.scopione-burger {
	background: none;
	border: 0;
	padding: 0;
	cursor: pointer;
	display: flex;
	flex-direction: column;
	justify-content: center;
	align-items: center;
	width: 48px;   /* base tap target, overridden in media queries */
	height: 48px;
	order: 1; /* appear first (left of logo) */
}

.scopione-burger span {
	display: block;
	width: 26px;
	height: 3px;
	background: var(--scopione-gray);
	margin: 4px 0;
	border-radius: 2px;
	transition: background-color .15s linear;
}

.scopione-burger:hover span,
.scopione-burger:focus span {
	background: #ffbe3d;
}

/* logo */
.scopione-logo {
	display: flex;
	align-items: center;
	justify-content: center;
	line-height: 1;
	margin: 0;
	text-decoration: none;
	order: 2;           /* appear second, to the right of burger */
	margin-left: 0.5rem;  /* space between burger and logo (adjust as needed) */
}

.scopione-logo img {
	display: block;
	height: 26px;
	width: auto;
	transform: translateY(1px); /* optical mobile nudge */
}

/* ====== SEARCH CLUSTER ====== */
.header-search-wrap {
	flex: 1 1 auto;
	min-width: 200px;
	max-width: 600px;
}
.header-search-wrap form .input-group {
	width: 100%;
}
.header-search-wrap input[type="text"] {
	height: 40px;
	font-size: 0.9rem;
}
.header-search-wrap .btn {
	height: 40px;
	font-size: 0.9rem;
	display: flex;
	align-items: center;
	justify-content: center;
}

/* search field styling */
.header-search-wrap .input-group .form-control {
	border-radius: 4px 0 0 4px;
}
.header-search-wrap .input-group .btn {
	border-radius: 0 4px 4px 0;
	background: #fff;
	border-color: #ced4da;
	color: #000;
	padding: 0 0.75rem;
	line-height: 1;
	display: flex;
	align-items: center;
	justify-content: center;
}
.header-search-wrap .input-group .btn svg {
	width: 16px;
	height: 16px;
	color: #000;
	fill: currentColor;
}
.header-search-wrap .input-group .btn:hover,
.header-search-wrap .input-group .btn:focus {
	background: #ffbe3d;
	border-color: #ffbe3d;
	color: #111;
}
.header-search-wrap .input-group .btn:hover svg,
.header-search-wrap .input-group .btn:focus svg {
	color: #111;
	fill: currentColor;
}

/* ====== RIGHT CLUSTER (icons: search trigger mobile, cart, account) ====== */
.header-right {
	display: flex;
	align-items: center;
	flex-shrink: 0;
	gap: 0.2rem;
	justify-content: flex-end;
}

/* icon buttons */
.header-icon-link {
	position: relative;
	color: var(--scopione-gray);
	text-decoration: none;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
}
/* reset when used as <button> (mobile search trigger) */
button.header-icon-link {
	background: none;
	border: 0;
	padding: 0;
	cursor: pointer;
}
.header-icon-link svg {
	width: 22px;
	height: 22px;
}
.header-icon-link svg path {
	fill: currentColor;
}
.header-icon-link:hover,
.header-icon-link:focus {
	color: #ffbe3d;
	text-decoration: none;
}
.header-icon-link:hover svg path,
.header-icon-link:focus svg path {
	fill: currentColor;
}

/* cart badge */
.navbar-cart-label {
	position: absolute;
	top: 2px;
	right: 2px;
	background: #ffbe3d;
	color: #111;
	font-size: 0.65rem;
	font-weight: 700;
	border-radius: 999px;
	line-height: 1;
	padding: 0.1rem 0.35rem;
	min-width: 1.1rem;
	text-align: center;
}

/* checkout trust badge */
.checkout-trust-badge {
	height: 24px;
	width: auto;
	display: block;
}

/* ====== OFF-CANVAS NAV DRAWER ====== */
#mobile-nav-drawer {
	position: fixed;
	top: 0;
	left: 0;
	height: 100vh;                       /* fallback for older browsers */
	height: 100dvh;                      /* dynamic viewport height (modern browsers) */
	width: 80%;
	max-width: 320px;
	background: #111;
	color: #fff;
	z-index: 2000;
	box-shadow: none;
	transform: translateX(-100%);
	transition: transform 0.25s ease;
	display: flex;
	flex-direction: column;
}
#mobile-nav-drawer.active {
	transform: translateX(0);
	box-shadow: 4px 0 20px rgba(0,0,0,0.7);
}
.mobile-drawer-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 1rem;
	border-bottom: 1px solid rgba(255,255,255,0.15);
}
.mobile-drawer-header h2 {
	margin: 0;
	font-size: 1rem;
	font-weight: 600;
	color: #fff;
}
.mobile-drawer-close-btn {
	background: none;
	border: 1px solid rgba(255,255,255,0.4);
	border-radius: 0.4rem;
	color: #fff;
	font-size: 0.8rem;
	line-height: 1;
	padding: 0.4rem 0.6rem;
}
.mobile-drawer-body {
  flex: 1 1 auto;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;

  /* Keep content above iPhone home-indicator + browser bottom bar */
  padding: 1rem;
  padding-bottom: calc(1rem + env(safe-area-inset-bottom) + 88px);
}

/* drawer section titles */
.mobile-drawer-section-title {
	font-size: 1rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin: 1.5rem 0 0.75rem 0;
	color: #b3b3b3; /* muted gray default */
}

/* highlight "Shop by Make" + "Account & Support" */
.mobile-drawer-section-title:first-of-type,
.mobile-drawer-section-title:nth-of-type(2) {
	color: #ffbe3d; /* Scopione Yellow */
	text-shadow: 0 0 8px rgba(255,190,61,0.25);
	border-left: 4px solid #ffbe3d;
	padding-left: 10px;
}

/* drawer lists */
.mobile-drawer-list,
.mobile-drawer-account {
	list-style: none;
	margin: 0;
	padding: 0;
}
.mobile-drawer-list li,
.mobile-drawer-account li {
	border-bottom: 1px solid rgba(255,255,255,0.08);
}
.mobile-drawer-list a,
.mobile-drawer-account a {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 0.75rem 0;
	color: rgba(255,255,255,0.85);
	text-decoration: none;
	font-size: 1rem;
	font-weight: 500;
	transition: color 0.25s ease, transform 0.15s ease;
}
.mobile-drawer-list a:hover,
.mobile-drawer-list a:focus,
.mobile-drawer-list a:active,
.mobile-drawer-account a:hover,
.mobile-drawer-account a:focus,
.mobile-drawer-account a:active {
	color: #ffbe3d;
	transform: translateX(3px);
}
.mobile-drawer-list a .chevron,
.mobile-drawer-account a .chevron {
	font-size: 0.8rem;
	opacity: 0.6;
	color: inherit;
	margin-left: 6px;
	transition: transform 0.25s ease;
}
.mobile-drawer-list a:hover .chevron,
.mobile-drawer-account a:hover .chevron {
	transform: translateX(3px);
}

/* ====== FULLSCREEN MOBILE SEARCH OVERLAY ====== */
#mobile-search-overlay {
	position: fixed;
	inset: 0;
	background: rgba(17,17,17,0.98);
	color: #fff;
	z-index: 2100;
	display: none;
	flex-direction: column;
	padding: 1rem;
}
#mobile-search-overlay.active {
	display: flex;
}
.mobile-search-top {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 1rem;
}
.mobile-search-top h2 {
	margin: 0;
	font-size: 1rem;
	font-weight: 600;
}
.mobile-search-close-btn {
	background: none;
	border: 1px solid rgba(255,255,255,0.4);
	border-radius: 0.4rem;
	color: #fff;
	font-size: 0.8rem;
	line-height: 1;
	padding: 0.4rem 0.6rem;
}
.mobile-search-form .input-group {
	width: 100%;
}
.mobile-search-form input[type="text"] {
	background: #fff;
	color: #000;
	height: 44px;
	font-size: 1rem;
}
.mobile-search-form .btn {
	height: 44px;
	font-size: 1rem;
	display: flex;
	align-items: center;
	justify-content: center;
}
.mobile-search-form svg {
	width: 20px;
	height: 20px;
}
.mobile-search-suggestions {
	margin-top: 1rem;
}
.mobile-search-suggestions-title {
	font-size: 0.8rem;
	font-weight: 700;
	text-transform: uppercase;
	color: rgba(255,255,255,0.6);
	margin-bottom: 0.5rem;
}
.mobile-search-chip-row {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
}
.mobile-search-chip {
	background: #2a2a2a;
	border: 1px solid rgba(255,255,255,0.2);
	border-radius: 999px;
	padding: 0.4rem 0.75rem;
	font-size: 0.8rem;
	line-height: 1.2;
	color: #fff;
	text-decoration: none;
	white-space: nowrap;
}

/* =========================================================
   RESPONSIVE LAYOUT
   ========================================================= */

/* MOBILE <769px */
@media (max-width:768px){

	.site-header-inner {
		display: grid;
		grid-template-columns: auto 1fr auto; /* left cluster | spacer | right icons */
		align-items: center;
		column-gap: 0.5rem;
		row-gap: 0;
		padding-left: 0.75rem;
		padding-right: 0.75rem;
		padding-top: 0.175rem;
		padding-bottom: 0.175rem;
		max-width: 100%;
	}

	/* burger + logo baseline aligned */
	.header-left-cluster {
		grid-column: 1;
		display: flex;
		align-items: center;
		gap: 0.75rem;
		min-width: auto;
	}

	.scopione-burger {
		width: 40px;
		height: 40px;
	}

	.scopione-burger span {
		width: 24px;
		height: 3px;
		margin: 3px 0;
	}

	.scopione-logo {
		display: flex;
		align-items: center;
		justify-content: flex-start;
		margin-left: 0rem; /* optical center adjust on mobile */
	}

	.scopione-logo img {
		height: 26px;
		transform: translateY(1px);
	}

	/* icon cluster */
	.header-right {
		grid-column: 3;
		display: flex;
		align-items: center;
		justify-content: flex-end;
		gap: 0.4rem;
	}

	/* hide desktop inline search on mobile */
	.header-search-wrap {
		display: none;
	}

	/* icon tap targets mobile */
	.header-icon-link {
		width: 36px;
		height: 36px;
	}
	.header-icon-link svg {
		width: 22px;
		height: 22px;
	}

	.navbar-cart-label {
		top: 2px;
		right: 2px;
		font-size: 0.65rem;
		padding: 0.1rem 0.35rem;
	}

	.checkout-trust-badge {
		height: 24px;
	}
}

/* TABLET / DESKTOP ≥769px */
@media (min-width:769px){
	.site-header-inner {
		display: grid;
		grid-template-columns: auto 1fr auto; /* left cluster | search | icons */
		align-items: center;
		column-gap: 1rem;
		row-gap: 0;
		padding-top: 0.5rem;
		padding-bottom: 0.5rem;
		padding-left: 0rem;
		padding-right: 0rem;
		max-width: 1200px;
	}

	/* burger + logo together */
	.header-left-cluster {
		grid-column: 1;
		display: flex;
		align-items: center;
		column-gap: 0.5rem;
		min-width: 140px;
	}

	.scopione-burger {
		width: 40px;
		height: 40px;
	}

	.scopione-burger span {
		width: 24px;
		height: 3px;
		margin: 3px 0;
	}

	.scopione-logo {
		display: flex;
		align-items: center;
		justify-content: flex-start;
		line-height: 1;
		margin-left: 0.5rem;
		margin-right: 0;
	}

	.scopione-logo img {
		height: 34px;
		transform: translateY(2px);
	}

	/* search middle column */
	.header-search-wrap {
		grid-column: 2;
		display: block;
		width: 100%;
		max-width: 700px;
		margin: 0 auto;
	}

	/* icons right */
	.header-right {
		grid-column: 3;
		display: flex;
		align-items: center;
		justify-content: flex-end;
		gap: 0.2rem;
	}

	.header-icon-link {
		width: 40px;
		height: 40px;
	}
	.header-icon-link svg {
		width: 24px;
		height: 24px;
	}

	.navbar-cart-label {
		top: 4px;
		right: 4px;
		font-size: 0.7rem;
		padding: 0.15rem 0.4rem;
	}

	.checkout-trust-badge {
		height: 28px;
	}
}

/* WIDE DESKTOP ≥1024px */
@media (min-width:1024px){
	.site-header-inner {
		column-gap: 2rem;
	}
	.header-search-wrap {
		max-width: 700px;
		margin: 0 auto;
	}
}

/* ULTRA-WIDE ≥1440px */
@media (min-width:1440px){
	.header-search-wrap {
		max-width: 800px;
	}
}
