/* ============================================================
   KosManager - Custom Stylesheet
   Bootstrap 5 + Custom Components
   ============================================================ */

:root {
  --sidebar-width: 260px;
  --sidebar-bg: #1E293B;
  --sidebar-hover: #334155;
  --sidebar-active: #2563EB;
  --topbar-height: 60px;
  --primary: #2563EB;
  --primary-light: #DBEAFE;
  --success: #16A34A;
  --warning: #D97706;
  --danger: #DC2626;
  --body-bg: #F1F5F9;
  --card-shadow: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --card-shadow-hover: 0 4px 12px rgba(0,0,0,.12);
  --border-color: #E2E8F0;
  --text-muted-color: #64748B;
  --font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
}

/* ============ BASE ============ */
* { box-sizing: border-box; }

body {
  font-family: var(--font-family);
  background: var(--body-bg);
  color: #1E293B;
  overflow-x: hidden;
}

a { color: var(--primary); text-decoration: none; }
a:hover { color: #1D4ED8; }

/* ============ SIDEBAR ============ */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: var(--sidebar-width);
  background: var(--sidebar-bg);
  display: flex;
  flex-direction: column;
  z-index: 1040;
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  overflow-y: auto;
  overflow-x: hidden;
}

.sidebar-header {
  padding: 1.1rem 1.25rem;
  border-bottom: 1px solid rgba(255,255,255,.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  font-size: 1.2rem;
  font-weight: 700;
  color: #fff;
}

.sidebar-brand i { font-size: 1.4rem; color: var(--primary); }

.sidebar-close { padding: 0; line-height: 1; }

.sidebar-kos-info {
  padding: .6rem 1.25rem;
  background: rgba(255,255,255,.05);
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.sidebar-nav {
  list-style: none;
  padding: .5rem 0;
  margin: 0;
  flex: 1;
}

.nav-label {
  padding: .8rem 1.25rem .3rem;
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255,255,255,.35);
}

.sidebar-nav .nav-item > a {
  display: flex;
  align-items: center;
  gap: .7rem;
  padding: .6rem 1.25rem;
  color: rgba(255,255,255,.75);
  border-radius: .375rem;
  margin: .1rem .6rem;
  font-size: .9rem;
  transition: background .2s, color .2s;
}

.sidebar-nav .nav-item > a:hover {
  background: var(--sidebar-hover);
  color: #fff;
}

.sidebar-nav .nav-item.active > a {
  background: var(--sidebar-active);
  color: #fff;
  font-weight: 500;
}

.sidebar-nav .nav-item > a i { font-size: 1.05rem; flex-shrink: 0; }
.sidebar-nav .nav-item > a .badge { font-size: .7rem; }

.sidebar-footer {
  padding: 1rem 1.25rem;
  border-top: 1px solid rgba(255,255,255,.08);
  flex-shrink: 0;
}

/* ============ MAIN WRAPPER ============ */
.main-wrapper {
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  transition: margin-left .3s cubic-bezier(.4,0,.2,1);
}

/* ============ TOPBAR ============ */
.topbar {
  height: var(--topbar-height);
  background: #fff;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 1.25rem;
  position: sticky;
  top: 0;
  z-index: 1020;
  box-shadow: 0 1px 3px rgba(0,0,0,.05);
  flex-shrink: 0;
}

.topbar-left { display: flex; align-items: center; gap: .5rem; }
.topbar-right { display: flex; align-items: center; gap: .25rem; }

.topbar-toggle, .topbar-icon {
  color: #64748B;
  padding: .4rem .5rem;
  border: none;
  background: none;
  border-radius: .375rem;
  transition: background .2s, color .2s;
}

.topbar-toggle:hover, .topbar-icon:hover {
  background: var(--body-bg);
  color: #1E293B;
}

.topbar-user {
  color: #1E293B;
  background: none;
  border: none;
  padding: .3rem .5rem;
  border-radius: .5rem;
  transition: background .2s;
  text-decoration: none;
}

.topbar-user:hover { background: var(--body-bg); }

.mobile-menu-title {
  display: inline-block;
  font-size: 1rem;
  font-weight: 600;
  color: #1E293B;
  max-width: calc(100vw - 190px);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.breadcrumb { font-size: .85rem; }
.breadcrumb-item a { color: var(--text-muted-color); }
.breadcrumb-item.active { color: #1E293B; font-weight: 500; }

/* ============ AVATAR ============ */
.avatar-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: .85rem;
  flex-shrink: 0;
}

.avatar-circle img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

.tenant-photo-trigger {
  border: 0;
  padding: 0;
  cursor: zoom-in;
  overflow: hidden;
}

/* ============ NOTIFICATIONS ============ */
.notif-badge {
  position: absolute;
  top: 2px; right: 2px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--danger);
  color: #fff;
  font-size: .65rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  border: 2px solid #fff;
}

.notif-dropdown { width: 320px; border: 1px solid var(--border-color); box-shadow: var(--card-shadow-hover); }
.notif-header {
  padding: .75rem 1rem;
  border-bottom: 1px solid var(--border-color);
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.notif-body { max-height: 320px; overflow-y: auto; }
.notif-item {
  display: flex;
  align-items: flex-start;
  padding: .7rem 1rem;
  border-bottom: 1px solid #F8FAFC;
  transition: background .15s;
}
.notif-item:hover { background: var(--body-bg); }
.notif-item.unread { background: var(--primary-light); }
.notif-empty { padding: 2rem 1rem; text-align: center; color: var(--text-muted-color); }
.notif-empty i { font-size: 2rem; display: block; margin-bottom: .5rem; }

/* ============ PAGE CONTENT ============ */
.page-content {
  flex: 1;
  padding: 1.5rem;
  padding-bottom: 5rem;
}

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: .75rem;
}

.page-header h1 {
  font-size: 1.4rem;
  font-weight: 700;
  color: #1E293B;
  margin: 0;
}

.payment-header-actions {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
}

.payment-action-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 160px;
}

/* ============ CARDS ============ */
.card {
  border: 1px solid var(--border-color);
  border-radius: .75rem;
  box-shadow: var(--card-shadow);
  background: #fff;
}

.card-header {
  background: transparent;
  border-bottom: 1px solid var(--border-color);
  padding: 1rem 1.25rem;
  font-weight: 600;
}

/* ============ STAT CARDS ============ */
.stat-card {
  border-radius: .75rem;
  padding: 1.25rem;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 1rem;
  min-height: 124px;
  border: none;
  box-shadow: var(--card-shadow);
  transition: transform .2s, box-shadow .2s;
}

.stat-card:hover { transform: translateY(-2px); box-shadow: var(--card-shadow-hover); }

.stat-card.blue   { background: linear-gradient(135deg, #2563EB, #3B82F6); }
.stat-card.green  { background: linear-gradient(135deg, #16A34A, #22C55E); }
.stat-card.orange { background: linear-gradient(135deg, #D97706, #F59E0B); }
.stat-card.red    { background: linear-gradient(135deg, #DC2626, #EF4444); }
.stat-card.purple { background: linear-gradient(135deg, #7C3AED, #A78BFA); }
.stat-card.teal   { background: linear-gradient(135deg, #0D9488, #14B8A6); }

.stat-icon {
  width: 52px; height: 52px;
  border-radius: .6rem;
  background: rgba(255,255,255,.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  flex-shrink: 0;
}

.stat-info .stat-label { font-size: .8rem; opacity: .85; font-weight: 500; }
.stat-info .stat-value { font-size: 1.6rem; font-weight: 700; line-height: 1.2; }
.stat-info .stat-sub   { font-size: .75rem; opacity: .75; }
.stat-info {
  min-width: 0;
}

.stat-info .stat-value {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.stat-value-money {
  font-size: 1.1rem !important;
}

/* ============ TABLES ============ */
.table-responsive { border-radius: .5rem; overflow: hidden; }
.table { margin-bottom: 0; }
.table thead th {
  background: #F8FAFC;
  border-bottom: 2px solid var(--border-color);
  font-size: .82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--text-muted-color);
  padding: .85rem 1rem;
  white-space: nowrap;
}
.table tbody td { padding: .85rem 1rem; vertical-align: middle; font-size: .9rem; }
.table tbody tr { transition: background .15s; }
.table tbody tr:hover { background: #F8FAFC; }

/* ============ FORMS ============ */
.form-label { font-weight: 500; font-size: .88rem; margin-bottom: .3rem; }
.form-control, .form-select {
  border-color: var(--border-color);
  border-radius: .5rem;
  font-size: .9rem;
  padding: .5rem .8rem;
  transition: border-color .2s, box-shadow .2s;
}
.form-control:focus, .form-select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37,99,235,.15);
}
.input-group-text {
  background: #F8FAFC;
  border-color: var(--border-color);
  color: var(--text-muted-color);
  border-radius: .5rem;
}

/* ============ BUTTONS ============ */
.btn {
  font-size: .88rem;
  font-weight: 500;
  border-radius: .5rem;
  transition: all .2s;
}
.btn-primary { background: var(--primary); border-color: var(--primary); }
.btn-primary:hover { background: #1D4ED8; border-color: #1D4ED8; }

.btn-action {
  padding: .25rem .55rem;
  font-size: .82rem;
  border-radius: .375rem;
}

/* ============ BADGES ============ */
.badge { font-size: .75rem; font-weight: 500; padding: .35em .65em; border-radius: .35rem; }

/* ============ WHATSAPP DUE TABLE ============ */
.wa-due-card .card-header {
  background: linear-gradient(90deg, #F8FAFC 0%, #FFFFFF 100%);
}

.wa-due-table tbody td {
  vertical-align: top;
}

.wa-row-preview {
  min-width: 320px;
  max-width: 560px;
  max-height: 110px;
  overflow: auto;
  background: #F5F1EB;
  border: 1px solid #E6DED3;
  border-radius: .55rem;
  padding: .65rem .75rem;
  white-space: pre-line;
  font-size: .83rem;
  color: #1E293B;
}

.wa-main-preview {
  min-height: 170px;
  max-height: 260px;
  overflow-y: auto;
  white-space: pre-line;
  overflow-wrap: anywhere;
}

.wa-due-card .table-responsive {
  overflow-x: auto;
}

.wa-due-description {
  max-width: 560px;
}

.wa-mobile-status,
.wa-mobile-phone,
.wa-mobile-history {
  display: none;
}

.wa-mobile-room {
  margin-left: .8rem;
}

.wa-mobile-due {
  margin-left: .8rem;
}

.wa-due-table {
  min-width: 760px;
}

.wa-due-table th,
.wa-due-table td {
  white-space: nowrap;
}

.wa-status-overdue {
  background: #DC3545;
  color: #fff;
}

.wa-status-today {
  background: #FFC107;
  color: #111827;
}

.wa-status-soon {
  background: #F59E0B;
  color: #111827;
}

/* ============ KAMAR GRID ============ */
.kamar-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 1rem; }
.kamar-card {
  border: 1px solid var(--border-color);
  border-radius: .75rem;
  overflow: hidden;
  transition: transform .2s, box-shadow .2s;
  cursor: pointer;
  background: #fff;
}
.kamar-card:hover { transform: translateY(-2px); box-shadow: var(--card-shadow-hover); }
.kamar-card.terisi  { border-left: 4px solid var(--primary); }
.kamar-card.tersedia { border-left: 4px solid var(--success); }
.kamar-card.perbaikan { border-left: 4px solid var(--warning); }
.kamar-img { height: 130px; object-fit: cover; width: 100%; background: #F1F5F9; display: flex; align-items: center; justify-content: center; color: #CBD5E1; font-size: 3rem; }
.kamar-img img { width: 100%; height: 130px; object-fit: cover; }
.kamar-body { padding: .8rem 1rem; }
.kamar-number { font-size: 1.1rem; font-weight: 700; color: #1E293B; }
.kamar-type { font-size: .78rem; color: var(--text-muted-color); }
.kamar-price { font-size: .95rem; font-weight: 600; color: var(--primary); margin-top: .2rem; }

/* ============ PAYMENT RECEIPT ============ */
@media print {
  .no-print { display: none !important; }
  .kwitansi { max-width: 100%; margin: 0; }
  body { background: white; }
}

/* ============ SIDEBAR OVERLAY ============ */
.sidebar-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 1039;
  display: none;
  opacity: 0;
  transition: opacity .3s;
}
.sidebar-overlay.show { display: block; opacity: 1; }

/* ============ BOTTOM NAVIGATION ============ */
.bottom-nav {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  height: 60px;
  background: #fff;
  border-top: 1px solid var(--border-color);
  z-index: 1030;
  justify-content: space-around;
  align-items: center;
  box-shadow: 0 -2px 8px rgba(0,0,0,.06);
}

.bottom-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  color: var(--text-muted-color);
  font-size: .65rem;
  font-weight: 500;
  padding: .4rem;
  border-radius: .4rem;
  transition: color .2s;
  min-width: 48px;
  text-align: center;
  text-decoration: none;
}

.bottom-nav-item i { font-size: 1.2rem; }
.bottom-nav-item.active { color: var(--primary); }

/* ============ RESPONSIVE ============ */
@media (max-width: 991.98px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.show { transform: translateX(0); }
  .main-wrapper { margin-left: 0; }
  .page-content { padding: 1rem; padding-bottom: 80px; }
}

@media (max-width: 767.98px) {
  .stat-card {
    padding: 1rem;
    flex-direction: column;
    align-items: flex-start;
    gap: .75rem;
  }
  .stat-info {
    width: 100%;
  }
  .stat-info .stat-label,
  .stat-info .stat-value,
  .stat-info .stat-sub {
    overflow-wrap: anywhere;
    word-break: break-word;
  }
  .stat-info .stat-value { font-size: 1.3rem; }
  .kamar-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
  .page-header h1 { display: none; }
  .mobile-menu-title { font-size: .95rem; max-width: calc(100vw - 170px); }

  /* Mobile: full-width only for main actions, keep table/small controls compact */
  .page-content .btn:not(.btn-sm):not(.btn-action) {
    width: 100%;
  }

  .page-content .btn:not(.btn-sm):not(.btn-action) + .btn:not(.btn-sm):not(.btn-action) {
    margin-top: .5rem;
    margin-left: 0 !important;
  }

  .payment-header-actions {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: .5rem;
  }

  .payment-action-btn {
    width: 100%;
    min-width: 0;
    margin: 0 !important;
  }

  .payment-action-btn:last-child {
    grid-column: 1 / -1;
  }

  .filter-bar {
    padding: .75rem;
    gap: .5rem;
  }

  .filter-controls {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .5rem;
  }

  .filter-controls .form-select {
    min-width: 0;
  }

  .filter-search-box {
    width: 100%;
    max-width: none;
    margin-left: 0;
  }

  .page-content .input-group .btn {
    width: auto;
    margin-top: 0;
    margin-left: 0 !important;
  }

  .table-responsive { overflow: visible; }
  .wa-due-card .table-responsive { overflow: visible; }
  .table.mobile-card-ready { border-collapse: separate; border-spacing: 0; }
  .table.mobile-card-ready thead { display: none; }
  .table.mobile-card-ready,
  .table.mobile-card-ready tbody,
  .table.mobile-card-ready tr,
  .table.mobile-card-ready td {
    display: block;
    width: 100%;
  }

  .table.mobile-card-ready tbody tr {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: .75rem;
    box-shadow: var(--card-shadow);
    margin-bottom: .75rem;
    overflow: hidden;
  }

  .table.mobile-card-ready tbody td {
    border: 0;
    border-bottom: 1px dashed #E2E8F0;
    padding: .7rem .9rem !important;
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: .8rem;
    text-align: right;
    white-space: normal;
  }

  .table.mobile-card-ready tbody td:last-child {
    border-bottom: 0;
  }

  .table.mobile-card-ready tbody td::before {
    content: attr(data-label);
    color: var(--text-muted-color);
    font-size: .78rem;
    font-weight: 600;
    letter-spacing: .02em;
    text-align: left;
    text-transform: uppercase;
    flex: 0 0 42%;
  }

  .table.mobile-card-ready tbody td[data-label=""]::before {
    display: none;
  }

  /* Penyewa specific mobile card arrangement */
  .table.table-penyewa.mobile-card-ready tbody td:first-child {
    display: none;
  }

  .table.table-penyewa.mobile-card-ready tbody td:nth-child(2) {
    padding: .9rem !important;
    border-bottom: 1px solid var(--border-color);
    background: #F8FAFC;
    text-align: left;
    display: block;
  }

  .table.table-penyewa.mobile-card-ready tbody td:nth-child(2)::before {
    display: none;
  }

  .table.table-penyewa.mobile-card-ready tbody td.penyewa-status-cell {
    display: none;
  }

  .table.table-penyewa.mobile-card-ready tbody td {
    justify-content: flex-start;
    text-align: left;
  }

  .table.table-penyewa.mobile-card-ready tbody td::before {
    flex: 0 0 42%;
    text-align: left;
    padding-right: .55rem;
    letter-spacing: 0;
    text-transform: none;
    content: attr(data-label);
    color: var(--text-muted-color);
    font-weight: 600;
  }

  .table.table-penyewa.mobile-card-ready tbody td .mobile-cell-value {
    display: inline-flex;
    align-items: flex-start;
    gap: .35rem;
    min-width: 0;
  }

  .table.table-penyewa.mobile-card-ready tbody td .mobile-cell-value::before {
    content: ":";
    color: var(--text-muted-color);
    font-weight: 600;
    flex-shrink: 0;
  }

  .table.table-penyewa.mobile-card-ready tbody td[data-label=""]::before {
    display: none;
    content: "";
  }

  .table.table-penyewa.mobile-card-ready tbody td:last-child {
    text-align: left;
  }

  .table.table-penyewa.mobile-card-ready tbody td:last-child .btn {
    margin-bottom: .3rem;
  }

  .wa-row-preview {
    min-width: 0;
    width: 100%;
    max-width: 100%;
  }

  .wa-due-card .card-header {
    align-items: flex-start !important;
    padding: 1rem;
  }

  .wa-due-card .card-header > div:first-child {
    min-width: 0;
  }

  .wa-due-description {
    line-height: 1.35;
  }

  .wa-due-filter {
    flex-shrink: 0;
  }

  .wa-due-table {
    min-width: 0;
    padding: 0 .9rem .9rem;
  }

  .wa-due-table tbody tr {
    margin: 0 0 .8rem;
    border-color: #F43F5E;
    box-shadow: none;
  }

  .wa-due-table tbody tr:last-child {
    margin-bottom: 0;
  }

  .wa-due-table tbody td {
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .wa-due-table tbody td.wa-tenant-cell {
    display: block;
    padding: 1rem !important;
    background: #F8FAFC;
    border-bottom: 1px solid var(--border-color);
    text-align: left;
  }

  .wa-due-table tbody td.wa-tenant-cell::before,
  .wa-due-table tbody td.wa-action-cell::before {
    display: none;
  }

  .wa-due-table .wa-tenant-cell > .fw-600 {
    display: inline-block;
    font-size: 1rem;
  }

  .wa-mobile-phone,
  .wa-mobile-history {
    display: block;
    margin-top: .55rem;
  }

  .wa-mobile-history {
    margin-top: .85rem;
  }

  .table.mobile-card-ready.wa-due-table tbody td.wa-desktop-phone,
  .table.mobile-card-ready.wa-due-table tbody td[data-label="Tipe"],
  .table.mobile-card-ready.wa-due-table tbody td[data-label="Kamar"] {
    display: none !important;
  }

  .wa-due-table td[data-label="Periode"] {
    display: none;
  }

  .wa-due-table td[data-label="Jatuh tempo"],
  .wa-due-table td[data-label="Tagihan"] {
    display: inline-flex;
    width: 50%;
    box-sizing: border-box;
    justify-content: flex-start;
    text-align: left;
    border-bottom: 0;
    padding-top: .35rem !important;
    padding-bottom: .2rem !important;
  }

  .table.mobile-card-ready.wa-due-table tbody td[data-label="Jatuh tempo"] {
    display: none !important;
  }

  .wa-due-table td[data-label="Jatuh tempo"]::before,
  .wa-due-table td[data-label="Tagihan"]::before {
    display: none;
  }

  .wa-due-table td[data-label="Tagihan"] {
    justify-content: flex-start;
    padding-right: .2rem !important;
    padding-bottom: .75rem !important;
  }

  .wa-due-table .wa-mobile-room {
    display: inline-block;
  }

  .wa-due-table .wa-preview-cell {
    display: block;
    padding: .2rem 1rem .8rem !important;
    border-bottom: 0;
    text-align: left;
  }

  .wa-due-table .wa-preview-cell::before {
    display: none;
  }

  .wa-due-table .wa-row-preview {
    min-height: 110px;
    max-height: 110px;
    padding: .7rem .75rem;
    background: #E9E2D9;
    border: 0;
    border-radius: .35rem;
  }

  .wa-due-table .wa-action-cell {
    display: block;
    padding: 0 1rem 1rem !important;
    text-align: left;
  }

  .wa-due-table .wa-preview-cell,
  .wa-due-table .wa-action-cell,
  .wa-due-table td[data-label="Jatuh tempo"],
  .wa-due-table td[data-label="Tagihan"] {
    text-align: left;
  }

  .wa-due-table .wa-action-cell .wa-send-row-btn {
    width: 100%;
    margin: 0;
    background: #2F8F57;
    border-color: #2F8F57;
    font-size: .9rem;
  }
}

/* ============ CHARTS ============ */
.chart-container { position: relative; }

/* ============ EMPTY STATE ============ */
.empty-state {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--text-muted-color);
}
.empty-state i { font-size: 3.5rem; display: block; margin-bottom: 1rem; color: #CBD5E1; }
.empty-state h6 { font-size: 1rem; margin-bottom: .4rem; color: #64748B; }

/* ============ SEARCH BOX ============ */
.search-box {
  position: relative;
  max-width: 280px;
}
.search-box .bi-search {
  position: absolute;
  left: .75rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted-color);
  pointer-events: none;
}
.search-box input { padding-left: 2.2rem; }

/* ============ FILTER BAR ============ */
.filter-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  flex-wrap: wrap;
  padding: .75rem 1.25rem;
  background: #F8FAFC;
  border-bottom: 1px solid var(--border-color);
}

.filter-controls {
  display: flex;
  align-items: center;
  gap: .5rem;
  flex-wrap: wrap;
  flex: 1;
}

.filter-controls .form-select {
  min-width: 140px;
  flex: 1;
}

.filter-search-box {
  flex: 1;
  max-width: 360px;
  margin-left: auto;
}

/* ============ PROGRESS ============ */
.progress { height: 8px; border-radius: 4px; background: #E2E8F0; }

/* ============ SCROLLBAR ============ */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #CBD5E1; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #94A3B8; }

/* ============ ANIMATIONS ============ */
.fade-in { animation: fadeIn .3s ease; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ============ UTILITIES ============ */
.text-rupiah { font-weight: 600; color: #16A34A; }
.text-rupiah-danger { font-weight: 600; color: var(--danger); }
.fw-600 { font-weight: 600; }
.rounded-lg { border-radius: .75rem !important; }
.bg-light-blue { background: var(--primary-light); }
.cursor-pointer { cursor: pointer; }

/* ============ MODAL ============ */
.modal-content { border: none; border-radius: .75rem; box-shadow: 0 20px 60px rgba(0,0,0,.15); }
.modal-header { border-bottom: 1px solid var(--border-color); }
.modal-footer { border-top: 1px solid var(--border-color); }

/* ============ PAGINATION ============ */
.pagination .page-link {
  color: var(--primary);
  border-color: var(--border-color);
  border-radius: .4rem;
  margin: 0 2px;
  font-size: .85rem;
}
.pagination .page-item.active .page-link {
  background: var(--primary);
  border-color: var(--primary);
}
