:root {
  --bg-main: #ffffff;
  --bg-surface: #fafaf9;
  --bg-card: #ffffff;
  --text-primary: #1c1917;
  --text-secondary: #44403c;
  --text-muted: #a8a29e;
  --primary: #1c1917;
  --accent: #00684a;
  --accent-soft: rgba(0, 104, 74, 0.08);
  --accent-yellow: #ffcc00;
  --glass-border: rgba(28, 25, 23, 0.08);
  --glass-shadow: 0 20px 50px -12px rgba(28, 25, 23, 0.05);
  --font-main: 'IBM Plex Sans Arabic', sans-serif;
  --font-heading: 'Playfair Display', serif;
  --spacing-section: 5rem;
  --container-width: 1200px;
  --transition-premium: 0.6s cubic-bezier(0.19, 1, 0.22, 1);
  --radius-lg: 20px;
}

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

html { background-color: #fcfcfc; scroll-behavior: smooth; }

body {
  font-family: var(--font-main);
  background-color: transparent;
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  direction: rtl;
  font-size: 16px;
}

.container {
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ─── Premium Cursor (Text-Reveal) ─── */
.cursor-dot,
.cursor-outline {
  position: fixed;
  top: 0;
  left: 0;
  transform: translate(-50%, -50%);
  z-index: 9999;
  pointer-events: none;
}

.cursor-dot {
  width: 8px;
  height: 8px;
  background-color: var(--accent);
  border-radius: 50%;
  transition: opacity 0.3s ease;
}

.cursor-outline {
  width: 40px;
  height: 40px;
  border: 2px solid var(--accent);
  border-radius: 50%;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
}

.cursor-text {
  position: absolute;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  white-space: nowrap;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

body:hover .cursor-outline.hovered {
  opacity: 1;
  width: auto;
  min-width: 80px;
  height: 40px;
  padding: 0 20px;
  background-color: #fff;
  border-radius: 20px;
  border-color: var(--accent);
}

body:hover .cursor-outline.hovered .cursor-text {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 768px) {
  .cursor-dot,
  .cursor-outline {
    display: none;
  }
}


/* ─── Noise Overlay ─── */
.noise {
  position: fixed; inset: 0; z-index: 9998;
  opacity: 0.04; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* ─── Background Blobs ─── */
.blob-container {
  position: fixed; inset: 0; z-index: 0;
  filter: blur(100px);
  pointer-events: none;
  background: radial-gradient(circle at center, rgba(255,255,255,0) 0%, #ffffff 92%);
}
.blob { opacity: 0.3; transform-origin: center; will-change: transform; }
/* blob positions are driven by GSAP in script.js */

main { position: relative; z-index: 1; }

/* ─── Typography ─── */
h1, h2, h3 { font-family: var(--font-heading); color: var(--accent); line-height: 1.2; }

.text-glow { color: var(--accent); display: inline-block; }
@supports (background-clip: text) or (-webkit-background-clip: text) {
  .text-glow {
    background: linear-gradient(135deg, #00684a, #10b981);
    -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent;
  }
}

/* ─── Buttons ─── */
.btn {
  padding: 0.875rem 1.75rem;
  border-radius: 8px; font-weight: 500; cursor: pointer;
  transition: var(--transition-premium);
  display: inline-flex; align-items: center; gap: 0.5rem;
  text-decoration: none; font-size: 0.95rem;
}
.btn-primary { background: var(--primary); color: #fff; border: none; }
.btn-primary:hover { background: var(--accent); transform: translateY(-2px); }

/* ─── Navbar ─── */
.navbar {
  position: fixed; top: 0; width: 100%; z-index: 1000;
  padding: 1.25rem 0;
  transition: var(--transition-premium);
}
.navbar.scrolled {
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: 0.85rem 0;
  border-bottom: 1px solid var(--glass-border);
}
.nav-container { display: flex; justify-content: space-between; align-items: center; gap: 1rem; }
.nav-links { display: flex; gap: 2rem; }
.nav-item { color: var(--text-secondary); font-weight: 500; text-decoration: none; transition: 0.3s; font-size: 0.95rem; }
.nav-item:hover { color: var(--accent); }
.nav-actions { display: flex; align-items: center; gap: 1rem; }

.logo-img { height: 34px; width: auto; object-fit: contain; transition: transform var(--transition-premium); }
.logo:hover .logo-img { transform: scale(1.05); }

/* Mobile Menu Button */
.mobile-menu-btn { display: none; background: none; border: 1px solid var(--glass-border); cursor: pointer; padding: 0.5rem 0.65rem; border-radius: 8px; color: var(--primary); line-height: 1; }

/* ─── Sections ─── */
section { padding: var(--spacing-section) 0; }
.section-header { text-align: center; max-width: 700px; margin: 0 auto 3rem; }
.section-title { font-size: clamp(1.8rem, 4vw, 2.8rem); margin-bottom: 1rem; }
.section-desc { color: var(--text-secondary); font-size: 1rem; line-height: 1.7; }

/* ─── Hero ─── */
.hero-compact {
  padding: 8rem 0 5rem;
  background: transparent;
  position: relative;
  /* FIX: was overflow:hidden which clipped the floating cards */
  overflow: visible;
}
.hero-compact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 4rem;
}
.compact-badge {
  display: inline-flex; align-items: center; gap: 0.6rem;
  padding: 0.45rem 1rem;
  background: var(--bg-surface);
  border: 1px solid var(--glass-border);
  border-radius: 100px;
  color: var(--accent); font-size: 0.8rem; font-weight: 700;
  margin-bottom: 1.5rem;
}
.compact-badge i { width: 14px; height: 14px; }

.compact-h1 {
  font-size: clamp(2rem, 4.5vw, 3.4rem) !important;
  font-weight: 800; line-height: 1.25;
  color: var(--primary); margin-bottom: 1.25rem;
}
.shine-pro {
  background: linear-gradient(120deg, var(--accent) 0%, var(--accent) 40%, #58d68d 50%, var(--accent) 60%, var(--accent) 100%);
  background-size: 200% auto;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shineAnimation 5s linear infinite;
}
@keyframes shineAnimation { to { background-position: 200% center; } }

.compact-p {
  font-size: 1rem; color: var(--text-secondary);
  line-height: 1.8; max-width: 520px; margin-bottom: 2rem;
}
.compact-actions { display: flex; gap: 0.875rem; flex-wrap: wrap; }

.btn-pro-primary {
  background: var(--primary); color: #fff;
  padding: 0.875rem 2rem; border-radius: 10px;
  font-weight: 700; text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 8px 20px rgba(0,0,0,0.08);
  font-size: 0.95rem;
}
.btn-pro-primary:hover { background: var(--accent); transform: translateY(-2px); box-shadow: 0 12px 25px rgba(0,104,74,0.15); }

.btn-pro-outline {
  padding: 0.875rem 2rem; border-radius: 10px;
  font-weight: 700; text-decoration: none;
  color: var(--primary); border: 1.5px solid var(--glass-border);
  transition: all 0.3s ease; font-size: 0.95rem;
}
.btn-pro-outline:hover { border-color: var(--accent); color: var(--accent); background: var(--bg-surface); }

/* Hero Visual */
.hero-compact-visual {
  position: relative; display: flex;
  justify-content: center; align-items: center;
}
.compact-card-stack { position: relative; width: 300px; height: 300px; }

.c-main-box {
  width: 220px; height: 220px;
  background: var(--bg-surface);
  border: 1px solid var(--glass-border);
  border-radius: 36px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 30px 70px rgba(0,0,0,0.05);
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
}
.compact-hero-logo { width: 110px; height: auto; object-fit: contain; filter: drop-shadow(0 8px 16px rgba(0,104,74,0.1)); }

.c-card {
  position: absolute; background: #fff;
  padding: 0.7rem 1rem; border-radius: 16px;
  display: flex; align-items: center; gap: 0.6rem;
  box-shadow: 0 12px 30px rgba(0,0,0,0.09);
  border: 1px solid rgba(0,0,0,0.03);
  z-index: 2; white-space: nowrap;
}
.c-card-1 { top: 2%; right: -20px; animation: float 5s ease-in-out infinite; }
.c-card-2 { bottom: 2%; left: -20px; animation: float 5s ease-in-out infinite 1.5s; }
/* c-card-3: transform set here, animation overridden by floatMid rule below */
.c-card-3 { top: 50%; left: -40px; transform: translateY(-50%); }
.c-card-4 { bottom: 22%; right: -45px; animation: float 7s ease-in-out infinite 2.5s; }

.c-icon { width: 28px; height: 28px; background: var(--accent-soft); color: var(--accent); border-radius: 7px; display: flex; align-items: center; justify-content: center; }
.c-icon i { width: 15px; height: 15px; }
.c-icon.gold { background: rgba(255,204,0,0.1); color: var(--accent-yellow); }
.c-icon.green { background: rgba(39,201,63,0.1); color: #27c93f; }
.c-icon.blue { background: rgba(59,130,246,0.1); color: #3b82f6; }
.c-text { font-weight: 700; font-size: 0.85rem; color: var(--primary); }

/* Float animations — use translateY only so they don't conflict with absolute positioning */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-12px); }
}
/* c-card-3 sits at top:50% with translateY(-50%) — use floatMid to preserve that */
.c-card-3 { animation: floatMid 6s ease-in-out infinite 0.5s; }
@keyframes floatMid {
  0%, 100% { transform: translateY(-50%); }
  50% { transform: translateY(calc(-50% - 12px)); }
}

/* ─── Mission Section ─── */
.mission-section { padding: 6rem 0; position: relative; z-index: 2; }

.mission-card {
  background: rgba(255,255,255,0.5);
  backdrop-filter: blur(40px); -webkit-backdrop-filter: blur(40px);
  border: 1px solid rgba(255,255,255,0.85);
  border-radius: 2.5rem; padding: 3.5rem 2.5rem;
  box-shadow: 0 30px 80px rgba(0,0,0,0.04);
  display: flex; flex-direction: column;
  align-items: center; text-align: center;
  max-width: 900px; margin: 0 auto;
}
.mission-badge {
  background: var(--primary); color: white;
  padding: 0.5rem 1.75rem; border-radius: 100px;
  font-size: 0.9rem; font-weight: 700;
  letter-spacing: 0.1rem; margin-bottom: 2rem;
  text-transform: uppercase;
}
.mission-title {
  font-size: clamp(1.6rem, 3.5vw, 2.8rem);
  line-height: 1.3; margin-bottom: 1.5rem; color: var(--primary);
}
.mission-title .highlight { color: var(--accent); display: block; margin-top: 0.5rem; }

.mission-desc {
  font-size: 1rem; line-height: 1.8;
  color: #555; max-width: 600px; margin-bottom: 2.5rem;
}
.mission-stats {
  display: flex; gap: 4rem; flex-wrap: wrap;
  border-top: 1px solid rgba(0,0,0,0.06);
  padding-top: 2.5rem; width: 100%; justify-content: center;
}
.stat-item { display: flex; flex-direction: column; gap: 0.4rem; align-items: center; }
.stat-val { font-size: 2.5rem; font-weight: 900; color: var(--primary); }
.stat-label { font-size: 0.95rem; font-weight: 600; color: var(--accent); }

/* Vision Grid */
.vision-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; margin-top: 3rem; }
.vision-item {
  background: rgba(255,255,255,0.5);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.7);
  padding: 2rem 1.75rem; border-radius: 1.5rem;
  text-align: center; transition: var(--transition-premium);
}
.vision-item:hover { transform: translateY(-6px); background: white; border-color: var(--accent); }
.vision-icon {
  width: 56px; height: 56px; background: var(--accent-soft); color: var(--accent);
  border-radius: 14px; display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1.25rem;
}
.vision-icon i { width: 26px; height: 26px; }
.vision-item h3 { font-size: 1.2rem; margin-bottom: 0.75rem; color: var(--primary); }
.vision-item p { font-size: 0.95rem; line-height: 1.6; color: #666; }

/* ─── Services Slider ─── */
/* FIX: overflow:hidden on the section prevents horizontal layout breaks when slides move */
#services { overflow: hidden; }

.services-slider {
  padding: 2rem 0 4rem !important;
  overflow: hidden !important;
}
/* FIX: removed per-slide opacity — causes jarring layout jumps with loop:false */
.swiper-slide { height: auto !important; }

.feature-card {
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(0,104,74,0.1);
  border-radius: var(--radius-lg); padding: 2rem;
  height: 100%; display: flex; flex-direction: column;
  justify-content: flex-end; min-height: 300px;
  transition: var(--transition-premium);
}
.feature-card:hover { transform: translateY(-6px); border-color: var(--accent); box-shadow: var(--glass-shadow); }
.feature-icon {
  width: 52px; height: 52px;
  background: var(--accent-soft); border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent); margin-bottom: auto;
}
.feature-icon i { width: 24px; height: 24px; }
.feature-card h3 { font-size: 1.25rem; margin-bottom: 0.6rem; margin-top: 1.25rem; }
.feature-card p { color: var(--text-secondary); font-size: 0.95rem; }

.slider-controls { display: flex; justify-content: space-between; align-items: center; margin-top: 2rem; padding: 0 0.5rem; }
.swiper-pagination { position: relative !important; bottom: 0 !important; width: auto !important; }
.swiper-pagination-bullet { background: var(--text-muted) !important; opacity: 0.3 !important; }
.swiper-pagination-bullet-active { background: var(--accent) !important; opacity: 1 !important; width: 20px !important; border-radius: 4px !important; }
.slider-nav { display: flex; gap: 0.75rem; }
.swiper-button-next, .swiper-button-prev {
  position: static !important;
  width: 44px !important; height: 44px !important;
  background: #fff !important;
  border: 1px solid var(--glass-border) !important;
  border-radius: 50% !important; color: var(--primary) !important; margin: 0 !important;
}
.swiper-button-next::after, .swiper-button-prev::after { font-size: 1rem !important; font-weight: 900; }
.swiper-button-next:hover, .swiper-button-prev:hover { background: var(--primary) !important; color: #fff !important; }

/* ─── How It Works ─── */
.how-section { padding: 6rem 0; background: rgba(255,255,255,0.2); }
.header-tag {
  color: var(--accent); font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.15rem;
  margin-bottom: 1rem; font-size: 0.85rem;
}
.timeline-container { position: relative; max-width: 900px; margin: 4rem auto 0; padding: 0 1rem; }
.timeline-line {
  position: absolute; left: 50%; top: 0; bottom: 0; width: 2px;
  background: linear-gradient(to bottom, transparent, var(--primary), transparent);
  transform: translateX(-50%); opacity: 0.15;
}
.timeline-step {
  display: flex; align-items: center;
  justify-content: flex-start; width: 100%;
  margin-bottom: 5rem; position: relative;
}
.timeline-step.step-reverse { flex-direction: row-reverse; }
.step-visual {
  position: absolute; left: 50%; transform: translateX(-50%);
  z-index: 5; display: flex; flex-direction: column;
  align-items: center; gap: 1rem;
}
.step-circle {
  width: 3rem; height: 3rem; background: white;
  border: 2px solid var(--primary); color: var(--primary);
  border-radius: 50%; display: flex; align-items: center;
  justify-content: center; font-weight: 900; font-size: 1rem;
}
.step-icon-box {
  width: 52px; height: 52px; background: var(--primary); color: white;
  border-radius: 14px; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 24px rgba(0,104,74,0.18);
}
.step-icon-box i { width: 24px; height: 24px; }
.step-card-premium {
  width: 44%;
  background: rgba(255,255,255,0.65);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255,255,255,0.85);
  padding: 2rem 2.25rem; border-radius: 2rem;
  box-shadow: 0 16px 40px rgba(0,0,0,0.05);
  transition: var(--transition-premium);
}
.step-card-premium:hover { transform: translateY(-6px); background: white; border-color: var(--accent); }
.step-card-premium h3 { font-size: 1.3rem; margin-bottom: 0.75rem; color: var(--primary); }
.step-card-premium p { font-size: 0.95rem; line-height: 1.7; color: #555; }

/* ─── Footer ─── */
.footer { padding: 4rem 0 2rem; border-top: 1px solid var(--glass-border); }
.footer-content { display: flex; justify-content: space-between; margin-bottom: 3rem; flex-wrap: wrap; gap: 2rem; }
.footer-links-side { display: flex; gap: 3rem; flex-wrap: wrap; }
.footer-group h4 { margin-bottom: 1rem; font-family: var(--font-main); font-size: 0.95rem; }
.footer-group a { display: block; color: var(--text-secondary); text-decoration: none; margin-bottom: 0.6rem; font-size: 0.9rem; transition: color 0.3s; }
.footer-group a:hover { color: var(--accent); }
.footer-bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 0.5rem; border-top: 1px solid var(--glass-border); padding-top: 1.5rem; color: var(--text-muted); font-size: 0.85rem; }

/* ─── Mobile Menu (Hidden) ─── */
@media (max-width: 768px) {
  .nav-links { display: none; }
  .mobile-menu-btn { display: none; }
  .nav-actions .btn {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
  }
}

/* ─── Responsive: Tablet ─── */
@media (max-width: 1024px) {
  .hero-compact { padding: 7rem 0 4rem; }
  .hero-compact-grid { grid-template-columns: 1fr; text-align: center; gap: 3rem; }
  .compact-badge { margin: 0 auto 1.5rem; }
  .compact-p { margin: 0 auto 2rem; }
  .compact-actions { justify-content: center; }
  .hero-compact-visual { margin-top: 1rem; }

  .vision-grid { grid-template-columns: 1fr 1fr; }

  .timeline-line { display: none; }
  .timeline-step,
  .timeline-step.step-reverse { flex-direction: column; align-items: center; }
  .step-visual { position: static; transform: none; margin-bottom: 1.5rem; }
  .step-card-premium { width: 100%; max-width: 480px; }

  .services-slider { margin: 0; }
}

/* ─── Responsive: Mobile ─── */
@media (max-width: 768px) {
  :root { --spacing-section: 3.5rem; }

  .hero-compact { padding: 6rem 0 3rem; }
  .compact-card-stack { width: 240px; height: 240px; }
  .c-main-box { width: 170px; height: 170px; border-radius: 28px; }
  .compact-hero-logo { width: 85px; }
  .c-card { padding: 0.55rem 0.8rem; font-size: 0.8rem; }
  .c-card-1 { right: -10px; }
  .c-card-2 { left: -10px; }
  .c-card-3 { left: -28px; }
  .c-card-4 { right: -28px; }

  .mission-section { padding: 3.5rem 0; }
  .mission-card { padding: 2rem 1.25rem; border-radius: 1.75rem; }
  .mission-stats { gap: 2rem; }
  .stat-val { font-size: 2rem; }

  .vision-grid { grid-template-columns: 1fr; gap: 1rem; }
  .vision-item { padding: 1.5rem 1.25rem; border-radius: 1.25rem; }

  .how-section { padding: 3.5rem 0; }
  .timeline-container { margin-top: 2rem; }
  .timeline-step { margin-bottom: 2.5rem; }
  .step-card-premium { padding: 1.5rem 1.25rem; border-radius: 1.5rem; }

  .footer-content { flex-direction: column; }
  .footer-bottom { flex-direction: column; align-items: center; text-align: center; }

  .slider-controls { flex-direction: column; gap: 1rem; }
}

/* ─── Responsive: Small Mobile ─── */
@media (max-width: 480px) {
  .compact-h1 { font-size: 1.75rem !important; }
  .compact-actions { flex-direction: column; align-items: center; }
  .btn-pro-primary, .btn-pro-outline { width: 100%; text-align: center; justify-content: center; }
  .compact-card-stack { width: 200px; height: 200px; }
  .c-main-box { width: 150px; height: 150px; }
  .c-card-3, .c-card-4 { display: none; }
  .mission-stats { flex-direction: column; gap: 1.5rem; }
}