/* EinPanel - tema CS:GO dark/gold */
@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Teko:wght@400;500;600;700&family=Rajdhani:wght@400;500;600;700&display=swap');

:root {
  --gold: #de9b35;
  --gold-dim: #b47c26;
  --gold-glow: rgba(222, 155, 53, .18);
  --bg: #0c0d10;
  --bg-2: #121318;
  --panel: #16181f;
  --panel-2: #1b1e27;
  --line: #23262f;
  --line-2: #2c3140;
  --txt: #e6e8ee;
  --txt-dim: #8b909c;
  --txt-mute: #5c616e;
  --green: #4ade80;
  --red: #ef4444;
  --orange: #f59e0b;
  --blue: #60a5fa;
  --radius: 4px;
  --sidebar-w: 248px;
}

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

html, body {
  background: var(--bg);
  color: var(--txt);
  font-family: 'Rajdhani', system-ui, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

body {
  background-image:
    radial-gradient(900px 500px at 78% -10%, rgba(222,155,53,.06), transparent 60%),
    radial-gradient(700px 500px at -5% 8%, rgba(222,155,53,.04), transparent 55%);
  background-attachment: fixed;
}

a { color: inherit; text-decoration: none; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ---------- angled HUD corners ---------- */
.clip { clip-path: polygon(10px 0, 100% 0, 100% calc(100% - 10px), calc(100% - 10px) 100%, 0 100%, 0 10px); }
.clip-sm { clip-path: polygon(6px 0, 100% 0, 100% calc(100% - 6px), calc(100% - 6px) 100%, 0 100%, 0 6px); }

/* ================= LAYOUT ================= */
.shell { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  background: linear-gradient(180deg, #0e0f13, #0a0b0e);
  border-right: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 40;
}

.brand {
  display: flex; align-items: center; gap: 12px;
  padding: 20px 20px 18px;
  border-bottom: 1px solid var(--line);
}
.brand-mark {
  width: 42px; height: 42px;
  background: linear-gradient(135deg, var(--gold), var(--gold-dim));
  display: grid; place-items: center;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 26px; color: #14150f; font-weight: 700;
  clip-path: polygon(8px 0,100% 0,100% calc(100% - 8px),calc(100% - 8px) 100%,0 100%,0 8px);
}
.brand-name { font-family: 'Bebas Neue', sans-serif; font-size: 24px; letter-spacing: 1px; }
.brand-name b { color: var(--gold); }
.brand-sub { font-size: 11px; color: var(--txt-mute); letter-spacing: 2px; text-transform: uppercase; }

.nav { padding: 14px 12px; flex: 1; overflow-y: auto; }
.nav-group { font-size: 10px; letter-spacing: 2px; color: var(--txt-mute); text-transform: uppercase; padding: 16px 12px 8px; }
.nav-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; margin: 2px 0;
  color: var(--txt-dim);
  font-weight: 500; font-size: 15px;
  border-left: 2px solid transparent;
  transition: .12s;
}
.nav-item svg { width: 18px; height: 18px; stroke-width: 2; opacity: .85; }
.nav-item:hover { background: var(--panel); color: var(--txt); }
.nav-item.on {
  background: linear-gradient(90deg, var(--gold-glow), transparent);
  color: var(--gold);
  border-left-color: var(--gold);
}
.nav-item.ext { color: var(--blue); }
.nav-item.ext.wa { color: var(--green); }

.who {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 18px; border-top: 1px solid var(--line);
}
.who-av {
  width: 34px; height: 34px; border-radius: 50%;
  background: linear-gradient(135deg, var(--gold), var(--gold-dim));
  display: grid; place-items: center; color: #14150f; font-weight: 700;
}
.who-name { font-weight: 600; font-size: 14px; }
.who-role { font-size: 11px; color: var(--txt-mute); }

.main { flex: 1; margin-left: var(--sidebar-w); padding: 28px 34px 60px; min-width: 0; }

.topbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 26px; }
.page-title { font-family: 'Bebas Neue', sans-serif; font-size: 34px; letter-spacing: 1px; line-height: 1; }
.page-title small { display: block; font-family: 'Rajdhani'; font-size: 13px; color: var(--txt-mute); letter-spacing: .5px; margin-top: 4px; }

.menu-btn { display: none; }

/* ================= CARDS ================= */
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  clip-path: polygon(10px 0,100% 0,100% calc(100% - 10px),calc(100% - 10px) 100%,0 100%,0 10px);
  position: relative;
}
.card::before {
  content: ''; position: absolute; top: 0; left: 0; width: 40px; height: 2px;
  background: var(--gold);
}
.card-h {
  display: flex; align-items: center; gap: 10px;
  padding: 16px 20px; border-bottom: 1px solid var(--line);
  font-weight: 600; font-size: 16px;
}
.card-h svg { width: 18px; height: 18px; color: var(--gold); }
.card-b { padding: 20px; }

/* ================= STAT TILES ================= */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 24px; }
.tile {
  background: var(--panel);
  border: 1px solid var(--line);
  border-top: 2px solid var(--gold);
  padding: 18px 20px;
  clip-path: polygon(0 0,100% 0,100% calc(100% - 8px),calc(100% - 8px) 100%,0 100%);
}
.tile-label { font-size: 11px; letter-spacing: 2px; color: var(--txt-mute); text-transform: uppercase; }
.tile-value { font-family: 'Teko', sans-serif; font-size: 46px; font-weight: 600; line-height: 1; margin-top: 4px; }
.tile-sub { font-size: 12px; color: var(--txt-mute); }
.tile.green .tile-value { color: var(--green); }
.tile.blue .tile-value { color: var(--blue); }
.tile.orange .tile-value { color: var(--orange); }
.tile.gold .tile-value { color: var(--gold); }

/* ================= TABLE ================= */
.tbl { width: 100%; border-collapse: collapse; }
.tbl th {
  text-align: left; padding: 12px 16px;
  font-size: 11px; letter-spacing: 1.5px; text-transform: uppercase;
  color: var(--txt-mute); border-bottom: 1px solid var(--line);
  font-weight: 600;
}
.tbl td { padding: 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.tbl tr:last-child td { border-bottom: none; }
.tbl tr:hover td { background: rgba(255,255,255,.015); }
.srv-name { font-weight: 700; font-size: 16px; }
.srv-id { font-size: 12px; color: var(--txt-mute); font-family: 'Rajdhani'; }
.mono { font-family: ui-monospace, 'Cascadia Code', Menlo, monospace; font-size: 13px; color: var(--txt-dim); }

/* ================= BADGES ================= */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; font-size: 12px; font-weight: 600;
  border: 1px solid transparent; border-radius: 3px;
}
.badge::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.badge.on { color: var(--green); background: rgba(74,222,128,.1); }
.badge.off { color: var(--txt-mute); background: rgba(255,255,255,.04); }
.badge.susp { color: var(--orange); background: rgba(245,158,11,.1); }

/* ================= BUTTONS ================= */
.btn {
  display: inline-flex; align-items: center; gap: 8px; justify-content: center;
  padding: 10px 18px; font-family: 'Rajdhani'; font-weight: 600; font-size: 14px;
  letter-spacing: .5px; text-transform: uppercase; cursor: pointer;
  border: 1px solid var(--line-2); background: var(--panel-2); color: var(--txt);
  transition: .12s; clip-path: polygon(6px 0,100% 0,100% calc(100% - 6px),calc(100% - 6px) 100%,0 100%,0 6px);
}
.btn:hover { border-color: var(--gold-dim); color: var(--gold); }
.btn svg { width: 16px; height: 16px; }
.btn-gold { background: linear-gradient(135deg, var(--gold), var(--gold-dim)); color: #14150f; border: none; }
.btn-gold:hover { filter: brightness(1.08); color: #14150f; }
.btn-green { background: rgba(74,222,128,.12); border-color: rgba(74,222,128,.3); color: var(--green); }
.btn-green:hover { background: rgba(74,222,128,.2); color: var(--green); }
.btn-red { background: rgba(239,68,68,.1); border-color: rgba(239,68,68,.3); color: var(--red); }
.btn-red:hover { background: rgba(239,68,68,.2); color: var(--red); }
.btn-sm { padding: 7px 12px; font-size: 12px; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn-icon { padding: 8px; width: 36px; }

.actions { display: flex; gap: 8px; }

/* ================= FORMS ================= */
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 12px; letter-spacing: 1px; text-transform: uppercase; color: var(--txt-dim); margin-bottom: 7px; font-weight: 600; }
.input {
  width: 100%; padding: 12px 14px;
  background: var(--bg-2); border: 1px solid var(--line-2); color: var(--txt);
  font-family: 'Rajdhani'; font-size: 15px; font-weight: 500;
  clip-path: polygon(6px 0,100% 0,100% calc(100% - 6px),calc(100% - 6px) 100%,0 100%,0 6px);
}
.input:focus { border-color: var(--gold); background: #101116; }
.input::placeholder { color: var(--txt-mute); }

/* ================= LOGIN ================= */
.login-wrap { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-card { width: 100%; max-width: 400px; background: var(--panel); border: 1px solid var(--line); padding: 38px 34px; clip-path: polygon(14px 0,100% 0,100% calc(100% - 14px),calc(100% - 14px) 100%,0 100%,0 14px); }
.login-logo { text-align: center; margin-bottom: 28px; }
.login-logo .lg { font-family: 'Bebas Neue'; font-size: 40px; letter-spacing: 2px; }
.login-logo .lg b { color: var(--gold); }
.login-logo .dm { font-size: 12px; color: var(--txt-mute); letter-spacing: 2px; text-transform: uppercase; }
.flash { padding: 11px 14px; margin-bottom: 18px; font-size: 14px; font-weight: 600; background: rgba(239,68,68,.1); border-left: 3px solid var(--red); color: #fca5a5; }
.login-hint { text-align: center; font-size: 12px; color: var(--txt-mute); margin-top: 18px; }

/* ================= SERVER DETAIL ================= */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 24px; }
.tab { padding: 12px 20px; font-weight: 600; color: var(--txt-dim); border-bottom: 2px solid transparent; cursor: pointer; text-transform: uppercase; font-size: 14px; letter-spacing: .5px; }
.tab.on { color: var(--gold); border-bottom-color: var(--gold); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }
.delimiter { margin: 22px 0 14px; font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--gold); border-bottom: 1px solid var(--line); padding-bottom: 8px; font-weight: 700; }
select.input optgroup { background: var(--panel); color: var(--txt-mute); font-weight: 700; }
select.input option { background: var(--panel); color: var(--txt); }

.kv { display: flex; justify-content: space-between; padding: 13px 0; border-bottom: 1px solid var(--line); }
.kv:last-child { border-bottom: none; }
.kv .k { color: var(--txt-dim); font-size: 13px; letter-spacing: .5px; text-transform: uppercase; }
.kv .v { font-weight: 600; }

/* ================= CONSOLE ================= */
.console {
  background: #08090b; border: 1px solid var(--line-2);
  font-family: ui-monospace, 'Cascadia Code', Menlo, monospace;
  font-size: 13px; line-height: 1.55;
  padding: 16px; height: 440px; overflow-y: auto; white-space: pre-wrap; word-break: break-word;
  color: #7dd87d;
}
.console::-webkit-scrollbar { width: 10px; }
.console::-webkit-scrollbar-thumb { background: var(--line-2); }
.console-bar { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.console-title { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.console-title svg { color: var(--gold); width: 18px; height: 18px; }
.cmd-row { display: flex; gap: 10px; margin-top: 14px; }
.cmd-row .prompt { display: grid; place-items: center; padding: 0 14px; background: var(--bg-2); border: 1px solid var(--line-2); color: var(--gold); font-family: ui-monospace, monospace; }
.cmd-input { flex: 1; }
.quick { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; align-items: center; }
.quick-lbl { font-size: 12px; color: var(--txt-mute); text-transform: uppercase; letter-spacing: 1px; }
.chip { padding: 6px 12px; background: var(--panel-2); border: 1px solid var(--line-2); font-size: 12px; font-family: ui-monospace, monospace; cursor: pointer; color: var(--txt-dim); }
.chip:hover { border-color: var(--gold-dim); color: var(--gold); }

.empty { text-align: center; padding: 60px 20px; color: var(--txt-mute); }
.empty svg { width: 44px; height: 44px; opacity: .4; margin-bottom: 14px; }

.res-off { display: flex; align-items: center; gap: 8px; color: var(--txt-mute); font-size: 14px; }
.res-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.res-item { background: var(--bg-2); border: 1px solid var(--line); padding: 14px; }
.res-item .rl { font-size: 11px; letter-spacing: 1px; text-transform: uppercase; color: var(--txt-mute); }
.res-item .rv { font-family: 'Teko'; font-size: 30px; line-height: 1; margin-top: 3px; }

/* ================= RESPONSIVE ================= */
@media (max-width: 960px) {
  .stats { grid-template-columns: repeat(2, 1fr); }
  .grid-2, .res-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .sidebar { transform: translateX(-100%); transition: transform .22s ease; box-shadow: 20px 0 60px rgba(0,0,0,.6); }
  body.nav-open .sidebar { transform: translateX(0); }
  .main { margin-left: 0; padding: 18px 16px 50px; }
  .menu-btn { display: inline-grid; place-items: center; width: 42px; height: 42px; background: var(--panel); border: 1px solid var(--line-2); color: var(--gold); cursor: pointer; }
  .page-title { font-size: 26px; }
  .stats { grid-template-columns: 1fr 1fr; gap: 10px; }
  .tile-value { font-size: 38px; }
  .tbl thead { display: none; }
  .tbl, .tbl tbody, .tbl tr, .tbl td { display: block; width: 100%; }
  .tbl tr { border: 1px solid var(--line); margin-bottom: 12px; padding: 6px; }
  .tbl td { border: none; padding: 8px 10px; display: flex; justify-content: space-between; gap: 12px; }
  .tbl td::before { content: attr(data-l); font-size: 11px; text-transform: uppercase; letter-spacing: 1px; color: var(--txt-mute); font-weight: 600; }
  .actions { justify-content: flex-end; }
  .nav-scrim { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 30; display: none; }
  body.nav-open .nav-scrim { display: block; }
}
/* ---- Sub-Users ---- */
.note { display: flex; gap: 12px; align-items: flex-start; background: rgba(222,155,53,.07); border: 1px solid var(--line); border-left: 3px solid var(--gold); padding: 14px 16px; color: var(--txt-dim); font-size: 14px; line-height: 1.55; }
.note svg { width: 20px; height: 20px; color: var(--gold); flex-shrink: 0; margin-top: 1px; }
.subrow { border: 1px solid var(--line); background: rgba(255,255,255,.015); padding: 14px 16px; margin-bottom: 14px; }
.subrow-h { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.subrow-edit { display: flex; flex-wrap: wrap; gap: 14px; align-items: center; margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--line); }
.chk { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; color: var(--txt-dim); cursor: pointer; user-select: none; }
.chk input { width: 16px; height: 16px; accent-color: var(--gold); cursor: pointer; }
.subadd-fields { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 14px; }
.subadd-fields .input { flex: 1; min-width: 220px; }
.subadd-perms { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; }

@media (max-width: 720px) {
  .subrow-h { flex-direction: column; }
  .subadd-fields .input { min-width: 100%; }
}
/* ---- File Manager ---- */
.fm-bar { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.fm-quickbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; padding-bottom: 14px; border-bottom: 1px dashed var(--line); }
.fm-quicklbl { font-size: 12px; color: var(--txt-mute); text-transform: uppercase; letter-spacing: 1px; margin-right: 4px; }
.fm-path { flex: 1; min-width: 160px; background: var(--bg); border: 1px solid var(--line); padding: 8px 12px; color: var(--gold); font-size: 13px; overflow-x: auto; white-space: nowrap; }
.fm-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.fm-list { border: 1px solid var(--line); }
.fm-entry { display: flex; align-items: center; gap: 12px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.fm-entry:last-child { border-bottom: none; }
.fm-entry:hover { background: rgba(255,255,255,.02); }
.fm-entry .fm-ico { width: 18px; text-align: center; color: var(--txt-mute); }
.fm-entry.dir .fm-ico { color: var(--gold); }
.fm-entry .fm-name { flex: 1; cursor: pointer; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fm-entry.dir .fm-name { color: var(--gold); font-weight: 600; }
.fm-entry .fm-size { color: var(--txt-mute); font-size: 12px; width: 80px; text-align: right; }
.fm-entry .fm-mod { color: var(--txt-mute); font-size: 12px; width: 90px; text-align: right; }
.fm-entry .fm-del { color: var(--red); cursor: pointer; font-size: 12px; padding: 2px 8px; border: 1px solid var(--line); background: transparent; }
.fm-entry .fm-del:hover { border-color: var(--red); }
.fm-editor-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; gap: 10px; }
.fm-editor-name { color: var(--gold); font-size: 13px; }
.fm-textarea { width: 100%; min-height: 380px; background: var(--bg); border: 1px solid var(--line); color: var(--txt); padding: 14px; font-size: 13px; line-height: 1.5; resize: vertical; }
.fm-textarea:focus { outline: none; border-color: var(--gold); }
@media (max-width: 720px) {
  .fm-entry .fm-mod { display: none; }
  .fm-entry .fm-size { width: 60px; }
}
/* ---- Servere Hostate (monitor) ---- */
.hs-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 20px; }
.hs-stat { background: var(--panel); border: 1px solid var(--line); padding: 20px; text-align: center; position: relative; overflow: hidden; }
.hs-stat::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 2px; background: var(--gold); }
.hs-num { font-family: 'Bebas Neue', sans-serif; font-size: 40px; line-height: 1; color: var(--gold); }
.hs-lbl { font-size: 11px; letter-spacing: 2px; text-transform: uppercase; color: var(--txt-mute); margin-top: 6px; }
.hs-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--txt-mute); margin-right: 12px; vertical-align: middle; }
.hs-dot.on { background: var(--green); box-shadow: 0 0 8px var(--green); }
.hs-dot.off { background: var(--red); }
.hs-name { font-weight: 600; color: var(--txt); }
.hs-ip { font-size: 12px; color: var(--txt-mute); }
.hs-players { font-weight: 700; }
.hs-bar { height: 5px; background: var(--bg); border-radius: 3px; margin-top: 6px; width: 120px; max-width: 100%; overflow: hidden; }
.hs-bar-fill { height: 100%; background: linear-gradient(90deg, var(--gold), var(--orange)); transition: width .4s; }
.badge.full { color: var(--red); background: rgba(239,68,68,.12); }
@media (max-width: 720px) { .hs-stats { grid-template-columns: repeat(2, 1fr); } .hs-bar { display: none; } }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
