/* =============================================================
   Eden Platform — Website Brand-Book Surface · "Midnight Atlas"
   site.css · v20260621-atlas-01
   One coherent design language for the public website surface.
   Static, accessible, no dependencies, no third-party calls.

   Direction: dark-led cinematic atlas. Deep void canvas, a fine
   origin grid as connective tissue, a literary serif for display,
   grotesk for reading, mono for coordinates/labels, and ONE
   luminous-green beacon used sparingly as the live signal.

   Product truth preserved: the Eden Atlas globe renderer
   (globe-render.js + globe-data.js) and production --orb-* values
   are carried over; only the design around it is new.
   ============================================================= */

:root {
  color-scheme: dark;

  /* surfaces — deep void through panel */
  --void: #050608;
  --void-2: #080a0d;
  --panel: #0c0f12;
  --panel-2: #11151a;

  /* ink — moonlight white through graphite */
  --ink: #eef0ec;
  --muted: #9da09a;
  --faint: #5d605b;
  --quiet: #34373a;

  /* hairlines + grid */
  --line: rgba(228, 232, 224, 0.10);
  --line-2: rgba(228, 232, 224, 0.18);
  --grid: rgba(228, 232, 224, 0.045);

  /* the one accent — a beacon, not a wash */
  --beacon: #9fe3b8;
  --beacon-ink: #04130b;
  --beacon-soft: rgba(159, 227, 184, 0.13);
  --beacon-line: rgba(159, 227, 184, 0.40);

  /* type */
  --serif: "Iowan Old Style", "Charter", "Source Serif Pro", ui-serif, Georgia, "Times New Roman", serif;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace;

  /* layout */
  --edge: clamp(20px, 4.4vw, 72px);
  --rail: 64px;
  --maxw: 1200px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  /* Atlas globe orb — production values preserved. */
  --orb-base: #050608;
  --orb-dot: color-mix(in srgb, #e6f3e0 78%, #f4f6f6 22%);
  --orb-glow: color-mix(in srgb, #b8e0c2 60%, #f4f6f6 40%);
  --orb-continent-opacity: 1;
  --orb-grid: rgba(220, 232, 220, 0.18);
  --orb-arc: rgba(220, 232, 220, 0.26);
  --orb-rim: rgba(220, 232, 220, 0.22);
  --orb-tick: rgba(220, 232, 220, 0.55);
  --orb-highlight: rgba(220, 236, 222, 0.16);
  --orb-shadow: rgba(0, 0, 0, 0.55);
  --orb-halo: #d8efe0;
  --orb-halo-strength: 0.85;
  --orb-proximity: 0;
}

/* ---------- light theme (derived from the dark home base) ---------- */
html[data-theme="light"] {
  color-scheme: light;
  --void: #f4f5f1;
  --void-2: #eceee8;
  --panel: #ffffff;
  --panel-2: #f7f8f4;
  --ink: #15170f;
  --muted: #585b52;
  --faint: #8b8e84;
  --quiet: #c4c7bd;
  --line: rgba(20, 24, 14, 0.12);
  --line-2: rgba(20, 24, 14, 0.20);
  --grid: rgba(20, 24, 14, 0.05);
  --beacon: #1f8a57;
  --beacon-ink: #ffffff;
  --beacon-soft: rgba(31, 138, 87, 0.10);
  --beacon-line: rgba(31, 138, 87, 0.34);

  --orb-base: #f4f5f1;
  --orb-dot: color-mix(in srgb, #2a3a2d 92%, #14161a 8%);
  --orb-glow: rgba(36, 52, 38, 0.08);
  --orb-continent-opacity: 0.86;
  --orb-grid: rgba(20, 30, 22, 0.18);
  --orb-arc: rgba(20, 30, 22, 0.24);
  --orb-rim: rgba(20, 30, 22, 0.20);
  --orb-tick: rgba(20, 30, 22, 0.5);
  --orb-highlight: rgba(255, 255, 255, 0);
  --orb-shadow: rgba(20, 30, 22, 0.16);
  --orb-halo: #1a2a1d;
  --orb-halo-strength: 0.32;
}

/* ---------- base ---------- */
* { box-sizing: border-box; }
html, body { margin: 0; }
html { scroll-behavior: smooth; }
body {
  background-color: var(--void);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  background-image:
    linear-gradient(transparent calc(100% - 1px), var(--grid) 100%),
    linear-gradient(90deg, transparent calc(100% - 1px), var(--grid) 100%);
  background-size: 64px 64px, 64px 64px;
  background-position: center top;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
::selection { background: var(--beacon-soft); }
:focus-visible { outline: 2px solid var(--beacon); outline-offset: 3px; }

.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--edge); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* ============================================================
   Top frame — shared chrome on every page
   ============================================================ */
.top {
  position: sticky;
  top: 0;
  z-index: 20;
  height: var(--rail);
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--void) 84%, transparent);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.top-in {
  display: flex; align-items: center; justify-content: space-between;
  gap: 18px; height: 100%;
}
.ep {
  font-family: var(--serif);
  font-size: 18px;
  letter-spacing: 0.03em;
  white-space: nowrap;
}
.ep b { color: var(--beacon); font-weight: 400; }
.site-nav { display: flex; gap: clamp(14px, 2vw, 30px); align-items: center; min-width: 0; }
.site-nav a {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  padding: 6px 0;
  position: relative;
  white-space: nowrap;
  transition: color 0.2s var(--ease);
}
.site-nav a:hover { color: var(--ink); }
.site-nav a.on { color: var(--ink); }
.site-nav a.on::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -1px;
  height: 1px; background: var(--beacon);
}
.top-right { display: flex; align-items: center; gap: 16px; white-space: nowrap; }
.coord { font-family: var(--mono); font-size: 11px; letter-spacing: 0.12em; color: var(--faint); }
.theme-toggle {
  font-family: var(--mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--muted); background: transparent; border: 1px solid var(--line-2);
  border-radius: 999px; padding: 6px 12px; cursor: pointer; transition: color 0.2s, border-color 0.2s;
}
.theme-toggle:hover { color: var(--ink); border-color: var(--beacon-line); }

/* ============================================================
   Hero
   ============================================================ */
.hero { position: relative; padding: clamp(48px, 8.5vw, 128px) 0 clamp(36px, 6vw, 88px); }
.hero-grid { display: grid; grid-template-columns: 1.04fr 0.96fr; gap: clamp(24px, 4vw, 56px); align-items: center; }
.hero-tight { display: block; }
.hero-tight .hero-grid { grid-template-columns: 1fr; max-width: 60ch; }

.kick {
  font-family: var(--mono); font-size: 11px; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--beacon); display: inline-flex; align-items: center; gap: 12px; margin: 0 0 26px;
}
.kick::before { content: ""; width: 30px; height: 1px; background: var(--beacon); opacity: 0.6; }

h1.display {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(2.7rem, 6vw, 5.2rem); line-height: 0.99; letter-spacing: -0.018em;
  margin: 0; color: var(--ink);
}
h1.display em { font-style: italic; color: var(--muted); }

.lede { font-size: clamp(1rem, 1.2vw, 1.16rem); color: var(--muted); max-width: 46ch; margin: 28px 0 0; }
.boundary { font-family: var(--mono); font-size: 11px; letter-spacing: 0.03em; color: var(--faint); margin: 22px 0 0; max-width: 60ch; }

.cta { display: flex; gap: 14px; margin-top: 36px; flex-wrap: wrap; }
.btn {
  font-family: var(--mono); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase;
  padding: 13px 22px; border: 1px solid var(--line-2); border-radius: 3px; color: var(--ink);
  transition: border-color 0.2s var(--ease), background 0.2s var(--ease), color 0.2s var(--ease);
}
.btn:hover { border-color: var(--beacon); background: var(--beacon-soft); }
.btn.solid { background: var(--beacon); color: var(--beacon-ink); border-color: var(--beacon); }
.btn.solid:hover { filter: brightness(1.07); }

.chip {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--beacon); border: 1px solid var(--beacon-line); border-radius: 999px; padding: 5px 13px;
}
.chip::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--beacon); }

/* ---------- hero sheet — structured right-column panel ----------
   Used on the home + globe-less product pages so their hero carries
   the same asymmetric balance as the Eden Atlas globe hero. The
   tight single-column hero (.hero-tight) is reserved for informative
   pages (brand book, contact, docs). */
.hero-sheet {
  border: 1px solid var(--line); border-radius: 6px; background: var(--void-2);
  padding: clamp(22px, 2.8vw, 34px); align-self: stretch;
}
.hs-top {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--faint); padding-bottom: 16px; border-bottom: 1px solid var(--line);
}
.hs-top .live { color: var(--beacon); display: inline-flex; align-items: center; gap: 8px; }
.hs-top .live::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--beacon); box-shadow: 0 0 0 4px var(--beacon-soft); }
.hs-statement { font-family: var(--serif); font-size: clamp(1.12rem, 1.7vw, 1.42rem); line-height: 1.42; color: var(--ink); margin: 18px 0 0; }
.hs-foot { margin-top: 20px; padding-top: 15px; border-top: 1px solid var(--line); font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); }
.hs-list { margin: 6px 0 0; }
.hs-row { display: grid; grid-template-columns: 82px 1fr; gap: 14px; align-items: baseline; padding: 14px 0; border-top: 1px solid var(--line); }
.hs-row:first-child { border-top: 0; }
.hs-row dt { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); margin: 0; }
.hs-row dd { margin: 0; font-family: var(--serif); font-size: 1.06rem; color: var(--ink); }
.hs-row dd.q { font-family: var(--sans); font-size: 0.92rem; color: var(--muted); }

/* ============================================================
   Atlas globe orb — ported from production (product truth)
   ============================================================ */
.orb-cell { display: flex; justify-content: center; }
.atlas-orb {
  position: relative;
  width: 100%;
  max-width: min(460px, 100%);
  margin: 0 auto;
  isolation: isolate;
  filter:
    drop-shadow(0 24px 60px var(--orb-shadow))
    drop-shadow(0 6px 18px color-mix(in srgb, var(--orb-shadow) 60%, transparent));
}
.atlas-orb-stage { display: block; width: 100%; }
.atlas-orb-svg { display: block; width: 100%; height: auto; aspect-ratio: 1; overflow: visible; }
.atlas-orb-arcs { opacity: calc(0.62 + 0.38 * var(--orb-proximity)); transition: opacity 220ms var(--ease); }
.atlas-orb-ticks-major { opacity: calc(0.78 + 0.22 * var(--orb-proximity)); transition: opacity 220ms var(--ease); }
.atlas-orb-ticks-minor { opacity: calc(0.42 + 0.32 * var(--orb-proximity)); transition: opacity 220ms var(--ease); }
.atlas-orb-mark { opacity: calc(0.55 + 0.40 * var(--orb-proximity)); transition: opacity 220ms var(--ease); }
.atlas-orb-caption {
  display: flex; align-items: baseline; justify-content: space-between; gap: 16px;
  margin: 16px 6px 0; color: var(--muted);
  font-family: var(--mono); font-size: 9.5px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase;
}
.atlas-orb-caption span:first-child::before {
  content: ""; display: inline-block; width: 16px; height: 1px; margin-right: 10px;
  vertical-align: 0.32em; background: currentColor; opacity: 0.55;
}
.atlas-orb-coord { color: var(--faint); letter-spacing: 0.18em; }

/* ============================================================
   Section scaffold — same rhythm on every page
   ============================================================ */
.sec { padding: clamp(44px, 7vw, 96px) 0; border-top: 1px solid var(--line); }
.sec-sub { font-family: var(--mono); font-size: 11px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--beacon); margin: 0 0 14px; }
.sec-head { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; margin-bottom: clamp(28px, 4vw, 48px); }
.sec-head h2 { font-family: var(--serif); font-weight: 400; font-size: clamp(1.7rem, 3vw, 2.6rem); letter-spacing: -0.012em; margin: 0; }
.sec-no { font-family: var(--mono); font-size: 11px; letter-spacing: 0.16em; color: var(--faint); white-space: nowrap; }

/* ---------- ecosystem index rows ---------- */
.index { display: flex; flex-direction: column; }
.row {
  display: grid; grid-template-columns: 54px 1.05fr 1.5fr auto; align-items: center; gap: 24px;
  padding: 26px 10px; border-top: 1px solid var(--line); transition: background 0.25s var(--ease);
}
.row:first-child { border-top: 0; }
.row:hover { background: var(--void-2); }
.row .n { font-family: var(--mono); font-size: 12px; color: var(--faint); }
.row .nm { font-family: var(--serif); font-size: clamp(1.25rem, 2vw, 1.75rem); letter-spacing: -0.01em; }
.row .ds { color: var(--muted); font-size: 0.96rem; }
.row .meta {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--faint); display: flex; align-items: center; gap: 9px; justify-content: flex-end; text-align: right;
}
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--beacon); box-shadow: 0 0 0 4px var(--beacon-soft); flex: none; }
.dot.idle { background: var(--quiet); box-shadow: none; }

/* ---------- editorial prose ---------- */
.prose { columns: 2; column-gap: 42px; max-width: var(--maxw); }
.prose p { margin: 0 0 1em; color: var(--muted); break-inside: avoid; }
.prose p:first-of-type::first-letter {
  font-family: var(--serif); font-size: 3em; line-height: 0.8; float: left; padding: 6px 12px 0 0; color: var(--ink);
}
.note { color: var(--muted); max-width: 62ch; }
.pull { font-family: var(--serif); font-style: italic; font-size: clamp(1.4rem, 3vw, 2.1rem); line-height: 1.28; color: var(--ink); max-width: 26ch; margin: 0; }

/* ---------- spec / capability rows ---------- */
.specs { list-style: none; margin: 0; padding: 0; }
.spec { display: grid; grid-template-columns: 46px 1fr auto; gap: 20px; align-items: start; padding: 22px 0; border-top: 1px solid var(--line); }
.spec:first-child { border-top: 0; }
.spec .sn { font-family: var(--mono); font-size: 12px; color: var(--faint); padding-top: 4px; }
.spec h3 { font-family: var(--serif); font-weight: 400; font-size: 1.2rem; margin: 0 0 6px; }
.spec p { margin: 0; color: var(--muted); font-size: 0.95rem; max-width: 56ch; }
.spec .tag { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); white-space: nowrap; padding-top: 5px; }

.stack > * + * { margin-top: clamp(16px, 2.4vw, 26px); }

/* ============================================================
   Brand book — the system, documented
   ============================================================ */
.specimen-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.specimen-grid > div { background: var(--void); padding: 24px; }
.specimen-grid .lab { font-family: var(--mono); font-size: 10px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); margin: 0 0 16px; }
.sp-serif { font-family: var(--serif); font-size: 2.1rem; line-height: 1; margin: 0; }
.sp-serif em { font-style: italic; color: var(--muted); }
.sp-sans { font-family: var(--sans); font-size: 1.4rem; margin: 0; }
.sp-mono { font-family: var(--mono); font-size: 1.05rem; letter-spacing: 0.04em; margin: 0; }

.swatches { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; }
.swatch { flex: 1 1 92px; }
.swatch span { display: block; height: 56px; border-radius: 3px; border: 1px solid var(--line); }
.swatch b { display: block; font-family: var(--sans); font-weight: 500; font-size: 0.82rem; margin-top: 8px; }
.swatch i { font-family: var(--mono); font-style: normal; font-size: 10px; color: var(--faint); }

.members { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.member { border: 1px solid var(--line); border-left: 2px solid var(--beacon-line); padding: 22px; background: var(--void-2); transition: border-color 0.2s var(--ease), transform 0.2s var(--ease); }
.member:hover { border-left-color: var(--beacon); transform: translateY(-2px); }
.member .mt { font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); margin: 0 0 10px; }
.member h3 { font-family: var(--serif); font-weight: 400; font-size: 1.4rem; margin: 0 0 8px; }
.member p { margin: 0; color: var(--muted); font-size: 0.92rem; }
.member .md { display: block; font-family: var(--mono); font-size: 10.5px; color: var(--beacon); margin-top: 12px; letter-spacing: 0.04em; }

/* ---------- bounded product promotion (e.g. Eden Atlas on home) ---------- */
.promo {
  display: grid; grid-template-columns: 0.82fr 1fr; gap: clamp(24px, 4vw, 56px);
  align-items: center; border: 1px solid var(--line); border-radius: 6px;
  background: var(--void-2); padding: clamp(24px, 3.6vw, 52px);
}
.promo .atlas-orb { max-width: min(320px, 100%); }
.promo-kick { font-family: var(--mono); font-size: 11px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--beacon); margin: 0 0 14px; display: inline-flex; align-items: center; gap: 10px; }
.promo-kick::before { content: ""; width: 22px; height: 1px; background: var(--beacon); opacity: 0.6; }
.promo h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(1.8rem, 3.4vw, 2.8rem); letter-spacing: -0.015em; margin: 0 0 14px; }
@media (max-width: 760px) { .promo { grid-template-columns: 1fr; } .promo .atlas-orb { max-width: min(300px, 72vw); margin-inline: 0; } }

/* ============================================================
   Footer
   ============================================================ */
.site-foot { border-top: 1px solid var(--line); padding: 44px 0 72px; }
.site-foot-in { display: flex; justify-content: space-between; align-items: baseline; gap: 20px; flex-wrap: wrap; }
.site-foot a.mail { font-family: var(--serif); font-size: 1.3rem; }
.site-foot a.mail:hover { color: var(--beacon); }
.site-foot .fc { font-family: var(--mono); font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint); }

/* ============================================================
   Reveal
   ============================================================ */
.reveal-on [data-reveal] { opacity: 0; transform: translateY(16px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); transition-delay: var(--reveal-delay, 0ms); }
.reveal-on [data-reveal].is-in { opacity: 1; transform: none; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; gap: 8px; }
  .orb-cell { margin-top: 24px; }
  .atlas-orb { max-width: min(360px, 78vw); }
  .prose { columns: 1; }
}
@media (max-width: 720px) {
  .top {
    height: auto;
  }
  .top-in {
    flex-wrap: wrap;
    padding-block: 11px;
  }
  .top-right .coord { display: none; }
  .site-nav {
    order: 3;
    width: 100%;
    gap: 18px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .site-nav::-webkit-scrollbar { display: none; }
  .row { grid-template-columns: 34px 1fr; row-gap: 8px; }
  .row .ds { grid-column: 2; }
  .row .meta { grid-column: 2; justify-content: flex-start; text-align: left; }
  .sec-head { flex-direction: column; gap: 6px; }
  .spec { grid-template-columns: 34px 1fr; }
  .spec .tag { grid-column: 2; padding-top: 2px; }
}
@media (max-width: 460px) {
  .ep { font-size: 16px; }
  h1.display { font-size: clamp(2.3rem, 11vw, 3rem); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal-on [data-reveal] { opacity: 1; transform: none; transition: none; }
  .member, .btn, .row { transition: none; }
}
