:root { 
    --bg: #050505; 
    --panel: #141414; 
    --accent: #00ffcc; 
    --gold: #ffcc00; 
    --header-h: 65px; 
    --sidebar-w: 260px;
    --leader-w: 300px;
    --border: #2a2a2a;
}
* { box-sizing: border-box; }
body, html { margin: 0; padding: 0; width: 100%; height: 100%; background: var(--bg); color: white; font-family: 'Segoe UI', sans-serif; overflow: hidden; }

.header { 
    height: var(--header-h); 
    background: var(--panel); 
    border-bottom: 1px solid var(--border); 
    display: flex; 
    align-items: center; 
    justify-content: space-between; 
    padding: 0 20px; 
    z-index: 100;
}
.header-center {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    pointer-events: none;
}
.header-logo { font-weight: 900; color: var(--accent); letter-spacing: 2px; font-size: 20px; line-height: 1; }
.header-slogan { font-size: 9px; color: #555; text-transform: uppercase; letter-spacing: 4px; margin-top: 4px; font-weight: 700; }

.auth-panel { display: flex; align-items: center; z-index: 101; }
.header-links { display: flex; gap: 25px; font-size: 11px; font-weight: 700; text-transform: uppercase; color: #888; z-index: 101; }
.header-links span { transition: 0.2s; cursor: pointer; }
.header-links span:hover { color: var(--accent); }

.modal-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.85);
    backdrop-filter: blur(5px);
    display: none; 
    justify-content: center;
    align-items: center;
    z-index: 2000;
}
.modal-content {
    background: var(--panel);
    width: 400px;
    padding: 30px;
    border-radius: 8px;
    border: 1px solid var(--border);
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    position: relative;
}
.modal-content h3 { margin-top: 0; color: var(--accent); text-transform: uppercase; letter-spacing: 2px; font-size: 16px; margin-bottom: 20px; text-align: center; }
.modal-close { position: absolute; top: 15px; right: 15px; cursor: pointer; color: #555; font-size: 20px; font-weight: bold; }
.modal-close:hover { color: white; }

.form-group { margin-bottom: 15px; }
.form-group label { display: block; font-size: 9px; color: #666; text-transform: uppercase; font-weight: 800; margin-bottom: 5px; }
.form-group input { width: 100%; background: #000; border: 1px solid #333; color: white; padding: 10px; border-radius: 4px; font-family: inherit; }

.terms-text { font-size: 11px; color: #777; margin: 15px 0; line-height: 1.4; text-align: center; }
.terms-link { color: var(--accent); text-decoration: underline; cursor: pointer; }

.legal-scroll { height: 250px; overflow-y: auto; background: #000; padding: 15px; border-radius: 4px; font-size: 12px; color: #aaa; margin-bottom: 20px; border: 1px solid #222; }
.legal-scroll h4 { color: var(--gold); margin: 15px 0 5px 0; font-size: 13px; }

.main-container { display: flex; height: calc(100vh - var(--header-h)); width: 100%; }
.sidebar { width: var(--sidebar-w); background: var(--panel); border-right: 1px solid var(--border); padding: 20px; display: flex; flex-direction: column; gap: 12px; overflow-y: auto; }
.ui-section { display: flex; flex-direction: column; gap: 8px; background: rgba(255,255,255,0.02); padding: 12px; border-radius: 6px; border: 1px solid var(--border); }
.ui-section label { font-size: 9px; color: #666; font-weight: 800; text-transform: uppercase; letter-spacing: 1px; }
input[type="number"], input[type="text"], select { background: #000; color: var(--accent); border: 1px solid #333; padding: 7px; border-radius: 4px; font-weight: 700; width: 100%; font-size: 13px; }
.input-row { display: flex; gap: 5px; }
button { width: 100%; padding: 10px; border-radius: 4px; background: #222; color: white; border: 1px solid #333; cursor: pointer; font-size: 11px; font-weight: 700; text-transform: uppercase; transition: 0.2s; }
button:hover { background: #2a2a2a; border-color: var(--accent); }
.btn-primary { background: var(--accent) !important; color: #000 !important; border: none !important; }
.btn-reject { background: transparent !important; border: 1px solid #ff4d4d !important; color: #ff4d4d !important; }
.btn-reject:hover { background: #ff4d4d !important; color: white !important; }

.workspace { flex-grow: 1; position: relative; overflow: hidden; background: #050505; cursor: crosshair; }
canvas { display: block; width: 100%; height: 100%; }
.leaderboard-fixed { width: var(--leader-w); background: var(--panel); border-left: 1px solid var(--border); display: flex; flex-direction: column; }
.leader-head { padding: 18px; font-weight: 900; font-size: 14px; text-align: center; letter-spacing: 3px; border-bottom: 1px solid var(--border); color: var(--accent); }
.stats-scroll { padding: 20px; overflow-y: auto; flex-grow: 1; }
.stats-scroll h2 { color: #555; font-size: 10px; margin: 25px 0 12px 0; border-bottom: 1px solid var(--border); padding-bottom: 5px; text-transform: uppercase; }

.stat-row { margin-bottom: 12px; }
.stat-head { display: flex; justify-content: space-between; margin-bottom: 4px; font-size: 11px; font-weight: 600; }
.bar-bg { height: 5px; background: #1a1a1a; width: 100%; border-radius: 10px; overflow: hidden; }
.bar-fill { height: 100%; background: var(--accent); border-radius: 10px; }
#tooltip { position: fixed; background: rgba(0, 0, 0, 0.9); padding: 12px; border-radius: 4px; display: none; z-index: 9999; border: 1px solid var(--accent); font-size: 12px; pointer-events: none; }

#cookieBanner { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); width: calc(100% - 40px); max-width: 600px; background: rgba(20, 20, 20, 0.98); backdrop-filter: blur(15px); border: 1px solid var(--border); border-left: 4px solid var(--accent); padding: 20px; border-radius: 8px; z-index: 3000; display: none; box-shadow: 0 15px 50px rgba(0,0,0,0.9); }
.cookie-content { display: flex; align-items: center; justify-content: space-between; gap: 25px; }
.cookie-text { font-size: 12px; color: #bbb; line-height: 1.5; }
.cookie-link { color: var(--accent); text-decoration: underline; cursor: pointer; font-weight: bold; }

/* BRAMA ADMINISTRACYJNA */
#adminGate {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: #000;
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}
.admin-box {
    background: #111;
    border: 2px solid var(--border);
    padding: 40px;
    border-radius: 10px;
    width: 350px;
    text-align: center;
    box-shadow: 0 0 50px rgba(0, 255, 204, 0.1);
}
.admin-title {
    color: var(--accent);
    font-weight: 900;
    letter-spacing: 3px;
    font-size: 18px;
    margin-bottom: 25px;
    text-transform: uppercase;
}
.admin-error { color: #ff4d4d; font-size: 11px; margin-top: 10px; display: none; text-transform: uppercase; font-weight: bold; }