/* ========================================================
   BERBER RANDEVU SAAS - 2026 MODERN UI DESIGN SYSTEM
   ======================================================== */

:root {
  --primary: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-light: #eff6ff;
  --primary-dark: #1e3a8a;
  
  --secondary: #475569;
  --dark: #0f172a;
  --dark-surface: #1e293b;
  
  --bg-main: #f8fafc;
  --card-bg: #ffffff;
  --border-color: #e2e8f0;
  
  --success: #10b981;
  --success-light: #ecfdf5;
  --warning: #f59e0b;
  --warning-light: #fffbeb;
  --danger: #ef4444;
  --danger-light: #fef2f2;
  
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.08), 0 2px 4px -2px rgb(0 0 0 / 0.05);
  --shadow-lg: 0 10px 25px -3px rgb(0 0 0 / 0.08), 0 4px 6px -4px rgb(0 0 0 / 0.04);
  --shadow-xl: 0 20px 30px -10px rgb(0 0 0 / 0.12);
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: var(--bg-main);
  color: #334155;
  min-height: 100vh;
  margin: 0;
  padding: 0;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

/* Modern Sidebar */
.app-sidebar {
  width: 260px;
  background: #ffffff;
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  position: sticky;
  top: 0;
  height: 100vh;
  z-index: 1000;
  transition: all 0.3s ease;
}

.sidebar-header {
  padding: 24px 20px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--border-color);
}

.sidebar-logo {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.2rem;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
}

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

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  color: #64748b;
  text-decoration: none;
  font-weight: 500;
  border-radius: var(--radius-md);
  margin-bottom: 4px;
  transition: all 0.2s ease;
}

.sidebar-link i {
  font-size: 1.15rem;
}

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

.sidebar-link.active {
  background-color: var(--primary);
  color: white;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.sidebar-footer {
  padding: 16px 20px;
  border-top: 1px solid var(--border-color);
  background: #fafafa;
}

/* App Content Area */
.app-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.app-topbar {
  height: 70px;
  background: #ffffff;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  position: sticky;
  top: 0;
  z-index: 900;
}

.app-main {
  padding: 28px;
  flex: 1;
}

/* Modern Card */
.modern-card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  padding: 24px;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

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

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

/* Metric / Stat Cards */
.stat-card {
  background: white;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 18px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s, box-shadow 0.2s;
}

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

.stat-icon {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  flex-shrink: 0;
}

.stat-icon.primary { background: #dbeafe; color: #2563eb; }
.stat-icon.success { background: #d1fae5; color: #059669; }
.stat-icon.warning { background: #fef3c7; color: #d97706; }
.stat-icon.danger  { background: #fee2e2; color: #dc2626; }
.stat-icon.purple  { background: #ede9fe; color: #7c3aed; }

.stat-info h3 {
  margin: 0;
  font-size: 1.65rem;
  font-weight: 700;
  color: var(--dark);
}

.stat-info p {
  margin: 0;
  color: #64748b;
  font-size: 0.88rem;
  font-weight: 500;
}

/* Booking Page Wizard */
.booking-container {
  max-width: 840px;
  margin: 40px auto;
  padding: 0 16px;
}

.booking-header {
  text-align: center;
  margin-bottom: 30px;
}

.booking-stepper {
  display: flex;
  justify-content: space-between;
  margin-bottom: 32px;
  position: relative;
}

.booking-stepper::before {
  content: "";
  position: absolute;
  top: 18px;
  left: 20px;
  right: 20px;
  height: 2px;
  background: var(--border-color);
  z-index: 1;
}

.step-item {
  position: relative;
  z-index: 2;
  text-align: center;
  flex: 1;
}

.step-circle {
  width: 38px;
  height: 38px;
  margin: 0 auto 8px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  color: #64748b;
  transition: all 0.3s;
}

.step-item.active .step-circle {
  border-color: var(--primary);
  background: var(--primary);
  color: #ffffff;
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.15);
}

.step-item.completed .step-circle {
  border-color: var(--success);
  background: var(--success);
  color: #ffffff;
}

.step-title {
  font-size: 0.82rem;
  color: #64748b;
  font-weight: 600;
}

.step-item.active .step-title {
  color: var(--primary);
}

/* Option Select Cards (Services & Staff) */
.selectable-card {
  border: 2px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 18px;
  cursor: pointer;
  background: white;
  transition: all 0.2s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.selectable-card:hover {
  border-color: #93c5fd;
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.selectable-card.selected {
  border-color: var(--primary);
  background: #f0f7ff;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

/* Time Slot Chips */
.slot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 10px;
}

.slot-chip {
  padding: 12px 8px;
  text-align: center;
  background: white;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s;
  color: var(--dark);
}

.slot-chip:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

.slot-chip.selected {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.3);
}

/* Modern Calendar styles */
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
}

.calendar-day-header {
  font-weight: 700;
  text-align: center;
  padding: 8px;
  color: #64748b;
  font-size: 0.85rem;
  text-transform: uppercase;
}

.calendar-day-cell {
  background: white;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  min-height: 110px;
  padding: 8px;
  position: relative;
  transition: background 0.15s;
}

.calendar-day-cell:hover {
  background: #f8fafc;
}

.calendar-day-cell.today {
  border-color: var(--primary);
  background: #fbfdff;
}

.calendar-day-number {
  font-weight: 700;
  font-size: 0.9rem;
  margin-bottom: 6px;
  display: inline-block;
  width: 26px;
  height: 26px;
  line-height: 26px;
  text-align: center;
  border-radius: 50%;
}

.calendar-day-cell.today .calendar-day-number {
  background: var(--primary);
  color: white;
}

.cal-event-pill {
  font-size: 0.75rem;
  padding: 3px 6px;
  border-radius: 4px;
  margin-bottom: 3px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-weight: 500;
  cursor: pointer;
}

.cal-event-pill.pending { background: #fef3c7; color: #b45309; }
.cal-event-pill.confirmed { background: #dbeafe; color: #1e40af; }
.cal-event-pill.completed { background: #d1fae5; color: #065f46; }
.cal-event-pill.cancelled { background: #fee2e2; color: #991b1b; }

/* Responsive adjustments */
@media (max-width: 991px) {
  .app-sidebar {
    position: fixed;
    left: -260px;
    box-shadow: var(--shadow-xl);
  }
  .app-sidebar.show {
    left: 0;
  }
  .app-main {
    padding: 16px;
  }
}

/* =====================================================
   MODERN DATE SELECTOR & GROUPED SLOTS (2026 UI)
   ===================================================== */
.date-strip-wrapper {
  position: relative;
  margin-bottom: 0.5rem;
}

.date-strip {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding: 6px 2px 14px 2px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.date-strip::-webkit-scrollbar {
  height: 6px;
}

.date-strip::-webkit-scrollbar-thumb {
  background: #cbd5e1;
  border-radius: 4px;
}

.date-chip {
  flex: 0 0 94px;
  min-width: 94px;
  padding: 12px 6px;
  background: #ffffff;
  border: 2px solid #e2e8f0;
  border-radius: 16px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03);
}

.date-chip:hover {
  border-color: #93c5fd;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.12);
}

.date-chip.active {
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  border-color: #1d4ed8;
  color: #ffffff !important;
  box-shadow: 0 8px 18px rgba(37, 99, 235, 0.35);
  transform: translateY(-2px);
}

.date-chip .date-chip-badge {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.5px;
  padding: 2px 8px;
  border-radius: 20px;
  background: #eff6ff;
  color: #2563eb;
  margin-bottom: 4px;
  text-transform: uppercase;
}

.date-chip.active .date-chip-badge {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

.date-chip .date-chip-badge.badge-tomorrow {
  background: #fef3c7;
  color: #b45309;
}

.date-chip.active .date-chip-badge.badge-tomorrow {
  background: rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

.date-chip .date-chip-weekday {
  font-size: 0.78rem;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 2px;
}

.date-chip.active .date-chip-weekday {
  color: #e0e7ff;
}

.date-chip .date-chip-day {
  font-size: 1.5rem;
  font-weight: 800;
  line-height: 1.1;
  color: #0f172a;
}

.date-chip.active .date-chip-day {
  color: #ffffff;
}

.date-chip .date-chip-month {
  font-size: 0.72rem;
  font-weight: 600;
  color: #94a3b8;
  margin-top: 2px;
}

.date-chip.active .date-chip-month {
  color: #cbd5e1;
}

/* Time Slot Section Headers */
.slot-group-header {
  font-size: 0.85rem;
  font-weight: 700;
  color: #475569;
  letter-spacing: 0.3px;
  margin-top: 1.25rem;
  margin-bottom: 0.6rem;
  display: flex;
  align-items: center;
  gap: 8px;
}

.slot-group-header:first-of-type {
  margin-top: 0;
}

.slot-group-header .badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 3px 8px;
}

.slot-chip {
  padding: 12px 8px;
  font-size: 1.05rem;
  font-weight: 700;
  border-radius: 12px;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

@keyframes pulse-btn {
  0% { transform: scale(1); }
  50% { transform: scale(1.03); box-shadow: 0 6px 20px rgba(37, 99, 235, 0.4); }
  100% { transform: scale(1); }
}

.pulse-highlight {
  animation: pulse-btn 1.2s ease-in-out infinite;
}

/* Sidebar Backdrop for Mobile */
.sidebar-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.5);
  backdrop-filter: blur(3px);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.sidebar-backdrop.show {
  opacity: 1;
  visibility: visible;
}

/* App Download CTA Button & Card */
.btn-apk-download {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  background: #0f172a;
  color: #ffffff !important;
  border: 1px solid #334155;
  border-radius: 14px;
  padding: 10px 20px;
  text-decoration: none !important;
  transition: all 0.2s ease;
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.2);
}

.btn-apk-download:hover {
  background: #1e293b;
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(15, 23, 42, 0.3);
  color: #ffffff !important;
}

.btn-apk-download .apk-icon {
  font-size: 1.85rem;
  color: #10b981;
}

.btn-apk-download .apk-text {
  text-align: left;
  line-height: 1.2;
}

.btn-apk-download .apk-subtitle {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #94a3b8;
}

.btn-apk-download .apk-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: #ffffff;
}

/* Mobile Friendly Form & Table Tweaks */
@media (max-width: 768px) {
  .app-main {
    padding: 14px;
  }
  .stat-card {
    padding: 16px;
  }
  .stat-icon {
    width: 46px;
    height: 46px;
    font-size: 1.3rem;
  }
  .table-responsive {
    border-radius: 12px;
  }
}

