:root {
  --ink: #14231D;
  --ink-2: #1B2F27;
  --paper: #F1ECDD;
  --paper-dim: rgba(241, 236, 221, 0.72);
  --brass: #C89544;
  --ember: #B3452C;
  --sage: #8AA396;
  --line: #33473C;

  --font-display: 'Fraunces', serif;
  --font-mono: 'IBM Plex Mono', monospace;
  --font-body: 'Inter', sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.wrap {
  max-width: 1080px;
  margin: 0 auto;
  padding: 0 1.75rem;
}

a:focus-visible, button:focus-visible {
  outline: 2px solid var(--brass);
  outline-offset: 3px;
}

/* Topbar */
.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.6rem 1.75rem;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}
.brand-lamp { width: 20px; height: 20px; color: var(--brass); }
.contact-link {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--sage);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, color 0.2s;
}
.contact-link:hover { color: var(--paper); border-color: var(--sage); }

/* Hero */
.hero { padding: 3.5rem 0 5rem; }
.hero-inner { max-width: 640px; }
.eyebrow {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.75rem;
  color: var(--sage);
  margin: 0 0 1.1rem;
}
h1 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(2.1rem, 4.6vw, 3.3rem);
  line-height: 1.16;
  margin: 0;
  color: var(--paper);
}
.lede {
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--paper-dim);
  max-width: 520px;
  margin: 1.35rem 0 0;
}

/* Ledger */
.ledger {
  position: relative;
  overflow: hidden;
  margin: 2.5rem 0 2rem;
  max-width: 460px;
  background: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 10px;
}
.ledger::before {
  content: "";
  position: absolute;
  top: 0; bottom: 0;
  width: 40%;
  background: linear-gradient(100deg, transparent, rgba(200,149,68,0.16), transparent);
  transform: translateX(-140%);
  animation: sweep 2.2s ease-out 0.5s 1;
}
.ledger-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.85rem 1.1rem;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.92rem;
}
.ledger-row:last-child { border-bottom: none; }
.ledger-label { color: var(--sage); flex: 1; }
.ledger-value { color: var(--paper); font-weight: 500; font-variant-numeric: tabular-nums; }
.ledger-row.flag { background: rgba(179, 69, 44, 0.1); }
.ledger-row.flag .ledger-value { color: #E39373; }
.ledger-lamp {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--ember);
  box-shadow: 0 0 0 0 rgba(179,69,44,0.6);
  animation: pulse 2.4s ease-in-out infinite;
  flex-shrink: 0;
}
.ledger-tag {
  font-size: 0.72rem;
  color: var(--ember);
  background: rgba(179,69,44,0.14);
  border: 1px solid rgba(179,69,44,0.35);
  padding: 0.18rem 0.5rem;
  border-radius: 999px;
  white-space: nowrap;
}

/* CTA */
.cta {
  display: inline-block;
  background: var(--brass);
  color: var(--ink);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  padding: 0.85rem 1.4rem;
  border-radius: 999px;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.cta:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(200,149,68,0.25); }

/* Problem */
.problem { padding: 4rem 0; border-top: 1px solid var(--line); }
.problem-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-top: 1.75rem;
}
.problem-block {
  background: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 1.5rem;
}
.problem-block h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.08rem;
  margin: 0 0 0.6rem;
}
.problem-block p {
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--paper-dim);
  margin: 0;
}

/* How it works */
.how { padding: 1rem 0 5rem; }
.steps {
  list-style: none;
  margin: 1.75rem 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.75rem;
}
.steps li { display: flex; flex-direction: column; gap: 0.6rem; }
.step-index {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--brass);
  border: 1px solid var(--line);
  width: 26px; height: 26px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
}
.steps h3 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.05rem;
  margin: 0;
}
.steps p {
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--paper-dim);
  margin: 0;
}

/* Footer */
.footer { border-top: 1px solid var(--line); padding: 1.6rem 0; }
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  font-size: 0.82rem;
  color: var(--sage);
}
.footer-inner a { text-decoration: none; color: var(--sage); border-bottom: 1px solid transparent; }
.footer-inner a:hover { color: var(--paper); border-color: var(--sage); }

/* Privacy page reuse */
.legal { padding: 3rem 0 5rem; max-width: 720px; margin: 0 auto; }
.legal h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); margin-bottom: 0.5rem; }
.legal h2 {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 1.2rem;
  margin: 2.2rem 0 0.6rem;
}
.legal p, .legal li {
  font-size: 0.95rem;
  line-height: 1.7;
  color: var(--paper-dim);
}
.legal .updated {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--sage);
  margin-top: 0.5rem;
}

@keyframes sweep {
  to { transform: translateX(280%); }
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(179,69,44,0.55); }
  50% { box-shadow: 0 0 0 6px rgba(179,69,44,0); }
}

@media (prefers-reduced-motion: reduce) {
  .ledger::before { animation: none; display: none; }
  .ledger-lamp { animation: none; }
  html { scroll-behavior: auto; }
}

@media (max-width: 760px) {
  .problem-grid, .steps { grid-template-columns: 1fr; }
  .hero { padding: 2.5rem 0 3.5rem; }
}
