/* Store “ledger cut” — unique identity (not sage/lime fintech templates) */
:root {
  --ink: #141a17;
  --ink-soft: #3a433e;
  --muted: #5e6a63;
  --line: rgba(20, 26, 23, 0.12);
  --line-strong: rgba(20, 26, 23, 0.18);
  --paper: #f2f0eb;
  --paper-deep: #e6e3db;
  --surface: #fbfaf7;
  --forest: #083028;
  --forest-mid: #0f4a3c;
  --forest-lift: #1a6351;
  --copper: #b8895a;
  --copper-soft: rgba(184, 137, 90, 0.18);
  --accent: var(--forest);
  --accent-ink: #f4f7f5;
  --brand: "Source Serif 4", Georgia, serif;
  --display: "Syne", "Source Sans 3", system-ui, sans-serif;
  --serif-body: "Literata", Georgia, serif;
  --sans: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --radius: 3px;
  --max: 1080px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
}

.site {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-image:
    linear-gradient(var(--line) 1px, transparent 1px),
    linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 72px 72px;
  background-position: -1px -1px;
}

/* logo */
.brand-mark {
  display: inline-block;
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 1px;
  background: linear-gradient(145deg, var(--forest) 0%, var(--forest-lift) 50%, var(--copper) 140%);
  box-shadow: 0 0 0 3px var(--copper-soft);
  flex-shrink: 0;
}

.brand-mark-lg {
  width: 0.9rem;
  height: 0.9rem;
  box-shadow: 0 0 0 4px rgba(184, 137, 90, 0.28);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--brand);
  font-size: 1.28rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-decoration: none;
  color: var(--ink);
}

/* masthead */
.mast {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1rem clamp(1.15rem, 3vw, 2rem);
  border-bottom: 1px solid var(--line-strong);
  background: rgba(251, 250, 247, 0.92);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 20;
}

.mast-nav {
  display: flex;
  gap: 1.35rem;
  margin-left: auto;
  margin-right: 0.25rem;
}

.mast-nav a {
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--muted);
}

.mast-nav a:hover {
  color: var(--forest);
}

/* buttons — rectangular, never pills */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-family: var(--sans);
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-decoration: none;
  padding: 0.72rem 1.2rem;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn-solid {
  background: var(--forest);
  color: var(--accent-ink);
  border-color: var(--forest);
}

.btn-solid:hover {
  background: var(--forest-mid);
  border-color: var(--forest-mid);
}

.btn-light {
  background: var(--paper);
  color: var(--forest);
  border-color: var(--paper);
}

.btn-light:hover {
  background: #fff;
}

.btn-ghost-light {
  background: transparent;
  color: rgba(251, 250, 247, 0.92);
  border-color: rgba(251, 250, 247, 0.35);
}

.btn-ghost-light:hover {
  border-color: #fff;
  color: #fff;
}

/* —— First viewport: full-bleed forest cut + thin ledger rail —— */
.hero-cut {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(12rem, 0.55fr);
  min-height: calc(100svh - 4.2rem);
  border-bottom: 1px solid var(--line-strong);
}

.hero-slab {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(15rem, 0.95fr);
  align-items: end;
  gap: clamp(1.5rem, 3vw, 2.5rem);
  padding: clamp(2.5rem, 8vh, 4.5rem) clamp(1.35rem, 4vw, 3rem);
  background:
    linear-gradient(160deg, rgba(184, 137, 90, 0.14) 0%, transparent 42%),
    linear-gradient(200deg, var(--forest-mid) 0%, var(--forest) 55%, #041914 100%);
  color: #f4f7f5;
  overflow: hidden;
  animation: slab-in 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.hero-slab::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    -18deg,
    transparent,
    transparent 11px,
    rgba(251, 250, 247, 0.03) 11px,
    rgba(251, 250, 247, 0.03) 12px
  );
  pointer-events: none;
}

.hero-slab > * {
  position: relative;
  z-index: 1;
}

.hero-copy {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-width: 0;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin: 0 0 1.35rem;
  font-family: var(--brand);
  font-size: clamp(2.4rem, 6vw, 3.4rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  color: #fff;
}

.hero-slab h1 {
  margin: 0 0 1rem;
  max-width: 12ch;
  font-family: var(--display);
  font-size: clamp(2rem, 4.8vw, 3.2rem);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.035em;
  color: #fff;
}

.lede {
  margin: 0 0 1.85rem;
  max-width: 34ch;
  font-family: var(--serif-body);
  font-size: 1.08rem;
  line-height: 1.55;
  color: rgba(244, 247, 245, 0.78);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

/* Hero analytical figure — budget credit + outlay, part of the forest plane */
.hero-viz {
  margin: 0;
  width: 100%;
  max-width: 26rem;
  justify-self: end;
  align-self: center;
  animation: viz-in 0.9s cubic-bezier(0.22, 1, 0.36, 1) 0.15s both;
}

.viz-svg {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 18px 40px rgba(0, 0, 0, 0.28));
}

.viz-frame {
  fill: rgba(4, 25, 20, 0.45);
  stroke: rgba(251, 250, 247, 0.16);
  stroke-width: 1;
}

.viz-kicker {
  fill: var(--copper);
  font-family: var(--display), system-ui, sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.viz-value {
  fill: #fff;
  font-family: var(--display), system-ui, sans-serif;
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.viz-sub {
  fill: rgba(244, 247, 245, 0.62);
  font-family: var(--serif-body), Georgia, serif;
  font-size: 13px;
}

.viz-meta {
  fill: rgba(244, 247, 245, 0.48);
  font-family: var(--sans), system-ui, sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.viz-track {
  fill: rgba(251, 250, 247, 0.1);
}

.viz-fill {
  fill: var(--copper);
  transform-origin: 28px 122px;
  animation: bar-draw 1.1s cubic-bezier(0.22, 1, 0.36, 1) 0.35s both;
}

.viz-line {
  fill: none;
  stroke: rgba(244, 247, 245, 0.88);
  stroke-width: 2;
  stroke-linecap: square;
  stroke-linejoin: miter;
  stroke-dasharray: 480;
  stroke-dashoffset: 480;
  animation: line-draw 1.2s cubic-bezier(0.22, 1, 0.36, 1) 0.45s forwards;
}

.viz-area {
  fill: rgba(184, 137, 90, 0.12);
  opacity: 0;
  animation: area-in 0.8s ease 0.7s forwards;
}

.viz-ticks line {
  stroke: rgba(251, 250, 247, 0.14);
  stroke-width: 1;
}

.viz-ticks text {
  fill: rgba(244, 247, 245, 0.4);
  font-family: var(--sans), system-ui, sans-serif;
  font-size: 10px;
  font-weight: 600;
}

.viz-bar {
  fill: rgba(251, 250, 247, 0.82);
  transform-box: fill-box;
  transform-origin: bottom;
  animation: bar-up 0.85s cubic-bezier(0.22, 1, 0.36, 1) 0.5s both;
}

.viz-bar-mid {
  fill: rgba(184, 137, 90, 0.85);
  animation-delay: 0.58s;
}

.viz-bar-low {
  fill: rgba(251, 250, 247, 0.45);
  animation-delay: 0.66s;
}

.viz-bar-faint {
  fill: rgba(251, 250, 247, 0.22);
  animation-delay: 0.74s;
}

.viz-rows line {
  stroke: rgba(251, 250, 247, 0.12);
}

.hero-rail {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 0.85rem;
  padding: 2rem 1.35rem 2.5rem;
  background: var(--surface);
  border-left: 1px solid var(--line-strong);
}

.rail-rule {
  width: 2.5rem;
  height: 3px;
  background: var(--copper);
  margin-bottom: 0.5rem;
}

.rail-label {
  margin: 0 0 0.75rem;
  font-family: var(--display);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--copper);
}

.rail-stat {
  margin: 0;
  display: grid;
  grid-template-columns: 2.1rem 1fr;
  gap: 0.55rem;
  align-items: baseline;
  font-family: var(--serif-body);
  font-size: 1.05rem;
  color: var(--ink);
  padding: 0.55rem 0;
  border-top: 1px solid var(--line);
}

.rail-stat span {
  font-family: var(--display);
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--forest);
  letter-spacing: 0.04em;
}

/* flow strip */
.strip {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}

.strip-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(2.75rem, 6vw, 4rem) clamp(1.25rem, 3vw, 2rem);
}

.strip-head {
  margin-bottom: 1.75rem;
  max-width: 34rem;
  padding-left: 0.85rem;
  border-left: 3px solid var(--forest);
}

.strip-head h2 {
  margin: 0 0 0.4rem;
  font-family: var(--display);
  font-size: clamp(1.55rem, 2.8vw, 2rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.strip-head p {
  margin: 0;
  font-family: var(--serif-body);
  color: var(--muted);
}

.ledger-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line-strong);
}

.ledger-steps li {
  display: grid;
  grid-template-columns: 3.5rem 1fr;
  gap: 1rem;
  padding: 1.35rem 0;
  border-bottom: 1px solid var(--line);
}

.idx {
  font-family: var(--display);
  font-size: 1rem;
  font-weight: 800;
  color: var(--copper);
  letter-spacing: 0.04em;
}

.ledger-steps h3 {
  margin: 0 0 0.3rem;
  font-family: var(--display);
  font-size: 1.05rem;
  font-weight: 700;
}

.ledger-steps p {
  margin: 0;
  max-width: 42ch;
  color: var(--muted);
  font-size: 0.98rem;
}

/* oxide band */
.oxide {
  background: var(--paper-deep);
  border-bottom: 1px solid var(--line);
}

.oxide-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(2.75rem, 6vw, 4rem) clamp(1.25rem, 3vw, 2rem);
}

.oxide h2 {
  margin: 0 0 1.5rem;
  max-width: 16ch;
  font-family: var(--display);
  font-size: clamp(1.55rem, 2.8vw, 2.05rem);
  font-weight: 800;
  letter-spacing: -0.03em;
}

.oxide-list {
  list-style: none;
  margin: 0 0 1.75rem;
  padding: 0;
  display: grid;
  gap: 0;
  max-width: 36rem;
  border-top: 1px solid var(--line-strong);
}

.oxide-list li {
  display: grid;
  gap: 0.2rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
}

.oxide-list strong {
  font-family: var(--display);
  font-size: 1rem;
  font-weight: 700;
}

.oxide-list span {
  color: var(--muted);
  font-family: var(--serif-body);
  font-size: 0.98rem;
}

/* footer */
.foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.5rem;
  padding: 1.25rem clamp(1.15rem, 3vw, 2rem);
  background: var(--surface);
}

.foot p {
  margin: 0;
  flex: 1;
  font-size: 0.86rem;
  color: var(--muted);
}

.foot-link {
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--forest);
  text-decoration: none;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.foot-link:hover {
  color: var(--copper);
}

@keyframes slab-in {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes viz-in {
  from {
    opacity: 0;
    transform: translateX(16px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes bar-draw {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

@keyframes line-draw {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes area-in {
  to {
    opacity: 1;
  }
}

@keyframes bar-up {
  from {
    transform: scaleY(0);
  }
  to {
    transform: scaleY(1);
  }
}

@media (max-width: 980px) {
  .hero-slab {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .hero-viz {
    max-width: 22rem;
    justify-self: start;
    margin-top: 0.5rem;
  }
}

@media (max-width: 820px) {
  .hero-cut {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .hero-slab {
    min-height: min(88svh, 720px);
    padding-bottom: 2.25rem;
  }

  .hero-rail {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 0.5rem 1.25rem;
    border-left: 0;
    border-top: 1px solid var(--line-strong);
  }

  .rail-stat {
    border-top: 0;
    padding: 0.25rem 0;
  }

  .rail-rule {
    width: 100%;
    flex-basis: 100%;
  }

  .rail-label {
    flex-basis: 100%;
  }
}

@media (max-width: 640px) {
  .mast-nav {
    display: none;
  }

  .mast {
    justify-content: space-between;
  }

  .hero-viz {
    max-width: 100%;
  }

  .viz-value {
    font-size: 30px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-slab,
  .hero-viz,
  .viz-fill,
  .viz-line,
  .viz-area,
  .viz-bar {
    animation: none;
  }

  .viz-line {
    stroke-dashoffset: 0;
  }

  .viz-area {
    opacity: 1;
  }
}
