/* ===================================================================
   PLANET BIRU - MONITORING & DOKUMENTASI PEKERJAAN
   Modern Executive Design System
   =================================================================== */

:root {
  /* Color Palette - Planet Biru Deep Ocean & Cyan */
  --primary-900: #06192d;
  --primary-800: #0c2540;
  --primary-700: #103358;
  --primary-600: #004b87;
  --primary-500: #0077c8;
  --primary-400: #009fe3;
  --primary-300: #38bdf8;
  --primary-200: #bae6fd;
  --primary-100: #e0f2fe;
  --primary-50:  #f0f9ff;

  /* Dynamic Client Brand Colors */
  --brand-header-dark: #002b49;
  --brand-header-cyan: #009fe3;
  --brand-primary: #0077c8;
  --brand-accent-glow: rgba(0, 159, 227, 0.35);
  --brand-banner-gradient: linear-gradient(90deg, var(--brand-header-dark) 0%, var(--brand-primary) 60%, var(--brand-header-cyan) 100%);

  /* Header Table (Bound to active brand) */
  --header-dark: var(--brand-header-dark);
  --header-cyan: var(--brand-header-cyan);
  --header-row-alt: #f4f9fd;

  /* Accents */
  --success: #10b981;
  --success-bg: #d1fae5;
  --warning: #f59e0b;
  --warning-bg: #fef3c7;
  --danger: #ef4444;
  --danger-bg: #fee2e2;
  --purple: #8b5cf6;
  --purple-bg: #ede9fe;

  /* Surfaces & Text */
  --bg-main: #f8fafc;
  --bg-card: #ffffff;
  --bg-card-glass: rgba(255, 255, 255, 0.85);
  --border-color: #e2e8f0;
  --border-focus: #009fe3;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-light: #94a3b8;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --shadow-glow: 0 0 15px rgba(0, 159, 227, 0.35);

  /* Radius */
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 20px;
  --radius-full: 9999px;

  /* Transition */
  --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Dark Mode Overrides */
[data-theme="dark"] {
  --bg-main: #0a0f1d;
  --bg-card: #131b2e;
  --bg-card-glass: rgba(19, 27, 46, 0.85);
  --border-color: #243049;
  --text-main: #f1f5f9;
  --text-muted: #94a3b8;
  --text-light: #64748b;
  --header-row-alt: #162035;
  --header-dark: #071526;
  --header-cyan: #0284c7;
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

/* App Container */
.app-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  width: 100%;
}

/* Top Navigation Bar */
.top-nav {
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-color);
  padding: 0.75rem 1.75rem;
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-sm);
}

.nav-inner {
  max-width: 1750px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.brand-section {
  display: flex;
  align-items: center;
  gap: 0.875rem;
}

.logo-badge {
  width: 44px;
  height: 44px;
  background: linear-gradient(135deg, #004b87 0%, #00a8ff 100%);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-size: 1.35rem;
  box-shadow: var(--shadow-glow);
  position: relative;
  overflow: hidden;
}

.logo-badge::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.3) 0%, transparent 70%);
}

.brand-info h1 {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(90deg, #002b49 0%, #009fe3 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

[data-theme="dark"] .brand-info h1 {
  background: linear-gradient(90deg, #e0f2fe 0%, #38bdf8 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-info p {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Nav Actions */
.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.55rem 1.1rem;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}

.btn-sm {
  padding: 0.35rem 0.75rem;
  font-size: 0.8rem;
  border-radius: var(--radius-sm);
}

.btn-lg {
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  border-radius: var(--radius-lg);
}

.btn-primary {
  background: linear-gradient(135deg, #0077c8 0%, #009fe3 100%);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(0, 159, 227, 0.25);
}

.btn-primary:hover {
  background: linear-gradient(135deg, #0060a0 0%, #0084d6 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(0, 159, 227, 0.35);
}

.btn-bot {
  background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
  color: #ffffff;
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.25);
  animation: pulse-glow 3s infinite;
}

.btn-bot:hover {
  background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(99, 102, 241, 0.4);
}

@keyframes pulse-glow {
  0%, 100% { box-shadow: 0 0 10px rgba(139, 92, 246, 0.3); }
  50% { box-shadow: 0 0 18px rgba(139, 92, 246, 0.6); }
}

.btn-excel {
  background: #107c41;
  color: #ffffff;
}
.btn-excel:hover {
  background: #0b5e31;
  transform: translateY(-1px);
}

.btn-pdf {
  background: #dc2626;
  color: #ffffff;
}
.btn-pdf:hover {
  background: #b91c1c;
  transform: translateY(-1px);
}

.btn-ppt {
  background: #ea580c;
  color: #ffffff;
}
.btn-ppt:hover {
  background: #c2410c;
  transform: translateY(-1px);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-main);
  border-color: var(--border-color);
}

.btn-secondary:hover {
  background: var(--primary-50);
  border-color: var(--primary-300);
}

[data-theme="dark"] .btn-secondary:hover {
  background: var(--primary-800);
  border-color: var(--primary-500);
}

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
}
.btn-ghost:hover {
  color: var(--text-main);
  background: rgba(0, 0, 0, 0.05);
}

/* Main Content Area */
.main-wrapper {
  flex: 1;
  max-width: 1750px;
  width: 100%;
  margin: 0 auto;
  padding: 1.5rem 1.75rem 3rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* KPI Overview Grid */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.kpi-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  gap: 1.25rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary-300);
}

.kpi-icon {
  width: 50px;
  height: 50px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
}

.kpi-icon.blue { background: rgba(0, 159, 227, 0.12); color: #009fe3; }
.kpi-icon.green { background: rgba(16, 185, 129, 0.12); color: #10b981; }
.kpi-icon.purple { background: rgba(139, 92, 246, 0.12); color: #8b5cf6; }
.kpi-icon.orange { background: rgba(245, 158, 11, 0.12); color: #f59e0b; }

.kpi-content {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.kpi-label {
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}

.kpi-value {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.kpi-sub {
  font-size: 0.75rem;
  color: var(--text-light);
  margin-top: 0.15rem;
}

/* Control & Filter Toolbar */
.toolbar-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1rem 1.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  box-shadow: var(--shadow-sm);
}

.toolbar-left {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
}

.search-box {
  position: relative;
  min-width: 260px;
  max-width: 380px;
  flex: 1;
}

.search-box svg {
  position: absolute;
  left: 0.85rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  width: 18px;
  height: 18px;
  pointer-events: none;
}

.search-input {
  width: 100%;
  padding: 0.55rem 0.85rem 0.55rem 2.4rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-main);
  color: var(--text-main);
  font-size: 0.875rem;
  transition: var(--transition);
}

.search-input:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(0, 159, 227, 0.15);
}

.filter-select {
  padding: 0.55rem 0.85rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-main);
  color: var(--text-main);
  font-size: 0.875rem;
  cursor: pointer;
}

.toolbar-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Table Container & Table Styling */
.table-wrapper {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.table-header-banner {
  background: linear-gradient(90deg, #002b49 0%, #004b87 60%, #009fe3 100%);
  color: #ffffff;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.table-title {
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.table-stats-badge {
  background: rgba(255, 255, 255, 0.18);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.25);
}

.table-scroll {
  overflow-x: auto;
  max-width: 100%;
  position: relative;
}

/* The Monitoring Table */
.monitoring-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.815rem;
  text-align: left;
  white-space: nowrap;
}

/* Header Rows Matching the Image */
.monitoring-table thead tr:first-child th {
  background-color: var(--header-dark);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.03em;
  padding: 0.75rem 0.65rem;
  border: 1px solid #143e60;
  text-align: center;
  vertical-align: middle;
}

/* Sub-header for Ukuran M2 */
.monitoring-table thead tr:nth-child(2) th {
  background-color: var(--header-cyan);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.72rem;
  padding: 0.5rem 0.5rem;
  border: 1px solid #0084ba;
  text-align: center;
}

.monitoring-table thead th.cyan-header {
  background-color: var(--header-cyan) !important;
}

/* Table Body */
.monitoring-table tbody tr {
  border-bottom: 1px solid var(--border-color);
  transition: background-color 0.15s ease;
}

.monitoring-table tbody tr:nth-child(even) {
  background-color: var(--header-row-alt);
}

.monitoring-table tbody tr:hover {
  background-color: rgba(0, 159, 227, 0.08);
}

.monitoring-table td {
  padding: 0.65rem 0.65rem;
  border: 1px solid var(--border-color);
  vertical-align: middle;
}

/* Alignment utilities for table */
.text-center { text-align: center !important; }
.text-right { text-align: right !important; }
.text-left { text-align: left !important; }
.font-bold { font-weight: 700 !important; }
.font-semibold { font-weight: 600 !important; }
.text-mono { font-family: 'JetBrains Mono', Consolas, monospace; }

/* Status Badges */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-full);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.badge-success { background: var(--success-bg); color: #065f46; }
.badge-warning { background: var(--warning-bg); color: #92400e; }
.badge-info { background: var(--primary-100); color: #0369a1; }
.badge-purple { background: var(--purple-bg); color: #5b21b6; }

[data-theme="dark"] .badge-success { background: rgba(16, 185, 129, 0.2); color: #34d399; }
[data-theme="dark"] .badge-warning { background: rgba(245, 158, 11, 0.2); color: #fbbf24; }
[data-theme="dark"] .badge-info { background: rgba(0, 159, 227, 0.2); color: #38bdf8; }
[data-theme="dark"] .badge-purple { background: rgba(139, 92, 246, 0.2); color: #c084fc; }

/* Action buttons inside table */
.row-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
}

.action-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.3rem;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.action-btn:hover {
  background: rgba(0, 0, 0, 0.06);
  color: var(--text-main);
}

.action-btn.btn-edit:hover { color: #0077c8; background: rgba(0, 119, 200, 0.1); }
.action-btn.btn-photo:hover { color: #10b981; background: rgba(16, 185, 129, 0.1); }
.action-btn.btn-del:hover { color: #ef4444; background: rgba(239, 68, 68, 0.1); }

/* Table Footer Summary */
.monitoring-table tfoot tr td {
  background-color: var(--header-dark);
  color: #ffffff;
  font-weight: 800;
  font-size: 0.85rem;
  padding: 0.85rem 0.65rem;
  border: 1px solid #143e60;
}

/* Modals */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 15, 30, 0.65);
  backdrop-filter: blur(6px);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-container {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  max-width: 820px;
  width: 100%;
  max-height: 90vh;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-xl);
  transform: translateY(20px) scale(0.98);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  overflow: hidden;
}

.modal-overlay.active .modal-container {
  transform: translateY(0) scale(1);
}

.modal-header {
  padding: 1.25rem 1.75rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--bg-main);
}

.modal-header h3 {
  font-size: 1.15rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.modal-body {
  padding: 1.5rem 1.75rem;
  overflow-y: auto;
  flex: 1;
}

.modal-footer {
  padding: 1rem 1.75rem;
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  background: var(--bg-main);
}

/* Form Styling */
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.form-group.col-span-2 {
  grid-column: span 2;
}

.form-group label {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
}

.form-input, .form-select, .form-textarea {
  width: 100%;
  padding: 0.55rem 0.8rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-main);
  font-size: 0.875rem;
  font-family: inherit;
  transition: var(--transition);
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(0, 159, 227, 0.15);
}

.calc-box {
  background: rgba(0, 159, 227, 0.06);
  border: 1px dashed var(--primary-300);
  border-radius: var(--radius-md);
  padding: 0.85rem;
  margin-top: 0.5rem;
}

.calc-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  margin-bottom: 0.35rem;
}

.calc-row.grand {
  margin-top: 0.5rem;
  padding-top: 0.5rem;
  border-top: 1px solid var(--primary-200);
  font-weight: 800;
  font-size: 1rem;
  color: #0077c8;
}

/* Bot Input Panel Tabs & Textarea */
.bot-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 1.25rem;
  gap: 0.5rem;
}

.bot-tab {
  padding: 0.6rem 1.1rem;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.bot-tab.active {
  color: #0077c8;
  border-bottom-color: #0077c8;
}

.bot-hint {
  background: rgba(99, 102, 241, 0.08);
  border-left: 3px solid #6366f1;
  padding: 0.75rem 1rem;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.bot-textarea {
  min-height: 180px;
  font-family: 'JetBrains Mono', Consolas, monospace;
  font-size: 0.85rem;
  line-height: 1.6;
}

/* Photo Documentation Gallery */
.photo-upload-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.photo-slot {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.photo-slot-title {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
  text-align: center;
}

.photo-dropzone {
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-lg);
  aspect-ratio: 4/3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem;
  cursor: pointer;
  background: var(--bg-main);
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.photo-dropzone:hover {
  border-color: var(--primary-400);
  background: rgba(0, 159, 227, 0.04);
}

.photo-preview-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  top: 0;
  left: 0;
}

.photo-remove-btn {
  position: absolute;
  top: 6px;
  right: 6px;
  background: rgba(239, 68, 68, 0.85);
  color: #fff;
  border: none;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 5;
}

/* Export Dialog options */
.export-card-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.export-card {
  border: 2px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.75rem;
  cursor: pointer;
  transition: var(--transition);
  background: var(--bg-card);
}

.export-card:hover {
  border-color: var(--primary-400);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.export-card.active {
  border-color: #0077c8;
  background: rgba(0, 119, 200, 0.05);
}

.export-icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: #fff;
}

.export-icon.excel { background: #107c41; }
.export-icon.pdf { background: #dc2626; }
.export-icon.ppt { background: #ea580c; }

/* Responsive rules */
@media (max-width: 1024px) {
  .nav-inner { flex-direction: column; align-items: stretch; }
  .toolbar-card { flex-direction: column; align-items: stretch; }
  .photo-upload-grid { grid-template-columns: 1fr; }
  .export-card-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .form-group.col-span-2 { grid-column: span 1; }
}

/* Toast Notification */
.toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--primary-500);
  border-radius: var(--radius-md);
  padding: 0.85rem 1.25rem;
  box-shadow: var(--shadow-lg);
  font-size: 0.875rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  transform: translateX(100%);
  opacity: 0;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
}

.toast.show {
  transform: translateX(0);
  opacity: 1;
}

.toast.success { border-left-color: var(--success); }
.toast.error { border-left-color: var(--danger); }
/* ===================================================================
   INTERACTIVE EXCEL SPREADSHEET TABLE STYLES (Excel-like Edit/Input/Delete)
   =================================================================== */
.monitoring-table td {
  padding: 0.2rem 0.25rem;
  border: 1px solid var(--border-color);
  vertical-align: middle;
  background: var(--bg-card);
}

.monitoring-table tbody tr:nth-child(even) td {
  background-color: var(--header-row-alt);
}

.monitoring-table tbody tr:hover td {
  background-color: rgba(0, 159, 227, 0.05);
}

/* Excel Cell Input */
.excel-input {
  width: 100%;
  border: 1px solid transparent;
  background: transparent;
  font-family: inherit;
  font-size: 0.815rem;
  color: var(--text-main);
  padding: 0.35rem 0.45rem;
  border-radius: var(--radius-sm);
  transition: all 0.15s ease;
  box-sizing: border-box;
}

.excel-input:hover {
  background: rgba(0, 159, 227, 0.06);
  border-color: rgba(0, 159, 227, 0.3);
}

.excel-input:focus {
  background: #ffffff;
  border: 2px solid var(--brand-header-cyan) !important;
  box-shadow: 0 0 0 3px var(--brand-accent-glow);
  outline: none;
  z-index: 10;
  position: relative;
}

[data-theme="dark"] .excel-input:focus {
  background: #1e293b;
  color: #ffffff;
}

select.excel-input {
  cursor: pointer;
}

/* Auto-calculated Formula Displays in Excel */
.excel-calc {
  display: block;
  width: 100%;
  padding: 0.35rem 0.45rem;
  font-weight: 700;
  border-radius: var(--radius-sm);
  box-sizing: border-box;
}

/* Excel Add Row Button Bar */
.add-row-tr td {
  padding: 0.65rem 1rem !important;
  text-align: center;
  background: rgba(0, 159, 227, 0.03) !important;
  border: 2px dashed var(--brand-header-cyan) !important;
  cursor: pointer;
  transition: var(--transition);
}

.add-row-tr:hover td {
  background: rgba(0, 159, 227, 0.1) !important;
  border-color: var(--brand-primary) !important;
}

.add-row-btn-inner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--brand-primary);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* Row Delete & Photo Action Buttons */
.cell-action-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.25rem;
  border-radius: 4px;
  color: var(--text-muted);
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.cell-action-btn:hover {
  background: rgba(0, 0, 0, 0.08);
}

.cell-action-btn.btn-del:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.15);
}

.cell-action-btn.btn-photo:hover {
  color: #10b981;
  background: rgba(16, 185, 129, 0.15);
}

/* ===================================================================
   CLIENT MANAGEMENT & BRAND THEME SWITCHER (Requirements 4 & 5)
   =================================================================== */
.client-brand-selector {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-main);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.3rem 0.65rem;
}

.client-color-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 1px rgba(0,0,0,0.2);
  flex-shrink: 0;
}

.client-select-dropdown {
  border: none;
  background: transparent;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-main);
  cursor: pointer;
  outline: none;
}

.client-manage-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.25rem 0.4rem;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  transition: var(--transition);
}

.client-manage-btn:hover {
  background: rgba(0,0,0,0.06);
  color: var(--text-main);
}

.theme-palette-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 0.75rem;
  margin-top: 0.5rem;
}

.theme-card-option {
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 0.65rem 0.75rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  align-items: center;
  transition: var(--transition);
}

.theme-card-option:hover {
  border-color: var(--brand-header-cyan);
  transform: translateY(-2px);
}

.theme-card-option.active {
  border-color: var(--brand-primary);
  background: rgba(0, 119, 200, 0.06);
}

.theme-swatch {
  width: 100%;
  height: 22px;
  border-radius: 4px;
}

/* ===================================================================
   EXPORT RENAME & CUSTOM OPTIONS (Requirement 6)
   =================================================================== */
.export-rename-section {
  background: var(--bg-main);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 1rem 1.25rem;
  margin-bottom: 1.25rem;
}

.export-filename-input-group {
  display: flex;
  align-items: center;
  margin-top: 0.5rem;
}

.export-filename-input {
  flex: 1;
  padding: 0.6rem 0.85rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md) 0 0 var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  font-family: inherit;
  background: var(--bg-card);
  color: var(--text-main);
}

.export-filename-input:focus {
  outline: none;
  border-color: var(--brand-header-cyan);
}

.export-extension-badge {
  padding: 0.6rem 0.9rem;
  background: var(--header-dark);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.85rem;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  border: 1px solid var(--header-dark);
}

.quick-templates-tag {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.5rem;
}

.template-pill {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-full);
  background: rgba(0, 159, 227, 0.1);
  color: var(--brand-primary);
  cursor: pointer;
  border: 1px solid transparent;
  transition: var(--transition);
}

.template-pill:hover {
  background: rgba(0, 159, 227, 0.2);
  border-color: var(--brand-header-cyan);
}

/* ===================================================================
   FILE IMPORT & CLEAR DASHBOARD STYLES
   =================================================================== */
.btn-danger-outline {
  background: transparent;
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.35);
}

.btn-danger-outline:hover {
  background: rgba(239, 68, 68, 0.1);
  border-color: #ef4444;
}

.import-dropzone {
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2.25rem 1.5rem;
  text-align: center;
  background: var(--bg-main);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}

.import-dropzone:hover, .import-dropzone.dragover {
  border-color: var(--brand-header-cyan);
  background: rgba(0, 159, 227, 0.05);
}

.import-icons-badge {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.import-file-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 700;
  box-shadow: var(--shadow-sm);
}

/* ===================================================================
   AUTO-SAVE & POWER OUTAGE RESILIENCE BAR (PROTEKSI LISTRIK PADAM)
   =================================================================== */

.recovery-banner {
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.12) 0%, rgba(0, 159, 227, 0.1) 100%);
  border-bottom: 1px solid rgba(16, 185, 129, 0.35);
  padding: 0.6rem 1.75rem;
  display: none;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-main);
  backdrop-filter: blur(8px);
}

.recovery-banner strong {
  color: #059669;
}

[data-theme="dark"] .recovery-banner {
  background: linear-gradient(90deg, rgba(16, 185, 129, 0.2) 0%, rgba(0, 159, 227, 0.15) 100%);
  color: #f1f5f9;
}

.autosave-bar {
  background: var(--bg-card);
  border-bottom: 1px solid var(--border-color);
  padding: 0.6rem 1.75rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
  position: relative;
  z-index: 40;
}

.autosave-inner {
  max-width: 1750px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
}

.autosave-left {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.autosave-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.autosave-label {
  font-size: 0.7rem;
  font-weight: 800;
  color: var(--text-muted);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.autosave-file-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: var(--bg-main);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.35rem 0.65rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-main);
  max-width: 320px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: var(--transition);
  cursor: pointer;
}

.autosave-file-chip:hover {
  border-color: var(--brand-header-cyan);
  background: rgba(0, 159, 227, 0.06);
}

.autosave-folder-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: var(--bg-main);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.35rem 0.65rem;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.78rem;
  color: var(--text-muted);
  max-width: 300px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: var(--transition);
  cursor: pointer;
}

.autosave-folder-chip:hover {
  border-color: var(--brand-header-cyan);
  color: var(--text-main);
  background: rgba(0, 159, 227, 0.06);
}

.autosave-right {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.autosave-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 700;
  transition: var(--transition);
}

.status-saved {
  background: rgba(16, 185, 129, 0.12);
  color: #059669;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

[data-theme="dark"] .status-saved {
  background: rgba(16, 185, 129, 0.2);
  color: #34d399;
  border-color: rgba(16, 185, 129, 0.4);
}

.status-saving {
  background: rgba(245, 158, 11, 0.12);
  color: #d97706;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

[data-theme="dark"] .status-saving {
  background: rgba(245, 158, 11, 0.2);
  color: #fbbf24;
  border-color: rgba(245, 158, 11, 0.4);
}

.status-warning {
  background: rgba(239, 68, 68, 0.12);
  color: #dc2626;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.status-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  display: inline-block;
  position: relative;
}

.dot-saved {
  background-color: #10b981;
  box-shadow: 0 0 8px #10b981;
  animation: pulse-saved 2s infinite;
}

.dot-saving {
  background-color: #f59e0b;
  box-shadow: 0 0 8px #f59e0b;
  animation: pulse-saving 1s infinite;
}

.dot-warning {
  background-color: #ef4444;
}

@keyframes pulse-saved {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(16, 185, 129, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(16, 185, 129, 0); }
}

@keyframes pulse-saving {
  0% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(245, 158, 11, 0.7); }
  70% { transform: scale(1.1); box-shadow: 0 0 0 6px rgba(245, 158, 11, 0); }
  100% { transform: scale(0.9); box-shadow: 0 0 0 0 rgba(245, 158, 11, 0); }
}

.power-shield-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  font-weight: 800;
  padding: 0.3rem 0.65rem;
  border-radius: var(--radius-full);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.12) 0%, rgba(0, 159, 227, 0.15) 100%);
  color: #b45309;
  border: 1px solid rgba(245, 158, 11, 0.35);
  letter-spacing: 0.02em;
}

[data-theme="dark"] .power-shield-badge {
  color: #fbbf24;
  border-color: rgba(245, 158, 11, 0.5);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.2) 0%, rgba(0, 159, 227, 0.2) 100%);
}

.template-chip-btn {
  background: var(--bg-main);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 0.35rem 0.65rem;
  font-size: 0.75rem;
  font-family: 'JetBrains Mono', monospace;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
}

.template-chip-btn:hover {
  border-color: var(--brand-header-cyan);
  color: var(--text-main);
  background: rgba(0, 159, 227, 0.08);
}

.badge-checkpoint {
  display: inline-block;
  background: rgba(139, 92, 246, 0.12);
  color: #7c3aed;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.72rem;
  border: 1px solid rgba(139, 92, 246, 0.25);
}

.badge-main {
  display: inline-block;
  background: rgba(0, 159, 227, 0.12);
  color: #0077c8;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.72rem;
  border: 1px solid rgba(0, 159, 227, 0.25);
}

[data-theme="dark"] .badge-checkpoint {
  background: rgba(139, 92, 246, 0.25);
  color: #c4b5fd;
}

[data-theme="dark"] .badge-main {
  background: rgba(0, 159, 227, 0.25);
  color: #7dd3fc;
}

/* ===================================================================
   VIEW SWITCHER BAR (Tabel Monitoring vs Dashboard Dokumentasi A4)
   =================================================================== */
.view-switcher-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
  padding: 0.5rem 0.75rem;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  flex-wrap: wrap;
  gap: 0.75rem;
}

.view-tabs {
  display: flex;
  gap: 0.5rem;
  background: var(--bg-main);
  padding: 0.3rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
}

.view-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: var(--transition);
}

.view-tab-btn:hover {
  color: var(--text-main);
  background: rgba(0, 159, 227, 0.08);
}

.view-tab-btn.active {
  color: #ffffff;
  background: var(--brand-primary);
  box-shadow: 0 2px 6px rgba(0, 119, 200, 0.35);
}

.view-tab-badge {
  background: #10b981;
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.view-meta-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.active-client-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.85rem;
  background: rgba(0, 159, 227, 0.08);
  border: 1px solid rgba(0, 159, 227, 0.25);
  border-radius: 999px;
  font-size: 0.8rem;
  color: var(--brand-primary);
}

.active-client-chip .client-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--brand-header-cyan);
}

/* ===================================================================
   DASHBOARD DOKUMENTASI VISUAL (A4 LANDSCAPE)
   =================================================================== */
.doc-dashboard-wrapper {
  margin-bottom: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.doc-controls-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 0.85rem 1.25rem;
  box-shadow: var(--shadow-sm);
  flex-wrap: wrap;
  gap: 1rem;
}

.doc-controls-left {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
}

.doc-controls-right {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.control-group {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.control-group label {
  font-size: 0.72rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.doc-outlet-select {
  min-width: 280px;
  max-width: 380px;
  font-size: 0.82rem;
  padding: 0.35rem 0.65rem;
  font-weight: 600;
}

.doc-hint-banner {
  background: linear-gradient(90deg, rgba(0, 159, 227, 0.08) 0%, rgba(16, 185, 129, 0.08) 100%);
  border: 1px solid rgba(0, 159, 227, 0.25);
  border-radius: var(--radius-md);
  padding: 0.65rem 1rem;
  font-size: 0.82rem;
  color: var(--text-main);
  line-height: 1.45;
}

/* Outer Desktop Frame */
.a4-sheet-outer {
  background: #2b3342;
  border-radius: var(--radius-lg);
  padding: 2.25rem 1.5rem;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow-x: auto;
  box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.4);
}

[data-theme="dark"] .a4-sheet-outer {
  background: #0d131f;
}

/* ===================================================================
   PIXEL-PERFECT A4 LANDSCAPE SHEET (297mm x 210mm Ratio: ~1.4142)
   =================================================================== */
.a4-doc-sheet {
  width: 1060px;
  height: 750px;
  position: relative;
  background-color: #ffffff;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.35), 0 3px 10px rgba(0, 0, 0, 0.2);
  border-radius: 3px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  user-select: text;
}

/* Background PNG Layer */
.a4-bg-layer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: 100% 100%;
  background-position: center;
  background-repeat: no-repeat;
  z-index: 1;
  pointer-events: none;
}

/* Foreground Content Layer */
.a4-content-layer {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  padding: 42px 60px 35px;
  display: flex;
  flex-direction: column;
}

/* 5. Header: Nama Toko - Alamat */
.a4-header-row {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  margin-bottom: 24px;
}

.a4-store-title {
  font-size: 30px;
  font-weight: 800;
  color: #164284;
  font-family: 'Plus Jakarta Sans', Arial, -apple-system, sans-serif;
  letter-spacing: -0.3px;
  padding: 4px 10px;
  border-radius: 4px;
  border: 1px dashed transparent;
  outline: none;
  cursor: text;
  transition: var(--transition);
  min-width: 260px;
}

.a4-store-title:hover {
  background: rgba(22, 66, 132, 0.06);
  border-color: rgba(22, 66, 132, 0.3);
}

.a4-store-title:focus {
  background: rgba(22, 66, 132, 0.08);
  border-color: #164284;
  box-shadow: 0 0 0 2px rgba(22, 66, 132, 0.15);
}

/* Photos Container: 2 Parallel Columns */
.a4-photos-container {
  display: flex;
  gap: 70px;
  justify-content: center;
  align-items: flex-start;
  flex: 1;
}

.a4-photo-col {
  flex: 1;
  max-width: 440px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Photo Frame: Supports Portrait & Landscape */
.a4-photo-frame {
  width: 100%;
  height: 420px;
  border: 1.5px solid #888888;
  background: #ffffff;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border-radius: 2px;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.a4-photo-frame:hover {
  border-color: #009fe3;
  box-shadow: 0 4px 15px rgba(0, 159, 227, 0.25);
}

.a4-photo-img {
  width: 100%;
  height: 100%;
  display: block;
}

.a4-photo-img.fit-contain {
  object-fit: contain;
  background: #fafafa;
}

.a4-photo-img.fit-cover {
  object-fit: cover;
}

.a4-photo-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1.5rem;
  text-align: center;
  color: #64748b;
  width: 100%;
  height: 100%;
}

.photo-placeholder-icon {
  font-size: 2.75rem;
  opacity: 0.7;
}

.photo-placeholder-text {
  font-size: 0.95rem;
  font-weight: 600;
  color: #334155;
}

.photo-placeholder-sub {
  font-size: 0.75rem;
  color: #94a3b8;
}

.a4-photo-hover-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 43, 73, 0.65);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  font-weight: 700;
  opacity: 0;
  transition: opacity 0.2s;
  pointer-events: none;
  backdrop-filter: blur(2px);
}

.a4-photo-frame:hover .a4-photo-hover-overlay {
  opacity: 1;
}

/* 3 & 4. Labels under photos */
.a4-label-block {
  width: 100%;
  text-align: center;
  margin-top: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
}

.a4-label-tag {
  font-size: 20px;
  font-weight: 800;
  color: #000000;
  font-family: 'Plus Jakarta Sans', Arial, sans-serif;
  letter-spacing: 0.5px;
  margin-bottom: 2px;
}

.a4-text-material {
  font-size: 17px;
  font-weight: 800;
  color: #164284;
  font-family: 'Plus Jakarta Sans', Arial, sans-serif;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 3px;
  border: 1px dashed transparent;
  outline: none;
  cursor: text;
  transition: var(--transition);
  min-width: 180px;
}

.a4-text-material:hover {
  background: rgba(22, 66, 132, 0.06);
  border-color: rgba(22, 66, 132, 0.3);
}

.a4-text-material:focus {
  background: rgba(22, 66, 132, 0.08);
  border-color: #164284;
}

.a4-text-dimension {
  font-size: 17px;
  font-weight: 800;
  color: #164284;
  font-family: 'Plus Jakarta Sans', Arial, sans-serif;
  text-transform: uppercase;
  padding: 2px 8px;
  border-radius: 3px;
  border: 1px dashed transparent;
  outline: none;
  cursor: text;
  transition: var(--transition);
  min-width: 180px;
}

.a4-text-dimension:hover {
  background: rgba(22, 66, 132, 0.06);
  border-color: rgba(22, 66, 132, 0.3);
}

.a4-text-dimension:focus {
  background: rgba(22, 66, 132, 0.08);
  border-color: #164284;
}

/* ===================================================================
   PRINT STYLES FOR A4 LANDSCAPE (100% PERFECT FIT)
   =================================================================== */
@media print {
  @page {
    size: A4 landscape;
    margin: 0;
  }

  body {
    background: #ffffff !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  /* Hide everything except the A4 Document Sheet */
  .top-navbar,
  .recovery-banner,
  .autosave-bar,
  .view-switcher-bar,
  .kpi-grid,
  .toolbar-card,
  .table-wrapper,
  .doc-controls-card,
  .doc-hint-banner,
  .modal-overlay,
  .toast-container {
    display: none !important;
  }

  .main-wrapper {
    padding: 0 !important;
    margin: 0 !important;
  }

  .doc-dashboard-wrapper {
    display: block !important;
    margin: 0 !important;
    padding: 0 !important;
  }

  .a4-sheet-outer {
    background: transparent !important;
    padding: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
  }

  .a4-doc-sheet {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 297mm !important;
    height: 210mm !important;
    margin: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    page-break-after: always;
  }

  .a4-photo-frame:hover {
    border-color: #888888 !important;
    box-shadow: none !important;
  }

  .a4-photo-hover-overlay {
    display: none !important;
  }
}



