/* SCD — Explore (Article listing) page styles.
 * Independent Sitefinity widgets, each self-including this sheet;
 * desktop/mobile variants viewport-gated (≤768px → mobile). Same
 * architecture as multimedia-listing.css.
 */

/* ===== Viewport gates ===== */
.ex-hero--desktop, .ex-section--desktop, .ex-cta--desktop { display: block; }
.ex-hero--mobile, .ex-section--mobile, .ex-cta--mobile { display: none; }
@media (max-width: 768px) {
    .ex-hero--desktop, .ex-section--desktop, .ex-cta--desktop { display: none; }
    .ex-hero--mobile, .ex-section--mobile, .ex-cta--mobile { display: block; }
}

/* ===== Hero (Figma 1552:8580) — text only ===== */
.ex-hero { background: #FFFFFF; }
.ex-hero__container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 112px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}
.ex-hero--desktop { padding: 56px 0; }
.ex-hero--mobile  { padding: 24px 0; }
.ex-hero--mobile .ex-hero__container { padding: 0 16px; gap: 8px; }
.ex-hero__eyebrow {
    display: inline-flex; align-items: center; gap: 12px; margin: 0;
    color: #2FB8A9; font-size: 20px; line-height: 28px; font-weight: 400;
}
.ex-hero__eyebrow-icon { width: 28px; height: 28px; display: block; }
.ex-hero--mobile .ex-hero__eyebrow { gap: 8px; font-size: 12px; line-height: 20px; }
.ex-hero--mobile .ex-hero__eyebrow-icon { width: 16px; height: 16px; }
.ex-hero__heading {
    margin: 0; font-size: 48px; line-height: 60px; font-weight: 600;
    letter-spacing: -0.96px; color: #000000;
}
.ex-hero--mobile .ex-hero__heading { font-size: 30px; line-height: 38px; font-weight: 700; letter-spacing: 0; color: #262626; }
.ex-hero__lead { margin: 0; font-size: 20px; line-height: 30px; color: #595959; }
.ex-hero--mobile .ex-hero__lead { font-size: 14px; line-height: 22px; }

/* ===== Section scaffold ===== */
.ex-section { background: #FFFFFF; }
.ex-section--desktop { padding: 48px 0; }
.ex-section--mobile  { padding: 24px 0; }
.ex-section__container { max-width: 1440px; margin: 0 auto; padding: 0 112px; }
.ex-section--mobile .ex-section__container { padding: 0 16px; }
.ex-section__header {
    display: flex; flex-direction: column; gap: 20px; margin-bottom: 36px;
}
.ex-section__header--row { flex-direction: row; align-items: center; justify-content: space-between; }
.ex-section--mobile .ex-section__header { gap: 8px; margin: 0 16px 20px; }
.ex-section__title {
    margin: 0; font-size: 36px; line-height: 44px; font-weight: 600;
    letter-spacing: -0.72px; color: rgba(0, 0, 0, 0.88);
}
.ex-section--mobile .ex-section__title { font-size: 20px; line-height: 28px; font-weight: 700; }
.ex-section__subtitle { margin: 0; font-size: 20px; line-height: 30px; color: #595959; }
.ex-section--mobile .ex-section__subtitle { font-size: 14px; line-height: 20px; }
.ex-empty { color: #595959; font-size: 16px; padding: 8px 0; }
.ex-loading { text-align: center; color: #6B7280; font-size: 14px; margin: 12px 0 0; }

/* ===== Featured Articles card (Figma 1552:8598) ===== */
.ex-fgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
.ex-fcard { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.ex-fcard__media { display: block; height: 208px; border-radius: 8px; overflow: hidden; background: #EEF1F6; }
.ex-fcard__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ex-fcard__media-ph { display: block; width: 100%; height: 100%; }
.ex-fcard__title { margin: 0; }
.ex-fcard__title a {
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
    font-size: 16px; line-height: 24px; font-weight: 600; color: #1C1C1C; text-decoration: none;
}
.ex-fcard__title a:hover { color: #465DA6; }
.ex-fcard__byline { display: flex; align-items: center; gap: 12px; }
.ex-fcard__avatar { width: 32px; height: 32px; border-radius: 50%; overflow: hidden; background: #EEF1FB; flex: 0 0 32px; }
.ex-fcard__avatar img { width: 32px; height: 32px; object-fit: cover; display: block; }
.ex-fcard__who { display: flex; flex-direction: column; min-width: 0; }
.ex-fcard__name { font-size: 14px; line-height: 20px; font-weight: 600; color: #1C1C1C; }
.ex-fcard__org { font-size: 14px; line-height: 20px; color: #8C8C8C; }

/* ===== Browse Articles card (Figma 1552:9369) ===== */
.ex-grid { display: grid; gap: 32px; }
.ex-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ex-card { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.ex-card__media { position: relative; display: block; height: 282px; border-radius: 8px; overflow: hidden; background: #EEF1F6; }
.ex-card__media img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ex-card__media-ph { display: block; width: 100%; height: 100%; }
.ex-card__badge {
    position: absolute; left: 8px; top: 8px;
    background: #EAF8F6; color: #269387; font-size: 14px; line-height: 20px; font-weight: 500;
    padding: 4px 12px; border-radius: 16px;
}
.ex-card__title { margin: 0; }
.ex-card__title a {
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
    font-size: 16px; line-height: 24px; font-weight: 600; color: #1C1C1C; text-decoration: none;
}
.ex-card__title a:hover { color: #465DA6; }
.ex-card__meta { display: flex; align-items: center; gap: 8px; margin: 8px 0 0; font-size: 14px; line-height: 20px; }
.ex-card__author { color: #000000; }
.ex-card__org { color: rgba(0, 0, 0, 0.45); }
.ex-card__dot { width: 2px; height: 2px; border-radius: 50%; background: rgba(0, 0, 0, 0.45); flex: 0 0 auto; }

/* ===== Browse layout (Figma 1552:9338) ===== */
.ex-browse__layout { display: flex; align-items: flex-start; gap: 52px; }
.ex-browse__main { flex: 1 1 0; min-width: 0; }
.ex-browse__bar { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.ex-browse [data-ex-browse-container].is-loading { opacity: 0.55; transition: opacity 120ms; }
.ex-filter { width: 240px; flex: 0 0 240px; }
.ex-filter__heading { margin: 0 0 28px; font-size: 16px; line-height: 24px; font-weight: 600; color: #8C8C8C; }
.ex-filter__group { margin-bottom: 28px; }
.ex-filter__group-title { margin: 0 0 8px; font-size: 16px; line-height: 24px; font-weight: 600; color: #000000; }
.ex-filter__opt { display: flex; align-items: center; gap: 12px; padding: 4px 0; font-size: 16px; line-height: 24px; color: #414651; cursor: pointer; }
.ex-filter__opt input { width: 20px; height: 20px; flex: 0 0 auto; accent-color: #465DA6; }
.ex-filter__opt--disabled { opacity: 0.45; cursor: default; }
.ex-sortbar { display: inline-flex; align-items: center; gap: 8px; }
.ex-sortbar__label { font-size: 16px; line-height: 24px; color: #8C8C8C; }
.ex-sortbar__select { appearance: auto; border: 0; background: transparent; font-size: 16px; line-height: 24px; font-weight: 600; color: #1C1C1C; cursor: pointer; }
.ex-pager { display: flex; align-items: center; justify-content: center; gap: 4px; margin-top: 32px; }
.ex-pager__num, .ex-pager__nav {
    min-width: 38px; height: 38px; padding: 0 8px; border: 1px solid #D5D7DA;
    background: #FFFFFF; border-radius: 8px; color: #414651; font-size: 14px; font-weight: 600; cursor: pointer;
}
.ex-pager__num.is-active { background: #EBF1FF; border-color: #465DA6; color: #465DA6; }
.ex-pager__num:disabled, .ex-pager__nav:disabled { opacity: 0.4; cursor: default; }
.ex-pager__gap { padding: 0 4px; color: #8C8C8C; }

/* ===== Impact Initiatives (Figma 1552:8789) — two design images ===== */
.ex-impact__row { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.ex-impact__panel { display: block; border-radius: 16px; overflow: hidden; }
.ex-impact__panel img { width: 100%; height: auto; display: block; }

/* ===== CTA ===== */
.ex-cta { background: #F6F9FF; }
.ex-cta__inner {
    max-width: 1440px; margin: 0 auto; padding: 72px 112px;
    display: flex; flex-direction: column; align-items: center; text-align: center; gap: 16px;
}
.ex-cta__title { margin: 0; font-size: 40px; line-height: 48px; font-weight: 600; letter-spacing: -0.8px; color: #000000; }
.ex-cta__sub { margin: 0; font-size: 18px; line-height: 27px; color: #595959; }
.ex-cta__btn {
    margin-top: 8px; display: inline-flex; align-items: center; justify-content: center;
    padding: 12px 24px; border-radius: 8px; background: #465DA6; color: #FFFFFF;
    font-size: 16px; line-height: 24px; font-weight: 600; text-decoration: none;
    box-shadow: 0 1px 2px rgba(10, 13, 18, 0.05);
}
.ex-cta__btn:hover { background: #38489E; color: #FFFFFF; }
.ex-cta--mobile .ex-cta__inner { padding: 40px 16px; }
.ex-cta--mobile .ex-cta__title { font-size: 26px; line-height: 34px; }
.ex-cta--mobile .ex-cta__sub { font-size: 15px; line-height: 22px; }

/* ===== Shimmer skeleton ===== */
@keyframes ex-shimmer { 0% { background-position: -400px 0; } 100% { background-position: 400px 0; } }
.ex-skel {
    display: block; background-color: #eef0f6;
    background-image: linear-gradient(90deg, #eef0f6 0%, #f7f8fb 50%, #eef0f6 100%);
    background-size: 400px 100%; background-repeat: no-repeat;
    animation: ex-shimmer 1.2s ease-in-out infinite; border-radius: 6px;
}
.ex-skel--media { width: 100%; height: 240px; border-radius: 8px; }
.ex-skel--line { height: 12px; margin: 8px 0; }
.ex-skel--w50 { width: 50%; } .ex-skel--w80 { width: 80%; }
.ex-grid--skeleton { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 32px; }
.ex-card--skeleton { display: flex; flex-direction: column; gap: 8px; pointer-events: none; }

/* ===== MOBILE reflow (equivalent design for ≤768px) ===== */
@media (max-width: 768px) {
    /* Featured → horizontal scroller of 280-wide cards */
    .ex-section--mobile .ex-fgrid {
        display: flex; grid-template-columns: none; gap: 16px;
        overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 0 16px;
    }
    .ex-section--mobile .ex-fgrid::-webkit-scrollbar { display: none; }
    .ex-section--mobile .ex-fgrid > * { flex: 0 0 auto; width: 280px; scroll-snap-align: start; }
    .ex-section--mobile .ex-fcard__media { height: 180px; }
    .ex-section--mobile .ex-fcard__title a { font-size: 16px; line-height: 22px; -webkit-line-clamp: 2; }

    /* Browse → single full-width column, collapsible filter */
    .ex-browse--mobile .ex-section__title { margin: 0 16px 16px; }
    .ex-browse--mobile .ex-browse__layout { flex-direction: column; gap: 16px; padding: 0 16px; }
    .ex-browse--mobile .ex-browse__toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
    .ex-browse--mobile .ex-browse__filter-btn {
        display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px;
        border: 1px solid #D5D7DA; border-radius: 8px; background: #FFFFFF;
        color: #414651; font-size: 14px; font-weight: 600; cursor: pointer;
    }
    .ex-browse--mobile .ex-filter { width: 100%; flex: none; }
    .ex-browse--mobile .ex-grid--2 { grid-template-columns: 1fr; gap: 24px; }
    .ex-section--mobile .ex-card__media { height: 210px; }
    .ex-section--mobile .ex-card__title a { font-size: 14px; line-height: 22px; }
    .ex-section--mobile .ex-card__meta { font-size: 12px; line-height: 20px; }
    .ex-section--mobile .ex-card__badge { font-size: 12px; line-height: 20px; padding: 2px 8px; }
    .ex-browse--mobile .ex-pager { flex-wrap: wrap; }

    /* Impact panels stack */
    .ex-section--mobile .ex-impact__row { grid-template-columns: 1fr; gap: 16px; padding: 0 16px; }
}
