/* Portal público de Actualidad Madrid: diseño editorial sobre Bootstrap 5.3 */
body.portal { background: var(--am-white); color: #1d2733; font-family: var(--bs-font-sans-serif); line-height: 1.6; }
.portal a { color: inherit; }
.font-serif, .portal h1, .portal h2, .portal h3, .portal .headline { font-family: Merriweather, Georgia, "Times New Roman", serif; }

/* Cabecera */
.topbar { background: var(--am-blue); color: #dfe6ee; font-size: .8rem; }
.topbar .clock { font-variant-numeric: tabular-nums; }
.masthead { padding: 1.75rem 0 1.25rem; }
.masthead .am-logo { font-size: clamp(1.6rem, 4.5vw, 2.6rem); }
.masthead .am-logo img { max-height: 56px; width: auto; }
.masthead .am-tagline { font-family: Merriweather, Georgia, serif; font-style: italic; font-size: .85rem; margin-top: .4rem; }
.portal-nav { border-top: 3px solid var(--am-blue); border-bottom: 1px solid #dde1e6; background: var(--am-white); }
.portal-nav .nav-link { color: var(--am-blue); font-weight: 500; font-size: .92rem; padding: .85rem .8rem; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.portal-nav .nav-link:hover, .portal-nav .nav-link.active { color: var(--am-red); border-bottom-color: var(--am-red); }
.search-form .form-control { border-radius: 2rem 0 0 2rem; border-color: #cfd5db; }
.search-form .btn { border-radius: 0 2rem 2rem 0; }

/* Contenedor y ritmo vertical */
.portal main { padding-top: 2rem; padding-bottom: 3.5rem; }
.section { margin-top: 3.5rem; }
.section-title { font-size: 1.15rem; font-weight: 900; text-transform: uppercase; letter-spacing: .06em; color: var(--am-blue);
    border-bottom: 2px solid var(--am-blue); padding-bottom: .5rem; margin-bottom: 1.5rem; display: flex; justify-content: space-between; align-items: baseline; }
.section-title a { font-family: var(--bs-font-sans-serif); font-size: .78rem; font-weight: 600; letter-spacing: 0; text-transform: none; text-decoration: none; color: var(--am-blue-2); }

/* Etiquetas */
.kicker { font-size: .72rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--am-blue-2); text-decoration: none; }
.kicker:hover { color: var(--am-red); }
.breaking { display: inline-block; background: var(--am-red); color: #fff; font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; padding: .15rem .5rem; border-radius: 2px; }
.meta { font-size: .8rem; color: var(--am-gray); }

/* Tarjetas */
.story { display: block; }
.story .thumb { height: auto; aspect-ratio: 16 / 9; object-fit: cover; width: 100%; background: var(--am-bg); border-radius: 2px; }
.story .headline { color: var(--am-blue); line-height: 1.3; margin: .35rem 0; text-decoration: none; }
.story a.headline:hover { color: var(--am-blue-2); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.story .excerpt { color: #3b4652; font-size: .95rem; margin-bottom: .4rem; }
.story-lg .headline { font-size: clamp(1.6rem, 3.6vw, 2.4rem); font-weight: 900; }
.story-lg .excerpt { font-size: 1.05rem; }
.story-md .headline { font-size: 1.15rem; font-weight: 700; }
.story-sm .headline { font-size: 1rem; font-weight: 700; }
.no-image { aspect-ratio: 16 / 9; background: linear-gradient(135deg, var(--am-blue), var(--am-blue-2)); color: rgba(255,255,255,.85); display: flex; align-items: center; justify-content: center;
    font-family: Merriweather, Georgia, serif; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; font-size: .8rem; border-radius: 2px; text-align: center; padding: 1rem; }
.story-row { padding: 1.1rem 0; border-bottom: 1px solid #e6e9ed; }
.story-row:first-child { padding-top: 0; }
.story-row:last-child { border-bottom: 0; }

/* Más leídas */
.most-read { counter-reset: rank; list-style: none; padding: 0; margin: 0; }
.most-read li { counter-increment: rank; display: flex; gap: 1rem; padding: .9rem 0; border-bottom: 1px solid #e6e9ed; }
.most-read li::before { content: counter(rank); font-family: Merriweather, Georgia, serif; font-size: 1.8rem; font-weight: 900; color: #c9d1da; line-height: 1; min-width: 1.4rem; }
.most-read a { text-decoration: none; font-weight: 600; font-size: .95rem; line-height: 1.35; color: var(--am-blue); }
.most-read a:hover { text-decoration: underline; }

/* Municipios */
.chip { display: inline-block; border: 1px solid #cfd5db; border-radius: 2rem; padding: .25rem .8rem; margin: 0 .35rem .5rem 0; font-size: .85rem; text-decoration: none; color: var(--am-blue); }
.chip:hover { border-color: var(--am-blue); background: var(--am-bg); }
.chip small { color: var(--am-gray); }

/* Artículo */
.article-title { font-size: clamp(1.8rem, 4.5vw, 2.8rem); font-weight: 900; color: var(--am-blue); line-height: 1.2; }
.article-subtitle { font-size: 1.2rem; color: var(--am-gray); font-family: Merriweather, Georgia, serif; font-weight: 400; line-height: 1.5; }
.article-body { font-family: Merriweather, Georgia, serif; font-size: 1.05rem; line-height: 1.85; max-width: 42rem; }
.article-body p { margin-bottom: 1.4rem; }
.article-figure img { width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 2px; }
.article-figure figcaption { font-size: .78rem; color: var(--am-gray); margin-top: .4rem; }
.ai-note { border-left: 3px solid var(--am-blue-2); background: var(--am-bg); padding: .8rem 1rem; font-size: .85rem; color: var(--am-gray); max-width: 42rem; }
.sources { max-width: 42rem; }
.sources li { margin-bottom: .6rem; }
.share a, .share button { width: 2.4rem; height: 2.4rem; display: inline-flex; align-items: center; justify-content: center; border: 1px solid #cfd5db; border-radius: 50%; background: #fff; color: var(--am-blue); text-decoration: none; }
.share a:hover, .share button:hover { background: var(--am-blue); color: #fff; border-color: var(--am-blue); }

/* Pie */
.portal-footer { background: var(--am-blue); color: #c9d4e0; font-size: .9rem; padding: 3rem 0 1.5rem; }
.portal-footer a { color: #e8eef5; text-decoration: none; }
.portal-footer a:hover { text-decoration: underline; }
.portal-footer h2 { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; color: #fff; font-family: var(--bs-font-sans-serif); font-weight: 700; }
.portal-footer .am-logo { color: #fff; font-size: 1.4rem; }
.portal-footer hr { border-color: rgba(255,255,255,.18); }

/* Paginación */
.pagination { --bs-pagination-color: var(--am-blue); --bs-pagination-active-bg: var(--am-blue); --bs-pagination-active-border-color: var(--am-blue); }

@media (max-width: 575.98px) {
    .section { margin-top: 2.5rem; }
    .portal main { padding-top: 1.25rem; }
}

/* Ajustes finos */
.portal-nav .nav-link { padding: .85rem .5rem; font-size: .88rem; }
.portal-footer .columns-2 { columns: 2; column-gap: 1.5rem; }
.portal-footer .columns-2 li { break-inside: avoid; }
.share { max-width: 42rem; }
.row-thumb { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; object-fit: cover; background: var(--am-bg); border-radius: 2px; }
