/* CSS RESET & VARIABLES */
:root {
  --bg-main: #f4f6fa;
  --bg-sidebar: #0f1f38;
  --bg-sidebar-hover: #172c4e;
  --bg-sidebar-active: #1d3b6a;
  --card-bg: #ffffff;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --text-light: #94a3b8;
  --border-color: #e2e8f0;
  --primary-blue: #2563eb;
  --primary-blue-hover: #1d4ed8;
  --success-green: #10b981;
  --warning-orange: #d97706;
  --danger-red: #ef4444;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-heading: 'Outfit', 'Inter', sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

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

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

/* APP LAYOUT */
.app-container {
  display: flex;
  min-height: 100vh;
}

/* LEFT SIDEBAR */
.sidebar {
  width: 250px;
  background-color: var(--bg-sidebar);
  color: #ffffff;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 20;
}

.sidebar-brand {
  padding: 24px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.brand-title {
  font-family: var(--font-heading);
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.brand-subtitle {
  font-size: 11.5px;
  color: #94a3b8;
  font-weight: 400;
  margin-top: 2px;
}

.sidebar-nav {
  padding: 16px 12px;
  flex-grow: 1;
  overflow-y: auto;
}

.nav-section-title {
  font-size: 11px;
  font-weight: 700;
  color: #64748b;
  letter-spacing: 0.08em;
  padding: 12px 12px 6px;
  text-transform: uppercase;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  color: #cbd5e1;
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.15s ease;
  margin-bottom: 3px;
}

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

.nav-item.active {
  background-color: var(--bg-sidebar-active);
  color: #ffffff;
  font-weight: 600;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
}

.nav-icon {
  width: 18px;
  height: 18px;
  stroke-width: 2;
  opacity: 0.85;
}

/* SYSTEM STATUS CARD (SIDEBAR BOTTOM) */
.system-status-box {
  margin: 16px 12px;
  padding: 14px 16px;
  background-color: #0b172a;
  border: 1px solid #1e293b;
  border-radius: 10px;
}

.status-heading {
  font-size: 10.5px;
  font-weight: 700;
  color: #64748b;
  letter-spacing: 0.06em;
  margin-bottom: 6px;
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}

.status-dot {
  width: 8px;
  height: 8px;
  background-color: var(--success-green);
  border-radius: 50%;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.7);
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.8; }
}

.status-text-primary {
  font-size: 13px;
  font-weight: 600;
  color: #f1f5f9;
}

.status-text-secondary {
  font-size: 11px;
  color: #94a3b8;
}

/* MAIN VIEW CONTAINER */
.main-content {
  flex-grow: 1;
  padding: 24px 32px 60px;
  overflow-x: hidden;
  max-width: 1600px;
}

/* CONTENT HEADER */
.content-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 16px;
}

.header-title {
  font-family: var(--font-heading);
  font-size: 26px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
}

.header-subtitle {
  font-size: 13.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

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

.badge-prototype {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  background-color: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
  border-radius: 9999px;
  font-size: 12px;
  font-weight: 600;
}

.badge-dot {
  width: 7px;
  height: 7px;
  background-color: #10b981;
  border-radius: 50%;
}

.category-select, .status-select {
  padding: 7px 14px;
  border: 1px solid var(--border-color);
  background-color: #ffffff;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  color: #334155;
  cursor: pointer;
  outline: none;
  transition: all 0.15s ease;
}

.category-select:focus, .status-select:focus {
  border-color: var(--primary-blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.btn-sync {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border: 1px solid var(--border-color);
  background-color: #ffffff;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  color: #334155;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-sync:hover {
  background-color: #f8fafc;
  border-color: #cbd5e1;
}

.btn-sync.spinning .sync-icon {
  animation: spin 1s linear infinite;
}

@keyframes spin {
  100% { transform: rotate(360deg); }
}

.sync-icon {
  width: 15px;
  height: 15px;
}

/* SECTION TITLES */
.section-title {
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 700;
  color: #0f172a;
}

.section-subtitle {
  font-size: 12.5px;
  color: var(--text-muted);
}

.section-header-inline {
  display: flex;
  align-items: center;
  margin-bottom: 12px;
}

.section-header-inline.space-between {
  justify-content: space-between;
}

/* RINGKASAN KINERJA (KPI) */
.section-kpi {
  margin-bottom: 28px;
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 16px;
}

.kpi-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 18px 20px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.kpi-card:hover {
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.04);
}

.kpi-label {
  font-size: 12.5px;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 6px;
}

.kpi-value {
  font-family: var(--font-heading);
  font-size: 26px;
  font-weight: 800;
  color: #0f172a;
  letter-spacing: -0.02em;
}

.kpi-sub {
  font-size: 11.5px;
  color: #94a3b8;
  margin-top: 4px;
}

.text-green { color: #059669 !important; }
.text-orange { color: #d97706 !important; }
.text-blue { color: #2563eb !important; }
.text-red { color: #dc2626 !important; }
.text-blue-deep { color: #1e3a8a !important; }

/* PROGRESS BAR */
.progress-container {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 14px 20px;
}

.progress-labels {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.progress-title {
  font-size: 13px;
  font-weight: 500;
  color: #334155;
}

.progress-percentage {
  font-family: var(--font-heading);
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
}

.progress-bar-bg {
  height: 8px;
  background-color: #e2e8f0;
  border-radius: 9999px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, #2563eb, #3b82f6);
  border-radius: 9999px;
  transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

/* VIRTUAL AI OFFICE */
.section-virtual-office {
  margin-bottom: 28px;
}

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

.btn-primary-sm:hover {
  background-color: var(--primary-blue-hover);
}

.agents-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 14px;
  margin-bottom: 14px;
}

.agent-card {
  background: var(--card-bg);
  border: 1.5px solid var(--border-color);
  border-radius: 12px;
  padding: 16px 14px;
  text-align: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.agent-card:hover {
  border-color: #93c5fd;
  transform: translateY(-2px);
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.04);
}

.agent-card.active-selection {
  border: 2px solid var(--primary-blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
  background-color: #f8fafc;
}

.agent-card-icon {
  width: 36px;
  height: 36px;
  margin: 0 auto 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #475569;
}

.agent-card-icon svg {
  width: 22px;
  height: 22px;
}

.agent-card-name {
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 4px;
}

.agent-card-status {
  font-size: 11.5px;
  font-weight: 600;
}

.status-success { color: #059669; }
.status-active { color: #2563eb; }
.status-ready { color: #2563eb; }
.status-muted { color: #94a3b8; }

/* AGENT DETAIL & ACTIVITY ROW */
.agent-detail-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.agent-desc-box, .agent-history-box {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 18px 20px;
}

.agent-desc-title, .history-title {
  font-size: 14.5px;
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 8px;
}

.agent-desc-text {
  font-size: 13px;
  color: #475569;
  line-height: 1.5;
  margin-bottom: 14px;
}

.agent-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-action-primary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: var(--primary-blue);
  color: #ffffff;
  border: none;
  padding: 8px 14px;
  font-size: 12.5px;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-action-primary svg {
  width: 14px;
  height: 14px;
}

.btn-action-primary:hover {
  background-color: var(--primary-blue-hover);
}

.btn-action-secondary {
  background-color: #f1f5f9;
  color: #334155;
  border: 1px solid var(--border-color);
  padding: 8px 14px;
  font-size: 12.5px;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.btn-action-secondary:hover {
  background-color: #e2e8f0;
}

.history-card {
  background-color: #f8fafc;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 12px 14px;
}

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

.history-card-agent {
  font-size: 12.5px;
  font-weight: 700;
  color: #0f172a;
}

.history-card-time {
  font-size: 11px;
  color: #94a3b8;
}

.history-card-body {
  font-size: 12.5px;
  color: #334155;
}

/* MONITORING LAYOUT */
.monitoring-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 20px;
}

.table-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.table-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}

.source-tag {
  font-size: 11.5px;
  color: #94a3b8;
  font-family: var(--font-mono);
}

.table-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.table-responsive {
  width: 100%;
  overflow-x: auto;
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  text-align: left;
}

.data-table th {
  background-color: #f8fafc;
  padding: 11px 14px;
  font-weight: 600;
  color: #475569;
  border-bottom: 1px solid var(--border-color);
  white-space: nowrap;
}

.data-table td {
  padding: 12px 14px;
  border-bottom: 1px solid #f1f5f9;
  color: #334155;
}

.data-table tr:hover {
  background-color: #f8fafc;
}

.text-right { text-align: right; }
.text-center { text-align: center; }
.font-mono { font-family: var(--font-mono); }
.font-bold { font-weight: 700; }

/* TABLE BADGES */
.badge-status {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.badge-status.menunggak {
  background-color: #fee2e2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.badge-status.bayar-sebagian {
  background-color: #fef3c7;
  color: #92400e;
  border: 1px solid #fde68a;
}

.badge-status.lunas {
  background-color: #dcfce7;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.btn-table-action {
  background-color: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 11.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.btn-table-action:hover {
  background-color: #dbeafe;
}

/* AI CHAT CARD */
.ai-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  height: 520px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.ai-card-header {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.ai-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ai-sparkle-icon {
  width: 28px;
  height: 28px;
  background-color: #eff6ff;
  color: var(--primary-blue);
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ai-sparkle-icon svg {
  width: 16px;
  height: 16px;
}

.ai-agent-title {
  font-size: 13.5px;
  font-weight: 700;
  color: #0f172a;
}

.ai-agent-status {
  font-size: 11px;
  color: #059669;
}

.ai-messages {
  flex-grow: 1;
  padding: 16px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 12px;
  font-size: 12.5px;
  background-color: #fbfcfe;
}

.ai-msg {
  max-width: 90%;
  padding: 10px 14px;
  border-radius: 10px;
  line-height: 1.5;
}

.ai-msg-bot {
  align-self: flex-start;
  background-color: #ffffff;
  border: 1px solid var(--border-color);
  color: #1e293b;
}

.ai-msg-user {
  align-self: flex-end;
  background-color: var(--primary-blue);
  color: #ffffff;
}

.ai-quick-prompts {
  padding: 8px 14px;
  display: flex;
  gap: 6px;
  overflow-x: auto;
  border-top: 1px solid #f1f5f9;
}

.ai-chip {
  background-color: #f1f5f9;
  border: 1px solid var(--border-color);
  color: #475569;
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 11px;
  font-weight: 500;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.ai-chip:hover {
  background-color: #e2e8f0;
  color: #0f172a;
}

.ai-input-form {
  display: flex;
  padding: 10px 14px;
  border-top: 1px solid var(--border-color);
  gap: 8px;
  background-color: #ffffff;
  border-radius: 0 0 12px 12px;
}

.ai-chat-input {
  flex-grow: 1;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 12.5px;
  outline: none;
}

.ai-chat-input:focus {
  border-color: var(--primary-blue);
}

.ai-btn-send {
  background-color: var(--primary-blue);
  color: #ffffff;
  border: none;
  border-radius: 8px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s ease;
}

.ai-btn-send:hover {
  background-color: var(--primary-blue-hover);
}

.ai-btn-send svg {
  width: 16px;
  height: 16px;
}

/* MODAL OVERLAY & CONTAINER */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background-color: rgba(15, 23, 42, 0.7);
  z-index: 100;
  overflow-y: auto;
  padding: 24px;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}

.modal-overlay.open {
  display: flex;
}

.modal-container {
  background-color: #f8fafc;
  border-radius: 16px;
  width: 100%;
  max-width: 900px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  max-height: 94vh;
  display: flex;
  flex-direction: column;
}

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

.modal-title {
  font-family: var(--font-heading);
  font-size: 17px;
  font-weight: 800;
  color: #0f172a;
}

.modal-subtitle {
  font-size: 12px;
  color: var(--text-muted);
}

.modal-actions-top {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-modal-action {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
  border: none;
}

.btn-modal-action svg {
  width: 14px;
  height: 14px;
}

.btn-pdf {
  background-color: var(--primary-blue);
  color: #ffffff;
}

.btn-pdf:hover {
  background-color: var(--primary-blue-hover);
}

.btn-send-wa {
  background-color: #059669;
  color: #ffffff;
}

.btn-send-wa:hover {
  background-color: #047857;
}

.btn-modal-close {
  background: none;
  border: none;
  font-size: 26px;
  color: #64748b;
  cursor: pointer;
  padding: 0 6px;
}

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

.modal-body {
  padding: 24px;
  overflow-y: auto;
  background-color: #e2e8f0;
  display: flex;
  justify-content: center;
}

/* INVOICE PAPER (OFFICIAL PEMDA STPD) */
.invoice-paper {
  background: #ffffff;
  width: 100%;
  max-width: 800px;
  padding: 24px 30px;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  color: #000000;
  font-family: 'Inter', serif;
}

.invoice-kop {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 6px;
}

.kop-emblem-wrap {
  width: 72px;
  height: 72px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.kop-emblem-img {
  width: 72px;
  height: 72px;
  object-fit: contain;
  display: block;
}

.kop-text {
  text-align: center;
  flex-grow: 1;
}

.kop-text h2 {
  font-size: 13.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  margin-bottom: 2px;
  color: #000000;
  line-height: 1.25;
}

.kop-text h3 {
  font-size: 16px;
  font-weight: 900;
  letter-spacing: 0.05em;
  color: #0f172a;
  margin-bottom: 2px;
  line-height: 1.25;
}

.kop-sub {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.03em;
  color: #1e293b;
  margin-bottom: 3px;
}

.kop-address, .kop-contact, .kop-web {
  font-size: 9px;
  color: #334155;
  margin-bottom: 1.5px;
  line-height: 1.35;
}

.kop-divider {
  border-top: 3px solid #000000;
  border-bottom: 1px solid #000000;
  height: 5px;
  margin: 6px 0 10px;
  width: 100%;
}

.invoice-title-block {
  text-align: center;
  margin-bottom: 10px;
}

.invoice-title-block h1 {
  font-size: 13.5px;
  font-weight: 800;
  text-decoration: underline;
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}

.invoice-number {
  font-size: 11px;
  font-weight: 700;
  font-family: var(--font-mono);
}

.invoice-meta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 10px;
  font-size: 10.5px;
}

.meta-box {
  background-color: #f8fafc;
  border: 1px solid #cbd5e1;
  padding: 8px 10px;
  border-radius: 4px;
}

.meta-box-title {
  font-weight: 800;
  font-size: 10px;
  border-bottom: 1px dashed #cbd5e1;
  padding-bottom: 3px;
  margin-bottom: 5px;
  color: #1e293b;
}

.meta-table {
  width: 100%;
}

.meta-table td {
  padding: 1.5px 3px;
  vertical-align: top;
}

.meta-table td:first-child {
  width: 40%;
  color: #475569;
}

.invoice-calc-wrap {
  margin-bottom: 8px;
}

.invoice-calc-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}

.invoice-calc-table th, .invoice-calc-table td {
  border: 1px solid #94a3b8;
  padding: 5px 8px;
}

.invoice-calc-table th {
  background-color: #f1f5f9;
  font-weight: 700;
  text-align: center;
}

.total-row {
  background-color: #f8fafc;
  font-size: 11.5px;
}

.terbilang-box {
  border: 1px dashed #94a3b8;
  background-color: #f8fafc;
  padding: 6px 10px;
  font-size: 10.5px;
  margin-bottom: 10px;
  border-radius: 4px;
}

.terbilang-label {
  font-weight: 700;
  color: #475569;
  margin-right: 6px;
}

.terbilang-words {
  font-weight: 800;
  font-style: italic;
  color: #0f172a;
}

.invoice-footer-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 16px;
  margin-bottom: 10px;
  font-size: 10px;
}

.inst-title {
  font-weight: 800;
  margin-bottom: 3px;
}

.inst-list {
  padding-left: 16px;
  color: #334155;
  margin-bottom: 6px;
}

.inst-list li {
  margin-bottom: 2px;
  line-height: 1.3;
}

.va-number {
  color: #1e40af;
  font-family: var(--font-mono);
}

.qris-box {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 8px;
  background: #f8fafc;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
}

.qris-svg {
  width: 38px;
  height: 38px;
}

.qris-label {
  font-size: 9.5px;
  font-weight: 700;
  color: #334155;
}

.signature-block {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.sig-city-date {
  font-size: 10px;
  line-height: 1.3;
}

.sig-title {
  font-weight: 700;
  font-size: 10px;
  margin-top: 3px;
  line-height: 1.25;
}

.sig-stamp-wrap {
  position: relative;
  height: 52px;
  width: 170px;
  margin: 4px 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sig-stamp {
  position: absolute;
  border: 2px solid rgba(220, 38, 38, 0.7);
  border-radius: 50%;
  width: 58px;
  height: 58px;
  color: rgba(220, 38, 38, 0.75);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-size: 7px;
  font-weight: 900;
  text-align: center;
  transform: rotate(-15deg);
  left: 8px;
}

.sig-signature {
  font-size: 18px;
  font-family: 'Outfit', cursive, sans-serif;
  color: #1e3a8a;
  transform: rotate(-3deg);
  z-index: 2;
}

.sig-name {
  font-size: 10.5px;
}

.sig-nip {
  font-size: 9.5px;
  color: #475569;
}

.invoice-bottom-note {
  font-size: 8px;
  color: #64748b;
  text-align: center;
  border-top: 1px solid #cbd5e1;
  padding-top: 6px;
}

/* TOAST */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background-color: #0f172a;
  color: #ffffff;
  padding: 12px 20px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.3);
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.25s ease;
  pointer-events: none;
  z-index: 200;
}

.toast.show {
  opacity: 1;
  transform: translateY(0);
}

/* RESPONSIVE DESIGN */
@media (max-width: 1200px) {
  .monitoring-layout {
    grid-template-columns: 1fr;
  }
  .agents-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  .sidebar {
    width: 70px;
  }
  .brand-subtitle, .sidebar-brand .brand-title, .nav-item span, .nav-section-title, .system-status-box {
    display: none;
  }
  .nav-item {
    justify-content: center;
    padding: 12px 0;
  }
  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .agent-detail-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .main-content {
    padding: 16px;
  }
  .kpi-grid {
    grid-template-columns: 1fr;
  }
  .agents-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .header-right {
    width: 100%;
    justify-content: flex-start;
  }
}
