:root {
    --color-bg: #000000;
    --color-surface: #000000;
    --color-border: #00FF00;
    --color-text: #FFFFFF;
    --color-blue: #0000FF;
    --color-orange: #FF6600;
    --color-purple: #FF00FF;
    --color-lime: #00FF00;
    --color-cyan: #00FFFF;
    --radius: 0px;
    --note-strength: 0;
    --banner-height: 56px;
    --btn-border: rgba(0, 255, 222, 0.45);
    --btn-bg: rgba(3, 6, 18, 0.75);
    --btn-bg-alt: rgba(255, 107, 214, 0.25);
    --btn-text: rgba(255, 255, 255, 0.92);
    font-family: "Comic Sans MS", "Arial", sans-serif;
}

html {
    background-color: var(--color-bg);
    color-scheme: dark;
    overflow-x: hidden;
    margin: 0;
    padding: 0;
    height: auto;
}

.hidden {
    display: none !important;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    min-height: 0;
    height: auto;
    width: 100%;
    background: #000000;
    background-image:
        radial-gradient(circle, #ffffff 1px, transparent 1px),
        radial-gradient(circle, #ffffff 1px, transparent 1px);
    background-size: 50px 50px, 80px 80px;
    background-position: 0 0, 40px 40px;
    background-attachment: fixed;
    color: var(--color-text);
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    overflow-x: hidden;
    overflow-y: auto;
    justify-content: flex-start;
    -ms-overflow-style: none;
    scrollbar-width: none;
}

body::-webkit-scrollbar {
    display: none;
}

/* Hide all scrollbars globally while keeping scroll functionality */
* {
    scrollbar-width: none !important; /* Firefox */
    -ms-overflow-style: none !important; /* IE and Edge */
}

*::-webkit-scrollbar {
    display: none !important; /* Chrome, Safari, Opera */
    width: 0 !important;
    height: 0 !important;
}

*::-webkit-scrollbar-track {
    display: none !important;
}

*::-webkit-scrollbar-thumb {
    display: none !important;
}

html::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
}

html {
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
}

body::before {
    content: "";
    position: fixed;
    top: 0;
    --banner-height: 54px;
    left: 0;
    right: 0;
    height: 4px;
    z-index: 1000;
    pointer-events: none;
    background: linear-gradient(90deg,
        #FF00FF 0%,
        #FF6600 25%,
        #00FFFF 50%,
        #00FF00 75%,
        #FF00FF 100%);
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.8);
    animation: bar-glow 3s ease-in-out infinite;
    transform: translateZ(0);
}

.site-landing-banner {
    width: 100%;
    max-width: 100%;
    align-self: stretch;
    background: rgba(7, 8, 20, 0.9);
    backdrop-filter: blur(8px);
    padding: 12px 20px;
    text-align: center;
    position: sticky;
    top: 0;
    z-index: 1200;
    border-bottom: 1px solid rgba(232, 180, 184, 0.35);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.45);
    flex-shrink: 0;
}

.site-landing-banner a {
    color: #F9F6F2;
    font-family: "Manrope", sans-serif;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    text-decoration: none;
}

.site-landing-banner a:hover,
.site-landing-banner a:focus-visible {
    color: #FFBED8;
}

@keyframes bar-glow {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 0 20px rgba(255, 0, 255, 0.8);
    }
    50% {
        opacity: 0.85;
        box-shadow: 0 0 30px rgba(255, 0, 255, 1);
    }
}

.page {
    width: 100%;
    position: relative;
    overflow-x: hidden;
    z-index: 1;
}

.music-field {
    position: fixed;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: 0;
}

.music-field .music {
    width: 110px;
    height: 140px;
    position: absolute;
    top: 100%;
    opacity: 0;
    --note-color: rgba(232, 180, 184, 0.35);
    --note-ring-color: rgba(255, 255, 255, 0.22);
    --note-bar-color: rgba(232, 180, 184, 0.24);
    --note-glow: rgba(232, 180, 184, 0.12);
    animation: orbit-notes 18s ease-in-out infinite;
    filter: drop-shadow(0 0 calc(2px + 26px * var(--note-strength)) var(--note-color));
    mix-blend-mode: screen;
    transition: filter 0.6s ease;
}

.music-field .music.track.two {
    animation-delay: 3s;
}

.music-field .music.track.three {
    animation-delay: 6s;
}

.music-field .music.track.four {
    animation-delay: 9s;
    animation-duration: 22s;
    --note-color: rgba(138, 193, 255, 0.4);
    --note-ring-color: rgba(138, 193, 255, 0.3);
    --note-bar-color: rgba(138, 193, 255, 0.26);
    --note-glow: rgba(138, 193, 255, 0.16);
}

.music-field .music.track.five {
    animation-delay: 13s;
    animation-duration: 24s;
    --note-color: rgba(255, 208, 154, 0.35);
    --note-ring-color: rgba(255, 208, 154, 0.32);
    --note-bar-color: rgba(255, 208, 154, 0.24);
    --note-glow: rgba(255, 208, 154, 0.15);
}

.music-field .music.track.six {
    animation-delay: 17s;
    animation-duration: 26s;
    --note-color: rgba(160, 255, 238, 0.32);
    --note-ring-color: rgba(160, 255, 238, 0.4);
    --note-bar-color: rgba(160, 255, 238, 0.26);
    --note-glow: rgba(160, 255, 238, 0.16);
    --note-strength: 0.35;
}

.music-field .music.track.seven {
    animation-delay: 21s;
    animation-duration: 28s;
    --note-color: rgba(255, 160, 210, 0.38);
    --note-ring-color: rgba(255, 160, 210, 0.34);
    --note-bar-color: rgba(255, 160, 210, 0.28);
    --note-glow: rgba(255, 160, 210, 0.18);
    --note-strength: 0.42;
}

.music-field .music.track.eight {
    animation-delay: 25s;
    animation-duration: 30s;
    --note-color: rgba(154, 181, 255, 0.36);
    --note-ring-color: rgba(154, 181, 255, 0.36);
    --note-bar-color: rgba(154, 181, 255, 0.28);
    --note-glow: rgba(154, 181, 255, 0.18);
    --note-strength: 0.45;
}


.music-field .music span {
    position: absolute;
    display: block;
    border: 2px solid var(--note-ring-color);
    background: transparent;
    border-radius: 50%;
    transition: border-color 0.4s ease, background-color 0.4s ease, box-shadow 0.4s ease;
    box-shadow: 0 0 16px rgba(232, 180, 184, 0.08);
}

.music-field .music span:nth-child(1),
.music-field .music span:nth-child(2) {
    width: 32px;
    height: 32px;
    bottom: 0;
}

.music-field .music span:nth-child(2) {
    right: 0;
    bottom: 22px;
}

.music-field .music span:nth-child(3),
.music-field .music span:nth-child(4) {
    width: 12px;
    border-radius: 6px;
    background: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0.04));
    border: none;
    left: 22px;
    bottom: 14px;
    height: 92px;
}

.music-field .music span:nth-child(4) {
    right: 2px;
    left: auto;
    height: 104px;
    bottom: 36px;
}

.music-field .music span:nth-child(5) {
    width: 82px;
    height: 20px;
    top: 16px;
    left: 18px;
    transform: rotate(-24deg);
    border-radius: 12px;
    border-width: 2px;
}

body.playing-canon .music-field .music span,
body.playing-jukebox .music-field .music span {
    border-color: var(--note-ring-color, rgba(232, 180, 184, 0.58));
    box-shadow: 0 0 22px var(--note-color, rgba(232, 180, 184, 0.18));
}

body.playing-canon .music-field .music span:nth-child(3),
body.playing-canon .music-field .music span:nth-child(4),
body.playing-canon .music-field .music span:nth-child(5),
body.playing-jukebox .music-field .music span:nth-child(3),
body.playing-jukebox .music-field .music span:nth-child(4),
body.playing-jukebox .music-field .music span:nth-child(5) {
    background: linear-gradient(180deg, var(--note-bar-color, rgba(232, 180, 184, 0.28)), rgba(0, 0, 0, 0.02));
}

.music-field .music::after {
    content: "";
    position: absolute;
    inset: -80px;
    background: radial-gradient(circle, var(--note-glow), transparent 60%);
    opacity: 0.12;
    transform: scale(0.92);
    filter: blur(14px);
    pointer-events: none;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

@keyframes noteGlowPulse {
    0% {
        box-shadow: 0 0 14px rgba(232, 180, 184, 0.1);
    }
    50% {
        box-shadow: 0 0 26px rgba(232, 180, 184, 0.26);
    }
    100% {
        box-shadow: 0 0 14px rgba(232, 180, 184, 0.12);
    }
}

.state-player .music-field .music::after {
    opacity: 0.32;
    transform: scale(1);
    animation: sweepGlow 8s ease-in-out infinite alternate;
}

.state-player .music-field .music span {
    animation: noteGlowPulse 6s ease-in-out infinite alternate;
}

@keyframes orbit-notes {
    0% {
        transform: rotate(12deg);
        top: 102%;
        left: 6%;
        opacity: 0;
    }
    10% {
        opacity: 0.18;
    }
    25% {
        transform: rotate(-8deg);
        top: -6%;
        left: 14%;
        opacity: 0.32;
    }
    50% {
        transform: rotate(6deg);
        top: -6%;
        left: 86%;
        opacity: 0.36;
    }
    75% {
        transform: rotate(-10deg);
        top: 102%;
        left: 94%;
        opacity: 0.26;
    }
    100% {
        transform: rotate(12deg);
        top: 102%;
        left: 6%;
        opacity: 0;
    }
}

@keyframes sweepGlow {
    0% {
        transform: scale(1) translateY(0);
        opacity: 0.18;
    }
    50% {
        transform: scale(1.04) translateY(-6px);
        opacity: 0.28;
    }
    100% {
        transform: scale(1) translateY(0);
        opacity: 0.18;
    }
}

.page-shell {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: clamp(12px, 2.4vw, 24px) clamp(18px, 3.5vw, 40px);
    display: grid;
    grid-template-columns: minmax(300px, 1fr) minmax(580px, 1fr);
    gap: clamp(12px, 2vw, 24px);
    align-items: start;
    justify-items: stretch;
}

.state-home .page-shell {
    padding-bottom: 20px;
}

.state-player .page-shell {
    padding-top: clamp(10px, 1.6vw, 20px);
    padding-bottom: clamp(6px, 1.4vw, 16px);
    gap: clamp(18px, 2.6vw, 30px);
}

.hero {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: clamp(20px, 4vw, 60px);
    align-items: start;
    padding: 0 clamp(20px, 3vw, 40px);
    margin-top: clamp(8px, 1.5vw, 16px);
    margin-bottom: clamp(4px, 1vw, 8px);
    width: 100%;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 900px) {
    .hero {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

.state-player .hero {
    margin-top: clamp(4px, 1.2vw, 12px);
}

.back-button {
    position: fixed;
    top: calc(var(--banner-height, 0px) + clamp(12px, 1.5vw, 22px));
    left: clamp(18px, 2.6vw, 34px);
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 16px;
    border-radius: 0;
    border: 3px solid var(--color-purple);
    background: #000000;
    color: var(--color-purple);
    text-decoration: none;
    font-size: 0.75rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    transition: all 0.2s ease;
    z-index: 6;
}

.back-button span[aria-hidden="true"] {
    font-size: 1.1rem;
    line-height: 1;
}

.back-button.hidden {
    display: none;
}

.back-button:hover {
    background: var(--color-purple);
    color: #000000;
}

.form-actions {
    margin-top: 18px;
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.form-actions .cta {
    flex: 0 1 220px;
    margin-top: 0;
    --banner-height: 54px;
    text-align: center;
    align-self: stretch;
    width: min(220px, 100%);
}

.drive-helper-hint {
    margin: 10px 0 0;
    font-size: 0.8rem;
    color: var(--color-muted);
}

.drive-helper-hint a {
    color: var(--color-accent);
    font-weight: 600;
    text-decoration: none;
}

.drive-helper-hint a:hover {
    text-decoration: underline;
}

.site-logo {
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 600;
    font-size: 0.78rem;
    background: rgba(232, 180, 184, 0.22);
    border: 1px solid rgba(232, 180, 184, 0.22);
    color: var(--color-text);
    box-shadow: none;
}

.state-player .site-logo {
    display: none !important;
}

.hero-meta {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: flex-start;
    text-align: left;
}

.badge {
    align-self: flex-start;
    padding: 6px 16px;
    border-radius: 999px;
    border: 1px solid rgba(232, 180, 184, 0.36);
    background: rgba(232, 180, 184, 0.1);
    color: rgba(232, 180, 184, 0.82);
    letter-spacing: 0.24em;
    text-transform: uppercase;
}

.corner-cluster {
    position: fixed;
    bottom: clamp(20px, 2.8vw, 32px);
    left: clamp(20px, 2.8vw, 36px);
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
    z-index: 5;
    background: rgba(0, 0, 0, 0.95);
    padding: 8px 12px;
    border-top: 4px solid #FF00FF;
    border-right: 3px solid var(--color-purple);
    border-bottom: 3px solid var(--color-purple);
    border-left: 4px solid #FF00FF;
    box-shadow: 0 -2px 15px rgba(255, 0, 255, 0.6), -2px 0 15px rgba(255, 0, 255, 0.6);
    pointer-events: auto;
}

.state-home .corner-cluster,
.state-player .corner-cluster {
    max-width: 240px;
}

.cluster-separator {
    color: var(--color-purple);
    font-size: 1rem;
    opacity: 0.5;
    margin: 0 4px;
}

.ascii-corner-art {
    font-family: monospace;
    font-size: 0.7rem;
    line-height: 1.2;
    color: var(--color-lime);
    white-space: pre;
    margin: 0;
    animation: corner-pulse 3s ease-in-out infinite;
}

.ascii-corner-art-right {
    font-family: monospace;
    font-size: 0.7rem;
    line-height: 1.2;
    color: var(--color-cyan);
    white-space: pre;
    margin: 0;
    animation: corner-pulse 3s ease-in-out infinite;
    animation-delay: 1.5s;
}

@keyframes corner-pulse {
    0%, 100% {
        opacity: 0.7;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.05);
    }
}

.bottom-badge {
    color: var(--color-purple);
    letter-spacing: 0.12em;
    font-size: 0.7rem;
    font-weight: 700;
    transition: all 0.2s ease;
    padding: 0;
    border-radius: 0;
    background: transparent;
    border: 0;
    white-space: nowrap;
}

.bottom-badge:hover {
    color: var(--color-orange);
}

.hero h1 {
    margin: 0;
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    white-space: nowrap;
    color: var(--color-cyan);
    text-shadow: 0 0 20px var(--color-cyan), 0 0 40px var(--color-cyan);
    animation: title-pulse 3s ease-in-out infinite;
}

@keyframes title-pulse {
    0%, 100% {
        text-shadow: 0 0 20px var(--color-cyan), 0 0 40px var(--color-cyan);
    }
    50% {
        text-shadow: 0 0 30px var(--color-cyan), 0 0 60px var(--color-cyan), 0 0 80px var(--color-cyan);
    }
}

.hero p {
    margin: 0;
    color: var(--color-text);
    font-size: clamp(0.9rem, 1.8vw, 1.04rem);
    line-height: 1.6;
}

.hero-eyebrow {
    color: var(--color-lime);
    font-size: 1rem;
    font-weight: bold;
    letter-spacing: 0.1em;
    margin: 0;
    text-shadow: 0 0 10px var(--color-lime);
}

.hero-lede {
    color: var(--color-orange);
    line-height: 1.7;
    font-weight: 600;
    font-size: clamp(1rem, 2vw, 1.15rem);
    letter-spacing: 0.05em;
}

.hero-callouts-row {
    display: flex;
    flex-direction: row;
    gap: 20px;
    align-items: flex-start;
    margin: 16px 0;
}

.hero-callouts {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: flex-start;
    flex: 1;
}

.ascii-dancer-side {
    font-family: monospace;
    font-size: 1rem;
    line-height: 1.2;
    color: var(--color-cyan);
    white-space: pre;
    margin: 0;
    text-shadow: 0 0 8px var(--color-cyan);
    animation: side-bounce 2.5s ease-in-out infinite;
}

.ascii-dancer-cluster {
    display: flex;
    flex-direction: row;
    gap: clamp(14px, 1.8vw, 28px);
    margin-left: clamp(14px, 2vw, 24px);
    align-items: flex-start;
}

.ascii-dancer-side--pink {
    color: #ff6bd6;
    text-shadow: 0 0 8px rgba(255, 107, 214, 0.8);
    animation-delay: 1s;
}

@keyframes side-bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-8px);
    }
}

.hero-callouts li {
    color: var(--color-cyan);
    font-size: 1rem;
    letter-spacing: 0.05em;
}

.hero-callouts strong {
    color: var(--color-purple);
    font-weight: bold;
    text-shadow: 0 0 8px var(--color-purple);
}

.ascii-art {
    font-family: monospace;
    font-size: 0.9rem;
    line-height: 1.2;
    color: var(--color-cyan);
    margin: 16px 0;
    padding: 12px;
    background: transparent;
    border: 2px solid var(--color-cyan);
    white-space: pre;
    overflow-x: auto;
}

.ascii-woman {
    grid-area: 1 / 1;
    justify-self: center;
    align-self: center;
    font-family: monospace;
    font-size: 1.5rem;
    line-height: 1.2;
    color: var(--color-orange);
    white-space: pre;
    z-index: 5;
    text-shadow: 0 0 10px var(--color-orange);
    animation: woman-dance 2s ease-in-out infinite;
}

@keyframes woman-dance {
    0%, 100% {
        transform: rotate(0deg);
    }
    25% {
        transform: rotate(-3deg);
    }
    75% {
        transform: rotate(3deg);
    }
}

.ascii-left-dancer {
    grid-area: 1 / 1;
    justify-self: start;
    align-self: center;
    margin-left: 20px;
    font-family: monospace;
    font-size: 1.2rem;
    line-height: 1.2;
    color: var(--color-cyan);
    white-space: pre;
    z-index: 5;
    animation: left-bounce 2.5s ease-in-out infinite;
}

@keyframes left-bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

.ascii-right-notes {
    grid-area: 1 / 1;
    justify-self: end;
    align-self: start;
    margin-right: 20px;
    margin-top: 40px;
    font-family: monospace;
    font-size: 1rem;
    line-height: 1.5;
    color: var(--color-purple);
    white-space: pre;
    z-index: 5;
    animation: notes-float 3s ease-in-out infinite;
}

@keyframes notes-float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
        opacity: 0.8;
    }
    50% {
        transform: translateY(-15px) rotate(5deg);
        opacity: 1;
    }
}

.ascii-bottom-dancer {
    grid-area: 1 / 1;
    justify-self: center;
    align-self: end;
    margin-bottom: 40px;
    font-family: monospace;
    font-size: 0.9rem;
    line-height: 1.2;
    color: var(--color-lime);
    white-space: pre;
    z-index: 5;
    opacity: 0.7;
    animation: bottom-sway 3s ease-in-out infinite;
}

@keyframes bottom-sway {
    0%, 100% {
        transform: rotate(-2deg);
    }
    50% {
        transform: rotate(2deg);
    }
}

.ascii-background {
    grid-area: 1 / 1;
    justify-self: center;
    align-self: center;
    font-family: monospace;
    font-size: 1.2rem;
    line-height: 1.5;
    color: var(--color-purple);
    opacity: 0.3;
    white-space: pre;
    pointer-events: none;
    z-index: 0;
}

.ascii-divider {
    font-family: monospace;
    font-size: 0.6rem;
    line-height: 1;
    color: var(--color-blue);
    margin: 16px 0;
    white-space: pre;
    overflow-x: hidden;
    text-align: center;
}

.retro-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 20px;
}

.retro-badge {
    display: inline-block;
    padding: 6px 14px;
    background: #000000;
    border: 3px solid var(--color-purple);
    color: var(--color-purple);
    font-size: 0.7rem;
    font-weight: bold;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    text-shadow: 0 0 10px var(--color-purple);
    animation: badge-glow 2s ease-in-out infinite;
}

.retro-badge:nth-child(2) {
    border-color: var(--color-orange);
    color: var(--color-orange);
    text-shadow: 0 0 10px var(--color-orange);
    animation-delay: 0.7s;
}

.retro-badge:nth-child(3) {
    border-color: var(--color-cyan);
    color: var(--color-cyan);
    text-shadow: 0 0 10px var(--color-cyan);
    animation-delay: 1.4s;
}

@keyframes badge-glow {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.85;
        transform: scale(1.05);
    }
}

.visitor-counter {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: #000000;
    border: 3px solid var(--color-purple);
    margin-bottom: 16px;
    font-family: monospace;
}

.counter-label {
    color: var(--color-purple);
    font-size: 0.7rem;
    font-weight: bold;
    letter-spacing: 0.1em;
}

.counter-numbers {
    color: var(--color-orange);
    font-size: 1rem;
    font-weight: bold;
    background: #000000;
    padding: 2px 8px;
    border: 2px solid var(--color-orange);
    letter-spacing: 0.2em;
    animation: counter-flicker 4s ease-in-out infinite;
}

@keyframes counter-flicker {
    0%, 96%, 100% {
        opacity: 1;
    }
    97%, 99% {
        opacity: 0.7;
    }
    98% {
        opacity: 1;
    }
}

.hero-visual {
    position: relative;
    width: 100%;
    min-height: 200px;
    display: grid;
    place-items: center;
    padding: 20px;
    overflow: visible;
}

.hero-orbit {
    grid-area: 1 / 1;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
}

.hero-ring {
    position: absolute;
    border-radius: 50%;
    border: 3px solid var(--color-purple);
    animation: ring-rotate 20s linear infinite;
}

.ring-base {
    width: 85%;
    height: 85%;
    border-color: var(--color-cyan);
}

.ring-highlight {
    width: 100%;
    height: 100%;
    animation-duration: 30s;
    animation-direction: reverse;
}

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

.hero-node {
    position: absolute;
    width: 16px;
    height: 16px;
    background: var(--color-purple);
    border: 2px solid var(--color-purple);
    border-radius: 50%;
    animation: node-pulse 3s ease-in-out infinite;
}

.node-primary {
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
}

.node-secondary {
    bottom: 10%;
    left: 50%;
    transform: translateX(-50%);
    animation-delay: 1.5s;
}

@keyframes node-pulse {
    0%, 100% {
        opacity: 1;
        transform: translateX(-50%) scale(1);
    }
    50% {
        opacity: 0.6;
        transform: translateX(-50%) scale(1.2);
    }
}

.ascii-lounge {
    margin: clamp(24px, 4vw, 48px) auto;
    width: min(920px, 100%);
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: clamp(12px, 2vw, 20px);
}

.ascii-card {
    border-radius: 18px;
    background: rgba(15, 8, 24, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: clamp(16px, 3vw, 22px);
    box-shadow: 0 10px 30px rgba(7, 0, 12, 0.4);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ascii-label {
    margin: 0;
    font-size: 0.82rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.72);
}

.ascii-card pre {
    margin: 0;
    font-family: "IBM Plex Mono", "Fira Code", "SFMono-Regular", Menlo, Consolas, monospace;
    font-size: 0.78rem;
    line-height: 1.3;
    color: rgba(255, 255, 255, 0.9);
    white-space: pre;
    overflow-x: auto;
}


.state-player .layout {
    grid-column: 1 / -1;
    grid-template-columns: minmax(0, 1fr);
    gap: clamp(20px, 3vw, 36px);
    justify-items: stretch;
    margin-top: -6px;
}

.intake-panel {
    justify-self: stretch;
    max-width: 100%;
    width: 100%;
}

.viz-panel {
    justify-self: stretch;
    width: 100%;
    min-width: 0;
}

.state-player .viz-panel {
    grid-column: 1;
    justify-self: center;
}

.state-player .intake-panel {
    grid-column: 1;
    justify-self: flex-start;
}

.state-home .layout {
    justify-items: end;
}

.cta {
    align-self: flex-start;
    margin-top: 10px;
    padding: 10px 20px;
    border-radius: 0;
    border: 3px solid #00FFDE;
    background: #000000;
    color: #00FFDE;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: none;
    font-size: 0.75rem;
}

.cta:hover {
    background: #00FFDE;
    color: #000000;
}

.cta.ghost {
    background: #000000;
    border: 3px solid #FF00FF;
    color: #FF00FF;
}

.cta.ghost:hover {
    background: #FF00FF;
    color: #000000;
}

.form-actions {
    margin-top: 18px;
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.layout {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr;
    gap: clamp(20px, 3vw, 36px);
    margin-top: 0;
    --banner-height: 54px;
    align-items: start;
    justify-items: stretch;
}

.state-player .layout {
    grid-column: 1 / -1;
    grid-template-columns: minmax(0, 1fr);
    gap: clamp(26px, 3.8vw, 44px);
    justify-items: center;
}

.intake-panel {
    justify-self: stretch;
    max-width: 100%;
    width: 100%;
}

.viz-panel {
    justify-self: stretch;
    width: 100%;
    min-width: 0;
}

.state-player .viz-panel {
    grid-column: 1;
    justify-self: center;
}

.state-player .intake-panel {
    grid-column: 1;
    justify-self: flex-start;
}

.viz-panel {
    transition: transform 0.5s ease, box-shadow 0.5s ease, opacity 0.45s ease, max-height 0.6s ease;
    transform-origin: top center;
    transform: scale(0.96);
    opacity: 0;
    max-height: 0;
    overflow: hidden;
}

.state-home .viz-panel {
    pointer-events: none;
    display: none;
}

.state-player .viz-panel {
    transform: scale(1);
    opacity: 1;
    max-height: 980px;
    box-shadow: 0 24px 64px rgba(232, 180, 184, 0.2), inset 0 0 46px rgba(232, 180, 184, 0.16);
}

.state-home .layout {
    justify-items: end;
}

.panel {
    position: relative;
    border-radius: 0;
    border: 3px solid var(--color-lime);
    background: #000000;
    box-shadow: none;
    padding: clamp(18px, 3vw, 28px);
    backdrop-filter: none;
    display: flex;
    flex-direction: column;
    gap: 18px;
    min-height: auto;
}

.panel h2 {
    margin: 0;
    font-size: 1.28rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--color-lime);
}

.section-title {
    text-transform: uppercase;
    font-size: 0.7rem;
    letter-spacing: 0.16em;
    color: var(--color-cyan);
    margin-bottom: 8px;
}


.toggle-group {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 0;
    border-radius: 0;
    background: transparent;
    border: 0;
    margin-bottom: 22px;
}

.toggle {
    flex: 1 1 190px;
    min-width: 170px;
    padding: 12px 20px;
    background: #000000;
    color: #00FFDE;
    border: 3px solid #00FFDE;
    border-radius: 0;
    text-transform: uppercase;
    letter-spacing: 0.16em;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
    line-height: 1.2;
    white-space: normal;
    box-shadow: none;
    font-weight: 600;
}

.toggle:hover {
    background: #00FFDE;
    color: #000000;
}

.toggle.active {
    background: #00FFDE;
    border-color: #00FFDE;
    color: #000000;
}

.toggle:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 255, 222, 0.4);
}

.mode-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
    margin-bottom: 22px;
}

.mode-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 16px;
    background: #000000;
    border: 2px solid var(--color-purple);
    border-radius: 0;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.mode-card:hover {
    background: var(--color-purple);
    color: #000000;
}

.mode-card.active {
    background: var(--color-purple);
    border-color: var(--color-purple);
}

.mode-card.active .mode-card-body h3,
.mode-card.active .mode-card-body p,
.mode-card.active .mode-card-icon {
    color: #000000;
}

.mode-card-icon {
    font-size: 2rem;
    color: var(--color-purple);
    transition: color 0.2s ease;
}

.mode-card:hover .mode-card-icon {
    color: #000000;
}

.mode-card-body {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.mode-card-body h3 {
    margin: 0;
    font-size: 0.9rem;
    font-weight: bold;
    letter-spacing: 0.1em;
    color: var(--color-purple);
    transition: color 0.2s ease;
}

.mode-card:hover .mode-card-body h3 {
    color: #000000;
}

.mode-card-body p {
    margin: 0;
    font-size: 0.7rem;
    color: var(--color-text);
    transition: color 0.2s ease;
}

.mode-card:hover .mode-card-body p {
    color: #000000;
}

.source-pane {
    display: block;
}

.source-pane.hidden {
    display: none;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 18px;
    color: var(--color-text);
    font-size: 0.92rem;
}

.field small {
    opacity: 0.7;
    color: var(--color-cyan);
}

.field input {
    width: 100%;
    background: #000000;
    border: 2px solid var(--color-cyan);
    border-radius: 0;
    padding: 14px 16px;
    color: var(--color-text);
    font-size: 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.field input:focus {
    outline: none;
    border-color: var(--color-orange);
    box-shadow: 0 0 0 3px var(--color-orange);
}

.metadata-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 28px;
}

.status-panel {
    min-height: 28px;
    font-size: 0.95rem;
    color: rgba(232, 180, 184, 0.85);
}

.tips {
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: var(--color-muted);
    font-size: 0.88rem;
}

.tips .meta {
    font-size: 0.8rem;
    opacity: 0.72;
}

.viz-panel {
    overflow: hidden;
}

.tiles-canvas {
    margin-top: 32px;
}

.footer {
    position: fixed;
    left: clamp(14px, 2.5vw, 32px);
    bottom: clamp(12px, 2vw, 24px);
    text-align: left;
    padding: 0;
    color: rgba(232, 180, 184, 0.5);
    font-size: 0.78rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    z-index: 4;
}

.state-home #viz-panel {
    opacity: 0;
    pointer-events: none;
    transform: scale(0.95);
    padding-top: 0;
    --banner-height: 54px;
    padding-bottom: 0;
    border-width: 0;
    margin-top: 0;
    --banner-height: 54px;
    max-height: 0;
}


.state-player .intake-panel {
    opacity: 0;
    pointer-events: none;
    transform: translateY(24px);
    display: none;
}


.state-player .hero .ghost {
    opacity: 0.85;
}

.state-home .hero .ghost {
    opacity: 0.45;
}

@media (max-width: 880px) {
    .music-field .music {
        animation-duration: 20s;
    }

    .panel {
        padding: 24px;
    }

    .hero h1 {
        letter-spacing: 0.06em;
    }
}

@media (max-width: 560px) {
    .hero h1 {
        white-space: normal;
    }
}

@media (max-width: 640px) {
    .page-shell {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto;
        gap: 24px;
        margin: 0 auto;
        width: min(100%, 94vw);
    }

    .hero {
        grid-column: 1;
    }

    .layout {
        grid-column: 1;
        grid-template-columns: 1fr;
        justify-content: center;
        justify-items: stretch;
    }

    .intake-panel,
    .viz-panel {
        order: unset;
        grid-column: 1;
        justify-self: stretch;
    }

    .music-field .music {
        opacity: 0.18;
    }
}

/* OAuth Authentication Styles */
.auth-status {
    font-family: "Manrope", system-ui, sans-serif;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid rgba(232, 180, 184, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.auth-button {
    background: rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(0, 255, 222, 0.45);
    color: rgba(255, 255, 255, 0.92);
    padding: 10px 24px;
    border-radius: 999px;
    font-size: 0.82rem;
    letter-spacing: 0.12em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
    box-shadow: 0 12px 22px rgba(0, 0, 0, 0.35), inset 0 0 16px rgba(0, 255, 222, 0.12);
}

.auth-button:hover {
    background: rgba(0, 255, 222, 0.25);
    border-color: rgba(0, 255, 222, 0.6);
    transform: translateY(-1px);
}

#user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(232, 180, 184, 0.08);
    padding: 8px 16px;
    border-radius: 8px;
    border: 1px solid rgba(232, 180, 184, 0.2);
}

#user-email {
    color: var(--color-text);
    font-size: 14px;
    font-weight: 500;
}

/* Advanced Settings Button Enhancements */
.advanced-button-container {
    display: flex;
    gap: 10px;
    margin-top: 16px;
    flex-wrap: wrap;
}

.advanced-musicality-button {
    flex: 1;
    min-width: 150px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.advanced-musicality-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(199, 54, 95, 0.4);
}

.advanced-musicality-button:active {
    transform: translateY(0);
}

.advanced-reset-button {
    flex: 1;
    min-width: 150px;
}

/* ========================================
   MOBILE BREAKPOINT (Up to 480px)
   ======================================== */
@media (max-width: 480px) {
    /* CRITICAL FIX: Prevent horizontal overflow */
    html,
    body {
        overflow-x: hidden;
        width: 100%;
        box-sizing: border-box;
    }

    body {
        background-size: 30px 30px, 50px 50px;
        font-size: 14px;
    }

    .site-landing-banner {
        padding: 10px 8px;
        font-size: 11px;
    }

    .site-landing-banner a {
        font-size: 12px; /* FIXED: Increased from 10px for readability */
        letter-spacing: 0.08em;
    }

    .back-button {
        position: static;
        margin: 8px auto 12px;
        display: flex;
        width: calc(100% - 16px);
        max-width: 200px;
        padding: 12px 16px;
        font-size: 0.7rem;
        justify-content: center;
    }

    .page-shell {
        padding: 8px 8px 16px;
        grid-template-columns: 1fr;
        gap: 16px;
        max-width: 100%;
    }

    .hero {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 0 8px;
        margin-top: 0;
        margin-bottom: 12px;
        text-align: center;
    }

    .hero-meta {
        align-items: center;
        text-align: center;
    }

    .hero-eyebrow {
        font-size: 0.75rem; /* FIXED: Increased from 0.7rem for readability */
    }

    .hero h1 {
        font-size: clamp(1.4rem, 8vw, 2rem);
        letter-spacing: 0.08em;
        white-space: normal;
        line-height: 1.2;
        word-wrap: break-word;
        overflow-wrap: break-word;
    }

    .hero-lede {
        font-size: clamp(0.8rem, 3.5vw, 0.95rem);
        line-height: 1.5;
    }

    .hero-callouts-row {
        flex-direction: column;
        gap: 12px;
        margin: 12px 0;
    }

    .hero-callouts {
        gap: 8px;
        align-items: center;
    }

    .hero-callouts li {
        font-size: 0.85rem;
        text-align: left;
    }

    .ascii-dancer-cluster {
        gap: 12px;
        margin-left: 0;
        justify-content: center;
    }

    .ascii-dancer-side,
    .ascii-dancer-side--pink {
        font-size: 0.8rem;
    }

    .retro-badges {
        flex-direction: column;
        align-items: center;
        gap: 6px;
        margin-top: 16px;
    }

    .retro-badge {
        padding: 6px 12px;
        font-size: 0.75rem; /* FIXED: Increased from 0.65rem for readability */
        text-align: center;
        width: 100%;
        max-width: 280px;
    }

    .hero-visual {
        min-height: 180px;
        padding: 12px;
        overflow: hidden; /* CRITICAL FIX: Prevent overflow */
        width: 100%;
    }

    /* CRITICAL FIX: Prevent hero-ring overflow */
    .hero-ring,
    .ring-base,
    .ring-highlight {
        max-width: 90%;
        max-height: 90%;
        overflow: hidden;
    }

    .hero-orbit {
        overflow: hidden;
        max-width: 100%;
    }

    .ascii-woman {
        font-size: 1rem;
    }

    .corner-cluster {
        position: static;
        margin: 16px auto;
        max-width: calc(100% - 16px);
        flex-direction: column;
        gap: 8px;
        padding: 10px;
    }

    .ascii-corner-art,
    .ascii-corner-art-right {
        font-size: 0.75rem; /* FIXED: Increased from 0.6rem for readability */
        text-align: center;
    }

    .bottom-badge {
        font-size: 0.75rem; /* FIXED: Increased from 0.65rem for readability */
        text-align: center;
    }

    .layout {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .state-player .layout {
        gap: 20px;
    }

    .panel {
        padding: 14px 12px;
        gap: 14px;
        border-width: 2px;
    }

    .panel h2 {
        font-size: 1rem;
        letter-spacing: 0.08em;
        text-align: center;
    }

    .section-title {
        font-size: 0.75rem; /* FIXED: Increased from 0.65rem for readability */
        text-align: center;
    }

    .toggle-group {
        flex-direction: column;
        gap: 8px;
        margin-bottom: 16px;
    }

    .toggle {
        flex: 1 1 auto;
        min-width: 100%;
        padding: 14px 16px;
        font-size: 0.75rem; /* FIXED: Increased from 0.7rem for readability */
        letter-spacing: 0.1em;
        min-height: 44px; /* FIXED: Touch target */
    }

    .mode-grid {
        grid-template-columns: 1fr;
        gap: 10px;
        margin-bottom: 16px;
    }

    .mode-card {
        padding: 14px;
    }

    .mode-card-icon {
        font-size: 1.6rem;
    }

    .mode-card-body h3 {
        font-size: 0.85rem;
    }

    .mode-card-body p {
        font-size: 0.65rem;
    }

    .field {
        gap: 6px;
        margin-bottom: 14px;
        font-size: 0.85rem;
    }

    .field input {
        padding: 12px 14px;
        font-size: 0.9rem;
        border-width: 2px;
    }

    .field small {
        font-size: 0.75rem;
    }

    .form-actions {
        flex-direction: column;
        gap: 10px;
        margin-top: 14px;
    }

    .form-actions .cta {
        flex: 1 1 auto;
        width: 100%;
        max-width: 100%;
        padding: 14px 20px;
        font-size: 0.7rem;
    }

    .cta {
        padding: 12px 18px;
        font-size: 0.75rem; /* FIXED: Increased from 0.7rem for readability */
        letter-spacing: 0.12em;
        border-width: 2px;
        min-height: 44px; /* FIXED: Touch target */
    }

    /* FIXED: Ensure all buttons meet touch target requirements */
    button {
        min-height: 44px;
        font-size: 12px;
        padding: 10px 16px;
    }

    .metadata-grid {
        grid-template-columns: 1fr;
        gap: 14px;
        margin-bottom: 20px;
    }

    .status-panel {
        font-size: 0.85rem;
        text-align: center;
    }

    .tips {
        gap: 6px;
        font-size: 0.8rem;
    }

    .tips .meta {
        font-size: 0.72rem;
    }

    .viz-panel {
        padding: 12px;
    }

    .state-player .viz-panel {
        max-height: 600px;
    }

    .tiles-canvas {
        margin-top: 20px;
    }

    .footer {
        position: static;
        text-align: center;
        padding: 12px 8px;
        margin: 16px auto 0;
        font-size: 0.7rem;
    }

    .music-field .music {
        width: 80px;
        height: 100px;
        animation-duration: 16s;
    }

    .music-field .music span:nth-child(1),
    .music-field .music span:nth-child(2) {
        width: 24px;
        height: 24px;
    }

    .music-field .music span:nth-child(3),
    .music-field .music span:nth-child(4) {
        width: 8px;
        height: 70px;
    }

    .music-field .music span:nth-child(5) {
        width: 60px;
        height: 16px;
    }

    .auth-status {
        flex-direction: column;
        gap: 8px;
        margin-top: 12px;
        padding-top: 12px;
    }

    .auth-button {
        padding: 12px 20px;
        font-size: 0.75rem;
        width: 100%;
        max-width: 240px;
    }

    #user-info {
        padding: 10px 14px;
        flex-direction: column;
        gap: 6px;
        text-align: center;
    }

    #user-email {
        font-size: 12px;
    }

    .advanced-button-container {
        flex-direction: column;
        gap: 8px;
        margin-top: 12px;
    }

    .advanced-musicality-button,
    .advanced-reset-button {
        flex: 1 1 auto;
        min-width: 100%;
        width: 100%;
    }

    .badge {
        padding: 5px 12px;
        font-size: 0.65rem;
        letter-spacing: 0.16em;
    }

    .visitor-counter {
        padding: 8px 10px;
        margin-bottom: 12px;
        flex-direction: column;
        gap: 6px;
        border-width: 2px;
    }

    .counter-label {
        font-size: 0.65rem;
    }

    .counter-numbers {
        font-size: 0.9rem;
        padding: 4px 10px;
    }

    .ascii-lounge {
        margin: 16px auto;
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .ascii-card {
        padding: 14px;
        border-radius: 12px;
    }

    .ascii-label {
        font-size: 0.75rem;
        letter-spacing: 0.2em;
    }

    .ascii-card pre {
        font-size: 0.7rem;
    }

    .drive-helper-hint {
        font-size: 0.75rem;
        margin: 8px 0 0;
        text-align: center;
    }
}

/* ========================================
   TABLET BREAKPOINT (481px to 768px)
   ======================================== */
@media (min-width: 481px) and (max-width: 768px) {
    body {
        background-size: 40px 40px, 65px 65px;
    }

    .site-landing-banner {
        padding: 12px 16px;
    }

    .site-landing-banner a {
        font-size: 11px;
        letter-spacing: 0.14em;
    }

    .back-button {
        top: calc(var(--banner-height, 0px) + 14px);
        left: 20px;
        padding: 10px 14px;
        font-size: 0.7rem;
    }

    .page-shell {
        padding: 16px 16px 20px;
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .hero {
        grid-template-columns: 1fr 1fr;
        gap: 24px;
        padding: 0 12px;
        margin-top: 8px;
    }

    .hero h1 {
        font-size: clamp(1.8rem, 5vw, 2.6rem);
        letter-spacing: 0.12em;
    }

    .hero-lede {
        font-size: clamp(0.95rem, 2.2vw, 1.08rem);
    }

    .hero-callouts-row {
        flex-direction: column;
        gap: 16px;
    }

    .hero-callouts li {
        font-size: 0.9rem;
    }

    /* Prevent hero overflow on tablet */
    .hero,
    .hero-visual,
    .hero-orbit,
    .hero-ring {
        max-width: 100% !important;
        overflow: hidden !important;
        box-sizing: border-box !important;
    }

    .hero-ring,
    .hero-orbit {
        width: 100% !important;
        transform: scale(0.92) !important;
    }

    .ascii-woman,
    .ascii-background {
        max-width: 100% !important;
        font-size: 1rem !important;
        overflow: hidden !important;
    }

    /* Constrain layout and panels */
    .layout,
    #intake-panel {
        max-width: 100% !important;
        overflow-x: hidden !important;
    }

    .layout h2,
    .ascii-divider {
        max-width: 100% !important;
        overflow: hidden !important;
    }

    .ascii-dancer-cluster {
        gap: 14px;
    }

    .retro-badges {
        gap: 8px;
        margin-top: 18px;
    }

    .retro-badge {
        padding: 6px 14px;
        font-size: 0.68rem;
    }

    .hero-visual {
        min-height: 220px;
    }

    .ascii-woman {
        font-size: 1.2rem;
    }

    .corner-cluster {
        bottom: 24px;
        left: 24px;
        max-width: 280px;
        padding: 10px 14px;
    }

    .ascii-corner-art,
    .ascii-corner-art-right {
        font-size: 0.68rem;
    }

    .bottom-badge {
        font-size: 0.68rem;
    }

    .layout {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .panel {
        padding: 20px 18px;
        gap: 16px;
    }

    .panel h2 {
        font-size: 1.1rem;
    }

    .section-title {
        font-size: 0.68rem;
    }

    .toggle-group {
        gap: 10px;
    }

    .toggle {
        flex: 1 1 calc(50% - 5px);
        min-width: calc(50% - 5px);
        padding: 13px 18px;
        font-size: 0.72rem;
    }

    .mode-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    .mode-card {
        padding: 16px;
    }

    .mode-card-icon {
        font-size: 1.8rem;
    }

    .mode-card-body h3 {
        font-size: 0.88rem;
    }

    .mode-card-body p {
        font-size: 0.68rem;
    }

    .field {
        gap: 8px;
        margin-bottom: 16px;
        font-size: 0.9rem;
    }

    .field input {
        padding: 13px 16px;
        font-size: 0.95rem;
    }

    .form-actions {
        flex-direction: row;
        gap: 12px;
    }

    .form-actions .cta {
        flex: 1 1 calc(50% - 6px);
        max-width: calc(50% - 6px);
    }

    .cta {
        padding: 11px 18px;
        font-size: 0.72rem;
    }

    .metadata-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .status-panel {
        font-size: 0.9rem;
    }

    .tips {
        font-size: 0.85rem;
    }

    .tips .meta {
        font-size: 0.76rem;
    }

    .state-player .viz-panel {
        max-height: 720px;
    }

    .tiles-canvas {
        margin-top: 24px;
    }

    .footer {
        left: 20px;
        bottom: 18px;
        font-size: 0.75rem;
    }

    .music-field .music {
        width: 95px;
        height: 120px;
        animation-duration: 17s;
    }

    .music-field .music span:nth-child(1),
    .music-field .music span:nth-child(2) {
        width: 28px;
        height: 28px;
    }

    .music-field .music span:nth-child(3),
    .music-field .music span:nth-child(4) {
        width: 10px;
        height: 80px;
    }

    .music-field .music span:nth-child(5) {
        width: 70px;
        height: 18px;
    }

    .auth-status {
        flex-direction: row;
        justify-content: center;
        gap: 12px;
    }

    .auth-button {
        padding: 10px 22px;
        font-size: 0.78rem;
        width: auto;
    }

    #user-info {
        flex-direction: row;
        padding: 8px 16px;
    }

    .advanced-button-container {
        flex-direction: row;
        gap: 10px;
    }

    .advanced-musicality-button,
    .advanced-reset-button {
        flex: 1;
        min-width: 160px;
    }

    .badge {
        padding: 6px 14px;
        font-size: 0.68rem;
    }

    .visitor-counter {
        padding: 8px 12px;
        flex-direction: row;
        gap: 8px;
    }

    .counter-label {
        font-size: 0.68rem;
    }

    .counter-numbers {
        font-size: 0.95rem;
    }

    .ascii-lounge {
        margin: 24px auto;
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .ascii-card {
        padding: 18px;
    }

    .ascii-label {
        font-size: 0.78rem;
    }

    .ascii-card pre {
        font-size: 0.74rem;
    }

    .drive-helper-hint {
        font-size: 0.78rem;
    }
}

/* ========================================
   LAPTOP/SMALL DESKTOP (769px to 1024px)
   ======================================== */
@media (min-width: 769px) and (max-width: 1024px) {
    .site-landing-banner {
        padding: 12px 20px;
    }

    .back-button {
        top: calc(var(--banner-height, 0px) + 16px);
        left: 26px;
        padding: 10px 16px;
        font-size: 0.73rem;
    }

    .page-shell {
        padding: 18px 20px 24px;
        grid-template-columns: minmax(280px, 1fr) minmax(520px, 1fr);
        gap: 20px;
        max-width: 1200px;
    }

    .hero {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
        padding: 0 16px;
    }

    .hero h1 {
        font-size: clamp(2.2rem, 4.5vw, 3rem);
    }

    .hero-lede {
        font-size: clamp(1rem, 1.9vw, 1.12rem);
    }

    .hero-callouts li {
        font-size: 0.95rem;
    }

    .retro-badge {
        font-size: 0.7rem;
    }

    .hero-visual {
        min-height: 240px;
    }

    .ascii-woman {
        font-size: 1.3rem;
    }

    /* Prevent hero overflow on laptop */
    .hero-visual,
    .hero-orbit,
    .hero-ring,
    .ring-base,
    .ring-highlight {
        max-width: 100% !important;
        width: 100% !important;
        overflow: hidden !important;
        box-sizing: border-box !important;
        transform: scale(0.95) !important;
        transform-origin: center !important;
    }

    .ascii-woman,
    .ascii-background {
        max-width: 100% !important;
        width: 100% !important;
        font-size: 1.1rem !important; /* Smaller than current 1.3rem */
        overflow: hidden !important;
        box-sizing: border-box !important;
    }

    .corner-cluster {
        bottom: 28px;
        left: 28px;
        max-width: 300px;
    }

    .layout {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .panel {
        padding: 22px 20px;
    }

    .panel h2 {
        font-size: 1.18rem;
    }

    .section-title {
        font-size: 0.7rem;
    }

    .toggle {
        flex: 1 1 200px;
        min-width: 200px;
        padding: 12px 20px;
        font-size: 0.74rem;
    }

    .mode-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .field {
        font-size: 0.92rem;
    }

    .field input {
        padding: 14px 16px;
        font-size: 1rem;
    }

    .form-actions {
        flex-direction: row;
    }

    .form-actions .cta {
        flex: 0 1 230px;
    }

    .cta {
        font-size: 0.74rem;
    }

    .metadata-grid {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    }

    .status-panel {
        font-size: 0.92rem;
    }

    .tips {
        font-size: 0.86rem;
    }

    .state-player .viz-panel {
        max-height: 850px;
    }

    .tiles-canvas {
        margin-top: 28px;
    }

    .footer {
        left: 26px;
        bottom: 20px;
        font-size: 0.76rem;
    }

    .ascii-lounge {
        margin: 32px auto;
        grid-template-columns: repeat(3, 1fr);
    }

    .ascii-card {
        padding: 20px;
    }

    .ascii-label {
        font-size: 0.8rem;
    }

    .ascii-card pre {
        font-size: 0.76rem;
    }
}

/* ========================================
   LARGE DESKTOP (1025px and above)
   ======================================== */
@media (min-width: 1025px) {
    .page-shell {
        max-width: 1400px;
        padding: clamp(16px, 2.6vw, 28px) clamp(24px, 3.8vw, 44px);
    }

    .hero {
        gap: clamp(32px, 5vw, 64px);
        padding: 0 clamp(24px, 3.2vw, 44px);
    }

    .hero h1 {
        font-size: clamp(2.6rem, 5.2vw, 3.6rem);
    }

    .hero-visual {
        min-height: 260px;
    }

    .ascii-woman {
        font-size: 1.5rem;
    }

    .corner-cluster {
        max-width: 320px;
        padding: 10px 16px;
    }

    .panel h2 {
        font-size: 1.28rem;
    }

    .toggle {
        flex: 1 1 220px;
        min-width: 220px;
    }

    .mode-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .metadata-grid {
        grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    }

    .ascii-lounge {
        grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
        max-width: 1200px;
    }

    .state-player .viz-panel {
        max-height: 980px;
    }
}


