/* grail.works — global chrome (header / footer / section scaffolding).
   Faithful rebuild of the production Squarespace chrome as it RENDERS
   (see production-capture/screenshots + tokens.md). Section content styles
   live inline per page (ported verbatim from the production code blocks). */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  padding: 0;
  background: #F5F5F5;
  font-family: sans-serif; /* production default; custom sections set their own */
}
img { max-width: 100%; }

/* ---------- a11y skip link ---------- */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: #FDB833;
  color: #1C2331;
  padding: 10px 18px;
  z-index: 200;
  font-family: 'Muli', sans-serif;
}
.skip-link:focus { left: 0; }

/* ---------- header (v4: fixed, dark, 72px — ported from the flagship pages) ---------- */
header.site {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50; height: 72px;
  display: flex; align-items: center;
  background: rgba(11,15,22,.62); backdrop-filter: blur(16px) saturate(1.2);
  border-bottom: 1px solid rgba(244,243,239,.08); transition: background .3s ease;
}
header.site.solid { background: rgba(11,15,22,.9); }
header.site .wrap {
  display: flex; align-items: center; justify-content: space-between;
  width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 44px; z-index: 2;
}
.brand {
  font-family: 'Bebas Neue', sans-serif; font-size: 30px; letter-spacing: 2.5px;
  color: #F4F3EF; text-decoration: none; line-height: 1; display: inline-flex;
}
.brand .g { color: #FDB833; }
nav.main { display: flex; align-items: center; gap: 34px; }
nav.main a {
  color: rgba(244,243,239,.72); text-decoration: none; font-family: 'Inter', sans-serif;
  font-size: 14.5px; font-weight: 500; letter-spacing: .2px; transition: color .2s ease;
}
nav.main a:hover { color: #F4F3EF; }
nav.main a.active,
nav.main a[aria-current="page"] { color: #FDB833; }
nav.main a.pill, nav.main a.pill.sm { color: #1C2331; font-weight: 700; }
.pill {
  display: inline-block; background: linear-gradient(96deg,#FFD98A,#FDB833 55%,#E8981D);
  color: #1C2331; font-family: 'Inter', sans-serif; font-weight: 700; font-size: 14px;
  letter-spacing: .3px; text-decoration: none; padding: 11px 24px; border-radius: 40px;
  box-shadow: 0 14px 40px -12px rgba(253,184,51,.5); transition: transform .2s ease;
}
.pill:hover { transform: translateY(-2px); }
/* burger (mobile) */
.burger {
  display: none; width: 40px; height: 40px; border: 1px solid rgba(244,243,239,.16);
  border-radius: 9px; background: transparent; cursor: pointer; padding: 0;
  align-items: center; justify-content: center;
}
.burger span { display: block; width: 18px; height: 2px; background: #F4F3EF; position: relative; }
.burger span::before, .burger span::after {
  content: ''; position: absolute; left: 0; width: 18px; height: 2px; background: #F4F3EF;
}
.burger span::before { top: -6px; } .burger span::after { top: 6px; }
/* mobile fullscreen menu */
.mobmenu {
  position: fixed; inset: 0; z-index: 60; background: rgba(11,15,22,.98); backdrop-filter: blur(10px);
  display: none; flex-direction: column; align-items: center; justify-content: center; gap: 30px;
}
.mobmenu.open { display: flex; }
html.menuopen header.site { display: none; }
.mobmenu a { color: #F4F3EF; text-decoration: none; font-family: 'Bebas Neue', sans-serif; font-size: 34px; letter-spacing: 1px; }
.mobmenu a[aria-current="page"] { color: #FDB833; }
.mobmenu .close { position: absolute; top: 22px; right: 28px; font-size: 34px; color: rgba(244,243,239,.72); background: none; border: none; cursor: pointer; }

/* the fixed header overlays the page — main clears it (72px) */
main { padding-top: 72px; }

@media (max-width: 900px) {
  nav.main { display: none; }
  .burger { display: flex; }
  header.site .wrap { padding: 0 24px; }
}

/* ---------- page sections (Squarespace fluid-engine parity) ---------- */
/* Squarespace clips every section horizontally (overflow-x: clip) — decorative
   pseudo-elements must never widen the page. */
main section { overflow-x: clip; }
@media (max-width: 767px) {
  /* production insets every page section at mobile: dark page bg shows as
     ~5.5vw gutters either side (visible beside light sections) */
  body:has(main section) { background: #1C2331; }
  /* !important: several sections' own CSS declares margin: 0 */
  main section { margin-left: 5.5vw !important; margin-right: 5.5vw !important; width: auto !important; }
}

/* ---------- section scaffolding (photo-background sections) ---------- */
.ps { position: relative; }
.ps-bg { position: absolute; inset: 0; overflow: hidden; }
.ps-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.ps-content { position: relative; z-index: 1; }

/* ---------- footer (v4 — ported from the flagship pages) ---------- */
footer.site { background:#080B11; border-top:1px solid rgba(244,243,239,.07); padding:clamp(64px,7vw,88px) 0 40px; font-family:'Inter',-apple-system,sans-serif; }
footer.site .wrap { max-width:1120px; margin:0 auto; padding:0 44px; }
.fgrid { display:grid; grid-template-columns:1.4fr 1fr 1fr 1fr 1.3fr; gap:40px; margin:0 0 clamp(44px,5vw,60px); }
.fbrand .brand { font-family:'Bebas Neue',sans-serif; font-size:26px; letter-spacing:2px; color:#F4F3EF; text-decoration:none; line-height:1; display:inline-flex; margin:0 0 16px; }
.fbrand .brand .g { color:#FDB833; }
.fbrand p { font-size:13.5px; line-height:1.6; color:rgba(244,243,239,.45); max-width:30ch; margin:0; }
.fcol h4 { font-size:11px; font-weight:700; letter-spacing:1.8px; text-transform:uppercase; color:rgba(244,243,239,.45); margin:0 0 18px; }
.fcol a, .fcol span { display:block; color:rgba(244,243,239,.72); text-decoration:none; font-size:14px; line-height:1.5; margin:0 0 12px; }
.fcol a:hover { color:#F4F3EF; }
.fcol .addr { color:rgba(244,243,239,.45); }
.fbot { display:flex; align-items:center; justify-content:space-between; gap:24px; flex-wrap:wrap;
  border-top:1px solid rgba(244,243,239,.07); padding-top:28px; }
.fbot .legal { font-size:12.5px; color:rgba(244,243,239,.45); }
.fsoc { display:flex; gap:22px; flex-wrap:wrap; }
.fsoc a { color:rgba(244,243,239,.72); text-decoration:none; font-size:13px; }
.fsoc a:hover { color:#FDB833; }
@media (max-width: 900px) {
  .fgrid { grid-template-columns:1fr 1fr; gap:36px 30px; }
  .fbrand { grid-column:1 / -1; }
  footer.site .wrap { padding-left:24px; padding-right:24px; }
}
@media (max-width: 560px) {
  .fgrid { grid-template-columns:1fr; }
}

/* ---------- YouTube click-to-play lightbox (home) ---------- */
.yt-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(10, 14, 20, .92);
  z-index: 300;
  align-items: center;
  justify-content: center;
  padding: 4vw;
}
.yt-lightbox.open { display: flex; }
.yt-lightbox .yt-frame-wrap {
  position: relative;
  width: min(1120px, 92vw);
  aspect-ratio: 16 / 9;
  background: #000;
}
.yt-lightbox iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.yt-lightbox .yt-close {
  position: absolute;
  top: -44px;
  right: 0;
  background: none;
  border: 0;
  color: #F5F5F5;
  font-size: 32px;
  line-height: 1;
  cursor: pointer;
  font-family: 'Muli', sans-serif;
}

/* ---------- accessibility baseline (2026) ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
:focus-visible {
  outline: 3px solid #FDB833;
  outline-offset: 2px;
  border-radius: 2px;
}

/* balanced display headings: no orphan last words (progressive enhancement) */
h1, h2, h3 { text-wrap: balance; }
