/* ============================================================
   Clamara Ops v2.0 — Corporate Safari Command Centre
   Design: Dark sidebar + warm earth tones + glass morphism
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,300;0,9..40,400;0,9..40,500;0,9..40,600;0,9..40,700;1,9..40,400&family=Playfair+Display:wght@600;700&display=swap');

:root {
  /* Core palette — African earth */
  --c-forest: #0a3d2a;
  --c-forest-deep: #062a1c;
  --c-forest-light: #0d4e36;
  --c-gold: #c9993a;
  --c-gold-light: #e6c67a;
  --c-gold-muted: rgba(201,153,58,0.15);
  --c-sand: #f5f0e6;
  --c-sand-light: #faf8f3;
  --c-ivory: #fdfcfa;

  /* Neutrals */
  --c-ink: #1a1a2e;
  --c-ink-light: #2d2d44;
  --c-text: #334155;
  --c-text-light: #64748b;
  --c-text-xlight: #94a3b8;
  --c-border: rgba(15,23,42,0.08);
  --c-border-strong: rgba(15,23,42,0.14);

  /* Surfaces */
  --c-bg: #f8f6f1;
  --c-card: #ffffff;
  --c-card-hover: #fefefe;
  --c-sidebar: linear-gradient(180deg, #0a3d2a 0%, #062a1c 40%, #041e14 100%);

  /* Status palette */
  --status-inquiry: #6366f1;
  --status-confirmed: #0ea5e9;
  --status-deposit: #f59e0b;
  --status-paid: #10b981;
  --status-ongoing: #8b5cf6;
  --status-completed: #059669;
  --status-cancelled: #ef4444;
  --status-default: #94a3b8;

  /* Sizing */
  --sidebar-w: 260px;
  --sidebar-collapsed: 72px;
  --header-h: 64px;
  --radius: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 12px rgba(0,0,0,0.06), 0 2px 4px rgba(0,0,0,0.04);
  --shadow-lg: 0 10px 30px rgba(0,0,0,0.08), 0 4px 10px rgba(0,0,0,0.04);
  --shadow-xl: 0 20px 50px rgba(0,0,0,0.10);

  /* Transitions */
  --ease: cubic-bezier(0.4, 0, 0.2, 1);
  --duration: 0.2s;
}

/* ========== RESET & BASE ========== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--c-text);
  background: var(--c-bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: var(--c-forest); text-decoration: none; }
a:hover { color: var(--c-forest-light); }

/* ========== LAYOUT SHELL ========== */
.app-shell {
  display: flex;
  min-height: 100vh;
}

/* ========== SIDEBAR ========== */
.sidebar {
  width: var(--sidebar-w);
  background: var(--c-sidebar);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 100;
  overflow-y: auto;
  overflow-x: hidden;
  transition: transform var(--duration) var(--ease);
}

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

.sidebar-brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.sidebar-brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--c-gold) 0%, var(--c-gold-light) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 20px;
  color: var(--c-forest-deep);
  flex-shrink: 0;
}

.sidebar-brand-text {
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.3px;
  line-height: 1.2;
}

.sidebar-brand-sub {
  color: rgba(255,255,255,0.45);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.4px;
  margin-top: 2px;
}

/* Sidebar navigation */
.sidebar-nav {
  flex: 1;
  padding: 12px 10px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.sidebar-section {
  margin-top: 16px;
  margin-bottom: 4px;
  padding: 0 12px;
}

.sidebar-section-title {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.30);
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: 10px;
  color: rgba(255,255,255,0.65);
  font-size: 13.5px;
  font-weight: 500;
  transition: all var(--duration) var(--ease);
  position: relative;
}

.sidebar-link:hover {
  background: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.95);
}

.sidebar-link.active {
  background: rgba(201,153,58,0.15);
  color: var(--c-gold-light);
}

.sidebar-link.active::before {
  content: '';
  position: absolute;
  left: 0;
  top: 6px;
  bottom: 6px;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: var(--c-gold);
}

.sidebar-icon {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
  opacity: 0.85;
}

.sidebar-badge {
  margin-left: auto;
  background: rgba(239,68,68,0.9);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 10px;
  min-width: 20px;
  text-align: center;
}

/* Sidebar footer / user area */
.sidebar-user {
  padding: 14px 16px;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  align-items: center;
  gap: 12px;
}

.sidebar-avatar {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--c-gold), var(--c-gold-light));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  color: var(--c-forest-deep);
  flex-shrink: 0;
}

.sidebar-user-info {
  flex: 1;
  min-width: 0;
}

.sidebar-user-name {
  color: rgba(255,255,255,0.9);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-user-role {
  color: rgba(255,255,255,0.40);
  font-size: 11px;
  text-transform: capitalize;
}

.sidebar-logout {
  background: none;
  border: 1px solid rgba(255,255,255,0.15);
  color: rgba(255,255,255,0.5);
  padding: 6px 8px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 12px;
  transition: all var(--duration) var(--ease);
}

.sidebar-logout:hover {
  background: rgba(255,255,255,0.08);
  color: rgba(255,255,255,0.8);
  border-color: rgba(255,255,255,0.25);
}

/* ========== MAIN CONTENT ========== */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-w);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ========== TOP HEADER BAR ========== */
.top-header {
  height: var(--header-h);
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--c-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  position: sticky;
  top: 0;
  z-index: 50;
}

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

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: var(--c-text);
  padding: 4px;
}

.page-title {
  font-family: 'Playfair Display', serif;
  font-size: 20px;
  font-weight: 700;
  color: var(--c-ink);
  letter-spacing: -0.01em;
}

.page-breadcrumb {
  font-size: 12px;
  color: var(--c-text-light);
}

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

.header-btn {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid var(--c-border);
  background: var(--c-card);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 16px;
  color: var(--c-text-light);
  transition: all var(--duration) var(--ease);
  position: relative;
}

.header-btn:hover {
  background: var(--c-sand-light);
  border-color: var(--c-border-strong);
  color: var(--c-text);
}

.header-btn .notif-dot {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #ef4444;
  border: 2px solid var(--c-card);
}

/* ========== PAGE CONTENT ========== */
.page-content {
  flex: 1;
  padding: 24px 28px 40px;
}

/* ========== CARDS ========== */
.card {
  background: var(--c-card);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--duration) var(--ease);
}

.card:hover {
  box-shadow: var(--shadow-md);
}

.card-body {
  padding: 20px;
}

.card-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--c-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--c-ink);
}

.card-subtitle {
  font-size: 12px;
  color: var(--c-text-light);
  margin-top: 2px;
}

/* ========== KPI CARDS ========== */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.kpi-card {
  background: var(--c-card);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  padding: 20px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s var(--ease);
}

.kpi-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.kpi-card::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 80px;
  height: 80px;
  border-radius: 0 var(--radius-lg) 0 80px;
  opacity: 0.08;
}

.kpi-card.kpi-green::after { background: var(--c-forest); }
.kpi-card.kpi-gold::after { background: var(--c-gold); }
.kpi-card.kpi-blue::after { background: #3b82f6; }
.kpi-card.kpi-purple::after { background: #8b5cf6; }

.kpi-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  margin-bottom: 14px;
}

.kpi-green .kpi-icon { background: rgba(10,61,42,0.08); color: var(--c-forest); }
.kpi-gold .kpi-icon { background: var(--c-gold-muted); color: var(--c-gold); }
.kpi-blue .kpi-icon { background: rgba(59,130,246,0.08); color: #3b82f6; }
.kpi-purple .kpi-icon { background: rgba(139,92,246,0.08); color: #8b5cf6; }

.kpi-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--c-text-light);
  margin-bottom: 4px;
}

.kpi-value {
  font-size: 28px;
  font-weight: 700;
  color: var(--c-ink);
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.kpi-meta {
  font-size: 12px;
  color: var(--c-text-xlight);
  margin-top: 6px;
}

.kpi-trend {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  margin-top: 8px;
}

.kpi-trend.up { background: rgba(16,185,129,0.08); color: #059669; }
.kpi-trend.down { background: rgba(239,68,68,0.08); color: #ef4444; }

/* ========== STATUS BADGES ========== */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.status-badge::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
}

.status-inquiry { background: rgba(99,102,241,0.08); color: #4f46e5; }
.status-inquiry::before { background: #6366f1; }
.status-confirmed { background: rgba(14,165,233,0.08); color: #0284c7; }
.status-confirmed::before { background: #0ea5e9; }
.status-deposit { background: rgba(245,158,11,0.08); color: #d97706; }
.status-deposit::before { background: #f59e0b; }
.status-paid { background: rgba(16,185,129,0.08); color: #059669; }
.status-paid::before { background: #10b981; }
.status-ongoing { background: rgba(139,92,246,0.08); color: #7c3aed; }
.status-ongoing::before { background: #8b5cf6; }
.status-completed { background: rgba(5,150,105,0.08); color: #047857; }
.status-completed::before { background: #059669; }
.status-cancelled { background: rgba(239,68,68,0.08); color: #dc2626; }
.status-cancelled::before { background: #ef4444; }
.status-default { background: rgba(148,163,184,0.08); color: #64748b; }
.status-default::before { background: #94a3b8; }

/* ========== BUTTONS ========== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 600;
  font-family: inherit;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--duration) var(--ease);
  white-space: nowrap;
  line-height: 1.4;
}

.btn-primary {
  background: linear-gradient(135deg, var(--c-forest) 0%, var(--c-forest-light) 100%);
  color: #fff;
  border-color: var(--c-forest);
  box-shadow: 0 2px 6px rgba(10,61,42,0.2);
}

.btn-primary:hover {
  background: linear-gradient(135deg, var(--c-forest-light) 0%, var(--c-forest) 100%);
  box-shadow: 0 4px 12px rgba(10,61,42,0.3);
  transform: translateY(-1px);
  color: #fff;
}

.btn-gold {
  background: linear-gradient(135deg, var(--c-gold) 0%, #d4a843 100%);
  color: var(--c-forest-deep);
  font-weight: 700;
  box-shadow: 0 2px 6px rgba(201,153,58,0.25);
}

.btn-gold:hover {
  box-shadow: 0 4px 12px rgba(201,153,58,0.35);
  transform: translateY(-1px);
}

.btn-outline {
  background: var(--c-card);
  border-color: var(--c-border-strong);
  color: var(--c-text);
}

.btn-outline:hover {
  background: var(--c-sand-light);
  border-color: var(--c-text-xlight);
}

.btn-ghost {
  background: transparent;
  color: var(--c-text-light);
  border: none;
  padding: 6px 10px;
}

.btn-ghost:hover {
  background: rgba(0,0,0,0.04);
  color: var(--c-text);
}

.btn-danger {
  background: #fef2f2;
  color: #dc2626;
  border-color: rgba(239,68,68,0.2);
}

.btn-danger:hover {
  background: #fee2e2;
  border-color: rgba(239,68,68,0.35);
}

.btn-sm {
  padding: 6px 12px;
  font-size: 12px;
  border-radius: 8px;
}

.btn-xs {
  padding: 4px 8px;
  font-size: 11px;
  border-radius: 6px;
}

/* ========== FORMS ========== */
.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--c-text-light);
  letter-spacing: 0.02em;
  margin-bottom: 6px;
}

.form-control,
.form-select {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--c-border-strong);
  border-radius: var(--radius);
  font-family: inherit;
  font-size: 14px;
  color: var(--c-text);
  background: var(--c-card);
  transition: all var(--duration) var(--ease);
  outline: none;
}

.form-control:focus,
.form-select:focus {
  border-color: var(--c-forest);
  box-shadow: 0 0 0 3px rgba(10,61,42,0.08);
}

.form-control::placeholder {
  color: var(--c-text-xlight);
}

.form-control-sm,
.form-select-sm {
  padding: 8px 12px;
  font-size: 13px;
}

textarea.form-control {
  min-height: 80px;
  resize: vertical;
}

.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

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

/* ========== TABLES ========== */
.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
}

table.data-table {
  width: 100%;
  border-collapse: collapse;
}

.data-table thead th {
  padding: 12px 14px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-text-light);
  background: var(--c-sand-light);
  border-bottom: 1px solid var(--c-border);
  text-align: left;
  white-space: nowrap;
}

.data-table tbody td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--c-border);
  font-size: 13.5px;
  vertical-align: middle;
}

.data-table tbody tr {
  transition: background var(--duration) var(--ease);
}

.data-table tbody tr:hover {
  background: rgba(201,153,58,0.04);
}

.data-table tbody tr:last-child td {
  border-bottom: none;
}

.text-right { text-align: right; }
.text-center { text-align: center; }
.text-muted { color: var(--c-text-light); }
.text-xs { font-size: 11px; }
.text-sm { font-size: 12px; }
.text-mono { font-family: 'SF Mono', 'Fira Code', monospace; }
.font-bold { font-weight: 700; }
.text-forest { color: var(--c-forest); }
.text-gold { color: var(--c-gold); }
.text-danger { color: #dc2626; }
.text-success { color: #059669; }

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 8px; }
.gap-2 { gap: 12px; }
.gap-3 { gap: 16px; }
.flex-wrap { flex-wrap: wrap; }
.flex-1 { flex: 1; }

.grid { display: grid; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* ========== ALERTS ========== */
.alert {
  padding: 14px 18px;
  border-radius: var(--radius);
  font-size: 13.5px;
  font-weight: 500;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 20px;
  animation: alertIn 0.3s var(--ease);
}

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

.alert-success {
  background: rgba(16,185,129,0.06);
  border: 1px solid rgba(16,185,129,0.18);
  color: #065f46;
}

.alert-danger,
.alert-error {
  background: rgba(239,68,68,0.06);
  border: 1px solid rgba(239,68,68,0.18);
  color: #991b1b;
}

.alert-warning {
  background: rgba(245,158,11,0.06);
  border: 1px solid rgba(245,158,11,0.18);
  color: #92400e;
}

.alert-info {
  background: rgba(59,130,246,0.06);
  border: 1px solid rgba(59,130,246,0.18);
  color: #1e40af;
}

/* ========== EMPTY STATES ========== */
.empty-state {
  text-align: center;
  padding: 48px 24px;
  color: var(--c-text-light);
}

.empty-state-icon {
  font-size: 48px;
  margin-bottom: 16px;
  opacity: 0.3;
}

.empty-state-title {
  font-size: 16px;
  font-weight: 600;
  color: var(--c-text);
  margin-bottom: 6px;
}

.empty-state-text {
  font-size: 13px;
  max-width: 360px;
  margin: 0 auto;
}

/* ========== FINANCE CARDS ========== */
.finance-grid {
  display: grid;
  gap: 12px;
}

.finance-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  background: var(--c-card);
}

.finance-row.net {
  border-color: rgba(10,61,42,0.2);
  background: rgba(10,61,42,0.03);
}

.finance-label {
  font-size: 13px;
  color: var(--c-text-light);
}

.finance-value {
  font-size: 16px;
  font-weight: 700;
  color: var(--c-ink);
  font-variant-numeric: tabular-nums;
}

/* ========== DASHBOARD SPECIFIC ========== */
.dash-grid {
  display: grid;
  grid-template-columns: 1fr 1.8fr;
  gap: 20px;
}

.activity-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--c-border);
}

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

.activity-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--c-gold);
  margin-top: 6px;
  flex-shrink: 0;
}

.activity-text {
  font-size: 13px;
  color: var(--c-text);
  line-height: 1.5;
}

.activity-time {
  font-size: 11px;
  color: var(--c-text-xlight);
  margin-top: 2px;
}

/* ========== QUICK ACTIONS ========== */
.quick-actions {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
}

.quick-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px 10px;
  border-radius: var(--radius);
  border: 1px solid var(--c-border);
  background: var(--c-card);
  cursor: pointer;
  transition: all 0.2s var(--ease);
  text-decoration: none;
  color: var(--c-text);
}

.quick-action:hover {
  background: var(--c-sand-light);
  border-color: var(--c-gold);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  color: var(--c-text);
}

.quick-action-icon {
  font-size: 24px;
}

.quick-action-label {
  font-size: 12px;
  font-weight: 600;
  text-align: center;
}

/* ========== FILTER PANEL ========== */
.filter-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.filter-bar .form-control,
.filter-bar .form-select {
  width: auto;
  min-width: 160px;
}

.filter-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 20px;
  background: var(--c-gold-muted);
  color: var(--c-gold);
  font-size: 12px;
  font-weight: 600;
}

/* ========== FOOTER ========== */
.app-footer {
  padding: 16px 28px;
  border-top: 1px solid var(--c-border);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 12px;
  color: var(--c-text-xlight);
}

/* ============================================================
   AUTH / LOGIN PAGE
   ============================================================ */
body.auth-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background:
    radial-gradient(ellipse 1000px 600px at 15% 20%, rgba(10,61,42,0.12), transparent 60%),
    radial-gradient(ellipse 800px 500px at 85% 80%, rgba(201,153,58,0.10), transparent 55%),
    var(--c-bg);
}

.auth-container {
  width: min(980px, 100%);
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  background: var(--c-card);
}

.auth-hero {
  background: var(--c-sidebar);
  padding: 40px 36px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  overflow: hidden;
}

.auth-hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -30%;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(201,153,58,0.15), transparent 70%);
}

.auth-hero::after {
  content: '';
  position: absolute;
  bottom: -30%;
  left: -20%;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.05), transparent 70%);
}

.auth-hero > * { position: relative; z-index: 1; }

.auth-hero-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 32px;
}

.auth-hero-mark {
  width: 50px;
  height: 50px;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--c-gold), var(--c-gold-light));
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 26px;
  color: var(--c-forest-deep);
}

.auth-hero-title {
  color: #fff;
  font-size: 18px;
  font-weight: 700;
}

.auth-hero-sub {
  color: rgba(255,255,255,0.45);
  font-size: 12px;
  margin-top: 2px;
}

.auth-hero h2 {
  font-family: 'Playfair Display', serif;
  color: #fff;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 10px;
}

.auth-hero p {
  color: rgba(255,255,255,0.55);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 28px;
}

.auth-features {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.auth-feature {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.auth-feature-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(201,153,58,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
}

.auth-feature-text {
  font-size: 13px;
  color: rgba(255,255,255,0.7);
  line-height: 1.5;
}

.auth-feature-text strong {
  color: rgba(255,255,255,0.92);
  display: block;
  margin-bottom: 2px;
}

/* Auth form side */
.auth-form-side {
  padding: 44px 36px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.auth-form-title {
  font-family: 'Playfair Display', serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--c-ink);
  margin-bottom: 6px;
}

.auth-form-sub {
  font-size: 13px;
  color: var(--c-text-light);
  margin-bottom: 28px;
}

.auth-form .form-group {
  margin-bottom: 18px;
}

.auth-form .form-label {
  font-size: 13px;
  color: var(--c-text);
  font-weight: 600;
}

.auth-form .form-control {
  padding: 12px 16px;
  border-radius: var(--radius);
  font-size: 14px;
}

.auth-submit {
  width: 100%;
  padding: 13px 20px;
  border: none;
  border-radius: var(--radius);
  background: linear-gradient(135deg, var(--c-forest) 0%, var(--c-forest-light) 100%);
  color: #fff;
  font-size: 15px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.25s var(--ease);
  box-shadow: 0 4px 12px rgba(10,61,42,0.25);
  letter-spacing: 0.3px;
}

.auth-submit:hover {
  box-shadow: 0 6px 20px rgba(10,61,42,0.35);
  transform: translateY(-1px);
}

.auth-footer-text {
  margin-top: 24px;
  font-size: 12px;
  color: var(--c-text-xlight);
  text-align: center;
  line-height: 1.6;
}

.auth-flash {
  padding: 12px 16px;
  border-radius: var(--radius);
  margin-bottom: 20px;
  font-size: 13px;
  font-weight: 500;
}

.auth-flash.error {
  background: rgba(239,68,68,0.06);
  border: 1px solid rgba(239,68,68,0.18);
  color: #991b1b;
}

.auth-flash.success {
  background: rgba(16,185,129,0.06);
  border: 1px solid rgba(16,185,129,0.18);
  color: #065f46;
}

/* ========== NOTIFICATION DROPDOWN ========== */
.notif-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 360px;
  background: var(--c-card);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  z-index: 200;
  display: none;
}

.notif-dropdown.open { display: block; }

.notif-header {
  padding: 14px 16px;
  border-bottom: 1px solid var(--c-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.notif-list {
  max-height: 340px;
  overflow-y: auto;
}

.notif-item {
  padding: 12px 16px;
  border-bottom: 1px solid var(--c-border);
  display: flex;
  gap: 10px;
  transition: background var(--duration) var(--ease);
}

.notif-item:hover { background: var(--c-sand-light); }
.notif-item.unread { background: rgba(201,153,58,0.04); }

.notif-icon-wrap {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  flex-shrink: 0;
}

/* ========== MOBILE RESPONSIVE ========== */
.mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 90;
}

@media (max-width: 992px) {
  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .mobile-overlay.open {
    display: block;
  }

  .mobile-toggle {
    display: block;
  }

  .main-content {
    margin-left: 0;
  }

  .dash-grid {
    grid-template-columns: 1fr;
  }

  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .auth-container {
    grid-template-columns: 1fr;
  }

  .auth-hero {
    padding: 28px 24px;
  }

  .auth-hero h2 { font-size: 22px; }

  .page-content {
    padding: 16px 16px 32px;
  }

  .top-header {
    padding: 0 16px;
  }
}

@media (max-width: 600px) {
  .kpi-grid {
    grid-template-columns: 1fr;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .quick-actions {
    grid-template-columns: repeat(2, 1fr);
  }

  .auth-form-side {
    padding: 28px 20px;
  }
}

/* ========== SCROLLBAR ========== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(0,0,0,0.12); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: rgba(0,0,0,0.2); }

/* ========== ANIMATIONS ========== */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.fade-in { animation: fadeIn 0.4s var(--ease) forwards; }
.fade-in-d1 { animation-delay: 0.05s; opacity: 0; }
.fade-in-d2 { animation-delay: 0.10s; opacity: 0; }
.fade-in-d3 { animation-delay: 0.15s; opacity: 0; }
.fade-in-d4 { animation-delay: 0.20s; opacity: 0; }

/* ========== PRINT ========== */
@media print {
  .sidebar, .top-header, .mobile-overlay { display: none !important; }
  .main-content { margin-left: 0 !important; }
  .page-content { padding: 0 !important; }
  .card { box-shadow: none !important; border: 1px solid #ddd !important; }
}
