/* The Madison Herald — house style */
:root {
  --paper: #faf8f3;
  --ink: #141414;
  --ink-2: #3b3934;
  --muted: #6b675e;
  --rule: #141414;
  --hair: #d9d4c7;
  --accent: #8a1c14;       /* oxblood, used sparingly */
  --es: #1f3d5c;           /* ink blue for the Spanish desk */
  --tint: #f1ede3;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Libre Franklin", "Helvetica Neue", Arial, sans-serif;
  --wrap: 1180px;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #151513; --ink: #ece8df; --ink-2: #cdc8bd; --muted: #9a958a;
    --rule: #ece8df; --hair: #34322d; --accent: #e07a6c; --es: #8fb3d9; --tint: #1d1c19;
  }
  .masthead__logo img, .footer__brand img, .about__crest { filter: invert(1); }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--serif); font-size: 17px; line-height: 1.5;
  font-optical-sizing: auto; text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
img { max-width: 100%; display: block; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; background: var(--ink); color: var(--paper); padding: 8px 12px; z-index: 10; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- Masthead ---------- */
.masthead { padding-top: 22px; }
.masthead__logo { display: block; max-width: 760px; margin: 0 auto; }
.masthead__logo img { width: 100%; height: auto; }
.masthead__logo:hover { text-decoration: none; }
.masthead__line {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px;
  margin-top: 14px; padding: 8px 0;
  font-family: var(--sans); font-size: 12px; letter-spacing: .02em; color: var(--ink-2);
}
.masthead__date { font-weight: 600; }
.masthead__tagline { font-family: var(--serif); font-style: italic; font-size: 15px; color: var(--ink); }
.masthead__updated { text-align: right; color: var(--muted); }

.nav { border-top: 3px double var(--rule); border-bottom: 1px solid var(--rule); margin-bottom: 28px; }
.nav__inner { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px 20px; padding-top: 10px; padding-bottom: 10px; }
.nav a {
  font-family: var(--sans); font-size: 12.5px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase;
  padding: 2px 0; border-bottom: 2px solid transparent;
}
.nav a:hover { text-decoration: none; border-bottom-color: var(--hair); }
.nav a[aria-current="page"] { border-bottom-color: var(--ink); }
.nav a.nav__es { color: var(--es); }
.nav a.nav__es[aria-current="page"] { border-bottom-color: var(--es); }

/* ---------- Common bits ---------- */
.kicker {
  margin: 0 0 8px; font-family: var(--sans); font-size: 12px; font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase; color: var(--accent);
}
.kicker--small { font-size: 10.5px; margin-bottom: 3px; }
.empty { font-style: italic; color: var(--muted); padding: 60px 0; text-align: center; }

/* ---------- Stories ---------- */
.story { margin: 0; }
.story__title { margin: 0 0 6px; font-weight: 700; line-height: 1.18; letter-spacing: -.005em; text-wrap: balance; }
.story__summary { margin: 0 0 8px; color: var(--ink-2); font-size: 15.5px; line-height: 1.5; }
.story__meta { margin: 0; font-family: var(--sans); font-size: 11.5px; color: var(--muted); letter-spacing: .02em; }
.story__source { font-weight: 600; color: var(--ink-2); text-transform: uppercase; letter-spacing: .06em; font-size: 10.5px; }
.dot { margin: 0 6px; }
.story__img { display: block; overflow: hidden; background: var(--tint); margin-bottom: 12px; }
.story__img img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; transition: transform .6s ease; }
.story__img:hover img { transform: scale(1.02); }

.story--lead .story__title { font-size: clamp(28px, 3.4vw, 42px); line-height: 1.08; margin-bottom: 12px; }
.story--lead .story__summary { font-size: 18.5px; line-height: 1.5; }
.story--lead .story__img img { aspect-ratio: 16 / 9; }
.story--feature .story__title { font-size: 24px; line-height: 1.15; }
.story--feature .story__img img { aspect-ratio: 16 / 10; }
.story--feature .story__summary { font-size: 16px; }
.story--standard .story__title { font-size: 19px; }
.story--compact .story__title { font-size: 16.5px; line-height: 1.25; font-weight: 600; }

/* ---------- Top of page ---------- */
.top { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 0; padding-bottom: 32px; }
.top__lead { padding-right: 36px; border-right: 1px solid var(--hair); }
.top__side { padding-left: 36px; }
.top__beneath { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--hair); }
.top__side > .story { padding: 0 0 18px; margin-bottom: 18px; border-bottom: 1px solid var(--hair); }
.top__side > .story:last-child { border-bottom: 0; }
.rail__title {
  margin: 0 0 14px; padding-bottom: 6px; border-bottom: 2px solid var(--ink);
  font-family: var(--sans); font-size: 13px; letter-spacing: .1em; text-transform: uppercase;
}
.rail__item { padding: 0 0 13px; margin-bottom: 13px; border-bottom: 1px solid var(--hair); }
.rail__item:last-child { border-bottom: 0; }

/* ---------- Section bands (front page) ---------- */
.band { border-top: 2px solid var(--rule); padding: 18px 0 34px; }
.band__head { display: flex; align-items: baseline; flex-wrap: wrap; gap: 4px 16px; margin-bottom: 20px; }
.band__head h2 { margin: 0; font-size: 26px; font-weight: 700; letter-spacing: -.01em; }
.band__head p { margin: 0; font-style: italic; color: var(--muted); font-size: 16px; }
.band__more { margin-left: auto; font-family: var(--sans); font-size: 12px; font-weight: 600; letter-spacing: .04em; color: var(--accent); }
.band__grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 32px; }
.band__list { display: flex; flex-direction: column; gap: 0; }
.band__list .story { padding-bottom: 16px; margin-bottom: 16px; border-bottom: 1px solid var(--hair); }
.band__list .story:last-child { border-bottom: 0; margin-bottom: 0; }
.band--ideas .story__title { font-style: italic; font-weight: 600; }

.band--es { background: var(--tint); border-top: 0; margin: 10px -24px 34px; padding: 26px 24px 30px; box-shadow: inset 0 3px 0 var(--es); }
.band--es .band__eyebrow { font-style: normal; width: 100%; margin: 0; font-family: var(--sans); font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--es); }
.band--es h2 a { color: var(--es); }
.band--es .band__more { color: var(--es); }
.band__cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 26px; }
.band__cols .story + .story { border-left: 1px solid var(--hair); padding-left: 26px; margin-left: -1px; }

/* ---------- Section pages ---------- */
.section-head { text-align: center; padding: 6px 0 24px; }
.section-head h1 { margin: 0; font-size: clamp(34px, 5vw, 52px); letter-spacing: -.015em; }
.section-head p { margin: 6px 0 0; font-style: italic; color: var(--muted); font-size: 18px; }
.lang-es .section-head h1 { color: var(--es); }
.river { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0 36px; border-top: 2px solid var(--rule); padding-top: 22px; margin-bottom: 40px; }
.river .story { padding-bottom: 20px; margin-bottom: 20px; border-bottom: 1px solid var(--hair); }

/* ---------- About ---------- */
.about { max-width: 680px; margin: 10px auto 60px; }
.about h1 { font-size: clamp(32px, 4.5vw, 46px); line-height: 1.1; margin: 0 0 22px; }
.about h2 { font-size: 22px; margin: 40px 0 10px; }
.about p { font-size: 19px; line-height: 1.65; margin: 0 0 18px; }
.about a { border-bottom: 1px solid var(--hair); }
.about__lede { font-size: 23px !important; line-height: 1.45 !important; }
.about__lede::first-letter { float: left; font-size: 72px; line-height: .85; padding: 6px 10px 0 0; font-weight: 700; }
.about__values { font-style: italic; border-left: 3px solid var(--accent); padding-left: 18px; }
.about__crest { margin: 36px auto; opacity: .9; }
.about__sign { text-align: center; margin-top: 40px !important; }
.notfound { text-align: center; padding: 80px 0; }

/* ---------- Our own articles ---------- */
.nav a.nav__orig { color: var(--accent); }
.nav a.nav__orig[aria-current="page"] { border-bottom-color: var(--accent); }
.story__badge {
  display: flex; align-items: center; gap: 7px; margin: 0 0 8px;
  font-family: var(--sans); font-size: 10.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent);
}
.story__badge img { width: 18px; height: auto; }
.story--original .story__title a { text-decoration-color: var(--accent); }
.story--lead.story--original .story__title { font-size: clamp(30px, 3.8vw, 46px); }
.story--lead.story--original .story__summary { font-style: italic; }

.band--orig { border-top: 0; box-shadow: inset 0 3px 0 var(--accent), inset 0 7px 0 var(--paper), inset 0 8px 0 var(--accent); padding-top: 26px; }
.band--orig .band__eyebrow {
  font-style: normal; width: 100%; display: flex; align-items: center; gap: 8px; margin: 0;
  font-family: var(--sans); font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent);
}
.band--orig .band__eyebrow img { width: 22px; height: auto; }
.band--orig .band__more { color: var(--accent); }
.band--orig .story__badge { display: none; }      /* the band already says it */
.band--orig-single .band__grid { grid-template-columns: 1fr; }
.band--orig-single .story--feature.has-img { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 32px; align-items: center; }
.band--orig-single .story--feature .story__img { margin: 0; }
.band--orig-single .story--feature .story__title { font-size: 30px; }

.section-head--orig img { margin: 0 auto 6px; width: 64px; height: auto; }
.section-head--orig h1, .lang-es .section-head--orig h1 { color: var(--accent); }
.section-head__eyebrow { margin: 0 0 4px !important; font-family: var(--sans); font-style: normal !important; font-size: 11px !important; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent) !important; }
.desk-switch { max-width: 860px; margin: -20px auto 50px; text-align: right; font-family: var(--sans); font-size: 13px; font-weight: 600; color: var(--accent); }

.art { max-width: 760px; margin: 8px auto 40px; }
.art__head { text-align: center; margin-bottom: 26px; }
.art__badge {
  display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 4px 8px; margin: 0 0 18px;
  font-family: var(--sans); font-size: 11.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent);
}
.art__badge img { width: 26px; height: auto; }
.art__badge .dot { margin: 0; }
.art h1 { margin: 0 0 14px; font-size: clamp(34px, 5.2vw, 56px); line-height: 1.06; letter-spacing: -.018em; text-wrap: balance; }
.art__dek { margin: 0 auto 18px; max-width: 640px; font-size: 21px; line-height: 1.45; font-style: italic; color: var(--ink-2); text-wrap: balance; }
.art__byline { margin: 0; padding: 12px 0; border-top: 1px solid var(--hair); border-bottom: 1px solid var(--hair); font-family: var(--sans); font-size: 12.5px; color: var(--muted); letter-spacing: .02em; }
.art__author { font-weight: 700; color: var(--ink); text-transform: uppercase; letter-spacing: .08em; font-size: 11.5px; }
.art__hero { margin: 0 0 34px; }
.art__hero img { width: 100%; height: auto; }
.art figcaption { margin-top: 8px; font-family: var(--sans); font-size: 12.5px; line-height: 1.45; color: var(--muted); }
.art__body { max-width: 660px; margin: 0 auto; font-size: 19.5px; line-height: 1.7; }
.art__body > p { margin: 0 0 1.15em; }
.art__body > p:first-child::first-letter { float: left; font-size: 4.1em; line-height: .82; padding: .08em .1em 0 0; font-weight: 700; }
.art__body h2 { font-size: 26px; line-height: 1.2; margin: 1.7em 0 .5em; }
.art__body h3 { font-family: var(--sans); font-size: 14px; letter-spacing: .1em; text-transform: uppercase; margin: 1.8em 0 .5em; }
.art__body a { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.art__body blockquote { margin: 1.6em 0; padding: 0 0 0 22px; border-left: 3px solid var(--accent); font-size: 23px; line-height: 1.45; font-style: italic; }
.art__body blockquote p { margin: 0; }
.art__body ul, .art__body ol { margin: 0 0 1.15em; padding-left: 1.3em; }
.art__body li { margin-bottom: .35em; }
.art__body figure { margin: 1.8em 0; }
.art__body figure img { width: 100%; height: auto; }
.art__body hr.break { border: 0; margin: 2em 0; text-align: center; }
.art__body hr.break::after { content: "✦  ✦  ✦"; color: var(--muted); letter-spacing: .4em; font-size: 13px; }
.art__end { display: inline-block; width: 11px; height: 11px; margin-left: 6px; background: var(--accent); vertical-align: baseline; }
.art__foot { max-width: 660px; margin: 36px auto 0; padding-top: 16px; border-top: 1px solid var(--hair); }
.art__share { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 0; font-family: var(--sans); font-size: 12.5px; font-weight: 600; }
.art__share span { color: var(--muted); text-transform: uppercase; letter-spacing: .1em; font-size: 11px; align-self: center; }

.archive { max-width: 860px; margin: 0 auto 50px; }
.archive__year { margin: 26px 0 0; padding-bottom: 6px; border-bottom: 2px solid var(--rule); font-family: var(--sans); font-size: 13px; letter-spacing: .12em; }
.archive__item { padding: 22px 0; border-bottom: 1px solid var(--hair); }
.archive__item--img { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 26px; align-items: start; }
.archive__img img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; }
.archive .story__title { font-size: 24px; }

@media (prefers-color-scheme: dark) {
  .story__badge img, .band__eyebrow img, .art__badge img, .section-head--orig img { filter: invert(1); }
}

/* ---------- Footer ---------- */
.footer { border-top: 3px double var(--rule); margin-top: 20px; padding: 34px 0 40px; font-family: var(--sans); font-size: 13px; color: var(--ink-2); }
.footer__inner { display: grid; grid-template-columns: 1fr 2fr; gap: 18px 40px; align-items: start; }
.footer__brand img { width: 240px; height: auto; }
.footer__brand p { margin: 8px 0 0; font-family: var(--serif); font-style: italic; font-size: 15px; }
.footer__nav { display: flex; flex-wrap: wrap; gap: 8px 22px; justify-content: flex-end; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; font-size: 12px; }
.footer__note { grid-column: 1 / -1; margin: 10px 0 0; padding-top: 16px; border-top: 1px solid var(--hair); color: var(--muted); font-size: 12px; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .river { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .band__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .band__cols .story:nth-child(odd) { border-left: 0; padding-left: 0; margin-left: 0; }
}
@media (max-width: 780px) {
  body { font-size: 16px; }
  .wrap { padding: 0 16px; }
  .masthead { padding-top: 14px; }
  .masthead__line { grid-template-columns: 1fr; text-align: center; gap: 2px; margin-top: 8px; }
  .masthead__updated { text-align: center; }
  .nav__inner { justify-content: flex-start; flex-wrap: nowrap; overflow-x: auto; gap: 22px; scrollbar-width: none; }
  .nav__inner::-webkit-scrollbar { display: none; }
  .nav a { white-space: nowrap; }
  .top, .band__grid { grid-template-columns: 1fr; }
  .top__side { padding-left: 0; }
  .top__lead { padding-right: 0; border-right: 0; padding-bottom: 24px; margin-bottom: 24px; border-bottom: 2px solid var(--rule); }
  .top__beneath { grid-template-columns: 1fr; gap: 18px; }
  .band__head .band__more { margin-left: 0; width: 100%; }
  .band--es { margin-left: -16px; margin-right: -16px; padding-left: 16px; padding-right: 16px; }
  .band__cols, .river { grid-template-columns: 1fr; }
  .band__cols .story + .story { border-left: 0; padding-left: 0; margin-left: 0; border-top: 1px solid var(--hair); padding-top: 16px; }
  .footer__inner { grid-template-columns: 1fr; }
  .footer__nav { justify-content: flex-start; }
  .band--orig-single .story--feature.has-img { grid-template-columns: 1fr; gap: 0; }
  .band--orig-single .story--feature .story__img { margin-bottom: 12px; }
  .band--orig-single .story--feature .story__title { font-size: 24px; }
  .archive__item--img { grid-template-columns: 1fr; gap: 12px; }
  .art__body { font-size: 18px; }
  .art__dek { font-size: 19px; }
  .art__body blockquote { font-size: 20px; }
}
