/* ============================================================================
   RT Digital — Tampilan Pengurus (v5 "Midnight Premium")

   Seluruh warna diambil dari assets/css/tokens.css.
   Jangan menulis nilai hex langsung di berkas ini — tambahkan token baru
   di tokens.css bila perlu, supaya mode terang & gelap tetap sinkron.
   ========================================================================== */

/* ============================================================ TATA LETAK */
html, body { height: 100%; }

.app-wrapper { display: flex; min-height: 100vh; }
.app-content { flex-grow: 1; min-width: 0; display: flex; flex-direction: column; }
.app-content > .container-fluid { flex-grow: 1; }

/* ============================================================== SIDEBAR */
.app-sidebar {
  width: 252px;
  flex-shrink: 0;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--rt-nav-bg);
  border-right: 1px solid var(--rt-nav-line);
  box-shadow: var(--rt-shadow-2);
}
.app-sidebar::-webkit-scrollbar { width: 4px; }
.app-sidebar::-webkit-scrollbar-thumb { background: rgba(255,255,255,.16); border: none; }

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: .7rem;
  color: #fff;
  font-weight: 800;
  font-size: 1rem;
  letter-spacing: -.01em;
  padding: 1.15rem 1.1rem 1rem;
  border-bottom: 1px solid var(--rt-nav-line);
  margin-bottom: .35rem;
}
.sidebar-brand i {
  width: 40px; height: 40px;
  flex-shrink: 0;
  border-radius: var(--rt-r-md);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem;
  color: var(--rt-gold-2);
  background: linear-gradient(160deg, rgba(255,255,255,.16), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.12);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.18);
}
.sidebar-brand-sub {
  font-size: .66rem;
  font-weight: 600;
  color: var(--rt-gold-2);
  letter-spacing: .1em;
  text-transform: uppercase;
  opacity: .85;
}

.app-sidebar .nav { gap: 1px; padding: .35rem .6rem !important; }

.app-sidebar .nav-link {
  position: relative;
  display: flex;
  align-items: center;
  color: var(--rt-nav-ink);
  padding: .6rem .75rem;
  border-radius: var(--rt-r-md);
  font-size: .875rem;
  font-weight: 500;
  transition: background var(--rt-transisi), color var(--rt-transisi);
}
.app-sidebar .nav-link i {
  width: 24px;
  flex-shrink: 0;
  font-size: 1.02rem;
  opacity: .9;
}
.app-sidebar .nav-link .badge { margin-left: auto; }

.app-sidebar .nav-link:hover {
  background: var(--rt-nav-hover);
  color: var(--rt-nav-ink-aktif);
}
.app-sidebar .nav-link.active {
  background: var(--rt-nav-aktif);
  color: var(--rt-nav-ink-aktif);
  font-weight: 600;
}
.app-sidebar .nav-link.active::before {
  content: '';
  position: absolute;
  left: -.6rem;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 22px;
  border-radius: 0 3px 3px 0;
  background: linear-gradient(180deg, var(--rt-gold-2), var(--rt-gold));
}
.app-sidebar .nav-link.active i { color: var(--rt-gold-2); opacity: 1; }

.sidebar-section-label {
  color: rgba(255, 255, 255, .38);
  font-size: .64rem;
  text-transform: uppercase;
  letter-spacing: .12em;
  font-weight: 700;
  padding: 1rem .75rem .35rem;
}

.sidebar-illustration { padding: .5rem .95rem 1.1rem; }
.sidebar-quote-box {
  position: relative;
  overflow: hidden;
  border-radius: var(--rt-r-lg);
  padding: .95rem 1rem;
  color: #fff;
  background: linear-gradient(150deg, rgba(255,255,255,.10), rgba(255,255,255,.03));
  border: 1px solid rgba(255,255,255,.10);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.12);
}
.sidebar-quote {
  color: rgba(255, 255, 255, .62);
  font-size: .72rem;
  line-height: 1.55;
  margin: .3rem 0 0;
}
.sidebar-quote-icon {
  position: absolute;
  right: 8px; bottom: 2px;
  font-size: 2.1rem;
  color: rgba(255, 255, 255, .09);
}

/* =============================================================== TOPBAR */
.content-topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--rt-glass);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--rt-line);
}
.content-topbar h5 { font-size: 1.08rem; margin-bottom: .1rem; }

.topbar-date {
  background: var(--rt-surface-3);
  border: 1px solid var(--rt-line-soft);
  border-radius: var(--rt-r-pill);
  padding: .42rem .95rem;
  font-size: .8rem;
  color: var(--rt-ink-2);
  align-items: center;
}
.topbar-rt-logo {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  object-fit: contain;
  padding: 3px;
  border-radius: var(--rt-r-md);
  background: var(--rt-surface);
  border: 1px solid var(--rt-line);
  box-shadow: var(--rt-shadow-1);
}
.topbar-bell {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--rt-surface-3);
  border: 1px solid var(--rt-line-soft);
  display: flex; align-items: center; justify-content: center;
  color: var(--rt-ink-2);
  font-size: 1rem;
  padding: 0;
  cursor: pointer;
}
.notif-menu { width:min(390px,calc(100vw - 24px)); max-height:480px; overflow:auto; border-color:var(--rt-line); }
.notif-item { border-bottom:1px solid var(--rt-line-soft); background:var(--rt-surface); }
.notif-item:hover,.notif-item.belum { background:var(--rt-surface-2); }
.notif-icon { width:34px;height:34px;border-radius:10px;display:inline-flex;align-items:center;justify-content:center;flex-shrink:0; }
.notif-icon.iuran { background:#dcfce7;color:#166534; }
.notif-icon.donasi { background:#fee2e2;color:#be123c; }
.notif-pesan { font-size:.72rem;white-space:normal;line-height:1.35; }
.notif-waktu { font-size:.65rem;margin-top:2px; }
.notif-belum { width:7px;height:7px;border-radius:50%;background:var(--rt-danger-2);margin-top:6px;flex-shrink:0; }
.notif-dot {
  position: absolute;
  top: -3px; right: -3px;
  background: var(--rt-danger-2);
  color: #fff;
  font-size: .62rem;
  font-weight: 700;
  min-width: 18px; height: 18px;
  border-radius: var(--rt-r-pill);
  display: flex; align-items: center; justify-content: center;
  padding: 0 4px;
  border: 2px solid var(--rt-surface);
}
.topbar-avatar-btn {
  display: flex; align-items: center;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--rt-r-pill);
  padding: .2rem .5rem .2rem .2rem;
  color: var(--rt-ink);
  transition: background var(--rt-transisi), border-color var(--rt-transisi);
}
.topbar-avatar-btn:hover {
  background: var(--rt-surface-3);
  border-color: var(--rt-line);
  color: var(--rt-ink);
}
.topbar-avatar-btn::after { color: var(--rt-ink-3); }
.avatar-circle {
  width: 38px; height: 38px;
  border-radius: 50%;
  background: linear-gradient(140deg, var(--rt-brand), var(--rt-brand-2));
  color: var(--rt-brand-ink);
  display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: .8rem;
  box-shadow: var(--rt-shadow-brand);
}

.app-footer {
  color: var(--rt-ink-3);
  font-size: .78rem;
  border-top: 1px solid var(--rt-line);
}

/* ======================================================== BANNER SAMBUTAN */
.welcome-banner {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  border-radius: var(--rt-r-xl);
  padding: 1.5rem 1.7rem;
  display: flex; align-items: center; gap: 1.15rem;
  color: #fff;
  background:
    radial-gradient(900px 300px at 88% -30%, rgba(217,180,95,.30), transparent 60%),
    linear-gradient(115deg, var(--rt-brand-deep) 0%, var(--rt-brand) 62%, var(--rt-brand-2) 128%);
  border: 1px solid rgba(255, 255, 255, .12);
  box-shadow: var(--rt-shadow-brand);
}
.welcome-banner::after {
  content: '';
  position: absolute; right: -60px; top: -90px;
  width: 280px; height: 280px;
  background: rgba(255, 255, 255, .07);
  border-radius: 50%;
  z-index: -1;
}
.welcome-banner h4 { color: #fff; letter-spacing: -.02em; }
.welcome-icon {
  width: 58px; height: 58px; flex-shrink: 0;
  border-radius: var(--rt-r-lg);
  background: rgba(255, 255, 255, .16);
  border: 1px solid rgba(255, 255, 255, .2);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.75rem; color: #fff;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.25);
}

/* ================================================================ KARTU */
.card {
  background-color: var(--rt-surface);
  border: 1px solid var(--rt-line);
  border-radius: var(--rt-r-lg);
  box-shadow: var(--rt-shadow-1);
  color: var(--rt-ink);
  transition: box-shadow var(--rt-transisi), transform var(--rt-transisi), border-color var(--rt-transisi);
}
.card:hover {
  box-shadow: var(--rt-shadow-2);
  border-color: var(--rt-line-strong);
}
.card-header {
  background-color: transparent !important;
  color: var(--rt-ink);
  border-bottom: 1px solid var(--rt-line);
  border-radius: var(--rt-r-lg) var(--rt-r-lg) 0 0 !important;
  font-size: .92rem;
  font-weight: 650;
  padding: .85rem 1.1rem;
}
.card-body { padding: 1.1rem; }

/* Kartu statistik */
.card-stat {
  border: 1px solid rgba(255, 255, 255, .13);
  border-radius: var(--rt-r-lg);
  color: #fff;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  box-shadow: var(--rt-shadow-2);
}
.card-stat:hover { transform: translateY(-2px); }
.card-stat::after {
  content: '';
  position: absolute; right: -26px; top: -26px;
  width: 110px; height: 110px;
  background: rgba(255, 255, 255, .10);
  border-radius: 50%;
  z-index: -1;
}
.card-stat .card-body { padding: 1.15rem; }
.card-stat .fs-4 { letter-spacing: -.02em; }
.stat-icon-circle {
  width: 42px; height: 42px;
  border-radius: var(--rt-r-md);
  background: rgba(255, 255, 255, .2);
  border: 1px solid rgba(255, 255, 255, .16);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.05rem;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.2);
}
.stat-sub { font-size: .73rem; opacity: .88; margin-top: .45rem; }
.opacity-85 { opacity: .85; }

.card-stat.bg-saldo   { background: linear-gradient(140deg, #065f46, #0d9668 70%, #10b981); }
.card-stat.bg-masuk   { background: linear-gradient(140deg, #17427f, #2563eb 70%, #3b82f6); }
.card-stat.bg-keluar  { background: linear-gradient(140deg, #8f2020, #c62828 70%, #ef4444); }
.card-stat.bg-program { background: linear-gradient(140deg, #8a5307, #c07d12 70%, #e3a53c); }
.card-stat.bg-ungu    { background: linear-gradient(140deg, #4c1d95, #6d28d9 70%, #8b5cf6); }

/* Kotak sorotan */
.highlight-box {
  background: var(--rt-brand-soft);
  border: 1px solid var(--rt-brand-line);
  border-radius: var(--rt-r-md);
  padding: .75rem .95rem;
  font-size: .85rem;
  color: var(--rt-ink);
}
.highlight-box .text-muted { color: var(--rt-ink-2) !important; }

/* Donat & legenda */
.donut-wrapper { position: relative; width: 148px; height: 148px; flex-shrink: 0; }
.donut-center {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  pointer-events: none;
}
.legend-dot {
  display: inline-block;
  width: 9px; height: 9px;
  border-radius: 50%;
  margin-right: 7px;
  vertical-align: 1px;
}
.legend-dot.bg-success { background: var(--rt-seri-1) !important; }
.legend-dot.bg-secondary { background: var(--rt-seri-3) !important; }

/* Transaksi */
.tx-icon {
  width: 38px; height: 38px;
  border-radius: var(--rt-r-md);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; font-size: .95rem;
}
.tx-in  { background: var(--rt-ok-soft); color: var(--rt-ok); }
.tx-out { background: var(--rt-danger-soft); color: var(--rt-danger); }
.min-w-0 { min-width: 0; }

.program-icon {
  width: 44px; height: 44px;
  border-radius: var(--rt-r-md);
  background: var(--rt-brand-soft);
  color: var(--rt-brand);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.1rem; flex-shrink: 0;
}

.pengumuman-icon {
  width: 38px; height: 38px;
  border-radius: var(--rt-r-md);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; font-size: .9rem; color: #fff;
}
.bg-icon-green  { background: linear-gradient(140deg, #0d9668, #34d399); }
.bg-icon-blue   { background: linear-gradient(140deg, #2563eb, #60a5fa); }
.bg-icon-orange { background: linear-gradient(140deg, #c07d12, #e3a53c); }

/* =============================================================== GALERI */
.gallery-thumb { height: 150px; object-fit: cover; }
.gallery-card { transition: transform var(--rt-transisi), box-shadow var(--rt-transisi); }
.gallery-card:hover { transform: translateY(-3px); box-shadow: var(--rt-shadow-2); }

/* ======================================================== ALARM DARURAT */
.alarm-active-card {
  border: 1px solid var(--rt-danger) !important;
  background: linear-gradient(140deg, var(--rt-danger-soft), transparent 60%);
}
.alarm-live-alert {
  border-left: 4px solid var(--rt-danger) !important;
  animation: alarmBannerPulse 1.8s ease-in-out infinite;
}
@keyframes alarmBannerPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, .30); }
  50%      { box-shadow: 0 0 0 9px rgba(239, 68, 68, 0); }
}
.alarm-pulse-icon {
  width: 62px; height: 62px;
  border-radius: 50%;
  background: var(--rt-danger-soft);
  color: var(--rt-danger);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.8rem;
  animation: alarmPulse 1.3s infinite;
  flex-shrink: 0;
}
@keyframes alarmPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, .38); }
  50%      { box-shadow: 0 0 0 13px rgba(239, 68, 68, 0); }
}

/* =============================================================== TABEL */
.table {
  --bs-table-bg: transparent;
  --bs-table-color: var(--rt-ink);
  --bs-table-border-color: var(--rt-line);
  margin-bottom: 0;
}
.table-responsive { border-radius: 0 0 var(--rt-r-lg) var(--rt-r-lg); }
.table thead th,
.table thead.table-light th {
  background-color: var(--rt-surface-2) !important;
  color: var(--rt-ink-2) !important;
  border-bottom: 1px solid var(--rt-line) !important;
  font-size: .72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  white-space: nowrap;
}
.table td, .table th { vertical-align: middle; border-color: var(--rt-line-soft); }
.table-hover > tbody > tr:hover > * {
  background-color: var(--rt-brand-soft);
  color: var(--rt-ink);
}
.table-secondary { --bs-table-bg: var(--rt-surface-3); --bs-table-color: var(--rt-ink-2); }
.table-success   { --bs-table-bg: var(--rt-ok-soft);  --bs-table-color: var(--rt-ink); }
.table-light     { --bs-table-bg: var(--rt-surface-2); --bs-table-color: var(--rt-ink-2); }

/* ==================================================== LENCANA & TOMBOL */
.badge { font-weight: 650; padding: .4em .7em; border-radius: var(--rt-r-sm); letter-spacing: .01em; }

.btn { border-radius: var(--rt-r-md); font-weight: 600; transition: all var(--rt-transisi); }
.btn:active { transform: translateY(1px); }
.btn-sm { border-radius: var(--rt-r-sm); }

.btn-success, .btn-primary {
  background: linear-gradient(140deg, var(--rt-brand-deep), var(--rt-brand));
  border: none;
  color: #fff;
  box-shadow: var(--rt-shadow-brand);
}
.btn-success:hover, .btn-primary:hover {
  background: linear-gradient(140deg, var(--rt-brand), var(--rt-brand-2));
  color: #fff;
}
.btn-danger {
  background: linear-gradient(140deg, #9b1c1c, var(--rt-danger-2));
  border: none;
  box-shadow: var(--rt-shadow-danger);
}
.btn-dark {
  background: linear-gradient(140deg, #1f2937, #111827);
  border: none;
  color: #fff;
}
.btn-outline-secondary {
  border-color: var(--rt-line-strong);
  color: var(--rt-ink-2);
}
.btn-outline-secondary:hover {
  background: var(--rt-surface-3);
  border-color: var(--rt-line-strong);
  color: var(--rt-ink);
}
.btn-light {
  background: var(--rt-surface-2);
  border-color: var(--rt-line);
  color: var(--rt-ink);
}
.btn-link { color: var(--rt-brand); }

/* =============================================== FORMULIR & DROPDOWN */
.form-control, .form-select {
  background-color: var(--rt-surface-inset);
  border: 1px solid var(--rt-line);
  color: var(--rt-ink);
  border-radius: var(--rt-r-md);
  transition: border-color var(--rt-transisi), box-shadow var(--rt-transisi);
}
.form-control:focus, .form-select:focus {
  background-color: var(--rt-surface);
  border-color: var(--rt-brand);
  box-shadow: 0 0 0 3px var(--rt-brand-soft);
  color: var(--rt-ink);
}
.form-control::placeholder { color: var(--rt-ink-3); }
.form-label { font-size: .82rem; font-weight: 600; color: var(--rt-ink-2); }
.form-text { color: var(--rt-ink-3); }
.input-group-text {
  background: var(--rt-surface-3);
  border-color: var(--rt-line);
  color: var(--rt-ink-2);
}
.form-check-input { background-color: var(--rt-surface-inset); border-color: var(--rt-line-strong); }
.form-check-input:checked { background-color: var(--rt-brand); border-color: var(--rt-brand); }

.dropdown-menu {
  background: var(--rt-surface);
  border: 1px solid var(--rt-line);
  border-radius: var(--rt-r-md);
  box-shadow: var(--rt-shadow-3);
  padding: .35rem;
}
.dropdown-item { border-radius: var(--rt-r-sm); color: var(--rt-ink); font-size: .88rem; }
.dropdown-item:hover { background: var(--rt-surface-3); color: var(--rt-ink); }

/* ============================================================== ALERTS */
.alert {
  border: 1px solid transparent;
  border-radius: var(--rt-r-md);
  color: var(--rt-ink);
}
.alert-warning { background-color: var(--rt-warn-soft);   border-color: var(--rt-warn);   color: var(--rt-ink); }
.alert-success { background-color: var(--rt-ok-soft);     border-color: var(--rt-ok);     color: var(--rt-ink); }
.alert-danger  { background-color: var(--rt-danger-soft); border-color: var(--rt-danger); color: var(--rt-ink); }
.alert-info    { background-color: var(--rt-info-soft);   border-color: var(--rt-info);   color: var(--rt-ink); }
.alert-secondary { background-color: var(--rt-surface-3); border-color: var(--rt-line); color: var(--rt-ink-2); }

/* ======================================================== LIST GROUP */
.list-group { --bs-list-group-bg: transparent; }
.list-group-item {
  background-color: transparent;
  border-color: var(--rt-line-soft);
  color: var(--rt-ink);
}
.list-group-item-action:hover { background-color: var(--rt-surface-2); color: var(--rt-ink); }

/* ================================================== WARNA TEKS UTILITAS */
.text-muted { color: var(--rt-ink-3) !important; }
.text-success { color: var(--rt-ok) !important; }
.text-danger  { color: var(--rt-danger) !important; }
.text-warning { color: var(--rt-warn) !important; }
.text-primary { color: var(--rt-info) !important; }
.bg-white { background-color: var(--rt-surface) !important; }
.bg-light { background-color: var(--rt-surface-2) !important; }
.border    { border-color: var(--rt-line) !important; }
.border-top, .border-bottom, .border-start, .border-end { border-color: var(--rt-line) !important; }
code { color: var(--rt-brand); background: var(--rt-brand-soft); padding: .1rem .35rem; border-radius: .3rem; }
hr { border-color: var(--rt-line); opacity: 1; }

.progress { background-color: var(--rt-surface-3); border-radius: var(--rt-r-pill); }
.progress-bar { background-color: var(--rt-brand); }

/* ========================================================= HALAMAN LOGIN */
.login-wrapper {
  min-height: 100vh;
  color: var(--app-ink);
  background-color: var(--app-bg);
  background-image: var(--app-bg-tint);
  background-attachment: fixed;
}
.login-card {
  border-radius: var(--rt-r-xl);
  border: 1px solid var(--app-line);
  background: var(--app-surface);
  box-shadow: var(--app-shadow-2);
  padding: 2rem !important;
}
.login-icon {
  width: 72px; height: 72px;
  border-radius: var(--rt-r-lg);
  background: linear-gradient(140deg, var(--app-accent-deep), var(--app-accent-2));
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-size: 1.9rem;
  margin: 0 auto 1.1rem;
  box-shadow: var(--app-shadow-accent);
  border: 1px solid rgba(255,255,255,.18);
}
.login-logo {
  width: 88px;
  height: 88px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.1rem;
  padding: 7px;
  border-radius: var(--rt-r-lg);
  background: var(--app-surface-2);
  border: 1px solid var(--app-line);
  box-shadow: var(--app-shadow-1);
}
.login-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.setting-logo-preview {
  width: 82px;
  height: 82px;
  object-fit: contain;
  padding: 5px;
  border-radius: var(--rt-r-md);
  background: var(--rt-surface);
  border: 1px solid var(--rt-line);
}
.login-btn {
  color: #fff;
  font-weight: 750;
  background: linear-gradient(135deg, var(--app-accent-deep), var(--app-accent));
  border: 0;
  padding-block: .72rem;
  border-radius: var(--rt-r-md);
  box-shadow: var(--app-shadow-accent);
}
.login-btn:hover,
.login-btn:focus { color: #fff; filter: brightness(1.06); }
.login-wrapper .text-white-50 { color: var(--app-ink-3) !important; }

/* ====================================================== LAYAR KECIL */
@media (max-width: 991.98px) {
  .app-sidebar {
    position: fixed;
    left: -252px;
    top: 0;
    height: 100vh;
    z-index: 1030;
    transition: left var(--rt-transisi);
  }
  .app-sidebar.show { left: 0; box-shadow: var(--rt-shadow-3); }
  .welcome-banner { padding: 1.15rem 1.2rem; }
  .welcome-banner h4 { font-size: 1.05rem; }
  .welcome-icon { width: 48px; height: 48px; font-size: 1.4rem; }
}


/* ============================================== TAUTAN DI DALAM KONTEN
   Bootstrap memberi tautan warna biru + garis bawah. Di sini tautan biasa
   memakai warna merek, tanpa garis bawah kecuali disentuh kursor — kecuali
   tautan yang memang punya gaya sendiri (tombol, menu samping, dsb).
   =================================================================== */
:where(a):not(.btn):not(.nav-link):not(.dropdown-item):not(.list-group-item):not(.text-reset):not(.text-white):not(.text-white-50):not(.page-link) {
  color: var(--rt-brand);
  text-decoration: none;
}
:where(a):not(.btn):not(.nav-link):not(.dropdown-item):not(.list-group-item):not(.text-reset):not(.text-white):not(.text-white-50):not(.page-link):hover {
  color: var(--rt-brand-2);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.welcome-banner a, .card-stat a, .alert a { color: inherit; }
.alert a { text-decoration: underline; text-underline-offset: 3px; }

/* ==================================== LENCANA NETRAL (mis. "Agustus 2026")
   .badge.bg-light + .text-dark bawaan Bootstrap tidak terbaca di mode gelap.
   =================================================================== */
.badge.bg-light,
.badge.bg-light.text-dark {
  background-color: var(--rt-surface-3) !important;
  color: var(--rt-ink-2) !important;
  border: 1px solid var(--rt-line) !important;
}
.badge.bg-secondary { background-color: var(--rt-surface-3) !important; color: var(--rt-ink-2) !important; }
.badge.bg-success-subtle { background-color: var(--rt-ok-soft) !important; }
.badge.bg-danger-subtle  { background-color: var(--rt-danger-soft) !important; }
.badge.bg-warning-subtle { background-color: var(--rt-warn-soft) !important; }
.badge.bg-info-subtle    { background-color: var(--rt-info-soft) !important; }
.text-success-emphasis { color: var(--rt-ok) !important; }
.text-danger-emphasis  { color: var(--rt-danger) !important; }
.text-warning-emphasis { color: var(--rt-warn) !important; }
.text-info-emphasis    { color: var(--rt-info) !important; }
.text-dark { color: var(--rt-ink) !important; }
.text-secondary { color: var(--rt-ink-2) !important; }
.text-white-50 { color: rgba(255,255,255,.62) !important; }

/* ================================== PILIHAN JENIS DARURAT (btn-check)
   Bootstrap mengisi tombol terpilih dengan warna solid bawaannya yang
   terlalu terang di mode gelap. Di sini state terpilih dibuat konsisten:
   latar lembut sewarna statusnya + garis tepi tegas.
   =================================================================== */
.btn-check + .btn { border-width: 1.5px; }
.btn-check:checked + .btn-outline-danger    { background: var(--rt-danger-soft); color: var(--rt-danger); border-color: var(--rt-danger); }
.btn-check:checked + .btn-outline-warning   { background: var(--rt-warn-soft);   color: var(--rt-warn);   border-color: var(--rt-warn); }
.btn-check:checked + .btn-outline-primary   { background: var(--rt-info-soft);   color: var(--rt-info);   border-color: var(--rt-info); }
.btn-check:checked + .btn-outline-info      { background: var(--rt-info-soft);   color: var(--rt-info);   border-color: var(--rt-info); }
.btn-check:checked + .btn-outline-success   { background: var(--rt-ok-soft);     color: var(--rt-ok);     border-color: var(--rt-ok); }
.btn-check:checked + .btn-outline-secondary { background: var(--rt-surface-3);   color: var(--rt-ink);    border-color: var(--rt-line-strong); }
.btn-check:checked + .btn { font-weight: 700; }

.btn-outline-danger  { color: var(--rt-danger); border-color: var(--rt-danger); }
.btn-outline-warning { color: var(--rt-warn);   border-color: var(--rt-warn); }
.btn-outline-primary { color: var(--rt-info);   border-color: var(--rt-info); }
.btn-outline-info    { color: var(--rt-info);   border-color: var(--rt-info); }
.btn-outline-success { color: var(--rt-ok);     border-color: var(--rt-ok); }
.btn-outline-danger:hover  { background: var(--rt-danger); color: #fff; }
.btn-outline-warning:hover { background: var(--rt-warn);   color: #fff; }
.btn-outline-primary:hover { background: var(--rt-info);   color: #fff; }
.btn-outline-info:hover    { background: var(--rt-info);   color: #fff; }
.btn-outline-success:hover { background: var(--rt-ok);     color: #fff; }

/* ================================================= DASHBOARD RINGKAS */
.rt-bank-dashboard { max-width:1320px; margin:0 auto; }
.rt-segmented { display:grid; grid-template-columns:repeat(3,1fr); gap:4px; max-width:520px; padding:5px; margin:0 auto 1.5rem; border-radius:var(--rt-r-pill); background:var(--rt-surface-2); border:1px solid var(--rt-line-soft); }
.rt-segmented a { padding:.62rem 1rem; border-radius:var(--rt-r-pill); text-align:center; color:var(--rt-ink-2); text-decoration:none; font-weight:700; font-size:.85rem; }
.rt-segmented a.active { background:var(--rt-brand); color:var(--rt-brand-ink); box-shadow:var(--rt-shadow-brand); }
.rt-dashboard-heading { display:flex; align-items:flex-end; justify-content:space-between; gap:1rem; margin-bottom:1rem; }
.rt-eyebrow { color:var(--rt-brand); font-size:.75rem; font-weight:800; text-transform:uppercase; letter-spacing:.08em; }
.rt-dashboard-grid { display:grid; grid-template-columns:minmax(0,1.65fr) minmax(280px,.75fr); gap:1rem; }
.rt-dashboard-main,.rt-dashboard-side { display:grid; gap:1rem; align-content:start; }
.rt-highlight-card,.rt-finance-card,.rt-balance-card,.rt-payment-card,.rt-list-card,.rt-quick-section { border:1px solid var(--rt-line); border-radius:var(--rt-r-xl); background:var(--rt-surface); box-shadow:var(--rt-shadow-1); }
.rt-highlight-card { min-height:210px; padding:1.55rem; display:flex; position:relative; overflow:hidden; background:linear-gradient(135deg,var(--rt-surface),var(--rt-brand-soft)); }
.rt-highlight-card::after { content:""; position:absolute; right:-70px; bottom:-110px; width:300px; height:300px; border-radius:50%; background:var(--rt-brand-soft); }
.rt-highlight-copy { position:relative; z-index:2; max-width:65%; }
.rt-highlight-date { display:inline-flex; margin-bottom:.7rem; color:var(--rt-ink-3); font-size:.78rem; font-weight:650; }
.rt-highlight-copy h3 { max-width:470px; font-size:1.45rem; line-height:1.25; margin-bottom:.6rem; }
.rt-highlight-copy p { color:var(--rt-ink-2); margin-bottom:1rem; }
.rt-highlight-link { color:var(--rt-brand); font-weight:750; font-size:.8rem; text-decoration:underline; text-underline-offset:3px; }
.rt-highlight-art { margin-left:auto; align-self:flex-end; position:relative; z-index:2; display:flex; align-items:flex-end; gap:.45rem; color:var(--rt-brand); }
.rt-highlight-art i:nth-child(1) { font-size:4.4rem; }.rt-highlight-art i:nth-child(2) { font-size:2.5rem; color:var(--rt-warn); }.rt-highlight-art i:nth-child(3) { font-size:3rem; color:var(--rt-brand-2); }
.rt-finance-card { padding:1.35rem; }
.rt-section-title { display:flex; justify-content:space-between; align-items:flex-start; gap:1rem; margin-bottom:1rem; }
.rt-section-title h5 { font-size:1rem; margin:0 0 .2rem; font-weight:800; }.rt-section-title p { font-size:.76rem; margin:0; color:var(--rt-ink-3); }
.rt-section-title > a { font-size:.78rem; color:var(--rt-brand); font-weight:750; text-decoration:none; white-space:nowrap; }
.rt-finance-summary { display:grid; grid-template-columns:1fr 1fr; margin:1.15rem 0 .45rem; }
.rt-finance-summary > div { display:grid; grid-template-columns:auto 1fr; column-gap:.45rem; padding:.2rem 1rem; }
.rt-finance-summary > div:first-child { border-right:1px solid var(--rt-line); padding-left:0; }
.rt-finance-summary small { color:var(--rt-ink-3); font-size:.72rem; }.rt-finance-summary strong { grid-column:2; color:var(--rt-ink); font-size:1.05rem; }
.rt-dot { width:9px; height:9px; border-radius:2px; margin-top:5px; }.rt-dot.masuk,.rt-bar.masuk { background:#12c99b; }.rt-dot.keluar,.rt-bar.keluar { background:#dd5d62; }
.rt-finance-difference { text-align:center; font-size:.88rem; margin:.5rem 0 1rem; }.rt-finance-difference.positif { color:var(--rt-ok); }.rt-finance-difference.negatif { color:var(--rt-danger); }
.rt-bars { height:175px; display:flex; justify-content:center; align-items:flex-end; gap:3.2rem; padding:0 1rem; border-bottom:1px solid var(--rt-line); }
.rt-bar-column { width:112px; height:100%; display:flex; flex-direction:column; justify-content:flex-end; align-items:center; gap:.45rem; }
.rt-bar { width:100%; max-height:135px; min-height:8px; border-radius:10px 10px 0 0; }.rt-bar-column span { font-size:.74rem; color:var(--rt-ink-2); white-space:nowrap; }
.rt-balance-card { padding:1.35rem; color:#fff; background:linear-gradient(135deg,var(--rt-brand-deep),var(--rt-brand)); border:none; }
.rt-balance-card span,.rt-balance-card small { display:block; opacity:.8; }.rt-balance-card strong { display:block; font-size:1.65rem; margin:.35rem 0 .65rem; }.rt-balance-card small { font-size:.72rem; line-height:1.4; }
.rt-payment-card { padding:1.1rem; display:flex; align-items:center; gap:1rem; }.rt-payment-card p { margin:.2rem 0 0; color:var(--rt-ink-3); font-size:.75rem; }
.rt-payment-ring { --value:0; width:68px; height:68px; border-radius:50%; flex-shrink:0; display:grid; place-items:center; background:conic-gradient(var(--rt-brand) calc(var(--value) * 1%),var(--rt-surface-3) 0); }
.rt-payment-ring::before { content:""; width:52px; height:52px; border-radius:50%; background:var(--rt-surface); grid-area:1/1; }.rt-payment-ring span { grid-area:1/1; z-index:1; font-size:.78rem; font-weight:800; }
.rt-mini-stats { display:grid; grid-template-columns:1fr 1fr; gap:.7rem; }.rt-mini-stats > div { padding:.9rem; border-radius:var(--rt-r-lg); border:1px solid var(--rt-line); background:var(--rt-surface); display:grid; grid-template-columns:auto 1fr; column-gap:.55rem; }
.rt-mini-stats i { grid-row:1/3; color:var(--rt-brand); font-size:1.1rem; }.rt-mini-stats strong { line-height:1; }.rt-mini-stats span { font-size:.7rem; color:var(--rt-ink-3); }
.rt-quick-section { margin-top:1rem; padding:1.25rem; }.rt-quick-grid { display:grid; grid-template-columns:repeat(8,minmax(74px,1fr)); gap:.75rem; }
.rt-quick-grid a { color:var(--rt-ink); text-decoration:none; text-align:center; font-size:.72rem; }.rt-quick-grid a span { width:58px; height:58px; border-radius:18px; display:grid; place-items:center; margin:0 auto .5rem; font-size:1.35rem; color:#102132; transition:transform .15s ease; }
.rt-quick-grid a:hover span { transform:translateY(-3px); }.rt-quick-grid .aqua { background:#75d7d0; }.rt-quick-grid .orange { background:#ff9a55; }.rt-quick-grid .blue { background:#8faaf5; }.rt-quick-grid .purple { background:#b7a2eb; }.rt-quick-grid .red { background:#f49291; }.rt-quick-grid .green { background:#80d7bb; }.rt-quick-grid .yellow { background:#f2cf6a; }.rt-quick-grid .outline { background:var(--rt-surface); border:1px solid var(--rt-line-strong); color:var(--rt-ink); }
.rt-list-card { padding:1.2rem; }.rt-activity-row { display:flex; align-items:center; gap:.75rem; padding:.75rem 0; border-top:1px solid var(--rt-line-soft); }
.rt-activity-row strong { display:block; font-size:.8rem; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }.rt-activity-row small { display:block; color:var(--rt-ink-3); font-size:.68rem; }.rt-activity-row > b { font-size:.76rem; white-space:nowrap; }
.rt-activity-icon { width:38px; height:38px; display:grid; place-items:center; border-radius:12px; flex-shrink:0; }.rt-activity-icon.masuk { background:var(--rt-ok-soft); color:var(--rt-ok); }.rt-activity-icon.keluar { background:var(--rt-danger-soft); color:var(--rt-danger); }.rt-activity-icon.info { background:var(--rt-info-soft); color:var(--rt-info); }
.rt-empty { padding:1.5rem; text-align:center; color:var(--rt-ink-3); font-size:.8rem; }
@media (max-width:1100px) { .rt-dashboard-grid { grid-template-columns:1fr; }.rt-dashboard-side { grid-template-columns:1fr 1fr; }.rt-mini-stats { grid-column:1/-1; grid-template-columns:repeat(4,1fr); }.rt-quick-grid { grid-template-columns:repeat(4,1fr); } }
@media (max-width:767px) { .rt-dashboard-heading { align-items:flex-start; }.rt-dashboard-heading .btn { padding:.45rem .6rem; font-size:.72rem; }.rt-highlight-card { min-height:190px; padding:1.1rem; }.rt-highlight-copy { max-width:76%; }.rt-highlight-copy h3 { font-size:1.15rem; }.rt-highlight-art i:nth-child(1) { font-size:3rem; }.rt-highlight-art i:nth-child(2) { display:none; }.rt-dashboard-side { grid-template-columns:1fr; }.rt-mini-stats { grid-template-columns:1fr 1fr; }.rt-finance-summary strong { font-size:.86rem; }.rt-bars { gap:2rem; }.rt-bar-column { width:82px; }.rt-quick-grid { grid-template-columns:repeat(4,1fr); }.rt-quick-grid a span { width:52px; height:52px; border-radius:16px; } }
