/* Royal Freedom — shared styles. Palette follows the logo: black, white and silver, with a warm gold accent. */
:root {
  --navy: #0d0d0f;
  --navy-2: #34343a;
  --ink: #1c1c20;
  --muted: #4a5568;
  --line: #e4ded2;
  --bg: #f8f6f1;
  --card: #ffffff;
  --gold: #d4a24c;
  --gold-deep: #8a5d14;      /* gold dark enough for text on light backgrounds (AA) */
  --cool: #dfe7f1;
  --warm: #fbf1df;
  --radius: 18px;
  --shadow: 0 1px 2px rgba(15, 31, 58, .06), 0 12px 32px -12px rgba(15, 31, 58, .18);
  --shadow-lg: 0 2px 4px rgba(15, 31, 58, .06), 0 30px 60px -20px rgba(15, 31, 58, .35);
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --wrap: 1180px;
  --header-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 400 1.0625rem/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy-2); }
h1, h2, h3 { font-family: var(--serif); color: var(--navy); line-height: 1.08; margin: 0 0 .5em; font-weight: 600; letter-spacing: 0; }
h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.7rem); }
h3 { font-size: 1.45rem; }
p { margin: 0 0 1em; }
.wrap { width: min(var(--wrap), 100% - 32px); margin-inline: auto; }
.eyebrow { display: inline-block; font: 600 .78rem/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-deep); margin-bottom: 14px; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 62ch; }
.center { text-align: center; }
.center .lead { margin-inline: auto; }
.section { padding: clamp(64px, 9vw, 120px) 0; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 8px; }
.skip-link:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 6px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; gap: .5em; justify-content: center;
  padding: 14px 26px; border-radius: 999px; border: 0; cursor: pointer;
  font: 600 1rem/1.2 var(--sans); text-decoration: none;
  background: var(--gold); color: var(--navy);
  box-shadow: 0 8px 22px -10px rgba(138, 93, 20, .8), inset 0 -2px 0 rgba(0,0,0,.12);
  transition: transform .2s ease, box-shadow .2s ease, background .2s;
}
.btn:hover { transform: translateY(-2px); background: #dfb05c; box-shadow: 0 14px 28px -12px rgba(138, 93, 20, .9), inset 0 -2px 0 rgba(0,0,0,.12); }
.btn-ghost { background: transparent; color: var(--navy); box-shadow: inset 0 0 0 2px var(--navy); }
.btn-ghost:hover { background: var(--navy); color: #fff; box-shadow: none; }
.btn-lg { padding: 18px 34px; font-size: 1.08rem; }
.btn .arrow { transition: transform .2s; }
.btn:hover .arrow { transform: translateX(3px); }

.logo { display: inline-flex; align-items: center; }
.site-header .logo img { height: 44px; width: auto; }
.logo--full img { width: 240px; height: auto; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--header-h);
  background: #000; border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.site-header .wrap { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.nav { display: flex; align-items: center; gap: 30px; }
.nav ul { list-style: none; display: flex; gap: 28px; margin: 0; padding: 0; }
.nav a:not(.btn) { color: #ececef; text-decoration: none; font-weight: 500; padding: 6px 0; position: relative; }
.nav a:not(.btn)::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--gold); transform: scaleX(0); transition: transform .25s; transform-origin: left; }
.nav a:not(.btn):hover::after, .nav a[aria-current="page"]::after { transform: scaleX(1); }
.nav .btn { padding: 11px 20px; }
.menu-toggle { display: none; background: none; border: 0; padding: 10px; cursor: pointer; color: #fff; }
.menu-toggle svg { width: 28px; height: 28px; }

@media (max-width: 860px) {
  .menu-toggle { display: inline-flex; }
  .nav {
    position: fixed; inset: var(--header-h) 0 auto 0; flex-direction: column; align-items: stretch; gap: 10px;
    padding: 20px 16px 28px; background: #000; border-bottom: 1px solid rgba(255,255,255,.12); box-shadow: var(--shadow-lg);
    display: none;
  }
  .nav.open { display: flex; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav ul a { display: block; padding: 14px 4px; font-size: 1.1rem; border-bottom: 1px solid rgba(255,255,255,.12); }
  .nav ul a::after { display: none; }
  .nav .btn { margin-top: 10px; padding: 15px; }
}

/* Footer */
.site-footer { background: #000; color: #d6deea; padding: 64px 0 28px; margin-top: 0; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 40px; }
.site-footer h2 { color: #fff; font: 600 .8rem/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; margin-bottom: 16px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.footer-note { font-size: .88rem; color: #aab6c8; max-width: 46ch; margin-top: 18px; }
.footer-bottom { margin-top: 48px; padding-top: 22px; border-top: 1px solid rgba(255,255,255,.12); font-size: .88rem; color: #aab6c8; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; }
@media (max-width: 760px) { .footer-grid { grid-template-columns: 1fr; gap: 32px; } }

/* Reveal-on-scroll: content is visible by default; JS only adds motion when it runs */
/* Text remains visible if the animation engine fails. */

/* ---------- HOME: journey ---------- */
.journey { position: relative; }
.stage { position: relative; }
.scene { position: relative; overflow: hidden; }
.scene-img { position: absolute; inset: 0; }
.scene-img img { width: 100%; height: 100%; object-fit: cover; object-position: 70% center; }
.scene-shade { position: absolute; inset: 0; }
.scene--cool { background: #1a2638; }
.scene--cool .scene-shade { background: linear-gradient(90deg, rgba(14,24,42,.93) 0%, rgba(14,24,42,.84) 50%, rgba(14,24,42,.3) 78%, rgba(14,24,42,.1) 100%); }
.scene--warm { background: var(--warm); }
.scene--warm .scene-shade { background: linear-gradient(90deg, rgba(251,241,223,.97) 0%, rgba(251,241,223,.92) 50%, rgba(251,241,223,.3) 78%, rgba(251,241,223,0) 100%); }
.scene-copy { position: relative; z-index: 2; padding: 120px 0 90px; }
.scene-copy .inner { max-width: 560px; }
.scene--cool h1, .scene--cool p, .scene--cool li { color: #eef2f8; }
.scene--cool .eyebrow { color: var(--gold); }
.scene--cool .lead { color: #c9d3e1; }
.scene--warm .lead { color: #4a3b26; }
.ticklist { list-style: none; padding: 0; margin: 22px 0 30px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 22px; }
.ticklist li { position: relative; padding-left: 26px; font-size: .98rem; line-height: 1.45; }
.ticklist li::before { content: ""; position: absolute; left: 0; top: .42em; width: 12px; height: 12px; border-radius: 4px; transform: rotate(45deg); }
.scene--cool .ticklist li::before { background: #7f93b2; }
.scene--warm .ticklist li::before { background: var(--gold); }
.fineprint { font-size: .82rem; opacity: .85; margin-top: 18px; max-width: 52ch; }
.scene--cool .fineprint { color: #aebbd0; }

/* Floating 3D chips */
.chips { position: absolute; inset: 0; z-index: 1; pointer-events: none; perspective: 900px; }
.chip {
  position: absolute; padding: 12px 18px; border-radius: 14px; font: 600 .92rem/1.2 var(--sans);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  box-shadow: var(--shadow-lg); transform-style: preserve-3d; white-space: nowrap;
  animation: float 7s ease-in-out infinite;
}
.chip i { font-style: normal; margin-right: 8px; }
.chip--cool { background: rgba(30, 44, 70, .62); color: #dfe7f3; border: 1px solid rgba(255,255,255,.14); }
.chip--warm { background: rgba(255, 250, 240, .82); color: var(--navy); border: 1px solid rgba(212,162,76,.45); }
.chip:nth-child(2n) { animation-delay: -2.5s; animation-duration: 8s; }
.chip:nth-child(3n) { animation-delay: -4s; animation-duration: 9s; }
@keyframes float { 0%,100% { transform: translate3d(0,0,0) rotateX(8deg) rotateY(-10deg); } 50% { transform: translate3d(0,-14px,40px) rotateX(-4deg) rotateY(6deg); } }
.c1 { right: 5%; top: 17%; } .c2 { right: 27%; bottom: 13%; } .c3 { right: 4%; bottom: 30%; }
@media (max-width: 1199px) { .chips { display: none; } }

/* Pinned mode (desktop + motion allowed + GSAP loaded): scenes stack inside a sticky stage */
.js-journey .journey { height: 260vh; }
.js-journey .stage { position: sticky; top: 0; height: 100vh; overflow: hidden; }
.js-journey .scene { position: absolute; inset: 0; display: flex; align-items: center; }
.js-journey .scene-copy { padding: calc(var(--header-h) + 10px) 0 40px; width: 100%; }
.js-journey .scene--warm { background: transparent; }
.js-journey .scene-copy h1, .js-journey .scene-copy h2 { font-size: clamp(2.1rem, min(4vw, 6.2vh), 3.6rem); }
.js-journey .scene-copy .lead { font-size: clamp(.95rem, 2.1vh, 1.08rem); margin-bottom: 0; }
.js-journey .ticklist { margin: clamp(10px, 2vh, 20px) 0 clamp(14px, 2.6vh, 26px); gap: 6px 22px; }
.js-journey .ticklist li { font-size: clamp(.88rem, 1.9vh, .98rem); }
.js-journey .fineprint { margin-top: 10px; }
.js-journey .scene-img img, .js-journey .scene-img, .js-journey .scene-shade, .js-journey .scene-copy { will-change: opacity, transform; }
.journey-progress { display: none; }
.js-journey .journey-progress {
  display: block; position: absolute; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 3;
  width: 160px; height: 4px; border-radius: 4px; background: rgba(255,255,255,.25); overflow: hidden;
}
.journey-progress span { display: block; height: 100%; width: 100%; background: var(--gold); transform-origin: left; transform: scaleX(0); }

/* Stacked fallback (mobile / reduced motion / no JS) */
@media (max-width: 899px) {
  .scene { display: flex; flex-direction: column; }
  .scene-img { position: relative; height: 56vw; min-height: 240px; order: -1; }
  .scene-shade { display: none; }
  .scene-copy { padding: 36px 0 56px; }
  .ticklist { grid-template-columns: 1fr; }
}

/* Phones: the warm photo starts as the evening photo and brightens as it scrolls into view */
.scene-prev { display: none; }
@media (max-width: 899px) {
  .js-motion .scene-prev { display: block; position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 70% center; }
  :root { --header-h: 64px; }
  .site-header .logo img { height: 46px; }
  .eyebrow { font-size: .82rem; }
  .side-label { font-size: .78rem; }
  .btn-lg { width: 100%; }
  .cta-band { border-radius: 20px; }
}

/* Eligibility */
.issues { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; margin-top: 44px; perspective: 1200px; }
.issue {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 22px;
  box-shadow: var(--shadow); transform-style: preserve-3d; transition: transform .25s ease, box-shadow .25s ease;
}
.issue:hover { box-shadow: var(--shadow-lg); }
.issue .ic { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; margin-bottom: 14px; background: linear-gradient(145deg, #fff4df, #f3dcae); color: var(--gold-deep); transform: translateZ(30px); }
.issue .ic svg { width: 22px; height: 22px; }
.issue h3 { font-size: 1.3rem; margin-bottom: 6px; }
.issue p { font-size: .93rem; color: var(--muted); margin: 0; }
.notice { margin: 36px auto 0; max-width: 760px; padding: 18px 22px; border-left: 4px solid var(--gold); background: #fff; border-radius: 0 12px 12px 0; color: var(--muted); font-size: .95rem; }

/* CTA band */
.cta-band { position: relative; overflow: hidden; background: radial-gradient(1200px 400px at 80% -10%, #3a3a42 0%, transparent 60%), var(--navy); color: #e6ecf5; text-align: center; border-radius: 28px; padding: clamp(48px, 7vw, 84px) 24px; }
.cta-band h2 { color: #fff; }
.cta-band p { color: #c9d3e1; max-width: 58ch; margin: 0 auto 28px; }
.cta-wrap { padding: 0 0 clamp(64px, 9vw, 110px); }

/* Page hero (inner pages) */
.page-hero { padding: clamp(56px, 8vw, 100px) 0 clamp(36px, 5vw, 56px); background: radial-gradient(900px 300px at 85% 0%, rgba(212,162,76,.18), transparent 70%); }

/* ---------- PROGRAMS ---------- */
.program { padding: clamp(48px, 7vw, 88px) 0; border-top: 1px solid var(--line); }
.program-head { max-width: 760px; margin-bottom: 32px; }
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; align-items: stretch; }
.side { border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow); }
.side h3 { display: flex; align-items: center; gap: 10px; }
.side-label { font: 700 .72rem/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; display: block; margin-bottom: 10px; }
.side--challenge { background: linear-gradient(160deg, #eef2f7, #e2e8f0); border: 1px solid #d5dde8; }
.side--challenge .side-label { color: #44546d; }
.side--path { background: linear-gradient(160deg, #fffaf0, #fbefd7); border: 1px solid #efdcb5; }
.side--path .side-label { color: var(--gold-deep); }
.side h4 { font: 600 .98rem/1.3 var(--sans); color: var(--navy); margin: 18px 0 6px; }
.side ul { margin: 0; padding-left: 20px; }
.side li { margin-bottom: 6px; }
.featured { background: var(--navy); color: #dde5f0; border-radius: 28px; padding: clamp(16px, 4vw, 52px); margin-top: 8px; }
.featured h2, .featured .program-head p { color: #fff; }
.featured .program-head .lead { color: #c9d3e1; }
.featured .eyebrow { color: var(--gold); }
.featured .side { color: var(--ink); }
.solar-media { display: grid; grid-template-columns: 1.1fr 1fr; gap: 36px; align-items: center; margin-bottom: 36px; }
.solar-media img { border-radius: 20px; box-shadow: var(--shadow-lg); width: 100%; aspect-ratio: 4/3; object-fit: cover; transform: perspective(1200px) rotateY(-6deg); transition: transform .5s ease; }
.solar-media img:hover { transform: perspective(1200px) rotateY(0); }
.callout { margin-top: 22px; padding: 16px 18px; border-radius: 12px; background: rgba(255,255,255,.65); border: 1px dashed #c9a96a; font-size: .93rem; }
.featured .callout { background: rgba(255,255,255,.06); border-color: rgba(212,162,76,.6); color: #dde5f0; }
@media (max-width: 860px) {
  .compare, .solar-media { grid-template-columns: 1fr; }
  .solar-media img { transform: none; }
  .side { padding: 24px 20px; }
}

/* Process */
.steps { position: relative; margin-top: 52px; }
.steps-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.steps::before { content: ""; position: absolute; left: 6%; right: 6%; top: 32px; height: 3px; background: var(--line); }
.steps-line { position: absolute; left: 6%; right: 6%; top: 32px; height: 3px; background: linear-gradient(90deg, var(--gold), #e9c27e); transform-origin: left; }
.js-motion .steps-line { transform: scaleX(0); }
.step { position: relative; text-align: center; padding: 0 6px; }
.step-num { width: 64px; height: 64px; margin: 0 auto 18px; border-radius: 50%; display: grid; place-items: center; font: 700 1.3rem/1 var(--serif); color: var(--navy); background: #fff; border: 3px solid var(--gold); box-shadow: var(--shadow); position: relative; z-index: 1; }
.step h3 { font-size: 1.35rem; }
.step p { font-size: .95rem; color: var(--muted); }
@media (max-width: 860px) {
  .steps-list { grid-template-columns: 1fr; gap: 26px; }
  .steps::before, .steps-line { left: 31px; right: auto; top: 0; bottom: 0; width: 3px; height: auto; }
  .steps-line { transform-origin: top; }
  .js-motion .steps-line { transform: scaleY(0); }
  .step { display: grid; grid-template-columns: 64px 1fr; gap: 0 18px; text-align: left; }
  .step-num { margin: 0; grid-row: span 2; }
}

/* ---------- REVIEWS ---------- */
.reviews { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 22px; margin-top: 40px; }
.review { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 14px; }
.review-top { display: flex; align-items: center; gap: 14px; }
.review-name { font-weight: 600; color: var(--navy); }
.review-stars { color: var(--gold-deep); letter-spacing: 2px; }
.review blockquote { margin: 0; color: var(--ink); }
.empty-state { margin: 40px auto 0; max-width: 620px; text-align: center; padding: 40px 28px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; box-shadow: var(--shadow); }

/* ---------- EMBEDS ---------- */
.embed-card { background: #fff; border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow-lg); padding: clamp(8px, 2vw, 24px); }
.embed-card iframe { display: block; width: 100%; border: 0; min-height: 520px; }
.embed-note { font-size: .88rem; color: var(--muted); margin-top: 14px; text-align: center; }
.trust-row { display: flex; flex-wrap: wrap; gap: 10px 22px; margin-top: 22px; color: var(--muted); font-size: .95rem; }
.trust-row span::before { content: "✓"; color: var(--gold-deep); font-weight: 700; margin-right: 8px; }

/* Thank-you loader */
.prep { display: none; }
.js-motion .prep { display: grid; place-items: center; text-align: center; padding: 56px 0 24px; }
.prep-ring { width: 54px; height: 54px; border-radius: 50%; border: 4px solid #eadcc0; border-top-color: var(--gold-deep); animation: spin 1s linear infinite; margin-bottom: 16px; }
@keyframes spin { to { transform: rotate(360deg); } }
.booking-ready .prep { display: none; }
.booking { transition: opacity .6s ease, transform .6s ease; }
.js-motion:not(.booking-ready) .booking { opacity: 1; }

/* ---------- LEGAL ---------- */
.legal { max-width: 820px; }
.legal h2 { font-size: 1.5rem; margin-top: 2em; }
.legal h3 { font-size: 1.1rem; margin-top: 1.4em; font-family: var(--sans); }
.legal li { margin-bottom: 6px; }

/* Reduced motion: kill decorative motion everywhere */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .js-motion [data-reveal] { opacity: 1; transform: none; }
}
