/* =========================================================
   Quantum Health Innovations — v2 (follows Rakel's mockup)
   Light editorial look: ivory + navy serif headings + seal gold.
   v3 follows the full mockup (light hero, founding + closing CTA, light footer).
   ========================================================= */
:root {
  --navy-950: #071328;
  --navy-900: #0b1b3a;
  --navy: #12285a;
  --navy-btn: #173a73;
  --gold: #b8913f;
  --gold-2: #d6b46a;
  --gold-3: #f0d999;
  --gold-grad: linear-gradient(135deg, #f6e3a8 0%, #d6b36a 35%, #a98440 60%, #e9cd8c 100%);
  --ink: #2a3140;
  --muted: #5d6676;
  --paper: #ffffff;
  --ivory: #fbf8f2;
  --cream: #f6f0e3;
  --sky: #eef3fa;
  --line: #e6dcc6;
  --line-2: #efe8d9;

  --f-display: "Cinzel", "Trajan Pro", Georgia, serif;
  --f-serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --f-sans: "Inter", system-ui, -apple-system, sans-serif;

  --radius: 10px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --container: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: auto; } /* eased scrolling is handled in script.js */
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--f-sans); font-weight: 400; font-size: 17px; line-height: 1.7;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
::selection { background: var(--gold-2); color: var(--navy-950); }

.container { width: min(var(--container), 100% - 48px); margin-inline: auto; }
.section { padding: clamp(76px, 10vw, 128px) 0; position: relative; }
p { margin: 0 0 18px; }

/* ---------- Type ---------- */
.eyebrow {
  font-size: 12px; font-weight: 600; letter-spacing: .26em; text-transform: uppercase;
  color: var(--gold); margin: 0 0 18px;
}
.eyebrow--light { color: var(--gold-2); }
.h2, .hero__title { font-family: var(--f-serif); font-weight: 700; color: var(--navy); letter-spacing: -.01em; line-height: 1.12; margin: 0 0 22px; }
.h2 { font-size: clamp(30px, 3.6vw, 46px); }
.h2 em, .hero__title em { font-style: italic; font-weight: 600; color: var(--gold); }
.lead { font-size: clamp(17px, 1.35vw, 19px); color: var(--muted); max-width: 72ch; }

/* Heading with the gold rule beside it (as in the mockup) */
.head { display: flex; align-items: center; gap: 28px; margin-bottom: 18px; }
.head .h2 { margin: 0; flex: 0 1 auto; }
.head .rule { flex: 1 1 60px; min-width: 40px; max-width: 220px; height: 1.5px; background: linear-gradient(90deg, var(--gold), rgba(184,145,63,.25)); }
.head--center { justify-content: center; text-align: center; margin: clamp(64px, 8vw, 100px) 0 40px; }
.head--center .rule:first-child { background: linear-gradient(270deg, var(--gold), rgba(184,145,63,.25)); }
.head--center .rule { max-width: 160px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 16px 30px; border-radius: 6px;
  font-family: var(--f-sans); font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  border: 1px solid transparent; cursor: pointer;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), background .35s, color .35s, border-color .35s;
}
.btn--gold { background: var(--gold-grad); background-size: 200% 200%; color: var(--navy-950); box-shadow: 0 10px 30px -12px rgba(184,145,63,.6), inset 0 1px 0 rgba(255,255,255,.4); }
.btn--gold:hover { transform: translateY(-2px); background-position: 100% 0; box-shadow: 0 18px 40px -14px rgba(184,145,63,.75); }
.btn--ghost { border-color: rgba(214,180,106,.45); color: var(--gold-3); background: rgba(214,180,106,.06); }
.btn--ghost:hover { border-color: var(--gold-2); background: rgba(214,180,106,.14); transform: translateY(-2px); }
.btn--navy { background: var(--navy-btn); color: #fff; letter-spacing: .06em; text-transform: none; font-size: 15px; padding: 15px 34px; box-shadow: 0 12px 26px -14px rgba(18,40,90,.7); }
.btn--navy:hover { background: var(--navy); transform: translateY(-2px); box-shadow: 0 18px 34px -16px rgba(18,40,90,.8); }
.btn--sm { padding: 11px 20px; font-size: 12px; }
.btn--block { width: 100%; }
.link-arrow { display: inline-flex; gap: 8px; font-family: var(--f-serif); font-weight: 600; font-size: 17px; color: var(--navy); border-bottom: 1.5px solid var(--navy); padding-bottom: 3px; transition: gap .35s var(--ease), color .3s, border-color .3s; }
.link-arrow:hover { gap: 14px; color: var(--gold); border-color: var(--gold); }

/* ---------- Nav (always white, as in the mockup) ---------- */
.nav { position: fixed; inset: 0 0 auto; z-index: 50; padding: 14px 0; background: rgba(255,255,255,.96); backdrop-filter: blur(14px) saturate(1.3); -webkit-backdrop-filter: blur(14px) saturate(1.3); border-bottom: 1px solid var(--line); transition: padding .4s, box-shadow .4s; }
.nav::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1.5px; background: linear-gradient(90deg, transparent, var(--gold-2) 20%, var(--gold-2) 80%, transparent); opacity: .7; }
.nav.is-scrolled { padding: 9px 0; box-shadow: 0 8px 30px -20px rgba(11,27,58,.35); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: flex; align-items: center; gap: 14px; }
.brand__seal { width: 56px; height: 56px; border-radius: 50%; overflow: hidden; flex: none; box-shadow: 0 0 0 1.5px rgba(214,180,106,.6); transition: width .4s, height .4s; }
.nav.is-scrolled .brand__seal { width: 46px; height: 46px; }
.brand__seal img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.07); }
.brand__text { display: flex; flex-direction: column; line-height: 1.15; padding-left: 14px; border-left: 1.5px solid var(--gold-2); }
.brand__name { font-family: var(--f-serif); font-weight: 700; font-size: 17px; letter-spacing: .04em; color: var(--navy); text-transform: uppercase; max-width: 20ch; }
.brand__sub { font-family: var(--f-serif); font-style: italic; font-weight: 500; font-size: 13px; color: var(--navy); opacity: .8; margin-top: 3px; }

.nav__links { display: flex; align-items: center; gap: 30px; }
.nav__links a:not(.btn) { font-family: var(--f-serif); font-size: 16px; font-weight: 600; color: var(--navy); position: relative; padding: 6px 0; transition: color .3s; }
.nav__links a:not(.btn)::after { content: ""; position: absolute; left: 0; bottom: 0; height: 1.5px; width: 100%; background: var(--gold); transform: scaleX(0); transform-origin: right; transition: transform .4s var(--ease); }
.nav__links a:not(.btn):hover, .nav__links a.is-active:not(.btn) { color: var(--gold); }
.nav__links a:not(.btn):hover::after, .nav__links a.is-active:not(.btn)::after { transform: scaleX(1); transform-origin: left; }
.nav__cta.btn--navy { padding: 12px 22px; font-size: 14.5px; }
.nav__progress { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--gold-grad); transform: scaleX(0); transform-origin: left; pointer-events: none; z-index: 1; }
.nav__toggle { display: none; background: none; border: 0; width: 44px; height: 44px; cursor: pointer; position: relative; }
.nav__toggle span { position: absolute; left: 10px; right: 10px; height: 1.5px; background: var(--navy); transition: transform .35s var(--ease); }
.nav__toggle span:first-child { top: 17px; } .nav__toggle span:last-child { top: 26px; }
.nav__toggle[aria-expanded="true"] span:first-child { transform: translateY(4.5px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:last-child { transform: translateY(-4.5px) rotate(-45deg); }

/* ---------- Interactive extras ---------- */
.split .w { display: inline-block; overflow: hidden; vertical-align: top; padding: 0 .06em .14em 0; margin: 0 -.06em -.14em 0; }
.split .w > span { display: inline-block; transform: translateY(110%); transition: transform 1s var(--ease); transition-delay: calc(var(--i, 0) * 55ms + 120ms); }
.is-in .split .w > span, .split.is-in .w > span { transform: none; }
.has-glow { position: relative; isolation: isolate; }
.has-glow::after { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; z-index: -1; background: radial-gradient(380px circle at var(--mx, 50%) var(--my, 50%), rgba(214,180,106,.2), transparent 50%); opacity: 0; transition: opacity .4s var(--ease); }
.has-glow:hover::after { opacity: 1; }
.tilt { transform-style: preserve-3d; will-change: transform; }
.hero__seal { transition: transform .6s var(--ease), opacity 1s var(--ease) !important; }
.to-top { position: fixed; right: 22px; bottom: 22px; z-index: 40; width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; cursor: pointer; color: var(--gold-3); background: var(--navy-900); border: 1px solid rgba(214,180,106,.4); box-shadow: 0 12px 30px -12px rgba(11,27,58,.6); opacity: 0; transform: translateY(14px); pointer-events: none; transition: opacity .4s var(--ease), transform .4s var(--ease), background .3s; }
.to-top.is-visible { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--navy-btn); }

/* ---------- Hero (light, lab feel, seal on the right) ---------- */
.hero { position: relative; display: flex; align-items: center; min-height: min(88vh, 760px); padding: 150px 0 90px; overflow: hidden; color: var(--ink);
  background:
    radial-gradient(60% 70% at 78% 45%, rgba(255,255,255,.95) 0%, rgba(255,255,255,0) 70%),
    linear-gradient(115deg, #ffffff 0%, #f7f9fc 38%, #e9f0f9 70%, #dfe8f4 100%); }
.hero__bg { position: absolute; inset: 0; pointer-events: none; }
.hero__bg:not(:has(.hero__photo))::before { content: ""; position: absolute; inset: 0; opacity: .5; background-image: linear-gradient(rgba(18,40,90,.05) 1px, transparent 1px), linear-gradient(90deg, rgba(18,40,90,.05) 1px, transparent 1px); background-size: 56px 56px; -webkit-mask-image: linear-gradient(90deg, transparent 30%, #000 75%); mask-image: linear-gradient(90deg, transparent 30%, #000 75%); }
.hero__photo { position: absolute; inset: -4% 0 -4% 0; width: 100%; height: 108%; object-fit: cover; object-position: right center; opacity: .95; animation: heroZoom 2.8s var(--ease) both; will-change: transform; }
.hero__bg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(255,255,255,.94) 0%, rgba(255,255,255,.82) 34%, rgba(255,255,255,.15) 62%, rgba(255,255,255,0) 100%); }
@keyframes heroZoom { from { transform: scale(1.08); opacity: 0; } to { transform: scale(1); opacity: .95; } }
.hero__glow { position: absolute; width: 760px; height: 760px; right: -120px; top: 50%; transform: translateY(-50%); background: radial-gradient(circle, rgba(214,180,106,.18) 0%, rgba(214,180,106,0) 60%); }
#particles { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .55; }
.hero__inner { position: relative; display: grid; grid-template-columns: 1.15fr .85fr; gap: 60px; align-items: center; }
.hero__copy { border-left: 2px solid var(--gold); padding-left: clamp(22px, 3vw, 40px); }
.hero .eyebrow { display: flex; align-items: center; gap: 16px; font-size: 13px; letter-spacing: .14em; }
.hero .eyebrow::after { content: ""; width: 70px; height: 1.5px; background: var(--gold); }
.hero__title { color: var(--navy); font-size: clamp(38px, 4.6vw, 62px); line-height: 1.08; margin-bottom: 24px; max-width: 16ch; }
.hero__lead { font-size: clamp(17px, 1.35vw, 19.5px); color: var(--ink); max-width: 50ch; margin-bottom: 34px; }
.hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 18px 30px; }
.hero__seal { position: relative; aspect-ratio: 1; width: 100%; max-width: 440px; justify-self: center; }
.seal-wrap { position: absolute; inset: 9%; border-radius: 50%; overflow: hidden; box-shadow: 0 40px 80px -24px rgba(11,27,58,.55), 0 0 0 6px rgba(255,255,255,.7), 0 0 70px rgba(214,180,106,.3); animation: float 8s ease-in-out infinite; }
.seal-wrap img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.075); }
.seal-wrap::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: linear-gradient(115deg, transparent 35%, rgba(255,240,200,.22) 50%, transparent 65%); background-size: 250% 100%; animation: sheen 7s ease-in-out infinite; mix-blend-mode: screen; }
.seal-ring { position: absolute; border-radius: 50%; }
.seal-ring--1 { inset: 3%; border: 1px dashed rgba(184,145,63,.45); animation: spin 60s linear infinite; }
.seal-ring--2 { inset: -2%; border: 1px solid rgba(184,145,63,.2); }
@keyframes float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }
@keyframes sheen { 0%, 60% { background-position: 150% 0; } 100% { background-position: -100% 0; } }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Featured story (navy band with the news video) ---------- */
.feature { position: relative; padding: clamp(70px, 8vw, 110px) 0; background: radial-gradient(90% 120% at 85% 20%, #17346f 0%, var(--navy-900) 50%, var(--navy-950) 100%); color: #c5cde0; overflow: hidden; }
.feature::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(214,180,106,.16) 1px, transparent 1.4px); background-size: 26px 26px; -webkit-mask-image: linear-gradient(100deg, #000, transparent 55%); mask-image: linear-gradient(100deg, #000, transparent 55%); pointer-events: none; }
.feature__grid { position: relative; display: grid; grid-template-columns: .85fr 1.15fr; gap: clamp(36px, 5vw, 72px); align-items: center; }
.feature .eyebrow { display: flex; align-items: center; gap: 14px; color: var(--gold-2); }
.feature .eyebrow::after { content: ""; width: 56px; height: 1.5px; background: var(--gold-2); }
.feature .h2 { color: #fff; }
.feature__copy > p { font-size: 17.5px; }
.feature__source { font-family: var(--f-serif); font-style: italic; color: var(--gold-3); }
.feature__source strong { font-style: normal; color: #fff; }
.link-arrow--light { color: #fff; border-color: var(--gold-2); }
.link-arrow--light:hover { color: var(--gold-3); border-color: var(--gold-3); }
.video { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: #000; box-shadow: 0 0 0 1px rgba(214,180,106,.35), 0 40px 80px -30px rgba(0,0,0,.8); }
.video::before { content: ""; position: absolute; inset: -10px; border: 1px solid rgba(214,180,106,.22); border-radius: calc(var(--radius) + 8px); pointer-events: none; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video__play { position: absolute; inset: 0; width: 100%; padding: 0; border: 0; background: none; cursor: pointer; display: grid; place-items: center; }
.video__play img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease), filter .6s; filter: saturate(.9) brightness(.82); }
.video__play::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(7,19,40,0) 45%, rgba(7,19,40,.75) 100%); }
.video__play:hover img { transform: scale(1.04); filter: saturate(1) brightness(.92); }
.video__btn { position: relative; z-index: 1; width: 86px; height: 86px; border-radius: 50%; display: grid; place-items: center; background: var(--gold-grad); box-shadow: 0 0 0 10px rgba(214,180,106,.2), 0 18px 40px -10px rgba(0,0,0,.6); transition: transform .5s var(--ease), box-shadow .5s var(--ease); }
.video__btn::before { content: ""; position: absolute; inset: -10px; border-radius: 50%; border: 1px solid rgba(240,217,153,.6); animation: pulse 2.6s var(--ease) infinite; }
.video__btn svg { width: 34px; height: 34px; fill: var(--navy-950); margin-left: 4px; }
.video__play:hover .video__btn { transform: scale(1.08); box-shadow: 0 0 0 14px rgba(214,180,106,.25), 0 22px 50px -10px rgba(0,0,0,.7); }
.video__play:focus-visible { outline: 2px solid var(--gold-2); outline-offset: -6px; }
.video__label { position: absolute; z-index: 1; left: 22px; bottom: 18px; font-size: 12px; font-weight: 600; letter-spacing: .22em; text-transform: uppercase; color: #fff; }
@keyframes pulse { 0% { transform: scale(.9); opacity: .9; } 100% { transform: scale(1.35); opacity: 0; } }

/* ---------- Mission + principles ---------- */
.callout { margin: 30px 0 0; padding: 26px 32px; background: var(--cream); border-left: 3px solid var(--gold); border-radius: 0 var(--radius) var(--radius) 0; font-family: var(--f-serif); font-style: italic; font-weight: 600; font-size: clamp(20px, 2vw, 26px); line-height: 1.4; color: var(--navy); }
.principles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.principle { background: var(--ivory); border: 1px solid var(--line); border-radius: var(--radius); padding: 40px 30px 34px; text-align: center; transition: box-shadow .4s var(--ease), border-color .4s; }
.principle:hover { border-color: var(--gold-2); box-shadow: 0 26px 50px -30px rgba(11,27,58,.35); }
.principle h3 { font-family: var(--f-serif); font-weight: 700; font-size: 23px; color: var(--navy); margin: 18px 0 10px; line-height: 1.2; }
.principle p { color: var(--muted); font-size: 15.5px; margin: 0; }
.icon { width: 54px; height: 54px; fill: none; stroke: var(--gold); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.principle .icon { margin-inline: auto; transition: transform .5s var(--ease); }
.principle:hover .icon { transform: translateY(-4px) scale(1.06); }

/* ---------- Photos (placeholders until real images arrive) ---------- */
.photo { position: relative; overflow: hidden; border-radius: var(--radius); display: grid; place-content: center; justify-items: center; gap: 12px; color: rgba(255,255,255,.75); background: radial-gradient(120% 90% at 30% 20%, #2b4a86 0%, #13295a 55%, #0b1b3a 100%); box-shadow: 0 30px 60px -34px rgba(11,27,58,.55); }
.photo::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(214,180,106,.22) 1px, transparent 1.4px); background-size: 22px 22px; mask-image: linear-gradient(135deg, #000, transparent 75%); -webkit-mask-image: linear-gradient(135deg, #000, transparent 75%); }
.photo svg { position: relative; width: 56px; height: 56px; fill: none; stroke: var(--gold-2); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.photo span { position: relative; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; }
.photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.photo:hover img { transform: scale(1.04); }

/* ---------- Military ---------- */
.military { background: var(--sky); }
.military__grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(36px, 5vw, 70px); align-items: center; }
.photo--military { aspect-ratio: 5 / 4; }
.military__copy > p { color: var(--muted); font-size: 17.5px; }
.served { list-style: none; padding: 0; margin: 28px 0 32px; display: grid; grid-template-columns: repeat(3, auto); justify-content: start; }
.served li { font-family: var(--f-serif); font-weight: 700; font-size: 17px; line-height: 1.3; color: var(--navy); padding: 4px 26px; border-left: 1.5px solid var(--gold-2); text-align: center; display: grid; place-items: center; }
.served li:first-child { border-left: 0; padding-left: 0; }

/* ---------- Generations ---------- */
.gens { display: grid; grid-template-columns: 1fr auto 1fr; gap: 0; margin-top: 30px; }
.gens::before { content: ""; grid-column: 2; grid-row: 1; width: 1.5px; margin: 10px clamp(20px, 3vw, 40px); background: linear-gradient(var(--gold-2), rgba(214,180,106,.2)); }
.gen:first-child { grid-column: 1; grid-row: 1; } .gen:last-child { grid-column: 3; grid-row: 1; }
.gen { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: center; border-radius: var(--radius); }
.gen .photo { aspect-ratio: 4 / 3.4; }
.gen h3 { font-family: var(--f-serif); font-weight: 700; font-size: clamp(24px, 2.3vw, 30px); line-height: 1.12; color: var(--navy); margin: 0 0 12px; }
.gen p { color: var(--muted); font-size: 16px; margin: 0; }
.note { margin: 40px 0 0; padding: 16px 24px; text-align: center; background: var(--cream); border-radius: var(--radius); font-family: var(--f-serif); font-style: italic; font-weight: 500; font-size: 18px; color: var(--navy); }

/* ---------- Research ---------- */
.research { background: var(--paper); border-top: 1px solid var(--line-2); }
.areas { list-style: none; padding: 0; margin: 40px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); }
.area { display: flex; align-items: center; gap: 16px; padding: 14px 24px; border-left: 1.5px solid var(--line); border-radius: var(--radius); transition: background .4s; }
.area:first-child { border-left: 0; padding-left: 0; }
.area span { font-family: var(--f-serif); font-weight: 700; font-size: 17.5px; line-height: 1.25; color: var(--navy); }
.area .icon { flex: none; width: 48px; height: 48px; transition: transform .5s var(--ease); }
.area:hover .icon { transform: rotate(-6deg) scale(1.08); }

/* ---------- Support ---------- */
.support { background: var(--ivory); }
.support__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0; align-items: center; margin-top: 30px; }
.photo--hands { aspect-ratio: 16 / 10; }
.support__copy { padding-left: clamp(30px, 4vw, 56px); margin-left: clamp(30px, 4vw, 56px); border-left: 1.5px solid var(--gold-2); }
.support__copy p { font-size: 17.5px; color: var(--ink); margin-bottom: 30px; }

/* ---------- Founding, leadership & closing call to action ---------- */
.founding { background: var(--paper); }
.creds { list-style: none; padding: 0; margin: 30px 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.creds li { padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--ivory); display: flex; flex-direction: column; gap: 2px; transition: border-color .4s; }
.creds li:hover { border-color: var(--gold-2); }
.creds__k { font-size: 11px; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; color: var(--gold); }
.creds__v { font-family: var(--f-serif); font-weight: 700; font-size: 17px; color: var(--navy); }
.engage { margin-top: clamp(64px, 8vw, 100px); }
.engage > p { color: var(--muted); }
.engage__links { display: flex; flex-wrap: wrap; gap: 14px 0; margin-top: 18px; }
.engage__links .link-arrow { margin-right: 34px; padding-right: 0; }
.engage__links .link-arrow + .link-arrow { position: relative; }
.engage__links .link-arrow + .link-arrow::before { content: ""; position: absolute; left: -18px; top: 2px; bottom: 4px; width: 1.5px; background: var(--gold-2); }
.ahead { margin-top: clamp(64px, 8vw, 100px); text-align: center; }
.ahead .head--center { margin: 0 0 10px; }
.ahead__sub { font-family: var(--f-serif); font-style: italic; font-size: 18px; color: var(--muted); }
.ahead__actions { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 18px 0; margin-top: 26px; }
.ahead__actions .btn { margin-right: 28px; }
.ig { display: inline-flex; align-items: center; gap: 12px; padding-left: 28px; border-left: 1.5px solid var(--gold-2); font-family: var(--f-serif); font-weight: 700; font-size: 17px; color: var(--navy); transition: color .3s; }
.ig svg, .footer__ig svg { width: 30px; height: 30px; fill: none; stroke: var(--gold); stroke-width: 1.7; }
.ig:hover { color: var(--gold); }

/* ---------- Contact ---------- */
.contact { background: var(--sky); }
.contact__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 6vw, 90px); align-items: start; }
.contact__intro > p { color: var(--muted); }
.contact__list { list-style: none; padding: 0; margin: 28px 0 0; }
.contact__list li { display: flex; gap: 20px; padding: 14px 0; border-bottom: 1px solid #d9e2ef; font-size: 16px; color: var(--ink); }
.contact__list span { width: 96px; flex: none; font-size: 11px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); padding-top: 4px; }
.contact__list a:hover { color: var(--gold); }
.contact__form { background: var(--paper); padding: clamp(28px, 4vw, 44px); border-radius: var(--radius); box-shadow: 0 30px 60px -36px rgba(11,27,58,.45); border: 1px solid #e3e9f2; }
.field { margin-bottom: 20px; }
.field label { display: block; font-size: 11px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase; color: var(--navy); margin-bottom: 8px; }
.field input, .field select, .field textarea { width: 100%; padding: 13px 14px; border: 1px solid #d5dce8; border-radius: 6px; background: #fbfcfe; font: inherit; font-size: 16px; color: var(--ink); outline: none; transition: border-color .3s, box-shadow .3s; }
.field select { appearance: none; -webkit-appearance: none; background: #fbfcfe url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23b8913f' stroke-width='1.5'/%3E%3C/svg%3E") right 14px center no-repeat; }
.field textarea { resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(214,180,106,.2); }
.form__ok { margin: 16px 0 0; font-size: 14px; color: var(--navy); text-align: center; }

/* ---------- Footer (centered seal, motto between gold rules, roomy) ---------- */
.footer { position: relative; background: var(--ivory); color: var(--muted); padding: clamp(72px, 8vw, 100px) 0 0; border-top: 1px solid var(--line); }
.footer::before { content: ""; position: absolute; top: -1px; left: 50%; width: min(520px, 70%); height: 2px; transform: translateX(-50%); background: linear-gradient(90deg, transparent, var(--gold), transparent); }
.footer__inner { display: flex; flex-direction: column; align-items: center; text-align: center; }
.footer__brand { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.footer__seal { width: 104px; height: 104px; border-radius: 50%; overflow: hidden; margin-bottom: 14px; isolation: isolate; box-shadow: 0 0 0 1px rgba(184,145,63,.55), 0 0 0 7px var(--paper), 0 0 0 8px rgba(184,145,63,.25), 0 22px 40px -18px rgba(11,27,58,.45); transition: transform .8s var(--ease); }
.footer__seal img { width: 100%; height: 100%; object-fit: cover; transform: scale(1.07); }
.footer__seal { position: relative; }
.footer__seal::after { content: ""; position: absolute; inset: 0; border-radius: 50%; background: linear-gradient(115deg, transparent 30%, rgba(255,244,214,.75) 48%, rgba(255,255,255,.15) 56%, transparent 70%); background-size: 260% 100%; background-position: 130% 0; mix-blend-mode: screen; pointer-events: none; }
.footer__brand:hover .footer__seal::after { animation: glint 1.1s var(--ease) forwards; }
@keyframes glint { from { background-position: 130% 0; } to { background-position: -40% 0; } }
.footer__name { font-family: var(--f-serif); font-weight: 700; font-size: 20px; letter-spacing: .06em; text-transform: uppercase; color: var(--navy); }
.footer__sub { font-family: var(--f-serif); font-style: italic; font-size: 15px; color: var(--muted); }
.footer__motto { display: flex; align-items: center; justify-content: center; gap: 18px; margin: 28px 0 0; font-family: var(--f-serif); font-style: italic; font-weight: 600; font-size: 19px; color: var(--navy); }
.footer__motto i { font-style: normal; color: var(--gold); margin: 0 4px; }
.footer__motto .rule { width: 56px; height: 1.5px; background: linear-gradient(90deg, transparent, var(--gold)); }
.footer__motto .rule:last-child { background: linear-gradient(270deg, transparent, var(--gold)); }
.footer__links { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 8px 0; margin: 36px 0 0; padding: 18px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); width: 100%; max-width: 860px; }
.footer__links a { position: relative; font-family: var(--f-serif); font-weight: 600; font-size: 15.5px; color: var(--navy); padding: 4px 18px; transition: color .3s; }
.footer__links a + a::before { content: ""; position: absolute; left: 0; top: 50%; width: 4px; height: 4px; border-radius: 50%; background: var(--gold-2); transform: translate(-50%, -50%); }
.footer__links a:hover { color: var(--gold); }
.footer__links .footer__ig { display: inline-flex; padding-right: 0; }
.footer__links .footer__ig:hover svg { transform: scale(1.12); }
.footer__ig svg { transition: transform .4s var(--ease); }
.footer__bottom { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px 40px; flex-wrap: wrap; padding: 30px 0 clamp(40px, 5vw, 56px); font-size: 13px; line-height: 1.6; color: #7a8292; }
.footer__bottom p { margin: 0; }
.footer__disclaimer { max-width: 520px; text-align: right; }

/* ---------- Premium interactions ---------- */
/* Photos unveil with a soft wipe and settle from a slight zoom */
.photo.has-img { background: var(--cream); }
.photo.has-img::before { display: none; }
.photo.has-img::after { content: ""; position: absolute; inset: 10px; border: 1px solid rgba(255,255,255,.55); border-radius: calc(var(--radius) - 4px); opacity: 0; transform: scale(1.03); transition: opacity .6s var(--ease), transform .6s var(--ease); pointer-events: none; }
.photo.has-img:hover::after { opacity: 1; transform: none; }
.reveal.reveal--img { opacity: 1; transform: none; }
.photo.has-img img { top: -7%; height: 114%; will-change: translate; }
.reveal--img img, .gen.reveal .photo img { clip-path: inset(0 0 100% 0); transform: scale(1.14); transition: clip-path 1.3s var(--ease), transform 1.8s var(--ease); }
.reveal--img.is-in img, .gen.reveal.is-in .photo img { clip-path: inset(0); transform: scale(1); }
.reveal--img.is-in:hover img, .gen.reveal.is-in .photo:hover img { transform: scale(1.04); transition-duration: 1.3s, 1.2s; }
/* Gold rules draw in beside headings */
.head .rule { transform: scaleX(0); transform-origin: left; transition: transform 1.4s var(--ease) .35s; }
.head--center .rule:first-child { transform-origin: right; }
.head.is-in .rule, .is-in .head .rule { transform: scaleX(1); }
/* Cards lift gently */
.principle, .creds li { transition: transform .5s var(--ease), box-shadow .5s var(--ease), border-color .4s; }
.principle:hover, .creds li:hover { transform: translateY(-4px); }
.creds li:hover { box-shadow: 0 20px 40px -28px rgba(11,27,58,.4); }
.area .icon { transition: transform .5s var(--ease); }
.area:hover .icon { transform: translateY(-3px) rotate(-6deg); }
.served li { transition: color .3s; }
.served li:hover { color: var(--gold); }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
  .reveal--img img, .gen.reveal .photo img { clip-path: none; }
  .reveal--img img, .gen.reveal .photo img, .hero__photo { transform: none; animation: none; }
  .head .rule { transform: none; }
  .seal-wrap, .seal-wrap::after, .seal-ring--1, .video__btn::before { animation: none; }
}

/* ---------- Tablet ---------- */
@media (max-width: 1024px) {
  .hero__inner, .military__grid, .contact__grid, .support__grid { grid-template-columns: 1fr; }
  .hero { padding: 130px 0 80px; }
  .hero__copy, .contact__intro, .military__copy, .support__copy, .section > .container > .lead { text-align: center; }
  .hero__lead, .lead { margin-inline: auto; }
  .hero__actions { justify-content: center; }
  .hero__seal { max-width: 380px; grid-row: 1; }
  .head { justify-content: center; text-align: center; }
  .head .rule { display: none; }
  .head .h2 { flex: 1 1 auto; }
  .callout { text-align: center; border-left: 0; border-top: 3px solid var(--gold); border-radius: 0 0 var(--radius) var(--radius); }
  .principles { gap: 16px; }
  .principle { padding: 32px 20px 28px; }
  .photo--military, .photo--hands { max-width: 640px; width: 100%; margin-inline: auto; }
  .served { justify-content: center; }
  .gens { grid-template-columns: 1fr 1fr; gap: 28px; }
  .gens::before { display: none; }
  .gen:first-child, .gen:last-child { grid-column: auto; grid-row: auto; }
  .gen { grid-template-columns: 1fr; text-align: center; gap: 20px; align-items: start; }
  .areas { grid-template-columns: 1fr 1fr; gap: 10px 0; }
  .area:nth-child(3) { border-left: 0; padding-left: 0; }
  .support__copy { padding: 34px 0 0; margin: 34px 0 0; border-left: 0; border-top: 1.5px solid var(--gold-2); max-width: 640px; margin-inline: auto; }
  .contact__list { max-width: 460px; margin-inline: auto; text-align: left; }
  .hero__copy { border-left: 0; padding-left: 0; }
  .feature__grid { grid-template-columns: 1fr; }
  .feature__copy { text-align: center; }
  .feature .eyebrow { justify-content: center; }
  .feature .eyebrow::before { content: ""; width: 40px; height: 1.5px; background: var(--gold-2); }
  .feature .eyebrow::after { width: 40px; }
  .video { max-width: 720px; width: 100%; margin-inline: auto; }
  .hero__bg::after { background: linear-gradient(180deg, rgba(255,255,255,.35) 0%, rgba(255,255,255,.88) 48%, rgba(255,255,255,.95) 100%); }
  .hero .eyebrow { justify-content: center; }
  .hero .eyebrow::before { content: ""; width: 40px; height: 1.5px; background: var(--gold); }
  .hero .eyebrow::after { width: 40px; }
  .hero__title { margin-inline: auto; }
  .hero__seal { max-width: 300px; }
  .creds { grid-template-columns: 1fr 1fr; }
  .founding .lead, .engage > p { text-align: center; margin-inline: auto; }
  .engage__links { justify-content: center; }
  .footer__bottom { flex-direction: column; align-items: center; text-align: center; }
  .footer__disclaimer { text-align: center; }
}
@media (max-width: 900px) {
  .nav__toggle { display: block; z-index: 2; }
  .nav.menu-open { backdrop-filter: none; -webkit-backdrop-filter: none; }
  .nav__links { position: fixed; inset: 0; flex-direction: column; justify-content: center; gap: 26px; background: var(--paper); opacity: 0; pointer-events: none; transition: opacity .4s var(--ease); }
  .nav__links.is-open { opacity: 1; pointer-events: auto; }
  .nav__links a:not(.btn) { font-family: var(--f-serif); font-weight: 700; font-size: 26px; letter-spacing: 0; text-transform: none; color: var(--navy) !important; }
  .nav__cta { margin-top: 8px; }
  .brand { position: relative; z-index: 2; }
  .brand__name { font-size: 15px; }
  .brand__sub { font-size: 12px; }
  .brand__seal { width: 48px; height: 48px; }

}

/* ---------- Phone ---------- */
@media (max-width: 640px) {
  body { font-size: 16px; }
  .container { width: calc(100% - 40px); }
  .section { padding: 68px 0; }
  .hero__title { font-size: clamp(34px, 9.5vw, 44px); }
  .hero__actions .btn { width: 100%; }
  .hero__seal { max-width: 280px; }
  .callout { padding: 22px; font-size: 19px; }
  .principle { padding: 32px 24px 28px; }
  .served { grid-template-columns: 1fr; gap: 12px; }
  .served li { border-left: 0; padding: 12px 0 0; border-top: 1.5px solid var(--gold-2); }
  .served li:first-child { border-top: 0; padding-top: 0; }
  .principles { grid-template-columns: 1fr; }
  .principle { padding: 32px 24px 28px; }
  .gens { grid-template-columns: 1fr; gap: 36px; }
  .areas { grid-template-columns: 1fr; gap: 0; max-width: 340px; margin-inline: auto; }
  .area, .area:first-child, .area:nth-child(3) { border-left: 0; padding: 16px 0; border-top: 1px solid var(--line); }
  .area:first-child { border-top: 0; }
  .note { font-size: 16.5px; padding: 16px 18px; }
  .contact__list span { width: 84px; }
  .hero { padding: 120px 0 64px; min-height: 0; }
  .hero__seal { max-width: 220px; }
  .hero__actions { flex-direction: column; }
  .brand__sub { display: none; }
  .brand__text { padding-left: 11px; }
  .brand__name { font-size: 14px; }
  .creds { grid-template-columns: 1fr; }
  .engage__links { flex-direction: column; align-items: center; gap: 16px; }
  .engage__links .link-arrow { margin-right: 0; }
  .engage__links .link-arrow + .link-arrow::before { display: none; }
  .ahead__actions { flex-direction: column; gap: 22px; }
  .ahead__actions .btn { margin-right: 0; width: 100%; }
  .ig { border-left: 0; padding-left: 0; }
  .footer__links a { padding: 4px 12px; font-size: 14.5px; }
  .footer__links a:nth-child(4)::before { display: none; }
  .footer__motto { font-size: 17px; gap: 12px; }
  .footer__motto .rule { width: 28px; }
  .footer__seal { width: 88px; height: 88px; }
  .footer__name { font-size: 17px; }
  .footer__bottom { padding-bottom: 84px; }
  .hero__bg::after { background: linear-gradient(180deg, rgba(255,255,255,.55) 0%, rgba(255,255,255,.92) 45%, rgba(255,255,255,.96) 100%); }
  .video__btn { width: 66px; height: 66px; }
  .video__btn svg { width: 26px; height: 26px; }
  .video::before { display: none; }
  .to-top { width: 44px; height: 44px; right: 16px; bottom: 16px; }
}

/* ---------- Phone polish: more breathing room, centered layout ---------- */
@media (max-width: 640px) {
  body, .qhi { line-height: 1.75; }
  .container { width: calc(100% - 48px); }
  .section, .feature { padding: 76px 0; }
  .h2 { font-size: clamp(28px, 7.6vw, 32px); line-height: 1.22; margin-bottom: 20px; }
  .hero__title { line-height: 1.16; margin-bottom: 22px; }
  .head { margin-bottom: 22px; }
  .head--center { margin: 76px 0 32px; }
  p, .lead, .hero__lead, .feature__copy > p { font-size: 16px; line-height: 1.8; }
  .lead, .military__copy > p, .support__copy p, .engage > p { text-align: center; }
  .hero .eyebrow, .feature .eyebrow { font-size: 11px; letter-spacing: .16em; gap: 12px; }
  .hero .eyebrow::before, .hero .eyebrow::after, .feature .eyebrow::before, .feature .eyebrow::after { width: 24px; flex: none; }
  .hero .eyebrow { letter-spacing: .12em; }
  .hero .eyebrow::before, .hero .eyebrow::after { display: none; }
  .hero__lead { margin-bottom: 30px; }
  .hero__actions { gap: 22px; }
  .feature__source { margin-bottom: 22px; }
  .callout { text-align: center; padding: 26px 22px; line-height: 1.5; margin-top: 34px; }
  .principles { gap: 18px; }
  .principle h3 { margin: 16px 0 12px; }
  .principle p, .gen p { line-height: 1.7; }
  .military__copy { margin-top: 8px; }
  .served { gap: 0; margin: 30px 0 34px; }
  .served li { padding: 14px 0; }
  .gens { gap: 52px; }
  .gen { gap: 22px; }
  .gen h3 { margin-bottom: 10px; }
  .note { margin-top: 40px; text-align: center; line-height: 1.6; }
  .areas { max-width: 300px; margin-top: 30px; }
  .area, .area:first-child, .area:nth-child(3) { flex-direction: column; align-items: center; text-align: center; gap: 12px; padding: 22px 0; }
  .support__copy { padding-top: 30px; margin-top: 30px; }
  .support__copy .btn { width: 100%; margin-top: 8px; }
  .founding .lead { margin-bottom: 0; }
  .creds { gap: 12px; margin-top: 32px; }
  .creds li { align-items: center; text-align: center; padding: 18px; gap: 4px; }
  .engage, .ahead { margin-top: 76px; }
  .engage__links { gap: 20px; margin-top: 24px; }
  .ahead__sub { line-height: 1.6; }
  .contact__intro .h2 em { display: block; }
  .contact__list { max-width: none; }
  .contact__list li { flex-direction: column; align-items: center; text-align: center; gap: 4px; padding: 14px 0; }
  .contact__list span { width: auto; }
  .contact__form { margin-top: 12px; }
  .footer__sub { margin-bottom: 4px; }
  .footer__motto { margin-top: 24px; }
  .footer__links { gap: 12px 0; padding: 20px 0; margin-top: 30px; }
  .footer__bottom { gap: 14px; padding-top: 26px; line-height: 1.7; }
}

/* Contact form error message (Astro build) */
.form__err { margin: 16px 0 0; font-size: 14px; color: #9b2c2c; text-align: center; }
.contact__form.is-sending button[type="submit"] { opacity: .6; pointer-events: none; }
