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

html, body {
    width: 100%;
    height: 100%;
    overflow-x: hidden;
}

html {
    scrollbar-width: thin;
    scrollbar-color: rgba(229, 169, 79, 0.5) #0E0A07;
}

body {
    font-family: 'Poppins', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #0A0705; /* Darker, richer black */
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    color: #fff;
}

/* Ambient Background */
.ambient-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    overflow: hidden;
    z-index: -1;
    pointer-events: none;
}

.ambient-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    opacity: 0.12;
    /* Phase 5: static ambient glow — the perpetual drift was visual noise. */
}

.orb-a {
    width: 600px;
    height: 600px;
    background: #C57D2E;
    top: -10%;
    left: -10%;
}

.orb-b {
    width: 500px;
    height: 500px;
    background: #5BB89C;
    bottom: -10%;
    right: -10%;
    animation-delay: -5s;
}

@keyframes floatAmbient {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(30px, 30px); }
}

body::-webkit-scrollbar {
    width: 12px;
}

body::-webkit-scrollbar-track {
    background: #0E0A07;
}

body::-webkit-scrollbar-thumb {
    background: rgba(229, 169, 79, 0.5);
    border-radius: 6px;
}

body::-webkit-scrollbar-thumb:hover {
    background: rgba(229, 169, 79, 0.7);
}


@keyframes spin {
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes spinLoader {
    to { transform: rotate(360deg); }
}

/* Startup playback language choice */
.language-start-overlay {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(5, 3, 2, 0.88);
    backdrop-filter: blur(18px);
}

.language-start-overlay.is-hidden {
    display: none;
}

.language-start-dialog {
    width: min(720px, 100%);
    border: 1px solid rgba(240, 187, 104, 0.28);
    border-radius: 8px;
    background: rgba(14, 10, 7, 0.96);
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.55);
    padding: 24px;
}

.language-start-kicker {
    color: var(--accent-hover, #F0BB68);
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.language-start-title {
    color: #fff;
    font-size: 28px;
    line-height: 1.15;
    margin: 0 0 8px;
}

.language-start-copy {
    color: rgba(255, 255, 255, 0.68);
    font-size: 14px;
    line-height: 1.5;
    margin: 0 0 20px;
}

.language-start-options {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.language-start-option {
    min-height: 132px;
    border: 1px solid rgba(255, 255, 255, 0.11);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.045);
    color: #fff;
    text-align: left;
    padding: 14px;
    cursor: pointer;
    transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.language-start-option:hover {
    transform: translateY(-2px);
    border-color: rgba(240, 187, 104, 0.5);
    background: rgba(240, 187, 104, 0.1);
}

.language-start-option strong {
    display: block;
    font-size: 15px;
    margin-bottom: 8px;
}

.language-start-option span {
    display: block;
    color: rgba(255, 255, 255, 0.64);
    font-size: 12px;
    line-height: 1.4;
}

@media (max-width: 720px) {
    .language-start-dialog {
        padding: 18px;
    }

    .language-start-title {
        font-size: 22px;
    }

    .language-start-options {
        grid-template-columns: 1fr;
    }

    .language-start-option {
        min-height: 96px;
    }
}
