/* === BUS DRIVER KI PLAYLIST - GRAINY TWO-TONE === */
@import url('https://fonts.googleapis.com/css2?family=Tiro+Devanagari+Hindi:wght@400&family=Inter:wght@400;600;700;800;900&display=swap');

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

:root {
    --bus-blue: #1a237e;
    --bus-red: #c0392b;
    --bus-accent: #f1c40f;
    --bus-text: #ffffff;
    --bus-card: rgba(10, 10, 40, 0.75);
    --bus-card-border: rgba(255, 255, 255, 0.08);
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--bus-text);
    background: #0a0a1a;
    overflow-x: hidden;
}

/* === GRAIN OVERLAY === */
.grain {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 9999;
    opacity: 0.4;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='1'/%3E%3C/svg%3E");
    background-repeat: repeat;
    mix-blend-mode: overlay;
}

/* === TOP BAR === */
.top-bar {
    position: fixed;
    top: 0; left: 0; right: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.2rem 2.5rem;
    z-index: 100;
}

.current-time {
    font-size: 0.85rem;
    opacity: 0.8;
    font-weight: 500;
}

.live-count {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 600;
}

.live-dot {
    width: 8px; height: 8px;
    background: #28c840;
    border-radius: 50%;
    animation: pulse-live 2s ease-in-out infinite;
}

@keyframes pulse-live {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(1.6); }
}

.home-link {
    color: var(--bus-text);
    font-size: 1.2rem;
    opacity: 0.6;
    text-decoration: none;
    transition: opacity 0.2s;
}
.home-link:hover { opacity: 1; }

/* === MOOD SWITCHER === */
.mood-switcher {
    position: fixed;
    top: 1.2rem;
    right: 4rem;
    z-index: 101;
}

.mood-toggle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #fff;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s, box-shadow 0.3s;
}

.mood-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(241, 196, 15, 0.3);
}

.mood-options {
    position: absolute;
    top: 50px;
    right: 0;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    padding: 0.6rem;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-10px) scale(0.95);
    transition: opacity 0.3s, transform 0.3s;
    min-width: 140px;
}

.mood-options.open {
    opacity: 1;
    pointer-events: all;
    transform: translateY(0) scale(1);
}

.mood-option {
    background: none;
    border: 1px solid transparent;
    color: #fff;
    font-family: 'Inter', sans-serif;
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.6rem 0.9rem;
    border-radius: 8px;
    cursor: pointer;
    text-align: left;
    transition: background 0.2s, border-color 0.2s;
}

.mood-option:hover {
    background: rgba(255, 255, 255, 0.08);
}

.mood-option.active {
    background: rgba(241, 196, 15, 0.12);
    border-color: var(--bus-accent);
    color: var(--bus-accent);
}

/* === HERO FULLSCREEN === */
.hero-fullscreen {
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background: url('/bus-driver-playlist/background.png') center center / cover no-repeat;
    z-index: 0;
    transition: opacity 0.6s ease;
}

/* Bus is now in the background image */

/* === HERO CONTENT === */
.hero-content {
    position: absolute;
    top: 15%;
    left: 0;
    right: 0;
    text-align: center;
    z-index: 3;
}

.hero-title {
    font-family: 'Tiro Devanagari Hindi', serif;
    font-size: 7rem;
    font-weight: 400;
    color: var(--bus-text);
    text-shadow: 0 4px 30px rgba(0,0,0,0.5);
    letter-spacing: 2px;
}

/* === QUOTE === */
.hero-quote-wrap {
    position: absolute;
    bottom: 22%;
    left: 0;
    right: 0;
    text-align: center;
    z-index: 5;
}

.hero-quote {
    font-family: 'Tiro Devanagari Hindi', serif;
    font-size: 1.15rem;
    opacity: 0.85;
    max-width: 550px;
    margin: 0 auto;
    line-height: 1.9;
    text-shadow: 0 2px 10px rgba(0,0,0,0.6);
}

/* === PLAYER PILL === */
.player-pill {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    width: 90%;
    max-width: 520px;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 60px;
    padding: 0.75rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.player-pill-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex: 1;
    min-width: 0;
}

.player-album-art {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    flex-shrink: 0;
    object-fit: cover;
    animation: spin-disc 3s linear infinite;
    animation-play-state: paused;
    border: 2px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.4);
}

.player-album-art.spinning {
    animation-play-state: running;
}

@keyframes spin-disc {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.player-meta {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.player-song {
    font-size: 0.85rem;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.player-artist {
    font-size: 0.7rem;
    opacity: 0.5;
}

.player-time-row {
    display: flex;
    align-items: center;
    gap: 0.2rem;
    margin-top: 0.15rem;
}

.player-time {
    font-size: 0.6rem;
    opacity: 0.5;
}

.player-time-sep {
    font-size: 0.6rem;
    opacity: 0.3;
}

.player-pill-progress {
    position: absolute;
    bottom: 0;
    left: 1.5rem;
    right: 1.5rem;
    height: 4px;
    background: rgba(255,255,255,0.1);
    border-radius: 2px;
    overflow: hidden;
    cursor: pointer;
    transition: height 0.2s;
}

.player-pill-progress:hover {
    height: 8px;
}

.player-pill-progress-fill {
    height: 100%;
    width: 0%;
    background: var(--bus-accent);
    border-radius: 2px;
    transition: width 0.2s linear;
    pointer-events: none;
}

.player-pill-controls {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.p-btn {
    background: none;
    border: none;
    color: var(--bus-text);
    font-size: 1.1rem;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s, transform 0.15s;
    padding: 0.4rem;
}
.p-btn:hover { opacity: 1; transform: scale(1.1); }

.p-play {
    width: 38px; height: 38px;
    background: var(--bus-text);
    color: #000;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    opacity: 1;
}
.p-play:hover { box-shadow: 0 0 15px rgba(255,255,255,0.3); }

.p-shuffle { font-size: 0.9rem; }

/* === HONK BUTTON === */
.honk-btn {
    position: absolute;
    left: 2rem;
    bottom: 40%;
    z-index: 10;
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.7rem 1.2rem;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    color: var(--bus-text);
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
    text-align: left;
}

.honk-btn:hover {
    background: rgba(241, 196, 15, 0.15);
    border-color: var(--bus-accent);
    box-shadow: 0 0 25px rgba(241, 196, 15, 0.2);
}

.honk-btn:active { transform: scale(0.9); }

.honk-icon { font-size: 1.3rem; }

.honk-label {
    line-height: 1.3;
    font-weight: 600;
}

.honk-label small {
    font-size: 0.65rem;
    opacity: 0.5;
    font-weight: 400;
}

.honk-count {
    background: var(--bus-accent);
    color: #000;
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
    font-size: 0.65rem;
    font-weight: 800;
}

/* === BELOW FOLD === */
.below-fold {
    background: linear-gradient(180deg, #0f1a3d 0%, #1a237e 30%, #4a1942 60%, #6b1d1d 100%);
    padding: 4rem 1.5rem;
}

.content-wrap {
    max-width: 600px;
    margin: 0 auto;
}

.section-heading {
    font-size: 1.1rem;
    margin-bottom: 1.2rem;
    opacity: 0.9;
}

/* Playlist */
.playlist-section { margin-bottom: 3rem; }

.playlist {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    max-height: 340px;
    overflow-y: auto;
    padding-right: 0.5rem;
}

/* Scrollbar styling */
.playlist::-webkit-scrollbar {
    width: 4px;
}

.playlist::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 2px;
}

.playlist::-webkit-scrollbar-thumb {
    background: var(--bus-accent);
    border-radius: 2px;
}

.playlist li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.2rem;
    background: var(--bus-card);
    border: 1px solid var(--bus-card-border);
    border-left: 3px solid transparent;
    border-radius: 12px;
    cursor: pointer;
    transition: border-color 0.3s, background 0.3s;
}

.playlist li:hover {
    border-color: var(--bus-accent);
    border-left-color: var(--bus-accent);
}

.playlist li.active {
    border-color: var(--bus-accent);
    border-left-color: var(--bus-accent);
    background: rgba(241, 196, 15, 0.06);
}

.playlist li.active .song-name { color: var(--bus-accent); }

.playlist .song-name {
    font-size: 0.9rem;
    font-weight: 600;
}

.playlist .song-duration {
    font-size: 0.75rem;
    opacity: 0.35;
}

/* Queue */
.queue-section {
    margin-bottom: 3rem;
    padding: 1.5rem;
    background: var(--bus-card);
    border: 1px solid var(--bus-card-border);
    border-radius: 16px;
}

.queue-section .section-heading {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.queue-count {
    background: var(--bus-accent);
    color: #000;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
}

.queue-desc {
    font-size: 0.8rem;
    opacity: 0.4;
    margin-bottom: 1rem;
}

.queue-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    max-height: 220px;
    overflow-y: auto;
    margin-bottom: 1rem;
}

.queue-list::-webkit-scrollbar {
    width: 3px;
}

.queue-list::-webkit-scrollbar-thumb {
    background: var(--bus-accent);
    border-radius: 2px;
}

.queue-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.7rem 1rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    font-size: 0.85rem;
}

.queue-list li .queue-song-name {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.queue-list li .queue-num {
    font-size: 0.7rem;
    opacity: 0.4;
    min-width: 20px;
}

.queue-list li .queue-remove {
    background: none;
    border: none;
    color: #e74c3c;
    font-size: 1rem;
    cursor: pointer;
    opacity: 0.5;
    transition: opacity 0.2s;
    padding: 0 0.3rem;
}

.queue-list li .queue-remove:hover {
    opacity: 1;
}

.queue-empty {
    text-align: center;
    opacity: 0.3;
    font-style: italic;
    font-size: 0.85rem;
    padding: 1rem !important;
    border: none !important;
    background: none !important;
}

.queue-controls {
    display: flex;
    gap: 0.75rem;
}

.queue-btn {
    flex: 1;
    padding: 0.7rem 1rem;
    border: 1px solid var(--bus-accent);
    background: rgba(241, 196, 15, 0.1);
    color: var(--bus-accent);
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}

.queue-btn:hover {
    background: rgba(241, 196, 15, 0.2);
    transform: translateY(-1px);
}

.queue-btn-clear {
    border-color: #e74c3c;
    color: #e74c3c;
    background: rgba(231, 76, 60, 0.1);
}

.queue-btn-clear:hover {
    background: rgba(231, 76, 60, 0.2);
}

/* Add to queue button in playlist items */
.playlist li .add-queue-btn {
    background: none;
    border: 1px solid rgba(255,255,255,0.15);
    color: var(--bus-accent);
    font-size: 1rem;
    cursor: pointer;
    border-radius: 50%;
    width: 26px;
    height: 26px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, border-color 0.2s, transform 0.2s;
    flex-shrink: 0;
    margin-left: 0.5rem;
}

.playlist li .add-queue-btn:hover {
    background: rgba(241, 196, 15, 0.15);
    border-color: var(--bus-accent);
    transform: scale(1.15);
}

/* Speed */
.speed-section {
    margin-bottom: 3rem;
    text-align: center;
    padding: 2rem;
    background: var(--bus-card);
    border: 1px solid var(--bus-card-border);
    border-radius: 16px;
}

.speed-desc {
    font-size: 0.8rem;
    opacity: 0.4;
    margin-bottom: 1.5rem;
}

.speed-num {
    font-size: 4.5rem;
    font-weight: 900;
    color: var(--bus-accent);
    line-height: 1;
}

.speed-unit {
    font-size: 1rem;
    opacity: 0.4;
}

.speed-bar {
    width: 100%;
    height: 5px;
    background: rgba(255,255,255,0.08);
    border-radius: 3px;
    overflow: hidden;
    margin: 1rem 0;
}

.speed-fill {
    width: 0%;
    height: 100%;
    background: linear-gradient(90deg, #28c840, var(--bus-accent), #e74c3c);
    border-radius: 3px;
    transition: width 0.3s;
}

.speed-comment {
    font-size: 0.85rem;
    opacity: 0.6;
    font-style: italic;
}

/* Passengers */
.passenger-section {
    margin-bottom: 3rem;
    text-align: center;
    padding: 2rem;
    background: var(--bus-card);
    border: 1px solid var(--bus-card-border);
    border-radius: 16px;
}

.passenger-desc {
    font-size: 0.8rem;
    opacity: 0.4;
    margin-bottom: 1rem;
}

.passenger-display {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.5rem;
}

.passenger-num {
    font-size: 3.5rem;
    font-weight: 900;
    color: var(--bus-accent);
}

.passenger-label {
    font-size: 1rem;
    opacity: 0.6;
}

/* Footer */
.bus-footer {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.08);
    text-align: center;
    opacity: 0.5;
}

.bus-footer .credit {
    margin-top: 0.5rem;
    font-size: 0.75rem;
}

.bus-footer a {
    color: var(--bus-accent);
    text-decoration: none;
}

/* === RESPONSIVE === */
@media (max-width: 768px) {
    .hero-title { font-size: 4rem; }
    .bus-container { width: 80%; right: 2%; bottom: 15%; }
    .honk-btn { left: 1rem; bottom: 35%; }
    .player-pill { width: 94%; border-radius: 20px; padding: 0.7rem 1rem; }
}

@media (max-width: 480px) {
    .hero-title { font-size: 3rem; }
    .hero-quote { font-size: 1rem; }
    .bus-container { width: 95%; right: 0; bottom: 18%; }
    .honk-btn { left: 0.75rem; bottom: 30%; padding: 0.5rem 0.8rem; }
    .honk-label { display: none; }
    .player-pill { bottom: 1.5rem; }
    .speed-num { font-size: 3rem; }
}
