/* Blog pages (directorio/blog.py). Colors come from tema.css; the nav, buttons and footer match
   landing.html, which keeps its own copy inline. */
@font-face {
  font-family: "Google Sans"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(/static/fonts/google-sans-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-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Google Sans"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(/static/fonts/google-sans-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;
}
:root { --sans: "Google Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif; }
* { box-sizing: border-box; }
html { scroll-padding-top: 80px; }
body {
  margin: 0; background: var(--bg); color: var(--text);
  font: 16px/1.65 var(--sans); -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
.wrap { width: min(1160px, 100% - 48px); margin-inline: auto; }
.wrap-angosto { width: min(760px, 100% - 48px); margin-inline: auto; }
h1, h2, h3 { letter-spacing: -.02em; line-height: 1.15; text-wrap: balance; }
.eyebrow { font-size: 12px; font-weight: 500; letter-spacing: .08em; text-transform: uppercase; color: var(--accent); margin: 0 0 10px; }
.eyebrow a { text-decoration: none; }
.lead { color: var(--text-2); font-size: 19px; line-height: 1.5; margin: 16px 0 0; }
.meta { color: var(--text-3); font-size: 14px; margin: 16px 0 0; }

/* Nav and footer, as on the landing page */
.btn {
  display: inline-flex; align-items: center; justify-content: center; height: 44px; padding: 0 20px;
  border-radius: 10px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--text);
  font: 500 15px var(--sans); text-decoration: none; white-space: nowrap;
}
.btn.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-text); }
.btn.primary:hover { filter: brightness(1.06); }
.btn.small { height: 36px; padding: 0 14px; font-size: 14px; border-radius: 8px; }
.btn:focus-visible, .icon-btn:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
nav.top {
  position: sticky; top: 0; z-index: 20; height: 64px;
  background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}
nav.top .wrap { height: 100%; display: flex; align-items: center; gap: 28px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; text-decoration: none; white-space: nowrap; }
.brand-mark { width: 26px; height: 26px; border-radius: 7px; background: var(--text); color: var(--bg); display: grid; place-items: center; }
.brand small { font-weight: 400; color: var(--text-3); font-size: inherit; }
.links { display: flex; gap: 24px; font-size: 14px; }
.links a { text-decoration: none; color: var(--text-2); }
.links a:hover { color: var(--text); }
.nav-actions { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.icon-btn {
  display: inline-grid; place-items: center; width: 36px; height: 36px; padding: 0;
  border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--text-2); cursor: pointer;
}
.theme-toggle .sun, :root[data-dark] .theme-toggle .moon { display: none; }
:root[data-dark] .theme-toggle .sun { display: block; }
footer { margin-top: 96px; padding: 48px 0 40px; border-top: 1px solid var(--line); color: var(--text-3); font-size: 13.5px; }
footer .cols { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 24px; }
footer .flinks { display: flex; flex-wrap: wrap; gap: 12px 20px; }
footer .flinks a { text-decoration: none; }
footer .flinks a:hover { color: var(--text); }

.migas { font-size: 13.5px; color: var(--text-3); margin: 32px 0 28px; }
.migas a { text-decoration: none; }
.migas a:hover { color: var(--text); }

/* Article */
.post header h1 { font-size: clamp(32px, 5vw, 48px); font-weight: 650; letter-spacing: -.035em; margin: 0; }
.aviso { margin: 28px 0 0; padding: 14px 16px; border-radius: 10px; border: 1px dashed var(--line-strong); background: var(--sunken); font-size: 14px; color: var(--text-2); }
.respuesta { margin: 32px 0 0; padding: 20px 22px; border-radius: 12px; background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent); }
.respuesta p:last-child { margin: 0; font-size: 17px; }
.toc { margin: 28px 0 0; padding: 16px 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.toc summary { cursor: pointer; font-weight: 600; }
.toc ul { margin: 12px 0 0; padding-left: 18px; font-size: 15px; }
.toc li.n3 { margin-left: 18px; list-style: circle; }
.toc a { text-decoration: none; color: var(--text-2); }
.toc a:hover { color: var(--text); text-decoration: underline; }
.cuerpo { margin-top: 12px; }
.cuerpo h2 { font-size: 28px; margin: 48px 0 12px; }
.cuerpo h3 { font-size: 21px; margin: 32px 0 8px; }
.cuerpo p, .cuerpo li { color: var(--text); }
.cuerpo a, .faq a, .respuesta a { color: var(--accent); text-underline-offset: 2px; }
.cuerpo li { margin: 6px 0; }
.cuerpo blockquote { margin: 24px 0; padding: 4px 20px; border-left: 3px solid var(--accent); color: var(--text-2); }
.cuerpo code { font: 14px var(--mono); background: var(--sunken); padding: 1px 6px; border-radius: 5px; }
.cuerpo hr { border: 0; border-top: 1px solid var(--line); margin: 40px 0; }
.tabla { overflow-x: auto; margin: 24px 0; border: 1px solid var(--line); border-radius: 10px; }
.tabla table { border-collapse: collapse; width: 100%; font-size: 14.5px; }
.tabla th, .tabla td { padding: 10px 14px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.tabla th { background: var(--sunken); font-weight: 600; }
.tabla tr:last-child td { border-bottom: 0; }
.faq { margin-top: 56px; }
.faq h2, .fuentes h2, .relacionados h2 { font-size: 24px; margin: 0 0 16px; }
.faq details { border-top: 1px solid var(--line); padding: 14px 0; }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; font-weight: 600; }
.faq details p { margin: 10px 0 0; color: var(--text-2); }
.cta { margin: 56px 0 0; padding: 28px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line-strong); box-shadow: var(--shadow); }
.cta h2 { font-size: 26px; margin: 0; }
.cta .lema { font-weight: 500; margin: 6px 0 0; }
.cta p { color: var(--text-2); }
.fuentes { margin-top: 48px; font-size: 14px; color: var(--text-2); }
.fuentes li { margin: 4px 0; overflow-wrap: anywhere; }
.relacionados { margin-top: 56px; }

/* Lists of posts */
.lista h1 { font-size: clamp(36px, 5.2vw, 56px); font-weight: 650; letter-spacing: -.035em; margin: 0; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 28px 0 0; }
.chips a { padding: 6px 12px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); font-size: 13.5px; text-decoration: none; color: var(--text-2); }
.chips a:hover, .chips a[aria-current] { border-color: var(--accent); color: var(--accent); }
.grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 28px; }
.relacionados .grid { margin-top: 0; }
.tarjeta { padding: 20px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface); display: flex; flex-direction: column; }
.tarjeta h3 { font-size: 18px; margin: 0; }
.tarjeta h3 a { text-decoration: none; }
.tarjeta h3 a:hover { color: var(--accent); }
.tarjeta p { color: var(--text-2); font-size: 14.5px; margin: 8px 0 0; }
.tarjeta .meta { margin-top: auto; padding-top: 12px; font-size: 13px; }

@media (max-width: 900px) {
  .grid { grid-template-columns: 1fr 1fr; }
  .links { display: none; }
}
@media (max-width: 640px) {
  .wrap, .wrap-angosto { width: calc(100% - 32px); }
  .grid { grid-template-columns: 1fr; }
  .nav-actions .btn { display: none; }
  .brand small { display: none; }
  .lead { font-size: 17px; }
  .cta { padding: 22px 18px; }
}
