/* style.css */
        @import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;600&family=Press+Start+2P&display=swap');

        :root {
            --bg: #120d02;
            --text: #ffb000;
            --dim: rgba(255, 176, 0, 0.2);
            --invert: #000;
            --font-main: 'JetBrains Mono', monospace;
        }

        /* --- Standard Themes --- */
        .theme-amber {
            --bg: #120d02;
            --text: #ffb000;
            --dim: rgba(255, 176, 0, 0.2);
            --invert: #000;
        }

        .theme-amber-light {
            --bg: #ffb000;
            --text: #120d02;
            --dim: rgba(0, 0, 0, 0.2);
            --invert: #ffb000;
        }

        .theme-green {
            --bg: #050f05;
            --text: #00ff41;
            --dim: rgba(0, 255, 65, 0.2);
            --invert: #000;
        }

        .theme-green-light {
            --bg: #00ff41;
            --text: #050f05;
            --dim: rgba(0, 0, 0, 0.2);
            --invert: #00ff41;
        }

        .theme-teal {
            --bg: #002b2b;
            --text: #00ffff;
            --dim: rgba(0, 255, 255, 0.2);
            --invert: #000;
        }

        .theme-teal-light {
            --bg: #00ffff;
            --text: #002b2b;
            --dim: rgba(0, 0, 0, 0.2);
            --invert: #00ffff;
        }

        .theme-eva {
            --bg: #2e004d;
            --text: #a7ff00;
            --dim: rgba(167, 255, 0, 0.2);
            --invert: #2e004d;
        }

        .theme-bw {
            --bg: #000;
            --text: #fff;
            --dim: rgba(255, 255, 255, 0.2);
            --invert: #000;
        }

        .theme-paper {
            --bg: #fff;
            --text: #000;
            --dim: rgba(0, 0, 0, 0.1);
            --invert: #fff;
        }

        .theme-mix-eva {
            --bg: #15081a;
            --text: #57f2cc;
            --dim: rgba(87, 242, 204, 0.2);
            --invert: #2e004d;
        }

        .theme-gruvbox-dark {
            --bg: #282828;
            --text: #fabd2f;
            --dim: rgba(250, 189, 47, 0.2);
            --invert: #282828;
        }

        .theme-gruvbox-light {
            --bg: #fbf1c7;
            --text: #3c3836;
            --dim: rgba(60, 56, 54, 0.1);
            --invert: #fbf1c7;
        }

        .theme-kanagawa-dark {
            --bg: #1F1F28;
            --text: #DCA561;
            --dim: rgba(220, 165, 97, 0.2);
            --invert: #1F1F28;
        }

        .theme-kanagawa-light {
            --bg: #F2ECBC;
            --text: #54546D;
            --dim: rgba(84, 84, 109, 0.1);
            --invert: #F2ECBC;
        }

        .theme-zorin-dark {
            --bg: #26292e;
            --text: #00d084;
            --dim: rgba(0, 208, 132, 0.2);
            --invert: #26292e;
        }

        .theme-zorin-light {
            --bg: #ffffff;
            --text: #176f4c;
            --dim: rgba(23, 111, 76, 0.1);
            --invert: #ffffff;
        }

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

        body {
            background-color: var(--bg);
            color: var(--text);
            font-family: var(--font-main);
            font-size: 1rem;
            height: 100vh;
            overflow: hidden;
            transition: all 0.3s ease;
        }

        button,
        input,
        textarea,
        select {
            font-family: var(--font-main);
        }

        .scroll-area {
            height: auto;
            max-height: 400px;
            overflow-y: auto;
            border: 1px dashed var(--dim);
            padding: 10px;
        }

        /* PRINT STYLES */
        @media print {

            .crt-overlay,
            #matrix-bg,
            #boot,
            #clown-overlay,
            header,
            nav,
            footer,
            .theme-menu-container,
            .btn,
            #sound-toggle,
            #funny-phrase {
                display: none !important;
            }

            html,
            body {
                width: 100%;
                height: auto !important;
                overflow: visible !important;
                margin: 0 !important;
                padding: 0 !important;
                background: white !important;
                color: black !important;
            }

            .screen,
            .frame,
            .container {
                width: 100%;
                height: auto !important;
                overflow: visible !important;
                display: block !important;
                position: static !important;
                border: none !important;
                box-shadow: none !important;
            }

            main,
            #view {
                width: 100% !important;
                height: auto !important;
                overflow: visible !important;
                border: none !important;
                margin: 0 !important;
                padding: 0 !important;
                display: block !important;
            }

            * {
                text-shadow: none !important;
                filter: none !important;
                color: black !important;
            }

            .photo {
                filter: grayscale(0) !important;
                border: 1px solid #000 !important;
            }

            a {
                text-decoration: none !important;
                color: black !important;
            }

            h1,
            h2,
            h3,
            h4 {
                border-bottom-color: #000 !important;
            }

            .exp-item {
                border-left-color: #000 !important;
            }

            .scroll-area {
                height: auto !important;
                max-height: none !important;
                overflow: visible !important;
                border: 1px solid #ddd !important;
            }

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

        .crt-overlay {
            position: fixed;
            inset: 0;
            pointer-events: none;
            z-index: 999;
            background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.1) 50%),
                linear-gradient(90deg, rgba(255, 0, 0, 0.02), rgba(0, 255, 0, 0.01), rgba(0, 0, 255, 0.02));
            background-size: 100% 3px, 3px 100%;
            opacity: 0.3;
        }

        .screen {
            display: flex;
            flex-direction: column;
            height: 100vh;
            padding: 5px;
        }

        .frame {
            border: 3px double var(--text);
            flex-grow: 1;
            display: flex;
            flex-direction: column;
            overflow: hidden;
            position: relative;
            box-shadow: inset 0 0 50px var(--dim);
        }

        @keyframes glitch-fx {
            0% {
                transform: translate(0);
                filter: invert(0);
            }

            20% {
                transform: translate(-4px, 2px);
                filter: invert(1);
            }

            40% {
                transform: translate(4px, -2px);
                filter: hue-rotate(90deg);
            }

            60% {
                transform: scale(1.02);
                filter: brightness(1.5);
            }

            100% {
                transform: translate(0);
            }
        }

        .glitch-active {
            animation: glitch-fx 0.1s infinite !important;
        }

        header {
            border-bottom: 2px solid var(--text);
            padding: 8px 15px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            background: var(--bg);
            gap: 10px;
        }

        .container {
            display: flex;
            flex-direction: column;
            flex-grow: 1;
            overflow: hidden;
        }

        @media (min-width: 768px) {
            .container {
                flex-direction: row;
            }
        }

        nav {
            background: var(--bg);
            border-right: 2px solid var(--text);
            display: flex;
            flex-direction: column;
            width: 180px;
            flex-shrink: 0;
            z-index: 10;
            overflow-y: auto;
            max-height: 100%;
        }

        @media (max-width: 767px) {
            .menu-toggle {
                display: inline-flex;
            }

            nav {
                width: 100%;
                height: auto;
                border-right: none;
                border-bottom: 2px solid var(--text);
                flex-direction: column;
                flex-wrap: nowrap;
                display: none;
            }

            body.nav-open nav {
                display: flex;
            }
        }

        nav button {
            background: transparent;
            border: none;
            color: var(--text);
            font-family: inherit;
            font-size: 1rem;
            text-align: left;
            padding: 12px 15px;
            cursor: pointer;
            text-transform: lowercase;
            white-space: pre;
            display: flex;
            align-items: center;
            gap: 10px;
        }

        nav button .nav-label {
            margin-left: 4px;
        }

        .nav-icon {
            width: 16px;
            height: 16px;
            fill: currentColor;
            transition: transform 0.2s;
        }

        nav button:hover .nav-icon {
            transform: scale(1.2) rotate(5deg);
        }

        /* HIDE ICONS IF TOGGLED */
        body.no-icons .nav-icon {
            display: none;
        }

        nav button:hover {
            background: var(--dim);
        }

        nav button.active {
            background: var(--text);
            color: var(--invert);
        }

        #nav-admin {
            display: none;
            margin-top: auto;
            border-top: 2px solid var(--text);
            color: red;
        }

        .menu-toggle {
            display: none;
            align-items: center;
            gap: 6px;
            background: transparent;
            border: 1px solid var(--text);
            color: var(--text);
            padding: 6px 10px;
            cursor: pointer;
            text-transform: uppercase;
            font-size: 0.85rem;
        }

        @media (max-width: 767px) {
            .menu-toggle {
                display: inline-flex;
            }
        }

        main {
            flex-grow: 1;
            padding: 20px;
            overflow-y: auto;
            scrollbar-width: thin;
            scrollbar-color: var(--text) transparent;
            position: relative;
        }

        @media (min-width: 768px) {
            main {
                padding: 30px 40px;
            }
        }

        .typing::after {
            content: '_';
            animation: blink 0.8s infinite;
        }

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

        .photo {
            width: 130px;
            height: 170px;
            border: 2px solid var(--text);
            filter: grayscale(1);
            object-fit: cover;
            margin-bottom: 10px;
            background: #222;
        }

        .exp-item {
            border-left: 2px solid var(--text);
            padding-left: 15px;
            margin-bottom: 20px;
        }

        .exp-item h4 {
            font-size: 1.1rem;
            margin-bottom: 2px;
        }

        .obs-tabs {
            display: flex;
            gap: 8px;
            border-bottom: 1px solid var(--text);
            padding-bottom: 10px;
            margin-bottom: 15px;
            flex-wrap: wrap;
        }

        .obs-tab-btn {
            background: transparent;
            border: 1px solid var(--text);
            color: var(--text);
            padding: 4px 10px;
            cursor: pointer;
            font-family: inherit;
            font-size: 0.85rem;
        }

        .obs-tab-btn.active {
            background: var(--text);
            color: var(--invert);
        }

        .obs-main {
            display: flex;
            flex-direction: column;
            gap: 15px;
        }

        @media (min-width: 768px) {
            .obs-main {
                flex-direction: row;
                height: 400px;
            }
        }

        .obs-files {
            width: 100%;
            border-bottom: 1px dashed var(--text);
            display: flex;
            flex-direction: column;
            overflow-y: auto;
        }

        @media (min-width: 768px) {
            .obs-files {
                width: 220px;
                border-bottom: none;
                border-right: 1px dashed var(--text);
                padding-right: 10px;
            }
        }

        .obs-file-item {
            background: none;
            border: none;
            color: var(--text);
            text-align: left;
            padding: 10px;
            cursor: pointer;
            font-family: inherit;
            font-size: 0.9rem;
            opacity: 0.7;
            border-bottom: 1px solid rgba(255, 255, 255, 0.05);
        }

        .obs-file-item.active {
            opacity: 1;
            font-weight: bold;
            border-left: 3px solid var(--text);
            background: var(--dim);
        }

        .obs-viewer {
            flex-grow: 1;
            padding: 15px;
            overflow-y: auto;
            background: rgba(0, 0, 0, 0.05);
            border: 1px dashed var(--dim);
            font-size: 0.9rem;
            line-height: 1.5;
            white-space: pre-wrap;
        }

        .blog-list {
            display: flex;
            flex-direction: column;
            gap: 20px;
        }

        .blog-entry {
            border: 1px solid var(--text);
            padding: 15px;
            background: rgba(0, 0, 0, 0.1);
            cursor: pointer;
            transition: 0.2s;
            position: relative;
        }

        .blog-entry:hover {
            transform: translateX(5px);
            background: var(--dim);
            border-left: 5px solid var(--text);
        }

        .blog-header {
            display: flex;
            justify-content: space-between;
            align-items: baseline;
            margin-bottom: 8px;
            border-bottom: 1px dashed var(--dim);
            padding-bottom: 5px;
            flex-wrap: wrap;
            gap: 10px;
        }

        .blog-title {
            font-size: 1.1rem;
            font-weight: bold;
        }

        .blog-date {
            font-size: 0.8rem;
            opacity: 0.7;
        }

        .blog-snippet {
            font-size: 0.9rem;
            opacity: 0.9;
            line-height: 1.4;
        }

        .blog-full {
            line-height: 1.6;
            white-space: pre-wrap;
        }

        .tag {
            font-size: 0.7rem;
            background: var(--text);
            color: var(--bg);
            padding: 2px 5px;
            border-radius: 2px;
            margin-right: 5px;
        }

        .todo-container {
            max-width: 600px;
            margin: 0 auto;
        }

        .todo-stats {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
            gap: 10px;
            align-items: center;
            margin: 10px 0;
        }

        .progress {
            position: relative;
            background: rgba(0,0,0,0.2);
            border: 1px solid var(--dim);
            height: 10px;
            border-radius: 999px;
            overflow: hidden;
        }

        .progress span {
            display: block;
            height: 100%;
            background: linear-gradient(90deg, var(--dim), var(--text));
        }

        .todo-input-group {
            display: flex;
            gap: 10px;
            margin-bottom: 20px;
            border-bottom: 2px solid var(--text);
            padding-bottom: 20px;
        }

        .todo-input {
            background: rgba(0, 0, 0, 0.2);
            border: 1px solid var(--text);
            color: var(--text);
            padding: 10px;
            flex-grow: 1;
            font-family: inherit;
            font-size: 1rem;
            outline: none;
        }

        .todo-input:focus {
            background: var(--dim);
        }

        .todo-list {
            display: flex;
            flex-direction: column;
            gap: 5px;
        }

        .todo-item {
            padding: 10px;
            border-bottom: 1px dashed var(--dim);
            cursor: pointer;
            display: flex;
            align-items: flex-start;
            gap: 15px;
            transition: 0.2s;
            user-select: none;
        }

        .todo-meta { flex: 1; }
        .todo-meta-line { font-size: 0.85rem; opacity: 0.75; display: flex; gap: 8px; align-items: center; }
        .todo-actions { display: flex; gap: 6px; margin-left: auto; }
        .todo-due { background: rgba(255,255,255,0.05); padding: 2px 6px; border-radius: 4px; }
        .todo-status { font-size: 0.7rem; letter-spacing: 1px; }
        .muted { opacity: 0.6; }

        .todo-item:hover {
            background: var(--dim);
            padding-left: 15px;
        }

        .todo-check {
            font-weight: bold;
            font-family: monospace;
            min-width: 25px;
        }

        .todo-text {
            flex-grow: 1;
            line-height: 1.4;
        }

        .todo-done .todo-text {
            text-decoration: line-through;
            opacity: 0.5;
        }

        .todo-del {
            opacity: 0;
            transition: 0.2s;
            color: red;
        }

        .todo-item:hover .todo-del {
            opacity: 1;
        }

        .cal-event-list {
            display: flex;
            flex-direction: column;
            gap: 8px;
            max-height: 240px;
            overflow-y: auto;
            padding: 4px;
            border: 1px dashed var(--dim);
        }

        .cal-event-row {
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 6px;
            border: 1px solid var(--dim);
            border-radius: 4px;
            background: rgba(0,0,0,0.15);
        }

        .cal-event-title { flex: 1; }

        .badge {
            background: var(--dim);
            padding: 2px 6px;
            border-radius: 4px;
            font-size: 0.8rem;
            letter-spacing: 0.5px;
        }

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

        @media(min-width: 768px) {
            .work-grid {
                grid-template-columns: 1fr 1fr;
            }
        }

        .work-card {
            border: 1px solid var(--text);
            padding: 20px;
            background: rgba(0, 0, 0, 0.15);
        }

        .work-card h3 {
            border-bottom: 1px dashed var(--text);
            padding-bottom: 10px;
            margin-bottom: 15px;
        }

        .pass-result {
            background: var(--dim);
            padding: 15px;
            font-size: 1.2rem;
            text-align: center;
            margin-bottom: 15px;
            word-break: break-all;
            border: 1px solid var(--text);
            font-family: var(--font-main);
        }

        .qr-preview {
            border: 1px dashed var(--dim);
            padding: 10px;
            display: flex;
            gap: 10px;
            align-items: center;
            justify-content: center;
            background: rgba(0, 0, 0, 0.1);
        }

        .qr-preview canvas {
            background: #fff;
        }

        /* CALENDAR */
        .calendar-grid {
            display: grid;
            grid-template-columns: repeat(7, 1fr);
            gap: 5px;
            margin-top: 20px;
        }

        .cal-day:hover {
            background: var(--dim);
        }

        /* BUTTON STYLES REFACTOR */
        .btn {
            border: 1px solid var(--text);
            background: rgba(0, 0, 0, 0.25);
            color: var(--text);
            padding: 8px 16px;
            min-height: 36px;
            cursor: pointer;
            border-radius: 6px;
            font-family: 'JetBrains Mono', monospace;
            font-size: 0.95rem;
            letter-spacing: 0.5px;
            transition: background 0.2s, color 0.2s, transform 0.1s, box-shadow 0.2s;
            text-transform: uppercase;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            gap: 6px;
        }

        .btn:hover {
            background: var(--text);
            color: var(--bg);
            box-shadow: 0 0 10px var(--dim);
            transform: translateY(-1px);
        }

        .btn:active {
            transform: translateY(0);
        }

        .btn-sm {
            padding: 4px 10px;
            min-height: 30px;
            font-size: 0.85rem;
        }

        .btn-red {
            border-color: #ff3333;
            color: #ff3333;
        }

        .btn-red:hover {
            background: #ff3333;
            color: #fff;
        }

        .btn-green {
            border-color: #00ff41;
            color: #00ff41;
        }

        .btn-green:hover {
            background: #00ff41;
            color: #000;
        }

        .btn-ghost {
            background: transparent;
            border-style: dashed;
        }

        .theme-toggle-row {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
            margin-bottom: 8px;
        }

        .modal-overlay {
            position: fixed;
            inset: 0;
            background: rgba(0, 0, 0, 0.7);
            display: flex;
            align-items: center;
            justify-content: center;
            z-index: 12000;
            padding: 20px;
            backdrop-filter: blur(2px);
        }

        .modal-window {
            background: var(--bg);
            border: 1px solid var(--text);
            color: var(--text);
            width: min(520px, 100%);
            border-radius: 8px;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
            overflow: hidden;
        }

        .modal-header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            padding: 10px 14px;
            border-bottom: 1px solid var(--dim);
            font-weight: bold;
            letter-spacing: 0.5px;
        }

        .modal-body {
            padding: 14px;
            font-size: 0.95rem;
            line-height: 1.5;
        }

        .modal-actions {
            display: flex;
            justify-content: flex-end;
            gap: 8px;
            padding: 10px 14px 14px;
            border-top: 1px solid var(--dim);
        }

        .toast {
            position: fixed;
            bottom: 20px;
            right: 20px;
            background: rgba(0, 0, 0, 0.85);
            color: var(--text);
            border: 1px solid var(--text);
            padding: 10px 12px;
            border-radius: 6px;
            box-shadow: 0 0 10px var(--dim);
            z-index: 12500;
            animation: fadeIn 0.2s ease-out;
            max-width: min(320px, 90vw);
        }

        .toast-success { border-color: #00ff41; color: #00ff41; }
        .toast-error { border-color: #ff3333; color: #ff7878; }


        .opts-grid {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 10px;
            margin-bottom: 15px;
        }

        .opt-check {
            display: flex;
            align-items: center;
            gap: 5px;
            cursor: pointer;
        }

        .translit-area {
            width: 100%;
            height: 100px;
            background: rgba(0, 0, 0, 0.2);
            border: 1px solid var(--text);
            color: var(--text);
            padding: 10px;
            font-family: inherit;
            resize: vertical;
            margin-bottom: 10px;
        }

        .game-hub {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
            gap: 10px;
            margin-bottom: 20px;
        }

        .game-card {
            border: 1px solid var(--text);
            padding: 15px;
            text-align: center;
            cursor: pointer;
            font-size: 0.9rem;
        }

        .game-card:hover {
            background: var(--dim);
            font-weight: bold;
        }

        .game-area {
            border: 2px solid var(--text);
            padding: 15px;
            background: rgba(0, 0, 0, 0.3);
            display: inline-block;
            position: relative;
            box-shadow: 0 0 15px var(--dim);
            width: min(100%, 720px);
            margin: 0 auto;
            max-height: calc(100vh - 240px);
            overflow: auto;
        }

        .game-stage {
            position: relative;
            width: 100%;
            min-height: 320px;
            max-height: calc(100vh - 300px);
        }

        .game-area canvas {
            width: 100%;
            height: auto;
            display: block;
            image-rendering: pixelated;
        }

        .custom-game {
            display: none;
            min-height: 320px;
            max-height: calc(100vh - 320px);
            background: #000;
            color: var(--text);
            padding: 10px;
            box-sizing: border-box;
            overflow: auto;
        }

        .custom-game:empty::before {
            content: 'Custom game output appears here';
            opacity: 0.6;
            font-size: 0.9rem;
        }

        .game-error {
            color: #f55;
            text-align: center;
            padding: 10px;
        }

        .game-hint {
            position: absolute;
            bottom: 8px;
            right: 12px;
            font-size: 0.75rem;
            opacity: 0.7;
        }

        .game-panels { display: grid; grid-template-columns: 1fr; gap: 12px; justify-items: center; }
        .game-footer { display: flex; justify-content: space-between; align-items: center; margin-top: 10px; }

        .pico-panel {
            border: 1px solid var(--dim);
            padding: 10px;
            background: rgba(0,0,0,0.2);
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .pico-list {
            border: 1px dashed var(--dim);
            padding: 8px;
            display: flex;
            flex-direction: column;
            gap: 6px;
            max-height: 240px;
            overflow-y: auto;
        }

        .pico-item {
            border: 1px solid var(--dim);
            padding: 6px;
            display: flex;
            flex-direction: column;
            gap: 4px;
            background: rgba(0,0,0,0.15);
        }

        .pico-title { font-weight: bold; }
        .pico-url { font-size: 0.75rem; opacity: 0.7; word-break: break-all; }
        .pico-actions { display: flex; gap: 6px; }

        .game-toolbar {
            display: flex;
            gap: 8px;
            align-items: center;
            flex-wrap: wrap;
        }

        .saver-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
            gap: 12px;
            margin: 10px 0 14px;
        }

        .saver-card {
            border: 1px solid var(--dim);
            padding: 12px;
            cursor: pointer;
            display: flex;
            flex-direction: column;
            gap: 6px;
            background: rgba(0, 0, 0, 0.15);
            border-radius: 6px;
        }

        .saver-card input { display: none; }

        .saver-card.active,
        .saver-card:hover {
            border-color: var(--text);
            box-shadow: 0 0 12px var(--dim);
        }

        .saver-name { font-weight: bold; letter-spacing: 0.5px; }
        .saver-desc { font-size: 0.85rem; opacity: 0.8; }
        .saver-badge { font-size: 0.7rem; text-transform: uppercase; opacity: 0.6; }

        .saver-actions {
            display: flex;
            flex-wrap: wrap;
            gap: 12px;
            align-items: center;
            justify-content: space-between;
            border-top: 1px solid var(--dim);
            padding-top: 10px;
        }

        .saver-action-buttons { display: flex; gap: 8px; }

        .saver-preview-shell {
            border: 1px solid var(--dim);
            border-radius: 6px;
            padding: 8px;
            background: rgba(0,0,0,0.15);
            margin-top: 12px;
        }

        #saver-preview-canvas {
            width: 100%;
            height: 240px;
            display: block;
            background: #000;
        }

        .gallery-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
            gap: 15px;
        }

        .gallery-item {
            border: 1px dashed var(--dim);
            padding: 10px;
            background: rgba(0, 0, 0, 0.1);
        }

        .gallery-thumb {
            width: 100%;
            aspect-ratio: 4/3;
            background: #222;
            display: flex;
            align-items: center;
            justify-content: center;
            border: 1px solid var(--dim);
            overflow: hidden;
        }

        .gallery-thumb img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            filter: grayscale(1) contrast(1.2);
        }

        /* HOME PROFILE STYLES */
        .home-profile-grid {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            margin-bottom: 20px;
        }

        .home-profile-btn {
            border: 2px solid var(--text);
            padding: 10px 20px;
            cursor: pointer;
            background: transparent;
            color: var(--text);
            font-family: inherit;
            font-size: 1rem;
            transition: 0.2s;
            min-width: 120px;
            text-align: center;
        }

        .home-profile-btn:hover,
        .home-profile-btn.active {
            background: var(--text);
            color: var(--bg);
        }

        .home-tags-area {
            margin-bottom: 20px;
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
            border-bottom: 1px dashed var(--dim);
            padding-bottom: 15px;
        }

        /* KEYBOARD NAV FOCUS */
        button:focus,
        a:focus,
        input:focus,
        textarea:focus {
            outline: 2px solid var(--text);
            background: var(--dim);
            box-shadow: 0 0 10px var(--text);
        }

        /* VISUAL EFFECTS */
        .fx-glow body {
            text-shadow: 0 0 4px var(--dim), 0 0 2px var(--text);
        }

        .fx-flicker body::after {
            content: " ";
            display: block;
            position: fixed;
            top: 0;
            left: 0;
            bottom: 0;
            right: 0;
            background: rgba(18, 16, 16, 0.1);
            opacity: 0;
            z-index: 998;
            pointer-events: none;
            animation: flicker-anim 0.15s infinite;
        }

        @keyframes flicker-anim {
            0% {
                opacity: 0.05;
            }

            50% {
                opacity: 0.1;
            }

            100% {
                opacity: 0.05;
            }
        }

        .fx-scanline .crt-overlay {
            opacity: 0.5;
            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));
            background-size: 100% 4px, 6px 100%;
        }

        /* SCREENSAVER */
        #screensaver-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: #000;
            z-index: 10000;
            display: none;
            align-items: center;
            justify-content: center;
            overflow: hidden;
        }

        #screensaver-canvas {
            width: 100%;
            height: 100%;
        }

        /* THEME MENU EXTRAS */
        .theme-extras {
            border-top: 1px dashed var(--dim);
            padding-top: 10px;
            margin-top: 10px;
        }

        .font-switcher {
            display: flex;
            align-items: center;
            gap: 8px;
            margin-top: 8px;
        }

        .home-tag-btn {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 6px 10px;
            background: var(--bg);
            color: var(--text);
            border: 1px dashed var(--dim);
            border-radius: 8px;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            opacity: 0.8;
            transition: opacity 0.2s, border-color 0.2s, background 0.2s;
        }

        .home-tag-btn:hover {
            opacity: 1;
            border-color: var(--text);
        }

        .home-tag-btn.active {
            background: var(--dim);
            border-color: var(--text);
            opacity: 1;
            font-weight: bold;
        }

        .home-links-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
            gap: 15px;
        }

        .home-link-card {
            display: block;
            border: 1px solid var(--dim);
            padding: 12px;
            text-decoration: none;
            color: var(--text);
            background: rgba(255, 255, 255, 0.02);
            transition: 0.2s;
            position: relative;
            overflow: hidden;
        }

        .home-link-card:hover {
            border-color: var(--text);
            background: rgba(255, 255, 255, 0.08);
            transform: translateX(3px);
        }

        .home-link-card .title {
            font-weight: bold;
            font-size: 1.05rem;
            display: block;
            margin-bottom: 4px;
        }

        .home-link-card .url {
            font-size: 0.75rem;
            opacity: 0.6;
            display: block;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .home-link-tags {
            margin-top: 8px;
            font-size: 0.7rem;
            opacity: 0.5;
        }

        footer {
            border-top: 2px solid var(--text);
            padding: 5px 15px;
            display: flex;
            justify-content: space-between;
            align-items: center;
            min-height: 50px;
            gap: 10px;
            position: relative;
        }

        .theme-menu-container {
            position: relative;
        }

        .theme-toggle-btn {
            background: var(--text);
            color: var(--bg);
            border: none;
            padding: 3px 8px;
            cursor: pointer;
            font-weight: bold;
            font-family: inherit;
            font-size: 0.75rem;
            line-height: 1;
        }

        .theme-popup {
            position: absolute;
            bottom: 100%;
            left: 0;
            background: var(--bg);
            border: 2px solid var(--text);
            padding: 10px;
            display: none;
            width: 320px;
            z-index: 100;
            box-shadow: 0 -5px 20px rgba(0, 0, 0, 0.5);
            margin-bottom: 10px;
            max-height: 420px;
            overflow-y: auto;
            flex-direction: column;
            gap: 6px;
        }

        .theme-popup.show {
            display: flex;
        }

        .theme-item {
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 8px 10px;
            cursor: pointer;
            font-size: 0.85rem;
            border: 1px solid transparent;
        }

        .theme-item:hover {
            background: var(--dim);
            border-color: var(--text);
        }

        .color-preview {
            width: 12px;
            height: 12px;
            border-radius: 50%;
            border: 1px solid var(--text);
        }

        #funny-phrase {
            font-size: 0.75rem;
            opacity: 0.6;
            font-style: italic;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            flex-grow: 1;
            margin: 0 15px;
            text-align: right;
        }

        #clown-overlay {
            position: fixed;
            inset: 0;
            display: none;
            align-items: center;
            justify-content: center;
            z-index: 10000;
            background: rgba(0, 0, 0, 0.9);
            pointer-events: none;
        }

        #boot {
            position: fixed;
            inset: 0;
            background: black;
            z-index: 1000;
            display: flex;
            flex-direction: column;
            justify-content: center;
            align-items: center;
        }

        #matrix-bg {
            position: fixed;
            inset: 0;
            pointer-events: none;
            z-index: 1;
            display: none;
            opacity: 0.25;
        }

        .underline {
            border-bottom: 2px solid var(--text);
            display: inline-block;
            margin-bottom: 10px;
        }

        /* Node Cards */
        .node-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
            gap: 20px;
            margin-top: 20px;
        }

        .node-card {
            border: 1px solid var(--text);
            padding: 20px;
            position: relative;
            background: rgba(0, 0, 0, 0.2);
            box-shadow: inset 0 0 10px var(--dim);
        }

        .node-card h3 {
            margin-bottom: 15px;
            font-size: 1.1rem;
            border-bottom: 1px solid var(--text);
            display: inline-block;
            padding-bottom: 2px;
        }

        .node-link {
            display: flex;
            align-items: center;
            gap: 10px;
            margin-bottom: 12px;
            text-decoration: none;
            color: inherit;
            font-size: 1.1rem;
            transition: 0.2s;
            padding: 5px;
            cursor: pointer;
        }

        .node-link:hover {
            background: var(--text);
            color: var(--invert);
            text-decoration: none;
        }

        .node-status {
            position: absolute;
            top: 10px;
            right: 10px;
            font-size: 0.7rem;
            opacity: 0.8;
            letter-spacing: 1px;
        }

        /* Admin Panel Styles */
        .admin-login {
            max-width: 400px;
            margin: 100px auto;
            border: 2px solid var(--text);
            padding: 30px;
            text-align: center;
        }

        .admin-input {
            background: rgba(0, 0, 0, 0.3);
            border: 1px solid var(--text);
            color: var(--text);
            padding: 10px;
            font-family: inherit;
            width: 100%;
            margin-bottom: 15px;
            outline: none;
        }

        .admin-dash {
            display: flex;
            gap: 20px;
            flex-direction: column;
            height: 100%;
        }

        @media(min-width: 768px) {
            .admin-dash {
                flex-direction: row;
            }
        }

        .admin-sidebar {
            width: 100%;
            border-bottom: 1px solid var(--text);
            padding-bottom: 10px;
            display: flex;
            gap: 5px;
            overflow-x: auto;
            flex-wrap: wrap;
        }

        .admin-sidebar>div {
            display: flex;
            gap: 5px;
            flex-wrap: wrap;
        }

        .admin-sidebar .btn {
            padding: 4px 8px;
            font-size: 0.75rem;
        }

        @media(min-width: 768px) {
            .admin-sidebar {
                width: 160px;
                min-width: 160px;
                border-bottom: none;
                border-right: 1px solid var(--dim);
                padding-right: 15px;
                flex-direction: column;
                flex-wrap: nowrap;
                gap: 0;
            }

            .admin-sidebar>div {
                flex-direction: column;
                gap: 3px;
                padding: 8px 0;
            }

            .admin-sidebar>div:not(:last-child) {
                border-bottom: 1px dashed var(--dim);
            }

            .admin-sidebar>div:last-child {
                margin-top: auto;
                padding-top: 15px;
            }

            .admin-sidebar .btn {
                width: 100%;
                text-align: left;
                padding: 4px 8px;
                font-size: 0.75rem;
            }
        }

        .admin-content {
            flex-grow: 1;
            overflow-y: auto;
            padding-right: 5px;
        }

        .form-group {
            margin-bottom: 15px;
        }

        .form-label {
            display: block;
            margin-bottom: 5px;
            opacity: 0.8;
            font-size: 0.8rem;
        }

        .form-control {
            width: 100%;
            background: rgba(0, 0, 0, 0.1);
            border: 1px solid var(--text);
            color: var(--text);
            padding: 8px;
            font-family: inherit;
        }

        textarea.form-control {
            height: 150px;
            resize: vertical;
        }

        .item-list {
            border: 1px dashed var(--dim);
            padding: 10px;
            max-height: 250px;
            overflow-y: auto;
            margin-bottom: 10px;
        }

        .item-row {
            display: flex;
            justify-content: space-between;
            border-bottom: 1px solid var(--dim);
            padding: 5px;
            align-items: center;
            gap: 10px;
        }

        .item-row:last-child {
            border-bottom: none;
        }

        .notes-manager {
            display: flex;
            gap: 15px;
            height: 400px;
            flex-direction: column;
        }

        @media(min-width:768px) {
            .notes-manager {
                flex-direction: row;
            }
        }

        .notes-cats {
            width: 100%;
            height: 150px;
            border: 1px solid var(--dim);
            padding: 5px;
            overflow-y: auto;
        }

        @media(min-width:768px) {
            .notes-cats {
                width: 30%;
                height: 100%;
            }
        }

        .notes-files-area {
            flex-grow: 1;
            display: flex;
            flex-direction: column;
            gap: 10px;
        }

        .notes-files-list {
            height: 150px;
            border: 1px solid var(--dim);
            padding: 5px;
            overflow-y: auto;
        }

        .notes-editor {
            flex-grow: 1;
            display: flex;
            flex-direction: column;
        }

/* ABOUT */
.about-lang-switch {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-bottom: 15px;
}

.about-shell {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 16px;
    align-items: start;
}

.about-photo {
    width: 150px;
    border: 2px solid var(--text);
    object-fit: cover;
    justify-self: end;
}

.about-text {
    min-height: 120px;
}

/* PLAYGROUND POLYGON — Theme-aware windows */
#view.playground-view {
    overflow: hidden;
}

.pg-desktop {
    background: radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.08), transparent 40%),
        radial-gradient(circle at 80% 40%, rgba(255, 255, 255, 0.06), transparent 42%),
        linear-gradient(135deg, rgba(255, 255, 255, 0.05), transparent 60%),
        var(--bg2, #0b0e17);
    border: 1px solid var(--dim);
    padding: 14px;
    min-height: calc(100vh - 220px);
    display: flex;
    flex-direction: column;
    gap: 12px;
    overflow: hidden;
    position: relative;
}

.pg-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--dim);
    border-radius: 10px;
    padding: 10px 12px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.25);
}

.pg-title {
    font-weight: 700;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pg-toggle-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.pg-window-area {
    position: relative;
    flex: 1;
    min-height: 70vh;
    border: 1px dashed var(--dim);
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent 60%);
}

.pg-window {
    position: absolute;
    width: clamp(280px, 32vw, 360px);
    min-height: 240px;
    max-height: calc(100vh - 260px);
    background: var(--bg);
    border: 1px solid var(--text);
    border-radius: 10px;
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.35);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.pg-window-wide {
    width: clamp(320px, 70vw, 860px);
}

.pg-titlebar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
    cursor: grab;
}

.pg-titletext {
    font-weight: 700;
    letter-spacing: 0.4px;
}

.pg-title-actions {
    display: flex;
    gap: 6px;
}

.pg-mini {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text);
    border: 1px solid var(--dim);
    border-radius: 6px;
    padding: 2px 8px;
    cursor: pointer;
}

.pg-body {
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    color: var(--text);
    overflow: auto;
}

.panel-sub {
    font-size: 0.75rem;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stat-row {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    font-size: 0.95rem;
}

.hud-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 8px;
}

.hud-card {
    padding: 8px 10px;
    border: 1px solid var(--dim);
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.04);
    font-size: 0.9rem;
}

.pg-three {
    gap: 12px;
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    align-items: flex-start;
}

.pg-fox-shell {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pg-three-demos {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.pg-demo-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.pg-demo-frame {
    border: 1px solid var(--dim);
    border-radius: 10px;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.3);
}

.pg-demo-frame canvas {
    width: 100%;
    height: clamp(180px, 28vh, 260px);
    display: block;
    background: #000;
}

.pg-window .fs-manager {
    height: 100%;
}

.fox-stage {
    width: 100%;
    height: clamp(180px, 28vh, 240px);
    border: 2px inset #fff;
    background: radial-gradient(circle at 20% 20%, rgba(255, 176, 0, 0.2), transparent 60%),
        radial-gradient(circle at 80% 30%, rgba(0, 255, 65, 0.15), transparent 60%),
        #1a1a1a;
}

.fox-canvas {
    width: 100%;
    height: 100%;
    display: block;
}

.panel-note {
    font-size: 0.8rem;
    opacity: 0.7;
}

.playground-code {
    width: 100%;
    min-height: 70px;
    border: 2px inset #fff;
    background: #000;
    color: #0f0;
    padding: 8px;
    font-family: 'JetBrains Mono', monospace;
}

.playground-term {
    width: 100%;
    margin-top: 6px;
    border: 2px inset #fff;
    padding: 6px 8px;
    background: #222;
    color: #0f0;
    font-family: 'JetBrains Mono', monospace;
}

.playground-output {
    border: 2px inset #fff;
    padding: 8px;
    min-height: 60px;
    background: #000;
    color: #0f0;
    font-family: 'JetBrains Mono', monospace;
    overflow: auto;
}

.btn-row {
    display: flex;
    gap: 8px;
    margin-top: 6px;
}

@media (max-width: 900px) {
    #view.playground-view {
        overflow: auto;
    }

    .about-shell {
        grid-template-columns: 1fr;
    }

    .about-photo {
        justify-self: center;
        width: 140px;
    }

    .pg-desktop {
        min-height: auto;
        padding: 10px;
    }

    .pg-toolbar {
        flex-direction: column;
        align-items: flex-start;
    }

    .pg-window-area {
        position: static;
        min-height: auto;
        overflow: auto;
        display: grid;
        grid-template-columns: 1fr;
        gap: 12px;
        padding: 8px;
    }

    .pg-window {
        position: relative;
        width: 100%;
        min-height: auto;
    }

    .pg-window-wide {
        width: 100%;
    }

    .pg-titlebar {
        cursor: default;
    }

    .pg-three {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    .pg-demo-frame canvas {
        height: 180px;
    }
}

        .win98-taskbar {
            display: flex;
            align-items: center;
            gap: 10px;
            padding: 6px 8px;
            background: #c0c0c0;
            border: 2px outset #fff;
            color: #000;
            position: relative;
        }

        .start-menu {
            position: absolute;
            bottom: 42px;
            left: 0;
            display: none;
            flex-direction: column;
            min-width: 180px;
            background: #c0c0c0;
            border: 2px outset #fff;
            box-shadow: 3px 3px 0 rgba(0, 0, 0, 0.3);
            z-index: 5;
        }

        .start-menu.open {
            display: flex;
        }

        .start-menu-title {
            background: linear-gradient(180deg, #000080, #0a2c8c);
            color: #fff;
            padding: 6px 8px;
            font-weight: bold;
        }

        .start-menu button {
            background: transparent;
            border: none;
            text-align: left;
            padding: 8px 10px;
            cursor: pointer;
            color: #000;
        }

        .start-menu button:hover {
            background: #e0e0e0;
        }

        .fox-loading {
            text-align: center;
            padding: 12px;
            color: #000;
            background: #dcdcdc;
            border: 1px dashed #999;
        }

        .start-btn {
            background: #dcdcdc;
            border: 2px outset #fff;
            padding: 4px 10px;
            font-weight: bold;
            cursor: pointer;
        }

        .task-label {
            flex: 1;
            padding: 4px 8px;
            border: 2px inset #fff;
            background: #e8e8e8;
        }

        .task-clock {
            border: 2px inset #fff;
            padding: 4px 8px;
            background: #e8e8e8;
            min-width: 96px;
            text-align: center;
        }

        .fs-manager {
            display: grid;
            grid-template-columns: 180px 1fr;
            gap: 10px;
            height: 100%;
            min-height: 240px;
        }

        .fs-sidebar {
            border: 1px dashed var(--dim);
            padding: 6px;
            display: flex;
            flex-direction: column;
            gap: 6px;
            overflow-y: auto;
        }

        .fs-item {
            text-align: left;
            border: 1px solid var(--dim);
            background: rgba(0, 0, 0, 0.2);
            color: var(--text);
            padding: 6px;
            border-radius: 6px;
            cursor: pointer;
        }

        .fs-item.active {
            border-color: var(--text);
            background: rgba(255, 176, 0, 0.1);
        }

        .fs-empty {
            opacity: 0.6;
            font-size: 0.9rem;
        }

        .fs-editor {
            border: 1px dashed var(--dim);
            padding: 8px;
            display: flex;
            flex-direction: column;
            gap: 8px;
        }

        .fs-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            gap: 8px;
            flex-wrap: wrap;
        }

        .fs-heading {
            font-weight: bold;
        }

        .fs-actions {
            display: flex;
            gap: 6px;
            align-items: center;
        }

        .fs-name {
            border: 1px solid var(--dim);
            padding: 4px 6px;
            background: rgba(0, 0, 0, 0.2);
            color: var(--text);
            border-radius: 6px;
        }

        .fs-text {
            width: 100%;
            height: 180px;
            background: rgba(0, 0, 0, 0.25);
            border: 1px dashed var(--dim);
            color: var(--text);
            padding: 8px;
            font-family: 'JetBrains Mono', monospace;
            resize: none;
        }

        /* Dynamic Styles Holder */
        #custom-theme-style {}

        /* Syntax highlighting */
        .code-block {
            background: rgba(0, 0, 0, 0.5);
            padding: 10px;
            border: 1px solid var(--dim);
            font-family: 'JetBrains Mono', monospace;
            font-size: 0.85rem;
            color: var(--text);
            height: 300px;
            overflow: auto;
        }

        /* Gallery Overlay */
        .gallery-overlay {
            position: fixed;
            inset: 0;
            z-index: 2000;
            background: rgba(0, 0, 0, 0.85);
            backdrop-filter: blur(5px);
            display: flex;
            align-items: center;
            justify-content: center;
            cursor: pointer;
            animation: fadeIn 0.2s;
        }

        .gallery-expand-content {
            width: 90%;
            max-height: 90vh;
            border: 2px solid var(--text);
            background: var(--bg);
            padding: 10px;
            overflow: auto;
            display: fill;
            align-items: center;
            justify-content: center;
            box-shadow: 0 0 30px var(--dim);
        }

        .gallery-expand-content img {
            width: 100%;
            height: auto;
            object-fit: fill;
        }

        .gallery-expand-content pre {
            width: fit-content;
            max-width: 100%;
            margin: 0 auto;
            display: block;
        }

        @keyframes fadeIn {
            from {
                opacity: 0;
            }

            to {
                opacity: 1;
            }
        }

        /* FX GLOW */
        .fx-glow body,
        .fx-glow * {
            text-shadow: 0 0 5px var(--text), 0 0 10px var(--text);
        }

        /* FX FLICKER */
        @keyframes flicker-anim {
            0% {
                opacity: 1;
            }

            5% {
                opacity: 0.8;
            }

            10% {
                opacity: 1;
            }

            15% {
                opacity: 1;
            }

            20% {
                opacity: 0.5;
            }

            25% {
                opacity: 1;
            }

            50% {
                opacity: 1;
            }

            55% {
                opacity: 0.8;
            }

            60% {
                opacity: 1;
            }

            100% {
                opacity: 1;
            }
        }

        .fx-flicker body {
            animation: flicker-anim 2s infinite;
            pointer-events: auto;
        }

        .fx-svg .nav-icon {
            filter: drop-shadow(0 0 6px var(--text));
            animation: flicker-anim 3s infinite ease-in-out;
        }

        @keyframes screen-pulse {
            0% { opacity: 1; }
            40% { opacity: 0.96; }
            60% { opacity: 1; }
            90% { opacity: 0.92; }
            100% { opacity: 1; }
        }

        .fx-screen-pulse .screen,
        .fx-screen-pulse body {
            animation: screen-pulse 5s infinite;
        }

        /* FX SCANLINE is already handled via crt-overlay mostly, but we can enhance it */
        .fx-scanline .crt-overlay {
            opacity: 0.5 !important;
            background-size: 100% 2px, 2px 100%;
        }
.btn:disabled,
.btn[disabled] {
    opacity: 0.5;
    cursor: not-allowed;
    filter: grayscale(0.4);
}

.final-page {
    min-height: 100vh;
    background: var(--bg);
    color: var(--text);
}

.final-shell {
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.final-header {
    border: 1px solid var(--dim);
    padding: 24px;
    background: rgba(0, 0, 0, 0.2);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.25);
    text-align: center;
}

.final-kicker {
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    opacity: 0.7;
    text-transform: uppercase;
}

.final-sub {
    opacity: 0.7;
    margin-top: 8px;
}

.final-card {
    border: 1px solid var(--text);
    padding: 24px;
    background: rgba(0, 0, 0, 0.35);
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: min(100%, 1400px);
    margin: 0 auto;
}

.final-meta {
    display: flex;
    gap: 18px;
    align-items: center;
    flex-wrap: wrap;
    justify-content: center;
}

.final-badge {
    border: 1px solid var(--text);
    padding: 6px 12px;
    font-size: 0.75rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

.final-lines {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 0.85rem;
    opacity: 0.8;
}

.final-body {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    justify-items: center;
}

.final-panel {
    border: 1px dashed var(--dim);
    padding: 16px;
    background: rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 320px;
}

.final-panel-wide {
    max-width: 100%;
}

.finals-container {
    width: 100%;
    min-height: 420px;
    border: 1px solid var(--dim);
    background: #050505;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.final-panel ul {
    margin: 10px 0 0 18px;
    padding: 0;
}

.final-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 12px;
}
