/* ASIES — estilos públicos. Mobile first, sin fuentes externas. */
:root {
  --brand: #c8102e;
  --brand-dark: #9e0c24;
  --accent: var(--brand);
  --ink: #121212;
  --ink-2: #3d3d3d;
  --muted: #6a6a6a;
  --line: #e3e1dc;
  --bg: #ffffff;
  --bg-soft: #f6f5f2;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: Charter, "Bitstream Charter", "Iowan Old Style", "Sitka Text", Cambria, Georgia, serif;
  --gutter: 16px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.5 var(--sans); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
[hidden] { display: none !important; }
a { color: inherit; }
button { font: inherit; }
h1, h2, h3 { margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: #fff; padding: 10px 14px; z-index: 50; }
.skip:focus { left: 8px; top: 8px; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 var(--gutter); }
.wrap-narrow { max-width: 760px; }
.wrap-read { max-width: 700px; margin: 0 auto; padding: 0 var(--gutter); }
.wrap-wide { max-width: 1100px; margin: 0 auto; }

/* ---------- Cabecera ---------- */
.site-header { background: var(--bg); border-bottom: 1px solid var(--line); }
.masthead { display: flex; align-items: center; justify-content: space-between; height: 58px; }
.brand { text-decoration: none; display: inline-flex; align-items: center; }
.wordmark { font-family: var(--sans); font-weight: 900; font-size: 29px; letter-spacing: -0.045em; line-height: 1; color: var(--ink); }
.wordmark::after { content: ""; display: inline-block; width: .26em; height: .26em; margin-left: .06em; background: var(--brand); }
.wordmark-inverse { color: #fff; }
.logo-img { height: 32px; width: auto; }
.icon-btn { display: inline-grid; place-items: center; width: 44px; height: 44px; margin-right: -10px; color: var(--ink); border-radius: 50%; }
.icon-btn:hover { background: var(--bg-soft); }

.section-nav { border-top: 1px solid var(--line); }
.section-nav ul { list-style: none; display: flex; gap: 22px; overflow-x: auto; scrollbar-width: none; margin: 0 auto; white-space: nowrap; }
.section-nav ul::-webkit-scrollbar { display: none; }
.section-nav a { display: block; padding: 12px 0 10px; font-size: 13px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; text-decoration: none; color: var(--ink-2); border-bottom: 3px solid transparent; }
.section-nav a:hover { color: var(--ink); }
.section-nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--brand); }

/* ---------- Tarjetas ---------- */
.card { position: relative; }
.card a { text-decoration: none; }
.card-media { display: block; background: var(--bg-soft); overflow: hidden; }
.card-media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.card-title a:hover { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
.kicker { display: inline-block; font-size: 12px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: var(--accent); text-decoration: none; margin-bottom: 6px; }
.card-title { font-weight: 800; letter-spacing: -0.012em; line-height: 1.2; }
.card-dek { color: var(--ink-2); margin: 8px 0 0; font-size: 16px; line-height: 1.45; }
.card-time { display: block; color: var(--muted); font-size: 13px; margin-top: 8px; }

.card-lead .card-media { margin: 0 calc(var(--gutter) * -1); }
.card-lead .card-body { padding-top: 14px; }
.card-lead .card-title { font-size: 28px; line-height: 1.12; letter-spacing: -0.022em; }
.card-lead .card-dek { font-size: 17px; }

.card-standard .card-body { padding-top: 10px; }
.card-standard .card-title { font-size: 19px; }

.card-row { display: grid; grid-template-columns: 1fr 112px; gap: 14px; padding: 14px 0; border-top: 1px solid var(--line); }
.card-row:not(:has(.card-media)) { grid-template-columns: 1fr; }
.card-row .card-media { grid-column: 2; grid-row: 1; align-self: start; }
.card-row .card-media img { aspect-ratio: 4 / 3; }
.card-row .card-body { grid-column: 1; grid-row: 1; }
.card-row .card-title { font-size: 17px; }
.card-row .kicker { margin-bottom: 3px; font-size: 11px; }
.card-row .card-time { margin-top: 6px; font-size: 12px; }

.card-compact .card-title { font-size: 16px; font-weight: 700; }
.card-compact .kicker { font-size: 11px; margin-bottom: 2px; }
.card-compact .card-time { display: none; }

/* ---------- Portada ---------- */
.front { padding-top: 0; }
.front-side .card-row:first-child { border-top: 0; }
.block { margin-top: 36px; }
.block-title { display: flex; justify-content: space-between; align-items: baseline; border-top: 3px solid var(--ink); padding-top: 10px; margin-bottom: 16px; font-size: 15px; font-weight: 900; letter-spacing: .06em; text-transform: uppercase; }
.block-title a { text-decoration: none; }
.block[style*="--accent"] .block-title { border-top-color: var(--accent); }
.block-more { font-size: 12px; font-weight: 700; color: var(--muted); letter-spacing: .04em; }
.grid-2, .grid-3 { display: grid; gap: 28px; }
.list .card-row:first-child { border-top: 0; padding-top: 0; }
.with-rail { display: block; }
.ranked { list-style: none; counter-reset: rank; margin: 0; padding: 0; }
.ranked li { counter-increment: rank; display: grid; grid-template-columns: 34px 1fr; padding: 12px 0; border-top: 1px solid var(--line); }
.ranked li:first-child { border-top: 0; padding-top: 0; }
.ranked li::before { content: counter(rank); font-size: 26px; font-weight: 900; color: var(--brand); line-height: 1; }

@media (min-width: 700px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .list-2 { display: grid; grid-template-columns: 1fr 1fr; column-gap: 28px; }
  .list-2 .card-row:nth-child(2) { border-top: 0; padding-top: 0; }
  .card-lead .card-media { margin: 0; }
}
@media (min-width: 960px) {
  :root { --gutter: 24px; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .front { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); gap: 32px; padding-top: 24px; }
  .front-side { border-left: 1px solid var(--line); padding-left: 24px; }
  .card-lead .card-title { font-size: 40px; }
  .with-rail { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 40px; align-items: start; }
  .rail { position: sticky; top: 16px; }
  .masthead { height: 76px; }
  .wordmark { font-size: 38px; }
}

/* ---------- Páginas de listado ---------- */
.page-head { padding: 20px 0 8px; }
.page-title { font-size: 32px; font-weight: 900; letter-spacing: -0.03em; line-height: 1.1; }
.page-desc { color: var(--ink-2); margin: 8px 0 0; font-size: 17px; }
.section-lead { margin-top: 16px; }
.pager { display: flex; justify-content: space-between; margin: 32px 0; }
.result-count { color: var(--muted); font-size: 14px; }
.search-form { display: flex; gap: 8px; margin-top: 16px; }
.search-form input { flex: 1; min-width: 0; height: 48px; padding: 0 14px; font-size: 17px; border: 1.5px solid var(--ink); border-radius: 2px; background: #fff; }

.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 10px; padding: 0; font-size: 13px; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin-right: 6px; color: var(--line); }
.crumbs a { text-decoration: none; }
.crumbs a:hover { text-decoration: underline; }

/* ---------- Artículo ---------- */
.article-head { padding-top: 18px; }
.article-head .crumbs { display: none; }
.article-title { font-size: 30px; line-height: 1.12; font-weight: 800; letter-spacing: -0.025em; margin-top: 2px; }
.article-dek { font-size: 19px; line-height: 1.42; color: var(--ink-2); margin: 12px 0 0; }
.byline { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin: 14px 0 18px; font-size: 14px; color: var(--muted); }
.byline-author { color: var(--ink); font-weight: 700; }
.byline-updated { flex-basis: 100%; font-size: 13px; }
.dot { color: #b9b9b9; }
.article-cover { margin: 0 0 22px; }
.article-cover img { width: 100%; }
.article-cover figcaption { font-size: 13px; color: var(--muted); padding: 8px var(--gutter) 0; }

.article-body { font-family: var(--serif); font-size: 19px; line-height: 1.68; color: #1b1b1b; }
.article-body > * { margin: 0 0 1.05em; }
.article-body h2 { font-family: var(--sans); font-size: 23px; line-height: 1.25; font-weight: 800; letter-spacing: -0.015em; margin: 1.6em 0 .5em; }
.article-body h3 { font-family: var(--sans); font-size: 19px; line-height: 1.3; font-weight: 800; margin: 1.4em 0 .4em; }
.article-body a { color: var(--brand-dark); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.article-body blockquote { margin: 1.4em 0; padding: 0 0 0 18px; border-left: 3px solid var(--brand); font-size: 21px; line-height: 1.5; font-style: italic; color: var(--ink); }
.article-body blockquote p { margin: 0; }
.article-body ul, .article-body ol { padding-left: 1.3em; }
.article-body li { margin: .35em 0; }
.article-body hr { border: 0; height: 1px; background: var(--line); margin: 2em 0; }
.article-body figure { margin: 1.5em 0; }
.article-body figure img { width: 100%; }
.article-body figcaption { font-family: var(--sans); font-size: 13px; color: var(--muted); margin-top: 6px; }
.article-body .embed-youtube { position: relative; aspect-ratio: 16 / 9; background: #000; }
.article-body .embed-youtube iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.article-body .embed-link { font-family: var(--sans); border: 1px solid var(--line); padding: 14px 16px; font-size: 15px; }
.article-body .embed-link a { font-weight: 700; }

.source, .report { font-family: var(--sans); font-size: 14px; color: var(--muted); }
.source a, .report a { color: var(--ink); }
.sources { font-family: var(--sans); border-top: 1px solid var(--line); padding-top: 14px; }
.sources h2 { font-size: 13px; letter-spacing: .06em; text-transform: uppercase; margin: 0 0 6px; }
.sources ul { font-size: 14px; color: var(--ink-2); padding-left: 1.1em; margin: 0; word-break: break-word; }
.notice { font-family: var(--sans); font-size: 14px; background: var(--bg-soft); border-left: 3px solid var(--accent); padding: 10px 14px; }
.preview-bar { background: #fff4c4; color: #5a4600; text-align: center; font-size: 14px; font-weight: 700; padding: 8px; }

@media (min-width: 700px) {
  .article-head { padding-top: 28px; }
  .article-head .crumbs { display: block; }
  .article-title { font-size: 44px; line-height: 1.08; }
  .article-dek { font-size: 21px; }
  .article-cover figcaption { padding: 8px 0 0; }
  .article-body { font-size: 20px; }
}

/* ---------- Compartir ---------- */
.share { font-family: var(--sans); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 14px 0; margin: 28px 0 14px; }
.share-label { display: block; font-size: 12px; font-weight: 800; letter-spacing: .07em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.share-buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.share-btn { display: inline-flex; align-items: center; min-height: 42px; padding: 0 14px; border: 1.5px solid var(--ink); background: #fff; color: var(--ink); font-size: 14px; font-weight: 700; text-decoration: none; border-radius: 3px; cursor: pointer; }
.share-btn:hover { background: var(--bg-soft); }
.share-native { background: var(--ink); color: #fff; }
.share-native:hover { background: #000; }
.share a.share-btn { color: var(--ink); text-decoration: none; }
.share a.share-wa { border-color: #128c3e; color: #0d6e30; }

/* ---------- Publicidad ---------- */
.ad-slot { margin: 28px auto; text-align: center; font-family: var(--sans); }
.ad-slot[data-pending] { display: none; }
.ad-label { display: block; font-size: 10px; letter-spacing: .1em; text-transform: uppercase; color: #9a9a9a; margin-bottom: 6px; }

/* ---------- Botones y formularios ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; padding: 0 20px; border: 1.5px solid var(--ink); border-radius: 3px; background: var(--ink); color: #fff; font-size: 15px; font-weight: 700; text-decoration: none; cursor: pointer; }
.btn:hover { background: #000; }
.btn-ghost { background: transparent; color: var(--ink); }
.btn-ghost:hover { background: var(--bg-soft); }
.btn-link { background: none; border: 0; padding: 0; color: inherit; text-decoration: underline; cursor: pointer; font-size: inherit; }
.form { margin-top: 20px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-weight: 700; font-size: 15px; margin-bottom: 6px; }
.field input, .field textarea { width: 100%; padding: 12px; font: 17px/1.4 var(--sans); border: 1.5px solid #b8b6b0; border-radius: 3px; background: #fff; }
.field input:focus, .field textarea:focus { border-color: var(--ink); outline: none; box-shadow: 0 0 0 3px rgba(200, 16, 46, .15); }
.form-note { font-size: 13px; color: var(--muted); }
.hp { position: absolute; left: -9999px; }
.alert { padding: 12px 14px; border-radius: 3px; font-weight: 600; }
.alert-ok { background: #e9f6ec; color: #145c26; }
.alert-error { background: #fdecee; color: #8a0f22; }

/* ---------- Páginas estáticas ---------- */
.static { padding-top: 24px; padding-bottom: 20px; }
.prose p, .prose li { font-size: 17px; line-height: 1.65; color: var(--ink-2); }
.prose h2 { font-size: 21px; margin: 28px 0 8px; }
.prose .lead { font-size: 19px; color: var(--ink); }
.empty { text-align: center; padding: 56px 16px; color: var(--ink-2); }
.empty-title { font-size: 20px; font-weight: 800; color: var(--ink); margin: 0 0 6px; }
.notfound { text-align: center; padding-top: 48px; padding-bottom: 32px; }
.notfound-code { font-size: 88px; font-weight: 900; letter-spacing: -.05em; color: var(--brand); margin: 0; line-height: 1; }
.notfound-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin: 20px 0; }
.notfound .search-form { max-width: 460px; margin: 20px auto 0; }

/* ---------- Pie ---------- */
.site-footer { background: var(--ink); color: #d6d6d6; margin-top: 56px; padding: 36px 0 24px; font-size: 15px; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.footer-grid { display: grid; gap: 28px; }
.footer-desc { margin: 10px 0 0; max-width: 34ch; color: #bdbdbd; }
.footer-h { font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: #9b9b9b; margin-bottom: 10px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: 7px 0; }
.footer-social { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 14px !important; }
.footer-link { color: #fff; text-decoration: none; font-size: 15px; }
.footer-bottom { border-top: 1px solid #333; margin-top: 28px; padding-top: 18px; font-size: 13px; color: #9b9b9b; }
.footer-bottom p { margin: 0; }
@media (min-width: 800px) { .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; } }

/* ---------- Consentimiento ---------- */
.consent { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 40; max-width: 560px; margin: 0 auto; background: #fff; color: var(--ink); border: 1px solid var(--line); box-shadow: 0 6px 30px rgba(0, 0, 0, .18); padding: 14px 16px; font-size: 14px; border-radius: 4px; padding-bottom: calc(14px + env(safe-area-inset-bottom)); }
.consent p { margin: 0 0 10px; }
.consent-opts { display: grid; gap: 8px; margin-bottom: 12px; }
.consent-opts label { display: flex; gap: 8px; align-items: center; font-weight: 600; }
.consent-opts input { width: 20px; height: 20px; accent-color: var(--brand); }
.consent-actions { display: flex; gap: 8px; align-items: center; justify-content: flex-end; flex-wrap: wrap; }
.consent-actions .btn { min-height: 40px; padding: 0 16px; font-size: 14px; }
.consent-actions .btn-link { margin-right: auto; font-size: 14px; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 3px; font-size: 14px; font-weight: 600; z-index: 60; }
