/* Hallmark · pre-emit critique: P4 H5 E4 S4 R4 V4
   DNA: Wirecutter editorial review (kickers, featured story, category lanes)
   Anchored on VendorCAD charcoal/cyan — cool paper, not warm cream. */

:root {
  --bg: #f6f7f9;
  --bg-ink: #0f1419;
  --surface: #ffffff;
  --surface-2: #eef1f4;
  --ink: #12151a;
  --muted: #5c6670;
  --accent: #0891b2;
  --accent-deep: #0e7490;
  --accent-soft: rgba(8, 145, 178, 0.1);
  --line: #d8dee6;
  --line-strong: #b8c0cb;
  --pass: #1b6b45;
  --max: 40rem;
  --wide: 68rem;
  --font-display: "Source Serif 4", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  --font-body: "Source Sans 3", "Segoe UI", system-ui, sans-serif;
  --font-label: "IBM Plex Mono", ui-monospace, monospace;
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html,
body {
  overflow-x: clip;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.65;
  font-size: 1.0625rem;
  font-weight: 400;
}

a {
  color: var(--accent-deep);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

a:hover {
  color: #155e75;
}

img {
  max-width: 100%;
  height: auto;
}

.skip {
  position: absolute;
  left: -9999px;
}

.skip:focus {
  left: 1rem;
  top: 1rem;
  z-index: 50;
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 0.5rem 0.75rem;
}

/* —— Header (Wirecutter: clean bar + utility strip) —— */

.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 20;
}

.site-header__inner,
.site-footer__inner,
.wrap,
.wrap-wide {
  width: min(100% - 2rem, var(--wide));
  margin-inline: auto;
}

.ownership-bar {
  background: var(--bg-ink);
  color: #c5ced6;
  border-top: none;
  padding: 0.4rem 0;
}

.ownership-bar p {
  margin: 0;
  font-size: 0.78rem;
  letter-spacing: 0.01em;
}

.ownership-bar strong {
  color: #fff;
  font-weight: 600;
}

.ownership-bar a {
  color: #67e8f9;
}

.ownership-bar a:hover {
  color: #a5f3fc;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.95rem 0;
}

.brand {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  color: var(--ink);
  text-decoration: none;
  min-width: 0;
}

.brand__name {
  font-family: var(--font-display);
  font-weight: 650;
  font-style: normal;
  letter-spacing: -0.02em;
  font-size: 1.35rem;
  line-height: 1.15;
  overflow-wrap: anywhere;
}

.brand__name span {
  color: var(--accent);
}

.brand__sub {
  color: var(--muted);
  font-size: 0.72rem;
  font-family: var(--font-label);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.55rem 1.15rem;
  font-size: 0.95rem;
  font-weight: 600;
}

.nav a {
  color: var(--ink);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  padding-bottom: 0.1rem;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--accent-deep);
  border-bottom-color: var(--accent);
}

/* —— Hero as featured story —— */

.hero {
  padding: 2.75rem 0 2.5rem;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}

.hero .wrap {
  width: min(100% - 2rem, var(--wide));
  display: grid;
  gap: 1.75rem;
}

@media (min-width: 900px) {
  .hero .wrap {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
    align-items: end;
    gap: 2.5rem;
  }
}

.hero__featured {
  min-width: 0;
}

.eyebrow,
.kicker {
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-deep);
  margin: 0 0 0.75rem;
  font-weight: 600;
}

.hero h1,
.article h1 {
  font-family: var(--font-display);
  font-weight: 650;
  font-style: normal;
  letter-spacing: -0.025em;
  line-height: 1.12;
  font-size: clamp(2rem, 4.5vw, 3.15rem);
  margin: 0 0 1rem;
  color: var(--ink);
  overflow-wrap: anywhere;
  min-width: 0;
}

.lede {
  font-size: 1.2rem;
  color: var(--muted);
  margin: 0 0 1.5rem;
  max-width: 36rem;
  line-height: 1.55;
}

.hero__rail {
  background: var(--surface-2);
  border: 1px solid var(--line);
  padding: 1.25rem 1.2rem;
  min-width: 0;
}

.hero__rail h2 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin: 0 0 0.85rem;
  font-weight: 650;
}

.hero__rail ol {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--muted);
  font-size: 0.95rem;
}

.hero__rail li + li {
  margin-top: 0.55rem;
}

.hero__rail a {
  color: var(--ink);
  font-weight: 600;
  text-decoration: none;
}

.hero__rail a:hover {
  color: var(--accent-deep);
  text-decoration: underline;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0.55rem 1.15rem;
  border-radius: 0.15rem;
  font-weight: 650;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1px solid transparent;
  letter-spacing: 0.01em;
}

.btn--primary {
  background: var(--accent);
  color: #fff;
}

.btn--primary:hover {
  background: var(--accent-deep);
  color: #fff;
}

.btn--ghost {
  border-color: var(--line-strong);
  color: var(--ink);
  background: var(--surface);
}

.btn--ghost:hover {
  border-color: var(--ink);
  color: var(--ink);
}

/* —— Article body —— */

.main {
  padding: 2rem 0 4rem;
}

.main .wrap {
  width: min(100% - 2rem, var(--max));
}

.main .wrap--wide {
  width: min(100% - 2rem, var(--wide));
}

.article h2 {
  font-family: var(--font-display);
  font-style: normal;
  font-size: 1.55rem;
  margin: 2.5rem 0 0.85rem;
  letter-spacing: -0.02em;
  font-weight: 650;
  line-height: 1.2;
}

.article h3 {
  font-family: var(--font-display);
  font-style: normal;
  font-size: 1.2rem;
  margin: 1.85rem 0 0.55rem;
  font-weight: 650;
}

.article p,
.article li {
  color: #2a3139;
}

.article ul,
.article ol {
  padding-left: 1.25rem;
}

.article li + li {
  margin-top: 0.4rem;
}

.article blockquote {
  margin: 1.35rem 0;
  padding: 1rem 1.15rem;
  border: 1px solid var(--line);
  background: var(--surface-2);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: 1.15rem;
  line-height: 1.45;
}

.article table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.25rem 0 1.75rem;
  font-size: 0.95rem;
  background: var(--surface);
}

.article th,
.article td {
  border: 1px solid var(--line);
  padding: 0.7rem 0.8rem;
  text-align: left;
  vertical-align: top;
}

.article th {
  background: var(--surface-2);
  color: var(--ink);
  font-weight: 650;
}

.answer-box {
  background: var(--accent-soft);
  border: 1px solid rgba(8, 145, 178, 0.28);
  border-top: 3px solid var(--accent);
  border-radius: 0;
  padding: 1.1rem 1.2rem;
  margin: 0 0 1.75rem;
}

.answer-box p {
  margin: 0;
  color: var(--ink);
}

.answer-box strong {
  font-family: var(--font-label);
  font-size: 0.72rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--accent-deep);
  display: block;
  margin-bottom: 0.45rem;
  font-weight: 600;
}

.meta-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.1rem;
  color: var(--muted);
  font-size: 0.88rem;
  margin: 0 0 1.35rem;
  padding-bottom: 1.1rem;
  border-bottom: 1px solid var(--line);
}

.disclosure {
  margin-top: 2.75rem;
  padding: 1.1rem 1.15rem;
  border: 1px solid var(--line);
  background: var(--surface-2);
  border-radius: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

/* —— Story cards (Wirecutter “latest” lanes) —— */

.card-grid {
  display: grid;
  gap: 0;
  margin: 1.25rem 0 2rem;
  border-top: 1px solid var(--line);
}

@media (min-width: 720px) {
  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1000px) {
  .main .wrap--wide .card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.card {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: 1.35rem 1.15rem 1.45rem;
  background: var(--surface);
  border: none;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  border-radius: 0;
  text-decoration: none;
  color: inherit;
  min-width: 0;
  transition: background 0.15s ease;
}

.card:hover {
  background: #f0f7fa;
}

.card:hover h3 {
  color: var(--accent-deep);
}

.card-kicker {
  font-family: var(--font-label);
  font-size: 0.68rem;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--accent-deep);
  margin: 0;
  font-weight: 600;
}

.card h2,
.card h3 {
  margin: 0;
  font-family: var(--font-display);
  font-style: normal;
  font-size: 1.2rem;
  font-weight: 650;
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.45;
}

.card-meta {
  margin-top: auto !important;
  padding-top: 0.65rem;
  font-family: var(--font-label);
  font-size: 0.72rem !important;
  color: var(--muted);
  letter-spacing: 0.02em;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin: 0 0 1.25rem;
}

.tag {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border: 1px solid var(--line);
  border-radius: 0.1rem;
  font-size: 0.78rem;
  color: var(--muted);
  text-decoration: none;
  background: var(--surface);
  font-family: var(--font-label);
}

.tag:hover {
  color: var(--accent-deep);
  border-color: var(--accent);
}

.article .lede {
  color: var(--muted);
  font-size: 1.15rem;
  margin: 0 0 1.5rem;
}

/* —— Home lanes & trust strip —— */

.section-band {
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  padding: 2.25rem 0;
}

.section-band--tint {
  background: var(--surface-2);
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  margin-bottom: 0.35rem;
}

.section-head h2 {
  font-family: var(--font-display);
  font-style: normal;
  font-size: clamp(1.45rem, 2.5vw, 1.85rem);
  margin: 0;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.section-head a {
  font-weight: 650;
  font-size: 0.92rem;
  text-decoration: none;
}

.section-dek {
  color: var(--muted);
  margin: 0 0 1.25rem;
  max-width: 40rem;
}

.trust-strip {
  display: grid;
  gap: 1rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

@media (min-width: 720px) {
  .trust-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.trust-strip li {
  background: var(--surface);
  border: 1px solid var(--line);
  padding: 1.15rem 1.1rem;
  margin: 0;
}

.trust-strip strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.05rem;
  margin-bottom: 0.35rem;
  color: var(--ink);
}

.trust-strip span {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

/* —— Footer —— */

.site-footer {
  border-top: 3px solid var(--bg-ink);
  padding: 2.5rem 0 2.75rem;
  background: var(--bg-ink);
  color: #a8b3bd;
  font-size: 0.92rem;
}

.site-footer__inner {
  display: grid;
  gap: 1.5rem;
}

.site-footer strong {
  color: #fff;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 650;
}

.site-footer a {
  color: #c5ced6;
}

.site-footer a:hover {
  color: #67e8f9;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem 1.25rem;
}

.machine-links {
  margin-top: 0.5rem;
  font-family: var(--font-label);
  font-size: 0.75rem;
  color: #7a8691;
}

.breadcrumbs {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0 0 1rem;
  font-family: var(--font-label);
  letter-spacing: 0.02em;
}

.breadcrumbs a {
  color: var(--muted);
  text-decoration: none;
}

.breadcrumbs a:hover {
  color: var(--accent-deep);
}

.cta-band {
  margin: 2.75rem 0 0;
  padding: 1.5rem 1.35rem;
  background: var(--bg-ink);
  border: none;
  border-radius: 0;
  color: #e8eef4;
}

.cta-band h2 {
  margin: 0 0 0.45rem;
  font-family: var(--font-display);
  font-style: normal;
  font-size: 1.35rem;
  color: #fff;
}

.cta-band p {
  margin: 0 0 1.1rem;
  color: #b8c4ce;
}

.cta-band .btn--ghost {
  background: transparent;
  border-color: rgba(232, 238, 244, 0.35);
  color: #e8eef4;
}

.cta-band .btn--ghost:hover {
  border-color: #67e8f9;
  color: #67e8f9;
}
