/* Direction H: Portal. Black room, warm gold rim, a galaxy behind the window. */
:root {
  --bg: #050507;
  --fg: #f4efe6;
  --muted: #b3aca2;
  --line: rgba(244, 239, 230, 0.13);
  --accent: #d9a35b;
  --font-display: 'Instrument Serif', Georgia, serif;
  --font-body: 'Geist', system-ui, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, monospace;
  --pad: clamp(20px, 4.5vw, 64px);
}

body { background: var(--bg); }
.bg-canvas { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; opacity: 0; transition: opacity 1.4s ease; }
.bg-canvas.is-ready { opacity: 1; }
.no-3d body { background: radial-gradient(ellipse 50% 60% at 72% 45%, #3a2d6b, #050507 70%); }

.nav { background: linear-gradient(to bottom, rgba(5, 5, 7, 0.7), transparent); }
.nav__brand { font-family: var(--font-body); font-size: 16px; font-weight: 600; letter-spacing: -0.01em; text-transform: none; }
.nav__links a { font-family: var(--font-body); font-size: 14px; letter-spacing: 0; text-transform: none; }
.nav__cta { min-height: 38px; padding: 0 16px; border-radius: 10px; border: 1px solid rgba(217, 163, 91, 0.6); color: var(--fg); opacity: 1 !important; }
.nav__toggle { font-family: var(--font-body); letter-spacing: 0; text-transform: none; font-size: 14px; }

.main { position: relative; z-index: 1; }
.kicker { font: 500 11px/1 var(--font-mono); letter-spacing: 0.14em; text-transform: uppercase; color: var(--accent); }
.serif { font-family: var(--font-display); font-weight: 400; font-size: clamp(40px, 4.8vw, 72px); line-height: 1.02; }
.serif em, .hero__title em, .contact__title em { font-style: italic; color: #f1d3a6; }

/* ---------- Dive (hero) ---------- */
.dive { position: relative; height: 260vh; }
.dive__sticky { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; display: flex; align-items: center; padding: 0 var(--pad); }
.hero { --out: 0; position: relative; display: flex; flex-direction: column; gap: 24px; max-width: 520px; opacity: calc(1 - var(--out)); transform: translateX(calc(var(--out) * -60px)); }
.badge { display: inline-flex; align-items: center; gap: 10px; font-size: 13px; color: var(--muted); }
.badge__dots { display: inline-flex; }
.badge__dots i { width: 16px; height: 16px; border-radius: 50%; margin-left: -5px; border: 2px solid var(--bg); background: linear-gradient(135deg, #8f7bff, #5a3fd0); }
.badge__dots i:first-child { margin-left: 0; background: linear-gradient(135deg, #f1d3a6, #d9a35b); }
.badge__dots i:last-child { background: linear-gradient(135deg, #8fd0ff, #3a6bd0); }
.hero__title { font-family: var(--font-display); font-weight: 400; font-size: clamp(46px, 5.4vw, 84px); line-height: 1; letter-spacing: -0.005em; }
.hero__lede { color: var(--muted); font-size: 16px; max-width: 40ch; }
.cta { display: inline-flex; align-items: center; gap: 12px; align-self: flex-start; min-height: 50px; padding: 0 20px 0 8px; border-radius: 12px; background: rgba(244, 239, 230, 0.06); border: 1px solid var(--line); text-decoration: none; font: 500 12px/1 var(--font-mono); letter-spacing: 0.12em; text-transform: uppercase; transition: border-color .2s, background .2s; }
.cta:hover { border-color: var(--accent); background: rgba(217, 163, 91, 0.1); }
.cta__icon { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9px; background: rgba(244, 239, 230, 0.08); color: var(--accent); }
.steps { display: grid; grid-template-columns: repeat(4, 72px); gap: 10px; margin-top: 10px; }
.steps li { display: flex; flex-direction: column; gap: 6px; }
.steps svg { width: 72px; height: 64px; padding: 14px 24px 26px; border-radius: 12px; background: rgba(244, 239, 230, 0.05); border: 1px solid var(--line); fill: none; stroke: var(--fg); stroke-width: 1.3; stroke-linejoin: round; stroke-linecap: round; }
.steps b { margin-top: -30px; padding-left: 10px; font-size: 12px; font-weight: 500; }
.steps span { margin-top: 12px; font: 500 10px/1 var(--font-mono); color: var(--muted); border-top: 1px solid var(--line); padding-top: 6px; width: 24px; }
.dive__hint { position: absolute; left: 50%; bottom: 72px; transform: translateX(-50%); font: 500 11px/1 var(--font-mono); letter-spacing: 0.3em; text-transform: uppercase; color: var(--muted); opacity: calc(1 - var(--out, 0)); }
@media (max-width: 760px) {
  .dive { height: 220vh; }
  .dive__sticky { align-items: flex-start; padding-top: 92px; }
  .hero { gap: 16px; }
  .hero__title { font-size: 40px; }
  .hero__lede { font-size: 15px; }
  .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .steps svg { width: 100%; }
  .dive__hint { display: none; }
}
.reduced .dive, .no-3d .dive { height: auto; min-height: 100vh; }
.reduced .dive__sticky, .no-3d .dive__sticky { position: relative; min-height: 100vh; }

/* ---------- Sections over the galaxy ---------- */
.sec { min-height: 100vh; display: flex; flex-direction: column; justify-content: center; gap: 40px; padding: 120px var(--pad); max-width: 1240px; margin: 0 auto; }
.sec__head { display: flex; flex-direction: column; gap: 16px; text-shadow: 0 2px 30px rgba(5, 5, 7, 0.9); }
.panels { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.panel { display: flex; flex-direction: column; gap: 12px; padding: 26px; min-height: 240px; border-radius: 18px; background: rgba(10, 9, 14, 0.58); border: 1px solid rgba(217, 163, 91, 0.22); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); }
.panel h3 { margin-top: auto; font-family: var(--font-display); font-weight: 400; font-size: 34px; line-height: 1; }
.panel p { color: var(--muted); font-size: 15px; }
.sec__more { color: var(--muted); font-size: 14px; }
.sec--about { align-items: flex-end; }
.about { max-width: 560px; min-height: 0; gap: 18px; }
.about h2 { margin: 0; }
.about__list { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.about__list li { display: flex; flex-direction: column; gap: 2px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; color: var(--muted); }
.about__list b { color: var(--fg); font-weight: 600; }
.sec--contact { align-items: center; text-align: center; }
.contact__title { font-family: var(--font-display); font-weight: 400; font-size: clamp(56px, 9vw, 150px); line-height: 0.95; text-shadow: 0 2px 40px rgba(5, 5, 7, 0.9); }
.contact__row { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 16px 32px; }
.contact__row .cta { align-self: auto; }
.link { text-decoration: none; padding: 12px 0; border-bottom: 1px solid var(--line); }
.link:hover { border-color: var(--accent); }
.footer { position: relative; z-index: 1; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 24px var(--pad) 84px; border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; background: rgba(5, 5, 7, 0.6); }
@media (max-width: 860px) { .panels { grid-template-columns: 1fr; } .panel { min-height: 0; } .sec--about { align-items: stretch; } }
