@charset "UTF-8";
/* CSS Document */

:root {
    --win-gray: #c0c0c0;
    --win-dark: #808080;
    --win-darker: #404040;
    --win-light: #ffffff;
    --win-blue: #000080;
    --desktop-col: #008080;
}

* { box-sizing: border-box; }

html, body {
    margin: 0; padding: 0;
    background-color: #000;
    font-family: 'Courier New', Courier, monospace; 
    height: 100%; width: 100%;
    overflow: hidden; 
    user-select: none;
    -webkit-user-select: none; 
}

/* CRT Scanline Overlay */
.crt::before {
    content: " "; display: block; position: absolute;
    top: 0; left: 0; bottom: 0; right: 0;
    background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
    z-index: 9999; background-size: 100% 2px, 3px 100%; pointer-events: none;
}

/* BOOT SCREEN */
#boot-screen {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: #000; color: #0f0; padding: 20px; z-index: 10000;
    font-size: 16px; line-height: 1.5; cursor: pointer;
}

/* DESKTOP CONTAINER */
#desktop {
    width: 100%; height: 100%;
    background-color: var(--desktop-col);
    position: relative; display: none; 
    padding-bottom: 50px; 
    overflow: hidden; 
}

/* ICON CONTAINER */
#icon-area {
    position: absolute; top: 0; left: 0; width: 100px;
    padding: 10px;
    display: flex; flex-direction: column;
}

/* ICONS */
.icon {
    width: 80px; text-align: center; margin-bottom: 20px;
    cursor: pointer; color: white;
    font-family: Tahoma, sans-serif; font-size: 12px;
    text-shadow: 1px 1px 0 #000;
}
.icon img { 
    width: 32px; height: 32px; 
    margin-bottom: 5px; display: block; margin: 0 auto 5px auto; 
}

/* STANDARD WINDOW STYLING */
.window {
    position: absolute; 
    background: var(--win-gray);
    border-top: 2px solid var(--win-light);
    border-left: 2px solid var(--win-light);
    border-right: 2px solid var(--win-darker);
    border-bottom: 2px solid var(--win-darker);
    box-shadow: 2px 2px 0 #000;
    width: 400px; 
    display: none; 
    flex-direction: column; padding: 2px;
}

/* --- MINIMIZED STATE CSS --- */
.window.minimized {
    height: auto !important;
    min-height: 0 !important;
    overflow: hidden !important;
}
.window.minimized .window-content {
    display: none !important;
}

/* --- DESKTOP SIZE OVERRIDES --- */
@media (min-width: 769px) {
    /* FEATURED VIDEO SIZE */
    #win-featured-video { width: 650px !important; }
    #win-featured-video iframe { height: 380px !important; }

    /* INCREASED SIZE FOR PHOTOS & VAULT */
    #win-photos, #win-video-lib { width: 580px !important; }

    /* MUSIC WINDOW FIXES */
    #win-music { 
        width: 350px !important; 
        height: auto !important;
        overflow: visible !important;
    }
}

/* FIX: Allow Music Window dropdown to overlap other windows */
#win-music .window-content {
    overflow: visible !important; 
    max-height: none !important;
}

.title-bar {
    background: var(--win-blue); color: white;
    padding: 4px 6px; font-weight: bold;
    display: flex; justify-content: space-between; align-items: center;
    cursor: grab; font-family: Tahoma, sans-serif; font-size: 13px;
    touch-action: none;
}
.title-bar.active { background: linear-gradient(90deg, var(--win-blue), #1084d0); }

/* BUTTON CONTAINER */
.win-controls { display: flex; align-items: center; }

/* CLOSE BUTTON */
.btn-close {
    width: 24px; height: 22px;
    background: var(--win-gray); border: 1px solid;
    border-color: var(--win-light) var(--win-darker) var(--win-darker) var(--win-light);
    font-size: 14px; line-height: 18px; text-align: center; cursor: pointer; color: black;
    font-weight: bold; margin-left: 4px;
}
.btn-close:active { border-color: var(--win-darker) var(--win-light) var(--win-light) var(--win-darker); }

/* MINIMIZE BUTTON */
.btn-min {
    width: 24px; height: 22px;
    background: var(--win-gray); border: 1px solid;
    border-color: var(--win-light) var(--win-darker) var(--win-darker) var(--win-light);
    /* DEFAULT STATE: Shows underscore _ */
    font-size: 16px; line-height: 16px; 
    text-align: center; cursor: pointer; color: black;
    font-weight: bold; padding-bottom: 2px;
}

/* CENTERED PLUS SIGN WHEN MINIMIZED */
/* When the window has class 'minimized', this button shows + */
.window.minimized .btn-min {
    display: flex; 
    align-items: center; 
    justify-content: center;
    font-size: 18px;
    font-weight: 900;
    padding: 0;
    line-height: 1;
}

.btn-min:active { border-color: var(--win-darker) var(--win-light) var(--win-light) var(--win-darker); }


.window-content {
    padding: 10px; overflow-y: auto; max-height: 65vh; 
    font-family: Tahoma, sans-serif; font-size: 14px;
    background: white; color: black;
}

/* MODAL OVERLAYS */
.modal-overlay {
    position: fixed !important;
    top: 0; left: 0; width: 100vw; height: 100vh;
    background: rgba(0,0,0,0.85);
    z-index: 20000 !important;
    display: none; 
    justify-content: center; align-items: center; padding: 20px;
}
.modal-window-box {
    background: var(--win-gray); border: 2px solid var(--win-light);
    box-shadow: 5px 5px 15px #000; width: 100%; max-width: 650px;
    display: flex; flex-direction: column; position: relative;
}

/* DYNAMIC VIDEO PLAYER SIZE */
#dyn-vid-frame {
    width: 100%;
    height: 250px;
}
@media (min-width: 769px) {
    #dyn-vid-frame {
        height: 450px; /* Taller Desktop Height */
    }
    .modal-window-box {
        max-width: 800px; /* Wider container for desktop theater mode */
    }
}

/* LIST STYLES */
.retro-list p { margin: 8px 0; border-bottom: 1px dotted #888; padding-bottom: 2px; }
.retro-list a { text-decoration: none; color: blue; font-weight: bold; }
.retro-list h3 { background: var(--win-gray); border: 2px inset white; padding: 2px 5px; margin: 15px 0 5px 0; font-size: 12px; }

/* MIXTAPE GENERATOR STYLES */
.mixtape-controls {
    text-align: center; border-bottom: 2px solid #888; 
    padding-bottom: 10px; margin-bottom: 10px;
}
.btn-remix {
    background: #000080; color: white; border: 2px outset #fff;
    padding: 5px 15px; font-family: 'Courier New', monospace; 
    font-weight: bold; cursor: pointer; font-size: 14px;
}
.btn-remix:active { border-style: inset; }
.track-list-container { font-size: 13px; }

/* LYRICS STYLING */
.lyrics-box p { margin: 0; line-height: 1.3; font-family: 'Courier New', Courier, monospace; font-size: 16px; font-weight: 500; }
.lyrics-box h3 { margin: 10px 0 10px 0; color: #000080; font-size: 18px; text-decoration: underline; }
.lyrics-box br { margin-bottom: 10px; display: block; content: " "; }

/* GRIDS */
.gallery-grid { 
    display: grid; 
    grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); 
    gap: 15px; 
}
.gallery-item { text-align: center; cursor: pointer; margin-bottom: 10px; }
.gallery-item:hover img { border: 2px solid blue; }
.gallery-item img { 
    width: 100%; height: 110px; 
    object-fit: cover; border: 2px inset white; background: black; 
}
.video-item img { 
    width: 100%; height: 100px; 
    object-fit: cover; border: 2px inset white; 
}
.video-item { text-align: center; cursor: pointer; font-size: 12px; }

/* --- WINDOW ICON GRIDS (For Favorites/Games) --- */
.win-icon-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    padding: 10px;
}
.win-icon-item {
    text-align: center;
    width: 80px;
    cursor: pointer;
    color: black;
    font-family: Tahoma, sans-serif;
    font-size: 11px;
}
.win-icon-item:hover span {
    background-color: #000080;
    color: white;
    outline: 1px dotted #ccc;
}
.win-icon-item img {
    width: 32px; 
    height: 32px;
    display: block;
    margin: 0 auto 5px auto;
}


/* SOCIAL LIST */
.social-list a { display: block; padding: 10px; text-decoration: none; color: black; border: 1px solid transparent; }
.social-list a:hover { background-color: var(--win-blue); color: white; border: 1px dotted white; }

/* RETRO MUSIC PLAYER STYLING */
.retro-player {
    background: #333;
    padding: 10px;
    border: 2px inset white;
    margin-bottom: 0;
}
.player-display-container {
    background: #000;
    border: 2px inset #555;
    margin-bottom: 8px;
    padding: 8px; /* Increased padding */
}
.player-display {
    font-family: 'Courier New', Courier, monospace;
    color: #0f0;
    font-size: 14px; /* Increased Base Font */
    white-space: nowrap;
    overflow: hidden;
}

/* Song Title Bigger */
#player-song-title {
    font-size: 20px;
    font-weight: bold;
    margin: 4px 0;
}

/* Status Text Bigger */
#player-status {
    font-size: 14px;
    margin-bottom: 2px;
}

/* Time & Bitrate Bigger */
#player-time, .bitrate-display {
    font-size: 14px;
}

.scrolling-text {
    animation: scrollText 10s linear infinite;
    padding-left: 100%;
    display: inline-block;
}
@keyframes scrollText {
    0% { transform: translateX(0); }
    100% { transform: translateX(-100%); }
}

.player-controls {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

/* Bigger Buttons */
.player-btn {
    background: var(--win-gray);
    border: 1px solid;
    border-color: var(--win-light) var(--win-darker) var(--win-darker) var(--win-light);
    font-family: Tahoma, sans-serif;
    font-weight: bold;
    font-size: 18px; /* Bigger font */
    padding: 8px 14px; /* Bigger padding for touch */
    cursor: pointer;
    min-width: 45px; /* Wider touch target */
}
.player-btn:active {
    border-color: var(--win-darker) var(--win-light) var(--win-light) var(--win-darker);
    transform: translateY(1px);
}

.player-progress-container {
    width: 100%;
    height: 14px; /* Slightly taller bar */
    background: #111;
    border: 1px inset #666;
    margin-bottom: 12px;
    cursor: pointer;
    position: relative;
}
.player-progress-bar {
    height: 100%;
    width: 0%;
    background: #0f0;
}

.playlist-container {
    height: 120px;
    overflow-y: auto;
    background: black;
    border: 1px inset #555;
    color: #0f0;
    font-family: 'Courier New', Courier, monospace;
    font-size: 11px;
    padding: 5px;
}
.playlist-item {
    cursor: pointer;
    padding: 4px; /* Easier to click */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.playlist-item:hover {
    background: #0f0;
    color: black;
}
.playlist-item.active {
    background: #000080;
    color: white;
}


/* TASKBAR */
#taskbar {
    position: fixed; bottom: 0; left: 0; width: 100%; height: 45px;
    background: var(--win-gray); border-top: 2px solid var(--win-light);
    display: flex; align-items: center; padding: 2px; z-index: 99999;
}
.task-btn {
    height: 34px; background: var(--win-gray);
    border: 2px solid; border-color: var(--win-light) var(--win-darker) var(--win-darker) var(--win-light);
    display: flex; align-items: center; padding: 0 12px;
    font-weight: bold; font-family: Tahoma, sans-serif; cursor: pointer; margin-left: 4px; font-size: 14px;
}
.task-btn:active { border-color: var(--win-darker) var(--win-light) var(--win-light) var(--win-darker); }
.task-btn img { margin-right: 6px; height: 22px; }
.clock {
    margin-left: auto; border: 2px inset var(--win-gray);
    padding: 5px 10px; font-family: Tahoma, sans-serif; font-size: 14px; margin-right: 5px;
}

/* SCRATCH HELPER */
#scratch-helper {
    position: fixed; bottom: 60px; right: 20px; width: 140px;
    cursor: pointer; z-index: 9999; text-align: center;
}
.speech-bubble {
    background: #ffffe0; border: 2px solid #000; padding: 8px;
    font-size: 16px; font-weight: bold; border-radius: 8px; margin-bottom: 8px;
    box-shadow: 3px 3px 0 rgba(0,0,0,0.4); color: black;
    opacity: 0; transition: opacity 0.3s; line-height: 1.2;
}

/* MOBILE OPTIMIZATION */
@media (max-width: 768px) {
    #desktop {
        overflow-y: auto; display: flex !important;
        flex-direction: column; align-items: center;
        padding-top: 10px; padding-bottom: 80px; 
    }
    #icon-area {
        position: relative; width: 100%; top: auto; left: auto;
        display: grid; grid-template-columns: repeat(4, 1fr);
        row-gap: 30px; padding: 10px; justify-items: center;
        margin-bottom: 30px; flex-shrink: 0; 
    }
    .icon { margin: 0; width: auto; }
    .icon img { width: 40px; height: 40px; }
    .icon div { font-size: 10px; }
    .window {
        position: relative !important; top: auto !important; left: auto !important;
        width: 95% !important; margin-bottom: 20px; 
        height: auto; max-height: none; flex-shrink: 0; 
    }
    .title-bar { cursor: default; }

    /* MOBILE PLAYER ENHANCEMENTS */
    /* Forces buttons to span the full width and be much taller on mobile */
    .player-controls .player-btn {
        padding: 12px 0; /* Taller touch targets */
        flex: 1; /* Distribute space evenly */
        margin: 0 2px; /* Small gap */
        font-size: 20px; /* Even bigger icon */
    }
}