:root {
    --bg-deep: #010103;
    --lumina-glow: #00f2ff;
    --lumina-accent: #7000ff;
    --glass: rgba(8, 8, 12, 0.5);
    --border: rgba(255, 255, 255, 0.08);
    --font-main: 'Outfit', sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
}

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

input, button, a, .core-btn, label, .sidebar-room, .sidebar-action-btn, .room-button, .modal-button, .copy-button, .emoji-button, .gif-button, .image-upload-button, .send-button {
    cursor: pointer;
}

body {
    background-color: var(--bg-deep) !important;
    background: var(--bg-deep) !important;
    color: #fff;
    font-family: var(--font-main);
    overflow-x: hidden;
    min-height: 100vh;
    letter-spacing: -0.02em;
    padding: 20px;
    position: relative;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

/* Override animated background on chat page */
body:has(#animatedBackground) {
    background: var(--bg-deep) !important;
    background-color: var(--bg-deep) !important;
}

body.page-loaded {
    opacity: 1;
}

body.page-exit {
    opacity: 0;
}

/* --- THE QUANTUM CANVAS --- */
.prism-bg {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    background: radial-gradient(circle at 50% 50%, #050510 0%, #010103 100%);
    pointer-events: none;
}

/* Hide animated background canvas on chat page */
#animatedBackground {
    display: none !important;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.35;
    mix-blend-mode: screen;
    animation: drift 25s infinite alternate ease-in-out;
    will-change: transform;
}

@keyframes drift {
    0% { transform: translate(-10%, -10%) scale(1); }
    100% { transform: translate(20%, 10%) scale(1.3); }
}

/* --- PHANTOM GLASS --- */
.lumina-card {
    background: var(--glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--border);
    border-radius: 40px;
    position: relative;
    transition: border-color 0.2s ease, background 0.2s ease;
    box-shadow: 0 20px 40px -15px rgba(0,0,0,0.5);
    will-change: border-color, background;
}

.lumina-card:hover {
    border-color: rgba(0, 242, 255, 0.3);
    background: rgba(12, 12, 20, 0.6);
    box-shadow: 0 25px 50px -15px rgba(0,0,0,0.6);
}

.card-glow {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: radial-gradient(400px circle at var(--mouse-x) var(--mouse-y), rgba(112,0,255,0.1), transparent 70%);
    pointer-events: none;
}

/* --- PHANTOM TRAILER --- */
.prism-cursor-ring {
    width: 40px;
    height: 40px;
    border: 1.5px solid var(--lumina-glow);
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    z-index: 9999;
    transition: transform 0.1s ease-out, opacity 0.2s ease;
    opacity: 0.6;
    mix-blend-mode: screen;
    will-change: transform;
}

/* Page Transition Effects */
.chat-container {
    animation: fadeInUp 0.5s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Cursor Trail */
.cursor-trail {
    position: fixed;
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: rgba(0, 242, 255, 0.4);
    pointer-events: none;
    z-index: 9999;
    transition: opacity 0.4s ease-out, transform 0.4s ease-out;
    transform: translate(-50%, -50%) scale(1);
    will-change: opacity, transform;
}

.back-button {
    position: absolute;
    top: 20px;
    left: 20px;
    padding: 10px 20px;
    background: var(--glass);
    color: #fff;
    text-decoration: none;
    border-radius: 20px;
    border: 1px solid var(--border);
    backdrop-filter: blur(20px) saturate(180%);
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease, color 0.15s ease;
    font-size: 14px;
    font-weight: 400;
    z-index: 10;
    box-shadow: 0 10px 20px -5px rgba(0,0,0,0.4);
    font-family: var(--font-main);
    will-change: transform;
}

.back-button:hover {
    background: rgba(12, 12, 20, 0.6);
    border-color: rgba(0, 242, 255, 0.3);
    color: var(--lumina-glow);
    transform: translateX(-3px);
    box-shadow: 0 15px 30px -5px rgba(0,0,0,0.5);
}

.chat-container {
    max-width: 1400px;
    margin: 0 auto;
    height: calc(100vh - 40px);
    display: flex;
    flex-direction: row;
    gap: 20px;
    padding-top: 60px;
}

/* Sidebar Styles */
.chat-sidebar {
    width: 280px;
    min-width: 280px;
    background: var(--glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--border);
    border-radius: 40px;
    display: flex;
    flex-direction: column;
    height: calc(100vh - 100px);
    box-shadow: 0 20px 40px -15px rgba(0,0,0,0.5);
    transition: border-color 0.2s ease, background 0.2s ease, width 0.2s ease;
    position: relative;
}

.chat-sidebar.lumina-card:hover,
.chat-sidebar:hover {
    border-color: rgba(0, 242, 255, 0.3);
    background: rgba(12, 12, 20, 0.6);
    box-shadow: 0 25px 50px -15px rgba(0,0,0,0.6);
}

.chat-sidebar.collapsed {
    width: 60px;
    min-width: 60px;
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sidebar-header h2 {
    font-size: 20px;
    color: #fff;
    margin: 0;
    font-weight: 600;
    font-family: var(--font-main);
}

.chat-sidebar.collapsed .sidebar-header h2 {
    display: none;
}

.sidebar-toggle {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    color: #fff;
    border-radius: 20px;
    padding: 8px 12px;
    cursor: pointer;
    font-size: 18px;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    font-family: var(--font-main);
}

.sidebar-toggle:hover {
    background: rgba(0, 242, 255, 0.1);
    border-color: rgba(0, 242, 255, 0.3);
    color: var(--lumina-glow);
}

.sidebar-content {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.sidebar-content::-webkit-scrollbar {
    width: 0;
}

.sidebar-room {
    width: 100%;
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    border-radius: 20px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
    display: flex;
    align-items: center;
    gap: 12px;
    color: #fff;
    text-decoration: none;
    position: relative;
    font-family: var(--font-main);
    will-change: transform;
}

.sidebar-room:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(0, 242, 255, 0.3);
    transform: translateX(3px);
}

.sidebar-room.active {
    background: linear-gradient(135deg, rgba(0, 242, 255, 0.15) 0%, rgba(112, 0, 255, 0.15) 100%);
    border-color: rgba(0, 242, 255, 0.4);
    box-shadow: 0 10px 20px -5px rgba(0, 242, 255, 0.15);
    color: #fff;
}

.sidebar-ai-button {
    width: 100%;
    padding: 12px 15px;
    background: linear-gradient(135deg, rgba(112, 0, 255, 0.15) 0%, rgba(0, 242, 255, 0.15) 100%);
    border: 1px solid rgba(112, 0, 255, 0.4);
    border-radius: 20px;
    margin-bottom: 8px;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
    display: flex;
    align-items: center;
    gap: 12px;
    color: #fff;
    text-decoration: none;
    position: relative;
    font-family: var(--font-main);
    box-shadow: 0 5px 15px -5px rgba(112, 0, 255, 0.15);
    will-change: transform;
}

.sidebar-ai-button:hover {
    background: linear-gradient(135deg, rgba(112, 0, 255, 0.25) 0%, rgba(0, 242, 255, 0.25) 100%);
    border-color: rgba(112, 0, 255, 0.6);
    transform: translateX(3px);
    box-shadow: 0 10px 20px -5px rgba(112, 0, 255, 0.2);
    color: #fff;
}

.sidebar-ai-button .ai-icon {
    font-size: 18px;
    flex-shrink: 0;
}

.sidebar-ai-button .ai-text {
    font-size: 14px;
    font-weight: 500;
    flex: 1;
}

.chat-sidebar.collapsed .sidebar-ai-button .ai-text {
    display: none;
}

.room-icon {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
    display: inline-block;
    position: relative;
}

.room-icon::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border: 1.5px solid var(--lumina-glow);
    border-radius: 2px;
    transform: rotate(45deg);
    opacity: 0.7;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(45deg);
}

.room-icon[data-room-type="dev"]::before {
    border-color: #ffd700;
    box-shadow: 0 0 6px rgba(255, 215, 0, 0.5);
    opacity: 0.8;
}

.action-icon {
    width: 12px;
    height: 12px;
    flex-shrink: 0;
    display: inline-block;
    position: relative;
}

.sidebar-action-btn:first-of-type .action-icon::before {
    content: '';
    position: absolute;
    width: 8px;
    height: 1.5px;
    background: currentColor;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0.8;
}

.sidebar-action-btn:first-of-type .action-icon::after {
    content: '';
    position: absolute;
    width: 1.5px;
    height: 8px;
    background: currentColor;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0.8;
}

.sidebar-action-btn:last-of-type .action-icon::before {
    content: '';
    position: absolute;
    width: 6px;
    height: 6px;
    border: 1.5px solid currentColor;
    border-radius: 50%;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 0.8;
}

.sidebar-action-btn:last-of-type .action-icon::after {
    content: '';
    position: absolute;
    width: 1px;
    height: 5px;
    background: currentColor;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(45deg);
    opacity: 0.8;
}

.announcement-panel-icon {
    width: 18px;
    height: 18px;
    display: inline-block;
    position: relative;
}

.announcement-panel-icon::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    border: 1.5px solid var(--lumina-glow);
    border-radius: 3px;
    background: rgba(0, 242, 255, 0.1);
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.announcement-panel-icon::after {
    content: '!';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--lumina-glow);
    font-weight: bold;
    font-size: 11px;
    font-family: var(--font-mono);
    line-height: 1;
}

.room-name-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.room-name {
    font-size: 14px;
    font-weight: 400;
    word-wrap: break-word;
    font-family: var(--font-main);
}

.chat-sidebar.collapsed .room-name-container {
    display: none;
}

.room-code-display {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 2px;
    opacity: 0.7;
    font-family: var(--font-mono);
}

.room-delete-btn {
    opacity: 0;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
    border-radius: 12px;
    padding: 4px 8px;
    cursor: pointer;
    font-size: 12px;
    transition: all 0.2s;
    flex-shrink: 0;
    font-family: var(--font-main);
}

.sidebar-room:hover .room-delete-btn {
    opacity: 1;
}

.room-delete-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
}

.chat-sidebar.collapsed .room-delete-btn {
    display: none;
}

.sidebar-divider {
    height: 1px;
    background: var(--border);
    margin: 15px 0;
}

.sidebar-section {
    margin-top: 10px;
}

.sidebar-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5px 10px 5px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-family: var(--font-mono);
    font-weight: 700;
}

.chat-sidebar.collapsed .sidebar-section-header {
    display: none;
}

.sidebar-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 15px;
    padding: 0 5px;
}

.chat-sidebar.collapsed .sidebar-actions {
    display: none;
}

.sidebar-action-btn {
    width: 100%;
    padding: 10px 15px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    color: #fff;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 400;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease, color 0.15s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    text-align: left;
    pointer-events: auto;
    position: relative;
    z-index: 1;
    font-family: var(--font-main);
    will-change: transform;
}

.sidebar-action-btn:hover {
    background: rgba(0, 242, 255, 0.1);
    border-color: rgba(0, 242, 255, 0.3);
    transform: translateX(3px);
    color: var(--lumina-glow);
}

.action-icon {
    font-size: 16px;
    flex-shrink: 0;
}

.action-text {
    flex: 1;
}

.rooms-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* Main Chat Area */
.chat-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.chat-header {
    text-align: center;
    margin-bottom: 30px;
    position: relative;
}

.chat-header h1 {
    font-size: 64px;
    color: #fff;
    margin-bottom: 10px;
    font-weight: 900;
    letter-spacing: -0.05em;
    font-family: var(--font-main);
}

.chat-subtitle {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.5);
    font-weight: 300;
    font-family: var(--font-main);
}

.room-controls {
    display: flex;
    gap: 10px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 20px;
    margin-bottom: 10px;
}

.room-button {
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 20px;
    color: #fff;
    cursor: pointer;
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 400;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease, color 0.15s ease;
    will-change: transform;
}

.room-button:hover {
    background: rgba(0, 242, 255, 0.1);
    border-color: rgba(0, 242, 255, 0.3);
    transform: translateY(-2px);
    color: var(--lumina-glow);
    box-shadow: 0 10px 20px -5px rgba(0, 242, 255, 0.15);
}

.room-button-leave {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

.room-button-leave:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
    color: #f87171;
    box-shadow: 0 10px 20px -5px rgba(239, 68, 68, 0.15);
}

.room-code-display {
    display: flex;
    align-items: center;
    padding: 8px 16px;
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: 20px;
    color: #22c55e;
    font-family: var(--font-mono);
    font-size: 14px;
    font-weight: 400;
}

.room-code-display strong {
    color: #22c55e;
    letter-spacing: 2px;
    font-weight: 700;
}

/* Chat Messages */
.chat-messages {
    flex: 1;
    background: var(--glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--border);
    border-radius: 40px;
    padding: 30px;
    box-shadow: 0 20px 40px -15px rgba(0,0,0,0.5);
    overflow-y: auto;
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    position: relative;
    transition: border-color 0.2s ease, background 0.2s ease;
    contain: layout style paint;
    transform: translateZ(0);
}

.chat-messages.lumina-card:hover,
.chat-messages:hover {
    border-color: rgba(0, 242, 255, 0.3);
    background: rgba(12, 12, 20, 0.6);
    box-shadow: 0 25px 50px -15px rgba(0,0,0,0.6);
}

.chat-messages::-webkit-scrollbar {
    width: 0;
}

.message {
    animation: msg-reveal 0.3s ease-out forwards;
    margin-bottom: 1rem;
    contain: layout style;
}

@keyframes msg-reveal {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.message-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.message-user {
    font-weight: 600;
    color: var(--lumina-glow);
    font-size: 14px;
    font-family: var(--font-main);
}

.message-time {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.4);
    font-family: var(--font-mono);
    font-weight: 400;
}

.message-content {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    padding: 1.75rem 2.25rem;
    border-radius: 30px;
    border-bottom-left-radius: 6px;
    word-wrap: break-word;
    font-size: 1.15rem;
    line-height: 1.7;
    font-family: var(--font-main);
    font-weight: 300;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.message-content:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(0, 242, 255, 0.2);
}

.message-content p {
    margin: 0;
    line-height: 1.7;
}

.message-content a {
    color: var(--lumina-glow);
    text-decoration: none;
    word-break: break-all;
    font-weight: 400;
    border-bottom: 1px solid rgba(0, 242, 255, 0.3);
    transition: all 0.2s;
}

.message-content a:hover {
    color: #fff;
    border-bottom-color: var(--lumina-glow);
}

.welcome-message .message-content {
    background: rgba(0, 242, 255, 0.05);
    border-color: rgba(0, 242, 255, 0.2);
    text-align: center;
    font-style: italic;
}

.chat-input-container {
    background: var(--glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--border);
    border-radius: 40px;
    padding: 20px;
    box-shadow: 0 20px 40px -15px rgba(0,0,0,0.5);
    transition: border-color 0.2s ease, background 0.2s ease;
}

.chat-input-container.lumina-card:hover,
.chat-input-container:hover {
    border-color: rgba(0, 242, 255, 0.3);
    background: rgba(12, 12, 20, 0.6);
    box-shadow: 0 25px 50px -15px rgba(0,0,0,0.6);
}

.user-name-container {
    margin-bottom: 15px;
}

.current-name-display {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 12px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 20px;
    border: 1px solid var(--border);
}

.current-name-display span {
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    font-family: var(--font-main);
}

.current-name-display strong {
    color: var(--lumina-glow);
    font-weight: 600;
}

.change-name-button {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 6px 12px;
    color: rgba(255, 255, 255, 0.8);
    font-family: var(--font-main);
    font-size: 12px;
    font-weight: 400;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    text-decoration: none;
}

.change-name-button:hover {
    background: rgba(0, 242, 255, 0.1);
    border-color: rgba(0, 242, 255, 0.3);
    color: var(--lumina-glow);
}

.input-wrapper {
    display: flex;
    gap: 10px;
    align-items: center;
}

.emoji-button,
.gif-button,
.image-upload-button {
    padding: 12px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 20px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0.5px;
    transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease, color 0.15s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 45px;
    height: 45px;
    color: #fff;
    font-family: var(--font-main);
    will-change: transform;
}

.emoji-button {
    font-size: 12px;
    font-weight: 400;
    letter-spacing: 0.5px;
}

.gif-button {
    font-weight: 400;
    font-size: 12px;
}

.emoji-button:hover,
.gif-button:hover,
.image-upload-button:hover {
    background: rgba(0, 242, 255, 0.1);
    border-color: rgba(0, 242, 255, 0.3);
    transform: translateY(-2px);
    color: var(--lumina-glow);
    box-shadow: 0 10px 20px -5px rgba(0, 242, 255, 0.15);
}

.emoji-button:disabled,
.gif-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

.image-preview,
.gif-preview {
    margin-top: 10px;
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 10px;
    backdrop-filter: blur(20px);
}

.image-preview img {
    max-width: 200px;
    max-height: 150px;
    border-radius: 12px;
    object-fit: contain;
}

.remove-image-button {
    position: absolute;
    top: 5px;
    right: 5px;
    background: rgba(239, 68, 68, 0.8);
    border: none;
    border-radius: 50%;
    width: 25px;
    height: 25px;
    color: white;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.remove-image-button:hover {
    background: rgba(239, 68, 68, 1);
    transform: scale(1.1);
}

.message-image,
.message-gif {
    margin-bottom: 10px;
    border-radius: 20px;
    overflow: hidden;
    max-width: 100%;
}

.message-image img,
.message-gif img {
    max-width: 100%;
    max-height: 300px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    object-fit: contain;
    display: block;
}

.chat-gif {
    cursor: pointer;
}

.chat-image {
    cursor: pointer;
}

.expanded-image-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
    animation: fadeIn 0.3s ease-out;
}

.expanded-image-container {
    position: relative;
    max-width: 90vw;
    max-height: 90vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.expanded-image {
    max-width: 100%;
    max-height: 90vh;
    border-radius: 20px;
    box-shadow: 0 50px 100px -30px rgba(0,0,0,0.9);
    object-fit: contain;
}

.close-expanded-image {
    position: absolute;
    top: -40px;
    right: 0;
    background: rgba(239, 68, 68, 0.8);
    border: none;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    color: white;
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 10001;
}

.close-expanded-image:hover {
    background: rgba(239, 68, 68, 1);
    transform: scale(1.1);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.message-input {
    flex: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 32px;
    padding: 12px 20px;
    color: #fff;
    font-family: var(--font-main);
    font-size: 16px;
    font-weight: 300;
    transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
}

.message-input::placeholder {
    color: rgba(255, 255, 255, 0.3);
}

.message-input:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(0, 242, 255, 0.4);
    box-shadow: 0 0 0 3px rgba(0, 242, 255, 0.1);
}

.message-input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.send-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
}

.send-button {
    width: 84px;
    height: 84px;
    border-radius: 28px;
    background: var(--lumina-glow);
    border: none;
    color: #000;
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
    box-shadow: 0 0 20px rgba(0, 242, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    will-change: transform;
}

.send-button:hover {
    transform: scale(1.05) translateY(-5px);
    background: #fff;
    box-shadow: 0 10px 25px rgba(0, 242, 255, 0.3);
}

.send-button svg {
    color: #000;
    width: 32px;
    height: 32px;
}

/* Rainbow text mode */
.rainbow-text {
    background: linear-gradient(
        90deg,
        #ff0000 0%,
        #ff7f00 14.28%,
        #ffff00 28.56%,
        #00ff00 42.84%,
        #0000ff 57.12%,
        #4b0082 71.4%,
        #9400d3 85.68%,
        #ff0000 100%
    );
    background-size: 200% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: rainbow-shift 3s linear infinite;
    display: inline-block;
}

@keyframes rainbow-shift {
    0% {
        background-position: 0% 50%;
    }
    100% {
        background-position: 200% 50%;
    }
}

.rainbow-mode .message-content p {
    background: linear-gradient(
        90deg,
        #ff0000 0%,
        #ff7f00 14.28%,
        #ffff00 28.56%,
        #00ff00 42.84%,
        #0000ff 57.12%,
        #4b0082 71.4%,
        #9400d3 85.68%,
        #ff0000 100%
    );
    background-size: 200% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: rainbow-shift 3s linear infinite;
}

/* Glitch text mode */
.glitch-text {
    position: relative;
}

.glitch-text:hover {
    animation: glitch 0.3s cubic-bezier(.25,.46,.45,.94) both infinite;
    color: var(--lumina-glow);
}

@keyframes glitch {
    0% { transform: translate(0); }
    20% { transform: translate(-2px, 2px); }
    40% { transform: translate(-2px, -2px); }
    60% { transform: translate(2px, 2px); }
    80% { transform: translate(2px, -2px); }
    100% { transform: translate(0); }
}

.glitch-mode .message-content p {
    position: relative;
    animation: glitch 0.3s infinite;
}

/* Modal Styles */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.modal-content {
    background: var(--glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid var(--border);
    border-radius: 40px;
    padding: 30px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 20px 40px -15px rgba(0,0,0,0.5);
    position: relative;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.modal-content:hover {
    border-color: rgba(0, 242, 255, 0.3);
    background: rgba(12, 12, 20, 0.6);
    box-shadow: 0 25px 50px -15px rgba(0,0,0,0.6);
}

.modal-content h2 {
    color: #fff;
    margin-bottom: 20px;
    text-align: center;
    font-weight: 600;
    font-size: 24px;
    font-family: var(--font-main);
}

.modal-content input {
    width: 100%;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 20px;
    color: #fff;
    font-family: var(--font-mono);
    font-size: 18px;
    text-align: center;
    letter-spacing: 4px;
    margin-bottom: 20px;
    transition: all 0.4s var(--ease-out-expo);
}

.modal-content input::placeholder {
    color: rgba(255, 255, 255, 0.3);
    letter-spacing: 0;
}

.modal-content input:focus {
    outline: none;
    border-color: rgba(0, 242, 255, 0.4);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(0, 242, 255, 0.1);
}

.modal-buttons {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.modal-button {
    padding: 10px 20px;
    background: var(--lumina-glow);
    border: none;
    border-radius: 20px;
    color: #000;
    cursor: pointer;
    font-family: var(--font-main);
    font-size: 14px;
    font-weight: 600;
    transition: all 0.4s var(--ease-out-expo);
    width: 100%;
    box-shadow: 0 0 30px rgba(0, 242, 255, 0.3);
}

.modal-button:hover {
    transform: scale(1.05) translateY(-2px);
    background: #fff;
    box-shadow: 0 20px 40px rgba(0, 242, 255, 0.4);
}

.modal-button-cancel {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
    box-shadow: none;
}

.modal-button-cancel:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
    color: #f87171;
    transform: scale(1.05) translateY(-2px);
}

.room-code-display-large {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    padding: 20px;
    background: rgba(34, 197, 94, 0.1);
    border: 2px solid rgba(34, 197, 94, 0.3);
    border-radius: 20px;
    margin-bottom: 20px;
}

.room-code-display-large span {
    font-size: 32px;
    font-weight: 700;
    color: #22c55e;
    letter-spacing: 4px;
    font-family: var(--font-mono);
}

.copy-button {
    padding: 10px 15px;
    background: var(--lumina-glow);
    border: none;
    border-radius: 20px;
    color: #000;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: all 0.4s var(--ease-out-expo);
    flex-shrink: 0;
    box-shadow: 0 0 30px rgba(0, 242, 255, 0.3);
    font-family: var(--font-main);
}

.copy-button:hover {
    transform: scale(1.05);
    background: #fff;
    box-shadow: 0 20px 40px rgba(0, 242, 255, 0.4);
}

.copy-button:active {
    transform: scale(0.98);
}

/* Emoji Picker Styles */
.emoji-picker-content {
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
}

.emoji-picker-content::-webkit-scrollbar {
    width: 0;
}

.emoji-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 10px;
    padding: 15px;
    max-height: 400px;
    overflow-y: auto;
}

.emoji-grid::-webkit-scrollbar {
    width: 0;
}

.emoji-item {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 10px;
    font-size: 24px;
    cursor: pointer;
    transition: all 0.4s var(--ease-out-expo);
    display: flex;
    align-items: center;
    justify-content: center;
    aspect-ratio: 1;
}

.emoji-item:hover {
    background: rgba(0, 242, 255, 0.1);
    border-color: rgba(0, 242, 255, 0.3);
    transform: scale(1.1);
}

/* GIF Picker Styles */
.gif-picker-content {
    max-width: 700px;
    max-height: 80vh;
    overflow-y: auto;
}

.gif-picker-content::-webkit-scrollbar {
    width: 0;
}

.gif-search-wrapper {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.gif-search-input {
    flex: 1;
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 20px;
    color: #fff;
    font-family: var(--font-main);
    transition: all 0.4s var(--ease-out-expo);
}

.gif-search-input:focus {
    outline: none;
    border-color: rgba(0, 242, 255, 0.4);
    background: rgba(255, 255, 255, 0.08);
}

.gif-search-button {
    padding: 10px 20px;
    background: var(--lumina-glow);
    border: none;
    border-radius: 20px;
    color: #000;
    cursor: pointer;
    font-family: var(--font-main);
    font-weight: 600;
    transition: all 0.4s var(--ease-out-expo);
    box-shadow: 0 0 30px rgba(0, 242, 255, 0.3);
}

.gif-search-button:hover {
    transform: scale(1.05) translateY(-2px);
    background: #fff;
    box-shadow: 0 20px 40px rgba(0, 242, 255, 0.4);
}

.gif-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    max-height: 500px;
    overflow-y: auto;
}

.gif-grid::-webkit-scrollbar {
    width: 0;
}

.gif-item {
    position: relative;
    cursor: pointer;
    border-radius: 20px;
    overflow: hidden;
    aspect-ratio: 1;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    transition: all 0.4s var(--ease-out-expo);
}

.gif-item:hover {
    transform: scale(1.05);
    border-color: rgba(0, 242, 255, 0.3);
    box-shadow: 0 20px 40px -10px rgba(0, 242, 255, 0.2);
}

.gif-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gif-loading,
.gif-error {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px;
    color: rgba(255, 255, 255, 0.5);
    font-family: var(--font-main);
}

.gif-error a {
    color: var(--lumina-glow);
    text-decoration: none;
    border-bottom: 1px solid rgba(0, 242, 255, 0.3);
}

/* Announcement Styles */
.announcement-bubble {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 1px;
    margin-left: 12px;
    cursor: pointer;
    transition: all 0.4s var(--ease-out-expo);
    vertical-align: middle;
    position: relative;
    animation: none;
    padding: 6px 12px;
    border-radius: 4px;
    background: rgba(255, 193, 7, 0.1);
    border: 2px solid rgba(255, 215, 0, 0.3);
    font-family: var(--font-mono);
    text-transform: uppercase;
}

.announcement-bubble.unread {
    animation: flashBubbleDramatic 1s ease-in-out infinite;
    background: rgba(255, 193, 7, 0.3);
    border: 3px solid rgba(255, 215, 0, 0.8);
    box-shadow: 
        0 0 20px rgba(255, 215, 0, 0.8),
        0 0 40px rgba(255, 193, 7, 0.6),
        inset 0 0 20px rgba(255, 215, 0, 0.3);
}

@keyframes flashBubbleDramatic {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
        box-shadow: 
            0 0 20px rgba(255, 215, 0, 0.8),
            0 0 40px rgba(255, 193, 7, 0.6),
            inset 0 0 20px rgba(255, 215, 0, 0.3);
    }
    25% {
        opacity: 0.7;
        transform: scale(1.15);
        box-shadow: 
            0 0 30px rgba(255, 215, 0, 1),
            0 0 60px rgba(255, 193, 7, 0.9),
            inset 0 0 30px rgba(255, 215, 0, 0.5);
    }
    50% {
        opacity: 1;
        transform: scale(1.25);
        box-shadow: 
            0 0 40px rgba(255, 215, 0, 1.2),
            0 0 80px rgba(255, 193, 7, 1),
            inset 0 0 40px rgba(255, 215, 0, 0.7);
    }
    75% {
        opacity: 0.7;
        transform: scale(1.15);
        box-shadow: 
            0 0 30px rgba(255, 215, 0, 1),
            0 0 60px rgba(255, 193, 7, 0.9),
            inset 0 0 30px rgba(255, 215, 0, 0.5);
    }
}

.announcement-bubble::before {
    content: '';
    position: absolute;
    top: -4px;
    right: -4px;
    width: 12px;
    height: 12px;
    background: #ff4444;
    border-radius: 50%;
    border: 2px solid #fff;
    display: none;
    animation: pulseDot 1s ease-in-out infinite;
}

.announcement-bubble.unread::before {
    display: block;
}

@keyframes pulseDot {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.3);
        opacity: 0.8;
    }
}

.announcement-bubble:hover {
    transform: scale(1.3);
}

.announcement-panel {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-top: 15px;
    background: var(--glass);
    backdrop-filter: blur(50px) saturate(220%);
    -webkit-backdrop-filter: blur(50px) saturate(220%);
    border: 1px solid var(--border);
    border-radius: 40px;
    padding: 0;
    box-shadow: 0 50px 100px -30px rgba(0,0,0,0.7);
    z-index: 1000;
    min-width: 400px;
    max-width: 600px;
    animation: slideDownPanel 0.3s ease-out;
    transition: all 0.6s var(--ease-out-expo);
}

.announcement-panel:hover {
    border-color: rgba(0, 242, 255, 0.3);
    background: rgba(12, 12, 20, 0.6);
    box-shadow: 0 60px 120px -20px rgba(0,0,0,0.8), 0 0 30px rgba(0, 242, 255, 0.05);
}

@keyframes slideDownPanel {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.announcement-panel-content {
    padding: 20px;
}

.announcement-panel-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--border);
}

.announcement-panel-icon {
    font-size: 28px;
}

.announcement-panel-header h3 {
    flex: 1;
    margin: 0;
    color: var(--lumina-glow);
    font-size: 22px;
    font-weight: 600;
    font-family: var(--font-main);
}

.announcement-panel-close {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    color: #fff;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
    transition: all 0.4s var(--ease-out-expo);
    font-weight: bold;
}

.announcement-panel-close:hover {
    background: rgba(0, 242, 255, 0.1);
    border-color: rgba(0, 242, 255, 0.3);
    color: var(--lumina-glow);
    transform: scale(1.15) rotate(90deg);
}

.announcement-panel-text {
    color: #fff;
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 12px;
    font-family: var(--font-main);
    font-weight: 300;
}

.announcement-panel-author {
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
    text-align: right;
    font-style: italic;
    font-family: var(--font-main);
}

/* Notification System */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    background: var(--glass);
    backdrop-filter: blur(50px) saturate(220%);
    -webkit-backdrop-filter: blur(50px) saturate(220%);
    color: white;
    padding: 20px 30px;
    border-radius: 40px;
    box-shadow: 0 50px 100px -30px rgba(0,0,0,0.7);
    z-index: 10000;
    display: none;
    align-items: center;
    gap: 15px;
    min-width: 300px;
    max-width: 500px;
    border: 1px solid var(--border);
    animation: slideInNotification 0.3s ease-out;
    transition: all 0.6s var(--ease-out-expo);
}

.notification:hover {
    border-color: rgba(0, 242, 255, 0.3);
    background: rgba(12, 12, 20, 0.6);
    box-shadow: 0 60px 120px -20px rgba(0,0,0,0.8), 0 0 30px rgba(0, 242, 255, 0.05);
}

@keyframes slideInNotification {
    from {
        opacity: 0;
        transform: translateX(100%);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.notification.show {
    display: flex;
}

.notification.success {
    border-color: rgba(34, 197, 94, 0.3);
}

.notification.error {
    border-color: rgba(239, 68, 68, 0.3);
}

.notification.info {
    border-color: rgba(0, 242, 255, 0.3);
}

.notification-icon {
    font-size: 16px;
    font-weight: bold;
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    font-family: var(--font-mono);
}

.notification-content {
    flex: 1;
}

.notification-title {
    font-weight: 600;
    font-size: 18px;
    margin-bottom: 5px;
    font-family: var(--font-main);
}

.notification-message {
    font-size: 14px;
    opacity: 0.9;
    line-height: 1.4;
    white-space: pre-line;
    font-family: var(--font-main);
    font-weight: 300;
}

/* Dev Chat Styling */
body.dev-chat-active {
    background: radial-gradient(circle at 50% 50%, #0a0510 0%, #010103 100%);
}

body.dev-chat-active::before {
    background: 
        radial-gradient(circle at 20% 50%, rgba(255, 215, 0, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 100, 200, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(100, 200, 255, 0.15) 0%, transparent 50%);
}

.dev-chat .chat-header {
    background: rgba(255, 215, 0, 0.05);
    border: 1px solid rgba(255, 215, 0, 0.2);
    border-radius: 40px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 50px 100px -30px rgba(255, 215, 0, 0.2), inset 0 0 30px rgba(255, 215, 0, 0.1);
    animation: devPulse 3s ease-in-out infinite;
    backdrop-filter: blur(50px) saturate(220%);
}

@keyframes devPulse {
    0%, 100% {
        box-shadow: 0 50px 100px -30px rgba(255, 215, 0, 0.2), inset 0 0 30px rgba(255, 215, 0, 0.1);
    }
    50% {
        box-shadow: 0 60px 120px -20px rgba(255, 215, 0, 0.4), inset 0 0 40px rgba(255, 215, 0, 0.2);
    }
}

.dev-chat-header h1 {
    background: linear-gradient(135deg, #ffd700 0%, #ff69b4 50%, #00bfff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: 0 0 20px rgba(255, 215, 0, 0.5);
    font-size: 64px;
    animation: devShimmer 2s ease-in-out infinite;
}

@keyframes devShimmer {
    0%, 100% {
        filter: brightness(1);
    }
    50% {
        filter: brightness(1.3);
    }
}

.dev-chat .chat-messages {
    border: 1px solid rgba(255, 215, 0, 0.2);
    box-shadow: 0 50px 100px -30px rgba(255, 215, 0, 0.1), inset 0 0 20px rgba(255, 215, 0, 0.05);
}

.dev-chat .message {
    background: rgba(255, 215, 0, 0.05);
}

.dev-chat .message-content {
    border-color: rgba(255, 215, 0, 0.3);
}

.dev-chat .message-content:hover {
    background: rgba(255, 215, 0, 0.08);
    border-color: rgba(255, 215, 0, 0.5);
    box-shadow: 0 20px 40px -10px rgba(255, 215, 0, 0.2);
}

.dev-chat .chat-input-container {
    border: 1px solid rgba(255, 215, 0, 0.2);
    box-shadow: 0 50px 100px -30px rgba(255, 215, 0, 0.15);
    background: rgba(255, 215, 0, 0.05);
}

.dev-chat .send-button {
    background: linear-gradient(135deg, #ffd700 0%, #ff69b4 100%);
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.4);
}

.dev-chat .send-button:hover {
    background: linear-gradient(135deg, #ffed4e 0%, #ff8cc8 100%);
    box-shadow: 0 20px 40px rgba(255, 215, 0, 0.6);
    transform: scale(1.05) translateY(-5px);
}

.dev-chat .room-button {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1) 0%, rgba(255, 100, 200, 0.1) 100%);
    border-color: rgba(255, 215, 0, 0.3);
}

.dev-chat .room-button:hover {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.2) 0%, rgba(255, 100, 200, 0.2) 100%);
    box-shadow: 0 20px 40px -10px rgba(255, 215, 0, 0.3);
}

.dev-welcome {
    background: linear-gradient(135deg, rgba(255, 215, 0, 0.1) 0%, rgba(255, 100, 200, 0.1) 100%) !important;
    border-color: rgba(255, 215, 0, 0.3) !important;
    box-shadow: 0 20px 40px -10px rgba(255, 215, 0, 0.2) !important;
}

@media (max-width: 600px) {
    .chat-header h1 {
        font-size: 32px;
    }

    .chat-subtitle {
        font-size: 14px;
    }

    .chat-messages {
        padding: 20px;
    }

    .input-wrapper {
        flex-direction: column;
    }

    .send-button {
        width: 100%;
        height: 60px;
    }

    .chat-container {
        flex-direction: column;
        max-width: 100%;
    }

    .chat-sidebar {
        width: 100%;
        height: auto;
        max-height: 200px;
        order: 2;
    }

    .chat-main {
        order: 1;
    }

    .chat-sidebar.collapsed {
        width: 100%;
        min-width: 100%;
    }
}

/* Notes Panel Styles */
.notes-panel {
    position: fixed;
    top: 0;
    right: 0;
    width: 400px;
    max-width: 90vw;
    height: 100vh;
    background: var(--glass);
    backdrop-filter: blur(50px) saturate(220%);
    border-left: 1px solid var(--border);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    box-shadow: 0 50px 100px -30px rgba(0,0,0,0.7);
    overflow-y: auto;
}

.notes-panel::-webkit-scrollbar {
    width: 0;
}

.notes-header {
    padding: 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(0, 242, 255, 0.05);
}

.notes-header h2 {
    margin: 0;
    color: var(--lumina-glow);
    font-size: 24px;
    font-family: var(--font-main);
    font-weight: 600;
}

.close-notes-button {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    color: #fff;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s var(--ease-out-expo);
}

.close-notes-button:hover {
    background: rgba(0, 242, 255, 0.1);
    border-color: rgba(0, 242, 255, 0.3);
    color: var(--lumina-glow);
    transform: rotate(90deg);
}

.notes-controls {
    padding: 15px 20px;
    border-bottom: 1px solid var(--border);
}

.add-note-button {
    width: 100%;
    padding: 12px;
    background: var(--lumina-glow);
    border: none;
    border-radius: 20px;
    color: #000;
    font-weight: 600;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.4s var(--ease-out-expo);
    font-family: var(--font-main);
    box-shadow: 0 0 30px rgba(0, 242, 255, 0.3);
}

.add-note-button:hover {
    transform: scale(1.02) translateY(-2px);
    background: #fff;
    box-shadow: 0 20px 40px rgba(0, 242, 255, 0.4);
}

.notes-container {
    flex: 1;
    padding: 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-content: flex-start;
    overflow-y: auto;
}

.notes-container::-webkit-scrollbar {
    width: 0;
}

/* Sticky Note Styles */
.sticky-note {
    width: 160px;
    min-height: 160px;
    padding: 15px;
    background: #ffeb3b;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2),
                0 2px 4px rgba(0, 0, 0, 0.1),
                inset 0 -2px 2px rgba(0, 0, 0, 0.1);
    position: relative;
    transition: transform 0.2s, box-shadow 0.2s;
    cursor: default;
    display: flex;
    flex-direction: column;
}

.sticky-note:hover {
    transform: rotate(0deg) scale(1.05) !important;
    box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3),
                0 3px 6px rgba(0, 0, 0, 0.2),
                inset 0 -2px 2px rgba(0, 0, 0, 0.1);
    z-index: 10;
}

.sticky-note::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 25px;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.3), transparent);
    pointer-events: none;
}

.sticky-note-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 10px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding-bottom: 8px;
}

.sticky-note-actions {
    display: flex;
    gap: 5px;
    flex-shrink: 0;
}

.sticky-note-title {
    margin: 0;
    font-size: 16px;
    font-weight: bold;
    color: #333;
    flex: 1;
    word-wrap: break-word;
    line-height: 1.3;
}

.edit-note-button,
.delete-note-button {
    background: rgba(220, 38, 38, 0.2);
    border: 1px solid rgba(220, 38, 38, 0.5);
    color: #dc2626;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    flex-shrink: 0;
}

.edit-note-button {
    background: rgba(59, 130, 246, 0.2);
    border-color: rgba(59, 130, 246, 0.5);
    color: #3b82f6;
}

.edit-note-button:hover {
    background: rgba(59, 130, 246, 0.4);
    transform: scale(1.1);
}

.delete-note-button:hover {
    background: rgba(220, 38, 38, 0.4);
    transform: scale(1.1);
}

.sticky-note-content {
    flex: 1;
    font-size: 13px;
    color: #555;
    line-height: 1.4;
    word-wrap: break-word;
    white-space: pre-wrap;
    margin-bottom: 10px;
}

.sticky-note-footer {
    display: flex;
    flex-direction: column;
    gap: 4px;
    font-size: 10px;
    color: #777;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding-top: 8px;
    margin-top: auto;
}

.sticky-note-author {
    font-weight: bold;
}

.sticky-note-date {
    opacity: 0.7;
}

/* Note Form Styles */
.note-form-group {
    margin-bottom: 20px;
}

.note-form-group label {
    display: block;
    margin-bottom: 8px;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 600;
    font-family: var(--font-main);
}

.note-input,
.note-textarea {
    width: 100%;
    padding: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 20px;
    color: #fff;
    font-family: var(--font-main);
    font-size: 14px;
    transition: all 0.4s var(--ease-out-expo);
}

.note-input:focus,
.note-textarea:focus {
    outline: none;
    border-color: rgba(0, 242, 255, 0.4);
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 3px rgba(0, 242, 255, 0.1);
}

.note-textarea {
    min-height: 120px;
    resize: vertical;
}

.note-char-count {
    display: block;
    text-align: right;
    margin-top: 5px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    font-family: var(--font-mono);
}

/* Dark mode support for notes */
@media (prefers-color-scheme: dark) {
    .sticky-note {
        color: #333;
    }
    
    .sticky-note-title {
        color: #333;
    }
    
    .sticky-note-content {
        color: #555;
    }
}