@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;500;600;700;800&family=Rajdhani:wght@400;500;600;700&display=swap');
/* =================================
   ALIMMEO BEATS — GLOBAL
================================= */

:root {
    --cyan: #55dfff;
    --blue: #168bbd;
    --white: #eaf8ff;
    --muted: #7896a8;
    --dark: #020811;
    --music-cyan: #55baff;
    --legal-cyan: #33ccff;
}

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

html,
body {
    width: 100%;
    min-height: 100%;
    overflow: hidden;
    background: var(--dark);
    color: var(--white);
    font-family: 'Rajdhani', sans-serif;
}

body {
    min-height: 100vh;
}

#scene {
    position: fixed;
    inset: 0;
    z-index: 0;
    display: block;
    width: 100%;
    height: 100%;
}

#app {
    position: relative;
    z-index: 2;
    width: 100%;
    height: 100vh;
    min-height: 600px;
    pointer-events: none;
}

/* =================================
   HEADER & BRAND
================================= */

.header {
    position: absolute;
    top: 38px;
    left: 5%;
    right: 5%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand {
    font-family: 'Orbitron', sans-serif;
    font-size: 17px;
    font-weight: 700;
    letter-spacing: 3px;
}

.brand span {
    color: var(--cyan);
}

.topline {
    color: var(--muted);
    font-size: 11px;
    letter-spacing: 4px;
}

/* =================================
   INTRO / ENTER SCREEN
   Preserve existing desktop appearance.
================================= */

.intro-screen {
    position: absolute;
    inset: 0;
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.hero {
    position: absolute;
    top: 50%;
    left: 12%;
    transform: translateY(-50%);
    pointer-events: auto;
}

.eyebrow {
    margin-bottom: 18px;
    color: var(--cyan);
    font-family: 'Orbitron', sans-serif;
    font-size: 10px;
    letter-spacing: 5px;
}

.hero h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: clamp(48px, 8vw, 112px);
    font-weight: 600;
    line-height: 0.95;
    letter-spacing: -5px;
    text-transform: lowercase;
    text-shadow: 0 0 35px rgba(50, 178, 230, 0.18);
}

.hero h1 span {
    display: block;
    margin-left: 70px;
    color: var(--cyan);
}

.tagline {
    margin-top: 28px;
    color: #a5c5d6;
    font-size: 13px;
    letter-spacing: 7px;
}

#enterButton {
    margin-top: 48px;
    padding: 15px 25px;
    border: 1px solid rgba(85, 223, 255, 0.65);
    background: rgba(4, 22, 35, 0.55);
    color: var(--white);
    font-family: 'Orbitron', sans-serif;
    font-size: 10px;
    letter-spacing: 3px;
    cursor: pointer;
    pointer-events: auto;
    transition: background 0.4s ease, color 0.4s ease, letter-spacing 0.4s ease, box-shadow 0.4s ease;
}

#enterButton:hover {
    background: rgba(35, 158, 202, 0.2);
    border-color: var(--cyan);
    letter-spacing: 3px;
    box-shadow: 0 0 25px rgba(40, 170, 255, 0.35);
}

/* =================================
   MAIN NAVIGATION
================================= */

.navigation {
    position: absolute;
    top: 50%;
    right: 5%;
    z-index: 30;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 22px;
    transform: translateX(40px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.navigation a {
    position: relative;
    color: rgba(220, 242, 255, 0.72);
    font-family: 'Orbitron', sans-serif;
    font-size: 11px;
    letter-spacing: 3px;
    text-decoration: none;
    transition: color 0.3s ease, text-shadow 0.3s ease;
}

.navigation a::after {
    content: '';
    position: absolute;
    right: 0;
    bottom: -7px;
    width: 0;
    height: 1px;
    background: var(--cyan);
    transition: width 0.3s ease;
}

.navigation a:hover {
    color: var(--cyan);
    text-shadow: 0 0 12px rgba(85, 223, 255, 0.7);
}

.navigation a:hover::after {
    width: 100%;
}

/* =================================
   FOOTER
================================= */

.footer {
    position: absolute;
    right: 5%;
    bottom: 35px;
    left: 5%;
    z-index: 30;
    display: flex;
    justify-content: space-between;
    color: var(--muted);
    font-family: 'Orbitron', sans-serif;
    font-size: 9px;
    line-height: 1.9;
    letter-spacing: 2px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.footer div:last-child {
    text-align: right;
}

.footer-legal {
    margin-top: 10px;
}

.footer-legal a {
    color: var(--legal-cyan);
    font-size: 10px;
    letter-spacing: 1.5px;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-legal a:hover {
    color: #fff;
    text-shadow: 0 0 12px var(--legal-cyan);
}

.footer-divider {
    display: inline-block;
    width: 1px;
    height: 12px;
    margin: 0 12px;
    background: rgba(255, 255, 255, 0.35);
    vertical-align: middle;
}

/* =================================
   LOADING EXPERIENCE
================================= */

#loadingScreen {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 8%;
    background: radial-gradient(circle at 75% 50%, rgba(20, 85, 130, 0.12), transparent 45%), #020811;
    color: #eaf7ff;
    font-family: 'Orbitron', sans-serif;
}

.loading-brand {
    position: absolute;
    top: 45px;
    left: 8%;
    color: #6bbce8;
    font-size: 13px;
    letter-spacing: 5px;
}

.loading-content {
    width: 100%;
    max-width: 540px;
}

.loading-content h1 {
    margin: 0 0 18px;
    font-size: clamp(30px, 4vw, 52px);
    font-weight: 600;
    letter-spacing: 2px;
}

.loading-content h1 span {
    display: block;
    color: #55baff;
}

.loading-status {
    margin-bottom: 38px;
    color: #76b9dc;
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    letter-spacing: 4px;
}

.loading-progress {
    display: flex;
    align-items: center;
    gap: 18px;
}

.loading-bar {
    flex: 1;
    height: 7px;
    padding: 1px;
    overflow: hidden;
    background: rgba(80, 150, 190, 0.15);
    border: 1px solid rgba(80, 180, 230, 0.35);
}

#loadingBarFill {
    width: 0%;
    height: 100%;
    background: #55baff;
    box-shadow: 0 0 15px #35aaff;
}

#loadingPercentage {
    min-width: 45px;
    color: #8bd5ff;
    font-size: 13px;
}

#loadingMessage {
    margin-top: 17px;
    color: #64869c;
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
    letter-spacing: 3px;
}

.loading-footer {
    position: absolute;
    bottom: 40px;
    left: 8%;
    color: #52758b;
    font-size: 10px;
    letter-spacing: 2px;
}

/* =================================
   FULLSCREEN CONTENT STAGE
================================= */

.content-stage {
    position: fixed;
    inset: 0;
    z-index: 20;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.content-stage>section {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    min-height: 100vh;
    overflow-y: auto;
    box-sizing: border-box;
    pointer-events: auto;
}

/* =================================
   HOME
================================= */

.home-content {
    display: none;
    position: relative;
    z-index: 20;
    width: 100%;
    min-height: 70vh;
    align-items: center;
    justify-content: center;
    padding: 100px 20px;
    text-align: center;
    pointer-events: none;
}

.home-info {
    max-width: 900px;
    margin: 0 auto;
}

.home-info h1 {
    margin: 25px 0;
    color: #fff;
    font-size: clamp(38px, 6vw, 76px);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: 2px;
}

.home-info h1 .title-line {
    display: block;
    color: #fff;
}

.home-info h1 .title-line:last-child {
    color: var(--music-cyan);
}

.home-info p {
    margin: 25px 0 35px;
    color: #9bb0c0;
    font-size: 14px;
    letter-spacing: 3px;
}

.home-explore {
    display: inline-block;
    padding: 14px 26px;
    border: 1px solid rgba(85, 186, 255, 0.5);
    color: var(--music-cyan);
    font-size: 12px;
    letter-spacing: 2px;
    text-decoration: none;
    pointer-events: auto;
    transition: 0.3s ease;
}

.home-explore:hover {
    background: rgba(85, 186, 255, 0.12);
    border-color: var(--music-cyan);
}

/* =================================
   MUSIC ARCHIVE & PLAYER
================================= */

.music-section {
    position: fixed;
    inset: 0;
    z-index: 10;
    display: none;
    overflow-y: auto;
    padding: 130px 8% 70px;
    background: radial-gradient(circle at 75% 35%, rgba(20, 105, 160, 0.13), transparent 45%), rgba(2, 8, 17, 0.96);
    color: #eaf7ff;
}

.music-header {
    margin-bottom: 45px;
	margin-top: 35px;
}

.music-eyebrow {
    margin-bottom: 15px;
    color: var(--music-cyan);
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    letter-spacing: 4px;
}

.music-header h2 {
    margin: 0;
    font-family: 'Orbitron', sans-serif;
    font-size: clamp(32px, 5vw, 58px);
    letter-spacing: 3px;
}

.music-header h2 span {
    color: var(--music-cyan);
}

.music-header p {
    color: #7298ad;
    font-family: 'Rajdhani', sans-serif;
    font-size: 14px;
    letter-spacing: 4px;
}

.music-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.8fr);
    align-items: start;
    gap: 30px;
    max-width: 1200px;
}

.music-player,
.music-playlist {
    max-width: none;
    border: 1px solid rgba(85, 186, 255, 0.22);
    background: linear-gradient(135deg, rgba(13, 36, 55, 0.85), rgba(3, 13, 25, 0.9));
    box-shadow: 0 0 40px rgba(20, 120, 190, 0.08);
}

.music-player {
    padding: 30px;
}

.music-track-info {
    position: relative;
    z-index: 500;
    display: flex !important;
    align-items: center;
    gap: 22px;
    min-height: 110px;
    visibility: visible !important;
    opacity: 1 !important;
}

.track-cover {
    display: flex;
    flex: 0 0 100px;
    align-items: center;
    justify-content: center;
    width: 100px;
    height: 100px;
    overflow: hidden;
    border: 1px solid rgba(85, 186, 255, 0.4);
    background: linear-gradient(135deg, #123c59, #06111e);
    box-shadow: 0 0 25px rgba(55, 170, 255, 0.12);
    color: var(--music-cyan);
    font-size: 42px;
}

.track-cover img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.track-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
    min-width: 0;
}

.track-details,
.track-details * {
    visibility: visible !important;
    opacity: 1 !important;
    color: #fff !important;
}

.track-label {
    color: var(--music-cyan);
    font-size: 10px;
    letter-spacing: 3px;
}

.track-details h3,
.music-track-info h3 {
    margin: 8px 0;
    color: #fff;
    font-family: 'Orbitron', sans-serif;
    font-size: 20px;
}

.track-details p,
.music-track-info p {
    margin: 0;
    color: #8bd5ff;
    font-family: 'Rajdhani', sans-serif;
}

.track-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    color: #7298ad;
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    letter-spacing: 1px;
}

.meta-divider {
    color: var(--music-cyan);
    font-size: 9px;
}

.music-controls {
    position: relative;
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 25px;
    margin: 35px 0;
    pointer-events: auto;
}

.music-controls button {
    position: relative;
    z-index: 201;
    width: 48px;
    height: 48px;
    border: 1px solid rgba(85, 186, 255, 0.4);
    background: rgba(25, 90, 130, 0.15);
    color: #8bd5ff;
    cursor: pointer;
    pointer-events: auto;
    transition: 0.3s;
}

.music-controls button:hover {
    background: var(--music-cyan);
    color: #020811;
    box-shadow: 0 0 20px rgba(85, 186, 255, 0.4);
}

#playTrack {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    border: 1px solid rgba(85, 186, 255, 0.35);
    border-radius: 0;
    background: rgba(20, 100, 150, 0.08);
    cursor: pointer;
    transition: all 0.3s ease;
}

#playTrack:hover {
    border-color: var(--music-cyan);
    background: rgba(85, 186, 255, 0.12);
    box-shadow: 0 0 20px rgba(85, 186, 255, 0.25);
}

.pause-icon {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pause-icon i {
    display: block;
    width: 3px;
    height: 20px;
    border-radius: 2px;
    background: var(--music-cyan);
    box-shadow: 0 0 8px var(--music-cyan);
    transition: all 0.3s ease;
}

#playTrack:hover .pause-icon i {
    box-shadow: 0 0 14px var(--music-cyan);
}

.play-icon {
    width: 0;
    height: 0;
    margin-left: 4px;
    border-top: 9px solid transparent;
    border-bottom: 9px solid transparent;
    border-left: 14px solid var(--music-cyan);
    filter: drop-shadow(0 0 6px var(--music-cyan));
}

.music-visualizer {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 75px;
    overflow: hidden;
}

.visualizer-bars {
    width: 100%;
    height: 65px;
    background: repeating-linear-gradient( 90deg, transparent 0 5px, rgba(65, 177, 240, 0.8) 5px 8px, transparent 8px 13px);
    mask-image: linear-gradient(to top, transparent, black 20%, black 80%, transparent);
    opacity: 0.55;
}

.music-progress {
    position: relative;
    z-index: 500;
    display: flex;
    align-items: center;
    gap: 15px;
    color: #7298ad;
    font-family: 'Rajdhani', sans-serif;
    font-size: 12px;
    pointer-events: auto;
}

.progress-track {
    position: relative;
    z-index: 501;
    flex: 1;
    height: 14px;
    background: rgba(85, 186, 255, 0.15);
    cursor: pointer;
    pointer-events: auto;
    touch-action: none;
    user-select: none;
}

.progress-track:hover {
    height: 14px;
}

.progress-track:active {
    cursor: grabbing;
}

#progressFill {
    width: 0%;
    height: 100%;
    background: var(--music-cyan);
    box-shadow: 0 0 10px var(--music-cyan);
    pointer-events: none;
    transition: width 0.3s linear;
}

.youtube-player-frame {
    position: relative;
    z-index: 100;
    width: 100%;
    max-width: 420px;
    margin: 30px auto 10px;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    border: 1px solid rgba(85, 186, 255, 0.35);
    box-shadow: 0 0 25px rgba(55, 170, 255, 0.12);
    pointer-events: auto;
}

#youtubePlayer,
#youtubePlayer iframe {
    position: relative;
    z-index: 101;
    display: block;
    width: 100%;
    height: 100%;
    pointer-events: auto;
}

.music-playlist {
    position: relative;
    z-index: 300;
    margin-top: 0;
    padding: 25px;
    pointer-events: auto;
}

.playlist-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(85, 186, 255, 0.25);
    color: var(--music-cyan);
    font-family: 'Orbitron', sans-serif;
    font-size: 13px;
    letter-spacing: 3px;
}

.playlist-heading::after {
    content: 'AUDIO DATABASE // 2026';
    color: #52758b;
    font-family: 'Rajdhani', sans-serif;
    font-size: 10px;
    letter-spacing: 1px;
}

.playlist-track {
    position: relative;
    z-index: 301;
    display: flex;
    align-items: center;
    gap: 15px;
    min-height: 65px;
    padding: 10px 12px;
    overflow: hidden;
    border-bottom: 1px solid rgba(85, 186, 255, 0.10);
    cursor: pointer;
    pointer-events: auto;
    transition: all 0.3s ease;
}

.playlist-track:hover {
    padding-left: 20px;
    background: rgba(55, 160, 220, 0.10);
}

.playlist-track.active {
    position: relative;
    background: linear-gradient(90deg, rgba(55, 170, 255, 0.16), transparent);
    border-left: 2px solid var(--music-cyan);
}

.playlist-track.active::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 2px;
    height: 100%;
    background: var(--music-cyan);
    box-shadow: 0 0 12px var(--music-cyan);
    animation: trackSignal 1.5s ease-in-out infinite;
}

.playlist-number {
    color: #52758b;
    font-family: 'Orbitron', sans-serif;
    font-size: 12px;
}

.playlist-track.active .playlist-number {
    color: var(--music-cyan);
}

.playlist-title {
    flex: 1;
    color: #c5dce9;
    font-family: 'Rajdhani', sans-serif;
    font-size: 15px;
    letter-spacing: 1px;
}

.playlist-track.active .playlist-title {
    color: #8bd5ff;
}

.playlist-play {
    color: var(--music-cyan);
    font-size: 13px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.playlist-track:hover .playlist-play,
.playlist-track.active .playlist-play {
    opacity: 1;
}

.playlist-track.active .playlist-play {
    animation: playPulse 1.2s ease-in-out infinite;
}

@keyframes trackSignal {
    0%,
    100% {
        opacity: 0.35;
    }
    50% {
        opacity: 1;
    }
}

@keyframes playPulse {
    0%,
    100% {
        text-shadow: 0 0 3px var(--music-cyan);
    }
    50% {
        text-shadow: 0 0 14px var(--music-cyan);
    }
}

.playlist-pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid rgba(85, 186, 255, 0.15);
    color: #7298ad;
    font-family: 'Rajdhani', sans-serif;
    font-size: 13px;
}

.playlist-pagination button {
    padding: 8px 14px;
    border: 1px solid rgba(85, 186, 255, 0.3);
    background: transparent;
    color: var(--music-cyan);
    cursor: pointer;
    font-family: inherit;
    transition: 0.3s ease;
}

.playlist-pagination button:hover:not(:disabled) {
    border-color: var(--music-cyan);
    background: rgba(85, 186, 255, 0.12);
}

.playlist-pagination button:disabled {
    opacity: 0.25;
    cursor: default;
}

/* =================================
   PROJECTS
================================= */

.projects-section {
    display: none;
    position: relative;
    z-index: 20;
    width: 100%;
    min-height: 70vh;
    padding: 100px 8%;
    color: #fff;
}

.projects-header {
    margin-bottom: 55px;
    text-align: center;
}

.projects-header h2 {
    margin: 20px 0;
    font-size: clamp(36px, 5vw, 64px);
    font-weight: 700;
    letter-spacing: 3px;
}

.projects-header h2 span {
    color: var(--music-cyan);
}

.projects-header p {
    color: #9bb0c0;
    font-size: 12px;
    letter-spacing: 3px;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
    max-width: 1200px;
    margin: 0 auto;
}

.project-card {
    position: relative;
    min-height: 260px;
    padding: 35px 28px;
    border: 1px solid rgba(85, 186, 255, 0.2);
    background: rgba(10, 25, 40, 0.65);
    transition: 0.35s ease;
}

.project-card:hover {
    transform: translateY(-8px);
    border-color: var(--music-cyan);
    background: rgba(20, 45, 65, 0.8);
}

.project-number {
    margin-bottom: 35px;
    color: var(--music-cyan);
    font-family: monospace;
    font-size: 11px;
    letter-spacing: 2px;
}

.project-card h3 {
    margin-bottom: 18px;
    font-size: 20px;
    letter-spacing: 1px;
}

.project-card p {
    color: #9bb0c0;
    font-size: 14px;
    line-height: 1.8;
}

.project-tech {
    margin-top: 28px;
    color: var(--music-cyan);
    font-size: 10px;
    letter-spacing: 1px;
    line-height: 1.8;
}

.projects-footer {
    margin-top: 55px;
    color: #68879b;
    font-size: 11px;
    letter-spacing: 4px;
    text-align: center;
}

/* =================================
   ABOUT
================================= */

.about-section {
    display: none;
    position: relative;
    z-index: 20;
    width: 100%;
    min-height: 70vh;
    padding: 100px 8%;
    color: #fff;
}

.about-content {
    max-width: 1100px;
    margin: 0 auto;
    text-align: center;
}

.about-content h2 {
    margin: 22px 0;
    font-size: clamp(36px, 5vw, 64px);
    letter-spacing: 3px;
}

.about-content h2 span {
    color: var(--music-cyan);
}

.about-intro {
    margin: 30px 0;
    color: var(--music-cyan);
    font-size: 13px;
    letter-spacing: 4px;
}

.about-description {
    max-width: 750px;
    margin: 0 auto;
    color: #9bb0c0;
    font-size: 14px;
    line-height: 2;
    letter-spacing: 1px;
}

.about-details {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
    margin-top: 65px;
}

.about-item {
    padding: 30px 22px;
    border: 1px solid rgba(85, 186, 255, 0.2);
    background: rgba(10, 25, 40, 0.65);
    text-align: left;
    transition: 0.35s ease;
}

.about-item:hover {
    transform: translateY(-6px);
    border-color: var(--music-cyan);
}

.about-label {
    color: var(--music-cyan);
    font-size: 11px;
    letter-spacing: 2px;
}

.about-item h3 {
    margin: 25px 0 15px;
    font-size: 17px;
    letter-spacing: 1px;
}

.about-item p {
    color: #9bb0c0;
    font-size: 13px;
    line-height: 1.8;
}

.about-signature {
    margin-top: 60px;
    color: #68879b;
    font-size: 11px;
    letter-spacing: 4px;
}

/* =================================
   CONTACT
================================= */

.contact-section {
    display: none;
    position: relative;
    z-index: 100;
    padding: 100px 8%;
    pointer-events: auto;
}

.contact-header {
    margin-bottom: 40px;
    text-align: center;
}

.contact-header h2 {
    color: #fff;
    font-size: 36px;
}

.contact-header h2 span {
    color: var(--music-cyan);
}

.contact-header p {
    color: #7298ad;
    font-size: 12px;
    letter-spacing: 3px;
}

.contact-direct {
    max-width: 500px;
    margin: 0 auto;
}

.contact-email {
    position: relative;
    z-index: 101;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px;
    border: 1px solid rgba(85, 186, 255, 0.3);
    background: rgba(85, 186, 255, 0.05);
    color: #fff;
    pointer-events: auto;
}

.contact-email button {
    position: relative;
    z-index: 102;
    border: none;
    background: transparent;
    color: var(--music-cyan);
    font-size: 24px;
    cursor: pointer;
    pointer-events: auto;
}

.copy-toast {
    margin-top: 15px;
    color: var(--music-cyan);
    text-align: center;
    opacity: 0;
    visibility: hidden;
    transition: 0.3s ease;
}

.copy-toast.show {
    opacity: 1;
    visibility: visible;
}

/* =================================
   LEGAL PAGES
================================= */

.content-stage>#privacy {
    z-index: 2;
}

.legal-section {
    display: none;
    align-items: center;
    justify-content: center;
    padding: 110px 7% 100px;
    background: transparent;
    pointer-events: auto;
}

.legal-container {
    position: relative;
    display: flex;
    flex-direction: column;
    width: min(900px, 100%);
    max-height: min(680px, 75vh);
    overflow: hidden;
    border: 1px solid rgba(51, 204, 255, 0.25);
    border-radius: 12px;
    background: rgba(3, 12, 25, 0.78);
    box-shadow: 0 0 35px rgba(0, 191, 255, 0.08), inset 0 0 35px rgba(0, 191, 255, 0.025);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    pointer-events: auto;
}

.legal-topline {
    position: relative;
    z-index: 50;
    display: flex;
    justify-content: space-between;
    padding: 18px 26px;
    border-bottom: 1px solid rgba(51, 204, 255, 0.16);
    color: #7c9eaf;
    font-family: 'DM Mono', monospace;
    font-size: 10px;
    letter-spacing: 2px;
    pointer-events: auto;
}

.legal-topline span {
    color: var(--legal-cyan);
}

.legal-header {
    padding: 30px 38px 24px;
}

.legal-header h2 {
    margin: 12px 0;
    color: #fff;
    font-size: clamp(30px, 5vw, 48px);
    letter-spacing: 2px;
}

.legal-header h2 span {
    color: var(--legal-cyan);
}

.legal-header p {
    color: #7895a8;
    font-size: 11px;
    letter-spacing: 3px;
}

.legal-scroll {
    min-height: 0;
    overflow-y: auto;
    padding: 0 38px 30px;
    scrollbar-width: thin;
    scrollbar-color: var(--legal-cyan) rgba(255, 255, 255, 0.05);
}

.legal-scroll::-webkit-scrollbar {
    width: 5px;
}

.legal-scroll::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.04);
}

.legal-scroll::-webkit-scrollbar-thumb {
    border-radius: 10px;
    background: var(--legal-cyan);
}

.legal-content {
    max-width: 720px;
}

.legal-intro {
    margin-bottom: 28px;
    padding: 22px;
    border-left: 2px solid var(--legal-cyan);
    background: rgba(51, 204, 255, 0.045);
}

.legal-label,
.legal-number {
    color: var(--legal-cyan);
    font-family: 'DM Mono', monospace;
    font-size: 10px;
    letter-spacing: 2px;
}

.legal-intro p,
.legal-block p {
    color: #b6c8d5;
    font-size: 13px;
    line-height: 1.9;
}

.legal-block {
    position: relative;
    padding: 18px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.legal-block h3 {
    margin: 9px 0;
    color: #edf8ff;
    font-size: 15px;
    letter-spacing: 1.5px;
}

.legal-updated {
    padding-top: 28px;
    color: #66879b;
    font-family: 'DM Mono', monospace;
    font-size: 10px;
    letter-spacing: 2px;
}

.legal-actions {
    position: relative;
    z-index: 50;
    display: flex;
    align-items: center;
    gap: 22px;
    pointer-events: auto;
}

.legal-close {
    position: relative;
    z-index: 60;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 1px solid rgba(51, 204, 255, 0.35);
    border-radius: 50%;
    color: var(--legal-cyan);
    font-size: 27px;
    line-height: 1;
    text-decoration: none;
    cursor: pointer;
    pointer-events: auto;
    transition: all 0.3s ease;
}

.legal-close:hover {
    transform: rotate(90deg);
    border-color: var(--legal-cyan);
    background: rgba(51, 204, 255, 0.15);
    color: #fff;
    box-shadow: 0 0 18px rgba(51, 204, 255, 0.4);
}

/* =================================
   TABLET
================================= */

@media (max-width: 900px) {
    .projects-grid,
    .about-details {
        grid-template-columns: 1fr;
    }
    .music-layout {
        grid-template-columns: 1fr;
    }
    .music-playlist {
        padding: 18px;
    }
}

/* =================================
   MOBILE
   Mobile HOME can scroll; menu and
   content have a clear separation.
================================= */

@media (max-width: 760px) {
    .header {
        top: 22px;
    }
    .topline {
        display: none;
    }
    /* Intro layout: retain its existing visual style. */
    .hero {
        left: 8%;
    }
    .hero h1 {
        font-size: clamp(45px, 13vw, 75px);
        letter-spacing: -3px;
    }
    .hero h1 span {
        margin-left: 30px;
    }
    .tagline {
        font-size: 10px;
        letter-spacing: 4px;
    }
    /* Navigation is positioned at the top after ENTER. */
    #mainNavigation {
        top: 90px;
        right: 10px;
        bottom: auto;
        left: 10px;
        z-index: 9999;
        display: flex;
        flex-direction: row;
        align-items: center;
        justify-content: center;
        flex-wrap: wrap;
        gap: 12px;
        transform: none;
    }
    #mainNavigation a {
        font-size: 9px;
        letter-spacing: 1px;
    }
    /* Reserve room below the menu on every content page. */
    .content-stage>section {
        padding-top: 160px;
        padding-right: 6%;
        padding-left: 6%;
        padding-bottom: 110px;
    }
    /* HOME is the only section whose mobile layout is being changed. */
    #home {
        min-height: 100%;
        height: 100%;
        overflow-y: auto;
        overflow-x: hidden;
        padding: 160px 6% 125px;
        -webkit-overflow-scrolling: touch;
        touch-action: pan-y;
        pointer-events: auto;
    }
    .home-content {
        min-height: 70vh;
        height: auto;
        pointer-events: auto;
    }
    .home-info {
        width: 100%;
    }
    .home-info p {
        letter-spacing: 1.5px;
        line-height: 1.7;
    }
    /* Other sections: menu-to-content spacing. */
    .music-section {
        padding: 160px 6% 60px;
    }
    .projects-section,
    .about-section,
    .contact-section {
        padding: 160px 6% 110px;
    }
    .legal-section {
        padding: 150px 5% 100px;
    }
    .legal-container {
        max-height: calc(100vh - 180px);
    }
    .legal-header {
        padding: 22px 24px 18px;
    }
    .legal-scroll {
        padding: 0 24px 24px;
    }
    .legal-topline {
        padding: 14px 18px;
    }
    .footer {
        right: 15px;
        bottom: 15px;
        left: 15px;
        z-index: 10000;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 10px;
        font-size: 8px;
        line-height: 1.7;
        text-align: center;
    }
    .footer div,
    .footer div:last-child {
        text-align: center;
    }
    .footer-legal {
        display: flex;
        align-items: center;
        justify-content: center;
        flex-wrap: wrap;
        gap: 6px;
    }
    .footer-divider {
        margin: 0 4px;
    }
    .music-player {
        padding: 20px;
    }
    .track-cover {
        flex-basis: 75px;
        width: 75px;
        height: 75px;
    }
    .music-track-info h3,
    .track-details h3 {
        font-size: 15px;
    }
    .music-header p {
        font-size: 11px;
        letter-spacing: 2px;
    }
    .playlist-heading {
        gap: 12px;
        font-size: 11px;
        letter-spacing: 2px;
    }
}

@media (max-width: 600px) {
    #loadingScreen {
        padding: 8%;
    }
    .loading-content h1 {
        font-size: 32px;
    }
    .loading-brand {
        top: 30px;
    }
    .loading-footer {
        bottom: 25px;
    }
}

.cinematic-title {
    position: relative;
    overflow: hidden;
}

.home-info h1 .title-line:nth-of-type(2) {
    color: var(--music-cyan);
}

/* =================================
   COSMIC SIGNAL GLITCH
================================= */

.signal-status {
    margin-bottom: 18px;
    color: var(--music-cyan);
    font-family: monospace;
    font-size: 11px;
    letter-spacing: 5px;
    opacity: 0;
}

.signal-dot {
    display: inline-block;
    width: 6px;
    height: 6px;
    margin-right: 9px;
    border-radius: 50%;
    background: var(--music-cyan);
}

.cinematic-title .title-line {
    display: block;
    position: relative;
    will-change: transform, opacity, filter;
}