/* ============================================
   KIZO APP — Mobile-First Design System
   ============================================ */

/* --- Color Palette --- */
:root {
  --kz-primary: #1B2A4A;
  --kz-primary-light: #2D4373;
  --kz-accent: #00B894;
  --kz-accent-light: #00D4AA;
  --kz-accent-dark: #009B7D;
  --kz-danger: #FF6B6B;
  --kz-danger-dark: #E55555;
  --kz-warning: #FDCB6E;
  --kz-warning-dark: #E0A800;
  --kz-info: #74B9FF;
  --kz-info-dark: #4A9AE8;
  --kz-success: #00B894;
  --kz-success-light: #E8F8F5;

  --kz-bg: #F0F2F5;
  --kz-bg-card: #FFFFFF;
  --kz-bg-dark: #1B2A4A;
  --kz-bg-input: #F5F6F8;

  --kz-text: #1A1D26;
  --kz-text-secondary: #6C7A8D;
  --kz-text-muted: #9BA5B4;
  --kz-text-white: #FFFFFF;
  --kz-text-on-accent: #FFFFFF;

  --kz-border: #E4E7EC;
  --kz-border-light: #F0F2F5;

  --kz-shadow-sm: 0 1px 3px rgba(27, 42, 74, 0.06);
  --kz-shadow: 0 2px 8px rgba(27, 42, 74, 0.08);
  --kz-shadow-md: 0 4px 16px rgba(27, 42, 74, 0.10);
  --kz-shadow-lg: 0 8px 32px rgba(27, 42, 74, 0.14);
  --kz-shadow-accent: 0 4px 20px rgba(0, 184, 148, 0.30);

  --kz-radius-sm: 8px;
  --kz-radius: 14px;
  --kz-radius-lg: 20px;
  --kz-radius-full: 100px;

  --kz-topbar-h: 56px;
  --kz-bottomnav-h: 68px;

  --kz-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --kz-transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --kz-transition-slow: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Reset & Base --- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  scroll-behavior: smooth;
}

body {
  font-family: var(--kz-font);
  background-color: var(--kz-bg);
  color: var(--kz-text);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  min-height: 100vh;
  min-height: 100dvh;
}

img {
  max-width: 100%;
  display: block;
}

a {
  text-decoration: none;
  color: inherit;
}

/* --- Typography --- */
.kz-h1 { font-size: 1.75rem; font-weight: 700; line-height: 1.2; }
.kz-h2 { font-size: 1.375rem; font-weight: 700; line-height: 1.3; }
.kz-h3 { font-size: 1.125rem; font-weight: 600; line-height: 1.4; }
.kz-h4 { font-size: 1rem; font-weight: 600; line-height: 1.4; }
.kz-body { font-size: 0.9375rem; line-height: 1.5; }
.kz-small { font-size: 0.8125rem; line-height: 1.4; }
.kz-tiny { font-size: 0.6875rem; line-height: 1.3; text-transform: uppercase; letter-spacing: 0.5px; font-weight: 600; }

.kz-text-primary { color: var(--kz-primary); }
.kz-text-accent { color: var(--kz-accent); }
.kz-text-danger { color: var(--kz-danger); }
.kz-text-warning { color: var(--kz-warning-dark); }
.kz-text-muted { color: var(--kz-text-muted); }
.kz-text-secondary { color: var(--kz-text-secondary); }
.kz-text-success { color: var(--kz-success); }
.kz-text-info { color: var(--kz-info-dark); }
.kz-text-white { color: var(--kz-text-white); }
.kz-text-center { text-align: center; }

.kz-fw-400 { font-weight: 400; }
.kz-fw-600 { font-weight: 600; }
.kz-fw-700 { font-weight: 700; }

/* --- App Shell Layout --- */
.kz-app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  position: relative;
}

.kz-topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--kz-topbar-h);
  background: var(--kz-bg-card);
  border-bottom: 1px solid var(--kz-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  z-index: 100;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.kz-topbar--dark {
  background: var(--kz-bg-dark);
  border-bottom-color: rgba(255,255,255,0.08);
}

.kz-topbar__left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.kz-topbar__right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.kz-topbar__avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--kz-accent), var(--kz-accent-dark));
  color: var(--kz-text-white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.875rem;
  flex-shrink: 0;
  overflow: hidden;
}

.kz-topbar__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kz-topbar__title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--kz-text);
}

.kz-topbar--dark .kz-topbar__title {
  color: var(--kz-text-white);
}

.kz-topbar__subtitle {
  font-size: 0.6875rem;
  color: var(--kz-text-muted);
  line-height: 1.2;
}

.kz-topbar--dark .kz-topbar__subtitle {
  color: rgba(255,255,255,0.6);
}

.kz-topbar__icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: none;
  background: var(--kz-bg-input);
  color: var(--kz-text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  transition: var(--kz-transition);
  font-size: 1.1rem;
}

.kz-topbar--dark .kz-topbar__icon-btn {
  background: rgba(255,255,255,0.1);
  color: var(--kz-text-white);
}

.kz-topbar__icon-btn:active {
  transform: scale(0.92);
}

.kz-topbar__badge {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--kz-danger);
  border: 2px solid var(--kz-bg-card);
}

.kz-main {
  flex: 1;
  padding-top: calc(var(--kz-topbar-h) + 8px);
  padding-bottom: calc(var(--kz-bottomnav-h) + 16px);
  padding-left: 16px;
  padding-right: 16px;
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
}

.kz-main--admin {
  max-width: 900px;
}

.kz-main--full {
  max-width: 100%;
  padding-left: 0;
  padding-right: 0;
}

/* --- Bottom Navigation --- */
.kz-bottomnav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: var(--kz-bottomnav-h);
  background: var(--kz-bg-card);
  border-top: 1px solid var(--kz-border);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 0 4px;
  padding-bottom: env(safe-area-inset-bottom, 0);
  z-index: 100;
  box-shadow: 0 -2px 12px rgba(27, 42, 74, 0.06);
}

.kz-bottomnav__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 6px 12px;
  border-radius: var(--kz-radius-sm);
  color: var(--kz-text-muted);
  cursor: pointer;
  transition: var(--kz-transition);
  position: relative;
  min-width: 56px;
  min-height: 48px;
  border: none;
  background: none;
  text-decoration: none;
  -webkit-tap-highlight-color: transparent;
}

.kz-bottomnav__item i,
.kz-bottomnav__item .kz-nav-icon {
  font-size: 1.25rem;
  transition: var(--kz-transition);
}

.kz-bottomnav__item span {
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  transition: var(--kz-transition);
}

.kz-bottomnav__item.active {
  color: var(--kz-accent);
}

.kz-bottomnav__item.active::before {
  content: '';
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 32px;
  height: 3px;
  background: var(--kz-accent);
  border-radius: 0 0 4px 4px;
}

.kz-bottomnav__item:active {
  transform: scale(0.92);
}

.kz-bottomnav__badge {
  position: absolute;
  top: 2px;
  right: 8px;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  background: var(--kz-danger);
  color: white;
  font-size: 0.5625rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
  line-height: 1;
}

/* --- Cards --- */
.kz-card {
  background: var(--kz-bg-card);
  border-radius: var(--kz-radius);
  box-shadow: var(--kz-shadow-sm);
  padding: 16px;
  margin-bottom: 12px;
  border: 1px solid var(--kz-border-light);
  transition: var(--kz-transition);
}

.kz-card--elevated {
  box-shadow: var(--kz-shadow);
}

.kz-card--accent {
  border-left: 4px solid var(--kz-accent);
}

.kz-card--danger {
  border-left: 4px solid var(--kz-danger);
}

.kz-card--warning {
  border-left: 4px solid var(--kz-warning);
}

.kz-card--info {
  border-left: 4px solid var(--kz-info);
}

.kz-card--gradient {
  background: linear-gradient(135deg, var(--kz-primary), var(--kz-primary-light));
  color: var(--kz-text-white);
  border: none;
}

.kz-card--unread {
  background: #F0FFFE;
  border-left: 4px solid var(--kz-accent);
}

.kz-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.kz-card__title {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--kz-text);
}

.kz-card--gradient .kz-card__title {
  color: var(--kz-text-white);
}

.kz-card__body {
  font-size: 0.875rem;
  color: var(--kz-text-secondary);
  line-height: 1.5;
}

.kz-card--gradient .kz-card__body {
  color: rgba(255,255,255,0.8);
}

/* --- Stat Cards --- */
.kz-stat {
  text-align: center;
  padding: 14px 8px;
}

.kz-stat__value {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 2px;
}

.kz-stat__label {
  font-size: 0.6875rem;
  color: var(--kz-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

/* --- Stat Grid --- */
.kz-stat-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  margin-bottom: 12px;
}

.kz-stat-grid--3 {
  grid-template-columns: repeat(3, 1fr);
}

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

/* --- Buttons --- */
.kz-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 24px;
  height: 50px;
  border-radius: var(--kz-radius);
  border: none;
  font-family: var(--kz-font);
  font-size: 0.9375rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--kz-transition);
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  position: relative;
  overflow: hidden;
  width: 100%;
  text-align: center;
}

.kz-btn:active {
  transform: scale(0.97);
}

.kz-btn--primary {
  background: linear-gradient(135deg, var(--kz-accent), var(--kz-accent-dark));
  color: var(--kz-text-on-accent);
  box-shadow: var(--kz-shadow-accent);
}

.kz-btn--primary:hover {
  box-shadow: 0 6px 24px rgba(0, 184, 148, 0.35);
}

.kz-btn--danger {
  background: linear-gradient(135deg, var(--kz-danger), var(--kz-danger-dark));
  color: white;
  box-shadow: 0 4px 20px rgba(255, 107, 107, 0.30);
}

.kz-btn--secondary {
  background: var(--kz-bg-input);
  color: var(--kz-text);
}

.kz-btn--outline {
  background: transparent;
  border: 2px solid var(--kz-border);
  color: var(--kz-text);
}

.kz-btn--outline-danger {
  background: transparent;
  border: 2px solid var(--kz-danger);
  color: var(--kz-danger);
}

.kz-btn--ghost {
  background: transparent;
  color: var(--kz-accent);
}

.kz-btn--lg {
  height: 60px;
  font-size: 1.0625rem;
  border-radius: var(--kz-radius-lg);
}

.kz-btn--xl {
  height: 72px;
  font-size: 1.125rem;
  border-radius: var(--kz-radius-lg);
  letter-spacing: 0.5px;
}

.kz-btn--sm {
  height: 38px;
  padding: 0 16px;
  font-size: 0.8125rem;
  border-radius: var(--kz-radius-sm);
}

.kz-btn--icon {
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 50%;
  flex-shrink: 0;
}

.kz-btn[disabled] {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

/* --- Badges --- */
.kz-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: var(--kz-radius-full);
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  line-height: 1;
}

.kz-badge--success {
  background: var(--kz-success-light);
  color: var(--kz-accent-dark);
}

.kz-badge--danger {
  background: #FFE8E8;
  color: var(--kz-danger-dark);
}

.kz-badge--warning {
  background: #FFF8E1;
  color: var(--kz-warning-dark);
}

.kz-badge--info {
  background: #E8F4FD;
  color: var(--kz-info-dark);
}

.kz-badge--neutral {
  background: var(--kz-bg-input);
  color: var(--kz-text-secondary);
}

.kz-badge--primary {
  background: rgba(27, 42, 74, 0.08);
  color: var(--kz-primary);
}

/* --- Status Dot --- */
.kz-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}

.kz-dot--active {
  background: var(--kz-accent);
  box-shadow: 0 0 0 3px rgba(0, 184, 148, 0.2);
  animation: kz-pulse 2s infinite;
}

.kz-dot--inactive {
  background: var(--kz-text-muted);
}

.kz-dot--danger {
  background: var(--kz-danger);
  box-shadow: 0 0 0 3px rgba(255, 107, 107, 0.2);
}

.kz-dot--warning {
  background: var(--kz-warning);
}

/* --- Inputs --- */
.kz-input {
  width: 100%;
  height: 50px;
  padding: 0 16px;
  border: 2px solid var(--kz-border);
  border-radius: var(--kz-radius);
  font-family: var(--kz-font);
  font-size: 0.9375rem;
  color: var(--kz-text);
  background: var(--kz-bg-card);
  transition: var(--kz-transition);
  -webkit-appearance: none;
  appearance: none;
}

.kz-input:focus {
  outline: none;
  border-color: var(--kz-accent);
  box-shadow: 0 0 0 3px rgba(0, 184, 148, 0.12);
}

.kz-input::placeholder {
  color: var(--kz-text-muted);
}

.kz-input--lg {
  height: 56px;
  font-size: 1rem;
}

.kz-label {
  display: block;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--kz-text-secondary);
  margin-bottom: 6px;
}

.kz-input-group {
  margin-bottom: 16px;
}

textarea.kz-input {
  height: auto;
  min-height: 100px;
  padding: 14px 16px;
  resize: vertical;
}

select.kz-input {
  cursor: pointer;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236C7A8D' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
}

/* --- Toast Notifications --- */
.kz-toast-container {
  position: fixed;
  bottom: calc(var(--kz-bottomnav-h) + 12px);
  left: 16px;
  right: 16px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
  max-width: 600px;
  margin: 0 auto;
}

.kz-toast {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-radius: var(--kz-radius);
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: var(--kz-shadow-lg);
  pointer-events: auto;
  animation: kz-slideUp 0.3s ease-out;
  color: var(--kz-text-white);
}

.kz-toast--success {
  background: var(--kz-accent-dark);
}

.kz-toast--error {
  background: var(--kz-danger-dark);
}

.kz-toast--info {
  background: var(--kz-primary);
}

.kz-toast--warning {
  background: var(--kz-warning-dark);
  color: var(--kz-text);
}

.kz-toast__icon {
  font-size: 1.1rem;
  flex-shrink: 0;
}

.kz-toast__close {
  margin-left: auto;
  background: none;
  border: none;
  color: inherit;
  opacity: 0.7;
  cursor: pointer;
  font-size: 1.1rem;
  padding: 0;
  flex-shrink: 0;
}

.kz-toast.kz-toast--exit {
  animation: kz-slideDown 0.25s ease-in forwards;
}

/* --- Loading Overlay --- */
.kz-loader-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 2000;
  gap: 16px;
  animation: kz-fadeIn 0.2s ease-out;
}

.kz-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--kz-border);
  border-top-color: var(--kz-accent);
  border-radius: 50%;
  animation: kz-spin 0.7s linear infinite;
}

.kz-spinner--sm {
  width: 20px;
  height: 20px;
  border-width: 2px;
}

.kz-loader-text {
  font-size: 0.875rem;
  color: var(--kz-text-secondary);
  font-weight: 500;
}

/* --- Bottom Sheet Modal --- */
.kz-sheet-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 500;
  animation: kz-fadeIn 0.2s ease-out;
}

.kz-sheet-backdrop.kz-sheet--exit {
  animation: kz-fadeOut 0.25s ease-in forwards;
}

.kz-sheet {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  max-height: 90vh;
  background: var(--kz-bg-card);
  border-radius: var(--kz-radius-lg) var(--kz-radius-lg) 0 0;
  z-index: 501;
  overflow-y: auto;
  animation: kz-slideUp 0.3s ease-out;
  padding: 0;
}

.kz-sheet.kz-sheet--exit {
  animation: kz-slideDown 0.25s ease-in forwards;
}

.kz-sheet__handle {
  width: 36px;
  height: 4px;
  background: var(--kz-border);
  border-radius: 2px;
  margin: 12px auto 0;
}

.kz-sheet__header {
  padding: 16px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--kz-border-light);
}

.kz-sheet__title {
  font-size: 1.0625rem;
  font-weight: 700;
}

.kz-sheet__close {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: var(--kz-bg-input);
  color: var(--kz-text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1rem;
}

.kz-sheet__body {
  padding: 20px;
}

/* --- Success Animation --- */
.kz-success-anim {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 32px;
}

.kz-checkmark-circle {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--kz-accent), var(--kz-accent-dark));
  display: flex;
  align-items: center;
  justify-content: center;
  animation: kz-scaleIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.kz-checkmark-circle i {
  color: white;
  font-size: 2rem;
}

.kz-success-text {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--kz-text);
}

.kz-success-sub {
  font-size: 0.875rem;
  color: var(--kz-text-secondary);
}

/* --- Employee Item Card --- */
.kz-emp-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--kz-bg-card);
  border-radius: var(--kz-radius);
  margin-bottom: 8px;
  box-shadow: var(--kz-shadow-sm);
  border: 1px solid var(--kz-border-light);
  cursor: pointer;
  transition: var(--kz-transition);
}

.kz-emp-card:active {
  transform: scale(0.98);
  background: var(--kz-bg-input);
}

.kz-emp-card__avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--kz-primary-light), var(--kz-primary));
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.875rem;
  flex-shrink: 0;
  overflow: hidden;
}

.kz-emp-card__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kz-emp-card__info {
  flex: 1;
  min-width: 0;
}

.kz-emp-card__name {
  font-size: 0.9375rem;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.kz-emp-card__meta {
  font-size: 0.75rem;
  color: var(--kz-text-muted);
}

.kz-emp-card__right {
  text-align: right;
  flex-shrink: 0;
}

/* --- Tabs / Sections --- */
.kz-tab-content {
  display: none;
  animation: kz-fadeIn 0.25s ease-out;
}

.kz-tab-content.active {
  display: block;
}

/* --- Pill Tabs (inline) --- */
.kz-pills {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding: 2px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  margin-bottom: 16px;
}

.kz-pills::-webkit-scrollbar {
  display: none;
}

.kz-pill {
  padding: 8px 18px;
  border-radius: var(--kz-radius-full);
  font-size: 0.8125rem;
  font-weight: 600;
  border: 2px solid var(--kz-border);
  background: var(--kz-bg-card);
  color: var(--kz-text-secondary);
  cursor: pointer;
  white-space: nowrap;
  transition: var(--kz-transition);
  flex-shrink: 0;
}

.kz-pill.active,
.kz-pill:active {
  background: var(--kz-primary);
  color: var(--kz-text-white);
  border-color: var(--kz-primary);
}

/* --- Quick Actions --- */
.kz-quick-actions {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 4px;
  margin-bottom: 16px;
  scrollbar-width: none;
}

.kz-quick-actions::-webkit-scrollbar {
  display: none;
}

.kz-quick-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  min-width: 80px;
  padding: 14px 10px;
  border-radius: var(--kz-radius);
  background: var(--kz-bg-card);
  border: 1px solid var(--kz-border-light);
  box-shadow: var(--kz-shadow-sm);
  cursor: pointer;
  transition: var(--kz-transition);
  text-decoration: none;
  flex-shrink: 0;
}

.kz-quick-action:active {
  transform: scale(0.95);
}

.kz-quick-action__icon {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: white;
}

.kz-quick-action__icon--accent {
  background: linear-gradient(135deg, var(--kz-accent), var(--kz-accent-dark));
}

.kz-quick-action__icon--primary {
  background: linear-gradient(135deg, var(--kz-primary-light), var(--kz-primary));
}

.kz-quick-action__icon--warning {
  background: linear-gradient(135deg, var(--kz-warning), var(--kz-warning-dark));
}

.kz-quick-action__icon--info {
  background: linear-gradient(135deg, var(--kz-info), var(--kz-info-dark));
}

.kz-quick-action__label {
  font-size: 0.6875rem;
  font-weight: 600;
  color: var(--kz-text-secondary);
  text-align: center;
}

/* --- Search Bar --- */
.kz-search {
  position: relative;
  margin-bottom: 12px;
}

.kz-search__input {
  width: 100%;
  height: 46px;
  padding: 0 16px 0 44px;
  border: 2px solid var(--kz-border);
  border-radius: var(--kz-radius-full);
  font-family: var(--kz-font);
  font-size: 0.875rem;
  color: var(--kz-text);
  background: var(--kz-bg-card);
  transition: var(--kz-transition);
}

.kz-search__input:focus {
  outline: none;
  border-color: var(--kz-accent);
  box-shadow: 0 0 0 3px rgba(0, 184, 148, 0.12);
}

.kz-search__icon {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--kz-text-muted);
  font-size: 0.9rem;
}

/* --- Expandable Card --- */
.kz-expand {
  overflow: hidden;
  max-height: 0;
  transition: max-height 0.3s ease-out, padding 0.3s ease-out;
  padding: 0 16px;
}

.kz-expand.open {
  max-height: 600px;
  padding: 12px 16px;
  border-top: 1px solid var(--kz-border-light);
}

/* --- Progress Bar --- */
.kz-progress {
  height: 6px;
  background: var(--kz-bg-input);
  border-radius: 3px;
  overflow: hidden;
}

.kz-progress__bar {
  height: 100%;
  border-radius: 3px;
  transition: width 0.5s ease-out;
}

.kz-progress__bar--accent { background: var(--kz-accent); }
.kz-progress__bar--danger { background: var(--kz-danger); }
.kz-progress__bar--warning { background: var(--kz-warning); }
.kz-progress__bar--info { background: var(--kz-info); }

/* --- Divider --- */
.kz-divider {
  height: 1px;
  background: var(--kz-border-light);
  margin: 16px 0;
}

/* --- Skeleton Loader --- */
.kz-skeleton {
  background: linear-gradient(90deg, var(--kz-bg-input) 25%, #E8EBF0 50%, var(--kz-bg-input) 75%);
  background-size: 200% 100%;
  animation: kz-shimmer 1.5s infinite;
  border-radius: var(--kz-radius-sm);
}

.kz-skeleton--text {
  height: 14px;
  width: 80%;
  margin-bottom: 8px;
}

.kz-skeleton--text-sm {
  height: 10px;
  width: 60%;
}

.kz-skeleton--circle {
  width: 42px;
  height: 42px;
  border-radius: 50%;
}

.kz-skeleton--card {
  height: 80px;
  width: 100%;
  margin-bottom: 10px;
}

/* --- Utility Classes --- */
.kz-flex { display: flex; }
.kz-flex-col { flex-direction: column; }
.kz-items-center { align-items: center; }
.kz-items-start { align-items: flex-start; }
.kz-justify-between { justify-content: space-between; }
.kz-justify-center { justify-content: center; }
.kz-justify-end { justify-content: flex-end; }
.kz-gap-4 { gap: 4px; }
.kz-gap-8 { gap: 8px; }
.kz-gap-12 { gap: 12px; }
.kz-gap-16 { gap: 16px; }
.kz-flex-1 { flex: 1; }
.kz-shrink-0 { flex-shrink: 0; }
.kz-wrap { flex-wrap: wrap; }

.kz-mt-0 { margin-top: 0; }
.kz-mt-8 { margin-top: 8px; }
.kz-mt-12 { margin-top: 12px; }
.kz-mt-16 { margin-top: 16px; }
.kz-mt-24 { margin-top: 24px; }
.kz-mr-4 { margin-right: 4px; }
.kz-mr-8 { margin-right: 8px; }
.kz-mb-0 { margin-bottom: 0; }
.kz-mb-4 { margin-bottom: 4px; }
.kz-mb-8 { margin-bottom: 8px; }
.kz-mb-12 { margin-bottom: 12px; }
.kz-mb-16 { margin-bottom: 16px; }
.kz-mb-24 { margin-bottom: 24px; }
.kz-p-0 { padding: 0; }
.kz-p-16 { padding: 16px; }
.kz-px-16 { padding-left: 16px; padding-right: 16px; }
.kz-pr-16 { padding-right: 16px; }
.kz-py-8 { padding-top: 8px; padding-bottom: 8px; }
.kz-py-12 { padding-top: 12px; padding-bottom: 12px; }
.kz-py-24 { padding-top: 24px; padding-bottom: 24px; }
.kz-py-32 { padding-top: 32px; padding-bottom: 32px; }

.kz-w-full { width: 100%; }
.kz-overflow-hidden { overflow: hidden; }
.kz-truncate { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

.kz-hidden { display: none !important; }
.kz-visible { display: block !important; }

.kz-scroll-x {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.kz-scroll-x::-webkit-scrollbar { display: none; }

/* --- GPS Status Bar --- */
.kz-gps-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: var(--kz-radius-sm);
  font-size: 0.8125rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.kz-gps-status--locating {
  background: #FFF8E1;
  color: var(--kz-warning-dark);
}

.kz-gps-status--verified {
  background: var(--kz-success-light);
  color: var(--kz-accent-dark);
}

.kz-gps-status--error {
  background: #FFE8E8;
  color: var(--kz-danger-dark);
}

/* --- QR Scanner Area --- */
.kz-qr-area {
  width: 100%;
  aspect-ratio: 1;
  max-width: 320px;
  margin: 0 auto 16px;
  border-radius: var(--kz-radius-lg);
  overflow: hidden;
  background: #000;
  position: relative;
}

.kz-qr-area video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.kz-qr-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.kz-qr-frame {
  width: 200px;
  height: 200px;
  border: 3px solid var(--kz-accent);
  border-radius: 16px;
  box-shadow: 0 0 0 4000px rgba(0, 0, 0, 0.4);
  position: relative;
}

.kz-qr-frame::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 50%;
  transform: translateX(-50%);
  width: 60%;
  height: 3px;
  background: var(--kz-accent);
  border-radius: 2px;
  animation: kz-scanline 2s ease-in-out infinite;
}

/* --- Step Progress --- */
.kz-steps {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  margin-bottom: 24px;
}

.kz-step {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--kz-text-muted);
}

.kz-step.active {
  color: var(--kz-accent);
}

.kz-step.done {
  color: var(--kz-accent-dark);
}

.kz-step__dot {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--kz-border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.6875rem;
  color: var(--kz-text-muted);
}

.kz-step.active .kz-step__dot {
  background: var(--kz-accent);
  color: white;
}

.kz-step.done .kz-step__dot {
  background: var(--kz-accent-dark);
  color: white;
}

.kz-step__line {
  width: 32px;
  height: 2px;
  background: var(--kz-border);
  margin: 0 4px;
}

.kz-step.done + .kz-step__line,
.kz-step__line.done {
  background: var(--kz-accent);
}

/* --- Scrollable Day Chips --- */
.kz-day-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 4px 0;
  margin-bottom: 16px;
  scrollbar-width: none;
}
.kz-day-scroll::-webkit-scrollbar { display: none; }

.kz-day-chip {
  min-width: 56px;
  padding: 10px 6px;
  border-radius: var(--kz-radius);
  background: var(--kz-bg-card);
  border: 2px solid var(--kz-border-light);
  text-align: center;
  cursor: pointer;
  transition: var(--kz-transition);
  flex-shrink: 0;
}

.kz-day-chip.active {
  background: var(--kz-primary);
  color: white;
  border-color: var(--kz-primary);
}

.kz-day-chip__day {
  font-size: 0.625rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  opacity: 0.7;
}

.kz-day-chip__date {
  font-size: 1.125rem;
  font-weight: 700;
  margin-top: 2px;
}

.kz-day-chip__dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  margin: 4px auto 0;
}

/* --- Animations --- */
@keyframes kz-fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes kz-fadeOut {
  from { opacity: 1; }
  to { opacity: 0; }
}

@keyframes kz-slideUp {
  from { transform: translateY(100%); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

@keyframes kz-slideDown {
  from { transform: translateY(0); opacity: 1; }
  to { transform: translateY(100%); opacity: 0; }
}

@keyframes kz-scaleIn {
  from { transform: scale(0); opacity: 0; }
  to { transform: scale(1); opacity: 1; }
}

@keyframes kz-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

@keyframes kz-spin {
  to { transform: rotate(360deg); }
}

@keyframes kz-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

@keyframes kz-scanline {
  0%, 100% { top: -1px; }
  50% { top: calc(100% - 2px); }
}

/* --- Responsive --- */
.kz-d-none { display: none !important; }
.kz-d-block { display: block !important; }

@media (min-width: 768px) {
  .kz-stat-grid--4 {
    grid-template-columns: repeat(4, 1fr);
  }

  .kz-main {
    padding-left: 24px;
    padding-right: 24px;
  }
  
  .kz-d-md-none { display: none !important; }
  .kz-d-md-block { display: block !important; }
}

/* --- Print --- */
@media print {
  .kz-topbar,
  .kz-bottomnav,
  .kz-toast-container {
    display: none !important;
  }

  .kz-main {
    padding: 0;
    max-width: 100%;
  }
}
