/* ============================================================
   Al-Dahra Clinic — Modern Minimalist Theme
   Palette: green / white / soft red accents
   ============================================================ */

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

:root {
  /* Greens */
  --green: #2E8B57;
  --green-dark: #1F6B40;
  --green-deep: #0F3D24;
  --green-light: #E8F5EF;
  --green-mist: #F4FAF7;

  /* Reds (used sparingly as accents) */
  --red: #E0413B;
  --red-soft: #FCEDEC;
  --red-dark: #960018;

  /* Neutrals */
  --ink: #15201A;
  --text: #3A4A42;
  --muted: #6B7A72;
  --line: #E6EDEA;
  --white: #FFFFFF;
  --cream: #FAFBF9;

  /* Effects */
  --radius: 18px;
  --radius-sm: 12px;
  --shadow-sm: 0 2px 12px rgba(15, 61, 36, 0.06);
  --shadow-md: 0 8px 30px rgba(15, 61, 36, 0.08);
  --shadow-lg: 0 20px 60px rgba(15, 61, 36, 0.12);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: 'Cairo', 'Inter', sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.7;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }

.container { max-width: 1180px; margin: 0 auto; padding: 0 24px; }

/* ===== SCROLL PROGRESS ===== */
.scroll-progress {
  position: fixed;
  top: 0;
  right: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--green), var(--red));
  z-index: 1000;
  transition: width 0.1s linear;
}

/* ===== NAVBAR ===== */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, box-shadow 0.3s;
}
.nav.scrolled { border-color: var(--line); box-shadow: var(--shadow-sm); }

.nav-inner {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.nav-logo { display: flex; align-items: center; gap: 12px; }
.nav-logo img { height: 46px; width: auto; }
.nav-name { display: flex; flex-direction: column; line-height: 1.25; }
.nav-name .ar { font-size: 14px; font-weight: 700; color: var(--ink); }
.nav-name .en { font-size: 12px; font-weight: 600; color: var(--green); letter-spacing: 0.04em; }

.nav-links { display: flex; align-items: center; gap: 8px; }
.nav-links a {
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text);
  padding: 8px 14px;
  border-radius: 999px;
  transition: color 0.2s, background 0.2s;
}
.nav-links a:hover { color: var(--green); background: var(--green-mist); }
.nav-links a.active { color: var(--green); background: var(--green-light); font-weight: 600; }

.nav-cta {
  background: var(--green);
  color: var(--white) !important;
  padding: 10px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  transition: background 0.2s, transform 0.2s;
}
.nav-cta:hover { background: var(--green-dark); transform: translateY(-1px); }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  width: 24px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  transition: transform 0.3s, opacity 0.3s;
}
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== HERO ===== */
.hero {
  background: linear-gradient(135deg, #1a1a1a 0%, #0A2D18 60%, #103A22 100%);
  color: var(--white);
  padding: 100px 2rem 80px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 88vh;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: -80px;
  right: -80px;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(46,139,87,0.18) 0%, transparent 70%);
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -60px;
  left: -60px;
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(46,139,87,0.10) 0%, transparent 70%);
}

.hero-inner {
  max-width: 1100px;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  position: relative;
  z-index: 1;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(46,139,87,0.2);
  border: 1px solid rgba(46,139,87,0.4);
  color: #7ECDA0;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: 20px;
  margin-bottom: 1.5rem;
}

.hero-eyebrow::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--red);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.3; }
}

.hero h1 {
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  font-weight: 700;
  line-height: 1.15;
  margin-bottom: 1rem;
  color: var(--white);
}

.hero h1 span { color: var(--red-dark); }

.hero-sub {
  font-family: 'Noto Kufi Arabic', sans-serif;
  font-size: 1.1rem;
  color: rgba(255,255,255,0.7);
  margin-bottom: 0.5rem;
  direction: rtl;
}

.hero-desc {
  font-size: 1rem;
  color: rgba(255,255,255,0.65);
  margin-bottom: 2.5rem;
  max-width: 460px;
}

.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

.btn-primary {
  background: var(--red-dark);
  color: var(--white);
  padding: 13px 28px;
  border-radius: 7px;
  font-size: 15px;
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.btn-primary:hover { background: var(--green-dark); transform: translateY(-1px); }

.btn-outline {
  background: transparent;
  color: var(--white);
  padding: 13px 28px;
  border-radius: 7px;
  font-size: 15px;
  font-weight: 500;
  text-decoration: none;
  border: 1px solid rgba(255,255,255,0.3);
  transition: border-color 0.2s, background 0.2s;
}

.btn-outline:hover { border-color: rgba(255,255,255,0.7); background: rgba(255,255,255,0.06); }

.hero-logo-wrap { display: flex; justify-content: center; align-items: center; }

.hero-logo-bg {
  position: relative;
  z-index: 2;
  width: 320px;
  height: 320px;
  border-radius: 32px;
  background: rgba(255, 255, 255, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25); /* Fixed broken box-shadow */
  padding: 24px;
}

.hero-logo-bg img {
  max-width: 80%;
  max-height: 80%;
  width: auto;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.08)); /* Clean shadow around the logo image */
}

/* STATS CONTAINER */
.stats { background: var(--green); padding: 3rem 2rem; }

.stats-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: rgba(255,255,255,0.2);
}

.stat-item { background: var(--green); padding: 2rem 1.5rem; text-align: center; }

.stat-number {
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--white);
  line-height: 1;
  margin-bottom: 0.4rem;
}

.stat-label { font-size: 13px; color: rgba(255,255,255,0.75); font-weight: 400; }

/* ===== SECTIONS ===== */
section { padding: 100px 0; }
.eyebrow {
  display: inline-block;
  font-size: 13px;
  font-weight: 700;
  color: var(--green);
  background: var(--green-light);
  padding: 6px 14px;
  border-radius: 999px;
  margin-bottom: 18px;
}
.eyebrow.light { color: #DCF0E5; background: rgba(255, 255, 255, 0.14); }
.section-title {
  font-size: clamp(1.7rem, 3vw, 2.6rem);
  font-weight: 800;
  color: var(--ink);
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin-bottom: 18px;
}
.section-desc { font-size: 1.02rem; color: var(--muted); max-width: 600px; line-height: 1.8; }

.section-head { text-align: center; margin-bottom: 56px; }
.section-head .section-desc { margin: 0 auto; }

/* ===== ABOUT ===== */
.about-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 70px;
  align-items: center;
}
.about-visual { position: relative; }
.about-logo-wrap {
  background: linear-gradient(160deg, var(--green-light), var(--green-mist));
  border-radius: 28px;
  padding: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1;
}
.about-logo-wrap img { width: 80%; }
.about-badge {
  position: absolute;
  bottom: -22px;
  left: -22px;
  background: var(--red);
  color: var(--white);
  border-radius: 18px;
  padding: 18px 24px;
  text-align: center;
  box-shadow: 0 12px 30px rgba(224, 65, 59, 0.35);
}
.about-badge strong { display: block; font-size: 2rem; font-weight: 800; line-height: 1; }
.about-badge span { font-size: 12px; opacity: 0.9; }

.about-content p { font-size: 1.02rem; color: var(--muted); margin-bottom: 24px; line-height: 1.9; }
.about-list { display: flex; flex-direction: column; gap: 14px; margin-bottom: 28px; }
.about-list li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 15px;
  color: var(--text);
  line-height: 1.7;
}
.about-list li::before {
  content: '✓';
  flex-shrink: 0;
  width: 22px; height: 22px;
  background: var(--green);
  color: var(--white);
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}
.about-tags { display: flex; gap: 10px; flex-wrap: wrap; }
.about-tags span {
  font-size: 13px;
  font-weight: 600;
  color: var(--green-dark);
  background: var(--green-light);
  padding: 6px 14px;
  border-radius: 999px;
}

/* ===== SERVICES ===== */
.services { background: var(--cream); }
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.service-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px 28px;
  transition: transform 0.3s var(--ease), box-shadow 0.3s, border-color 0.3s;
}
.service-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: transparent;
}
.service-icon {
  width: 54px; height: 54px;
  background: var(--green-light);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  transition: background 0.3s;
}
.service-card:hover .service-icon { background: var(--green); }
.service-icon svg {
  width: 26px; height: 26px;
  stroke: var(--green);
  fill: none;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: stroke 0.3s;
}
.service-card:hover .service-icon svg { stroke: var(--white); }
.service-card h3 { font-size: 17px; font-weight: 700; color: var(--ink); margin-bottom: 8px; }
.service-card p { font-size: 14px; color: var(--muted); line-height: 1.7; }

/* ===== DOCTORS ===== */
.doctors { background: var(--white); }
.filters {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 44px;
}
.filter-btn {
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  background: var(--white);
  border: 1px solid var(--line);
  padding: 9px 20px;
  border-radius: 999px;
  cursor: pointer;
  transition: all 0.2s;
}
.filter-btn:hover { border-color: var(--green); color: var(--green); }
.filter-btn.active { background: var(--green); color: var(--white); border-color: var(--green); }

.doctors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
}
.doctor-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px 24px;
  text-align: center;
  transition: transform 0.3s var(--ease), box-shadow 0.3s, border-color 0.3s;
}
.doctor-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: transparent;
}
.doctor-avatar {
  width: 84px; height: 84px;
  border-radius: 50%;
  margin: 0 auto 18px;
  background: linear-gradient(135deg, var(--green-light), var(--green-mist));
  border: 3px solid var(--green);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--green);
}
.doctor-card h3 { font-size: 16px; font-weight: 700; color: var(--ink); margin-bottom: 4px; }
.doctor-specialty {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--green);
  margin-bottom: 14px;
}
.doctor-schedule {
  font-size: 12.5px;
  color: var(--muted);
  background: var(--green-mist);
  border-radius: var(--radius-sm);
  padding: 10px 12px;
  line-height: 1.7;
}
.doctor-card.hidden { display: none; }

/* ===== CONTACT ===== */
.contact { background: var(--cream); }
.contact-card {
  background: linear-gradient(150deg, #0F3D24 0%, #1F6B40 100%);
  border-radius: 28px;
  padding: 60px;
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 50px;
  align-items: center;
  color: var(--white);
  position: relative;
  overflow: hidden;
}
.contact-card::before {
  content: '';
  position: absolute;
  top: -100px; left: -100px;
  width: 300px; height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(224, 65, 59, 0.25) 0%, transparent 70%);
}
.contact-left { position: relative; z-index: 1; }
.contact-left h2 {
  font-size: clamp(1.6rem, 2.6vw, 2.3rem);
  font-weight: 800;
  line-height: 1.25;
  margin-bottom: 18px;
}
.contact-left p { color: rgba(255, 255, 255, 0.75); margin-bottom: 28px; max-width: 440px; }
.contact-info { display: flex; flex-direction: column; gap: 14px; }
.contact-row {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.9);
  transition: color 0.2s;
}
.contact-row:hover { color: var(--white); }
.ci-icon {
  width: 40px; height: 40px;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.12);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}
.social-row { display: flex; gap: 12px; margin-top: 8px; }
.social-btn {
  font-size: 13px;
  font-weight: 600;
  color: var(--white);
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.22);
  padding: 9px 20px;
  border-radius: 999px;
  transition: background 0.2s;
}
.social-btn:hover { background: rgba(255, 255, 255, 0.22); }

.contact-right {
  position: relative; z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.contact-stat {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 18px;
  padding: 28px;
  text-align: center;
  backdrop-filter: blur(8px);
}
.cs-num { font-size: 2.4rem; font-weight: 800; line-height: 1; margin-bottom: 6px; }
.cs-num.red { color: #FFC9C5; }
.cs-lbl { font-size: 13.5px; color: rgba(255, 255, 255, 0.75); }

/* ===== FOOTER ===== */
.footer { background: #0A2114; color: rgba(255, 255, 255, 0.6); padding: 70px 0 28px; }
.footer-top {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  margin-bottom: 24px;
}
.footer-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.footer-brand img { height: 44px; filter: brightness(0) invert(1); }
.footer-brand .ar { font-size: 14px; font-weight: 700; color: var(--white); }
.footer-brand .en { font-size: 12px; color: var(--green); font-weight: 600; letter-spacing: 0.04em; }
.footer-desc { font-size: 13.5px; line-height: 1.8; max-width: 320px; }
.footer-col h4 { font-size: 14px; font-weight: 700; color: var(--white); margin-bottom: 16px; }
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col ul li a {
  font-size: 13.5px;
  color: rgba(255, 255, 255, 0.55);
  transition: color 0.2s;
}
.footer-col ul li a:hover { color: var(--green); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12.5px;
  color: rgba(255, 255, 255, 0.35);
}
.footer-bottom span { color: var(--green); }

/* ===== REVEAL ANIMATION ===== */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ===== RESPONSIVE ===== */
@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1fr; text-align: center; gap: 50px; }
  .hero-sub { margin-left: auto; margin-right: auto; }
  .hero-actions { justify-content: center; }
  .hero-visual { order: -1; }
  .about-grid { grid-template-columns: 1fr; gap: 60px; }
  .about-content { text-align: center; }
  .about-list { text-align: right; }
  .about-tags { justify-content: center; }
  .contact-card { grid-template-columns: 1fr; padding: 44px; gap: 36px; }
  .footer-top { grid-template-columns: 1fr 1fr; gap: 32px; }
}

@media (max-width: 768px) {
  section { padding: 70px 0; }
  .nav-links {
    position: fixed;
    top: 76px; right: 0;
    width: 75%; max-width: 320px;
    height: calc(100vh - 76px);
    background: var(--white);
    flex-direction: column;
    align-items: stretch;
    padding: 28px 24px;
    gap: 6px;
    box-shadow: -10px 0 40px rgba(0, 0, 0, 0.1);
    transform: translateX(100%);
    transition: transform 0.35s var(--ease);
  }
  .nav-links.open { transform: translateX(0); }
  .nav-links a { padding: 14px 16px; font-size: 16px; }
  .nav-cta { display: none; }
  .nav-toggle { display: flex; }

  .hero { padding: 60px 24px 80px; }
  .hero-logo-card { width: 220px; height: 220px; }
  .hero-visual { min-height: 280px; }
  .float-1 { right: 10px; top: 0; }
  .float-2 { left: 10px; bottom: 0; }

  .stats-grid { grid-template-columns: 1fr 1fr; gap: 30px 16px; padding: 36px 22px; }
  .doctors-grid { grid-template-columns: 1fr 1fr; }
  .stats {
    padding: 2rem 1rem;
  }

  .stats-inner {
    grid-template-columns: repeat(2, 1fr); /* Displays as a 2x2 grid on tablets/phones */
    gap: 1px;
  }

  .stat-item {
    padding: 1.5rem 1rem;
  }

  .stat-number {
    font-size: 1.8rem; /* Scaled down slightly so numbers like 100K+ fit without wrapping */
  }

  .stat-label {
    font-size: 12px;
  }
}


@media (max-width: 520px) {
  .container { padding: 0 18px; }
  .stats-grid { grid-template-columns: 1fr; }
  .doctors-grid { grid-template-columns: 1fr; }
  .contact-card { padding: 32px 24px; }
  .footer-top { grid-template-columns: 1fr; text-align: center; }
  .footer-brand, .footer-desc { margin-left: auto; margin-right: auto; }
  .footer-bottom { flex-direction: column; gap: 10px; }
  .about-badge { left: 50%; transform: translateX(-50%); bottom: -26px; }
  .stats-inner {
    grid-template-columns: 1fr; /* Stack vertically on very small screens */
  }
  
  .stat-number {
    font-size: 2rem;
  }
}

