/* gonzalezsierra.co — Estudio El Niño 2026-27 — hoja base */
:root {
  --azul-principal: #0e4d6e;
  --rojo-p05: #dc2626;
  --azul-p95: #2563eb;
  --naranja: #d47700;
  --fondo: #fafaf8;
  --texto: #111111;
  --texto-sec: #4b5563;
  --gris: #9ca3af;
  --gris-claro: #e5e7eb;
  --max-w: 760px;
}

@import url('https://fonts.googleapis.com/css2?family=Source+Serif+4:opsz,wght@8..60,400;8..60,600;8..60,700&family=JetBrains+Mono:wght@400;500&display=swap');

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  padding: 0;
  background: var(--fondo);
  color: var(--texto);
  font-family: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  font-size: 18px;
  line-height: 1.65;
  font-feature-settings: "kern", "liga", "calt";
}

header.estudio-header {
  border-bottom: 1px solid var(--gris-claro);
  padding: 3.5rem 1.25rem 2rem 1.25rem;
  background: var(--fondo);
}

header.estudio-header > .inner,
main, footer.estudio-footer > .inner {
  max-width: var(--max-w);
  margin: 0 auto;
}

h1.titulo-estudio {
  font-size: 2.0rem;
  line-height: 1.2;
  margin: 0 0 0.6rem 0;
  color: var(--azul-principal);
  font-weight: 700;
}

p.lead {
  font-size: 1.15rem;
  color: var(--texto-sec);
  margin: 0 0 1.5rem 0;
  font-style: italic;
}

.meta-estudio {
  font-size: 0.9rem;
  color: var(--texto-sec);
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem 1.4rem;
  margin: 0 0 1rem 0;
}
.meta-estudio b { color: var(--texto); font-weight: 600; }

nav.toc {
  border: 1px solid var(--gris-claro);
  padding: 1rem 1.25rem;
  margin: 2rem 0 0 0;
  background: #ffffff;
  border-radius: 6px;
}
nav.toc h2 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--texto-sec);
  margin: 0 0 0.6rem 0;
}
nav.toc ol {
  list-style-position: inside;
  padding-left: 0;
  margin: 0;
  font-size: 0.95rem;
}
nav.toc li { margin: 0.18rem 0; }
nav.toc a {
  color: var(--azul-principal);
  text-decoration: none;
  border-bottom: 1px dotted var(--gris);
}
nav.toc a:hover { color: var(--rojo-p05); border-bottom-color: currentColor; }

main { padding: 0 1.25rem 4rem 1.25rem; }

section {
  margin: 3rem 0 0 0;
  scroll-margin-top: 2rem;
}
section h2 {
  font-size: 1.5rem;
  color: var(--azul-principal);
  border-bottom: 2px solid var(--azul-principal);
  padding-bottom: 0.3rem;
  margin: 0 0 1.2rem 0;
  font-weight: 700;
}
section h3 {
  font-size: 1.15rem;
  color: var(--texto);
  margin: 1.6rem 0 0.6rem 0;
  font-weight: 600;
}

p { margin: 0 0 1rem 0; }
strong { color: var(--texto); font-weight: 600; }
em { color: var(--texto-sec); }

a { color: var(--azul-principal); }
a:hover { color: var(--rojo-p05); }

figure {
  margin: 2rem -1rem;
  padding: 0;
}
figure img { width: 100%; height: auto; border-radius: 4px; }
figcaption {
  font-size: 0.88rem;
  color: var(--texto-sec);
  margin: 0.6rem 0.5rem 0 0.5rem;
  text-align: center;
  font-style: italic;
}

table.datos {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.93rem;
  margin: 1.4rem 0;
}
table.datos th, table.datos td {
  padding: 0.45rem 0.7rem;
  border-bottom: 1px solid var(--gris-claro);
  text-align: left;
}
table.datos th {
  color: var(--texto-sec);
  font-weight: 600;
  background: #f0eee9;
  border-bottom: 2px solid var(--gris);
}
table.datos td.num { text-align: right; font-variant-numeric: tabular-nums; }

code, .mono {
  font-family: 'JetBrains Mono', 'Menlo', 'Consolas', monospace;
  font-size: 0.92em;
  background: #f0eee9;
  padding: 0.05rem 0.35rem;
  border-radius: 3px;
}
pre {
  background: #f0eee9;
  padding: 1rem;
  border-radius: 4px;
  overflow-x: auto;
  font-size: 0.85rem;
}
pre code { background: transparent; padding: 0; }

.callout {
  border-left: 4px solid var(--naranja);
  background: #fff5e6;
  padding: 0.85rem 1rem;
  margin: 1.2rem 0;
  font-size: 0.95rem;
}

footer.estudio-footer {
  border-top: 1px solid var(--gris-claro);
  padding: 2.5rem 1.25rem 4rem 1.25rem;
  font-size: 0.9rem;
  color: var(--texto-sec);
}
footer.estudio-footer h3 {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 0 0 0.7rem 0;
}
footer.estudio-footer .citas li { margin: 0.25rem 0; }

@media (max-width: 700px) {
  body { font-size: 16px; }
  h1.titulo-estudio { font-size: 1.55rem; }
  section h2 { font-size: 1.25rem; }
  figure { margin: 1.5rem 0; }
  header.estudio-header { padding-top: 2rem; }
}
