* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --spotify-green: #1db954;
    --spotify-dark: #191414;
    --text-primary: #ffffff;
    --text-secondary: #b3b3b3;
    --text-muted: #808080;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: var(--spotify-dark);
    color: var(--text-primary);
    overflow: hidden;
    height: 100vh;
    width: 100vw;
    user-select: none;
    -webkit-user-select: none;
}

.kiosk-container {
    position: relative;
    height: 100vh;
    width: 100vw;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* Background with album art */
.background-art {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    filter: blur(60px) brightness(0.4);
    transform: scale(1.1);
    transition: background-image 0.8s ease;
    z-index: 0;
}

.background-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        180deg,
        rgba(25, 20, 20, 0.9) 0%,
        rgba(25, 20, 20, 0.85) 50%,
        rgba(25, 20, 20, 0.95) 100%
    );
    z-index: 1;
}

/* Main Content */
.main-content {
    position: relative;
    z-index: 10;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 2rem 2rem 3rem 2rem;
    max-width: 100%;
    width: 100%;
    height: 100%;
    gap: 2rem;
}

/* Album Artwork */
.album-art-container {
    width: 100%;
    display: flex;
    justify-content: center;
    flex: 1;
    min-height: 0;
    animation: fadeIn 0.5s ease;
}

.album-art-wrapper {
    position: relative;
    width: 90%;
    max-width: 90vw;
    aspect-ratio: 1;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.8);
}

.album-art {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    animation: fadeIn 0.5s ease;
}

.art-shadow {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 40%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.5), transparent);
    pointer-events: none;
}

/* Track Information */
.track-info {
    text-align: center;
    width: 100%;
    padding: 0 2rem;
    flex-shrink: 0;
    animation: fadeInUp 0.6s ease 0.2s both;
}

.track-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    line-height: 1.2;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

.artist-name {
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
    line-height: 1.3;
}

.album-name {
    font-size: 0.95rem;
    font-weight: 400;
    color: var(--text-muted);
    line-height: 1.4;
}

/* Progress Bar */
.progress-container {
    width: 100%;
    padding: 0 2rem;
    flex-shrink: 0;
    animation: fadeInUp 0.6s ease 0.4s both;
}

.progress-bar {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 1rem;
}

.progress-fill {
    height: 100%;
    background: var(--spotify-green);
    border-radius: 3px;
    width: 0%;
    transition: width 0.3s linear;
    box-shadow: 0 0 10px rgba(29, 185, 84, 0.5);
}

.time-info {
    display: flex;
    justify-content: space-between;
    font-size: 0.9rem;
    color: var(--text-muted);
    font-variant-numeric: tabular-nums;
}

.time-elapsed,
.time-total {
    font-weight: 500;
}

/* Spotify Branding */
.spotify-branding {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-shrink: 0;
    animation: fadeInUp 0.6s ease 0.6s both;
}

.spotify-logo {
    width: 32px;
    height: 32px;
    color: var(--spotify-green);
}

.now-playing-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

/* Status Indicator */
.status-indicator {
    position: absolute;
    top: 2rem;
    right: 2rem;
    z-index: 20;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1.25rem;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 50px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--spotify-green);
    animation: pulse 2s ease-in-out infinite;
}

.status-text {
    font-weight: 500;
}

.status-indicator.error .status-dot {
    background: #ff4444;
    animation: none;
}

.status-indicator.error .status-text {
    color: #ff4444;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

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

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.6;
        transform: scale(0.95);
    }
}

/* Responsive adjustments for vertical screens */
@media (min-height: 1000px) {
    .main-content {
        gap: 2rem;
        padding: 2rem 2rem 3rem 2rem;
    }
    
    .track-title {
        font-size: 2.25rem;
    }
    
    .artist-name {
        font-size: 1.4rem;
    }
    
    .album-name {
        font-size: 1.1rem;
    }
    
    .album-art-wrapper {
        width: 90%;
    }
}

@media (max-width: 768px) {
    .main-content {
        padding: 2rem;
        gap: 2rem;
    }
    
    .track-title {
        font-size: 2rem;
    }
    
    .artist-name {
        font-size: 1.25rem;
    }
    
    .album-name {
        font-size: 1rem;
    }
    
    .album-art-wrapper {
        width: 90%;
    }
    
    .status-indicator {
        top: 1rem;
        right: 1rem;
        font-size: 0.75rem;
        padding: 0.5rem 1rem;
    }
}

/* Loading state */
.album-art[src=""],
.album-art:not([src]) {
    background: rgba(255, 255, 255, 0.1);
}

.track-title:empty::before {
    content: "No Track Playing";
}

.artist-name:empty::before {
    content: "—";
}

.album-name:empty::before {
    content: "—";
}
