:root {
    --spotify-green: #1DB954;
    --spotify-black: #121212;
    --spotify-dark: #191414;
    --text-white: #FFFFFF;
    --text-gray: #B3B3B3;
    --accent-red: #E91E63;
    --accent-blue: #2196F3;
    --accent-yellow: #FFC107;
    --accent-purple: #9C27B0;
    --glass: rgba(255, 255, 255, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Outfit', sans-serif;
}

body {
    background-color: var(--spotify-black);
    color: var(--text-white);
    height: 100vh;
    width: 100vw;
    overflow: hidden;
    position: fixed;
}

.screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--spotify-black);
    transition: opacity 0.5s ease;
    z-index: 100;
}

.screen.hidden {
    opacity: 0;
    pointer-events: none;
}

/* Loader */
.loader {
    text-align: center;
}

.spotify-logo-anim {
    width: 100px;
    height: 100px;
    margin: 0 auto 1.5rem;
    animation: pulse 2s infinite ease-in-out;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 0.8;
    }

    50% {
        transform: scale(1.1);
        opacity: 1;
    }

    100% {
        transform: scale(1);
        opacity: 0.8;
    }
}

#loading-text {
    font-size: 1.2rem;
    font-weight: 500;
    color: var(--spotify-green);
    letter-spacing: 1px;
}

/* Wrapper */
#wrapper {
    width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
}

/* Progress Bar */
#progress-bar-container {
    position: absolute;
    top: 15px;
    left: 10px;
    right: 10px;
    display: flex;
    gap: 5px;
    z-index: 50;
}

.progress-bar-bg {
    height: 4px;
    background: rgba(255, 255, 255, 0.2);
    flex-grow: 1;
    border-radius: 2px;
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: var(--text-white);
    width: 0%;
    border-radius: 2px;
}

.progress-bar-fill.filled {
    width: 100%;
}

/* Slides */
#slides-container {
    flex-grow: 1;
    position: relative;
    overflow: hidden;
    width: 100%;
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 2rem;
    opacity: 0;
    visibility: hidden;
    transform: scale(1.05);
    transition: all 0.7s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}

.slide.active {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
    z-index: 2;
}

/* Slide Specific Layouts */
.slide-title {
    font-size: 3.5rem;
    font-weight: 800;
    text-align: center;
    margin-bottom: 2rem;
    line-height: 1;
    text-transform: uppercase;
    letter-spacing: -2px;
}

.slide-subtitle {
    font-size: 1.2rem;
    text-align: center;
    margin-bottom: 3rem;
    opacity: 0.8;
}

/* Stats Lists */
.stats-list {
    width: 100%;
    max-width: 400px;
}

.stat-item {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0.8rem;
    background: var(--glass);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    transition: transform 0.3s ease;
}

.stat-item:hover {
    transform: translateX(10px);
}

.stat-rank {
    font-size: 1.5rem;
    font-weight: 800;
    margin-right: 1.5rem;
    width: 30px;
}

.stat-img {
    width: 50px;
    height: 50px;
    border-radius: 6px;
    margin-right: 1rem;
    object-fit: cover;
}

.stat-info {
    flex-grow: 1;
}

.stat-name {
    display: block;
    font-weight: 600;
    font-size: 1rem;
}

.stat-sub {
    font-size: 0.85rem;
    opacity: 0.6;
}

/* Highlight Items (Large) */
.highlight-container {
    text-align: center;
}

.highlight-img {
    width: 250px;
    height: 250px;
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    margin-bottom: 2rem;
    object-fit: cover;
}

.highlight-name {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
}

.highlight-sub {
    font-size: 1.2rem;
    opacity: 0.7;
}

/* Decorative Backgrounds for Slides */
.bg-blob {
    position: absolute;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    filter: blur(100px);
    z-index: -1;
    opacity: 0.3;
}

/* Controls */
#controls {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    z-index: 40;
}

.nav-btn {
    flex-grow: 1;
    background: transparent;
    border: none;
    cursor: pointer;
    outline: none;
    -webkit-tap-highlight-color: transparent;
    opacity: 0;
}

/* Playback Overlay - Hidden from bottom, now part of slide if needed */
#playback-overlay {
    display: none;
}

.slide-track-info {
    position: absolute;
    bottom: 60px;
    left: 0;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.8s ease 0.5s;
}

.slide.active .slide-track-info {
    opacity: 1;
    transform: translateY(0);
}

.slide-track-pill {
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    padding: 8px 16px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.slide-track-pill img {
    width: 24px;
    height: 24px;
    border-radius: 4px;
}

.slide-track-pill span {
    font-size: 0.8rem;
    font-weight: 600;
    max-width: 200px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Responsive */
@media (max-width: 480px) {
    .slide-title {
        font-size: 2.2rem;
    }

    .highlight-img {
        width: 200px;
        height: 200px;
    }

    .highlight-name {
        font-size: 1.8rem;
    }
}

/* Animations for slide content */
.animate-in {
    animation: slideInUp 0.8s cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}