/* ============================================
   Dreams Park Videos - Modern Card UI
   CDP-Shop Design System
   --primary: #003366  --secondary: #990033
   ============================================ */

/* ── CSS Variables ────────────────────────── */
:root {
    --vcard-radius: 12px;
    --vcard-shadow: 0 2px 12px rgba(0, 51, 102, 0.08);
    --vcard-shadow-hover: 0 12px 32px rgba(0, 51, 102, 0.16);
    --vcard-primary: #003366;
    --vcard-secondary: #990033;
    --vcard-bg: #ffffff;
    --vcard-border: rgba(0, 51, 102, 0.1);
    --vcard-transition: 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ── Filter Bar ──────────────────────────── */
.vfilter-bar {
    background: var(--vcard-bg);
    border: 1px solid var(--vcard-border);
    border-radius: var(--vcard-radius);
    padding: 16px 20px;
    box-shadow: var(--vcard-shadow);
}
.vfilter-bar .form-label {
    font-size: 0.78rem;
}
.vfilter-bar .form-select {
    border-color: var(--vcard-border);
    border-radius: 4px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.vfilter-bar .form-select:focus {
    border-color: var(--vcard-primary);
    box-shadow: 0 0 0 0.2rem rgba(0, 51, 102, 0.15);
}

/* ── Card Container (vertical layout) ────── */
.vcard {
    background: var(--vcard-bg);
    border: 1px solid var(--vcard-border);
    border-radius: var(--vcard-radius);
    overflow: hidden;
    box-shadow: var(--vcard-shadow);
    transition:
        transform var(--vcard-transition),
        box-shadow var(--vcard-transition);
    height: 100%;
    display: flex;
    flex-direction: column;
}
.vcard:hover {
    transform: translateY(-5px);
    box-shadow: var(--vcard-shadow-hover);
}

/* ── Image Section (top of card) ─────────── */
.vcard-img-wrap {
    position: relative;
    height: 200px;
    overflow: hidden;
    flex-shrink: 0;
}
.vcard-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.vcard:hover .vcard-img {
    transform: scale(1.06);
}
.vcard-img-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        transparent 30%,
        rgba(0, 51, 102, 0.5) 100%
    );
    pointer-events: none;
}

/* Game type badge — top-left */
.vcard-type-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 5px 12px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 1;
}

/* Video category badge styles moved to style.css (shared globally) */

/* Studio Session Player Video card info */
.vcard-player-info {
    padding: 0.5rem 0;
}
.vcard-player-name {
    font-size: 1rem;
    font-weight: 600;
    color: #212529;
    margin-bottom: 0.25rem;
}
.vcard-player-team {
    font-size: 0.875rem;
    color: #6c757d;
}

/* Date badge — bottom-right on image */
.vcard-date-badge {
    position: absolute;
    bottom: 10px;
    right: 10px;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.68rem;
    font-weight: 600;
    color: #fff;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 1;
}

/* ── Card Body ───────────────────────────── */
.vcard-body {
    display: flex;
    flex-direction: column;
    padding: 16px;
    flex: 1;
    gap: 10px;
}

/* ── Header: Tournament info ─────────────── */
.vcard-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--vcard-border);
}
.vcard-tournament-label {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--vcard-primary);
}
.vcard-game-number {
    font-size: 0.72rem;
    font-weight: 700;
    color: #6c757d;
    font-family: 'SF Mono', 'Consolas', 'Monaco', monospace;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

/* ── Meta Pills ──────────────────────────── */
.vcard-meta {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
.vcard-pill {
    display: inline-flex;
    align-items: center;
    gap: 2px;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
}
.vcard-pill-id {
    background: rgba(0, 51, 102, 0.08);
    color: var(--vcard-primary);
}
.vcard-pill-field {
    background: rgba(153, 0, 51, 0.07);
    color: var(--vcard-secondary);
}
.vcard-pill-day {
    background: rgba(25, 135, 84, 0.08);
    color: #198754;
}

/* ── Scoreboard ──────────────────────────── */
.vcard-scoreboard {
    display: flex;
    align-items: stretch;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid rgba(0, 51, 102, 0.08);
}
.vcard-team {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    min-width: 0;
    padding: 10px 12px;
}
.vcard-team-away {
    justify-content: flex-end;
    text-align: right;
    background: linear-gradient(135deg, rgba(0, 51, 102, 0.06) 0%, rgba(0, 51, 102, 0.02) 100%);
}
.vcard-team-home {
    justify-content: flex-start;
    text-align: left;
    background: linear-gradient(135deg, rgba(153, 0, 51, 0.02) 0%, rgba(153, 0, 51, 0.06) 100%);
}
.vcard-team-name {
    font-size: 0.74rem;
    font-weight: 700;
    line-height: 1.25;
    word-break: break-word;
    overflow-wrap: break-word;
    min-width: 0;
}
.vcard-team-away .vcard-team-name {
    color: var(--vcard-primary);
}
.vcard-team-home .vcard-team-name {
    color: var(--vcard-secondary);
}
.vcard-score {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    padding: 0 4px;
    font-size: 1.1rem;
    font-weight: 900;
    flex-shrink: 0;
}
.vcard-team-away .vcard-score {
    color: var(--vcard-primary);
}
.vcard-team-home .vcard-score {
    color: var(--vcard-secondary);
}
.vcard-vs {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 6px;
    font-size: 0.55rem;
    font-weight: 800;
    color: #fff;
    letter-spacing: 1px;
    background: linear-gradient(180deg, var(--vcard-primary) 0%, #004d99 100%);
    flex-shrink: 0;
}

/* ── Price Badge (top-right on image) ───── */
.vcard-price-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.85);
    color: var(--vcard-primary);
    font-size: 0.95rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px;
    backdrop-filter: blur(4px);
    z-index: 2;
    letter-spacing: 0.3px;
    line-height: 1;
}


/* ── Footer: Action Buttons ──────────────── */
.vcard-footer {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: auto;
    padding-top: 10px;
    border-top: 1px solid var(--vcard-border);
}

/* Wishlist button with heart icon */
.vcard-wishlist-btn {
    flex-shrink: 0;
}
.vcard-wishlist-btn i {
    font-size: 1.2rem;
}

/* Active wishlist button — #990033 filled, override global hover/focus */
.vcard-wishlist-btn.active,
.vcard-wishlist-btn.active:hover,
.vcard-wishlist-btn.active:focus,
.vcard-wishlist-btn.active:active {
    background-color: #990033 !important;
    border-color: #990033 !important;
    color: #fff !important;
}


/* ── Empty State ─────────────────────────── */
.vcard-empty {
    text-align: center;
    padding: 48px 24px;
    background: var(--vcard-bg);
    border-radius: var(--vcard-radius);
    border: 2px dashed var(--vcard-border);
}
.vcard-empty-icon {
    font-size: 3rem;
    color: #ced4da;
    margin-bottom: 12px;
}

/* ── Entrance Animation ──────────────────── */
@keyframes vcardFadeUp {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
#videoGrid > [class*="col-"] {
    animation: vcardFadeUp 0.4s ease both;
}
#videoGrid > [class*="col-"]:nth-child(2) { animation-delay: 0.05s; }
#videoGrid > [class*="col-"]:nth-child(3) { animation-delay: 0.1s; }
#videoGrid > [class*="col-"]:nth-child(4) { animation-delay: 0.15s; }
#videoGrid > [class*="col-"]:nth-child(5) { animation-delay: 0.2s; }
#videoGrid > [class*="col-"]:nth-child(6) { animation-delay: 0.25s; }
#videoGrid > [class*="col-"]:nth-child(7) { animation-delay: 0.3s; }
#videoGrid > [class*="col-"]:nth-child(8) { animation-delay: 0.35s; }
#videoGrid > [class*="col-"]:nth-child(9) { animation-delay: 0.4s; }

/* ── Video Detail Page ───────────────────── */
.video-preview-wrapper {
    position: relative;
    cursor: pointer;
}
.video-detail-thumbnail {
    min-height: 300px;
    max-height: 450px;
    object-fit: cover;
}
.video-preview-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.35);
    opacity: 0;
    transition: opacity 0.3s ease;
}
.video-preview-wrapper:hover .video-preview-overlay {
    opacity: 1;
}
.video-preview-info {
    background: linear-gradient(transparent, rgba(0, 0, 0, 0.6));
}
.play-btn-lg {
    width: 80px;
    height: 80px;
}
.play-btn-lg i {
    font-size: 2.5rem;
}

/* Score card (detail page) */
.score-card .team-icon {
    transition: transform 0.2s ease;
}
.score-card .team-icon:hover {
    transform: scale(1.1);
}
.score-display {
    line-height: 1;
}

/* ── Hero Banner ─────────────────────────── */
.video-hero-banner .bg-primary {
    background: linear-gradient(135deg, #003366 0%, #004d99 100%) !important;
}
.video-hero-images img {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}


/* ── Pagination ──────────────────────────── */
.pagination .page-link {
    color: var(--vcard-primary);
    border-color: #dee2e6;
    min-width: 38px;
    text-align: center;
    border-radius: 6px;
    margin: 0 2px;
    transition: all 0.2s ease;
}
.pagination .page-item.active .page-link {
    background-color: var(--vcard-secondary);
    border-color: var(--vcard-secondary);
    color: #fff;
}
.pagination .page-link:hover {
    background-color: var(--vcard-primary);
    border-color: var(--vcard-primary);
    color: #fff;
}
.pagination .page-item.disabled .page-link {
    color: #adb5bd;
}

/* ── Responsive ──────────────────────────── */
@media (max-width: 767.98px) {
    .vcard-img-wrap {
        height: 170px;
    }
    .vcard-body {
        padding: 14px;
        gap: 8px;
    }
    .vcard-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
    }
    .vcard-team {
        padding: 8px 10px;
    }
    .vcard-team-name {
        font-size: 0.7rem;
    }
    .video-detail-thumbnail {
        min-height: 200px;
        max-height: 280px;
    }
    .video-hero-banner h1 {
        font-size: 1.4rem;
    }
    .play-btn-lg {
        width: 60px;
        height: 60px;
    }
    .play-btn-lg i {
        font-size: 2rem;
    }
}

@media (max-width: 575.98px) {
    .vcard-img-wrap {
        height: 150px;
    }
    .vfilter-bar {
        padding: 12px 14px;
    }
}
