:root {
    --bg-gradient: radial-gradient(circle at center, #1a1a1a 0%, #000000 100%);
    --bg-color: #050505;
    --card-bg: rgba(20, 20, 20, 0.7);
    --text-color: #e8e8e8;
    --text-muted: #888;
    --accent-color: #c79c60; 
    --accent-glow: rgba(199, 156, 96, 0.3);
    --font-main: 'Roboto', sans-serif;
    --font-retro: 'Press Start 2P', cursive;
}
* { box-sizing: border-box; margin: 0; padding: 0; }
body {
    font-family: var(--font-main);
    background: var(--bg-color);
    background: var(--bg-gradient);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
    font-size: 0.95rem; 
}
a { text-decoration: none; color: inherit; transition: 0.3s; }

/* --- NAVIGATION --- */
nav {
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(10px);
    padding: 10px 20px;
    display: flex; align-items: center; gap: 15px;
    border-bottom: 1px solid var(--accent-color);
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
    position: relative; z-index: 500; flex-wrap: wrap;
}
.nav-brand { display: flex; align-items: center; gap: 15px; margin-right: auto; }
.nav-logo { height: 30px; width: auto; border-radius: 4px; }
.nav-title { font-family: var(--font-retro); font-size: 1rem; color: var(--accent-color); text-shadow: 2px 2px 0px #333; letter-spacing: 1px; white-space: nowrap; }
nav a, .nav-btn { font-weight: 700; font-size: 0.8rem; color: #aaa; padding: 8px 15px; border-radius: 30px; border: 1px solid transparent; transition: all 0.3s; text-transform: uppercase; cursor: pointer; background: transparent; font-family: var(--font-main); }
nav a:hover, .nav-btn:hover { color: var(--accent-color); border-color: var(--accent-color); background: rgba(199, 156, 96, 0.1); transform: translateY(-2px); }
nav a.highlight { background: var(--accent-color); color: #000; box-shadow: 0 0 10px var(--accent-glow); }
nav a.highlight:hover { background: #fff; }

/* Language Switcher Style */
.lang-switcher { display: flex; gap: 5px; align-items: center; margin-left: 5px; }
.lang-link { font-size: 0.75rem; padding: 5px 8px; color: #666; font-weight: bold; border: 1px solid #333; border-radius: 4px; }
.lang-link:hover { color: var(--accent-color); border-color: var(--accent-color); }
.lang-link.active { background: var(--accent-color); color: #000; border-color: var(--accent-color); box-shadow: 0 0 5px var(--accent-glow); }

.btn-logout { border: 1px solid #ff4444; color: #ff4444; }
.btn-logout:hover { background: #ff4444; color: white; }
.user-display { color: var(--accent-color); border: 1px solid var(--accent-color); font-family: var(--font-retro); font-size: 0.6rem; box-shadow: 0 0 5px var(--accent-glow); }

/* --- DROPDOWN MENUS --- */
.dropdown-container { position: relative; display: inline-block; }
.dropdown-menu { display: none; position: absolute; top: 120%; right: 0; background: rgba(15, 15, 15, 0.98); min-width: 260px; box-shadow: 0 8px 16px rgba(0,0,0,0.8); border: 1px solid var(--accent-color); border-radius: 12px; padding: 15px; z-index: 1000; animation: fadeIn 0.3s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
.dropdown-menu.show { display: block; }
.form-input { width: 100%; padding: 8px; margin-bottom: 12px; background: #000; border: 1px solid #444; color: var(--accent-color); border-radius: 5px; font-family: var(--font-main); font-size: 0.9rem; }
.form-input:focus { outline: none; border-color: var(--accent-color); box-shadow: 0 0 5px var(--accent-glow); }
.form-btn { width: 100%; padding: 8px; background: var(--accent-color); color: #000; border: none; border-radius: 5px; font-weight: bold; cursor: pointer; transition: 0.3s; font-size: 0.9rem; }
.form-btn:hover { background: #fff; }
.dropdown-title { font-family: var(--font-retro); font-size: 0.6rem; color: var(--accent-color); margin-bottom: 12px; text-align: center; display: block; }

/* --- LAYOUT --- */
.container { max-width: 1400px; margin: 30px auto; padding: 0 15px; flex: 1; width: 100%; }
.layout-wrapper { display: flex; gap: 30px; align-items: flex-start; }
.sidebar { flex: 0 0 220px; background: transparent; }
.sidebar-link { display: block; margin-bottom: 12px; padding: 12px; text-align: center; font-family: var(--font-retro); font-size: 9px; line-height: 1.5; background: linear-gradient(145deg, rgba(30, 30, 30, 0.8), rgba(10, 10, 10, 0.9)); border: 1px solid #333; border-radius: 10px; color: var(--accent-color); transition: all 0.3s ease; box-shadow: 0 4px 6px rgba(0,0,0,0.3); }
.sidebar-link:hover { transform: translateX(8px); border-color: var(--accent-color); box-shadow: 0 0 15px var(--accent-glow); text-shadow: 0 0 5px var(--accent-color); }
.main-content { flex: 1; width: 100%; }
.section-title { font-family: var(--font-retro); font-size: 1.3rem; color: var(--accent-color); border-bottom: 2px solid var(--accent-color); padding-bottom: 8px; margin-bottom: 25px; display: inline-block; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 15px; }
.card { background: linear-gradient(145deg, rgba(30, 30, 30, 0.6), rgba(5, 5, 5, 0.8)); border-radius: 14px; padding: 10px; text-align: center; border: 1px solid #333; display: flex; flex-direction: column; justify-content: space-between; transition: all 0.4s ease; backdrop-filter: blur(5px); }
.card:hover { transform: translateY(-6px); border-color: var(--accent-color); box-shadow: 0 10px 30px rgba(0,0,0,0.5), 0 0 10px var(--accent-glow); }
.card img { width: 100%; height: 120px; object-fit: cover; border-radius: 8px; margin-bottom: 10px; border: 1px solid #333; }
.card h3 { font-family: var(--font-retro); color: var(--accent-color); font-size: 10px; margin-bottom: 6px; line-height: 1.4; }
.card p { font-size: 0.8rem; color: var(--text-muted); margin-bottom: 12px; flex-grow: 1; }
.btn { display: inline-block; padding: 8px 20px; background: transparent; border: 1px solid var(--accent-color); color: var(--accent-color); border-radius: 30px; font-family: var(--font-retro); font-size: 8px; text-transform: uppercase; transition: all 0.3s; cursor: pointer; }
.btn:hover { background: var(--accent-color); color: #000; box-shadow: 0 0 15px var(--accent-glow); }
footer { margin-top: 50px; padding: 20px; text-align: center; background: rgba(10, 10, 10, 0.95); border-top: 1px solid #333; color: var(--accent-color); font-size: 0.8rem; }

/* --- CHAT --- */
#chat-icon { position: fixed; bottom: 20px; right: 20px; width: 50px; height: 50px; background: #000; border: 2px solid var(--accent-color); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 24px; cursor: pointer; z-index: 1000; box-shadow: 0 0 15px var(--accent-glow); transition: transform 0.3s; }
#chat-icon:hover { transform: scale(1.1) rotate(10deg); background: var(--accent-color); }
#sidebar-chat { position: fixed; top: 0; right: -320px; width: 280px; height: 100%; background: rgba(10, 10, 10, 0.95); border-left: 2px solid var(--accent-color); backdrop-filter: blur(10px); z-index: 999; display: flex; flex-direction: column; transition: right 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); box-shadow: -10px 0 30px rgba(0,0,0,0.8); }
#sidebar-chat.active { right: 0; }
#chat-feed { flex: 1; padding: 15px; overflow-y: auto; }
.chat-msg { margin-bottom: 12px; padding: 8px; background: rgba(255, 255, 255, 0.05); border-left: 3px solid var(--accent-color); border-radius: 4px; font-size: 0.85rem; }
.chat-msg strong { color: var(--accent-color); display: block; font-size: 0.85rem; margin-bottom: 4px; }
.chat-input-area { display: flex; align-items: center; border-top: 1px solid #333; background: #000; }
#chat-input { flex: 1; padding: 15px; border: none; background: transparent; color: var(--accent-color); outline: none; font-size: 0.9rem; }
#chat-send-btn { padding: 0 15px; background: transparent; border: none; font-size: 18px; cursor: pointer; color: var(--accent-color); }
::-webkit-input-placeholder { color: #555; }

@media (max-width: 900px) {
    body { zoom: 0.90; }
    .layout-wrapper { flex-direction: column; }
    .sidebar { width: 100%; display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .sidebar-link { margin-bottom: 0; }
    .nav-brand { margin-right: 0; width: 100%; justify-content: center; margin-bottom: 10px; }
    nav { justify-content: center; }
}

/* --- FIXED MOBILE DROPDOWN --- */
@media (max-width: 600px) {
    .sidebar { grid-template-columns: 1fr; }
    .container { padding: 0 8px; }
    .grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .btn { width: 100%; }
    
    .dropdown-menu { 
        position: fixed; 
        top: 80px; 
        left: 50%; 
        transform: translateX(-50%); 
        width: 90%; 
        max-width: 320px; 
        background: rgba(15, 15, 15, 0.98); 
        border: 2px solid var(--accent-color);
        box-shadow: 0 0 50px rgba(0,0,0,0.9);
        padding: 20px;
        max-height: 80vh; 
        overflow-y: auto;
        z-index: 9999;
    }
}