/* Surviving the AI Apocalypse — VHS-label design system */
:root {
  --paper: #F3EEE3;
  --label: #FFFDF7;
  --ink: #1A1714;
  --ink-2: #3A342D;
  --muted: #5A534A;
  --rule: #D9D2C3;
  --dash: #8A8171;
  --red: #C23A22;
  --orange: #E8892B;
  --yellow: #F2C230;
  --blue: #1F3A93;
  --blue-dim: #3B55A8;
  --lcd: #121110;
  --amber: #FFB020;
  --display: 'Archivo Black', 'Arial Black', sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, Menlo, monospace;
  --serif: 'Source Serif 4', Georgia, serif;
}
* { 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: 19px; line-height: 1.55; }
a { color: var(--blue); }
a:hover { color: #142766; }
img { max-width: 100%; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 16px; top: 16px; background: var(--label); padding: 8px 12px; z-index: 10; }

.stripes { display: flex; height: 8px; }
.stripes span { flex: 1; }
.stripes span:nth-child(1) { background: var(--red); }
.stripes span:nth-child(2) { background: var(--orange); }
.stripes span:nth-child(3) { background: var(--yellow); }
.stripes span:nth-child(4) { background: var(--blue); }
.stripes.thick { height: 10px; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.wrap.narrow { max-width: 1100px; }

/* Header */
.site-header { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between; padding-top: 20px; padding-bottom: 20px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); }
.brand:hover { color: var(--ink); }
.brand-name { display: block; font-family: var(--display); font-size: 22px; letter-spacing: .02em; line-height: 1; }
.brand-sub { display: block; font-size: 16px; font-style: italic; line-height: 1.2; margin-top: 4px; }
.nav { display: flex; flex-wrap: wrap; gap: 6px 22px; font-family: var(--mono); font-size: 15px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.nav a { color: var(--ink); text-decoration: none; padding: 8px 0; }
.nav a:hover, .nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 4px; }

/* Type helpers */
.eyebrow { font-family: var(--mono); font-size: 14px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.eyebrow.red { color: var(--red); }
.display { font-family: var(--display); line-height: 1.05; margin: 0; }
.dek { font-style: italic; color: var(--ink-2); }
.mono-link { font-family: var(--mono); font-size: 15px; font-weight: 600; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; }

/* Hero */
.hero { display: flex; flex-wrap: wrap; gap: 48px; align-items: center; padding-top: 32px; padding-bottom: 64px; }
.hero-main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 18px; }
.hero-side { flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.hero h1 { font-size: clamp(38px, 5.2vw, 72px); line-height: 1; letter-spacing: -.01em; margin: 0; }
.hero .dek { font-size: clamp(21px, 2.2vw, 28px); line-height: 1.3; margin: 0; }
.hero .about { margin: 8px 0 0; max-width: 620px; color: var(--ink-2); border-top: 2px solid var(--ink); padding-top: 16px; }

/* Subscribe */
.subscribe { display: flex; flex-direction: column; gap: 10px; max-width: 560px; }
.subscribe label { font-family: var(--mono); font-size: 15px; font-weight: 600; }
.subscribe .row { display: flex; flex-wrap: wrap; gap: 10px; }
.subscribe input { flex: 1 1 240px; min-height: 52px; padding: 0 16px; font-size: 18px; font-family: inherit; border: 2px solid var(--ink); border-radius: 6px; background: var(--label); color: var(--ink); }
.subscribe .fine { font-size: 15px; color: var(--muted); }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 24px; font-family: var(--display); font-size: 17px; color: #fff; background: var(--red); border: 2px solid var(--ink); border-radius: 6px; cursor: pointer; text-decoration: none; }
.btn:hover { color: #fff; background: #A52F1A; }
.btn[disabled] { background: var(--muted); cursor: not-allowed; }
.btn.ghost { background: var(--label); color: var(--ink); font-family: var(--mono); font-weight: 600; font-size: 15px; min-height: 48px; }
.btn.ghost:hover { background: var(--paper); color: var(--ink); }

/* VCR */
.vcr { overflow: hidden; background: var(--lcd); border: 2px solid var(--ink); border-radius: 12px; padding: 28px 24px 22px; display: flex; flex-direction: column; gap: 18px; box-shadow: 8px 8px 0 var(--ink); }
.vcr-top { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 12px; letter-spacing: .14em; color: #9C9384; }
.lcd { white-space: nowrap; font-family: var(--mono); font-weight: 600; font-size: clamp(60px, 6.4vw, 92px); line-height: 1; color: var(--amber); text-align: center; letter-spacing: .04em; }
@keyframes blink { 0%, 49% { opacity: 1; } 50%, 100% { opacity: .15; } }
.blink { animation: blink 1.2s steps(1) infinite; }
@media (prefers-reduced-motion: reduce) { .blink { animation: none; } }
.vcr-buttons { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.vcr-buttons a { min-height: 44px; display: flex; align-items: center; justify-content: center; background: #2A2724; color: var(--paper); border-radius: 6px; font-family: var(--mono); font-size: 13px; font-weight: 600; text-decoration: none; }
.vcr-buttons a:hover { background: #3A3631; color: #fff; }
.vcr-buttons a.rec { background: var(--red); color: #fff; }
.vcr-caption { margin: 0; font-size: 17px; font-style: italic; color: var(--ink-2); }

/* Sections */
.block { padding-bottom: 72px; }
.block-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 12px; border-top: 3px solid var(--ink); padding-top: 20px; margin-bottom: 28px; }
.block-head h2 { font-size: 44px; margin: 0; display: flex; align-items: center; gap: 14px; }
.block-head p { margin: 6px 0 0; font-size: 20px; font-style: italic; color: var(--ink-2); }

/* Cards */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 24px; }
.card { background: var(--label); border: 2px solid var(--ink); border-radius: 8px; overflow: hidden; display: flex; flex-direction: column; }
.card-body { padding: 20px 22px 22px; display: flex; flex-direction: column; gap: 12px; flex-grow: 1; }
.card-meta { display: flex; justify-content: space-between; gap: 8px; flex-wrap: wrap; font-family: var(--mono); font-size: 13px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.card h3 { margin: 0; font-size: 24px; line-height: 1.15; }
.card h3 a { color: var(--ink); text-decoration: none; }
.card h3 a:hover { text-decoration: underline; }
.card p { margin: 0; font-size: 18px; }
.verdict { background: var(--paper); border-radius: 6px; padding: 10px 12px; font-size: 17px; font-style: italic; }
.pills { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; font-family: var(--mono); font-size: 13px; font-weight: 600; }
.pill { padding: 6px 10px; border: 1.5px solid var(--ink); border-radius: 999px; }
.pill.dark { background: var(--ink); color: var(--label); }

/* Panels */
.duo { display: flex; flex-wrap: wrap; gap: 24px; padding-bottom: 72px; }
.panel { flex: 1 1 460px; min-width: 0; background: var(--label); border: 2px solid var(--ink); border-radius: 8px; padding: 28px; display: flex; flex-direction: column; gap: 16px; }
.panel h2 { margin: 0; font-size: 32px; line-height: 1.1; }
.panel p { margin: 0; font-size: 18px; }
.panel.blue { background: var(--blue); color: #fff; }
.panel.blue .eyebrow { color: #fff; }
.panel.blue a { color: #fff; }
.meter { display: grid; grid-template-columns: repeat(10, minmax(0, 1fr)); gap: 5px; }
.meter span { height: 28px; border-radius: 3px; background: var(--blue-dim); }
.meter span.on { background: var(--amber); }
.meter-legend { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 13px; margin-top: 8px; }
.checklist { list-style: none; margin: 0; padding: 0; font-family: var(--mono); font-size: 15px; line-height: 1.6; }
.checklist li::before { content: "✓ "; font-family: system-ui, -apple-system, "Segoe UI Symbol", sans-serif; }
.sym { font-family: system-ui, -apple-system, "Segoe UI Symbol", sans-serif; }
.sources-mini { font-size: 15px; display: flex; flex-direction: column; gap: 4px; }
.panel.blue .sources-mini a { color: #fff; }

/* Record */
.record { background: var(--label); border: 2px solid var(--ink); border-radius: 8px; padding: 28px; display: flex; flex-wrap: wrap; gap: 28px; align-items: flex-start; }
.record-intro { flex: 1 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.record-intro h2 { margin: 0; font-size: 30px; }
.record-intro p { margin: 0; font-size: 18px; }
.prompt-wrap { flex: 999 1 520px; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.prompt-box { background: var(--lcd); color: var(--paper); border-radius: 8px; padding: 22px; font-family: var(--mono); font-size: 15px; line-height: 1.6; white-space: pre-wrap; margin: 0; overflow-wrap: anywhere; }
.copy-btn { align-self: flex-start; }

/* Section browse */
.section-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.section-tile { display: flex; flex-direction: column; gap: 6px; padding: 20px; background: var(--label); border: 2px solid var(--ink); border-radius: 8px; text-decoration: none; color: var(--ink); min-height: 110px; }
.section-tile:hover { background: #fff; color: var(--ink); }
.section-tile .name { font-family: var(--display); font-size: 21px; }
.section-tile .desc { font-size: 17px; color: var(--ink-2); }
.section-tile .count { font-family: var(--mono); font-size: 13px; color: var(--muted); margin-top: auto; }

/* Sponsor slot */
.sponsor-slot { border: 2px dashed var(--dash); border-radius: 8px; padding: 22px 24px; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; }
.sponsor-slot .who { font-family: var(--display); font-size: 22px; }

/* Footer */
.site-footer { background: var(--ink); color: var(--paper); }
.site-footer .wrap { padding-top: 44px; padding-bottom: 44px; display: flex; flex-wrap: wrap; gap: 32px; justify-content: space-between; }
.site-footer .about { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.site-footer .about strong { font-family: var(--display); font-weight: 400; font-size: 20px; }
.site-footer p { margin: 0; font-size: 17px; color: #D8D0C2; }
.site-footer .legal { font-family: var(--mono); font-size: 13px; color: #B8AF9F; }
.site-footer nav { display: flex; flex-direction: column; gap: 8px; font-family: var(--mono); font-size: 15px; }
.site-footer a { color: var(--paper); }

/* Entry page */
.entry-layout { display: flex; flex-wrap: wrap; gap: 40px; align-items: flex-start; padding-top: 24px; padding-bottom: 80px; }
.entry-main { flex: 999 1 600px; min-width: 0; display: flex; flex-direction: column; gap: 28px; }
.entry-side { flex: 1 1 280px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.entry-main h1 { font-size: clamp(36px, 4.6vw, 60px); line-height: 1.02; margin: 0; }
.entry-main .dek { font-size: 22px; margin: 0; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; }
.fact { background: var(--label); border: 2px solid var(--ink); border-radius: 8px; padding: 14px 16px; }
.fact .k { font-family: var(--mono); font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.fact .v { font-family: var(--display); font-size: 19px; line-height: 1.2; }
.entry-main section { display: flex; flex-direction: column; gap: 12px; }
.entry-main section h2 { font-size: 28px; margin: 0; }
.entry-main section p { margin: 0; }
.steps-box { background: var(--label); border: 2px solid var(--ink); border-radius: 8px; padding: 28px; }
.steps-box ol { margin: 0; padding-left: 28px; display: flex; flex-direction: column; gap: 14px; }
.grownup { background: var(--blue); color: #fff; border-radius: 8px; padding: 28px; }
.grownup h2 { font-size: 26px; }
.grownup ul { margin: 0; padding-left: 24px; display: flex; flex-direction: column; gap: 8px; }
.verdict-big { border-top: 3px solid var(--ink); padding-top: 20px; }
.verdict-big p { font-size: 22px; font-style: italic; }
.source-list { display: flex; flex-direction: column; gap: 8px; font-size: 17px; margin: 0; padding: 0; list-style: none; }
.side-box { background: var(--label); border: 2px solid var(--ink); border-radius: 8px; padding: 22px; display: flex; flex-direction: column; gap: 12px; }
.side-box .title { font-family: var(--display); font-size: 20px; line-height: 1.15; }
.side-link { display: block; padding: 16px; background: var(--label); border: 2px solid var(--ink); border-radius: 8px; text-decoration: none; color: var(--ink); font-family: var(--display); font-size: 18px; line-height: 1.2; }
.side-link:hover { background: #fff; color: var(--ink); }
.crumbs { font-family: var(--mono); font-size: 14px; display: flex; flex-wrap: wrap; gap: 6px; color: var(--muted); }
.crumbs a { color: var(--muted); }

/* Generic page */
.page { padding-top: 24px; padding-bottom: 80px; display: flex; flex-direction: column; gap: 32px; }
.page h1 { font-size: clamp(36px, 5vw, 64px); line-height: 1.02; margin: 0; }
.prose { max-width: 760px; display: flex; flex-direction: column; gap: 16px; }
.prose p, .prose ul { margin: 0; }
.prose h2 { font-size: 28px; margin: 16px 0 0; }
.list-rows { display: flex; flex-direction: column; border-top: 3px solid var(--ink); }
.list-rows a.row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px; padding: 20px 0; border-bottom: 1.5px solid var(--rule); text-decoration: none; color: var(--ink); }
.list-rows a.row:hover .t { text-decoration: underline; }
.list-rows .t { font-family: var(--display); font-size: 22px; line-height: 1.2; }
.list-rows .m { font-family: var(--mono); font-size: 14px; color: var(--muted); }
.empty { border: 2px dashed var(--dash); border-radius: 8px; padding: 28px; font-size: 19px; }
.placements { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; }

@media (max-width: 640px) {
  body { font-size: 18px; }
  .block-head h2 { font-size: 34px; }
  .panel, .record, .steps-box, .grownup { padding: 22px; }
}

/* Panic Meter dial (homepage signature + section) */
.dial-card { display: flex; flex-direction: column; gap: 12px; background: var(--label); color: var(--ink); border: 2px solid var(--ink); border-radius: 12px; padding: 22px 24px 24px; box-shadow: 8px 8px 0 var(--ink); text-decoration: none; }
.dial-card:hover { color: var(--ink); background: #fff; }
.dial-top { display: flex; justify-content: space-between; font-family: var(--mono); font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--red); }
.dial { display: block; width: 100%; height: auto; }
.dial-large { max-width: 340px; margin: 0 auto; }
.dial-q { font-family: var(--display); font-size: 24px; line-height: 1.15; }
.dial-verdict { font-size: 18px; color: var(--ink-2); }
.dial-verdict strong { font-family: var(--display); font-weight: 400; color: var(--ink); }
.dial-more { margin-top: 2px; color: var(--blue); }
.dial-row { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.dial-row .dial-small { width: 220px; max-width: 100%; color: var(--ink); background: var(--label); border-radius: 10px; padding: 12px 12px 8px; }
.dial-read { display: flex; flex-direction: column; gap: 4px; font-family: var(--mono); font-size: 15px; }
.dial-level { font-family: var(--display); font-size: 40px; line-height: 1; }

/* Panic Meter: weekly alert band, separate from the lead story */
.alert-band { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 28px; margin-top: 8px; padding: 30px 28px 26px; background: var(--ink); color: var(--paper); border-radius: 12px; overflow: hidden; }
.alert-band::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 10px; background: repeating-linear-gradient(-45deg, var(--yellow) 0 14px, var(--ink) 14px 28px); }
.alert-dial { flex: 0 0 260px; max-width: 100%; background: var(--label); color: var(--ink); border-radius: 10px; padding: 14px 14px 10px; }
.alert-text { flex: 1 1 420px; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
.alert-top { display: flex; align-items: center; gap: 10px; font-family: var(--mono); font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--yellow); }
.alert-band h2 { margin: 0; font-size: clamp(26px, 3vw, 36px); line-height: 1.1; color: #fff; }
.alert-level { color: var(--yellow); margin-right: 6px; }
.alert-band p { margin: 0; font-size: 18px; color: #E4DDD0; max-width: 760px; }
.alert-meta { font-family: var(--mono); font-size: 14px !important; }
.alert-band a { color: var(--yellow); }
.hero { padding-top: 40px; }

/* The needle never quite sits still: a constant, small tremble just past the reading */
.needle { transform-box: view-box; transform-origin: 100px 100px; transform: rotate(calc(var(--a) + 1.5deg)); animation: needle-tremble 2.4s ease-in-out infinite; }
@keyframes needle-tremble {
  0%, 100% { transform: rotate(calc(var(--a) + 1.5deg)); }
  20% { transform: rotate(calc(var(--a) + 2.6deg)); }
  35% { transform: rotate(calc(var(--a) + 0.8deg)); }
  55% { transform: rotate(calc(var(--a) + 2.2deg)); }
  70% { transform: rotate(calc(var(--a) + 0.4deg)); }
  85% { transform: rotate(calc(var(--a) + 1.9deg)); }
}
@media (prefers-reduced-motion: reduce) { .needle { animation: none; } }

/* Panic Meter history */
.history-chart { width: 100%; height: auto; display: block; font-family: var(--mono); }
.legend { display: flex; gap: 20px; flex-wrap: wrap; font-family: var(--mono); font-size: 14px; color: var(--ink-2); }
.legend i { display: inline-block; width: 18px; height: 4px; border-radius: 2px; margin-right: 8px; vertical-align: middle; }
.muted { color: var(--muted); }
.table-wrap { overflow-x: auto; border: 2px solid var(--ink); border-radius: 8px; background: var(--label); }
table.data { border-collapse: collapse; width: 100%; font-size: 17px; }
table.data th, table.data td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--rule); white-space: nowrap; }
table.data th { font-family: var(--mono); font-size: 13px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
table.data td:last-child { white-space: normal; min-width: 240px; }
