/* LLM Time Machine — visual language:
   - Warm dark background for the hero, white for body
   - System font stack, tight display type, monospace for numbers
   - Single accent color (Qwen pink) so readers link the story visually */

:root {
  --bg: #fafafa;
  --bg-dark: #0d1117;
  --bg-accent: #1a0912;
  --fg: #1a1d23;
  --fg-dim: #555;
  --fg-faint: #888;
  --accent: #d81b60;
  --accent-soft: #ffeef4;
  --border: #e6e6e6;
  --moe-blue: #1e88e5;
  --moe-green: #43a047;
  --moe-purple: #8e24aa;
  --moe-orange: #fb8c00;
  --code: #2d333b;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica,
               Arial, sans-serif, "Apple Color Emoji";
  font-size: 16.5px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--accent); text-decoration: none; border-bottom: 1px solid transparent; }
a:hover { border-bottom-color: var(--accent); }

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3 {
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.12;
  margin: 0 0 16px 0;
}

h1 { font-size: clamp(2.2rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.7rem, 3vw, 2.6rem); margin-bottom: 18px; }
h3 { font-size: 1.25rem; }

p { margin: 0 0 16px 0; }

.eyebrow,
.section-eyebrow {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  color: var(--fg-faint);
  font-weight: 600;
  margin-bottom: 12px;
}

.accent { color: var(--accent); }

/* ---------- HERO ---------- */
.hero {
  background: linear-gradient(135deg, var(--bg-dark) 0%, var(--bg-accent) 100%);
  color: #f0f0f0;
  padding: 80px 0 100px 0;
  border-bottom: 6px solid var(--accent);
}
.hero .eyebrow { color: var(--accent); }
.hero h1 { color: #ffffff; max-width: 900px; }
.hero .lede {
  font-size: 1.2rem;
  color: #d0d4da;
  max-width: 760px;
  margin-top: 20px;
}
.hero strong { color: #fff; }

.hero-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  margin-top: 48px;
  max-width: 900px;
}
.stat {
  padding: 22px 24px;
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
}
.stat-val {
  font-family: "SF Mono", Menlo, Consolas, monospace;
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 6px;
}
.stat-label {
  font-size: 0.9rem;
  color: #b5bac1;
  line-height: 1.35;
}

/* ---------- SECTIONS ---------- */
.section {
  padding: 80px 0;
  border-bottom: 1px solid var(--border);
}
.section-dark {
  background: #f3f4f6;
}
.section-accent {
  background: var(--accent-soft);
  border-top: 4px solid var(--accent);
}

.body {
  font-size: 1.08rem;
  max-width: 760px;
  color: var(--fg-dim);
}
.body strong { color: var(--fg); }
.centered { text-align: center; margin-left: auto; margin-right: auto; }

/* ---------- CHART ---------- */
.chart-controls {
  display: flex;
  gap: 32px;
  flex-wrap: wrap;
  margin: 24px 0 18px 0;
  padding: 16px 20px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  align-items: center;
}
.control {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.92rem;
}
.control label { font-weight: 500; color: var(--fg-dim); }
.control select, .control input[type=range] {
  font-size: 0.95rem;
  padding: 6px 8px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fff;
  min-width: 180px;
}
.control input[type=range] { padding: 0; accent-color: var(--accent); }

.chart-wrap {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px;
  min-height: 480px;
  position: relative;
}
#timeline-chart { max-height: 520px; }

.insight {
  margin-top: 28px;
  padding: 22px 26px;
  background: var(--accent-soft);
  border-left: 4px solid var(--accent);
  border-radius: 0 8px 8px 0;
}
.insight p { margin: 0; color: var(--fg); }
.insight strong { color: var(--accent); }
.insight-warn {
  background: #fff8e6;
  border-left-color: #e8a500;
}
.insight-warn strong { color: #b57400; }

/* ---------- SNAPSHOTS ---------- */
.snapshot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
  margin: 40px 0;
}
.snapshot {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 28px;
}
.hero-snapshot {
  border: 2px solid var(--accent);
  box-shadow: 0 8px 30px -12px rgba(216, 27, 96, 0.35);
}
.snapshot-date {
  font-family: "SF Mono", Menlo, Consolas, monospace;
  color: var(--fg-faint);
  font-size: 0.88rem;
  margin-bottom: 8px;
}
.snapshot-model {
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 4px;
  letter-spacing: -0.02em;
}
.hero-snapshot .snapshot-model { color: var(--accent); }
.snapshot-meta {
  color: var(--fg-dim);
  font-size: 0.9rem;
  margin-bottom: 18px;
  font-family: "SF Mono", Menlo, Consolas, monospace;
}
.snapshot-scores {
  display: grid;
  gap: 8px;
  margin-bottom: 18px;
  padding: 14px 16px;
  background: #f8f8f8;
  border-radius: 8px;
}
.hero-snapshot .snapshot-scores { background: var(--accent-soft); }
.snapshot-scores > div {
  display: flex;
  justify-content: space-between;
  font-size: 0.95rem;
}
.snapshot-scores span { color: var(--fg-dim); }
.snapshot-scores strong {
  font-family: "SF Mono", Menlo, Consolas, monospace;
  font-size: 1.1rem;
  color: var(--fg);
}
.hero-snapshot .snapshot-scores strong { color: var(--accent); }
.snapshot-scores em {
  font-style: normal;
  font-family: -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 0.78rem;
  font-weight: 600;
  color: #2e7d32;
  margin-left: 4px;
  padding: 1px 6px;
  background: rgba(46, 125, 50, 0.08);
  border-radius: 4px;
  letter-spacing: 0;
}
.snapshot-note {
  font-size: 0.92rem;
  color: var(--fg-dim);
  font-style: italic;
  margin: 0;
}

/* ---------- LEVERS ---------- */
.levers {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
  margin: 36px 0;
}
.lever {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 24px;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.lever:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px -15px rgba(0,0,0,0.25);
}
.lever-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px; height: 36px;
  background: var(--accent);
  color: #fff;
  border-radius: 50%;
  font-family: "SF Mono", Menlo, Consolas, monospace;
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 14px;
}
.lever h3 {
  margin-bottom: 10px;
  color: var(--fg);
}
.lever p {
  font-size: 0.96rem;
  color: var(--fg-dim);
  margin: 0;
}

/* ---------- FIGURE ---------- */
.figure {
  display: block;
  max-width: 100%;
  margin: 28px auto;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #fff;
}

/* ---------- PROJECTIONS ---------- */
.projection-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
  margin: 36px 0;
}
.projection {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 28px;
  border-top: 4px dashed var(--accent);
}
.proj-date {
  font-family: "SF Mono", Menlo, Consolas, monospace;
  color: var(--accent);
  font-size: 0.9rem;
  margin-bottom: 6px;
  font-weight: 600;
}
.projection h3 {
  margin-bottom: 18px;
  font-size: 1.2rem;
}
.projection ul {
  margin: 0;
  padding-left: 0;
  list-style: none;
}
.projection li {
  padding: 8px 0;
  border-bottom: 1px solid #f0f0f0;
  font-size: 0.95rem;
  color: var(--fg-dim);
}
.projection li:last-child { border-bottom: 0; }
.projection li strong {
  color: var(--fg);
  font-family: "SF Mono", Menlo, Consolas, monospace;
}

/* ---------- TAKEAWAYS ---------- */
.takeaways {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  margin-top: 32px;
}
.takeaway {
  background: #fff;
  border: 1px solid rgba(216, 27, 96, 0.15);
  border-radius: 10px;
  padding: 24px;
}
.takeaway h3 {
  color: var(--accent);
  font-size: 1.1rem;
  margin-bottom: 10px;
}
.takeaway p {
  font-size: 0.95rem;
  color: var(--fg-dim);
  margin: 0;
}

/* ---------- FOOTER ---------- */
footer {
  background: var(--bg-dark);
  color: #9da5b4;
  padding: 48px 0 64px 0;
  font-size: 0.9rem;
}
footer p { max-width: 780px; margin-bottom: 12px; }
footer a { color: #f0f0f0; border-bottom: 1px solid rgba(255,255,255,0.3); }
footer a:hover { border-bottom-color: var(--accent); }
.credit { color: var(--fg-faint); margin-top: 20px; }

/* ---------- MOBILE ---------- */
@media (max-width: 720px) {
  .hero { padding: 60px 0 70px 0; }
  .section { padding: 56px 0; }
  .chart-controls { flex-direction: column; align-items: stretch; gap: 16px; }
  .control select, .control input[type=range] { min-width: auto; width: 100%; }
  .hero-stats { grid-template-columns: 1fr; }
  body { font-size: 16px; }
}
