/* Kivorent News. Three beats, three colors; the color bar always tells you which beat you are in. */
:root {
  --paper: #f6f7fa;
  --card: #ffffff;
  --ink: #0f1e3d;
  --ink-soft: #46526d;
  --line: #d5dae5;
  --tech: #2b4bf2;
  --health: #087a63;
  --markets: #9a5b00;
  --beat: var(--ink);
  --display: "Bricolage Grotesque", "Arial Narrow", Arial, sans-serif;
  --text: "Source Serif 4", Georgia, "Times New Roman", serif;
  --measure: 68ch;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--text);
  font-size: 1.125rem;
  line-height: 1.65;
}
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--tech); outline-offset: 2px; border-radius: 2px; }
h1, h2, h3 { font-family: var(--display); line-height: 1.08; letter-spacing: -0.015em; margin: 0; text-wrap: balance; }
p { margin: 0; }
.wrap { max-width: 76rem; margin-inline: auto; padding-inline: 1.25rem; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.hp { position: absolute; left: -200vw; width: 1px; height: 1px; opacity: 0; }
.skip { position: absolute; left: 1rem; top: -4rem; background: var(--ink); color: #fff; padding: 0.5rem 0.9rem; font-family: var(--display); z-index: 10; }
.skip:focus { top: 1rem; }

/* beat color plumbing */
.spine-tech, .beat-tech, .lane-tech, .on-tech { --beat: var(--tech); }
.spine-health, .beat-health, .lane-health, .on-health { --beat: var(--health); }
.spine-markets, .beat-markets, .lane-markets, .on-markets { --beat: var(--markets); }
.beat { font-family: var(--display); font-size: 0.875rem; font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: 0.45em; }
a.beat:hover { text-decoration: underline; }
.sq { width: 0.7em; height: 0.7em; background: var(--beat); display: inline-block; }
.kind { font-family: var(--display); font-size: 0.875rem; color: var(--ink-soft); }
.card-meta { display: flex; flex-wrap: wrap; gap: 0.25rem 0.9rem; align-items: center; margin-bottom: 0.5rem; }

/* masthead */
.mast { background: var(--card); border-bottom: 8px solid var(--beat); }
.mast-in { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; padding-block: 1.1rem 0.6rem; flex-wrap: wrap; }
.wordmark { font-family: var(--display); font-weight: 800; font-size: clamp(1.9rem, 4vw, 2.75rem); letter-spacing: -0.035em; text-decoration: none; line-height: 1; }
.wm-news { font-weight: 300; }
.mast-date { font-family: var(--display); font-size: 0.9rem; color: var(--ink-soft); }
.nav { display: flex; flex-wrap: wrap; gap: 0.2rem 1.5rem; padding-block: 0.5rem 0.9rem; font-family: var(--display); font-size: 0.98rem; font-weight: 500; }
.nav a { text-decoration: none; padding-block: 0.15rem; border-bottom: 3px solid transparent; }
.nav a:hover, .nav a[aria-current="page"] { border-bottom-color: var(--ink); }
.nav .nav-tech:hover, .nav .nav-tech[aria-current] { border-bottom-color: var(--tech); }
.nav .nav-health:hover, .nav .nav-health[aria-current] { border-bottom-color: var(--health); }
.nav .nav-markets:hover, .nav .nav-markets[aria-current] { border-bottom-color: var(--markets); }
.nav-end { margin-left: auto; }

/* front page: lead + latest */
.top { display: grid; grid-template-columns: minmax(0, 2.1fr) minmax(0, 1fr); gap: 3rem; padding-block: 3rem 3.25rem; }
.lead h1 { font-size: clamp(2.3rem, 5.4vw, 4.6rem); font-weight: 750; line-height: 0.98; letter-spacing: -0.03em; }
.lead h1 a { text-decoration: none; }
.lead h1 a:hover { text-decoration: underline; text-decoration-thickness: 0.06em; text-decoration-color: var(--beat); }
.lead-dek { font-size: 1.3rem; line-height: 1.45; margin-top: 1.25rem; max-width: 44ch; }
.lead-date { font-family: var(--display); font-size: 0.9rem; color: var(--ink-soft); margin-top: 1rem; }
.latest h2 { font-size: 1.05rem; font-weight: 700; padding-bottom: 0.6rem; border-bottom: 2px solid var(--ink); }
.latest ol { list-style: none; margin: 0; padding: 0; }
.latest li { padding: 0.85rem 0 0.9rem 0.9rem; border-bottom: 1px solid var(--line); border-left: 4px solid var(--beat); margin-top: 0.75rem; }
.latest-t { display: block; font-family: var(--display); font-weight: 600; font-size: 1.08rem; line-height: 1.2; text-decoration: none; margin-top: 0.25rem; }
.latest-t:hover { text-decoration: underline; }

/* the three lanes */
.lanes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem; padding-bottom: 3.5rem; }
.lane { background: var(--card); border-top: 10px solid var(--beat); padding: 1.25rem 1.35rem 1.4rem; }
.lane > h2 { font-size: 1.5rem; font-weight: 750; }
.lane > h2 a { text-decoration: none; }
.lane > h2 a:hover { text-decoration: underline; text-decoration-color: var(--beat); }
.lane-blurb { font-size: 0.98rem; line-height: 1.45; color: var(--ink-soft); margin-top: 0.4rem; }
.lane-item { border-top: 1px solid var(--line); padding-top: 0.9rem; margin-top: 1rem; }
.lane-item h3 { font-size: 1.14rem; font-weight: 600; line-height: 1.2; margin-top: 0.15rem; }
.lane-item h3 a { text-decoration: none; }
.lane-item h3 a:hover { text-decoration: underline; }
.card-dek { font-size: 1rem; line-height: 1.5; color: var(--ink-soft); margin-top: 0.45rem; }
.lane-more { font-family: var(--display); font-size: 0.95rem; font-weight: 600; margin-top: 1.25rem; }

/* how it works strip */
.how { border-top: 2px solid var(--ink); padding-block: 2.25rem 3.5rem; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.4fr); gap: 1.5rem 3rem; }
.how-head h2 { font-size: 2rem; font-weight: 750; }
.how-head p { color: var(--ink-soft); margin-top: 0.6rem; font-size: 1rem; line-height: 1.5; }
.how-list { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 2.5rem; }
.how-list li { break-inside: avoid; border-left: 4px solid var(--beat); padding: 0.15rem 0 0.15rem 0.8rem; margin-bottom: 0.95rem; font-family: var(--display); font-weight: 600; font-size: 1.05rem; line-height: 1.25; }
.how-list a { text-decoration: none; }
.how-list a:hover { text-decoration: underline; }
.how-more { grid-column: 2; font-family: var(--display); font-weight: 600; font-size: 0.95rem; }

/* newsletter band */
.signup { background: var(--ink); color: #fff; }
.signup-in { max-width: 76rem; margin-inline: auto; padding: 2.75rem 1.25rem 3rem; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0.75rem 3rem; align-items: start; }
.signup h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 750; grid-column: 1; }
.signup-in > p { grid-column: 1; color: #cfd6e6; font-size: 1.02rem; line-height: 1.5; max-width: 46ch; }
.signup .signup-form { grid-column: 2; grid-row: 1 / span 2; align-self: center; }
.signup-form { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0.6rem; }
.signup-form input[type="email"], .stack-form input, .stack-form textarea, .stack-form select {
  font: inherit; font-family: var(--display); font-size: 1rem; padding: 0.8rem 0.9rem; border: 2px solid var(--ink); background: #fff; color: var(--ink); border-radius: 0; width: 100%;
}
.signup .signup-form input[type="email"] { border-color: #fff; }
button { font-family: var(--display); font-weight: 700; font-size: 1rem; padding: 0.8rem 1.3rem; border: 2px solid var(--ink); background: var(--ink); color: #fff; cursor: pointer; }
.signup button { background: #fff; color: var(--ink); border-color: #fff; }
button:hover { filter: brightness(1.15); }
.signup button:hover { filter: none; background: #e3e8f4; }
button[disabled] { opacity: 0.6; cursor: progress; }
.form-msg { grid-column: 1 / -1; font-family: var(--display); font-size: 0.95rem; min-height: 1.4em; }
.form-msg.err { color: #b3261e; }
.signup .form-msg.err { color: #ffb4ab; }
.signup-form.on-page { margin-block: 1.75rem 1.25rem; max-width: 34rem; }

/* section and list pages */
.sec-head { padding-block: 2.75rem 2rem; }
.sec-head h1 { font-size: clamp(2.2rem, 5vw, 3.6rem); font-weight: 750; letter-spacing: -0.03em; }
.sec-head p { font-size: 1.2rem; color: var(--ink-soft); margin-top: 0.6rem; max-width: 52ch; }
.list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 3rem; padding-bottom: 3.5rem; }
.row { border-top: 1px solid var(--line); border-left: 4px solid var(--beat); padding: 1.1rem 0 1.3rem 1rem; margin-top: 1rem; }
.row h2 { font-size: 1.4rem; font-weight: 650; line-height: 1.15; }
.row h2 a { text-decoration: none; }
.row h2 a:hover { text-decoration: underline; }
.row-date { font-family: var(--display); font-size: 0.875rem; color: var(--ink-soft); }

/* story */
.story-head { padding-block: 2.75rem 1.75rem; max-width: 58rem; margin-inline: auto; }
.story-head h1 { font-size: clamp(2.1rem, 4.6vw, 3.6rem); font-weight: 750; line-height: 1.02; letter-spacing: -0.028em; }
.story-dek { font-size: 1.35rem; line-height: 1.45; margin-top: 1.1rem; max-width: 50ch; }
.story-by { font-family: var(--display); font-size: 0.92rem; color: var(--ink-soft); margin-top: 1.1rem; }
.story-grid { display: grid; grid-template-columns: minmax(0, 1fr) 17rem; gap: 3.5rem; max-width: 58rem; margin-inline: auto; padding-bottom: 3.5rem; }
.story-body { max-width: var(--measure); }
.story-body > p, .prose > p { margin-top: 1.15em; }
.story-body h2, .prose h2 { font-size: 1.55rem; font-weight: 700; margin-top: 2.2rem; }
.story-body h3 { font-size: 1.2rem; font-weight: 700; margin-top: 1.7rem; }
.story-body ul, .story-body ol, .prose ul { padding-left: 1.2rem; margin: 1em 0 0; }
.story-body li, .prose li { margin-top: 0.45em; }
.story-body a, .prose a { text-decoration-color: var(--beat); text-decoration-thickness: 2px; }
.story-body table { border-collapse: collapse; width: 100%; margin-top: 1.4rem; font-family: var(--display); font-size: 0.98rem; }
.story-body th, .story-body td { text-align: left; padding: 0.55rem 0.7rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.story-body th { border-bottom: 2px solid var(--ink); font-weight: 700; }
.know { background: var(--card); border-left: 8px solid var(--beat); padding: 1.1rem 1.3rem 1.25rem; }
.story-body .know h2 { font-size: 1.05rem; margin-top: 0; }
.know ul { margin-top: 0.5rem; }
.know li { font-family: var(--display); font-size: 1.02rem; line-height: 1.4; }
.disclaimer { font-family: var(--display); font-size: 0.92rem; line-height: 1.45; color: var(--ink-soft); border-top: 1px solid var(--line); padding-top: 1rem; margin-top: 2.25rem !important; }
.sources { margin-top: 2rem; border-top: 2px solid var(--ink); padding-top: 0.9rem; }
.story-body .sources h2 { font-size: 1.05rem; margin-top: 0; }
.sources li { font-family: var(--display); font-size: 0.98rem; line-height: 1.4; }
.fix { font-family: var(--display); font-size: 0.92rem; color: var(--ink-soft); margin-top: 1.5rem !important; }
.story-side h2 { font-size: 1.05rem; font-weight: 700; padding-bottom: 0.55rem; border-bottom: 2px solid var(--beat); }
.side-item { border-bottom: 1px solid var(--line); padding-block: 0.8rem 0.9rem; }
.side-item h3 { font-size: 1.05rem; font-weight: 600; line-height: 1.2; margin-top: 0.1rem; }
.side-item h3 a { text-decoration: none; }
.side-item h3 a:hover { text-decoration: underline; }
.ad { margin: 0 auto 1.5rem; max-width: 76rem; padding-inline: 1.25rem; }

/* plain pages */
.prose { max-width: 46rem; padding-block: 2.75rem 3.5rem; }
.prose h1 { font-size: clamp(2.1rem, 4.6vw, 3.3rem); font-weight: 750; letter-spacing: -0.028em; }
.prose-lede { font-size: 1.3rem; line-height: 1.45; margin-top: 1rem !important; }
.stack-form { display: grid; gap: 0.4rem; margin-top: 1.4rem; max-width: 34rem; }
.stack-form label { font-family: var(--display); font-weight: 600; font-size: 0.95rem; margin-top: 0.7rem; }
.stack-form button { justify-self: start; margin-top: 0.9rem; }

/* footer */
.foot { background: var(--card); border-top: 1px solid var(--line); font-family: var(--display); font-size: 0.95rem; }
.foot-in { display: flex; justify-content: space-between; gap: 2rem; flex-wrap: wrap; padding-block: 2rem 2.5rem; }
.foot-name { font-weight: 800; font-size: 1.15rem; letter-spacing: -0.02em; margin-bottom: 0.3rem; }
.foot nav { display: flex; flex-wrap: wrap; gap: 0.4rem 1.4rem; align-content: start; }

/* the last 18 months, and the archive */
.back { border-top: 2px solid var(--ink); padding-block: 2.25rem 3.5rem; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2.4fr); gap: 1.5rem 3rem; }
.back-list { list-style: none; margin: 0; padding: 0; columns: 2; column-gap: 2.5rem; }
.back-list li { break-inside: avoid; border-left: 4px solid var(--beat); padding: 0.1rem 0 0.2rem 0.8rem; margin-bottom: 1rem; font-family: var(--display); line-height: 1.25; }
.back-when { display: block; font-size: 0.875rem; color: var(--ink-soft); }
.back-list a { font-weight: 600; font-size: 1.05rem; text-decoration: none; }
.back-list a:hover { text-decoration: underline; }
.back .how-more { grid-column: 2; }
.months { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 3rem; padding-bottom: 3.5rem; }
.month { border-top: 2px solid var(--ink); padding-top: 0.9rem; margin-top: 1.75rem; }
.month h2 { font-size: 1.5rem; font-weight: 750; }
.month ul { list-style: none; margin: 0; padding: 0; }
.month li { border-left: 4px solid var(--beat); padding: 0.2rem 0 0.3rem 0.9rem; margin-top: 1rem; }
.month-t { font-family: var(--display); font-weight: 600; font-size: 1.12rem; line-height: 1.2; text-decoration: none; }
.month-t:hover { text-decoration: underline; }
.lookback { font-family: var(--display); font-size: 0.98rem; line-height: 1.45; border: 2px solid var(--ink); padding: 0.75rem 1rem; margin-bottom: 1.25rem; }

@media (max-width: 60rem) {
  .back { grid-template-columns: 1fr; }
  .back .how-more { grid-column: 1; }
  .months { grid-template-columns: 1fr; }
  .top { grid-template-columns: 1fr; gap: 2rem; padding-block: 2rem 2.5rem; }
  .lanes { grid-template-columns: 1fr; gap: 1.5rem; }
  .how { grid-template-columns: 1fr; }
  .how-more { grid-column: 1; }
  .signup-in { grid-template-columns: 1fr; }
  .signup .signup-form { grid-column: 1; grid-row: auto; margin-top: 0.75rem; }
  .list { grid-template-columns: 1fr; }
  .story-grid { grid-template-columns: 1fr; gap: 2.5rem; }
}
@media (max-width: 36rem) {
  body { font-size: 1.06rem; }
  .wrap, .signup-in { padding-inline: 1rem; }
  .how-list { columns: 1; }
  .back-list { columns: 1; }
  .nav { gap: 0.2rem 1.1rem; font-size: 0.94rem; }
  .nav-end { margin-left: 0; }
  .signup-form { grid-template-columns: 1fr; }
  .lead-dek, .story-dek { font-size: 1.15rem; }
}
@media (prefers-reduced-motion: no-preference) {
  .nav a { transition: border-color 0.12s; }
}
@media print {
  .mast nav, .signup, .story-side, .foot, .fix { display: none; }
  body { background: #fff; }
}
