:root {
  --paper: #f5f1e8;
  --ink: #171713;
  --muted: #68675f;
  --blue: #2357d8;
  --acid: #c7f15b;
  --line: #cbc7bc;
  --white: #fffdf7;
  --sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, serif;
}

* { box-sizing: border-box; }
html { color: var(--ink); background: var(--paper); }
body { margin: 0; font-family: var(--sans); min-width: 300px; }
button, input { font: inherit; }
a { color: inherit; text-underline-offset: 3px; }
button, a { -webkit-tap-highlight-color: transparent; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
[hidden] { display: none !important; }

.masthead, main, .site-footer { width: min(880px, calc(100% - 32px)); margin-inline: auto; }
.masthead { display: flex; justify-content: space-between; align-items: flex-start; padding: 26px 0 20px; border-bottom: 1px solid var(--ink); }
.brand { font: 800 28px/1 var(--sans); text-decoration: none; letter-spacing: -.06em; }
.brand span, .feature-mark span { color: var(--blue); }
.masthead p { margin: 0; text-align: right; color: var(--muted); font-size: 12px; line-height: 1.35; text-transform: uppercase; letter-spacing: .08em; }

.intro { padding: 72px 0 45px; max-width: 760px; }
.eyebrow, .mini-label, .card-label { margin: 0 0 12px; font: 700 11px/1 var(--sans); text-transform: uppercase; letter-spacing: .16em; }
h1 { margin: 0; font: 400 clamp(48px, 9vw, 82px)/.93 var(--serif); letter-spacing: -.055em; }
h1 em { color: var(--blue); font-weight: 400; }
.lede { max-width: 670px; margin: 28px 0 0; font: 20px/1.5 var(--serif); color: #3f3e39; }

.setup { position: relative; padding: 30px; border: 1px solid var(--ink); border-radius: 3px; background: var(--white); box-shadow: 7px 7px 0 var(--ink); }
.setup h2 { margin: 0 0 20px; font: 600 25px/1 var(--serif); }
label { display: block; margin-bottom: 8px; font-size: 13px; font-weight: 700; }
.input-row { display: flex; gap: 10px; }
input[type="text"] { min-width: 0; flex: 1; border: 1px solid var(--ink); border-radius: 2px; padding: 14px 15px; background: white; font-size: 16px; }
.button { min-height: 48px; border: 1px solid var(--ink); border-radius: 2px; padding: 11px 19px; cursor: pointer; font-weight: 800; }
.button.primary { color: white; background: var(--ink); }
.button.primary:hover { color: var(--ink); background: var(--acid); }
.button.secondary { background: transparent; }
.button:disabled { cursor: wait; opacity: .55; }
.hint, .target, .status { margin: 12px 0 0; color: var(--muted); font-size: 13px; }
.status:empty { display: none; }
.account-line, .meter-line, .slider-head, .action-row, .progress-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.account-line { padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.account-line strong { display: block; margin-top: 6px; overflow-wrap: anywhere; }
.text-button { border: 0; padding: 4px 0; background: none; color: var(--blue); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.meter-line { padding: 18px 0 28px; color: var(--muted); font-size: 13px; }
.meter-line strong { color: var(--ink); }
.slider-head label { margin: 0; }
.slider-head output { font: 600 33px/1 var(--serif); }
.range { width: 100%; height: 34px; margin: 8px 0 0; accent-color: var(--blue); cursor: pointer; }
.action-row { justify-content: flex-start; margin-top: 22px; }
.progress { margin-top: 22px; border-top: 1px solid var(--line); padding-top: 18px; }
.progress-head { font-size: 13px; }
.progress-detail { color: var(--muted); }
.progress-track { overflow: hidden; height: 6px; margin-top: 10px; background: #dedbd2; border-radius: 10px; }
.progress-track span { display: block; width: 12%; height: 100%; background: var(--blue); transition: width .25s ease; }
.error { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; padding: 13px 15px; border-left: 5px solid #b4382b; background: #f7e5df; font-size: 14px; }
.error .text-button { margin-left: auto; color: #7d2017; }

.results { padding: 82px 0 65px; }
.results-head { display: flex; justify-content: space-between; align-items: end; margin-bottom: 23px; }
.results-head h2 { margin: 0; font: 500 42px/1 var(--serif); letter-spacing: -.035em; }
.results-head > span { color: var(--muted); font-size: 13px; }
.featured { width: min(760px, 100%); margin-inline: auto; background: var(--ink); color: var(--paper); border-radius: 3px; padding: 28px; box-shadow: 8px 8px 0 var(--acid); }
.feature-top { display: flex; justify-content: space-between; gap: 20px; padding-bottom: 23px; border-bottom: 1px solid #54544e; }
.feature-mark { font-weight: 800; font-size: 20px; letter-spacing: -.04em; }
.feature-top > div { min-width: 0; text-align: right; }
.feature-top strong, .feature-top time { display: block; overflow-wrap: anywhere; }
.feature-top time { margin-top: 4px; color: #b9b8b0; font-size: 12px; }
.comparison { display: grid; grid-template-columns: 1fr 1fr; gap: 0; }
.comparison section { min-width: 0; padding: 27px 25px 29px 0; }
.comparison section + section { padding-left: 25px; padding-right: 0; border-left: 1px solid #54544e; }
.card-label { color: #aeadA6; }
.post-text { margin: 0; font: 19px/1.55 var(--serif); white-space: pre-wrap; overflow-wrap: anywhere; }
.replacement { color: var(--ink); background: var(--acid); border-bottom: 2px solid var(--acid); border-radius: 2px; padding: 0 .08em; }
.featured footer { padding-top: 19px; border-top: 1px solid #54544e; color: #cccac1; font-size: 12px; }
.all-head { display: flex; align-items: baseline; justify-content: space-between; margin: 65px 0 12px; border-bottom: 1px solid var(--ink); padding-bottom: 10px; }
.all-head h3 { margin: 0; font: 600 22px/1 var(--serif); }
.all-head span { color: var(--muted); font-size: 12px; }
.post-item { padding: 24px 0; border-bottom: 1px solid var(--line); }
.post-meta { display: flex; justify-content: space-between; gap: 15px; margin-bottom: 10px; color: var(--muted); font-size: 12px; }
.post-item .post-text { font-size: 19px; }
.post-item .replacement { color: var(--ink); }
details { margin-top: 13px; }
summary { width: max-content; color: var(--blue); cursor: pointer; font-size: 12px; }
.original-copy { margin: 11px 0 0; padding-left: 14px; border-left: 2px solid var(--line); color: var(--muted); font: 15px/1.5 var(--serif); white-space: pre-wrap; overflow-wrap: anywhere; }
.site-footer { display: flex; justify-content: space-between; gap: 25px; padding: 25px 0 45px; border-top: 1px solid var(--ink); color: var(--muted); font-size: 11px; }

@media (max-width: 620px) {
  .intro { padding-top: 52px; }
  .lede { font-size: 18px; }
  .setup { padding: 22px; box-shadow: 5px 5px 0 var(--ink); }
  .input-row, .action-row { align-items: stretch; flex-direction: column; }
  .input-row .button { width: 100%; }
  .results { padding-top: 65px; }
  .results-head { align-items: flex-start; flex-direction: column; gap: 9px; }
  .results-head h2 { font-size: 35px; }
  .featured { padding: 22px; box-shadow: 5px 5px 0 var(--acid); }
  .comparison { grid-template-columns: 1fr; }
  .comparison section { padding: 24px 0; }
  .comparison section + section { padding: 24px 0 6px; border-top: 1px solid #54544e; border-left: 0; }
  .site-footer { flex-direction: column; }
}

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

@media print {
  body { background: white; }
  .masthead, .intro, .setup, .results-head, .all-head, .post-list, .site-footer { display: none; }
  .results { display: block !important; padding: 0; }
  .featured { box-shadow: none; print-color-adjust: exact; -webkit-print-color-adjust: exact; }
}
