:root {
    --accent-blue: #00eaff;
    --accent-purple: #ff00ff;
    --accent-green: #00ff7f;
    --glass: rgba(255, 255, 255, 0.03);
    --border: rgba(255, 255, 255, 0.08);
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: 'Inter', sans-serif; }

body {
    background: linear-gradient(135deg, #05010a, #1a0033, #00051a, #0d001a);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    color: white;
    min-height: 100vh;
    display: flex; justify-content: center; align-items: center;
    overflow-x: hidden; padding: 20px;
}

@keyframes gradientShift { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }

#trail {
    position: fixed; inset: 0;
    pointer-events: none; /* Allows clicks to pass through to buttons/scroll */
    z-index: 1;
}

.container { width: 100%; max-width: 1100px; z-index: 10; position: relative; }

.title { font-size: clamp(3rem, 10vw, 5rem); font-weight: 900; letter-spacing: -4px; text-align: center; background: linear-gradient(#fff, #888); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.tagline { text-align: center; margin-bottom: 40px; color: #666; text-transform: uppercase; letter-spacing: 3px; font-size: 0.8rem; }

.grid-layout { display: grid; gap: 20px; }

.bento-card {
    background: var(--glass);
    backdrop-filter: blur(30px); -webkit-backdrop-filter: blur(30px);
    border: 1px solid var(--border);
    border-radius: 30px; padding: 30px;
    box-shadow: 0 25px 50px rgba(0,0,0,0.5);
    position: relative;
    z-index: 5;
}

/* Scroll Header Logic */
.shelf-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; }
.progress-container { width: 100px; height: 4px; background: rgba(255,255,255,0.1); border-radius: 10px; overflow: hidden; }
.progress-bar { width: 0%; height: 100%; background: linear-gradient(to right, var(--accent-blue), var(--accent-purple)); transition: width 0.1s ease; }

/* Status Dots */
.status-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 8px; position: relative; top: -1px; }
.status-dot.green { background: var(--accent-green); box-shadow: 0 0 10px var(--accent-green); animation: pulse 2s infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.4; } }
kbd { background: rgba(255,255,255,0.1); border-radius: 4px; padding: 2px 6px; font-size: 0.7rem; margin-left: 8px; color: #aaa; }

/* Buttons */
.buttons { display: flex; gap: 15px; flex-wrap: wrap; }
.btn { flex: 1; min-width: 180px; padding: 18px; border-radius: 20px; text-decoration: none; font-weight: 700; color: white; text-align: center; border: 1px solid var(--border); transition: 0.3s; background: rgba(255,255,255,0.03); }
.btn.primary { background: white; color: black; border: none; }
.btn:hover { transform: translateY(-3px); border-color: var(--accent-blue); box-shadow: 0 10px 30px rgba(0, 234, 255, 0.2); }

/* --- THE FINAL SCROLL FIX --- */
.media-row { 
    display: flex; 
    gap: 20px; 
    overflow-x: auto !important; 
    overflow-y: hidden;
    padding-bottom: 25px; 
    position: relative;
    z-index: 100; /* Highest priority */
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-purple) transparent;
}

/* Chrome/Safari Scrollbar */
.media-row::-webkit-scrollbar { height: 10px; }
.media-row::-webkit-scrollbar-track { background: rgba(255, 255, 255, 0.05); border-radius: 10px; }
.media-row::-webkit-scrollbar-thumb { background: linear-gradient(to right, var(--accent-blue), var(--accent-purple)); border-radius: 10px; }

.media-item-link { 
    flex: 0 0 160px !important; /* CRITICAL: Prevents posters from shrinking */
    text-decoration: none; 
    transition: 0.3s; 
}
.media-item-link:hover { transform: translateY(-8px); }
.media-item img { width: 160px; height: 240px; border-radius: 18px; border: 1px solid var(--border); object-fit: cover; display: block; background: #111; }
.media-item p { font-size: 0.75rem; color: #888; margin-top: 10px; width: 160px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 768px) { .buttons { flex-direction: column; } .btn { width: 100%; } }
