/* Estilos del blog de zelthur (/blog y /blog/<articulo>), 30 sep 2026.
   Base copiada del <style> de index.html (fuentes, tokens, botones, navbar) + estilos propios del blog (prefijo bl-).
   Las utilidades de Tailwind salen de css/tailwind.css (su config ya incluye blog/**.html: si usas una clase nueva,
   corre sh docs/herramientas/tailwind/build.sh). Rutas absolutas (/fonts/...) porque las páginas viven en /blog/. */

/* ── Fuentes locales (mismas caras que la landing) ── */
@font-face { font-family: 'Geist'; font-style: normal; font-weight: 300 700; font-display: swap; src: url(/fonts/geist-latin-ext.woff2) format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Geist'; font-style: normal; font-weight: 300 700; font-display: swap; src: url(/fonts/geist-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Geist Mono'; font-style: normal; font-weight: 400; font-display: swap; src: url(/fonts/geist-mono-latin-ext.woff2) format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Geist Mono'; font-style: normal; font-weight: 400; font-display: swap; src: url(/fonts/geist-mono-latin.woff2) format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Bespoke Serif'; src: url(/fonts/bespoke-serif-400-normal.woff2) format('woff2'); font-weight: 400; font-display: swap; font-style: normal; }
@font-face { font-family: 'Bespoke Serif'; src: url(/fonts/bespoke-serif-400-italic.woff2) format('woff2'); font-weight: 400; font-display: swap; font-style: italic; }
@font-face { font-family: 'Bespoke Serif'; src: url(/fonts/bespoke-serif-300-800-normal.woff2) format('woff2'); font-weight: 300 800; font-display: swap; font-style: normal; }
@font-face { font-family: 'Bespoke Serif'; src: url(/fonts/bespoke-serif-300-800-italic.woff2) format('woff2'); font-weight: 300 800; font-display: swap; font-style: italic; }

:root {
  color-scheme: light;
  --page: #FFFFFF;
  --cream: #FAF7F1;
  --ink: #161D18;
  --pine: #27593F;
  --line: rgba(22,29,24,0.10);
}
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  font-family: 'Geist', system-ui, sans-serif;
  background-color: var(--page);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}
.font-serif { font-family: 'Bespoke Serif', Georgia, serif; font-weight: 400; letter-spacing: -0.022em; }
::selection { background-color: #27593F; color: #FAF7F1; }

/* ── Botones y enlaces (igual que la landing) ── */
.btn-primary { background-color: var(--pine); color: #FAF7F1; transition: background-color .25s ease, transform .25s ease; }
.btn-primary:hover { background-color: #1D4530; }
.btn-primary .arrow { display: inline-flex; transition: transform .3s cubic-bezier(.5,.8,.3,1); }
.btn-primary:hover .arrow { transform: translateX(3px); }
.ulink { position: relative; }
.ulink::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: -3px; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform .3s cubic-bezier(.5,.8,.3,1);
}
.ulink:hover::after, .ulink[aria-current="page"]::after { transform: scaleX(1); transform-origin: left; }

/* ── Navbar: píldora al hacer scroll (js/blog.js pone .nav-scrolled en #nav) ── */
.nav-inner {
  max-width: 100%; margin: 10px auto 0; padding: 14px 0;
  border-radius: 999px; border: 1px solid transparent;
  transition: max-width .5s cubic-bezier(.2,.7,.2,1), padding .4s ease, background-color .4s ease, box-shadow .4s ease, border-color .4s ease;
}
#nav.nav-scrolled .nav-inner {
  max-width: 920px; padding: 8px 18px;
  background-color: rgba(255,255,255,0.92);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  border-color: var(--line);
  box-shadow: 0 10px 36px -14px rgba(22,29,24,0.16);
}

/* ── Cabecera crema con puntos (lista del blog y artículo) ── */
.bl-head { position: relative; background: var(--cream); border-bottom: 1px solid var(--line); padding: 128px 0 52px; }
@media (min-width: 768px) { .bl-head { padding: 160px 0 72px; } }
.bl-head::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(rgba(22,29,24,0.08) 1px, transparent 1.4px); background-size: 20px 20px;
  -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent); mask-image: linear-gradient(to bottom, #000 30%, transparent);
}
.bl-head > * { position: relative; }
.bl-kicker { font-family: 'Geist Mono', ui-monospace, monospace; font-size: 11.5px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--pine); }
.bl-kicker a { color: inherit; }
.bl-kicker a:hover { text-decoration: underline; text-underline-offset: 3px; }
.bl-h1 { margin-top: 16px; font-family: 'Bespoke Serif', Georgia, serif; font-weight: 400; font-size: clamp(34px, 5.6vw, 60px); line-height: 1.05; letter-spacing: -0.03em; color: var(--ink); max-width: 15em; text-wrap: balance; }
.bl-h1 em { font-style: italic; color: var(--pine); }
.bl-dek { margin-top: 20px; max-width: 38em; font-size: 17.5px; line-height: 1.6; color: rgba(22,29,24,0.68); }
.bl-meta { margin-top: 22px; font-size: 13.5px; line-height: 1.7; color: rgba(22,29,24,0.62); }
.bl-meta span { white-space: nowrap; }
.bl-meta span:not(:last-child)::after { content: "·"; margin: 0 6px 0 10px; color: rgba(22,29,24,0.35); } /* el punto va al final de cada dato: si la línea se parte, no empieza con "·" */

/* ── Lista de artículos (/blog) ── */
.bl-list { display: grid; gap: 20px; padding: 48px 0 72px; }
@media (min-width: 768px) { .bl-list { grid-template-columns: repeat(2, 1fr); gap: 24px; padding: 64px 0 96px; } }
.bl-card {
  position: relative; display: flex; flex-direction: column; gap: 12px;
  padding: 26px 24px 24px; border: 1px solid var(--line); border-radius: 18px; background: #fff;
  box-shadow: 0 1px 2px rgba(22,29,24,0.04);
  transition: border-color .3s ease, box-shadow .3s ease;
}
.bl-card:hover { border-color: rgba(39,89,63,0.35); box-shadow: 0 18px 40px -28px rgba(22,29,24,0.40); }
.bl-card-meta { font-family: 'Geist Mono', ui-monospace, monospace; font-size: 11.5px; letter-spacing: 0.06em; text-transform: uppercase; color: rgba(22,29,24,0.55); }
.bl-card-meta .tag { color: var(--pine); }
.bl-card h2 { font-family: 'Bespoke Serif', Georgia, serif; font-weight: 400; font-size: 25px; line-height: 1.18; letter-spacing: -0.02em; color: var(--ink); text-wrap: balance; }
.bl-card h2 a::after { content: ""; position: absolute; inset: 0; border-radius: inherit; } /* toda la tarjeta es clicable */
.bl-card h2 a:focus-visible { outline: none; }
.bl-card:focus-within { outline: 2px solid var(--pine); outline-offset: 3px; }
.bl-card p { font-size: 15px; line-height: 1.6; color: rgba(22,29,24,0.66); }
.bl-card .more { margin-top: auto; padding-top: 6px; font-size: 13.5px; font-weight: 500; color: var(--pine); }

/* ── Artículo ── */
.bl-article { max-width: 700px; margin: 0 auto; padding: 48px 24px 24px; }
@media (min-width: 768px) { .bl-article { padding-top: 64px; } }
.bl-prose { font-size: 17.5px; line-height: 1.72; color: rgba(22,29,24,0.86); }
.bl-prose > * + * { margin-top: 1.1em; }
.bl-prose h2 { margin-top: 2.1em; font-family: 'Bespoke Serif', Georgia, serif; font-weight: 400; font-size: 30px; line-height: 1.15; letter-spacing: -0.025em; color: var(--ink); text-wrap: balance; }
.bl-prose h3 { margin-top: 1.6em; font-size: 19px; font-weight: 600; line-height: 1.35; color: var(--ink); }
.bl-prose h2 + *, .bl-prose h3 + * { margin-top: 0.6em; }
.bl-prose strong { font-weight: 600; color: var(--ink); }
.bl-prose a { color: var(--pine); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.bl-prose a:hover { text-decoration-thickness: 2px; }
.bl-prose ul, .bl-prose ol { padding-left: 1.3em; }
.bl-prose ul { list-style: disc; }
.bl-prose ol { list-style: decimal; }
.bl-prose li + li { margin-top: 0.45em; }
.bl-prose li::marker { color: var(--pine); }
.bl-prose blockquote { border-left: 2px solid var(--pine); padding-left: 18px; color: rgba(22,29,24,0.72); font-style: italic; }
.bl-prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.4em 0; }
.bl-prose .nota { font-size: 14px; line-height: 1.6; color: rgba(22,29,24,0.6); }

/* Recuadro "En corto" (resumen arriba del artículo: lo que citan Google y los asistentes de IA) */
.bl-resumen {
  padding: 22px 24px; border: 1px solid var(--line); border-radius: 16px;
  background-color: var(--cream);
  background-image: radial-gradient(rgba(22,29,24,0.09) 1px, transparent 1.4px); background-size: 18px 18px;
  font-size: 16px; line-height: 1.6;
}
.bl-resumen .bl-kicker { display: block; margin-bottom: 10px; }
.bl-resumen ul { margin: 0; }

/* Tablas: con scroll horizontal propio en celular (la página nunca se desborda) */
.bl-tabla { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; -webkit-overflow-scrolling: touch; }
.bl-tabla:focus-visible { outline: 2px solid var(--pine); outline-offset: 3px; }
.bl-tabla table { width: 100%; min-width: 520px; border-collapse: collapse; font-size: 14.5px; line-height: 1.45; }
.bl-tabla th, .bl-tabla td { padding: 11px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.bl-tabla thead th { background: var(--cream); font-weight: 600; color: var(--ink); font-size: 13px; }
.bl-tabla tbody tr:last-child td { border-bottom: 0; }
.bl-tabla td.num { font-family: 'Geist Mono', ui-monospace, monospace; font-size: 13.5px; white-space: nowrap; }

/* Cierre con CTA */
.bl-cta {
  margin: 56px auto 0; max-width: 700px; text-align: center; padding: 44px 24px;
  border: 1px solid var(--line); border-radius: 22px;
  background-color: var(--cream);
  background-image: radial-gradient(rgba(22,29,24,0.10) 1px, transparent 1.4px); background-size: 18px 18px;
}
.bl-cta h2 { font-family: 'Bespoke Serif', Georgia, serif; font-weight: 400; font-size: clamp(26px, 4vw, 36px); line-height: 1.1; letter-spacing: -0.03em; color: var(--ink); text-wrap: balance; }
.bl-cta h2 em { font-style: italic; color: var(--pine); }
.bl-cta p { margin: 12px auto 24px; max-width: 30em; font-size: 15.5px; line-height: 1.6; color: rgba(22,29,24,0.66); }
.bl-back { display: inline-flex; align-items: center; gap: 8px; margin: 40px 0 72px; font-size: 14px; color: var(--pine); }
.bl-back:hover { text-decoration: underline; text-underline-offset: 3px; }
