/* ═══════════════════════════════════════════════════════════
   Consulere Rooster – Finance & Consulting brand
   ═══════════════════════════════════════════════════════════ */

:root {
  --primary: #E6B325;
  --primary-hover: #C99A1F;
  --primary-secondary: #F0C84A;
  --primary-light: #FEF9E7;
  --primary-rgb: 230, 179, 37;
  --primary-gradient: linear-gradient(135deg, #E6B325 0%, #F0C84A 100%);
  --sidebar-bg: #0a0a0a;
  --sidebar-text: #e5e5e5;
  --sidebar-muted: #999999;
  --success: #10b981;
  --success-light: #ecfdf5;
  --teal: #0ea5e9;
  --teal-light: #e0f2fe;
  --gray: #64748b;
  --gray-light: #94a3b8;
  --text: #2a3547;
  --text-muted: #5a6a85;
  --bg: #f0f4f9;
  --surface: #ffffff;
  --border: #e5eaef;
  --sidebar-width: 270px;
  --header-height: 70px;
  --radius: 12px;
  --radius-lg: 18px;
  --radius-xl: 22px;
  --shadow-card: 0 2px 12px rgba(42, 53, 71, 0.06);
  --shadow-hover: 0 8px 28px rgba(42, 53, 71, 0.1);
  --transition: 0.22s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
  transition: background-color var(--transition), color var(--transition);
}

[data-theme="dark"] {
  --primary-light: rgba(230, 179, 37, 0.15);
  --text: #f1f5f9;
  --text-muted: #94a3b8;
  --bg: #1a1f36;
  --surface: #232a45;
  --border: #334155;
  --shadow-card: 0 2px 12px rgba(0, 0, 0, 0.25);
  --shadow-hover: 0 8px 28px rgba(0, 0, 0, 0.35);
}

[data-theme="dark"] body {
  background: var(--bg);
  color: var(--text);
}

[data-theme="dark"] .sidebar-link:hover {
  background: rgba(255, 255, 255, 0.05);
}

[data-theme="dark"] .form-saas {
  background: rgba(255, 255, 255, 0.03);
}

[data-theme="dark"] .table-saas thead th {
  background: rgba(255, 255, 255, 0.04);
}

[data-theme="dark"] .hero-card,
[data-theme="dark"] .card-saas,
[data-theme="dark"] .stat-card-v2 {
  background: var(--surface);
  border-color: var(--border);
}

[data-theme="dark"] .text-muted {
  color: var(--text-muted) !important;
}

*, *::before, *::after { box-sizing: border-box; }

body {
  font-family: "Inter", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  margin: 0;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  transition: background-color var(--transition), color var(--transition);
}

.sidebar,
.top-header,
.card-saas,
.stat-card-v2,
.mobile-bottom-nav {
  transition: background-color var(--transition), border-color var(--transition), color var(--transition);
}

html { scroll-behavior: smooth; }

/* ── App shell ── */
.app-layout {
  display: flex;
  min-height: 100vh;
}

.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  z-index: 1040;
  backdrop-filter: blur(2px);
}

.sidebar-overlay.show { display: block; }

/* ── Sidebar ── */
.sidebar {
  width: var(--sidebar-width);
  background: var(--sidebar-bg);
  border-right: 1px solid #1a1a1a;
  color: var(--sidebar-text);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  z-index: 1050;
  transition: transform var(--transition);
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1.375rem 1.25rem 1rem;
  text-decoration: none;
}

.sidebar-brand-icon {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
  background: transparent;
}

.sidebar-brand-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.sidebar-brand-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: #ffffff;
  letter-spacing: 0.06em;
  line-height: 1.2;
  text-transform: uppercase;
}

.sidebar-brand-sub {
  font-size: 0.68rem;
  color: var(--sidebar-muted);
  font-weight: 500;
}

.sidebar-section-label {
  color: var(--sidebar-muted);
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gray-light);
  padding: 0.75rem 1.5rem 0.5rem;
}

.sidebar-nav {
  flex: 1;
  padding: 0.25rem 0.875rem;
  overflow-y: auto;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 1rem;
  margin-bottom: 4px;
  border-radius: 10px;
  color: var(--sidebar-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all var(--transition);
}

.sidebar-link i {
  width: 20px;
  text-align: center;
  font-size: 1rem;
  color: var(--sidebar-muted);
}

.sidebar-link:hover {
  background: rgba(230, 179, 37, 0.12);
  color: var(--sidebar-text);
}

.sidebar-link:hover i {
  color: var(--primary);
}

.sidebar-link.active {
  background: rgba(230, 179, 37, 0.18);
  color: var(--primary);
  box-shadow: none;
}

.sidebar-link.active i { color: var(--primary); }

.sidebar-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.125rem;
  height: 1.125rem;
  padding: 0 0.35rem;
  margin-left: 0.25rem;
  border-radius: 999px;
  background: #fff;
  color: var(--primary);
  font-size: 0.625rem;
  font-weight: 700;
  line-height: 1;
}

.sidebar-link.active .sidebar-badge {
  background: rgba(255,255,255,0.25);
  color: #fff;
}

.sidebar-link-muted { color: var(--sidebar-muted); }
.sidebar-link-muted:hover { color: var(--primary); background: rgba(230, 179, 37, 0.12); }

.sidebar-footer {
  padding: 1rem 0.875rem 1.25rem;
  border-top: 1px solid #222222;
}

/* ── Main panel ── */
.main-panel {
  flex: 1;
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.top-header {
  height: var(--header-height);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 0 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  position: sticky;
  top: 0;
  z-index: 1020;
}

.sidebar-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

.header-search {
  flex: 1;
  max-width: 280px;
  position: relative;
}

.header-search i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--gray-light);
  font-size: 0.85rem;
}

.header-search input {
  width: 100%;
  padding: 0.55rem 0.875rem 0.55rem 2.5rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #f6f9fc;
  font-size: 0.875rem;
  color: var(--text);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-left: auto;
}

.header-date {
  font-size: 0.8125rem;
  color: var(--gray);
  padding-right: 0.5rem;
  border-right: 1px solid var(--border);
}

.header-date i { margin-right: 0.35rem; color: var(--gray-light); }

.header-icon-btn {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-muted);
  cursor: pointer;
  position: relative;
  transition: all var(--transition);
}

.header-icon-btn:hover {
  background: var(--primary-light);
  border-color: rgba(var(--primary-rgb), 0.2);
  color: var(--primary);
}

.header-user {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.25rem 0.5rem 0.25rem 0.25rem;
  border-radius: 99px;
  border: 1px solid var(--border);
  background: #f6f9fc;
}

.header-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary-gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.85rem;
}

.header-avatar-manager {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  box-shadow: 0 0 0 2px #fef3c7;
}

.header-user-name {
  font-size: 0.8125rem;
  font-weight: 600;
  line-height: 1.2;
}

.header-user-role {
  font-size: 0.6875rem;
  color: var(--gray-light);
}

.page-content {
  padding: 1.5rem 1.75rem 2.5rem;
  flex: 1;
}

.page-enter {
  animation: pageEnter 0.4s ease forwards;
}

@keyframes pageEnter {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* Modals boven sidebar (1050) */
.modal-backdrop { z-index: 1055 !important; }
.modal { z-index: 1060 !important; }

/* ── Hero welcome card ── */
.hero-card {
  background: var(--primary-gradient);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(var(--primary-rgb), 0.28);
  position: relative;
}

.hero-card::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(255,255,255,0.12) 0%, transparent 70%);
  pointer-events: none;
}

.hero-card-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2rem 2.25rem;
  gap: 1.5rem;
  position: relative;
}

.hero-eyebrow {
  font-size: 0.8125rem;
  color: rgba(255,255,255,0.75);
  margin: 0 0 0.5rem;
  font-weight: 500;
}

.hero-title {
  font-size: 1.75rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 0.5rem;
  letter-spacing: -0.03em;
}

.hero-sub {
  color: rgba(255,255,255,0.85);
  font-size: 0.9375rem;
  margin: 0 0 1.25rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
}

.btn-hero-light {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1rem;
  background: #fff;
  color: var(--primary);
  border-radius: 10px;
  font-size: 0.8125rem;
  font-weight: 600;
  text-decoration: none;
  transition: all var(--transition);
}

.btn-hero-light:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.15);
  color: var(--primary-hover);
}

.btn-hero-ghost {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.5rem 1rem;
  background: rgba(255,255,255,0.15);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 10px;
  font-size: 0.8125rem;
  font-weight: 500;
  text-decoration: none;
  transition: all var(--transition);
}

.btn-hero-ghost:hover {
  background: rgba(255,255,255,0.25);
  color: #fff;
}

.hero-visual {
  flex-shrink: 0;
}

.hero-icon-ring {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: rgba(255,255,255,0.15);
  border: 2px dashed rgba(255,255,255,0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  color: rgba(255,255,255,0.9);
  animation: float 4s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-8px); }
}

/* ── Stat cards v2 ── */
.stat-card-v2 {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 1.375rem 1.5rem;
  box-shadow: var(--shadow-card);
  border: 1px solid transparent;
  height: 100%;
  transition: all 0.25s ease;
}

.stat-card-v2:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-3px);
  border-color: var(--border);
}

.stat-card-v2-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 1rem;
}

.stat-card-v2-label {
  font-size: 0.8125rem;
  color: var(--text-muted);
  font-weight: 500;
  margin-bottom: 0.375rem;
}

.stat-card-v2-value {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.04em;
  color: var(--text);
  line-height: 1;
}

.stat-card-v2-value small {
  font-size: 1rem;
  font-weight: 500;
  color: var(--gray-light);
  margin-left: 2px;
}

.stat-card-v2-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
}

.stat-card-v2-icon.primary { background: var(--primary-light); color: var(--primary); }
.stat-card-v2-icon.success { background: var(--success-light); color: var(--success); }
.stat-card-v2-icon.amber   { background: #fffbeb; color: #f59e0b; }
.stat-card-v2-icon.teal    { background: var(--teal-light); color: var(--teal); }

.stat-card-v2-foot {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.stat-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
  height: 100%;
}

.stat-card-clickable {
  cursor: pointer;
  position: relative;
}

.stat-card-clickable:hover {
  border-color: rgba(var(--primary-rgb), 0.25);
}

.stat-card-clickable:hover .stat-card-go {
  opacity: 1;
  transform: translateX(3px);
  color: var(--primary);
}

.stat-card-go {
  color: var(--gray-light);
  font-size: 0.875rem;
  opacity: 0;
  transition: all 0.2s ease;
}

@media (hover: none) {
  .stat-card-go { opacity: 0.55; }
}

.time-input,
.date-input {
  cursor: text;
  font-variant-numeric: tabular-nums;
}

.stat-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--gray);
  background: #f6f9fc;
  padding: 0.3em 0.65em;
  border-radius: 99px;
}

.stat-chip.success {
  background: var(--success-light);
  color: #059669;
}

/* ── Page headers (subpages) ── */
.welcome-header h1 {
  font-size: 1.625rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  margin: 0 0 0.25rem;
  color: var(--text);
}

.welcome-header p {
  color: var(--text-muted);
  font-size: 0.9375rem;
  margin: 0 0 1.5rem;
}

/* ── Cards ── */
.card-saas {
  background: var(--surface);
  border: none;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: box-shadow 0.25s ease;
}

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

.card-saas-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #f0f4f9;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.card-saas-header h2 {
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--text);
}

.card-saas-header h2 .icon-accent {
  color: var(--primary);
  font-size: 0.9rem;
}

.card-saas-body { padding: 0; }

/* ── Pulsing dot ── */
.pulse-dot {
  width: 8px;
  height: 8px;
  background: var(--success);
  border-radius: 50%;
  display: inline-block;
  position: relative;
  flex-shrink: 0;
}

.pulse-dot::before {
  content: "";
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  background: var(--success);
  opacity: 0.4;
  animation: pulse 2s ease infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 0.4; }
  50%       { transform: scale(1.8); opacity: 0; }
}

/* ── Tables ── */
.table-saas {
  width: 100%;
  margin: 0;
  font-size: 0.875rem;
  border-collapse: collapse;
}

.table-saas thead th {
  background: #f6f9fc;
  color: var(--gray);
  font-weight: 600;
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.875rem 1.5rem;
  border-bottom: 1px solid var(--border);
}

.table-saas tbody td {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #f0f4f9;
  vertical-align: middle;
}

.table-saas tbody tr:last-child td { border-bottom: none; }
.table-saas tbody tr { transition: background 0.15s; }
.table-saas tbody tr:hover { background: #fafcff; }

.table-row-highlight {
  background: rgba(192, 57, 43, 0.06) !important;
}

[data-theme="dark"] .table-row-highlight {
  background: rgba(192, 57, 43, 0.12) !important;
}

.employee-cell {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.employee-avatar {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  background: var(--primary-light);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.8125rem;
}

/* ── Badges ── */
.badge-status {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.35em 0.75em;
  border-radius: 99px;
}

.badge-aanwezig { background: var(--success-light); color: #059669; }
.badge-afwezig  { background: #f0f4f9; color: var(--gray); }
.badge-loc-ok   { background: var(--success-light); color: #059669; }
.badge-loc-fail { background: #fef2f2; color: #dc2626; }
.badge-accent   { background: var(--primary-light); color: var(--primary); }
.badge-status.success { background: var(--success-light); color: #059669; }
.badge-status.warning { background: #fff7ed; color: #ea580c; }
.badge-status.danger  { background: #fef2f2; color: #dc2626; }

/* ── Activity feed ── */
.activity-feed { list-style: none; margin: 0; padding: 0.5rem 0; }

.activity-item {
  display: flex;
  gap: 0.875rem;
  padding: 0.875rem 1.5rem;
  border-bottom: 1px solid #f0f4f9;
  transition: background 0.15s;
}

.activity-item:last-child { border-bottom: none; }
.activity-item:hover { background: #fafcff; }

.activity-icon {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  flex-shrink: 0;
}

.activity-icon.success { background: var(--success-light); color: var(--success); }
.activity-icon.indigo  { background: var(--primary-light); color: var(--primary); }
.activity-icon.gray    { background: #f0f4f9; color: var(--gray); }

.activity-title { font-size: 0.8125rem; font-weight: 600; margin-bottom: 0.125rem; }
.activity-meta  { font-size: 0.75rem; color: var(--gray); }

/* ── Buttons ── */
.btn-primary-saas {
  background: var(--primary);
  border: none;
  color: #fff;
  font-weight: 600;
  font-size: 0.875rem;
  padding: 0.5625rem 1.125rem;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
}

.btn-primary-saas:hover {
  background: var(--primary-hover);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(var(--primary-rgb), 0.35);
}

.btn-secondary-saas {
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text);
  font-weight: 500;
  font-size: 0.875rem;
  padding: 0.5625rem 1.125rem;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
}

.btn-secondary-saas:hover {
  background: #f6f9fc;
  border-color: #cbd5e1;
  transform: translateY(-1px);
  box-shadow: var(--shadow-card);
  color: var(--text);
}

.btn-icon-saas {
  width: 36px;
  height: 36px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--gray);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-icon-saas:hover {
  background: var(--primary-light);
  border-color: rgba(var(--primary-rgb), 0.25);
  color: var(--primary);
}

.btn-icon-saas.danger:hover {
  background: #fef2f2;
  border-color: #fecaca;
  color: #dc2626;
}

/* ── Empty states ── */
.empty-state { padding: 3rem 2rem; text-align: center; }

.empty-illustration {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.25rem;
  background: linear-gradient(135deg, var(--primary-light), #fde8e8);
  border-radius: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  color: var(--primary);
}

.empty-state h3 { font-size: 1rem; font-weight: 600; margin: 0 0 0.375rem; }
.empty-state p  { color: var(--gray); font-size: 0.875rem; margin: 0; }

/* ── Progress bars ── */
.hours-row {
  padding: 1rem 1.5rem;
  border-bottom: 1px solid #f0f4f9;
  transition: background 0.15s;
}

.hours-row:last-child { border-bottom: none; }
.hours-row:hover { background: #fafcff; }

.hours-row-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.625rem;
}

.hours-row-name  { font-weight: 600; font-size: 0.875rem; }
.hours-row-value { font-weight: 700; color: var(--primary); font-size: 0.875rem; }

.progress-saas {
  height: 10px;
  background: #eef2f7;
  border-radius: 99px;
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.06);
}

.progress-saas-bar {
  height: 100%;
  min-width: 0;
  background: var(--primary-gradient);
  border-radius: 99px;
  transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 0.35rem;
}

.progress-saas-bar span {
  font-size: 0.625rem;
  font-weight: 700;
  color: #fff;
  line-height: 1;
  white-space: nowrap;
}

.progress-saas-bar.is-high {
  background: linear-gradient(90deg, #34d399 0%, #10b981 100%);
}

.progress-saas-bar.is-complete {
  background: linear-gradient(90deg, #059669 0%, #047857 100%);
}

.chart-week-sub {
  margin: 0.25rem 0 0;
  font-size: 0.8125rem;
  color: var(--gray);
  font-weight: 500;
}

.week-hours-chart {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 0.75rem;
  padding: 1.25rem 1.5rem 1.5rem;
  min-height: 220px;
  align-items: end;
}

.week-hours-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
}

.week-hours-value {
  font-size: 0.75rem;
  font-weight: 700;
  color: #64748b;
  font-variant-numeric: tabular-nums;
}

.week-hours-track {
  width: 100%;
  max-width: 52px;
  height: 140px;
  background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
  border-radius: 14px;
  display: flex;
  align-items: flex-end;
  padding: 6px;
  box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.05);
}

.week-hours-fill {
  width: 100%;
  min-height: 8px;
  border-radius: 10px;
  background: linear-gradient(180deg, rgba(230, 179, 37, 0.85) 0%, var(--primary) 100%);
  transition: height 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

.week-hours-col.is-today .week-hours-value {
  color: var(--primary);
}

.week-hours-col.is-today .week-hours-track {
  background: linear-gradient(180deg, #fffdf5 0%, var(--primary-light) 100%);
  box-shadow: inset 0 0 0 1px rgba(var(--primary-rgb), 0.12);
}

.week-hours-col.is-today .week-hours-fill {
  background: var(--primary-gradient);
  box-shadow: 0 4px 14px rgba(var(--primary-rgb), 0.28);
}

.week-hours-label {
  font-size: 0.75rem;
  font-weight: 600;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.week-hours-col.is-today .week-hours-label {
  color: #c0392b;
}

@media (max-width: 768px) {
  .week-hours-chart {
    gap: 0.375rem;
    padding: 1rem;
  }

  .week-hours-track {
    height: 110px;
    max-width: 100%;
  }

  .week-hours-value,
  .week-hours-label {
    font-size: 0.6875rem;
  }
}

/* ── Forms ── */
.form-saas {
  padding: 1.25rem 1.5rem;
  background: #f6f9fc;
  border-bottom: 1px solid #f0f4f9;
}

.form-saas .form-control {
  border-radius: 10px;
  border-color: var(--border);
  font-size: 0.875rem;
  padding: 0.5625rem 0.875rem;
}

.form-saas .form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1);
}

.form-saas .form-label {
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 0.375rem;
}

code.employee-code {
  background: var(--primary-light);
  color: var(--primary);
  padding: 0.25em 0.6em;
  border-radius: 8px;
  font-size: 0.8125rem;
  font-weight: 600;
}

.chart-container {
  position: relative;
  height: 280px;
  padding: 1rem 1.5rem 1.5rem;
}

.alert-saas { border-radius: var(--radius); font-size: 0.875rem; border: none; }

/* ── Login ── */
.login-page {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.login-panel-left {
  background: #0a0a0a;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-start;
  padding: 3rem;
  color: #fff;
  position: relative;
  overflow: hidden;
}

.login-panel-left::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.login-panel-icon {
  width: auto;
  height: auto;
  background: transparent;
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  font-size: 1.75rem;
  margin-bottom: 1.5rem;
  position: relative;
}

.login-panel-icon img {
  max-width: 280px;
  width: 100%;
  height: auto;
}

.login-panel-left h2 {
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  position: relative;
}

.login-panel-left p {
  font-size: 1rem;
  opacity: 0.85;
  max-width: 360px;
  position: relative;
  margin: 0;
}

.login-panel-right {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: var(--bg);
}

.login-card {
  background: var(--surface);
  border-radius: var(--radius-xl);
  padding: 2.5rem 2rem;
  width: 100%;
  max-width: 400px;
  box-shadow: var(--shadow-hover);
  text-align: center;
}

.login-logo {
  width: 52px;
  height: 52px;
  background: var(--primary-gradient);
  border-radius: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 1.25rem;
  margin: 0 auto 1rem;
  box-shadow: 0 8px 20px rgba(var(--primary-rgb), 0.3);
}

.login-brand {
  font-weight: 700;
  font-size: 1.375rem;
  letter-spacing: -0.03em;
  margin-bottom: 0.25rem;
}

.login-subtitle { color: var(--gray); font-size: 0.875rem; margin-bottom: 1.75rem; }

.login-card form { text-align: left; }

.login-card .form-control {
  border-radius: 10px;
  border-color: var(--border);
  padding: 0.6875rem 0.875rem;
}

.login-card .form-control:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1);
}

.login-divider {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin: 1.5rem 0;
  color: var(--gray-light);
  font-size: 0.75rem;
}

.login-divider::before,
.login-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* ── Responsive ── */
@media (max-width: 991.98px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open { transform: translateX(0); }
  .main-panel { margin-left: 0; }
  .sidebar-toggle { display: none; }
  .hero-visual { display: none; }
  .page-content {
    padding: 1.25rem 1rem calc(5rem + env(safe-area-inset-bottom, 0));
  }
}

@media (max-width: 767.98px) {
  .login-page { grid-template-columns: 1fr; }
  .login-panel-left { display: none; }
  .hero-title { font-size: 1.375rem; }
  .hero-card-body { padding: 1.5rem; }
}

@media (max-width: 575.98px) {
  .stat-card-v2-value { font-size: 1.625rem; }
  .table-saas thead th,
  .table-saas tbody td { padding: 0.75rem 1rem; }
  .btn-primary-saas,
  .btn-secondary-saas {
    min-height: 44px;
    touch-action: manipulation;
  }
  .btn-icon-saas {
    min-width: 44px;
    min-height: 44px;
  }
  .row.g-3 > [class*="col-"] {
    flex: 0 0 100%;
    max-width: 100%;
  }
}

/* ── Notifications dropdown ── */
.notif-wrap { position: relative; }

.notif-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  font-size: 0.625rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
}

.notif-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: min(360px, calc(100vw - 2rem));
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-hover);
  z-index: 1080;
  overflow: hidden;
}

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

.notif-dropdown-head {
  padding: 0.875rem 1rem;
  font-weight: 700;
  font-size: 0.875rem;
  border-bottom: 1px solid var(--border);
}

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

.notif-item {
  display: flex;
  gap: 0.75rem;
  width: 100%;
  padding: 0.875rem 1rem;
  border: none;
  border-bottom: 1px solid var(--border);
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: background var(--transition);
}

.notif-item:hover { background: rgba(192, 57, 43, 0.06); }

.notif-item.unread { background: var(--primary-light); }

.notif-item-icon {
  color: var(--primary);
  margin-top: 2px;
  flex-shrink: 0;
}

.notif-item-text {
  font-size: 0.8125rem;
  color: var(--text);
  line-height: 1.4;
}

.notif-item-time {
  font-size: 0.6875rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

.notif-empty {
  padding: 2rem 1rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.875rem;
}

/* ── Mobile bottom navigation ── */
.mobile-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 64px;
  background: var(--surface);
  border-top: 1px solid var(--border);
  display: flex;
  align-items: stretch;
  justify-content: space-around;
  z-index: 1045;
  padding-bottom: env(safe-area-inset-bottom, 0);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.06);
}

.mobile-nav-item {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.2rem;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.625rem;
  font-weight: 600;
  border: none;
  background: transparent;
  min-height: 44px;
  padding: 0.25rem;
  transition: color var(--transition);
}

.mobile-nav-item i { font-size: 1.125rem; }

.mobile-nav-item.active,
.mobile-nav-item:hover {
  color: var(--primary);
}

.table-scroll-mobile {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
