/* ClearNotation Landing Page — Design System */

:root {
  --cn-bg: #fefdf5;
  --cn-fg: #111;
  --cn-accent: #5f8c6b;
  --cn-accent-hover: #4a7356;
  --cn-surface: #f5f5f0;
  --cn-border: #d6d3d1;
  --cn-muted: #78716c;
  --cn-code-bg: #f5f5f0;

  --cn-radius-sm: 4px;
  --cn-radius-md: 8px;
  --cn-radius-lg: 12px;

  --cn-max-width: 1024px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  background: var(--cn-bg);
  color: var(--cn-fg);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── Layout ─────────────────────────────────────────────── */

.container {
  width: 100%;
  max-width: var(--cn-max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Nav ─────────────────────────────────────────────────── */

.nav {
  border-bottom: 1px solid var(--cn-border);
  padding: 0 24px;
  background: #5f8c6b;
}

.nav-inner {
  max-width: var(--cn-max-width);
  margin: 0 auto;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: "Geist Mono", monospace;
  font-weight: 600;
  font-size: 15px;
  color: #ffffff;
  text-decoration: none;
  letter-spacing: 0;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 24px;
  list-style: none;
}

.nav-links a {
  font-family: "Geist Sans", sans-serif;
  font-size: 14px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 100ms ease-out;
}

.nav-links a:hover {
  color: #ffffff;
}

/* ── Hero ─────────────────────────────────────────────────── */

.hero {
  padding: 80px 24px 64px;
  text-align: center;
  border-bottom: 1px solid var(--cn-border);
  background: linear-gradient(180deg, var(--cn-bg) 0%, #f3f0e8 100%);
}

.hero-inner {
  max-width: 640px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-block;
  font-family: "Geist Sans", sans-serif;
  font-size: 12px;
  font-weight: 500;
  color: var(--cn-accent);
  border: 1px solid var(--cn-accent);
  border-radius: var(--cn-radius-sm);
  padding: 2px 8px;
  margin-bottom: 24px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hero h1 {
  font-family: "Geist Sans", sans-serif;
  font-weight: 600;
  font-size: 48px;
  line-height: 1.1;
  letter-spacing: -0.03em;
  color: var(--cn-fg);
  margin-bottom: 16px;
}

.hero-tagline {
  font-family: "Geist Sans", sans-serif;
  font-weight: 600;
  font-size: 20px;
  color: var(--cn-muted);
  margin-bottom: 16px;
  letter-spacing: -0.01em;
}

.hero-description {
  font-size: 16px;
  color: var(--cn-muted);
  max-width: 520px;
  margin: 0 auto 32px;
  line-height: 1.65;
}

.hero-ctas {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}

/* ── Buttons ─────────────────────────────────────────────── */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: "Geist Sans", sans-serif;
  font-size: 14px;
  font-weight: 500;
  padding: 8px 16px;
  border-radius: var(--cn-radius-sm);
  border: 1px solid transparent;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 100ms ease-out, border-color 100ms ease-out, color 100ms ease-out;
  white-space: nowrap;
}

.btn-primary {
  background: var(--cn-accent);
  color: #ffffff;
  border-color: var(--cn-accent);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
}

.btn-primary:hover {
  background: var(--cn-accent-hover);
  border-color: var(--cn-accent-hover);
}

.btn-secondary {
  background: var(--cn-bg);
  color: var(--cn-fg);
  border-color: var(--cn-border);
}

.btn-secondary:hover {
  border-color: var(--cn-accent);
  color: var(--cn-accent);
}

/* ── Sections ────────────────────────────────────────────── */

.section {
  padding: 64px 24px;
  border-bottom: 1px solid var(--cn-border);
}

.section:last-of-type {
  border-bottom: none;
}

.section-label {
  font-family: "Geist Mono", monospace;
  font-size: 11px;
  font-weight: 500;
  color: var(--cn-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}

.section-title {
  font-family: "Geist Sans", sans-serif;
  font-weight: 600;
  font-size: 28px;
  letter-spacing: -0.02em;
  color: var(--cn-fg);
  margin-bottom: 8px;
}

.section-subtitle {
  font-size: 15px;
  color: var(--cn-muted);
  margin-bottom: 40px;
  max-width: 480px;
}

/* ── Comparison ──────────────────────────────────────────── */

.comparison {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

.comparison-col {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--cn-border);
  border-radius: var(--cn-radius-md);
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.comparison-col:first-child {
  border-left: 3px solid var(--cn-accent);
}

.comparison-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  background: var(--cn-surface);
  border-bottom: 1px solid var(--cn-border);
}

.comparison-header-label {
  font-family: "Geist Sans", sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: var(--cn-fg);
}

.comparison-header-ext {
  font-family: "Geist Mono", monospace;
  font-size: 11px;
  color: var(--cn-muted);
  margin-left: auto;
}

.comparison-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cn-border);
  flex-shrink: 0;
}

.comparison-dot.accent {
  background: var(--cn-accent);
}

pre.comparison-code {
  margin: 0;
  padding: 20px;
  background: var(--cn-code-bg);
  overflow-x: auto;
  flex: 1;
}

code.comparison-code {
  font-family: "Geist Mono", monospace;
  font-size: 13px;
  line-height: 1.7;
  color: var(--cn-fg);
  white-space: pre;
}

.token-key     { color: #5f8c6b; }
.token-string  { color: #92400e; }
.token-comment { color: #a8a29e; font-style: italic; }
.token-punct   { color: #78716c; }

/* ── Install Cards ───────────────────────────────────────── */

.install-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.install-card {
  border: 1px solid var(--cn-border);
  border-radius: var(--cn-radius-md);
  padding: 24px;
  background: var(--cn-bg);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.install-card-icon {
  font-size: 20px;
  margin-bottom: 12px;
  display: block;
}

.install-card-title {
  font-family: "Geist Sans", sans-serif;
  font-weight: 600;
  font-size: 14px;
  color: var(--cn-fg);
  margin-bottom: 4px;
}

.install-card-subtitle {
  font-size: 13px;
  color: var(--cn-muted);
  margin-bottom: 16px;
}

.install-cmd {
  display: flex;
  align-items: center;
  background: var(--cn-code-bg);
  border: 1px solid var(--cn-border);
  border-radius: var(--cn-radius-sm);
  padding: 8px 12px;
  gap: 8px;
}

.install-cmd code {
  font-family: "Geist Mono", monospace;
  font-size: 12px;
  color: var(--cn-fg);
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.copy-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--cn-muted);
  padding: 0;
  display: flex;
  align-items: center;
  flex-shrink: 0;
  transition: color 100ms ease-out;
}

.copy-btn:hover {
  color: var(--cn-fg);
}

.copy-btn svg {
  width: 14px;
  height: 14px;
  stroke: currentColor;
  stroke-width: 1.5;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ── Features strip ──────────────────────────────────────── */

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.feature-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.feature-title {
  font-family: "Geist Sans", sans-serif;
  font-weight: 600;
  font-size: 14px;
  color: var(--cn-fg);
}

.feature-desc {
  font-size: 14px;
  color: var(--cn-muted);
  line-height: 1.6;
}

/* -- Stats Row ─────────────────────────────────────────── */

.stats-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.stat-card {
  background: var(--cn-bg);
  border: 1px solid var(--cn-border);
  border-radius: 6px;
  padding: 24px;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

.stat-label {
  font-family: "Geist Mono", monospace;
  font-size: 11px;
  color: var(--cn-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.stat-headline {
  font-family: "Geist Sans", sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: var(--cn-fg);
  margin-bottom: 16px;
}

.stat-desc {
  font-size: 12px;
  color: #57534e;
  line-height: 1.5;
  margin-top: 16px;
}

.stat-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}

.stat-bar-label {
  font-family: "Geist Mono", monospace;
  font-size: 11px;
  width: 32px;
  flex-shrink: 0;
}

.stat-bar-track {
  flex: 1;
  background: #e7e5e4;
  border-radius: 2px;
  height: 22px;
  overflow: hidden;
}

.stat-bar-fill {
  height: 100%;
  border-radius: 2px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 6px;
  font-family: "Geist Mono", monospace;
  font-size: 10px;
  color: #fefdf5;
}

.stat-bar-fill.primary { background: #5f8c6b; }
.stat-bar-fill.muted   { background: #a8a29e; }

.stat-tally {
  display: flex;
  justify-content: space-around;
  text-align: center;
}

.stat-tally-num {
  font-family: "Geist Mono", monospace;
  font-size: 36px;
  font-weight: 700;
  line-height: 1;
}

.stat-tally-caption {
  font-family: "Geist Mono", monospace;
  font-size: 10px;
  margin-top: 4px;
}

.stat-tally-divider {
  width: 1px;
  background: var(--cn-border);
}

.stat-impl-grid {
  display: flex;
  gap: 12px;
}

.stat-impl-col {
  flex: 1;
  text-align: center;
}

.stat-impl-col-label {
  font-family: "Geist Mono", monospace;
  font-size: 10px;
  margin-bottom: 6px;
  font-weight: 600;
}

.stat-impl-pills {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3px;
}

.stat-impl-pill {
  padding: 5px 4px;
  border-radius: 2px;
  font-family: "Geist Mono", monospace;
  font-size: 9px;
}

.stat-impl-pill.primary { background: #5f8c6b; color: #fefdf5; }
.stat-impl-pill.muted   { background: #d6d3d1; color: #57534e; }

.stat-impl-footer {
  font-family: "Geist Mono", monospace;
  font-size: 9px;
  color: var(--cn-muted);
  margin-top: 4px;
}

/* ── Footer ──────────────────────────────────────────────── */

footer {
  margin-top: auto;
  border-top: 1px solid var(--cn-border);
  padding: 24px;
  background: #5f8c6b;
}

.footer-inner {
  max-width: var(--cn-max-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-left {
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
  font-family: "Geist Sans", sans-serif;
}

.footer-links {
  display: flex;
  gap: 16px;
  list-style: none;
}

.footer-links a {
  font-family: "Geist Sans", sans-serif;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 100ms ease-out;
}

.footer-links a:hover {
  color: #ffffff;
}

/* ── Responsive ──────────────────────────────────────────── */

@media (max-width: 768px) {
  .hero h1 {
    font-size: 32px;
  }

  .hero-tagline {
    font-size: 18px;
  }

  .comparison {
    grid-template-columns: 1fr;
  }

  .install-grid {
    grid-template-columns: 1fr;
  }

  .features-grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .stats-row {
    grid-template-columns: 1fr;
  }

  .nav-links {
    display: none;
  }

  .section-title {
    font-size: 22px;
  }
}

@media (max-width: 480px) {
  .hero {
    padding: 48px 24px 48px;
  }

  .hero h1 {
    font-size: 28px;
  }

  .section {
    padding: 48px 24px;
  }
}
