/* Lading Co. — stylesheet
   Palette is seven values. Change them here and the whole site follows. */

:root {
  /* Surfaces */
  --paper:        #EAE8E3;   /* page background (warm) */
  --paper-2:      #F4F2ED;   /* raised: cards, panels, boxes */
  --rule:         #C9C5BD;   /* hairlines and grid seams */
  --petrol:       #0D242A;   /* dark surface: calculator, buttons, emphasis */
  --rule-dark:    rgba(255,255,255,.16); /* hairlines on dark */

  /* Ink */
  --ink:          #15171B;   /* headings, body */
  --muted:        #57544D;   /* labels, card body, secondary copy */
  --ink-on-dark:  #F4F2ED;
  --muted-on-dark:#A3B2B4;
  --faint-on-dark:#92A1A3;   /* calculator footnote */

  /* Accent — one hue, three lightnesses */
  --signal:       #B8431E;   /* on light */
  --signal-lift:  #E07A4E;   /* on dark */
  --signal-deep:  #9C3617;   /* button hover */

  /* Type */
  --display: 'Archivo', system-ui, -apple-system, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, SFMono-Regular, monospace;

  /* Rhythm */
  --shell: 1120px;
  --pad: 28px;
  --section-y: 76px;
}

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

html { scroll-behavior: smooth; }

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

a { color: var(--ink); }
a:hover { color: var(--signal); }

:focus-visible { outline: 2px solid var(--signal); outline-offset: 3px; }

.shell { max-width: var(--shell); margin: 0 auto; padding: 0 var(--pad); }

/* ---------- Type scale ---------- */

h1, h2 { font-weight: 800; letter-spacing: -.028em; line-height: 1.04; margin: 0; }
h1 { font-size: clamp(2.5rem, 6.2vw, 4.6rem); max-width: 16ch; }
h2 { font-size: clamp(1.9rem, 3.9vw, 2.9rem); }
h3 { font-weight: 600; font-size: 1.15rem; letter-spacing: -.01em; line-height: 1.3; margin: 0 0 9px; }

p { text-wrap: pretty; }

.lede {
  font-size: clamp(1.05rem, 1.7vw, 1.28rem);
  line-height: 1.5;
  color: var(--muted);
  max-width: 52ch;
  margin: 0;
}

/* Mono tracking is limited to three steps: .04 tight, .1 normal, .16 wide. */
.mono   { font-family: var(--mono); letter-spacing: .04em; }
.mono-n { font-family: var(--mono); letter-spacing: .1em; text-transform: uppercase; }
.mono-w { font-family: var(--mono); letter-spacing: .16em; text-transform: uppercase; }

/* Section eyebrow with trailing rule */
.eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 22px;
}
.eyebrow::after { content: ''; flex: 1; height: 1px; background: var(--rule); }
.eyebrow--dark { color: var(--muted-on-dark); }
.eyebrow--dark::after { background: var(--rule-dark); }

.tag {
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--signal);
}

/* ---------- Buttons ---------- */

.btn {
  font-family: var(--mono);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: .1em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 14px 26px;
  border: 1px solid var(--petrol);
  background: var(--petrol);
  color: var(--ink-on-dark);
  transition: background .16s ease, border-color .16s ease, color .16s ease;
  display: inline-block;
}
.btn:hover { background: var(--signal-deep); border-color: var(--signal-deep); color: var(--ink-on-dark); }

.btn--ghost { background: transparent; color: var(--petrol); }
.btn--ghost:hover { background: var(--petrol); color: var(--ink-on-dark); }

/* ---------- Header ---------- */

.site-head {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 93%, transparent);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
}
.site-head__in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding: 15px var(--pad);
  max-width: var(--shell);
  margin: 0 auto;
}
.brand {
  font-weight: 800;
  font-size: 1.16rem;
  letter-spacing: -.03em;
  text-decoration: none;
  color: var(--ink);
}
.brand,
.brand:hover,
.brand:focus,
.brand:active { color: var(--ink) !important; }
.brand span,
.brand:hover span,
.brand:focus span,
.brand:active span { color: var(--signal) !important; }
.site-nav { display: flex; flex-wrap: wrap; gap: 24px; font-size: 12px; }
.site-nav a { color: var(--muted); text-decoration: none; }
.site-nav a:hover { color: var(--ink); }

/* ---------- Sections ---------- */

.section { padding: var(--section-y) 0; border-bottom: 1px solid var(--rule); }
.section--hero { padding-top: 88px; padding-bottom: 64px; }
.section--dark { background: var(--petrol); color: var(--ink-on-dark); border-bottom: 0; }
.section--dark h2 { color: var(--ink-on-dark); }
.section--dark .lede { color: var(--muted-on-dark); }

.section__head { max-width: 62ch; margin-bottom: 44px; }
.section__head h2 { margin-bottom: 18px; }
.section__head h2:only-child, .section__head h2:last-child { margin-bottom: 0; }

/* ---------- Cell strips ----------
   Fixed-count strips use wrapping flex with a growable basis, so a wrapped row
   stretches to fill the width instead of leaving a gap. Borders sit on the
   cells; the parent supplies the seam colour. */

.strip {
  display: flex;
  flex-wrap: wrap;
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--rule);
}
.strip > * { background: var(--paper-2); }
.strip--dark { background: var(--rule-dark); border-color: var(--rule-dark); }
.strip--dark > * { background: var(--petrol); }

/* Cell counts are pinned explicitly. A growable flex-basis stretches a wrapped
   row but cannot control how many items wrap, so a basis wider than the
   container always yields 3+1 with the orphan spanning full width. */
.cell-4 { flex: 1 1 calc(25% - 1px); min-width: 0; padding: 26px 22px; }
.cell-2 { flex: 1 1 calc(50% - 1px); min-width: 0; padding: 24px; }
.cell-half { flex: 1 1 calc(50% - 1px); min-width: 0; padding: 34px; }

@media (max-width: 980px) { .cell-4 { flex-basis: calc(50% - 1px); } }
@media (max-width: 620px) {
  .cell-4, .cell-2, .cell-half { flex-basis: 100%; }
}
.card p { font-size: 15px; color: var(--muted); margin: 0; line-height: 1.55; }
.card .tag { display: block; margin-bottom: 14px; }

/* ---------- Hero ---------- */

.hero-copy { margin: 0 0 36px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.hero-note { font-family: var(--mono); font-size: 12px; letter-spacing: .04em; color: var(--muted); }

.lane {
  margin: 44px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1px;
  background: var(--rule);
  border: 1px solid var(--petrol);
}
.lane > div { flex: 1 1 calc(25% - 1px); min-width: 0; background: var(--paper-2); padding: 16px 18px; }
@media (max-width: 980px) { .lane > div { flex-basis: calc(50% - 1px); } }
@media (max-width: 620px) { .lane > div { flex-basis: 100%; } }
.lane dt {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 7px;
}
.lane dd {
  margin: 0;
  font-family: var(--mono);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .04em;
  font-variant-numeric: tabular-nums;
}

/* ---------- Emphasis bar ---------- */

.note-bar {
  border: 1px solid var(--petrol);
  border-top: 0;
  padding: 26px 28px;
  background: var(--petrol);
  color: var(--ink-on-dark);
}
.note-bar p {
  margin: 0;
  font-weight: 600;
  font-size: 1.22rem;
  letter-spacing: -.02em;
  line-height: 1.35;
}

/* ---------- Calculator ---------- */

.field { margin-bottom: 26px; }
.field:last-child { margin-bottom: 0; }
.field label {
  display: block;
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted-on-dark);
  margin-bottom: 11px;
}
.field__row { display: flex; align-items: center; gap: 14px; }
.field input[type=range] { flex: 1; min-width: 0; height: 6px; accent-color: var(--signal-lift); }
.field output {
  font-family: var(--mono);
  font-size: 16px;
  font-weight: 600;
  color: var(--ink-on-dark);
  min-width: 96px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.out { margin-bottom: 30px; }
.out__label {
  font-family: var(--mono);
  font-size: 11.5px;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted-on-dark);
  margin-bottom: 10px;
}
.out__num {
  font-weight: 800;
  letter-spacing: -.035em;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}
.out__num--lg { font-size: clamp(2.1rem, 5vw, 3.1rem); color: var(--signal-lift); }
.out__num--sm { font-size: clamp(1.5rem, 3.2vw, 2rem); color: var(--ink-on-dark); }
.out__sub { font-size: 14.5px; color: var(--muted-on-dark); margin-top: 9px; line-height: 1.5; }

.calc-foot {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .04em;
  color: var(--faint-on-dark);
  line-height: 1.65;
  padding-top: 22px;
  border-top: 1px solid var(--rule-dark);
}

/* ---------- Compliance ---------- */

.pull { border-left: 3px solid var(--signal); padding: 6px 0 6px 26px; max-width: 64ch; }
.pull p { margin: 0 0 18px; color: var(--muted); }
.pull p:last-child { margin-bottom: 0; }

/* ---------- Start ---------- */

.start-box { background: var(--paper-2); border: 1px solid var(--petrol); padding: 46px; }
.start-box h2 { margin-bottom: 20px; max-width: 20ch; }
.start-box .lede { margin-bottom: 32px; }

.steps { margin: 0 0 34px; padding: 0; list-style: none; display: grid; gap: 15px; }
.steps li { display: grid; grid-template-columns: 44px 1fr; font-size: 16px; color: var(--muted); }
.steps span:first-child {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .04em;
  color: var(--signal);
  padding-top: 4px;
}

/* ---------- Footer ---------- */

.site-foot { padding: 56px 0 44px; font-size: 14.5px; }
.foot-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 34px;
  margin-bottom: 38px;
}
.foot-cols h4 {
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
  margin: 0 0 14px;
}
.foot-cols p { margin: 0 0 7px; color: var(--muted); max-width: 38ch; }
.foot-cols p:last-child { margin-bottom: 0; }
.foot-cols a { color: var(--muted); }
.foot-legal {
  border-top: 1px solid var(--rule);
  padding-top: 22px;
  display: flex;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: .04em;
  color: var(--muted);
}

/* ---------- Motion ---------- */

@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.rise { animation: rise .62s cubic-bezier(.2,.7,.3,1) both; }
.rise-1 { animation-delay: .05s; }
.rise-2 { animation-delay: .13s; }
.rise-3 { animation-delay: .21s; }
.rise-4 { animation-delay: .29s; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}
