/* ============================================================
   OTR Database — override ringan di atas tema Mazer (app.css)
   Mazer sudah memuat Bootstrap 5.3.3 + Bootstrap Icons + font Nunito.
   ============================================================ */
:root {
  --otr-primary: #435ebe;
  --otr-muted: #607080;
  --otr-line: #dee2e6;
  --otr-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 10px 30px -18px rgba(16, 24, 40, .18);
}

/* ---------- brand di sidebar ---------- */
.sidebar .logo a { display: flex; align-items: center; font-weight: 800; }
.brand-logo { max-height: 30px; max-width: 30px; border-radius: 8px; margin-right: 8px; }

/* ---------- kartu statistik ---------- */
.stat-card { transition: transform .15s ease, box-shadow .15s ease; }
.stat-card:hover { transform: translateY(-3px); }
.stat-icon {
  width: 48px; height: 48px; border-radius: 13px; flex: 0 0 48px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 1.35rem; color: #fff;
}
.grad-blue  { background: linear-gradient(135deg, #435ebe, #6f86e8); }
.grad-cyan  { background: linear-gradient(135deg, #0dcaf0, #41bbdd); }
.grad-green { background: linear-gradient(135deg, #198754, #57ca98); }
.grad-amber { background: linear-gradient(135deg, #ffc107, #ffb020); }
.stat-label { font-size: .76rem; color: var(--otr-muted); text-transform: uppercase; letter-spacing: .06em; font-weight: 700; }
.stat-value { font-size: 1.65rem; font-weight: 800; line-height: 1.15; letter-spacing: -.02em; color: #25396f; }
.stat-value small { font-size: .78rem; font-weight: 600; color: var(--otr-muted); }

/* ---------- tabel ---------- */
.table > thead th {
  font-size: .72rem; text-transform: uppercase; letter-spacing: .07em;
  color: var(--otr-muted); font-weight: 700; white-space: nowrap;
}
.harga { font-variant-numeric: tabular-nums; white-space: nowrap; font-weight: 700; }

/* badge jenis bernuansa lembut */
.badge.bg-primary { background: #e5ebff !important; color: #435ebe !important; font-weight: 700; }
.badge.bg-success { background: #d9f5e5 !important; color: #198754 !important; font-weight: 700; }

/* ---------- form & misc ---------- */
.form-label { font-size: .82rem; font-weight: 700; color: var(--otr-muted); }
.alert { border-radius: 12px; }
code { color: #435ebe; }
.detail-table td { padding: .55rem .25rem; }
.progress { border-radius: 999px; }

/* ---------- login ---------- */
.login-body {
  min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 1rem;
  background:
    radial-gradient(900px 500px at 85% -10%, rgba(67, 94, 190, .30), transparent 60%),
    radial-gradient(700px 500px at -10% 110%, rgba(65, 187, 221, .25), transparent 60%),
    linear-gradient(135deg, #f2f7ff 0%, #dbe4ff 100%);
}
.login-card { width: 100%; max-width: 400px; border: none; border-radius: 1rem; box-shadow: 0 30px 60px -20px rgba(67, 94, 190, .35); }
.login-brand {
  width: 58px; height: 58px; margin: 0 auto; border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #435ebe, #6f86e8);
  color: #fff; font-size: 1.6rem; box-shadow: 0 10px 24px -8px rgba(67, 94, 190, .6);
}

/* ---------- dark mode ---------- */
[data-bs-theme="dark"] .stat-value { color: #fff; }
[data-bs-theme="dark"] .badge.bg-primary { background: rgba(67, 94, 190, .30) !important; color: #a9bbff !important; }
[data-bs-theme="dark"] .badge.bg-success { background: rgba(25, 135, 84, .35) !important; color: #75d7a8 !important; }
[data-bs-theme="dark"] .login-body { background: linear-gradient(135deg, #141824 0%, #1f2a52 100%); }

/* ---------- smartphone: tabel menjadi kartu ---------- */
@media (max-width: 767.98px) {
  .table-card thead { display: none; }
  .table-card tr {
    display: block; border: 1px solid var(--otr-line); border-radius: 12px;
    margin: .6rem; padding: .35rem .2rem; background: #fff; box-shadow: var(--otr-shadow);
  }
  .table-card td { display: flex; justify-content: space-between; gap: 1rem; border: none !important; padding: .32rem .8rem; }
  .table-card td::before { content: attr(data-label); font-weight: 700; color: var(--otr-muted); font-size: .8rem; }
  [data-bs-theme="dark"] .table-card tr { background: #2b2d42; }
}

/* ---------- print ---------- */
@media print {
  .d-print-none, #sidebar, #main > header, footer, .page-heading { display: none !important; }
  body { background: #fff; }
  .card { box-shadow: none; }
}