:root {
  --bg: #fbfaf7;
  --surface: #ffffff;
  --ink: #14181f;
  --muted: #5b6472;
  --line: #e3e0d7;
  --accent: #0b6e5e;
  --accent-ink: #ffffff;
  --chip: #f0eee7;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #101317; --surface: #161b21; --ink: #eceff3; --muted: #9aa3b0;
    --line: #262d36; --accent: #3ecfb2; --accent-ink: #06201a; --chip: #1d242c;
  }
}
:root[data-theme="dark"] {
  --bg: #101317; --surface: #161b21; --ink: #eceff3; --muted: #9aa3b0;
  --line: #262d36; --accent: #3ecfb2; --accent-ink: #06201a; --chip: #1d242c;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 16px/1.55 var(--sans);
}
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }
img { max-width: 100%; height: auto; }
.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 8px; top: 8px; background: var(--accent); color: var(--accent-ink); padding: 8px 12px; z-index: 10; }

/* Cabecera */
.top { border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 5; }
.bar { display: flex; align-items: center; gap: 20px; height: 56px; }
.brand { font: 800 19px/1 var(--sans); letter-spacing: -0.02em; display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.brand:hover { text-decoration: none; }
.mark { width: 14px; height: 14px; background: var(--accent); border-radius: 3px; display: inline-block; }
.nav { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; flex: 1; padding: 2px 0; }
.nav::-webkit-scrollbar { display: none; }
.nav a { padding: 6px 12px; border-radius: 999px; font-size: 14px; white-space: nowrap; color: var(--muted); }
.nav a:hover { background: var(--chip); text-decoration: none; color: var(--ink); }
.nav a[aria-current="page"] { background: var(--ink); color: var(--bg); }

/* Listados */
.hero { padding: 28px 0 8px; }
.hero h1 { margin: 0 0 6px; font: 700 28px/1.2 var(--serif); letter-spacing: -0.01em; }
.hero p { margin: 0; color: var(--muted); }
.tools { display: flex; gap: 12px; align-items: center; padding: 14px 0 6px; flex-wrap: wrap; }
.search {
  flex: 1; min-width: 200px; padding: 10px 14px; border: 1px solid var(--line);
  border-radius: 10px; background: var(--surface); color: var(--ink); font: inherit;
}
.search:focus { outline: 2px solid var(--accent); outline-offset: 1px; }
.count { color: var(--muted); font-size: 14px; }
.day { margin: 26px 0 0; padding-bottom: 8px; border-bottom: 2px solid var(--ink); font: 700 13px/1 var(--sans); text-transform: uppercase; letter-spacing: 0.06em; }
.item { display: grid; grid-template-columns: 1fr 132px; gap: 18px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.item .kicker { margin: 0 0 6px; font-size: 13px; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; }
.kicker .src { font-weight: 700; color: var(--accent); }
.kicker .dot::before { content: "·"; margin-right: 8px; }
.item h2 { margin: 0 0 6px; font: 700 21px/1.25 var(--serif); letter-spacing: -0.005em; }
.item h2 a:hover { text-decoration-thickness: 2px; }
.item .ex { margin: 0; color: var(--muted); font-size: 15px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.th { display: block; aspect-ratio: 3 / 2; border-radius: 8px; overflow: hidden; background: var(--chip); align-self: start; }
.th img { width: 100%; height: 100%; object-fit: cover; display: block; }
.empty { padding: 40px 0; color: var(--muted); }
.pager { display: flex; justify-content: space-between; padding: 24px 0 40px; font-size: 15px; }
.pager a { padding: 8px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); }
.badge { font-size: 11px; text-transform: uppercase; letter-spacing: 0.05em; padding: 1px 6px; border: 1px solid var(--line); border-radius: 4px; }

/* Nota */
.article { max-width: 720px; margin: 0 auto; padding: 28px 16px 48px; }
.crumbs { font-size: 14px; color: var(--muted); margin-bottom: 14px; }
.crumbs a { color: var(--accent); font-weight: 600; }
.article h1 { margin: 0 0 14px; font: 700 clamp(28px, 5vw, 40px)/1.15 var(--serif); letter-spacing: -0.015em; }
.byline { color: var(--muted); font-size: 14px; display: flex; flex-wrap: wrap; gap: 4px 12px; margin-bottom: 18px; }
.byline strong { color: var(--ink); }
.origin {
  border: 1px solid var(--line); background: var(--surface); border-left: 4px solid var(--accent);
  border-radius: 8px; padding: 12px 16px; font-size: 14px; color: var(--muted); margin: 0 0 22px;
}
.origin a { color: var(--accent); font-weight: 700; }
.hero-img { margin: 0 0 24px; }
.hero-img img { width: 100%; border-radius: 10px; display: block; background: var(--chip); }
.body { font: 19px/1.7 var(--serif); }
.body p { margin: 0 0 1.1em; }
.body h2, .body h3, .body h4 { font-family: var(--sans); line-height: 1.25; margin: 1.8em 0 0.6em; letter-spacing: -0.01em; }
.body h2 { font-size: 24px; }
.body h3 { font-size: 20px; }
.body a { color: var(--accent); text-decoration: underline; text-underline-offset: 3px; }
.body blockquote { margin: 1.4em 0; padding: 4px 0 4px 20px; border-left: 3px solid var(--accent); color: var(--muted); font-style: italic; }
.body figure { margin: 1.6em 0; }
.body figcaption, .body figcaption p { font: 13px/1.4 var(--sans); color: var(--muted); margin: 6px 0 0; }
.body img { border-radius: 8px; }
.body table { width: 100%; border-collapse: collapse; font: 15px/1.4 var(--sans); margin: 1.4em 0; display: block; overflow-x: auto; }
.body th, .body td { border: 1px solid var(--line); padding: 8px 10px; text-align: left; }
.body ul, .body ol { padding-left: 1.3em; margin: 0 0 1.1em; }
.credit { margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.cta { display: inline-block; margin-top: 12px; padding: 10px 16px; border-radius: 8px; background: var(--accent); color: var(--accent-ink); font-weight: 700; }
.cta:hover { text-decoration: none; opacity: 0.9; }
.more { max-width: 1040px; margin: 0 auto; padding: 0 16px 48px; }
.more h2 { font: 700 13px/1 var(--sans); text-transform: uppercase; letter-spacing: 0.06em; padding-bottom: 8px; border-bottom: 2px solid var(--ink); }

/* Páginas de texto */
.page { max-width: 720px; margin: 0 auto; padding: 32px 16px 56px; }
.page h1 { font: 700 32px/1.2 var(--serif); margin: 0 0 12px; }
.page h2 { font: 700 20px/1.3 var(--sans); margin: 28px 0 8px; }
.page li { margin-bottom: 6px; }
.sources { list-style: none; padding: 0; margin: 20px 0; }
.sources li { padding: 12px 0; border-bottom: 1px solid var(--line); display: flex; gap: 10px; flex-wrap: wrap; justify-content: space-between; }

/* Pie */
.foot { border-top: 1px solid var(--line); padding: 28px 0 40px; color: var(--muted); font-size: 14px; }
.foot .wrap { display: flex; gap: 12px 24px; flex-wrap: wrap; justify-content: space-between; }
.foot nav { display: flex; gap: 16px; flex-wrap: wrap; }
.foot p { margin: 0; max-width: 560px; }

@media (max-width: 600px) {
  .item { grid-template-columns: 1fr 96px; gap: 12px; }
  .item h2 { font-size: 18px; }
  .item .ex { display: none; }
  .hero h1 { font-size: 24px; }
  .body { font-size: 18px; }
  .bar { gap: 12px; }
}
@media print { .top, .foot, .more, .cta { display: none; } }
