/* ==========================================================================
   LUXE FLUTTER — Design System
   Aesthetic: editorial noir couture. Ink-black ground, warm ivory type,
   brushed-gold hairlines. Reads like a fashion-house lookbook, not a salon
   template. Signature motif: the "flutter rule" — a hairline lash arc used
   as section divider and reveal.

   EDIT SAFELY: nearly everything visual is a variable in :root below.
   ========================================================================== */

/* ---------- 1. Tokens ---------- */
:root {
  /* Brand — black & gold with warm ivory for readability */
  --ink:        #0B0A09;   /* primary black ground */
  --ink-2:      #131110;   /* raised black surface */
  --ink-3:      #1D1A17;   /* hairline / border on dark */
  --ivory:      #F4EFE7;   /* primary light ground + type on dark (17:1) */
  --ivory-dim:  #B9B0A3;   /* secondary type on dark (9:1) */
  --gold:       #C8A96A;   /* accent on DARK only (8.7:1 on ink) */
  --gold-bright:#E8CF9A;   /* highlight, hover */
  --gold-deep:  #7A5C1B;   /* accent text on LIGHT grounds (5.4:1 on ivory) */
  --gold-line:  rgba(200, 169, 106, 0.32);

  /* Type */
  --font-display: "Italiana", "Didot", "Bodoni MT", serif;
  --font-serif:   "Cormorant Garamond", Georgia, serif;
  --font-sans:    "Jost", "Futura", "Century Gothic", sans-serif;

  --step--1: clamp(0.78rem, 0.76rem + 0.10vw, 0.84rem);
  --step-0:  clamp(1.00rem, 0.97rem + 0.16vw, 1.10rem);
  --step-1:  clamp(1.25rem, 1.18rem + 0.35vw, 1.50rem);
  --step-2:  clamp(1.60rem, 1.44rem + 0.80vw, 2.20rem);
  --step-3:  clamp(2.10rem, 1.75rem + 1.75vw, 3.40rem);
  --step-4:  clamp(2.80rem, 2.00rem + 4.00vw, 6.00rem);

  /* Space */
  --gutter: clamp(1.25rem, 5vw, 4rem);
  --band:   clamp(4.5rem, 9vw, 9rem);
  --max:    76rem;
  --max-prose: 40rem;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

/* ---------- 2. Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--ink);
  color: var(--ivory);
  font-family: var(--font-sans);
  font-size: var(--step-0);
  font-weight: 300;
  line-height: 1.7;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg, iframe { max-width: 100%; display: block; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; line-height: 1.08; }
p { margin: 0 0 1.15em; }
ul, ol { margin: 0 0 1.15em; padding-left: 1.15em; }
li { margin-bottom: 0.45em; }
a { color: inherit; }

/* Visible, on-brand focus ring everywhere */
:focus-visible {
  outline: 2px solid var(--gold-bright);
  outline-offset: 3px;
  border-radius: 2px;
}

.skip-link {
  position: absolute; left: 50%; top: 0; transform: translate(-50%, -120%);
  z-index: 200; background: var(--gold); color: var(--ink);
  padding: 0.75rem 1.5rem; font: 500 var(--step--1)/1 var(--font-sans);
  letter-spacing: 0.16em; text-transform: uppercase; text-decoration: none;
  transition: transform 0.2s var(--ease);
}
.skip-link:focus { transform: translate(-50%, 0); }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* ---------- 3. Layout primitives ---------- */
.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.band { padding-block: var(--band); }
.band--tight { padding-block: clamp(3rem, 6vw, 5rem); }
.prose { max-width: var(--max-prose); }

.light { background: var(--ivory); color: var(--ink); }
.light a { color: var(--gold-deep); }
.light .eyebrow { color: var(--gold-deep); }
.light .rule::before { background: rgba(122, 92, 27, 0.45); }
.light .lead { color: #3A342C; }

.split {
  display: grid;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: center;
  grid-template-columns: 1fr;
}
@media (min-width: 62rem) {
  .split { grid-template-columns: 1.05fr 0.95fr; }
  .split--reverse > :first-child { order: 2; }
}

/* ---------- 4. Typography components ---------- */
.eyebrow {
  display: block;
  font: 400 var(--step--1)/1 var(--font-sans);
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.1rem;
}

.display  { font-family: var(--font-display); font-size: var(--step-3); letter-spacing: 0.01em; }
.display--xl { font-size: var(--step-4); line-height: 0.98; }
.h-sect   { font-family: var(--font-display); font-size: var(--step-2); letter-spacing: 0.02em; }
.h-item   { font-family: var(--font-display); font-size: var(--step-1); letter-spacing: 0.03em; }

.lead {
  font-family: var(--font-serif);
  font-size: var(--step-1);
  font-weight: 300;
  font-style: italic;
  line-height: 1.55;
  color: var(--ivory-dim);
}

.rule { position: relative; padding-top: 1.6rem; }
.rule::before {
  content: ""; position: absolute; top: 0; left: 0;
  width: 3.5rem; height: 1px; background: var(--gold);
}

/* Flutter rule — the signature lash-arc divider */
.flutter {
  display: block; width: min(220px, 60%); height: auto; margin: 2.5rem auto;
  color: var(--gold-line);
}
.flutter path { fill: none; stroke: currentColor; stroke-width: 1; }

/* ---------- 5. Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.6rem;
  min-height: 3rem; padding: 0.9rem 2rem;
  font: 400 var(--step--1)/1 var(--font-sans);
  letter-spacing: 0.2em; text-transform: uppercase; text-decoration: none;
  border: 1px solid var(--gold); background: transparent; color: var(--gold);
  cursor: pointer;
  transition: background-color 0.35s var(--ease), color 0.35s var(--ease),
              border-color 0.35s var(--ease), transform 0.35s var(--ease);
}
.btn:hover, .btn:focus-visible { background: var(--gold); color: var(--ink); }
.btn:active { transform: translateY(1px); }

.btn--solid { background: var(--gold); color: var(--ink); }
.btn--solid:hover, .btn--solid:focus-visible { background: var(--gold-bright); border-color: var(--gold-bright); }

.light .btn { border-color: var(--gold-deep); color: var(--gold-deep); }
.light .btn:hover, .light .btn:focus-visible { background: var(--gold-deep); color: var(--ivory); }
.light .btn--solid { background: var(--ink); border-color: var(--ink); color: var(--ivory); }
.light .btn--solid:hover, .light .btn--solid:focus-visible { background: var(--gold-deep); border-color: var(--gold-deep); }

.btn-row { display: flex; flex-wrap: wrap; gap: 1rem; margin-top: 2rem; }

/* Text link with drawn underline */
.link-u {
  text-decoration: none; position: relative; white-space: nowrap;
  border-bottom: 1px solid var(--gold-line); padding-bottom: 2px;
  transition: border-color 0.3s var(--ease);
}
.link-u:hover, .link-u:focus-visible { border-color: currentColor; }

/* ---------- 6. Header / nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(11, 10, 9, 0.72);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: background-color 0.4s var(--ease), border-color 0.4s var(--ease);
}
.site-header.is-stuck { background: rgba(11, 10, 9, 0.96); border-bottom-color: var(--ink-3); }

.nav-bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; min-height: 4.75rem;
}

.brand { display: inline-flex; flex-direction: column; text-decoration: none; line-height: 1; }
.brand__name {
  font-family: var(--font-display); font-size: 1.5rem;
  letter-spacing: 0.22em; color: var(--ivory); text-transform: uppercase;
}
.brand__tag {
  font-size: 0.58rem; letter-spacing: 0.4em; text-transform: uppercase;
  color: var(--gold); margin-top: 0.4rem;
}

.nav-list {
  display: flex; align-items: center; gap: clamp(1.25rem, 2.6vw, 2.5rem);
  list-style: none; margin: 0; padding: 0;
}
.nav-list a {
  text-decoration: none; font-size: var(--step--1);
  letter-spacing: 0.2em; text-transform: uppercase; color: var(--ivory-dim);
  padding-block: 0.5rem;
  transition: color 0.3s var(--ease);
}
.nav-list a:hover, .nav-list a:focus-visible { color: var(--ivory); }
.nav-list a[aria-current="page"] { color: var(--gold); }

.nav-cta { display: inline-flex; }
@media (min-width: 62rem) { .nav-cta__long { display: none; } }

.nav-toggle {
  display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
  width: 44px; height: 44px; padding: 0; margin-right: -8px;
  background: none; border: 0; cursor: pointer;
}
.nav-toggle span { display: block; height: 1px; width: 26px; background: var(--ivory); transition: transform 0.3s var(--ease), opacity 0.3s var(--ease); }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 61.99rem) {
  .nav-panel {
    position: fixed; inset: 4.75rem 0 auto 0;
    background: rgba(11, 10, 9, 0.985);
    border-bottom: 1px solid var(--ink-3);
    padding: 2rem var(--gutter) 2.75rem;
    display: none;
  }
  .nav-panel.is-open { display: block; }
  .nav-list { flex-direction: column; align-items: flex-start; gap: 1.35rem; }
  .nav-list a { font-size: 1.05rem; }
  .nav-panel .btn { margin-top: 1.75rem; width: 100%; }
}
@media (min-width: 62rem) {
  .nav-toggle { display: none; }
  .nav-panel { display: flex !important; align-items: center; gap: 2.25rem; }
}

/* ---------- 7. Hero ---------- */
.hero { position: relative; display: grid; align-items: end; min-height: min(88svh, 900px); overflow: hidden; }
.hero__media { position: absolute; inset: 0; z-index: 0; }
.hero__media img { width: 100%; height: 100%; object-fit: cover; }
.hero__scrim {
  position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(to top, var(--ink) 4%, rgba(11,10,9,0.72) 42%, rgba(11,10,9,0.35) 100%),
    radial-gradient(120% 80% at 15% 85%, rgba(200,169,106,0.10), transparent 60%);
}
.hero__inner { position: relative; z-index: 2; padding-block: clamp(4rem, 12vh, 8rem); }
.hero__title { max-width: 16ch; }
.hero__title em { font-style: normal; color: var(--gold); }
.hero__meta {
  display: flex; flex-wrap: wrap; gap: 0.75rem 2rem; margin-top: 2.5rem;
  font-size: var(--step--1); letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--ivory-dim);
}

/* ---------- 9. Featured services grid ---------- */
.grid-3 { display: grid; gap: clamp(1.5rem, 3vw, 2.5rem); grid-template-columns: 1fr; }
@media (min-width: 46rem) { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 66rem) { .grid-3 { grid-template-columns: repeat(3, 1fr); } }

.card {
  display: flex; flex-direction: column;
  border: 1px solid var(--ink-3); background: var(--ink-2);
  transition: border-color 0.4s var(--ease), transform 0.4s var(--ease);
}
.card:hover { border-color: var(--gold-line); transform: translateY(-4px); }
.card__body { padding: clamp(1.5rem, 3vw, 2.25rem); display: flex; flex-direction: column; flex: 1; }
.card__num {
  font-family: var(--font-serif); font-size: var(--step--1); font-style: italic;
  color: var(--gold); letter-spacing: 0.1em; margin-bottom: 0.9rem;
}
.card__body p { color: var(--ivory-dim); font-size: 0.95rem; }
.card__body .link-u { margin-top: auto; align-self: flex-start; color: var(--gold); font-size: var(--step--1); letter-spacing: 0.2em; text-transform: uppercase; }
.light .card { background: #EFE8DB; border-color: rgba(122,92,27,0.2); }
.light .card__num, .light .card__body .link-u { color: var(--gold-deep); }
.light .card__body p { color: #4A443A; }

/* ---------- 10. Service menu (Services page) ---------- */
.menu-group { border-top: 1px solid var(--ink-3); padding-top: clamp(2rem, 4vw, 3rem); margin-top: clamp(2.5rem, 5vw, 4rem); }
.light .menu-group { border-top-color: rgba(122,92,27,0.25); }
.menu-group__head { margin-bottom: 2.5rem; }

.service {
  display: grid; gap: 0.5rem 2.5rem; padding-block: clamp(1.5rem, 3vw, 2rem);
  border-bottom: 1px solid var(--ink-3);
  grid-template-columns: 1fr;
}
.light .service { border-bottom-color: rgba(122,92,27,0.18); }
@media (min-width: 52rem) {
  /* Only split into two columns once a service carries price/duration meta —
     otherwise the description gets an odd empty gutter. */
  .service:has(.service__meta) { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
}

.service__desc { color: var(--ivory-dim); font-size: 0.96rem; margin: 0.65rem 0 0; }
.light .service__desc { color: #4A443A; }

.service__meta { display: flex; flex-direction: column; gap: 0.35rem; align-content: start; }
.service__meta dl { display: grid; grid-template-columns: auto 1fr; gap: 0.3rem 1rem; margin: 0; font-size: var(--step--1); }
.service__meta dt { letter-spacing: 0.18em; text-transform: uppercase; color: var(--ivory-dim); }
.service__meta dd { margin: 0; color: var(--gold); }
.light .service__meta dt { color: #6B6355; }
.light .service__meta dd { color: var(--gold-deep); }

/* Availability tags — never imply a service is offered unless confirmed */
.tag {
  display: inline-block; font-size: 0.66rem; letter-spacing: 0.22em; text-transform: uppercase;
  padding: 0.3rem 0.7rem; border: 1px solid currentColor; margin-left: 0.75rem;
  vertical-align: middle; white-space: nowrap;
}
.tag--offered { color: var(--gold); }
.tag--confirm { color: var(--ivory-dim); border-style: dashed; }
.light .tag--offered { color: var(--gold-deep); }
.light .tag--confirm { color: #6B6355; }

/* ---------- 11. Info panel / contact details ---------- */
.panel {
  border: 1px solid var(--ink-3); background: var(--ink-2);
  padding: clamp(1.75rem, 4vw, 2.75rem);
}
.light .panel { background: #EFE8DB; border-color: rgba(122,92,27,0.2); }

.detail-list { list-style: none; margin: 0; padding: 0; }
.detail-list li { padding-block: 1.15rem; border-bottom: 1px solid var(--ink-3); margin: 0; }
.detail-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.light .detail-list li { border-bottom-color: rgba(122,92,27,0.18); }
.detail-list dt, .detail-list .label {
  display: block; font-size: var(--step--1); letter-spacing: 0.24em;
  text-transform: uppercase; color: var(--gold); margin-bottom: 0.4rem;
}
.light .detail-list .label { color: var(--gold-deep); }
.detail-list a { text-decoration: none; border-bottom: 1px solid var(--gold-line); }

.ph-note {
  display: inline-block; font-size: var(--step--1); letter-spacing: 0.1em;
  color: var(--ivory-dim); font-style: italic; font-family: var(--font-serif);
}
.light .ph-note { color: #6B6355; }

/* ---------- 12. Forms ---------- */
.form { display: grid; gap: 1.5rem; }
.field { display: grid; gap: 0.55rem; }
.field--half { grid-column: span 1; }
@media (min-width: 46rem) {
  .form--2col { grid-template-columns: repeat(2, 1fr); }
  .form--2col .field--full { grid-column: 1 / -1; }
}

label {
  font-size: var(--step--1); letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--ivory-dim);
}
.light label { color: #4A443A; }
.req { color: var(--gold); }
.light .req { color: var(--gold-deep); }

input, select, textarea {
  width: 100%; padding: 0.95rem 1.1rem;
  font-family: var(--font-sans); font-size: 1rem; font-weight: 300; color: var(--ivory);
  background: var(--ink); border: 1px solid var(--ink-3); border-radius: 0;
  transition: border-color 0.3s var(--ease), background-color 0.3s var(--ease);
}
textarea { min-height: 9rem; resize: vertical; }
input:hover, select:hover, textarea:hover { border-color: var(--gold-line); }
input:focus, select:focus, textarea:focus { border-color: var(--gold); outline-offset: 2px; }
.light input, .light select, .light textarea {
  background: #FBF8F2; border-color: rgba(122,92,27,0.28); color: var(--ink);
}
select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--gold) 50%),
                    linear-gradient(135deg, var(--gold) 50%, transparent 50%);
  background-position: calc(100% - 20px) 50%, calc(100% - 14px) 50%;
  background-size: 6px 6px, 6px 6px; background-repeat: no-repeat;
  padding-right: 3rem;
}

.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: #E0796B; }
.err {
  font-size: var(--step--1); letter-spacing: 0.06em; text-transform: none;
  color: #E0796B; min-height: 0;
}
.light .err { color: #A63A28; }

.consent { display: flex; gap: 0.85rem; align-items: flex-start; }
.consent input { width: 1.15rem; height: 1.15rem; flex: 0 0 auto; margin-top: 0.35rem; accent-color: var(--gold); }
.consent label { text-transform: none; letter-spacing: 0.01em; font-size: 0.92rem; line-height: 1.6; }

/* Honeypot — bots fill it, humans never see it */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-status { padding: 1rem 1.25rem; border: 1px solid; font-size: 0.95rem; }
.form-status[hidden] { display: none !important; }
.form-status.is-ok   { border-color: var(--gold); color: var(--gold); }
.form-status.is-fail { border-color: #E0796B; color: #E0796B; }
.light .form-status.is-ok { border-color: var(--gold-deep); color: var(--gold-deep); }

/* ---------- 13. Booking / CTA band ---------- */
.cta-band { position: relative; text-align: center; background: var(--ink-2); border-block: 1px solid var(--ink-3); }
.cta-band .btn-row { justify-content: center; }

.steps { counter-reset: step; list-style: none; padding: 0; margin: 0; display: grid; gap: 2rem; }
@media (min-width: 52rem) { .steps { grid-template-columns: repeat(3, 1fr); gap: 2.5rem; } }
.steps li { counter-increment: step; padding-top: 1.5rem; border-top: 1px solid var(--gold-line); margin: 0; }
.steps li::before {
  content: "0" counter(step); display: block;
  font-family: var(--font-serif); font-style: italic; font-size: var(--step-1);
  color: var(--gold); margin-bottom: 0.6rem;
}
.light .steps li::before { color: var(--gold-deep); }

.embed-slot {
  display: grid; place-items: center; text-align: center; gap: 1rem;
  min-height: 24rem; padding: 2.5rem;
  border: 1px dashed var(--gold-line); background: var(--ink-2);
}

/* ---------- 14. Legal / long-form ---------- */
.legal { max-width: 46rem; }
.legal h2 { font-family: var(--font-display); font-size: var(--step-2); margin: 3rem 0 1rem; }
.legal h3 { font-family: var(--font-sans); font-weight: 400; font-size: 1.05rem; letter-spacing: 0.14em; text-transform: uppercase; margin: 2.25rem 0 0.75rem; color: var(--gold); }
.light .legal h3 { color: var(--gold-deep); }
.legal p, .legal li { color: var(--ivory-dim); }
.light .legal p, .light .legal li { color: #3A342C; }
.legal .updated { font-family: var(--font-serif); font-style: italic; }

.notice {
  border-left: 2px solid var(--gold); padding: 1.25rem 1.5rem; margin: 2.5rem 0;
  background: rgba(200,169,106,0.05); font-size: 0.95rem;
}
.light .notice { border-left-color: var(--gold-deep); background: rgba(122,92,27,0.06); }

/* ---------- 15. Footer ---------- */
.site-footer { background: var(--ink); border-top: 1px solid var(--ink-3); padding-block: clamp(3.5rem, 7vw, 5.5rem) 2.5rem; }
.footer-grid { display: grid; gap: 2.75rem; grid-template-columns: 1fr; }
@media (min-width: 52rem) { .footer-grid { grid-template-columns: 1.3fr 1fr 1fr; gap: 3.5rem; } }
.footer-grid h2 { font-size: var(--step--1); letter-spacing: 0.24em; text-transform: uppercase; color: var(--gold); margin-bottom: 1.25rem; font-family: var(--font-sans); }
.footer-grid ul { list-style: none; padding: 0; margin: 0; }
.footer-grid li { margin-bottom: 0.7rem; }
.footer-grid a { text-decoration: none; color: var(--ivory-dim); transition: color 0.3s var(--ease); }
.footer-grid a:hover, .footer-grid a:focus-visible { color: var(--ivory); }
.footer-bottom {
  display: flex; flex-wrap: wrap; gap: 0.75rem 2rem; justify-content: space-between;
  margin-top: 3.5rem; padding-top: 1.75rem; border-top: 1px solid var(--ink-3);
  font-size: var(--step--1); color: var(--ivory-dim); letter-spacing: 0.08em;
}

/* ---------- 16. Motion — one orchestrated reveal, nothing frantic ---------- */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.reveal.is-in { opacity: 1; transform: none; }
.reveal[data-delay="1"] { transition-delay: 0.10s; }
.reveal[data-delay="2"] { transition-delay: 0.20s; }
.reveal[data-delay="3"] { transition-delay: 0.30s; }
.reveal[data-delay="4"] { transition-delay: 0.40s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ---------- 17. Print ---------- */
@media print {
  .site-header, .site-footer, .btn-row, .nav-toggle { display: none !important; }
  body { background: #fff; color: #000; }
}

/* ---------- 18. scroll-world engine theme ----------
   The engine hard-codes .sw-root{--sw-ink:#241d2b;--sw-bg:#F5EDE0} — a dark-on-cream
   default — and injects that stylesheet at RUNTIME, so it lands after this file in
   source order. A plain :root block ties on specificity (0,1,0) and therefore loses.
   `html .sw-root` (0,1,1) outranks it, which is what actually makes the dark theme
   stick. Do not "simplify" this back to :root alone: the hero headline renders
   near-black on the bright gold frame and becomes unreadable. */
:root,
html .sw-root {
  --sw-bg:        var(--ink);
  --sw-ink:       var(--ivory);
  --sw-ink-soft:  var(--ivory-dim);
  --sw-accent:    var(--gold);
  --sw-font-display: var(--font-display);
  --sw-font-body:    var(--font-sans);
}

/* The flight sits directly under the sticky header; the concourse starts after it. */
#world { position: relative; z-index: 1; }
/* The engine's topbar is empty when nav+brand are off — don't reserve space for it. */
.sw-topbar:empty { display: none !important; }


/* ---------- 19. Owner portrait ---------- */
.portrait { margin: 0; }
.portrait img {
  display: block; width: 100%; height: auto;
  border: 1px solid var(--ink-3);
  filter: saturate(0.94) contrast(1.02);
}
.light .portrait img { border-color: rgba(122, 92, 27, 0.28); }
.portrait figcaption {
  margin-top: 1rem;
  font-size: var(--step--1); letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--gold);
}
.light .portrait figcaption { color: var(--gold-deep); }

/* ---------- 20. Map ---------- */
.map-frame {
  margin-top: 2.5rem;
  aspect-ratio: 16 / 10;
  border: 1px solid var(--ink-3);
  background: var(--ink-2);
  overflow: hidden;
}
.map-frame iframe {
  width: 100%; height: 100%; border: 0; display: block;
  /* Google's embed is a bright light map; tone it to sit inside the dark section
     without shipping a second map provider. */
  filter: invert(0.91) hue-rotate(180deg) saturate(0.55) brightness(0.96) contrast(1.05);
}
@media (prefers-reduced-motion: reduce) { .map-frame iframe { filter: invert(0.91) hue-rotate(180deg) saturate(0.55); } }

/* ---------- 21. Sub-page hero ----------
   Sub-pages open on a still from the flight, so the whole site reads as one
   world without paying for a second video chain on every route. */
.page-hero {
  position: relative;
  display: grid; align-items: end;
  min-height: min(58svh, 560px);
  overflow: hidden;
  border-bottom: 1px solid var(--ink-3);
}
.page-hero__media { position: absolute; inset: 0; z-index: 0; }
.page-hero__media img { width: 100%; height: 100%; object-fit: cover; }
.page-hero::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(to top, var(--ink) 3%, rgba(11,10,9,0.78) 45%, rgba(11,10,9,0.42) 100%),
    radial-gradient(110% 70% at 12% 90%, rgba(200,169,106,0.12), transparent 62%);
}
.page-hero__inner { position: relative; z-index: 2; padding-block: clamp(3rem, 8vh, 5.5rem); }
.page-hero .display { max-width: 18ch; }
.page-hero .lead { max-width: 46ch; margin-top: 1.5rem; }

/* Breadcrumb */
.crumb {
  display: flex; flex-wrap: wrap; gap: 0.5rem; align-items: center;
  list-style: none; margin: 0 0 1.25rem; padding: 0;
  font-size: var(--step--1); letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--ivory-dim);
}
.crumb li { margin: 0; }
.crumb li + li::before { content: "/"; margin-right: 0.5rem; color: var(--gold-line); }
.crumb a { text-decoration: none; color: var(--ivory-dim); border-bottom: 1px solid transparent; }
.crumb a:hover, .crumb a:focus-visible { color: var(--gold); border-bottom-color: var(--gold-line); }
.crumb [aria-current="page"] { color: var(--gold); }

/* ---------- 22. Teaser cards (homepage -> sub-pages) ---------- */
.teaser {
  display: grid; gap: 0; text-decoration: none;
  border: 1px solid var(--ink-3); background: var(--ink-2);
  transition: border-color 0.4s var(--ease), transform 0.4s var(--ease);
  overflow: hidden;
}
.teaser:hover, .teaser:focus-visible { border-color: var(--gold-line); transform: translateY(-4px); }
.teaser img { width: 100%; height: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.teaser__body { padding: clamp(1.5rem, 3vw, 2.25rem); }
.teaser__body p { color: var(--ivory-dim); font-size: 0.95rem; margin-bottom: 0; }
.teaser__more {
  display: inline-block; margin-top: 1.25rem;
  font-size: var(--step--1); letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold);
}
.teaser:hover .teaser__more { color: var(--gold-bright); }

/* ---------- 23. 404 ---------- */
.error-page { display: grid; place-items: center; min-height: 70svh; text-align: center; }

/* ---------- 24. Tabs ---------- */
.tabs { margin-top: clamp(2rem, 5vw, 3rem); }
.tablist {
  display: flex; flex-wrap: wrap; gap: clamp(1.5rem, 4vw, 3rem);
  border-bottom: 1px solid var(--ink-3);
  margin-bottom: clamp(2.5rem, 5vw, 3.5rem);
}
.light .tablist { border-bottom-color: rgba(122, 92, 27, 0.25); }
.tablist button {
  position: relative;
  appearance: none; background: none; border: 0; cursor: pointer;
  padding: 0 0 1.1rem; margin-bottom: -1px;
  font-family: var(--font-sans); font-size: var(--step--1); font-weight: 400;
  letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--ivory-dim);
  transition: color 0.3s var(--ease);
}
.light .tablist button { color: #6B6355; }
.tablist button::after {
  content: ""; position: absolute; left: 0; bottom: -1px; height: 1px; width: 100%;
  background: var(--gold); transform: scaleX(0); transform-origin: left;
  transition: transform 0.4s var(--ease);
}
.light .tablist button::after { background: var(--gold-deep); }
.tablist button:hover, .tablist button:focus-visible { color: var(--ivory); }
.light .tablist button:hover, .light .tablist button:focus-visible { color: var(--ink); }
.tablist button[aria-selected="true"] { color: var(--gold); }
.light .tablist button[aria-selected="true"] { color: var(--gold-deep); }
.tablist button[aria-selected="true"]::after { transform: scaleX(1); }
.tablist .tab__count {
  display: block; margin-top: 0.4rem;
  font-family: var(--font-serif); font-style: italic; text-transform: none;
  letter-spacing: 0.02em; font-size: 0.8rem; color: var(--ivory-dim);
}
.light .tablist .tab__count { color: #6B6355; }

[role="tabpanel"][hidden] { display: none !important; }
[role="tabpanel"]:focus { outline: none; }

/* ---------- 25. Third-party embed frame ---------- */
.embed-frame {
  border: 1px solid var(--ink-3); background: var(--ink-2);
  padding: clamp(1rem, 2.5vw, 1.75rem);
  min-height: 18rem;
}
.light .embed-frame { background: #EFE8DB; border-color: rgba(122, 92, 27, 0.2); }
.embed-frame .sk-ww-icloud-calendar { min-height: 16rem; }

/* ---------- 26. Model call criteria ---------- */
.criteria { display: grid; gap: clamp(1.5rem, 3vw, 2.5rem); grid-template-columns: 1fr; }
@media (min-width: 52rem) { .criteria { grid-template-columns: repeat(2, 1fr); } }
.criteria__col h3 {
  font-size: var(--step--1); letter-spacing: 0.24em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 1.25rem; font-family: var(--font-sans); font-weight: 400;
}
.light .criteria__col h3 { color: var(--gold-deep); }
.criteria__col ul { list-style: none; padding: 0; margin: 0; }
.criteria__col li { position: relative; padding-left: 1.5rem; margin-bottom: 0.9rem; }
.criteria__col li::before {
  content: ""; position: absolute; left: 0; top: 0.65em;
  width: 6px; height: 1px; background: var(--gold);
}
.light .criteria__col li::before { background: var(--gold-deep); }

/* ---------- 27. scroll-world engine component overrides ----------
   The engine ships a LIGHT default theme (cream chips, white route pills). Re-pointing
   its tokens (section 18) fixes text colour but not these baked-in backgrounds, which
   then render ivory-on-white. Verified in-browser: the route pill measured ~1.05:1
   before this block. Specificity must beat the engine's runtime-injected sheet. */

/* Route rail — dark pill, gold hairline, ivory label. */
html .sw-root .sw-route span {
  background: rgba(11, 10, 9, 0.82) !important;
  border-color: var(--gold-line) !important;
  color: var(--ivory) !important;
  backdrop-filter: blur(6px);
}

/* Copy tags — hairline chips, not cream lozenges. */
html .sw-root .sw-copy__tags li {
  background: rgba(11, 10, 9, 0.55) !important;
  border-color: var(--gold-line) !important;
  color: var(--gold-bright) !important;
}

/* Keep the scroll hint quiet but legible over bright frames. */
html .sw-root .sw-hint { text-shadow: 0 1px 12px rgba(11, 10, 9, 0.9); }

/* The copy sits over video, so give it a soft ground on the brightest scenes. */
html .sw-root .sw-copy__title,
html .sw-root .sw-copy__body { text-shadow: 0 2px 18px rgba(11, 10, 9, 0.55); }

/* ---------- 28. Engine CTA buttons ----------
   The engine's own .sw-btn--primary resolved to background AND color both
   rgb(244,239,231) once its tokens were re-pointed — an invisible white-on-white
   button at the end of the flight (measured 1:1). These are explicit so the CTA
   can never inherit its way back into being unreadable. */
html .sw-root .sw-btn--primary {
  background: var(--gold) !important;
  border-color: var(--gold) !important;
  color: var(--ink) !important;
}
html .sw-root .sw-btn--primary:hover,
html .sw-root .sw-btn--primary:focus-visible {
  background: var(--gold-bright) !important;
  border-color: var(--gold-bright) !important;
  color: var(--ink) !important;
}
html .sw-root .sw-btn--ghost {
  color: var(--ivory) !important;
  border-color: var(--gold-line) !important;
  background: rgba(11, 10, 9, 0.45) !important;
}
html .sw-root .sw-btn--ghost:hover,
html .sw-root .sw-btn--ghost:focus-visible {
  background: rgba(11, 10, 9, 0.75) !important;
  border-color: var(--gold) !important;
  color: var(--gold-bright) !important;
}

/* ---------- 29. Light-section controls: readability over ratio ----------
   Gold-deep (#7A5C1B) on ivory measures 5.4:1 and passes WCAG AA, but the buttons
   are thin, wide-letterspaced uppercase — and the contrast formula takes no account
   of stroke weight. On screen they read as pale, washed-out text. Ink on ivory is
   17:1 and the gold survives as the border and hover fill, so the brand is intact
   and the label is unambiguous. */
.light .btn {
  color: var(--ink);
  border-color: var(--gold-deep);
}
.light .btn:hover,
.light .btn:focus-visible {
  background: var(--gold-deep);
  border-color: var(--gold-deep);
  color: var(--ivory);
}

/* Tabs sit on the same ivory ground and had the same problem. */
.light .tablist button,
.tablist button {
  color: #4A443A;
}
.tablist button[aria-selected="true"] {
  color: var(--ink);
  font-weight: 500;
}
.light .tablist button:hover,
.light .tablist button:focus-visible {
  color: var(--ink);
}
.tablist .tab__count { color: #6B6355; }

/* The gold underline still marks the active tab, so colour is not the only cue. */
.light .tablist button[aria-selected="true"]::after { background: var(--gold-deep); }

/* ---------- 30. Tab labels on ivory (specificity fix) ----------
   Section 24 sets `.light .tablist button[aria-selected="true"] { color: gold-deep }`
   at (0,3,0). The section-29 rule was (0,2,0) and lost, so the active tab stayed pale
   gold on cream. Matching that specificity and coming later in the file wins cleanly —
   no !important needed. */
.light .tablist button[aria-selected="true"] { color: var(--ink); }
.light .tablist button { color: #4A443A; }
.light .tablist .tab__count { color: #5A5348; }
.light .tablist button[aria-selected="true"] .tab__count { color: var(--gold-deep); }
