/* =========================================================================
   AstroOracle — design system
   Primitives: .device (bezel) · .screen (borderless shot) · .pill · hairlines
   Rhythm: one accent per section, dark bands for contrast, lines not boxes
   ========================================================================= */

:root {
  /* colour */
  --page: #fbf6ec;
  --paper: #fffdf8;
  --ink: #1b140c;
  --body: #6a5f53;
  --muted: #988b7c;
  --hair: #ece0cd;
  --hair-soft: #f4ebdc;
  --accent: #e07a0c;
  --accent-deep: #c2660a;
  --accent-soft: #fff0d4;
  --night: #15100a;
  --night-text: #f3e7d5;
  --night-dim: #b4a695;

  /* type */
  --display: Fraunces, Georgia, 'Times New Roman', serif;
  --ui: Inter, 'Segoe UI', system-ui, -apple-system, sans-serif;

  /* space */
  --s-1: 4px; --s-2: 8px; --s-3: 12px; --s-4: 16px; --s-5: 24px;
  --s-6: 32px; --s-7: 48px; --s-8: 72px; --s-9: 96px;

  /* shape */
  --r-1: 12px; --r-2: 20px; --r-3: 32px; --r-pill: 999px;
  --shadow-1: 0 1px 2px rgba(60, 42, 16, 0.05), 0 10px 26px -16px rgba(60, 42, 16, 0.30);
  --shadow-2: 0 2px 4px rgba(60, 42, 16, 0.06), 0 26px 50px -24px rgba(60, 42, 16, 0.38);
  --shadow-device: 0 50px 90px -40px rgba(38, 25, 6, 0.65);

  --container: 1140px;
  --narrow: 720px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: var(--ui);
  font-size: 16.5px;
  line-height: 1.55;
  letter-spacing: -0.003em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ---------- type ---------- */

h1, h2, h3, .display { font-family: var(--display); font-weight: 700; color: var(--ink); margin: 0; line-height: 1.06; letter-spacing: -0.025em; }
h1 { font-size: clamp(2.35rem, 4.4vw, 3.5rem); }
h2 { font-size: clamp(1.85rem, 3.2vw, 2.6rem); }
h3 { font-size: 1.08rem; line-height: 1.25; letter-spacing: -0.015em; }
p { margin: 0; color: var(--body); }
.lede { font-size: 1.06rem; line-height: 1.6; max-width: 46ch; }
.small { font-size: 0.9rem; }
.tiny { font-size: 0.82rem; color: var(--muted); }
.eyebrow {
  display: block; font-family: var(--ui); font-size: 0.68rem; font-weight: 600; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--accent); margin: 0 0 var(--s-4);
}
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-deep); }
img { max-width: 100%; height: auto; display: block; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }

/* ---------- layout ---------- */

.wrap { width: min(100% - 40px, var(--container)); margin-inline: auto; position: relative; z-index: 1; }
.wrap--narrow { max-width: var(--narrow); }
section { position: relative; scroll-margin-top: 84px; }   /* anchors clear the sticky nav */
.pad { padding: var(--s-8) 0; }
.pad-sm { padding: var(--s-7) 0; }
.center { text-align: center; }

/* ---------- actions ---------- */

.pill {
  display: inline-flex; align-items: center; gap: 8px; padding: 13px 26px;
  border-radius: var(--r-pill); font-family: var(--ui); font-size: 0.95rem; font-weight: 600;
  background: var(--ink); color: var(--page); border: 1px solid var(--ink);
  transition: transform 0.16s ease, box-shadow 0.16s ease, background 0.16s ease;
}
.pill:hover { color: var(--page); transform: translateY(-1px); box-shadow: var(--shadow-1); }
.pill--accent { background: var(--accent); border-color: var(--accent); color: #fff; }
.pill--accent:hover { background: var(--accent-deep); border-color: var(--accent-deep); color: #fff; }
.pill--quiet { background: transparent; color: var(--ink); border-color: var(--hair); }
.pill--quiet:hover { background: var(--paper); color: var(--ink); border-color: var(--ink); }
.pill--light { background: var(--paper); border-color: var(--paper); color: var(--ink); }
.pill--light:hover { color: var(--ink); }
.pill--sm { padding: 9px 18px; font-size: 0.88rem; }
.pill svg { width: 15px; height: 15px; stroke: currentColor; fill: none; stroke-width: 2; }

.textlink { font-weight: 600; font-size: 0.95rem; display: inline-flex; align-items: center; gap: 7px; }
.textlink svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 2; transition: transform 0.16s ease; }
.textlink:hover svg { transform: translateX(3px); }

/* ---------- device primitives ---------- */

.device {
  position: relative; border-radius: 34px; padding: 8px; width: 264px;
  background: linear-gradient(165deg, #3b2c14, #1d1409 55%, #0d0904);
  box-shadow: var(--shadow-device);
}
.device::after {
  content: ''; position: absolute; top: 17px; left: 50%; transform: translateX(-50%);
  width: 56px; height: 4px; border-radius: var(--r-pill); background: rgba(255, 255, 255, 0.16); z-index: 2;
}
.device img { border-radius: 27px; }
.device--clip { overflow: hidden; }

.screen {
  border-radius: var(--r-2); overflow: hidden; background: var(--paper);
  border: 1px solid var(--hair-soft); box-shadow: var(--shadow-1);
}
/* a window on a screenshot: fixed height, top-aligned, never distorted */
.screen--window { position: relative; }
.screen--window img { height: 100%; width: 100%; object-fit: cover; object-position: center var(--crop, top); }
.screen--window::after {
  content: ''; position: absolute; inset: auto 0 0 0; height: 64px; pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 253, 248, 0), rgba(255, 253, 248, 0.95));
}

/* ---------- celestial motif: two thin arcs, used twice on the page ---------- */

.orbits { position: absolute; inset: 0; overflow: clip; pointer-events: none; z-index: 0; }
.orbits svg { position: absolute; stroke: rgba(224, 122, 12, 0.16); fill: none; stroke-width: 1; }

/* ---------- nav ---------- */

.nav { position: sticky; top: 0; z-index: 70; background: rgba(251, 246, 236, 0.78); backdrop-filter: blur(14px) saturate(1.2); border-bottom: 1px solid transparent; transition: border-color 0.25s ease, background 0.25s ease; }
.nav.stuck { border-bottom-color: var(--hair); background: rgba(251, 246, 236, 0.94); }
.nav .wrap { display: flex; align-items: center; height: 66px; gap: var(--s-6); }
.nav img { height: 32px; width: auto; }
.nav-links { display: flex; gap: var(--s-6); margin-inline: auto; }
.nav-links a { color: var(--body); font-size: 0.92rem; font-weight: 500; }
.nav-links a:hover { color: var(--ink); }

/* ---------- hero ---------- */

.hero { position: relative; padding: var(--s-8) 0 0; overflow: clip; }
.hero::before {
  content: ''; position: absolute; inset: -30% -10% auto 26%; height: 820px; z-index: 0; pointer-events: none;
  background: radial-gradient(44% 46% at 58% 44%, rgba(224, 122, 12, 0.15), transparent 70%);
}
.hero .wrap { display: grid; grid-template-columns: minmax(0, 0.86fr) minmax(0, 1.14fr); gap: var(--s-7); align-items: end; }
.hero-copy { padding-bottom: var(--s-8); }
.hero h1 { margin-bottom: var(--s-4); }
.hero h1 em { font-style: normal; color: var(--accent); }
.hero .lede { margin-bottom: var(--s-5); }
.hero-actions { display: flex; align-items: center; gap: var(--s-5); flex-wrap: wrap; }
.hero-meta { display: flex; gap: var(--s-4); margin-top: var(--s-5); font-size: 0.86rem; color: var(--muted); flex-wrap: wrap; }
.hero-meta b { color: var(--ink); font-weight: 600; }

.hero-stage { position: relative; display: flex; justify-content: center; align-items: flex-end; min-height: 520px; }
.hero-stage .device { width: 296px; margin-bottom: -12px; }
.ucard {
  position: absolute; background: var(--paper); border: 1px solid var(--hair-soft);
  border-radius: var(--r-1); box-shadow: var(--shadow-2); padding: 12px 14px; width: 198px; z-index: 3;
}
.ucard .label { font-size: 0.64rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin-bottom: 6px; }
.ucard strong { display: block; font-size: 0.92rem; font-weight: 600; letter-spacing: -0.01em; }
.ucard span { display: block; font-size: 0.8rem; color: var(--muted); margin-top: 2px; }
.ucard--a { left: 1%; bottom: 186px; animation: drift 9s ease-in-out infinite; }
.ucard--b { right: 0; bottom: 72px; animation: drift 12s ease-in-out infinite; animation-delay: -4s; }
@keyframes drift { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

/* ---------- dark bands ---------- */

.night { background: var(--night); color: var(--night-text); }
.night h2, .night h3 { color: var(--night-text); }
.night p { color: var(--night-dim); }
.night .eyebrow { color: #f0a94a; }
.night .pill--quiet { color: var(--night-text); border-color: rgba(255, 255, 255, 0.22); }
.night .pill--quiet:hover { background: rgba(255, 255, 255, 0.08); color: var(--night-text); }

/* proof band: one real answer, large enough to read */
.proof { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: var(--s-8); align-items: center; }
.proof-shot { border-radius: var(--r-2); overflow: hidden; box-shadow: 0 40px 70px -40px rgba(0, 0, 0, 0.9); border: 1px solid rgba(255, 255, 255, 0.08); }
.notes { list-style: none; margin: var(--s-5) 0 0; padding: 0; }
.notes li { padding: var(--s-4) 0; border-top: 1px solid rgba(255, 255, 255, 0.12); }
.notes li:last-child { border-bottom: 1px solid rgba(255, 255, 255, 0.12); }
.notes b { display: block; font-size: 0.97rem; color: var(--night-text); font-weight: 600; margin-bottom: 2px; }
.notes span { font-size: 0.92rem; color: var(--night-dim); }

/* ---------- steps ---------- */

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-6); position: relative; }
.steps::before { content: ''; position: absolute; left: 7%; right: 7%; top: 22px; border-top: 1px dashed var(--hair); z-index: 0; }
.step { position: relative; z-index: 1; }
.step-n {
  width: 44px; height: 44px; border-radius: 50%; background: var(--page); border: 1px solid var(--hair);
  display: grid; place-items: center; font-family: var(--display); font-weight: 700; font-size: 0.95rem;
  color: var(--accent); margin-bottom: var(--s-5);
}
.step h3 { margin-bottom: 6px; }
.step p { font-size: 0.94rem; max-width: 34ch; }
.step .screen { margin-top: var(--s-5); height: 268px; }

/* ---------- chart section ---------- */

.bleed { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 0.92fr); gap: var(--s-8); align-items: center; }
.bleed-visual .screen { max-width: 420px; height: 470px; }
.spec { list-style: none; margin: var(--s-5) 0 0; padding: 0; }
.spec li { display: flex; gap: var(--s-4); padding: 13px 0; border-top: 1px solid var(--hair); font-size: 0.96rem; }
.spec li:last-child { border-bottom: 1px solid var(--hair); }
.spec b { min-width: 128px; font-weight: 600; color: var(--ink); }
.spec span { color: var(--body); }

/* ---------- timing ---------- */

.timing-list { list-style: none; margin: var(--s-6) 0 0; padding: 0; }
.timing-list li { display: flex; align-items: baseline; gap: var(--s-4); padding: 15px 0; border-top: 1px solid var(--hair); }
.timing-list li:last-child { border-bottom: 1px solid var(--hair); }
.timing-list b { font-weight: 600; font-size: 1rem; }
.timing-list .house { color: var(--body); font-size: 0.92rem; }
.timing-list .when { margin-left: auto; font-variant-numeric: tabular-nums; color: var(--muted); font-size: 0.92rem; white-space: nowrap; }

/* ---------- question wall ---------- */

.wall { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.q {
  border: 1px solid var(--hair); background: var(--paper); border-radius: var(--r-pill);
  padding: 10px 18px; font-size: 0.95rem; color: var(--ink);
  transition: border-color 0.18s ease, transform 0.18s ease;
}
.q:hover { border-color: var(--accent); transform: translateY(-2px); }
.q--hi { color: var(--body); }

/* ---------- app strip ---------- */

.strip { display: flex; gap: var(--s-5); align-items: flex-end; justify-content: center; padding: var(--s-6) 0 0; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.strip::-webkit-scrollbar { display: none; }
.strip .device { flex: 0 0 auto; scroll-snap-align: center; width: 184px; box-shadow: 0 40px 70px -36px rgba(0, 0, 0, 0.9); }
.strip .device:nth-child(2), .strip .device:nth-child(4) { width: 204px; margin-bottom: 16px; }
.strip .device:nth-child(3) { width: 226px; margin-bottom: 28px; }

/* ---------- honesty ---------- */

.honest { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s-7); }
.honest h3 { margin-bottom: 6px; }
.honest p { font-size: 0.94rem; }
.faces { display: flex; align-items: center; margin-top: var(--s-5); }
.faces img { width: 42px; height: 42px; border-radius: 50%; margin-left: -10px; box-shadow: 0 0 0 3px var(--page); }
.faces img:first-child { margin-left: 0; }
.faces span { margin-left: var(--s-4); font-size: 0.9rem; color: var(--muted); }

/* ---------- FAQ ---------- */

.faq { max-width: 780px; margin-inline: auto; }
details { border-top: 1px solid var(--hair); padding: var(--s-4) 0; }
details:last-of-type { border-bottom: 1px solid var(--hair); }
summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: var(--s-4); font-weight: 600; font-size: 1rem; }
summary::-webkit-details-marker { display: none; }
summary::after { content: ''; margin-left: auto; width: 9px; height: 9px; border-right: 1.6px solid var(--accent); border-bottom: 1.6px solid var(--accent); transform: rotate(45deg) translateY(-2px); transition: transform 0.2s ease; }
details[open] summary::after { transform: rotate(225deg) translateY(-2px); }
details p { margin-top: var(--s-3); font-size: 0.96rem; max-width: 64ch; }

/* ---------- final CTA ---------- */

.finale { position: relative; overflow: hidden; background: var(--night); color: var(--night-text); border-radius: var(--r-3); padding: var(--s-8) var(--s-7); text-align: center; }
.finale h2 { color: var(--night-text); max-width: 20ch; margin-inline: auto; }
.finale p { color: var(--night-dim); max-width: 46ch; margin: var(--s-4) auto var(--s-6); }
.finale .emblem { width: 56px; height: 56px; margin: 0 auto var(--s-5); }
.finale .orbits svg { stroke: rgba(240, 169, 74, 0.22); }

/* ---------- footer ---------- */

.foot { padding: var(--s-7) 0 var(--s-6); border-top: 1px solid var(--hair); margin-top: var(--s-8); }
.foot-row { display: flex; align-items: center; gap: var(--s-5); flex-wrap: wrap; }
.foot img { height: 28px; width: auto; }
.foot nav { display: flex; gap: var(--s-5); margin-inline: auto; flex-wrap: wrap; }
.foot nav a { color: var(--body); font-size: 0.9rem; }
.foot .tiny { margin-top: var(--s-5); }

/* ---------- long-form pages ---------- */

.doc { padding: var(--s-7) 0 var(--s-5); }
.doc .wrap { max-width: var(--narrow); }
.doc h1 { font-size: clamp(2rem, 3.2vw, 2.6rem); margin-bottom: 6px; }
.doc h2 { font-size: 1.32rem; margin-top: var(--s-7); }
.doc p, .doc li { color: var(--body); font-size: 0.99rem; }
.doc p { margin-top: var(--s-3); }
.doc ul { padding-left: 22px; margin-top: var(--s-3); }
.doc li { margin-bottom: 8px; }
.doc .updated { color: var(--muted); font-size: 0.88rem; margin-top: 6px; }

/* ---------- motion ---------- */

.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.6s cubic-bezier(.2,.7,.3,1), transform 0.6s cubic-bezier(.2,.7,.3,1); }
.reveal.in { opacity: 1; transform: none; }
.d1 { transition-delay: 0.07s; } .d2 { transition-delay: 0.14s; } .d3 { transition-delay: 0.21s; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; }
}

/* ---------- responsive ---------- */

@media (max-width: 1080px) {
  .hero .wrap { gap: var(--s-6); }
  .hero-stage .device { width: 264px; }
  .ucard { width: 178px; }
  .proof { grid-template-columns: 1fr; gap: var(--s-6); }
  .bleed { grid-template-columns: 1fr; gap: var(--s-6); }
  .bleed-visual .screen { max-width: 380px; height: 420px; margin-inline: auto; }
  .honest { grid-template-columns: 1fr 1fr; gap: var(--s-6); }
}

@media (max-width: 860px) {
  .nav-links { display: none; }
  .nav .wrap { gap: var(--s-4); }
  .nav .pill { margin-left: auto; }
  .hero { padding-top: var(--s-7); }
  .hero .wrap { grid-template-columns: 1fr; }
  .hero-copy { padding-bottom: var(--s-5); }
  .hero .lede { max-width: none; }
  .hero-stage { min-height: 470px; }
  .steps { grid-template-columns: 1fr; gap: var(--s-6); }
  .steps::before { display: none; }
  .step { display: grid; grid-template-columns: 44px 1fr; gap: var(--s-3) var(--s-4); align-items: start; }
  .step-n { margin-bottom: 0; }
  .step h3, .step p { grid-column: 2; }
  .step .screen { grid-column: 1 / -1; }
  .honest { grid-template-columns: 1fr; gap: var(--s-5); }
  .pad { padding: var(--s-7) 0; }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  .hero { padding-top: var(--s-6); }
  .hero-meta { gap: var(--s-3); font-size: 0.82rem; }
  h1 { font-size: 2.45rem; }
  .wrap { width: calc(100% - 32px); }
  .hero-stage { min-height: 430px; }
  .hero-stage .device { width: 232px; }
  .ucard { width: 160px; padding: 10px 12px; }
  .ucard--a { left: 0; bottom: 156px; }
  .ucard--b { right: 0; bottom: 44px; }
  .spec li { flex-direction: column; gap: 2px; }
  .spec b { min-width: 0; }
  .finale { padding: var(--s-7) var(--s-5); border-radius: var(--r-2); }
  .strip .device, .strip .device:nth-child(2), .strip .device:nth-child(3), .strip .device:nth-child(4) { width: 188px; margin-bottom: 0; }
}
