﻿        * {
            box-sizing: border-box;
        }
        body {
            margin: 0;
            padding: 24px;
            font-family: Arial, sans-serif;
            background: radial-gradient(circle at top, #303030 0, #0a0a0a 55%, #000000 100%);
            color: #f5f5f5;
        }
        body.theme-tobgun1 {
            background: radial-gradient(circle at top, #16324f 0, #050b16 55%, #02030a 100%);
            color: #e3f2fd;
        }
        body.theme-aries {
            background:
                radial-gradient(circle at 12% 0%, rgba(255, 235, 59, 0.23) 0, transparent 42%),
                radial-gradient(circle at 88% 8%, rgba(244, 143, 177, 0.2) 0, transparent 46%),
                radial-gradient(circle at 18% 100%, rgba(46, 125, 50, 0.28) 0, transparent 48%),
                radial-gradient(circle at 100% 78%, rgba(171, 71, 188, 0.22) 0, transparent 52%),
                radial-gradient(circle at 50% 50%, #02040a 0, #000000 70%);
            color: #dde7ff;
        }
        body.theme-skippy {
            background:
                url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='64' height='64' viewBox='0 0 64 64'%3E%3Crect x='8' y='28' width='48' height='6' rx='3' fill='%23000' opacity='0.2'/%3E%3Crect x='29' y='8' width='6' height='48' rx='3' fill='%23000' opacity='0.2'/%3E%3Cellipse cx='32' cy='28' rx='14' ry='15' fill='none' stroke='%23000' stroke-width='2.5' opacity='0.25'/%3E%3Cellipse cx='26' cy='26' rx='4' ry='5' fill='%23000' opacity='0.3'/%3E%3Cellipse cx='38' cy='26' rx='4' ry='5' fill='%23000' opacity='0.3'/%3E%3Cpath d='M32 32 L30 38 L32 36 L34 38 Z' fill='%23000' opacity='0.3'/%3E%3Cpath d='M22 40 Q32 44 42 40' stroke='%23000' stroke-width='1.5' fill='none' opacity='0.25' stroke-linecap='round'/%3E%3C/svg%3E"),
                radial-gradient(circle at 50% 0%, rgba(180, 0, 0, 0.35) 0, transparent 50%),
                radial-gradient(circle at 20% 80%, rgba(120, 0, 0, 0.25) 0, transparent 45%),
                radial-gradient(circle at 80% 80%, rgba(80, 0, 0, 0.2) 0, transparent 45%),
                radial-gradient(circle at 50% 50%, #0a0000 0, #000000 70%);
            color: #ffdddd;
        }
        body.theme-terra-morpheous {
            background:
                radial-gradient(circle at 15% 20%, rgba(156, 39, 176, 0.35) 0, transparent 45%),
                radial-gradient(circle at 85% 80%, rgba(76, 175, 80, 0.3) 0, transparent 45%),
                radial-gradient(circle at 50% 50%, rgba(45, 25, 65, 0.95) 0, #0a0610 70%);
            color: #e8d5f0;
        }
        body.theme-ammo {
            background:
                repeating-linear-gradient(90deg, transparent 0, transparent 2px, rgba(139, 119, 101, 0.08) 2px, rgba(139, 119, 101, 0.08) 4px),
                radial-gradient(circle at 30% 30%, rgba(101, 67, 33, 0.25) 0, transparent 50%),
                radial-gradient(circle at 70% 70%, rgba(80, 70, 60, 0.2) 0, transparent 50%),
                radial-gradient(circle at 50% 50%, #1a1814 0, #0d0c0a 70%);
            color: #d4c4a8;
        }
        body.theme-muffin {
            background:
                radial-gradient(circle at 20% 20%, rgba(210, 170, 100, 0.2) 0, transparent 45%),
                radial-gradient(circle at 80% 80%, rgba(180, 140, 80, 0.18) 0, transparent 45%),
                radial-gradient(circle at 50% 50%, #1f1810 0, #14100c 70%);
            color: #f5e6c8;
        }
        body.theme-mota {
            background:
                radial-gradient(circle at 20% 80%, rgba(0, 150, 136, 0.25) 0, transparent 45%),
                radial-gradient(circle at 80% 20%, rgba(0, 188, 212, 0.2) 0, transparent 45%),
                radial-gradient(circle at 50% 50%, #0a1412 0, #06100e 70%);
            color: #b2dfdb;
        }
        body.theme-uxhiha {
            background:
                radial-gradient(circle at 50% 0%, rgba(180, 0, 0, 0.4) 0, transparent 50%),
                radial-gradient(circle at 20% 80%, rgba(139, 0, 0, 0.3) 0, transparent 45%),
                radial-gradient(circle at 80% 80%, rgba(80, 0, 0, 0.25) 0, transparent 45%),
                radial-gradient(circle at 50% 50%, #0d0000 0, #000000 70%);
            color: #ffcccc;
        }
        .codes-layout {
            max-width: 1400px;
            margin: 0 auto;
            border: 3px solid #ff8c00;
            border-radius: 8px;
            background: linear-gradient(135deg, #181818 0%, #101010 40%, #181818 100%);
            box-shadow: 0 0 30px rgba(0, 0, 0, 0.8);
            overflow: hidden;
        }
        body.theme-tobgun1 .codes-layout {
            border-color: #b71c1c;
            background: linear-gradient(135deg, #0e1b2b 0%, #050b14 40%, #101b30 100%);
            box-shadow: 0 0 40px rgba(4, 9, 30, 0.9);
        }
        body.theme-aries .codes-layout {
            border-color: #ba68c8;
            background: linear-gradient(135deg, rgba(13, 20, 54, 0.98) 0%, rgba(21, 31, 90, 0.98) 35%, rgba(49, 27, 81, 0.98) 70%, rgba(74, 20, 140, 0.98) 100%);
            box-shadow: 0 0 32px rgba(74, 20, 140, 0.75);
        }
        body.theme-skippy .codes-layout {
            border-color: #b71c1c;
            background: linear-gradient(135deg, #1a0505 0%, #0d0000 40%, #150808 100%);
            box-shadow: 0 0 40px rgba(183, 28, 28, 0.5);
        }
        body.theme-terra-morpheous .codes-layout {
            border-color: #9c27b0;
            background: linear-gradient(135deg, rgba(45, 25, 65, 0.98) 0%, rgba(62, 39, 81, 0.98) 40%, rgba(27, 94, 32, 0.25) 100%);
            box-shadow: 0 0 36px rgba(156, 39, 176, 0.5);
        }
        body.theme-ammo .codes-layout {
            border-color: #8b7355;
            background: linear-gradient(135deg, #2a261e 0%, #1a1814 40%, #252018 100%);
            box-shadow: 0 0 30px rgba(139, 115, 85, 0.35);
        }
        body.theme-muffin .codes-layout {
            border-color: #c4a35a;
            background: linear-gradient(135deg, #2a2418 0%, #1e1a12 40%, #252018 100%);
            box-shadow: 0 0 32px rgba(196, 163, 90, 0.35);
        }
        body.theme-mota .codes-layout {
            border-color: #00897b;
            background: linear-gradient(135deg, #0e1f1c 0%, #0a1614 40%, #0e1f1c 100%);
            box-shadow: 0 0 32px rgba(0, 137, 123, 0.4);
        }
        body.theme-uxhiha .codes-layout {
            border-color: #b22222;
            background: linear-gradient(135deg, #1a0505 0%, #0d0000 40%, #150505 100%);
            box-shadow: 0 0 40px rgba(178, 34, 34, 0.5);
        }
        /* â”€â”€â”€ User submission panel (Codes tab) â”€â”€â”€ */
        .submit-panel {
            margin-top: 16px;
            padding: 24px;
            border-radius: 12px;
            border: 1px solid rgba(0, 212, 255, 0.35);
            background: rgba(8, 16, 24, 0.85);
            box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
        }
        .submit-panel-header h2 {
            margin: 0 0 6px;
            color: #00d4ff;
            font-size: 22px;
            letter-spacing: 0.5px;
        }
        .submit-panel-header p {
            margin: 0 0 18px;
            color: rgba(255, 255, 255, 0.7);
            font-size: 13px;
        }
        .submit-form {
            display: flex;
            flex-direction: column;
            gap: 14px;
        }
        .submit-row {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 14px;
        }
        @media (max-width: 640px) { .submit-row { grid-template-columns: 1fr; } }
        .submit-form label {
            display: flex;
            flex-direction: column;
            gap: 6px;
            font-size: 12px;
            text-transform: uppercase;
            letter-spacing: 0.5px;
            color: rgba(0, 212, 255, 0.85);
        }
        .submit-full { width: 100%; }
        .submit-form input[type="text"],
        .submit-form input[type="file"],
        .submit-form select,
        .submit-form textarea {
            padding: 10px 12px;
            border-radius: 8px;
            border: 1px solid rgba(255, 255, 255, 0.18);
            background: rgba(0, 0, 0, 0.5);
            color: #fff;
            font-size: 14px;
            font-family: inherit;
            text-transform: none;
            letter-spacing: normal;
        }
        .submit-form textarea {
            font-family: ui-monospace, "JetBrains Mono", Menlo, Consolas, monospace;
            font-size: 12px;
            resize: vertical;
        }
        .submit-form input:focus,
        .submit-form select:focus,
        .submit-form textarea:focus {
            outline: none;
            border-color: #00d4ff;
            box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.25);
        }
        .submit-actions {
            display: flex;
            align-items: center;
            gap: 12px;
            flex-wrap: wrap;
            margin-top: 4px;
        }
        .submit-btn {
            background: #00d4ff;
            color: #001018;
            font-weight: 700;
            padding: 12px 22px;
            border-radius: 8px;
            border: none;
            cursor: pointer;
        }
        .submit-btn:hover { background: #33dfff; }
        .submit-btn:disabled { opacity: 0.5; cursor: wait; }
        .submit-status {
            font-size: 13px;
            color: rgba(255, 255, 255, 0.85);
        }
        .submit-status.ok { color: #4ade80; }
        .submit-status.err { color: #f87171; }
        .submit-footnote {
            margin: 8px 0 0;
            font-size: 11px;
            color: rgba(255, 255, 255, 0.45);
        }
        .submit-footnote code {
            background: rgba(0, 212, 255, 0.1);
            padding: 1px 6px;
            border-radius: 4px;
            color: #00d4ff;
        }

        /* Submit a code - same section rhythm as dev edit modal */
        .submit-panel.submit-catalog-panel {
            max-width: 720px;
            margin-left: auto;
            margin-right: auto;
            padding: 0;
            overflow: hidden;
            border-radius: 14px;
            border: 1px solid rgba(0, 212, 255, 0.38);
            background: linear-gradient(165deg, rgba(12, 22, 34, 0.95) 0%, rgba(6, 10, 18, 0.98) 100%);
            box-shadow: 0 20px 48px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(0, 212, 255, 0.06) inset;
        }
        .submit-catalog-header {
            padding: 22px 26px 18px;
            border-bottom: 1px solid rgba(0, 212, 255, 0.14);
            background: linear-gradient(180deg, rgba(0, 212, 255, 0.07) 0%, transparent 100%);
        }
        .submit-catalog-header h2 {
            margin: 0 0 6px;
            font-size: 22px;
        }
        .submit-catalog-header p {
            margin: 0;
            font-size: 13px;
            line-height: 1.5;
            color: rgba(255, 255, 255, 0.62);
        }
        .submit-catalog-form {
            padding: 22px 26px 26px;
            gap: 0;
        }
        .submit-catalog-form.submit-form {
            gap: 0;
        }
        .submit-catalog-section {
            margin-bottom: 20px;
            padding: 16px 18px;
            border-radius: 10px;
            border: 1px solid rgba(255, 255, 255, 0.07);
            background: rgba(0, 0, 0, 0.28);
        }
        .submit-catalog-section:last-of-type {
            margin-bottom: 0;
        }
        .submit-catalog-section--listing {
            border-color: rgba(255, 140, 0, 0.35);
            background: linear-gradient(165deg, rgba(40, 28, 12, 0.35) 0%, rgba(0, 0, 0, 0.28) 100%);
        }
        .submit-catalog-section-title {
            margin: 0 0 8px;
            padding-bottom: 10px;
            border-bottom: 1px solid rgba(255, 255, 255, 0.06);
            font-size: 11px;
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 0.14em;
            color: rgba(0, 212, 255, 0.78);
        }
        .submit-catalog-section--listing .submit-catalog-section-title {
            color: rgba(255, 180, 100, 0.95);
        }
        .submit-catalog-hint {
            margin: 0 0 14px;
            font-size: 12px;
            line-height: 1.45;
            color: rgba(255, 255, 255, 0.5);
        }
        .submit-catalog-form .submit-row {
            margin-top: 0;
        }
        .submit-catalog-form .submit-row + .submit-row {
            margin-top: 14px;
        }
        .submit-catalog-form .submit-full {
            margin-bottom: 0;
        }
        .submit-catalog-form .submit-full + .submit-full {
            margin-top: 14px;
        }
        .submit-catalog-form textarea {
            min-height: 72px;
        }
        .submit-catalog-form #submit-notes {
            min-height: 120px;
        }
        .submit-catalog-footer {
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            gap: 12px;
            margin-top: 22px;
            padding-top: 20px;
            border-top: 1px solid rgba(0, 212, 255, 0.12);
        }
        .submit-catalog-footer .submit-btn {
            min-width: 160px;
        }
        .submit-catalog-form select:disabled {
            opacity: 0.65;
            cursor: not-allowed;
        }

        .catalog-banner {
            margin-bottom: 12px;
            padding: 10px 14px;
            border-radius: 8px;
            font-size: 13px;
        }
        .catalog-banner.loading { background: rgba(0, 212, 255, 0.12); border: 1px solid rgba(0, 212, 255, 0.35); color: #b8ecff; }
        .catalog-banner.err { background: rgba(255, 80, 80, 0.12); border: 1px solid rgba(255, 100, 100, 0.4); color: #ffb8b8; }
        .header-dev-row {
            display: flex;
            align-items: center;
            gap: 10px;
            flex-wrap: wrap;
            margin-top: 8px;
        }
        .filter-row {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            align-items: center;
            margin-top: -2px;
        }
        .filter-select-wrap {
            display: inline-flex;
            align-items: center;
            gap: 8px;
            padding: 6px 10px;
            background: #161616;
            border-radius: 6px;
            border: 1px solid #333;
        }
        .filter-select-wrap label {
            font-size: 11px;
            text-transform: uppercase;
            letter-spacing: 1px;
            color: #ffcc80;
        }
        .filter-select-wrap select {
            min-width: 170px;
            padding: 6px 8px;
            border-radius: 4px;
            border: 1px solid #555;
            background: #0d0d0d;
            color: #f5f5f5;
            font-size: 12px;
        }
        .public-msg-modal .modal-box {
            max-width: 640px;
            border-color: rgba(229, 57, 53, 0.45);
            background: linear-gradient(160deg, #1f1212 0%, #121820 100%);
        }
        .public-msg-modal h3 {
            color: #ffcdd2;
        }
        .public-msg-modal .submit-footnote {
            margin: 0 0 12px;
            color: rgba(255, 255, 255, 0.78);
        }
        .public-msg-modal .submit-form textarea {
            min-height: 120px;
            resize: vertical;
        }
        .editor-picker-modal .modal-box {
            max-width: 760px;
            border-color: rgba(255, 180, 80, 0.45);
            background: linear-gradient(160deg, #20160e 0%, #121820 100%);
        }
        .editor-picker-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
            gap: 10px;
            margin: 14px 0;
        }
        .editor-pick-btn {
            width: 100%;
            text-align: left;
            border: 1px solid rgba(255, 255, 255, 0.22);
            border-radius: 10px;
            padding: 10px 12px;
            background: rgba(0, 0, 0, 0.35);
            color: #fff;
            font-size: 12px;
            cursor: pointer;
            transition: border-color 0.15s, background 0.15s;
        }
        .editor-pick-btn:hover:not(.geniebot-btn):not(.bl4editor-com-btn):not(.gzo-editor-btn):not(.retro-editor-btn):not(.superexboom-btn):not(.scooters-btn):not(.mattmab-btn) {
            border-color: #ffcc80;
            background: rgba(255, 128, 0, 0.12);
        }
        .editor-pick-btn .editor-pick-name {
            display: block;
            font-weight: 700;
            margin-bottom: 4px;
            color: #ffd89e;
        }
        .editor-pick-btn .editor-pick-sub {
            display: block;
            color: #d2d2d2;
            font-size: 11px;
            opacity: 0.9;
        }
        /* Banner tiles: real <img> (same folder as Codes.html) so images load even when CSS url() paths fail on some hosts */
        .editor-pick-btn.geniebot-btn,
        .editor-pick-btn.bl4editor-com-btn,
        .editor-pick-btn.gzo-editor-btn,
        .editor-pick-btn.retro-editor-btn,
        .editor-pick-btn.superexboom-btn,
        .editor-pick-btn.scooters-btn,
        .editor-pick-btn.mattmab-btn {
            position: relative;
            isolation: isolate;
            overflow: hidden;
            background: transparent;
            min-height: 76px;
            transition: border-color 0.15s;
        }
        .editor-pick-btn.geniebot-btn > .editor-pick-banner,
        .editor-pick-btn.bl4editor-com-btn > .editor-pick-banner,
        .editor-pick-btn.gzo-editor-btn > .editor-pick-banner,
        .editor-pick-btn.retro-editor-btn > .editor-pick-banner,
        .editor-pick-btn.superexboom-btn > .editor-pick-banner,
        .editor-pick-btn.scooters-btn > .editor-pick-banner,
        .editor-pick-btn.mattmab-btn > .editor-pick-banner {
            position: absolute;
            inset: 0;
            width: 100%;
            height: 100%;
            object-fit: cover;
            object-position: center;
            z-index: 0;
            pointer-events: none;
        }
        .editor-pick-btn.geniebot-btn::after {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 1;
            background: linear-gradient(rgba(10, 6, 18, 0.58), rgba(10, 6, 18, 0.58));
            pointer-events: none;
        }
        .editor-pick-btn.geniebot-btn:hover::after {
            background: linear-gradient(rgba(10, 6, 18, 0.45), rgba(10, 6, 18, 0.45));
        }
        .editor-pick-btn.geniebot-btn {
            border-color: rgba(180, 130, 255, 0.8);
        }
        .editor-pick-btn.geniebot-btn:hover {
            border-color: #d7b0ff;
        }
        .editor-pick-btn.bl4editor-com-btn::after {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 1;
            background: linear-gradient(rgba(4, 18, 24, 0.55), rgba(4, 18, 24, 0.55));
            pointer-events: none;
        }
        .editor-pick-btn.bl4editor-com-btn:hover::after {
            background: linear-gradient(rgba(4, 18, 24, 0.4), rgba(4, 18, 24, 0.4));
        }
        .editor-pick-btn.bl4editor-com-btn {
            border-color: rgba(0, 220, 200, 0.6);
        }
        .editor-pick-btn.bl4editor-com-btn:hover {
            border-color: #5ee8ff;
        }
        .editor-pick-btn.gzo-editor-btn::after {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 1;
            background: linear-gradient(rgba(6, 18, 26, 0.55), rgba(6, 18, 26, 0.55));
            pointer-events: none;
        }
        .editor-pick-btn.gzo-editor-btn:hover::after {
            background: linear-gradient(rgba(6, 18, 26, 0.4), rgba(6, 18, 26, 0.4));
        }
        .editor-pick-btn.gzo-editor-btn {
            border-color: rgba(0, 230, 255, 0.65);
        }
        .editor-pick-btn.gzo-editor-btn:hover {
            border-color: #7ff2ff;
        }
        .editor-pick-btn.retro-editor-btn::after {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 1;
            background: linear-gradient(rgba(8, 10, 28, 0.58), rgba(8, 10, 28, 0.58));
            pointer-events: none;
        }
        .editor-pick-btn.retro-editor-btn:hover::after {
            background: linear-gradient(rgba(8, 10, 28, 0.42), rgba(8, 10, 28, 0.42));
        }
        .editor-pick-btn.retro-editor-btn {
            border-color: rgba(132, 118, 255, 0.7);
        }
        .editor-pick-btn.retro-editor-btn:hover {
            border-color: #b7acff;
        }
        .editor-pick-btn.superexboom-btn::after {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 1;
            background: linear-gradient(rgba(18, 8, 28, 0.56), rgba(18, 8, 28, 0.56));
            pointer-events: none;
        }
        .editor-pick-btn.superexboom-btn:hover::after {
            background: linear-gradient(rgba(18, 8, 28, 0.4), rgba(18, 8, 28, 0.4));
        }
        .editor-pick-btn.superexboom-btn {
            border-color: rgba(198, 112, 255, 0.72);
        }
        .editor-pick-btn.superexboom-btn:hover {
            border-color: #e4a8ff;
        }
        .editor-pick-btn.scooters-btn::after {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 1;
            background: linear-gradient(rgba(6, 16, 30, 0.56), rgba(6, 16, 30, 0.56));
            pointer-events: none;
        }
        .editor-pick-btn.scooters-btn:hover::after {
            background: linear-gradient(rgba(6, 16, 30, 0.4), rgba(6, 16, 30, 0.4));
        }
        .editor-pick-btn.scooters-btn {
            border-color: rgba(74, 234, 255, 0.7);
        }
        .editor-pick-btn.scooters-btn:hover {
            border-color: #9cf4ff;
        }
        .editor-pick-btn.mattmab-btn::after {
            content: "";
            position: absolute;
            inset: 0;
            z-index: 1;
            background: linear-gradient(rgba(4, 16, 26, 0.56), rgba(4, 16, 26, 0.56));
            pointer-events: none;
        }
        .editor-pick-btn.mattmab-btn:hover::after {
            background: linear-gradient(rgba(4, 16, 26, 0.4), rgba(4, 16, 26, 0.4));
        }
        .editor-pick-btn.mattmab-btn {
            border-color: rgba(95, 255, 241, 0.72);
        }
        .editor-pick-btn.mattmab-btn:hover {
            border-color: #b2fff8;
        }
        .editor-pick-btn.geniebot-btn .editor-pick-name,
        .editor-pick-btn.geniebot-btn .editor-pick-sub,
        .editor-pick-btn.bl4editor-com-btn .editor-pick-name,
        .editor-pick-btn.bl4editor-com-btn .editor-pick-sub,
        .editor-pick-btn.gzo-editor-btn .editor-pick-name,
        .editor-pick-btn.gzo-editor-btn .editor-pick-sub,
        .editor-pick-btn.retro-editor-btn .editor-pick-name,
        .editor-pick-btn.retro-editor-btn .editor-pick-sub,
        .editor-pick-btn.superexboom-btn .editor-pick-name,
        .editor-pick-btn.superexboom-btn .editor-pick-sub,
        .editor-pick-btn.scooters-btn .editor-pick-name,
        .editor-pick-btn.scooters-btn .editor-pick-sub,
        .editor-pick-btn.mattmab-btn .editor-pick-name,
        .editor-pick-btn.mattmab-btn .editor-pick-sub {
            position: relative;
            z-index: 2;
            color: #fff;
            text-shadow: 0 2px 5px rgba(0, 0, 0, 0.85);
        }
        .modal-overlay {
            display: none;
            position: fixed;
            inset: 0;
            z-index: 2000;
            background: rgba(0, 0, 0, 0.75);
            align-items: center;
            justify-content: center;
            padding: 16px;
        }
        .modal-overlay.open { display: flex; }
        .modal-box {
            max-width: 560px;
            width: 100%;
            max-height: 90vh;
            overflow: auto;
            padding: 20px;
            border-radius: 12px;
            border: 1px solid rgba(0, 212, 255, 0.35);
            background: #121820;
            color: #eee;
        }
        .modal-box h3 { margin: 0 0 12px; color: #00d4ff; font-size: 18px; }
        .modal-box select,
        .modal-box input[type="password"],
        .modal-box input[type="text"]:not(.code-text) {
            width: 100%;
            padding: 10px 12px;
            border-radius: 8px;
            border: 1px solid rgba(255, 255, 255, 0.18);
            background: rgba(0, 0, 0, 0.5);
            color: #fff;
            font-size: 14px;
            font-family: inherit;
            box-sizing: border-box;
        }
        .modal-box select:focus,
        .modal-box input:focus {
            outline: none;
            border-color: #00d4ff;
            box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.25);
        }
        .modal-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }
        .password-field-wrap {
            position: relative;
            display: block;
            width: 100%;
        }
        .password-field-wrap input {
            width: 100%;
            padding: 10px 4.25rem 10px 12px;
            border-radius: 8px;
            border: 1px solid rgba(255, 255, 255, 0.18);
            background: rgba(0, 0, 0, 0.5);
            color: #fff;
            font-size: 14px;
            font-family: inherit;
            box-sizing: border-box;
        }
        .password-field-wrap input:focus {
            outline: none;
            border-color: #00d4ff;
            box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.25);
        }
        .password-toggle-btn {
            position: absolute;
            right: 6px;
            top: 50%;
            transform: translateY(-50%);
            padding: 4px 8px;
            border: none;
            border-radius: 6px;
            background: rgba(0, 212, 255, 0.15);
            color: #00d4ff;
            font-size: 11px;
            font-weight: 600;
            letter-spacing: 0.3px;
            text-transform: uppercase;
            cursor: pointer;
            line-height: 1.2;
        }
        .password-toggle-btn:hover {
            background: rgba(0, 212, 255, 0.28);
        }
        .password-toggle-btn[aria-pressed="true"] {
            color: #fff;
            background: rgba(0, 212, 255, 0.4);
        }

        /* Developer - edit item (polished layout) */
        .dev-edit-modal.modal-overlay {
            z-index: 10050;
            background: rgba(0, 0, 0, 0.82);
            backdrop-filter: blur(6px);
        }
        .dev-edit-modal-box {
            display: flex;
            flex-direction: column;
            max-width: 640px;
            width: 100%;
            max-height: min(92vh, 900px);
            padding: 0;
            overflow: hidden;
            border-radius: 14px;
            border: 1px solid rgba(0, 212, 255, 0.38);
            background: linear-gradient(165deg, rgba(14, 24, 36, 0.98) 0%, rgba(6, 10, 18, 0.99) 100%);
            box-shadow:
                0 28px 56px rgba(0, 0, 0, 0.55),
                0 0 0 1px rgba(0, 212, 255, 0.06) inset;
            position: relative;
        }
        .dev-edit-modal-head {
            flex-shrink: 0;
        }
        .dev-edit-modal-scroll {
            flex: 1;
            min-height: 0;
            overflow-y: auto;
            -webkit-overflow-scrolling: touch;
        }
        .dev-edit-modal-toolbar {
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            gap: 10px;
            padding: 12px 26px 14px;
            border-bottom: 1px solid rgba(0, 212, 255, 0.16);
            background: rgba(0, 0, 0, 0.5);
        }
        .dev-edit-modal-toolbar .submit-btn {
            min-width: 150px;
        }
        .dev-edit-modal-toolbar-hint {
            margin: 0;
            font-size: 11px;
            color: rgba(255, 255, 255, 0.45);
            flex: 1 1 160px;
        }
        .dev-edit-modal-header {
            padding: 22px 26px 18px;
            border-bottom: 1px solid rgba(0, 212, 255, 0.1);
            background: linear-gradient(180deg, rgba(0, 212, 255, 0.07) 0%, transparent 100%);
        }
        .dev-edit-modal-header-inner {
            display: flex;
            align-items: flex-start;
            justify-content: space-between;
            gap: 16px;
        }
        .dev-edit-modal-header-text {
            flex: 1;
            min-width: 0;
        }
        .dev-edit-modal-close {
            flex-shrink: 0;
            width: 38px;
            height: 38px;
            margin: -4px -4px 0 0;
            padding: 0;
            border-radius: 10px;
            border: 1px solid rgba(255, 255, 255, 0.14);
            background: rgba(0, 0, 0, 0.4);
            color: rgba(255, 255, 255, 0.75);
            font-size: 24px;
            line-height: 1;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
        }
        .dev-edit-modal-close:hover {
            color: #fff;
            border-color: rgba(0, 212, 255, 0.45);
            background: rgba(0, 212, 255, 0.1);
        }
        .dev-edit-modal-close:focus {
            outline: none;
            border-color: #00d4ff;
            box-shadow: 0 0 0 2px rgba(0, 212, 255, 0.3);
        }
        .dev-edit-modal-header h3 {
            margin: 0 0 6px;
            font-size: 20px;
            font-weight: 700;
            letter-spacing: 0.3px;
            color: #00d4ff;
        }
        .dev-edit-modal-sub {
            margin: 0;
            font-size: 13px;
            line-height: 1.45;
            color: rgba(255, 255, 255, 0.55);
        }
        .dev-edit-form {
            padding: 22px 26px 26px;
            gap: 0;
        }
        .dev-edit-form.submit-form label {
            color: rgba(0, 212, 255, 0.88);
        }
        .dev-edit-section {
            margin-bottom: 18px;
            padding: 16px 18px;
            border-radius: 10px;
            border: 1px solid rgba(255, 255, 255, 0.07);
            background: rgba(0, 0, 0, 0.28);
        }
        .dev-edit-section:last-of-type {
            margin-bottom: 0;
        }
        .dev-edit-section-title {
            margin: 0 0 14px;
            padding-bottom: 10px;
            border-bottom: 1px solid rgba(255, 255, 255, 0.06);
            font-size: 11px;
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 0.14em;
            color: rgba(0, 212, 255, 0.78);
        }
        .dev-edit-reference {
            margin: 0 0 12px;
            font-size: 12px;
            line-height: 1.55;
            color: rgba(255, 255, 255, 0.62);
        }
        .dev-edit-reference:last-child {
            margin-bottom: 0;
        }
        .dev-edit-reference-list {
            margin: 8px 0 0;
            padding-left: 18px;
            font-size: 12px;
            line-height: 1.55;
            color: rgba(255, 255, 255, 0.62);
        }
        .dev-edit-reference-list li + li {
            margin-top: 6px;
        }
        .dev-edit-reference code,
        .dev-edit-reference-list code {
            font-size: 11px;
            padding: 1px 5px;
            border-radius: 4px;
            background: rgba(0, 0, 0, 0.35);
            color: rgba(255, 200, 120, 0.95);
        }
        .dev-edit-section .submit-row {
            margin-top: 0;
        }
        .dev-edit-section .submit-row + .submit-row {
            margin-top: 14px;
        }
        .dev-edit-form .submit-full {
            margin-bottom: 0;
        }
        .dev-edit-form .submit-full + .submit-full {
            margin-top: 14px;
        }
        .dev-edit-form textarea {
            min-height: 76px;
        }
        .dev-edit-form #dev-edit-notes {
            min-height: 100px;
        }
        .dev-edit-discord-section {
            border-color: rgba(88, 101, 242, 0.45);
            background: rgba(88, 101, 242, 0.08);
        }
        .dev-edit-discord-picks {
            display: flex;
            flex-wrap: wrap;
            gap: 10px;
            margin-top: 4px;
        }
        .dev-edit-discord-pick {
            display: inline-flex;
            align-items: center;
            gap: 8px;
            margin: 0;
            padding: 10px 14px;
            border-radius: 8px;
            border: 1px solid rgba(255, 255, 255, 0.18);
            background: rgba(0, 0, 0, 0.35);
            cursor: pointer;
            font-size: 12px;
            font-weight: 600;
            color: rgba(255, 255, 255, 0.88);
            transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
        }
        .dev-edit-discord-pick input {
            accent-color: #5865f2;
            width: 16px;
            height: 16px;
            margin: 0;
            cursor: pointer;
        }
        .dev-edit-discord-pick:has(input:checked) {
            border-color: #5865f2;
            background: rgba(88, 101, 242, 0.22);
            box-shadow: 0 0 0 1px rgba(88, 101, 242, 0.35);
        }
        .dev-edit-discord-pick-discord:has(input:checked) {
            border-color: #5865f2;
        }
        .dev-edit-footer {
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            gap: 12px;
            margin-top: 22px;
            padding-top: 20px;
            border-top: 1px solid rgba(0, 212, 255, 0.12);
        }
        .dev-edit-footer .submit-btn {
            min-width: 140px;
        }
        #owner-edit-panel { margin-bottom: 16px; }

        .codes-header {
            padding: 20px 24px;
            background: repeating-linear-gradient(
                -45deg,
                #202020,
                #202020 8px,
                #252525 8px,
                #252525 16px
            );
            border-bottom: 3px solid #ff8c00;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 16px;
        }
        .codes-header-title {
            display: flex;
            flex-direction: column;
            gap: 4px;
        }
        .codes-header-title h1 {
            margin: 0;
            font-size: 26px;
            letter-spacing: 3px;
            text-transform: uppercase;
            color: #ffb74d;
            text-shadow: 0 0 6px #000, 0 0 12px #ff8c00;
        }
        body.theme-tobgun1 .codes-header {
            background: repeating-linear-gradient(
                -45deg,
                #10233a,
                #10233a 8px,
                #152b46 8px,
                #152b46 16px
            );
            border-bottom-color: #b71c1c;
        }
        body.theme-tobgun1 .codes-header-title h1 {
            color: #90caf9;
            text-shadow: 0 0 6px #000, 0 0 14px #1976d2;
        }
        body.theme-tobgun1 .codes-header-meta strong {
            color: #ff8a80;
        }
        body.theme-aries .codes-header {
            background: repeating-linear-gradient(
                -45deg,
                rgba(26, 35, 126, 0.85),
                rgba(26, 35, 126, 0.85) 8px,
                rgba(74, 20, 140, 0.85) 8px,
                rgba(74, 20, 140, 0.85) 16px
            );
            border-bottom-color: #ba68c8;
        }
        body.theme-aries .codes-header-title h1 {
            color: #ffe082;
            text-shadow: 0 0 6px #000, 0 0 12px rgba(255, 193, 7, 0.75);
        }
        body.theme-aries .codes-header-meta strong {
            color: #a5d6a7;
        }
        body.theme-skippy .codes-header {
            background: repeating-linear-gradient(-45deg, #1a0505, #1a0505 8px, #2a0a0a 8px, #2a0a0a 16px);
            border-bottom-color: #b71c1c;
        }
        body.theme-skippy .codes-header-title h1 {
            color: #ef5350;
            text-shadow: 0 0 6px #000, 0 0 14px rgba(183, 28, 28, 0.9);
        }
        body.theme-skippy .codes-header-meta strong {
            color: #ffcdd2;
        }
        body.theme-terra-morpheous .codes-header {
            background: repeating-linear-gradient(-45deg, rgba(62, 39, 81, 0.95), rgba(62, 39, 81, 0.95) 8px, rgba(49, 27, 69, 0.95) 8px, rgba(49, 27, 69, 0.95) 16px);
            border-bottom-color: #9c27b0;
        }
        body.theme-terra-morpheous .codes-header-title h1 {
            color: #ce93d8;
            text-shadow: 0 0 6px #000, 0 0 14px rgba(156, 39, 176, 0.8);
        }
        body.theme-terra-morpheous .codes-header-meta strong {
            color: #a5d6a7;
        }
        body.theme-ammo .codes-header {
            background: repeating-linear-gradient(-45deg, #2a261e, #2a261e 8px, #352c22 8px, #352c22 16px);
            border-bottom-color: #8b7355;
        }
        body.theme-ammo .codes-header-title h1 {
            color: #c4a35a;
            text-shadow: 0 0 6px #000, 0 0 12px rgba(196, 163, 90, 0.6);
        }
        body.theme-ammo .codes-header-meta strong {
            color: #d4c4a8;
        }
        body.theme-muffin .codes-header {
            background: repeating-linear-gradient(-45deg, #2a2418, #2a2418 8px, #352c1e 8px, #352c1e 16px);
            border-bottom-color: #c4a35a;
        }
        body.theme-mota .codes-header {
            background: repeating-linear-gradient(-45deg, #0e1f1c, #0e1f1c 8px, #0f2522 8px, #0f2522 16px);
            border-bottom-color: #00897b;
        }
        body.theme-muffin .codes-header-title h1 {
            color: #e8d4a0;
            text-shadow: 0 0 6px #000, 0 0 14px rgba(196, 163, 90, 0.7);
        }
        body.theme-muffin .codes-header-meta strong {
            color: #f5e6c8;
        }
        body.theme-mota .codes-header-title h1 {
            color: #4db6ac;
            text-shadow: 0 0 6px #000, 0 0 14px rgba(0, 150, 136, 0.7);
        }
        body.theme-mota .codes-header-meta strong {
            color: #b2dfdb;
        }
        body.theme-uxhiha .codes-header {
            background: repeating-linear-gradient(-45deg, #1a0505, #1a0505 8px, #250808 8px, #250808 16px);
            border-bottom-color: #b22222;
        }
        body.theme-uxhiha .codes-header-title h1 {
            color: #ff6b6b;
            text-shadow: 0 0 6px #000, 0 0 12px rgba(178, 34, 34, 0.8);
        }
        body.theme-uxhiha .codes-header-meta strong {
            color: #ffcccc;
        }
        .codes-header-title span {
            font-size: 12px;
            text-transform: uppercase;
            letter-spacing: 2px;
            color: #dddddd;
        }
        .codes-header-meta {
            text-align: right;
            font-size: 11px;
            text-transform: uppercase;
            letter-spacing: 1px;
            color: #cccccc;
            display: flex;
            flex-direction: column;
            align-items: flex-end;
        }
        .codes-header-meta > div {
            margin-bottom: 2px;
        }
        .codes-header-meta > div:last-child {
            margin-top: 8px;
        }
        .codes-header-meta strong {
            color: #ffcc80;
        }

        .codes-main {
            padding: 18px 22px 22px;
            display: flex;
            flex-direction: column;
            gap: 16px;
        }

        .top-bar {
            display: flex;
            flex-wrap: wrap;
            gap: 12px 24px;
            align-items: center;
            justify-content: space-between;
        }
        .section-tabs {
            display: inline-flex;
            border: 2px solid #444;
            border-radius: 6px;
            overflow: hidden;
            background: #111;
        }
        .section-tab {
            padding: 10px 18px;
            border: none;
            background: transparent;
            color: #aaaaaa;
            font-size: 12px;
            font-weight: 700;
            letter-spacing: 2px;
            text-transform: uppercase;
            cursor: pointer;
            transition: background 0.15s, color 0.15s;
        }
        .section-tab + .section-tab {
            border-left: 1px solid #333;
        }
        .section-tab:hover {
            background: #222;
            color: #ffffff;
        }
        .section-tab.active {
            background: linear-gradient(135deg, #ff8c00 0%, #ff6b00 100%);
            color: #111;
        }

        .search-area {
            display: inline-flex;
            align-items: center;
            gap: 8px;
            padding: 6px 10px;
            background: #161616;
            border-radius: 6px;
            border: 1px solid #333;
        }
        .search-area label {
            font-size: 11px;
            text-transform: uppercase;
            letter-spacing: 1px;
            color: #ffcc80;
        }
        .creator-area {
            display: inline-flex;
            flex-direction: column;
            align-items: flex-end;
            gap: 4px;
            padding: 6px 10px;
            background: #161616;
            border-radius: 6px;
            border: 1px solid #333;
        }
        .creator-area-label {
            font-size: 11px;
            text-transform: uppercase;
            letter-spacing: 1px;
            color: #ffcc80;
        }
        .creator-pills {
            display: flex;
            flex-wrap: wrap;
            gap: 6px;
            justify-content: flex-end;
        }
        .creator-select {
            min-width: 220px;
            max-width: 320px;
            width: 100%;
            border: 1px solid #444;
            border-radius: 999px;
            padding: 6px 30px 6px 12px;
            font-size: 12px;
            background: #151515;
            color: #f2f2f2;
        }
        .creator-pill {
            border: 1px solid #444;
            border-radius: 999px;
            padding: 3px 10px;
            font-size: 11px;
            background: #151515;
            color: #cccccc;
            cursor: pointer;
            transition: background 0.15s, color 0.15s, border-color 0.15s;
        }
        .creator-pill:hover {
            background: #222;
            color: #ffffff;
        }
        .creator-pill.active {
            background: linear-gradient(135deg, #ff8c00 0%, #ff6b00 100%);
            color: #111;
            border-color: #ff8c00;
        }
        .pending-creator-bar {
            display: none;
            flex-direction: column;
            gap: 10px;
            margin: 10px 0 14px;
            padding: 12px 14px;
            background: linear-gradient(160deg, rgba(201, 162, 39, 0.12) 0%, #161616 55%);
            border: 1px solid rgba(201, 162, 39, 0.45);
            border-radius: 8px;
        }
        .pending-creator-bar.open {
            display: flex;
        }
        .pending-creator-bar-head {
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
        }
        .pending-creator-label {
            font-size: 11px;
            text-transform: uppercase;
            letter-spacing: 1px;
            color: #e6c35c;
            font-weight: 700;
        }
        .pending-creator-hint {
            font-size: 12px;
            color: rgba(255, 255, 255, 0.72);
            margin: 0;
        }
        .pending-creator-pills {
            display: flex;
            flex-wrap: wrap;
            gap: 8px;
        }
        .pending-creator-pill {
            border: 1px solid rgba(201, 162, 39, 0.45);
            border-radius: 999px;
            padding: 5px 12px;
            font-size: 12px;
            background: #151515;
            color: #f0e6c8;
            cursor: pointer;
            transition: background 0.15s, color 0.15s, border-color 0.15s;
        }
        .pending-creator-pill:hover {
            background: #222;
            color: #fff;
        }
        .pending-creator-pill.active {
            background: linear-gradient(135deg, #c9a227 0%, #e6c35c 100%);
            color: #111;
            border-color: #e6c35c;
            font-weight: 700;
        }
        .pending-creator-pill .pending-creator-count {
            opacity: 0.85;
            font-weight: 600;
        }
        body.theme-tobgun1 .creator-pill.active {
            background: linear-gradient(135deg, #1976d2 0%, #b71c1c 100%);
            color: #e3f2fd;
            border-color: #b71c1c;
        }
        body.theme-aries .creator-pill.active {
            background: linear-gradient(135deg, #aed581 0%, #4db6ac 40%, #ba68c8 100%);
            color: #0b0b10;
            border-color: #aed581;
        }
        body.theme-skippy .creator-pill.active {
            background: linear-gradient(135deg, #b71c1c 0%, #7f0000 100%);
            color: #ffcdd2;
            border-color: #ef5350;
        }
        body.theme-terra-morpheous .creator-pill.active {
            background: linear-gradient(135deg, #9c27b0 0%, #4caf50 100%);
            color: #fff;
            border-color: #ce93d8;
        }
        body.theme-ammo .creator-pill.active {
            background: linear-gradient(135deg, #8b7355 0%, #5d4e37 50%, #6b5b45 100%);
            color: #1a1814;
            border-color: #c4a35a;
        }
        body.theme-muffin .creator-pill.active {
            background: linear-gradient(135deg, #c4a35a 0%, #a08040 50%, #b89550 100%);
            color: #1a1610;
            border-color: #e8d4a0;
        }
        body.theme-mota .creator-pill.active {
            background: linear-gradient(135deg, #00897b 0%, #00695c 50%, #00796b 100%);
            color: #e0f2f1;
            border-color: #4db6ac;
        }
        body.theme-uxhiha .creator-pill.active {
            background: linear-gradient(135deg, #b22222 0%, #8b0000 50%, #a52a2a 100%);
            color: #ffcccc;
            border-color: #dc143c;
        }
        #search-input {
            min-width: 220px;
            padding: 6px 8px;
            border-radius: 4px;
            border: 1px solid #555;
            background: #0d0d0d;
            color: #f5f5f5;
            font-size: 12px;
        }
        #search-input::placeholder {
            color: #777;
        }

        .legend-row {
            display: flex;
            flex-wrap: wrap;
            gap: 12px;
            font-size: 11px;
            color: #bbbbbb;
            text-transform: uppercase;
            letter-spacing: 1px;
        }
        .legend-pill {
            display: inline-flex;
            align-items: center;
            gap: 6px;
            padding: 4px 8px;
            border-radius: 999px;
            border: 1px solid #444;
            background: #151515;
        }
        .legend-row .section-tab {
            padding: 4px 12px;
            font-size: 11px;
            letter-spacing: 1px;
            text-transform: uppercase;
            border: 1px solid #444;
            background: #151515;
            color: #bbbbbb;
            border-radius: 999px;
            cursor: pointer;
            flex-wrap: wrap;
            transition: background 0.15s, color 0.15s, border-color 0.15s;
        }
        .legend-row .section-tab:hover {
            background: #222;
            color: #fff;
        }
        .legend-row .section-tab.active {
            background: linear-gradient(135deg, #ff8c00 0%, #ff6b00 100%);
            color: #111;
            border-color: #ff8c00;
        }
        .legend-pill-text {
            cursor: default;
        }
        .legend-count {
            margin-left: 4px;
            font-weight: 700;
            color: #888;
        }
        .legend-row .section-tab.active .legend-count {
            color: #111;
        }
        .dev-leaderboard-wrap {
            max-width: 720px;
            margin: 0 auto;
            padding: 8px 4px 24px;
        }
        .dev-leaderboard-head {
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            justify-content: space-between;
            gap: 12px;
            margin-bottom: 16px;
        }
        .dev-leaderboard-head h2 {
            margin: 0;
            font-size: 18px;
            color: #00d4ff;
        }
        .dev-leaderboard-hint {
            margin: 0 0 14px;
            font-size: 12px;
            color: rgba(255, 255, 255, 0.55);
            line-height: 1.45;
        }
        .dev-leaderboard-table-wrap {
            border: 1px solid rgba(0, 212, 255, 0.25);
            border-radius: 10px;
            overflow: hidden;
            background: rgba(0, 0, 0, 0.35);
        }
        .dev-leaderboard-table {
            width: 100%;
            border-collapse: collapse;
            font-size: 13px;
            table-layout: fixed;
        }
        .dev-leaderboard-table th,
        .dev-leaderboard-table td {
            padding: 10px 14px;
            border-bottom: 1px solid rgba(255, 255, 255, 0.06);
            vertical-align: middle;
        }
        .dev-leaderboard-table th {
            font-size: 11px;
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 0.08em;
            color: #00d4ff;
            background: rgba(0, 212, 255, 0.1);
            text-align: left;
        }
        .dev-leaderboard-table th.lb-col-num,
        .dev-leaderboard-table td.lb-col-num {
            width: 72px;
            text-align: right;
            font-variant-numeric: tabular-nums;
        }
        .dev-leaderboard-table td.lb-col-creator {
            font-weight: 600;
            color: #fff;
            word-break: break-word;
        }
        .dev-leaderboard-table tbody tr:hover td {
            background: rgba(0, 212, 255, 0.06);
        }
        .dev-leaderboard-table tbody tr:last-child td {
            border-bottom: none;
        }
        .dev-leaderboard-totals {
            margin-top: 14px;
            font-size: 12px;
            color: rgba(255, 255, 255, 0.55);
        }
        .dev-leaderboard-empty {
            padding: 24px;
            text-align: center;
            color: rgba(255, 255, 255, 0.5);
            font-size: 13px;
        }

        .legend-creator-count {
            flex-basis: 100%;
            display: none;
            margin-top: 4px;
            padding: 2px 10px;
            border-radius: 999px;
            font-size: 10px;
            font-weight: 700;
            letter-spacing: 0.4px;
            text-transform: none;
            border: 1px solid rgba(255, 255, 255, 0.18);
            background: rgba(0, 0, 0, 0.35);
            color: rgba(255, 255, 255, 0.88);
        }
        .legend-row .section-tab.active .legend-creator-count {
            border-color: rgba(0, 0, 0, 0.22);
            background: rgba(255, 255, 255, 0.32);
            color: #111;
        }
        .search-result-summary {
            font-size: 12px;
            color: #ffcc80;
            margin-top: 6px;
            min-height: 1.4em;
        }
        .codes-list-bar {
            margin-top: 12px;
            padding: 12px 16px;
            background: #1a1a1a;
            border: 1px solid #444;
            border-radius: 6px;
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            gap: 12px;
        }
        .codes-list-bar #codes-list-label {
            font-size: 12px;
            font-weight: 700;
            color: #ffcc80;
            text-transform: uppercase;
            letter-spacing: 1px;
        }
        .codes-list-actions {
            display: flex;
            gap: 8px;
            flex-wrap: wrap;
        }
        .codes-list-text {
            width: 100%;
            margin-top: 6px;
            padding: 6px 8px;
            background: #050505;
            border-radius: 4px;
            border: 1px solid #444;
            color: #f5f5f5;
            font-size: 11px;
            font-family: "Courier New", monospace;
            resize: vertical;
            min-height: 60px;
        }
        .legend-swatch {
            width: 14px;
            height: 14px;
            border-radius: 3px;
        }
        .legend-swatch-legit {
            background: linear-gradient(135deg, #ffd54f 0%, #ff8f00 100%);
            box-shadow: 0 0 6px rgba(255, 193, 7, 0.7);
        }
        .legend-swatch-modded {
            background: linear-gradient(135deg, #29b6f6 0%, #00838f 100%);
            box-shadow: 0 0 6px rgba(41, 182, 246, 0.6);
        }

        .catalog-pagination--top {
            margin-top: 8px;
            margin-bottom: 10px;
        }

        .catalog-pagination-page-btn.is-active {
            border-color: #8b7cf5;
            color: #fff;
            background: rgba(139, 124, 245, 0.22);
        }

        .items-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
            gap: 14px;
            margin-top: 4px;
        }

        .catalog-pagination {
            display: flex;
            flex-wrap: wrap;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            margin: 14px 0 4px;
            padding: 10px 12px;
            border: 1px solid #333;
            border-radius: 8px;
            background: rgba(0, 0, 0, 0.25);
        }

        .catalog-pagination-info {
            font-size: 0.82rem;
            color: #bbb;
        }

        .catalog-pagination-controls {
            display: inline-flex;
            align-items: center;
            gap: 10px;
        }

        .catalog-pagination-label {
            font-size: 0.82rem;
            color: #ddd;
            min-width: 88px;
            text-align: center;
        }

        .item-vote-btn[disabled] {
            opacity: 0.65;
            cursor: default;
        }

        .item-card {
            position: relative;
            padding: 14px 14px 12px;
            background: radial-gradient(circle at top left, #3b3b3b 0, #191919 40%, #101010 100%);
            border-radius: 8px;
            border: 2px solid #333;
            box-shadow: 0 4px 14px rgba(0, 0, 0, 0.7);
            overflow: hidden;
            display: flex;
            flex-direction: column;
            gap: 8px;
            transition: transform 0.12s ease-out, box-shadow 0.12s ease-out, border-color 0.12s ease-out;
            content-visibility: auto;
            contain-intrinsic-size: 360px 420px;
        }
        .item-card::before {
            content: "";
            position: absolute;
            inset: -2px;
            border-radius: 10px;
            border: 2px solid transparent;
            pointer-events: none;
        }
        .item-card-legit {
            border-color: #ffb300;
        }
        .item-card-legit::before {
            border-color: rgba(255, 184, 0, 0.25);
        }
        .item-card-modded {
            border-color: #00bcd4;
        }
        .item-card-modded::before {
            border-color: rgba(0, 188, 212, 0.25);
        }
        .item-card-builds {
            border-color: #9c27b0;
        }
        .item-card-builds::before {
            border-color: rgba(156, 39, 176, 0.25);
        }
        .tag-builds, .legend-swatch-builds { }
        .item-card:hover {
            transform: translateY(-2px);
            box-shadow: 0 8px 18px rgba(0, 0, 0, 0.9);
        }

        .item-header {
            display: flex;
            flex-direction: column;
            gap: 4px;
            padding-bottom: 4px;
            border-bottom: 1px solid #333;
        }
        .item-tag {
            display: inline-flex;
            align-items: center;
            align-self: flex-start;
            gap: 6px;
            padding: 2px 8px;
            border-radius: 999px;
            font-size: 10px;
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 1px;
            border: 1px solid #444;
            background: #101010;
        }
        .tag-legit {
            border-color: #ffb300;
            color: #ffe082;
        }
        .tag-modded {
            border-color: #00bcd4;
            color: #80deea;
        }
        .item-card-pending {
            border-color: #c9a227;
        }
        .item-card-pending::before {
            border-color: rgba(201, 162, 39, 0.35);
        }
        .tag-pending {
            border-color: #c9a227;
            color: #ffe082;
        }
        .legend-swatch-owner-red {
            background: #e53935;
            box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.35);
        }
        .dev-inbox-btn {
            position: relative;
            display: none;
            align-items: center;
            justify-content: center;
            width: 38px;
            height: 34px;
            padding: 0;
            border-radius: 8px;
            border: 1px solid #444;
            background: #1a1a1a;
            color: #e8e8e8;
            cursor: pointer;
            line-height: 1;
        }
        .dev-inbox-btn:hover {
            background: #252525;
            border-color: #666;
        }
        .dev-inbox-icon {
            display: block;
            font-size: 18px;
        }
        .dev-inbox-badge {
            position: absolute;
            top: -5px;
            right: -5px;
            min-width: 18px;
            height: 18px;
            padding: 0 5px;
            border-radius: 999px;
            background: #e53935;
            color: #fff;
            font-size: 11px;
            font-weight: 700;
            line-height: 18px;
            text-align: center;
            display: none;
        }
        .dev-inbox-badge.visible {
            display: inline-block;
        }
        .dev-inbox-modal .public-messages-list {
            max-height: min(60vh, 420px);
        }
        .public-msg-toggle {
            width: 100%;
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            text-align: left;
            font-weight: 600;
            padding: 12px 14px;
            border-radius: 8px;
            border: 1px solid rgba(229, 57, 53, 0.55);
            background: rgba(40, 18, 18, 0.9);
            color: #ffcdd2;
            cursor: pointer;
        }
        .public-msg-toggle:hover {
            background: rgba(55, 24, 24, 0.95);
        }
        .public-msg-toggle .chev {
            opacity: 0.7;
            font-size: 12px;
        }
        .public-msg-compose-wrap {
            margin-top: 14px;
            padding-top: 14px;
            border-top: 1px solid rgba(229, 57, 53, 0.25);
        }
        .public-msg-compose-wrap[hidden] {
            display: none !important;
        }
        .public-messages-dev-wrap {
            margin-top: 18px;
            padding-top: 14px;
            border-top: 1px solid rgba(255, 255, 255, 0.12);
        }
        .public-messages-dev-wrap h3 {
            margin: 0 0 8px;
            font-size: 13px;
            font-weight: 600;
            color: rgba(255, 205, 210, 0.85);
        }
        .owner-comments-toggle {
            display: flex;
            align-items: center;
            justify-content: space-between;
            width: 100%;
            text-align: left;
            font-weight: 600;
        }
        .owner-comments-compose-wrap[hidden] {
            display: none !important;
        }
        .public-messages-list {
            max-height: 280px;
            overflow: auto;
            margin: 12px 0;
            font-size: 13px;
        }
        .public-message-row {
            padding: 10px 12px;
            margin-bottom: 8px;
            background: #141414;
            border-radius: 8px;
            border: 1px solid #333;
        }
        .public-message-meta {
            font-size: 11px;
            color: #888;
            margin-bottom: 6px;
        }
        .public-message-body {
            white-space: pre-wrap;
            word-break: break-word;
        }
        .public-message-img-wrap {
            margin-top: 8px;
        }
        .public-message-img-wrap img {
            max-width: 100%;
            max-height: 320px;
            border-radius: 6px;
            border: 1px solid #333;
            vertical-align: middle;
        }
        .public-message-replies {
            margin: 10px 0 0 10px;
            padding-left: 12px;
            border-left: 2px solid rgba(255, 255, 255, 0.12);
        }
        .public-message-reply {
            margin-bottom: 10px;
            font-size: 12px;
        }
        .public-message-reply .reply-author {
            color: #81c784;
            font-weight: 600;
        }
        .dev-inline-reply {
            margin-top: 10px;
            padding-top: 8px;
            border-top: 1px solid #2a2a2a;
        }
        .dev-inline-reply textarea {
            width: 100%;
            min-height: 52px;
            font-size: 12px;
            margin-bottom: 6px;
            box-sizing: border-box;
        }
        .dev-inline-reply input[type="file"] {
            font-size: 11px;
            margin-bottom: 6px;
        }
        .edit-req-comment-block {
            margin-bottom: 12px;
            padding-bottom: 10px;
            border-bottom: 1px solid #2a2a2a;
        }
        .edit-req-replies {
            margin: 8px 0 0 10px;
            padding-left: 10px;
            border-left: 2px solid rgba(129, 199, 132, 0.25);
        }
        body.theme-tobgun1 .item-card {
            background: radial-gradient(circle at top left, #1e3260 0, #0c1528 40%, #050a16 100%);
            border-color: #283593;
        }
        body.theme-tobgun1 .item-card::before {
            border-color: rgba(183, 28, 28, 0.35);
        }
        body.theme-tobgun1 .item-card-legit {
            border-color: #42a5f5;
        }
        body.theme-tobgun1 .item-card-legit::before {
            border-color: rgba(66, 165, 245, 0.35);
        }
        body.theme-tobgun1 .item-card-modded {
            border-color: #ef5350;
        }
        body.theme-tobgun1 .item-card-modded::before {
            border-color: rgba(239, 83, 80, 0.4);
        }
        body.theme-tobgun1 .tag-legit {
            border-color: #42a5f5;
            color: #bbdefb;
        }
        body.theme-tobgun1 .tag-modded {
            border-color: #ef5350;
            color: #ffcdd2;
        }
        body.theme-aries .item-card {
            background: radial-gradient(circle at top left, rgba(10, 30, 60, 0.96) 0, rgba(24, 49, 92, 0.98) 35%, rgba(40, 60, 50, 0.98) 70%, rgba(64, 89, 53, 0.98) 100%);
            border-color: #c5e1a5;
        }
        body.theme-aries .item-card::before {
            border-color: rgba(174, 213, 129, 0.55);
        }
        body.theme-aries .item-card-legit {
            border-color: #c5e1a5;
        }
        body.theme-aries .item-card-legit::before {
            border-color: rgba(174, 213, 129, 0.65);
        }
        body.theme-aries .item-card-modded {
            border-color: #81c784;
        }
        body.theme-aries .item-card-modded::before {
            border-color: rgba(129, 199, 132, 0.65);
        }
        body.theme-aries .tag-legit {
            border-color: #c5e1a5;
            color: #f0f4c3;
        }
        body.theme-aries .tag-modded {
            border-color: #81c784;
            color: #c8e6c9;
        }
        body.theme-ynot {
            background:
                radial-gradient(circle at 0% 0%, rgba(0, 188, 212, 0.18) 0, transparent 40%),
                radial-gradient(circle at 100% 10%, rgba(0, 229, 255, 0.16) 0, transparent 45%),
                radial-gradient(circle at 20% 100%, rgba(0, 151, 167, 0.22) 0, transparent 45%),
                radial-gradient(circle at 80% 80%, rgba(3, 169, 244, 0.24) 0, transparent 55%),
                radial-gradient(circle at 50% 50%, #021016 0, #000000 70%);
            color: #e0f7fa;
        }
        body.theme-ynot .codes-layout {
            border-color: #00e5ff;
            background: linear-gradient(135deg, #001018 0%, #001c26 30%, #002b36 65%, #004252 100%);
            box-shadow: 0 0 38px rgba(0, 229, 255, 0.75);
        }
        body.theme-ynot .codes-header {
            background: repeating-linear-gradient(
                -45deg,
                rgba(0, 96, 100, 0.9),
                rgba(0, 96, 100, 0.9) 8px,
                rgba(0, 151, 167, 0.9) 8px,
                rgba(0, 151, 167, 0.9) 16px
            );
            border-bottom-color: #00e5ff;
        }
        body.theme-ynot .codes-header-title h1 {
            color: #84ffff;
            text-shadow: 0 0 6px #000, 0 0 14px rgba(0, 229, 255, 0.9);
        }
        body.theme-ynot .codes-header-meta strong {
            color: #a7ffeb;
        }
        body.theme-ynot .creator-pill.active {
            background: linear-gradient(135deg, #00e5ff 0%, #00bcd4 45%, #00838f 100%);
            color: #001015;
            border-color: #00e5ff;
        }
        body.theme-ynot .item-card {
            background: radial-gradient(circle at top left, rgba(0, 40, 60, 0.98) 0, rgba(0, 57, 81, 0.98) 35%, rgba(0, 77, 97, 0.99) 70%, rgba(0, 96, 100, 0.99) 100%);
            border-color: #00bcd4;
        }
        body.theme-ynot .item-card::before {
            border-color: rgba(0, 229, 255, 0.7);
        }
        body.theme-ynot .item-card-legit {
            border-color: #18ffff;
        }
        body.theme-ynot .item-card-legit::before {
            border-color: rgba(129, 212, 250, 0.7);
        }
        body.theme-ynot .item-card-modded {
            border-color: #00e5ff;
        }
        body.theme-ynot .item-card-modded::before {
            border-color: rgba(0, 229, 255, 0.8);
        }
        body.theme-ynot .tag-legit {
            border-color: #18ffff;
            color: #e0f7fa;
        }
        body.theme-ynot .tag-modded {
            border-color: #00e5ff;
            color: #b2ebf2;
        }
        body.theme-skippy .item-card {
            background: radial-gradient(circle at top left, #1a0505 0, #0d0000 40%, #050000 100%);
            border-color: #4a1515;
        }
        body.theme-skippy .item-card::before {
            border-color: rgba(183, 28, 28, 0.3);
        }
        body.theme-skippy .item-card-legit {
            border-color: #b71c1c;
        }
        body.theme-skippy .item-card-legit::before {
            border-color: rgba(183, 28, 28, 0.4);
        }
        body.theme-skippy .item-card-modded {
            border-color: #c62828;
        }
        body.theme-skippy .item-card-modded::before {
            border-color: rgba(198, 40, 40, 0.5);
        }
        body.theme-skippy .tag-legit {
            border-color: #b71c1c;
            color: #ffcdd2;
        }
        body.theme-skippy .tag-modded {
            border-color: #ef5350;
            color: #ffcdd2;
        }
        body.theme-terra-morpheous .item-card {
            background: radial-gradient(circle at top left, rgba(45, 25, 65, 0.98) 0, rgba(30, 15, 45, 0.98) 50%, rgba(27, 94, 32, 0.15) 100%);
            border-color: #6a1b9a;
        }
        body.theme-terra-morpheous .item-card::before {
            border-color: rgba(156, 39, 176, 0.35);
        }
        body.theme-terra-morpheous .item-card-legit {
            border-color: #7b1fa2;
        }
        body.theme-terra-morpheous .item-card-legit::before {
            border-color: rgba(123, 31, 162, 0.45);
        }
        body.theme-terra-morpheous .item-card-modded {
            border-color: #4caf50;
        }
        body.theme-terra-morpheous .item-card-modded::before {
            border-color: rgba(76, 175, 80, 0.45);
        }
        body.theme-terra-morpheous .tag-legit {
            border-color: #ce93d8;
            color: #e1bee7;
        }
        body.theme-terra-morpheous .tag-modded {
            border-color: #81c784;
            color: #c8e6c9;
        }
        body.theme-ammo .item-card {
            background: radial-gradient(circle at top left, #2a261e 0, #1a1814 40%, #151310 100%);
            border-color: #5d4e37;
        }
        body.theme-ammo .item-card::before {
            border-color: rgba(139, 115, 85, 0.3);
        }
        body.theme-ammo .item-card-legit {
            border-color: #8b7355;
        }
        body.theme-ammo .item-card-legit::before {
            border-color: rgba(139, 115, 85, 0.4);
        }
        body.theme-ammo .item-card-modded {
            border-color: #a08060;
        }
        body.theme-ammo .item-card-modded::before {
            border-color: rgba(196, 163, 90, 0.35);
        }
        body.theme-ammo .tag-legit {
            border-color: #8b7355;
            color: #d4c4a8;
        }
        body.theme-ammo .tag-modded {
            border-color: #c4a35a;
            color: #e8dcc4;
        }
        body.theme-muffin .item-card {
            background: radial-gradient(circle at top left, #2a2418 0%, #1e1a12 40%, #181410 100%);
            border-color: #8b7355;
        }
        body.theme-muffin .item-card::before {
            border-color: rgba(196, 163, 90, 0.3);
        }
        body.theme-muffin .item-card-legit {
            border-color: #b89550;
        }
        body.theme-muffin .item-card-legit::before {
            border-color: rgba(184, 149, 80, 0.4);
        }
        body.theme-muffin .item-card-modded {
            border-color: #c4a35a;
        }
        body.theme-muffin .item-card-modded::before {
            border-color: rgba(196, 163, 90, 0.45);
        }
        body.theme-muffin .tag-legit {
            border-color: #b89550;
            color: #e8d4a0;
        }
        body.theme-muffin .tag-modded {
            border-color: #c4a35a;
            color: #f5e6c8;
        }
        body.theme-mota .item-card {
            border-color: rgba(0, 150, 136, 0.4);
            background: linear-gradient(145deg, rgba(14, 31, 28, 0.95) 0%, rgba(8, 22, 20, 0.98) 100%);
        }
        body.theme-mota .item-card::before {
            border-color: rgba(0, 150, 136, 0.25);
        }
        body.theme-mota .item-card-legit {
            border-color: rgba(0, 150, 136, 0.35);
        }
        body.theme-mota .item-card-legit::before {
            border-color: rgba(0, 150, 136, 0.2);
        }
        body.theme-mota .item-card-modded {
            border-color: rgba(0, 137, 123, 0.5);
        }
        body.theme-mota .item-card-modded::before {
            border-color: rgba(0, 137, 123, 0.3);
        }
        body.theme-mota .tag-legit {
            border-color: #00695c;
            color: #80cbc4;
        }
        body.theme-mota .tag-modded {
            border-color: #00897b;
            color: #b2dfdb;
        }
        body.theme-uxhiha .item-card {
            border-color: rgba(178, 34, 34, 0.5);
        }
        body.theme-uxhiha .item-card::before {
            border-color: rgba(178, 34, 34, 0.3);
        }
        body.theme-uxhiha .item-card-legit {
            border-color: rgba(178, 34, 34, 0.4);
        }
        body.theme-uxhiha .item-card-legit::before {
            border-color: rgba(178, 34, 34, 0.25);
        }
        body.theme-uxhiha .item-card-modded {
            border-color: #b22222;
        }
        body.theme-uxhiha .item-card-modded::before {
            border-color: rgba(178, 34, 34, 0.4);
        }
        body.theme-uxhiha .tag-legit {
            border-color: #8b0000;
            color: #ffb3b3;
        }
        body.theme-uxhiha .tag-modded {
            border-color: #b22222;
            color: #ffcccc;
        }
        .item-name {
            margin: 0;
            font-size: 16px;
            font-weight: 700;
            color: #ffffff;
            text-shadow: 0 0 4px #000;
        }
        .item-meta {
            font-size: 11px;
            color: #bbbbbb;
        }

        .item-image-wrap {
            margin-top: 6px;
            border-radius: 6px;
            overflow: hidden;
            border: 1px solid #333;
            background: #0a0a0a linear-gradient(110deg, #141414 8%, #1f1f1f 18%, #141414 33%);
            background-size: 200% 100%;
            min-height: 140px;
            cursor: zoom-in;
        }
        .item-image {
            display: block;
            width: 100%;
            height: auto;
            min-height: 140px;
            object-fit: contain;
            transition: transform 0.15s ease-out, opacity 0.2s ease-out;
        }
        .item-image.item-image-pending {
            opacity: 0;
        }
        .item-image-wrap:hover .item-image {
            transform: scale(1.04);
        }

        .dps-calc-grid {
            display: grid;
            grid-template-columns: repeat(2, minmax(0, 1fr));
            gap: 10px;
        }
        .dps-calc-grid label {
            display: flex;
            flex-direction: column;
            gap: 6px;
            font-size: 12px;
            color: #ffd180;
        }
        .dps-calc-grid input {
            width: 100%;
            padding: 8px 10px;
            border-radius: 6px;
            border: 1px solid #5a4a2c;
            background: #0e0a04;
            color: #fff8e1;
        }
        .dps-calc-result {
            margin-top: 12px;
            padding: 12px 14px;
            border-radius: 8px;
            border: 1px solid rgba(255, 193, 7, 0.35);
            background: rgba(255, 193, 7, 0.08);
            color: #fff3cd;
            font-size: 13px;
            line-height: 1.45;
        }
        .dps-calc-result-intro {
            margin: 0 0 10px;
            font-size: 13px;
            font-weight: 600;
            color: #fff8e1;
            line-height: 1.4;
        }
        .dps-calc-table-wrap {
            max-height: min(52vh, 380px);
            overflow: auto;
            border-radius: 8px;
            border: 1px solid rgba(255, 193, 7, 0.22);
            background: rgba(0, 0, 0, 0.35);
        }
        .dps-calc-table {
            width: 100%;
            border-collapse: collapse;
            font-size: 12px;
        }
        .dps-calc-table thead th {
            position: sticky;
            top: 0;
            z-index: 1;
            padding: 8px 10px;
            text-align: left;
            font-size: 10px;
            text-transform: uppercase;
            letter-spacing: 0.06em;
            color: #ffcc80;
            background: rgba(26, 18, 8, 0.98);
            border-bottom: 1px solid rgba(255, 193, 7, 0.25);
        }
        .dps-calc-table tbody td {
            padding: 6px 10px;
            border-bottom: 1px solid rgba(255, 255, 255, 0.06);
            color: #f0f0f0;
        }
        .dps-calc-table tbody td:last-child {
            text-align: right;
            font-variant-numeric: tabular-nums;
            font-weight: 600;
            color: #ffe082;
        }
        .dps-calc-table tbody tr:nth-child(even) td {
            background: rgba(255, 255, 255, 0.02);
        }
        .dps-calc-table tbody tr.dps-calc-row-baseline td {
            background: rgba(255, 193, 7, 0.14);
            box-shadow: inset 3px 0 0 0 #ffb74d;
        }
        .dps-calc-table tbody tr.dps-calc-row-baseline td:first-child {
            font-weight: 700;
            color: #ffe082;
        }
        .dps-calc-note {
            margin-top: 8px;
            font-size: 11px;
            color: #ffd180;
        }

        .item-notes {
            font-size: 11px;
            color: #cccccc;
            background: rgba(0, 0, 0, 0.55);
            border-radius: 4px;
            padding: 6px 8px;
            border-left: 3px solid #555;
        }
        .item-notes-row {
            margin-top: 8px;
            display: flex;
            flex-direction: column;
            gap: 6px;
        }
        .item-notes-head {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 10px;
            flex-wrap: wrap;
        }
        .item-notes-label {
            font-size: 11px;
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 0.04em;
            color: #ff8c00;
        }
        .item-notes-body {
            font-size: 11px;
            color: #cccccc;
            background: rgba(0, 0, 0, 0.55);
            border-radius: 4px;
            padding: 6px 8px;
            border-left: 3px solid #555;
            white-space: pre-wrap;
            word-break: break-word;
        }

        .item-codes {
            margin-top: 4px;
            display: flex;
            flex-direction: column;
            gap: 6px;
        }
        .code-block {
            display: flex;
            flex-direction: column;
            gap: 4px;
        }
        .code-label {
            font-size: 11px;
            text-transform: uppercase;
            letter-spacing: 1px;
            color: #ffcc80;
        }
        .code-label-row {
            display: flex;
            flex-wrap: wrap;
            align-items: baseline;
            gap: 8px;
        }
        .code-label-note {
            font-size: 10px;
            font-weight: 500;
            text-transform: none;
            letter-spacing: 0.02em;
            color: #b8b0a5;
        }
        .code-text {
            width: 100%;
            min-height: 40px;
            max-height: 90px;
            resize: vertical;
            padding: 5px 6px;
            border-radius: 4px;
            border: 1px solid #555;
            background: #050505;
            color: #f5f5f5;
            font-size: 11px;
            font-family: "Courier New", monospace;
        }
        .code-buttons {
            display: flex;
            gap: 6px;
            flex-wrap: wrap;
        }
        .btn-discord {
            border-color: #5865f2;
            background: linear-gradient(135deg, #5865f2 0%, #4752c4 100%);
            color: #fff;
            text-decoration: none;
            display: inline-flex;
            align-items: center;
            justify-content: center;
        }
        .btn-discord:hover {
            color: #fff;
        }
        .item-meta-tacklebox {
            color: #7eb8ff;
            font-weight: 600;
        }
        .submit-tacklebox-discord {
            margin-top: 14px;
            padding-top: 12px;
            border-top: 1px solid var(--b1);
        }
        .submit-tacklebox-discord .btn-discord {
            margin-top: 8px;
        }
        .btn-website {
            border-color: #f9a825;
            background: linear-gradient(135deg, #f9a825 0%, #f57f17 100%);
            color: #1a1200;
            text-decoration: none;
            display: inline-flex;
            align-items: center;
            justify-content: center;
            font-weight: 600;
        }
        .btn-website:hover {
            color: #1a1200;
        }
        .submit-lootlemon-website {
            margin-top: 0;
            border: 1px solid rgba(249, 168, 37, 0.45);
            border-radius: 10px;
            padding: 14px 16px;
            background: rgba(249, 168, 37, 0.08);
        }
        .submit-lootlemon-website .submit-catalog-section-title {
            color: #f9a825;
        }

        .item-actions {
            display: flex;
            gap: 8px;
            flex-wrap: wrap;
            margin-top: 6px;
        }
        .btn {
            padding: 6px 10px;
            border-radius: 4px;
            border: 1px solid #ff8c00;
            background: linear-gradient(135deg, #ff8c00 0%, #ff6b00 100%);
            color: #111;
            font-size: 11px;
            font-weight: 700;
            text-transform: uppercase;
            letter-spacing: 1px;
            cursor: pointer;
            transition: transform 0.1s ease-out, box-shadow 0.1s ease-out, background 0.1s ease-out;
        }
        .btn.small {
            padding: 4px 8px;
            font-size: 10px;
        }
        .btn.secondary {
            background: #202020;
            border-color: #777;
            color: #f0f0f0;
        }
        .btn:hover:not(:disabled) {
            transform: translateY(-1px);
            box-shadow: 0 3px 8px rgba(0, 0, 0, 0.8);
        }
        .btn:disabled {
            opacity: 0.5;
            cursor: default;
        }

        .empty-state {
            padding: 24px;
            border-radius: 6px;
            border: 1px dashed #555;
            background: rgba(0, 0, 0, 0.4);
            font-size: 12px;
            text-align: center;
            color: #bbbbbb;
        }

        .inline-translator {
            margin-top: 12px;
            padding: 12px 14px;
            border-radius: 8px;
            border: 2px solid #444;
            background: radial-gradient(circle at top left, #2b2510 0, #15120a 40%, #050403 100%);
        }
        .inline-translator-header {
            display: flex;
            justify-content: space-between;
            align-items: baseline;
            gap: 8px;
            margin-bottom: 8px;
        }
        .inline-translator-title {
            font-size: 14px;
            font-weight: 700;
            color: #ffca28;
            text-transform: uppercase;
            letter-spacing: 1px;
        }
        .inline-translator-subtitle {
            font-size: 10px;
            color: #dddddd;
            text-transform: uppercase;
            letter-spacing: 1px;
        }
        .translator-status {
            margin-bottom: 8px;
            padding: 6px 8px;
            border-radius: 4px;
            font-size: 11px;
        }
        .translator-status-info {
            background: rgba(255, 193, 7, 0.15);
            border: 1px solid #ffb300;
            color: #ffe082;
        }
        .translator-status-success {
            background: rgba(76, 175, 80, 0.18);
            border: 1px solid #66bb6a;
            color: #c5e1a5;
        }
        .translator-status-error {
            background: rgba(244, 67, 54, 0.18);
            border: 1px solid #ef5350;
            color: #ffcdd2;
        }
        .inline-translator-body {
            display: grid;
            grid-template-columns: minmax(0, 1.1fr) minmax(0, 1.9fr);
            gap: 10px;
        }
        .inline-translator-body > div {
            display: flex;
            flex-direction: column;
            gap: 4px;
        }
        .inline-translator-label {
            font-size: 11px;
            text-transform: uppercase;
            letter-spacing: 1px;
            color: #ffcc80;
        }
        #inline-translator-deserialized {
            width: 100%;
            min-height: 70px;
            max-height: 160px;
            resize: vertical;
            padding: 6px 8px;
            border-radius: 4px;
            border: 1px solid #555;
            background: #050505;
            color: #f5f5f5;
            font-size: 11px;
            font-family: "Courier New", monospace;
        }
        #inline-translator-output {
            width: 100%;
            min-height: 70px;
            max-height: 160px;
            padding: 6px 8px;
            border-radius: 4px;
            border: 1px solid #555;
            background: #050505;
            color: #f5f5f5;
            font-size: 11px;
            font-family: "Courier New", monospace;
            white-space: pre-wrap;
            overflow-y: auto;
        }

        .footer-note {
            margin-top: 10px;
            font-size: 10px;
            color: #888888;
            text-transform: uppercase;
            letter-spacing: 1px;
        }

        .image-modal {
            position: fixed;
            inset: 0;
            background: rgba(0, 0, 0, 0.85);
            display: none;
            align-items: center;
            justify-content: center;
            z-index: 9999;
        }
        .image-modal-inner {
            max-width: 90vw;
            max-height: 90vh;
            display: flex;
            flex-direction: column;
            gap: 8px;
            align-items: flex-end;
        }
        .image-modal-img {
            max-width: 100%;
            max-height: 100%;
            border-radius: 8px;
            border: 2px solid #ff8c00;
            box-shadow: 0 0 24px rgba(0, 0, 0, 0.9);
        }
        .image-modal-close {
            align-self: flex-end;
        }

        @media (max-width: 900px) {
            .codes-main {
                padding: 14px;
            }
            .inline-translator-body {
                grid-template-columns: minmax(0, 1fr);
            }
        }

/* === Codes.html revamp (layout hierarchy) === */
:root {
    --codes-cta-bg: linear-gradient(135deg, #ff8c00 0%, #ff6b00 100%);
    --codes-cta-shadow: 0 4px 18px rgba(255, 140, 0, 0.35);
    --codes-zone-bg: rgba(0, 0, 0, 0.28);
    --codes-zone-border: rgba(255, 255, 255, 0.08);
}

.codes-header-slim {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding: 16px 22px;
}

.codes-header-start {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 12px 18px;
    min-width: 0;
}

.codes-header-end {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
}

.codes-back-link {
    border: none;
    background: transparent;
    color: rgba(255, 204, 128, 0.95);
    font-size: 12px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    cursor: pointer;
    padding: 0;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.codes-back-link:hover {
    color: #fff;
}

.codes-header-meta--inline {
    flex-direction: row;
    align-items: center;
    gap: 8px;
    text-align: left;
    font-size: 11px;
    text-transform: none;
    letter-spacing: 0.2px;
    color: rgba(255, 255, 255, 0.72);
}

.codes-header-meta--inline strong {
    color: #ffcc80;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-size: 10px;
}

.codes-header-meta-sep {
    opacity: 0.45;
}

.btn.cta-submit {
    padding: 12px 22px;
    border: none;
    border-radius: 10px;
    background: var(--codes-cta-bg);
    color: #111;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: var(--codes-cta-shadow);
    transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.btn.cta-submit:hover {
    transform: translateY(-1px);
    filter: brightness(1.06);
}

.btn.cta-submit.active {
    outline: 2px solid rgba(255, 255, 255, 0.45);
    outline-offset: 2px;
}

.codes-tools-wrap {
    position: relative;
}

.codes-tools-menu {
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 200px;
    padding: 6px;
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: #151515;
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.65);
    z-index: 50;
}

.codes-tools-item {
    display: block;
    width: 100%;
    text-align: left;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: #eee;
    padding: 10px 12px;
    font-size: 13px;
    cursor: pointer;
}

.codes-tools-item:hover {
    background: rgba(255, 140, 0, 0.14);
}

.codes-dev-label {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.55);
}

.codes-header-inbox[hidden] {
    display: none !important;
}

.catalog-zone {
    margin-top: 4px;
    padding: 16px;
    border-radius: 10px;
    border: 1px solid var(--codes-zone-border);
    background: var(--codes-zone-bg);
}

.catalog-zone-label {
    margin: 0 0 12px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1.4px;
    text-transform: uppercase;
    color: rgba(255, 204, 128, 0.8);
}

.catalog-toolbar {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 14px;
}

.catalog-nav {
    margin-top: 2px;
    margin-bottom: 6px;
    gap: 8px;
}

.catalog-nav .section-tab {
    padding: 8px 16px;
    font-size: 12px;
    border-radius: 8px;
    border: 1px solid #444;
}

.catalog-hint {
    margin: 0 0 12px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    letter-spacing: 0.2px;
}

.codes-submit-sticky {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 1200;
    padding: 12px 18px;
    border: none;
    border-radius: 999px;
    background: var(--codes-cta-bg);
    color: #111;
    font-weight: 800;
    font-size: 13px;
    letter-spacing: 0.3px;
    text-transform: uppercase;
    cursor: pointer;
    box-shadow: var(--codes-cta-shadow);
}

.codes-submit-sticky[hidden] {
    display: none !important;
}

.header-dev-row {
    display: none;
}

@media (min-width: 901px) {
    .codes-header-slim {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }
    .codes-submit-sticky {
        display: none !important;
    }
}

@media (max-width: 900px) {
    .codes-header-end {
        width: 100%;
        justify-content: stretch;
    }
    .btn.cta-submit {
        flex: 1 1 100%;
        text-align: center;
    }
    .catalog-zone {
        padding: 12px;
    }
    .filter-row {
        display: grid;
        grid-template-columns: 1fr;
        gap: 10px;
    }
    .creator-pills {
        flex-wrap: nowrap;
        overflow-x: auto;
        max-width: 100%;
        padding-bottom: 4px;
    }
    .catalog-nav {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 4px;
    }
}


/* Tools menu: avoid clipping inside .codes-layout overflow */
.codes-header-slim {
    overflow: visible;
    z-index: 150;
}

.codes-tools-menu.is-open {
    position: fixed;
    z-index: 4000;
    min-width: 200px;
    max-width: calc(100vw - 24px);
}

@media (max-width: 900px) {
    .codes-tools-menu.is-open {
        left: 12px !important;
        right: 12px !important;
        width: auto !important;
        min-width: 0;
    }
}

.scan-dlc-modal .scan-dlc-modal-box {
    width: min(960px, 96vw);
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.scan-dlc-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}
.scan-dlc-wait {
    padding: 14px 16px;
    border: 1px solid rgba(201, 162, 39, 0.45);
    background: rgba(201, 162, 39, 0.1);
    border-radius: 8px;
}
.scan-dlc-toolbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}
.scan-dlc-table-wrap {
    overflow: auto;
    max-height: min(58vh, 560px);
    border: 1px solid #333;
    border-radius: 8px;
}
.scan-dlc-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}
.scan-dlc-table th,
.scan-dlc-table td {
    padding: 8px 10px;
    border-bottom: 1px solid #2a2a2a;
    text-align: left;
    vertical-align: middle;
}
.scan-dlc-table th {
    position: sticky;
    top: 0;
    background: #1a1a1a;
    z-index: 1;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: rgba(255, 255, 255, 0.7);
}
.scan-dlc-row-diff {
    background: rgba(201, 162, 39, 0.08);
}
.scan-dlc-table select {
    max-width: 180px;
}
#submit-dlc-status {
    display: inline-block;
    margin-top: 6px;
}

