/* ============================================================
   TopSheet — landing page
   Design language extracted from the product UI:
   warm paper, ink, signature forest green, monospace metadata.
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Hanken+Grotesk:wght@400;500;600;700;800&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  /* surfaces */
  --paper:        #F4F1EA;
  --paper-2:      #EEEADF;
  --tan:          #E7DFCF;
  --card:         #FBFAF5;
  --green-tint:   color-mix(in srgb, var(--green) 15%, var(--paper));

  /* ink */
  --ink:          #1B1A16;
  --ink-2:        #4A473F;
  --mute:         #8E887A;
  --line:         #E0DACC;
  --line-strong:  #CFC8B7;

  /* accents */
  --green:        #3E6B3C;
  --green-deep:   color-mix(in srgb, var(--green) 72%, #000);
  --red:          #E23B2E;
  --amber:        #C0772E;
  --task:         #5C7C97;
  --task-bg:      #E2E8EE;

  /* type */
  --sans: 'Hanken Grotesk', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;

  --maxw: 1180px;
  --pad: clamp(20px, 5vw, 64px);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

::selection { background: var(--green); color: #fff; }

a { color: inherit; text-decoration: none; }

/* ---------- shared type ---------- */
.eyebrow {
  font-family: var(--mono);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--mute);
}

.mono { font-family: var(--mono); }

h1, h2, h3 {
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.04;
  text-wrap: balance;
  margin: 0;
}

p { margin: 0; text-wrap: pretty; }

.lead {
  font-size: clamp(1.12rem, 1.7vw, 1.4rem);
  line-height: 1.55;
  color: var(--ink-2);
  font-weight: 400;
}

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding-inline: var(--pad);
}

/* ============================================================
   NAV
   ============================================================ */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 86%, transparent);
  backdrop-filter: saturate(150%) blur(12px);
  -webkit-backdrop-filter: saturate(150%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s ease, background .3s ease;
}
.nav.scrolled { border-bottom-color: var(--line); }
.nav-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 18px var(--pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-weight: 700;
  font-size: 1.32rem;
  letter-spacing: -0.02em;
}
.brand .dot {
  width: 11px; height: 11px;
  border-radius: 50%;
  background: var(--green);
  flex: none;
}
.nav-actions { display: flex; align-items: center; gap: 10px; }

/* ---------- buttons ---------- */
.btn {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 0.98rem;
  letter-spacing: -0.01em;
  border-radius: 11px;
  padding: 11px 19px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .15s ease, background .2s ease, color .2s ease, border-color .2s ease, box-shadow .2s ease;
  display: inline-flex; align-items: center; gap: 9px;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--ink);
  color: var(--paper);
}
.btn-primary:hover { background: #000; box-shadow: 0 8px 24px -10px rgba(0,0,0,.5); }
.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn-ghost:hover { border-color: var(--ink); background: color-mix(in srgb, var(--ink) 4%, transparent); }
.btn-lg { padding: 15px 28px; font-size: 1.08rem; border-radius: 13px; }
.btn-green { background: var(--green); color: #fff; }
.btn-green:hover { background: var(--green-deep); box-shadow: 0 10px 28px -12px var(--green); }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  position: relative;
  text-align: center;
  padding: clamp(64px, 11vw, 132px) 0 clamp(48px, 7vw, 88px);
}
.hero .eyebrow { display: inline-block; margin-bottom: 26px; }
.hero h1 {
  font-size: clamp(2.7rem, 6.4vw, 5.4rem);
  letter-spacing: -0.035em;
  max-width: 16ch;
  margin: 0 auto;
}
.hero h1 .accent { color: var(--green); }
.hero .lead {
  max-width: 50ch;
  margin: 28px auto 0;
}
.hero-cta {
  margin-top: 38px;
  display: flex;
  gap: 13px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ---------- "just talk" record motif ---------- */
.talk {
  margin: clamp(56px, 8vw, 92px) auto 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 22px;
}
.record {
  position: relative;
  width: 92px; height: 92px;
  border-radius: 50%;
  background: var(--red);
  display: grid; place-items: center;
  border: none; cursor: pointer;
  box-shadow: 0 18px 44px -16px rgba(226,59,46,.7);
  transition: transform .2s ease;
}
.record:hover { transform: scale(1.04); }
.record svg { width: 34px; height: 34px; color: #fff; }
.record::before, .record::after {
  content: '';
  position: absolute; inset: 0;
  border-radius: 50%;
  border: 2px solid var(--red);
  animation: ripple 2.8s ease-out infinite;
}
.record::after { animation-delay: 1.4s; }
@keyframes ripple {
  0%   { transform: scale(1); opacity: .55; }
  100% { transform: scale(2.1); opacity: 0; }
}
.waveform {
  display: flex; align-items: center; gap: 5px; height: 30px;
}
.waveform i {
  display: block;
  width: 4px;
  border-radius: 4px;
  background: var(--ink);
  opacity: .82;
  animation: wave 1.1s ease-in-out infinite;
}
@keyframes wave {
  0%, 100% { height: 7px; }
  50%      { height: 28px; }
}
.talk-caption {
  font-family: var(--mono);
  font-size: 0.86rem;
  letter-spacing: 0.04em;
  color: var(--ink-2);
}
.talk-caption b { color: var(--ink); font-weight: 600; }
.talk-line {
  min-height: 1.5em;
  font-size: clamp(1.05rem, 2vw, 1.45rem);
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--ink);
  max-width: 40ch;
  text-align: center;
}
.talk-line .caret {
  display: inline-block;
  width: 2px; height: 1.05em;
  background: var(--green);
  margin-left: 2px;
  vertical-align: -0.16em;
  animation: blink 1s steps(1) infinite;
}
@keyframes blink { 50% { opacity: 0; } }

/* ============================================================
   SECTION scaffolding
   ============================================================ */
section { position: relative; }
.section {
  padding: clamp(64px, 10vw, 130px) 0;
}
.section-head { max-width: 64ch; }
.section-head .eyebrow { display: block; margin-bottom: 20px; }
.section-head h2 {
  font-size: clamp(2rem, 4.4vw, 3.4rem);
  letter-spacing: -0.03em;
}
.section-head .lead { margin-top: 22px; max-width: 52ch; }

.divider { border: 0; border-top: 1px solid var(--line); margin: 0 var(--pad); }
.wrap .divider { margin-inline: 0; }

/* ============================================================
   AHA — thought → structure
   ============================================================ */
.aha { background: var(--paper-2); }
.aha-grid {
  margin-top: clamp(40px, 6vw, 68px);
  display: grid;
  grid-template-columns: 1.02fr 0.98fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
@media (max-width: 880px) { .aha-grid { grid-template-columns: 1fr; } }

.said {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: clamp(26px, 3.4vw, 40px);
  box-shadow: 0 24px 60px -38px rgba(40,35,20,.45);
}
.said .label {
  font-family: var(--mono);
  font-size: 0.74rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--mute);
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 18px;
}
.said .label::before {
  content: ''; width: 8px; height: 8px; border-radius: 50%;
  background: var(--red); flex: none;
}
.said blockquote {
  margin: 0;
  font-size: clamp(1.3rem, 2.5vw, 1.85rem);
  line-height: 1.34;
  font-weight: 500;
  letter-spacing: -0.02em;
}
.said blockquote .hl {
  background: linear-gradient(transparent 62%, color-mix(in srgb, var(--green) 26%, transparent) 0);
  border-radius: 2px;
  transition: background .5s ease;
}

.entities {
  display: flex;
  flex-direction: column;
  gap: 13px;
}
.entities .label {
  font-family: var(--mono);
  font-size: 0.74rem; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--mute);
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 4px;
}
.entities .label .brand-mini { color: var(--green); font-weight: 700; letter-spacing: -0.02em; text-transform: none; font-family: var(--sans); }
.entity {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 15px 18px;
  display: flex; align-items: center; gap: 14px;
  box-shadow: 0 10px 30px -24px rgba(40,35,20,.5);
  opacity: 0; transform: translateY(14px) scale(.985);
  transition: opacity .6s ease, transform .6s cubic-bezier(.2,.7,.2,1);
}
.reveal-in .entity { opacity: 1; transform: none; }
.reveal-in .entity:nth-child(2) { transition-delay: .08s; }
.reveal-in .entity:nth-child(3) { transition-delay: .20s; }
.reveal-in .entity:nth-child(4) { transition-delay: .32s; }
.reveal-in .entity:nth-child(5) { transition-delay: .44s; }
.entity .emo {
  font-size: 1.25rem; line-height: 1; flex: none;
  width: 34px; height: 34px; display: grid; place-items: center;
  background: var(--paper-2); border-radius: 9px;
}
.entity .body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.entity .kind {
  font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.14em;
  text-transform: uppercase; color: var(--mute);
}
.entity .name { font-weight: 600; font-size: 1.04rem; letter-spacing: -0.01em; }
.entity .name .person, .entity .name .place { color: var(--green); }
.entity.link { background: color-mix(in srgb, var(--green-tint) 70%, var(--card)); border-color: color-mix(in srgb, var(--green) 22%, var(--line)); }
.entity.link .name { font-weight: 500; font-size: 0.98rem; color: var(--green-deep); }

.aha-kicker {
  margin-top: clamp(48px, 7vw, 84px);
  max-width: 40ch;
}
.aha-kicker p { font-size: clamp(1.5rem, 3.2vw, 2.4rem); font-weight: 500; letter-spacing: -0.025em; line-height: 1.18; }
.aha-kicker p .soft { color: var(--mute); }
.aha-kicker p + p { margin-top: 0.6em; }

/* ============================================================
   MANY VIEWS
   ============================================================ */
.views-grid {
  margin-top: clamp(40px, 6vw, 64px);
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}
@media (max-width: 620px) { .views-grid { grid-template-columns: 1fr; } }

.vcard {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 22px 20px;
  display: flex; flex-direction: column; gap: 18px;
  box-shadow: 0 20px 48px -36px rgba(40,35,20,.5);
}
.vcard-top { display: flex; flex-direction: column; gap: 6px; }
.vc-eyebrow { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--green); }
.vcard-top h3 { font-size: 1.4rem; letter-spacing: -0.025em; }
.vcard-top p { color: var(--ink-2); font-size: 0.95rem; line-height: 1.45; text-wrap: pretty; }

.vpreview {
  margin-top: auto;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 13px;
  padding: 16px;
  min-height: 156px;
  display: flex; flex-direction: column; justify-content: center;
}

/* timeline preview */
.tl { display: flex; flex-direction: column; }
.tl-item { display: flex; align-items: center; gap: 10px; padding: 9px 0; }
.tl-time { width: 38px; flex: none; text-align: right; font-family: var(--mono); font-size: 0.72rem; color: var(--mute); }
.tl-rail { width: 14px; flex: none; align-self: stretch; position: relative; display: flex; align-items: center; justify-content: center; }
.tl-rail::before { content: ''; position: absolute; top: 0; bottom: 0; left: 50%; transform: translateX(-50%); width: 2px; background: var(--line-strong); }
.tl-item:first-child .tl-rail::before { top: 50%; }
.tl-item:last-child .tl-rail::before { bottom: 50%; }
.tl-node { width: 9px; height: 9px; border-radius: 50%; background: var(--amber); position: relative; z-index: 1; box-shadow: 0 0 0 3px var(--paper); }
.tl-text { font-size: 0.9rem; color: var(--ink); letter-spacing: -0.01em; }

/* tasks preview */
.mtasks { display: flex; flex-direction: column; gap: 13px; }
.mtask { display: flex; align-items: center; gap: 11px; font-size: 0.92rem; color: var(--ink); letter-spacing: -0.01em; }
.mcheck { width: 19px; height: 19px; border-radius: 50%; border: 2px solid var(--line-strong); flex: none; position: relative; }
.mcheck.done { background: var(--green); border-color: var(--green); }
.mcheck.done::after { content: ''; position: absolute; left: 5px; top: 2px; width: 4px; height: 8px; border: solid var(--card); border-width: 0 2px 2px 0; transform: rotate(45deg); }
.mtask.done .ml { color: var(--mute); text-decoration: line-through; text-decoration-color: var(--line-strong); }

/* graph preview */
.vgraph { position: relative; width: 100%; height: 168px; max-width: 460px; margin: 0 auto; }
.vg-edges { position: absolute; inset: 0; width: 100%; height: 100%; }
.vg-edges line { stroke: color-mix(in srgb, var(--green) 42%, var(--line-strong)); stroke-width: 1.5; }
.vg-edges line.strong { stroke: color-mix(in srgb, var(--green) 42%, var(--line-strong)); stroke-width: 1.5; }
.vg-node {
  position: absolute; transform: translate(-50%, -50%);
  width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center; font-size: 1.15rem;
  background: var(--card); border: 1.5px solid var(--line-strong);
  box-shadow: 0 8px 18px -12px rgba(40,35,20,.6);
}
.vg-node.you { background: var(--ink); color: var(--paper); border-color: var(--ink); font-size: 0.72rem; font-weight: 700; letter-spacing: -0.02em; }
.vg-node.person { border-color: var(--green); background: color-mix(in srgb, var(--green) 12%, var(--card)); }
.vg-node.goal, .vg-node.thing { border-color: var(--amber); background: color-mix(in srgb, var(--amber) 12%, var(--card)); }
.vg-node.property { border-color: var(--green-deep); background: color-mix(in srgb, var(--green) 18%, var(--card)); width: 48px; height: 48px; font-size: 1.3rem; box-shadow: 0 10px 22px -12px var(--green); }

/* entity preview */
.vent { display: flex; flex-direction: column; gap: 14px; width: 100%; }
.vent-head { display: flex; align-items: center; gap: 12px; }
.vent-avatar { width: 44px; height: 44px; border-radius: 50%; flex: none; display: grid; place-items: center; font-size: 1.25rem; background: color-mix(in srgb, var(--green) 12%, var(--card)); border: 1.5px solid var(--green); }
.vent-avatar.property { background: color-mix(in srgb, var(--green) 18%, var(--card)); border-color: var(--green-deep); }
.vent-id { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.vent-name { font-weight: 600; font-size: 1.08rem; letter-spacing: -0.015em; color: var(--green-deep); }
.vent-role { font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mute); }
.vent-facts { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.vfact { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.vfact:last-child { border-bottom: 0; padding-bottom: 0; }
.fk { font-family: var(--mono); font-size: 0.62rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mute); flex: none; }
.fv { color: var(--ink); font-size: 0.82rem; font-weight: 500; text-align: right; letter-spacing: -0.01em; }

/* ============================================================
   OLD WAY vs TOPSHEET
   ============================================================ */
.contrast-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: 20px;
  overflow: hidden;
}
@media (max-width: 760px) { .contrast-grid { grid-template-columns: 1fr; } }
.contrast-col { padding: clamp(30px, 4vw, 52px); background: var(--paper); }
.contrast-col.them { background: var(--paper); }
.contrast-col.us { background: var(--ink); color: var(--paper); }
.contrast-col .eyebrow { display: block; margin-bottom: 18px; }
.contrast-col.us .eyebrow { color: color-mix(in srgb, var(--paper) 64%, transparent); }
.contrast-col h3 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); letter-spacing: -0.025em; margin-bottom: 22px; }
.contrast-col.us h3 .accent { color: color-mix(in srgb, var(--green) 42%, #fff); }
.contrast-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 13px; }
.contrast-list li { display: flex; gap: 12px; font-size: 1.04rem; color: var(--ink-2); }
.contrast-col.us .contrast-list li { color: color-mix(in srgb, var(--paper) 80%, transparent); }
.contrast-list li .mk { font-family: var(--mono); flex: none; color: var(--mute); }
.contrast-col.us .contrast-list li .mk { color: color-mix(in srgb, var(--green) 42%, #fff); }
.contrast-col .punch { margin-top: 26px; font-size: 1.18rem; font-weight: 600; letter-spacing: -0.02em; color: var(--ink); }
.contrast-col.us .punch { color: var(--paper); }

/* ============================================================
   WHY TOPSHEET
   ============================================================ */
.why { background: var(--green); color: #EAF1E6; }
.why .wrap { display: grid; grid-template-columns: 0.85fr 1.15fr; gap: clamp(28px, 5vw, 64px); align-items: start; }
@media (max-width: 820px) { .why .wrap { grid-template-columns: 1fr; } }
.why .eyebrow { color: color-mix(in srgb, #fff 60%, transparent); }
.why h2 { color: #fff; font-size: clamp(2rem, 4.2vw, 3.1rem); letter-spacing: -0.03em; }
.why p { color: #DCE7D6; font-size: clamp(1.12rem, 1.7vw, 1.4rem); line-height: 1.5; }
.why p + p { margin-top: 1em; }
.why p b { color: #fff; font-weight: 600; }

/* ============================================================
   CLOSING
   ============================================================ */
.closing { text-align: center; padding: clamp(80px, 12vw, 150px) 0; }
.closing h2 {
  font-size: clamp(2.4rem, 5.6vw, 4.6rem);
  letter-spacing: -0.035em;
  max-width: 16ch; margin: 0 auto;
}
.closing h2 .accent { color: var(--green); }
.closing .just {
  margin-top: 30px;
  font-family: var(--mono);
  font-size: 1.05rem; letter-spacing: 0.04em; color: var(--ink-2);
}
.closing .hero-cta { margin-top: 30px; }

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  border-top: 1px solid var(--line);
  padding: 40px 0 56px;
}
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer .brand { font-size: 1.1rem; }
.footer .fcopy { font-family: var(--mono); font-size: 0.76rem; color: var(--mute); letter-spacing: 0.03em; }
.footer .flegal { font-family: var(--mono); font-size: 0.76rem; letter-spacing: 0.03em; color: var(--mute); }
.footer .flegal a { color: var(--ink-2); text-decoration: none; transition: color .2s ease; }
.footer .flegal a:hover { color: var(--green-deep, var(--green)); }

/* ============================================================
   SCROLL REVEAL
   ============================================================ */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1); }
.reveal.reveal-in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: .08s; }
.reveal.d2 { transition-delay: .16s; }
.reveal.d3 { transition-delay: .24s; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal, .entity { opacity: 1 !important; transform: none !important; transition: none !important; }
  .record::before, .record::after, .waveform i, .talk-line .caret { animation: none !important; }
}

body.no-motion .reveal, body.no-motion .entity { opacity: 1 !important; transform: none !important; transition: none !important; }
body.no-motion .record::before, body.no-motion .record::after, body.no-motion .waveform i, body.no-motion .talk-line .caret { animation: none !important; }
body.no-motion { scroll-behavior: auto; }

/* ============================================================
   TWEAKS PANEL
   ============================================================ */
#tweaks { display: none; }
#tweaks.on {
  display: block;
  position: fixed;
  right: 18px; bottom: 18px;
  z-index: 1000;
  width: 290px;
  background: var(--card);
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  box-shadow: 0 30px 70px -24px rgba(30,25,12,.5);
  font-family: var(--sans);
  overflow: hidden;
}
.tw-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 13px 15px;
  border-bottom: 1px solid var(--line);
  cursor: grab;
}
.tw-head .t { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ink); }
.tw-x { border: none; background: none; cursor: pointer; color: var(--mute); font-size: 1.1rem; line-height: 1; padding: 2px 4px; border-radius: 6px; }
.tw-x:hover { color: var(--ink); background: var(--paper-2); }
.tw-body { padding: 15px; display: flex; flex-direction: column; gap: 17px; max-height: 70vh; overflow-y: auto; }
.tw-field { display: flex; flex-direction: column; gap: 9px; }
.tw-label { font-family: var(--mono); font-size: 0.66rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--mute); }
.tw-swatches { display: flex; gap: 9px; }
.tw-sw { width: 30px; height: 30px; border-radius: 9px; border: 2px solid transparent; cursor: pointer; padding: 0; outline: 2px solid var(--line); outline-offset: -2px; transition: transform .12s ease; }
.tw-sw:hover { transform: scale(1.08); }
.tw-sw.sel { border-color: var(--card); outline-color: var(--ink); }
.tw-seg { display: flex; gap: 6px; flex-wrap: wrap; }
.tw-opt { font-family: var(--sans); font-size: 0.82rem; font-weight: 500; padding: 7px 11px; border-radius: 9px; border: 1px solid var(--line-strong); background: var(--paper); color: var(--ink-2); cursor: pointer; transition: all .15s ease; }
.tw-opt:hover { border-color: var(--ink); }
.tw-opt.sel { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.tw-toggle { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.tw-switch { width: 42px; height: 24px; border-radius: 999px; background: var(--line-strong); border: none; cursor: pointer; position: relative; transition: background .2s ease; flex: none; }
.tw-switch.on { background: var(--green); }
.tw-switch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform .2s ease; box-shadow: 0 1px 3px rgba(0,0,0,.3); }
.tw-switch.on::after { transform: translateX(18px); }

/* ============================================================
   LIVE CAPTURE STAGE  (hero)
   ============================================================ */
.stage {
  height: 100vh;
  height: calc(100svh - var(--nav-h, 76px));
  min-height: 460px;
  display: flex;
  flex-direction: column;
  /* clearance for the re-added scroll cue below the record button's ripple */
  padding-bottom: clamp(72px, 10vh, 116px);
  position: relative;
  overflow: hidden;
}
/* soft glow rising from the mic */
.stage::after {
  content: '';
  position: absolute;
  left: 50%; bottom: -8%;
  width: min(720px, 90vw); height: 360px;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at center, color-mix(in srgb, var(--green) 12%, transparent), transparent 70%);
  pointer-events: none; z-index: 0;
}

.stage-bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding-top: 20px; padding-bottom: 8px;
  position: relative; z-index: 2;
}
.live {
  font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--ink-2);
  display: inline-flex; align-items: center; gap: 9px;
}
.rec-dot {
  width: 9px; height: 9px; border-radius: 50%; background: var(--red); flex: none;
  animation: recpulse 1.7s ease-in-out infinite;
}
@keyframes recpulse {
  0%, 100% { opacity: 1;  box-shadow: 0 0 0 0 color-mix(in srgb, var(--red) 55%, transparent); }
  60%      { opacity: .45; box-shadow: 0 0 0 7px transparent; }
}

/* ---------- scroll cue (re-added; anchored to the viewport-fit hero) ---------- */
.scroll-cue {
  position: absolute; left: 50%; bottom: clamp(14px, 2.4vh, 28px);
  transform: translateX(-50%);
  display: inline-flex; flex-direction: column; align-items: center; gap: 6px;
  background: none; border: none; cursor: pointer; padding: 8px 14px;
  color: var(--ink-2); opacity: .65; z-index: 2;
  font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.22em;
  text-transform: uppercase;
  transition: opacity .25s ease;
}
.scroll-cue:hover { opacity: 1; }
.scroll-cue svg { width: 16px; height: 16px; animation: cueBob 2.4s ease-in-out infinite; }
@keyframes cueBob {
  0%, 100% { transform: translateY(0); opacity: .7; }
  55%      { transform: translateY(6px); opacity: 1; }
}
body.no-motion .scroll-cue svg { animation: none !important; }
@media (prefers-reduced-motion: reduce) { .scroll-cue svg { animation: none !important; } }

.mode-toggle {
  display: inline-flex; background: var(--paper-2);
  border: 1px solid var(--line); border-radius: 12px; padding: 4px; gap: 3px;
}
.mode-opt {
  font-family: var(--sans); font-size: 0.84rem; font-weight: 600; letter-spacing: -0.01em;
  padding: 7px 14px; border: none; background: transparent; color: var(--ink-2);
  border-radius: 8px; cursor: pointer; transition: background .25s ease, color .25s ease;
  white-space: nowrap;
}
.mode-opt.sel { background: var(--ink); color: var(--paper); }

/* ---- the carousel that fills the space above the mic ---- */
.carousel {
  flex: 1 1 0; position: relative;
  min-height: 160px;
  margin: clamp(10px, 2vh, 22px) var(--pad) 0;
  z-index: 1;
}
.card {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 30px 0 8px;
  opacity: 0; transform: translateY(20px) scale(.975);
  pointer-events: none;
}
.card.show {
  opacity: 1; transform: none; pointer-events: auto;
  transition: opacity .55s ease, transform .6s cubic-bezier(.2,.8,.25,1);
}
.card-head {
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--mute);
}
.dots {
  position: absolute; bottom: -2px; left: 50%; transform: translateX(-50%);
  display: flex; gap: 7px; z-index: 4;
}
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--line-strong); transition: background .3s ease, width .3s ease; }
.dot.on { background: var(--green); width: 20px; border-radius: 4px; }
.graph-inner { position: absolute; inset: 0; }

/* ---- ENTITY CARDS (task / person / timeline) ---- */
.entity-card {
  background: var(--card); border: 1px solid var(--line); border-radius: 17px;
  box-shadow: 0 22px 50px -32px rgba(40,35,20,.62);
  padding: 19px 22px; display: flex; gap: 16px; align-items: flex-start;
  width: min(440px, 100%);
}
.task-entity .task-title { font-size: 1.18rem; }
.person-entity, .when-entity { align-items: center; }
.avatar {
  width: 54px; height: 54px; border-radius: 50%; flex: none;
  display: grid; place-items: center; font-size: 1.5rem;
  background: color-mix(in srgb, var(--green) 12%, var(--card)); border: 1.5px solid var(--green);
}
.when-cal { border-radius: 14px; background: color-mix(in srgb, var(--amber) 14%, var(--card)); border-color: var(--amber); }
.person-main { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.person-name { font-weight: 600; font-size: 1.22rem; letter-spacing: -0.015em; color: var(--green-deep); }
.when-entity .person-name { color: var(--amber); }
.person-role { font-family: var(--mono); font-size: 0.68rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--mute); white-space: normal; overflow-wrap: anywhere; }
.person-main { flex: 1; min-width: 0; }
.task-check { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line-strong); flex: none; margin-top: 1px; }
.task-main { display: flex; flex-direction: column; gap: 9px; min-width: 0; flex: 1; }
.task-title { font-weight: 600; font-size: 1.08rem; letter-spacing: -0.012em; }
.task-meta { display: flex; flex-wrap: wrap; gap: 7px; align-items: center; }
.chip {
  font-family: var(--mono); font-size: 0.64rem; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 3px 9px; border-radius: 7px; display: inline-flex; align-items: center; gap: 6px;
  font-weight: 500;
}
.chip .cdot { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.chip.person, .chip.place, .chip.goal { background: color-mix(in srgb, var(--green) 14%, var(--card)); color: var(--green-deep); }
.chip.when { background: color-mix(in srgb, var(--amber) 16%, var(--card)); color: var(--amber); }
.task-emoji { font-size: 1rem; }

/* ---- KNOWLEDGE GRAPH ---- */
.graph-edges, .graph-nodes {
  position: absolute; left: 0; top: 0; overflow: visible;
  transform-origin: 0 0;
  transition: transform .8s cubic-bezier(.4,0,.2,1);
}
.graph-nodes { pointer-events: none; }
.graph-edges line {
  stroke: color-mix(in srgb, var(--green) 42%, var(--line-strong)); stroke-width: 1.5;
  stroke-dasharray: var(--len); stroke-dashoffset: var(--len);
  transition: stroke-dashoffset .8s cubic-bezier(.4,0,.2,1);
}
.graph-edges line.drawn { stroke-dashoffset: 0; }
.graph-edges line.strong { stroke: color-mix(in srgb, var(--green) 42%, var(--line-strong)); stroke-width: 1.5; }

.gnode2 {
  position: absolute;
  transform: translate(-50%, -50%) scale(.3);
  opacity: 0; transition: opacity .5s ease, transform .6s cubic-bezier(.2,.9,.3,1.1);
}
.gnode2.in { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.gnode2 .disc {
  width: 56px; height: 56px; border-radius: 50%;
  display: grid; place-items: center; font-size: 1.45rem;
  background: var(--card); border: 1.5px solid var(--line-strong);
  box-shadow: 0 14px 32px -18px rgba(40,35,20,.65);
}
.gnode2 .glabel {
  position: absolute; top: calc(100% + 9px); left: 50%; transform: translateX(-50%);
  display: flex; flex-direction: column; align-items: center; gap: 1px;
  width: max-content;
}
.gnode2 .gname { font-weight: 600; font-size: 0.92rem; letter-spacing: -0.01em; color: var(--ink); white-space: nowrap; }
.gnode2 .grole { font-family: var(--mono); font-size: 0.6rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--mute); }
.gnode2.person  .disc { border-color: var(--green); background: color-mix(in srgb, var(--green) 12%, var(--card)); }
.gnode2.place   .disc { border-color: var(--amber); background: color-mix(in srgb, var(--amber) 12%, var(--card)); }
.gnode2.goal    .disc { border-color: var(--amber); background: color-mix(in srgb, var(--amber) 12%, var(--card)); }
.gnode2.project .disc { border-color: var(--green-deep); background: color-mix(in srgb, var(--green) 16%, var(--card)); }
.gnode2.thing .disc { border-color: var(--amber); background: color-mix(in srgb, var(--amber) 12%, var(--card)); }
.gnode2.property .disc { border-color: var(--green-deep); background: color-mix(in srgb, var(--green) 18%, var(--card)); width: 64px; height: 64px; font-size: 1.6rem; box-shadow: 0 16px 34px -16px var(--green); }
.gnode2.you .disc {
  width: 66px; height: 66px; background: var(--ink); border-color: var(--ink); color: var(--paper);
  font-size: 1.05rem; font-weight: 700; letter-spacing: -0.02em;
}
.gnode2.you .gname { font-size: 1rem; }

/* ---- CAPTURE (mic) ZONE ---- */
.stage .record { width: 76px; height: 76px; box-shadow: 0 16px 38px -16px rgba(226,59,46,.7); }
.stage .record svg { width: 30px; height: 30px; }
.capture {
  display: flex; flex-direction: column; align-items: center; gap: 14px;
  padding-top: clamp(6px, 1.6vh, 16px); position: relative; z-index: 2;
}
.transcript {
  min-height: 2.4em; max-height: 4em; overflow: hidden;
  max-width: 26ch; text-align: center;
  font-size: clamp(1.15rem, 2.6vw, 1.9rem); font-weight: 500;
  letter-spacing: -0.02em; line-height: 1.22; color: var(--ink);
}
.transcript .caret {
  display: inline-block; width: 2px; height: 1.02em; background: var(--green);
  margin-left: 3px; vertical-align: -0.16em; animation: blink 1s steps(1) infinite;
}
.transcript:empty::before { content: '\00a0'; }
.mic-row { display: flex; align-items: center; gap: clamp(14px, 3vw, 26px); }
.wave { display: flex; align-items: center; gap: 4px; height: 36px; }
.wave i { display: block; width: 4px; border-radius: 4px; background: var(--ink); opacity: .62; animation: wave 1s ease-in-out infinite; }
.capture-hint { font-family: var(--mono); font-size: 0.82rem; letter-spacing: 0.04em; color: var(--ink-2); }
.capture-hint b { color: var(--ink); font-weight: 600; }

/* ---- PAYOFF ---- */
.payoff {
  text-align: center;
  padding: clamp(80px, 14vw, 170px) var(--pad) clamp(64px, 10vw, 120px);
  background: var(--paper-2);
  border-top: 1px solid var(--line);
}
.payoff-eyebrow { font-family: var(--mono); font-size: 0.76rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--mute); }
.payoff-h {
  margin: 22px auto 0; max-width: 16ch;
  font-size: clamp(2.6rem, 6.2vw, 5.2rem); letter-spacing: -0.035em; line-height: 1.02; font-weight: 600;
}
.payoff-h .accent { color: var(--green); }
.payoff-lead { max-width: 48ch; margin: 26px auto 0; font-size: clamp(1.1rem, 1.7vw, 1.38rem); line-height: 1.55; color: var(--ink-2); }
.payoff .hero-cta { margin-top: 36px; }

/* small screens: graph + cards shrink */
@media (max-width: 640px) {
  .gnode2 .disc { width: 46px; height: 46px; font-size: 1.15rem; }
  .gnode2.you .disc { width: 54px; height: 54px; }
  .gnode2 .gname { font-size: 0.8rem; }
}
@media (max-width: 560px) {
  .nav-inner { gap: 10px; }
  .nav .btn { padding: 9px 13px; font-size: 0.9rem; border-radius: 9px; }
  .brand { font-size: 1.15rem; }
  .brand .dot { width: 9px; height: 9px; }
}
@media (max-width: 440px) {
  .nav-actions .btn-ghost { display: none; }
}

body.no-motion .rec-dot, body.no-motion .wave i { animation: none !important; }
body.no-motion .transcript .caret { animation: none !important; }
body.no-motion .card.show { opacity: 1 !important; transform: none !important; transition: none !important; }
body.no-motion .graph-nodes, body.no-motion .graph-edges { transition: none !important; }
body.no-motion .gnode2 { opacity: 1 !important; transform: translate(-50%,-50%) !important; transition: none !important; }
body.no-motion .graph-edges line { stroke-dashoffset: 0 !important; transition: none !important; }
