/* إعدادات عامة احترافية */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
  }
  
  html, body {
    font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Tahoma, "Noto Sans Arabic", sans-serif;
    background-color: var(--bg);
    color: var(--text);
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background-color var(--transition-fast), color var(--transition-fast);
    height: 100%;
    display: flex;
    flex-direction: column;
}

body {
    line-height: 1.7;
    font-size: 16px;
    padding: 0;
    margin: 0;
    background: linear-gradient(135deg, var(--bg-gradient-start), var(--bg-gradient-end));
    flex: 1;
    display: flex;
    flex-direction: column;
  }
  
  /* الحاوية الأساسية */
  .container {
    width: 100%;
    max-width: 1200px;
    padding: 0 16px;
    margin: 0 auto;
  }
  
  /* الهيدر الاحترافي */
.top-bar {
  background: rgba(var(--surface-rgb), 0.95);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
}

.top-bar.scrolled {
  box-shadow: var(--shadow-md);
  background: rgba(var(--surface-rgb), 0.98);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  max-width: 1200px;
  margin: 0 auto;
}

.logo-title {
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: transform var(--transition-fast);
}

.logo-title:hover {
  transform: scale(1.02);
}

.site-logo-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-hover));
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: var(--font-weight-bold);
  font-size: 16px;
  color: white;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-normal);
}

.site-logo-circle:hover {
  transform: rotate(15deg) scale(1.05);
  box-shadow: var(--shadow-lg);
}

.site-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.site-name {
  font-size: 18px;
  font-weight: var(--font-weight-semibold);
  color: var(--text);
  letter-spacing: -0.5px;
}

.site-caption {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: var(--font-weight-medium);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.main-nav {
  display: flex;
  gap: 24px;
  font-size: 14px;
  align-items: center;
}

.main-nav a {
  color: var(--text-muted);
  text-decoration: none;
  padding: 8px 12px;
  border-radius: var(--radius-md);
  font-weight: var(--font-weight-medium);
  transition: all var(--transition-fast);
  position: relative;
}

.main-nav a:hover {
  color: var(--primary);
  background: var(--primary-light);
  transform: translateY(-1px);
}

.main-nav a[aria-current="page"] {
  color: var(--primary);
  background: var(--primary-light);
  font-weight: var(--font-weight-semibold);
}

.main-nav a::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 50%;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: all var(--transition-fast);
  transform: translateX(-50%);
}

.main-nav a:hover::after,
.main-nav a[aria-current="page"]::after {
  width: 80%;
}
  
  /* قسم البطل الاحترافي */
.hero {
  padding: 80px 0 60px;
  background: linear-gradient(135deg, var(--bg-gradient-start), var(--bg-gradient-end));
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 30% 50%, rgba(var(--primary-rgb), 0.1) 0%, transparent 50%),
              radial-gradient(circle at 70% 30%, rgba(var(--accent-rgb), 0.08) 0%, transparent 50%);
  pointer-events: none;
}

.hero-content {
  display: flex;
  gap: 48px;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-text {
  flex: 2;
  min-width: 320px;
}

.hero h1 {
  font-size: clamp(28px, 6vw, 48px);
  font-weight: var(--font-weight-bold);
  margin-bottom: 16px;
  color: var(--text);
  line-height: 1.2;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, var(--primary), var(--primary-hover));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero h2 {
  color: var(--primary);
  font-weight: var(--font-weight-semibold);
}

.hero p {
  color: var(--text-muted);
}

.hero-subtitle {
  font-size: clamp(14px, 2.4vw, 18px);
  color: var(--text-muted);
  max-width: 720px;
  margin-bottom: 24px;
  line-height: 1.6;
  font-weight: var(--font-weight-medium);
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 32px;
}

.hero-tags span {
  font-size: 14px;
  border-radius: 999px;
  padding: 8px 16px;
  background: linear-gradient(135deg, var(--primary-light), rgba(var(--primary-rgb), 0.1));
  color: var(--primary);
  border: 1px solid rgba(var(--primary-rgb), 0.2);
  font-weight: var(--font-weight-medium);
  backdrop-filter: blur(10px);
  transition: all var(--transition-fast);
}

.hero-tags span:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 40px;
}
  
  /* أزرار احترافية */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-lg);
  padding: 12px 24px;
  font-size: 14px;
  font-weight: var(--font-weight-medium);
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}

.btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
  transition: left var(--transition-slow);
}

.btn:hover::before {
  left: 100%;
}

.btn.primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-hover));
  color: white;
  box-shadow: var(--shadow-md);
  border: none;
}

.btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
  filter: brightness(1.1);
}

.btn.primary:active {
  transform: translateY(0);
}

.btn.outline {
  border-color: var(--primary);
  color: var(--primary);
  background: transparent;
  box-shadow: var(--shadow-sm);
}

.btn.outline:hover {
  background: var(--primary);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn.small {
  padding: 8px 16px;
  font-size: 13px;
  border-radius: var(--radius-md);
}

.btn.ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--text-muted);
  box-shadow: none;
}

.btn.ghost:hover {
  background: var(--surface-elevated);
  color: var(--text);
  transform: translateY(-1px);
  box-shadow: var(--shadow-sm);
  box-shadow: 0 8px 20px rgba(245,158,11,0.12);
  }
  
/* التأثيرات معرفة مسبقاً للأزرار */
  
/* تمت إزالة التكرارات لضمان اعتماد المتغيرات الأساسية عبر الثيمات */
  
  /* إحصائيات البطل الاحترافية */
.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.stat-box {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  min-width: 140px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-fast);
  position: relative;
  overflow: hidden;
}

.stat-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
}

.stat-box:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.stat-number {
  display: block;
  font-size: 24px;
  font-weight: var(--font-weight-bold);
  color: var(--primary);
  margin-bottom: 4px;
  background: linear-gradient(135deg, var(--primary), var(--primary-hover));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.stat-label {
  font-size: 12px;
  color: var(--frame-text);
  font-weight: var(--font-weight-medium);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
  
/* بطاقة البروفايل الاحترافية */
.profile-card {
  background: var(--surface);
  border-radius: var(--radius-xl);
  padding: 32px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
  flex: 1;
  min-width: 260px;
  max-width: 380px;
}

.profile-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
}

.profile-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary);
}

.profile-image {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  margin: 0 auto 24px;
  overflow: hidden;
  border: 4px solid var(--primary-light);
  box-shadow: var(--shadow-md);
  transition: all var(--transition-fast);
}

.profile-card:hover .profile-image {
  border-color: var(--primary);
  transform: scale(1.05);
}

.profile-name {
  font-size: 24px;
  font-weight: var(--font-weight-bold);
  margin-bottom: 8px;
  color: var(--text);
  text-align: center;
}

.profile-title {
  font-size: 16px;
  color: var(--primary);
  font-weight: var(--font-weight-medium);
  margin-bottom: 16px;
  text-align: center;
}

.profile-bio {
  font-size: 14px;
  color: var(--frame-text);
  text-align: center;
  margin-bottom: 24px;
  line-height: 1.6;
}

.profile-social {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 24px;
}

.profile-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--surface-elevated);
  color: var(--text-muted);
  text-decoration: none;
  transition: all var(--transition-fast);
  border: 1px solid var(--border);
}

.profile-social a:hover {
  background: var(--primary);
  color: white;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.profile-contact {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.profile-contact a {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  padding: 8px 12px;
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
}

.profile-contact a:hover {
  background: var(--surface-elevated);
  color: var(--primary);
  transform: translateX(4px);
}
  
  /* الأقسام العامة الاحترافية */
.section {
  padding: 80px 0;
  position: relative;
}

.section:nth-child(even) {
  background: linear-gradient(135deg, var(--bg-gradient-start), var(--bg-gradient-end));
}

.section.section-alt {
  background: linear-gradient(135deg, var(--surface), var(--surface-elevated));
}
  
  .section-header {
    text-align: center;
    margin-bottom: 60px;
    position: relative;
  }
  
  .section-header::before {
    content: '';
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    border-radius: 2px;
  }
  
  .section-title {
    font-size: 40px;
    font-weight: var(--font-weight-bold);
    color: var(--text);
    margin-bottom: 16px;
    position: relative;
    display: inline-block;
  }
  
  .section-title::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary), transparent);
    border-radius: 1px;
  }
  
  .section-subtitle {
    font-size: 18px;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
  }
  
.section-description {
  font-size: 16px;
  color: var(--text-muted);
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
  line-height: 1.7;
  margin-top: 16px;
}

.section-text {
  font-size: 16px;
  color: var(--text-muted);
  line-height: 1.7;
  max-width: 720px;
}
  
/* شبكات احترافية */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
  margin-top: 40px;
}

/* أدوات شبكة عامة */
.grid {
  display: grid;
  gap: 24px;
}

.grid.two-cols {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid.three-cols {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 900px) {
  .grid.two-cols,
  .grid.three-cols {
    grid-template-columns: 1fr;
  }
}

.cards-grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 20px;
}

.cards-grid-2 {
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 32px;
}
  
  /* بطاقات احترافية */
.cards-grid .card {
  background: var(--surface);
  border-radius: var(--radius-xl);
  padding: 32px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
  color: var(--frame-text);
}

  .cards-grid .card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition-normal);
  }

  .cards-grid .card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary);
  }

  .cards-grid .card:hover::before {
    transform: scaleX(1);
  }
  
.cards-grid .card h3 {
  color: var(--primary);
}

.cards-grid .card h4 {
  color: rgba(var(--primary-rgb), 0.85);
}
  
/* تعتمد الألوان على متغيرات الثيم تلقائياً */
  
  .card h3 {
    font-size: 15px;
    margin-bottom: 8px;
  }
  
  .wide-card {
    grid-column: span 2;
  }
  
  /* القوائم */
  .list {
    list-style: none;
    padding-right: 10px;
    font-size: 13px;
  }
  
  .list li {
    position: relative;
    margin-bottom: 6px;
    padding-right: 14px;
  }
  
.list li::before {
  content: "•";
  position: absolute;
  right: 0;
  top: 0;
  color: var(--primary);
}
  
  .inline-list {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 16px;
  }
  
  /* التاغات للقطاعات */
  .tags-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 10px;
  }
  
.tag {
  font-size: 12px;
  border-radius: 999px;
  padding: 6px 12px;
  border: 1px solid var(--border);
  background: rgba(var(--surface-rgb), 0.08);
  color: var(--text-muted);
}
  
  /* التستيمونيالز */
  .testimonial p {
    font-size: 13px;
  }
  
  .testimonial p:first-child {
    margin-bottom: 4px;
  }
  
  /* قسم CTA */
.section-cta {
  text-align: center;
  background: linear-gradient(180deg, var(--surface), var(--surface-elevated));
}
  
  .section-cta .section-text {
    margin: 0 auto 16px;
  }
  
  .cta-center {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
  }
  
  /* الفوتر */
.footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  padding: 18px 0 22px;
  color: var(--text-muted);
  margin-top: auto;
  width: 100%;
}
  
  .footer-container {
    text-align: center;
    font-size: 11px;
    opacity: 0.7;
  }
  
  .footer-note {
    margin-top: 4px;
  }
  
  /* متغيرات احترافية (ثيم فاتح افتراضي) */
:root {
  --bg: #ffffff;
  --bg-gradient-start: #f8fafc;
  --bg-gradient-end: #ffffff;
  --surface: #ffffff;
  --surface-elevated: #f8fafc;
  --surface-rgb: 255, 255, 255;
  --text: #1e293b;
  --text-muted: #64748b;
  --text-subtle: #94a3b8;
  --primary: #3b82f6;
  --primary-hover: #2563eb;
  --primary-light: #dbeafe;
  --primary-rgb: 59, 130, 246;
  --primary-contrast: #ffffff;
  --frame-text: var(--text);
  --accent: #f59e0b;
  --accent-hover: #d97706;
  --accent-rgb: 245, 158, 11;
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  --card-shadow: rgba(2,6,23,0.06);
  --transition-fast: 200ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-normal: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --font-weight-normal: 400;
  --font-weight-medium: 500;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
}
  
  /* ثيم داكن احترافي - محسّن للوضوح والتباين */
:root[data-theme="dark"], [data-theme="dark"] {
  --bg: #0f172a;
  --bg-gradient-start: #0a0f1f;
  --bg-gradient-end: #141b2d;
  --surface: #1a2332;
  --surface-elevated: #242d3d;
  --surface-rgb: 26, 35, 50;
  --text: #f0f4f8;
  --text-muted: #cbd5e1;
  --text-subtle: #94a3b8;
  --primary: #60a5fa;
  --primary-hover: #3b82f6;
  --primary-light: rgba(96, 165, 250, 0.15);
  --primary-rgb: 96, 165, 250;
  --frame-text: #e0e7ff;
  --accent: #fbbf24;
  --accent-hover: #f59e0b;
  --accent-rgb: 251, 191, 36;
  --success: #34d399;
  --warning: #fbbf24;
  --error: #f87171;
  --border: #2d3748;
  --border-light: #3d4556;
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.5);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.6), 0 2px 4px -1px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.7), 0 4px 6px -2px rgba(0, 0, 0, 0.6);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.8), 0 10px 10px -5px rgba(0, 0, 0, 0.7);
  --card-shadow: rgba(0, 0, 0, 0.4);
}
  
  /* تطبيق المتغيرات على العناصر الأساسية */
html, body {
  background-color: var(--bg);
  color: var(--text);
  transition: background-color var(--transition-fast), color var(--transition-fast);
}

img { max-width: 100%; height: auto; display: block; }
  
  /* مثال لتعديل الشريط العلوي والأزرار لاستخدام المتغيرات */
.top-bar {
  background: linear-gradient(180deg, var(--surface), rgba(255,255,255,0.02));
  border-bottom: 1px solid var(--border);
  box-shadow: 0 6px 18px var(--card-shadow);
  transition: background var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}
  
  /* أزرار عامة - تعتمد على التعريفات الاحترافية أعلاه */
  /* تمت إزالة التعريف المتكرر لضمان تناسق المظهر */
  
  /* تحسين مظهر زر تبديل الثيم */
.theme-toggle {
  --tt-size: 44px;
  --tt-bg-light: linear-gradient(180deg, rgba(255,255,255,0.7), rgba(255,255,255,0.18));
  --tt-bg-dark: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01));
  --tt-border: rgba(0,0,0,0.06);
  --tt-shadow-light: 0 8px 18px rgba(2,6,23,0.06);
  --tt-shadow-dark: 0 8px 24px rgba(2,6,23,0.45);

  display: inline-grid;
  place-items: center;
  width: var(--tt-size);
  height: var(--tt-size);
  padding: 0;
  border-radius: 12px;
  border: 1px solid var(--tt-border);
  background: var(--tt-bg-light);
  box-shadow: var(--tt-shadow-light);
  cursor: pointer;
  transition: background var(--transition-fast), transform 160ms ease, box-shadow var(--transition-fast), border-color var(--transition-fast);
  -webkit-tap-highlight-color: transparent;
}

/* أيقونة داخل الزر */
.theme-toggle .icon {
  display: inline-block;
  font-size: 18px;
  line-height: 1;
  transition: transform 240ms cubic-bezier(.2,.9,.2,1), opacity 160ms ease;
  will-change: transform, opacity;
}

/* تحرّكات خفيفة عند التحويم والضغط */
.theme-toggle:hover { transform: translateY(-3px); }
.theme-toggle:active { transform: translateY(0); }
.theme-toggle:focus { outline: none; }

/* دعم الوصول - تركيز مرئي */
.theme-toggle:focus-visible {
  box-shadow: 0 0 0 4px rgba(14,165,133,0.12), var(--tt-shadow-light);
  border-color: rgba(14,165,133,0.28);
}

/* مظهر الزر عندما يكون الثيم داكن (يعتمد على html[data-theme="dark"]) */
[data-theme="dark"] .theme-toggle {
  background: var(--tt-bg-dark);
  border-color: rgba(255,255,255,0.06);
  box-shadow: var(--tt-shadow-dark);
}

/* حركة بسيطة للايقونة بناءً على الثيم */
html[data-theme="dark"] .theme-toggle .icon {
  transform: rotate(-18deg) scale(1.05);
  opacity: 0.95;
}
html:not([data-theme="dark"]) .theme-toggle .icon {
  transform: rotate(0deg) scale(1);
  opacity: 1;
}

/* اجعل الزر متجاوباً عند الحجم الصغير */
@media (max-width: 480px) {
  .theme-toggle { --tt-size: 40px; border-radius: 10px; }
  .theme-toggle .icon { font-size: 16px; }
}

/* تصميم متجاوب احترافي */
  @media (max-width: 768px) {
    .hero-content {
      flex-direction: column;
      text-align: center;
    }
    
    .hero h1 {
      font-size: 36px;
    }
    
    .hero-subtitle {
      font-size: 16px;
    }
    
    .hero-stats {
      justify-content: center;
    }
    
    .stat-box {
      min-width: 120px;
      padding: 16px 20px;
    }
    
    .profile-card {
      max-width: 100%;
    }
    
    .section-title {
      font-size: 32px;
    }
    
    .cards-grid {
      grid-template-columns: 1fr;
      gap: 20px;
    }
    
    .cards-grid-3,
    .cards-grid-2 {
      grid-template-columns: 1fr;
    }
    
    .container {
      padding: 0 16px;
    }
    
    .top-bar .container {
      padding: 0 12px;
    }
    
    .main-nav {
      gap: 8px;
    }
    
    .main-nav a {
      padding: 6px 10px;
      font-size: 13px;
    }
  }
  
  @media (max-width: 480px) {
    .hero {
      padding: 60px 0 40px;
    }
    
    .hero h1 {
      font-size: 28px;
    }
    
    .hero-tags {
      justify-content: center;
    }
    
    .hero-cta {
      flex-direction: column;
      align-items: center;
    }
    
    .btn {
      width: 100%;
      max-width: 280px;
    }
    
    .section {
      padding: 60px 0;
    }
    
    .section-title {
      font-size: 28px;
    }
    
    .section-subtitle {
      font-size: 16px;
    }
    
    .card {
      padding: 24px;
    }
    
    .profile-card {
      padding: 24px;
    }
    
    .profile-image {
      width: 100px;
      height: 100px;
    }
    
    .profile-name {
      font-size: 20px;
    }
    
    .profile-title {
      font-size: 14px;
    }
  }
  
  /* تحسينات موبايل متقدمة (احترافية) */
@media (max-width: 600px) {
  /* هيدر أكثر إحكاما: شعار أصغر ونص مختصر */
  .header-container {
    padding: 10px 12px;
    gap: 8px;
  }
  .site-logo-circle { width: 40px; height: 40px; font-size: 14px; }
  .site-text .site-name { font-size: 16px; }
  .site-text .site-caption { display: none; } /* يخفي التسمية الثانوية لتوفير المساحة */

  /* إظهار زر الهامبرغر وحسّن المساحة اللمسية */
  .nav-actions { gap: 8px; }
  .nav-toggle { display: inline-flex; width:44px; height:44px; }

  /* جعل mobile-nav يغطي كامل الشاشة تقريباً لواجهة تطبيق */
  .mobile-nav {
    align-items: stretch;
    justify-content: flex-end;
  }
  .mobile-nav-inner {
    width: 100%;
    max-width: 100%;
    padding: 20px;
    border-radius: 0;
    box-shadow: none;
  }
  .mobile-nav nav a {
    font-size: 16px;
    padding: 14px 16px;
    border-radius: 8px;
  }

  /* قلّل الحشوة العامة للأقسام للحفاظ على المحتوى مرئياً */
  .section { padding: 36px 0; }
  .hero { padding: 36px 0 20px; }
  .hero h1 { font-size: 28px; }
  .hero-subtitle { font-size: 14px; max-width: 100%; }

  /* صف البطل يُعرض عمودياً ومُوسّط */
  .hero-content { flex-direction: column; align-items: center; text-align: center; gap: 20px; }
  .hero-text { order: 2; }
  .hero-card { order: 1; }

  /* أزرار CTA بعرض كامل لمس أسهل */
  .hero-cta, .cta-center { width: 100%; display:flex; flex-direction:column; gap:12px; align-items:stretch; }
  .hero-cta .btn, .cta-center .btn { width: 100%; max-width: 100%; padding: 14px; font-size: 15px; }

  /* بطاقات التستيمونيالز عرض كامل وتوسيط نص */
  #testimonials .grid { grid-template-columns: 1fr; gap: 16px; }
  #testimonials .card { max-width: 100%; padding: 18px; text-align: right; }

  /* بطاقات عامة أصغر ومسافات داخلية أقل */
  .cards-grid .card, .course-card, .location-card { padding: 18px; }

  /* تحسين شبكة الأماكن */
  .locations-grid { grid-template-columns: 1fr; gap: 14px; }
  .location-card .actions { justify-content: flex-start; gap: 8px; }

  /* تقليل ارتفاع الصور الاحتياطي لعرض أسرع */
  .event-image { height: 200px; }
  .event-title { font-size: 18px; }

  /* Back to top أصغر على الموبايل */
  .back-to-top { width:44px; height:44px; font-size:18px; bottom:20px; right:20px; }

  /* تحسينات الوصول: زيادة مساحة اللمس للأزرار الصغيرة */
  .btn.small, .theme-toggle, .nav-toggle { min-width:44px; min-height:44px; }

  /* منع تجاوز النصوص الطويلة */
  .section-text, .event-desc, .profile-desc { word-break: break-word; }

  /* Footer تباعد مناسب */
  .footer { padding: 16px 0; font-size: 13px; }
}

/* Mobile polish: professional phone layout */
@media (max-width: 480px) {
  html { font-size: 16px; }
  .container { padding: 0 14px; }

  /* Header */
  .header-container { padding: 8px 12px; gap: 8px; align-items: center; }
  .site-logo-circle { width: 38px; height: 38px; font-size: 13px; }
  .site-text .site-name { font-size: 15px; }
  .site-caption { display: none; } /* توفير المساحة */
  .main-nav { display: flex; flex-wrap: wrap; gap: 8px; }
  .nav-toggle { display: none; }

  /* Mobile nav full-width sheet */
  .mobile-nav-inner { width: 100%; max-width: 100%; padding: 18px; border-radius: 0; box-shadow: none; }
  .mobile-nav nav a { font-size: 16px; padding: 14px 16px; border-radius: 8px; }

  /* Hero compact + stacked */
  .hero { padding: 28px 0 20px; }
  .hero-content { flex-direction: column; gap: 16px; text-align: center; align-items: center; }
  .hero h1 { font-size: 26px; }
  .hero-subtitle { font-size: 14px; max-width: 100%; }
  .hero-card { width: 100%; max-width: 360px; margin: 0 auto; }
  .profile-card { padding: 18px; max-width: 340px; }

  /* CTA: full-width buttons, large tap targets */
  .hero-cta, .cta-center { flex-direction: column; align-items: stretch; gap: 12px; width: 100%; }
  .btn { width: 100%; padding: 14px; font-size: 15px; border-radius: 12px; }
  .btn.small { width: auto; align-self: center; }

  /* Stats stacked for clarity */
  .hero-stats { flex-direction: column; gap: 12px; align-items: center; width: 100%; }
  .stat-box { width: 100%; max-width: 420px; min-width: auto; }

  /* Cards & grids compact */
  .cards-grid { grid-template-columns: 1fr; gap: 14px; }
  .cards-grid .card, .course-card, .location-card { padding: 16px; border-radius: 14px; }

  /* Testimonials single column and centered */
  #testimonials .grid { grid-template-columns: 1fr; gap: 14px; }
  #testimonials .card { margin: 0 auto; max-width: 540px; text-align: center; }

  /* Events - images smaller and content tighter */
  .events-grid { grid-template-columns: 1fr; gap: 16px; }
  .event-image { height: 180px; border-radius: 12px; }
  .event-content { padding: 16px; }

  /* General spacing, footer */
  .section { padding: 28px 0; }
  .footer { padding: 14px 0; font-size: 13px; }
  body { line-height: 1.65; font-size: 15px; }

  /* Touch targets */
  .theme-toggle, .nav-toggle, .btn { min-height: 48px; min-width: 48px; }

  /* Readability / wrapping */
  .section-text, p, li { word-break: break-word; hyphens: auto; }
}

/* Phablet adjustments (481–768) */
@media (min-width: 481px) and (max-width: 768px) {
  .hero h1 { font-size: 34px; }
  .hero-subtitle { font-size: 16px; }
  .btn { padding: 12px 18px; max-width: 420px; }
  .cards-grid { grid-template-columns: repeat(2, 1fr); gap: 18px; }
  #testimonials .grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
  .event-image { height: 220px; }
}

/* تحسينات احترافية نهائية */

/* تأثيرات بصرية متقدمة */
.glow-effect {
  box-shadow: 0 0 20px rgba(var(--primary-rgb), 0.3);
}

.glow-effect:hover {
  box-shadow: 0 0 30px rgba(var(--primary-rgb), 0.5);
}

/* تأثيرات النص المتدرج */
.gradient-text {
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* تأثيرات الزجاج */
.glass-effect {
  background: rgba(var(--surface-rgb), 0.8);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* تأثيرات التحويل ثلاثي الأبعاد */
.perspective-card {
  transform-style: preserve-3d;
  transition: transform 0.6s ease;
}

.perspective-card:hover {
  transform: perspective(1000px) rotateY(5deg) rotateX(5deg) translateZ(20px);
}

/* تأثيرات الإضاءة */
.light-effect {
  position: relative;
  overflow: hidden;
}

.light-effect::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(var(--primary-rgb), 0.1) 0%, transparent 70%);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.light-effect:hover::before {
  opacity: 1;
}

/* تأثيرات التموج */
.ripple-effect {
  position: relative;
  overflow: hidden;
}

.ripple-effect::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(var(--primary-rgb), 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.ripple-effect:hover::after {
  width: 300px;
  height: 300px;
}

/* تحسينات التباين والوضوح */
.high-contrast {
  filter: contrast(1.1) saturate(1.1);
}

/* تأثيرات التظليل المتقدمة */
.advanced-shadow {
  box-shadow: 
    0 1px 1px rgba(0,0,0,0.05),
    0 2px 2px rgba(0,0,0,0.05),
    0 4px 4px rgba(0,0,0,0.05),
    0 8px 8px rgba(0,0,0,0.05),
    0 16px 16px rgba(0,0,0,0.05);
}

.advanced-shadow:hover {
  box-shadow: 
    0 1px 1px rgba(0,0,0,0.08),
    0 2px 2px rgba(0,0,0,0.08),
    0 4px 4px rgba(0,0,0,0.08),
    0 8px 8px rgba(0,0,0,0.08),
    0 16px 16px rgba(0,0,0,0.08),
    0 32px 32px rgba(0,0,0,0.08);
}

/* تحسينات النصوص */
.text-shadow {
  text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.text-glow {
  text-shadow: 0 0 10px rgba(var(--primary-rgb), 0.5);
}

/* تأثيرات الحدود المتدرجة */
.border-gradient {
  position: relative;
  background: var(--surface);
  border-radius: var(--radius-lg);
}

.border-gradient::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(45deg, var(--primary), var(--accent), var(--primary));
  border-radius: var(--radius-lg);
  z-index: -1;
  animation: borderRotate 3s linear infinite;
}

@keyframes borderRotate {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* تحسينات الأداء */
.will-animate {
  will-change: transform, opacity;
}

.gpu-accelerated {
  transform: translateZ(0);
  backface-visibility: hidden;
  perspective: 1000px;
}
.language-switching {
  animation: fadeInUp 0.3s ease-out;
}

/* تأثير ناعم على النصوص عند تغيير اللغة */
[data-i18n] {
  transition: opacity 0.2s ease, transform 0.2s ease;
}

/* تأثير بصري على زر تغيير اللغة أثناء التبديل */
.lang-toggle.switching .lang-label {
  animation: pulse 0.3s ease-in-out;
}

.theme-switching, .theme-switching * {
  transition: color var(--transition-fast), background-color var(--transition-fast), border-color var(--transition-fast);
}

@media (prefers-reduced-motion: reduce) {
  .theme-switching, .theme-switching * {
    transition: none !important;
  }
}

@keyframes pulse {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(0.9); opacity: 0.7; }
  100% { transform: scale(1); opacity: 1; }
}

/* تأثير على اتجاه النص عند التبديل بين RTL/LTR */
html[lang="ar"] [data-i18n],
html[lang="en"] [data-i18n] {
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* === Typography Improvements === */
html, body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", sans-serif;
  letter-spacing: -0.3px;
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.3;
}

h1 { font-size: 2.2rem; }
h2 { font-size: 1.8rem; }
h3 { font-size: 1.2rem; }

/* === Improved Spacing & Layout === */
.container {
  padding: 0 20px;
}

.section {
  padding: 60px 0;
}

.section-title {
  font-size: 2rem;
  margin-bottom: 24px;
  font-weight: 700;
}

/* === Card Enhancements === */
.card, .profile-card, .location-card, .stat-box {
  transition: all 280ms cubic-bezier(0.23, 1, 0.320, 1);
  position: relative;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, transparent, rgba(255,255,255,0.05));
  pointer-events: none;
  opacity: 0;
  transition: opacity 280ms ease;
}

.card:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 40px var(--card-shadow);
  border-color: rgba(14,165,133,0.15);
}

.card:hover::before { opacity: 1; }

/* === Button Enhancements === */
.btn {
  position: relative;
  overflow: hidden;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: all 240ms cubic-bezier(0.23, 1, 0.320, 1);
}

.btn::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  transform: translate(-50%, -50%);
  transition: width 480ms, height 480ms;
}

.btn:active::after {
  width: 300px;
  height: 300px;
}

.btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(245,158,11,0.3);
}

.btn.outline:hover {
  border-color: var(--primary);
  background: rgba(14,165,133,0.08);
}

/* === Navigation Improvements === */
.main-nav a {
  position: relative;
  transition: color 240ms ease;
}

.main-nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0; right: 0;
  height: 2px;
  background: var(--primary);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 280ms cubic-bezier(0.23, 1, 0.320, 1);
}

.main-nav a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}

/* === Scroll Animations === */
@keyframes slideInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.card {
  animation: slideInUp 600ms cubic-bezier(0.23, 1, 0.320, 1) backwards;
}

.section:nth-child(2) .card { animation-delay: 100ms; }
.section:nth-child(3) .card { animation-delay: 150ms; }
.section:nth-child(4) .card { animation-delay: 200ms; }

/* === Theme Toggle Button Enhanced === */
.theme-toggle {
  position: relative;
  z-index: 1;
}

.theme-toggle .icon {
  display: inline-block;
  animation: rotateIcon 600ms cubic-bezier(0.23, 1, 0.320, 1);
}

@keyframes rotateIcon {
  from { transform: rotate(-180deg); opacity: 0; }
  to { transform: rotate(0deg); opacity: 1; }
}

/* === Language Toggle Button === */
.lang-toggle {
  font-size: 13px;
  transition: all 240ms ease;
}

.lang-toggle:hover {
  transform: scale(1.08);
}

/* === Hero Section Enhanced === */
.hero {
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -10%;
  width: 400px;
  height: 400px;
  background: radial-gradient(circle, rgba(14,165,133,0.1), transparent);
  pointer-events: none;
  animation: float 8s ease-in-out infinite;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0); }
  50% { transform: translate(20px, -20px); }
}

/* === Stat Boxes Enhanced === */
.stat-box {
  text-align: center;
  transition: all 320ms cubic-bezier(0.23, 1, 0.320, 1);
}

.stat-box:hover {
  transform: translateY(-6px) scale(1.02);
}

.stat-number {
  animation: slideInUp 800ms cubic-bezier(0.23, 1, 0.320, 1) 200ms backwards;
}

/* === Responsive Typography === */
@media (max-width: 768px) {
  h1 { font-size: 1.8rem; }
  h2 { font-size: 1.4rem; }
  .section-title { font-size: 1.6rem; }
  .section { padding: 40px 0; }
  .container { padding: 0 12px; }
  .cards-grid { gap: 16px; }
}

/* === Back to Top Button === */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: 30px;
  width: 50px;
  height: 50px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  box-shadow: 0 8px 24px rgba(14,165,133,0.3);
  transition: all 240ms ease;
  z-index: 99;
}

.back-to-top.show {
  display: flex;
  animation: slideInUp 300ms ease;
}

.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(14,165,133,0.4);
}

/* === تحسينات الوضوح في الثيم الداكن === */
[data-theme="dark"] {
  --text: #f0f4f8;
  --text-muted: #cbd5e1;
}

[data-theme="dark"] .section-text,
[data-theme="dark"] p,
[data-theme="dark"] li,
[data-theme="dark"] .list li {
  color: var(--text-muted);
}

[data-theme="dark"] .card,
[data-theme="dark"] .profile-card,
[data-theme="dark"] .stat-box,
[data-theme="dark"] .location-card {
  background: var(--surface);
  color: var(--text);
}

[data-theme="dark"] .card p,
[data-theme="dark"] .profile-card p,
[data-theme="dark"] .stat-box p,
[data-theme="dark"] .location-card p,
[data-theme="dark"] .card li,
[data-theme="dark"] .profile-card li {
  color: var(--text-muted);
}

[data-theme="dark"] .card h3,
[data-theme="dark"] .profile-card h2,
[data-theme="dark"] .stat-box {
  color: var(--text);
}

[data-theme="dark"] .hero h1 {
  background: linear-gradient(135deg, #60a5fa, #a78bfa);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

[data-theme="dark"] .hero-subtitle {
  color: var(--text-muted);
}

[data-theme="dark"] .profile-desc,
[data-theme="dark"] .section-text {
  color: var(--text-muted);
}

[data-theme="dark"] .tag {
  background: rgba(96, 165, 250, 0.08);
  color: var(--text-muted);
  border-color: rgba(96, 165, 250, 0.2);
}

[data-theme="dark"] .tag:hover {
  background: rgba(96, 165, 250, 0.12);
  color: #60a5fa;
}

[data-theme="dark"] .testimonial p {
  color: var(--text-muted);
}

[data-theme="dark"] .hero-tags span {
  background: rgba(96, 165, 250, 0.12);
  color: #60a5fa;
  border-color: rgba(96, 165, 250, 0.25);
}

[data-theme="dark"] .hero-tags span:hover {
  background: rgba(96, 165, 250, 0.18);
  color: #93c5fd;
}

[data-theme="dark"] .stat-label {
  color: var(--text-subtle);
}

[data-theme="dark"] .stat-number {
  background: linear-gradient(135deg, #60a5fa, #a78bfa);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

[data-theme="dark"] .location-card .venue,
[data-theme="dark"] .location-card .dates {
  color: var(--text-muted);
}

[data-theme="dark"] .location-card .desc {
  color: var(--text-muted);
}

[data-theme="dark"] .btn.outline {
  color: var(--text);
  border-color: rgba(96, 165, 250, 0.3);
}

[data-theme="dark"] .btn.outline:hover {
  background: rgba(96, 165, 250, 0.1);
  color: #60a5fa;
}

[data-theme="dark"] .btn.ghost {
  color: var(--text-muted);
  border-color: rgba(96, 165, 250, 0.2);
}

[data-theme="dark"] .btn.ghost:hover {
  background: rgba(96, 165, 250, 0.08);
  color: #60a5fa;
}

[data-theme="dark"] .site-name,
[data-theme="dark"] .site-caption {
  color: var(--text);
}

[data-theme="dark"] .main-nav a {
  color: var(--text-muted);
}

[data-theme="dark"] .main-nav a:hover {
  color: #60a5fa;
  background: rgba(96, 165, 250, 0.1);
}

[data-theme="dark"] .footer {
  color: var(--text-subtle);
  border-top-color: var(--border);
}

[data-theme="dark"] .section-title {
  color: var(--text);
}

[data-theme="dark"] .section-subtitle {
  color: var(--text-muted);
}

/* تحسين التعاريض للبطاقات */
[data-theme="dark"] .card::before {
  background: linear-gradient(135deg, transparent, rgba(96, 165, 250, 0.05));
}

[data-theme="dark"] .profile-card::before {
  background: linear-gradient(90deg, #60a5fa, #a78bfa);
}

[data-theme="dark"] .stat-box::before {
  background: linear-gradient(90deg, #60a5fa, #fbbf24);
}

/* تأكد من أن جميع النصوص في البطاقات ظاهرة */
[data-theme="dark"] .cards-grid .card *:not(h1):not(h2):not(h3):not(h4):not(h5):not(h6) {
  color: var(--text-muted);
}

[data-theme="dark"] .cards-grid .card h3 {
  color: #60a5fa;
}

/* تحسين تباين الأزرار في الثيم الداكن */
[data-theme="dark"] .btn.primary {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: white;
  box-shadow: 0 8px 20px rgba(59, 130, 246, 0.3);
}

[data-theme="dark"] .btn.primary:hover {
  background: linear-gradient(135deg, #60a5fa, #3b82f6);
  box-shadow: 0 12px 32px rgba(96, 165, 250, 0.4);
}

/* === قسم الدورات التدريبية === */
.courses-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 24px;
  margin-top: 40px;
}

.course-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 28px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
  position: relative;
  overflow: hidden;
}

.course-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--transition-normal);
}

.course-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.course-card:hover::before {
  transform: scaleX(1);
}

.course-title {
  font-size: 18px;
  font-weight: var(--font-weight-bold);
  color: var(--primary);
  margin: 0;
  line-height: 1.4;
}

.course-list {
  list-style: none;
  padding: 0;
}

.course-list li {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.7;
  padding: 8px 0;
  border-bottom: 1px solid rgba(var(--border), 0.3);
  display: flex;
  align-items: flex-start;
}

.course-list li:last-child {
  border-bottom: none;
}

.course-list li::before {
  content: "▸";
  color: var(--primary);
  margin-right: 10px;
  margin-left: 0;
  flex-shrink: 0;
}

/* تحسينات الثيم الداكن */
[data-theme="dark"] .course-card {
  background: var(--surface);
  border-color: var(--border);
}

[data-theme="dark"] .course-card:hover {
  border-color: var(--primary);
  background: linear-gradient(135deg, var(--surface), rgba(96, 165, 250, 0.05));
}

[data-theme="dark"] .course-title {
  color: #60a5fa;
}

[data-theme="dark"] .course-list li {
  color: var(--text-muted);
}

/* === قسم المعارض والمؤتمرات === */
.events-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 28px;
  margin-top: 40px;
}

.event-card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
  position: relative;
  display: flex;
  flex-direction: column;
}

.event-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}

.event-image {
  width: 100%;
  height: 280px;
  border-radius: 12px 12px 0 0;
  overflow: hidden;
  display: block;
  background: var(--surface);
}

.event-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 400ms var(--transition-normal), opacity 300ms ease;
}

/* تأثير تحويم بسيط على الصورة */
.event-card:hover .event-image img {
  transform: scale(1.03);
}

.event-content {
  padding: 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  flex: 1;
}

.event-title {
  font-size: 20px;
  font-weight: var(--font-weight-bold);
  color: var(--primary);
  margin: 0;
  line-height: 1.4;
}

.event-meta {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.event-date,
.event-location {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: var(--font-weight-medium);
  display: flex;
  align-items: center;
  gap: 8px;
}

.event-date::before {
  content: "📅";
  font-size: 16px;
}

.event-location::before {
  content: "📍";
  font-size: 16px;
}

.event-desc {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.7;
  margin: 0;
  flex: 1;
}

.event-attendees {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: auto;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: linear-gradient(135deg, rgba(var(--primary-rgb), 0.1), rgba(var(--accent-rgb), 0.1));
  border: 1px solid rgba(var(--primary-rgb), 0.2);
  border-radius: 999px;
  font-size: 13px;
  font-weight: var(--font-weight-medium);
  color: var(--primary);
}

.badge::before {
  content: "👥";
  font-size: 14px;
}

/* تحسينات الثيم الداكن */
[data-theme="dark"] .event-card {
  background: var(--surface);
  border-color: var(--border);
}

[data-theme="dark"] .event-card:hover {
  border-color: var(--primary);
  background: linear-gradient(135deg, var(--surface), rgba(96, 165, 250, 0.05));
}

[data-theme="dark"] .event-title {
  color: #60a5fa;
}

[data-theme="dark"] .event-date,
[data-theme="dark"] .event-location,
[data-theme="dark"] .event-desc {
  color: var(--text-muted);
}

[data-theme="dark"] .badge {
  background: rgba(96, 165, 250, 0.1);
  border-color: rgba(96, 165, 250, 0.2);
  color: #60a5fa;
}

/* Responsive */
@media (max-width: 1000px) {
  .events-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .events-grid {
    grid-template-columns: 1fr;
  }
  
  .event-content {
    padding: 20px;
  }
  
  .event-title {
    font-size: 18px;
  }
  
  .event-image {
    height: 240px;
  }
}

/* آراء العملاء - توسيط احترافي */
  #testimonials {
    text-align: center;
  }

  #testimonials .section-title {
    margin: 0 auto 40px;
    display: block;
  }

  /* جعل بطاقات آراء العملاء عمود واحد دائماً */
  #testimonials .grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
  }

  #testimonials .grid {
    justify-items: center;
  }

  #testimonials .card {
    max-width: 500px;
    margin: 0 auto;
  }

  /* قسم الاتصال - توسيط احترافي */
  #contact {
    text-align: center;
  }

  #contact .section-title {
    margin: 0 auto 24px;
    display: block;
  }

  #contact .section-text {
    margin: 0 auto 32px;
    display: block;
  }

  .cta-center {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 16px;
  }
  
  /* تحسين العرض على الهاتف */
  @media (max-width: 768px) {
    #testimonials .grid {
      display: grid;
      grid-template-columns: 1fr;
      gap: 20px;
    }

    #testimonials .card {
      max-width: 100%;
      padding: 24px;
    }

    #contact .section-title {
      font-size: 28px;
    }

    #contact .section-text {
      font-size: 14px;
    }

    .cta-center {
      gap: 12px;
    }

    .btn {
      width: 100%;
      max-width: 100%;
    }

    .btn.small {
      width: auto;
      max-width: auto;
    }
  }

  @media (max-width: 480px) {
    #testimonials .card {
      padding: 20px;
    }

    #testimonials .card p {
      font-size: 13px;
    }

    #contact {
      padding: 40px 0;
    }

    #contact .section-title {
      font-size: 24px;
      margin-bottom: 16px;
    }

    #contact .section-text {
      font-size: 13px;
      line-height: 1.6;
    }

    .cta-center {
      flex-direction: column;
      align-items: stretch;
    }

    .cta-center .btn {
      width: 100%;
    }
  }

  /* توسيط متقدم على الشاشات الكبيرة */
  @media (min-width: 1200px) {
    #testimonials .section-title {
      max-width: 100%;
    }

    #testimonials .cards-grid {
      max-width: 1200px;
      margin: 0 auto;
    }

    #contact {
      max-width: 100%;
    }

    #contact .section-title,
    #contact .section-text {
      max-width: 800px;
    }

    .cta-center {
      max-width: 600px;
      margin: 0 auto;
    }
  }

/* Skip link (for accessibility, appears on focus) */
.skip-link {
  position: absolute;
  top: -40px;
  left: 12px;
  background: var(--primary);
  color: #fff;
  padding: 8px 12px;
  border-radius: 8px;
  z-index: 120;
  transition: top 180ms ease, opacity 180ms ease;
  opacity: 0;
}
.skip-link:focus {
  top: 12px;
  opacity: 1;
  outline: none;
}

/* Visible helper used by animations.js */
.visible {
  opacity: 1 !important;
  transform: translateY(0) !important;
}

/* Mobile nav sheet improvements */
.mobile-nav {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.35);
  align-items: flex-end;
  justify-content: center;
  z-index: 999;
  -webkit-tap-highlight-color: transparent;
}
.mobile-nav.open {
  display: flex;
}
.mobile-nav-inner {
  width: 100%;
  max-width: 720px;
  background: var(--surface);
  border-radius: 16px 16px 0 0;
  padding: 18px;
  box-shadow: 0 -8px 40px rgba(2,6,23,0.12);
  transform: translateY(0);
}

/* Nav toggle (hamburger) */
.nav-toggle {
  display: none; /* shown via media queries already */
  background: none;
  border: 1px solid transparent;
  padding: 8px;
  border-radius: 10px;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
}
.nav-toggle .icon { font-size: 20px; }

/* Profile avatar (placeholder style) */
.profile-avatar {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(var(--primary-rgb),0.12), rgba(var(--accent-rgb),0.06));
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
  font-weight: 700;
  color: var(--primary);
  font-size: 28px;
  border: 4px solid var(--primary-light);
  box-shadow: var(--shadow-md);
}

/* Focus-visible improvements for accessibility */
:focus {
  outline: none;
}
:focus-visible {
  box-shadow: 0 0 0 4px rgba(59,130,246,0.12);
  border-radius: 8px;
}

/* Ensure mobile sheet respects reduced-motion */
@media (prefers-reduced-motion: reduce) {
  .mobile-nav-inner, .mobile-nav, .card, .btn {
    transition: none !important;
    animation: none !important;
  }
}

/* ضمان اتجاه المستند يطابق لغة المستند */
html[lang="en"] { direction: ltr; }
html[lang="ar"] { direction: rtl; }

/* تحسين مظهر mobile nav links لسهولة التمرير واللمس */
.mobile-nav-inner nav a {
  display: block;
  padding: 14px 18px;
  font-size: 18px;
  border-radius: 10px;
  color: var(--text);
  margin-bottom: 8px;
}

/* تباعد أفضل بين أعمدة البطاقات على الشاشات الكبيرة */
@media (min-width: 1200px) {
  .cards-grid { gap: 28px; grid-template-columns: repeat(3, 1fr); }
  .courses-grid { grid-template-columns: repeat(3, minmax(320px, 1fr)); }
}

/* تحسين عرض بطاقات الأماكن والدورات ليبدو احترافياً على جميع الأجهزة */
.location-card, .course-card, .event-card {
  border-radius: 14px;
  padding: 18px;
  box-shadow: var(--shadow-sm);
  transition: transform 240ms ease, box-shadow 240ms ease;
}
.location-card:hover, .course-card:hover, .event-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
}

/* أنماط لصور الأماكن في بطاقات المواقع */
.loc-image {
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: var(--radius-md);
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-fast);
}

.loc-image:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-md);
}

[data-theme="dark"] .loc-image {
  box-shadow: var(--shadow-sm);
}

[data-theme="dark"] .loc-image:hover {
  box-shadow: var(--shadow-md);
}

.action-fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: var(--shadow-md);
  cursor: pointer;
  z-index: 1000;
  transition: transform 200ms ease, box-shadow 200ms ease;
}
.action-fab.top { top: 90px; bottom: auto; }
.action-fab:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.action-fab .icon { font-size: 24px; line-height: 1; }

.quick-actions {
  position: fixed;
  bottom: 24px;
  right: 92px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: 14px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(2,6,23,0.08);
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
  transition: opacity 200ms ease, transform 200ms ease;
  z-index: 999;
}
.quick-actions.top { top: 90px; bottom: auto; right: 92px; }
.quick-actions.open { opacity: 1; transform: translateY(0); pointer-events: auto; }

.quick-actions .chip {
  display: inline-flex;
  align-items: center;
  padding: 8px 12px;
  border-radius: 9999px;
  border: 1px solid rgba(2,6,23,0.12);
  background: transparent;
  color: var(--text);
  text-decoration: none;
  font-size: 14px;
  white-space: nowrap;
  transition: background 180ms ease, transform 180ms ease, box-shadow 180ms ease;
}
.quick-actions .chip:hover { background: rgba(var(--primary-rgb),0.08); transform: translateY(-2px); }

[dir="rtl"] .action-fab { left: 24px; right: auto; }
[dir="rtl"] .action-fab.top { left: 24px; right: auto; }
[dir="rtl"] .quick-actions { left: 92px; right: auto; }
[dir="rtl"] .quick-actions.top { left: 92px; right: auto; }

@media (max-width: 640px) {
  .quick-actions {
    max-width: calc(100vw - 130px);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }
}
