/* ==========================================================================
   CIMORA - Mobile-First Premium Dark Streaming App Theme
   Color Palette:
   - Primary Background: #060818 / #040512 / #090909
   - Surface / Card: #0c0f2b / #090c24
   - Crimson Red: #e50914 / #dc2626
   - Crimson Red Hover: #ff1e27
   - Accent Cyan: #00f0ff
   - Match Green: #46d369
   - Text White: #ffffff
   - Text Gray / Muted: #9ca3af / #6b7280
   ========================================================================== */

/* --------------------------------------------------------------------------
   Reset & Variables
   -------------------------------------------------------------------------- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --bg-main: #040615;
    --bg-surface: #0a0d28;
    --bg-card: #0d1235;
    --bg-nav: rgba(4, 6, 21, 0.95);
    
    --color-red: #e50914;
    --color-red-hover: #ff1e27;
    --color-red-glow: rgba(229, 9, 20, 0.4);
    
    --color-cyan: #00f0ff;
    --color-match: #46d369;
    
    --text-primary: #ffffff;
    --text-secondary: #9ca3af;
    --text-muted: #6b7280;
    
    --border-subtle: rgba(255, 255, 255, 0.08);
    --border-medium: rgba(255, 255, 255, 0.16);
    
    --font-family: 'Open Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-full: 9999px;
    
    --transition-fast: 0.2s ease;
}

html {
    font-size: 16px;
    background-color: var(--bg-main);
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-main);
    color: var(--text-primary);
    line-height: 1.45;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    padding-bottom: 90px; /* Safe space for fixed bottom navigation */
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
    outline: none;
    transition: all var(--transition-fast);
}

/* --------------------------------------------------------------------------
   App View Container
   -------------------------------------------------------------------------- */
.app-container {
    width: 100%;
    max-width: 720px; /* Optimized mobile-first view */
    margin: 0 auto;
    padding: 0 16px;
}

@media (min-width: 1024px) {
    .app-container {
        max-width: 980px;
        padding: 0 24px;
    }
}

/* --------------------------------------------------------------------------
   Top App Header
   -------------------------------------------------------------------------- */
.app-header {
    position: sticky;
    top: 0;
    z-index: 500;
    width: 100%;
    background: rgba(4, 6, 21, 0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    padding: 12px 16px;
}

.app-header-inner {
    max-width: 980px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 44px;
}

.header-icon-btn {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    border-radius: var(--radius-full);
}

.header-icon-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.header-title-centered {
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #ffffff;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 0 10px;
}

/* --------------------------------------------------------------------------
   Movie Poster Hero
   -------------------------------------------------------------------------- */
.poster-hero-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 0 16px;
}

.poster-frame {
    position: relative;
    width: 180px;
    aspect-ratio: 2 / 3;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 12px 36px rgba(0, 0, 0, 0.9), 0 0 20px rgba(4, 6, 21, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: #090c24;
}

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

/* --------------------------------------------------------------------------
   Metadata Row
   -------------------------------------------------------------------------- */
.movie-meta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 16px 0 18px;
    font-size: 0.95rem;
    font-weight: 600;
    color: #d1d5db;
}

.meta-match {
    color: var(--color-match);
    font-weight: 700;
}

.meta-item {
    color: #e5e7eb;
}

.meta-badge-age {
    display: inline-flex;
    align-items: center;
    padding: 1px 6px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 700;
    color: #f3f4f6;
    line-height: 1.2;
}

.meta-badge-tech {
    display: inline-flex;
    align-items: center;
    padding: 1px 5px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 3px;
    font-size: 0.75rem;
    font-weight: 700;
    color: #cbd5e1;
    letter-spacing: 0.05em;
}

/* --------------------------------------------------------------------------
   Play Button (Full-width Crimson Red)
   -------------------------------------------------------------------------- */
.play-btn-wrapper {
    width: 100%;
    margin-bottom: 20px;
}

.btn-play-full {
    width: 100%;
    height: 52px;
    background-color: var(--color-red);
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 4px 20px var(--color-red-glow);
    transition: transform var(--transition-fast), background-color var(--transition-fast);
}

.btn-play-full:hover {
    background-color: var(--color-red-hover);
    transform: translateY(-1px);
}

.btn-play-full:active {
    transform: translateY(0);
}

.btn-play-full svg {
    width: 22px;
    height: 22px;
    fill: #ffffff;
}

/* --------------------------------------------------------------------------
   Overview & Cast
   -------------------------------------------------------------------------- */
.overview-section {
    margin-bottom: 24px;
}

.overview-text {
    font-size: 0.95rem;
    line-height: 1.5;
    color: #f3f4f6;
    margin-bottom: 12px;
}

.overview-text.is-truncated {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.read-more-btn {
    color: #9ca3af;
    font-size: 0.85rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 4px;
}

.read-more-btn:hover {
    color: #ffffff;
}

.cast-row {
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

.cast-row strong {
    color: #d1d5db;
}

/* --------------------------------------------------------------------------
   Action Row (My List, Rate, Share)
   -------------------------------------------------------------------------- */
.action-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    padding: 16px 0;
    border-top: 1px solid var(--border-subtle);
    border-bottom: 1px solid var(--border-subtle);
    margin-bottom: 28px;
}

.action-item-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #d1d5db;
    padding: 8px 4px;
    border-radius: var(--radius-sm);
    transition: color var(--transition-fast), transform var(--transition-fast);
}

.action-item-btn:hover {
    color: #ffffff;
    transform: translateY(-1px);
}

.action-item-btn svg {
    width: 24px;
    height: 24px;
}

.action-label {
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.action-item-btn.is-active {
    color: var(--color-cyan);
}

/* --------------------------------------------------------------------------
   Trailers & More Section
   -------------------------------------------------------------------------- */
.trailers-more-section {
    margin-top: 8px;
    margin-bottom: 36px;
}

.trailers-tab-header {
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
    margin-bottom: 18px;
}

.trailers-tab-title {
    font-size: 0.95rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #ffffff;
}

.trailers-tab-header::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--color-red);
    box-shadow: 0 0 10px var(--color-red-glow);
    border-radius: 2px;
}

.trailer-preview-card {
    position: relative;
    width: 100%;
    border-radius: var(--radius-md);
    overflow: hidden;
    background: #090c24;
    border: 1px solid var(--border-subtle);
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.7);
}

.trailer-thumb-container {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    overflow: hidden;
}

.trailer-thumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease, filter 0.3s ease;
    filter: brightness(0.8);
}

.trailer-preview-card:hover .trailer-thumb-img {
    transform: scale(1.03);
    filter: brightness(0.7);
}

/* Center circular play button */
.trailer-play-circle {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 58px;
    height: 58px;
    border-radius: var(--radius-full);
    border: 2px solid rgba(255, 255, 255, 0.95);
    background: rgba(4, 6, 21, 0.65);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    box-shadow: 0 0 24px rgba(0, 0, 0, 0.8);
    transition: all var(--transition-fast);
}

.trailer-play-circle svg {
    width: 24px;
    height: 24px;
    margin-left: 3px;
    fill: currentColor;
}

.trailer-preview-card:hover .trailer-play-circle {
    transform: translate(-50%, -50%) scale(1.1);
    background: var(--color-red);
    border-color: var(--color-red);
    box-shadow: 0 0 20px var(--color-red-glow);
}

.trailer-card-info {
    padding: 14px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #070a22;
}

.trailer-card-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #ffffff;
}

.trailer-card-runtime {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 600;
}

/* --------------------------------------------------------------------------
   Fixed Bottom Navigation Bar (App Experience)
   -------------------------------------------------------------------------- */
.bottom-nav-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--bg-nav);
    backdrop-filter: blur(16px);
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 0 8px;
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    color: #8e95a5;
    flex: 1;
    height: 100%;
    transition: color var(--transition-fast);
}

.bottom-nav-item svg {
    width: 22px;
    height: 22px;
}

.bottom-nav-label {
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.bottom-nav-item.active {
    color: #ffffff;
}

.bottom-nav-item:hover {
    color: #ffffff;
}

/* --------------------------------------------------------------------------
   Trailer Modal
   -------------------------------------------------------------------------- */
.modal-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 3000;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(14px);
    align-items: center;
    justify-content: center;
    padding: 16px;
    opacity: 0;
    transition: opacity var(--transition-fast);
}

.modal-backdrop.is-open {
    display: flex;
    opacity: 1;
}

.modal-content {
    position: relative;
    width: 100%;
    max-width: 860px;
    background: #090c28;
    border: 1px solid var(--border-medium);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.95);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 8px 12px;
    background: #05081c;
    border-bottom: 1px solid var(--border-subtle);
}

.modal-title {
    font-size: 0.95rem;
    font-weight: 700;
    color: #ffffff;
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-close-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    border-radius: var(--radius-sm);
}

.modal-close-btn:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
}

.modal-body {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 9;
    background: #000000;
    overflow: hidden;
}

/* Step 1: Full-width Preview Thumbnail with Central Cyan Play Button */
.modal-step1-preview {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    overflow: hidden;
    background: #000000;
}

.step1-preview-img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: brightness(0.85);
    transition: transform 0.4s ease, filter 0.3s ease;
}

.modal-step1-preview:hover .step1-preview-img {
    transform: scale(1.02);
    filter: brightness(0.75);
}

.step1-overlay {
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at center, rgba(3, 5, 35, 0.15) 0%, rgba(3, 5, 35, 0.5) 75%, rgba(3, 5, 35, 0.85) 100%);
    pointer-events: none;
}

/* Large Circular Cyan/Blue Play Button in Exact Center */
.step1-cyan-play-btn {
    position: relative;
    z-index: 6;
    width: 72px;
    height: 72px;
    border-radius: var(--radius-full);
    background: rgba(0, 240, 255, 0.22);
    border: 2.5px solid var(--color-cyan);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    box-shadow: 0 0 25px rgba(0, 240, 255, 0.6), inset 0 0 15px rgba(0, 240, 255, 0.3);
    transition: transform var(--transition-fast), background-color var(--transition-fast), box-shadow var(--transition-fast);
}

.step1-cyan-play-btn svg {
    width: 28px;
    height: 28px;
    margin-left: 4px;
    fill: #ffffff;
    filter: drop-shadow(0 0 6px rgba(0, 240, 255, 0.8));
}

.modal-step1-preview:hover .step1-cyan-play-btn,
.step1-cyan-play-btn:hover {
    transform: scale(1.1);
    background: rgba(0, 240, 255, 0.4);
    box-shadow: 0 0 35px rgba(0, 240, 255, 0.9), inset 0 0 20px rgba(0, 240, 255, 0.6);
}

.step1-cyan-play-btn:active {
    transform: scale(0.96);
}

.custom-video-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
    background: #000000;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.custom-video-wrapper .modal-video-player {
    width: 100%;
    height: auto;
    max-width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: contain;
    background: #000000;
    display: block;
    outline: none;
    cursor: pointer;
}

/* Custom Player Controls Bar */
.custom-player-controls {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 10;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.92) 0%, rgba(0, 0, 0, 0.45) 60%, transparent 100%);
    padding: 10px 14px 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    opacity: 1;
    visibility: visible;
}

.custom-player-controls.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* Timeline / Seek Bar */
.player-timeline-container {
    width: 100%;
    height: 14px;
    display: flex;
    align-items: center;
    cursor: pointer;
    position: relative;
    padding: 4px 0;
}

.player-timeline-track {
    position: relative;
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.25);
    border-radius: 2px;
    transition: height 0.15s ease;
}

.player-timeline-container:hover .player-timeline-track {
    height: 6px;
}

.player-timeline-loaded {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 2px;
}

.player-timeline-progress {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0%;
    background: var(--color-red);
    box-shadow: 0 0 8px var(--color-red-glow);
    border-radius: 2px;
}

.player-timeline-thumb {
    position: absolute;
    top: 50%;
    left: 0%;
    transform: translate(-50%, -50%) scale(0);
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #ffffff;
    box-shadow: 0 0 6px rgba(0, 0, 0, 0.8);
    transition: transform 0.15s ease;
}

.player-timeline-container:hover .player-timeline-thumb {
    transform: translate(-50%, -50%) scale(1);
}

/* Controls Buttons Row */
.player-controls-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.player-controls-left,
.player-controls-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.player-btn {
    background: transparent;
    border: none;
    color: #ffffff;
    padding: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: color 0.2s ease, transform 0.1s ease;
}

.player-btn:hover {
    color: var(--color-cyan);
    transform: scale(1.08);
}

.control-icon {
    width: 20px;
    height: 20px;
}

.player-time-display {
    font-size: 0.82rem;
    font-weight: 600;
    color: #e2e8f0;
    display: flex;
    align-items: center;
    gap: 4px;
    letter-spacing: 0.02em;
    font-variant-numeric: tabular-nums;
}

.player-time-divider {
    color: #64748b;
    margin: 0 2px;
}

#playerDuration {
    color: #94a3b8;
}

.modal-video-player {
    width: 100%;
    height: 100%;
    max-width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: contain;
    background: #000000;
    display: block;
    outline: none;
}

.modal-iframe {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100%;
    border: none;
    display: block;
}

.modal-unavailable {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 24px;
    text-align: center;
    gap: 10px;
    color: #cbd5e1;
}

.modal-subtitle {
    font-size: 0.74rem;
    font-weight: 700;
    color: var(--color-cyan);
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-top: 2px;
}

.modal-footer-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 16px;
    background: #05081c;
    border-top: 1px solid var(--border-subtle);
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-weight: 600;
}

.modal-preview-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #e2e8f0;
    font-weight: 600;
    font-size: 0.78rem;
}

.modal-preview-badge::before {
    content: '';
    display: inline-block;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background-color: var(--color-cyan);
    box-shadow: 0 0 8px var(--color-cyan);
}

.modal-preview-time {
    color: #94a3b8;
    font-size: 0.78rem;
    font-weight: 600;
}

/* Post-Intro Preview Ended Overlay */
.modal-preview-ended {
    position: absolute;
    inset: 0;
    z-index: 20;
    background: rgba(4, 6, 21, 0.96);
    backdrop-filter: blur(12px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px;
    text-align: center;
    gap: 12px;
}

.ended-badge {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-full);
    background: rgba(0, 240, 255, 0.15);
    border: 1px solid var(--color-cyan);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2px;
}

.modal-preview-ended h3 {
    font-size: 1.35rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.02em;
}

.modal-preview-ended p {
    font-size: 0.9rem;
    color: #9ca3af;
    max-width: 320px;
    margin-bottom: 6px;
}

.ended-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    max-width: 320px;
}

.btn-replay {
    background-color: var(--color-red);
    color: #ffffff;
    font-weight: 700;
    padding: 10px 18px;
    border-radius: var(--radius-sm);
    box-shadow: 0 4px 16px var(--color-red-glow);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    flex: 1;
    min-width: 120px;
    cursor: pointer;
    transition: background-color var(--transition-fast);
}

.btn-replay:hover {
    background-color: var(--color-red-hover);
}

.btn-close-ended {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    font-weight: 700;
    padding: 10px 18px;
    border-radius: var(--radius-sm);
    flex: 1;
    min-width: 100px;
    cursor: pointer;
    transition: background-color var(--transition-fast);
}

.btn-close-ended:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* --------------------------------------------------------------------------
   Standalone Full-Screen Content Locker Popup Modal
   -------------------------------------------------------------------------- */
.locker-popup-modal {
    position: fixed;
    inset: 0;
    z-index: 50000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(0, 0, 0, 0.88);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.locker-popup-modal.is-open {
    display: flex;
    opacity: 1;
    visibility: visible;
}

.locker-popup-card {
    position: relative;
    width: 100%;
    max-width: 440px;
    max-height: calc(100vh - 32px);
    background: #080c1e;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 12px;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.95), 0 0 35px rgba(0, 240, 255, 0.15);
    display: flex;
    flex-direction: column;
    animation: popupZoomIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes popupZoomIn {
    from {
        transform: scale(0.92);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.locker-popup-close-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 20;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    border: none;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.15s ease;
}

.locker-popup-close-btn:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.08);
}

.locker-popup-body {
    padding: 36px 18px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    width: 100%;
}

.locker-popup-title {
    font-size: 1.15rem;
    font-weight: 600;
    line-height: 1.45;
    color: #ffffff;
    margin-bottom: 20px;
    letter-spacing: -0.01em;
    max-width: 380px;
    padding: 0 4px;
}

.locker-popup-blue {
    color: #38bdf8;
    font-weight: 700;
}

.locker-popup-offers {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 11px;
    margin-bottom: 22px;
}

.locker-popup-offer-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 48px;
    padding: 12px 16px;
    background: #ffffff;
    color: #0a0a0a;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 700;
    border-radius: 8px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
    transition: transform 0.15s ease, box-shadow 0.15s ease, background-color 0.15s ease;
    cursor: pointer;
    text-align: center;
    word-break: break-word;
}

.locker-popup-offer-btn:hover {
    background-color: #f1f5f9;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 240, 255, 0.25);
}

.locker-popup-offer-btn:active {
    transform: translateY(0);
}

.locker-popup-skeleton {
    width: 100%;
    height: 48px;
    background: linear-gradient(90deg, #1e293b 25%, #334155 50%, #1e293b 75%);
    background-size: 200% 100%;
    animation: skeletonShimmer 1.5s infinite;
    border-radius: 8px;
}

.locker-popup-status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 4px 8px;
}

.locker-popup-spinner {
    width: 12px;
    height: 12px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
}

.locker-popup-status-text {
    font-size: 0.92rem;
    font-weight: 600;
    color: #ffffff;
    letter-spacing: 0.02em;
}

/* --------------------------------------------------------------------------
   Toast Notification
   -------------------------------------------------------------------------- */
.toast-container {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 4000;
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 90%;
    max-width: 360px;
}

.toast {
    background: #0c1038;
    color: #ffffff;
    border: 1px solid var(--color-cyan);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.9);
    padding: 10px 16px;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    animation: toastPop 0.3s ease forwards;
}

@keyframes toastPop {
    from { transform: translateY(12px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* --------------------------------------------------------------------------
   Desktop Refinements
   -------------------------------------------------------------------------- */
@media (min-width: 768px) {
    .poster-frame {
        width: 220px;
    }

    .btn-play-full {
        max-width: 380px;
        margin: 0 auto;
    }

    .overview-text {
        text-align: center;
        max-width: 680px;
        margin-left: auto;
        margin-right: auto;
    }

    .cast-row {
        text-align: center;
    }

    .action-row {
        max-width: 440px;
        margin-left: auto;
        margin-right: auto;
    }
}
