/* ==========================================================================
   CashBook App - Modern Premium Minimalist Design System
   Fitur: Arsitektur MVC, MySQL Backend, JWT Auth, Multi-Book, Responsive
   ========================================================================== */

:root {
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  
  /* Canvas & Neutral Colors */
  --bg-body: #F8FAFC;
  --bg-card: #FFFFFF;
  --bg-sidebar: #FFFFFF;
  --text-main: #0F172A;
  --text-muted: #64748B;
  --text-subtle: #94A3B8;
  --border-color: #E2E8F0;
  --border-light: #F1F5F9;

  /* Primary Brand Accent (Cerulean / Ocean Blue - Harmonized with Logo) */
  --primary-color: #0E8AD9;
  --primary-hover: #086EA8;
  --primary-bg: #F0F8FF;
  --primary-border: #BAE6FD;
  --primary-glow: rgba(14, 138, 217, 0.20);

  /* Cash In (Premium Emerald/Mint Matte) */
  --cash-in-color: #059669;
  --cash-in-hover: #047857;
  --cash-in-bg: #ECFDF5;
  --cash-in-border: #A7F3D0;
  --cash-in-soft: #D1FAE5;
  --cash-in-shadow: rgba(5, 150, 105, 0.16);

  /* Cash Out (Premium Rose/Crimson Matte) */
  --cash-out-color: #E11D48;
  --cash-out-hover: #BE123C;
  --cash-out-bg: #FFF1F2;
  --cash-out-border: #FECDD3;
  --cash-out-soft: #FFE4E6;
  --cash-out-shadow: rgba(225, 29, 72, 0.16);

  /* Danger / Soft Red */
  --danger-color: #DC2626;
  --danger-bg: #FEF2F2;
  --danger-border: #FECACA;

  /* Elevation & Soft Multi-layer Shadows */
  --shadow-xs: 0 1px 2px 0 rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 2px 6px -1px rgba(15, 23, 42, 0.05), 0 1px 3px -1px rgba(15, 23, 42, 0.02);
  --shadow-md: 0 8px 20px -3px rgba(15, 23, 42, 0.07), 0 3px 8px -2px rgba(15, 23, 42, 0.03);
  --shadow-lg: 0 16px 32px -4px rgba(15, 23, 42, 0.09), 0 6px 14px -3px rgba(15, 23, 42, 0.04);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 10px 10px -5px rgba(0, 0, 0, 0.03);
  --shadow-modal: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 10px 10px -5px rgba(0, 0, 0, 0.03);

  /* Rounded Corners */
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 16px;
  --radius-modal: 16px;
  --radius-full: 9999px;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html, body {
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
  box-sizing: border-box;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-body);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

/* ==========================================================================
   Keyframe Animations
   ========================================================================== */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes modalPop {
  0% {
    opacity: 0;
    transform: scale(0.95) translateY(-8px);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* ==========================================================================
   Layar Autentikasi (Login / Register Screen)
   ========================================================================== */
.auth-screen {
  min-height: 100vh;
  width: 100vw;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  background: 
    radial-gradient(circle at 10% 15%, rgba(14, 138, 217, 0.07) 0%, transparent 45%),
    radial-gradient(circle at 90% 85%, rgba(5, 150, 105, 0.07) 0%, transparent 45%),
    var(--bg-body);
  animation: fadeIn 0.3s ease;
  box-sizing: border-box;
}

.auth-card {
  width: 100%;
  max-width: 440px;
  background: #FFFFFF;
  border: 1px solid rgba(226, 232, 240, 0.85);
  border-radius: var(--radius-modal);
  box-shadow: var(--shadow-modal);
  padding: 36px 32px;
  animation: modalPop 0.25s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  position: relative;
}

.auth-brand {
  text-align: center;
  margin-bottom: 24px;
}

.auth-logo {
  font-size: 2.4rem;
  width: 58px;
  height: 58px;
  background: var(--primary-bg);
  border: 1px solid var(--primary-border);
  border-radius: var(--radius-lg);
  display: grid;
  place-items: center;
  margin: 0 auto 12px;
  box-shadow: var(--shadow-sm);
}

.auth-brand h2 {
  font-size: 1.45rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-main);
}

.auth-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 4px;
  line-height: 1.4;
}

/* Segmented Auth Tabs */
.auth-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: #F1F5F9;
  border-radius: 12px;
  padding: 4px;
  margin-bottom: 20px;
  gap: 4px;
}

.auth-tab-btn {
  padding: 9px 12px;
  border: none;
  background: transparent;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.auth-tab-btn:hover {
  color: var(--text-main);
  background: rgba(255, 255, 255, 0.6);
}

.auth-tab-btn.active {
  background: #FFFFFF;
  color: var(--primary-color);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
  font-weight: 700;
}

.auth-alert {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.82rem;
  font-weight: 500;
  margin-bottom: 16px;
  animation: slideUp 0.2s ease;
}

.auth-alert.alert-danger {
  background: var(--cash-out-bg);
  color: var(--cash-out-color);
  border: 1px solid var(--cash-out-border);
}

.auth-alert.alert-success {
  background: var(--cash-in-bg);
  color: var(--cash-in-color);
  border: 1px solid var(--cash-in-border);
}

.auth-alert.alert-warning {
  background: #FFFBEB;
  color: #B45309;
  border: 1px solid #FDE68A;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.btn-auth-submit {
  padding: 12px 18px;
  font-size: 0.95rem;
  font-weight: 700;
  border-radius: var(--radius-md);
  margin-top: 4px;
  background: linear-gradient(135deg, #1999E2 0%, #086EA8 100%);
  color: #FFFFFF;
  border: 1px solid transparent;
  box-shadow: 0 4px 14px var(--primary-glow);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-auth-submit:hover {
  background: linear-gradient(135deg, #0C7BC7 0%, #02599D 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 18px var(--primary-glow);
}

.btn-auth-submit:active {
  transform: scale(0.98) translateY(0);
  box-shadow: 0 2px 8px var(--primary-glow);
}

.auth-divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 12px 0;
  color: var(--text-subtle);
  font-size: 0.75rem;
  text-transform: uppercase;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid var(--border-color);
}

.auth-divider span {
  padding: 0 10px;
}

.btn-demo-auth {
  border-color: #CBD5E1;
  color: #334155;
  font-weight: 600;
  font-size: 0.85rem;
  background: #F8FAFC;
}

.btn-demo-auth:hover {
  background: #F1F5F9;
  border-color: #94A3B8;
  transform: translateY(-1px);
}

.auth-footer-note {
  text-align: center;
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid var(--border-light);
  font-size: 0.75rem;
  color: var(--text-subtle);
}

/* ==========================================================================
   2FA Google Authenticator (TOTP) UI Styles
   ========================================================================== */
.auth-otp-step {
  display: flex;
  flex-direction: column;
  gap: 16px;
  animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.otp-header-info {
  text-align: center;
  margin-bottom: 4px;
}

.otp-shield-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: #EEF2FF;
  color: #4F46E5;
  border: 1px solid #C7D2FE;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.otp-header-info h3 {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.02em;
}

.otp-desc-text {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 6px;
  line-height: 1.45;
}

.otp-desc-text strong {
  color: var(--primary-color);
  word-break: break-all;
}

/* Two-Factor QR Setup Card */
.twofactor-setup-box {
  background: #F8FAFC;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 16px;
  text-align: center;
  animation: fadeIn 0.3s ease;
  box-shadow: inset 0 1px 2px rgba(0,0,0,0.02);
}

.setup-guide-badge {
  font-size: 0.75rem;
  font-weight: 700;
  color: #0F172A;
  margin-bottom: 6px;
}

.setup-guide-text {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-bottom: 12px;
}

.qr-code-wrapper {
  background: white;
  padding: 10px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  display: inline-flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
}

.qr-code-img {
  width: 160px;
  height: 160px;
  display: block;
  border-radius: var(--radius-xs);
}

.secret-key-wrapper {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: center;
}

.secret-label {
  font-size: 0.72rem;
  color: var(--text-subtle);
  font-weight: 500;
}

.secret-key-box {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 4px 8px;
}

.secret-key-box code {
  font-family: monospace;
  font-size: 0.85rem;
  font-weight: 700;
  color: #1E293B;
  letter-spacing: 0.08em;
}

.btn-copy-key {
  background: var(--primary-bg);
  color: var(--primary-color);
  border: 1px solid var(--primary-border);
  border-radius: var(--radius-xs);
  padding: 3px 8px;
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-copy-key:hover {
  background: var(--primary-color);
  color: white;
}

.input-otp {
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: 0.35em;
  text-align: center;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  color: var(--primary-color);
  background: #F8FAFC;
}

.input-otp:focus {
  background: white;
}

.otp-demo-hint {
  font-size: 0.75rem;
  background: var(--primary-bg);
  border: 1px dashed var(--primary-border);
  color: var(--primary-hover);
  border-radius: var(--radius-sm);
  padding: 6px 10px;
  margin-top: 8px;
}

.btn-back-login {
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 600;
  padding: 8px 12px;
  border: none;
  background: transparent;
  cursor: pointer;
  transition: color 0.15s ease;
}

.btn-back-login:hover {
  color: var(--text-main);
  text-decoration: underline;
}

.form-text-hint {
  display: block;
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 5px;
  line-height: 1.35;
}

/* ==========================================================================
   Layout: Sidebar (Left) & Main (Right)
   ========================================================================== */
.app-layout {
  display: flex;
  min-height: 100vh;
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
  box-sizing: border-box;
  position: relative;
  animation: fadeIn 0.25s ease;
}

/* Sidebar */
.app-sidebar {
  width: 295px;
  min-width: 295px;
  flex-shrink: 0;
  background: var(--bg-sidebar);
  border-right: 1px solid var(--border-color);
  height: 100vh;
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  z-index: 100;
  overflow-y: auto;
  overflow-x: hidden;
  transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1), min-width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: var(--shadow-xs);
}

.sidebar-header {
  padding: 16px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid var(--border-light);
  min-height: 72px;
  transition: padding 0.3s ease;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  overflow: hidden;
}

.brand-toggle-btn {
  cursor: pointer;
  border-radius: var(--radius-md);
  padding: 4px 8px 4px 4px;
  margin: -4px 0 -4px -4px;
  transition: background-color 0.18s ease, transform 0.18s ease, opacity 0.18s ease;
  user-select: none;
  width: 100%;
}

.brand-toggle-btn:hover {
  background: var(--primary-bg);
}

.brand-toggle-btn:active {
  transform: scale(0.98);
}

.brand-toggle-btn:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

.app-sidebar.collapsed .brand-toggle-btn {
  padding: 4px;
  margin: 0;
  width: auto;
}

.brand-icon {
  font-size: 1.4rem;
  background: var(--primary-bg);
  border: 1px solid var(--primary-border);
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-md);
  flex-shrink: 0;
  box-shadow: var(--shadow-xs);
}

.brand-text {
  display: flex;
  flex-direction: column;
  white-space: nowrap;
}

.brand h1 {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-main);
  line-height: 1.2;
}

.brand .subtitle {
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--text-muted);
}

.sidebar-header-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-sidebar-toggle {
  background: var(--bg-body);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  width: 34px;
  height: 34px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 0.75rem;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.btn-sidebar-toggle:hover {
  background: var(--primary-bg);
  color: var(--primary-color);
  border-color: var(--primary-border);
  transform: scale(1.05);
}

.btn-close-sidebar {
  display: none;
  background: transparent;
  border: none;
  font-size: 1.6rem;
  color: var(--text-muted);
  cursor: pointer;
  line-height: 1;
}

/* ==========================================================================
   Sidebar Navigasi Menu Baru (Sesuai Referensi Gambar 1)
   ========================================================================== */
.sidebar-nav {
  padding: 16px 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow-y: auto;
}

.nav-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.nav-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 6px 10px;
  background: transparent;
  border: none;
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
  user-select: none;
  text-align: left;
}

.nav-section-header:hover {
  background: #F8FAFC;
}

.nav-section-title {
  font-size: 0.82rem;
  font-weight: 500;
  color: #64748B;
  letter-spacing: 0.01em;
}

.nav-chevron {
  color: #94A3B8;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  flex-shrink: 0;
}

.nav-section.collapsed .nav-chevron {
  transform: rotate(-90deg);
}

.nav-section-items {
  display: flex;
  flex-direction: column;
  gap: 4px;
  transition: all 0.2s ease;
}

.nav-section.collapsed .nav-section-items {
  display: none;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 14px;
  border-radius: 10px;
  border: none;
  background: transparent;
  color: #334155;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

.nav-item:hover {
  background: #F1F5F9;
  color: #0F172A;
}

.nav-item-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: #64748B;
  transition: color 0.18s ease;
}

.nav-item:hover .nav-item-icon {
  color: #1E293B;
}

.nav-item-label {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Item Aktif: Latar Ungu/Indigo dengan teks dan ikon putih (Sesuai Referensi Gambar 1) */
.nav-item.active {
  background: #4F46E5;
  color: #FFFFFF;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.25);
}

.nav-item.active .nav-item-icon {
  color: #FFFFFF;
}

.nav-item.active:hover {
  background: #4338CA;
  color: #FFFFFF;
}

/* --------------------------------------------------------------------------
   Sidebar Compact / Minimize Mode (.app-sidebar.collapsed)
   -------------------------------------------------------------------------- */
.app-sidebar.collapsed {
  width: 76px;
  min-width: 76px;
}

.app-sidebar.collapsed .sidebar-header {
  padding: 14px 6px;
  flex-direction: column;
  gap: 10px;
  align-items: center;
  justify-content: center;
}

.app-sidebar.collapsed .brand {
  justify-content: center;
}

.app-sidebar.collapsed .brand-text {
  display: none;
}

.app-sidebar.collapsed .sidebar-header-actions {
  width: 100%;
  justify-content: center;
}

.app-sidebar.collapsed .sidebar-nav {
  padding: 12px 6px;
  gap: 12px;
  align-items: center;
}

.app-sidebar.collapsed .nav-section-header {
  display: none;
}

.app-sidebar.collapsed .nav-section {
  width: 100%;
  align-items: center;
}

.app-sidebar.collapsed .nav-section.collapsed .nav-section-items {
  display: flex !important;
}

.app-sidebar.collapsed .nav-section-items {
  width: 100%;
  align-items: center;
}

.app-sidebar.collapsed .nav-item {
  width: 44px;
  height: 44px;
  padding: 0;
  justify-content: center;
  border-radius: 10px;
  margin: 0 auto;
}

.app-sidebar.collapsed .nav-item-label {
  display: none;
}

.app-sidebar.collapsed .nav-item-icon {
  width: 22px;
  height: 22px;
}

/* --------------------------------------------------------------------------
   View Page Header & Placeholder Card (Untuk Business Settings & Help Docs)
   -------------------------------------------------------------------------- */
.view-page-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.btn-view-back {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: var(--radius-sm);
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  color: #334155;
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.btn-view-back:hover {
  background: #F1F5F9;
  border-color: #CBD5E1;
  color: var(--primary-color);
  transform: translateX(-2px);
}

.view-page-title {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0F172A;
}

.view-page-body {
  width: 100%;
}

.placeholder-content-card {
  max-width: 600px;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 16px;
  padding: 48px 32px;
  text-align: center;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
}

.placeholder-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: #EEF2FF;
  color: #4F46E5;
  display: grid;
  place-items: center;
  margin-bottom: 8px;
}

.placeholder-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1E293B;
}

.placeholder-desc {
  font-size: 0.95rem;
  color: #64748B;
  margin: 0;
}

/* --------------------------------------------------------------------------
   Halaman Pengaturan Bisnis (Sesuai Referensi Gambar 3 & 4)
   -------------------------------------------------------------------------- */
.business-settings-view {
  padding: 24px 32px;
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

.biz-settings-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.biz-settings-header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.biz-settings-container {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 28px;
  align-items: start;
}

/* Sidebar Tab Vertikal */
.biz-settings-sidebar {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.biz-settings-tab-btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  padding: 14px 18px;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  background: #FFFFFF;
  cursor: pointer;
  text-align: left;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.biz-settings-tab-btn:hover {
  background: #F8FAFC;
  border-color: #CBD5E1;
}

.biz-settings-tab-btn.active {
  background: #EEF2FF;
  border-color: #C7D2FE;
  box-shadow: 0 2px 6px rgba(79, 70, 229, 0.08);
}

.biz-settings-tab-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #1E293B;
  transition: color 0.2s ease;
}

.biz-settings-tab-btn.active .biz-settings-tab-title {
  color: #4F46E5;
}

.biz-settings-tab-sub {
  font-size: 0.8rem;
  color: #64748B;
  margin-top: 3px;
}

.biz-settings-tab-btn.active .biz-settings-tab-sub {
  color: #6366F1;
}

/* Konten Tab Kanan */
.biz-settings-content {
  min-width: 0;
}

.biz-tab-pane {
  display: block;
}

.biz-tab-pane.hidden {
  display: none !important;
}

/* Kartu Ringkasan Header Profil Bisnis */
.biz-profile-header-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 14px;
  padding: 22px 26px;
  margin-bottom: 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.biz-header-top {
  display: flex;
  align-items: center;
  gap: 16px;
}

.biz-avatar-building {
  width: 52px;
  height: 52px;
  border-radius: 12px;
  background: #F1F5F9;
  color: #475569;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.biz-header-meta {
  display: flex;
  flex-direction: column;
}

.biz-profile-name {
  font-size: 1.25rem;
  font-weight: 800;
  color: #0F172A;
  margin: 0;
  letter-spacing: -0.01em;
}

.biz-profile-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-top: 4px;
}

.biz-profile-status-badge.status-incomplete {
  color: #DC2626;
}

.biz-profile-status-badge.status-complete {
  color: #16A34A;
}

.biz-strength-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 18px;
  font-size: 0.88rem;
  color: #334155;
}

.biz-strength-title strong {
  color: #D97706;
}

.biz-percent-label {
  font-weight: 700;
  color: #D97706;
}

.biz-strength-bar-track {
  width: 100%;
  height: 8px;
  background: #E2E8F0;
  border-radius: 9999px;
  overflow: hidden;
  margin-top: 8px;
}

.biz-strength-bar-fill {
  height: 100%;
  background: #EA580C;
  border-radius: 9999px;
  transition: width 0.35s ease, background-color 0.35s ease;
}

.biz-incomplete-infobox {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 16px;
  padding: 12px 16px;
  background: #EEF2FF;
  border: 1px solid #C7D2FE;
  border-radius: 10px;
  font-size: 0.88rem;
  color: #3730A3;
  line-height: 1.45;
}

.biz-infobox-icon {
  flex-shrink: 0;
  color: #4F46E5;
  display: grid;
  place-items: center;
}

/* Kartu Form Bagian (Dasar & Komunikasi) */
.biz-form-section-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 14px;
  padding: 24px 26px;
  margin-bottom: 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.biz-section-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0F172A;
  margin: 0 0 18px 0;
  padding-bottom: 12px;
  border-bottom: 1px solid #F1F5F9;
}

.biz-section-title.text-danger {
  color: #DC2626;
  border-bottom-color: #FEE2E2;
}

.biz-field-group {
  margin-bottom: 18px;
}

.biz-field-group:last-child {
  margin-bottom: 0;
}

.biz-field-label {
  display: block;
  font-size: 0.84rem;
  font-weight: 600;
  color: #475569;
  margin-bottom: 6px;
}

.biz-field-input-row {
  display: flex;
  align-items: center;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  padding: 0 12px;
  transition: all 0.2s ease;
}

.biz-field-input-row.textarea-row {
  align-items: flex-start;
  padding-top: 8px;
  padding-bottom: 8px;
}

.biz-field-input-row:focus-within,
.biz-field-input-row.editing {
  border-color: #6366F1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

.biz-field-icon {
  color: #94A3B8;
  display: grid;
  place-items: center;
  margin-right: 10px;
  flex-shrink: 0;
}

.biz-field-icon.align-top {
  margin-top: 4px;
}

.biz-field-input,
.biz-field-textarea {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 0.95rem;
  color: #1E293B;
  padding: 10px 0;
  outline: none;
  font-family: inherit;
  width: 100%;
}

.biz-field-input[readonly],
.biz-field-textarea[readonly] {
  cursor: default;
  color: #1E293B;
  user-select: text;
}

.biz-field-textarea {
  resize: vertical;
  min-height: 48px;
  line-height: 1.5;
}

.btn-field-edit {
  background: transparent;
  border: none;
  padding: 8px;
  color: #6366F1;
  cursor: pointer;
  border-radius: 8px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  transition: all 0.15s ease;
}

.btn-field-edit.align-top {
  margin-top: 2px;
}

.btn-field-edit:hover {
  background: #EEF2FF;
  color: #4F46E5;
}

/* Inline Edit Component (Profile & Business Fields) */
.inline-edit-error {
  font-size: 0.8rem;
  color: #DC2626;
  font-weight: 500;
  margin-top: 5px;
  line-height: 1.35;
}

.inline-edit-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
  margin-top: 8px;
}

.btn-inline-cancel {
  padding: 6px 14px;
  font-size: 0.82rem;
  font-weight: 500;
  color: #64748B;
  background: #FFFFFF;
  border: 1px solid #CBD5E1;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
  line-height: 1.4;
}

.btn-inline-cancel:hover {
  background: #F1F5F9;
  color: #334155;
  border-color: #94A3B8;
}

.btn-inline-update {
  padding: 6px 14px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #FFFFFF;
  background: #6366F1;
  border: 1px solid #6366F1;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
  line-height: 1.4;
}

.btn-inline-update:hover:not(:disabled) {
  background: #4F46E5;
  border-color: #4F46E5;
}

.btn-inline-update:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  background: #A5B4FC;
  border-color: #A5B4FC;
}

/* Card Tab Pengaturan Bahaya (Hapus Bisnis) */
.biz-danger-card {
  border-color: #FEE2E2;
  background: #FFFBFB;
}

.biz-danger-desc {
  font-size: 0.92rem;
  color: #64748B;
  line-height: 1.6;
  margin: 0 0 20px 0;
}

.biz-danger-action-row {
  display: flex;
  justify-content: flex-start;
}

.btn-danger-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid #DC2626;
  border-radius: 10px;
  background: #FFFFFF;
  color: #DC2626;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-danger-outline:hover {
  background: #DC2626;
  color: #FFFFFF;
  box-shadow: 0 3px 10px rgba(220, 38, 38, 0.2);
}

/* --------------------------------------------------------------------------
   Halaman Panduan / Help Docs (Sesuai Referensi Gambar 5)
   -------------------------------------------------------------------------- */
.help-docs-view {
  padding: 24px 32px;
  max-width: 1360px;
  width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
}

.help-docs-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.help-docs-header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.btn-help-nav-books {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  border-radius: var(--radius-sm);
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  color: #4F46E5;
  font-weight: 600;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-help-nav-books:hover {
  background: #EEF2FF;
  border-color: #C7D2FE;
  transform: translateY(-1px);
}

.help-docs-container {
  display: grid;
  grid-template-columns: 310px 1fr;
  gap: 32px;
  align-items: start;
}

.help-topics-sidebar {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 12px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  position: sticky;
  top: 90px;
}

.help-topics-nav {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.help-topic-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 11px 14px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: #334155;
  font-size: 0.88rem;
  font-weight: 500;
  cursor: pointer;
  text-align: left;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

.help-topic-btn:hover {
  background: #F8FAFC;
  color: #0F172A;
}

.help-topic-btn .topic-chevron {
  color: #94A3B8;
  transition: transform 0.2s ease, color 0.2s ease;
  flex-shrink: 0;
}

.help-topic-btn:hover .topic-chevron {
  color: #475569;
}

/* Topik Aktif (Sesuai Referensi Gambar 5) */
.help-topic-btn.active {
  background: #EEF2FF;
  color: #4F46E5;
  font-weight: 600;
}

.help-topic-btn.active .topic-chevron {
  color: #4F46E5;
  transform: translateX(2px);
}

.help-content-display {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 36px 40px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  min-height: 480px;
}

.help-topic-content {
  display: none;
  animation: fadeInTopic 0.22s ease forwards;
}

.help-topic-content.active {
  display: block;
}

@keyframes fadeInTopic {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.help-topic-title {
  font-size: 1.55rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0F172A;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid #F1F5F9;
}

.help-lead-text {
  font-size: 1rem;
  line-height: 1.65;
  color: #334155;
  margin-bottom: 22px;
}

.help-section-subhead {
  font-size: 1.12rem;
  font-weight: 700;
  color: #1E293B;
  margin: 24px 0 12px;
}

.help-bullet-list,
.help-numbered-list {
  padding-left: 20px;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  color: #334155;
  line-height: 1.6;
  font-size: 0.95rem;
}

.help-bullet-list li,
.help-numbered-list li {
  padding-left: 4px;
}

.help-note-box {
  background: #F8FAFC;
  border-left: 4px solid #4F46E5;
  border-radius: 6px;
  padding: 14px 18px;
  margin: 20px 0;
  font-size: 0.92rem;
  color: #334155;
  line-height: 1.6;
}

.help-note-box.warning {
  background: #FFFBEB;
  border-left-color: #F59E0B;
  color: #92400E;
}

.help-faq-item {
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 18px 20px;
  margin-bottom: 14px;
  background: #FFFFFF;
}

.help-faq-q {
  font-size: 0.98rem;
  font-weight: 700;
  color: #0F172A;
  margin-bottom: 8px;
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.help-faq-badge {
  background: #EEF2FF;
  color: #4F46E5;
  font-size: 0.78rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 4px;
  flex-shrink: 0;
  margin-top: 2px;
}

.help-faq-a {
  font-size: 0.92rem;
  color: #475569;
  line-height: 1.65;
  margin: 0;
}

@media (max-width: 900px) {
  .business-settings-view {
    padding: 16px;
  }

  .biz-settings-container {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .biz-settings-sidebar {
    flex-direction: row;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .biz-settings-tab-btn {
    min-width: 150px;
    flex: 1;
    padding: 10px 14px;
  }

  .biz-profile-header-card,
  .biz-form-section-card {
    padding: 16px;
  }

  .help-docs-view {
    padding: 16px;
  }

  .help-docs-container {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .help-topics-sidebar {
    position: static;
    max-height: 280px;
    overflow-y: auto;
  }

  .help-content-display {
    padding: 24px 20px;
  }

  .help-topic-title {
    font-size: 1.35rem;
  }
}

/* ==========================================================================
   Konten Utama (Main Dashboard)
   ========================================================================== */
.app-main {
  flex: 1;
  min-width: 0;
  max-width: 100%;
  display: flex;
  flex-direction: column;
  background-color: var(--bg-body);
  overflow-x: hidden;
  box-sizing: border-box;
}

/* Top Bar */
.main-topbar {
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-color);
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  position: sticky;
  top: 0;
  z-index: 90;
  box-shadow: var(--shadow-xs);
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.btn-hamburger {
  display: none;
  background: #F1F5F9;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-hamburger:hover {
  background: #E2E8F0;
}

.btn-topbar-logo-mobile {
  padding: 3px;
  background: transparent;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
}

.btn-topbar-logo-mobile:hover {
  background: var(--primary-bg);
  border-color: var(--primary-border);
}

.btn-topbar-logo-mobile:active {
  transform: scale(0.95);
}

.btn-topbar-logo-mobile:focus-visible {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

.topbar-mobile-logo-img {
  width: 30px;
  height: 30px;
  object-fit: contain;
  display: block;
}

/* --------------------------------------------------------------------------
   Business Switcher Dropdown (Multi-Business)
   -------------------------------------------------------------------------- */
.business-dropdown-container {
  position: relative;
}

.btn-business-dropdown {
  display: flex;
  align-items: center;
  gap: 10px;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 6px 14px 6px 10px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: var(--shadow-xs);
}

.btn-business-dropdown:hover {
  border-color: var(--primary-color);
  background: #FAFAFA;
  box-shadow: var(--shadow-sm);
  transform: translateY(-1px);
}

.biz-badge-icon {
  width: 32px;
  height: 32px;
  background: #EEF2FF;
  border: 1px solid #C7D2FE;
  border-radius: var(--radius-sm);
  display: grid;
  place-items: center;
  font-size: 1.05rem;
  flex-shrink: 0;
}

.biz-info-block {
  display: flex;
  flex-direction: column;
  text-align: left;
}

.biz-label-super {
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  line-height: 1;
}

.biz-name-display {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-main);
  max-width: 170px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-top: 2px;
}

.biz-chevron-arrow {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-left: 2px;
  transition: transform 0.2s ease;
}

.btn-business-dropdown[aria-expanded="true"] .biz-chevron-arrow {
  transform: rotate(180deg);
}

.business-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  width: 290px;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  z-index: 150;
  overflow: hidden;
  animation: slideUp 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.business-dropdown-menu.hidden {
  display: none !important;
}

.biz-menu-header {
  padding: 10px 14px 6px;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--text-subtle);
  background: #F8FAFC;
  border-bottom: 1px solid var(--border-light);
}

.biz-menu-list {
  max-height: 240px;
  overflow-y: auto;
  padding: 6px 0;
}

.biz-menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  width: 100%;
  border: none;
  background: transparent;
  cursor: pointer;
  text-align: left;
  transition: background 0.15s ease;
  gap: 8px;
}

.biz-menu-item:hover {
  background: var(--primary-bg);
}

.biz-menu-item.active {
  background: var(--primary-bg);
  border-left: 3px solid var(--primary-color);
}

.biz-menu-item-info {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}

.biz-menu-item-name {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.biz-menu-item.active .biz-menu-item-name {
  color: var(--primary-color);
}

.biz-menu-item-meta {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin-top: 1px;
}

.biz-menu-item-badge {
  font-size: 0.65rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: #F1F5F9;
  color: #475569;
  white-space: nowrap;
}

.biz-menu-item.active .biz-menu-item-badge {
  background: #E0F2FE;
  color: var(--primary-hover);
}

.biz-menu-divider {
  border-bottom: 1px solid var(--border-light);
}

.btn-add-biz-action {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 10px 14px;
  border: none;
  background: #F8FAFC;
  color: var(--primary-color);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s ease;
}

.btn-add-biz-action:hover {
  background: var(--primary-bg);
}

.topbar-divider {
  width: 1px;
  height: 32px;
  background: var(--border-color);
  margin: 0 4px;
}

.active-book-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.book-badge-wrapper {
  display: flex;
}

.book-pill {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: var(--primary-bg);
  color: var(--primary-hover);
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

.book-title-wrapper {
  display: flex;
  align-items: center;
  gap: 8px;
}

.book-title-wrapper h2 {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-main);
}

.btn-icon-subtle {
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: 0.95rem;
  padding: 2px 5px;
  border-radius: var(--radius-xs);
  transition: background 0.15s ease;
}

.btn-icon-subtle:hover {
  background: #F1F5F9;
}

.book-meta-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 12px;
}


/* User Profile Dropdown (Topbar Right - Sesuai Gambar 1, 2 & 3) */
.profile-dropdown-container {
  position: relative;
  display: inline-flex;
}

.btn-profile-dropdown {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  padding: 4px 12px 4px 5px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: var(--shadow-xs);
  user-select: none;
}

.btn-profile-dropdown:hover {
  background: #F8FAFC;
  border-color: #CBD5E1;
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.profile-avatar-circle {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: #EEF2FF;
  color: #4F46E5;
  font-weight: 700;
  font-size: 0.8rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  border: 1px solid #C7D2FE;
}

.profile-name-text {
  font-size: 0.86rem;
  font-weight: 600;
  color: #1E293B;
  max-width: 150px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.profile-chevron {
  font-size: 0.75rem;
  color: #64748B;
  margin-left: 2px;
  transition: transform 0.2s ease;
}

.btn-profile-dropdown[aria-expanded="true"] .profile-chevron {
  transform: rotate(180deg);
}

/* Dropdown Popup Menu (Sesuai Gambar 3) */
.profile-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 220px;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: var(--shadow-xl);
  z-index: 200;
  overflow: hidden;
  animation: slideUp 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.profile-dropdown-menu.hidden {
  display: none !important;
}

.profile-menu-user-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  cursor: pointer;
  transition: background 0.15s ease;
}

.profile-menu-user-row:hover {
  background: #F8FAFC;
}

.profile-menu-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: #EEF2FF;
  color: #4F46E5;
  font-weight: 700;
  font-size: 0.92rem;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  border: 1px solid #C7D2FE;
}

.profile-menu-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.profile-menu-name {
  font-size: 0.86rem;
  font-weight: 700;
  color: #0F172A;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.profile-menu-sublink {
  font-size: 0.78rem;
  font-weight: 600;
  color: #4F46E5;
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.profile-arrow {
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1;
}

.profile-menu-divider {
  height: 1px;
  background: var(--border-light);
  width: 100%;
}

.profile-menu-logout-row {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 14px;
  border: none;
  background: transparent;
  color: #334155;
  font-size: 0.84rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
  text-align: left;
}

.profile-menu-logout-row:hover {
  background: #FEF2F2;
  color: #DC2626;
}

.logout-door-icon {
  display: grid;
  place-items: center;
  color: inherit;
  flex-shrink: 0;
}

/* ==========================================================================
   Halaman Detail Profil Pengguna (Sesuai Gambar 4)
   ========================================================================== */
.profile-details-view {
  padding: 24px 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  animation: fadeIn 0.25s ease;
}

.profile-details-view.hidden {
  display: none !important;
}

.profile-details-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-profile-back {
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  color: #334155;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-profile-back:hover {
  background: #F1F5F9;
  border-color: #CBD5E1;
  color: var(--primary-color);
  transform: translateX(-2px);
}

.profile-details-title {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0F172A;
}

.profile-card-container {
  max-width: 540px;
  width: 100%;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 14px;
  padding: 24px 28px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
  display: flex;
  flex-direction: column;
  gap: 16px;
  box-sizing: border-box;
}

.profile-field-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.profile-field-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #64748B;
}

.profile-input-box {
  display: flex;
  align-items: center;
  background: #FFFFFF;
  border: 1.5px solid #E2E8F0;
  border-radius: 8px;
  padding: 2px 8px 2px 14px;
  transition: all 0.2s ease;
}

.profile-input-box:focus-within,
.profile-input-box.editing {
  border-color: #4F46E5;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

.profile-text-input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-size: 0.92rem;
  font-weight: 600;
  color: #1E293B;
  padding: 10px 0;
  width: 100%;
}

.profile-text-input[readonly] {
  color: #334155;
  cursor: default;
}

.btn-input-pencil {
  background: transparent;
  border: none;
  color: #6366F1;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.15s ease;
  flex-shrink: 0;
}

.btn-input-pencil:hover {
  background: #EEF2FF;
  color: #4338CA;
  transform: scale(1.08);
}

.profile-verified-banner {
  background: #ECFDF5;
  border: 1px solid #A7F3D0;
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-top: 2px;
}

.verified-icon-circle {
  width: 22px;
  height: 22px;
  color: #059669;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  margin-top: 1px;
}

.verified-text-wrap {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.verified-title {
  font-size: 0.86rem;
  font-weight: 700;
  color: #065F46;
}

.verified-desc {
  font-size: 0.78rem;
  color: #047857;
  line-height: 1.4;
  margin: 0;
}

.profile-card-divider {
  height: 1px;
  background: #F1F5F9;
  width: 100%;
  margin: 8px 0 2px;
}

.profile-card-footer {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.btn-profile-logout {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  border: none;
  color: #DC2626;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  padding: 6px 0;
  transition: color 0.15s ease, transform 0.15s ease;
  width: fit-content;
}

.btn-profile-logout:hover {
  color: #B91C1C;
  transform: translateX(2px);
}

.profile-app-version {
  font-size: 0.75rem;
  font-weight: 500;
  color: #94A3B8;
}

/* ==========================================================================
   Tampilan Utama Bisnis / Business Dashboard View (Sesuai Gambar 1)
   ========================================================================== */
.business-dashboard-view {
  padding: 24px 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  animation: fadeIn 0.2s ease;
}

.business-dashboard-view.hidden {
  display: none !important;
}

.biz-dash-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 4px 0;
}

.biz-dash-title {
  font-size: 1.45rem;
  font-weight: 800;
  color: #0F172A;
  letter-spacing: -0.02em;
  margin: 0;
}

.biz-dash-toolbar {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.biz-search-box {
  position: relative;
  flex: 1;
  max-width: 380px;
  min-width: 240px;
  display: flex;
  align-items: center;
}

.biz-search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #94A3B8;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 2;
  width: 18px;
  height: 18px;
}

.biz-search-box input,
.biz-search-box input[type="text"],
#bizBookSearchInput {
  width: 100%;
  height: 44px;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  padding: 8px 44px 8px 44px !important;
  font-size: 0.88rem;
  color: #1E293B;
  font-family: inherit;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.02);
}

.biz-search-box input::placeholder,
#bizBookSearchInput::placeholder {
  color: #94A3B8;
  font-size: 0.86rem;
}

.biz-search-box input:focus,
#bizBookSearchInput:focus {
  outline: none;
  border-color: #4F46E5;
  background: #FFFFFF;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

.biz-search-badge {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  color: #94A3B8;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 6px;
  line-height: 1.2;
  pointer-events: none;
  z-index: 2;
}

.biz-sort-wrapper {
  position: relative;
  display: inline-flex;
}

.biz-sort-select {
  appearance: none;
  -webkit-appearance: none;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  padding: 10px 38px 10px 16px;
  font-size: 0.86rem;
  font-weight: 600;
  color: #334155;
  height: 44px;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.02);
  transition: all 0.2s ease;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 13px;
}

.biz-sort-select:hover {
  border-color: #CBD5E1;
  background-color: #F8FAFC;
}

.biz-sort-select:focus {
  outline: none;
  border-color: #4F46E5;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

.btn-biz-add-book {
  background: #4F46E5;
  color: #FFFFFF;
  border: none;
  border-radius: 10px;
  height: 44px;
  padding: 0 22px;
  font-size: 0.9rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  transition: all 0.15s ease;
  box-shadow: 0 1px 3px rgba(79, 70, 229, 0.2);
}

.btn-biz-add-book:hover {
  background: #4338CA;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.btn-biz-plus {
  font-size: 1.1rem;
  line-height: 1;
}

.biz-dash-layout {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

.biz-books-column {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

.biz-books-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.biz-book-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  cursor: pointer;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.02);
  position: relative;
}

.biz-book-card.menu-open {
  z-index: 50;
}

.biz-book-card:hover {
  border-color: #CBD5E1;
  background: #F8FAFC;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
}

.biz-book-left {
  display: flex;
  align-items: center;
  gap: 16px;
  min-width: 0;
  flex: 1;
}

.biz-book-avatar {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: #EEF2FF;
  color: #4F46E5;
  display: grid;
  place-items: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.biz-book-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  flex: 1;
}

.biz-book-title {
  font-size: 1rem;
  font-weight: 700;
  color: #0F172A;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.biz-book-sub {
  font-size: 0.78rem;
  color: #64748B;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.biz-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.biz-active-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 9999px;
  background: #EEF2FF;
  color: #4F46E5;
  border: 1px solid #C7D2FE;
  font-size: 0.72rem;
  font-weight: 700;
  line-height: 1.3;
  flex-shrink: 0;
}

.biz-book-right {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-shrink: 0;
}

.biz-book-balance {
  font-size: 0.95rem;
  font-weight: 700;
  color: #059669;
  white-space: nowrap;
}

.biz-book-balance.negative {
  color: #DC2626;
}

.biz-book-balance.zero {
  color: #057A55;
}

.biz-book-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-book-row-action {
  background: transparent;
  border: none;
  color: #4F46E5;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-book-row-action:hover {
  background: #EEF2FF;
  color: #4338CA;
}

.btn-book-row-action.text-danger {
  color: #EF4444;
}

.btn-book-row-action.text-danger:hover {
  background: #FEF2F2;
  color: #DC2626;
}

.btn-book-row-action.btn-move-biz-book {
  color: #EF4444;
}

.btn-book-row-action.btn-move-biz-book:hover {
  background: #FEF2F2;
  color: #DC2626;
}

/* 3-dots more menu wrapper & dropdown */
.biz-book-more-wrapper {
  position: relative;
  display: none;
}

.btn-biz-book-more {
  background: transparent;
  border: none;
  color: #64748B;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
  padding: 0;
}

.btn-biz-book-more:hover {
  background: #F1F5F9;
  color: #0F172A;
}

.biz-book-more-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.12), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
  min-width: 165px;
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  z-index: 100;
  animation: fadeInMenu 0.15s ease;
}

.biz-book-more-menu.hidden {
  display: none !important;
}

.biz-book-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border: none;
  background: transparent;
  border-radius: 6px;
  cursor: pointer;
  text-align: left;
  font-size: 0.85rem;
  font-weight: 500;
  color: #334155;
  transition: background-color 0.15s ease, color 0.15s ease;
  width: 100%;
  white-space: nowrap;
}

.biz-book-menu-item:hover {
  background-color: #F8FAFC;
  color: #0F172A;
}

.biz-book-menu-item.text-danger {
  color: #DC2626;
}

.biz-book-menu-item.text-danger:hover {
  background-color: #FEF2F2;
  color: #B91C1C;
}

.biz-book-menu-item svg {
  flex-shrink: 0;
}

@keyframes fadeInMenu {
  from {
    opacity: 0;
    transform: translateY(-4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Responsif Mobile untuk Kartu Buku Kas Sesuai Gambar 2 */
@media (max-width: 768px) {
  .biz-dash-toolbar {
    gap: 10px;
  }

  .biz-search-box {
    max-width: 100%;
    min-width: 0;
    width: 100%;
    order: 1;
  }

  .biz-sort-wrapper {
    flex: 1;
    min-width: 0;
    order: 2;
  }

  .biz-sort-select {
    width: 100%;
    font-size: 0.82rem;
    padding: 8px 32px 8px 12px;
    height: 40px;
  }

  .btn-biz-add-book {
    margin-left: 0;
    order: 3;
    height: 40px;
    padding: 0 16px;
    font-size: 0.84rem;
  }

  .biz-book-card {
    padding: 12px 14px;
    gap: 12px;
    border-radius: 10px;
  }

  .biz-book-left {
    gap: 12px;
    flex: 1;
    min-width: 0;
  }

  .biz-book-avatar {
    width: 38px;
    height: 38px;
    border-radius: 8px;
    font-size: 1.1rem;
    flex-shrink: 0;
  }

  .biz-book-avatar svg {
    width: 20px;
    height: 20px;
  }

  .biz-book-info {
    gap: 2px;
    flex: 1;
    min-width: 0;
  }

  .biz-book-title {
    font-size: 0.95rem;
    font-weight: 700;
    line-height: 1.25;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .biz-book-sub {
    font-size: 0.78rem;
    color: #64748B;
    line-height: 1.2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .biz-book-right {
    gap: 8px;
    flex-shrink: 0;
    align-items: center;
  }

  .biz-book-balance {
    font-size: 0.92rem;
    font-weight: 700;
    white-space: nowrap;
    text-align: right;
  }

  .biz-book-actions {
    display: none !important;
  }

  .biz-book-more-wrapper {
    display: block;
  }
}

/* Preset Quick Add Card Sesuai Gambar 1 */
.biz-preset-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 4px;
}

.biz-preset-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.preset-icon-stacked {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: #E6F4EA;
  display: grid;
  place-items: center;
  font-size: 1.25rem;
  flex-shrink: 0;
}

.preset-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #0F172A;
}

.preset-sub {
  font-size: 0.78rem;
  color: #64748B;
}

.preset-pills-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-preset-pill {
  background: #EEF2FF;
  border: 1px solid #C7D2FE;
  color: #4F46E5;
  border-radius: 9999px;
  padding: 8px 18px;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-preset-pill:hover {
  background: #E0E7FF;
  transform: translateY(-1px);
}

/* Promo Card Sesuai Gambar 1 */
.biz-promo-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 14px;
  padding: 22px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
}

.promo-icon-box {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: #ECFDF5;
  display: grid;
  place-items: center;
}

.promo-title {
  font-size: 0.95rem;
  font-weight: 800;
  color: #0F172A;
  line-height: 1.35;
  margin: 0;
}

.promo-desc {
  font-size: 0.8rem;
  color: #64748B;
  line-height: 1.45;
  margin: 0;
}

.promo-link {
  color: #4F46E5;
  font-size: 0.86rem;
  font-weight: 700;
  text-decoration: none;
  margin-top: 4px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  transition: color 0.15s ease;
}

.promo-link:hover {
  text-decoration: underline;
  color: #4338CA;
}

/* Content Body */
.content-body {
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
  overflow-x: hidden;
}

.content-body.hidden {
  display: none !important;
}

/* ==========================================================================
   Inner Book Header & Actions (Sesuai Gambar 2 & 5)
   ========================================================================== */
.book-inner-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 4px 0 2px;
}

.book-inner-title-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.btn-book-back {
  background: transparent;
  border: none;
  font-size: 1.25rem;
  font-weight: 700;
  color: #1E293B;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.15s ease;
}

.btn-book-back:hover {
  background: #F1F5F9;
  color: #4F46E5;
}

.book-name-heading {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0F172A;
}

.btn-book-action-icon {
  background: transparent;
  border: none;
  color: #4F46E5;
  width: 32px;
  height: 32px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-book-action-icon:hover {
  background: #EEF2FF;
  transform: rotate(20deg);
}

.book-inner-actions-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-bulk-entries {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  color: #4F46E5;
  font-size: 0.84rem;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.btn-bulk-entries:hover {
  background: #EEF2FF;
  border-color: #C7D2FE;
  transform: translateY(-1px);
}

/* Reports Dropdown Container & Menu (Gambar 5) */
.reports-dropdown-container {
  position: relative;
  display: inline-flex;
}

.btn-reports-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  color: #4F46E5;
  font-size: 0.84rem;
  font-weight: 600;
  padding: 7px 16px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.btn-reports-trigger:hover {
  background: #EEF2FF;
  border-color: #C7D2FE;
  transform: translateY(-1px);
}

.reports-dropdown-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  width: 170px;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.04);
  z-index: 120;
  overflow: hidden;
  padding: 6px 0;
  animation: slideUp 0.15s cubic-bezier(0.16, 1, 0.3, 1);
}

.reports-dropdown-menu.hidden {
  display: none !important;
}

.report-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 14px;
  border: none;
  background: transparent;
  color: #1E293B;
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
  text-align: left;
}

.report-menu-item:hover {
  background: #F8FAFC;
  color: #4F46E5;
}

.report-icon-badge {
  font-size: 0.65rem;
  font-weight: 800;
  border: 1.5px solid #475569;
  color: #475569;
  border-radius: 3px;
  padding: 1px 4px;
  line-height: 1;
}

.report-icon-badge.badge-excel {
  border: none;
  color: #107C41;
  display: grid;
  place-items: center;
  padding: 0;
}


/* ==========================================================================
   Book Settings View (Sesuai Gambar 3)
   ========================================================================== */
.book-settings-view {
  padding: 24px 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  animation: fadeIn 0.2s ease;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.book-settings-view.hidden {
  display: none !important;
}

.settings-top-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #F1F5F9;
  padding-bottom: 16px;
  gap: 16px;
  flex-wrap: wrap;
}

.settings-title-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-settings-back {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.15s ease;
  color: #334155;
}

.btn-settings-back:hover {
  background: #F1F5F9;
  color: #4F46E5;
  transform: translateX(-2px);
}

.settings-main-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #0F172A;
  display: flex;
  align-items: center;
  gap: 8px;
}

.settings-book-subtitle {
  font-size: 0.95rem;
  font-weight: 500;
  color: #64748B;
}

.settings-header-actions-right {
  display: flex;
  align-items: center;
  gap: 16px;
}

.btn-settings-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: transparent;
  border: none;
  font-size: 0.86rem;
  font-weight: 600;
  color: #4F46E5;
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 6px;
  transition: all 0.15s ease;
}

.btn-settings-action:hover {
  background: #EEF2FF;
}

.btn-settings-action.text-danger {
  color: #DC2626;
}

.btn-settings-action.text-danger:hover {
  background: #FEF2F2;
}

.settings-body-layout {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 36px;
  min-height: 380px;
}

@media (max-width: 768px) {
  .settings-body-layout {
    grid-template-columns: 1fr;
  }
}

.settings-sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-right: 1px solid #F1F5F9;
  padding-right: 20px;
}

.settings-nav-item {
  padding: 12px 14px;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  cursor: pointer;
}

.settings-nav-item.active {
  background: #EEF2FF;
  border-left: 3.5px solid #4F46E5;
}

.settings-nav-title {
  font-size: 0.9rem;
  font-weight: 700;
  color: #1E293B;
}

.settings-nav-desc {
  font-size: 0.74rem;
  color: #64748B;
  line-height: 1.35;
}

.settings-content-pane {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: 680px;
}

.settings-pane-header h3 {
  font-size: 0.82rem;
  font-weight: 700;
  color: #64748B;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.settings-card-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.settings-field-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 0.15s ease;
}

.settings-field-card.clickable {
  cursor: pointer;
}

.settings-field-card.clickable:hover {
  border-color: #CBD5E1;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
  transform: translateY(-1px);
}

.field-card-info {
  display: flex;
  flex-direction: column;
}

.field-card-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #0F172A;
}

.field-card-sub {
  font-size: 0.78rem;
  color: #64748B;
  margin-top: 3px;
}

.field-card-badge {
  background: #EEF2FF;
  color: #4F46E5;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 9999px;
  border: 1px solid #C7D2FE;
  transition: all 0.15s ease;
}

.field-card-badge.off {
  background: #F1F5F9;
  color: #64748B;
  border-color: #CBD5E1;
}

/* ==========================================================================
   Bulk Entries / Import Entries View (Sesuai Gambar 4)
   ========================================================================== */
.bulk-entries-view {
  padding: 24px 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  animation: fadeIn 0.2s ease;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.bulk-entries-view.hidden {
  display: none !important;
}

.bulk-top-header {
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid #F1F5F9;
  padding-bottom: 16px;
}

.btn-bulk-back {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.15s ease;
  color: #334155;
}

.btn-bulk-back:hover {
  background: #F1F5F9;
  color: #4F46E5;
  transform: translateX(-2px);
}

.bulk-main-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #0F172A;
  display: flex;
  align-items: center;
  gap: 8px;
}

.bulk-book-subtitle {
  font-size: 0.95rem;
  font-weight: 500;
  color: #64748B;
}

.bulk-body-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
  max-width: 680px;
}

.bulk-form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.bulk-input-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #475569;
}

.bulk-file-input-wrapper {
  border: 1.5px solid #4F46E5;
  border-radius: 8px;
  padding: 8px 12px;
  background: #FFFFFF;
  display: flex;
  align-items: center;
}

.bulk-file-input {
  font-size: 0.86rem;
  cursor: pointer;
  width: 100%;
}

.download-sample-card {
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.sample-card-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.excel-icon-box {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: #E6F4EA;
  flex-shrink: 0;
}

.sample-title {
  font-size: 0.88rem;
  font-weight: 700;
  color: #0F172A;
  display: block;
}

.sample-desc {
  font-size: 0.78rem;
  color: #64748B;
  display: block;
}

.btn-download-sample-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #FFFFFF;
  border: 1px solid #CBD5E1;
  color: #4F46E5;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.btn-download-sample-action:hover {
  background: #EEF2FF;
  border-color: #C7D2FE;
}

.bulk-preview-container {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.bulk-preview-container.hidden {
  display: none !important;
}

.bulk-preview-container h4 {
  font-size: 0.88rem;
  font-weight: 700;
  color: #1E293B;
}

.bulk-footer-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 10px;
}

.btn-bulk-cancel {
  padding: 9px 20px;
  font-weight: 600;
}

.btn-bulk-next {
  background: #4F46E5;
  color: #FFFFFF;
  padding: 10px 22px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.88rem;
  border: none;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-bulk-next:hover {
  background: #4338CA;
}

/* ==========================================================================
   Inner Cashbook Display (Modern Refined Ledger System)
   Sesuai Referensi Gambar Pengguna
   ========================================================================== */

/* 1. Top Filter Row (Pills: Duration, Types, Members, Payment Modes, Categories) */
.top-filter-bar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 10px;
  margin-bottom: 4px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.filter-pill-wrapper {
  position: relative;
  display: inline-flex;
}

.filter-pill-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 9999px;
  padding: 8px 34px 8px 16px;
  font-size: 0.84rem;
  font-weight: 500;
  color: #475569;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 13px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
}

.filter-pill-select:hover {
  border-color: #CBD5E1;
  background-color: #F8FAFC;
  color: #1E293B;
}

.filter-pill-select:focus {
  outline: none;
  border-color: #059669;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.12);
}

.btn-reset-filters {
  background: transparent;
  border: 1px solid #E2E8F0;
  color: #64748B;
  border-radius: 9999px;
  padding: 8px 16px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-reset-filters:hover {
  background: #F1F5F9;
  color: #0F172A;
  border-color: #CBD5E1;
}

/* Custom Date Range Controls */
.custom-date-container {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 9999px;
  padding: 4px 14px;
}

.custom-date-container.hidden {
  display: none !important;
}

.date-control {
  border: none;
  background: transparent;
  font-size: 0.82rem;
  color: #1E293B;
  font-family: inherit;
  outline: none;
}

.date-separator {
  font-size: 0.78rem;
  color: #94A3B8;
  font-weight: 500;
}

/* 2. Action & Search Row (Search Input on Left, + Cash In / — Cash Out on Right) */
.action-search-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.search-input-box {
  position: relative;
  width: 420px;
  max-width: 100%;
  display: flex;
  align-items: center;
}

.search-box-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #94A3B8;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 2;
  width: 18px;
  height: 18px;
}

.search-input-box input,
.search-input-box input[type="text"],
#searchInput {
  width: 100%;
  height: 44px;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  padding: 8px 44px 8px 44px !important;
  font-size: 0.88rem;
  color: #1E293B;
  font-family: inherit;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.02);
}

.search-input-box input::placeholder,
#searchInput::placeholder {
  color: #94A3B8;
  font-size: 0.86rem;
}

.search-input-box input:focus,
#searchInput:focus {
  outline: none;
  border-color: #059669;
  background: #FFFFFF;
  box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.12);
}

.search-shortcut-badge {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  color: #94A3B8;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 6px;
  line-height: 1.2;
  pointer-events: none;
  z-index: 2;
}

.main-cash-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.btn-pill-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 24px;
  min-height: 44px;
  border-radius: 8px;
  font-size: 0.92rem;
  font-weight: 700;
  color: #FFFFFF;
  border: none;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  letter-spacing: 0.01em;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.btn-pill-cashin {
  background-color: #057A55; /* Solid Deep Forest Green */
}

.btn-pill-cashin:hover {
  background-color: #046C4E;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(5, 122, 85, 0.28);
}

.btn-pill-cashout {
  background-color: #C81E1E; /* Solid Deep Crimson Red */
}

.btn-pill-cashout:hover {
  background-color: #9B1C1C;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(200, 30, 30, 0.28);
}

.btn-pill-action:active {
  transform: scale(0.98);
}

.action-symbol {
  font-size: 1.05rem;
  font-weight: 800;
  line-height: 1;
}

.action-text {
  font-size: 0.92rem;
  font-weight: 700;
}

/* 3. Summary Strip Card (Unified 3-Column Horizontal Card: Cash In | Cash Out | Net Balance) */
.summary-strip-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 14px;
  display: flex;
  align-items: center;
  padding: 16px 24px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.03);
}

.strip-column {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 4px 18px;
}

.strip-v-divider {
  width: 1px;
  height: 48px;
  background: #E2E8F0;
  flex-shrink: 0;
}

.strip-icon-circle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.bg-icon-in {
  background-color: #E6F4EA;
  color: #137333;
}

.bg-icon-out {
  background-color: #FCE8E6;
  color: #C5221F;
}

.bg-icon-balance {
  background-color: #E8F0FE;
  color: #1A73E8;
}

.strip-glyph {
  font-size: 1.05rem;
  font-weight: 800;
  line-height: 1;
}

.strip-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.strip-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: #334155;
}

.strip-value {
  font-size: 1.45rem;
  font-weight: 800;
  color: #0F172A;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

/* 4. Table Toolbar & Pagination Header Row */
.table-entries-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 2px;
  color: #64748B;
  font-size: 0.84rem;
}

.entries-counter-text {
  font-weight: 500;
  color: #64748B;
}

.entries-pagination-box {
  display: flex;
  align-items: center;
  gap: 8px;
}

.page-dropdown-container {
  position: relative;
  display: inline-flex;
}

.page-dropdown-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 6px;
  padding: 4px 24px 4px 10px;
  font-size: 0.78rem;
  font-weight: 500;
  color: #475569;
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 6px center;
  background-size: 12px;
}

.page-of-text {
  font-size: 0.78rem;
  color: #64748B;
}

.page-nav-arrow-btns {
  display: flex;
  align-items: center;
  gap: 4px;
}

.btn-nav-arrow {
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 6px;
  font-size: 1.1rem;
  font-weight: 700;
  color: #64748B;
  cursor: pointer;
  transition: all 0.15s ease;
  line-height: 1;
}

.btn-nav-arrow:hover:not(:disabled) {
  background: #F8FAFC;
  border-color: #CBD5E1;
  color: #1E293B;
}

.btn-nav-arrow:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: #F8FAFC;
}

/* 5. Ledger Table Card & Rows */
.ledger-table-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.02);
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.table-responsive {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.ledger-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  table-layout: fixed;
}

.ledger-table .th-datetime,
.ledger-table .col-datetime {
  width: 125px;
}

.ledger-table .th-category,
.ledger-table .col-category {
  width: 130px;
}

.ledger-table .th-mode,
.ledger-table .col-mode {
  width: 120px;
}

.ledger-table .th-bill,
.ledger-table .col-bill {
  width: 72px;
}

.ledger-table .th-amount,
.ledger-table .col-amount {
  width: 125px;
}

.ledger-table .th-balance,
.ledger-table .col-balance {
  width: 165px;
}

.ledger-table thead tr {
  background-color: #F8FAFD; /* Soft light blue/lavender tint */
  border-bottom: 1px solid #E2E8F0;
}

.ledger-table th {
  padding: 14px 16px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #64748B;
  white-space: nowrap;
}

.ledger-table td {
  padding: 14px 16px;
  border-bottom: 1px solid #F1F5F9;
  font-size: 0.86rem;
  vertical-align: middle;
  color: #1E293B;
  transition: background-color 0.15s ease;
}

.ledger-table tbody tr:hover td {
  background-color: #FBFCFE;
}

.ledger-table tbody tr.row-selected td {
  background-color: #F0FDF4;
}

.th-cb, .col-cb {
  width: 42px;
  text-align: center;
  padding-left: 18px;
  padding-right: 8px;
}

.row-checkbox {
  width: 17px;
  height: 17px;
  border-radius: 4px;
  border: 1.5px solid #CBD5E1;
  accent-color: #4F46E5;
  cursor: pointer;
}

/* Bulk Selection Action Header Row (Sesuai Gambar 3 & 4) */
.bulk-header-row {
  background-color: #F0F4FE !important; /* Soft light periwinkle/blue tint */
  border-bottom: 1px solid #E2E8F0 !important;
}

.th-bulk-container {
  padding: 10px 18px !important;
  font-weight: normal;
  text-align: left;
}

.bulk-header-bar {
  display: flex;
  align-items: center;
  gap: 16px;
}

.bulk-select-all-box {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 600;
  color: #334155;
  user-select: none;
}

.bulk-v-divider {
  width: 1px;
  height: 20px;
  background-color: #CBD5E1;
}

.btn-bulk-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  border: none;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: 8px;
  transition: all 0.15s ease;
  font-family: inherit;
  color: #1E293B;
}

.btn-bulk-delete:hover {
  background: rgba(239, 68, 68, 0.08);
  color: #DC2626;
}

.btn-bulk-move-copy {
  color: #4F46E5;
}

.btn-bulk-move-copy:hover {
  background: rgba(79, 70, 229, 0.08);
}

.bulk-caret {
  margin-left: 2px;
}

.bulk-dropdown-container {
  position: relative;
  display: inline-flex;
}

/* Popover Menu Move or Copy (Sesuai Gambar 4) */
.bulk-popover-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.12), 0 8px 10px -6px rgba(0, 0, 0, 0.08);
  min-width: 220px;
  padding: 6px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 2px;
  animation: fadeIn 0.15s ease;
}

.bulk-popover-menu.hidden {
  display: none !important;
}

.bulk-menu-option {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 10px 14px;
  border: none;
  background: transparent;
  color: #1E293B;
  font-size: 0.88rem;
  font-weight: 500;
  border-radius: 8px;
  cursor: pointer;
  text-align: left;
  transition: all 0.15s ease;
  font-family: inherit;
}

.bulk-menu-option:hover {
  background: #F1F5F9;
  color: #0F172A;
}

.bulk-menu-option svg {
  color: #64748B;
  flex-shrink: 0;
}

.bulk-menu-option:hover svg {
  color: #4F46E5;
}

.entries-selected-divider {
  margin: 0 8px;
  color: #CBD5E1;
  font-weight: 300;
}

.entries-selected-count {
  font-weight: 600;
  color: #334155;
}

.col-datetime .date-primary {
  font-weight: 600;
  color: #1E293B;
  font-size: 0.86rem;
}

.col-datetime .time-sub {
  font-size: 0.76rem;
  color: #64748B;
  margin-top: 2px;
}

.col-details {
  min-width: 0;
  overflow: hidden;
}

.col-details .details-desc {
  font-weight: 500;
  color: #1E293B;
  font-size: 0.86rem;
  display: block;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.details-contact {
  font-weight: 600;
  color: #1E293B;
  font-size: 0.88rem;
  line-height: 1.3;
  display: block;
  max-width: 100%;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.contact-type-badge {
  color: #64748B;
  font-size: 0.76rem;
  font-weight: 500;
}

.cell-text-plain {
  font-weight: 500;
  color: #1E293B;
  font-size: 0.86rem;
}

.cell-text-muted {
  color: #94A3B8;
  font-size: 0.86rem;
}

.th-amount, .th-balance, .col-amount, .col-balance {
  text-align: right;
  white-space: nowrap;
}

.balance-cell-wrapper {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  width: 100%;
}

.balance-cell-primary {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.row-edited-tag {
  font-size: 0.72rem;
  font-weight: 500;
  color: #94A3B8;
  white-space: nowrap;
}

.row-hover-actions {
  display: none !important;
}

@media (hover: hover) and (min-width: 769px) {
  .ledger-table tbody tr:hover {
    background-color: #F0F7FF !important;
  }
  
  .ledger-table tbody tr:hover .row-hover-actions {
    display: inline-flex !important;
    align-items: center;
    gap: 4px;
    margin-left: 6px;
  }
}

.btn-row-action {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 4px;
  padding: 3px 5px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #64748B;
  transition: all 0.15s ease;
}

.btn-row-action:hover {
  background: #F8FAFC;
  color: #1E293B;
  border-color: #CBD5E1;
}

.btn-row-action.btn-row-delete:hover {
  background: #FEF2F2;
  color: #DC2626;
  border-color: #FECACA;
}

.ledger-table td.col-amount.amount-in,
.ledger-table td.amount-in,
.col-amount.amount-in,
.amount-val.amount-in,
.amount-in {
  color: #057A55 !important;
  font-weight: 700 !important;
}

.ledger-table td.col-amount.amount-out,
.ledger-table td.amount-out,
.col-amount.amount-out,
.amount-val.amount-out,
.amount-out {
  color: #C81E1E !important;
  font-weight: 700 !important;
}

.balance-val {
  color: #1E293B;
  font-weight: 600;
}

/* Desktop default for mobile card elements in cashbookTable */
#cashbookTable .col-mobile-card {
  display: none !important;
}

#cashbookTable .mobile-date-divider {
  display: none !important;
}

/* Khusus Tabel Transaksi Buku Kas di Mobile (#cashbookTable) Sesuai Gambar 1 */
@media (max-width: 768px) {
  .ledger-table-card .table-responsive {
    overflow-x: visible;
  }

  #cashbookTable {
    display: block !important;
    width: 100% !important;
    border: none !important;
  }

  #cashbookTable thead {
    display: none !important;
  }

  #cashbookTable tbody {
    display: block !important;
    width: 100% !important;
  }

  #cashbookTable tbody tr {
    display: block !important;
    width: 100% !important;
    border-bottom: 1px solid #F1F5F9;
    background: #FFFFFF;
    transition: background-color 0.15s ease;
  }

  #cashbookTable tbody tr:last-child {
    border-bottom: none;
  }

  #cashbookTable tbody tr:hover {
    background-color: #F8FAFC !important;
  }

  #cashbookTable tbody tr.row-selected {
    background-color: #F0FDF4 !important;
  }

  /* Sembunyikan kolom desktop pada tabel transaksi buku kas */
  #cashbookTable .col-desktop-only {
    display: none !important;
  }

  /* Tampilkan kartu transaksi mobile */
  #cashbookTable .col-mobile-card {
    display: block !important;
    width: 100% !important;
    padding: 0 !important;
    border: none !important;
    background: transparent !important;
    box-sizing: border-box;
  }

  /* Header Tanggal Pemisah Antar Hari Sesuai Gambar 1 */
  #cashbookTable .mobile-date-divider {
    display: block !important;
    width: 100%;
    padding: 6px 16px;
    font-size: 0.78rem;
    font-weight: 600;
    color: #475569;
    background: #F1F5F9;
    border-top: 1px solid #E2E8F0;
    border-bottom: 1px solid #E2E8F0;
    letter-spacing: 0.01em;
    box-sizing: border-box;
  }

  #cashbookTable tbody tr:first-child .mobile-date-divider {
    border-top: none;
  }

  /* Wadah Kartu Transaksi Mobile */
  #cashbookTable .mobile-tx-card-inner {
    padding: 14px 16px;
    display: flex;
    flex-direction: column;
    gap: 6px;
  }

  /* Baris Atas: Kategori, Mode & Nominal Sesuai Gambar 1 */
  #cashbookTable .mobile-tx-top-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
  }

  #cashbookTable .mobile-tx-chips {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    flex: 1;
    min-width: 0;
  }

  #cashbookTable .mobile-chip {
    display: inline-flex;
    align-items: center;
    padding: 2.5px 8px;
    border-radius: 6px;
    font-size: 0.74rem;
    font-weight: 600;
    line-height: 1.25;
    white-space: nowrap;
  }

  #cashbookTable .mobile-chip-category {
    background: #EEF2FF;
    color: #4F46E5;
    border: 1px solid rgba(79, 70, 229, 0.15);
  }

  #cashbookTable .mobile-chip-mode {
    background: #E0F2FE;
    color: #0284C7;
    border: 1px solid rgba(2, 132, 199, 0.15);
  }

  #cashbookTable .mobile-chip-contact {
    background: #F1F5F9;
    color: #334155;
    border: 1px solid #E2E8F0;
  }

  #cashbookTable .mobile-tx-amount {
    font-size: 1.05rem;
    font-weight: 800;
    text-align: right;
    white-space: nowrap;
    flex-shrink: 0;
    letter-spacing: -0.01em;
    line-height: 1.2;
  }

  #cashbookTable .mobile-tx-amount.amount-in {
    color: #057A55 !important;
  }

  #cashbookTable .mobile-tx-amount.amount-out {
    color: #C81E1E !important;
  }

  /* Baris Tengah: Deskripsi/Remark & Saldo Berjalan Sesuai Gambar 1 */
  #cashbookTable .mobile-tx-mid-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
  }

  #cashbookTable .mobile-tx-desc {
    font-size: 0.86rem;
    color: #1E293B;
    line-height: 1.38;
    flex: 1;
    min-width: 0;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
  }

  #cashbookTable .mobile-tx-balance {
    font-size: 0.78rem;
    color: #64748B;
    font-weight: 500;
    text-align: right;
    white-space: nowrap;
    flex-shrink: 0;
    line-height: 1.2;
  }

  #cashbookTable .mobile-tx-bal-label {
    color: #64748B;
    margin-right: 2px;
  }

  #cashbookTable .mobile-tx-bal-val {
    color: #334155;
    font-weight: 600;
  }

  /* Baris Bawah: Meta Penulis, Waktu & Lampiran Sesuai Gambar 1 */
  #cashbookTable .mobile-tx-bottom-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 2px;
  }

  #cashbookTable .mobile-tx-meta {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.78rem;
    flex-wrap: wrap;
    line-height: 1.2;
  }

  #cashbookTable .mobile-tx-author {
    color: #E11D48;
    font-weight: 600;
  }

  #cashbookTable .mobile-tx-time {
    color: #64748B;
    font-weight: 400;
  }

  #cashbookTable .mobile-tx-attach {
    flex-shrink: 0;
  }
}

.col-actions {
  text-align: center;
  white-space: nowrap;
  width: 80px;
}

.btn-action {
  background: #F1F5F9;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 5px 8px;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.18s ease;
  margin: 0 2px;
}

.btn-action:hover {
  transform: scale(1.1);
  background: white;
  box-shadow: var(--shadow-xs);
}

.btn-action.btn-delete:hover {
  background: var(--cash-out-bg);
  border-color: var(--cash-out-border);
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 48px 24px;
}

.empty-icon {
  font-size: 3rem;
  margin-bottom: 12px;
  opacity: 0.8;
}

.empty-state h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
}

.empty-state p {
  font-size: 0.85rem;
  color: var(--text-muted);
  max-width: 360px;
  margin: 4px auto 0;
}

/* Responsiveness */
@media (max-width: 1024px) {
  .summary-strip-card {
    flex-direction: column;
    align-items: stretch;
    gap: 14px;
    padding: 16px;
  }
  .strip-v-divider {
    width: 100%;
    height: 1px;
  }
  .strip-column {
    padding: 4px 0;
  }
  .search-input-box {
    width: 100%;
  }
}

@media (max-width: 768px) {
  .content-body {
    padding-bottom: calc(84px + env(safe-area-inset-bottom));
  }
  .action-search-row {
    flex-direction: column;
    align-items: stretch;
  }
  .main-cash-actions {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    padding: 10px 16px calc(10px + env(safe-area-inset-bottom));
    background: #FFFFFF;
    border-top: 1px solid #E2E8F0;
    box-shadow: 0 -4px 16px rgba(15, 23, 42, 0.08);
    z-index: 85;
    box-sizing: border-box;
  }
  .main-cash-actions.mobile-bar-hidden {
    display: none !important;
  }
  .entries-pagination-box {
    display: none !important;
  }
  .table-entries-toolbar {
    justify-content: center;
  }
  .entries-counter-text {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
    font-size: 0.78rem;
    color: #64748B;
  }
  .entries-counter-text::before,
  .entries-counter-text::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #E2E8F0;
  }
  .mobile-infinite-sentinel {
    height: 1px;
    width: 100%;
  }
}

/* ==========================================================================
   Modals & Form Styling (Standarisasi Global)
   ========================================================================== */
dialog {
  border: none;
  background: transparent;
  padding: 0;
  margin: auto;
  max-width: 95vw;
  outline: none;
}

dialog::backdrop {
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(6px);
  animation: fadeIn 0.2s ease;
}

/* Standarisasi Jendela Modal Global (Premium Container) */
.modal-content {
  background: #FFFFFF;
  border-radius: 16px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.08), 0 10px 10px -5px rgba(0, 0, 0, 0.03);
  border: 1px solid rgba(226, 232, 240, 0.85);
  overflow: hidden;
  animation: modalPop 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  width: 100%;
  max-width: 500px;
}

.modal-settings .modal-content {
  max-width: 620px;
}

.modal-header {
  padding: 20px 24px;
  border-bottom: 1px solid #F1F5F9;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #FFFFFF;
}

.modal-header h3 {
  font-size: 1.15rem;
  font-weight: 800;
  color: #0F172A;
  letter-spacing: -0.01em;
  margin: 0;
}

.modal-subtitle {
  font-size: 0.8rem;
  color: #64748B;
  margin: 3px 0 0 0;
}

/* Tombol Silang (X) Lingkaran Minimalis */
.btn-close,
.btn-close-modal {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-radius: 50%;
  font-size: 1.25rem;
  color: #94A3B8;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  padding: 0;
  line-height: 1;
}

.btn-close:hover,
.btn-close-modal:hover {
  background: #F1F5F9;
  color: #0F172A;
  transform: scale(1.05);
}

.btn-close:active,
.btn-close-modal:active {
  transform: scale(0.95);
  background: #E2E8F0;
}

/* Form Container didalam Modal */
.modal-content > form {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.modal-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

@media (max-width: 520px) {
  .form-row {
    grid-template-columns: 1fr;
  }
}

.form-group label {
  font-size: 0.82rem;
  font-weight: 700;
  color: #334155;
  display: flex;
  align-items: center;
  gap: 4px;
}

.form-group label .required {
  color: #EF4444;
  font-weight: 800;
}

/* Input Fields & Dropdowns Interaktif (Interactive Fields & Selectors) */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="date"],
input[type="datetime-local"],
select,
textarea,
.form-control {
  width: 100%;
  min-height: 42px;
  padding: 10px 14px;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  background: #FFFFFF;
  color: #0F172A;
  font-size: 0.9rem;
  font-family: inherit;
  font-weight: 500;
  transition: border-color 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s cubic-bezier(0.16, 1, 0.3, 1), background-color 0.2s ease;
  box-sizing: border-box;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="number"]:focus,
input[type="date"]:focus,
input[type="datetime-local"]:focus,
select:focus,
textarea:focus,
.form-control:focus {
  outline: none;
  border-color: #3B82F6;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.12);
  background: #FFFFFF;
}

input::placeholder,
textarea::placeholder,
.form-control::placeholder {
  color: #94A3B8;
  opacity: 1;
}

/* Custom Dropdown Chevron Icon */
select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2364748B' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 14px 14px;
  padding-right: 36px;
  cursor: pointer;
}

textarea {
  min-height: 80px;
  resize: vertical;
  line-height: 1.5;
}

/* Nominal Input Styling */
.input-currency-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.input-currency-wrapper .currency-prefix {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-weight: 800;
  font-size: 1.05rem;
  color: #64748B;
  pointer-events: none;
  user-select: none;
}

.input-currency-wrapper input {
  padding-left: 46px;
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #0F172A;
}

.hint-preview {
  font-size: 0.85rem;
  font-weight: 700;
  color: #10B981;
  margin-top: 4px;
  padding-left: 2px;
  transition: color 0.2s ease;
}

.hint-preview.is-out {
  color: #EF4444;
}

/* Modal Footer & Button Placement */
.modal-footer {
  padding: 16px 24px;
  border-top: 1px solid #F1F5F9;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  background: #F8FAFC;
}

.modal-content > form .modal-footer {
  margin: 8px -24px -24px -24px;
}

/* In-Modal Segmented Toggle: KAS MASUK vs KAS KELUAR */
.type-toggle-group {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: #F1F5F9;
  padding: 5px;
  border-radius: 12px;
  gap: 6px;
  margin-bottom: 4px;
}

.toggle-tab {
  padding: 10px 14px;
  border: none;
  background: transparent;
  font-weight: 700;
  font-size: 0.85rem;
  border-radius: 9px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  color: #64748B;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.toggle-tab:hover:not(.active-in):not(.active-out) {
  color: #0F172A;
  background: rgba(255, 255, 255, 0.6);
}

.toggle-tab.active-in {
  background: #FFFFFF;
  color: #10B981;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05);
  font-weight: 800;
}

.toggle-tab.active-out {
  background: #FFFFFF;
  color: #EF4444;
  box-shadow: 0 2px 8px rgba(239, 68, 68, 0.15), 0 1px 2px rgba(0, 0, 0, 0.05);
  font-weight: 800;
}

/* ==========================================================================
   Master Data Settings Modal
   ========================================================================== */
.settings-tabs-nav {
  display: flex;
  background: #F1F5F9;
  padding: 6px 8px;
  gap: 6px;
  border-bottom: 1px solid #E2E8F0;
}

.settings-tab-btn {
  flex: 1;
  padding: 9px 12px;
  background: transparent;
  border: none;
  border-radius: 9px;
  font-size: 0.84rem;
  font-weight: 600;
  color: #64748B;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.settings-tab-btn:hover:not(.active) {
  color: #0F172A;
  background: rgba(255, 255, 255, 0.6);
}

.settings-tab-btn.active {
  background: #FFFFFF;
  color: var(--primary-color);
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.06);
}

.settings-modal-body {
  padding: 24px;
}

.settings-pane {
  display: flex;
  flex-direction: column;
}

.cat-type-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: #F1F5F9;
  padding: 4px;
  border-radius: 10px;
  gap: 6px;
  margin-bottom: 16px;
}

.cat-type-btn {
  padding: 8px 12px;
  border: none;
  background: transparent;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #64748B;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  text-align: center;
}

.cat-type-btn:hover:not(.active-in):not(.active-out) {
  color: #0F172A;
  background: rgba(255, 255, 255, 0.6);
}

.cat-type-btn.active-in {
  background: #FFFFFF;
  color: #10B981;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(16, 185, 129, 0.15);
}

.cat-type-btn.active-out {
  background: #FFFFFF;
  color: #EF4444;
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(239, 68, 68, 0.15);
}

.settings-add-box {
  display: flex;
  gap: 10px;
  margin-bottom: 16px;
}

.settings-add-box input {
  flex: 1;
}

.settings-list-container {
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  background: #F8FAFC;
  padding: 14px;
  max-height: 240px;
  overflow-y: auto;
}

.list-meta-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  font-size: 0.8rem;
  font-weight: 700;
  color: #475569;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.settings-items-ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 0;
  margin: 0;
}

.master-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 9px;
  padding: 9px 14px;
  font-size: 0.86rem;
  font-weight: 600;
  color: #1E293B;
  transition: all 0.18s ease;
}

.master-item:hover {
  border-color: #CBD5E1;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
  background: #FFFFFF;
}

.master-item-name {
  font-weight: 600;
  color: #1E293B;
}

.btn-delete-master {
  background: transparent;
  border: none;
  color: #94A3B8;
  font-size: 1.2rem;
  cursor: pointer;
  padding: 3px 8px;
  border-radius: 6px;
  line-height: 1;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-delete-master:hover {
  color: #EF4444;
  background: #FEE2E2;
  transform: scale(1.1);
}

.btn-delete-master:active {
  transform: scale(0.95);
}

.empty-list-item {
  text-align: center;
  padding: 24px;
  color: #94A3B8;
  font-size: 0.85rem;
  font-style: italic;
}

.section-hint {
  font-size: 0.84rem;
  color: #64748B;
  margin-bottom: 14px;
  line-height: 1.4;
}

.data-option-buttons {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ==========================================================================
   Button Hierarchy & Utilities (Primary vs Secondary/Cancel)
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 18px;
  border-radius: 10px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  border: 1px solid transparent;
  white-space: nowrap;
  text-decoration: none;
  user-select: none;
  box-sizing: border-box;
}

.btn-sm {
  padding: 7px 14px;
  font-size: 0.82rem;
  border-radius: 8px;
}

/* Tombol Aksi Utama: Luxury Gradient, Hover Elevation & Active Micro-press */
.btn-primary {
  background: linear-gradient(135deg, #1999E2 0%, #086EA8 100%);
  color: #FFFFFF;
  box-shadow: 0 2px 6px rgba(14, 138, 217, 0.25);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #0C7BC7 0%, #02599D 100%);
  transform: translateY(-1.5px);
  box-shadow: 0 6px 16px rgba(14, 138, 217, 0.35);
}

.btn-primary:active {
  transform: scale(0.98) translateY(0);
  box-shadow: 0 2px 4px rgba(14, 138, 217, 0.2);
}

/* Tombol Outline Standar */
.btn-outline {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  color: #334155;
  border-radius: 10px;
}

.btn-outline:hover {
  background: #F8FAFC;
  border-color: #CBD5E1;
  color: #0F172A;
  transform: translateY(-1px);
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.btn-outline:active {
  transform: scale(0.98) translateY(0);
}

/* Tombol Ghost / Sekunder (Batal / Tutup): Tanpa border kaku, hover abu lembut */
.btn-ghost {
  background: transparent;
  border: 1px solid transparent;
  color: #64748B;
}

.btn-ghost:hover {
  background: #F1F5F9;
  color: #0F172A;
  transform: translateY(-1px);
  border-color: transparent;
}

.btn-ghost:active {
  transform: scale(0.98) translateY(0);
  background: #E2E8F0;
}

/* Tombol Batal pada Footer Modal */
.modal-footer .btn-outline {
  background: transparent;
  border: 1px solid transparent;
  color: #64748B;
  font-weight: 600;
}

.modal-footer .btn-outline:hover {
  background: #F1F5F9;
  color: #0F172A;
  transform: translateY(-1px);
  border-color: transparent;
}

.modal-footer .btn-outline:active {
  transform: scale(0.98) translateY(0);
  background: #E2E8F0;
}

/* Tombol Bahaya / Hapus */
.btn-danger {
  background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%);
  color: #FFFFFF;
  box-shadow: 0 2px 6px rgba(239, 68, 68, 0.2);
}

.btn-danger:hover {
  background: linear-gradient(135deg, #DC2626 0%, #B91C1C 100%);
  transform: translateY(-1.5px);
  box-shadow: 0 6px 16px rgba(239, 68, 68, 0.28);
}

.btn-danger:active {
  transform: scale(0.98) translateY(0);
}

.btn-block {
  width: 100%;
}

.hidden {
  display: none !important;
}

/* ==========================================================================
   Responsivitas (Mobile & Tablet <= 900px)
   ========================================================================== */
@media (max-width: 900px) {
  .app-sidebar {
    position: fixed;
    left: -320px;
    top: 0;
    bottom: 0;
    width: 290px;
    min-width: 290px;
    z-index: 200;
    transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-xl);
  }

  .app-sidebar.open {
    left: 0;
  }

  .sidebar-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(4px);
    z-index: 150;
  }

  .sidebar-backdrop.active {
    display: block;
  }

  .btn-close-sidebar {
    display: block;
  }

  .btn-hamburger {
    display: flex;
  }

  .main-topbar {
    padding: 12px 16px;
  }

  .content-body {
    padding: 16px;
    gap: 16px;
  }

  .summary-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .action-banner {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .user-profile-menu {
    border-left: none;
    padding-left: 0;
  }
}

/* ==========================================================================
   Right Side Drawer Modal (Cash In / Cash Out Entry System)
   Sesuai Referensi Gambar Pengguna
   ========================================================================== */
dialog.side-drawer-modal {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: auto;
  width: 480px;
  max-width: 100vw;
  height: 100vh;
  max-height: 100vh;
  margin: 0 0 0 auto;
  padding: 0;
  border: none;
  background: transparent;
  outline: none;
  overflow: hidden;
  z-index: 1050;
}

dialog.side-drawer-modal::backdrop {
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(4px);
  animation: fadeIn 0.2s ease;
}

dialog.side-drawer-modal[open] .drawer-panel {
  animation: slideDrawerRight 0.28s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes slideDrawerRight {
  from {
    transform: translateX(100%);
    opacity: 0.9;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.drawer-panel {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  background: #FFFFFF;
  box-shadow: -10px 0 35px rgba(0, 0, 0, 0.12);
  overflow: hidden;
}

/* Drawer Header */
.drawer-header {
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #F1F5F9;
  background: #FFFFFF;
  flex-shrink: 0;
}

.drawer-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin: 0;
  letter-spacing: -0.01em;
  transition: color 0.2s ease;
}

.drawer-title-in {
  color: #057A55 !important; /* Forest green matching image */
}

.drawer-title-out {
  color: #C81E1E !important; /* Crimson red matching image */
}

.btn-drawer-close {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #FFFFFF;
  border: 1px solid #E5E7EB;
  border-radius: 8px;
  color: #4B5563;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.btn-drawer-close:hover {
  background: #F3F4F6;
  color: #111827;
  border-color: #D1D5DB;
  transform: scale(1.05);
}

/* Drawer Form Container */
.drawer-form {
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow: hidden;
  margin: 0;
  padding: 0;
}

/* Drawer Scrollable Body */
.drawer-body {
  flex: 1;
  padding: 20px 24px;
  overflow-y: auto;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Type Segmented Switcher Pills */
.drawer-type-switcher {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 2px;
}

.drawer-pill-btn {
  padding: 7px 20px;
  border-radius: 9999px;
  font-size: 0.86rem;
  font-weight: 600;
  border: 1px solid #E5E7EB;
  background: #F9FAFB;
  color: #4B5563;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.drawer-pill-btn:hover:not(.active-in):not(.active-out) {
  background: #F3F4F6;
  color: #111827;
}

.drawer-pill-btn.active-in {
  background: #057A55 !important;
  color: #FFFFFF !important;
  border-color: #057A55 !important;
  box-shadow: 0 2px 6px rgba(5, 122, 85, 0.2);
}

.drawer-pill-btn.active-out {
  background: #C81E1E !important;
  color: #FFFFFF !important;
  border-color: #C81E1E !important;
  box-shadow: 0 2px 6px rgba(200, 30, 30, 0.2);
}

/* 2 Columns Row */
.drawer-row-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.drawer-row-2col.single-col {
  grid-template-columns: 1fr;
}

/* Drawer Field */
.drawer-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.drawer-field-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.drawer-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #374151;
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0;
}

.drawer-label .required {
  color: #EF4444;
}

.info-tooltip-bubble {
  color: #9CA3AF;
  cursor: help;
  font-size: 0.8rem;
  line-height: 1;
  transition: color 0.15s ease;
}

.info-tooltip-bubble:hover {
  color: #4B5563;
}

.btn-field-gear {
  background: transparent;
  border: none;
  color: #9CA3AF;
  cursor: pointer;
  font-size: 0.85rem;
  padding: 2px 4px;
  border-radius: 4px;
  transition: all 0.15s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.btn-field-gear:hover {
  color: #374151;
  background: #F3F4F6;
  transform: rotate(30deg);
}

/* Drawer Input & Select Elements */
.drawer-input-icon-box {
  position: relative;
  display: flex;
  align-items: center;
}

.drawer-input-icon {
  position: absolute;
  left: 12px;
  font-size: 0.95rem;
  pointer-events: none;
  color: #6B7280;
  z-index: 1;
}

.drawer-input-icon-box .drawer-input {
  padding-left: 38px;
}

.drawer-input {
  width: 100%;
  height: 42px;
  padding: 9px 12px;
  background: #FFFFFF;
  border: 1px solid #D1D5DB;
  border-radius: 8px;
  font-size: 0.88rem;
  color: #111827;
  font-family: inherit;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  box-sizing: border-box;
}

.drawer-input:focus {
  outline: none;
  border-color: #4F46E5;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

.drawer-amount-input {
  font-size: 0.95rem;
  font-weight: 600;
  color: #111827;
  padding-left: 14px !important;
}

.amount-calc-preview {
  font-size: 0.8rem;
  font-weight: 600;
  color: #057A55;
  margin: 2px 0 0 2px;
  transition: color 0.2s ease;
}

.amount-calc-preview.is-out {
  color: #C81E1E;
}

/* Select with clean dropdown icon */
.drawer-select-wrapper {
  position: relative;
}

.drawer-select {
  width: 100%;
  height: 42px;
  padding: 9px 34px 9px 12px;
  background: #FFFFFF;
  border: 1px solid #D1D5DB;
  border-radius: 8px;
  font-size: 0.88rem;
  color: #111827;
  font-family: inherit;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236B7280' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 13px;
  cursor: pointer;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  box-sizing: border-box;
}

.drawer-select:focus {
  outline: none;
  border-color: #4F46E5;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

/* Attach Bills Section */
.drawer-attach-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 2px;
}

.attach-btn-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.btn-attach-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  background: #FFFFFF;
  border: 1px solid #D1D5DB;
  border-radius: 9999px;
  font-size: 0.84rem;
  font-weight: 600;
  color: #374151;
  cursor: pointer;
  transition: all 0.18s ease;
}

.btn-attach-pill:hover {
  background: #F9FAFB;
  border-color: #9CA3AF;
  color: #111827;
}

.attach-helper-text {
  font-size: 0.78rem;
  color: #6B7280;
}

.attached-files-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 2px;
}

.attached-file-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #F3F4F6;
  border: 1px solid #E5E7EB;
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 0.75rem;
  color: #374151;
}

.attached-file-chip .btn-remove-chip {
  background: transparent;
  border: none;
  color: #9CA3AF;
  cursor: pointer;
  font-size: 0.8rem;
  padding: 0;
  line-height: 1;
}

.attached-file-chip .btn-remove-chip:hover {
  color: #EF4444;
}

/* Add More Fields Banner */
.drawer-banner-fields {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: #F9FAFB;
  border: 1px dashed #D1D5DB;
  border-radius: 10px;
  margin-top: 4px;
  transition: all 0.2s ease;
}

.drawer-banner-fields .banner-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.banner-sparkle {
  font-size: 0.95rem;
}

.banner-title {
  font-size: 0.82rem;
  font-weight: 600;
  color: #374151;
}

.banner-badge-new {
  background: var(--primary-bg);
  color: var(--primary-color);
  border: 1px solid var(--primary-border);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 1px 6px;
  border-radius: 9999px;
  text-transform: uppercase;
}

.drawer-banner-fields .banner-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-banner-action {
  background: transparent;
  border: none;
  color: #4F46E5;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 6px;
  border-radius: 4px;
  transition: background 0.15s ease;
}

.btn-banner-action:hover {
  background: #EEF2FF;
  text-decoration: underline;
}

.btn-banner-dismiss {
  background: transparent;
  border: none;
  color: #9CA3AF;
  cursor: pointer;
  font-size: 0.85rem;
  padding: 2px 6px;
  border-radius: 4px;
  line-height: 1;
}

.btn-banner-dismiss:hover {
  color: #374151;
  background: #E5E7EB;
}

/* Drawer Footer Action Buttons */
.drawer-footer {
  padding: 16px 24px;
  border-top: 1px solid #F1F5F9;
  background: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-shrink: 0;
}

.btn-drawer-primary {
  background: #4F46E5;
  color: #FFFFFF;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 9px 20px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 1px 3px rgba(79, 70, 229, 0.2);
}

.btn-drawer-primary:hover {
  background: #4338CA;
  box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
  transform: translateY(-1px);
}

.btn-drawer-primary:active {
  transform: translateY(0);
}

.btn-drawer-secondary {
  background: #FFFFFF;
  color: #374151;
  border: 1px solid #D1D5DB;
  border-radius: 8px;
  padding: 9px 20px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-drawer-secondary:hover {
  background: #F9FAFB;
  border-color: #9CA3AF;
  color: #111827;
}

.btn-drawer-secondary:active {
  background: #F3F4F6;
}

@media (max-width: 540px) {
  dialog.side-drawer-modal {
    width: 100vw;
  }
  .drawer-row-2col {
    grid-template-columns: 1fr;
  }
  .drawer-footer {
    flex-direction: column-reverse;
    gap: 8px;
  }
  .btn-drawer-primary,
  .btn-drawer-secondary {
    width: 100%;
    text-align: center;
  }
}

/* ==========================================================================
   Table: Interactive Bill Attachment Column (Sesuai Referensi Gambar 1)
   ========================================================================== */
.col-bill-interactive {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.col-bill-interactive:hover {
  background-color: #F1F5F9;
  transform: translateY(-1px);
}

.bill-attach-count {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.84rem;
  font-weight: 700;
  color: #475569;
  line-height: 1;
}

.bill-attach-count svg {
  stroke: #64748B;
  flex-shrink: 0;
}

.bill-attach-label {
  font-size: 0.65rem;
  color: #94A3B8;
  margin-top: 3px;
  font-weight: 500;
  line-height: 1;
}

.th-bill,
.col-bill {
  text-align: center;
  white-space: nowrap;
}

/* Interactive Table Row */
.ledger-table tbody tr,
.transaction-table tbody tr {
  cursor: pointer;
  transition: background-color 0.15s ease;
}

.ledger-table tbody tr:hover,
.transaction-table tbody tr:hover {
  background-color: #F8FAFC !important;
}

/* ==========================================================================
   Entry Details Right Slide Drawer (Sesuai Referensi Gambar 2)
   ========================================================================== */
.drawer-title-plain {
  font-size: 1.15rem;
  font-weight: 700;
  color: #111827;
  margin: 0;
  letter-spacing: -0.01em;
}

.details-body {
  padding: 20px;
  background: #FAFAFA;
  display: flex;
  flex-direction: column;
  gap: 16px;
  flex: 1;
  overflow-y: auto;
}

/* White Entry Card */
.entry-card-container {
  background: #FFFFFF;
  border: 1px solid #E5E7EB;
  border-radius: 12px;
  padding: 18px 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
  display: flex;
  flex-direction: column;
}

.entry-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
}

.entry-type-text {
  font-size: 0.88rem;
  font-weight: 600;
  line-height: 1;
}

.entry-type-in {
  color: #057A55 !important;
}

.entry-type-out {
  color: #C81E1E !important;
}

.entry-sync-info {
  display: flex;
  align-items: center;
  gap: 6px;
}

.entry-datetime-str {
  font-size: 0.78rem;
  color: #4B5563;
  font-weight: 500;
}

.cloud-sync-icon {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
}

.entry-amount-headline {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
  line-height: 1.2;
}

.entry-amount-headline.text-in {
  color: #057A55 !important;
}

.entry-amount-headline.text-out {
  color: #C81E1E !important;
}

.entry-card-divider {
  border-top: 1px solid #F3F4F6;
  margin: 0 0 14px 0;
}

.entry-remark-section {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 14px;
}

.entry-remark-label {
  font-size: 0.72rem;
  font-weight: 500;
  color: #9CA3AF;
  text-transform: capitalize;
}

.entry-remark-val {
  font-size: 0.94rem;
  font-weight: 500;
  color: #1F2937;
  line-height: 1.4;
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* Attachments Preview Row */
.entry-attachments-preview-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 16px;
}

.attachment-thumb-card {
  width: 62px;
  height: 62px;
  border-radius: 8px;
  border: 1px solid #E5E7EB;
  overflow: hidden;
  position: relative;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  background: #F9FAFB;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.attachment-thumb-card:hover {
  transform: translateY(-2px) scale(1.03);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  border-color: #CBD5E1;
}

.attachment-thumb-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.attachment-thumb-tag {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(17, 24, 39, 0.75);
  backdrop-filter: blur(2px);
  color: #FFFFFF;
  font-size: 0.62rem;
  text-align: center;
  padding: 2px 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 500;
}

.attachment-pdf-card {
  background: #FFFFFF;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-bottom: 14px;
}

.attachment-pdf-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Meta Category & Payment Soft Pills */
.entry-meta-pills-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.entry-soft-pill {
  padding: 4px 14px;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1;
}

.pill-category {
  background: #EEF2FF;
  color: #4F46E5;
}

.pill-payment {
  background: #E0F2FE;
  color: #0284C7;
}

/* Activities Timeline */
.entry-activities-section {
  margin-top: 4px;
}

.activities-title {
  font-size: 0.86rem;
  font-weight: 600;
  color: #374151;
  margin: 0 0 10px 0;
}

.activities-timeline {
  display: flex;
  flex-direction: column;
  position: relative;
}

.timeline-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  position: relative;
  padding-bottom: 12px;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-item:not(:last-child)::after {
  content: '';
  position: absolute;
  left: 10px;
  top: 24px;
  bottom: 0;
  width: 2px;
  background: #E5E7EB;
}

.timeline-icon {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #F3F4F6;
  color: #9CA3AF;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 1px;
  z-index: 1;
}

.timeline-icon.timeline-icon-edit {
  background: #EFF6FF;
  color: #3B82F6;
}

.timeline-content {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.timeline-actor {
  font-size: 0.84rem;
  font-weight: 600;
  color: #1F2937;
}

.timeline-timestamp {
  font-size: 0.72rem;
  color: #6B7280;
}

/* Details Footer Actions */
.details-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  background: #FFFFFF;
  border-top: 1px solid #F1F5F9;
  flex-shrink: 0;
}

.btn-details-delete {
  background: transparent;
  border: none;
  color: #DC2626;
  font-size: 0.85rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-details-delete:hover {
  background: #FEF2F2;
  color: #B91C1C;
}

.details-footer-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.details-dropdown-wrapper {
  position: relative;
}

.btn-details-more {
  background: #FFFFFF;
  border: 1px solid #D1D5DB;
  color: #374151;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px 14px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.15s ease;
}

.btn-details-more:hover {
  background: #F9FAFB;
  border-color: #9CA3AF;
  color: #111827;
}

.details-more-menu {
  position: absolute;
  bottom: calc(100% + 8px);
  right: 0;
  background: #FFFFFF;
  border: 1px solid #E5E7EB;
  border-radius: 12px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.12), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
  width: 320px;
  max-width: 90vw;
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  z-index: 100;
  animation: slideUp 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.details-more-menu.hidden {
  display: none !important;
}

.more-action-card-btn {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 10px 12px;
  border: none;
  background: transparent;
  border-radius: 8px;
  cursor: pointer;
  text-align: left;
  transition: background-color 0.15s ease;
  width: 100%;
}

.more-action-card-btn:hover {
  background-color: #F8FAFC;
}

.more-action-icon {
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #374151;
  flex-shrink: 0;
  margin-top: 1px;
}

.more-action-text-block {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.more-action-title {
  font-size: 0.86rem;
  font-weight: 700;
  color: #1F2937;
  line-height: 1.2;
}

.more-action-desc {
  font-size: 0.72rem;
  color: #6B7280;
  line-height: 1.3;
}

.btn-details-more.active {
  color: #4F46E5;
  border-color: #818CF8;
}

.btn-details-more.active svg {
  transform: rotate(180deg);
  transition: transform 0.2s ease;
}

/* ==========================================================================
   Transfer Entry Drawer (Move / Copy / Copy Opposite) - Sesuai Gambar 3, 4, 5
   ========================================================================== */
.transfer-body {
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
  overflow-y: auto;
  background: #FFFFFF;
}

.transfer-subtitle {
  font-size: 0.86rem;
  color: #374151;
  margin: 0 0 16px 0;
}

.transfer-search-box {
  position: relative;
  display: flex;
  align-items: center;
  margin-bottom: 20px;
}

.transfer-search-icon {
  position: absolute;
  left: 12px;
  font-size: 0.85rem;
  color: #9CA3AF;
  pointer-events: none;
}

.transfer-search-box input {
  width: 100%;
  padding: 10px 36px 10px 36px;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
  font-size: 0.86rem;
  color: #1E293B;
  outline: none;
  background: #FFFFFF;
  transition: all 0.2s ease;
}

.transfer-search-box input:focus {
  border-color: #6366F1;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

.transfer-shortcut-badge {
  position: absolute;
  right: 12px;
  font-size: 0.75rem;
  color: #9CA3AF;
  background: #F1F5F9;
  padding: 1px 6px;
  border-radius: 4px;
  font-weight: 600;
  pointer-events: none;
}

.transfer-book-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.transfer-book-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border: 1.5px solid #E2E8F0;
  border-radius: 10px;
  cursor: pointer;
  background: #FFFFFF;
  transition: all 0.18s cubic-bezier(0.16, 1, 0.3, 1);
}

.transfer-book-item:hover {
  border-color: #CBD5E1;
  background: #F8FAFC;
  transform: translateY(-1px);
}

.transfer-book-item.selected {
  border-color: #4F46E5;
  background: #F5F3FF;
  box-shadow: 0 0 0 2px rgba(79, 70, 229, 0.15);
}

.transfer-book-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.transfer-book-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: #EEF2FF;
  color: #4F46E5;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.82rem;
  flex-shrink: 0;
}

.transfer-book-item.selected .transfer-book-icon {
  background: #4F46E5;
  color: #FFFFFF;
}

.transfer-book-name {
  font-size: 0.88rem;
  font-weight: 600;
  color: #1F2937;
}

.transfer-book-item.selected .transfer-book-name {
  color: #4338CA;
}

.transfer-book-radio {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid #CBD5E1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.transfer-book-item.selected .transfer-book-radio {
  border-color: #4F46E5;
  background: #4F46E5;
}

.transfer-book-radio::after {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #FFFFFF;
  opacity: 0;
  transition: opacity 0.15s ease;
}

.transfer-book-item.selected .transfer-book-radio::after {
  opacity: 1;
}

.transfer-empty-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 16px;
  text-align: center;
}

.transfer-empty-box.hidden {
  display: none !important;
}

.transfer-empty-text {
  font-size: 0.86rem;
  color: #6B7280;
  margin: 0 0 16px 0;
}

.btn-transfer-create-book {
  background: #FFFFFF;
  border: 1px solid #D1D5DB;
  color: #4F46E5;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px 18px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-transfer-create-book:hover {
  background: #F5F3FF;
  border-color: #818CF8;
}

/* Status Banner (Moving from -> Moving to) */
.transfer-status-banner {
  background: #F9FAFB;
  border-top: 1px solid #F1F5F9;
  border-bottom: 1px solid #F1F5F9;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.transfer-banner-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.transfer-banner-label {
  font-size: 0.72rem;
  color: #9CA3AF;
  font-weight: 500;
}

.transfer-banner-val {
  font-size: 0.86rem;
  font-weight: 600;
  color: #1F2937;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.transfer-banner-val.text-muted {
  color: #6B7280 !important;
  font-weight: 500;
}

.transfer-banner-arrow {
  color: #1F2937;
  font-size: 1.1rem;
  flex-shrink: 0;
}

/* Transfer Footer Actions */
.transfer-footer {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 24px;
  background: #FFFFFF;
  border-top: 1px solid #F1F5F9;
}

.btn-transfer-execute {
  background: #E5E7EB;
  color: #9CA3AF;
  border: none;
  font-size: 0.86rem;
  font-weight: 600;
  padding: 10px 24px;
  border-radius: 8px;
  cursor: not-allowed;
  transition: all 0.2s ease;
  min-width: 88px;
}

.btn-transfer-execute:not(:disabled) {
  background: #4F46E5;
  color: #FFFFFF;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(79, 70, 229, 0.2);
}

.btn-transfer-execute:not(:disabled):hover {
  background: #4338CA;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
}

.btn-transfer-cancel {
  background: #FFFFFF;
  border: 1px solid #D1D5DB;
  color: #4F46E5;
  font-size: 0.86rem;
  font-weight: 600;
  padding: 10px 24px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-transfer-cancel:hover {
  background: #F9FAFB;
  border-color: #9CA3AF;
}

.btn-details-edit {
  background: #4F46E5;
  color: #FFFFFF;
  border: none;
  font-size: 0.85rem;
  font-weight: 600;
  padding: 8px 20px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  box-shadow: 0 1px 3px rgba(79, 70, 229, 0.2);
  transition: all 0.15s ease;
}

.btn-details-edit:hover {
  background: #4338CA;
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
}

/* Lightbox Modal */
.lightbox-content {
  max-width: 720px;
  width: 90vw;
  background: #FFFFFF;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}

.lightbox-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid #F1F5F9;
  font-weight: 600;
  font-size: 0.9rem;
  color: #0F172A;
}

.lightbox-body {
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  max-height: 80vh;
  overflow: auto;
}

.lightbox-img {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.lightbox-pdf-frame {
  width: 100%;
  height: 600px;
  border: none;
  border-radius: 8px;
}

/* ==========================================================================
   Modal Dialog: Add New Book (Sesuai Gambar 1)
   ========================================================================== */
.modal-dialog-newbook {
  border: none;
  background: transparent;
  padding: 0;
  margin: auto;
  outline: none;
  max-width: 95vw;
}

.modal-dialog-newbook::backdrop {
  background: rgba(15, 23, 42, 0.45);
  backdrop-filter: blur(4px);
  animation: fadeIn 0.2s ease;
}

.newbook-modal-card {
  background: #FFFFFF;
  border-radius: 16px;
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  border: 1px solid #E2E8F0;
  width: 520px;
  max-width: 92vw;
  overflow: hidden;
  animation: modalPop 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

.newbook-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid #F1F5F9;
  background: #FFFFFF;
}

.newbook-modal-title {
  font-size: 1.22rem;
  font-weight: 700;
  color: #0F172A;
  letter-spacing: -0.01em;
  margin: 0;
}

.btn-newbook-close {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  color: #1E293B;
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: all 0.15s ease;
  padding: 0;
  flex-shrink: 0;
}

.btn-newbook-close:hover {
  background: #F8FAFC;
  border-color: #CBD5E1;
  color: #0F172A;
  transform: scale(1.02);
}

.btn-newbook-close:active {
  transform: scale(0.96);
  background: #F1F5F9;
}

.newbook-form {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: 0;
}

.newbook-modal-body {
  padding: 24px 24px 28px 24px;
  background: #FFFFFF;
}

.newbook-field-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.newbook-label {
  font-size: 0.88rem;
  font-weight: 600;
  color: #1E293B;
  letter-spacing: -0.01em;
  margin-bottom: 2px;
}

.newbook-input {
  width: 100%;
  height: 48px;
  background: #FFFFFF;
  border: 2px solid #4F46E5;
  border-radius: 8px;
  padding: 10px 16px;
  font-size: 0.95rem;
  color: #0F172A;
  box-sizing: border-box;
  outline: none;
  font-family: inherit;
  transition: all 0.15s ease;
}

.newbook-input::placeholder {
  color: #94A3B8;
  font-size: 0.95rem;
}

.newbook-input:focus {
  border-color: #4338CA;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

.newbook-modal-footer {
  padding: 16px 24px 20px 24px;
  border-top: 1px solid #F1F5F9;
  background: #FFFFFF;
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.btn-newbook-save {
  background: #4F46E5;
  color: #FFFFFF;
  border: none;
  border-radius: 10px;
  height: 44px;
  padding: 0 36px;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  box-shadow: 0 1px 3px rgba(79, 70, 229, 0.2);
}

.btn-newbook-save:hover {
  background: #4338CA;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.btn-newbook-save:active {
  transform: translateY(0);
}

/* ==========================================================================
   Modal Dialog: Export Transactions (Sesuai Gambar 1 & Gambar 2)
   ========================================================================== */
.modal-export-tx {
  border: none;
  background: transparent;
  padding: 0;
  margin: auto;
  outline: none;
  max-width: 95vw;
}

.modal-export-tx::backdrop {
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(5px);
  animation: fadeIn 0.2s ease;
}

.export-tx-card {
  background: #FFFFFF;
  border-radius: 16px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  border: 1px solid #E2E8F0;
  width: 960px;
  max-width: 95vw;
  height: 90vh;
  max-height: 92vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: modalPop 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

.export-tx-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid #E2E8F0;
  background: #FFFFFF;
  flex-shrink: 0;
}

.export-tx-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #0F172A;
  letter-spacing: -0.01em;
  margin: 0;
}

.export-tx-tabs-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 24px;
  border-bottom: 1px solid #F1F5F9;
  background: #FFFFFF;
  overflow-x: auto;
  flex-shrink: 0;
}

.export-tab-pill {
  padding: 7px 18px;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 600;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  color: #475569;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.export-tab-pill:hover {
  background: #F8FAFC;
  border-color: #CBD5E1;
  color: #1E293B;
}

.export-tab-pill.active {
  background: #EEF2FF;
  border-color: #C7D2FE;
  color: #4F46E5;
  font-weight: 700;
}

.export-tx-body {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  background: #F8FAFC;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.export-view-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

.export-view-section.hidden {
  display: none !important;
}

/* View 1: Preview Bar & Document Sheet */
.export-preview-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.export-section-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #0F172A;
  margin: 0;
}

.btn-pdf-settings {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 16px;
  background: #FFFFFF;
  border: 1px solid #CBD5E1;
  border-radius: 8px;
  color: #4F46E5;
  font-size: 0.86rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03);
}

.btn-pdf-settings:hover {
  background: #EEF2FF;
  border-color: #A5B4FC;
  color: #4338CA;
  transform: translateY(-1px);
}

.export-pdf-sheet {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 24px 28px;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.04);
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.pdf-sheet-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.pdf-sheet-avatar {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #F1F5F9;
  border: 1px solid #E2E8F0;
  display: grid;
  place-items: center;
  font-size: 1.5rem;
  flex-shrink: 0;
}

.pdf-sheet-identity {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.pdf-biz-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: #0F172A;
  margin: 0;
  letter-spacing: -0.01em;
}

.pdf-meta-text {
  font-size: 0.8rem;
  color: #64748B;
  margin: 0;
}

.pdf-sheet-book {
  padding-top: 2px;
}

.pdf-book-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: #0F172A;
  margin: 0;
}

.pdf-summary-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  background: #FFFFFF;
  overflow: hidden;
}

.pdf-summary-col {
  padding: 12px 18px;
  display: flex;
  flex-direction: column;
  gap: 4px;
  border-right: 1px solid #E2E8F0;
}

.pdf-summary-col:last-child {
  border-right: none;
}

.pdf-summary-label {
  font-size: 0.78rem;
  font-weight: 600;
  color: #64748B;
}

.pdf-summary-val {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.pdf-summary-val.val-in {
  color: #059669;
}

.pdf-summary-val.val-out {
  color: #DC2626;
}

.pdf-summary-val.val-balance {
  color: #0F172A;
}

.pdf-summary-val.val-balance.negative {
  color: #DC2626;
}

.pdf-entries-count {
  font-size: 0.86rem;
  font-weight: 600;
  color: #334155;
}

.pdf-table-responsive {
  width: 100%;
  overflow-x: auto;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
}

.pdf-ledger-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.82rem;
  background: #FFFFFF;
  border: 1px solid #D1D5DB;
  page-break-inside: auto;
}

.pdf-ledger-table th {
  background: #EFF3F8;
  padding: 8px 10px;
  text-align: left;
  font-weight: 700;
  color: #111827;
  border: 1px solid #D1D5DB;
  white-space: nowrap;
}

.pdf-ledger-table th.text-right,
.pdf-ledger-table td.text-right {
  text-align: right;
}

.pdf-ledger-table td {
  padding: 8px 10px;
  border: 1px solid #D1D5DB;
  color: #1F2937;
  vertical-align: top;
  font-size: 0.82rem;
}

.pdf-ledger-table tr {
  page-break-inside: avoid !important;
  break-inside: avoid !important;
}

.pdf-ledger-table thead {
  display: table-header-group;
}

.pdf-ledger-table tfoot {
  display: table-footer-group;
}

.pdf-ledger-table tr.row-final-balance {
  background: #FFFFFF;
  font-weight: 700;
}

.pdf-ledger-table tr.row-final-balance td {
  border: 1px solid #D1D5DB;
  font-weight: 700;
  background: #FFFFFF;
}

.pdf-ledger-table tr.pdf-group-row td {
  background: #F1F5F9;
  font-weight: 700;
  color: #334155;
  font-size: 0.82rem;
  padding: 8px 10px;
  border: 1px solid #D1D5DB;
}

.pdf-remark-cell {
  display: flex;
  flex-direction: column;
  gap: 4px;
  max-width: 140px;
  word-break: break-all;
}

.pdf-remark-text {
  font-size: 0.82rem;
  color: #111827;
  line-height: 1.3;
}

.pdf-attach-badges-col {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 2px;
}

.pdf-attach-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 4px;
  font-size: 10px;
  font-weight: 700;
  vertical-align: middle;
}

.pdf-attach-badge.badge-img {
  background: #3B82F6;
  color: #FFFFFF;
}

.pdf-attach-badge.badge-pdf {
  background: #3B82F6;
  color: #FFFFFF;
}

/* Print Page Container for html2pdf (Prevents split tables across pages) */
.pdf-print-page {
  background: #FFFFFF;
  padding: 0;
  margin: 0 auto;
  box-sizing: border-box;
  page-break-inside: avoid !important;
  break-inside: avoid !important;
}

.html2pdf__page-break {
  page-break-after: always !important;
  break-after: page !important;
  height: 0;
  display: block;
  clear: both;
}

/* View 1B: Excel Preview Sheet (Sesuai Gambar 3) */
.export-excel-sheet {
  background: #FFFFFF;
  border: 1px solid #E5E7EB;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
}

.export-excel-sheet.hidden {
  display: none !important;
}

.excel-table-responsive {
  width: 100%;
  overflow-x: auto;
}

.excel-ledger-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.excel-ledger-table th {
  background: #FFFFFF;
  padding: 10px 14px;
  text-align: left;
  font-weight: 600;
  color: #4B5563;
  border-bottom: 1px solid #E5E7EB;
  border-right: 1px solid #F3F4F6;
  white-space: nowrap;
}

.excel-ledger-table th.text-right,
.excel-ledger-table td.text-right {
  text-align: right;
}

.excel-ledger-table td {
  padding: 9px 14px;
  border-bottom: 1px solid #F3F4F6;
  border-right: 1px solid #F9FAFB;
  color: #374151;
  vertical-align: middle;
  font-size: 0.84rem;
  white-space: nowrap;
}

.excel-ledger-table tr:hover {
  background: #F9FAFB;
}

.excel-ledger-table td.cell-remark-long {
  max-width: 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* View 2: PDF Settings Topbar, Groups & Checkboxes */
.export-settings-topbar {
  display: flex;
  align-items: center;
  margin-bottom: 4px;
}

.btn-back-to-preview {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: transparent;
  border: none;
  font-size: 1.15rem;
  font-weight: 700;
  color: #0F172A;
  cursor: pointer;
  padding: 2px 0;
  transition: all 0.15s ease;
}

.btn-back-to-preview:hover {
  color: #4F46E5;
  transform: translateX(-2px);
}

.back-arrow-icon {
  font-size: 1.25rem;
  line-height: 1;
}

.pdf-settings-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pdf-group-title {
  font-size: 0.96rem;
  font-weight: 700;
  color: #0F172A;
  margin: 0;
}

.pdf-group-sub {
  font-size: 0.8rem;
  color: #64748B;
  margin: 0;
}

.pdf-identity-card {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  background: #FFFFFF;
  max-width: 340px;
  width: 100%;
  box-sizing: border-box;
}

.pdf-identity-avatar {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: #EEF2FF;
  border: 1px solid #C7D2FE;
  display: grid;
  place-items: center;
  font-size: 1.35rem;
  flex-shrink: 0;
}

.pdf-identity-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: #0F172A;
}

.pdf-columns-grid,
.pdf-other-options-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}

@media (max-width: 768px) {
  .pdf-columns-grid,
  .pdf-other-options-grid {
    grid-template-columns: 1fr;
  }
}

.pdf-col-checkbox-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-radius: 10px;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  cursor: pointer;
  font-size: 0.88rem;
  font-weight: 600;
  color: #334155;
  transition: all 0.15s ease;
  user-select: none;
  box-sizing: border-box;
}

.pdf-col-checkbox-card:hover:not(.compulsory) {
  border-color: #CBD5E1;
  background: #F8FAFC;
}

.pdf-col-checkbox-card.checked {
  background: #EEF2FF;
  border-color: #C7D2FE;
  color: #4F46E5;
}

.pdf-col-checkbox-card.compulsory {
  background: #F1F5F9;
  border-color: #E2E8F0;
  color: #475569;
  cursor: default;
}

.pdf-checkbox-icon {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-size: 11px;
  font-weight: 800;
  flex-shrink: 0;
  transition: all 0.15s ease;
  border: 1.5px solid #CBD5E1;
  background: #FFFFFF;
  color: transparent;
}

.pdf-col-checkbox-card.checked .pdf-checkbox-icon {
  background: #4F46E5;
  border-color: #4F46E5;
  color: #FFFFFF;
}

.pdf-col-checkbox-card.compulsory .pdf-checkbox-icon {
  background: #6366F1;
  border-color: #6366F1;
  color: #FFFFFF;
}

.pdf-col-name {
  font-size: 0.88rem;
}

.pdf-col-badge {
  margin-left: auto;
  font-size: 0.72rem;
  color: #64748B;
  font-weight: 500;
}

/* Modal Footer & Buttons */
.export-tx-footer {
  padding: 16px 24px;
  border-top: 1px solid #E2E8F0;
  background: #FFFFFF;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  flex-shrink: 0;
}

.btn-export-download {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #4F46E5;
  color: #FFFFFF;
  border: none;
  border-radius: 10px;
  height: 44px;
  padding: 0 24px;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 1px 3px rgba(79, 70, 229, 0.2);
}

.btn-export-download:hover {
  background: #4338CA;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

.btn-export-save-settings {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #4F46E5;
  color: #FFFFFF;
  border: none;
  border-radius: 10px;
  height: 44px;
  padding: 0 28px;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 1px 3px rgba(79, 70, 229, 0.2);
}

.btn-export-save-settings:hover {
  background: #4338CA;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

/* ==========================================================================
   Book Settings Subpanes (Contact, Category, Payment Mode - Sesuai Gambar 3, 4, 5)
   ========================================================================== */
.settings-subpane {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  animation: fadeIn 0.15s ease;
}

.settings-subpane.hidden {
  display: none !important;
}

.subpane-breadcrumb {
  font-size: 0.78rem;
  color: #64748B;
  font-weight: 500;
  margin-bottom: -4px;
}

.subpane-title-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 4px;
}

.btn-subpane-back {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  cursor: pointer;
  color: #1E293B;
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  transition: all 0.15s ease;
}

.btn-subpane-back:hover {
  background: #F1F5F9;
  color: #4F46E5;
  border-color: #CBD5E1;
}

.subpane-heading {
  font-size: 1.25rem;
  font-weight: 800;
  color: #0F172A;
  margin: 0;
}

/* Subpane Toggle Cards */
.subpane-toggle-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.subpane-toggle-label {
  font-size: 0.95rem;
  font-weight: 600;
  color: #1E293B;
}

.toggle-label-with-badge {
  display: flex;
  align-items: center;
  gap: 8px;
}

.badge-new-green {
  background: #DCFCE7;
  color: #16A34A;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 9999px;
  line-height: 1.2;
}

/* Modern Toggle Switch */
.switch-toggle {
  position: relative;
  display: inline-block;
  width: 44px;
  height: 24px;
  margin: 0;
  flex-shrink: 0;
}

.switch-toggle input {
  opacity: 0;
  width: 0;
  height: 0;
}

.switch-toggle .slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #E2E8F0;
  transition: 0.25s ease;
  border-radius: 24px;
}

.switch-toggle .slider:before {
  position: absolute;
  content: "";
  height: 18px;
  width: 18px;
  left: 3px;
  bottom: 3px;
  background-color: white;
  transition: 0.25s ease;
  border-radius: 50%;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.switch-toggle input:checked + .slider {
  background-color: #5542F6;
}

.switch-toggle input:checked + .slider:before {
  transform: translateX(20px);
}

/* Subpane Action Buttons Stack */
.subpane-buttons-stack {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 6px 0;
}

.btn-subpane-outline-action {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 14px 20px;
  font-size: 0.92rem;
  font-weight: 600;
  color: #4F46E5;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: all 0.15s ease;
  width: 100%;
  text-align: left;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02);
}

.btn-subpane-outline-action:hover {
  border-color: #C7D2FE;
  background: #F8FAFC;
  box-shadow: 0 2px 6px rgba(79, 70, 229, 0.06);
}

.btn-subpane-outline-action .action-btn-icon {
  font-size: 1.25rem;
  font-weight: 700;
  color: #4F46E5;
  line-height: 1;
}

/* Subpane Section Block & Items */
.subpane-section-block {
  margin-top: 10px;
}

.subpane-section-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: #64748B;
  margin: 0 0 12px 0;
}

.subpane-item-cards-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.subpane-item-row-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02);
  transition: all 0.15s ease;
}

.subpane-item-row-card:hover {
  border-color: #CBD5E1;
}

.subpane-item-name {
  font-size: 0.95rem;
  font-weight: 600;
  color: #1E293B;
}

.btn-item-more {
  background: transparent;
  border: none;
  color: #64748B;
  cursor: pointer;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 1.25rem;
  line-height: 1;
  transition: all 0.15s ease;
}

.btn-item-more:hover {
  background: #F1F5F9;
  color: #0F172A;
}

/* Contact Grid & Empty State */
.contact-actions-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 20px;
}

.contact-action-card {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  padding: 20px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  cursor: pointer;
  transition: all 0.15s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02);
}

.contact-action-card:hover {
  border-color: #CBD5E1;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.05);
  transform: translateY(-1px);
}

.action-icon-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
}

.action-icon-circle.icon-green {
  background: #DCFCE7;
}

.action-icon-circle.icon-purple {
  background: #EEF2FF;
}

.action-icon-circle.icon-blue {
  background: #EFF6FF;
}

.action-card-text {
  font-size: 0.86rem;
  font-weight: 700;
  text-align: center;
}

.action-card-text.text-green {
  color: #16A34A;
}

.action-card-text.text-purple {
  color: #4F46E5;
}

.contact-empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 56px 24px;
  text-align: center;
}

.contact-empty-avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: #EEF2FF;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.contact-empty-state .empty-title {
  font-size: 1rem;
  font-weight: 700;
  color: #0F172A;
  margin: 0 0 6px 0;
}

.contact-empty-state .empty-sub {
  font-size: 0.84rem;
  color: #64748B;
  margin: 0;
}

/* ==========================================================================
   Delete Business Modal (Sesuai Gambar 1)
   ========================================================================== */
.modal-delete-business {
  max-width: 480px;
  width: 90%;
  padding: 0;
  border-radius: 14px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  border: none;
}

.delete-business-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.delete-business-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.delete-business-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #1E293B;
  margin: 0;
}

.delete-business-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.delete-business-prompt-instruction {
  font-size: 0.88rem;
  color: #334155;
  margin: 0;
}

.delete-business-prompt-instruction strong {
  font-weight: 800;
  color: #0F172A;
}

.delete-business-field-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.delete-business-input-label {
  font-size: 0.84rem;
  font-weight: 600;
  color: #334155;
}

.delete-business-input-wrapper {
  position: relative;
  width: 100%;
}

.delete-business-input {
  width: 100%;
  height: 44px;
  border: 1.5px solid #CBD5E1;
  border-radius: 8px;
  padding: 0 14px;
  font-size: 0.92rem;
  box-sizing: border-box;
  outline: none;
  transition: all 0.15s ease;
}

.delete-business-input:focus {
  border-color: #4F46E5;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}

.delete-business-warning-box {
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.warning-box-header {
  display: flex;
  align-items: center;
  gap: 10px;
}

.warning-box-icon {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.warning-box-text {
  font-size: 0.88rem;
  font-weight: 700;
  color: #DC2626;
  margin: 0;
}

.delete-business-chips-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-height: 120px;
  overflow-y: auto;
  padding-left: 30px;
}

.delete-business-chip {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  background: #FEE2E2;
  color: #991B1B;
  font-size: 0.8rem;
  font-weight: 600;
  border-radius: 6px;
  white-space: nowrap;
}

.delete-business-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  padding-top: 14px;
  border-top: 1px solid #F1F5F9;
}

.btn-delete-biz-confirm {
  background: #FFFFFF;
  border: 1px solid #FECACA;
  border-radius: 8px;
  color: #DC2626;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 18px;
  transition: all 0.15s ease;
}

.btn-delete-biz-confirm:not(:disabled):hover {
  background: #FEF2F2;
  border-color: #DC2626;
}

.btn-delete-biz-confirm:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  border-color: #E2E8F0;
}

.btn-delete-biz-cancel {
  background: #4F46E5;
  border: 1px solid #4F46E5;
  border-radius: 8px;
  color: #FFFFFF;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 18px;
  transition: all 0.15s ease;
}

.btn-delete-biz-cancel:hover {
  background: #4338CA;
  border-color: #4338CA;
}

/* ==========================================================================
   Delete Book Modal (Sesuai Gambar 1)
   ========================================================================== */
.modal-delete-book {
  max-width: 480px;
  width: 90%;
  padding: 0;
  border-radius: 14px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  border: none;
}

.delete-book-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.delete-book-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.delete-book-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #1E293B;
  margin: 0;
}

.delete-book-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.delete-book-warning-banner {
  background: #FFF7ED;
  border: 1px solid #FDBA74;
  border-radius: 8px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.warning-banner-icon {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.warning-banner-text {
  font-size: 0.84rem;
  font-weight: 600;
  color: #C2410C;
  margin: 0;
  line-height: 1.4;
}

.delete-book-prompt-instruction {
  font-size: 0.88rem;
  color: #334155;
  margin: 0;
}

.delete-book-prompt-instruction strong {
  font-weight: 800;
  color: #0F172A;
}

.delete-book-input {
  width: 100%;
  height: 44px;
  border: 1.5px solid #6366F1;
  border-radius: 8px;
  padding: 0 14px;
  font-size: 0.92rem;
  box-sizing: border-box;
  outline: none;
  transition: all 0.15s ease;
}

.delete-book-input:focus {
  border-color: #4F46E5;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.delete-book-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  padding-top: 14px;
}

.btn-delete-cancel {
  background: transparent;
  border: none;
  color: #4F46E5;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 6px;
  transition: all 0.15s ease;
}

.btn-delete-cancel:hover {
  background: #EEF2FF;
}

.btn-delete-confirm {
  background: #FFFFFF;
  border: 1px solid #EF4444;
  border-radius: 8px;
  color: #DC2626;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 18px;
  transition: all 0.15s ease;
}

.btn-delete-confirm:not(:disabled):hover {
  background: #FEF2F2;
  border-color: #DC2626;
}

.btn-delete-confirm:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  border-color: #FCA5A5;
}

/* ==========================================================================
   Duplicate Book Modal (Sesuai Gambar 2)
   ========================================================================== */
.modal-duplicate-book {
  max-width: 500px;
  width: 90%;
  padding: 0;
  border-radius: 14px;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  border: none;
}

.duplicate-book-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.duplicate-book-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.duplicate-book-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #1E293B;
  margin: 0;
}

.duplicate-book-body {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.duplicate-info-banner {
  background: #EEF2FF;
  border-radius: 8px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.duplicate-info-icon {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.duplicate-info-text {
  font-size: 0.82rem;
  font-weight: 600;
  color: #3730A3;
  margin: 0;
}

.duplicate-step-block {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.duplicate-step-title {
  font-size: 0.82rem;
  font-weight: 700;
  color: #475569;
  margin: 0;
}

.duplicate-input-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #334155;
  margin-top: 2px;
}

.duplicate-input {
  width: 100%;
  height: 42px;
  border: 1.5px solid #6366F1;
  border-radius: 8px;
  padding: 0 14px;
  font-size: 0.92rem;
  box-sizing: border-box;
  outline: none;
}

.duplicate-input:focus {
  border-color: #4F46E5;
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.15);
}

.duplicate-settings-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.duplicate-option-card {
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.duplicate-option-card:hover {
  background: #F1F5F9;
}

.duplicate-option-card input[type="checkbox"] {
  accent-color: #4F46E5;
  width: 17px;
  height: 17px;
  cursor: pointer;
}

.dup-card-label-text {
  font-size: 0.85rem;
  font-weight: 600;
  color: #1E293B;
}

.duplicate-book-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 14px;
  padding-top: 14px;
}

.btn-duplicate-cancel {
  background: transparent;
  border: none;
  color: #4F46E5;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 6px;
}

.btn-duplicate-cancel:hover {
  background: #EEF2FF;
}

.btn-duplicate-submit {
  background: #4F46E5;
  border: none;
  border-radius: 8px;
  color: #FFFFFF;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  padding: 10px 22px;
  transition: all 0.15s ease;
}

.btn-duplicate-submit:hover {
  background: #4338CA;
}

.btn-duplicate-submit:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.move-book-name-box {
  font-size: 0.95rem;
  font-weight: 700;
  color: #0F172A;
  background: #F8FAFC;
  border: 1px solid #E2E8F0;
  border-radius: 8px;
  padding: 10px 14px;
}

.move-book-single-biz-alert {
  font-size: 0.84rem;
  font-weight: 600;
  color: #B91C1C;
  background: #FEF2F2;
  border: 1px solid #FECACA;
  border-radius: 8px;
  padding: 10px 14px;
}

/* =========================================================================
   Transaction Drawer Field Error Pill (Sesuai Gambar 1 & Gambar 2)
   ========================================================================= */
.field-error-pill {
  display: block;
  background-color: #FDE8E8;
  color: #C53030;
  font-size: 0.78rem;
  font-weight: 500;
  line-height: 1.35;
  padding: 5px 12px;
  border-radius: 6px;
  margin-top: 6px;
  box-sizing: border-box;
  width: 100%;
  animation: fadeInDown 0.15s ease-out;
}

.field-error-pill.hidden {
  display: none !important;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-3px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================================================================
   Custom HTML/CSS Dialogs (Pengganti window.prompt(), window.alert(), dll)
   ========================================================================= */
.modal-prompt-dialog,
.modal-confirm-dialog,
.modal-action-sheet-dialog,
.modal-alert-dialog {
  border: none;
  background: transparent;
  padding: 0;
  margin: auto;
}

.custom-prompt-card,
.custom-confirm-card,
.custom-action-sheet-card,
.custom-alert-card {
  max-width: 440px;
  width: 92vw;
  background: #FFFFFF;
  border-radius: 14px;
  box-shadow: 0 20px 25px -5px rgba(15, 23, 42, 0.15), 0 10px 10px -5px rgba(15, 23, 42, 0.08);
  border: 1px solid #E2E8F0;
  overflow: hidden;
  animation: modalPop 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.custom-prompt-header,
.custom-confirm-header,
.action-sheet-header,
.custom-alert-header {
  padding: 16px 20px;
  border-bottom: 1px solid #F1F5F9;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.custom-prompt-title,
.custom-confirm-title,
.action-sheet-title,
.custom-alert-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #0F172A;
  margin: 0;
}

.action-sheet-subtitle {
  font-size: 0.72rem;
  font-weight: 600;
  color: #64748B;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: block;
  margin-bottom: 2px;
}

.confirm-header-icon-wrap,
.alert-icon-wrap {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-right: 12px;
  flex-shrink: 0;
}

.confirm-header-icon-wrap {
  background: #FEE2E2;
}

.alert-icon-wrap {
  background: #EEF2FF;
}

.custom-prompt-body,
.custom-confirm-body,
.action-sheet-body,
.custom-alert-body {
  padding: 20px;
}

.custom-prompt-message,
.custom-confirm-message,
.custom-alert-message {
  font-size: 0.9rem;
  color: #475569;
  margin: 0 0 14px 0;
  line-height: 1.5;
}

.custom-prompt-field-group {
  display: flex;
  flex-direction: column;
}

.custom-prompt-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #334155;
  margin-bottom: 6px;
}

.custom-prompt-input,
.custom-prompt-select {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid #CBD5E1;
  border-radius: 8px;
  font-size: 0.9rem;
  color: #0F172A;
  background: #FFFFFF;
  outline: none;
  transition: all 0.15s ease;
  box-sizing: border-box;
}

.custom-prompt-input:focus,
.custom-prompt-select:focus {
  border-color: #4F46E5;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

.custom-prompt-footer,
.custom-confirm-footer,
.action-sheet-footer,
.custom-alert-footer {
  padding: 14px 20px;
  background: #F8FAFC;
  border-top: 1px solid #F1F5F9;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

/* Action Sheet Buttons (Rename, Delete) */
.action-sheet-btn {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border-radius: 8px;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  cursor: pointer;
  margin-bottom: 10px;
  text-align: left;
  transition: all 0.15s ease;
}

.action-sheet-btn:hover {
  background: #F8FAFC;
  border-color: #CBD5E1;
}

.action-sheet-btn-danger:hover {
  background: #FEF2F2;
  border-color: #FECACA;
}

.action-btn-texts {
  display: flex;
  flex-direction: column;
}

.action-btn-main {
  font-size: 0.9rem;
  font-weight: 600;
  color: #1E293B;
}

.action-btn-desc {
  font-size: 0.75rem;
  color: #64748B;
  margin-top: 2px;
}

/* ==========================================================================
   Contact Management Styles (Gambar 1, 3, 4)
   ========================================================================== */

/* 1. Add New Contact Manually Modal (Sesuai Gambar 4) */
.modal-add-contact-manual {
  padding: 0;
  border: none;
  background: transparent;
}

.add-contact-card {
  width: 90vw;
  max-width: 440px;
  background: #FFFFFF;
  border-radius: 16px;
  box-shadow: 0 20px 45px rgba(15, 23, 42, 0.16);
  border: 1px solid #E2E8F0;
  overflow: hidden;
  animation: modalScaleIn 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.add-contact-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 24px;
  border-bottom: 1px solid #F1F5F9;
}

.add-contact-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: #1E293B;
  margin: 0;
}

.add-contact-body {
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.bulk-csv-link-banner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #E8F5E9;
  border: 1px solid #C8E6C9;
  border-radius: 10px;
  padding: 10px 14px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.bulk-csv-link-banner:hover {
  background: #DCEDC8;
  border-color: #A5D6A7;
}

.bulk-csv-banner-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.excel-icon-tiny {
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
}

.bulk-csv-banner-text {
  font-size: 0.85rem;
  font-weight: 600;
  color: #1B5E20;
}

.bulk-csv-chevron {
  font-size: 1.25rem;
  font-weight: 700;
  color: #1B5E20;
  line-height: 1;
}

.add-contact-field-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.add-contact-label {
  font-size: 0.82rem;
  font-weight: 600;
  color: #334155;
}

.add-contact-input {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid #CBD5E1;
  border-radius: 8px;
  font-size: 0.92rem;
  color: #0F172A;
  background: #FFFFFF;
  outline: none;
  transition: all 0.15s ease;
  box-sizing: border-box;
}

.add-contact-input:focus {
  border-color: #4F46E5;
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.12);
}

.phone-input-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.country-prefix-box {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 9px 12px;
  border: 1.5px solid #CBD5E1;
  border-radius: 8px;
  background: #F8FAFC;
  cursor: pointer;
  user-select: none;
  flex-shrink: 0;
}

.country-flag {
  font-size: 1.15rem;
  line-height: 1;
}

.country-arrow {
  font-size: 0.65rem;
  color: #64748B;
}

.phone-number-input {
  flex: 1;
}

.contact-type-pills-row {
  display: flex;
  gap: 10px;
  margin-top: 2px;
}

.contact-type-pill {
  padding: 8px 20px;
  border-radius: 9999px;
  font-size: 0.86rem;
  font-weight: 600;
  border: 1px solid #E2E8F0;
  background: #FFFFFF;
  color: #475569;
  cursor: pointer;
  transition: all 0.15s ease;
}

.contact-type-pill:hover {
  background: #F8FAFC;
  border-color: #CBD5E1;
}

.contact-type-pill.active {
  background: #EDE9FE;
  border-color: #C4B5FD;
  color: #4F46E5;
  font-weight: 700;
}

.add-contact-footer {
  padding: 14px 24px;
  border-top: 1px solid #F1F5F9;
  display: flex;
  justify-content: flex-end;
  background: #FFFFFF;
}

.btn-save-contact-primary {
  padding: 10px 28px;
  background: #4F46E5;
  color: #FFFFFF;
  font-weight: 700;
  font-size: 0.92rem;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.15s ease;
}

.btn-save-contact-primary:hover {
  background: #4338CA;
}

/* 2. Import Contacts from Books Drawer (Sesuai Gambar 3) */
.import-from-books-panel {
  max-width: 440px;
  display: flex;
  flex-direction: column;
}

.import-from-books-body {
  padding: 20px 24px;
  display: flex;
  flex-direction: column;
}

.import-books-warning-banner {
  background: #FFF7ED;
  border: 1px solid #FDBA74;
  border-radius: 8px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.import-books-warning-icon {
  display: flex;
  align-items: center;
}

.import-books-warning-text {
  font-size: 0.86rem;
  font-weight: 600;
  color: #C2410C;
}

.import-books-instruction {
  font-size: 0.84rem;
  font-weight: 600;
  color: #64748B;
  margin: 0 0 14px 0;
}

.import-books-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.import-book-radio-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid #E2E8F0;
  border-radius: 10px;
  background: #FFFFFF;
  cursor: pointer;
  transition: all 0.15s ease;
}

.import-book-radio-card:hover {
  background: #F8FAFC;
  border-color: #CBD5E1;
}

.import-book-radio-card.selected {
  border-color: #4F46E5;
  background: #F5F3FF;
}

.import-book-radio-card input[type="radio"] {
  accent-color: #4F46E5;
  width: 18px;
  height: 18px;
  cursor: pointer;
}

.import-book-info {
  display: flex;
  flex-direction: column;
}

.import-book-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: #1E293B;
}

.import-book-count {
  font-size: 0.78rem;
  color: #94A3B8;
  margin-top: 2px;
}

.import-from-books-footer {
  padding: 16px 24px;
  border-top: 1px solid #F1F5F9;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  background: #FFFFFF;
}

.btn-purple-pill-action {
  padding: 10px 22px;
  background: #4F46E5;
  color: #FFFFFF;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.88rem;
  border: none;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background 0.15s ease;
}

.btn-purple-pill-action:hover {
  background: #4338CA;
}

/* 3. Subpane Contact Item Card Enhancements */
.contact-item-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.contact-avatar-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #EEF2FF;
  color: #4F46E5;
  font-size: 0.82rem;
  font-weight: 700;
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.contact-item-details {
  display: flex;
  flex-direction: column;
}

.contact-name-text {
  font-size: 0.9rem;
  font-weight: 700;
  color: #1E293B;
}

.contact-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 2px;
}

.contact-phone-text {
  font-size: 0.78rem;
  color: #64748B;
}

.contact-badge-pill {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 9999px;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

.contact-badge-pill.customer {
  background: #E0E7FF;
  color: #3730A3;
}

.contact-badge-pill.supplier {
  background: #FEF3C7;
  color: #92400E;
}

/* ==========================================================================
   Language Dropdown (Stage 1 i18n)
   ========================================================================== */
.lang-dropdown-container {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.btn-lang-dropdown {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: var(--shadow-xs);
  flex-shrink: 0;
}

.btn-lang-dropdown:hover {
  background: #F8FAFC;
  color: var(--primary-color);
  border-color: #CBD5E1;
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
}

.btn-lang-dropdown[aria-expanded="true"] {
  background: #EEF2FF;
  color: #4F46E5;
  border-color: #C7D2FE;
}

.btn-lang-dropdown .lang-globe-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-lang-auth {
  width: 32px;
  height: 32px;
  background: #F8FAFC;
}

.auth-lang-container {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 10;
}

.lang-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 180px;
  background: #FFFFFF;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: 6px;
  z-index: 100;
  animation: slideUp 0.15s cubic-bezier(0.16, 1, 0.3, 1);
  box-sizing: border-box;
}

.lang-dropdown-menu.hidden {
  display: none !important;
}

.lang-menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 8px 12px;
  border: none;
  background: transparent;
  border-radius: var(--radius-sm);
  color: var(--text-main);
  font-size: 0.84rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
  text-align: left;
  box-sizing: border-box;
}

.lang-menu-item:hover {
  background: #F1F5F9;
  color: var(--primary-color);
}

.lang-menu-item.active {
  background: #EEF2FF;
  color: #4F46E5;
  font-weight: 600;
}

.lang-item-check {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  color: #4F46E5;
  font-weight: bold;
}

/* ==========================================================================
   Modern Footer (Stage 1)
   ========================================================================== */
.app-footer {
  margin-top: auto;
  position: relative;
  background: #FFFFFF;
  padding: 16px 24px;
  box-sizing: border-box;
  width: 100%;
}

.app-footer::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, #6366F1, #A855F7);
}

.app-footer-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 100%;
}

.footer-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-icon {
  font-size: 0.95rem;
  display: inline-flex;
  align-items: center;
}

.footer-copyright {
  font-size: 12.5px;
  color: #64748B;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.footer-right {
  display: flex;
  align-items: center;
}

.footer-badge-version {
  display: inline-flex;
  align-items: center;
  padding: 2px 10px;
  font-size: 11.5px;
  font-weight: 600;
  color: #4F46E5;
  background: #EEF2FF;
  border-radius: 9999px;
  letter-spacing: 0.02em;
  transition: all 0.2s ease;
  cursor: default;
  user-select: none;
}

.footer-badge-version:hover {
  background: #E0E7FF;
  transform: translateY(-1px);
}

/* Auth Footer variant */
.auth-footer {
  background: transparent;
  padding: 12px 16px 0;
  width: 100%;
  max-width: 440px;
  margin-top: 0;
}

.auth-footer::before {
  display: none;
}

.auth-footer .app-footer-content {
  justify-content: center;
  gap: 14px;
}

@media (max-width: 768px) {
  .app-footer {
    padding: 14px 16px;
  }
  .app-footer-content {
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 8px;
  }
}

  .lang-dropdown-menu { 
    width: 210px; 
  }
  
  .lang-item-flag { 
    display: inline-flex; 
    align-items: center; 
    justify-content: center; 
    min-width: 28px; 
    padding: 2px 6px; 
    border-radius: 6px; 
    background: #EEF2FF; 
    color: #4F46E5; 
    font-size: 11px; 
    font-weight: 700; 
    letter-spacing: 0.3px; 
  }

  .lang-item-name { 
    flex: 1; 
    white-space: nowrap; 
  }


@media (max-width: 768px) {
  .main-topbar {
    padding: 10px 14px;
    gap: 8px;
  }

  .topbar-left {
    flex: 1;
    min-width: 0;
    gap: 10px;
  }

  .business-dropdown-container {
    min-width: 0;
    max-width: 100%;
  }

  .btn-business-dropdown {
    min-width: 0;
    max-width: 100%;
    padding: 5px 10px 5px 8px;
    gap: 8px;
  }

  .biz-info-block {
    min-width: 0;
    flex: 1;
  }

  .biz-name-display {
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .topbar-right {
    gap: 8px;
    flex-shrink: 0;
  }

  .btn-profile-dropdown {
    width: 36px;
    height: 36px;
    padding: 0;
    gap: 0;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
  }

  .btn-profile-dropdown .profile-avatar-circle {
    width: 100%;
    height: 100%;
    border: none;
    font-size: 0.82rem;
  }

  .profile-name-text,
  .profile-chevron {
    display: none;
  }
}

/* Perbaikan: menu More Actions tidak terpotong di layar kecil */
@media (max-width: 540px) {
  .details-footer {
    position: relative;
  }
  .details-dropdown-wrapper {
    position: static;
  }
  .details-more-menu {
    left: 12px;
    right: 12px;
    width: auto;
    max-width: none;
    bottom: calc(100% + 8px);
  }
}

/* ===== Logo CashBook ===== */
.visually-hidden { 
  position: absolute; 
  width: 1px; 
  height: 1px; 
  margin: -1px; 
  padding: 0; 
  overflow: hidden; 
  clip: rect(0, 0, 0, 0); 
  white-space: nowrap; 
  border: 0; 
}
.auth-logo-img { 
  display: block; 
  width: 200px; 
  max-width: 70%; 
  height: auto; 
  margin: 0 auto 12px; 
}
.brand-icon-img { 
  display: block; 
  width: 42px; 
  height: 42px; 
  flex-shrink: 0; 
  border-radius: 10px; 
  box-shadow: 
  var(--shadow-xs); 
}
.footer-logo-img { 
  display: block; 
  width: 16px; 
  height: 16px; 
  border-radius: 4px; 
}

/* Mobile: kolom pencarian, urutan, dan tombol Tambah Buku tersusun atas-bawah */
@media (max-width: 768px) {
  .biz-dash-toolbar { 
    flex-direction: column; 
    align-items: stretch; 
    gap: 10px; 
  }
  .biz-search-box { 
    flex: none; 
    width: 100%; 
    max-width: 100%; 
    min-width: 0; 
    order: 1; 
  }
  .biz-sort-wrapper { 
    flex: none; 
    width: 100%; 
    min-width: 0; 
    order: 2; 
  }
  .biz-sort-select { 
    width: 100%; 
  }
  .btn-biz-add-book { 
    flex: none; 
    width: 100%; 
    justify-content: center; 
    margin-left: 0; 
    order: 3; 
  }
}

/* Info entri dan paginasi: rapi di layar kecil */
.table-entries-toolbar { flex-wrap: wrap; gap: 8px 12px; }
@media (max-width: 600px) {
  .table-entries-toolbar { flex-direction: column; align-items: stretch; gap: 10px; padding: 2px 0 4px; }
  .entries-counter-text { font-size: 0.82rem; line-height: 1.4; }
  .entries-pagination-box { width: 100%; gap: 10px; }
  .page-dropdown-container { flex: 1; min-width: 0; }
  .page-dropdown-select { width: 100%; height: 38px; font-size: 0.85rem; padding: 6px 30px 6px 12px; }
  .page-of-text { white-space: nowrap; font-size: 0.82rem; }
  .page-nav-arrow-btns { gap: 8px; }
  .btn-nav-arrow { width: 38px; height: 38px; border-radius: 8px; }
}

/* ==========================================================================
   Custom Entry Fields (Book Settings, Modal, Transaction Form & Details)
   ========================================================================== */
.custom-fields-settings-section {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid #E2E8F0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.custom-fields-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.custom-fields-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.custom-fields-heading {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: #0F172A;
}

.custom-fields-count-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 9999px;
  background: #EEF2FF;
  color: #4F46E5;
  font-size: 0.75rem;
  font-weight: 700;
}

.btn-add-more-field {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid #C7D2FE;
  background: #EEF2FF;
  color: #4F46E5;
  font-size: 0.84rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-add-more-field:hover:not(:disabled) {
  background: #E0E7FF;
  border-color: #A5B4FC;
}

.btn-add-more-field:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.custom-fields-limit-note {
  margin: 0;
  font-size: 0.8rem;
  color: #B45309;
  background: #FFFBEB;
  border: 1px solid #FDE68A;
  padding: 8px 12px;
  border-radius: 8px;
}

.custom-fields-empty {
  padding: 16px;
  border-radius: 10px;
  border: 1px dashed #CBD5E1;
  background: #F8FAFC;
  color: #64748B;
  font-size: 0.85rem;
  text-align: center;
}

.custom-fields-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.custom-field-item-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  background: #FFFFFF;
  border: 1px solid #E2E8F0;
  border-radius: 12px;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.02);
}

.custom-field-item-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  flex: 1;
}

.custom-field-item-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.custom-field-item-name {
  font-size: 0.94rem;
  font-weight: 700;
  color: #0F172A;
  word-break: break-word;
}

.custom-field-type-pill,
.custom-field-req-pill {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 9999px;
  font-size: 0.72rem;
  font-weight: 600;
}

.custom-field-type-pill {
  background: #F1F5F9;
  color: #475569;
}

.custom-field-req-pill {
  background: #FEF2F2;
  color: #DC2626;
}

.custom-field-item-meta {
  font-size: 0.78rem;
  color: #64748B;
}

.custom-field-item-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.custom-field-modal-card {
  max-width: 480px;
}

.custom-field-modal-body {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.custom-field-select {
  width: 100%;
  height: 44px;
}

.cf-option-add-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cf-option-input {
  height: 40px;
  flex: 1;
}

.cf-option-add-btn {
  height: 40px;
  padding: 0 14px;
  flex-shrink: 0;
}

.cf-options-chips-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 6px;
}

.cf-option-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 9999px;
  background: #EEF2FF;
  border: 1px solid #C7D2FE;
  color: #3730A3;
  font-size: 0.8rem;
  font-weight: 600;
}

.cf-option-chip-remove {
  border: none;
  background: transparent;
  color: #4F46E5;
  cursor: pointer;
  font-size: 0.95rem;
  line-height: 1;
  padding: 0 2px;
}

.cf-required-toggle-card {
  padding: 12px 14px;
}

.cf-modal-footer {
  gap: 10px;
}

.tx-custom-fields-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding-top: 4px;
}

.details-custom-fields {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed #E2E8F0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.details-cf-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.85rem;
}

.details-cf-label {
  color: #64748B;
  font-weight: 600;
}

.details-cf-value {
  color: #0F172A;
  font-weight: 600;
  text-align: right;
  word-break: break-word;
}
