/**
 * Header, off-canvas menu, and footer.
 *
 * Reproduces the production pattern: a slim announcement bar, a transparent header
 * over the hero with the wordmark left and a "Menu" trigger right, and a full-screen
 * near-black overlay menu.
 *
 * The production menu is an ElementsKit off-canvas widget that is not keyboard
 * operable and leaves focus behind the overlay. This implementation is a real
 * dialog: focus is trapped while open, Escape closes, and the trigger is restored.
 */

/* ---- Announcement bar --------------------------------------------------- */

.sfx-announce {
	background: var(--sfx-ink);
	color: var(--sfx-white);
	font-size: var(--sfx-fs-fine);
	padding: 6px 0;
}
.sfx-announce__inner { display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap; }
.sfx-announce a { color: var(--sfx-green); text-underline-offset: 2px; }

/* ---- Header ------------------------------------------------------------- */

.sfx-header {
	position: absolute;
	inset-inline: 0;
	z-index: 100;
	padding-block: 20px;
}

/* Pages without a dark hero get a solid header so the wordmark stays legible. */
.sfx-header--solid {
	position: sticky;
	top: 0;
	background: var(--sfx-white);
	border-bottom: 1px solid var(--sfx-grey-200);
}

.sfx-header__inner { display: flex; align-items: center; justify-content: space-between; gap: var(--sfx-gutter-sm); }
.sfx-header__brand { display: inline-flex; align-items: center; text-decoration: none; }
.sfx-header__brand img { max-height: 40px; width: auto; }
.sfx-header__brand-text { font-size: 20px; font-weight: var(--sfx-w-semibold); color: var(--sfx-white); }
.sfx-header--solid .sfx-header__brand-text { color: var(--sfx-ink); }

.sfx-header__actions { display: flex; align-items: center; gap: 16px; }

/* Menu trigger — white pill, matching production. */
.sfx-menu-toggle {
	display: inline-flex;
	align-items: center;
	gap: 14px;
	padding: 12px 20px;
	background: var(--sfx-white);
	border: 1px solid var(--sfx-white);
	border-radius: var(--sfx-radius);
	font-family: var(--sfx-font);
	font-size: 15px;
	font-weight: var(--sfx-w-medium);
	color: var(--sfx-ink);
	cursor: pointer;
}
.sfx-header--solid .sfx-menu-toggle { border-color: var(--sfx-grey-200); }
.sfx-menu-toggle__bars { display: grid; gap: 3px; }
.sfx-menu-toggle__bars span { display: block; width: 20px; height: 1.5px; background: var(--sfx-ink); }

/* ---- Off-canvas overlay menu -------------------------------------------- */

.sfx-offcanvas {
	position: fixed;
	inset: 0;
	z-index: 200;
	background: var(--sfx-black);
	color: var(--sfx-white);
	overflow-y: auto;
	padding: 40px 0 80px;
	/* Closed by the [hidden] attribute so the menu is inert and unreachable by
	   keyboard or screen reader until opened. */
}

.sfx-offcanvas[hidden] { display: none; }

.sfx-offcanvas__top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 60px; }

.sfx-offcanvas__close {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	padding: 12px 20px;
	background: transparent;
	border: 1px solid var(--sfx-hairline);
	border-radius: var(--sfx-radius);
	font-family: var(--sfx-font);
	font-size: 15px;
	color: var(--sfx-white);
	cursor: pointer;
}
.sfx-offcanvas__close:hover { border-color: var(--sfx-green); color: var(--sfx-green); }

.sfx-offcanvas__cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--sfx-gutter); }

.sfx-offcanvas__group-title {
	font-size: 20px;
	font-weight: var(--sfx-w-medium);
	color: var(--sfx-white);
	margin: 0 0 20px;
	padding-bottom: 12px;
	border-bottom: 1px solid var(--sfx-hairline);
}

.sfx-offcanvas__list { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.sfx-offcanvas__list a {
	color: var(--sfx-grey-300);
	text-decoration: none;
	font-size: var(--sfx-fs-body);
	transition: color var(--sfx-dur) var(--sfx-ease);
}
.sfx-offcanvas__list a:hover,
.sfx-offcanvas__list a:focus-visible { color: var(--sfx-green); }

/* Descriptive sublabels are what make the mega menu useful to a retrieval system
   as well as a buyer: the anchor text says what the page answers. */
.sfx-offcanvas__desc { display: block; font-size: var(--sfx-fs-fine); color: var(--sfx-ink-300); margin-top: 2px; }

@media (max-width: 1024px) { .sfx-offcanvas__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 767px)  { .sfx-offcanvas__cols { grid-template-columns: minmax(0, 1fr); } }

body.sfx-menu-open { overflow: hidden; }

/* ---- Footer ------------------------------------------------------------- */

.sfx-footer { background: var(--sfx-black); color: var(--sfx-grey-300); padding-block: var(--sfx-section-y) 40px; }
.sfx-footer a { color: var(--sfx-grey-300); text-decoration: none; }
.sfx-footer a:hover { color: var(--sfx-green); }
.sfx-footer__cols { display: grid; grid-template-columns: 1.6fr repeat(4, minmax(0, 1fr)); gap: var(--sfx-gutter); }
.sfx-footer__title {
	font-size: var(--sfx-fs-fine);
	font-weight: var(--sfx-w-semibold);
	letter-spacing: 2px;
	text-transform: uppercase;
	color: var(--sfx-white);
	margin: 0 0 20px;
}
.sfx-footer__list { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; font-size: var(--sfx-fs-small); }
.sfx-footer__bottom {
	margin-top: 60px;
	padding-top: 24px;
	border-top: 1px solid var(--sfx-hairline);
	display: flex;
	justify-content: space-between;
	gap: 20px;
	flex-wrap: wrap;
	font-size: var(--sfx-fs-fine);
}

/* The registered entity name and address appear in the footer on every page, and
   are read from the facts ledger — the same source the Organization schema node
   uses, so the two cannot drift apart. */
.sfx-footer__entity { max-width: 42ch; font-size: var(--sfx-fs-fine); line-height: 1.7; }

@media (max-width: 1024px) { .sfx-footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 767px)  { .sfx-footer__cols { grid-template-columns: minmax(0, 1fr); } }
