@font-face {
            font-family: 'Aero';
            src: url('AERO_03.otf') format('opentype');
        }

        :root {
            --aero-blue: linear-gradient(to bottom, #7abcff 0%, #4096ee 50%, #11599e 51%, #3982c6 100%);
            --aero-white: linear-gradient(to bottom, #ffffff 0%, #f1f1f1 50%, #e1e1e1 51%, #f6f6f6 100%);
        }

        * {
            font-family: 'Aero', 'Segoe UI', Tahoma, sans-serif;
        }

        body, html {
            margin: 0; padding: 0; width: 100%; height: 100%;
            overflow: hidden;
        }

        #bg {
            position: fixed; top: 0; left: 0; width: 100%; height: 100%;
            background-size: cover; background-position: center;
            transition: background-image 1.5s ease-in-out;
            z-index: -2;
        }

        #search-container {
            position: fixed; top: 10px; left: 50%; transform: translateX(-50%);
            width: 400px; z-index: 50;
        }
        
        #search-input {
            width: 100%; padding: 8px 15px;
            background: rgba(255, 255, 255, 0.7);
            backdrop-filter: blur(10px);
            border: 1px solid rgba(255, 255, 255, 0.8);
            border-radius: 0;
            font-size: 14px;
            outline: none;
            box-shadow: 0 2px 10px rgba(0,0,0,0.2);
        }
        
        #search-input:focus {
            background: rgba(255, 255, 255, 0.9);
        }
        
        #search-results {
            position: absolute; top: 100%; left: 0; right: 0;
            background: rgba(255, 255, 255, 0.9);
            backdrop-filter: blur(10px);
            border-radius: 0;
            margin-top: 5px;
            max-height: 300px;
            overflow-y: auto;
            display: none;
            box-shadow: 0 4px 15px rgba(0,0,0,0.3);
        }
        
        .search-result-item {
            padding: 10px 15px;
            border-bottom: 1px solid #ccc;
            cursor: pointer;
        }
        
        .search-result-item:hover {
            background: rgba(0, 120, 215, 0.2);
        }
        
        .search-result-time {
            font-size: 11px; color: #666;
        }

        #sidebar {
            position: fixed; left: 0; top: 50px; width: 220px; height: calc(100% - 150px);
            background: rgba(255, 255, 255, 0.2);
            backdrop-filter: blur(10px);
            border-right: 1px solid rgba(255, 255, 255, 0.3);
            padding: 10px; overflow-y: auto;
        }

        #chat-window {
            margin-left: 240px; padding: 20px;
            height: calc(100% - 140px); overflow-y: auto;
            display: flex; flex-direction: column; gap: 20px;
        }

        .msg-wrapper { display: flex; flex-direction: column; max-width: 60%; position: relative; }
        .msg-wrapper.left { align-self: flex-start; }
        .msg-wrapper.right { align-self: flex-end; align-items: flex-end; }

        .username-label { 
            font-size: 12px; color: white; text-shadow: 1px 1px 2px black; 
            margin-bottom: 4px; font-weight: bold;
            display: flex; align-items: center; gap: 8px;
            flex-wrap: wrap;
        }
        
        .timestamp-label {
            font-size: 10px; color: rgba(255,255,255,0.8); 
            text-shadow: 1px 1px 2px black;
            font-weight: normal;
        }

        .bubble-row { display: flex; align-items: flex-start; }
        .right .bubble-row { flex-direction: row-reverse; }

        .pfp-area { position: relative; width: 50px; height: 50px; flex-shrink: 0; }
        .pfp-img { width: 40px; height: 40px; margin: 5px; border-radius: 4px; object-fit: cover; }
        .pfp-frame { position: absolute; top: 0; left: 0; width: 50px; height: 50px; pointer-events: none; }

        .bubble {
            margin: 0 10px; padding: 10px 15px; border-radius: 15px;
            border: 1px solid rgba(0,0,0,0.2); box-shadow: 0 4px 10px rgba(0,0,0,0.2);
            position: relative; font-size: 14px;
            word-break: break-word;
        }
        .left .bubble { background: var(--aero-white); color: #333; }
        .right .bubble { background: var(--aero-blue); color: white; text-shadow: 0 1px 1px rgba(0,0,0,0.5); }

        .bubble a {
            color: #0066cc;
            text-decoration: underline;
            cursor: pointer;
        }
        .right .bubble a {
            color: #ffff99;
        }
        
        .youtube-embed {
            margin-top: 8px;
            max-width: 100%;
        }
        
        .youtube-embed iframe {
            max-width: 100%;
            border-radius: 8px;
            border: 1px solid rgba(0,0,0,0.2);
        }

        .file-attachment {
            margin-top: 8px;
            max-width: 100%;
        }
        
        .file-attachment img, .file-attachment video {
            max-width: 100%;
            max-height: 300px;
            border-radius: 8px;
            border: 1px solid rgba(0,0,0,0.2);
        }
        
        .file-attachment audio {
            max-width: 100%;
        }

        @keyframes rainbow {
            0% { background: linear-gradient(to bottom, #ff0000 0%, #cc0000 100%); }
            17% { background: linear-gradient(to bottom, #ffff00 0%, #cccc00 100%); }
            33% { background: linear-gradient(to bottom, #00ff00 0%, #00cc00 100%); }
            50% { background: linear-gradient(to bottom, #00ffff 0%, #00cccc 100%); }
            67% { background: linear-gradient(to bottom, #0000ff 0%, #0000cc 100%); }
            83% { background: linear-gradient(to bottom, #ff00ff 0%, #cc00cc 100%); }
            100% { background: linear-gradient(to bottom, #ff0000 0%, #cc0000 100%); }
        }
        
        .bubble.rainbow-bubble {
            animation: rainbow 3s linear infinite;
            color: white;
            text-shadow: 0 1px 2px rgba(0,0,0,0.5);
        }

        .top-buttons {
            position: fixed; top: 10px; left: 10px;
            display: flex; gap: 10px;
        }

        #settings-btn, #rules-btn {
            padding: 5px 15px; background: rgba(255,255,255,0.4);
            border: 1px solid white; border-radius: 5px; cursor: pointer;
            color: #333; font-weight: bold;
        }

        #settings-window {
            position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%);
            width: 400px; background: rgba(200, 220, 240, 0.9);
            border: 1px solid #777; border-radius: 8px; box-shadow: 0 10px 50px rgba(0,0,0,0.5);
            display: none; z-index: 100; padding: 5px;
        }
        .win7-title { display: flex; justify-content: space-between; padding: 5px; font-size: 13px; font-weight: bold; }
        .close-btn { background: red; color: white; border: 1px solid darkred; padding: 0 8px; cursor: pointer; }
        .win7-content { background: white; padding: 15px; border-radius: 3px; display: grid; grid-template-columns: 100px 1fr; gap: 10px; }

        .pfp-grid { grid-column: span 2; display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; margin-top: 10px; }
        .pfp-choice { width: 40px; height: 40px; cursor: pointer; border: 2px solid transparent; }
        .pfp-choice:hover { border-color: #0078d7; }

        .dock {
            position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%);
            width: 80%; height: 60px; background: rgba(255, 255, 255, 0.4);
            backdrop-filter: blur(15px); border: 1px solid rgba(255, 255, 255, 0.6);
            border-radius: 15px; display: flex; align-items: center; padding: 0 20px; gap: 10px;
        }
        
        #file-input {
            display: none;
        }
        
        .plus-btn {
            width: 40px; height: 40px;
            background: rgba(255, 255, 255, 0.7);
            border: 1px solid #999;
            border-radius: 0;
            font-size: 24px;
            font-weight: bold;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            color: #333;
        }
        
        .plus-btn:hover {
            background: rgba(255, 255, 255, 0.9);
        }
        
        #messageInput { flex: 1; padding: 8px; border-radius: 5px; border: 1px solid #ccc; }
        #sendBtn { padding: 8px 20px; border-radius: 5px; border: 1px solid #333; cursor: pointer; background: #eee; }

        .user-item {
            display: flex; align-items: center; gap: 8px;
            color: white; padding: 5px; margin: 2px 0;
            text-shadow: 1px 1px 2px black; border-radius: 3px;
        }
        
        .user-pfp-area {
            position: relative; width: 30px; height: 30px; flex-shrink: 0;
        }
        
        .user-pfp-img {
            width: 24px; height: 24px; margin: 3px; border-radius: 3px; object-fit: cover;
        }
        
        .user-pfp-frame {
            position: absolute; top: 0; left: 0; width: 30px; height: 30px; pointer-events: none;
        }
        
        .user-name {
            flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
            display: flex; align-items: center; gap: 5px;
        }
        
        .badge-img {
            height: 16px; width: auto; vertical-align: middle;
        }
        
        .emoji, .emoticon-img {
            height: 1.5em; width: auto; margin: 0 2px;
            vertical-align: middle; display: inline-block;
        }

        .grecaptcha-badge { 
            display: none !important;
        }
