/* Nusantara / Orivo Cash Management Theme - Exact Match to image-1.png */

:root {
  --sidebar-bg: #0b1a30;
  --sidebar-header-bg: #091527;
  --sidebar-active-bg: #162a4a;
  --sidebar-hover-bg: #11233d;
  --sidebar-text: #94a9c4;
  --sidebar-text-active: #ffffff;
  --sidebar-section-title: #4d6685;
  --sidebar-width: 250px;
  
  --topbar-bg: #ffffff;
  --topbar-border: #e2e8f0;
  --body-bg: #f3f6f9;
  
  --card-bg: #ffffff;
  --card-border: #e2e8f0;
  --card-radius: 14px;
  --card-shadow: 0 1px 3px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.02);
  
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  
  --teal-primary: #0f766e;
  --teal-hover: #0d655e;
  --teal-light: #ccfbf1;
  --teal-text: #0f766e;
  
  --amber-primary: #d97706;
  --amber-light: #fef3c7;
  --amber-text: #92400e;
  
  --green-primary: #10b981;
  --red-primary: #ef4444;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: var(--body-bg);
  color: var(--text-main);
  display: flex;
  min-height: 100vh;
  overflow-x: hidden;
}

/* Sidebar Styles */
.n-sidebar {
  width: var(--sidebar-width);
  background-color: var(--sidebar-bg);
  color: var(--sidebar-text);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  height: 100vh;
  position: sticky;
  top: 0;
  z-index: 100;
  border-right: 1px solid #060e1b;
}

.n-sidebar-brand {
  height: 64px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0 20px;
  background-color: var(--sidebar-header-bg);
  border-bottom: 1px solid #14243b;
}

.n-brand-icon {
  width: 34px;
  height: 34px;
  background-color: #0d9488;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 800;
  font-size: 18px;
  box-shadow: 0 2px 6px rgba(13, 148, 136, 0.4);
}

.n-brand-text {
  display: flex;
  flex-direction: column;
}

.n-brand-title {
  color: #ffffff;
  font-weight: 800;
  font-size: 13px;
  letter-spacing: 0.06em;
}

.n-brand-sub {
  color: #64748b;
  font-size: 10px;
  letter-spacing: 0.05em;
  font-weight: 600;
  margin-top: 1px;
}

.n-sidebar-menu {
  flex: 1;
  overflow-y: auto;
  padding: 14px 10px 40px;
}

.n-sidebar-menu::-webkit-scrollbar {
  width: 5px;
}

.n-sidebar-menu::-webkit-scrollbar-track {
  background: transparent;
}

.n-sidebar-menu::-webkit-scrollbar-thumb {
  background: #1e3352;
  border-radius: 10px;
}

.n-menu-section {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--sidebar-section-title);
  padding: 16px 12px 6px;
  text-transform: uppercase;
}

.n-menu-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--sidebar-text);
  text-decoration: none;
  font-size: 12.5px;
  font-weight: 500;
  margin-bottom: 2px;
  transition: all 0.15s ease;
  cursor: pointer;
}

.n-menu-item:hover {
  background-color: var(--sidebar-hover-bg);
  color: #ffffff;
}

.n-menu-item.active {
  background-color: var(--sidebar-active-bg);
  color: var(--sidebar-text-active);
  font-weight: 600;
}

.n-menu-item .n-icon {
  font-size: 14px;
  width: 18px;
  display: inline-flex;
  justify-content: center;
  opacity: 0.9;
}

/* Main Content Area */
.n-main-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
  background-color: var(--body-bg);
}

/* Topbar Styles */
.n-topbar {
  height: 64px;
  background-color: var(--topbar-bg);
  border-bottom: 1px solid var(--topbar-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  position: sticky;
  top: 0;
  z-index: 90;
}

.n-topbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  max-width: 820px;
}

.n-selector-pill {
  border: 1px solid #cbd5e1;
  background: #ffffff;
  border-radius: 8px;
  padding: 7px 12px;
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  white-space: nowrap;
}

.n-selector-pill .pill-label {
  font-size: 10px;
  color: var(--text-muted);
  font-weight: 700;
  letter-spacing: 0.04em;
}

.n-selector-pill .pill-val {
  font-weight: 600;
  color: var(--text-main);
}

.n-search-box {
  flex: 1;
  position: relative;
  display: flex;
  align-items: center;
}

.n-search-input {
  width: 100%;
  padding: 8px 12px 8px 32px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 12px;
  background-color: #ffffff;
  color: var(--text-main);
  outline: none;
  transition: border-color 0.15s ease;
}

.n-search-input:focus {
  border-color: var(--teal-primary);
}

.n-search-icon {
  position: absolute;
  left: 10px;
  color: #94a3b8;
  font-size: 13px;
  pointer-events: none;
}

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

.n-icon-btn {
  width: 34px;
  height: 34px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 14px;
  color: #475569;
  position: relative;
}

.n-badge-dot {
  position: absolute;
  top: -5px;
  right: -5px;
  background-color: #dc2626;
  color: #ffffff;
  font-size: 9px;
  font-weight: 700;
  padding: 1px 5px;
  border-radius: 999px;
  border: 2px solid #ffffff;
}

.n-lang-switcher {
  display: flex;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  overflow: hidden;
  font-size: 11px;
  font-weight: 700;
}

.n-lang-opt {
  padding: 6px 9px;
  cursor: pointer;
  background: #ffffff;
  color: #64748b;
}

.n-lang-opt.active {
  background-color: #0b1a30;
  color: #ffffff;
}

.n-user-profile {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  padding-left: 6px;
}

.n-user-avatar {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background-color: #1e3a5f;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 12px;
}

.n-user-info {
  display: flex;
  flex-direction: column;
}

.n-user-name {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-main);
}

.n-user-role {
  font-size: 10.5px;
  color: var(--text-muted);
}

/* Page Body */
.n-page-content {
  padding: 24px 28px 48px;
  flex: 1;
}

.n-breadcrumb {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.n-page-header {
  margin-bottom: 20px;
}

.n-page-title {
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 800;
  color: var(--text-main);
  letter-spacing: -0.01em;
}

.n-page-subtitle {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
}

/* Filter Card */
.n-filter-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--card-radius);
  padding: 12px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  box-shadow: var(--card-shadow);
}

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

.n-filter-group {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.n-filter-label {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--text-muted);
}

.n-filter-select {
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 6px 12px;
  font-size: 12px;
  background: #ffffff;
  color: var(--text-main);
  outline: none;
}

.n-btn-refresh {
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 7px 14px;
  font-size: 12px;
  font-weight: 600;
  background: #ffffff;
  color: var(--text-main);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  align-self: flex-end;
}

.n-btn-refresh:hover {
  background: #f8fafc;
}

.n-filter-time {
  font-size: 12px;
  color: var(--text-light);
}

/* 4 Summary Cards Grid */
.n-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 22px;
}

.n-kpi-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--card-radius);
  padding: 16px 20px;
  box-shadow: var(--card-shadow);
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

.n-kpi-accent {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 4px;
}

.n-kpi-accent.green { background-color: var(--green-primary); }
.n-kpi-accent.teal { background-color: #06b6d4; }
.n-kpi-accent.amber { background-color: #f59e0b; }
.n-kpi-accent.red { background-color: #ef4444; }

.n-kpi-label {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 8px;
}

.n-kpi-val {
  font-size: 22px;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.1;
  margin-bottom: 8px;
}

.n-kpi-sub {
  font-size: 11.5px;
  color: var(--text-muted);
}

/* Two-Column Dashboard Content */
.n-grid-2col {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 20px;
}

.n-card {
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--card-radius);
  padding: 18px 22px;
  box-shadow: var(--card-shadow);
}

.n-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.n-card-title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-main);
}

/* Chart Styles */
.n-chart-legend {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 11.5px;
}

.n-legend-item {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--text-muted);
}

.n-legend-box {
  width: 10px;
  height: 10px;
  border-radius: 2px;
}

.n-btn-csv {
  border: 1px solid #cbd5e1;
  background: #ffffff;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-main);
  cursor: pointer;
}

.n-barchart-container {
  display: flex;
  align-items: flex-end;
  height: 220px;
  gap: 6px;
  padding: 10px 0;
  border-bottom: 1px solid #e2e8f0;
}

.n-bar-col {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 100%;
  gap: 2px;
  cursor: pointer;
  position: relative;
}

.n-bar-col:hover .n-bar-teal, .n-bar-col:hover .n-bar-amber {
  filter: brightness(1.15);
}

.n-bar-teal {
  background-color: #0f766e;
  border-radius: 3px 3px 0 0;
  width: 100%;
  transition: height 0.3s ease;
}

.n-bar-amber {
  background-color: #d97706;
  border-radius: 0 0 3px 3px;
  width: 100%;
  transition: height 0.3s ease;
}

/* Tasks / Approval Widget */
.n-task-item {
  border-bottom: 1px solid #f1f5f9;
  padding: 14px 0;
}

.n-task-item:last-child {
  border-bottom: none;
}

.n-task-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 4px;
}

.n-task-amount {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-main);
}

.n-task-badge {
  background-color: #fef3c7;
  color: #92400e;
  font-size: 10.5px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 999px;
}

.n-task-sub {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.n-task-actions {
  display: flex;
  gap: 8px;
}

.n-btn-teal {
  background-color: var(--teal-primary);
  color: #ffffff;
  border: none;
  border-radius: 6px;
  padding: 6px 14px;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
}

.n-btn-teal:hover {
  background-color: var(--teal-hover);
}

.n-btn-outline {
  background-color: #ffffff;
  border: 1px solid #cbd5e1;
  color: #334155;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 11.5px;
  font-weight: 500;
  cursor: pointer;
}

.n-btn-outline:hover {
  background-color: #f8fafc;
}


/* Modal Styles */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(11, 26, 48, 0.65);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-box {
  background: #ffffff;
  border-radius: 16px;
  width: 90%;
  max-width: 620px;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
  border: 1px solid #e2e8f0;
  transform: translateY(15px);
  transition: transform 0.2s ease;
  overflow: hidden;
}

.modal-overlay.active .modal-box {
  transform: translateY(0);
}

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

.modal-title {
  margin: 0;
  font-size: 16px;
  font-weight: 800;
  color: #0f172a;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-close-btn {
  background: transparent;
  border: none;
  font-size: 20px;
  line-height: 1;
  color: #64748b;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: 6px;
}

.modal-close-btn:hover {
  background: #e2e8f0;
  color: #0f172a;
}

.modal-body {
  padding: 24px;
  overflow-y: auto;
  font-size: 13px;
  color: #334155;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

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

.form-label {
  font-size: 11.5px;
  font-weight: 700;
  color: #475569;
}

.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  font-size: 13px;
  color: #0f172a;
  outline: none;
  background: #ffffff;
  box-sizing: border-box;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  border-color: #0f766e;
  box-shadow: 0 0 0 3px rgba(15, 118, 110, 0.15);
}

.form-input[readonly] {
  background: #f1f5f9;
  color: #64748b;
  cursor: default;
}

.modal-footer {
  padding: 14px 24px;
  border-top: 1px solid #e2e8f0;
  background: #f8fafc;
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

.view-field-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 16px;
}

.view-field {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.view-field-label {
  font-size: 11px;
  color: #64748b;
  text-transform: uppercase;
  font-weight: 700;
}

.view-field-value {
  font-size: 13px;
  font-weight: 600;
  color: #0f172a;
}

.timeline-box {
  border-left: 2px solid #0f766e;
  padding-left: 14px;
  margin-left: 6px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 8px;
}

.timeline-step {
  position: relative;
  font-size: 12px;
}

.timeline-step::before {
  content: '';
  position: absolute;
  left: -19px;
  top: 4px;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: #0f766e;
  border: 2px solid #fff;
}


/* ==========================================================================
   5 ENTERPRISE BANKING THEMES FOR ORIVO (Corporate, Bank Back Office & Mobile)
   ========================================================================== */

/* 1. THEME TEAL (Default Orivo Corporate Treasury) */
[data-theme="teal"], body.theme-teal {
  --sidebar-bg: #0b1a30;
  --sidebar-header-bg: #091527;
  --sidebar-active-bg: #162a4a;
  --sidebar-hover-bg: #11233d;
  --sidebar-text: #94a9c4;
  --sidebar-text-active: #ffffff;
  --teal-primary: #169388;
  --teal-hover: #0d736a;
  --teal-light: #ccfbf1;
  --teal-text: #0f766e;
  --topbar-bg: #ffffff;
  --body-bg: #f3f6f9;
  --card-bg: #ffffff;
}

/* 2. THEME NAVY & GOLD (Executive Wealth & Private Banking) */
[data-theme="navy"], body.theme-navy {
  --sidebar-bg: #0a192f;
  --sidebar-header-bg: #06101e;
  --sidebar-active-bg: #1e3a8a;
  --sidebar-hover-bg: #132440;
  --sidebar-text: #93c5fd;
  --sidebar-text-active: #ffffff;
  --teal-primary: #d97706;
  --teal-hover: #b45309;
  --teal-light: #fef3c7;
  --teal-text: #92400e;
  --amber-primary: #f59e0b;
  --topbar-bg: #ffffff;
  --body-bg: #f0f4f8;
  --card-bg: #ffffff;
}

/* 3. THEME SYARIAH (Emerald Sharia & Green Islamic Banking) */
[data-theme="syariah"], body.theme-syariah {
  --sidebar-bg: #064e3b;
  --sidebar-header-bg: #022c22;
  --sidebar-active-bg: #047857;
  --sidebar-hover-bg: #065f46;
  --sidebar-text: #a7f3d0;
  --sidebar-text-active: #ffffff;
  --teal-primary: #059669;
  --teal-hover: #047857;
  --teal-light: #d1fae5;
  --teal-text: #065f46;
  --amber-primary: #eab308;
  --topbar-bg: #ffffff;
  --body-bg: #f0fdf4;
  --card-bg: #ffffff;
}

/* 4. THEME PLATINUM (Bank Platinum & Cobalt Wholesale Treasury) */
[data-theme="platinum"], body.theme-platinum {
  --sidebar-bg: #1e293b;
  --sidebar-header-bg: #0f172a;
  --sidebar-active-bg: #2563eb;
  --sidebar-hover-bg: #334155;
  --sidebar-text: #cbd5e1;
  --sidebar-text-active: #ffffff;
  --teal-primary: #2563eb;
  --teal-hover: #1d4ed8;
  --teal-light: #dbeafe;
  --teal-text: #1e40af;
  --topbar-bg: #ffffff;
  --body-bg: #f1f5f9;
  --card-bg: #ffffff;
}

/* 5. THEME LIGHT (Clean Modern Minimalist Light Mode) */
[data-theme="light"], body.theme-light {
  --sidebar-bg: #ffffff;
  --sidebar-header-bg: #f8fafc;
  --sidebar-active-bg: #e2e8f0;
  --sidebar-hover-bg: #f1f5f9;
  --sidebar-text: #475569;
  --sidebar-text-active: #0f172a;
  --sidebar-section-title: #94a3b8;
  --topbar-bg: #ffffff;
  --topbar-border: #cbd5e1;
  --body-bg: #f1f5f9;
  --card-bg: #ffffff;
  --card-border: #cbd5e1;
  --text-main: #0f172a;
  --teal-primary: #0d9488;
  --teal-hover: #0f766e;
}
