/* ==========================================================================
   Pulso Angelino · lenguaje de diario (capa final)
   Plano: sin degradados ni sombras pesadas; orden por reglas finas, espacio
   y jerarquía tipográfica. Íconos de línea SVG (función icon() en PHP).
   ========================================================================== */
:root{
  --d-bg:#ffffff;
  --d-surface:#f6f7f9;
  --d-ink:#0b1324;
  --d-text:#374151;
  --d-muted:#6b7280;
  --d-line:#e5e7eb;
  --d-line-strong:#d1d5db;
  --d-navy:#06173a;
  --d-blue:#0b3b8f;
  --d-red:#d90d1c;
  --d-radius:8px;
  --d-radius-img:6px;
  --d-ease:cubic-bezier(.2,.7,.2,1);
}

/* ---------- Base ---------- */
html body,body main,body .story{background:var(--d-bg)!important}
body h1,body h2,body h3{text-wrap:balance}
body p{text-wrap:pretty}
body .icon{display:inline-block;width:1em;height:1em;flex:none;vertical-align:-.14em;stroke-width:2.2}
body a .icon-arrow-right{transition:transform .2s var(--d-ease)}
body a:hover .icon-arrow-right,body button:hover .icon-arrow-right{transform:translateX(3px)}
body :focus-visible{outline:2px solid var(--d-blue)!important;outline-offset:3px}
::selection{background:#dbe7ff}

/* Sin degradados ni adornos tipográficos */
body .page-head,body .events-hero,body .media-hero,body .jobs-hero,body .jobs-cta__link,body .weather-section,body .cover-story-media,body .top-story-image,body .modern-news-image,body .story-media-shade{background-image:none!important}
body .cover-story:before,body .regional-guide:before,body .footer-grid:after,body .story-media-shade,body .newsroom:before{display:none!important;content:none!important}
body .top-stories article:before{content:none!important}
body .ticker-items a:after{content:""!important;display:inline-block;width:1px;height:14px;margin:0 22px;background:var(--d-line-strong);vertical-align:middle}

/* ---------- Superficies planas: borde fino en vez de sombra ---------- */
body .newsroom .cover-story,body .newsroom .top-stories,body .briefing,body .modern-news-card,body .news-card,body .category-lead,
body .event-page-grid article,body .event-page-lead,body .video-catalog-grid article,body .video-catalog-lead,body .community-column,
body .agenda-column,body .guide-editorial article,body .weather-widget,body .story-more__card,body .article-body,body .story-summary,
body .jobs-strip__card,body .job-card,body .empty,body .ads-home__slot--filled{box-shadow:none!important;border:1px solid var(--d-line)!important;border-radius:var(--d-radius)!important}
body .modern-news-card:hover,body .news-card:hover,body .event-page-grid article:hover,body .jobs-cta__link:hover{transform:none!important;box-shadow:none!important;border-color:var(--d-line-strong)!important}
body .modern-news-image,body .news-card-image,body .cover-story-media,body .story-media,body .top-story-image,body .top-stories article>a,body .community-feed article>a{border-radius:0!important}
body .story-media{border-radius:var(--d-radius)!important;box-shadow:none!important}
body .modern-news-image img,body .news-card-image img,body .cover-story-media img,body .category-lead img{transition:transform .5s var(--d-ease),opacity .4s ease!important}
body .modern-news-card:hover img,body .news-card:hover img,body .cover-story:hover .cover-story-media img{transform:scale(1.025)!important}

/* ---------- Cabecera ---------- */
body .site-header{border-top:3px solid var(--d-red);box-shadow:none;border-bottom:1px solid var(--d-line)}
body .main-nav{border-top:1px solid var(--d-line)!important}
body .main-nav a.nav-jobs{background:var(--d-red)!important}
body .main-nav .nav-tag-nuevo{background:#fff!important;color:var(--d-red)!important}
body .ticker{background:var(--d-bg)}
body .ticker .shell>b{background:var(--d-red)!important}
body .ticker .shell>b:before{animation:none!important}

/* ---------- Encabezados de sección: título + regla que se extiende ---------- */
body .editorial-heading,body .section-title{display:flex!important;align-items:flex-end!important;gap:16px!important;padding:0 0 12px!important;margin-bottom:22px!important;border:0!important;border-bottom:1px solid var(--d-ink)!important}
body .editorial-heading small,body .section-title small{display:block!important;padding:0!important;background:none!important;color:var(--d-red)!important;font-size:11.5px!important;font-weight:700!important;letter-spacing:.12em!important;border-radius:0!important}
body .editorial-heading h2,body .section-title h2{margin:4px 0 0!important;font-size:30px!important;line-height:1.1!important}
body .editorial-heading>a,body .section-title>a{display:inline-flex!important;align-items:center;gap:6px;margin-left:auto!important;padding:0 0 2px!important;border:0!important;background:none!important;border-radius:0!important;color:var(--d-blue)!important;font-size:13.5px!important;font-weight:700!important}
body .editorial-heading>a:hover,body .section-title>a:hover{color:var(--d-red)!important}
body .editorial-heading.light{border-bottom-color:rgba(255,255,255,.5)!important}
body .editorial-heading.light small{background:none!important;color:#ff8a92!important}
body .editorial-heading.light>a{color:#fff!important}
body .top-stories-label{border-bottom:1px solid var(--d-ink)!important}
body .section-tabs a{background:var(--d-bg)!important;border:1px solid var(--d-line)!important;border-radius:999px!important}

/* ---------- Portada ---------- */
body .newsroom .cover-story{border:0!important;border-bottom:1px solid var(--d-line)!important;border-radius:0!important}
body .newsroom .cover-story-media{border-radius:var(--d-radius)!important;overflow:hidden!important}
body .cover-story-copy{padding:8px 0 22px 28px!important}
body .cover-story-copy:before{display:none!important}
body .cover-story-copy h1{font-size:clamp(28px,2.6vw,40px)!important;line-height:1.08!important}
body .newsroom .top-stories{border:0!important;border-radius:0!important;padding:0!important}
body .newsroom .top-stories article>a,body .newsroom .top-story-image{border-radius:var(--d-radius-img)!important}
body .briefing{border-radius:var(--d-radius)!important}
body .briefing-more,body .briefing>a{background:var(--d-navy)!important}
body .modern-news-grid{gap:28px 24px!important}
body .modern-news-card{border:0!important;border-radius:0!important;background:transparent!important}
body .modern-news-card .modern-news-image{border-radius:var(--d-radius)!important;overflow:hidden}
body .modern-news-card>div{padding:12px 0 0!important}

/* Empleos: CTA plano */
body .jobs-cta__link{background:var(--d-navy)!important;border-radius:var(--d-radius)!important;box-shadow:none!important}
body .jobs-cta__link:hover{background:#0a2552!important}
body .jobs-cta__icon{background:rgba(255,255,255,.1)!important;border-radius:var(--d-radius)!important}
body .jobs-cta__btn{border-radius:var(--d-radius)!important}

/* Publicidad */
body .ads-home__slot{border-radius:var(--d-radius)!important}
body .ads-home__slot:not(.ads-home__slot--filled){background:var(--d-surface)!important;border:1px dashed var(--d-line-strong)!important}

/* Bloques inferiores */
body .weather-widget{background:var(--d-surface)!important;border:0!important}
body .media-band{background:var(--d-navy)!important}
body .community-column,body .agenda-column{border:0!important;padding:0!important;background:transparent!important}
body .agenda-list time{border-radius:var(--d-radius)!important}
body .guide-editorial article{border-radius:var(--d-radius)!important;overflow:hidden}

/* ---------- Cabeceras de páginas internas: blancas, tipográficas ---------- */
body .page-head,body .events-hero,body .media-hero{background:var(--d-bg)!important;color:var(--d-ink)!important;border-bottom:1px solid var(--d-line)!important;padding:34px 0 30px!important}
body .page-head h1,body .events-hero h1,body .media-hero h1{color:var(--d-ink)!important;font-size:clamp(36px,4.4vw,56px)!important}
body .media-hero h1 em{color:var(--d-red)!important}
body .page-head p,body .events-hero p,body .media-hero p,body .page-head-row p{color:var(--d-text)!important}
body .page-head small,body .events-hero small,body .media-hero small{color:var(--d-red)!important}
body .breadcrumbs-dark,body .breadcrumbs-dark a,body .breadcrumbs-dark span{color:var(--d-muted)!important}
body .page-head-row>b{background:var(--d-surface)!important;color:var(--d-ink)!important;border:0!important;border-radius:var(--d-radius)!important;box-shadow:none!important}
body .page-head-row>b span{color:var(--d-muted)!important}
body .region-tabs a,body .commune-tabs a{background:var(--d-bg)!important;border:1px solid var(--d-line)!important;color:var(--d-text)!important}
body .region-tabs a:hover,body .commune-tabs a:hover{border-color:var(--d-blue)!important;color:var(--d-blue)!important}
body .region-tabs a[aria-current=page],body .commune-tabs a[aria-current=page]{background:var(--d-navy)!important;border-color:var(--d-navy)!important;color:#fff!important}
body .commune-tabs span{color:var(--d-muted)!important}
body .media-hero-badge{display:none!important}
body .events-hero .black-button,body .events-hero-grid a{background:var(--d-red)!important;color:#fff!important;border-radius:var(--d-radius)!important}
body .jobs-hero{background:var(--d-navy)!important;border-radius:var(--d-radius)!important;border-top:0!important}

/* ---------- Artículo ---------- */
body .article-body{border:0!important;padding-left:0!important;padding-right:0!important;background:transparent!important}
body .story-share{background:var(--d-navy)!important;border-radius:var(--d-radius)!important}
body .story-summary{background:var(--d-surface)!important;border:0!important}
body .story-summary>a{background:var(--d-navy)!important}
body .story-more__card{border:1px solid var(--d-line)!important}
body .story-more__jobs{border-top:3px solid var(--d-blue)!important}
body .story-more__button{border-radius:var(--d-radius)!important;background:var(--d-navy)!important}
body .reading-progress span{background:var(--d-red)!important;box-shadow:none!important}

/* ---------- Pie y franja de participación ---------- */
body .contact-strip{background:var(--d-surface)!important;color:var(--d-ink)!important;border-top:1px solid var(--d-line)!important}
body .contact-strip h2{color:var(--d-ink)!important}
body .contact-strip p{color:var(--d-text)!important}
body .contact-strip__badge{background:none!important;color:var(--d-red)!important;padding:0!important}
body .contact-strip__cta{background:var(--d-navy)!important;color:#fff!important;border-radius:var(--d-radius)!important}
body .site-footer{background:var(--d-navy)!important}

/* ---------- Tecnología de interfaz ---------- */
/* Transición suave entre páginas (navegadores compatibles) */
@view-transition{navigation:auto}
::view-transition-old(root),::view-transition-new(root){animation-duration:.22s}
/* Cabecera compacta al bajar (computador) */
@media(min-width:901px){
  body .brandbar{transition:height .25s var(--d-ease),opacity .2s ease;overflow:hidden}
  body.is-scrolled .brandbar{height:0!important;opacity:0}
  body.is-scrolled .utility{display:none}
}
/* Imágenes que aparecen suavemente al cargar */
body img.is-loading{opacity:0}
body img.is-loaded{opacity:1;transition:opacity .4s ease}
/* Botón volver arriba */
body .back-to-top{position:fixed;right:20px;bottom:24px;z-index:85;display:grid;place-items:center;width:44px;height:44px;border:1px solid var(--d-line);border-radius:999px!important;background:#fff;color:var(--d-ink);cursor:pointer;opacity:0;transform:translateY(10px);pointer-events:none;transition:opacity .2s ease,transform .2s ease}
body .back-to-top.is-visible{opacity:1;transform:none;pointer-events:auto}
body .back-to-top:hover{border-color:var(--d-ink)}
body .back-to-top .icon{width:18px;height:18px}
/* (Sin content-visibility: con alturas variables en celular provocaba solapamientos entre secciones.) */
@media(prefers-reduced-motion:reduce){
  @view-transition{navigation:none}
  body *{transition:none!important;animation:none!important}
}

/* ---------- Celular ---------- */
@media(max-width:650px){
  body .editorial-heading,body .section-title{flex-wrap:nowrap!important;align-items:flex-end!important}
  body .editorial-heading>div,body .section-title>div{flex:1 1 auto!important}
  body .editorial-heading h2,body .section-title h2{font-size:23px!important}
  body .editorial-heading>a,body .section-title>a{min-height:40px;white-space:nowrap;font-size:13px!important}
  body .cover-story-copy{padding:14px 0 18px!important}
  body .cover-story-copy h1{font-size:26px!important}
  body .modern-news-grid{gap:0!important}
  body .modern-news-card{display:grid!important;grid-template-columns:112px minmax(0,1fr)!important;gap:12px;padding:14px 0!important;border-bottom:1px solid var(--d-line)!important}
  body .modern-news-card .modern-news-image{min-height:84px!important;height:84px!important;border-radius:var(--d-radius-img)!important}
  body .modern-news-card>div{padding:0!important}
  body .news-card{border:0!important;border-bottom:1px solid var(--d-line)!important;border-radius:0!important;padding:14px 0!important;margin:0!important;grid-template-columns:112px minmax(0,1fr)!important;gap:12px}
  body .news-card-image{min-height:84px!important;height:84px!important;border-radius:var(--d-radius-img)!important;overflow:hidden}
  body .news-card-image img{min-height:84px!important}
  body .news-card-copy{padding:0!important}
  body .page-head,body .events-hero,body .media-hero{padding:22px 0 20px!important}
  body .page-head h1,body .events-hero h1,body .media-hero h1{font-size:34px!important}
  body .back-to-top{bottom:calc(84px + env(safe-area-inset-bottom));right:14px}
  body .mobile-toolbar{border-radius:0!important;background:#fff!important;border-top:1px solid var(--d-line)!important;box-shadow:none!important}
  body .mobile-toolbar a{color:var(--d-muted)!important}
  body .mobile-toolbar a:first-child,body .mobile-toolbar__jobs{color:var(--d-red)!important}
}
/* overflow-x:hidden en html/body anula la cabecera fija; clip evita el desborde horizontal sin romperla */
html,html body{overflow-x:clip!important;overflow-y:visible!important}
body .media-hero .shell,body .events-hero .shell{min-height:0!important;padding-top:0!important;padding-bottom:0!important}
body .media-hero{display:block!important}
@media(max-width:650px){
  body .mobile-toolbar a:first-child,body .mobile-toolbar__jobs{color:var(--d-muted)!important}
  body .mobile-toolbar a[aria-current=page]{color:var(--d-red)!important}
}

/* Botón volver arriba: invisible e inalcanzable mientras no corresponde (no tapa enlaces) */
body .back-to-top{visibility:hidden}
body .back-to-top.is-visible{visibility:visible}

/* Zonas táctiles cómodas en tablets y pantallas táctiles */
@media(max-width:1100px),(pointer:coarse){
  body .utility-regions a,body .utility-ads{display:inline-flex;align-items:center;min-height:32px}
  body .editorial-heading>a,body .section-title>a,body .top-stories-label a,body .ads-home__label button,body .more,
  body .commune-tabs a,body .region-tabs a,body .jobs-pill,body .job-contact-btn,body .job-detail-back,body .job-detail-back a,
  body .event-fact>a,body .video-channel-link,body .story-summary>a,body .not-found a{display:inline-flex!important;align-items:center;min-height:40px}
  body .site-footer .footer-nav a,body .footer-email a,body .footer-quick-links a,body .footer-bottom__links a{display:inline-flex!important;align-items:center;min-height:40px}
}
/* Los saltos a secciones (#publicidad, #noticias) no quedan escondidos bajo la cabecera fija */
html{scroll-padding-top:150px}
@media(max-width:900px){html{scroll-padding-top:120px}}
/* Menú móvil abierto: texto oscuro sobre fondo blanco (una regla antigua lo dejaba blanco sobre blanco) */
@media(max-width:900px){
  html body .main-nav.open .main-nav-links a{color:var(--d-ink)!important;background:transparent!important;border-bottom:1px solid var(--d-line)!important;font-size:15px!important;font-weight:600!important;text-transform:none!important;letter-spacing:0!important}
  html body .main-nav.open .main-nav-links a[aria-current=page]{color:var(--d-red)!important}
  html body .main-nav.open .main-nav-links a.nav-jobs{color:#fff!important;background:var(--d-red)!important;border-bottom:0!important}
}
@media(max-width:900px){
  html body .mobile-toolbar a,html body .mobile-toolbar a.mobile-toolbar__jobs,html body .mobile-toolbar a:first-child{color:var(--d-muted)!important;background:transparent!important}
  html body .mobile-toolbar a[aria-current=page]{color:var(--d-red)!important}
  html body .mobile-toolbar a span{color:inherit!important}
}
