/* ==========================================================================
   Global header — matches Figma navbar + megamenus. Tokens from the design.
   ========================================================================== */
:root {
	--ffh-bg: #1e1e1e;
	--ffh-bg-deep: #050505;
	--ffh-orange: #ff6700;
	--ffh-grey: #505050;
	--ffh-grey-light: #828282;
	--ffh-white: #ffffff;
	--ffh-font: 'Open Sans', system-ui, sans-serif;
	--ffh-font-display: 'League Spartan', 'Open Sans', sans-serif;
	--ffh-max: 1312px;
	--ffh-gutter: 64px;
}

.ffh { position: relative; z-index: 1000; background: var(--ffh-bg); color: var(--ffh-white); font-family: var(--ffh-font); }
.ffh *, .ffh *::before, .ffh *::after { box-sizing: border-box; }
.ffh a { color: inherit; text-decoration: none; }
.ffh :where(ul) { list-style: none; margin: 0; padding: 0; }
.ffh :where(button) { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
.ffh img { display: block; }

/* ---- Bar ---- */
.ffh__bar { position: relative; }
.ffh__inner { max-width: calc(var(--ffh-max) + 2 * var(--ffh-gutter)); margin: 0 auto; padding: 0 var(--ffh-gutter); height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.ffh__left { display: flex; align-items: center; gap: 32px; min-width: 0; }
.ffh__logo { display: block; flex-shrink: 0; }
.ffh__logo img { height: 35px; width: auto; }
.ffh__nav { display: flex; }
.ffh__menu { display: flex; align-items: center; gap: 32px; }
.ffh__link {
	display: inline-flex; align-items: center; height: 24px;
	font-size: 16px; font-weight: 600; line-height: 24px; letter-spacing: 0.8px; text-transform: uppercase; color: var(--ffh-white);
	white-space: nowrap; position: relative; transition: color .15s;
}
.ffh__item.is-current > .ffh__link, .ffh__item.is-open > .ffh__link, .ffh__link:hover { color: var(--ffh-orange); }
.ffh__item.is-current > .ffh__link::after { content: ''; position: absolute; left: 0; right: 0; bottom: -7px; height: 2px; background: var(--ffh-orange); }

/* ---- Buttons ---- */
.ffh__btn {
	display: inline-flex; align-items: center; justify-content: center; gap: 12px; height: 40px; padding: 8px 20px; border-radius: 100px; border: 1px solid transparent;
	font-size: 16px; font-weight: 600; line-height: 24px; letter-spacing: 0.8px; text-transform: uppercase; white-space: nowrap; transition: filter .15s, background .15s;
}
.ffh__btn--ghost { background: rgba(255,255,255,0.1); color: var(--ffh-white); }
.ffh__btn--ghost:hover { background: rgba(255,255,255,0.18); }
.ffh__btn--primary { background: var(--ffh-orange); color: var(--ffh-bg); letter-spacing: 0; }
.ffh__btn--primary:hover { filter: brightness(1.08); }
.ffh__btn--lg { height: 44px; padding: 10px 24px; letter-spacing: 0.8px; }
.ffh__btn--block { width: 100%; }
.ffh__btn-icon { width: 18px; height: 18px; }
.ffh__actions { display: flex; align-items: center; gap: 24px; flex-shrink: 0; }
.ffh__search-toggle { width: 44px; height: 44px; border-radius: 50%; background: var(--ffh-grey-light); display: inline-flex; align-items: center; justify-content: center; }
.ffh__search-toggle img, .ffh__search-toggle svg { width: 17px; height: 17px; }
.ffh__burger { display: none; width: 24px; height: 24px; flex-direction: column; justify-content: center; gap: 5px; }
.ffh__burger span { display: block; height: 2px; width: 20px; background: var(--ffh-white); border-radius: 2px; }

/* ---- Search overlay (replaces the bar content) ---- */
.ffh__search { position: absolute; inset: 0; display: flex; align-items: center; gap: 33px; max-width: calc(var(--ffh-max) + 2 * var(--ffh-gutter)); margin: 0 auto; padding: 12px var(--ffh-gutter); background: var(--ffh-bg); }
.ffh__search[hidden] { display: none; }
.ffh__search .ffh__logo { margin-right: 47px; }
.ffh__search-field { flex: 1; display: flex; align-items: center; gap: 12px; height: 48px; padding: 8px 30px; border-radius: 30px; background: var(--ffh-grey); }
.ffh__search-icon { display: inline-flex; width: 24px; height: 24px; align-items: center; justify-content: center; }
.ffh__search-icon img, .ffh__search-icon svg { width: 22px; height: 22px; }
.ffh__search-field input { flex: 1; background: none; border: 0; outline: 0; color: var(--ffh-white); font: 600 20px/30px var(--ffh-font); }
.ffh__search-field input::placeholder { color: var(--ffh-white); opacity: 1; }
.ffh__search-close { width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center; }

/* ---- Dropdowns ---- */
.ffh__dd { position: absolute; left: 0; right: 0; top: 72px; background: var(--ffh-bg); box-shadow: 0 24px 48px rgba(0,0,0,0.35); }
.ffh__dd[hidden] { display: none; }
.ffh__dd-inner { max-width: calc(var(--ffh-max) + 2 * var(--ffh-gutter)); margin: 0 auto; }

/* Shared intro block (heading / text / button) */
.ffh__dd-intro { display: flex; flex-direction: column; gap: 32px; align-items: flex-start; }
.ffh__dd-title { display: flex; flex-direction: column; gap: 16px; }
.ffh__dd-heading { margin: 0; font: 700 36px/1.1 var(--ffh-font-display); letter-spacing: -0.36px; text-transform: uppercase; color: var(--ffh-white); }
.ffh__dd-text { margin: 0; font-size: 16px; line-height: 24px; color: var(--ffh-white); }

/* Type: cards (Our Builds) */
.ffh__dd--cards .ffh__dd-inner { display: flex; align-items: center; gap: 48px; padding: 24px var(--ffh-gutter); }
.ffh__dd--cards .ffh__dd-intro { width: 394px; flex-shrink: 0; }
.ffh__cards { display: flex; gap: 24px; flex: 1; min-width: 0; }
.ffh__card { flex: 1; min-width: 0; display: flex; flex-direction: column; border-radius: 16px; overflow: hidden; background: var(--ffh-bg-deep); color: var(--ffh-white); transition: transform .15s; }
.ffh__card:hover { transform: translateY(-2px); }
.ffh__card.is-highlight { background: var(--ffh-orange); }
.ffh__card-img { aspect-ratio: 274 / 234; background: #2a2a2a; }
.ffh__card-img img { width: 100%; height: 100%; object-fit: cover; }
.ffh__card-body { padding: 24px; display: flex; flex-direction: column; gap: 8px; }
.ffh__card-title { margin: 0; font: 700 22px/1.1 var(--ffh-font-display); letter-spacing: -0.22px; text-transform: uppercase; }
.ffh__card-text { margin: 0; font-size: 14px; line-height: 21px; }

/* Type: panel (Shop) */
.ffh__dd--panel .ffh__dd-inner { display: flex; gap: 32px; max-width: none; margin: 0; padding: 0; }
.ffh__list { flex: 0 0 295px; display: flex; flex-direction: column; gap: 24px; padding: 32px 0 32px var(--ffh-gutter); margin-left: max(0px, calc((100% - var(--ffh-max) - 2 * var(--ffh-gutter)) / 2)); }
.ffh__list-title { margin: 0; font-size: 16px; font-weight: 600; line-height: 24px; text-transform: uppercase; }
.ffh__list-links { display: flex; flex-direction: column; gap: 16px; }
.ffh__list-links a { font-size: 16px; line-height: 24px; transition: color .15s; }
.ffh__list-links a:hover { color: var(--ffh-orange); }
.ffh__panel { flex: 1; display: flex; align-items: flex-start; gap: 48px; padding: 32px var(--ffh-gutter) 32px 32px; margin: 0 1px 0 0; background: var(--ffh-bg-deep); border-radius: 16px; min-height: 372px; }
.ffh__dd-intro--panel { width: 304px; flex-shrink: 0; }
.ffh__panel-img { width: 308px; height: 308px; border-radius: 16px; overflow: hidden; flex-shrink: 0; }
.ffh__panel-img img { width: 100%; height: 100%; object-fit: cover; }

/* Type: icon grid (Compliance / About) */
.ffh__dd--grid .ffh__dd-inner { padding: 32px var(--ffh-gutter); }
.ffh__grid { display: flex; gap: 32px; }
.ffh__grid-item { flex: 1; min-width: 0; }
.ffh__grid-item a { display: flex; gap: 12px; padding: 8px 0; align-items: flex-start; }
.ffh__grid-icon { width: 24px; height: 24px; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; }
.ffh__grid-icon img { width: 24px; height: 24px; }
.ffh__grid-body { display: flex; flex-direction: column; }
.ffh__grid-title { font-size: 16px; font-weight: 600; line-height: 24px; letter-spacing: 0.8px; text-transform: uppercase; transition: color .15s; }
.ffh__grid-item a:hover .ffh__grid-title { color: var(--ffh-orange); }
.ffh__grid-desc { font-size: 14px; line-height: 21px; }

/* ---- Mobile drawer ---- */
.ffh__mobile { position: fixed; inset: 0; top: var(--wp-admin--admin-bar--height, 0px); z-index: 1001; background: var(--ffh-bg); overflow-y: auto; display: flex; flex-direction: column; padding-bottom: 96px; }
.ffh__mobile[hidden] { display: none; }
.ffh__mobile-top { display: flex; align-items: center; justify-content: space-between; height: 64px; padding: 0 20px; }
.ffh__mobile-top .ffh__logo img { height: 25px; }
.ffh__mobile-top-actions { display: flex; align-items: center; gap: 12px; }
.ffh__mobile-phone { width: 44px; height: 44px; border-radius: 50%; background: var(--ffh-orange); display: inline-flex; align-items: center; justify-content: center; }
.ffh__mobile-phone img { width: 18px; height: 18px; }
.ffh__mobile-close { width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; }
.ffh__mobile-menu { padding: 16px 20px 24px; display: flex; flex-direction: column; }
.ffh__mobile-link { display: flex; align-items: center; justify-content: space-between; width: 100%; padding: 12px 0; font-size: 16px; font-weight: 600; line-height: 24px; letter-spacing: 0.8px; text-transform: uppercase; text-align: left; }
.ffh__mobile-chev { width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; transition: transform .2s; }
.ffh__mobile-chev img, .ffh__mobile-chev svg { width: 8px; height: 13px; }
.ffh__mobile-item.is-open .ffh__mobile-chev { transform: rotate(90deg); }
.ffh__mobile-sub { padding: 16px 0; display: flex; flex-direction: column; gap: 8px; }
.ffh__mobile-sub[hidden] { display: none; }
.ffh__mobile-sub a { display: flex; align-items: center; gap: 12px; padding: 12px 0; font-size: 14px; font-weight: 600; line-height: 24px; letter-spacing: 0.7px; text-transform: uppercase; }
.ffh__mobile-sub-icon { width: 24px; height: 24px; display: inline-flex; align-items: center; justify-content: center; }
.ffh__mobile-sub-icon img { width: 24px; height: 24px; max-width: 24px; }
.ffh__mobile-actions { padding: 0 20px; display: flex; flex-direction: column; gap: 16px; }
.ffh__mobile .ffh__btn--primary { color: var(--ffh-white); letter-spacing: 0.8px; }
.ffh__backdrop { position: fixed; inset: 0; z-index: 999; background: rgba(0,0,0,0.5); }
.ffh__backdrop[hidden] { display: none; }
body.ffh-locked { overflow: hidden; }

/* ---- Breakpoints ---- */
@media (max-width: 1180px) {
	:root { --ffh-gutter: 32px; }
	.ffh__menu { gap: 20px; }
	.ffh__actions { gap: 12px; }
	.ffh__btn--ghost { display: none; }
}
@media (max-width: 991px) {
	.ffh__inner { height: 64px; padding: 0 20px; }
	.ffh__logo img { height: 25px; }
	.ffh__nav, .ffh__btn--ghost, .ffh__search-toggle, .ffh__dd { display: none !important; }
	.ffh__actions .ffh__btn--primary { width: 44px; height: 44px; padding: 0; border-radius: 50%; }
	.ffh__actions .ffh__btn--primary span { display: none; }
	.ffh__burger { display: flex; }
}
