/* ═══════════════════════════════════════════════════════════
   نظام النادي الصيفي - المكونات المشتركة
   ═══════════════════════════════════════════════════════════ */

/* ════════════════════════════════════
   الأزرار (Buttons)
   ════════════════════════════════════ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-6);
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-semibold);
  line-height: 1.5;
  border: 2px solid transparent;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition-base);
  text-decoration: none;
  white-space: nowrap;
  user-select: none;
  position: relative;
  overflow: hidden;
}

.btn::after {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(255,255,255,0.15);
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.btn:hover::after {
  opacity: 1;
}

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

.btn-primary {
  background: var(--gradient-primary);
  color: var(--text-white);
  box-shadow: var(--shadow-primary);
}

.btn-primary:hover {
  box-shadow: 0 6px 28px rgba(0, 119, 182, 0.35);
  transform: translateY(-2px);
}

.btn-secondary {
  background: var(--gradient-secondary);
  color: var(--text-white);
  box-shadow: var(--shadow-orange);
}

.btn-secondary:hover {
  box-shadow: 0 6px 28px rgba(255, 107, 53, 0.35);
  transform: translateY(-2px);
}

.btn-success {
  background: var(--gradient-success);
  color: var(--text-white);
  box-shadow: var(--shadow-success);
}

.btn-success:hover {
  box-shadow: 0 6px 28px rgba(6, 214, 160, 0.35);
  transform: translateY(-2px);
}

.btn-danger {
  background: var(--gradient-warm);
  color: var(--text-white);
}

.btn-danger:hover {
  box-shadow: 0 6px 28px rgba(239, 71, 111, 0.3);
  transform: translateY(-2px);
}

.btn-outline {
  background: transparent;
  border-color: var(--ocean-blue);
  color: var(--ocean-blue);
}

.btn-outline:hover {
  background: var(--ocean-blue-50);
  transform: translateY(-1px);
}

.btn-outline-orange {
  background: transparent;
  border-color: var(--orange);
  color: var(--orange);
}

.btn-outline-orange:hover {
  background: var(--orange-50);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
}

.btn-ghost:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.btn-sm {
  padding: var(--space-2) var(--space-4);
  font-size: var(--font-size-sm);
  border-radius: var(--radius-md);
}

.btn-lg {
  padding: var(--space-4) var(--space-8);
  font-size: var(--font-size-lg);
  border-radius: var(--radius-xl);
}

.btn-block {
  width: 100%;
}

.btn-icon {
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: var(--radius-lg);
}

.btn-icon-sm {
  width: 36px;
  height: 36px;
  padding: 0;
  border-radius: var(--radius-md);
  font-size: var(--font-size-sm);
}

/* ── زر عائم (FAB) ── */
.btn-floating {
  position: fixed;
  bottom: var(--space-8);
  left: var(--space-8);
  width: 64px;
  height: 64px;
  border-radius: var(--radius-full);
  background: var(--gradient-secondary);
  color: var(--text-white);
  font-size: var(--font-size-xl);
  box-shadow: var(--shadow-xl), var(--shadow-orange);
  z-index: var(--z-sticky);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
  animation: floatPulse 3s ease-in-out infinite;
}

.btn-floating:hover {
  transform: scale(1.1) translateY(-4px);
  box-shadow: var(--shadow-2xl), 0 8px 32px rgba(255, 107, 53, 0.4);
}

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

/* الزر مع حالة التحميل */
.btn-loading {
  pointer-events: none;
  opacity: 0.7;
}
.btn-loading::before {
  content: '';
  width: 18px;
  height: 18px;
  border: 2px solid transparent;
  border-top-color: currentColor;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  margin-left: var(--space-2);
}

/* ════════════════════════════════════
   البطاقات (Cards)
   ════════════════════════════════════ */
.card {
  background: var(--bg-white);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  transition: all var(--transition-base);
}

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

.card-glass {
  background: var(--glass-bg);
  backdrop-filter: var(--glass-blur);
  -webkit-backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-glass);
  transition: all var(--transition-base);
}

.card-glass:hover {
  box-shadow: var(--shadow-lg);
  border-color: rgba(255,255,255,0.5);
}

.card-gradient {
  background: var(--gradient-primary);
  color: var(--text-white);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-primary);
  position: relative;
  overflow: hidden;
}

.card-gradient::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 60%);
  animation: shimmer 8s linear infinite;
}

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

.card-gradient-warm {
  background: var(--gradient-secondary);
  color: var(--text-white);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-orange);
  position: relative;
  overflow: hidden;
}

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

.card-title {
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-bold);
  color: var(--text-primary);
  margin-bottom: 0;
}

.card-body {
  padding: var(--space-2) 0;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-3);
  margin-top: var(--space-4);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border-light);
}

/* ════════════════════════════════════
   النماذج (Forms)
   ════════════════════════════════════ */
.form-group {
  margin-bottom: var(--space-5);
  position: relative;
}

.form-label {
  display: block;
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--text-primary);
  margin-bottom: var(--space-2);
}

.form-label .required {
  color: var(--danger);
  margin-right: var(--space-1);
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: var(--space-3) var(--space-4);
  font-family: var(--font-family);
  font-size: var(--font-size-base);
  color: var(--text-primary);
  background: var(--bg-white);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-lg);
  transition: all var(--transition-base);
  direction: rtl;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  border-color: var(--ocean-blue);
  box-shadow: 0 0 0 4px var(--ocean-blue-50);
  outline: none;
}

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

.form-input.error {
  border-color: var(--danger);
  box-shadow: 0 0 0 4px var(--danger-bg);
}

.form-input.success {
  border-color: var(--success);
}

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

.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%234A5568' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: left var(--space-4) center;
  padding-left: var(--space-10);
  cursor: pointer;
}

.form-hint {
  font-size: var(--font-size-xs);
  color: var(--text-muted);
  margin-top: var(--space-1);
}

.form-error {
  font-size: var(--font-size-xs);
  color: var(--danger);
  margin-top: var(--space-1);
  display: flex;
  align-items: center;
  gap: var(--space-1);
}

.form-error i {
  font-size: 12px;
}

/* حقل مع أيقونة */
.input-icon-wrapper {
  position: relative;
}

.input-icon-wrapper .form-input {
  padding-right: var(--space-10);
}

.input-icon-wrapper .input-icon {
  position: absolute;
  right: var(--space-4);
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: var(--font-size-md);
  transition: color var(--transition-fast);
  pointer-events: none;
}

.input-icon-wrapper:focus-within .input-icon {
  color: var(--ocean-blue);
}

/* ════════════════════════════════════
   الشارات (Badges)
   ════════════════════════════════════ */
.badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-1);
  padding: var(--space-1) var(--space-3);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-semibold);
  border-radius: var(--radius-full);
  white-space: nowrap;
}

.badge-primary {
  background: var(--ocean-blue-100);
  color: var(--ocean-blue-dark);
}

.badge-success {
  background: var(--success-bg);
  color: #047857;
}

.badge-warning {
  background: var(--warning-bg);
  color: #B45309;
}

.badge-danger {
  background: var(--danger-bg);
  color: #BE123C;
}

.badge-info {
  background: var(--info-bg);
  color: #0369A1;
}

.badge-orange {
  background: var(--orange-50);
  color: var(--orange-dark);
}

.badge-dot::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  flex-shrink: 0;
}

.badge-lg {
  padding: var(--space-2) var(--space-4);
  font-size: var(--font-size-sm);
}

/* ════════════════════════════════════
   التنبيهات (Alerts)
   ════════════════════════════════════ */
.alert {
  display: flex;
  align-items: flex-start;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  border-radius: var(--radius-lg);
  font-size: var(--font-size-sm);
  border: 1px solid transparent;
  margin-bottom: var(--space-4);
}

.alert i {
  font-size: var(--font-size-lg);
  flex-shrink: 0;
  margin-top: 2px;
}

.alert-success {
  background: var(--success-bg);
  border-color: rgba(6, 214, 160, 0.2);
  color: #047857;
}

.alert-warning {
  background: var(--warning-bg);
  border-color: rgba(255, 209, 102, 0.3);
  color: #B45309;
}

.alert-error {
  background: var(--danger-bg);
  border-color: rgba(239, 71, 111, 0.2);
  color: #BE123C;
}

.alert-info {
  background: var(--info-bg);
  border-color: rgba(0, 180, 216, 0.2);
  color: #0369A1;
}

/* ════════════════════════════════════
   النوافذ المنبثقة (Modals)
   ════════════════════════════════════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: var(--z-modal-backdrop);
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
  padding: var(--space-4);
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-content {
  background: var(--bg-white);
  border-radius: var(--radius-xl);
  padding: var(--space-8);
  max-width: 520px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-2xl);
  transform: scale(0.9) translateY(20px);
  transition: transform var(--transition-spring);
}

.modal-overlay.active .modal-content {
  transform: scale(1) translateY(0);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-6);
}

.modal-title {
  font-size: var(--font-size-xl);
  font-weight: var(--font-weight-bold);
  margin-bottom: 0;
}

.modal-close {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: all var(--transition-fast);
  cursor: pointer;
  background: none;
  border: none;
  font-size: var(--font-size-lg);
}

.modal-close:hover {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.modal-footer {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-3);
  margin-top: var(--space-6);
  padding-top: var(--space-4);
  border-top: 1px solid var(--border-light);
}

/* ════════════════════════════════════
   الجداول (Tables)
   ════════════════════════════════════ */
.table-container {
  overflow-x: auto;
  border-radius: var(--radius-xl);
  border: 1px solid var(--border-light);
  background: var(--bg-white);
}

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

.table thead {
  background: var(--bg-secondary);
}

.table th {
  padding: var(--space-4) var(--space-5);
  text-align: right;
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--text-secondary);
  white-space: nowrap;
  border-bottom: 2px solid var(--border-color);
}

.table td {
  padding: var(--space-4) var(--space-5);
  text-align: right;
  font-size: var(--font-size-sm);
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-light);
  vertical-align: middle;
}

.table tbody tr {
  transition: background var(--transition-fast);
}

.table tbody tr:hover {
  background: var(--ocean-blue-50);
}

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

/* ════════════════════════════════════
   بطاقات الإحصائيات (Stat Cards)
   ════════════════════════════════════ */
.stat-card {
  background: var(--bg-white);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  display: flex;
  align-items: flex-start;
  gap: var(--space-4);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}

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

.stat-card::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 4px;
  height: 100%;
  border-radius: 0 var(--radius-xl) var(--radius-xl) 0;
}

.stat-card.blue::after { background: var(--gradient-primary); }
.stat-card.orange::after { background: var(--gradient-secondary); }
.stat-card.green::after { background: var(--gradient-success); }
.stat-card.yellow::after { background: var(--gradient-gold); }

.stat-icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--font-size-xl);
  flex-shrink: 0;
}

.stat-icon.blue {
  background: var(--ocean-blue-100);
  color: var(--ocean-blue);
}

.stat-icon.orange {
  background: var(--orange-100);
  color: var(--orange);
}

.stat-icon.green {
  background: var(--mint-100);
  color: var(--mint);
}

.stat-icon.yellow {
  background: var(--yellow-50);
  color: var(--yellow-dark);
}

.stat-info {
  flex: 1;
}

.stat-value {
  font-size: var(--font-size-2xl);
  font-weight: var(--font-weight-extrabold);
  color: var(--text-primary);
  line-height: 1.2;
}

.stat-label {
  font-size: var(--font-size-sm);
  color: var(--text-muted);
  margin-top: var(--space-1);
}

/* ════════════════════════════════════
   الخط الزمني (Timeline)
   ════════════════════════════════════ */
.timeline {
  position: relative;
  padding-right: var(--space-8);
}

.timeline::before {
  content: '';
  position: absolute;
  right: 14px;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--gradient-primary);
  border-radius: var(--radius-full);
}

.timeline-item {
  position: relative;
  padding-bottom: var(--space-6);
  padding-right: var(--space-6);
}

.timeline-item::before {
  content: '';
  position: absolute;
  right: calc(-1 * var(--space-8) + 8px);
  top: 6px;
  width: 14px;
  height: 14px;
  background: var(--ocean-blue);
  border: 3px solid var(--bg-white);
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
  z-index: 1;
}

.timeline-item.active::before {
  background: var(--mint);
  box-shadow: 0 0 0 4px var(--mint-50);
  animation: pulse-dot 2s ease-in-out infinite;
}

.timeline-item.completed::before {
  background: var(--success);
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-time {
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-semibold);
  color: var(--ocean-blue);
  margin-bottom: var(--space-1);
}

.timeline-content {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  padding: var(--space-4);
  box-shadow: var(--shadow-xs);
  border: 1px solid var(--border-light);
}

.timeline-title {
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--text-primary);
  margin-bottom: var(--space-1);
}

.timeline-desc {
  font-size: var(--font-size-xs);
  color: var(--text-muted);
  margin-bottom: 0;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 4px var(--mint-50); }
  50% { box-shadow: 0 0 0 8px rgba(6, 214, 160, 0.05); }
}

/* ════════════════════════════════════
   علامات التبويب (Tabs)
   ════════════════════════════════════ */
.tabs {
  display: flex;
  gap: var(--space-1);
  background: var(--bg-secondary);
  border-radius: var(--radius-lg);
  padding: var(--space-1);
  margin-bottom: var(--space-6);
  overflow-x: auto;
}

.tab-btn {
  padding: var(--space-3) var(--space-5);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
  color: var(--text-muted);
  background: transparent;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-base);
  white-space: nowrap;
  font-family: var(--font-family);
}

.tab-btn:hover {
  color: var(--text-primary);
  background: rgba(255,255,255,0.5);
}

.tab-btn.active {
  background: var(--bg-white);
  color: var(--ocean-blue);
  box-shadow: var(--shadow-sm);
}

.tab-content {
  display: none;
}

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

/* ════════════════════════════════════
   الإشعارات المنبثقة (Toasts)
   ════════════════════════════════════ */
.toast-container {
  position: fixed;
  top: var(--space-6);
  left: 50%;
  transform: translateX(-50%);
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  pointer-events: none;
  max-width: 440px;
  width: 90%;
}

.toast {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  border-right: 4px solid transparent;
  transform: translateY(-20px);
  opacity: 0;
  animation: toastIn 0.4s var(--transition-spring) forwards;
  pointer-events: auto;
  font-size: var(--font-size-sm);
}

.toast.success { border-right-color: var(--success); }
.toast.error { border-right-color: var(--danger); }
.toast.warning { border-right-color: var(--warning); }
.toast.info { border-right-color: var(--ocean-blue); }

.toast-icon {
  font-size: var(--font-size-lg);
  flex-shrink: 0;
}

.toast.success .toast-icon { color: var(--success); }
.toast.error .toast-icon { color: var(--danger); }
.toast.warning .toast-icon { color: var(--warning); }
.toast.info .toast-icon { color: var(--ocean-blue); }

.toast-message { flex: 1; color: var(--text-primary); }

.toast-close {
  cursor: pointer;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: var(--font-size-base);
  padding: var(--space-1);
  transition: color var(--transition-fast);
}

.toast-close:hover {
  color: var(--text-primary);
}

.toast.removing {
  animation: toastOut 0.3s ease forwards;
}

@keyframes toastIn {
  to { transform: translateY(0); opacity: 1; }
}

@keyframes toastOut {
  to { transform: translateX(100px); opacity: 0; }
}

/* ════════════════════════════════════
   المؤشر الدوار (Spinner)
   ════════════════════════════════════ */
.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border-color);
  border-top-color: var(--ocean-blue);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

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

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

.loading-overlay {
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(8px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
  z-index: var(--z-modal);
}

.loading-text {
  font-size: var(--font-size-md);
  font-weight: var(--font-weight-semibold);
  color: var(--text-secondary);
}

/* ════════════════════════════════════
   صندوق البحث (Search)
   ════════════════════════════════════ */
.search-box {
  position: relative;
}

.search-box .form-input {
  padding-right: var(--space-10);
  border-radius: var(--radius-full);
  background: var(--bg-secondary);
  border-color: transparent;
}

.search-box .form-input:focus {
  background: var(--bg-white);
  border-color: var(--ocean-blue);
}

.search-box .search-icon {
  position: absolute;
  right: var(--space-4);
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
}

/* ════════════════════════════════════
   الأيقونات التفاعلية
   ════════════════════════════════════ */
.icon-interactive {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-lg);
  color: var(--text-muted);
  transition: all var(--transition-base);
  cursor: pointer;
  font-size: var(--font-size-lg);
}

.icon-interactive:hover {
  background: var(--ocean-blue-50);
  color: var(--ocean-blue);
  transform: scale(1.1);
}

.icon-interactive.active {
  background: var(--ocean-blue-100);
  color: var(--ocean-blue);
}

/* ════════════════════════════════════
   شريط التقدم (Progress)
   ════════════════════════════════════ */
.progress-bar {
  height: 8px;
  background: var(--bg-secondary);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  border-radius: var(--radius-full);
  background: var(--gradient-primary);
  transition: width 0.5s ease;
}

.progress-fill.orange { background: var(--gradient-secondary); }
.progress-fill.green { background: var(--gradient-success); }

/* ════════════════════════════════════
   القائمة المنسدلة (Dropdown)
   ════════════════════════════════════ */
.dropdown {
  position: relative;
  display: inline-block;
}

.dropdown-menu {
  position: absolute;
  top: calc(100% + var(--space-2));
  left: 0;
  min-width: 200px;
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--border-light);
  padding: var(--space-2);
  z-index: var(--z-dropdown);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: all var(--transition-base);
}

.dropdown-menu.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  font-size: var(--font-size-sm);
  color: var(--text-primary);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: background var(--transition-fast);
  border: none;
  background: none;
  width: 100%;
  text-align: right;
  font-family: var(--font-family);
}

.dropdown-item:hover {
  background: var(--ocean-blue-50);
  color: var(--ocean-blue);
}

.dropdown-divider {
  height: 1px;
  background: var(--border-light);
  margin: var(--space-2) 0;
}

/* ════════════════════════════════════
   بطاقة النقاط (Gamification)
   ════════════════════════════════════ */
.points-card {
  background: var(--gradient-gold);
  border-radius: var(--radius-xl);
  padding: var(--space-6);
  color: var(--text-white);
  position: relative;
  overflow: hidden;
  text-align: center;
}

.points-card::before {
  content: '';
  position: absolute;
  top: -30%;
  left: -30%;
  width: 160%;
  height: 160%;
  background: radial-gradient(circle at 30% 40%, rgba(255,255,255,0.15), transparent 50%);
}

.points-value {
  font-size: var(--font-size-4xl);
  font-weight: var(--font-weight-extrabold);
  line-height: 1;
  text-shadow: 0 2px 8px rgba(0,0,0,0.15);
  position: relative;
}

.points-star {
  font-size: var(--font-size-3xl);
  color: var(--yellow);
  filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
  animation: starBounce 2s ease-in-out infinite;
  display: inline-block;
}

@keyframes starBounce {
  0%, 100% { transform: scale(1) rotate(0deg); }
  25% { transform: scale(1.15) rotate(5deg); }
  50% { transform: scale(1) rotate(0deg); }
  75% { transform: scale(1.1) rotate(-3deg); }
}

.points-label {
  font-size: var(--font-size-md);
  font-weight: var(--font-weight-semibold);
  margin-top: var(--space-2);
  opacity: 0.9;
  position: relative;
}

/* ════════════════════════════════════
   حالة GPS
   ════════════════════════════════════ */
.gps-status {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-full);
  font-size: var(--font-size-sm);
  font-weight: var(--font-weight-semibold);
}

.gps-status.inside {
  background: var(--success-bg);
  color: #047857;
}

.gps-status.outside {
  background: var(--danger-bg);
  color: #BE123C;
}

.gps-pin {
  font-size: var(--font-size-md);
  animation: gpsPing 2s ease-in-out infinite;
}

.gps-status.inside .gps-pin { color: var(--success); }
.gps-status.outside .gps-pin { color: var(--danger); }

@keyframes gpsPing {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.2); }
}

/* ════════════════════════════════════
   صفحة فارغة (Empty State)
   ════════════════════════════════════ */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--space-16) var(--space-4);
  text-align: center;
}

.empty-state-icon {
  font-size: 4rem;
  color: var(--text-muted);
  opacity: 0.4;
  margin-bottom: var(--space-4);
}

.empty-state-title {
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-semibold);
  color: var(--text-secondary);
  margin-bottom: var(--space-2);
}

.empty-state-desc {
  font-size: var(--font-size-sm);
  color: var(--text-muted);
  max-width: 360px;
}

/* ════════════════════════════════════
   الصورة الرمزية (Avatar)
   ════════════════════════════════════ */
.avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: var(--font-weight-bold);
  font-size: var(--font-size-sm);
  color: var(--text-white);
  flex-shrink: 0;
}

.avatar-sm { width: 32px; height: 32px; font-size: var(--font-size-xs); }
.avatar-lg { width: 56px; height: 56px; font-size: var(--font-size-lg); }
.avatar-xl { width: 72px; height: 72px; font-size: var(--font-size-xl); }

.avatar.blue { background: var(--gradient-primary); }
.avatar.orange { background: var(--gradient-secondary); }
.avatar.green { background: var(--gradient-success); }
.avatar.gold { background: var(--gradient-gold); }

/* ════════════════════════════════════
   Toggle Switch
   ════════════════════════════════════ */
.toggle-switch {
  position: relative;
  display: inline-block;
  width: 52px;
  height: 28px;
}

.toggle-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.toggle-slider {
  position: absolute;
  inset: 0;
  background: var(--bg-secondary);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-base);
}

.toggle-slider::before {
  content: '';
  position: absolute;
  top: 2px;
  right: 2px;
  width: 20px;
  height: 20px;
  background: var(--bg-white);
  border-radius: 50%;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

.toggle-switch input:checked + .toggle-slider {
  background: var(--gradient-primary);
  border-color: var(--ocean-blue);
}

.toggle-switch input:checked + .toggle-slider::before {
  right: 26px;
}
