:root {
    font-size: clamp(8px, 2.5vw, 18px);

    /* Light Theme */
    --bg-color: #c0c8cd;
    --laptop-base-color: linear-gradient(#555, #444);
    --screen-color: #0c0c0e;
    --screen-border-color: #333;
    --screen-text-color: #e0e0e0;
    --scene-border-color: #202124;
    --social-note-bg: #FDFEFE;
    --wall-color: #c0c8cd;
    --wall-pattern: url('data:image/svg+xml,%3Csvg width="60" height="60" viewBox="0 0 60 60" xmlns="http://www.w3.org/2000/svg"%3E%3Cg fill="none" fill-rule="evenodd"%3E%3Cg fill="%23d1d9da" fill-opacity="0.2"%3E%3Cpath d="M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z"/%3E%3C/g%3E%3C/g%3E%3C/svg%3E');
    --social-note-text-color: #333;
    --social-note-border-color: #555;
    --distrokid-color: #D81D30;
    --progress-shimmer-color: linear-gradient(90deg, rgba(255,255,255,0) 0%, rgba(255,255,255,0.2) 50%, rgba(255,255,255,0) 100%);
}

[data-theme="dark"] {
    /* Dark Theme */
    --bg-color: #3c4043;
    --laptop-base-color: #222;
    --screen-color: #000;
    --screen-border-color: #1a1a1a;
    --screen-text-color: #b0b0b0;
    --scene-border-color: #121212;
    --social-note-bg: #2d2d2d;
    --wall-color: #383a3d;
    --wall-pattern: url('data:image/svg+xml,%3Csvg width="60" height="60" viewBox="0 0 60 60" xmlns="http://www.w3.org/2000/svg"%3E%3Cg fill="none" fill-rule="evenodd"%3E%3Cg fill="%23d1d9da" fill-opacity="0.05"%3E%3Cpath d="M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z"/%3E%3C/g%3E%3C/g%3E%3C/svg%3E');
    --social-note-text-color: #e0e0e0;
    --social-note-border-color: #999;
    --distrokid-color: #92b8d0;
    --progress-shimmer-color: linear-gradient(90deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.2) 50%, rgba(0,0,0,0) 100%);
}

html, body {
    height: 100%;
    width: 100%;
    margin: 0;
    overflow: hidden;
    background: var(--bg-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Patrick Hand', cursive;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background 0.5s ease;
}

.scene {
    position: relative;
    width: 100%; 
    height: 100%;
    max-width: 500px;
    max-height: 800px;
    aspect-ratio: 500 / 800;
    background: var(--wall-color);
    background-image: var(--wall-pattern);
    box-shadow: 0 0 2em rgba(0,0,0,0.35), inset 0 0 3em rgba(0,0,0,0.1);
    border-left: 1.2em solid var(--scene-border-color);
    border-right: 1.2em solid var(--scene-border-color);
    overflow: hidden;
    transform-style: preserve-3d;
    perspective: 1000px;
    transition: background 0.5s ease, border-color 0.5s ease;
}

/* Walls for 3D effect */
.wall {
    position: absolute;
    background: var(--wall-color);
    box-shadow: 
        inset -20px 0 30px rgba(0,0,0,0.2), 
        inset 20px 0 30px rgba(0,0,0,0.2),  
        inset 0 20px 30px rgba(0,0,0,0.2);  
    transition: background 0.5s ease, box-shadow 0.5s ease;
}

.left-wall {
    left: 0; top: 0;
    width: 50%; height: 100%;
    transform-origin: right;
    transform: rotateY(90deg) translateX(-50%);
}

.right-wall {
    right: 0; top: 0;
    width: 50%; height: 100%;
    transform-origin: left;
    transform: rotateY(-90deg) translateX(50%);
}

.up-wall {
    left: 0; top: 0;
    width: 100%; height: 50%;
    transform-origin: bottom;
    transform: rotateX(-90deg) translateY(-50%);
}

/* --- Newer PC Design --- */
.laptop {
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    height: 28%;
    z-index: 10;
}
.screen {
    position: absolute;
    bottom: 12%;
    width: 100%;
    height: 100%;
    background: var(--screen-color);
    border: 0.8em solid var(--screen-border-color);
    border-bottom: none;
    border-radius: 1.2em 1.2em 0 0;
    padding: 1em;
    box-sizing: border-box;
    color: var(--screen-text-color);
    font-family: 'Roboto Mono', monospace;
    font-size: 1.6em;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-shadow: 0 0 2em rgba(100, 180, 255, 0.3), inset 0 0 1.5em #000;
    animation: screenFlicker 15s infinite;
    transition: background 0.5s ease, border-color 0.5s ease, color 0.5s ease;
}
.screen::before {
    content: '';
    position: absolute;
    top: -0.6em;
    left: 50%;
    transform: translateX(-50%);
    width: 0.4em;
    height: 0.4em;
    background: #222;
    border-radius: 50%;
    transition: background 0.5s ease;
}
@keyframes screenFlicker {
    0%, 100% { box-shadow: 0 0 2em rgba(100, 180, 255, 0.3), inset 0 0 1.5em #000; }
    50% { box-shadow: 0 0 2.2em rgba(100, 180, 255, 0.35), inset 0 0 1.5em #000; }
}

.laptop-base {
    position: absolute;
    bottom: 0;
    width: 100%;
    height: 15%;
    background: var(--laptop-base-color);
    border: 0.3em solid #222;
    border-radius: 0 0 1.2em 1.2em;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 1em;
    box-sizing: border-box;
    transition: background 0.5s ease;
}
.trackpad {
    width: 30%;
    height: 70%;
    background: #3a3a3a;
    border-radius: 0.5em;
    box-shadow: inset 0 0 5px rgba(0,0,0,0.5);
    transition: background 0.5s ease;
}
.progress-bar { width: 80%; height: 1em; background: #333; border: 0.1em solid #555; border-radius: 0.3em; margin-top: 0.5em; overflow: hidden; padding: 0.15em; }
.progress { 
    width: 33%; height: 100%; background: #4285F4; border-radius: 0.15em; 
    transition: width 1s ease-out;
    animation: shimmer 2s infinite;
    background-image: var(--progress-shimmer-color);
    background-size: 200% 100%;
}
@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* --- Wall Notes & Posters --- */
.note, .poster { 
    position: absolute; 
    box-shadow: 0.4em 0.4em 0.8em rgba(0,0,0,0.25);
    transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}
.note:hover, .poster:hover {
    transform: translateY(-6px) rotate(var(--rotate, 0deg));
    box-shadow: 0.8em 0.8em 1.5em rgba(0,0,0,0.3);
}
.note::before, .poster::before { content: ''; position: absolute; top: 6%; left: 50%; transform: translateX(-50%) rotate(5deg); width: 14%; height: 11%; background-color: #f7d04f; border: 0.15em solid #a3862c; box-shadow: 0.1em 0.1em 0.15em rgba(0,0,0,0.4); z-index: 1; border-radius: 0.1em; }

.note {
    padding: 1.5%; font-size: 1.1em; 
    line-height: 1.1; 
    border: 1px solid rgba(0,0,0,0.1); 
    border-radius: 0.1em 0.2em 0.1em 0.3em;
    display: flex;
    align-items: center;
    justify-content: center;
}

.poster {
    background-color: #fff;
    padding: 0.8em;
    border-radius: 0.2em;
}
.poster img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.poster-1 { top: 8.75%; right: 8%; width: 30%; height: 21.25%; transform: rotate(3deg); --rotate: 3deg; z-index: 5; }
.poster-2 { top: 12.5%; left: 12%; width: 32%; height: 17.5%; transform: rotate(-3deg); --rotate: -3deg; z-index: 6; }

.note-3 { top: 5%; left: 32%; width: 22%; height: 7.5%; background-color: #a4e3e8; transform: rotate(2deg); --rotate: 2deg; z-index: 7; }
.note-4 { top: 33%; left: 71%; width: 22%; height: 11.25%; background-color: #fefefe; transform: rotate(-5deg); --rotate: -5deg; font-size: 3em; color: #d1453b; font-weight: bold; border: 0.2em solid #333; z-index: 9; cursor: pointer; }

.note-5 { 
    top: 28%; left: 6%; 
    width: 48%; height: 28%; 
    background-color: #d2b48c; 
    border: 1.5em solid #5E2C04; 
    transform: rotate(4deg); --rotate: 4deg;
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    gap: 10%;
    padding: 3%; 
    z-index: 8; 
}
.note-5::before{ display: none; }

.social-note { 
    background: var(--social-note-bg); box-shadow: 0.15em 0.15em 0.2em rgba(0,0,0,0.2); 
    font-weight: bold; font-size: 0.9em;
    border-radius: 0.2em; border: 1px solid var(--social-note-border-color); text-decoration: none; color: var(--social-note-text-color);
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.3em; 
    padding: 5%; transition: transform 0.2s ease, background-color 0.2s ease;
    aspect-ratio: 1 / 1;
}
.social-note:hover { transform: scale(1.05); background-color: #fff; }
.social-note svg { width: 2em; height: 2em; }
.social-note span { margin-top: 0.2em; }

.social-note.tiktok { transform: rotate(-5deg); }
.social-note.spotify { transform: rotate(8deg); }
.social-note.ig { transform: rotate(2deg); }
.social-note.distrokid { transform: rotate(-3deg); color: var(--distrokid-color); }

.misc-note { position: absolute; background-color: #f7d04f; border: 0.15em solid #a3862c; border-radius: 0.1em; z-index: 5;}

.footer-note {
    position: absolute;
    bottom: 0.8%;
    left: 0;
    width: 100%;
    text-align: center;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.9em;
    color: #888;
    z-index: 11;
}

/* Theme switch button */
.theme-switch {
    position: absolute;
    top: 55%;
    right: 5%;
    width: 60px;
    height: 90px;
    background: #e0e0e0;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2), inset 0 2px 4px rgba(255,255,255,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 15;
    font-size: 0; /* Hide the emoji */
    transition: background 0.3s ease, box-shadow 0.3s ease;
}

.theme-switch::before {
    content: '';
    position: absolute;
    width: 35px;
    height: 55px;
    background: #b0b0b0;
    border-radius: 4px;
    box-shadow: inset 0 2px 5px rgba(0,0,0,0.3);
    transition: transform 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
}

[data-theme="dark"] .theme-switch::before {
    background: #888;
    box-shadow: inset 0 -2px 5px rgba(0,0,0,0.3);
}

/* Explosion Easter Egg Styles */
.explosion-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 9999;
    pointer-events: none;
}
.particle {
    position: absolute;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    animation: explode 5s ease-out forwards;
}
@keyframes explode {
    0% {
        transform: translate(0, 0) scale(1);
        opacity: 1;
    }
    100% {
        transform: var(--transform-end) scale(0);
        opacity: 0;
    }
}