:root {
  --counter-ground: #e2e0da;
  --counter-ink: #1a1a1a;
  --counter-tomato: #e4572e;
  --counter-wash: #f6dcd0;
  --counter-reading: "Libre Caslon Text", Georgia, serif;
  --counter-display: "Libre Caslon Display", Georgia, serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 28px; }
body {
  margin: 0;
  background: var(--counter-ground);
  color: var(--counter-ink);
  font: 400 20px/1.85 var(--counter-reading);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .23em; }
a:hover { text-decoration-color: var(--counter-tomato); text-decoration-thickness: 3px; }
a:focus-visible { outline: 2px solid var(--counter-ink); outline-offset: 5px; background: var(--counter-wash); }
::selection { color: var(--counter-ink); background: var(--counter-wash); }
img { display: block; max-width: 100%; object-fit: cover; }
figure { margin: 0; }
figcaption { font-size: 18px; line-height: 1.6; margin-top: 13px; }
p { margin: 0 0 1.3em; }
h1, h2, h3 { font-family: var(--counter-display); font-weight: 400; line-height: 1.05; }
h1 { font-size: clamp(48px, 5.3vw, 76px); letter-spacing: -.025em; margin: 0; text-wrap: balance; }
h2 { font-size: 52px; letter-spacing: -.018em; margin: 0 0 28px; text-wrap: balance; }
h3 { font-size: 34px; margin: 0 0 20px; }
i[data-lucide], svg.lucide { display: inline-block; flex: 0 0 auto; width: 20px; height: 20px; vertical-align: -.17em; }
.counter-skip { position: absolute; left: 20px; top: -100px; padding: 8px 18px; background: var(--counter-ground); z-index: 5; }
.counter-skip:focus { top: 12px; }

/* The name occupies the entire receipt head; the three purposes sit below it. */
.counter-mast {
  max-width: 1100px;
  margin: 24px auto 0;
  border-block: 1px solid var(--counter-tomato);
  padding: 19px 0 21px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 17px 46px;
}
.counter-name {
  grid-column: 1 / -1;
  font-family: var(--counter-display);
  font-size: clamp(64px, 7.5vw, 108px);
  line-height: 1;
  letter-spacing: -.035em;
  text-decoration: none;
  text-align: center;
}
.counter-name:hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .09em; }
.counter-head-pair { font-size: 18px; line-height: 1.55; }
.counter-head-pair a { display: inline-flex; align-items: center; gap: 9px; margin-bottom: 4px; }
.counter-head-pair span { display: block; padding-left: 29px; }

/* One shallow photograph, never a background or a surface for text. */
.counter-opening { max-width: 1100px; margin: 0 auto; padding: 31px 0 29px; }
.counter-opening h1 { max-width: 800px; margin: 0 auto 24px; text-align: center; font-size: 62px; line-height: 1.02; }
.counter-first-photo { width: 100%; max-width: 760px; margin: 0 auto; }
.counter-first-photo img { width: 760px; height: 170px; animation: counter-arrival .85s ease-out; }
.counter-first-photo figcaption { max-width: 760px; }
.counter-opening-sentences { display: grid; grid-template-columns: 1fr 1.16fr 1fr; gap: 42px; padding-top: 27px; font-size: 18px; line-height: 1.65; }
.counter-opening-sentences p { border-top: 1px solid var(--counter-tomato); padding-top: 12px; margin: 0; }
.counter-tomato-field { background: var(--counter-tomato); padding: 24px; }
.counter-tomato-field p { max-width: 1100px; margin: auto; font-size: 23px; line-height: 1.5; text-align: center; }

/* Each condition has its own measure. The numeral lives outside the prose. */
.counter-conditions { max-width: 1100px; margin: 79px auto 0; }
.counter-condition { position: relative; display: grid; grid-template-columns: 140px 310px minmax(0, 1fr); gap: 32px; padding: 60px 0 65px; border-bottom: 1px solid var(--counter-tomato); align-items: start; }
.counter-condition:first-child { border-top: 1px solid var(--counter-tomato); }
.counter-condition-count { position: sticky; top: 32px; color: var(--counter-tomato); font-family: var(--counter-reading); font-size: 164px; line-height: .85; transform: translateY(-23px); }
.counter-condition h2 { font-size: 53px; margin-bottom: 0; }
.counter-condition p:last-child { margin-bottom: 0; }
.counter-condition-request { grid-template-columns: 140px 365px minmax(0, 1fr); padding-top: 89px; padding-bottom: 83px; }
.counter-condition-unknown { grid-template-columns: 140px 280px minmax(0, 1fr); padding-top: 55px; padding-bottom: 59px; }
.counter-condition::after { content: ""; position: absolute; right: 0; bottom: 16px; width: 32px; height: 16px; border-block: 2px solid var(--counter-tomato); border-right: 2px solid var(--counter-tomato); }
.counter-return { max-width: 640px; margin: 122px auto 111px; }
.counter-return h2 { width: calc(100% + 260px); margin-left: -130px; margin-bottom: 43px; font-size: 73px; }
.counter-return > p:first-of-type { font-size: 25px; line-height: 1.7; }
.counter-return > p:first-of-type::first-letter { float: left; font-family: var(--counter-display); font-size: 88px; line-height: .92; padding: 5px 8px 0 0; }
.counter-wide-close { background: var(--counter-tomato); margin: 0; padding: 68px max(30px, calc((100% - 1100px) / 2)) 77px; }
.counter-wide-close h2 { max-width: 1050px; font-size: 80px; margin-bottom: 27px; }
.counter-wide-close p { max-width: 1000px; font-size: 26px; line-height: 1.7; margin: 0; }
.counter-wide-close a:hover { text-decoration-color: var(--counter-ink); }

/* Headings hang into the wide margin; the account remains one readable column. */
.counter-breadcrumb { max-width: 1100px; margin: 25px auto 0; font-size: 18px; line-height: 1.6; }
.counter-breadcrumb ol { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.counter-breadcrumb li + li::before { content: "/"; margin-right: 10px; }
.counter-inner-intro { max-width: 1100px; margin: 45px auto 61px; }
.counter-inner-intro h1 { max-width: 1000px; }
.counter-inner-intro > p { max-width: 640px; margin: 33px auto 0; font-size: 24px; line-height: 1.7; }
.counter-reading { max-width: 640px; margin: 0 auto 97px; }
.counter-reading > section { position: relative; padding-top: 46px; margin-top: 44px; }
.counter-reading > section:first-child { margin-top: 0; padding-top: 0; }
.counter-reading > section + section::before { content: ""; position: absolute; top: 0; left: -115px; width: 76px; border-top: 1px solid var(--counter-tomato); }
.counter-reading > section > h2 { width: calc(100% + 230px); margin-left: -115px; }
.counter-reading > section > p:last-child { margin-bottom: 0; }
.counter-section-photo { width: 760px; max-width: none; margin: 37px 0 42px -120px; }
.counter-section-photo img { width: 760px; height: 150px; }
.counter-section-photo figcaption { max-width: 640px; margin-left: 120px; }
.counter-questions h2 { font-size: 48px; }
.counter-source-entry { padding-bottom: 8px; }
.counter-source-entry h2 { font-size: 43px; }
.counter-foot { padding: 42px 24px 34px; font-size: 18px; line-height: 1.75; }
.counter-foot-inner { max-width: 1100px; margin: auto; }
.counter-foot-nav { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 17px 24px; padding-bottom: 31px; margin-bottom: 27px; border-bottom: 1px solid var(--counter-tomato); }
.counter-foot-nav a { display: flex; align-items: center; gap: 10px; width: fit-content; }
.counter-foot p { max-width: 850px; margin-bottom: 13px; }
.counter-foot .counter-copyright { margin: 0; }
@keyframes counter-arrival { from { transform: translateY(7px); } to { transform: translateY(0); } }

@media (max-width: 1160px) {
  .counter-mast, .counter-opening, .counter-conditions, .counter-breadcrumb, .counter-inner-intro { margin-left: 30px; margin-right: 30px; }
  .counter-mast { gap: 17px 25px; }
  .counter-condition { grid-template-columns: 85px 29% minmax(0, 1fr); gap: 25px; }
  .counter-condition-count { font-size: 126px; transform: translateY(-12px); }
  .counter-condition h2 { font-size: 46px; }
  .counter-return h2 { width: calc(100% + 80px); margin-left: -40px; font-size: 64px; }
  .counter-reading > section > h2 { width: calc(100% + 100px); margin-left: -50px; }
  .counter-reading > section + section::before { left: -50px; width: 40px; }
  .counter-section-photo { max-width: calc(100vw - 60px); margin-left: max(-120px, calc((640px - (100vw - 60px)) / 2)); }
  .counter-section-photo img { width: 100%; }
  .counter-section-photo figcaption { margin-left: 0; }
}

@media (max-width: 760px) {
  body { font-size: 18px; line-height: 1.85; }
  h2 { font-size: 39px; }
  .counter-mast, .counter-opening, .counter-conditions, .counter-breadcrumb, .counter-inner-intro { margin-left: 20px; margin-right: 20px; }
  .counter-mast { display: block; margin-top: 14px; padding: 15px 0 17px; }
  .counter-name { display: block; font-size: clamp(42px, 12.3vw, 64px); line-height: .99; padding-bottom: 17px; text-align: left; text-wrap: balance; }
  .counter-head-pair { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; margin-top: 8px; font-size: 18px; }
  .counter-head-pair a { margin: 0; gap: 6px; white-space: nowrap; }
  .counter-head-pair span { padding: 0; text-align: right; }
  .counter-head-pair i[data-lucide], .counter-head-pair svg.lucide { width: 16px; height: 16px; }
  .counter-opening { padding-top: 25px; padding-bottom: 27px; }
  .counter-opening h1 { font-size: 41px; line-height: 1.04; margin-bottom: 21px; }
  .counter-first-photo img { width: 100%; height: 130px; object-position: 50% 50%; }
  .counter-first-photo figcaption { margin-top: 12px; }
  .counter-opening-sentences { display: block; padding-top: 23px; font-size: 18px; line-height: 1.7; }
  .counter-opening-sentences p { padding-top: 0; border-top: 0; }
  .counter-opening-sentences p + p { margin-top: 17px; }
  .counter-tomato-field { padding: 23px 20px; }
  .counter-tomato-field p { font-size: 22px; text-align: left; line-height: 1.6; }
  .counter-conditions { margin-top: 52px; }
  .counter-condition { grid-template-columns: 48px minmax(0, 1fr); gap: 0 19px; padding-top: 35px; padding-bottom: 43px; }
  .counter-condition-count { position: static; grid-row: 1 / span 2; font-size: 77px; transform: translateY(-5px); }
  .counter-condition h2 { font-size: 39px; padding: 0; margin-bottom: 22px; }
  .counter-condition > div { grid-column: 2; }
  .counter-condition-request { padding-top: 48px; padding-bottom: 49px; }
  .counter-condition-unknown { padding-top: 34px; }
  .counter-return { margin: 74px 25px 70px; }
  .counter-return h2 { font-size: 49px; width: auto; margin: 0 -5px 32px; }
  .counter-return > p:first-of-type { font-size: 22px; line-height: 1.75; }
  .counter-return > p:first-of-type::first-letter { font-size: 77px; padding-top: 3px; }
  .counter-wide-close { padding: 38px 20px 47px; }
  .counter-wide-close h2 { font-size: 53px; }
  .counter-wide-close p { font-size: 22px; }
  .counter-breadcrumb { margin-top: 22px; }
  .counter-inner-intro { margin-top: 33px; margin-bottom: 38px; }
  .counter-inner-intro h1 { font-size: 48px; }
  .counter-inner-intro > p { margin-top: 26px; font-size: 22px; }
  .counter-reading { margin: 0 25px 65px; }
  .counter-reading > section { padding-top: 36px; margin-top: 35px; }
  .counter-reading > section > h2 { width: auto; margin-left: -5px; margin-right: -5px; }
  .counter-reading > section + section::before { left: -5px; width: 57px; }
  .counter-section-photo { width: calc(100% + 10px); max-width: calc(100% + 10px); margin: 29px -5px 32px; }
  .counter-section-photo img { height: 120px; }
  .counter-section-photo figcaption { margin-left: 5px; max-width: calc(100% - 10px); }
  .counter-questions h2 { font-size: 39px; }
  .counter-source-entry h2 { font-size: 37px; }
  .counter-foot { padding: 33px 20px 29px; }
  .counter-foot-nav { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px 16px; }
  .counter-foot-nav a { gap: 7px; }
  .counter-foot-nav i[data-lucide], .counter-foot-nav svg.lucide { width: 18px; height: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .counter-first-photo img { animation: none; }
}
