/* ============================================================
   RIFID PINJAM — Design System v3 "Neon Ledger"
   Terinspirasi grass.io: lime neon + ink gelap + hard shadow
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Bricolage+Grotesque:opsz,wght@12..96,400;12..96,600;12..96,700;12..96,800&family=DM+Sans:opsz,wght@9..40,400;9..40,500;9..40,600;9..40,700&display=swap');

:root {
  --ink: #191A23;
  --ink-2: #2A2C38;
  --lime: #ABF600;
  --lime-deep: #89C000;
  --lime-soft: #F2FED1;
  --cyan-soft: #E9FDFF;
  --paper: #FFFFFF;
  --fog: #F7F7F5;
  --fog-2: #EFEEE9;
  --line: #E3E2DC;
  --muted: #6B6B78;
  --danger: #E24B4B;
  --danger-soft: #FFE5E5;
  --amber: #C98200;
  --amber-soft: #FFF3D6;
  --font-display: 'Bricolage Grotesque', 'Trebuchet MS', sans-serif;
  --font-body: 'DM Sans', 'Helvetica Neue', sans-serif;
  --r-sm: 10px;
  --r-md: 16px;
  --r-lg: 24px;
  --r-xl: 34px;
  --r-pill: 9999px;
  --shadow-sm: 2px 2px 0 var(--ink);
  --shadow: 4px 4px 0 var(--ink);
  --shadow-lg: 7px 7px 0 var(--ink);
  --side-w: 268px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  background: var(--fog);
  color: var(--ink);
  line-height: 1.55;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 9999; opacity: .028;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='4'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
}
h1, h2, h3, h4, .display { font-family: var(--font-display); letter-spacing: -.02em; line-height: 1.08; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }
button, input, select, textarea { font-family: inherit; }
::selection { background: var(--lime); color: var(--ink); }

.container { max-width: 1140px; margin: 0 auto; padding: 0 24px; }
.page { padding: 38px 0 80px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  background: var(--lime); color: var(--ink); border: 1px solid var(--ink);
  padding: 5px 13px; border-radius: var(--r-pill); box-shadow: var(--shadow-sm);
}
.hint { color: var(--muted); font-size: .84rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 11px 20px; border-radius: var(--r-pill); cursor: pointer;
  border: 1.5px solid var(--ink); background: var(--paper); color: var(--ink);
  font-size: .9rem; font-weight: 600; font-family: var(--font-body);
  box-shadow: var(--shadow-sm);
  transition: transform .12s cubic-bezier(.34,1.56,.64,1), box-shadow .12s ease, background .15s ease;
  white-space: nowrap; text-align: center;
}
.btn:hover { transform: translate(-1px,-2px); box-shadow: 5px 6px 0 var(--ink); }
.btn:active { transform: translate(2px,2px); box-shadow: 1px 1px 0 var(--ink); }
.btn-primary { background: var(--ink); color: #fff; }
.btn-primary:hover { background: var(--ink-2); }
.btn-lime { background: var(--lime); color: var(--ink); }
.btn-lime:hover { background: #BBFF1A; }
.btn-ghost { background: transparent; box-shadow: none; border-color: transparent; }
.btn-ghost:hover { background: var(--fog-2); box-shadow: none; transform: none; }
.btn-danger { background: var(--danger-soft); color: #A82A2A; border-color: #E9B4B4; box-shadow: 2px 2px 0 #E9B4B4; }
.btn-danger:hover { background: #FFD6D6; box-shadow: 4px 4px 0 #E9B4B4; }
.btn-sm { padding: 7px 14px; font-size: .8rem; }
.btn-lg { padding: 15px 30px; font-size: 1rem; }
.btn-block { width: 100%; }

/* ============ NAVBAR ============ */
.nav {
  position: sticky; top: 0; z-index: 60;
  background: rgba(247,247,245,.86); backdrop-filter: blur(14px) saturate(1.3);
  border-bottom: 1.5px solid var(--ink);
}
.nav .container { display: flex; align-items: center; justify-content: space-between; gap: 18px; height: 72px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-family: var(--font-display); font-weight: 800; font-size: 1.16rem; letter-spacing: -.03em; }
.brand img { height: 36px; width: auto; border-radius: 9px; border: 1.5px solid var(--ink); }
.nav-actions { display: flex; align-items: center; gap: 10px; }

/* ============ SIDEBAR ADMIN ============ */
.admin-shell { display: grid; grid-template-columns: var(--side-w) 1fr; min-height: 100vh; }
.side {
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
  background: var(--ink); color: #fff;
  border-right: 2px solid var(--ink);
  display: flex; flex-direction: column;
}
.side-brand {
  display: flex; align-items: center; gap: 11px; padding: 22px 22px 20px;
  font-family: var(--font-display); font-weight: 800; font-size: 1.05rem; letter-spacing: -.02em;
  border-bottom: 1.5px solid rgba(255,255,255,.12);
}
.side-brand img { height: 32px; width: auto; border-radius: 8px; background: #fff; padding: 2px; }
.side-brand .sb-tag {
  margin-left: auto; font-size: .62rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  background: var(--lime); color: var(--ink); padding: 3px 9px; border-radius: var(--r-pill);
}
.side-backdrop { position: fixed; inset: 0; background: rgba(25,26,35,.5); z-index: 110; display: none; }
.admin-main { min-width: 0; display: flex; flex-direction: column; }
.side-nav { padding: 16px 14px; display: flex; flex-direction: column; gap: 3px; flex: 1; }
.side-sec { font-size: .64rem; font-weight: 700; letter-spacing: .16em; text-transform: uppercase; color: rgba(255,255,255,.42); padding: 16px 10px 7px; }
.side-link {
  display: flex; align-items: center; gap: 11px; width: 100%;
  padding: 10px 13px; border-radius: var(--r-sm); border: 0; cursor: pointer;
  background: transparent; color: rgba(255,255,255,.76);
  font-size: .9rem; font-weight: 500; font-family: var(--font-body); text-align: left;
  transition: background .14s ease, color .14s ease, transform .14s ease;
}
.side-link:hover { background: rgba(255,255,255,.07); color: #fff; transform: translateX(3px); }
.side-link.active { background: var(--lime); color: var(--ink); font-weight: 700; box-shadow: 3px 3px 0 rgba(0,0,0,.55); }
.side-link .ic { font-size: 1.02rem; width: 20px; text-align: center; flex-shrink: 0; }
.side-link .badge-n { margin-left: auto; background: rgba(255,255,255,.14); padding: 1px 8px; border-radius: var(--r-pill); font-size: .7rem; font-weight: 700; }
.side-link.active .badge-n { background: var(--ink); color: var(--lime); }
.side-foot { padding: 16px; border-top: 1.5px solid rgba(255,255,255,.12); display: flex; flex-direction: column; gap: 9px; }
.side-foot .who { font-size: .8rem; color: rgba(255,255,255,.6); }
.side-foot .who b { color: #fff; display: block; font-size: .88rem; }

.admin-main { min-width: 0; background: var(--fog); }
.admin-top {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 34px; background: rgba(247,247,245,.9); backdrop-filter: blur(12px);
  border-bottom: 1.5px solid var(--ink);
}
.admin-top h1 { font-size: 1.5rem; font-weight: 800; }
.admin-top .crumb { font-size: .76rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 2px; }
.admin-body { padding: 30px 34px 70px; }
.view { display: none; animation: fadeUp .34s cubic-bezier(.22,1,.36,1); }
.view.active { display: block; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.side-toggle { display: none; }

/* ============ CARD & PANEL ============ */
.panel {
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r-lg);
  box-shadow: var(--shadow); overflow: hidden;
}
.panel-head {
  display: flex; align-items: center; justify-content: space-between; gap: 14px;
  padding: 17px 22px; border-bottom: 1.5px solid var(--ink); background: var(--paper);
}
.panel-head h2 { font-size: 1.06rem; font-weight: 700; }
.panel-head .sub { font-size: .8rem; color: var(--muted); margin-top: 1px; }
.panel-body { padding: 20px 22px; }
.panel + .panel { margin-top: 22px; }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(196px, 1fr)); gap: 16px; margin-bottom: 28px; }
.tile {
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r-md);
  padding: 17px 19px; box-shadow: var(--shadow-sm);
  transition: transform .16s cubic-bezier(.34,1.56,.64,1), box-shadow .16s ease;
}
.tile:hover { transform: translate(-2px,-3px); box-shadow: 6px 7px 0 var(--ink); }
.tile .lbl { font-size: .68rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.tile .num { font-family: var(--font-display); font-size: 1.58rem; font-weight: 700; margin-top: 6px; letter-spacing: -.03em; }
.tile.green { background: var(--lime-soft); }
.tile.green .num { color: var(--lime-deep); }
.tile.amber { background: var(--amber-soft); }
.tile.amber .num { color: var(--amber); }
.tile.red { background: var(--danger-soft); }
.tile.red .num { color: var(--danger); }
.tile.dark { background: var(--ink); color: #fff; }
.tile.dark .lbl { color: rgba(255,255,255,.5); }
.tile.dark .num { color: var(--lime); }

/* ============ TABEL ============ */
.table-card {
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r-lg);
  box-shadow: var(--shadow); overflow: hidden;
}
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .88rem; }
thead th {
  text-align: left; font-size: .68rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: var(--muted); padding: 13px 16px; background: var(--fog);
  border-bottom: 1.5px solid var(--ink); white-space: nowrap;
}
tbody td { padding: 13px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr { transition: background .12s ease; }
tbody tr:hover { background: var(--lime-soft); }
td.money { font-variant-numeric: tabular-nums; font-weight: 600; }
.table-card code { font-size: .76rem; background: var(--fog-2); padding: 2px 7px; border-radius: 6px; }

.chip {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 3px 11px; border-radius: var(--r-pill); font-size: .74rem; font-weight: 700;
  background: var(--fog-2); border: 1px solid var(--line); color: var(--ink-2);
}
.chip.green { background: var(--lime-soft); border-color: var(--lime-deep); color: var(--lime-deep); }
.chip.sm { font-size: .68rem; padding: 2px 9px; }
.status {
  display: inline-block; padding: 4px 12px; border-radius: var(--r-pill);
  font-size: .71rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em;
  border: 1.5px solid var(--ink); background: var(--fog-2);
}
.status.aktif { background: var(--cyan-soft); }
.status.lunas { background: var(--lime-soft); }
.status.telat { background: var(--danger-soft); color: #A82A2A; }

.progress { width: 92px; height: 8px; background: var(--fog-2); border-radius: 99px; overflow: hidden; border: 1px solid var(--line); }
.progress i { display: block; height: 100%; background: var(--lime); border-radius: 99px; transition: width .5s cubic-bezier(.22,1,.36,1); }
.row-actions { display: flex; gap: 6px; flex-wrap: wrap; }

/* ============ TABS ============ */
.tabs { display: inline-flex; gap: 4px; padding: 4px; background: var(--fog-2); border: 1.5px solid var(--ink); border-radius: var(--r-pill); flex-wrap: wrap; }
.tab {
  padding: 7px 15px; border-radius: var(--r-pill); border: 0; background: transparent;
  font-size: .82rem; font-weight: 600; cursor: pointer; color: var(--muted); font-family: var(--font-body);
  transition: background .14s ease, color .14s ease;
}
.tab:hover { color: var(--ink); }
.tab.active { background: var(--ink); color: #fff; box-shadow: 2px 2px 0 var(--lime); }

/* ============ FORM ============ */
.field { display: flex; flex-direction: column; gap: 6px; }
.field label { font-size: .78rem; font-weight: 700; color: var(--ink-2); }
input, select, textarea {
  padding: 10px 14px; border-radius: var(--r-sm); border: 1.5px solid var(--ink);
  background: var(--paper); color: var(--ink); font-size: .9rem; font-family: var(--font-body);
  transition: box-shadow .14s ease, transform .14s ease; width: 100%;
}
input:focus, select:focus, textarea:focus { outline: 0; box-shadow: 3px 3px 0 var(--lime-deep); transform: translate(-1px,-1px); }
input:disabled, select:disabled { opacity: .5; cursor: not-allowed; }
textarea { resize: vertical; min-height: 70px; }
select { cursor: pointer; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23191A23' d='M1 1l5 5 5-5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 13px center; padding-right: 34px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
.form-row-3 { grid-template-columns: repeat(3, 1fr); }
.form-error {
  display: none; background: var(--danger-soft); color: #A82A2A; border: 1.5px solid #E9B4B4;
  border-radius: var(--r-sm); padding: 10px 14px; font-size: .85rem; font-weight: 600;
}
.form-error.show { display: block; }
.form-row + .form-row, .field + .field { margin-top: 14px; }

/* ============ MODAL ============ */
.modal-back {
  position: fixed; inset: 0; background: rgba(25,26,35,.62); backdrop-filter: blur(6px);
  display: none; align-items: center; justify-content: center; z-index: 200; padding: 22px; overflow-y: auto;
}
.modal-back.show { display: flex; }
.modal {
  background: var(--paper); border: 2px solid var(--ink); border-radius: var(--r-xl);
  box-shadow: var(--shadow-lg); width: 100%; max-width: 660px; padding: 26px 28px;
  animation: pop .26s cubic-bezier(.34,1.56,.64,1); max-height: 92vh; overflow-y: auto;
}
@keyframes pop { from { opacity: 0; transform: scale(.94) translateY(14px); } to { opacity: 1; transform: none; } }
.modal h3 { font-size: 1.24rem; font-weight: 700; margin-bottom: 14px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 22px; padding-top: 18px; border-top: 1.5px solid var(--line); }

/* ============ PAGER ============ */
.pager { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; margin: 18px 2px 0; }
.pg-btn {
  min-width: 36px; height: 36px; padding: 0 13px; border-radius: var(--r-sm); cursor: pointer;
  border: 1.5px solid var(--ink); background: var(--paper); color: var(--ink);
  font-size: .85rem; font-weight: 700; font-family: var(--font-body);
  box-shadow: 2px 2px 0 var(--ink);
  transition: transform .12s cubic-bezier(.34,1.56,.64,1), box-shadow .12s ease, background .14s ease;
}
.pg-btn:hover:not(:disabled):not(.active) { background: var(--lime-soft); transform: translate(-1px,-1px); box-shadow: 4px 4px 0 var(--ink); }
.pg-btn.active { background: var(--ink); color: var(--lime); box-shadow: 2px 2px 0 var(--lime); }
.pg-btn:disabled { opacity: .35; cursor: default; box-shadow: none; }
.pg-ellipsis { color: var(--muted); padding: 0 3px; font-weight: 700; }
.pg-info { font-size: .74rem; font-weight: 700; margin-left: 8px; background: var(--lime-soft); color: var(--lime-deep); border: 1px solid var(--lime-deep); padding: 5px 12px; border-radius: var(--r-pill); }

/* ============ KARTU PAKET (landing) ============ */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(288px, 1fr)); gap: 20px; }
.pcard {
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r-xl);
  box-shadow: var(--shadow); padding: 22px; display: flex; flex-direction: column;
  transition: transform .18s cubic-bezier(.34,1.56,.64,1), box-shadow .18s ease;
}
.pcard:hover { transform: translate(-3px,-4px); box-shadow: 8px 9px 0 var(--ink); }
.pcard .pname { font-family: var(--font-display); font-weight: 700; font-size: 1.05rem; }
.ready-tag {
  font-size: .64rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  background: var(--lime); border: 1.5px solid var(--ink); padding: 3px 10px; border-radius: var(--r-pill);
}
.ready-tag.no { background: var(--fog-2); color: var(--muted); }
.pcard .amount { font-family: var(--font-display); font-size: 2.05rem; font-weight: 800; letter-spacing: -.04em; margin: 14px 0 4px; }
.pcard .meta { display: flex; gap: 7px; flex-wrap: wrap; margin-bottom: 12px; }
.pcard .req { font-size: .83rem; color: var(--muted); margin-bottom: 14px; }
.wa-btns { display: flex; gap: 8px; flex-wrap: wrap; margin-top: auto; }
.wa-btn {
  display: inline-flex; align-items: center; gap: 7px; padding: 9px 16px;
  border-radius: var(--r-pill); border: 1.5px solid var(--ink); background: var(--lime);
  color: var(--ink); font-size: .84rem; font-weight: 700; box-shadow: var(--shadow-sm);
  transition: transform .12s cubic-bezier(.34,1.56,.64,1), box-shadow .12s ease;
}
.wa-btn:hover { transform: translate(-1px,-2px); box-shadow: 4px 5px 0 var(--ink); }
.wa-num { font-size: .8rem; color: var(--muted); }

/* ============ MODAL & KAS ============ */
.modal-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.mc-card {
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm); padding: 18px 20px;
}
.mc-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-bottom: 10px; }
.mc-head .mc-bal { font-family: var(--font-display); font-size: 1.5rem; font-weight: 700; letter-spacing: -.03em; }
.mc-note { font-size: .78rem; color: var(--muted); }
.ledger-btn { font-size: .78rem; }

/* ============ HERO LANDING ============ */
.hero {
  position: relative; overflow: hidden;
  padding: 74px 0 84px;
  background:
    radial-gradient(900px 420px at 88% -8%, var(--lime-soft) 0%, transparent 62%),
    radial-gradient(680px 380px at 4% 104%, var(--cyan-soft) 0%, transparent 60%),
    var(--fog);
  border-bottom: 1.5px solid var(--ink);
}
.hero-wrap { display: flex; align-items: center; justify-content: space-between; gap: 34px; }
.hero-text { flex: 1 1 460px; min-width: 290px; }
.hero h1 { font-size: clamp(2.5rem, 5.4vw, 4.1rem); font-weight: 800; letter-spacing: -.045em; margin: 16px 0 0; }
.hero .sub { font-size: 1.06rem; color: var(--ink-2); margin-top: 16px; max-width: 46ch; }
.hero-cta { display: flex; gap: 11px; flex-wrap: wrap; margin-top: 26px; }
.hero-stats { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 34px; }
.hero-stats .stat {
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r-md);
  padding: 13px 18px; box-shadow: var(--shadow-sm); min-width: 132px;
}
.hero-stats .num { font-family: var(--font-display); font-size: 1.32rem; font-weight: 700; letter-spacing: -.03em; }
.hero-stats .lbl { font-size: .68rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--muted); margin-top: 2px; }
.hero-logo { flex: 0 0 auto; }
.hero-logo img { max-width: 340px; max-height: 280px; width: auto; height: auto; border-radius: var(--r-xl); border: 1.5px solid var(--ink); box-shadow: var(--shadow-lg); background: var(--paper); padding: 10px; }
.hero-logo-mobile { display: none !important; }

.section { padding: 62px 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 26px; flex-wrap: wrap; }
.section-head h2 { font-size: clamp(1.6rem, 3vw, 2.15rem); font-weight: 800; letter-spacing: -.035em; }
.section-head .hint { font-size: .84rem; }
.footer { border-top: 1.5px solid var(--ink); padding: 30px 0; background: var(--paper); }
.footer .container { display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap; font-size: .85rem; color: var(--muted); }
.badge {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: .74rem; font-weight: 700; letter-spacing: .06em;
  background: var(--lime); border: 1.5px solid var(--ink); padding: 6px 14px;
  border-radius: var(--r-pill); box-shadow: var(--shadow-sm);
}
.empty { color: var(--muted); text-align: center; padding: 30px; font-size: .9rem; }

/* ============ RIWAYAT / LIST ============ */
.hist { display: flex; flex-direction: column; gap: 8px; margin-top: 10px; }
.h-row { display: flex; justify-content: space-between; align-items: center; background: var(--fog); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 9px 13px; font-size: .86rem; gap: 12px; }
.h-row .when { color: var(--muted); font-size: .8rem; white-space: nowrap; }
#profitRows { display: flex; flex-direction: column; gap: 7px; }
#profitRows .h-row { background: var(--fog); border: 1px solid var(--line); border-radius: var(--r-sm); padding: 10px 14px; font-size: .88rem; }

/* ============ LOGIN ============ */
.login-card {
  width: 100%; max-width: 408px; margin: 9vh auto; background: var(--paper);
  border: 2px solid var(--ink); border-radius: var(--r-xl); box-shadow: var(--shadow-lg);
  padding: 32px 30px;
}
.login-card h1 { font-size: 1.6rem; font-weight: 800; margin-bottom: 6px; }
.login-card .field { margin-top: 15px; }

/* ============ TOAST ============ */
.toast {
  position: fixed; left: 50%; bottom: 26px; transform: translate(-50%, 20px);
  background: var(--ink); color: #fff; border: 1.5px solid var(--ink);
  padding: 12px 22px; border-radius: var(--r-pill); box-shadow: var(--shadow-lg);
  font-size: .88rem; font-weight: 600; opacity: 0; pointer-events: none;
  transition: opacity .22s ease, transform .22s cubic-bezier(.34,1.56,.64,1); z-index: 500;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.error { background: var(--danger); }

/* ============ LOGIN CAPTCHA ============ */
.captcha-row { display: flex; align-items: stretch; gap: 10px; }
.captcha-box {
  flex: 0 0 auto; width: 220px; height: 64px;
  border: 1.5px solid var(--ink); border-radius: var(--r-md);
  overflow: hidden; cursor: pointer; background: #f7f7f5;
  box-shadow: 2px 2px 0 var(--ink); position: relative;
  transition: transform .14s ease, box-shadow .14s ease;
}
.captcha-box:hover { transform: translate(-1px,-1px); box-shadow: 3px 3px 0 var(--ink); }
.captcha-box:active { transform: translate(1px,1px); box-shadow: 1px 1px 0 var(--ink); }
.captcha-box img { display: block; width: 100%; height: 100%; object-fit: cover; user-select: none; -webkit-user-drag: none; }
.captcha-box.loading img { opacity: .35; }
.captcha-row input {
  flex: 1 1 auto; min-width: 0;
  text-transform: uppercase; letter-spacing: .18em; font-weight: 700;
  font-family: var(--font-display);
}

/* ============ CLOUDFLARE TURNSTILE ============ */
.cf-turnstile { min-height: 65px; }
#cfTurnstile iframe { max-width: 100%; }
.captcha-turnstile-note { font-size: .72rem; color: var(--muted); margin-top: 6px; }

/* ============ RBAC: USER & HAK AKSES ============ */
.rbac-matrix { border: 1.5px solid var(--ink); border-radius: 12px; overflow: hidden; }
.rbac-matrix-row {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
  padding: 9px 12px; border-bottom: 1px solid rgba(25,26,35,.12);
}
.rbac-matrix-row:last-child { border-bottom: none; }
.rbac-matrix-row:nth-child(odd) { background: rgba(25,26,35,.025); }
.rbac-matrix-name { flex: 1 1 150px; min-width: 130px; font-weight: 600; font-size: .88rem; }
.rbac-matrix-row .rbac-sec {
  flex: 0 0 100%; font-size: .64rem; font-weight: 800; letter-spacing: .1em;
  text-transform: uppercase; color: var(--muted); padding-top: 4px;
}
.rbac-lvl {
  display: inline-flex; align-items: center; gap: 5px;
  border: 1.5px solid var(--ink); border-radius: 999px;
  padding: 3px 10px; font-size: .72rem; font-weight: 700;
  cursor: pointer; background: var(--paper); transition: transform .12s ease, background .12s ease;
  white-space: nowrap;
}
.rbac-lvl:hover { transform: translateY(-1px); }
.rbac-lvl input { margin: 0; accent-color: #191A23; }
.rbac-lvl.on { background: #ABF600; box-shadow: 2px 2px 0 var(--ink); }
.rbac-lvl.off { opacity: .5; }
.rbac-legend { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 10px; font-size: .74rem; color: var(--muted); }
.rbac-legend b { color: var(--ink); }
.rbac-radio {
  display: inline-flex; align-items: center; gap: 7px;
  border: 1.5px solid var(--ink); border-radius: 999px; padding: 6px 14px;
  font-size: .85rem; font-weight: 600; cursor: pointer; background: var(--paper);
}
.rbac-radio input { margin: 0; accent-color: #191A23; }
.rbac-user-cell { display: flex; align-items: center; gap: 8px; }
.rbac-badge {
  display: inline-block; font-size: .62rem; font-weight: 800; letter-spacing: .06em;
  text-transform: uppercase; padding: 2px 8px; border-radius: 999px;
  border: 1.5px solid var(--ink); background: #ABF600;
}
.rbac-badge.staff { background: #fff; }
.rbac-perm-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.rbac-tag {
  font-size: .66rem; padding: 2px 7px; border-radius: 999px;
  background: rgba(25,26,35,.07); border: 1px solid rgba(25,26,35,.16);
}
.rbac-tag.lv1 { opacity: .65; }
.rbac-tag.lv2 { background: #FFF3B0; }
.rbac-tag.lv3 { background: #ABF600; }

/* ============ DROPDOWN DENGAN SEARCH (form +Pinjaman Baru) ============ */
.ss { position: relative; }
.ss-control { position: relative; display: flex; align-items: center; }
.ss-search {
  width: 100%;
  padding-right: 34px;
}
.ss-clear {
  position: absolute; right: 6px;
  width: 24px; height: 24px; line-height: 1;
  border: 0; border-radius: 50%;
  background: rgba(25,26,35,.08); color: #191A23;
  font-size: 1.05rem; line-height: 22px; text-align: center;
  cursor: pointer; display: none;
}
.ss.open .ss-clear, .ss-search:focus + .ss-clear { display: block; }
.ss-list {
  position: absolute; z-index: 60; left: 0; right: 0; top: calc(100% + 4px);
  max-height: 240px; overflow-y: auto;
  background: #fff; border: 1px solid rgba(25,26,35,.16);
  border-radius: 12px; box-shadow: 0 14px 34px rgba(25,26,35,.14);
  padding: 5px;
}
.ss-opt {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 11px; border-radius: 9px; cursor: pointer; font-size: .9rem;
}
.ss-opt:hover, .ss-opt.hl { background: rgba(171,246,0,.20); }
.ss-opt.sel { background: #ABF600; font-weight: 600; }
.ss-opt-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ss-opt-wa { font-size: .74rem; color: rgba(25,26,35,.55); flex-shrink: 0; }
.ss-opt.sel .ss-opt-wa { color: rgba(25,26,35,.7); }
.ss-empty { padding: 12px 11px; font-size: .86rem; color: rgba(25,26,35,.55); text-align: center; }

/* ============ RBAC: MENU SUPER-ADMIN-ONLY ============ */
.rbac-super-only {
  opacity: .72;
  background: repeating-linear-gradient(
    135deg, rgba(25,26,35,.03), rgba(25,26,35,.03) 6px,
    rgba(25,26,35,.06) 6px, rgba(25,26,35,.06) 12px);
}
.rbac-super-badge {
  display: inline-block; margin-left: 6px;
  font-size: .62rem; font-weight: 700; letter-spacing: .02em;
  padding: 2px 7px; border-radius: 999px;
  background: #191A23; color: #ABF600; white-space: nowrap;
}
.rbac-locked {
  display: flex; align-items: center; justify-content: center;
  opacity: .4; cursor: not-allowed; pointer-events: none;
}

/* ============ RESPONSIF ============ */
@media (max-width: 1024px) {
  .admin-shell { grid-template-columns: 1fr; }
  .side {
    position: fixed; left: 0; top: 0; width: 282px; z-index: 120;
    transform: translateX(-102%); transition: transform .26s cubic-bezier(.22,1,.36,1);
  }
  .side.open { transform: none; box-shadow: 12px 0 40px rgba(0,0,0,.3); }
  .side-toggle { display: inline-flex; }
  .admin-top { padding: 14px 20px; }
  .admin-body { padding: 22px 20px 60px; }
  .side-backdrop.show { display: block; }
}
/* ============ NAVBAR BURGER (mobile) ============ */
.nav-burger {
  display: none; width: 44px; height: 44px; padding: 0;
  flex-direction: column; align-items: center; justify-content: center; gap: 5px;
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: 12px;
  cursor: pointer; flex-shrink: 0; box-shadow: 2px 2px 0 var(--ink);
  transition: transform .16s ease, box-shadow .16s ease;
}
.nav-burger span {
  display: block; width: 20px; height: 2.5px; border-radius: 99px;
  background: var(--ink); transition: transform .24s cubic-bezier(.22,1,.36,1), opacity .18s ease;
}
.nav-burger:hover { transform: translate(-1px,-1px); box-shadow: 3px 3px 0 var(--ink); }
.nav-burger:active { transform: translate(1px,1px); box-shadow: 1px 1px 0 var(--ink); }
.nav-burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.nav-burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

@media (max-width: 760px) {
  /* --- Navbar mobile: hamburger (3 garis) + dropdown --- */
  .nav .container { height: 64px; gap: 12px; }
  .nav-burger { display: flex; }
  .nav-actions {
    position: absolute; left: 0; right: 0; top: 100%;
    display: none; flex-direction: column; align-items: stretch; gap: 8px;
    padding: 14px 18px 18px;
    background: var(--paper); border-bottom: 1.5px solid var(--ink);
    box-shadow: 0 14px 28px rgba(17,19,24,.14);
  }
  .nav-actions.open { display: flex; }
  .nav-actions .btn { width: 100%; justify-content: center; padding: 11px 14px; font-size: .92rem; }

  .hero-wrap { flex-direction: column; align-items: flex-start; }
  .hero-logo { display: none !important; }
  .hero-logo-mobile { display: block !important; text-align: center; width: 100%; margin: 18px 0 4px; }
  .hero-logo-mobile img { max-width: 240px; width: 62%; border-radius: var(--r-lg); border: 1.5px solid var(--ink); box-shadow: var(--shadow); background: var(--paper); padding: 8px; margin: 0 auto; display: block; }
  .form-row, .form-row-3 { grid-template-columns: 1fr; }
  .container { padding: 0 18px; }
  .hero { padding: 48px 0 58px; }
  .panel-body { padding: 16px; }
}

/* ============ TOOLBAR / FILTER BAR ============ */
.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 16px; flex-wrap: wrap; }
.toolbar h2 { font-size: 1.12rem; font-weight: 700; }
.filter-bar { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.filter-bar input, .filter-bar select { width: auto; min-width: 150px; }
.filter-bar input[type="search"], .filter-bar input { min-width: 190px; }

/* ============ NAVIGASI VIEW (multi-page) ============ */
.view-title { display: none; }
.view-head { margin-bottom: 22px; }
.view-head h2 { font-size: 1.5rem; font-weight: 800; letter-spacing: -.03em; }
.view-head p { color: var(--muted); font-size: .9rem; margin-top: 4px; }

/* ============ LAPORAN ============ */
.report-meta { font-size: .88rem; color: var(--ink-2); background: var(--fog); border: 1.5px solid var(--ink); border-radius: var(--r-md); padding: 11px 16px; }
.report-meta b { font-family: var(--font-display); }
#reportRows td { font-size: .88rem; }
#reportRows td.num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }

/* ============ RICH TEXT TOOLBAR ============ */
.rt-wrap { border: 1.5px solid var(--line); border-radius: var(--r-md); overflow: hidden; background: var(--paper); transition: border-color .15s ease; }
.rt-wrap:focus-within { border-color: var(--ink); box-shadow: 0 0 0 3px var(--lime-soft); }
.rt-toolbar {
  display: flex; align-items: center; gap: 3px; flex-wrap: wrap;
  padding: 7px 9px; background: var(--fog); border-bottom: 1px solid var(--line);
}
.rt-btn {
  min-width: 30px; height: 30px; padding: 0 7px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid transparent; border-radius: 8px; background: transparent;
  cursor: pointer; color: var(--ink); font-size: .84rem; font-weight: 700;
  font-family: var(--font-body); transition: background .12s ease, border-color .12s ease, transform .12s ease;
}
.rt-btn:hover { background: var(--paper); border-color: var(--line); transform: translateY(-1px); }
.rt-btn.on { background: var(--lime); border-color: var(--ink); box-shadow: 2px 2px 0 var(--ink); }
.rt-b { font-weight: 900; }
.rt-i { font-style: italic; font-family: Georgia, serif; }
.rt-u { text-decoration: underline; }
.rt-sub { font-size: .72rem; vertical-align: sub; }
.rt-sup { font-size: .72rem; vertical-align: super; }
.rt-bullet { letter-spacing: -.05em; }
.rt-num { font-variant-numeric: tabular-nums; }
.rt-roman { font-family: Georgia, serif; font-style: italic; }
.rt-clear { opacity: .7; }
.rt-editor {
  min-height: 110px; max-height: 320px; overflow-y: auto; padding: 12px 14px;
  font-size: .92rem; line-height: 1.65; color: var(--ink); outline: none;
}
.rt-editor:empty::before { content: attr(data-placeholder); color: var(--muted); }
.rt-editor ul, .rt-editor ol { margin: 6px 0; padding-left: 22px; }
.rt-editor li { margin: 2px 0; }
.rt-editor ol[type="I"] { list-style-type: upper-roman; }
.rt-editor b, .rt-editor strong { font-weight: 800; }
.rt-editor u { text-decoration: underline; }
.rt-editor sub { font-size: .78em; vertical-align: sub; }
.rt-editor sup { font-size: .78em; vertical-align: super; }

/* ============ PANDUAN CARA AJUKAN (landing) ============ */
.step-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(258px, 1fr)); gap: 18px; }
.step-item {
  background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r-lg);
  box-shadow: var(--shadow); padding: 20px 22px; position: relative;
}
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: var(--r-pill);
  background: var(--lime); border: 1.5px solid var(--ink);
  font-family: var(--font-display); font-weight: 800; font-size: 1.02rem;
  box-shadow: var(--shadow-sm); margin-bottom: 12px;
}
.step-item h3 { font-family: var(--font-display); font-size: 1.04rem; font-weight: 700; margin: 0 0 6px; }
.step-item p { font-size: .87rem; color: var(--ink-2); margin: 0; }
.step-item .step-body { font-size: .87rem; color: var(--ink-2); }
.step-item .step-body b, .step-item .step-body strong { color: var(--ink); }
#caraAjukanSteps .step-item { scroll-margin-top: 90px; }

/* ============ RICH TEXT TOOLBAR (Syarat & Ketentuan) ============ */
.rt-wrap { margin-top: 8px; border: 1.5px solid var(--ink); border-radius: var(--r-md); overflow: hidden; background: var(--paper); }
.rt-toolbar {
  display: flex; align-items: center; gap: 4px; flex-wrap: wrap;
  padding: 7px 9px; background: var(--fog); border-bottom: 1.5px solid var(--ink);
}
.rt-btn {
  min-width: 32px; height: 30px; padding: 0 8px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1.5px solid var(--ink); border-radius: 8px; background: var(--paper);
  font-size: .84rem; font-weight: 700; cursor: pointer; color: var(--ink);
  transition: transform .12s cubic-bezier(.34,1.56,.64,1), background .12s ease;
  font-family: var(--font-body);
}
.rt-btn:hover { background: var(--lime); transform: translate(-1px,-1px); }
.rt-btn.on { background: var(--lime); box-shadow: 2px 2px 0 var(--ink); }
.rt-btn.rt-b { font-weight: 900; }
.rt-btn.rt-i { font-style: italic; font-family: Georgia, serif; }
.rt-btn.rt-u { text-decoration: underline; }
.rt-btn.rt-sub { font-size: .74rem; }
.rt-btn.rt-sup { font-size: .74rem; }
.rt-btn.rt-clear { font-size: .95rem; }
.rt-editor {
  min-height: 110px; max-height: 280px; overflow-y: auto;
  padding: 12px 14px; font-size: .92rem; line-height: 1.6; outline: none;
}
.rt-editor:focus { background: #fff; }
.rt-editor ul, .rt-editor ol { margin: 6px 0; padding-left: 22px; }
.rt-editor li { margin: 2px 0; }
.rt-editor p { margin: 4px 0; }
.rt-editor:empty::before { content: 'Tulis syarat & ketentuan di sini…'; color: var(--muted); }

/* Rich text di landing page (kartu paket) */
.pcard .req { white-space: pre-line; }
.pcard .req ul, .pcard .req ol { margin: 6px 0; padding-left: 20px; }
.pcard .req li { margin: 2px 0; }
.pcard .req b, .pcard .req strong { font-weight: 800; }
.pcard .req i, .pcard .req em { font-style: italic; }
.pcard .req u { text-decoration: underline; }

/* ============ MENU CARA AJUKAN (kelola poin) ============ */
.step-list { display: flex; flex-direction: column; gap: 10px; }
.step-item {
  display: flex; gap: 11px; align-items: flex-start;
  background: var(--fog); border: 1.5px solid var(--line); border-radius: var(--r-md); padding: 12px 14px;
}
.step-num {
  flex: 0 0 auto; width: 30px; height: 30px; border-radius: 50%;
  background: var(--lime); border: 1.5px solid var(--ink); color: var(--ink);
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: .85rem;
}
.step-item textarea {
  flex: 1; min-height: 62px; font-size: .9rem; line-height: 1.5; resize: vertical;
}
.step-actions { display: flex; flex-direction: column; gap: 4px; }
.step-actions button {
  width: 30px; height: 26px; border-radius: 7px; border: 1.5px solid var(--ink);
  background: var(--paper); cursor: pointer; font-size: .8rem; font-weight: 700;
}
.step-actions button:hover { background: var(--lime); }
.step-actions button.del:hover { background: var(--danger); color: #fff; }

/* ============ CARA AJUKAN — baris poin di dashboard ============ */
.cara-row {
  display: flex; gap: 11px; align-items: flex-start;
  background: var(--fog); border: 1.5px solid var(--line); border-radius: var(--r-md);
  padding: 12px 14px; margin-bottom: 10px;
}
.cara-idx {
  flex: 0 0 auto; width: 30px; height: 30px; border-radius: 50%;
  background: var(--lime); border: 1.5px solid var(--ink); color: var(--ink);
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: .85rem;
}
.cara-fields { flex: 1; display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.cara-fields input { font-weight: 700; }
.cara-fields textarea { font-size: .88rem; line-height: 1.5; resize: vertical; }
.cara-actions { display: flex; flex-direction: column; gap: 4px; }
.cara-actions button { width: 32px; height: 27px; padding: 0; }

/* ============ TESTIMONI (landing) ============ */
.testi-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 20px; }
.testi-card { background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--r-xl); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; transition: transform .18s cubic-bezier(.34,1.56,.64,1), box-shadow .18s ease; }
.testi-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.testi-photo { position: relative; aspect-ratio: 1 / 1; background: var(--fog); border-bottom: 1.5px solid var(--ink); overflow: hidden; }
.testi-photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.testi-photo-empty { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; font-size: 2.4rem; color: var(--muted); background: linear-gradient(135deg, var(--fog), var(--paper)); }
.testi-name { position: absolute; left: 10px; bottom: 10px; background: rgba(17,19,24,.88); color: #fff; font-size: .74rem; font-weight: 700; padding: 4px 10px; border-radius: 999px; backdrop-filter: blur(4px); }
.testi-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; }
.testi-row { display: flex; align-items: baseline; gap: 8px; font-size: .84rem; }
.testi-key { color: var(--muted); font-weight: 600; min-width: 74px; flex-shrink: 0; }
.testi-val { color: var(--ink); font-weight: 700; word-break: break-word; }
.testi-empty { color: var(--muted); font-size: .82rem; font-style: italic; }

/* ============ TESTIMONI (admin) ============ */
.testi-admin-list { display: flex; flex-direction: column; gap: 12px; }
.testi-admin-row { display: flex; align-items: center; gap: 14px; padding: 12px; border: 1.5px solid var(--line); border-radius: var(--r-lg); background: var(--paper); }
.testi-admin-row img, .testi-admin-thumb { width: 68px; height: 68px; border-radius: 12px; object-fit: cover; flex-shrink: 0; background: var(--fog); border: 1.5px solid var(--line); display: flex; align-items: center; justify-content: center; font-size: 1.6rem; color: var(--muted); }
.testi-admin-info { flex: 1; min-width: 0; }
.testi-admin-name { font-weight: 800; color: var(--ink); font-size: .95rem; }
.testi-admin-meta { font-size: .8rem; color: var(--muted); margin-top: 3px; }
.testi-admin-acts { display: flex; gap: 6px; flex-shrink: 0; flex-wrap: wrap; justify-content: flex-end; }

