:root {
  color-scheme: light;
  --paper: #f1eee5;
  --ink: #18202b;
  --muted: #5f6870;
  --line: #b9b6ad;
  --blue: #1857c9;
  --red: #a9372e;
  --green: #1b7656;
  --white: #fbfaf6;
  --max: 1240px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scrollbar-color: var(--blue) #d8d3c8; scrollbar-width: thin; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif; line-height: 1.55; }
a { color: inherit; }
.site-header, main, footer { width: min(calc(100% - 48px), var(--max)); margin: 0 auto; }
.site-header { min-height: 80px; display: flex; align-items: center; justify-content: space-between; gap: 32px; border-bottom: 1px solid var(--line); }
.wordmark { min-height: 44px; display: inline-flex; align-items: center; gap: 12px; font-size: .84rem; font-weight: 850; letter-spacing: .05em; text-decoration: none; text-transform: uppercase; }
.wordmark span { width: 40px; height: 40px; display: grid; place-items: center; background: var(--ink); color: var(--white); font: 800 .78rem/1 ui-monospace, "Cascadia Code", monospace; }
nav { display: flex; gap: 28px; }
nav a { min-height: 44px; display: inline-flex; align-items: center; padding: 0 4px; color: var(--muted); font-size: .84rem; font-weight: 700; text-decoration: none; }
nav a:hover, nav a:focus-visible { color: var(--blue); }
.hero { min-height: 690px; display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(330px, .65fr); gap: clamp(50px, 8vw, 116px); align-items: center; padding: 92px 0 105px; }
.eyebrow { margin: 0 0 18px; color: var(--blue); font: 800 .72rem/1.2 ui-monospace, "Cascadia Code", monospace; letter-spacing: .13em; text-transform: uppercase; }
h1, h2, p { text-wrap: pretty; }
h1 { max-width: 850px; margin: 0; font-size: clamp(4rem, 8.8vw, 8.6rem); line-height: .86; letter-spacing: -.07em; }
h1 em { color: var(--blue); font-family: Georgia, "Times New Roman", serif; font-weight: 400; }
.lede { max-width: 700px; margin: 32px 0 0; color: var(--muted); font-size: clamp(1.03rem, 1.5vw, 1.27rem); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.button { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; padding: 0 20px; border: 1px solid var(--ink); font-size: .86rem; font-weight: 800; text-decoration: none; }
.button.primary { background: var(--ink); color: var(--white); }
.button:hover, .button:focus-visible { border-color: var(--blue); color: var(--blue); }
.button.primary:hover, .button.primary:focus-visible { background: var(--blue); color: var(--white); }
.surgery-card { align-self: end; margin-bottom: 26px; padding: 24px; background: var(--white); border: 1px solid var(--ink); box-shadow: 9px 9px 0 #d5d0c4; }
.card-head { display: flex; justify-content: space-between; gap: 18px; padding-bottom: 17px; border-bottom: 1px solid var(--line); font: 800 .67rem/1 ui-monospace, "Cascadia Code", monospace; letter-spacing: .08em; }
.status { color: var(--green); }
.before-after { display: grid; grid-template-columns: 1fr auto 1fr; gap: 9px; align-items: center; padding: 27px 0; }
.sample { min-height: 152px; padding: 12px; border: 1px solid var(--line); }
.sample span { display: block; margin-bottom: 18px; color: var(--muted); font: 800 .62rem/1 ui-monospace, "Cascadia Code", monospace; }
.sample i { display: block; width: 100%; height: 6px; margin: 8px 0; background: #d5d2ca; }
.sample i:nth-of-type(2) { width: 72%; }
.sample b { min-height: 30px; display: grid; place-items: center; margin-top: 16px; background: #d0cec6; color: #484842; font-size: .64rem; }
.sample.after { border-color: var(--green); }
.sample.after i { background: #aecbbb; }
.sample.after b { background: var(--green); color: white; }
.seam { color: var(--red); font-weight: 900; }
.surgery-card dl { margin: 0; }
.surgery-card dl div { display: flex; justify-content: space-between; gap: 18px; padding: 11px 0; border-top: 1px solid var(--line); }
.surgery-card dt { color: var(--muted); }
.surgery-card dd { margin: 0; font-weight: 800; }
.method { display: grid; grid-template-columns: .28fr 1fr; gap: 42px; padding: 105px 0 115px; border-top: 1px solid var(--line); contain: layout paint style; }
.section-label { display: flex; gap: 12px; color: var(--red); font: 800 .68rem/1 ui-monospace, "Cascadia Code", monospace; letter-spacing: .1em; }
.section-label p { margin: 0; }
.method h2, .install h2 { max-width: 850px; margin: 0; font-size: clamp(2.8rem, 6vw, 6rem); line-height: .91; letter-spacing: -.06em; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 62px; border-top: 1px solid var(--ink); border-bottom: 1px solid var(--ink); }
.steps article { min-height: 310px; padding: 24px 22px 27px 0; border-right: 1px solid var(--line); }
.steps article:not(:first-child) { padding-left: 22px; }
.steps article:last-child { border-right: 0; }
.steps article > span { color: var(--blue); font: 800 .68rem/1 ui-monospace, "Cascadia Code", monospace; letter-spacing: .11em; }
.steps h3 { margin: 105px 0 12px; font-size: 1.4rem; }
.steps p { margin: 0; color: var(--muted); }
.install { display: grid; grid-template-columns: 1fr .8fr; gap: 50px; align-items: end; padding: 110px 0; border-top: 1px solid var(--line); contain: layout paint style; }
.install-command { padding-left: 30px; border-left: 4px solid var(--blue); }
.install-command code { display: block; overflow-wrap: anywhere; color: var(--blue); font: 750 .9rem/1.6 ui-monospace, "Cascadia Code", monospace; }
.install-command p { margin: 22px 0; color: var(--muted); font-size: .84rem; }
.install-command a { min-height: 44px; display: inline-flex; align-items: center; font-weight: 800; }
footer { min-height: 120px; display: flex; align-items: center; justify-content: space-between; gap: 30px; border-top: 1px solid var(--line); color: var(--muted); font-size: .82rem; }
footer a { min-height: 44px; display: inline-flex; align-items: center; padding: 0 4px; }

@media (max-width: 840px) {
  nav a:not(:last-child) { display: none; }
  .hero { min-height: auto; grid-template-columns: 1fr; gap: 52px; padding: 74px 0 90px; }
  .surgery-card { align-self: auto; margin: 0; }
  .method, .install { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .steps article, .steps article:not(:first-child) { min-height: 230px; padding: 24px 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .steps article:last-child { border-bottom: 0; }
  .steps h3 { margin-top: 62px; }
  footer { align-items: flex-start; flex-direction: column; justify-content: center; }
}

@media (max-width: 520px) {
  .site-header, main, footer { width: min(calc(100% - 24px), var(--max)); }
  h1 { font-size: clamp(3.5rem, 17vw, 5rem); }
  .before-after { grid-template-columns: 1fr; }
  .seam { transform: rotate(90deg); justify-self: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
