/* Estilo común del sitio. Columna editorial, tarjetas, tablas. Claro y oscuro. */
:root {
  --paper: #f4f6f3;
  --surface: #ffffff;
  --ink: #15211c;
  --muted: #5a6862;
  --line: #d9e0db;
  --accent: #2c6a4e;
  --accent-soft: #e2eee7;
  --sun: #a67816;
  --sun-soft: #f6ecd6;
  --idea: #6a5a8e;
  --idea-soft: #ece8f4;
  --warn: #a2412f;
  --warn-soft: #f6e3de;
  --display: "Instrument Serif", Georgia, "Times New Roman", serif;
  --body: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Menlo, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #101714; --surface: #18221e; --ink: #e7eee9; --muted: #9aaba3; --line: #2a3832;
    --accent: #7cc4a0; --accent-soft: #1d3329; --sun: #e2b55a; --sun-soft: #33291a;
    --idea: #b7a6e0; --idea-soft: #28233a; --warn: #ef9a87; --warn-soft: #3a221d; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #101714; --surface: #18221e; --ink: #e7eee9; --muted: #9aaba3; --line: #2a3832;
  --accent: #7cc4a0; --accent-soft: #1d3329; --sun: #e2b55a; --sun-soft: #33291a;
  --idea: #b7a6e0; --idea-soft: #28233a; --warn: #ef9a87; --warn-soft: #3a221d; color-scheme: dark;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--body); font-size: 16.5px; line-height: 1.6; }
a { color: var(--accent); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 3px; }

.wrap { max-width: 1040px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 720px) { .wrap { padding: 0 24px; } }
.prose { max-width: 66ch; }

header.top { border-bottom: 1px solid var(--line); background: var(--paper); position: sticky; top: 0; z-index: 1000; }
header.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 8px 16px; flex-wrap: wrap; padding-top: 12px; padding-bottom: 12px; }
.brand { font-family: var(--display); font-size: 1.35rem; letter-spacing: .01em; color: var(--ink); text-decoration: none; }
.brand small { font-family: var(--mono); font-size: .66rem; color: var(--muted); margin-left: 8px; letter-spacing: .04em; text-transform: uppercase; }
nav.main { display: flex; gap: 4px 16px; flex-wrap: wrap; }
nav.main a { color: var(--muted); text-decoration: none; font-size: .9rem; padding: 2px 0; border-bottom: 2px solid transparent; }
nav.main a:hover { color: var(--ink); }
nav.main a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); }

.hero { padding-top: 56px; padding-bottom: 36px; }
.hero h1 { font-family: var(--display); font-weight: 400; font-size: clamp(2.2rem, 5vw, 3.4rem); line-height: 1.08; margin: 0 0 18px; text-wrap: balance; max-width: 22ch; }
.hero h1 em { color: var(--accent); }
.hero p { color: var(--muted); font-size: 1.08rem; margin: 0 0 10px; }

section { padding: 40px 0; border-top: 1px solid var(--line); }
.label { font-family: var(--mono); font-size: .72rem; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin: 0 0 8px; }
h2 { font-family: var(--display); font-weight: 400; font-size: 2rem; line-height: 1.15; margin: 0 0 14px; text-wrap: balance; }
h3 { font-size: 1.06rem; font-weight: 600; margin: 0; }
p.lead { color: var(--muted); margin: 0 0 8px; }

.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 22px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 22px; }
@media (max-width: 820px) { .grid3 { grid-template-columns: 1fr; } }
@media (max-width: 720px) { .grid2 { grid-template-columns: 1fr; } }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.card p { margin: 0; color: var(--muted); }
.card ul { margin: 0; padding-left: 18px; }
.card li { margin: 4px 0; }
.pillar { border-top: 4px solid var(--c, var(--accent)); }
.pillar .head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.pillar .num { font-family: var(--display); font-size: 2rem; line-height: 1; color: var(--c, var(--accent)); }
.card div.open { border-top: 1px dashed var(--line); padding-top: 10px; font-size: .92rem; color: var(--muted); }
.card div.open strong { font-weight: 600; color: var(--ink); }

.pill { font-family: var(--mono); font-size: .68rem; letter-spacing: .05em; text-transform: uppercase; padding: 3px 9px; border-radius: 999px; white-space: nowrap; display: inline-block; }
.pill.dev, .pill.ok { background: var(--accent-soft); color: var(--accent); }
.pill.idea { background: var(--idea-soft); color: var(--idea); }
.pill.open, .pill.pend { background: var(--sun-soft); color: var(--sun); }
.pill.priv { background: var(--warn-soft); color: var(--warn); }

.flow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); margin-top: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.flow div { padding: 18px; border-right: 1px solid var(--line); }
.flow div:last-child { border-right: 0; }
.flow b { display: block; font-family: var(--display); font-weight: 400; font-size: 1.3rem; margin-bottom: 4px; }
.flow span { color: var(--muted); font-size: .92rem; }
@media (max-width: 720px) { .flow { grid-template-columns: 1fr; } .flow div { border-right: 0; border-bottom: 1px solid var(--line); } .flow div:last-child { border-bottom: 0; } }

.note { background: var(--sun-soft); border-left: 4px solid var(--sun); border-radius: 8px; padding: 14px 16px; margin: 18px 0 0; }
.note p { margin: 0; }
.note.priv { background: var(--warn-soft); border-left-color: var(--warn); }

.tablewrap { overflow-x: auto; margin-top: 16px; }
table { width: 100%; border-collapse: collapse; font-size: .94rem; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-family: var(--mono); font-size: .7rem; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); font-weight: 500; }
td.empty { color: var(--muted); text-align: center; padding: 28px 12px; }

.questions { display: grid; gap: 12px; margin-top: 18px; }
.q { background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--sun); border-radius: 8px; padding: 14px 16px; }
.q h3 { margin-bottom: 4px; }
.q p { margin: 0; color: var(--muted); font-size: .95rem; }

.log { list-style: none; padding: 0; margin: 18px 0 0; border-left: 2px solid var(--line); }
.log li { position: relative; padding: 0 0 18px 22px; }
.log li::before { content: ""; position: absolute; left: -7px; top: 7px; width: 12px; height: 12px; border-radius: 50%; background: var(--paper); border: 2px solid var(--accent); }
.log time { font-family: var(--mono); font-size: .78rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.log p { margin: 2px 0 0; }

.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.filters label { font-size: .85rem; color: var(--muted); display: flex; flex-direction: column; gap: 4px; }
.filters select, .filters input { font: inherit; font-size: .92rem; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 7px 10px; min-width: 160px; }

#map { height: 420px; border: 1px solid var(--line); border-radius: 10px; margin-top: 18px; z-index: 1; }
@media (max-width: 720px) { #map { height: 320px; } }

.doclist { list-style: none; padding: 0; margin: 18px 0 0; display: grid; gap: 10px; }
.doclist li { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; }
.doclist .meta { font-family: var(--mono); font-size: .75rem; color: var(--muted); }
.doclist p { margin: 4px 0 0; color: var(--muted); font-size: .94rem; }

footer { border-top: 1px solid var(--line); padding: 28px 0 48px; color: var(--muted); font-size: .88rem; }
