/* ------------------------------------------------------------------------
   Home: latest clip highlights.

   Built on the theme's existing language rather than a new one: #202026 ground,
   #df4661 accent, `zuume` condensed display, `area-normal` for text, and square
   corners everywhere (the site's buttons are border-radius 0 -- rounding these
   cards would make them look bolted on).

   The footage is the only loud element. Everything around it stays quiet: thin
   rules, one accent, no shadows, no gradient washes.
   ------------------------------------------------------------------------ */

.plnHighlights {
    --pln-hl-ground: #202026;
    --pln-hl-panel: #18181e;
    --pln-hl-accent: #df4661;
    --pln-hl-text: #f2f2f2;
    --pln-hl-muted: #9a9aa6;
    --pln-hl-line: rgba(255, 255, 255, 0.12);
    --pln-hl-card: 320px;

    background: var(--pln-hl-ground);
    /* The news section that follows carries a decorative sticker at top:-110px,
       designed to straddle the seam with whatever sits above it. The extra bottom
       padding keeps that sticker clear of the captions instead of landing on them. */
    padding: 72px 0 136px;
    color: var(--pln-hl-text);
}

.plnHighlights__inner {
    max-width: 1440px;
    margin: 0 auto;
    padding: 0 16px;
}

@media (min-width: 768px) {
    .plnHighlights__inner { padding: 0 48px; }
}

/* ---- heading ---- */

.plnHighlights__head {
    margin: 0 0 28px;
}

.plnHighlights__eyebrow {
    display: inline-block;
    margin: 0 0 14px;
    padding: 7px 12px;
    background: var(--pln-hl-accent);
    color: #fff;
    font-family: "area-normal", sans-serif;
    font-size: 13px;
    font-weight: 500;
    line-height: 1;
}

.plnHighlights__title {
    margin: 0;
    font-family: "zuume", "vinila-condensed", sans-serif;
    font-weight: 400;
    text-transform: uppercase;
    font-size: clamp(38px, 7vw, 64px);
    line-height: 0.94;
    color: var(--pln-hl-text);
}

.plnHighlights__sub {
    margin: 10px 0 0;
    font-family: "area-normal", sans-serif;
    font-size: 15px;
    color: var(--pln-hl-muted);
}

/* ---- rail ---- */

.plnHighlights__rail {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: var(--pln-hl-card);
    gap: 20px;
    margin: 0;
    padding: 4px 0 20px;
    list-style: none;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scroll-snap-type: x mandatory;
    scrollbar-width: thin;
    scrollbar-color: var(--pln-hl-accent) transparent;
}

.plnHighlights__rail::-webkit-scrollbar { height: 6px; }
.plnHighlights__rail::-webkit-scrollbar-track { background: rgba(255, 255, 255, 0.06); }
.plnHighlights__rail::-webkit-scrollbar-thumb { background: var(--pln-hl-accent); }

.plnHighlights__item { scroll-snap-align: start; }

/* ---- card ---- */

.plnHighlights__card {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: none;
    color: inherit;
    text-align: left;
    font: inherit;
    cursor: pointer;
}

.plnHighlights__card:focus-visible {
    outline: 3px solid var(--pln-hl-accent);
    outline-offset: 3px;
}

.plnHighlights__frame {
    position: relative;
    display: block;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    background: var(--pln-hl-panel);
    border: 1px solid var(--pln-hl-line);
}

.plnHighlights__img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 240ms ease, opacity 240ms ease;
}

.plnHighlights__card:hover .plnHighlights__img,
.plnHighlights__card:focus-visible .plnHighlights__img {
    transform: scale(1.035);
    opacity: 0.82;
}

/* Top-RIGHT on purpose: these are broadcast frames with the scoreboard
   lower-third burned into the bottom of the picture. */
.plnHighlights__time {
    position: absolute;
    top: 8px;
    right: 8px;
    padding: 3px 7px;
    background: rgba(0, 0, 0, 0.78);
    color: #fff;
    font-family: "area-normal", sans-serif;
    font-size: 12px;
    font-variant-numeric: tabular-nums;
    line-height: 1.3;
}

.plnHighlights__play {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 54px;
    height: 54px;
    margin: -27px 0 0 -27px;
    display: grid;
    place-items: center;
    background: rgba(24, 24, 30, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.45);
    color: #fff;
    transition: background-color 200ms ease, border-color 200ms ease;
}

.plnHighlights__play svg { margin-left: 3px; }

.plnHighlights__card:hover .plnHighlights__play,
.plnHighlights__card:focus-visible .plnHighlights__play {
    background: var(--pln-hl-accent);
    border-color: var(--pln-hl-accent);
}

.plnHighlights__show {
    display: block;
    margin: 12px 0 5px;
    font-family: "zuume", "vinila-condensed", sans-serif;
    font-size: 19px;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    color: var(--pln-hl-accent);
}

.plnHighlights__caption {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-family: "area-normal", sans-serif;
    font-size: 15px;
    line-height: 1.45;
    color: var(--pln-hl-text);
}

/* ---- player ---- */

.plnHighlights__player {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: grid;
    place-items: center;
    padding: 20px;
}

.plnHighlights__player[hidden] { display: none; }

.plnHighlights__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(10, 10, 14, 0.92);
}

.plnHighlights__dialog {
    position: relative;
    width: min(380px, 100%);
    max-height: 100%;
    overflow-y: auto;
    background: var(--pln-hl-panel);
    border: 1px solid var(--pln-hl-line);
    padding: 14px;
}

.plnHighlights__video {
    display: block;
    width: 100%;
    aspect-ratio: 9 / 16;
    max-height: 68vh;
    background: #000;
}

.plnHighlights__close {
    position: absolute;
    top: -46px;
    right: 0;
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 0;
    background: rgba(24, 24, 30, 0.9);
    color: #fff;
    cursor: pointer;
}

.plnHighlights__close:hover,
.plnHighlights__close:focus-visible {
    background: var(--pln-hl-accent);
    border-color: var(--pln-hl-accent);
    outline: none;
}

.plnHighlights__playerShow {
    margin: 12px 0 4px;
    font-family: "zuume", "vinila-condensed", sans-serif;
    font-size: 20px;
    text-transform: uppercase;
    color: var(--pln-hl-accent);
}

.plnHighlights__playerCaption {
    margin: 0;
    font-family: "area-normal", sans-serif;
    font-size: 15px;
    line-height: 1.45;
    color: var(--pln-hl-text);
}

/* ---- responsive ---- */

@media (max-width: 767px) {
    .plnHighlights { padding: 48px 0 120px; }
    .plnHighlights__rail {
        --pln-hl-card: 78vw;
        gap: 14px;
        /* let cards run to the screen edge, which reads as "there is more" */
        margin: 0 -16px;
        padding-left: 16px;
        padding-right: 16px;
    }
    .plnHighlights__close { top: -42px; }
}

@media (prefers-reduced-motion: reduce) {
    .plnHighlights__img,
    .plnHighlights__play {
        transition: none;
    }
    .plnHighlights__card:hover .plnHighlights__img,
    .plnHighlights__card:focus-visible .plnHighlights__img {
        transform: none;
    }
}
