/* ===== Tipografía ===== */
@font-face {
  font-family: 'Lora';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/lora-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Lora';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/lora-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Lora';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/lora-700.woff2') format('woff2');
}
@font-face {
  font-family: 'Mulish';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('../fonts/mulish-300.woff2') format('woff2');
}
@font-face {
  font-family: 'Mulish';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/mulish-400.woff2') format('woff2');
}
@font-face {
  font-family: 'Mulish';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('../fonts/mulish-500.woff2') format('woff2');
}
@font-face {
  font-family: 'Mulish';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('../fonts/mulish-600.woff2') format('woff2');
}
@font-face {
  font-family: 'Mulish';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/mulish-700.woff2') format('woff2');
}

/* ===== Design tokens ===== */
:root {
  --font-head: 'Lora', Georgia, serif;
  --font-body: 'Mulish', system-ui, sans-serif;

  --bg: oklch(0.985 0.002 250);
  --bg-raised: oklch(1 0 0);
  --fg: oklch(0.18 0.01 250);
  --fg-muted: oklch(0.45 0.01 250);
  --border: oklch(0.9 0.005 250);
  --header-bg: oklch(0.18 0.01 250);
  --header-fg: oklch(0.96 0.005 250);
  --header-fg-muted: oklch(0.75 0.01 250);
  --accent: oklch(0.55 0.16 250);
  --accent-contrast: oklch(0.98 0.01 250);
  --alt-bg: oklch(0.94 0.006 250);

  --content-width: 1200px;
  --reading-width: 68ch;
  --radius: 2px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: oklch(0.16 0.008 250);
    --bg-raised: oklch(0.2 0.008 250);
    --fg: oklch(0.94 0.005 250);
    --fg-muted: oklch(0.68 0.01 250);
    --border: oklch(0.3 0.01 250);
    --header-bg: oklch(0.1 0.006 250);
    --header-fg: oklch(0.96 0.005 250);
    --header-fg-muted: oklch(0.7 0.01 250);
    --accent: oklch(0.68 0.15 250);
    --accent-contrast: oklch(0.12 0.006 250);
    --alt-bg: oklch(0.22 0.01 250);
  }
}

html[data-theme="dark"] {
  --bg: oklch(0.16 0.008 250);
  --bg-raised: oklch(0.2 0.008 250);
  --fg: oklch(0.94 0.005 250);
  --fg-muted: oklch(0.68 0.01 250);
  --border: oklch(0.3 0.01 250);
  --header-bg: oklch(0.1 0.006 250);
  --header-fg: oklch(0.96 0.005 250);
  --header-fg-muted: oklch(0.7 0.01 250);
  --accent: oklch(0.68 0.15 250);
  --accent-contrast: oklch(0.12 0.006 250);
  --alt-bg: oklch(0.22 0.01 250);
}
html[data-theme="light"] {
  --bg: oklch(0.985 0.002 250);
  --bg-raised: oklch(1 0 0);
  --fg: oklch(0.18 0.01 250);
  --fg-muted: oklch(0.45 0.01 250);
  --border: oklch(0.9 0.005 250);
  --header-bg: oklch(0.18 0.01 250);
  --header-fg: oklch(0.96 0.005 250);
  --header-fg-muted: oklch(0.75 0.01 250);
  --accent: oklch(0.55 0.16 250);
  --accent-contrast: oklch(0.98 0.01 250);
  --alt-bg: oklch(0.94 0.006 250);
}

/* ===== Reset ===== */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  text-wrap: pretty;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--fg); text-decoration: none; }
a:hover { color: var(--accent); }
ul { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, h4 { font-family: var(--font-head); font-weight: 700; line-height: 1.1; margin: 0; letter-spacing: -0.01em; }
button { font-family: inherit; cursor: pointer; }
input, textarea { font-family: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.container { max-width: var(--content-width); margin: 0 auto; padding: 0 24px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; padding: 0; margin: -1px; }
.skip-link { position: absolute; left: -9999px; top: 0; background: var(--accent); color: var(--accent-contrast); padding: 10px 16px; z-index: 200; }
.skip-link:focus { left: 0; }

/* ===== Header ===== */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: var(--header-bg); color: var(--header-fg);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 16px; padding-bottom: 16px; gap: 24px;
}
.site-logo {
  font-family: var(--font-head); font-weight: 700; font-size: 22px;
  letter-spacing: -0.02em; color: var(--header-fg); white-space: nowrap;
  display: inline-flex; align-items: center;
}
.site-logo img,
.site-header .custom-logo-link,
.site-header .custom-logo { height: 32px; width: auto; display: block; max-height: 32px; }
.primary-nav { display: flex; }
.primary-nav ul { display: flex; gap: 22px; flex-wrap: wrap; }
.primary-nav a {
  color: var(--header-fg-muted); font-size: 13px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.06em;
  transition: color .15s ease;
}
.primary-nav a:hover, .primary-nav a:focus-visible { color: var(--header-fg); }
.primary-nav .current-menu-item > a,
.primary-nav .current-menu-ancestor > a { color: var(--header-fg); border-bottom: 2px solid var(--accent); padding-bottom: 4px; }
.header-actions { display: flex; align-items: center; gap: 14px; }
.header-actions button {
  background: none; border: none; color: var(--header-fg-muted);
  font-size: 13px; font-weight: 600; letter-spacing: 0.04em;
  display: flex; align-items: center; gap: 6px; padding: 6px; border-radius: var(--radius);
  transition: color .15s ease;
}
.header-actions button:hover { color: var(--header-fg); }
.icon { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.8; }
.icon--filled { fill: currentColor; stroke: none; }

.search-panel {
  max-height: 0; overflow: hidden; background: var(--header-bg);
  transition: max-height .3s ease;
}
.search-panel.is-open { max-height: 90px; }
.search-panel .container { padding-top: 0; padding-bottom: 20px; }
.search-panel form { display: flex; border-bottom: 1px solid var(--header-fg-muted); }
.search-panel input {
  flex: 1; background: none; border: none; color: var(--header-fg);
  font-size: 20px; font-family: var(--font-head); padding: 8px 0; outline: none;
}
.search-panel input::placeholder { color: var(--header-fg-muted); }
.search-panel button[type="submit"] { background: none; border: none; color: var(--header-fg); font-weight: 700; }

.header-actions .mobile-toggle { display: none; }

@media (max-width: 860px) {
  .primary-nav { display: none; }
  .header-actions .mobile-toggle { display: flex; }
  .primary-nav.is-open {
    display: flex; position: absolute; top: 100%; left: 0; right: 0;
    background: var(--header-bg); flex-direction: column; padding: 8px 24px 20px;
  }
  .primary-nav.is-open ul { flex-direction: column; gap: 4px; }
  .primary-nav.is-open a { display: block; padding: 10px 0; border-bottom: 1px solid oklch(0.3 0.01 250 / 0.4); }
}

/* ===== Breadcrumbs ===== */
.breadcrumbs { font-size: 12px; color: var(--fg-muted); padding: 16px 24px 0; }
.breadcrumbs .container { padding: 0; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.breadcrumbs a { color: var(--fg-muted); }
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs [aria-current="page"] { color: var(--fg); font-weight: 600; }
.breadcrumbs .sep { color: var(--border); }

/* ===== Home / hero grid ===== */
.hero-grid {
  display: grid; grid-template-columns: 1.5fr 1fr; gap: 0;
  border-bottom: 1px solid var(--border);
}
.hero-main { padding: 40px 24px; border-right: 1px solid var(--border); }
.eyebrow {
  font-size: 12px; font-weight: 700; color: var(--accent);
  letter-spacing: 0.08em; text-transform: uppercase; display: inline-block;
}
.category-badge {
  display: inline-block; font-size: 11.5px; font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--accent-contrast); background: var(--accent);
  padding: 4px 10px; border-radius: 999px; margin-bottom: 8px;
}
.category-badge:hover { color: var(--accent-contrast); opacity: 0.85; }
.hero-main h1 { font-size: clamp(28px, 4vw, 40px); margin-top: 10px; }
.hero-main a.hero-title-link { transition: opacity .15s ease; }
.hero-main a.hero-title-link:hover { opacity: 0.75; }
.hero-media { display: block; margin-top: 20px; aspect-ratio: 16/9; overflow: hidden; border-radius: var(--radius); background: var(--bg-raised); }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-excerpt { font-size: 16px; color: var(--fg-muted); margin-top: 16px; max-width: 60ch; }
.hero-meta { font-size: 13px; color: var(--fg-muted); margin-top: 14px; }

.side-list { display: flex; flex-direction: column; border-left: 1px solid var(--border); }
.side-list .eyebrow { padding: 24px 24px 0; }
.side-item { padding: 16px 24px; border-bottom: 1px solid var(--border); }
.side-item:last-child { border-bottom: none; }
.side-item h3 { font-size: 18px; }
.side-item h3 a:hover { color: var(--accent); }
.side-item time { font-size: 12px; color: var(--fg-muted); margin-top: 6px; display: block; }

/* ===== Section blocks (secondary home sections) ===== */
.section-block { padding: 44px 24px; border-bottom: 1px solid var(--border); }
.section-heading {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 24px;
}
.section-heading h2 { font-size: 22px; }
.section-heading a { font-size: 13px; font-weight: 600; color: var(--fg-muted); text-transform: uppercase; letter-spacing: 0.05em; }
.section-heading a:hover { color: var(--accent); }
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 32px; }
.card-media { display: block; aspect-ratio: 16/10; overflow: hidden; border-radius: var(--radius); background: var(--bg-raised); margin-bottom: 14px; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.card:hover .card-media img { transform: scale(1.03); }

/* Bloque destacado + lista: una nota grande con imagen a la izquierda y un
   listado de titulares a la derecha, para romper la repetición de grillas
   idénticas y dar jerarquía visual a la segunda sección más relevante. */
.featured-split { display: grid; grid-template-columns: 1.4fr 1fr; gap: 28px; }
.featured-split .card-media { aspect-ratio: 16/9; }
.featured-split .featured-item h3 { font-size: 24px; line-height: 1.25; margin-top: 0; }
.featured-split .featured-item .card-excerpt { font-size: 15px; margin-top: 10px; }
.featured-list {
  display: flex; flex-direction: column; gap: 14px;
  border-left: 1px solid var(--border); padding-left: 28px;
}
.featured-list-item { border-top: 1px solid var(--border); padding-top: 14px; }
.featured-list-item:first-child { border-top: none; padding-top: 0; }
.featured-list-item h3 { font-size: 17px; font-weight: 700; line-height: 1.3; }
.featured-list-item h3 a:hover { color: var(--accent); }
.featured-list-item time { font-size: 12px; color: var(--fg-muted); margin-top: 6px; display: block; }

/* Banda distintiva: fondo alterno para diferenciar la última sección de
   portada del resto (mismo recurso que "El Esquinazo" en el diseño original). */
.section-block--band { background: var(--alt-bg); }

@media (max-width: 700px) {
  .featured-split { grid-template-columns: 1fr; }
  .featured-list { border-left: none; padding-left: 0; border-top: 1px solid var(--border); padding-top: 20px; margin-top: 4px; }
}
.card h3 { font-size: 19px; margin-top: 0; }
.card h3 a:hover { color: var(--accent); }
.card time { font-size: 12px; color: var(--fg-muted); margin-top: 8px; display: block; }
.card .card-excerpt { font-size: 14.5px; color: var(--fg-muted); margin-top: 8px; }

/* ===== Single post ===== */
/* .post-layout corre las dos columnas (contenido + sidebar) desde el
   encabezado hacia abajo, para que "Te puede interesar" empiece a la par
   del título y la imagen, no recién a la altura del cuerpo del texto. */
.post-layout {
  display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 56px; align-items: start;
  max-width: var(--content-width); margin: 0 auto; padding: 0 24px 48px;
}
.post-main { max-width: var(--reading-width); }

.post-header { padding: 24px 0 32px; text-align: left; }
.post-header .category-badge { margin-bottom: 12px; }
.post-header h1 { font-size: clamp(30px, 5vw, 46px); }
.post-subtitle { font-size: 18px; color: var(--fg-muted); margin-top: 16px; }
.post-meta {
  display: flex; align-items: center; gap: 12px; margin-top: 24px;
  font-size: 14px; color: var(--fg-muted); flex-wrap: wrap;
}
.post-meta .author-avatar { border-radius: 50%; display: block; }
.post-meta .author { font-weight: 600; color: var(--fg); margin-left: -4px; }
.post-meta .dot::before { content: "·"; margin-right: 12px; }
.post-featured-media { margin: 24px 0 32px; }
.post-featured-media figure { margin: 0; aspect-ratio: 16/9; overflow: hidden; border-radius: var(--radius); background: var(--bg-raised); }
.post-featured-media img { width: 100%; height: 100%; object-fit: cover; }
.post-featured-media figcaption { font-size: 13px; color: var(--fg-muted); margin-top: 10px; }

.post-body { font-family: var(--font-head); font-weight: 400; font-size: 19px; line-height: 1.7; }

.inline-related {
  margin: 1.8em 0; padding: 16px 20px; background: var(--bg-raised);
  border-left: 3px solid var(--accent); border-radius: var(--radius);
  font-size: 15.5px; line-height: 1.5;
}
.inline-related-label { font-weight: 700; margin-right: 6px; }
.inline-related a { color: var(--accent); text-decoration: underline; }

.post-sidebar { display: flex; flex-direction: column; gap: 40px; position: sticky; top: 88px; }
.sidebar-block .eyebrow { display: block; margin-bottom: 16px; }
.sidebar-item { display: flex; gap: 12px; padding: 14px 0; }
.sidebar-item + .sidebar-item { border-top: 1px solid var(--border); }
.sidebar-item-media { flex-shrink: 0; width: 72px; aspect-ratio: 4/3; overflow: hidden; border-radius: var(--radius); display: block; background: var(--bg-raised); }
.sidebar-item-media img { width: 100%; height: 100%; object-fit: cover; }
.sidebar-item h3 { font-size: 15px; line-height: 1.35; }
.sidebar-item h3 a:hover { color: var(--accent); }
.sidebar-item time { font-size: 11.5px; color: var(--fg-muted); margin-top: 6px; display: block; }
.sidebar-section-list li { border-top: 1px solid var(--border); }
.sidebar-section-list li:first-child { border-top: none; }
.sidebar-section-list a { display: block; padding: 10px 0; font-size: 14px; }
.sidebar-section-list a:hover { color: var(--accent); }
.post-body p { margin: 0 0 1.4em; }
.post-body h2 { font-size: 26px; margin: 1.6em 0 .6em; }
.post-body h3 { font-size: 21px; margin: 1.4em 0 .5em; }
.post-body blockquote {
  margin: 1.8em 0; padding-left: 20px; border-left: 3px solid var(--accent);
  font-family: var(--font-head); font-style: italic; font-size: 21px; color: var(--fg-muted);
}
.post-body img { border-radius: var(--radius); margin: 1.6em 0; }
.post-body figcaption { font-size: 14px; color: var(--fg-muted); text-align: center; margin-top: -1.2em; margin-bottom: 1.6em; }
.post-body a { color: var(--accent); text-decoration: underline; text-decoration-color: oklch(0.55 0.16 250 / 0.35); }
.post-body ul, .post-body ol { padding-left: 1.4em; margin: 0 0 1.4em; }
.post-body .wp-block-image, .post-body .wp-caption { margin: 1.6em 0; }
.post-body .aligncenter { margin-left: auto; margin-right: auto; }

.share-row {
  display: flex; align-items: center; gap: 10px; margin: 28px 0 0;
  padding-top: 24px; border-top: 1px solid var(--border);
}
.share-row span.share-label { font-size: 13px; color: var(--fg-muted); font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; }
.share-row .share-btn {
  width: 36px; height: 36px; border-radius: 50%; border: none; background: var(--border);
  display: flex; align-items: center; justify-content: center; color: var(--fg-muted);
  transition: background .15s ease, color .15s ease;
}
.share-row .share-btn:hover, .share-row .share-btn:focus-visible { background: var(--accent); color: var(--accent-contrast); }
.share-row .share-btn .icon { width: 16px; height: 16px; }

.share-row--compact { border-top: none; padding-top: 0; margin: 16px 0 0; }
.share-row--compact .share-btn { width: 30px; height: 30px; }
.share-row--compact .share-btn .icon { width: 14px; height: 14px; }

.page-links { font-size: 14px; color: var(--fg-muted); margin: 24px 0; }
.page-links a { color: var(--accent); margin-left: 6px; }

.tags-row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 20px 0 0; }
.tags-row a { font-size: 13px; padding: 5px 12px; border: 1px solid var(--border); border-radius: 999px; color: var(--fg-muted); }
.tags-row a:hover { border-color: var(--accent); color: var(--accent); }

/* ===== Page (static content) ===== */
.page-header { padding: 48px 24px 8px; max-width: var(--reading-width); margin: 0 auto; }
.page-header h1 { font-size: clamp(28px, 5vw, 42px); }
.page-body-wrap { display: grid; grid-template-columns: 1fr min(var(--reading-width), 100%) 1fr; padding: 24px 24px 56px; }
.page-body { grid-column: 2; font-family: var(--font-head); font-weight: 400; font-size: 18px; line-height: 1.7; }
.page-body p { margin: 0 0 1.3em; }
.page-body h2 { font-size: 24px; margin: 1.5em 0 .6em; }
.page-body h3 { font-size: 20px; margin: 1.3em 0 .5em; }
.page-body img { border-radius: var(--radius); margin: 1.5em 0; }
.page-body a { color: var(--accent); text-decoration: underline; }

/* ===== Archive / category ===== */
.archive-header { padding: 48px 24px 32px; border-bottom: 1px solid var(--border); }
.archive-header .eyebrow { margin-bottom: 8px; }
.archive-header h1 { font-size: clamp(28px, 4vw, 38px); }
.archive-header .archive-desc { color: var(--fg-muted); margin-top: 10px; max-width: 60ch; }
.archive-list { padding: 8px 24px 48px; display: flex; flex-direction: column; }
.archive-item {
  display: grid; grid-template-columns: 220px 1fr; gap: 28px;
  padding: 28px 0; border-bottom: 1px solid var(--border);
}
.archive-item .card-media { margin-bottom: 0; aspect-ratio: 4/3; }
.archive-item h2 { font-size: 22px; }
.archive-item h2 a:hover { color: var(--accent); }
.archive-item .card-excerpt { margin-top: 10px; font-size: 15.5px; }

.empty-state { padding: 56px 24px; text-align: center; color: var(--fg-muted); }

.pagination { display: flex; justify-content: center; gap: 8px; padding: 0 24px 56px; flex-wrap: wrap; }
.pagination a, .pagination span {
  padding: 8px 14px; border: 1px solid var(--border); border-radius: var(--radius);
  font-size: 14px; color: var(--fg-muted);
}
.pagination a:hover { border-color: var(--accent); color: var(--accent); }
.pagination .current { background: var(--accent); color: var(--accent-contrast); border-color: var(--accent); }

/* ===== 404 ===== */
.error-404 { max-width: 600px; margin: 0 auto; padding: 96px 24px; text-align: center; }
.error-404 .error-code { font-family: var(--font-head); font-size: 96px; font-weight: 700; color: var(--accent); line-height: 1; }
.error-404 h1 { font-size: 26px; margin-top: 16px; }
.error-404 p { color: var(--fg-muted); margin-top: 12px; line-height: 1.5; }
.error-404 .search-panel-inline { display: flex; border-bottom: 1px solid var(--border); padding-bottom: 10px; margin: 32px auto 0; max-width: 400px; }
.error-404 .search-panel-inline input { border: none; background: none; font-size: 16px; flex: 1; outline: none; font-family: inherit; color: var(--fg); }
.error-404 .search-panel-inline button { background: none; border: none; color: var(--accent); font-weight: 700; font-size: 14px; }
.error-404 .btn-home {
  display: inline-block; margin-top: 28px; padding: 12px 24px;
  background: var(--header-bg); color: var(--header-fg); border-radius: var(--radius);
  font-size: 14px; font-weight: 700;
}
.error-404 .btn-home:hover { color: var(--header-fg); opacity: .85; }
.error-suggestions { border-top: 1px solid var(--border); max-width: var(--content-width); margin: 0 auto; padding: 40px 24px; }
.error-suggestions h2 { font-size: 18px; margin-bottom: 16px; }

/* ===== Footer ===== */
.site-footer { background: var(--header-bg); color: var(--header-fg-muted); }
.footer-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 40px;
  padding: 56px 24px;
}
.footer-grid > div + div { border-left: 1px solid oklch(0.3 0.01 250); padding-left: 40px; }
.footer-brand { max-width: 320px; }
.footer-grid h4 { font-family: var(--font-head); color: var(--header-fg); font-size: 14px; text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: 16px; }
.footer-brand .site-logo {
  width: 100%; padding-bottom: 20px; margin-bottom: 4px;
  border-bottom: 1px solid oklch(0.3 0.01 250);
}
.footer-brand .site-logo img { height: 30px; }
.footer-brand p { font-size: 14px; margin-top: 16px; max-width: 32ch; }
.footer-nav li { margin-bottom: 12px; }
.footer-nav li:last-child { margin-bottom: 0; }
.footer-nav a {
  color: var(--header-fg-muted); font-size: 14px; line-height: 1.4;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.footer-nav a:hover { color: var(--header-fg); }
.footer-social { display: flex; gap: 12px; margin-top: 4px; }
.footer-social a {
  width: 36px; height: 36px; border-radius: 50%; border: none; background: oklch(0.24 0.012 250);
  display: flex; align-items: center; justify-content: center; color: var(--header-fg);
  transition: background .15s ease, color .15s ease;
}
.footer-social a:hover { background: var(--accent); color: var(--accent-contrast); }
.footer-social .icon { width: 16px; height: 16px; }
.footer-widget { font-size: 14px; }
.newsletter-intro { font-size: 14px; margin-bottom: 14px; }
.newsletter-form { display: flex; margin-top: 4px; border-bottom: 1px solid oklch(0.4 0.01 250); padding-bottom: 8px; }
.newsletter-form input { flex: 1; background: none; border: none; color: var(--header-fg); font-size: 15px; outline: none; }
.newsletter-form input::placeholder { color: var(--header-fg-muted); }
.newsletter-form button { background: none; border: none; color: var(--accent); font-weight: 700; font-size: 14px; }
.site-footer .footer-bottom {
  border-top: 1px solid oklch(0.3 0.01 250); padding: 20px 24px;
  display: flex; justify-content: space-between; font-size: 13px; flex-wrap: wrap; gap: 8px;
}
.footer-bottom a { color: var(--header-fg-muted); text-decoration: underline; }
.footer-bottom a:hover { color: var(--header-fg); }

@media (max-width: 900px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-main { border-right: none; border-bottom: 1px solid var(--border); }
  .side-list { border-left: none; }
  .post-layout, .page-body-wrap { grid-template-columns: 1fr; padding-left: 20px; padding-right: 20px; }
  .post-main { max-width: none; }
  .page-body { grid-column: 1; }
  .post-sidebar { position: static; padding-top: 32px; border-top: 1px solid var(--border); }
  .archive-item { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .container { padding-left: 18px; padding-right: 18px; }
  .site-logo img,
  .site-header .custom-logo-link,
  .site-header .custom-logo { height: 24px; max-height: 24px; }
}
@media (max-width: 480px) {
  .footer-grid { gap: 28px; padding: 40px 24px; }
  .footer-grid > div + div {
    border-left: none; padding-left: 0;
    border-top: 1px solid oklch(0.3 0.01 250); padding-top: 24px;
  }
  .footer-nav li { margin-bottom: 10px; }
}

/* ===== Progreso de lectura ===== */
.reading-progress {
  position: fixed; top: 0; left: 0; width: 100%; height: 3px; z-index: 200; pointer-events: none;
}
.reading-progress-bar {
  height: 100%; width: 100%; background: var(--accent); will-change: transform;
  transform: scaleX(0); transform-origin: left;
}

/* ===== Letra capital ===== */
.post-body > p:first-of-type::first-letter {
  font-family: var(--font-head); font-weight: 700; color: var(--accent);
  font-size: 3.6em; line-height: 0.8; float: left; margin: 0.04em 0.08em 0 0;
}

/* ===== Volver arriba ===== */
.back-to-top {
  position: fixed; bottom: 24px; right: 24px; width: 44px; height: 44px; z-index: 150;
  border: none; border-radius: 50%; background: var(--header-bg); color: var(--header-fg);
  display: flex; align-items: center; justify-content: center; cursor: pointer;
  box-shadow: 0 2px 10px oklch(0 0 0 / 0.2);
  opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: opacity .2s ease, transform .2s ease, visibility .2s, bottom .15s ease;
}
.back-to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.back-to-top:hover { opacity: 0.85; }
.back-to-top .icon { width: 20px; height: 20px; }

@media print {
  .site-header, .site-footer, .share-row, .post-sidebar, .breadcrumbs,
  .reading-progress, .back-to-top { display: none; }
}
