/* threadline marketing site.
   Mood: the thread that survives the night — sessions come and go, the
   knowing stays on disk. Deep indigo ground, a warm terracotta thread-strand
   accent, and the glyphs the CLI already uses (▸ ⧗ ⚠ ↳ ✓). Type: Manrope
   (display) + Fira Code. No em dashes. */

:root {
  --bg:        #0c0e22;
  --bg-2:      #10122b;
  --surface:   #151838;
  --surface-2: #1b1f47;
  --border:    #272c5c;
  --text:      #dfe1f0;
  --dim:       #8b91c0;
  --dim-2:     #565c8f;

  --active: #e8734a;   /* ▸ the thread strand, running */
  --block:  #e0707a;   /* ⚠ blocked */
  --wait:   #e5c07b;   /* ⧗ waiting on something outside this machine */
  --decide: #7ea8e0;   /* ↳ what got ruled out and why */
  --done:   #6fbf8b;   /* ✓ closed */

  --sans: 'Manrope', system-ui, -apple-system, sans-serif;
  --mono: 'Fira Code', ui-monospace, 'SF Mono', Menlo, monospace;

  --maxw: 1080px;
  --radius: 8px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  background: var(--bg);
  background-image:
    radial-gradient(860px 580px at 84% -8%, rgba(232,115,74,0.10), transparent 60%),
    radial-gradient(680px 480px at 8% 6%, rgba(126,168,224,0.08), transparent 55%);
  background-attachment: fixed;
  color: var(--text);
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
a { color: var(--active); text-decoration: none; }
a:hover { text-decoration: underline; }
code {
  font-family: var(--mono); font-size: 0.86em;
  background: var(--surface-2); padding: 1px 6px; border-radius: 4px;
  color: var(--text); white-space: nowrap;
}
.terminal code { background: transparent; padding: 0; }

.active { color: var(--active); } .block { color: var(--block); }
.wait { color: var(--wait); } .decide { color: var(--decide); } .done { color: var(--done); }
.dim { color: var(--dim); } .bright { color: var(--text); }
.bold { font-weight: 600; } .muted { color: var(--dim); }

/* ===== terminal frame ===== */
.terminal {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 30px 80px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.02) inset;
  overflow: hidden;
  font-family: var(--mono);
  color: var(--text);
}
.term-bar {
  display: flex; align-items: center; gap: 8px;
  height: 34px; padding: 0 14px;
  background: #0a0b1e;
  border-bottom: 1px solid var(--border);
}
.tl { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.tl.red { background: var(--block); } .tl.amber { background: var(--wait); } .tl.green { background: var(--done); }
.term-title { font-size: 12px; color: var(--dim-2); margin-left: auto; margin-right: auto; transform: translateX(-22px); letter-spacing: 0.03em; }
.term-spacer { margin-left: auto; }
.term-body { padding: 16px 18px; font-size: 13px; line-height: 1.7; }
.term-line { display: block; white-space: pre-wrap; }
.prompt { color: var(--active); margin-right: 7px; }
.cursor { display: inline-block; width: 8px; height: 15px; background: var(--active); vertical-align: text-bottom; margin-left: 2px; }

/* copy button */
.copy-btn {
  margin-left: auto; padding: 3px 10px; font-family: var(--mono); font-size: 11px;
  color: var(--dim); background: transparent; border: 1px solid var(--border);
  border-radius: 4px; cursor: pointer; transition: all 0.15s;
}
.copy-btn:hover { color: var(--active); border-color: var(--active); }
.copy-btn.copied { color: var(--active); border-color: var(--active); }

/* ===== nav ===== */
.nav {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 26px;
  background: rgba(12,14,34,0.82);
  backdrop-filter: saturate(1.2) blur(12px);
  border-bottom: 1px solid var(--border);
}
.wordmark { font-family: var(--sans); font-weight: 700; font-size: 17px; color: var(--text); display: inline-flex; align-items: center; gap: 9px; letter-spacing: -0.01em; }
.wordmark .pw { color: var(--active); font-size: 16px; text-shadow: 0 0 10px rgba(232,115,74,0.55); }
.nav-links { display: flex; gap: 20px; align-items: center; }
.nav-links a { font-family: var(--mono); font-size: 13px; color: var(--dim); }
.nav-links a:hover { color: var(--text); text-decoration: none; }
.github-link { color: var(--text) !important; border: 1px solid var(--border); padding: 5px 11px; border-radius: 4px; }
.github-link:hover { border-color: var(--active); color: var(--active) !important; }

/* ===== hero ===== */
.hero { position: relative; padding: 74px 26px 60px; overflow: hidden; }
.hero-inner { position: relative; z-index: 1; max-width: var(--maxw); margin: 0 auto; display: grid; grid-template-columns: 1fr 1.05fr; gap: 50px; align-items: center; }

.thread-mark { display: inline-flex; align-items: center; justify-content: center; width: 56px; height: 56px; border-radius: 50%; border: 1.5px solid rgba(232,115,74,0.5); color: var(--active); font-size: 24px; margin-bottom: 22px; box-shadow: 0 0 24px rgba(232,115,74,0.26), 0 0 60px rgba(232,115,74,0.1); }
.thread-mark.glow { animation: thread-glow 3.4s ease-in-out infinite; }
@keyframes thread-glow { 0%,100% { box-shadow: 0 0 20px rgba(232,115,74,0.2), 0 0 50px rgba(232,115,74,0.08); } 50% { box-shadow: 0 0 30px rgba(232,115,74,0.38), 0 0 80px rgba(232,115,74,0.15); } }

.eyebrow { font-family: var(--mono); font-size: 12px; font-weight: 500; text-transform: uppercase; letter-spacing: 0.16em; color: var(--dim); margin-bottom: 14px; }
.hero h1 { font-family: var(--sans); font-size: clamp(36px, 5vw, 58px); font-weight: 800; line-height: 1.06; letter-spacing: -0.03em; margin-bottom: 18px; }
.hero h1 .pt { color: var(--active); text-shadow: 0 0 30px rgba(232,115,74,0.3); }
.subhead { font-size: 18px; color: var(--dim); max-width: 48ch; margin-bottom: 24px; }

.install-block { margin-bottom: 11px; }
.install-block .term-body { padding: 13px 15px; }
.inspect-line { font-size: 13px; color: var(--dim); margin-bottom: 22px; }
.tag-row { display: flex; gap: 10px; flex-wrap: wrap; }
.tag { font-family: var(--mono); font-size: 11.5px; color: var(--dim); border: 1px solid var(--border); border-radius: 20px; padding: 4px 11px; }
.tag b { color: var(--active); font-weight: 500; }

/* ===== sections ===== */
.section { max-width: var(--maxw); margin: 0 auto; padding: 78px 26px; }
.section h2 { font-family: var(--sans); font-size: clamp(27px, 3.4vw, 38px); font-weight: 800; line-height: 1.12; letter-spacing: -0.02em; margin-bottom: 16px; max-width: 22ch; }
.lede { font-size: 18px; color: var(--dim); max-width: 64ch; margin-bottom: 36px; }
.aside { font-size: 14px; color: var(--dim); max-width: 64ch; margin-top: 22px; }
.prose { max-width: 62ch; display: flex; flex-direction: column; gap: 14px; }
.prose p { font-size: 18px; color: var(--text); }
.prose .key { color: var(--active); font-weight: 600; }
.prose blockquote { border-left: 2px solid var(--active); padding-left: 18px; color: var(--dim); font-style: italic; }
.section-tinted { background: var(--bg-2); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }

/* ===== feature grid (the three fields) ===== */
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature-card { min-width: 0; background: var(--surface); border: 1px solid var(--border); border-radius: 6px; padding: 24px; border-top: 3px solid var(--dim-2); }
.feature-card.fc-active { border-top-color: var(--active); }
.feature-card.fc-decide { border-top-color: var(--decide); }
.feature-card.fc-wait { border-top-color: var(--wait); }
.fc-head { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.fc-glyph { font-family: var(--mono); font-size: 20px; }
.feature-card.fc-active .fc-glyph { color: var(--active); }
.feature-card.fc-decide .fc-glyph { color: var(--decide); }
.feature-card.fc-wait .fc-glyph { color: var(--wait); }
.feature-card h3 { font-size: 16px; font-weight: 700; }
.feature-card p { font-size: 14px; color: var(--dim); }
.feature-card code { font-size: 12px; white-space: pre-wrap; word-break: break-word; display: inline-block; }

/* ===== checklist (design principles) ===== */
.checklist { display: flex; flex-direction: column; gap: 14px; max-width: 760px; }
.check { display: flex; gap: 16px; align-items: flex-start; padding: 20px 22px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); transition: border-color 0.15s, transform 0.15s; }
.check:hover { border-color: rgba(232,115,74,0.4); transform: translateX(3px); }
.check .box { font-family: var(--mono); color: var(--active); font-size: 16px; flex: none; margin-top: 2px; text-shadow: 0 0 8px rgba(232,115,74,0.35); }
.check h3 { font-family: var(--sans); font-size: 17px; font-weight: 700; margin-bottom: 4px; }
.check p { font-size: 14.5px; color: var(--dim); }
.check .note { font-family: var(--mono); font-size: 11.5px; color: var(--dim-2); margin-top: 7px; }

/* ===== install steps ===== */
.steps { list-style: none; max-width: 720px; display: flex; flex-direction: column; }
.steps > li { display: flex; gap: 16px; align-items: baseline; font-size: 16px; line-height: 1.6; padding: 20px 0; border-top: 1px solid var(--border); }
.steps > li:first-child { border-top: none; }
.step-num { font-family: var(--mono); font-size: 13px; color: var(--active); flex: none; width: 30px; }
.install-final { max-width: 760px; margin-bottom: 34px; }

/* ===== footer / cross-promo ===== */
.footer { border-top: 1px solid var(--border); background: var(--bg-2); padding: 50px 26px 40px; margin-top: 30px; }
.footer-inner { max-width: var(--maxw); margin: 0 auto; }
.footer-top { display: flex; justify-content: space-between; align-items: flex-start; flex-wrap: wrap; gap: 24px; margin-bottom: 38px; }
.footer .wordmark { font-size: 17px; }
.footer-tag { font-family: var(--mono); font-size: 12px; color: var(--dim); margin-top: 8px; }
.promo-h { font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--dim-2); margin-bottom: 16px; }
.promo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.promo-card { display: flex; flex-direction: column; gap: 5px; padding: 18px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); transition: border-color 0.15s, transform 0.15s; }
.promo-card:hover { border-color: rgba(232,115,74,0.45); transform: translateY(-2px); text-decoration: none; }
.promo-name { font-family: var(--mono); font-size: 14px; color: var(--text); font-weight: 500; }
.promo-name .pg { color: var(--active); margin-right: 6px; }
.promo-desc { font-size: 13px; color: var(--dim); }
.footer-note { max-width: var(--maxw); margin: 34px auto 0; font-family: var(--mono); font-size: 12px; color: var(--dim-2); }

/* ===== reveal (progressive enhancement) ===== */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.5s ease, transform 0.5s ease; }
.js .reveal.in { opacity: 1; transform: none; }

/* ===== responsive ===== */
@media (max-width: 880px) {
  .hero-inner { grid-template-columns: 1fr; gap: 38px; }
  .promo-grid, .feature-grid { grid-template-columns: 1fr; }
  .nav-links a:not(.github-link) { display: none; }
}
@media (max-width: 560px) {
  .section { padding: 54px 20px; }
  .hero { padding-top: 46px; }
}
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; transform: none !important; transition: none; }
  html { scroll-behavior: auto; }
  .thread-mark.glow { animation: none; }
  .cursor { animation: none; }
}
@keyframes soft-blink { 0%, 60% { opacity: 1; } 80%, 100% { opacity: 0.2; } }
@media (prefers-reduced-motion: no-preference) {
  .cursor.live { animation: soft-blink 1.5s steps(1) infinite; }
}
