/* ==========================================================================
   Burning Sapp LLC
   Shared stylesheet. Direction: "Controlled Burn", an after-dark
   engineering journal. Fraunces speaks, Inter explains, Plex Mono certifies.
   ========================================================================== */

/* Metric-adjusted fallback so the big serif headings don't re-wrap
   when Fraunces finishes loading. */
@font-face {
  font-family: 'Fraunces Fallback';
  src: local('Georgia');
  size-adjust: 93%;
  ascent-override: 92%;
}

:root {
  color-scheme: dark;
  --bg: #171310;
  --surface: #211B16;
  --text: #EDE4D6;
  --muted: #9C8F7E;
  --ember: #E8862D;
  --ember-deep: #B4531E;
  --line: rgba(237, 228, 214, .13);
  --serif: 'Fraunces', 'Fraunces Fallback', Georgia, 'Times New Roman', serif;
  --sans: 'Inter', system-ui, 'Segoe UI', Arial, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, Consolas, monospace;
  --measure: 62ch;
}

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

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

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.65;
  font-optical-sizing: auto;
  -webkit-font-smoothing: antialiased;
}

::selection { background: var(--ember); color: #171310; }

a { color: inherit; }
a:focus-visible {
  outline: 2px solid var(--ember);
  outline-offset: 3px;
  border-radius: 1px;
}

/* ---- shared pieces ------------------------------------------------------ */

.wrap {
  max-width: 68rem;
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 2.5rem);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 10;
  background: var(--surface);
  color: var(--text);
  font-family: var(--mono);
  font-size: .8rem;
  padding: .7rem 1rem;
  border: 1px solid var(--ember);
}
.skip:focus { left: 1rem; top: 1rem; }

hr.ember {
  border: 0;
  height: 1px;
  background: linear-gradient(90deg,
    transparent,
    rgba(232, 134, 45, .35) 18%,
    var(--ember) 50%,
    rgba(232, 134, 45, .35) 82%,
    transparent);
}
hr.ember.dim { opacity: .45; }

.kicker {
  font-family: var(--mono);
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--muted);
}
.kicker .idx { color: var(--ember); }

.link {
  color: var(--text);
  text-decoration: underline;
  text-decoration-color: var(--ember);
  text-decoration-thickness: 1.5px;
  text-underline-offset: .35em;
  transition: text-decoration-thickness .15s ease, color .15s ease;
}
.link:hover { text-decoration-thickness: 3px; color: var(--ember); }

.legacy {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 560;
  color: var(--ember);
}

/* ---- masthead ----------------------------------------------------------- */

.masthead-inner {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem 2rem;
  flex-wrap: wrap;
  padding-block: 1.4rem;
}

.wordmark {
  font-family: var(--serif);
  font-weight: 620;
  font-size: 1.65rem;
  letter-spacing: -.01em;
  white-space: nowrap;
  color: var(--text);
  text-decoration: none;
}
@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  .wordmark {
    background: linear-gradient(90deg, #9C8F7E 0%, #EDE4D6 45%, #E8862D 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
  }
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem 1.6rem;
  font-family: var(--mono);
  font-size: .78rem;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.nav a {
  color: var(--muted);
  text-decoration: none;
  padding-block: .15rem;
  border-bottom: 1px solid transparent;
  transition: color .15s ease, border-color .15s ease;
}
.nav a:hover { color: var(--text); border-bottom-color: var(--line); }
.nav a[aria-current="page"] { color: var(--ember); border-bottom-color: var(--ember); }

/* ---- sections with folio margin ----------------------------------------- */

section { padding-block: clamp(4rem, 9vw, 7rem); }
section.tight { padding-block: clamp(3rem, 6vw, 4.5rem); }

.folio {
  display: grid;
  grid-template-columns: 9.5rem minmax(0, 1fr);
  gap: 1.25rem 2.5rem;
  align-items: start;
}
.folio > .kicker { padding-top: .15rem; }

.section-title {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(1.7rem, 3.4vw, 2.4rem);
  line-height: 1.15;
  letter-spacing: -.012em;
  text-wrap: balance;
  margin-bottom: clamp(1.75rem, 4vw, 3rem);
  max-width: 24ch;
}
.section-intro {
  max-width: var(--measure);
  margin-top: -1rem;
  margin-bottom: clamp(1.75rem, 4vw, 2.5rem);
}

/* ---- home hero ---------------------------------------------------------- */

.hero { padding-block: clamp(5rem, 16vh, 9.5rem) clamp(4.5rem, 10vw, 7rem); }

.hero h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2.6rem, 7.2vw, 5.4rem);
  line-height: 1.06;
  letter-spacing: -.015em;
  text-wrap: balance;
  max-width: 18ch;
  margin-top: 1.4rem;
}
.hero h1 .modern {
  font-family: var(--sans);
  font-weight: 615;
  font-size: .88em;
  letter-spacing: -.03em;
}

.dek {
  max-width: var(--measure);
  margin-top: 1.75rem;
  font-size: 1.15rem;
}

.hero-cta { margin-top: 2.75rem; display: flex; flex-direction: column; gap: .8rem; }
.hero-cta .link { font-size: 1.3rem; width: fit-content; }
.hero-note { font-family: var(--mono); font-size: .8rem; color: var(--muted); }

/* ---- inner page hero ---------------------------------------------------- */

.page-hero { padding-block: clamp(3.5rem, 9vw, 5.5rem) clamp(2.5rem, 6vw, 3.5rem); }
.page-hero h1 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(2.2rem, 5.6vw, 3.9rem);
  line-height: 1.08;
  letter-spacing: -.015em;
  text-wrap: balance;
  max-width: 20ch;
  margin-top: 1.1rem;
}
.page-lede {
  max-width: var(--measure);
  margin-top: 1.5rem;
  font-size: 1.15rem;
}

/* ---- diff block --------------------------------------------------------- */

.diff-fig { margin: 2.5rem 0 0; max-width: 34rem; }
.diff {
  font-family: var(--mono);
  font-size: .85rem;
  line-height: 1.9;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 1.1rem 1.4rem;
  margin: 0;
  overflow-x: auto;
}
.diff del {
  color: var(--muted);
  text-decoration: line-through;
  text-decoration-color: rgba(156, 143, 126, .5);
}
.diff ins { color: var(--ember); text-decoration: none; }
@media (max-width: 24rem) {
  .diff { white-space: pre-wrap; }
}

/* ---- services list (home) ----------------------------------------------- */

.svc {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 1.5rem 3rem;
  padding-block: 2.6rem;
}
.svc-head { display: flex; gap: 1.1rem; align-items: baseline; }
.svc-num { font-family: var(--mono); font-size: .8rem; color: var(--muted); }
.svc h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(1.45rem, 2.6vw, 1.9rem);
  line-height: 1.2;
  letter-spacing: -.01em;
}
.svc h3 a { text-decoration: none; transition: color .15s ease; }
.svc h3 a:hover { color: var(--ember); }
.svc-body p { max-width: var(--measure); }
.svc-more { margin-top: 1rem; font-size: .95rem; }
.svc-deliv {
  margin-top: 1.1rem;
  font-family: var(--mono);
  font-size: .8rem;
  letter-spacing: .02em;
  color: var(--muted);
}
.svc-deliv b { color: var(--ember); font-weight: 500; }

/* ---- scenarios ("does this sound familiar") ----------------------------- */

.scenarios {
  list-style: none;
  border-bottom: 1px solid var(--line);
  max-width: 52rem;
}
.scenarios li {
  border-top: 1px solid var(--line);
  padding-block: 1.05rem;
  padding-left: 1.75rem;
  position: relative;
}
.scenarios li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 1.65rem;
  width: 6px;
  height: 6px;
  background: var(--ember);
}

/* ---- process steps ------------------------------------------------------ */

.steps {
  border-bottom: 1px solid var(--line);
  list-style: none;
  margin: 0;
  padding: 0;
}
.step {
  display: grid;
  grid-template-columns: 4.5rem minmax(0, 1fr);
  gap: 1rem 2rem;
  padding-block: 1.9rem;
  border-top: 1px solid var(--line);
}
.step-num {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 2.6rem;
  line-height: 1;
  font-variant-numeric: oldstyle-nums;
  color: var(--muted);
}
.step h3 {
  font-family: var(--sans);
  font-weight: 640;
  font-size: 1.1rem;
  letter-spacing: -.01em;
}
.step p { max-width: var(--measure); margin-top: .3rem; }
.step .step-evid {
  margin-top: .75rem;
  font-family: var(--mono);
  font-size: .75rem;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted);
}
.step .step-evid b { color: var(--ember); font-weight: 500; }

/* ---- hairline card grid (deliverables) ---------------------------------- */

.grid-hair {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
}
.grid-hair > * { background: var(--bg); padding: 1.6rem 1.5rem; }
.grid-hair h3 {
  font-family: var(--sans);
  font-weight: 640;
  font-size: 1rem;
  letter-spacing: -.01em;
}
.grid-hair p { margin-top: .5rem; font-size: .97rem; color: var(--text); }
.grid-hair .tag {
  display: block;
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ember);
  margin-bottom: .7rem;
}

/* ---- spec list ---------------------------------------------------------- */

.spec { border-bottom: 1px solid var(--line); }
.spec-row {
  display: grid;
  grid-template-columns: 8rem minmax(0, 1fr);
  gap: .35rem 1.5rem;
  padding-block: 1.15rem;
  border-top: 1px solid var(--line);
}
.spec-row dt {
  font-family: var(--mono);
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: .25rem;
}
.spec-row dd { font-size: 1rem; }

/* ---- pull statement ----------------------------------------------------- */

.pull {
  font-family: var(--serif);
  font-weight: 540;
  font-size: clamp(1.5rem, 2.8vw, 2rem);
  line-height: 1.35;
  letter-spacing: -.01em;
  text-wrap: balance;
}
.pull .legacy { font-weight: 540; }

.why {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: 3rem 4rem;
  align-items: start;
}

/* ---- questions and answers ---------------------------------------------- */

.qa { border-bottom: 1px solid var(--line); max-width: 52rem; }
.qa-item { border-top: 1px solid var(--line); padding-block: 1.6rem; }
.qa-item h3 {
  font-family: var(--sans);
  font-weight: 640;
  font-size: 1.05rem;
  letter-spacing: -.01em;
}
.qa-item p { margin-top: .5rem; max-width: var(--measure); }

/* ---- note panel --------------------------------------------------------- */

.note {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 1.6rem 1.75rem;
  max-width: 46rem;
}
.note.stack-top { margin-top: 1.5rem; }
.note .tag {
  display: block;
  font-family: var(--mono);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--ember);
  margin-bottom: .7rem;
}
.note p + p { margin-top: .8rem; }

/* ---- partners ----------------------------------------------------------- */

.partners { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.partner {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 2.25rem;
}
.monogram {
  width: 3.4rem;
  height: 3.4rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--ember);
  margin-bottom: 1.4rem;
}
.partner h3 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.5rem;
  letter-spacing: -.01em;
}
.partner-role {
  font-family: var(--mono);
  font-size: .75rem;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: .3rem;
}
.partner-bio { margin-top: 1.1rem; font-size: 1rem; }
.partners-caption {
  margin-top: 1.6rem;
  font-family: var(--mono);
  font-size: .8rem;
  color: var(--muted);
}

/* ---- contact ------------------------------------------------------------ */

.contact { text-align: center; padding-block: clamp(5rem, 12vw, 8.5rem); }
.contact h2 {
  font-family: var(--serif);
  font-weight: 600;
  font-size: clamp(1.9rem, 4.6vw, 3.1rem);
  line-height: 1.15;
  letter-spacing: -.015em;
  text-wrap: balance;
  max-width: 24ch;
  margin: 1.4rem auto 0;
}
.email {
  display: inline-block;
  margin-top: 2.4rem;
  font-family: var(--serif);
  font-weight: 560;
  font-size: clamp(1.25rem, 3.6vw, 2.3rem);
  letter-spacing: -.01em;
  color: var(--ember);
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: .3em;
  overflow-wrap: anywhere;
  transition: text-decoration-thickness .15s ease;
}
.email:hover { text-decoration-thickness: 3px; }
.contact-note {
  margin-top: 1.9rem;
  font-family: var(--mono);
  font-size: .8rem;
  color: var(--muted);
}

/* ---- checklist (contact page) ------------------------------------------- */

.checklist { list-style: none; max-width: 52rem; }
.checklist li {
  display: grid;
  grid-template-columns: 8.5rem minmax(0, 1fr);
  gap: .3rem 1.5rem;
  padding-block: 1.05rem;
  border-top: 1px solid var(--line);
}
.checklist li:last-child { border-bottom: 1px solid var(--line); }
.checklist .what {
  font-family: var(--mono);
  font-size: .75rem;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: .25rem;
}

/* ---- footer ------------------------------------------------------------- */

.colophon {
  padding-block: 2.25rem 2.75rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem 2.5rem;
  flex-wrap: wrap;
  font-family: var(--mono);
  font-size: .8rem;
  line-height: 1.8;
  color: var(--muted);
}
.colophon a { color: var(--muted); text-decoration: underline; text-underline-offset: .25em; }
.colophon a:hover { color: var(--ember); }

/* ---- responsive --------------------------------------------------------- */

@media (max-width: 66rem) {
  .why { grid-template-columns: minmax(0, 1fr); gap: 2.25rem; }
}

@media (max-width: 56rem) {
  .spec-row { grid-template-columns: minmax(0, 1fr); gap: .15rem; }
  .spec-row dt { padding-top: 0; }
  .checklist li { grid-template-columns: minmax(0, 1fr); gap: .15rem; }
  .checklist .what { padding-top: 0; }
  .folio { grid-template-columns: minmax(0, 1fr); }
  .folio > .kicker { padding-top: 0; }
  .svc { grid-template-columns: minmax(0, 1fr); gap: 1rem; padding-block: 2.2rem; }
  .partners { grid-template-columns: minmax(0, 1fr); }
  .step { grid-template-columns: 3.25rem minmax(0, 1fr); gap: .5rem 1.25rem; }
  .step-num { font-size: 2rem; }
}

/* ---- print -------------------------------------------------------------- */

@media print {
  :root {
    color-scheme: light;
    --bg: #FAF7F2;
    --surface: #FFFFFF;
    --text: #1C1917;
    --muted: #6B6459;
    --ember: #B4531E;
    --line: rgba(28, 25, 23, .2);
  }
  body { background: var(--bg); color: var(--text); }
  .wordmark { background: none; -webkit-background-clip: initial; background-clip: initial; color: var(--text); }
  hr.ember { background: none; border-top: 1px solid var(--ember); height: 0; }
  .nav, .skip { display: none; }
}
