/* ═══════════════════════════════════════════════════════════
   IZGE MEDYA — style.css
   Deneysel Ses Mimarisi | Cyber-Minimalist Tasarım Sistemi
   ═══════════════════════════════════════════════════════════ */

/* ── Base ── */
html {
    scroll-behavior: smooth;
}

/* ── Glass Panel ── */
.glass-panel {
    background: rgba(27, 31, 44, 0.6);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(245, 245, 255, 0.1);
}

/* ── Holographic Card ── */
.holographic-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 0%, rgba(245, 245, 255, 0.05) 50%, transparent 100%);
    pointer-events: none;
}

/* ── Text Glow ── */
.text-glow {
    text-shadow: 0 0 15px rgba(61, 233, 111, 0.3);
}

/* ── Pulse Slow ── */
@keyframes pulse-slow {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.6; }
}
.animate-pulse-slow {
    animation: pulse-slow 4s ease-in-out infinite;
}

/* ── Starfield Canvas ── */
#starfield-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    pointer-events: none;
}

/* ── Hero Visualizer Canvas ── */
#hero-visualizer {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

/* ══════════════════════════════════════════════════════
   SCROLL REVEAL
   ══════════════════════════════════════════════════════ */
.reveal-item {
    opacity: 0;
    transform: translateY(40px) scale(0.97);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal-item.revealed {
    opacity: 1;
    transform: translateY(0) scale(1);
}

/* ══════════════════════════════════════════════════════
   MOUSE GLOW
   ══════════════════════════════════════════════════════ */
.glow-target {
    position: relative;
    overflow: hidden;
}
.glow-target .mouse-glow {
    position: absolute;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(61, 233, 111, 0.12) 0%, transparent 70%);
    pointer-events: none;
    transform: translate(-50%, -50%);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: 1;
}
.glow-target:hover .mouse-glow {
    opacity: 1;
}

/* ══════════════════════════════════════════════════════
   FLOATING MUSIC PLAYER
   ══════════════════════════════════════════════════════ */
#floating-player {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 90;
    width: 320px;
    transform: translateY(120%);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
#floating-player.visible {
    transform: translateY(0);
}

@media (max-width: 640px) {
    #floating-player {
        width: calc(100% - 32px);
        right: 16px;
        bottom: 16px;
    }
}

/* ── Now Playing Marquee ── */
@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}
.marquee-track {
    display: flex;
    width: max-content;
    animation: marquee 12s linear infinite;
}

/* ── Player EQ Bars ── */
@keyframes eq-bar {
    0%, 100% { height: 4px; }
    25% { height: 14px; }
    50% { height: 8px; }
    75% { height: 18px; }
}
.eq-bar {
    width: 3px;
    border-radius: 2px;
    background: #3de96f;
    animation: eq-bar 0.8s ease-in-out infinite;
}

/* ── Progress Bar ── */
.player-progress {
    position: relative;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
}
.player-progress-fill {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #3de96f, #38bdf8);
    border-radius: 2px;
    transition: width 0.3s linear;
}

/* ── Volume Slider ── */
.volume-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 60px;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    outline: none;
    cursor: pointer;
    transition: background 0.3s;
}
.volume-slider:hover {
    background: rgba(255, 255, 255, 0.2);
}
.volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #3de96f;
    cursor: pointer;
    box-shadow: 0 0 6px rgba(61, 233, 111, 0.5);
    transition: transform 0.2s;
}
.volume-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}
.volume-slider::-moz-range-thumb {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #3de96f;
    cursor: pointer;
    border: none;
    box-shadow: 0 0 6px rgba(61, 233, 111, 0.5);
    transition: transform 0.2s;
}
.volume-slider::-moz-range-thumb:hover {
    transform: scale(1.2);
}

/* ══════════════════════════════════════════════════════
   FULL-SCREEN MOBILE NAV OVERLAY
   ══════════════════════════════════════════════════════ */
#mobile-nav-overlay {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: rgba(15, 19, 31, 0.95);
    backdrop-filter: blur(40px);
    -webkit-backdrop-filter: blur(40px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}
#mobile-nav-overlay.open {
    opacity: 1;
    pointer-events: all;
}
#mobile-nav-overlay a {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 0.2s ease;
}
#mobile-nav-overlay.open a {
    opacity: 1;
    transform: translateY(0);
}
#mobile-nav-overlay.open a:nth-child(1) { transition-delay: 0.1s; }
#mobile-nav-overlay.open a:nth-child(2) { transition-delay: 0.18s; }
#mobile-nav-overlay.open a:nth-child(3) { transition-delay: 0.26s; }
#mobile-nav-overlay.open a:nth-child(4) { transition-delay: 0.34s; }

#mobile-nav-overlay .holo-border {
    position: absolute;
    inset: 20px;
    border: 1px solid rgba(61, 233, 111, 0.15);
    border-radius: 24px;
    pointer-events: none;
}
#mobile-nav-overlay .holo-corner {
    position: absolute;
    width: 20px;
    height: 20px;
    border-color: #3de96f;
    border-style: solid;
    border-width: 0;
}
#mobile-nav-overlay .holo-corner.tl { top: 16px; left: 16px; border-top-width: 2px; border-left-width: 2px; border-top-left-radius: 8px; }
#mobile-nav-overlay .holo-corner.tr { top: 16px; right: 16px; border-top-width: 2px; border-right-width: 2px; border-top-right-radius: 8px; }
#mobile-nav-overlay .holo-corner.bl { bottom: 16px; left: 16px; border-bottom-width: 2px; border-left-width: 2px; border-bottom-left-radius: 8px; }
#mobile-nav-overlay .holo-corner.br { bottom: 16px; right: 16px; border-bottom-width: 2px; border-right-width: 2px; border-bottom-right-radius: 8px; }

/* ══════════════════════════════════════════════════════
   LYRICS STREAM — Vaporwave / Cyberpunk Aesthetic
   ══════════════════════════════════════════════════════ */
#lyrics-stream-container {
    position: relative;
    width: 100%;
    height: 420px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    border-radius: 24px;
    background: rgba(15, 19, 31, 0.5);
    border: 1px solid rgba(61, 233, 111, 0.06);
    /* Mask: fade top & bottom edges for seamless stream illusion */
    -webkit-mask-image: linear-gradient(
        to bottom,
        transparent 0%,
        black 12%,
        black 88%,
        transparent 100%
    );
    mask-image: linear-gradient(
        to bottom,
        transparent 0%,
        black 12%,
        black 88%,
        transparent 100%
    );
}

/* Track info badge at top */
.lyrics-track-info {
    position: absolute;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 5;
    font-family: 'Space Grotesk', monospace;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    color: rgba(61, 233, 111, 0.35);
    white-space: nowrap;
    padding: 6px 16px;
    border-radius: 20px;
    background: rgba(61, 233, 111, 0.04);
    border: 1px solid rgba(61, 233, 111, 0.08);
}

/* Lyrics text wrapper — animated upward stream */
#lyrics-text-wrapper {
    position: absolute;
    width: 100%;
    padding: 0 32px;
    box-sizing: border-box;
}

/* The lyrics text block */
.lyrics-text {
    font-family: 'Space Grotesk', monospace;
    font-size: 16px;
    line-height: 2.6;
    letter-spacing: 0.06em;
    color: rgba(61, 233, 111, 0.55);
    white-space: pre-wrap;
    text-align: center;
    text-shadow:
        0 0 10px rgba(61, 233, 111, 0.4),
        0 0 30px rgba(61, 233, 111, 0.2);
    user-select: none;
    pointer-events: none;
}

/* Upward streaming animation — bottom to top */
@keyframes streamUp {
    0% {
        transform: translateY(0);
    }
    100% {
        transform: translateY(-100%);
    }
}

#lyrics-text-wrapper.streaming {
    animation: streamUp var(--stream-duration, 45s) linear infinite;
}

/* Subtle scanline overlay for CRT / cyberpunk flavor */
#lyrics-stream-container::after {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(
        0deg,
        transparent,
        transparent 2px,
        rgba(61, 233, 111, 0.008) 2px,
        rgba(61, 233, 111, 0.008) 4px
    );
    pointer-events: none;
    z-index: 3;
}

/* Responsive height adjustments */
@media (max-width: 768px) {
    #lyrics-stream-container {
        height: 320px;
    }
    .lyrics-text {
        font-size: 13px;
        line-height: 2.4;
    }
}




/* ══════════════════════════════════════════════════════
   SKIP-TO-CONTENT (A11y)
   ══════════════════════════════════════════════════════ */
.skip-link {
    position: absolute;
    top: -100%;
    left: 16px;
    z-index: 999;
    padding: 12px 24px;
    background: #3de96f;
    color: #0f131f;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 700;
    border-radius: 0 0 12px 12px;
    transition: top 0.3s ease;
}
.skip-link:focus {
    top: 0;
}

/* ══════════════════════════════════════════════════════
   SCROLLBAR
   ══════════════════════════════════════════════════════ */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: #0f131f; }
::-webkit-scrollbar-thumb { background: #1b1f2c; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #3de96f; }

/* ══════════════════════════════════════════════════════
   SKELETON SHIMMER (Synthesis Loading)
   ══════════════════════════════════════════════════════ */
@keyframes skeleton-shimmer {
    0% { background-position: -400px 0; }
    100% { background-position: 400px 0; }
}
.skeleton-shimmer {
    background: linear-gradient(
        90deg,
        rgba(27, 31, 44, 0.6) 0%,
        rgba(61, 233, 111, 0.06) 40%,
        rgba(27, 31, 44, 0.6) 80%
    );
    background-size: 800px 100%;
    animation: skeleton-shimmer 1.8s ease-in-out infinite;
}

/* ══════════════════════════════════════════════════════
   SYNTHESIS CAROUSEL
   ══════════════════════════════════════════════════════ */
.synthesis-carousel {
    display: flex;
    gap: 24px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
    padding: 0 24px 20px 24px;
    scroll-padding-left: 24px;
}

/* Edge-to-edge padding on larger screens */
@media (min-width: 768px) {
    .synthesis-carousel {
        padding: 0 calc((100vw - 1440px) / 2 + 24px) 20px;
        padding-left: max(24px, calc((100vw - 1440px) / 2 + 24px));
        padding-right: 48px;
        scroll-padding-left: max(24px, calc((100vw - 1440px) / 2 + 24px));
    }
}

/* Skeleton cards inside carousel */
.synthesis-carousel .synthesis-skeleton {
    min-width: 300px;
    flex-shrink: 0;
    scroll-snap-align: start;
}

/* Custom horizontal scrollbar — cyber-minimalist */
.synthesis-carousel::-webkit-scrollbar {
    height: 4px;
}
.synthesis-carousel::-webkit-scrollbar-track {
    background: rgba(27, 31, 44, 0.4);
    border-radius: 2px;
    margin: 0 24px;
}
.synthesis-carousel::-webkit-scrollbar-thumb {
    background: rgba(61, 233, 111, 0.25);
    border-radius: 2px;
    transition: background 0.3s ease;
}
.synthesis-carousel::-webkit-scrollbar-thumb:hover {
    background: rgba(61, 233, 111, 0.6);
}
/* Firefox scrollbar */
.synthesis-carousel {
    scrollbar-width: thin;
    scrollbar-color: rgba(61, 233, 111, 0.25) rgba(27, 31, 44, 0.4);
}

/* ══════════════════════════════════════════════════════
   SYNTHESIS VIDEO CARDS
   ══════════════════════════════════════════════════════ */
.synthesis-card {
    min-width: 300px;
    flex-shrink: 0;
    scroll-snap-align: start;
    opacity: 0;
    transform: translateY(24px);
    animation: synthesis-card-in 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@keyframes synthesis-card-in {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.synthesis-card:nth-child(1)  { animation-delay: 0.05s; }
.synthesis-card:nth-child(2)  { animation-delay: 0.08s; }
.synthesis-card:nth-child(3)  { animation-delay: 0.11s; }
.synthesis-card:nth-child(4)  { animation-delay: 0.14s; }
.synthesis-card:nth-child(5)  { animation-delay: 0.17s; }
.synthesis-card:nth-child(6)  { animation-delay: 0.20s; }
.synthesis-card:nth-child(7)  { animation-delay: 0.23s; }
.synthesis-card:nth-child(8)  { animation-delay: 0.26s; }
.synthesis-card:nth-child(9)  { animation-delay: 0.29s; }
.synthesis-card:nth-child(10) { animation-delay: 0.32s; }
.synthesis-card:nth-child(11) { animation-delay: 0.35s; }
.synthesis-card:nth-child(12) { animation-delay: 0.38s; }
.synthesis-card:nth-child(13) { animation-delay: 0.41s; }
.synthesis-card:nth-child(14) { animation-delay: 0.44s; }
.synthesis-card:nth-child(15) { animation-delay: 0.47s; }
.synthesis-card:nth-child(16) { animation-delay: 0.50s; }

/* Synthesis error state */
.synthesis-error {
    min-width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 48px 24px;
    text-align: center;
}
.synthesis-error .material-symbols-outlined {
    font-size: 48px;
    color: rgba(239, 68, 68, 0.6);
}
.synthesis-error p {
    color: rgba(245, 245, 255, 0.5);
    font-family: 'Space Grotesk', sans-serif;
    font-size: 14px;
}
.synthesis-error a {
    color: #3de96f;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: opacity 0.2s ease;
}
.synthesis-error a:hover {
    opacity: 0.7;
}

/* ══════════════════════════════════════════════════════
   REDUCED MOTION (A11y)
   ══════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html { scroll-behavior: auto; }
    .marquee-track { animation: none; }
    .skeleton-shimmer { animation: none; }
    .reveal-item {
        opacity: 1;
        transform: none;
    }
    .synthesis-card {
        opacity: 1;
        transform: none;
        animation: none;
    }
    .synthesis-carousel {
        scroll-snap-type: none;
    }
    #lyrics-text-wrapper.streaming {
        animation: none;
        transform: none;
    }
}
