@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@300;400;600;700;800&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  --primary-color: #10b981;
  --primary-glow: rgba(16, 185, 129, 0.25);
  --secondary-color: #3b82f6;
  --secondary-glow: rgba(59, 130, 246, 0.25);
  
  --bg-dark: #0f172a;
  --bg-dark-900: #020617;
  --bg-light: #f8fafc;
  
  --card-dark: rgba(30, 41, 59, 0.7);
  --card-light: rgba(255, 255, 255, 0.9);
  
  --text-dark-primary: #f8fafc;
  --text-dark-secondary: #94a3b8;
  --text-light-primary: #0f172a;
  --text-light-secondary: #475569;
  
  --border-dark: rgba(255, 255, 255, 0.08);
  --border-light: rgba(0, 0, 0, 0.06);

  --font-ar: 'Cairo', sans-serif;
  --font-en: 'Inter', sans-serif;
  
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-en);
  background-color: var(--bg-dark-900);
  color: var(--text-dark-primary);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

body.rtl {
  font-family: var(--font-ar);
  direction: rtl;
  text-align: right;
}

/* Dynamic theme styles applied on containers */
.app-container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 100%;
  overflow-x: hidden;
  background: radial-gradient(circle at 10% 20%, rgba(16, 185, 129, 0.05) 0%, transparent 40%),
              radial-gradient(circle at 90% 80%, rgba(59, 130, 246, 0.05) 0%, transparent 40%),
              var(--bg-dark-900);
}

/* Glassmorphism Header */
header {
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  background: rgba(15, 23, 42, 0.6);
  border-bottom: 1px solid var(--border-dark);
  padding: 15px 5%;
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

.brand-logo {
  height: 42px;
  width: 42px;
  object-fit: contain;
  border-radius: var(--radius-sm);
}

.brand-name {
  font-size: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.header-controls {
  display: flex;
  align-items: center;
  gap: 15px;
}

/* Custom buttons */
.btn {
  padding: 10px 22px;
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-decoration: none;
}

.btn-primary {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  color: #ffffff;
  box-shadow: 0 4px 15px var(--primary-glow);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px var(--primary-glow), 0 0 10px var(--secondary-glow);
  opacity: 0.95;
}

.btn-secondary {
  background: var(--glass-bg);
  border: 1px solid var(--border-dark);
  color: var(--text-dark-primary);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.15);
  transform: translateY(-2px);
}

.btn-danger {
  background: #ef4444;
  color: white;
}
.btn-danger:hover {
  background: #dc2626;
  transform: translateY(-2px);
}

/* Glassmorphism Card styling */
.card {
  background: var(--card-dark);
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-lg);
  padding: 30px;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
  transition: var(--transition);
}

.card:hover {
  border-color: rgba(255, 255, 255, 0.15);
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.35);
}

/* Input Styles */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-dark-secondary);
}

.form-control {
  width: 100%;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid var(--border-dark);
  color: var(--text-dark-primary);
  font-size: 1rem;
  transition: var(--transition);
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

/* Grid Layouts */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}

.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 25px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

@media (max-width: 992px) {
  .grid-3, .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .grid-2, .grid-3, .grid-4 {
    grid-template-columns: 1fr;
  }
}

/* Translation Switcher dropdown */
.lang-select {
  background: var(--glass-bg);
  border: 1px solid var(--border-dark);
  color: var(--text-dark-primary);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 0.85rem;
}

.lang-select option {
  background: var(--bg-dark);
  color: var(--text-dark-primary);
}



/* Page animations */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Custom Table Design for Admins/Kitchen */
.custom-table-container {
  overflow-x: auto;
  margin-top: 15px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-dark);
}

/* Custom visible scrollbar for table container */
.custom-table-container::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
.custom-table-container::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.15);
  border-radius: 4px;
}
.custom-table-container::-webkit-scrollbar-thumb {
  background: var(--primary-color);
  border-radius: 4px;
}
.custom-table-container::-webkit-scrollbar-thumb:hover {
  background: var(--secondary-color);
}

.custom-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

body.rtl .custom-table {
  text-align: right;
}

.custom-table th {
  background: rgba(15, 23, 42, 0.8);
  padding: 14px 18px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-dark-secondary);
  border-bottom: 1px solid var(--border-dark);
}

.custom-table td {
  padding: 14px 18px;
  font-size: 0.95rem;
  border-bottom: 1px solid var(--border-dark);
  color: var(--text-dark-primary);
}

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

.custom-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

/* Status Badges */
.badge {
  padding: 4px 10px;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  display: inline-block;
}

.badge-success { background: rgba(16, 185, 129, 0.15); color: #10b981; }
.badge-warning { background: rgba(245, 158, 11, 0.15); color: #f59e0b; }
.badge-danger { background: rgba(239, 68, 68, 0.15); color: #ef4444; }
.badge-info { background: rgba(59, 130, 246, 0.15); color: #3b82f6; }

/* Interactive items list - e.g. packages and daily boxes selection */
.selectable-card {
  border: 2px solid transparent;
  cursor: pointer;
}

.selectable-card:hover {
  transform: scale(1.02);
}

.selectable-card.selected {
  border-color: var(--primary-color);
  box-shadow: 0 0 15px var(--primary-glow);
}

/* Tabs system */
.tabs-header {
  display: flex;
  gap: 10px;
  border-bottom: 1px solid var(--border-dark);
  margin-bottom: 25px;
}

.tab-btn {
  padding: 12px 20px;
  background: transparent;
  border: none;
  color: var(--text-dark-secondary);
  cursor: pointer;
  font-weight: 600;
  position: relative;
  font-size: 0.95rem;
  transition: var(--transition);
  white-space: nowrap; /* Prevent button text wrapping */
}

body.rtl .tab-btn {
  font-family: var(--font-ar);
}

.tab-btn:hover {
  color: var(--text-dark-primary);
}

.tab-btn.active {
  color: var(--primary-color);
}

.tab-btn.active::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--primary-color);
  box-shadow: 0 0 8px var(--primary-color);
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
  animation: fadeIn 0.4s ease;
}

/* Color pickers grid */
.color-picker-wrapper {
  display: flex;
  align-items: center;
  gap: 15px;
}

.color-input-circle {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  border: 2px solid var(--border-dark);
  cursor: pointer;
  background: none;
  overflow: hidden;
}

.color-input-circle::-webkit-color-swatch-wrapper {
  padding: 0;
}

.color-input-circle::-webkit-color-swatch {
  border: none;
  border-radius: 50%;
}

/* Map placeholder stylesheet */
#map {
  height: 300px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-dark);
  margin-bottom: 15px;
  background: var(--bg-dark);
}

/* Toast notifications */
.toast {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: #1e293b;
  border: 1px solid var(--border-dark);
  color: #fff;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  box-shadow: 0 10px 25px rgba(0,0,0,0.3);
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 10px;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

body.rtl .toast {
  right: auto;
  left: 20px;
}

/* Loader wrapper */
.loader {
  border: 3px solid rgba(255,255,255,0.1);
  border-radius: 50%;
  border-top: 3px solid var(--primary-color);
  width: 24px;
  height: 24px;
  animation: spin 1s linear infinite;
  display: inline-block;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.center-flex {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
}

/* Mobile Responsiveness Improvements */
@media (max-width: 600px) {
  html, body {
    max-width: 100%;
    overflow-x: hidden;
  }
  
  header {
    flex-direction: column;
    gap: 12px;
    padding: 15px 10px;
    text-align: center;
  }
  
  .header-controls {
    width: 100%;
    justify-content: center;
    gap: 10px;
  }
  
  .card {
    padding: 20px 15px;
    border-radius: var(--radius-md);
  }
  
  .tabs-header {
    display: flex !important;
    flex-wrap: nowrap !important;
    overflow-x: auto !important;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 5px;
    gap: 5px;
    justify-content: flex-start !important;
  }
  
  .tab-btn {
    flex-shrink: 0;
    padding: 8px 12px;
    font-size: 0.85rem;
  }
  
  .banner {
    padding: 25px 15px !important;
  }
  
  .banner h1 {
    font-size: 1.6rem !important;
  }
  
  .banner p {
    font-size: 0.85rem !important;
    margin-bottom: 15px !important;
  }

  .banner .btn {
    padding: 8px 16px !important;
    font-size: 0.85rem !important;
  }

  .onboarding-content {
    padding: 20px 15px;
  }
  
  #map {
    height: 220px;
  }
  
  .meal-grid {
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)) !important;
    gap: 10px !important;
  }
}

/* Progressive Wizard Bar Styles */
.wizard-progress-wrapper {
  margin-bottom: 25px;
}

.wizard-step-text {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--primary-color);
  margin-bottom: 12px;
  text-align: center;
}

body.rtl .wizard-step-text {
  font-family: var(--font-ar);
}

.wizard-progress-track {
  height: 6px;
  background: var(--border-dark);
  border-radius: 50px;
  overflow: hidden;
  position: relative;
}

.wizard-progress-bar {
  height: 100%;
  width: 25%;
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
  border-radius: 50px;
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 10px var(--primary-glow);
}

/* Resize Header Buttons to match Lang switcher */
header .btn, #auth-buttons .btn {
  padding: 6px 14px !important;
  font-size: 0.85rem !important;
  border-radius: var(--radius-sm) !important;
}

/* Onboarding slide background images */
.onboarding-bg-img {
  width: 100%;
  height: 220px;
  border-radius: var(--radius-lg);
  object-fit: cover;
  margin-bottom: 20px;
  border: 1px solid var(--border-dark);
}

/* Meal Category Sub-Tabs in Checkout */
.meal-categories-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 20px;
  border-bottom: 1px solid var(--border-dark);
  padding-bottom: 8px;
  overflow-x: auto;
  white-space: nowrap;
}
.category-tab-btn {
  background: transparent;
  border: 1px solid var(--border-dark);
  color: var(--text-dark-secondary);
  padding: 6px 14px;
  border-radius: 50px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  transition: var(--transition);
}
body.rtl .category-tab-btn {
  font-family: var(--font-ar);
}
.category-tab-btn.active {
  background: var(--primary-color);
  color: #fff;
  border-color: var(--primary-color);
  box-shadow: 0 2px 8px var(--primary-glow);
}
.meal-category-section {
  display: none;
  animation: fadeIn 0.3s ease;
}
.meal-category-section.active {
  display: block;
}

/* Meal Item Images */
.meal-image-container {
  width: 100%;
  height: 140px;
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 10px;
  border: 1px solid var(--border-dark);
  background: rgba(0, 0, 0, 0.2);
}
.meal-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}
.meal-selection-item:hover .meal-image {
  transform: scale(1.05);
}

/* Light Theme Style Definitions */
body.light-theme {
  --bg-dark-900: #f8fafc;
  --bg-dark: #ffffff;
  --card-dark: #ffffff;
  --text-dark-primary: #0f172a;
  --text-dark-secondary: #64748b;
  --border-dark: #e2e8f0;
}
body.light-theme .app-container {
  background: radial-gradient(circle at 10% 20%, rgba(16, 185, 129, 0.03) 0%, transparent 40%),
              radial-gradient(circle at 90% 80%, rgba(59, 130, 246, 0.03) 0%, transparent 40%),
              #f8fafc;
}
body.light-theme header {
  background: rgba(255, 255, 255, 0.75);
}
body.light-theme .form-control {
  background: #ffffff;
  border-color: #cbd5e1;
}
body.light-theme .form-control:focus {
  border-color: var(--primary-color);
}
body.light-theme .custom-table th {
  background: #f1f5f9;
  color: #475569;
}
body.light-theme .custom-table tr:hover td {
  background: rgba(0, 0, 0, 0.01);
}
body.light-theme .meal-selection-item {
  background: #f8fafc;
}
body.light-theme .onboarding-overlay {
  background: #f8fafc;
}
body.light-theme .selectable-card:hover {
  background: #f8fafc;
}
body.light-theme .onboarding-img {
  background: rgba(16, 185, 129, 0.1);
}
body.light-theme .toast {
  background: #ffffff;
  color: #0f172a;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
}

/* Sleek Banner Custom Graphics Styling */
#main-banner-container {
  width: 100%;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-dark);
  margin-bottom: 25px;
}

#main-banner-container img {
  width: 100%;
  height: auto;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Full-Screen Onboarding Splash Screen CSS Styles */
.onboarding-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(2, 6, 23, 0.85);
  z-index: 100000;
  display: flex;
  justify-content: center;
  align-items: center;
  backdrop-filter: blur(8px);
}

.onboarding-slide {
  display: none;
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* Mobile-in-Desktop Wrapper for wider screens */
@media (min-width: 481px) {
  .onboarding-slide {
    width: 420px;
    height: 80vh;
    max-height: 800px;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 24px;
    border: 1px solid var(--border-dark);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.6);
    overflow: hidden;
  }
}

.onboarding-slide.active {
  display: block;
}

#slide-1 {
  background-image: radial-gradient(circle at center, rgba(16, 185, 129, 0.35) 0%, #020617 100%);
}
#slide-2 {
  background-image: radial-gradient(circle at center, rgba(59, 130, 246, 0.35) 0%, #020617 100%);
}
#slide-3 {
  background-image: radial-gradient(circle at center, rgba(139, 92, 246, 0.35) 0%, #020617 100%);
}

.onboarding-slide-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  background: linear-gradient(to bottom, rgba(2, 6, 23, 0.3) 0%, rgba(2, 6, 23, 0.65) 45%, rgba(2, 6, 23, 0.95) 100%);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 50px 30px;
  box-sizing: border-box;
}

.onboarding-header {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: center;
}

.onboarding-body {
  text-align: center;
  max-width: 600px;
  margin: 0 auto;
  padding: 20px;
}

.slide-title {
  font-size: 2.2rem;
  font-weight: 800;
  color: #ffffff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.6);
  margin-bottom: 15px;
}
body.rtl .slide-title {
  font-family: var(--font-ar);
}

.slide-desc {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.85);
  line-height: 1.6;
  text-shadow: 0 1px 5px rgba(0, 0, 0, 0.6);
}
body.rtl .slide-desc {
  font-family: var(--font-ar);
}

.onboarding-footer {
  display: flex;
  flex-direction: column;
  gap: 25px;
  align-items: center;
  width: 100%;
  max-width: 500px;
  margin: 0 auto;
}

.onboarding-dots {
  display: flex;
  gap: 8px;
  justify-content: center;
}

.onboarding-actions {
  display: flex;
  justify-content: space-between;
  width: 100%;
  align-items: center;
}

.onboarding-actions .btn {
  min-width: 110px;
  padding: 12px 24px !important;
  font-size: 1rem !important;
  font-weight: 700;
}

/* Premium Admin Dashboard Redesign */
.admin-dashboard-banner {
  background: linear-gradient(135deg, #60a5fa 0%, #3b82f6 100%);
  border-radius: 16px;
  padding: 24px 30px;
  color: #ffffff;
  margin-bottom: 30px;
  box-shadow: 0 10px 25px rgba(59, 130, 246, 0.15);
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  overflow: hidden;
}

.admin-dashboard-banner::before {
  content: '';
  position: absolute;
  top: -50px;
  right: -50px;
  width: 150px;
  height: 150px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
}

.admin-dashboard-banner h1 {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-ar);
}

.admin-dashboard-banner p {
  font-size: 0.95rem;
  opacity: 0.9;
  font-family: var(--font-ar);
}

/* Colored Border Cards */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.stats-card {
  background: var(--card-dark);
  border: 1px solid var(--border-dark);
  border-radius: 16px;
  padding: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: all 0.3s ease;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.stats-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.stats-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.stats-info h4 {
  font-size: 0.9rem;
  color: var(--text-dark-secondary);
  font-weight: 600;
  font-family: var(--font-ar);
}

.stats-info .value {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-dark-primary);
}

.stats-icon-circle {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
}

/* Themed card modifiers */
.card-theme-purple {
  border-right: 5px solid #a855f7 !important;
}
.card-theme-purple .stats-icon-circle {
  background: rgba(168, 85, 247, 0.1);
  color: #a855f7;
}

.card-theme-skyblue {
  border-right: 5px solid #06b6d4 !important;
}
.card-theme-skyblue .stats-icon-circle {
  background: rgba(6, 182, 212, 0.1);
  color: #06b6d4;
}

.card-theme-green {
  border-right: 5px solid #10b981 !important;
}
.card-theme-green .stats-icon-circle {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
}

.card-theme-blue {
  border-right: 5px solid #3b82f6 !important;
}
.card-theme-blue .stats-icon-circle {
  background: rgba(59, 130, 246, 0.1);
  color: #3b82f6;
}

.card-theme-red {
  border-right: 5px solid #ef4444 !important;
}
.card-theme-red .stats-icon-circle {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
}

.card-theme-indigo {
  border-right: 5px solid #6366f1 !important;
}
.card-theme-indigo .stats-icon-circle {
  background: rgba(99, 102, 241, 0.1);
  color: #6366f1;
}

/* Interactive Calendar Date Picker Widget */
.calendar-widget-container {
  border: 1px solid var(--border-dark);
  border-radius: var(--radius-md);
  padding: 15px;
  background: rgba(255, 255, 255, 0.02);
  margin-top: 8px;
}

body.light-theme .calendar-widget-container {
  background: #f8fafc;
}

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

.calendar-ctrls span {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text-dark-primary);
  font-family: var(--font-ar);
}

.calendar-ctrls button {
  background: transparent;
  border: 1px solid var(--border-dark);
  color: var(--text-dark-primary);
  padding: 4px 8px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 0.8rem;
  transition: var(--transition);
}

.calendar-ctrls button:hover {
  background: var(--border-dark);
}

.calendar-days-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 5px;
  text-align: center;
}

.calendar-day-header {
  font-size: 0.75rem;
  font-weight: bold;
  color: var(--text-dark-secondary);
  padding: 6px 0;
  border-bottom: 1px solid var(--border-dark);
  font-family: var(--font-ar);
}

.calendar-day-cell {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-dark-primary);
  cursor: pointer;
  border-radius: 50%;
  transition: var(--transition);
}

.calendar-day-cell:hover {
  background: var(--border-dark);
}

.calendar-day-cell.selected {
  background: var(--primary-color) !important;
  color: #ffffff !important;
  box-shadow: 0 2px 8px var(--primary-glow);
}

.calendar-day-cell.today {
  border: 2px solid var(--secondary-color);
}

.calendar-day-cell.disabled {
  opacity: 0.25;
  cursor: not-allowed;
  pointer-events: none;
}

/* Selected Date Tags Box */
.selected-tags-box {
  margin-top: 15px;
  padding-top: 15px;
  border-top: 1px dashed var(--border-dark);
}

.selected-tags-box h5 {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-dark-primary);
  margin-bottom: 10px;
  font-family: var(--font-ar);
}

.selected-tags-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.date-tag-chip {
  background: rgba(59, 130, 246, 0.12);
  border: 1px solid rgba(59, 130, 246, 0.3);
  color: #3b82f6;
  border-radius: 50px;
  padding: 4px 10px;
  font-size: 0.75rem;
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-ar);
}

body.light-theme .date-tag-chip {
  background: #eff6ff;
  border-color: #bfdbfe;
}

.date-tag-chip .remove-btn {
  background: transparent;
  border: none;
  color: #3b82f6;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: bold;
  line-height: 1;
  padding: 0;
  display: inline-flex;
}

.date-tag-chip .remove-btn:hover {
  color: #ef4444;
}
