/**
 * Soundcheck Player Styles
 * YouTube player container and video controls
 */

/* Close button - top left, always on top */
.btn-close {
    position: fixed;
    top: max(var(--spacing-md), env(safe-area-inset-top));
    left: var(--spacing-md);
    z-index: calc(var(--z-controls) + 100);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    color: rgba(255, 255, 255, 0.9);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    box-shadow:
        0 2px 8px rgba(0, 0, 0, 0.4),
        0 0 0 1px rgba(0, 0, 0, 0.2);
}

.btn-close:hover {
    background: rgba(0, 0, 0, 0.7);
    color: #fff;
    transform: scale(1.1);
    border-color: rgba(255, 255, 255, 0.25);
}

.btn-close:active {
    transform: scale(0.95);
}

.btn-close svg {
    width: 20px;
    height: 20px;
}

/* Player layer - centers content */
/* Padding accounts for fixed elements at top (close/settings buttons) and bottom (preset selector/stats) */
.layer-player {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    /* Top padding clears close button and lineup card handle */
    padding-top: calc(100px + var(--safe-area-inset-top, env(safe-area-inset-top, 0px)));
    padding-left: var(--spacing-lg);
    padding-right: var(--spacing-lg);
    /* Bottom padding clears fixed preset selector and session stats */
    padding-bottom: calc(120px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 34px)));
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Push player down when lineup card is expanded */
.lineup-card.expanded ~ .layer-player {
    transform: translateY(220px);
}

/* Player wrapper - contains iframe and transition overlay */
.player-wrapper {
    position: relative;
    width: var(--player-width);
    max-width: 100%;
    background-color: #000;
    border-radius: var(--radius-lg);
    overflow: visible;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    /* Maintain 16:9 aspect ratio */
    aspect-ratio: 16 / 9;
}

/* Video container clips the iframe */
#youtube-player {
    overflow: hidden;
    border-radius: var(--radius-lg);
}

/* Mobile: edge-to-edge video, no rounded corners */
@media (max-width: 640px) {
    .layer-player {
        padding-top: calc(100px + var(--safe-area-inset-top, env(safe-area-inset-top, 0px)));
        padding-left: 0;
        padding-right: 0;
        padding-bottom: calc(120px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 34px)));
    }

    .player-wrapper {
        width: 100vw;
        max-width: 100vw;
        border-radius: 0;
        box-shadow: none;
    }

    #youtube-player {
        border-radius: 0;
    }
}

/* YouTube iframe styling */
#youtube-player {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

#youtube-player iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* Transition overlay for fade effects */
.player-transition-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #000;
    opacity: 0;
    pointer-events: none;
    transition: opacity var(--transition-slow);
}

.player-transition-overlay.fading-out {
    opacity: 1;
}

.player-transition-overlay.fading-in {
    opacity: 0;
}

/* Show info above player */
.show-info {
    margin-bottom: var(--spacing-sm);
    text-align: center;
    font-size: 15px;
    color: rgba(255, 255, 255, 0.7);
    z-index: var(--z-song-info);
}

.show-date {
    color: #4ade80;
    font-weight: 600;
}

.show-separator {
    margin: 0 6px;
    color: rgba(255, 255, 255, 0.4);
}

.show-venue {
    color: rgba(255, 255, 255, 0.9);
}

.show-more {
    margin-left: var(--spacing-xs);
    background: rgba(255, 255, 255, 0.15);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
}

.show-more:empty {
    display: none;
}

/* Song info below player */
.song-info {
    margin-top: var(--spacing-sm);
    text-align: center;
    z-index: var(--z-song-info);
    max-width: var(--player-width);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.artist-name {
    font-size: 24px;
    font-weight: 700;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    line-height: 1.1;
    margin-bottom: 2px;
}

/* Skip forward button - circular, bottom-right corner of video */
.btn-skip-forward {
    position: absolute;
    right: 12px;
    bottom: -56px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1px;
    width: 44px;
    height: 44px;
    padding: 4px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    background: rgba(255, 255, 255, 0.03);
    color: rgba(255, 255, 255, 0.3);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
    z-index: 40;
}

.btn-skip-forward:hover {
    background: rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.7);
    transform: scale(1.1);
}

.btn-skip-forward:active {
    transform: scale(0.95);
}

.btn-skip-forward svg {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}

.btn-skip-forward .skip-text {
    font-size: 9px;
    font-weight: 600;
    letter-spacing: 0.3px;
    line-height: 1;
}

.info-separator {
    display: none;
}

.song-title {
    font-size: 20px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.5);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
    line-height: 1.1;
}

.artist-genres {
    font-size: 10px;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.35);
    margin-top: 2px;
    line-height: 1.1;
}

.artist-genres:empty {
    display: none;
}

/* Rating buttons */
.rating-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-top: 20px;
    z-index: var(--z-song-info);
    position: relative;
    width: 100%;
    padding: 0 var(--spacing-md);
    min-height: 70px; /* Fixed height prevents layout shift when switching modes */
}

.rating-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 1;
    aspect-ratio: 1;
    max-width: 70px;
    min-width: 44px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.4));
    /* Allow swipe gestures to pass through while keeping tap functionality */
    touch-action: manipulation;
}

.rating-btn:active {
    transform: scale(0.95);
}

.rating-btn.thumbs-down {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
}

.rating-btn.skip {
    max-width: 60px;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.5);
}

.rating-btn.thumbs-up {
    background: rgba(34, 197, 94, 0.2);
    color: #4ade80;
}

/* Hover states only for devices with hover capability (not touch) */
@media (hover: hover) {
    .rating-btn:hover {
        transform: scale(1.1);
    }

    .rating-btn.thumbs-down:hover {
        background: rgba(239, 68, 68, 0.3);
        color: #fca5a5;
    }

    .rating-btn.skip:hover {
        background: rgba(255, 255, 255, 0.15);
        color: rgba(255, 255, 255, 0.7);
    }

    .rating-btn.thumbs-up:hover {
        background: rgba(34, 197, 94, 0.3);
        color: #86efac;
    }
}

/* Secondary rating buttons (undo, star) - subtle but visible */
.rating-btn-secondary {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0.7;
    aspect-ratio: 1;
    max-width: 50px;
    min-width: 36px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s ease;
    background: rgba(255, 255, 255, 0.03);
    color: rgba(255, 255, 255, 0.3);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
    /* Allow swipe gestures to pass through while keeping tap functionality */
    touch-action: manipulation;
}

.rating-btn-secondary:active {
    transform: scale(0.95);
}

@media (hover: hover) {
    .rating-btn-secondary:hover {
        background: rgba(255, 255, 255, 0.15);
        color: rgba(255, 255, 255, 0.7);
        transform: scale(1.1);
    }
}

.rating-btn-secondary svg {
    width: 20px;
    height: 20px;
}

/* Star toggle button icon switching */
.rating-btn-secondary.star .icon-star,
.rating-btn-secondary.star .icon-close {
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.rating-btn-secondary.star.expanded .icon-star {
    display: none;
}

.rating-btn-secondary.star.expanded .icon-close {
    display: block !important;
}

/* 5-Star Rating Panel - sits inside rating-buttons, hidden by default */
.star-rating-panel {
    display: none;
    gap: 4px;
    align-items: center;
    justify-content: center;
}

.rating-buttons.star-mode .star-rating-panel {
    display: flex;
    animation: slideInFromRight 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideInFromRight {
    from {
        transform: translateX(50px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Individual star buttons */
.star-rating-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 4px;
    border-radius: 50%;
    transition: transform 0.15s ease;
    color: rgba(255, 255, 255, 0.4);
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.star-rating-btn:active {
    transform: scale(0.95);
}

@media (hover: hover) {
    .star-rating-btn:hover {
        transform: scale(1.1);
    }
}

.star-rating-btn svg {
    width: 44px;
    height: 44px;
    transition: fill 0.15s ease, stroke 0.15s ease, transform 0.2s ease;
}

/* Filled state (on hover of this star or previous stars) */
.star-rating-btn.filled svg {
    fill: #fbbf24;
    stroke: #fbbf24;
    color: #fbbf24;
}

/* Wave fill animation */
@keyframes starWaveFill {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.3);
    }
    100% {
        transform: scale(1);
    }
}

.star-rating-btn.wave-animating {
    animation: starWaveFill 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* Staggered animation delays for wave effect */
.star-rating-btn:nth-child(1).wave-animating { animation-delay: 0ms; }
.star-rating-btn:nth-child(2).wave-animating { animation-delay: 50ms; }
.star-rating-btn:nth-child(3).wave-animating { animation-delay: 100ms; }
.star-rating-btn:nth-child(4).wave-animating { animation-delay: 150ms; }
.star-rating-btn:nth-child(5).wave-animating { animation-delay: 200ms; }

/* Rating buttons hide completely when star panel is visible */
.rating-buttons.star-mode .rating-btn,
.rating-buttons.star-mode .rating-btn-secondary.undo {
    display: none;
}

/* In star mode: use invisible spacer to keep stars perfectly centered */
/* Spacer on left matches X button width, so stars stay centered */
.rating-buttons.star-mode::before {
    content: '';
    width: 44px;  /* matches X button fixed size */
    flex-shrink: 0;
}

/* X button: force small size in star mode (prevent flex growth) */
.rating-buttons.star-mode .rating-btn-secondary.star {
    flex: 0 0 44px;  /* don't grow, don't shrink, fixed 44px */
    width: 44px;
    max-width: 44px;
    min-width: 44px;
}

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

.rating-btn.skip svg {
    width: 20px;
    height: 20px;
}

/* Rating button pulse animation */
@keyframes rating-pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.35);
    }
    100% {
        transform: scale(1);
    }
}

.rating-btn.pulse-up {
    animation: rating-pulse 0.3s ease-out;
    background: rgba(34, 197, 94, 0.5) !important;
    color: #86efac !important;
}

.rating-btn.pulse-down {
    animation: rating-pulse 0.3s ease-out;
    background: rgba(239, 68, 68, 0.5) !important;
    color: #fca5a5 !important;
}

/* Swipe-active states - glow effect during swipe gesture */
.rating-btn.thumbs-down.swipe-active {
    background: rgba(239, 68, 68, 0.4);
    color: #fca5a5;
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.5), 0 0 40px rgba(239, 68, 68, 0.3);
}

.rating-btn.thumbs-up.swipe-active {
    background: rgba(34, 197, 94, 0.4);
    color: #86efac;
    box-shadow: 0 0 20px rgba(34, 197, 94, 0.5), 0 0 40px rgba(34, 197, 94, 0.3);
}

/* Persistent rated states - shown when song has been rated */
.rating-btn.rated-up {
    background: rgba(34, 197, 94, 0.75);
    color: #fff;
    transform: scale(1.15);
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.85);
}

.rating-btn.rated-up svg {
    width: 28px;
    height: 28px;
}

.rating-btn.rated-down {
    background: rgba(239, 68, 68, 0.75);
    color: #fff;
    transform: scale(1.15);
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.85);
}

.rating-btn.rated-down svg {
    width: 28px;
    height: 28px;
}

/* Star rating persistent filled state */
.star-rating-btn.rated svg {
    fill: #fbbf24;
    stroke: #fbbf24;
}

/* Video slide animations */
@keyframes slide-out-left {
    0% {
        transform: translateX(0);
        opacity: 1;
    }
    100% {
        transform: translateX(-100%);
        opacity: 0;
    }
}

@keyframes slide-out-right {
    0% {
        transform: translateX(0);
        opacity: 1;
    }
    100% {
        transform: translateX(100%);
        opacity: 0;
    }
}

@keyframes slide-in-from-left {
    0% {
        transform: translateX(-100%);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slide-in-from-right {
    0% {
        transform: translateX(100%);
        opacity: 0;
    }
    100% {
        transform: translateX(0);
        opacity: 1;
    }
}

.player-wrapper.slide-out-left {
    animation: slide-out-left 0.25s ease-in forwards;
}

.player-wrapper.slide-out-right {
    animation: slide-out-right 0.25s ease-in forwards;
}

.player-wrapper.slide-in-from-left {
    animation: slide-in-from-left 0.25s ease-out forwards;
}

.player-wrapper.slide-in-from-right {
    animation: slide-in-from-right 0.25s ease-out forwards;
}

/* Player loading state */
.player-wrapper.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 3px solid rgba(255, 255, 255, 0.2);
    border-top-color: var(--color-accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .layer-player {
        padding-top: calc(100px + var(--safe-area-inset-top, env(safe-area-inset-top, 0px)));
        padding-left: var(--spacing-md);
        padding-right: var(--spacing-md);
        padding-bottom: calc(120px + var(--safe-area-inset-bottom, env(safe-area-inset-bottom, 34px)));
    }

    /* Smaller push on mobile since lineup card is smaller */
    .lineup-card.expanded ~ .layer-player {
        transform: translateY(120px);
    }

    /* Slightly smaller text on mobile */
    .artist-name {
        font-size: 20px;
        font-weight: 700;
    }

    .song-title {
        font-size: 17px;
    }

    /* Tighter gap and less padding on mobile for wider buttons */
    .rating-buttons {
        gap: 4px;
        padding: 0 var(--spacing-xs);
    }

    /* Star rating buttons on mobile - larger for touch */
    .star-rating-btn svg {
        width: 47px;
        height: 47px;
    }

    .star-rating-panel {
        gap: 4px;
    }

    .star-rating-btn {
        padding: 0;
    }

    /* Mobile: smaller spacer and X button to match */
    .rating-buttons.star-mode::before {
        width: 36px;
    }

    .rating-buttons.star-mode .rating-btn-secondary.star {
        flex: 0 0 36px;
        width: 36px;
        max-width: 36px;
        min-width: 36px;
    }

    .rating-btn.skip svg {
        width: 25px;
        height: 25px;
    }

    /* Skip forward button on mobile */
    .btn-skip-forward {
        right: 8px;
        bottom: -50px;
        width: 40px;
        height: 40px;
        padding: 3px;
    }

    .btn-skip-forward svg {
        width: 12px;
        height: 12px;
    }

    .btn-skip-forward .skip-text {
        font-size: 8px;
    }
}

/* Swipe feedback - subtle tilt effect */
.player-wrapper.swiping-left {
    transform: perspective(1000px) rotateY(5deg) translateX(-20px);
    transition: transform 0.1s ease-out;
}

.player-wrapper.swiping-right {
    transform: perspective(1000px) rotateY(-5deg) translateX(20px);
    transition: transform 0.1s ease-out;
}

/* ========================================
   Embed Loading Overlay
   ======================================== */

.embed-loading-overlay {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(10px);
    z-index: 10;
    display: none;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm, 8px);
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    padding: 10px 18px;
    border-radius: 24px;
    opacity: 0;
    transition: opacity 0.3s ease, transform 0.3s ease;
    pointer-events: none;
}

.embed-loading-overlay.visible {
    display: flex;
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

.embed-loading-spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-top-color: var(--color-accent, #4ade80);
    border-radius: 50%;
    animation: embed-spin 0.8s linear infinite;
    flex-shrink: 0;
}

@keyframes embed-spin {
    to { transform: rotate(360deg); }
}

.embed-loading-text {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.9);
    text-align: center;
    white-space: nowrap;
}

/* ========================================
   Lineup Card - Pull-down show info
   ======================================== */

.lineup-card {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: calc(var(--z-controls) + 20);
    background: linear-gradient(to bottom,
        rgba(0, 0, 0, 0.5) 0%,
        rgba(0, 0, 0, 0.45) 70%,
        rgba(0, 0, 0, 0.2) 90%,
        transparent 100%
    );
    padding: 72px var(--spacing-md) 8px;
    /* Start with card partially hidden, showing bottom of art + handle */
    transform: translateY(calc(-100% + 130px));
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}


/* Handle area - at bottom of card, always visible */
.lineup-card-handle {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px var(--spacing-md);
    cursor: pointer;
    color: rgba(255, 255, 255, 0.4);
    transition: color 0.2s ease;
    margin-top: 4px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
    position: relative;
    z-index: 20;
    /* Ensure clickable */
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}

.lineup-card-handle:hover {
    color: rgba(255, 255, 255, 0.7);
}

.lineup-handle-text {
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.lineup-handle-chevron {
    transition: transform 0.3s ease;
}

/* Expanded state */
.lineup-card.expanded {
    transform: translateY(0);
}

.lineup-card.expanded .lineup-handle-chevron {
    transform: rotate(180deg);
}

/* Card content - image and artists */
.lineup-card-content {
    display: flex;
    gap: var(--spacing-md);
    padding: 0 var(--spacing-sm);
    transition: opacity 0.25s ease;
    position: relative;
    z-index: -1 !important; /* Negative to force below fade */
}


/* Note: Old lineup-card-artists and lineup-card-image styles removed
   Content is now rendered by the show_card component */

/* Full-width gradient fade overlay - fades content to black at top when collapsed */
.lineup-card-fade {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 40px; /* Stop above the handle */
    background: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,1) 75%, rgba(0,0,0,0) 100%);
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 100 !important;
    isolation: isolate;
}

/* Hide the fade when lineup is expanded */
.lineup-card.expanded .lineup-card-fade {
    opacity: 0;
}

/* Note: Old lineup-card-image, lineup-card-artists, lineup-artist styles removed
   Content is now rendered by the show_card component */

/* Mobile adjustments for lineup card wrapper */
@media (max-width: 768px) {
    .lineup-card {
        padding: 64px var(--spacing-sm) 8px;
        transform: translateY(calc(-100% + 110px));
    }

    .lineup-card-content {
        padding: 0;
    }
}

/* Short screens (iPhone SE, etc.) - compact lineup card */
@media (max-height: 700px) {
    .lineup-card {
        padding: 56px var(--spacing-sm) 4px;
    }

    .lineup-card-handle {
        padding: 6px var(--spacing-sm);
        margin-top: 2px;
    }

    .lineup-handle-text {
        font-size: 12px;
        letter-spacing: 1px;
    }
}

/* ==========================================================================
   Show Card Component Integration
   Override styles for .sc-card when inside lineup card
   ========================================================================== */

/* Override component's grid layout for lineup card context */
.lineup-card-content .sc-card {
    grid-template-columns: 120px 1fr 50px 40px;
    gap: 12px;
    padding: 12px;
    background: transparent;
    border-bottom: none;
    cursor: default;
}

.lineup-card-content .sc-card:hover {
    background: transparent;
}

/* Image column */
.lineup-card-content .sc-thumbnail,
.lineup-card-content .sc-thumbnail-placeholder {
    width: 120px;
    height: 120px;
    cursor: default;
}

.lineup-card-content .sc-thumbnail:hover {
    transform: none;
    box-shadow: none;
}

.lineup-card-content .sc-zoom-hint {
    display: none;
}

/* Info column - fade when collapsed */
.lineup-card-content .sc-info {
    opacity: 0.4;
    transition: opacity 0.25s ease;
}

.lineup-card.expanded .lineup-card-content .sc-info {
    opacity: 1;
}

/* Venue name styling */
.lineup-card-content .sc-venue {
    font-size: 14px;
    line-height: 1.3;
}

/* Artist list styling */
.lineup-card-content .sc-artists {
    padding-left: 0;
    margin: 0;
}

.lineup-card-content .sc-artists li {
    padding: 3px 0;
    font-size: 13px;
}

/* Hide genres in collapsed state, show when expanded */
.lineup-card-content .sc-genres {
    display: none;
}

.lineup-card.expanded .lineup-card-content .sc-genres {
    display: flex;
}

/* Rating column - hidden when collapsed */
.lineup-card-content .sc-rating-col {
    opacity: 0;
    transition: opacity 0.25s ease;
}

.lineup-card.expanded .lineup-card-content .sc-rating-col {
    opacity: 1;
}

/* Menu column - hidden when collapsed */
.lineup-card-content .sc-menu {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.lineup-card.expanded .lineup-card-content .sc-menu {
    opacity: 1;
    pointer-events: auto;
}

/* Mobile adjustments for lineup card show component */
@media (max-width: 480px) {
    .lineup-card-content .sc-card {
        grid-template-columns: 90px 1fr 40px 32px;
        gap: 8px;
        padding: 10px;
    }

    .lineup-card-content .sc-thumbnail,
    .lineup-card-content .sc-thumbnail-placeholder {
        width: 90px;
        height: 90px;
    }

    .lineup-card-content .sc-venue {
        font-size: 13px;
    }

    .lineup-card-content .sc-artists li {
        font-size: 12px;
        padding: 2px 0;
    }
}

/* End of playlist action button */
.end-action-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 24px;
    padding: 12px 24px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.8);
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.end-action-btn svg {
    flex-shrink: 0;
    vertical-align: middle;
}

.end-action-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
    color: rgba(255, 255, 255, 0.95);
    transform: scale(1.05);
}

.end-action-btn:active {
    transform: scale(0.98);
}

@media (max-width: 768px) {
    .end-action-btn {
        padding: 14px 28px;
        font-size: 16px;
    }
}

/* Completion container - replaces rating buttons when playlist is done */
.completion-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 14px 32px 18px;
    text-align: center;
    /* Translucent card background */
    background: rgba(80, 100, 140, 0.15);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 16px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    margin: 16px auto 0;
    max-width: 400px;
    width: auto;
}

.completion-title {
    font-size: 20px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.95);
    margin-bottom: 8px;
}

.completion-subtitle {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 16px;
}

.completion-container .end-action-btn {
    margin-top: 8px;
}

/* Button container for multiple completion buttons (e.g., onboarding) */
.completion-buttons {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    width: 100%;
    margin-top: 8px;
}

.completion-buttons .end-action-btn {
    margin-top: 0;
    padding: 10px 16px;
    font-size: 14px;
}

/* Secondary button style - more subtle */
.end-action-btn-secondary {
    background: transparent;
    border-color: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.7);
}

.end-action-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.25);
    color: rgba(255, 255, 255, 0.85);
}

@media (max-width: 768px) {
    .completion-container {
        padding: 12px 24px 16px;
        max-width: 340px;
    }

    .completion-title {
        font-size: 18px;
    }

    .completion-subtitle {
        font-size: 13px;
    }

    .completion-buttons {
        gap: 6px;
    }

    .completion-buttons .end-action-btn {
        padding: 10px 14px;
        font-size: 13px;
    }
}

/* ========================================
   Buffering Hint Tooltip
   ======================================== */

.buffering-hint {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 12px;
    padding: 10px 16px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-md);
    color: rgba(255, 255, 255, 0.9);
    text-align: center;
    cursor: pointer;
    z-index: var(--z-controls);
}

.buffering-hint.hidden {
    display: none;
}

.buffering-hint-arrow {
    position: absolute;
    top: -14px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 14px;
    color: rgba(255, 255, 255, 0.5);
    line-height: 1;
}

.buffering-hint-text {
    font-size: 13px;
    line-height: 1.4;
}

.buffering-hint-close {
    position: absolute;
    top: 4px;
    right: 8px;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    font-size: 16px;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}

.buffering-hint-close:hover {
    color: rgba(255, 255, 255, 0.8);
}
