/**
 * Watch / video.php — premium panels tied to home preset (--watch-* in home-sections-presets.css).
 * Scoped under .ui-video.
 * Cache: header uses ?v=filemtime(this file) for this stylesheet — edit & save to force browser refresh.
 */

/* Prevent horizontal overflow on mobile (player/embed/tags must stay within shell-main) */
.ui-video {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

.ui-video .video-layout,
.ui-video .main-column,
.ui-video .side-column {
    min-width: 0;
    max-width: 100%;
}

.ui-video .watch-player-shell,
.ui-video .player-wrapper.watch-player-frame,
.ui-video .watch-player-viewport {
    max-width: 100%;
}

.ui-video .video-embed-container iframe,
.ui-video .video-embed-container video,
.ui-video .video-player-native {
    max-width: 100% !important;
}

.modal-link {
    color: var(--shell-accent, var(--brand-gold, #f59e0b));
    text-decoration: none;
    display: block;
    padding: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: 0.2s;
}

.modal-link:last-child {
    border-bottom: none;
}

.modal-link:hover {
    background: rgba(255, 255, 255, 0.05);
    padding-left: 15px;
    color: #fde68a;
}

.modal-link:active {
    transform: scale(0.98);
    background: rgba(255, 255, 255, 0.1);
}

/* ——— Breadcrumb ——— */
.ui-video .watch-breadcrumb {
    background: var(--watch-breadcrumb-bg, rgba(255, 255, 255, 0.03));
    border: 1px solid var(--watch-breadcrumb-border, var(--glass-border, var(--shell-border)));
    padding: 15px 25px;
    border-radius: 16px;
    color: var(--text-muted, var(--shell-muted));
    font-size: 14px;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: nowrap;
    overflow: hidden;
    white-space: nowrap;
    backdrop-filter: blur(var(--watch-breadcrumb-blur, 16px));
    -webkit-backdrop-filter: blur(var(--watch-breadcrumb-blur, 16px));
    box-shadow: 0 10px 36px rgba(0, 0, 0, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.ui-video .watch-breadcrumb a {
    color: var(--accent-color, var(--shell-accent));
    text-decoration: none;
    transition: 0.2s;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 5px;
    flex-shrink: 0;
}

.ui-video .watch-breadcrumb a:hover {
    color: var(--brand-gold, #fbbf24);
    text-decoration: underline;
}

.ui-video .watch-breadcrumb i {
    font-size: 12px;
    color: var(--watch-breadcrumb-chevron, var(--text-muted, var(--shell-muted)));
    opacity: 0.75;
    flex-shrink: 0;
}

.ui-video .watch-breadcrumb span {
    color: var(--watch-breadcrumb-current, #e5e7eb);
    font-weight: 400;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    flex: 1;
    min-width: 0;
}

@media (max-width: 768px) {
    .ui-video .breadcrumb.watch-breadcrumb {
        padding: 11px 14px;
        font-size: 13px;
        gap: 8px;
        border-radius: 14px;
        margin-bottom: 22px;
        display: flex !important;
        align-items: center;
        flex-wrap: nowrap !important;
        overflow: hidden;
        white-space: nowrap;
    }

    .ui-video .watch-breadcrumb a span {
        display: none;
    }

    .ui-video .watch-breadcrumb a i {
        font-size: 14px;
    }

    .ui-video .watch-breadcrumb a,
    .ui-video .watch-breadcrumb span {
        min-width: 0;
    }

    .ui-video .watch-breadcrumb .series-link {
        max-width: 38%;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        display: block;
        flex: 0 1 auto;
    }

    .ui-video .watch-breadcrumb > span {
        flex: 1 1 auto;
        min-width: 0;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .ui-video .video-main-info.watch-main-info {
        padding: 20px 18px 22px;
    }
}

.ui-video .video-layout {
    display: grid;
    gap: 30px;
}

@media (min-width: 993px) {
    .ui-video .video-layout {
        gap: 36px;
    }

    .ui-video .video-layout--with-sidebar {
        grid-template-columns: minmax(0, 1fr) min(360px, 34%);
        gap: 40px;
    }
}

.ui-video .video-layout--single {
    grid-template-columns: 1fr;
}

@media (max-width: 992px) {
    .ui-video .video-layout--with-sidebar,
    .ui-video .video-layout--single,
    .ui-video .video-layout {
        grid-template-columns: 1fr;
    }
}

/* ——— Player shell (card frame + radials) ——— */
.ui-video .video-main-block.watch-player-shell {
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    margin-bottom: 25px;
    border: 1px solid var(--watch-main-shell-border);
    background: var(--watch-main-shell-bg);
    box-shadow: var(--watch-main-shell-shadow);
}

.ui-video .watch-player-shell::before {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--watch-page-radials);
    opacity: 0.88;
    pointer-events: none;
    border-radius: inherit;
    z-index: 0;
}

.ui-video .watch-player-shell::after {
    content: "";
    position: absolute;
    inset: 0;
    box-shadow: var(--watch-main-shell-inset);
    pointer-events: none;
    border-radius: inherit;
    z-index: 1;
}

.ui-video .watch-player-shell > * {
    position: relative;
    z-index: 2;
}

/* Mobile / tablet: hide desktop-only episode rail (duplicate markup for layout) */
@media (max-width: 992px) {
    .ui-video .watch-episodes-panel--desktop-sidebar {
        display: none !important;
    }
}

/* Desktop (≥993px): narrower player column + separate Episode rail on the right */
@media (min-width: 993px) {
    .ui-video .watch-episodes-panel--mobile-stack {
        display: none !important;
    }

    .ui-video .watch-desktop-top {
        display: flex;
        flex-direction: row;
        align-items: flex-start;
        gap: 1.25rem;
        margin-bottom: 25px;
    }

    .ui-video .watch-desktop-top__primary {
        flex: 1 1 0;
        min-width: 0;
        max-width: none;
    }

    /* Player column slightly capped when episode rail is present — sidebar stays readable */
    .ui-video
        .watch-desktop-top:has(.watch-episodes-panel--desktop-sidebar)
        .watch-desktop-top__primary {
        max-width: calc(100% - 1.25rem - clamp(272px, 28vw, 322px));
    }

    .ui-video .watch-desktop-top__primary .video-main-block.watch-player-shell {
        margin-bottom: 0;
    }

    .ui-video .watch-desktop-top__episodes {
        flex: 0 0 clamp(272px, 28vw, 322px);
        max-width: 322px;
        width: clamp(272px, 28vw, 322px);
        align-self: stretch;
        max-height: min(94vh, 960px);
        display: flex;
        flex-direction: column;
        overflow: hidden;
        margin-bottom: 0;
        border-radius: 18px;
        scrollbar-width: thin;
        scrollbar-color: color-mix(in srgb, var(--shell-accent, #38bdf8) 45%, transparent) rgba(15, 23, 42, 0.35);
    }

    /* Full-bleed episode list: remove default glass horizontal padding so thumbs use full column */
    .ui-video
        .watch-desktop-top__episodes.glass-card.watch-panel.watch-panel--episodes-from-series {
        padding: 0.55rem 0 0.65rem;
    }

    .ui-video .watch-desktop-top__episodes.watch-panel--episodes-from-series {
        margin-bottom: 0;
    }

    .ui-video .watch-desktop-top__episodes .watch-rail-header {
        position: relative;
        flex-wrap: wrap;
        gap: 0.4rem 0.75rem;
        padding: 0.15rem 0.65rem 0.75rem;
        margin-bottom: 0.5rem;
        border-bottom: none;
        background: linear-gradient(180deg, rgba(255, 255, 255, 0.045) 0%, transparent 88%);
        border-radius: 12px 12px 0 0;
    }

    .ui-video .watch-desktop-top__episodes .watch-rail-header::after {
        content: "";
        position: absolute;
        left: 0.55rem;
        right: 0.55rem;
        bottom: 0.2rem;
        height: 1px;
        border-radius: 999px;
        background: linear-gradient(
            90deg,
            transparent 0%,
            color-mix(in srgb, var(--shell-accent, #38bdf8) 65%, transparent) 18%,
            color-mix(in srgb, var(--shell-accent, #38bdf8) 40%, transparent) 50%,
            color-mix(in srgb, var(--shell-accent, #38bdf8) 65%, transparent) 82%,
            transparent 100%
        );
        opacity: 0.95;
        pointer-events: none;
    }

    .ui-video .watch-desktop-top__episodes .watch-rail-header__title {
        margin: 0;
        font-size: clamp(1.02rem, 1.28vw, 1.22rem);
        font-weight: 800;
        line-height: 1.22;
        letter-spacing: 0.04em;
        font-family: var(--font-display, var(--shell-display), system-ui, sans-serif);
        text-transform: none;
        background: var(
            --watch-episodes-head-gradient,
            linear-gradient(120deg, #f0f9ff 0%, #bae6fd 28%, #38bdf8 55%, #7dd3fc 78%, #e0f2fe 100%)
        );
        -webkit-background-clip: text;
        background-clip: text;
        -webkit-text-fill-color: transparent;
        color: transparent;
        filter: drop-shadow(0 2px 18px rgba(56, 189, 248, 0.38));
    }

    @supports not ((-webkit-background-clip: text) or (background-clip: text)) {
        .ui-video .watch-desktop-top__episodes .watch-rail-header__title {
            color: #e0f2fe;
            -webkit-text-fill-color: unset;
            filter: none;
        }
    }

    .ui-video .watch-desktop-top__episodes .watch-rail-header__action {
        font-weight: 700;
        letter-spacing: 0.03em;
        border-width: 1px;
        box-shadow:
            0 0 0 1px rgba(56, 189, 248, 0.12),
            0 8px 22px rgba(0, 0, 0, 0.35);
    }

    .ui-video .watch-desktop-top__episodes .watch-video-static-grid--episodes {
        display: flex;
        flex-direction: column;
        flex-wrap: nowrap;
        overflow-x: visible;
        overflow-y: visible;
        gap: 0.55rem;
        margin: 0;
        padding: 0;
        width: 100%;
        max-width: none;
        box-sizing: border-box;
        scroll-snap-type: none;
        scrollbar-color: auto;
    }

    .ui-video .watch-desktop-top__episodes .watch-video-static-grid--episodes > .video-card-premium {
        flex: none;
        width: 100%;
        max-width: none;
        min-width: 0;
        box-sizing: border-box;
        scroll-snap-align: none;
    }

    .ui-video .watch-desktop-top__episodes .watch-episodes-rail {
        display: flex;
        flex-direction: column;
        gap: 0;
        min-height: 0;
        flex: 1 1 auto;
    }

    .ui-video .watch-desktop-top__episodes .watch-episodes-rail__dock {
        position: relative;
        display: flex;
        flex-direction: column;
        flex: 1 1 auto;
        min-height: 0;
    }

    /* Up / down controls: top-right and bottom-right over the thumbnail stack */
    .ui-video .watch-desktop-top__episodes .watch-episodes-rail__nav {
        position: absolute;
        inset: 0;
        z-index: 4;
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        align-items: flex-end;
        padding: 4px 5px 6px;
        pointer-events: none;
    }

    .ui-video .watch-desktop-top__episodes .watch-episodes-rail__btn {
        pointer-events: auto;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 2.1rem;
        height: 2.1rem;
        padding: 0;
        border-radius: 10px;
        border: 1px solid rgba(148, 163, 184, 0.35);
        background: rgba(2, 6, 23, 0.58);
        color: rgba(248, 250, 252, 0.95);
        cursor: pointer;
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, 0.08),
            0 6px 16px rgba(0, 0, 0, 0.45);
        transition:
            background 0.15s ease,
            border-color 0.15s ease,
            color 0.15s ease,
            transform 0.12s ease;
    }

    .ui-video .watch-desktop-top__episodes .watch-episodes-rail__btn:hover:not(:disabled) {
        border-color: color-mix(in srgb, var(--shell-accent, #38bdf8) 55%, rgba(148, 163, 184, 0.35));
        color: #fff;
        background: rgba(15, 23, 42, 0.78);
    }

    .ui-video .watch-desktop-top__episodes .watch-episodes-rail__btn:focus-visible {
        outline: 2px solid color-mix(in srgb, var(--shell-accent, #38bdf8) 70%, transparent);
        outline-offset: 2px;
    }

    .ui-video .watch-desktop-top__episodes .watch-episodes-rail__btn:disabled {
        opacity: 0.35;
        cursor: default;
        pointer-events: none;
    }

    .ui-video .watch-desktop-top__episodes .watch-episodes-rail__viewport {
        overflow-y: auto;
        overflow-x: hidden;
        overscroll-behavior: contain;
        min-height: 0;
        flex: 1 1 auto;
        max-height: none;
        scrollbar-width: thin;
        scrollbar-color: color-mix(in srgb, var(--shell-accent, #38bdf8) 45%, transparent) rgba(15, 23, 42, 0.35);
        border-radius: 0;
        padding: 0;
        margin: 0;
    }

    /* Slightly tighter hero + menu so the watch column reads smaller on desktop */
    .ui-video .watch-desktop-top__primary .video-title {
        font-size: clamp(1.05rem, 2vw, 1.28rem);
        padding-bottom: 10px;
        margin: 0 0 8px;
    }

    .ui-video .watch-desktop-top__primary .video-main-info.watch-main-info {
        padding: 18px 20px 22px;
    }

    .ui-video .watch-desktop-top__primary .watch-player-menu {
        gap: 0.55rem;
    }

    .ui-video .watch-desktop-top__primary .watch-player-menu .video-watch-meta-compact {
        gap: 0.35rem 0.55rem;
    }

    .ui-video .watch-desktop-top__primary .watch-player-menu .video-watch-kv__label {
        font-size: 0.68rem;
    }

    .ui-video .watch-desktop-top__primary .watch-player-menu .video-watch-kv__value,
    .ui-video .watch-desktop-top__primary .watch-player-menu .video-watch-kv__value--plain {
        font-size: 0.88rem;
    }

    .ui-video .watch-desktop-top__primary .watch-player-menu .video-watch-tag {
        font-size: 0.78rem;
        padding: 0.28rem 0.55rem;
    }

    .ui-video .watch-desktop-top__primary .watch-player-menu .action-bar--premium.action-bar--watch-toolbar {
        gap: 0.45rem;
    }

    .ui-video
        .watch-desktop-top__primary
        .watch-player-menu
        .action-bar--watch-toolbar
        .action-btn--premium
        .action-btn__label {
        font-size: 0.82rem;
    }

    .ui-video
        .watch-desktop-top__primary
        .watch-player-menu
        .action-bar--watch-toolbar
        .action-btn--premium
        .action-btn__icon {
        font-size: 0.95rem;
    }
}

.ui-video .player-wrapper.watch-player-frame {
    background: linear-gradient(
        180deg,
        rgba(15, 23, 42, 0.62) 0%,
        rgba(2, 6, 23, 0.88) 24%,
        #000 42%,
        #000 100%
    );
    position: relative;
    padding-top: 56.25%;
    border-bottom: 1px solid var(--watch-player-frame-border);
    box-shadow:
        var(--watch-player-frame-shadow),
        inset 0 0 0 1px rgba(255, 255, 255, 0.04),
        inset 0 -40px 80px rgba(0, 0, 0, 0.45);
}

/* Inner stage: clips iframe/video with soft inner frame (embed + MP4) */
.ui-video .watch-player-viewport {
    position: absolute;
    inset: 0;
    z-index: 1;
    border-radius: 16px 16px 0 0;
    overflow: hidden;
    box-shadow:
        inset 0 0 0 1px rgba(255, 255, 255, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        inset 0 0 120px rgba(0, 0, 0, 0.25);
}

.ui-video .video-embed-container {
    position: absolute;
    inset: 0;
}

.ui-video .video-embed-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.ui-video .video-embed-container > * {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.ui-video .video-player-native {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.ui-video .video-player-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #fff;
    position: absolute;
    top: 0;
    width: 100%;
    background: #000;
}

.ui-video .video-player-empty__inner {
    text-align: center;
    color: rgba(226, 232, 240, 0.88);
    padding: 1.15rem 1.35rem;
    border-radius: 16px;
    background: rgba(15, 23, 42, 0.55);
    border: 1px solid rgba(148, 163, 184, 0.2);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.ui-video .video-player-empty__inner i {
    font-size: 44px;
    margin-bottom: 12px;
    color: rgba(148, 163, 184, 0.45);
}

.ui-video .video-player-empty__inner > div:last-child {
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.02em;
    color: rgba(226, 232, 240, 0.75);
}

/* ——— Watch: poster + play, then external embed / native MP4 ——— */
.ui-video .watch-player-stage {
    position: absolute;
    inset: 0;
    z-index: 2;
    border-radius: inherit;
    overflow: hidden;
    background: #000;
}

.ui-video .watch-player-stage:not([hidden]) {
    z-index: 6;
}

.ui-video .watch-player-poster {
    position: absolute;
    inset: 0;
    z-index: 5;
    cursor: pointer;
    border-radius: inherit;
    overflow: hidden;
    outline: none;
}

.ui-video .watch-player-poster[hidden],
.ui-video .watch-player-poster.watch-player-poster--dismissed {
    display: none !important;
}

.ui-video .watch-player-poster__img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
    transform: scale(1);
    transition: transform 0.85s cubic-bezier(0.4, 0, 0.2, 1);
}

.ui-video .watch-player-poster:hover .watch-player-poster__img {
    transform: scale(1.045);
}

.ui-video .watch-player-poster__fallback {
    position: absolute;
    inset: 0;
    background: linear-gradient(155deg, #1e293b 0%, #0f172a 45%, #020617 100%);
    pointer-events: none;
}

.ui-video .watch-player-poster__shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.05) 0%,
        rgba(0, 0, 0, 0.35) 55%,
        rgba(0, 0, 0, 0.65) 100%
    );
    pointer-events: none;
}

@keyframes watch-play-outline-pulse {
    0%,
    100% {
        opacity: 0.92;
        filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.45)) drop-shadow(0 0 10px rgba(255, 255, 255, 0.18));
    }
    50% {
        opacity: 1;
        filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5)) drop-shadow(0 0 18px rgba(255, 255, 255, 0.32));
    }
}

.ui-video .watch-player-play-btn {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 5.65rem;
    height: 5.65rem;
    padding: 0;
    margin: 0;
    border: 0;
    background: transparent;
    color: #fff;
    cursor: pointer;
    transition:
        transform 0.24s cubic-bezier(0.34, 1.45, 0.64, 1),
        filter 0.24s ease;
}

.ui-video .watch-player-play-btn__svg {
    display: block;
    width: 4.35rem;
    height: 4.35rem;
    overflow: visible;
    animation: watch-play-outline-pulse 2.8s ease-in-out infinite;
    transition: transform 0.24s cubic-bezier(0.34, 1.45, 0.64, 1);
}

.ui-video .watch-player-play-btn__path {
    stroke-opacity: 0.9;
    vector-effect: non-scaling-stroke;
    shape-rendering: geometricPrecision;
    transition: stroke-opacity 0.2s ease;
}

.ui-video .watch-player-play-btn:hover .watch-player-play-btn__path,
.ui-video .watch-player-play-btn:focus-visible .watch-player-play-btn__path {
    stroke-opacity: 1;
}

/* Desktop: ~2× tap target + icon vs mobile/tablet defaults above */
@media (min-width: 1024px) {
    .ui-video .watch-player-play-btn {
        width: 11.3rem;
        height: 11.3rem;
    }

    .ui-video .watch-player-play-btn__svg {
        width: 8.7rem;
        height: 8.7rem;
    }

    .ui-video .watch-player-play-btn:focus-visible {
        outline-offset: 14px;
    }
}

.ui-video .watch-player-play-btn:focus-visible {
    outline: 2px solid rgba(255, 255, 255, 0.85);
    outline-offset: 10px;
    border-radius: 4px;
}

.ui-video .watch-player-play-btn:hover {
    transform: translate(-50%, -50%) scale(1.05);
}

.ui-video .watch-player-play-btn:hover .watch-player-play-btn__svg {
    transform: scale(1.1);
    animation-play-state: paused;
    filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.55)) drop-shadow(0 0 22px rgba(255, 255, 255, 0.35));
}

.ui-video .watch-player-play-btn:active {
    transform: translate(-50%, -50%) scale(1.07);
}

.ui-video .watch-player-play-btn:active .watch-player-play-btn__svg {
    transform: scale(1.16);
}

@media (prefers-reduced-motion: reduce) {
    .ui-video .watch-player-play-btn__svg {
        animation: none !important;
    }

    .ui-video .watch-player-poster:hover .watch-player-poster__img {
        transform: scale(1);
    }
}

.ui-video .video-main-info.watch-main-info {
    padding: 25px 26px 28px;
    background: var(--watch-info-bg);
    backdrop-filter: blur(var(--watch-backdrop-blur, 18px));
    -webkit-backdrop-filter: blur(var(--watch-backdrop-blur, 18px));
    border-top: 1px solid rgba(148, 163, 184, 0.12);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.06),
        0 -12px 36px rgba(0, 0, 0, 0.18);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .ui-video .video-main-info.watch-main-info {
        background: var(--watch-info-bg);
    }
}

@media (max-width: 768px) {
    .ui-video .video-main-info.watch-main-info {
        backdrop-filter: blur(var(--watch-backdrop-blur-mobile, 12px));
        -webkit-backdrop-filter: blur(var(--watch-backdrop-blur-mobile, 12px));
    }
}

.ui-video .video-title {
    font-size: clamp(1.15rem, 4.2vw, 1.45rem);
    font-weight: 700;
    margin: 0 0 10px;
    color: var(--watch-title-fallback);
    line-height: 1.32;
    position: relative;
    padding-bottom: 14px;
    letter-spacing: 0.01em;
}

@supports (-webkit-background-clip: text) or (background-clip: text) {
    .ui-video .video-title {
        background: var(--watch-title-gradient);
        -webkit-background-clip: text;
        background-clip: text;
        -webkit-text-fill-color: transparent;
        color: transparent;
    }
}

.ui-video .video-title::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 88px;
    height: 2px;
    background: var(--watch-title-accent-line);
    border-radius: 2px;
    box-shadow: 0 1px 14px var(--watch-title-accent-glow, rgba(56, 189, 248, 0.22));
}

.ui-video .watch-hero {
    max-width: 100%;
}

/* Player menu dock: meta → pills → actions (reference-style flow) */
.ui-video .watch-player-menu {
    display: flex;
    flex-direction: column;
    gap: 0.85rem;
    margin-top: 0.35rem;
    padding-bottom: 1rem;
    margin-bottom: 0.15rem;
    border-bottom: 1px solid rgba(148, 163, 184, 0.14);
}

.ui-video .watch-player-menu .video-watch-meta-compact {
    margin-bottom: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 0.65rem;
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
}

.ui-video .watch-player-menu .video-watch-meta-compact__sep {
    display: none;
}

.ui-video .watch-player-menu .video-watch-kv {
    flex: 1 1 min(240px, 100%);
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.72rem;
    min-width: 0;
    max-width: 100%;
    padding: 0.62rem 0.85rem 0.62rem 0.65rem;
    border-radius: 14px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease,
        transform 0.2s ease;
}

.ui-video .watch-player-menu .video-watch-kv:hover {
    transform: translateY(-1px);
}

.ui-video .watch-player-menu .video-watch-kv__glyph {
    flex-shrink: 0;
    width: 2.45rem;
    height: 2.45rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    font-size: 0.88rem;
    line-height: 1;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.14),
        0 4px 14px rgba(0, 0, 0, 0.22);
}

.ui-video .watch-player-menu .video-watch-kv--series .video-watch-kv__glyph {
    color: #ede9fe;
    background: linear-gradient(145deg, rgba(139, 92, 246, 0.55) 0%, rgba(91, 33, 182, 0.72) 100%);
    border-color: rgba(196, 181, 253, 0.35);
}

.ui-video .watch-player-menu .video-watch-kv--platform .video-watch-kv__glyph {
    color: #ccfbf1;
    background: linear-gradient(145deg, rgba(20, 184, 166, 0.5) 0%, rgba(15, 118, 110, 0.78) 100%);
    border-color: rgba(45, 212, 191, 0.38);
}

.ui-video .watch-player-menu .video-watch-kv__main {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.12rem;
    min-width: 0;
    flex: 1 1 auto;
}

.ui-video .watch-player-menu .video-watch-kv__label {
    color: rgba(203, 213, 225, 0.88);
}

.ui-video .watch-player-menu .video-watch-kv__label::after {
    content: ':';
    margin-right: 0.35rem;
}

.ui-video .watch-player-menu .video-watch-kv--series {
    background: linear-gradient(
        165deg,
        rgba(76, 29, 149, 0.28) 0%,
        rgba(15, 23, 42, 0.82) 48%,
        rgba(15, 23, 42, 0.92) 100%
    );
    border-color: rgba(167, 139, 250, 0.32);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.06),
        0 10px 28px rgba(0, 0, 0, 0.28);
}

.ui-video .watch-player-menu .video-watch-kv--series:hover {
    border-color: rgba(196, 181, 253, 0.45);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 12px 32px rgba(91, 33, 182, 0.2);
}

.ui-video .watch-player-menu .video-watch-kv--platform {
    background: linear-gradient(
        165deg,
        rgba(13, 148, 136, 0.26) 0%,
        rgba(15, 23, 42, 0.82) 48%,
        rgba(15, 23, 42, 0.94) 100%
    );
    border-color: rgba(45, 212, 191, 0.3);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.06),
        0 10px 28px rgba(0, 0, 0, 0.28);
}

.ui-video .watch-player-menu .video-watch-kv--platform:hover {
    border-color: rgba(94, 234, 212, 0.48);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 12px 32px rgba(13, 148, 136, 0.22);
}

.ui-video .watch-player-menu .video-watch-kv__value {
    color: #a5b4fc;
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.35;
    text-decoration: none;
    text-underline-offset: 0.14em;
    max-width: 100%;
    word-break: break-word;
    transition:
        color 0.18s ease,
        text-decoration-color 0.18s ease;
}

.ui-video .watch-player-menu .video-watch-kv--platform .video-watch-kv__value {
    color: #5eead4;
}

.ui-video .watch-player-menu .video-watch-kv__value:hover {
    color: #c7d2fe;
    text-decoration: underline;
    text-decoration-color: rgba(199, 210, 254, 0.75);
}

.ui-video .watch-player-menu .video-watch-kv--platform .video-watch-kv__value:hover {
    color: #99f6e4;
    text-decoration-color: rgba(153, 246, 228, 0.75);
}

.ui-video .watch-player-menu .video-watch-kv__value:focus-visible {
    outline: 2px solid rgba(56, 189, 248, 0.65);
    outline-offset: 2px;
    border-radius: 4px;
}

.ui-video .watch-player-menu .video-watch-kv--platform .video-watch-kv__value:focus-visible {
    outline-color: rgba(45, 212, 191, 0.7);
}

.ui-video .watch-player-menu .video-watch-kv__value--plain {
    color: rgba(226, 232, 240, 0.96);
    font-size: 0.95rem;
    font-weight: 600;
}

.ui-video .watch-player-menu .video-watch-kv--platform .video-watch-kv__value--plain {
    color: rgba(204, 251, 241, 0.95);
}

.ui-video .watch-player-menu .video-watch-tag-row {
    margin: 0;
}

.ui-video .watch-player-menu .video-watch-actors-block {
    margin: 0 0 0.75rem;
    padding: 0;
    border: none;
    background: transparent;
}

.ui-video .watch-player-menu .video-watch-actors-block__label {
    margin: 0 0 0.28rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.38rem;
    height: 1.38rem;
    border-radius: 999px;
    font-size: 0.62rem;
    color: rgba(191, 219, 254, 0.96);
    border: 1px solid rgba(96, 165, 250, 0.42);
    background: rgba(30, 58, 138, 0.34);
}

.ui-video .watch-player-menu .video-watch-actors-block__label i {
    color: #93c5fd;
}

.ui-video .watch-player-menu .video-watch-tag-row--actors {
    margin: 0;
}

.ui-video .watch-player-menu .video-watch-tag-row--actors.video-watch-tag-row--scroll {
    padding: 0.15rem 0 0.5rem;
}

/* Actors keep same tag-pill structure, but with its own palette */
.ui-video .watch-player-menu .video-watch-tag-row--actors .video-watch-tag--coral {
    color: #fecaca;
    background: rgba(127, 29, 29, 0.35);
    border-color: rgba(248, 113, 113, 0.42);
    border-left: 3px solid rgba(252, 165, 165, 0.9);
}

.ui-video .watch-player-menu .video-watch-tag-row--actors .video-watch-tag--gold {
    color: #fde68a;
    background: rgba(120, 53, 15, 0.35);
    border-color: rgba(251, 191, 36, 0.42);
    border-left: 3px solid rgba(253, 224, 71, 0.92);
}

.ui-video .watch-player-menu .video-watch-tag-row--actors .video-watch-tag--violet {
    color: #f5d0fe;
    background: rgba(112, 26, 117, 0.34);
    border-color: rgba(217, 70, 239, 0.42);
    border-left: 3px solid rgba(233, 213, 255, 0.92);
}

.ui-video .watch-player-menu .video-watch-tag-row--actors .video-watch-tag--sky {
    color: #bfdbfe;
    background: rgba(30, 58, 138, 0.35);
    border-color: rgba(96, 165, 250, 0.4);
    border-left: 3px solid rgba(147, 197, 253, 0.9);
}

.ui-video .watch-player-menu .video-watch-tag {
    background: rgba(30, 41, 59, 0.55);
    border: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.06),
        0 1px 0 rgba(0, 0, 0, 0.2);
}

/* Rotating accent — each pill (category / tag / cast) gets its own hue */
.ui-video .watch-player-menu .video-watch-tag--coral {
    color: #93c5fd;
    background: rgba(30, 58, 138, 0.38);
    border-color: rgba(96, 165, 250, 0.42);
    border-left: 3px solid rgba(147, 197, 253, 0.9);
}

.ui-video .watch-player-menu .video-watch-tag--gold {
    color: #7dd3fc;
    background: rgba(12, 74, 110, 0.38);
    border-color: rgba(56, 189, 248, 0.42);
    border-left: 3px solid rgba(125, 211, 252, 0.9);
}

.ui-video .watch-player-menu .video-watch-tag--violet {
    color: #c4b5fd;
    background: rgba(76, 29, 149, 0.32);
    border-color: rgba(167, 139, 250, 0.45);
    border-left: 3px solid rgba(196, 181, 253, 0.92);
}

.ui-video .watch-player-menu .video-watch-tag--sky {
    color: #6ee7b7;
    background: rgba(6, 78, 59, 0.35);
    border-color: rgba(52, 211, 153, 0.4);
    border-left: 3px solid rgba(110, 231, 183, 0.9);
}

.ui-video .watch-player-menu .video-watch-tag i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1rem;
    flex-shrink: 0;
    font-size: 0.68rem;
    opacity: 0.92;
}

.ui-video .watch-player-menu .video-watch-tag__text {
    min-width: 0;
}

.ui-video .watch-player-menu .video-watch-tag:hover {
    filter: brightness(1.12);
}

.ui-video .watch-player-menu .video-watch-tag--coral:hover {
    border-color: rgba(147, 197, 253, 0.55);
}

.ui-video .watch-player-menu .video-watch-tag--gold:hover {
    border-color: rgba(125, 211, 252, 0.55);
}

.ui-video .watch-player-menu .video-watch-tag--violet:hover {
    border-color: rgba(196, 181, 253, 0.55);
}

.ui-video .watch-player-menu .video-watch-tag--sky:hover {
    border-color: rgba(110, 231, 183, 0.55);
}

.ui-video .watch-player-menu .action-bar--premium.action-bar--watch-toolbar {
    margin-top: 0;
}

/* Series + Platform — one compact line (no wide cards) */
.ui-video .video-watch-meta-compact {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem 0.65rem;
    margin: 0 0 0.65rem;
    font-size: 0.875rem;
    line-height: 1.45;
}

.ui-video .video-watch-meta-compact__sep {
    color: rgba(148, 163, 184, 0.55);
    font-weight: 700;
    user-select: none;
}

.ui-video .video-watch-kv {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.35rem 0.5rem;
    max-width: 100%;
}

.ui-video .video-watch-kv__label {
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--text-muted, var(--shell-muted));
}

.ui-video .video-watch-kv__value {
    color: #f1f5f9;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s ease;
}

.ui-video .video-watch-kv__value:hover {
    color: var(--shell-accent, var(--accent-color));
}

.ui-video .video-watch-kv__value--plain {
    color: rgba(241, 245, 249, 0.95);
    font-weight: 600;
}

/* Categories + tags + cast — single horizontal row, scroll on overflow */
.ui-video .video-watch-tag-row {
    margin: 0 0 1rem;
    max-width: 100%;
}

.ui-video .video-watch-tag-row--scroll {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.45rem;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0.15rem 0 0.5rem;
    margin: 0;
    padding-left: 0;
    padding-right: 0;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 2px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: color-mix(in srgb, var(--shell-accent, #38bdf8) 45%, transparent) rgba(15, 23, 42, 0.35);
}

.ui-video .video-watch-tag-row--scroll::-webkit-scrollbar {
    height: 5px;
}

.ui-video .video-watch-tag-row--scroll::-webkit-scrollbar-thumb {
    background: color-mix(in srgb, var(--shell-accent, #38bdf8) 50%, rgba(100, 116, 139, 0.4));
    border-radius: 999px;
}

.ui-video .video-watch-tag-row--scroll::-webkit-scrollbar-track {
    background: rgba(15, 23, 42, 0.35);
    border-radius: 999px;
}

.ui-video .video-watch-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.38rem 0.72rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 600;
    text-decoration: none;
    background: rgba(15, 23, 42, 0.42);
    border: 1px solid rgba(148, 163, 184, 0.22);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition:
        transform 0.15s ease,
        filter 0.15s ease,
        border-color 0.15s ease,
        background 0.15s ease;
    flex: 0 0 auto;
    max-width: min(280px, 100%);
    white-space: nowrap;
    scroll-snap-align: start;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
}

.ui-video .video-watch-tag--actor {
    font-weight: 600;
}

.ui-video .video-watch-tag i {
    font-size: 0.7rem;
    opacity: 0.9;
}

.ui-video .video-watch-tag:hover {
    transform: translateY(-1px);
    filter: brightness(1.06);
    background: rgba(15, 23, 42, 0.55);
    border-color: rgba(125, 211, 252, 0.28);
}

.ui-video .video-watch-tag:active {
    transform: scale(0.98);
}

.ui-video .video-watch-tag:focus-visible {
    outline: 2px solid rgba(56, 189, 248, 0.55);
    outline-offset: 2px;
}

.ui-video .video-watch-tag--coral {
    color: #60a5fa;
}

.ui-video .video-watch-tag--gold {
    color: #38bdf8;
}

.ui-video .video-watch-tag--violet {
    color: #a78bfa;
}

.ui-video .video-watch-tag--sky {
    color: #34d399;
}

/* Watch action toolbar — premium glass dock (single row, shrink-safe) */
.ui-video .action-bar--premium.action-bar--watch-toolbar {
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: stretch;
    justify-content: stretch;
    gap: clamp(0.35rem, 1.8vw, 0.65rem);
    margin-top: 0.75rem;
    width: 100%;
    padding: clamp(0.48rem, 1.8vw, 0.7rem);
    border-radius: 20px;
    background: linear-gradient(
        168deg,
        rgba(30, 41, 59, 0.55) 0%,
        rgba(2, 6, 18, 0.82) 42%,
        rgba(2, 6, 18, 0.92) 100%
    );
    border: 1px solid rgba(148, 163, 184, 0.22);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        inset 0 -1px 0 rgba(0, 0, 0, 0.28),
        0 18px 50px rgba(0, 0, 0, 0.42),
        0 0 0 1px rgba(0, 0, 0, 0.22);
    backdrop-filter: blur(18px) saturate(1.15);
    -webkit-backdrop-filter: blur(18px) saturate(1.15);
}

.ui-video .action-btn--premium {
    cursor: pointer;
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: clamp(0.35rem, 1.5vw, 0.55rem);
    padding: 0.55rem clamp(0.55rem, 2.5vw, 1rem) 0.55rem clamp(0.45rem, 2vw, 0.75rem);
    border-radius: 14px;
    font-size: clamp(0.76rem, 2.8vw, 0.9rem);
    font-weight: 600;
    letter-spacing: 0.03em;
    text-decoration: none;
    border: 1px solid transparent;
    transition:
        transform 0.22s cubic-bezier(0.4, 0, 0.2, 1),
        box-shadow 0.22s ease,
        background 0.22s ease,
        border-color 0.22s ease,
        filter 0.22s ease;
    white-space: nowrap;
    flex: 1 1 0;
    min-width: 0;
    font-family: inherit;
    line-height: 1.25;
    -webkit-tap-highlight-color: transparent;
    overflow: hidden;
}

@media (max-width: 992px) {
    .ui-video .action-btn--premium {
        min-height: 48px;
    }
}

.ui-video .action-btn--premium:focus-visible {
    outline: 2px solid rgba(56, 189, 248, 0.75);
    outline-offset: 3px;
}

.ui-video .action-btn__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: clamp(2rem, 7vw, 2.35rem);
    height: clamp(2rem, 7vw, 2.35rem);
    border-radius: 12px;
    font-size: clamp(0.8rem, 2.6vw, 0.92rem);
    flex-shrink: 0;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.ui-video .action-btn--download {
    flex: 1.22 1 0;
    color: #f8fafc;
    border-color: rgba(255, 255, 255, 0.28);
    background: linear-gradient(
        142deg,
        #22d3ee 0%,
        #0ea5e9 22%,
        #2563eb 52%,
        #6366f1 78%,
        #7c3aed 100%
    );
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.12) inset,
        0 1px 0 rgba(255, 255, 255, 0.18) inset,
        0 8px 28px rgba(14, 165, 233, 0.45),
        0 4px 14px rgba(99, 102, 241, 0.35);
    text-shadow: 0 1px 2px rgba(15, 23, 42, 0.5);
}

.ui-video .action-btn--download .action-btn__icon {
    background: linear-gradient(160deg, rgba(15, 23, 42, 0.35), rgba(15, 23, 42, 0.15));
    color: #f0f9ff;
    border-radius: 11px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.ui-video .action-btn--download:hover {
    transform: translateY(-2px);
    filter: brightness(1.06) saturate(1.1);
    border-color: rgba(255, 255, 255, 0.38);
    box-shadow:
        0 0 0 1px rgba(255, 255, 255, 0.16) inset,
        0 1px 0 rgba(255, 255, 255, 0.22) inset,
        0 12px 40px rgba(14, 165, 233, 0.55),
        0 6px 20px rgba(99, 102, 241, 0.42);
}

.ui-video .action-btn--share {
    flex: 1 1 0;
    color: rgba(248, 250, 252, 0.98);
    border-color: rgba(56, 189, 248, 0.32);
    background: linear-gradient(
        168deg,
        rgba(56, 189, 248, 0.14) 0%,
        rgba(51, 65, 85, 0.5) 38%,
        rgba(15, 23, 42, 0.94) 100%
    );
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.1),
        inset 0 0 0 1px rgba(56, 189, 248, 0.08),
        0 4px 18px rgba(0, 0, 0, 0.28);
}

.ui-video .action-btn--share .action-btn__icon {
    background: linear-gradient(145deg, rgba(56, 189, 248, 0.38), rgba(37, 99, 235, 0.28));
    color: #e0f2fe;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.ui-video .action-btn--share:hover {
    transform: translateY(-2px);
    border-color: rgba(125, 211, 252, 0.55);
    background: linear-gradient(
        168deg,
        rgba(56, 189, 248, 0.22) 0%,
        rgba(71, 85, 105, 0.58) 40%,
        rgba(30, 41, 59, 0.97) 100%
    );
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.12),
        0 8px 28px rgba(14, 165, 233, 0.28);
}

.ui-video .action-btn--report {
    flex: 1 1 0;
    color: rgba(254, 242, 242, 0.98);
    border-color: rgba(251, 113, 133, 0.35);
    background: linear-gradient(
        168deg,
        rgba(251, 113, 133, 0.12) 0%,
        rgba(51, 24, 32, 0.52) 38%,
        rgba(15, 23, 42, 0.94) 100%
    );
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.06),
        inset 0 0 0 1px rgba(248, 113, 113, 0.06),
        0 4px 18px rgba(0, 0, 0, 0.3);
}

.ui-video .action-btn--report .action-btn__icon {
    background: linear-gradient(145deg, rgba(248, 113, 113, 0.32), rgba(185, 28, 28, 0.24));
    color: #fecaca;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.ui-video .action-btn--report:hover {
    transform: translateY(-2px);
    border-color: rgba(252, 165, 165, 0.55);
    background: linear-gradient(
        168deg,
        rgba(251, 113, 113, 0.2) 0%,
        rgba(80, 30, 40, 0.62) 42%,
        rgba(30, 27, 35, 0.98) 100%
    );
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        0 8px 28px rgba(185, 28, 28, 0.24);
}

.ui-video .action-btn--premium:active {
    transform: scale(0.98);
    transition-duration: 0.1s;
}

.ui-video .action-btn--download:active,
.ui-video .action-btn--share:active,
.ui-video .action-btn--report:active {
    transform: scale(0.98);
}

@media (min-width: 993px) {
    .ui-video .action-bar--premium.action-bar--watch-toolbar {
        flex-wrap: nowrap;
        padding: 0.65rem 0.7rem;
        gap: 0.7rem;
        border-radius: 20px;
    }

    .ui-video .action-btn--premium {
        padding: 0.72rem 1.35rem 0.72rem 0.75rem;
        font-size: 0.9rem;
        border-radius: 15px;
    }

    .ui-video .action-btn__icon {
        width: 2.5rem;
        height: 2.5rem;
        font-size: 0.95rem;
        border-radius: 12px;
    }

    .ui-video .action-btn--share,
    .ui-video .action-btn--report {
        flex: 1 1 0;
        min-width: 8rem;
    }

    .ui-video .action-btn--download {
        flex: 1.2 1 0;
        min-width: 10rem;
    }

    .ui-video .action-bar--watch-toolbar .action-btn--premium {
        border-radius: 12px;
    }
}

/* Watch toolbar — solid buttons, rounded-rect (not pill), bold white + soft color shadow */
.ui-video .action-bar--watch-toolbar .action-btn--premium {
    border-radius: 12px;
    font-weight: 700;
    color: #ffffff;
    border-color: transparent;
    text-shadow: none;
}

.ui-video .action-bar--watch-toolbar .action-btn__label {
    color: #ffffff;
}

.ui-video .action-bar--watch-toolbar .action-btn__label--watch-mobile {
    display: none;
}

.ui-video .action-bar--watch-toolbar .action-btn__icon {
    width: clamp(1.85rem, 6vw, 2.25rem);
    height: clamp(1.85rem, 6vw, 2.25rem);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.22);
    color: #ffffff;
    box-shadow: none;
    font-size: clamp(0.78rem, 2.6vw, 0.9rem);
}

.ui-video .action-bar--watch-toolbar .action-btn--download {
    background: #818cf8;
    border-color: transparent;
    box-shadow: 0 10px 28px rgba(99, 102, 241, 0.48);
}

.ui-video .action-bar--watch-toolbar .action-btn--download .action-btn__icon {
    background: rgba(255, 255, 255, 0.22);
    color: #ffffff;
}

.ui-video .action-bar--watch-toolbar .action-btn--download:hover {
    filter: brightness(1.08);
    border-color: transparent;
    transform: translateY(-2px);
    box-shadow: 0 14px 36px rgba(99, 102, 241, 0.55);
}

.ui-video .action-bar--watch-toolbar .action-btn--share {
    background: #14b8a6;
    border-color: transparent;
    box-shadow: 0 10px 28px rgba(20, 184, 166, 0.42);
}

.ui-video .action-bar--watch-toolbar .action-btn--share .action-btn__icon {
    background: rgba(255, 255, 255, 0.22);
    color: #ffffff;
}

.ui-video .action-bar--watch-toolbar .action-btn--share:hover {
    filter: brightness(1.08);
    border-color: transparent;
    background: #14b8a6;
    transform: translateY(-2px);
    box-shadow: 0 14px 36px rgba(20, 184, 166, 0.5);
}

.ui-video .action-bar--watch-toolbar .action-btn--report {
    background: #fb7185;
    border-color: transparent;
    box-shadow: 0 10px 28px rgba(251, 113, 133, 0.45);
}

.ui-video .action-bar--watch-toolbar .action-btn--report .action-btn__icon {
    background: rgba(255, 255, 255, 0.22);
    color: #ffffff;
}

.ui-video .action-bar--watch-toolbar .action-btn--report:hover {
    filter: brightness(1.08);
    border-color: transparent;
    background: #fb7185;
    transform: translateY(-2px);
    box-shadow: 0 14px 36px rgba(251, 113, 133, 0.52);
}

/* Telegram CTA: hidden on desktop; shown only in mobile block below */
.ui-video .watch-tg-banner.watch-tg-banner--mobile-only {
    display: none;
}

/* —— Mobile “Direct Download” — static pill, blue→violet (live animations in video-watch-dl-mobile.css if needed) —— */
@media (max-width: 640px) {
    /* Watch toolbar: mobile = full-width Direct Download only (PC unchanged ≥641px) */
    .ui-video .action-bar--watch-toolbar .action-btn--share,
    .ui-video .action-bar--watch-toolbar .action-btn--report {
        display: none !important;
    }

    .ui-video .action-bar--watch-toolbar:not(:has(.action-btn--download)) {
        display: none !important;
    }

    .ui-video .action-bar--watch-toolbar.action-bar--premium {
        display: block;
        width: 100%;
        padding: 0;
        margin-top: 0.55rem;
        border-radius: 0;
        background: transparent;
        border: none;
        box-shadow: none;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .ui-video .action-bar--watch-toolbar .action-btn__label--watch-desktop {
        display: none !important;
    }

    .ui-video .action-bar--watch-toolbar .action-btn__label--watch-mobile {
        display: inline !important;
    }

    /* Direct Download — static pill, blue→violet (details + override: video-watch-dl-mobile.css) */
    .ui-video .action-bar--watch-toolbar .action-btn--download.action-btn--premium {
        display: inline-flex;
        width: 100%;
        box-sizing: border-box;
        flex-direction: row;
        justify-content: center;
        align-items: center;
        gap: 0.55rem;
        min-height: 2.85rem;
        padding: 0.7rem 1.15rem;
        border-radius: 9999px;
        font-size: 0.95rem;
        font-weight: 700;
        letter-spacing: 0.03em;
        color: #ffffff;
        text-decoration: none;
        border: 1px solid rgba(255, 255, 255, 0.22);
        background-image: linear-gradient(90deg, #4a90e2 0%, #5678e0 45%, #6e56cf 100%);
        background-size: 100% 100%;
        box-shadow:
            0 1px 0 rgba(255, 255, 255, 0.28) inset,
            0 8px 22px rgba(0, 0, 0, 0.38),
            0 4px 14px rgba(78, 89, 207, 0.42);
        white-space: nowrap;
        overflow: hidden;
    }

    .ui-video .action-bar--watch-toolbar .action-btn--download.action-btn--premium:hover {
        filter: brightness(1.05);
        transform: translateY(-1px);
    }

    .ui-video .action-bar--watch-toolbar .action-btn--download .action-btn__icon,
    .ui-video .action-bar--watch-toolbar .action-btn--download .action-btn__label {
        position: relative;
        z-index: 1;
    }

    .ui-video .action-bar--watch-toolbar .action-btn--download .action-btn__icon {
        width: 1.75rem;
        height: 1.75rem;
        font-size: 0.85rem;
        border-radius: 50%;
        background: rgba(255, 255, 255, 0.24);
        color: #ffffff;
        flex-shrink: 0;
        box-shadow: 0 1px 2px rgba(0, 0, 0, 0.15);
    }

    .ui-video .action-bar--watch-toolbar .action-btn--download .action-btn__label {
        font-size: clamp(0.88rem, 3.8vw, 1rem);
        font-weight: 700;
        letter-spacing: 0.04em;
        line-height: 1.15;
        text-align: center;
        min-width: 0;
        flex: 0 1 auto;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        max-width: 100%;
    }

    .ui-video .watch-player-menu .video-watch-actors-block__label {
        width: 1.3rem;
        height: 1.3rem;
        font-size: 0.56rem;
        margin-bottom: 0.2rem;
    }

    .ui-video .watch-player-menu .video-watch-tag-row--actors.video-watch-tag-row--scroll {
        padding: 0.1rem 0 0.4rem;
    }

    /* Mobile-only Telegram CTA under watch toolbar (original) */
    .ui-video .watch-tg-banner.watch-tg-banner--mobile-only {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 0.5rem;
        margin-top: 0.65rem;
        padding: 0.55rem 0.65rem 0.55rem 0.55rem;
        border-radius: 14px;
        text-decoration: none;
        color: #e0f2fe;
        background: linear-gradient(135deg, #0369a1 0%, #0c4a6e 45%, #075985 100%);
        border: 1px solid rgba(56, 189, 248, 0.45);
        box-shadow:
            0 0 0 1px rgba(14, 165, 233, 0.12),
            0 12px 28px rgba(2, 132, 199, 0.35),
            inset 0 1px 0 rgba(255, 255, 255, 0.12);
        overflow: hidden;
        animation: watch-tg-banner-pulse 2.8s ease-in-out infinite;
    }

    .ui-video .watch-tg-banner__shine {
        position: absolute;
        inset: 0;
        background: linear-gradient(
            105deg,
            transparent 0%,
            transparent 40%,
            rgba(255, 255, 255, 0.14) 50%,
            transparent 60%,
            transparent 100%
        );
        transform: translateX(-100%);
        animation: watch-tg-banner-shine 4s ease-in-out infinite;
        pointer-events: none;
        z-index: 0;
    }

    .ui-video .watch-tg-banner__left {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        min-width: 0;
        flex: 1;
        position: relative;
        z-index: 1;
    }

    .ui-video .watch-tg-banner__icon {
        flex-shrink: 0;
        width: 2.25rem;
        height: 2.25rem;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.12);
        font-size: 1.1rem;
        color: #fff;
    }

    .ui-video .watch-tg-banner__copy {
        display: flex;
        flex-direction: column;
        gap: 0.12rem;
        min-width: 0;
    }

    .ui-video .watch-tg-banner__live {
        display: inline-flex;
        align-items: center;
        gap: 0.35rem;
        font-size: 0.62rem;
        font-weight: 800;
        letter-spacing: 0.12em;
        text-transform: uppercase;
        color: rgba(224, 242, 254, 0.88);
    }

    .ui-video .watch-tg-banner__dot {
        width: 0.38rem;
        height: 0.38rem;
        border-radius: 50%;
        background: #4ade80;
        box-shadow: 0 0 0 2px rgba(74, 222, 128, 0.35);
        animation: watch-tg-dot-blink 1.4s ease-in-out infinite;
    }

    .ui-video .watch-tg-banner__line {
        font-size: clamp(0.72rem, 3.2vw, 0.82rem);
        font-weight: 700;
        line-height: 1.25;
        color: #fff;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .ui-video .watch-tg-banner__cta {
        flex-shrink: 0;
        display: inline-flex;
        align-items: center;
        gap: 0.2rem;
        padding: 0.35rem 0.5rem;
        border-radius: 10px;
        font-size: 0.68rem;
        font-weight: 800;
        letter-spacing: 0.02em;
        background: rgba(255, 255, 255, 0.18);
        color: #fff;
        position: relative;
        z-index: 1;
    }

    .ui-video .watch-tg-banner__cta i {
        font-size: 0.55rem;
        opacity: 0.9;
    }

    .ui-video .watch-tg-banner.watch-tg-banner--mobile-only:active {
        transform: scale(0.98);
    }
}

@keyframes watch-tg-banner-pulse {
    0%,
    100% {
        box-shadow:
            0 0 0 1px rgba(14, 165, 233, 0.12),
            0 12px 28px rgba(2, 132, 199, 0.35),
            inset 0 1px 0 rgba(255, 255, 255, 0.12);
    }
    50% {
        box-shadow:
            0 0 0 1px rgba(56, 189, 248, 0.35),
            0 14px 34px rgba(2, 132, 199, 0.5),
            inset 0 1px 0 rgba(255, 255, 255, 0.16);
    }
}

@keyframes watch-tg-banner-shine {
    0%,
    65% {
        transform: translateX(-100%);
    }
    85% {
        transform: translateX(100%);
    }
    100% {
        transform: translateX(100%);
    }
}

@keyframes watch-tg-dot-blink {
    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.65;
        transform: scale(0.92);
    }
}

@media (max-width: 600px) {
    .ui-video .video-title {
        font-size: clamp(1.05rem, 4.5vw, 1.2rem);
        letter-spacing: 0.005em;
        line-height: 1.3;
    }
}

/* ——— Panels (Storyline, Related, Details) ——— */
.ui-video .glass-card.watch-panel {
    position: relative;
    border-radius: 20px;
    padding: 26px 26px 28px;
    margin-bottom: 25px;
    border: 1px solid var(--watch-panel-border);
    background: var(--watch-panel-bg);
    box-shadow: var(--watch-panel-shadow);
    backdrop-filter: blur(var(--watch-backdrop-blur, 20px));
    -webkit-backdrop-filter: blur(var(--watch-backdrop-blur, 20px));
    overflow: hidden;
}

@media (max-width: 768px) {
    .ui-video .watch-panel--story,
    .ui-video .watch-panel--rail {
        backdrop-filter: blur(var(--watch-backdrop-blur-mobile, 12px));
        -webkit-backdrop-filter: blur(var(--watch-backdrop-blur-mobile, 12px));
    }
}

.ui-video .watch-panel::before {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--watch-panel-radials);
    opacity: 0.75;
    pointer-events: none;
    border-radius: inherit;
    z-index: 0;
}

.ui-video .watch-panel > * {
    position: relative;
    z-index: 1;
}

.ui-video .glass-card.watch-panel .section-header {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-bottom: 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--watch-section-header-border);
    color: var(--watch-section-header-color);
    font-family: var(--font-display, var(--shell-display), sans-serif);
}

.ui-video .watch-rail-header {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0.5rem 1rem;
    margin-bottom: 1rem;
    padding-bottom: 0.85rem;
    border-bottom: 1px solid var(--watch-rail-header-border, var(--watch-section-header-border));
}

.ui-video .watch-rail-header--editorial {
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 0.15rem;
    margin-bottom: 1.1rem;
}

.ui-video .watch-rail-header__eyebrow {
    margin: 0;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--watch-rail-eyebrow-color, rgba(148, 163, 184, 0.75));
}

.ui-video .watch-rail-header__title {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: var(--watch-rail-title-color, var(--watch-section-header-color));
    font-family: var(--font-display, var(--shell-display), sans-serif);
    line-height: 1.25;
}

.ui-video .watch-rail-header__action {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--watch-rail-action-color, #7dd3fc);
    text-decoration: none;
    padding: 0.35rem 0.65rem;
    border-radius: 999px;
    border: 1px solid var(--watch-rail-action-border, rgba(56, 189, 248, 0.28));
    background: var(--watch-rail-action-bg, rgba(15, 23, 42, 0.35));
    transition:
        background 0.2s ease,
        border-color 0.2s ease,
        color 0.2s ease;
    white-space: nowrap;
}

.ui-video .watch-rail-header__action:hover {
    color: #f0f9ff;
    border-color: rgba(125, 211, 252, 0.45);
    background: rgba(30, 58, 138, 0.35);
}

.ui-video .watch-rail-header__action:focus-visible {
    outline: 2px solid rgba(56, 189, 248, 0.65);
    outline-offset: 2px;
}

.ui-video .watch-story {
    margin: 0;
}

.ui-video .watch-story__body {
    max-width: 65ch;
    color: var(--watch-story-color);
    line-height: 1.78;
    font-size: 0.95rem;
    margin: 0;
}

.ui-video .watch-story__body strong {
    font-weight: 650;
    color: var(--watch-story-strong, rgba(248, 250, 252, 0.95));
}

@media (min-width: 993px) {
    .ui-video .watch-story__body {
        font-size: 1rem;
    }
}

.ui-video .story-body {
    color: var(--watch-story-color);
    line-height: 1.75;
    margin-bottom: 0;
}

.ui-video .video-inline-link {
    color: var(--shell-accent, var(--accent-color));
    text-decoration: none;
    font-weight: 500;
}

.ui-video .video-inline-link:hover {
    text-decoration: underline;
    color: #7dd3fc;
}

/* Related — mobile rail / desktop grid */
.ui-video .video-related-scroll {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.85rem;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0.15rem 0 0.35rem;
    margin: 0 -4px;
    padding-left: 4px;
    padding-right: 4px;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.ui-video .video-related-scroll::-webkit-scrollbar {
    height: 5px;
}

.ui-video .video-related-scroll::-webkit-scrollbar-thumb {
    background: color-mix(in srgb, var(--shell-accent, #38bdf8) 45%, rgba(100, 116, 139, 0.35));
    border-radius: 999px;
}

@media (min-width: 769px) {
    .ui-video .video-related-scroll {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 1rem;
        overflow-x: visible;
        margin: 0;
        padding: 0;
        scroll-snap-type: none;
    }
}

/* Episode from this series + You may also like */
.ui-video .watch-video-static-grid {
    display: grid;
    gap: 0.85rem 1rem;
    grid-template-columns: 1fr;
}

.ui-video .watch-video-static-grid .video-card-premium {
    min-width: 0;
    width: 100%;
    max-width: none;
    flex: none;
}

/* "Episode from this series" — mobile: same horizontal slide rail as old You may also like */
.ui-video .watch-video-static-grid--episodes {
    display: flex;
    flex-wrap: nowrap;
    gap: 0.85rem;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 0.15rem 0 0.35rem;
    margin: 0 -4px;
    padding-left: 4px;
    padding-right: 4px;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: color-mix(in srgb, var(--shell-accent, #38bdf8) 45%, transparent) rgba(15, 23, 42, 0.35);
}

.ui-video .watch-video-static-grid--episodes::-webkit-scrollbar {
    height: 5px;
}

.ui-video .watch-video-static-grid--episodes::-webkit-scrollbar-thumb {
    background: color-mix(in srgb, var(--shell-accent, #38bdf8) 50%, rgba(100, 116, 139, 0.4));
    border-radius: 999px;
}

.ui-video .watch-video-static-grid--episodes > .video-card-premium {
    flex: 0 0 clamp(158px, 68vw, 228px);
    max-width: 240px;
    width: auto;
    scroll-snap-align: start;
}

@media (min-width: 769px) {
    .ui-video .watch-video-static-grid--episodes {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        gap: 0.85rem 1rem;
        overflow-x: visible;
        overflow-y: visible;
        margin: 0;
        padding: 0;
        scroll-snap-type: none;
        scrollbar-color: auto;
    }

    .ui-video .watch-video-static-grid--episodes > .video-card-premium {
        flex: none;
        max-width: none;
        width: 100%;
        scroll-snap-align: none;
    }

    .ui-video .watch-video-static-grid--likes {
        grid-template-columns: repeat(4, 1fr);
    }
}

.ui-video .watch-panel--episodes-from-series,
.ui-video .watch-panel--you-may-also-like {
    margin-bottom: 25px;
}

.ui-video .watch-you-may-also-like__footer {
    display: flex;
    justify-content: center;
    margin-top: 1rem;
    padding-top: 0.15rem;
}

.ui-video .watch-you-may-also-like__more {
    padding: 0.42rem 1.05rem;
    font-size: 0.8rem;
}

.ui-video .video-related-scroll .video-card-premium,
.ui-video .video-series-strip__scroll .video-card-premium--watch-rail,
.ui-video .watch-video-static-grid--episodes > .video-card-premium {
    min-width: 0;
    border-color: rgba(148, 163, 184, 0.14);
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.32), 0 0 0 1px rgba(148, 163, 184, 0.08);
}

.ui-video .video-related-scroll .video-card-premium:hover,
.ui-video .video-series-strip__scroll .video-card-premium--watch-rail:hover,
.ui-video .watch-video-static-grid--episodes > .video-card-premium:hover {
    border-color: rgba(56, 189, 248, 0.26);
    box-shadow:
        0 14px 40px rgba(0, 0, 0, 0.42),
        0 0 0 1px rgba(56, 189, 248, 0.12);
}

.ui-video .video-card-premium--watch-rail {
    flex: 0 0 clamp(158px, 68vw, 228px);
    max-width: 240px;
    scroll-snap-align: start;
}

@media (min-width: 769px) {
    .ui-video .video-card-premium--watch-rail {
        flex: none;
        max-width: none;
        width: auto;
    }
}

.ui-video .video-series-strip {
    margin-bottom: 25px;
}

.ui-video .video-series-strip .watch-rail-header__title {
    color: var(--watch-series-head-color);
}

.ui-video .video-series-strip__scroll {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding-bottom: 6px;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 2px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

.ui-video .video-series-strip__scroll .video-card-premium {
    flex: 0 0 clamp(158px, 68vw, 228px);
    max-width: 240px;
    scroll-snap-align: start;
}
