/* ideas.phasetransitions.ai — quiet scientific / emergence.
   Order from noise. Light lab paper, one cool accent, three type registers:
   Space Grotesk (headings), IBM Plex Mono (labels/coordinates), Source Serif 4 (prose). */

@font-face { font-family: "Space Grotesk"; src: url("./fonts/space-grotesk-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Space Grotesk"; src: url("./fonts/space-grotesk-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "IBM Plex Mono"; src: url("./fonts/ibm-plex-mono-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("./fonts/source-serif-4-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("./fonts/source-serif-4-400-italic.woff2") format("woff2"); font-weight: 400; font-style: italic; font-display: swap; }
@font-face { font-family: "Source Serif 4"; src: url("./fonts/source-serif-4-600.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: swap; }

:root {
  --paper: #eef1f0;
  --card: #f7f8f7;
  --ink: #15191b;
  --ink-soft: #3b4346;
  --phase: #0e7c86;
  --phase-deep: #0a5c64;
  --hover: #e7ebea;
  --muted: #6b7572;
  --rule: #d6dbd9;
  --grotesk: "Space Grotesk", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  --serif: "Source Serif 4", Georgia, serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.wrap { max-width: 960px; margin: 0 auto; padding: 0 28px; }

/* shared header nav */
.nav { border-bottom: 1px solid var(--rule); }
.nav .wrap { display: flex; align-items: center; justify-content: space-between; padding-top: 20px; padding-bottom: 20px; gap: 16px; flex-wrap: wrap; }
.brand { font-family: var(--mono); font-size: 0.82rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink); transition: color 0.15s; }
.brand:hover { color: var(--phase-deep); }
.nav-links { display: flex; gap: 22px; }
.nav-links a { font-family: var(--mono); font-size: 0.82rem; color: var(--ink); border-bottom: 1px solid transparent; transition: border-color 0.15s, color 0.15s; }
.nav-links a:hover { color: var(--phase-deep); border-color: var(--phase); }
.nav-links a.active { color: var(--muted); }
.nav-links a.active:hover { color: var(--muted); border-color: transparent; }

/* labels / eyebrows */
.label {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 18px;
}
.num { font-family: var(--mono); color: var(--phase); }

a { color: var(--phase); text-decoration: none; }
:focus-visible { outline: 2px solid var(--phase); outline-offset: 3px; }

/* One selection model: every selectable item is a whole-block link that highlights on hover. */
a.card, a.topic { color: var(--ink); transition: background 0.15s, border-color 0.15s; }
a.topic:hover { background: var(--hover); }
a.card:hover { background: var(--hover); border-color: var(--muted); }
.go { color: var(--muted); transition: color 0.15s; padding-left: 4px; }
a.card:hover .go, a.topic:hover .go { color: var(--phase-deep); }

/* Inline / standalone text links (reading, not selecting). */
.practice-link, .foot-links a { border-bottom: 1px solid transparent; transition: border-color 0.15s, color 0.15s; }
.practice-link:hover, .foot-links a:hover { border-color: var(--phase); color: var(--phase-deep); }

/* ---- hero ---- */
.hero { padding: 86px 0 56px; border-bottom: 1px solid var(--rule); }
.hero .eyebrow {
  font-family: var(--mono); font-size: 0.78rem; letter-spacing: 0.24em;
  text-transform: uppercase; color: var(--muted); margin: 0 0 26px;
}
.hero .eyebrow .dot { color: var(--phase); padding: 0 4px; }
.tagline {
  font-family: var(--grotesk); font-weight: 700;
  font-size: clamp(2.5rem, 7vw, 4.6rem); line-height: 1.0; letter-spacing: -0.025em;
  margin: 0; color: var(--ink);
}
.lede { font-size: clamp(1.1rem, 2vw, 1.32rem); line-height: 1.5; color: var(--ink-soft); max-width: 50ch; margin: 26px 0 0; }
.signature { margin: 44px 0 8px; }
.signature canvas, .signature img { display: block; width: 100%; max-width: 760px; height: auto; aspect-ratio: 760 / 260; }
/* On a phone held upright the wide band crushes the lattice; give the canvas a taller
   shape so the re-tiled 36×54 field (see phase.js) breathes. Portrait phones only;
   landscape and tablet/laptop keep the wide band. */
@media (orientation: portrait) and (max-width: 600px) {
  .signature canvas { aspect-ratio: 3 / 4; }
}
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.cta {
  font-family: var(--mono); font-size: 0.82rem; letter-spacing: 0.02em;
  padding: 11px 20px; background: var(--phase); color: #fff; border: 1px solid var(--phase);
  border-bottom-color: var(--phase);
}
.cta:hover { background: var(--phase-deep); border-color: var(--phase-deep); color: #fff; }
.cta.ghost { background: transparent; color: var(--phase); }
.cta.ghost:hover { background: transparent; color: var(--phase-deep); border-color: var(--phase-deep); }

/* ---- section rhythm ---- */
/* Sections also carry .wrap (padding: 0 28px), which outranks `main section` on
   specificity. Set vertical padding with `main section.wrap` so it actually applies. */
main section { border-bottom: 1px solid var(--rule); }
main section.wrap { padding-top: 48px; padding-bottom: 48px; }
.label { margin-bottom: 24px; }

/* start here cards */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
a.card { background: var(--card); border: 1px solid var(--rule); padding: 24px; display: flex; flex-direction: column; }
.card-who { display: block; font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin: 0 0 12px; }
.card-gloss { display: block; font-size: 1.0rem; color: var(--ink-soft); margin: 0 0 18px; flex: 1; }
.card-piece { display: block; font-family: var(--grotesk); font-weight: 700; font-size: 1.12rem; line-height: 1.25; color: var(--phase); }
a.card:hover .card-piece { color: var(--phase-deep); }

/* topics */
.topic-list { list-style: none; padding: 0; margin: 0; }
.topic-list li { border-top: 1px solid var(--rule); }
a.topic { display: grid; grid-template-columns: 48px 1fr; gap: 18px; padding: 22px 8px; }
.topic-body h3 { font-family: var(--grotesk); font-weight: 700; font-size: 1.3rem; letter-spacing: -0.01em; margin: 0 0 6px; }
.topic-body p { margin: 0 0 10px; color: var(--ink-soft); max-width: 58ch; }
.topic-go { font-family: var(--mono); font-size: 0.82rem; color: var(--phase); }
a.topic:hover .topic-go { color: var(--phase-deep); }

/* practice (secondary) */
#practice { border-bottom: none; }
.practice-panel { background: var(--card); border: 1px solid var(--rule); padding: 30px; max-width: 640px; }
.practice-body { font-size: 1.05rem; color: var(--ink-soft); margin: 0 0 18px; }
.practice-link { font-family: var(--mono); font-size: 0.82rem; }

/* footer */
footer.wrap { padding-top: 44px; padding-bottom: 72px; }
.foot-tag { font-family: var(--grotesk); font-weight: 500; font-size: 1.1rem; margin: 0 0 16px; }
.foot-links { display: flex; gap: 22px; margin: 0 0 16px; }
.foot-links a { font-family: var(--mono); font-size: 0.85rem; }
.foot-meta { font-family: var(--mono); font-size: 0.78rem; color: var(--muted); margin: 0; }

/* ---- responsive ---- */
@media (max-width: 720px) {
  .cards { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
