/* ==========================================================================
   AcuityOS v3.0 Stylesheet - The Brutalist Amber Cyber System
   ========================================================================== */

/* ─── Variables & Tokens ────────────────────────────────────────────────── */
:root {
    --bg-dark: #0a0806;       /* Warm Charcoal */
    --primary: #FFB300;       /* Amber Phosphorus Glow */
    --primary-dim: rgba(255, 179, 0, 0.3);
    --secondary: #FF6F00;     /* Orange Warning */
    --warning: #D50000;       /* Crimson Security Alert */
    --text: #D7CCC8;          /* Light Sepia Text */
    --text-bright: #FFE082;   /* Bright Amber Text */
    --font-mono: "Courier New", Courier, monospace;
    --font-sans: "Helvetica Neue", Arial, sans-serif;
    --border-radius: 4px;     /* Brutalist: sharp or minimally rounded corners */
    --transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ─── Global Reset & Body ────────────────────────────────────────────────── */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    user-select: none;
}

body, html {
    width: 100%;
    height: 100%;
    overflow: hidden;
    background-color: var(--bg-dark);
    font-family: var(--font-sans);
    color: var(--text);
}

/* ─── CRT Scanline Screen Filters ────────────────────────────────────────── */
.crt-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(rgba(18, 16, 12, 0) 50%, rgba(0, 0, 0, 0.25) 50%), 
                linear-gradient(90deg, rgba(255, 0, 0, 0.04), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.04));
    background-size: 100% 3px, 5px 100%;
    pointer-events: none;
    z-index: 9999;
}

/* ─── 3D GAME STAGE & WRAPPER ────────────────────────────────────────────── */
#game-stage {
    width: 100%;
    height: 100%;
    position: relative;
    perspective: 1200px;
    transform-style: preserve-3d;
    overflow: hidden;
    background-color: #030202;
}

/* 3D Monitor Shell */
#screen-container {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    transform-origin: center center;
    transition: transform 2.5s cubic-bezier(0.25, 1, 0.5, 1);
    z-index: 10;
    transform-style: preserve-3d;
}

/* ─── Screen Panels (Boot vs Desktop) ─────────────────────────────────────── */
.screen-panel {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    transition: opacity 0.3s ease;
}

.hidden {
    display: none !important;
    opacity: 0;
    pointer-events: none;
}

/* ─── 1. Boot Screen ─────────────────────────────────────────────────────── */
#boot-screen {
    background-color: #050403;
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: var(--font-mono);
    border: 15px solid #1c140c; /* Brutalist monitor frame */
}

.boot-container {
    width: 90%;
    max-width: 680px;
    padding: 30px;
    border: 2px solid var(--primary-dim);
    background-color: rgba(10, 8, 6, 0.95);
    box-shadow: 0 0 30px rgba(255, 179, 0, 0.05);
    border-radius: var(--border-radius);
}

.boot-logo {
    font-size: 9px;
    line-height: 1.1;
    color: var(--primary);
    text-shadow: 0 0 6px var(--primary);
    margin-bottom: 25px;
    white-space: pre;
}

.boot-text-engine {
    line-height: 1.6;
}

.boot-line {
    margin-bottom: 8px;
    color: var(--text);
}

.login-prompt {
    display: flex;
    align-items: center;
    margin-top: 15px;
    font-size: 16px;
    color: var(--primary);
}

#agent-input, #password-input {
    background: transparent;
    border: none;
    outline: none;
    color: var(--primary);
    font-family: var(--font-mono);
    font-size: 16px;
    text-transform: uppercase;
    width: 300px;
    caret-color: transparent;
}

.blink-cursor {
    animation: blink 0.9s infinite;
    color: var(--primary);
}

.error-msg {
    color: var(--warning);
    margin-top: 12px;
    font-weight: bold;
}

.boot-instruction {
    margin-top: 25px;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.3);
    border-top: 1px dashed rgba(255, 255, 255, 0.1);
    padding-top: 10px;
}

@keyframes blink {
    50% { opacity: 0; }
}

/* ─── 2. Virtual Desktop ─────────────────────────────────────────────────── */
#desktop {
    background: radial-gradient(circle, #21150b 0%, #070503 100%);
    background-size: cover;
    border: 15px solid #1a120c; /* CRT Monitor border shell */
}

.desktop-grid {
    position: absolute;
    top: 55px;
    left: 30px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    z-index: 10;
}

.desktop-icon {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    cursor: pointer;
    border-radius: var(--border-radius);
    transition: var(--transition);
    position: relative;
    border: 1px solid transparent;
}

.desktop-icon:hover {
    background-color: rgba(255, 179, 0, 0.05);
    border: 1px solid rgba(255, 179, 0, 0.15);
}

.icon-visual {
    font-size: 34px;
    margin-bottom: 6px;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.5));
    transition: var(--transition);
}

.desktop-icon:hover .icon-visual {
    transform: scale(1.08);
}

.icon-label {
    font-size: 11px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.7);
    text-shadow: 0 2px 4px rgba(0,0,0,0.9);
    text-align: center;
}

.mail-badge {
    position: absolute;
    top: 2px;
    right: 12px;
    background-color: var(--secondary);
    color: var(--bg-dark);
    font-size: 10px;
    font-weight: bold;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: pulse 1.2s infinite;
}

@keyframes pulse {
    0% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(255, 111, 0, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 5px rgba(255, 111, 0, 0); }
    100% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(255, 111, 0, 0); }
}

/* ─── ENVIRONMENTAL STICKY NOTES ─────────────────────────────────────────── */
.sticky-note {
    position: absolute;
    width: 200px;
    background-color: #ffd54f;
    color: #424242;
    padding: 12px;
    border-radius: 2px;
    box-shadow: 2px 4px 10px rgba(0,0,0,0.4);
    font-family: var(--font-sans);
    font-size: 11px;
    line-height: 1.4;
    z-index: 5;
    border-top: 5px solid #ffb300;
}

.sticky-note.note-red {
    background-color: #ff8a80;
    border-top: 5px solid #d50000;
    color: #3e2723;
}

.note-header {
    font-weight: bold;
    font-size: 9px;
    margin-bottom: 5px;
    letter-spacing: 0.5px;
    opacity: 0.6;
}

/* ─── 3. Floating Windows (Amber Glassmorphism) ────────────────────────── */
.window {
    position: absolute;
    display: flex;
    flex-direction: column;
    border-radius: var(--border-radius);
    z-index: 100;
    overflow: hidden;
    transition: box-shadow 0.15s ease;
}

.window.active-window {
    z-index: 500;
    border: 1px solid var(--primary);
    box-shadow: 0 8px 32px 0 rgba(255, 179, 0, 0.25);
}

.glassmorphic {
    background: rgba(20, 15, 10, 0.88);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 179, 0, 0.2);
    box-shadow: 0 8px 24px 0 rgba(0, 0, 0, 0.6);
}

.window-header {
    height: 32px;
    background-color: rgba(30, 22, 14, 0.95);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 10px;
    cursor: move;
    border-bottom: 1px solid rgba(255, 179, 0, 0.1);
}

.window-title {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-bright);
    letter-spacing: 0.5px;
    font-family: var(--font-mono);
}

.window.active-window .window-title {
    color: var(--primary);
    text-shadow: 0 0 4px rgba(255, 179, 0, 0.4);
}

.window-close-btn {
    background: transparent;
    border: none;
    outline: none;
    color: rgba(255, 255, 255, 0.4);
    font-size: 16px;
    cursor: pointer;
    line-height: 1;
    transition: var(--transition);
}

.window-close-btn:hover {
    color: var(--warning);
}

.window-content {
    flex-grow: 1;
    overflow: auto;
    background-color: rgba(10, 8, 6, 0.5);
}

/* ─── 4. Upper Top Menu Bar ────────────────────────────────────────────── */
.top-menu-bar {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 30px;
    background: rgba(15, 11, 7, 0.9);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 179, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 15px;
    font-size: 11px;
    z-index: 7000;
    font-family: var(--font-mono);
}

.menu-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.menu-logo {
    color: var(--primary);
    font-weight: 900;
}

.menu-item {
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
}

.menu-item:hover {
    color: var(--text-bright);
}

.case-banner {
    color: var(--secondary);
    font-weight: bold;
    letter-spacing: 0.5px;
    animation: pulse-brightness 2s infinite alternate;
}

@keyframes pulse-brightness {
    0% { opacity: 0.7; }
    100% { opacity: 1; }
}

.menu-right {
    display: flex;
    align-items: center;
    gap: 15px;
    color: rgba(255, 255, 255, 0.5);
}

.menu-stat span {
    font-weight: bold;
}

#threat-indicator.threat-ok {
    color: var(--primary);
}

#threat-indicator.threat-alert {
    color: var(--warning);
    animation: alert-blink 0.5s infinite alternate;
}

@keyframes alert-blink {
    0% { opacity: 0.4; }
    100% { opacity: 1; }
}

.status-blink {
    color: var(--primary);
    animation: alert-blink 1.5s infinite alternate;
}

/* ─── 5. Mail App Layout ─────────────────────────────────────────────────── */
.mail-layout {
    display: flex;
    height: calc(100% - 32px);
}

.mail-sidebar {
    width: 140px;
    border-right: 1px solid rgba(255, 179, 0, 0.1);
    display: flex;
    flex-direction: column;
    background-color: rgba(10, 8, 6, 0.3);
}

.inbox-title {
    font-size: 10px;
    font-weight: bold;
    padding: 8px 10px;
    color: rgba(255, 255, 255, 0.35);
    text-transform: uppercase;
}

.mail-list {
    flex-grow: 1;
    overflow: auto;
}

.mail-item {
    padding: 8px 10px;
    border-bottom: 1px solid rgba(255, 179, 0, 0.05);
    cursor: pointer;
}

.mail-item:hover {
    background-color: rgba(255, 179, 0, 0.03);
}

.mail-item.unread {
    border-left: 3px solid var(--primary);
}

.mail-item.active-mail {
    background-color: rgba(255, 179, 0, 0.06);
}

.mail-item-sender {
    font-size: 10px;
    font-weight: bold;
    color: var(--text-bright);
}

.mail-item-subject {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.5);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mail-body {
    flex-grow: 1;
    padding: 12px;
    display: flex;
    flex-direction: column;
    overflow: auto;
}

.mail-subject {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-bright);
    margin-bottom: 4px;
}

.mail-sender {
    font-size: 10px;
    color: var(--secondary);
    margin-bottom: 8px;
}

.mail-divider {
    border: none;
    border-top: 1px solid rgba(255, 179, 0, 0.1);
    margin-bottom: 10px;
}

.mail-text {
    font-size: 11.5px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.8);
    white-space: pre-wrap;
}

/* ─── 6. File Explorer Layout ────────────────────────────────────────────── */
.explorer-layout {
    display: flex;
    height: calc(100% - 32px);
}

.explorer-sidebar {
    width: 110px;
    border-right: 1px solid rgba(255, 179, 0, 0.1);
    padding: 8px;
    background-color: rgba(10, 8, 6, 0.2);
}

.sidebar-item {
    font-size: 10px;
    padding: 5px 8px;
    cursor: pointer;
    border-radius: 2px;
    margin-bottom: 4px;
    color: rgba(255, 255, 255, 0.6);
}

.sidebar-item:hover, .sidebar-item.active {
    background-color: rgba(255, 179, 0, 0.05);
    color: var(--primary);
}

.explorer-grid {
    flex-grow: 1;
    padding: 12px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(65px, 1fr));
    grid-auto-rows: max-content;
    gap: 12px;
    overflow: auto;
}

.explorer-file {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    width: 65px;
    padding: 4px;
    border-radius: 2px;
    border: 1px solid transparent;
}

.explorer-file:hover {
    background-color: rgba(255, 179, 0, 0.05);
    border: 1px solid rgba(255, 179, 0, 0.1);
}

.file-icon {
    font-size: 26px;
    margin-bottom: 2px;
}

.file-name {
    font-size: 9px;
    color: rgba(255, 255, 255, 0.85);
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    width: 100%;
}

/* ─── 7. Central Database Layout ─────────────────────────────────────────── */
.database-layout {
    display: flex;
    flex-direction: column;
    height: calc(100% - 32px);
    background-color: rgba(10, 8, 6, 0.6);
}

.db-search-bar {
    display: flex;
    align-items: center;
    padding: 6px 10px;
    background-color: rgba(30, 22, 14, 0.4);
    border-bottom: 1px solid rgba(255, 179, 0, 0.1);
}

.db-search-icon {
    font-size: 12px;
    margin-right: 8px;
}

#db-search-input {
    flex-grow: 1;
    background: transparent;
    border: none;
    outline: none;
    color: var(--text-bright);
    font-size: 11px;
}

.db-main-content {
    display: flex;
    flex-grow: 1;
    overflow: hidden;
}

.db-sidebar {
    width: 150px;
    border-right: 1px solid rgba(255, 179, 0, 0.1);
    display: flex;
    flex-direction: column;
    background-color: rgba(15, 11, 7, 0.3);
}

.db-list-title {
    font-size: 9px;
    font-weight: bold;
    padding: 6px 10px;
    color: rgba(255, 255, 255, 0.3);
    text-transform: uppercase;
}

.db-profile-list {
    flex-grow: 1;
    overflow: auto;
}

.db-profile-item {
    padding: 8px 10px;
    border-bottom: 1px solid rgba(255, 179, 0, 0.05);
    cursor: pointer;
    font-size: 10.5px;
    color: rgba(255, 255, 255, 0.65);
}

.db-profile-item:hover {
    background-color: rgba(255, 179, 0, 0.03);
    color: var(--primary);
}

.db-profile-item.active-profile {
    background-color: rgba(255, 179, 0, 0.06);
    border-left: 2px solid var(--primary);
    color: var(--primary);
}

.db-dossier {
    flex-grow: 1;
    padding: 12px;
    overflow: auto;
}

.dossier-placeholder {
    margin-top: 80px;
    text-align: center;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.3);
    line-height: 1.5;
}

.dossier-header {
    display: flex;
    gap: 12px;
    margin-bottom: 12px;
}

.dossier-avatar {
    width: 64px;
    height: 64px;
    border: 1px solid var(--primary-dim);
    background-color: #050403;
    font-family: var(--font-mono);
    font-size: 5px;
    line-height: 1.1;
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    white-space: pre;
    border-radius: 2px;
}

.dossier-meta {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
}

.dossier-name {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-bright);
}

.dossier-tag {
    font-size: 8px;
    font-weight: bold;
    padding: 1px 5px;
    border-radius: 2px;
    width: max-content;
    text-transform: uppercase;
}

.tag-red { background-color: rgba(213, 0, 0, 0.2); border: 1px solid var(--warning); color: var(--warning); }
.tag-green { background-color: rgba(255, 179, 0, 0.2); border: 1px solid var(--primary); color: var(--primary); }
.tag-orange { background-color: rgba(255, 111, 0, 0.2); border: 1px solid var(--secondary); color: var(--secondary); }

.dossier-section {
    margin-bottom: 12px;
}

.dossier-sec-title {
    font-size: 10px;
    font-weight: bold;
    color: var(--secondary);
    text-transform: uppercase;
    border-bottom: 1px solid rgba(255, 111, 0, 0.2);
    padding-bottom: 2px;
    margin-bottom: 6px;
}

.dossier-sec-text {
    font-size: 11px;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.8);
}

.dossier-sec-text table {
    width: 100%;
    border-collapse: collapse;
    font-size: 10.5px;
}

.dossier-sec-text td {
    padding: 3px 0;
    border-bottom: 1px dashed rgba(255, 179, 0, 0.05);
}

.dossier-sec-text td.label {
    color: rgba(255, 255, 255, 0.45);
    width: 100px;
}

.override-trigger-btn {
    background-color: var(--secondary);
    border: none;
    color: var(--bg-dark);
    font-size: 10px;
    font-weight: bold;
    padding: 5px 10px;
    cursor: pointer;
    border-radius: 2px;
    margin-top: 8px;
}

.override-trigger-btn:hover {
    background-color: var(--primary);
}

/* ─── 8. Audio Scrubber Layout ───────────────────────────────────────────── */
.scrubber-layout {
    display: flex;
    flex-direction: column;
    height: calc(100% - 32px);
    background-color: rgba(10, 8, 6, 0.6);
}

.scrubber-tape-deck {
    height: 120px;
    background-color: #120e0a;
    border-bottom: 1px solid rgba(255, 179, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: space-around;
    padding: 10px;
    position: relative;
}

.reel {
    width: 70px;
    height: 70px;
    border: 3px dashed var(--primary-dim);
    border-radius: 50%;
    position: relative;
    animation: rotate-reel 4s linear infinite;
    animation-play-state: paused;
}

.reel::before {
    content: '';
    position: absolute;
    width: 14px;
    height: 14px;
    background-color: var(--primary);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 50%;
}

@keyframes rotate-reel {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.tape-wave-indicator {
    flex-grow: 1;
    height: 50px;
    margin: 0 20px;
    background-color: rgba(0,0,0,0.6);
    border: 1px solid rgba(255, 179, 0, 0.15);
    position: relative;
    border-radius: 2px;
    overflow: hidden;
}

.wave-track {
    width: 100%;
    height: 100%;
    background: repeating-linear-gradient(90deg, transparent, transparent 15px, rgba(255,179,0,0.06) 15px, rgba(255,179,0,0.06) 30px),
                linear-gradient(0deg, transparent 48%, var(--primary-dim) 50%, transparent 52%);
}

.progress-line {
    position: absolute;
    width: 2px;
    height: 100%;
    background-color: var(--secondary);
    top: 0;
    left: 0;
    box-shadow: 0 0 6px var(--secondary);
}

.scrubber-controls {
    flex-grow: 1;
    padding: 12px;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
}

.scrubber-dropzone {
    border: 2px dashed var(--primary-dim);
    background-color: rgba(0,0,0,0.3);
    height: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: var(--border-radius);
    margin-bottom: 8px;
    transition: var(--transition);
}

.scrubber-dropzone.dragover {
    background-color: rgba(255, 179, 0, 0.08);
    border-color: var(--primary);
}

.drop-icon {
    font-size: 20px;
    margin-bottom: 3px;
}

.drop-text {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.4);
    font-family: var(--font-mono);
}

.scrubber-sliders {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.slider-row {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.slider-row label {
    font-size: 9px;
    font-weight: bold;
    color: var(--secondary);
    font-family: var(--font-mono);
}

.slider-row input[type="range"] {
    -webkit-appearance: none;
    width: 100%;
    height: 6px;
    background: #1c140c;
    outline: none;
    border: 1px solid rgba(255,179,0,0.15);
    border-radius: 3px;
}

.slider-row input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    background-color: var(--primary);
    cursor: pointer;
    border-radius: 2px;
    box-shadow: 0 0 4px var(--primary);
}

.val-label {
    font-size: 9px;
    font-family: var(--font-mono);
    color: var(--text-bright);
    align-self: flex-end;
}

.scrubber-status {
    padding: 6px 12px;
    font-size: 9.5px;
    font-family: var(--font-mono);
    background-color: rgba(15, 11, 7, 0.8);
    border-top: 1px solid rgba(255, 179, 0, 0.1);
    color: var(--primary);
}

/* ─── 9. Remote Override Layout ─────────────────────────────────────────── */
.override-layout {
    padding: 15px;
    background-color: rgba(10, 8, 6, 0.5);
    height: calc(100% - 32px);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.override-panel {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.override-desc {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.45);
    line-height: 1.4;
    border-bottom: 1px dashed rgba(255, 179, 0, 0.1);
    padding-bottom: 6px;
}

.form-row {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.form-row label {
    font-size: 9.5px;
    font-weight: bold;
    color: var(--secondary);
    font-family: var(--font-mono);
}

.form-row input {
    background-color: rgba(0,0,0,0.5);
    border: 1px solid rgba(255,179,0,0.2);
    color: var(--text-bright);
    padding: 6px 8px;
    font-family: var(--font-mono);
    font-size: 11px;
    outline: none;
    border-radius: 2px;
}

.form-row input:focus {
    border-color: var(--primary);
}

.override-actions {
    margin-top: 8px;
}

.override-btn {
    width: 100%;
    background-color: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: bold;
    padding: 8px 0;
    cursor: pointer;
    border-radius: 2px;
}

.override-btn:hover {
    background-color: rgba(255,179,0,0.08);
}

.override-status {
    padding: 6px 0;
    font-family: var(--font-mono);
    font-size: 10px;
    color: var(--secondary);
}

/* ─── 10. System Settings Layout ────────────────────────────────────────── */
.settings-layout {
    padding: 15px;
    font-family: var(--font-sans);
    height: calc(100% - 32px);
}

.settings-title {
    font-size: 11px;
    font-weight: bold;
    color: var(--secondary);
    text-transform: uppercase;
    margin-bottom: 12px;
    border-bottom: 1px solid rgba(255,111,0,0.2);
    padding-bottom: 4px;
}

.setting-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255,179,0,0.05);
}

.setting-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.setting-label {
    font-size: 11px;
    font-weight: bold;
    color: var(--text-bright);
}

.setting-desc {
    font-size: 9.5px;
    color: rgba(255,255,255,0.4);
}

/* Switch styling */
.switch {
    position: relative;
    display: inline-block;
    width: 34px;
    height: 20px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.switch-slider {
    position: absolute;
    cursor: pointer;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: #21150b;
    transition: .4s;
    border-radius: 20px;
    border: 1px solid rgba(255,179,0,0.3);
}

.switch-slider:before {
    position: absolute;
    content: "";
    height: 12px;
    width: 12px;
    left: 3px;
    bottom: 3px;
    background-color: rgba(255,179,0,0.5);
    transition: .4s;
    border-radius: 50%;
}

input:checked + .switch-slider {
    background-color: rgba(255,179,0,0.2);
}

input:checked + .switch-slider:before {
    transform: translateX(14px);
    background-color: var(--primary);
}

/* ─── 11. Video CCTV Feed Layout ────────────────────────────────────────── */
.feed-layout {
    display: flex;
    flex-direction: column;
    height: calc(100% - 32px);
    background-color: #000;
}

.cam-screen {
    flex-grow: 1;
    position: relative;
    background-color: #120e0a;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.scanline-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: linear-gradient(rgba(18, 16, 12, 0) 50%, rgba(0, 0, 0, 0.4) 50%);
    background-size: 100% 4px;
    pointer-events: none;
    z-index: 5;
}

.cam-grid {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(rgba(255,179,0,0.04) 1px, transparent 1px);
    background-size: 16px 16px;
}

.cam-label {
    position: absolute;
    top: 10px;
    left: 10px;
    font-family: var(--font-mono);
    font-size: 10px;
    color: var(--warning);
    font-weight: bold;
    z-index: 4;
}

.feed-tape {
    width: 110px;
    height: 70px;
    background-color: #21150b;
    border: 2px solid var(--primary);
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 6;
    box-shadow: 0 0 10px rgba(255,179,0,0.2);
}

.feed-tape-reels {
    width: 36px;
    height: 12px;
    background: repeating-linear-gradient(90deg, transparent, transparent 4px, var(--primary) 4px, var(--primary) 8px);
    margin-bottom: 6px;
}

.feed-tape-label {
    font-size: 8px;
    font-family: var(--font-mono);
    color: var(--text-bright);
    font-weight: bold;
}

.feed-desc {
    padding: 8px 12px;
    font-size: 10px;
    color: rgba(255,255,255,0.4);
    font-family: var(--font-sans);
    line-height: 1.4;
    border-top: 1px solid rgba(255,179,0,0.1);
    background-color: #080605;
}

/* ─── 12. File Viewer & Decryption Lens ──────────────────────────────────── */
.viewer-wrapper {
    position: relative;
    flex-grow: 1;
    overflow: hidden;
}

.viewer-layout {
    padding: 12px;
    font-family: var(--font-mono);
    font-size: 11.5px;
    line-height: 1.6;
    background-color: #070504 !important;
    color: var(--text);
    white-space: pre-wrap;
    height: 100%;
    overflow: auto;
}

/* Redacted text block */
.redacted {
    background-color: #000;
    color: #000 !important;
    display: inline-block;
    padding: 0 4px;
    margin: 0 2px;
    cursor: default;
    transition: background-color 0.2s ease;
}

/* Redacted revealed style */
.redacted-revealed {
    background-color: transparent !important;
    color: var(--primary) !important;
    border-bottom: 1px dashed var(--primary);
}

/* Decryption Lens floating block */
.decrypt-lens {
    position: absolute;
    width: 140px;
    height: 70px;
    border: 2px solid var(--primary);
    background-color: rgba(255, 179, 0, 0.08);
    box-shadow: 0 0 15px rgba(255,179,0,0.3);
    cursor: move;
    z-index: 10;
    pointer-events: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
}

.lens-glass {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    backdrop-filter: brightness(1.2) contrast(1.1);
    -webkit-backdrop-filter: brightness(1.2) contrast(1.1);
}

.lens-label {
    font-size: 8px;
    font-family: var(--font-mono);
    font-weight: bold;
    color: var(--primary);
    z-index: 11;
    pointer-events: none;
    text-shadow: 0 0 4px #000;
}

.viewer-footer {
    padding: 8px 12px;
    background-color: rgba(15,11,7,0.95);
    border-top: 1px solid rgba(255,179,0,0.1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.lens-btn {
    background-color: transparent;
    border: 1px solid var(--primary);
    color: var(--primary);
    font-size: 10px;
    padding: 4px 8px;
    cursor: pointer;
    font-family: var(--font-sans);
    border-radius: 2px;
}

.lens-btn:hover {
    background-color: rgba(255,179,0,0.05);
}

.lens-info {
    font-size: 9px;
    color: rgba(255,255,255,0.4);
}

/* ─── 13. Threat Alarm & Climax Trash Can ────────────────────────────────── */
.alert-banner {
    position: absolute;
    top: 40px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 580px;
    background-color: rgba(213, 0, 0, 0.95);
    border: 1px solid var(--text-bright);
    box-shadow: 0 0 25px rgba(213, 0, 0, 0.6);
    color: var(--text-bright);
    padding: 12px;
    border-radius: var(--border-radius);
    text-align: center;
    z-index: 9000;
    animation: alert-flash-amber 1s infinite alternate;
}

@keyframes alert-flash-amber {
    0% { background-color: rgba(213, 0, 0, 0.95); box-shadow: 0 0 25px rgba(213,0,0,0.6); }
    100% { background-color: rgba(80, 0, 0, 0.95); box-shadow: 0 0 10px rgba(80,0,0,0.2); }
}

.alert-title {
    font-size: 14px;
    font-weight: bold;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.alert-desc {
    font-size: 11.5px;
    margin-bottom: 8px;
}

.alert-desc span {
    font-weight: bold;
    font-size: 14px;
    color: var(--primary);
}

.alert-action {
    font-size: 9.5px;
    font-weight: bold;
    background-color: var(--bg-dark);
    color: var(--secondary);
    display: inline-block;
    padding: 3px 8px;
    border-radius: 2px;
    border: 1px solid var(--secondary);
}

/* Trash Bin Icon */
.desktop-trash {
    position: absolute;
    bottom: 60px;
    right: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    cursor: pointer;
    border-radius: var(--border-radius);
    border: 1px solid var(--warning);
    background-color: rgba(213, 0, 0, 0.05);
    z-index: 10;
    animation: border-glitch 1s infinite alternate;
}

@keyframes border-glitch {
    0% { border-color: var(--warning); }
    100% { border-color: var(--secondary); }
}

.trash-bin-visual {
    font-size: 32px;
    margin-bottom: 4px;
}

.trash-label {
    font-size: 10px;
    color: var(--warning);
    font-weight: bold;
    text-align: center;
}

/* ─── 14. Taskbar ────────────────────────────────────────────────────────── */
.taskbar {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 40px;
    background-color: rgba(15, 11, 7, 0.95);
    border-top: 1px solid rgba(255, 179, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 15px;
    z-index: 8000;
}

.taskbar-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.taskbar-start-btn {
    background-color: var(--primary);
    color: var(--bg-dark);
    font-size: 11px;
    font-weight: bold;
    padding: 5px 10px;
    border-radius: 2px;
    cursor: pointer;
}

.taskbar-start-btn:hover {
    background-color: var(--text-bright);
}

.agent-label {
    font-size: 10.5px;
    color: var(--text);
    font-weight: bold;
}

.taskbar-center {
    display: flex;
    align-items: center;
    gap: 8px;
}

.taskbar-tab {
    font-size: 11px;
    padding: 4px 10px;
    background-color: rgba(255, 179, 0, 0.02);
    border: 1px solid rgba(255, 179, 0, 0.1);
    color: rgba(255, 255, 255, 0.5);
    border-radius: 2px;
    cursor: pointer;
}

.taskbar-tab:hover {
    background-color: rgba(255, 179, 0, 0.05);
}

.taskbar-tab.active {
    background-color: rgba(255, 179, 0, 0.05);
    border: 1px solid var(--primary);
    color: var(--primary);
}

.taskbar-right {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 11px;
}

.taskbar-net-status {
    color: var(--secondary);
    font-weight: bold;
}

.taskbar-clock {
    color: var(--text);
    font-family: var(--font-mono);
}

/* ─── 15. PS1 LOW-POLY 3D ROOM CLIMAX LAYOUT ────────────────────────────── */
#room-3d {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    transform-style: preserve-3d;
    z-index: 1;
}

/* Wall panels forming virtual 3D room coordinates */
.wall {
    position: absolute;
    background-size: 32px 32px;
    image-rendering: pixelated;
}

.wall-back {
    width: 200%;
    height: 200%;
    top: -50%;
    left: -50%;
    transform: translateZ(-800px);
    /* PS1 style wood panels/dark bricks */
    background: repeating-linear-gradient(45deg, #1c1008, #1c1008 10px, #160c06 10px, #160c06 20px);
    border: 4px solid #050302;
}

.wall-left {
    width: 1200px;
    height: 100%;
    top: 0;
    left: -600px;
    transform: rotateY(90deg) translateZ(-400px);
    background: linear-gradient(90deg, #100a06, #1f140c);
}

.wall-right {
    width: 1200px;
    height: 100%;
    top: 0;
    right: -600px;
    transform: rotateY(-90deg) translateZ(-400px);
    background: linear-gradient(-90deg, #100a06, #1f140c);
}

.floor {
    position: absolute;
    width: 200%;
    height: 1200px;
    bottom: -600px;
    left: -50%;
    transform: rotateX(90deg);
    /* Gritty carpet / tile grid */
    background-color: #110d0a;
    background-image: linear-gradient(rgba(255, 179, 0, 0.02) 1px, transparent 1px),
                      linear-gradient(90deg, rgba(255, 179, 0, 0.02) 1px, transparent 1px);
    background-size: 64px 64px;
}

.ceiling {
    position: absolute;
    width: 200%;
    height: 1200px;
    top: -600px;
    left: -50%;
    transform: rotateX(-90deg);
    background-color: #080605;
}

/* Scary anomaly creep silhouette shadow */
#anomaly-silhouette {
    position: absolute;
    width: 180px;
    height: 420px;
    background-color: #000;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) translateZ(-750px);
    transform-style: preserve-3d;
    filter: blur(2px);
    clip-path: polygon(50% 0%, 90% 20%, 70% 50%, 100% 70%, 75% 100%, 25% 100%, 0% 70%, 30% 50%, 10% 20%);
    opacity: 0;
    transition: opacity 10s ease, transform 30s linear;
}

/* Glowing scary red eyes */
#anomaly-silhouette::before {
    content: '⚫ ⚫';
    position: absolute;
    top: 60px;
    left: 50%;
    transform: translateX(-50%);
    color: #ff0000;
    font-size: 16px;
    text-shadow: 0 0 10px #ff0000, 0 0 20px #ff0000;
    letter-spacing: 8px;
    animation: jitter-eyes 0.1s infinite alternate;
}

@keyframes jitter-eyes {
    0% { transform: translateX(-52%) translateY(-1px); }
    100% { transform: translateX(-48%) translateY(1px); }
}

/* Sever Power Cable Desk Container */
#sever-cable-container {
    position: absolute;
    width: 180px;
    height: 120px;
    bottom: -80px;
    left: 50%;
    transform: translateX(-50%) translateZ(-350px) rotateX(20deg);
    z-index: 500;
    cursor: pointer;
    background-color: #1a120c;
    border: 2px solid rgba(255,179,0,0.15);
    border-radius: 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.power-outlet {
    width: 40px;
    height: 40px;
    background-color: #0c0806;
    border: 1px solid rgba(255,179,0,0.3);
    border-radius: 5px;
    position: relative;
}

.power-outlet::before {
    content: '▪▪';
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    color: rgba(255,179,0,0.2);
    font-size: 16px;
}

#sever-cable {
    width: 25px;
    height: 50px;
    background-color: #3e2723;
    border: 1.5px solid var(--primary);
    position: absolute;
    top: 15px;
    border-radius: 3px;
    box-shadow: 0 0 15px var(--primary-dim);
}

.cable-glow {
    position: absolute;
    top: 15px;
    width: 25px;
    height: 50px;
    border-radius: 3px;
    box-shadow: 0 0 20px var(--primary);
    animation: alert-blink 1s infinite alternate;
    pointer-events: none;
}

#sever-cable.cable-unplugged {
    transform: rotate(45deg) translateY(60px);
    background-color: #1e1e1e;
    border-color: #555;
    box-shadow: none;
}

.cable-label {
    color: var(--primary);
    font-size: 8.5px;
    font-family: var(--font-mono);
    font-weight: bold;
    text-align: center;
    margin-top: 15px;
    text-shadow: 0 0 4px #000;
}

/* ─── CLIMAX 3D PERSPECTIVE STATE SHIFT ─────────────────────────────────── */
.climax-3d-tilt #screen-container {
    transform: translateZ(-200px) rotateX(16deg) rotateY(-8deg) scale(0.9);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.95);
    border: 12px solid #0f0b07;
}

/* ─── Glitch & Shake Animations ────────────────────────────────────────── */
@keyframes shake {
    0% { transform: translate(0, 0) rotate(0deg); }
    10% { transform: translate(-2px, -3px) rotate(-0.5deg); }
    20% { transform: translate(-3px, 0px) rotate(0.8deg); }
    30% { transform: translate(0px, 2px) rotate(0deg); }
    40% { transform: translate(2px, -1px) rotate(0.5deg); }
    50% { transform: translate(-1px, 2px) rotate(-0.8deg); }
    60% { transform: translate(-3px, 1px) rotate(0deg); }
    70% { transform: translate(2px, 1px) rotate(-0.5deg); }
    80% { transform: translate(-1px, -1px) rotate(0.8deg); }
    90% { transform: translate(2px, 2px) rotate(0deg); }
    100% { transform: translate(1px, -2px) rotate(-0.5deg); }
}

@keyframes crt-flicker {
    0% { filter: brightness(1) contrast(1); }
    20% { filter: brightness(0.85) contrast(0.95); opacity: 0.96; }
    40% { filter: brightness(1.2) contrast(1.1) hue-rotate(5deg); }
    60% { filter: brightness(0.8) contrast(0.9); opacity: 0.93; }
    80% { filter: brightness(1.3) contrast(1.15) hue-rotate(-5deg); }
    100% { filter: brightness(1) contrast(1); }
}
