:root {
  --bg: #0f1115;
  --surface: #171a21;
  --surface-2: #1f232c;
  --border: #2a2f3a;
  --text: #e8eaed;
  --text-dim: #9aa0ab;
  --accent: #3ddc97;
  --red: #ef5350;
  --orange: #ffa726;
  --yellow: #ffee58;
  --blue: #42a5f5;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Tahoma, "Segoe UI", "Vazirmatn", sans-serif;
  font-size: 15px;
  line-height: 1.7;
}

a { color: var(--accent); text-decoration: none; }

.layout { display: flex; min-height: 100vh; }

.sidebar {
  width: 220px;
  flex-shrink: 0;
  background: var(--surface);
  border-left: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 16px 0;
}

.sidebar .brand {
  font-weight: bold;
  padding: 0 16px 16px 16px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 8px;
}

.sidebar a {
  display: block;
  padding: 10px 16px;
  color: var(--text-dim);
}

.sidebar a:hover { color: var(--text); background: var(--surface-2); }
.sidebar a.active { color: var(--accent); background: var(--surface-2); border-right: 3px solid var(--accent); }

.sidebar-footer {
  margin-top: auto;
  padding: 16px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-dim);
  font-size: 13px;
}

.logout { color: var(--red); }

.content { flex: 1; padding: 24px 32px; max-width: 1100px; }
.content-plain {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.notice {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 14px;
  color: var(--text-dim);
  font-size: 13px;
  margin-bottom: 24px;
}

h1 { font-size: 22px; margin: 0 0 20px 0; }
h2 { font-size: 17px; margin: 28px 0 12px 0; color: var(--text-dim); }

.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 14px; margin-bottom: 8px; }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px;
}
.card .value { font-size: 26px; font-weight: bold; }
.card .label { color: var(--text-dim); font-size: 13px; margin-top: 4px; }

table { width: 100%; border-collapse: collapse; background: var(--surface); border-radius: 10px; overflow: hidden; }
th, td { text-align: right; padding: 10px 14px; border-bottom: 1px solid var(--border); font-size: 14px; }
th { color: var(--text-dim); font-weight: normal; background: var(--surface-2); }
tr:last-child td { border-bottom: none; }

.badge { display: inline-block; padding: 2px 9px; border-radius: 999px; font-size: 12px; }
.badge.critical { background: rgba(239,83,80,.15); color: var(--red); }
.badge.high { background: rgba(255,167,38,.15); color: var(--orange); }
.badge.medium { background: rgba(255,238,88,.15); color: var(--yellow); }
.badge.low { background: rgba(255,255,255,.08); color: var(--text-dim); }
.badge.positive { background: rgba(61,220,151,.15); color: var(--accent); }
.badge.negative { background: rgba(239,83,80,.15); color: var(--red); }
.badge.neutral { background: rgba(255,255,255,.08); color: var(--text-dim); }
.badge.pending { background: rgba(66,165,245,.15); color: var(--blue); }

.empty { color: var(--text-dim); padding: 24px; text-align: center; }

.login-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 40px;
  text-align: center;
  max-width: 360px;
}
.login-box h1 { margin-bottom: 6px; }
.login-box p { color: var(--text-dim); margin-bottom: 24px; }
.login-error { color: var(--red); margin-bottom: 16px; font-size: 14px; }
