/*
Theme Name: El Poblador
Description: Portal editorial de El Poblador.
Template: twentytwentyfive
Version: 1.1.0
Text Domain: elpoblador
*/

:root {
    --elp-navy: #082b43;
    --elp-ink: #102b42;
    --elp-orange: #ed531c;
    --elp-line: #e4e9ed;
    --elp-paper: #f6f7f8;
}

.elp-home,
.elp-home * {
    box-sizing: border-box;
}

body.elp-home {
    margin: 0;
    color: var(--elp-ink);
    background: #fff;
    font-family: Arial, Helvetica, sans-serif;
}

.elp-home a {
    color: inherit;
    text-decoration: none;
}

.elp-home img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.elp-wrap {
    width: min(1320px, calc(100% - 40px));
    margin: 0 auto;
}

.elp-header {
    background: #fff;
    border-bottom: 1px solid var(--elp-line);
}

.elp-header-inner {
    min-height: 78px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.elp-brand a {
    color: var(--elp-navy);
    font-size: clamp(27px, 3vw, 38px);
    font-weight: 900;
    letter-spacing: -1.8px;
}

.elp-brand a span {
    color: var(--elp-orange);
}

.elp-brand .custom-logo-link {
    display: block;
    width: min(300px, 55vw);
}

.elp-brand .custom-logo {
    width: auto;
    max-width: 100%;
    max-height: 68px;
    height: auto;
    object-fit: contain;
}

.elp-header-meta {
    display: flex;
    gap: 18px;
    color: #607183;
    font-size: 12px;
    font-weight: 600;
}

.elp-weather {
    border-top: 1px solid var(--elp-line);
    border-bottom: 1px solid var(--elp-line);
    overflow: hidden;
}

.elp-weather-track {
    display: flex;
    gap: 30px;
    overflow-x: auto;
    padding: 12px 0;
    scrollbar-width: thin;
}

.elp-weather-item {
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
    font-size: 13px;
}

.elp-weather-item small {
    color: #6a7c8a;
}

.elp-weather-icon {
    color: var(--elp-orange);
    font-size: 22px;
}

.elp-nav {
    border-bottom: 1px solid var(--elp-line);
}

.elp-nav-list {
    display: flex;
    align-items: center;
    gap: 36px;
    overflow-x: auto;
    margin: 0;
    padding: 0;
    list-style: none;
}

.elp-nav-list a {
    display: block;
    padding: 17px 0;
    white-space: nowrap;
    font-size: 14px;
    font-weight: 700;
}

.elp-nav-list a:hover,
.elp-nav-list .current-menu-item a {
    color: var(--elp-orange);
}

.elp-main {
    padding-top: 18px;
}

.elp-top {
    display: grid;
    grid-template-columns: minmax(0, 1.8fr) minmax(0, 1fr);
    gap: 14px;
}

.elp-top-side {
    display: grid;
    gap: 14px;
    grid-template-rows: 1fr 1fr;
}

.elp-card {
    min-width: 0;
    overflow: hidden;
    border-radius: 7px;
    background: var(--elp-paper);
}

.elp-card-link {
    display: block;
    height: 100%;
}

.elp-card-image {
    height: 205px;
    overflow: hidden;
    background: #e6ebee;
}

.elp-card-copy {
    padding: 15px;
}

.elp-card h2 {
    margin: 8px 0;
    font-size: clamp(19px, 1.8vw, 25px);
    line-height: 1.12;
    letter-spacing: -.4px;
}

.elp-card p {
    margin: 0;
    color: #53697a;
    font-size: 14px;
    line-height: 1.45;
}

.elp-card time {
    display: block;
    margin-top: 9px;
    color: #6a7b88;
    font-size: 11px;
    font-weight: 700;
}

.elp-tag {
    display: inline-block;
    padding: 5px 8px;
    border-radius: 3px;
    background: var(--elp-orange);
    color: #fff;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
}

.elp-lead {
    position: relative;
    min-height: 490px;
    background: var(--elp-navy);
}

.elp-lead .elp-card-link {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

.elp-lead .elp-card-image {
    position: absolute;
    inset: 0;
    height: 100%;
}

.elp-lead .elp-card-image::after {
    position: absolute;
    inset: 0;
    content: "";
    background: linear-gradient(0deg, rgba(3, 27, 43, .97), rgba(3, 27, 43, .03) 75%);
}

.elp-lead .elp-card-copy {
    position: relative;
    z-index: 1;
    padding: 28px;
    color: #fff;
}

.elp-lead h2 {
    max-width: 800px;
    font-size: clamp(30px, 3.8vw, 55px);
    letter-spacing: -1.4px;
}

.elp-lead p,
.elp-lead time {
    color: #fff;
}

.elp-side-card .elp-card-image {
    height: 135px;
}

.elp-side-card h2 {
    font-size: clamp(18px, 1.7vw, 24px);
}

.elp-now {
    display: flex;
    align-items: center;
    gap: 24px;
    margin: 16px 0;
    padding: 15px 18px;
    border-radius: 6px;
    color: #fff;
    background: var(--elp-navy);
}

.elp-now > strong,
.elp-now > strong span {
    color: #ff652e;
}

.elp-now-items {
    display: flex;
    gap: 25px;
    overflow-x: auto;
}

.elp-now-items a {
    min-width: 220px;
    font-size: 12px;
    line-height: 1.3;
}

.elp-news {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.elp-events {
    margin: 20px 0;
    padding: 22px;
    border-radius: 7px;
    background: var(--elp-navy);
    color: #fff;
}

.elp-section-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
    margin-bottom: 15px;
}

.elp-section-head h2 {
    margin: 0;
    font-size: clamp(25px, 3vw, 35px);
    letter-spacing: -.7px;
}

.elp-section-head a {
    color: var(--elp-orange);
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
}

.elp-event-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

.elp-event-card {
    overflow: hidden;
    border-radius: 5px;
    background: #fff;
    color: var(--elp-ink);
}

.elp-event-card img {
    height: 140px;
}

.elp-event-card div {
    padding: 14px;
}

.elp-event-card time,
.elp-event-card span {
    display: block;
    margin-bottom: 5px;
    color: var(--elp-orange);
    font-size: 12px;
    font-weight: 700;
}

.elp-event-card h3 {
    margin: 5px 0;
    font-size: 18px;
}

.elp-event-card p {
    margin: 0;
    color: #647381;
    font-size: 13px;
    line-height: 1.4;
}

.elp-events-empty {
    margin: 0;
    color: #d6e0e7;
}

.elp-stories {
    margin: 35px 0;
}

.elp-stories .elp-section-head h2 {
    border-left: 5px solid var(--elp-orange);
    padding-left: 12px;
}

.elp-empty {
    padding: 75px 20px;
    text-align: center;
    background: var(--elp-paper);
}

.elp-footer {
    margin-top: 35px;
    padding: 26px 0;
    border-top: 1px solid var(--elp-line);
}

.elp-footer .elp-wrap {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    color: #607183;
    font-size: 13px;
}

.elp-footer strong {
    color: var(--elp-navy);
    font-size: 23px;
}

@media (max-width: 800px) {
    .elp-wrap {
        width: min(100% - 28px, 1320px);
    }

    .elp-header-meta span {
        display: none;
    }

    .elp-nav-list {
        gap: 24px;
    }

    .elp-top {
        grid-template-columns: 1fr;
    }

    .elp-top-side {
        grid-template-columns: 1fr 1fr;
        grid-template-rows: auto;
    }

    .elp-lead {
        min-height: 390px;
    }

    .elp-news,
    .elp-event-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .elp-weather-track {
        gap: 20px;
    }
}

@media (max-width: 480px) {
    .elp-header-inner {
        min-height: 64px;
    }

    .elp-header-meta {
        font-size: 11px;
    }

    .elp-top-side {
        grid-template-columns: 1fr;
    }

    .elp-lead {
        min-height: 340px;
    }

    .elp-lead .elp-card-copy {
        padding: 18px;
    }

    .elp-lead h2 {
        font-size: 32px;
    }

    .elp-news,
    .elp-event-grid {
        grid-template-columns: 1fr;
    }

    .elp-side-card .elp-card-image,
    .elp-card-image {
        height: 190px;
    }

    .elp-events {
        padding: 16px;
    }

    .elp-now {
        gap: 14px;
    }
}

/* Lectura y grilla de clima */
.elp-return {
    font-size: 14px;
    font-weight: 700;
}

.elp-article-wrap {
    width: min(100% - 40px, 1040px);
    margin: 0 auto;
    padding: 42px 0 30px;
}

.elp-article-header {
    max-width: 900px;
    margin: 0 auto 24px;
}

.elp-article-category {
    color: #d94c1a;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.elp-article h1 {
    margin: 14px 0 18px;
    color: #102b42;
    font-size: clamp(32px, 4.5vw, 54px);
    line-height: 1.1;
    letter-spacing: -.035em;
    overflow-wrap: anywhere;
}

.elp-article-deck {
    color: #4e6272;
    font-size: clamp(18px, 2vw, 22px);
    line-height: 1.45;
}

.elp-article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 20px;
    padding: 16px 0;
    border-top: 1px solid #e4e9ed;
    border-bottom: 1px solid #e4e9ed;
    color: #607183;
    font-size: 13px;
}

.elp-article-media {
    margin: 0 auto 32px;
}

.elp-article-media img {
    width: 100%;
    height: auto;
    max-height: 650px;
    object-fit: contain;
    background: #f2f4f5;
}

.elp-article-media figcaption {
    padding: 8px 0;
    color: #657582;
    font-size: 12px;
    line-height: 1.4;
}

.elp-article-content {
    max-width: 720px;
    margin: 0 auto;
    color: #263745;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 19px;
    line-height: 1.7;
    overflow-wrap: anywhere;
}

.elp-article-content p {
    margin: 0 0 1.25em;
}

.elp-article-content img {
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

.elp-article-content a {
    color: #a93812;
    text-decoration: underline;
}

.elp-weather-main {
    min-height: 55vh;
    padding: 45px 0;
}

.elp-weather-main h1 {
    margin: 8px 0;
    font-size: clamp(32px, 4vw, 48px);
}

.elp-weather-main > header > p {
    color: #607183;
}

.elp-weather-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 14px;
    margin-top: 25px;
}

.elp-weather-tile {
    padding: 20px;
    border: 1px solid #e4e9ed;
    border-radius: 8px;
    background: #f9fafb;
}

.elp-weather-tile-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.elp-weather-tile h2 {
    margin: 0;
    font-size: 16px;
}

.elp-weather-tile-top span {
    color: #ed531c;
    font-size: 25px;
}

.elp-weather-tile strong {
    display: block;
    margin-top: 16px;
    font-size: 30px;
}

.elp-weather-tile p {
    margin: 6px 0 0;
    color: #607183;
}

.elp-weather-credit {
    color: #657582;
    font-size: 12px;
}

.elp-weather-all {
    display: inline-flex;
    align-items: center;
    white-space: nowrap;
    color: #c44318;
    font-size: 13px;
    font-weight: 700;
}

@media (max-width: 600px) {
    .elp-article-wrap {
        width: min(100% - 30px, 1040px);
        padding-top: 26px;
    }

    .elp-article-content {
        font-size: 18px;
        line-height: 1.65;
    }

    .elp-weather-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .elp-weather-tile {
        padding: 15px;
    }
}

/* Cinta automática del clima */
.elp-weather-track[data-elp-ready="1"] {
    overflow: hidden;
    align-items: center;
    gap: 14px;
}

.elp-weather-window {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
}

.elp-weather-belt {
    display: flex;
    width: max-content;
    animation: elp-weather-move 36s linear infinite;
}

.elp-weather-group {
    display: flex;
    flex: 0 0 auto;
    align-items: center;
    gap: 30px;
    padding-right: 30px;
}

.elp-weather-track[data-elp-ready="1"] .elp-weather-all {
    flex: 0 0 auto;
    padding-left: 10px;
    border-left: 1px solid #e4e9ed;
}

@keyframes elp-weather-move {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
    .elp-weather-belt {
        animation: none;
    }

    .elp-weather-window {
        overflow-x: auto;
    }
}

/* ELP_DISENO_PORTADA_V1 — INICIO */

body.elp-home {
    font-family: Inter, Arial, sans-serif;
    color: #08263b;
}

body.elp-home .elp-header-inner {
    min-height: 84px;
}

body.elp-home .elp-brand .custom-logo-link {
    width: min(300px, 60vw);
}

body.elp-home .elp-brand .custom-logo {
    display: block;
    width: 100%;
    max-width: 300px;
    max-height: 90px;
    height: auto;
    object-fit: contain;
    object-position: left center;
}

/* Cinta de clima */
body.elp-home .elp-weather {
    background: #fff;
}

body.elp-home .elp-weather-track {
    min-height: 58px;
    align-items: center;
    gap: 14px;
    padding: 10px 0;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
}

body.elp-home .elp-weather-track::-webkit-scrollbar {
    display: none;
}

body.elp-home .elp-weather-track[data-elp-ready="1"] {
    overflow: hidden;
}

body.elp-home .elp-weather-window {
    min-width: 0;
    overflow: hidden;
}

body.elp-home .elp-weather-belt {
    align-items: center;
    animation-duration: 210s;
}

body.elp-home .elp-weather-group {
    align-items: center;
    gap: 28px;
}

body.elp-home .elp-weather-item {
    min-height: 34px;
    align-items: center;
    line-height: 1.35;
    font-size: 13px;
}

body.elp-home .elp-weather-item strong {
    font-weight: 700;
}

body.elp-home .elp-weather-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 25px;
    line-height: 1;
}

body.elp-home .elp-weather-all {
    align-self: center;
    flex: 0 0 auto;
    padding: 8px 0 8px 12px;
    line-height: 1.3;
}

/* Navegación */
body.elp-home .elp-nav-list {
    scrollbar-width: none;
}

body.elp-home .elp-nav-list::-webkit-scrollbar {
    display: none;
}

body.elp-home .elp-nav-list a {
    font-size: 14px;
    font-weight: 750;
}

/* Mosaico principal */
body.elp-home .elp-main {
    padding-top: 18px;
}

body.elp-home .elp-top,
body.elp-home .elp-top-side,
body.elp-home .elp-news {
    gap: 14px;
}

body.elp-home .elp-card {
    border-radius: 8px;
}

body.elp-home .elp-card-link {
    text-decoration: none;
}

body.elp-home .elp-card h2 {
    font-weight: 800;
    line-height: 1.12;
    overflow-wrap: anywhere;
}

body.elp-home .elp-card p {
    line-height: 1.45;
}

body.elp-home .elp-card-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

body.elp-home .elp-lead {
    min-height: 490px;
}

body.elp-home .elp-lead .elp-card-copy {
    padding: clamp(22px, 2.5vw, 36px);
}

body.elp-home .elp-lead h2 {
    max-width: 820px;
    font-size: clamp(32px, 3.5vw, 54px);
    font-weight: 850;
    line-height: 1.05;
}

body.elp-home .elp-side-card .elp-card-link {
    display: flex;
    flex-direction: column;
}

body.elp-home .elp-side-card .elp-card-copy {
    flex: 1;
    padding: 17px;
}

body.elp-home .elp-side-card .elp-card-image {
    flex: 0 0 145px;
}

body.elp-home .elp-side-card h2 {
    font-size: clamp(19px, 1.55vw, 23px);
}

/* Franja AHORA */
body.elp-home .elp-now {
    min-height: 58px;
    padding: 12px 18px;
}

body.elp-home .elp-now-items {
    align-items: center;
    scrollbar-width: none;
}

body.elp-home .elp-now-items::-webkit-scrollbar {
    display: none;
}

body.elp-home .elp-now-items a {
    color: #fff;
    line-height: 1.35;
}

/* Eventos */
body.elp-home .elp-events {
    margin-top: 24px;
    padding: clamp(16px, 2vw, 24px);
    border-radius: 8px;
}

body.elp-home .elp-events .elp-section-head h2 {
    color: #fff;
    font-weight: 850;
}

body.elp-home .elp-events .elp-section-head a {
    display: inline-flex;
    align-items: center;
    min-height: 40px;
    padding: 8px 14px;
    border-radius: 6px;
    background: #f4511e;
    color: #fff;
}

body.elp-home .elp-event-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
}

body.elp-home .elp-event-card {
    display: flex;
    flex-direction: column;
    min-width: 0;
    text-decoration: none;
}

body.elp-home .elp-event-card img {
    display: block;
    width: 100%;
    height: 150px;
    object-fit: cover;
}

body.elp-home .elp-event-card div {
    flex: 1;
    padding: 16px;
}

body.elp-home .elp-event-card time {
    font-size: 13px;
    line-height: 1.35;
}

body.elp-home .elp-event-card h3 {
    font-weight: 800;
    line-height: 1.2;
    overflow-wrap: anywhere;
}

@media (max-width: 900px) {
    body.elp-home .elp-event-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 680px) {
    body.elp-home .elp-wrap {
        width: calc(100% - 28px);
    }

    body.elp-home .elp-header-inner {
        min-height: 72px;
        gap: 12px;
    }

    body.elp-home .elp-brand .custom-logo-link {
        width: min(225px, 55vw);
    }

    body.elp-home .elp-header-meta {
        font-size: 11px;
        text-align: right;
        line-height: 1.3;
    }

    body.elp-home .elp-weather-track {
        min-height: 54px;
        padding: 8px 0;
    }

    body.elp-home .elp-weather-group {
        gap: 22px;
    }

    body.elp-home .elp-weather-item {
        font-size: 13px;
    }

    body.elp-home .elp-nav-list {
        gap: 24px;
    }

    body.elp-home .elp-nav-list a {
        padding: 14px 0;
        font-size: 14px;
    }

    body.elp-home .elp-top {
        grid-template-columns: minmax(0, 1fr);
    }

    body.elp-home .elp-top-side {
        grid-template-columns: minmax(0, 1fr);
        grid-template-rows: auto;
    }

    body.elp-home .elp-lead {
        min-height: 380px;
    }

    body.elp-home .elp-lead h2 {
        font-size: clamp(29px, 8vw, 40px);
        line-height: 1.08;
    }

    body.elp-home .elp-side-card .elp-card-image {
        flex-basis: 160px;
    }

    body.elp-home .elp-news {
        grid-template-columns: minmax(0, 1fr);
    }

    body.elp-home .elp-now {
        gap: 14px;
    }

    body.elp-home .elp-section-head h2 {
        font-size: 27px;
    }
}

@media (max-width: 420px) {
    body.elp-home .elp-header-meta span {
        display: none;
    }

    body.elp-home .elp-event-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    body.elp-home .elp-events .elp-section-head a {
        padding: 8px 10px;
        font-size: 12px;
    }
}

@media (prefers-reduced-motion: reduce) {
    body.elp-home .elp-weather-belt {
        animation: none;
    }

    body.elp-home .elp-weather-window {
        overflow-x: auto;
    }
}

/* ELP_DISENO_PORTADA_V1 — FIN */

/* ELP_LEGIBILIDAD_PORTADA_V1 — INICIO */

body.elp-home .elp-events .elp-event-card {
    color: #08263b;
}

body.elp-home .elp-events .elp-event-card h3 {
    color: #08263b;
}

body.elp-home .elp-news {
    align-items: start;
}

body.elp-home .elp-news .elp-card-link {
    height: auto;
}

body.elp-home .elp-side-card:not(:has(.elp-card-image)) .elp-card-link {
    justify-content: center;
}

/* ELP_LEGIBILIDAD_PORTADA_V1 — FIN */
