:root{--bg:#0f1724;--panel:#071326;--accent:#5cc5ff;--muted:#9fb3c8;--text:#e6eef8;--card:#081220}
*{box-sizing:border-box}
html,body{height:100%;margin:0;font-family:Inter,ui-sans-serif,system-ui,-apple-system,Segoe UI,Roboto,"Helvetica Neue",Arial;color:var(--text);background:linear-gradient(180deg,#061021 0%,#071426 100%)}
header{display:flex;align-items:center;justify-content:space-between;padding:14px 20px;background:linear-gradient(90deg,rgba(255,255,255,0.02),transparent);backdrop-filter:blur(4px)}
header h1{margin:0;font-size:1.1rem}
nav a{color:var(--muted);margin-left:14px;text-decoration:none}
main{padding:18px 20px}
h1,h2,h3,h4{line-height:1.15}
.layout{display:flex;gap:16px;align-items:flex-start}
.sidebar{width:220px}
.sidebar .panel{padding:12px;height:calc(100vh - 120px);overflow:auto}
.sidebar h2{margin:0 0 8px 0;font-size:0.95rem}
.sidebar ul{list-style:none;padding:0;margin:0}
.sidebar li{margin:6px 0}
.level-link{display:block;width:100%;text-align:left;padding:8px;border-radius:6px;border:0;background:transparent;color:var(--muted);cursor:pointer;font-weight:600}
.level-link.active{background:rgba(92,197,255,0.06);color:var(--accent)}
.content{flex:1}
.panel{background:var(--panel);padding:14px;border-radius:10px;margin-bottom:12px;box-shadow:0 3px 12px rgba(2,6,23,0.6)}
.search-row{display:flex;gap:8px;align-items:center;margin-bottom:12px}
.search-row input[type=text]{flex:1;padding:10px 12px;border-radius:8px;border:1px solid rgba(255,255,255,0.04);background:transparent;color:var(--text)}
.search-row select{padding:8px;border-radius:8px;border:1px solid rgba(255,255,255,0.04);background:transparent;color:var(--text)}
.table-wrap{overflow:auto;border-radius:8px}
table.levels-table{width:100%;border-collapse:collapse;background:linear-gradient(180deg,rgba(255,255,255,0.012),transparent)}
table.levels-table th,table.levels-table td{padding:12px 14px;border-bottom:1px solid rgba(255,255,255,0.02);text-align:left}
table.levels-table th{color:var(--muted);font-size:0.85rem;font-weight:600}
table.levels-table tr:hover td{background:rgba(255,255,255,0.01)}
.btn{display:inline-block;padding:8px 10px;border-radius:8px;background:var(--accent);color:#042;cursor:pointer;border:none}
.muted{color:var(--muted);font-size:0.9rem}
.video-modal{position:fixed;inset:0;background:rgba(0,0,0,0.7);display:flex;align-items:center;justify-content:center;z-index:1200}
.video-modal .inner{width:90%;max-width:960px;background:var(--card);padding:12px;border-radius:8px}
.video-modal iframe{width:100%;height:540px;border:0;border-radius:6px}
@media(max-width:900px){.layout{flex-direction:column}.sidebar{width:100%}.video-modal iframe{height:320px}}

/* small helpers reused */
.small{font-size:0.9rem}
.discord-panel{display:flex;align-items:center;justify-content:space-between;gap:24px;margin-top:18px;padding:26px 28px;background:linear-gradient(135deg,rgba(88,101,242,0.18),rgba(7,19,38,0.95));border:1px solid rgba(88,101,242,0.22)}
.discord-copy{flex:1}
.discord-badge{display:flex;align-items:center;gap:16px;margin-bottom:14px}
.discord-logo{display:flex;align-items:center;justify-content:center;width:64px;height:64px;border-radius:18px;background:#5865f2;color:#fff;box-shadow:0 10px 24px rgba(88,101,242,0.32)}
.discord-logo img{width:34px;height:34px;display:block}
.discord-label{margin:0 0 6px 0;text-transform:uppercase;letter-spacing:0.14em;font-size:0.72rem;font-weight:700;color:#bfc7ff}
.discord-panel h2{margin:0;font-size:1.9rem}
.discord-text{max-width:720px;margin:0 0 16px 0;line-height:1.65;color:#dce8f5}
.discord-highlights{display:flex;flex-wrap:wrap;gap:10px}
.discord-highlights span{padding:8px 12px;border-radius:999px;background:rgba(255,255,255,0.07);color:#eef3ff;font-size:0.92rem}
.discord-actions{display:flex;align-items:center;justify-content:center}
.discord-btn{padding:12px 18px;background:#5865f2;color:#fff;font-weight:700}
.rules-view header{padding:18px 28px}
.rules-view header h1{font-size:2rem;font-weight:800;letter-spacing:0.02em}
.rules-view main{display:flex;justify-content:center;padding:40px 20px 64px}
.rules-page{width:min(100%,920px);margin:0 auto;padding:32px 36px;background:linear-gradient(180deg,rgba(8,18,32,0.98),rgba(7,19,38,0.94));border:1px solid rgba(92,197,255,0.12);box-shadow:0 18px 48px rgba(2,6,23,0.48)}
.rules-hero{text-align:center;margin:0 auto 30px;max-width:680px}
.rules-kicker{margin:0 0 10px 0;text-transform:uppercase;letter-spacing:0.18em;font-size:0.72rem;color:var(--accent);font-weight:700}
.rules-page h2{margin:0 0 12px 0;font-size:2.1rem;font-weight:800}
.rule-section + .rule-section{margin-top:24px;padding-top:24px;border-top:1px solid rgba(255,255,255,0.06)}
.rule-section h3{margin:0 0 12px 0;font-size:1.28rem;font-weight:750;color:#f4f8ff}
.rule-section h4{margin:18px 0 10px 0;font-size:0.95rem;font-weight:800;letter-spacing:0.08em;text-transform:uppercase;color:var(--accent)}
.rule-section p{margin:0 0 12px 0;line-height:1.7;color:#dce8f5}
.rules-list{margin:0;padding-left:22px}
.rules-list li{margin:0 0 8px 0;line-height:1.55;color:#dce8f5}
@media(max-width:900px){.layout{flex-direction:column}.sidebar{width:100%}.video-modal iframe{height:320px}.discord-panel{flex-direction:column;align-items:flex-start;padding:22px 20px}.discord-panel h2{font-size:1.55rem}.discord-actions{width:100%;justify-content:flex-start}.rules-view header{padding:16px 18px}.rules-view header h1{font-size:1.55rem}.rules-page{padding:24px 20px}.rules-page h2{font-size:1.65rem}}
