/* ============================================================================
   Sekolah Bot Admin — Dark theme stylesheet
   ============================================================================ */
:root {
  --bg:        #0f1117;
  --surface:   #1a1d27;
  --surface2:  #22263a;
  --border:    #2d3248;
  --accent:    #4f7cff;
  --accent2:   #7c4fff;
  --success:   #2dd48c;
  --warning:   #f5a623;
  --danger:    #ff4f6e;
  --text:      #e8eaf0;
  --muted:     #7a8099;
  --sidebar-w: 260px;
}
*,*::before,*::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
  height: 100%;
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
}
a { color: inherit; text-decoration: none; }

/* ─── Layout ─── */
.layout { display: flex; min-height: 100vh; }

/* ─── Sidebar ─── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  position: fixed; top: 0; left: 0; height: 100vh; z-index: 100;
}
.sidebar-logo {
  padding: 20px 24px; border-bottom: 1px solid var(--border);
  display: flex; align-items: center; gap: 10px;
}
.sidebar-logo .icon {
  width: 36px; height: 36px;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 18px;
}
.sidebar-logo .brand { font-weight: 700; font-size: 15px; line-height: 1.2; }
.sidebar-logo .brand span { color: var(--accent); display: block; font-size: 11px; font-weight: 500; }
.sidebar-nav { flex: 1; overflow-y: auto; padding: 16px 12px; }
.nav-group-label {
  font-size: 10px; font-weight: 600; letter-spacing: .08em; color: var(--muted);
  text-transform: uppercase; padding: 14px 12px 6px;
}
.nav-link {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 12px; border-radius: 8px;
  color: var(--muted); font-weight: 500; font-size: 13px;
  transition: .15s; white-space: nowrap;
}
.nav-link:hover { background: var(--surface2); color: var(--text); }
.nav-link.active { background: rgba(79,124,255,.15); color: var(--accent); }
.nav-link .ico { width: 18px; text-align: center; font-size: 15px; flex-shrink: 0; }
.nav-badge {
  margin-left: auto; background: var(--danger); color: #fff;
  font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 20px;
}

/* ─── Topbar ─── */
.topbar {
  position: fixed; top: 0; left: var(--sidebar-w); right: 0; height: 60px;
  background: var(--surface); border-bottom: 1px solid var(--border);
  display: flex; align-items: center; padding: 0 24px; gap: 16px; z-index: 90;
}
.topbar-title { font-weight: 700; font-size: 16px; flex: 1; }
.topbar-user { display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--muted); }
.topbar-user strong { color: var(--text); }
.btn-logout {
  background: none; border: 1px solid var(--border); color: var(--muted);
  padding: 6px 12px; border-radius: 6px; font-size: 12px;
  display: inline-block; transition: .15s;
}
.btn-logout:hover { border-color: var(--danger); color: var(--danger); }

/* ─── Main ─── */
.main {
  margin-left: var(--sidebar-w); margin-top: 60px;
  padding: 28px; flex: 1; min-width: 0;
}

/* ─── Cards ─── */
.card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px; overflow: hidden; margin-bottom: 20px;
}
.card-header {
  padding: 18px 20px; border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px;
}
.card-title { font-weight: 700; font-size: 15px; }
.card-body { padding: 20px; }

/* ─── Stat cards ─── */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; margin-bottom: 28px; }
.stat-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 14px; padding: 20px; position: relative; overflow: hidden;
}
.stat-card::before {
  content: ''; position: absolute; top: -20px; right: -20px;
  width: 80px; height: 80px; border-radius: 50%; opacity: .12;
}
.stat-card.blue::before   { background: var(--accent);  }
.stat-card.purple::before { background: var(--accent2); }
.stat-card.green::before  { background: var(--success); }
.stat-card.orange::before { background: var(--warning); }
.stat-card .num { font-size: 28px; font-weight: 700; margin-bottom: 4px; }
.stat-card .label { font-size: 12px; color: var(--muted); font-weight: 500; }
.stat-card .ico2 { font-size: 22px; margin-bottom: 10px; }

/* ─── Table ─── */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
thead th {
  padding: 10px 14px; text-align: left;
  font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--muted); border-bottom: 1px solid var(--border);
}
tbody td {
  padding: 12px 14px; border-bottom: 1px solid var(--border);
  font-size: 13px; vertical-align: middle;
}
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: rgba(255,255,255,.02); }

/* ─── Badges ─── */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 10px; border-radius: 20px; font-size: 11px; font-weight: 600;
}
.badge-pending  { background: rgba(245,166,35,.15);  color: var(--warning); }
.badge-approved,
.badge-active   { background: rgba(45,212,140,.15);  color: var(--success); }
.badge-rejected,
.badge-danger   { background: rgba(255,79,110,.15);  color: var(--danger);  }
.badge-alumni,
.badge-info     { background: rgba(79,124,255,.15);  color: var(--accent);  }

/* ─── Buttons ─── */
.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 14px; border-radius: 8px; border: none; cursor: pointer;
  font-family: inherit; font-size: 13px; font-weight: 600;
  transition: .15s; white-space: nowrap; text-decoration: none;
}
.btn-primary   { background: var(--accent);   color: #fff; }
.btn-primary:hover  { background: #3d6bef; }
.btn-success   { background: var(--success);  color: #0f1117; }
.btn-success:hover  { opacity: .9; }
.btn-danger    { background: var(--danger);   color: #fff; }
.btn-danger:hover   { opacity: .9; }
.btn-secondary { background: var(--surface2); color: var(--text); border: 1px solid var(--border); }
.btn-secondary:hover { background: var(--border); }
.btn-sm  { padding: 5px 10px; font-size: 12px; border-radius: 6px; }
.btn-xs  { padding: 3px 8px;  font-size: 11px; border-radius: 5px; }

/* ─── Forms ─── */
.form-group  { margin-bottom: 18px; }
.form-label  {
  display: block; font-size: 12px; font-weight: 600; color: var(--muted);
  margin-bottom: 6px; letter-spacing: .04em; text-transform: uppercase;
}
.form-control {
  width: 100%; background: var(--surface2); border: 1px solid var(--border);
  color: var(--text); padding: 9px 12px; border-radius: 8px;
  font-family: inherit; font-size: 13px; outline: none; transition: .15s;
}
.form-control:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(79,124,255,.15); }
.form-control::placeholder { color: var(--muted); }
select.form-control option { background: var(--surface); }
textarea.form-control { resize: vertical; min-height: 80px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ─── Alerts ─── */
.alert {
  padding: 12px 16px; border-radius: 8px; font-size: 13px;
  margin-bottom: 16px; display: flex; align-items: center; gap: 8px;
}
.alert-success { background: rgba(45,212,140,.1);  border: 1px solid rgba(45,212,140,.25); color: var(--success); }
.alert-error   { background: rgba(255,79,110,.1);  border: 1px solid rgba(255,79,110,.25); color: var(--danger);  }

/* ─── Page header ─── */
.page-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 22px; flex-wrap: wrap; gap: 10px;
}
.page-header h1 { font-size: 20px; font-weight: 700; }

/* ─── Filters ─── */
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 18px; }
.filters .form-control { width: auto; }

/* ─── Login page (standalone) ─── */
.login-page {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden; padding: 20px;
}
.login-orb {
  position: fixed; border-radius: 50%; filter: blur(80px); opacity: .25; pointer-events: none;
}
.login-orb-1 { width: 400px; height: 400px; background: radial-gradient(var(--accent),  transparent); top: -100px; left: -100px; }
.login-orb-2 { width: 300px; height: 300px; background: radial-gradient(var(--accent2), transparent); bottom: -80px; right: -80px; }
.login-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: 20px;
  padding: 40px; width: 100%; max-width: 400px; position: relative; z-index: 1;
}
.login-logo { text-align: center; margin-bottom: 32px; }
.login-logo .icon {
  width: 56px; height: 56px;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  border-radius: 16px; display: flex; align-items: center; justify-content: center;
  font-size: 26px; margin: 0 auto 12px;
}
.login-logo h1 { font-size: 20px; font-weight: 800; margin-bottom: 4px; }
.login-logo p  { font-size: 13px; color: var(--muted); }
.login-card .btn-primary { width: 100%; padding: 12px; margin-top: 8px;
  background: linear-gradient(135deg, var(--accent), var(--accent2)); }

/* ─── Mobile ─── */
@media (max-width: 768px) {
  :root { --sidebar-w: 100%; }
  .sidebar { position: relative; height: auto; border-right: none; border-bottom: 1px solid var(--border); }
  .sidebar-nav { display: flex; flex-wrap: wrap; gap: 4px; }
  .nav-group-label { width: 100%; }
  .topbar { position: relative; left: 0; }
  .main { margin-left: 0; margin-top: 0; padding: 16px; }
  .form-row { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
}
