/* ==========================================================================
   Midecare — Global Styles
   Brand palette derived from logo (teal + navy)
   Variable names kept as --green-* for stability; values are teal/navy.
   ========================================================================== */

/* Prevent FOUC: hide translatable text until applyLanguage runs */
html.i18n-loading [data-i18n] { visibility: hidden; }

:root {
  /* Brand teal + navy (from logo) */
  --green-900: #0a3442; /* deepest navy-teal (footer / ink) */
  --green-800: #0e5566; /* primary dark (hover, accents) */
  --green-700: #12889b; /* PRIMARY teal */
  --green-600: #159aad;
  --green-500: #1fb0c4;
  --green-400: #4cc3d4;
  --green-300: #a7dde6;
  --green-100: #d4eef3;
  --green-50:  #eaf7fa;

  /* Navy accent (logo wordmark) */
  --navy: #0e3a57;

  /* Neutrals (cool/bluish) */
  --ink-900: #0c2430;
  --ink-700: #2a3b44;
  --ink-500: #566670;
  --ink-400: #7a8a93;
  --line:    #e2edf0;
  --bg:      #ffffff;
  --bg-soft: #f4fafb;
  --white:   #ffffff;

  /* Effects */
  --shadow-sm: 0 1px 2px rgba(12, 36, 48, .06), 0 2px 8px rgba(12, 36, 48, .05);
  --shadow-md: 0 8px 24px rgba(12, 36, 48, .10);
  --shadow-lg: 0 20px 50px rgba(12, 36, 48, .16);
  --radius-sm: 10px;
  --radius:    16px;
  --radius-lg: 24px;
  --radius-full: 999px;

  /* Typography */
  --font-latin: "Poppins", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-arabic: "Tajawal", system-ui, "Segoe UI", Tahoma, sans-serif;
  --font: var(--font-latin);

  --maxw: 1200px;
  --header-h: 72px;
}

/* Arabic mode font */
html[lang="ar"] { --font: var(--font-arabic); }

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink-700);
  background: var(--bg);
  line-height: 1.7;
  font-size: 16px;
  overflow-x: hidden;
}
img, video, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4 { margin: 0; color: var(--ink-900); line-height: 1.25; font-weight: 700; }
p { margin: 0 0 1rem; }
button { font-family: inherit; cursor: pointer; }
.mt-2 {margin-top: 10px !important;}
.pt-2 {padding-top: 10px !important;}
.pt-0 {padding-top: 0px !important;}
/* ---------- Layout helpers ---------- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 20px; }
.section { padding: 64px 0; }
.section--soft { background: linear-gradient(180deg, var(--bg-soft) 0%, #eef6f8 50%, var(--bg-soft) 100%); }
.section--tint { background: linear-gradient(135deg, var(--green-50), #e0f2f5 50%, var(--green-50)); }
.section-head { max-width: 720px; margin: 0 auto 48px; text-align: center; }
.eyebrow {
  display: inline-block;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--green-700);
  background: linear-gradient(120deg, var(--green-50), var(--green-100));
  padding: 7px 16px;
  border-radius: var(--radius-full);
  margin-bottom: 16px;
  border: 1px solid var(--green-100);
}
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.5rem); }
.section-head p { color: var(--ink-500); margin-top: 12px; }

.grid { display: grid; gap: 24px; }
.text-center { text-align: center; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  font-weight: 600; font-size: .98rem;
  padding: 8px 20px; border-radius: var(--radius-full);
  border: 1.5px solid transparent; transition: transform .15s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--green-800); color: #fff; box-shadow: 0 8px 20px rgba(14,85,102,.32); }
.btn--primary:hover { background: var(--green-900); box-shadow: 0 12px 26px rgba(14,85,102,.4); }
.btn--ghost { background: transparent; color: var(--green-800); border-color: var(--green-300); }
.btn--ghost:hover { background: var(--green-50); border-color: var(--green-500); }
.btn--white { background: #fff; color: var(--green-800); }
.btn--white:hover { background: var(--green-50); }
.btn--wa { background: #25d366; color: #063; }
.btn--wa:hover { background: #1fbe5b; }
.btn svg { width: 18px; height: 18px; }

html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255);
  backdrop-filter: saturate(160%) blur(5px);
  border-bottom: 1px solid var(--line);
  transition: background .35s ease, backdrop-filter .35s ease, border-color .35s ease, box-shadow .35s ease;
}
.nav {
  height: var(--header-h);
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
}
.brand { display: flex; align-items: center; gap: 10px;background-color: #ffffff;border-radius: 3px;padding: 2px 8px; }
.brand img { height: 44px; width: auto; }
.nav-links { display: flex; align-items: center; gap: 6px; }
.nav-links a {
  padding: 9px 14px; border-radius: var(--radius-full);
  font-weight: 500; color: var(--ink-700); font-size: .95rem;
  transition: background .18s ease, color .18s ease;
}
.nav-links a:hover { background: var(--green-50); color: var(--green-800); }
.nav-links a.active { color: var(--green-800); background: var(--green-50); font-weight: 600; }
.nav-actions { display: flex; align-items: center; gap: 10px; }

.lang-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--green-50); color: var(--green-800);
  border: 1px solid var(--green-100); border-radius: var(--radius-full);
  padding: 8px 14px; font-weight: 600; font-size: .9rem;
}
.lang-toggle:hover { background: var(--green-100); }

.nav-toggle {
  display: none; background: var(--green-50); border: 1px solid var(--green-100);
  border-radius: 12px; width: 44px; height: 44px; align-items: center; justify-content: center;
  color: var(--green-800);
}
.nav-toggle svg { width: 24px; height: 24px; }

/* Overlay header (home): transparent over hero, solid on scroll */
.site-header--overlay {
  position: fixed; inset-inline: 0; top: 0;
  background: transparent; backdrop-filter: none;
  border-bottom-color: transparent;
}
.site-header--overlay:not(.is-scrolled) .nav-links a { color: rgba(255,255,255,.92); }
.site-header--overlay:not(.is-scrolled) .nav-links a:hover,
.site-header--overlay:not(.is-scrolled) .nav-links a.active { background: rgba(255,255,255,.16); color: #fff; }
.site-header--overlay:not(.is-scrolled) .lang-toggle,
.site-header--overlay:not(.is-scrolled) .nav-toggle {
  background: rgba(255,255,255,.14); color: #fff; border-color: rgba(255,255,255,.34);
}
.site-header--overlay:not(.is-scrolled) .lang-toggle:hover,
.site-header--overlay:not(.is-scrolled) .nav-toggle:hover { background: rgba(255,255,255,.24); }
.site-header--overlay.is-scrolled {
  background: rgba(255,255,255,.99);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom-color: var(--line);
  box-shadow: 0 6px 22px rgba(12,36,48,.09);
}
/* Mobile open dropdown stays readable regardless of scroll state */
.site-header--overlay .nav.open .nav-links a { color: var(--ink-700); }
.site-header--overlay .nav.open .nav-links a:hover,
.site-header--overlay .nav.open .nav-links a.active { background: var(--green-50); color: var(--green-800); }

/* ---------- Hero ---------- */
.hero {
  position: relative; min-height: 100vh; min-height: 100svh;
  display: flex; align-items: center; color: #fff; overflow: hidden;
  text-shadow: 0 1px 1px black;
}
.hero__video, .hero__img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; z-index: 0;
}
.hero__overlay {
  position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(180deg, rgba(10,52,66,.62) 0%, rgba(10,52,66,.26) 32%, rgba(10,52,66,.34) 62%, rgba(8,40,52,.85) 100%),
    linear-gradient(115deg, rgba(12,45,60,.72) 0%, rgba(14,58,87,.4) 55%, rgba(12,36,48,.22) 100%);
    /* opacity: .5; */
    /* filter: blur(3px); */
    backdrop-filter: blur(5px);
}
.hero__inner { position: relative; z-index: 2; max-width: 720px; padding: calc(var(--header-h) + 34px) 0 96px; }

/* Scroll-down cue */
.hero__scroll {
  position: absolute; inset-inline: 0; bottom: 26px; margin-inline: auto; z-index: 2;
  width: 27px; height: 44px; border: 2px solid rgba(255,255,255,.55);
  border-radius: 15px; display: grid; justify-items: center; padding-top: 8px;
  transition: border-color .2s ease;
}
.hero__scroll:hover { border-color: rgba(255,255,255,.9); }
.hero__scroll span {
  width: 4px; height: 8px; border-radius: 2px; background: #fff;
  animation: heroScroll 1.7s ease-in-out infinite;
}
@keyframes heroScroll {
  0% { opacity: 0; transform: translateY(-4px); }
  35% { opacity: 1; }
  75% { opacity: 0; transform: translateY(9px); }
  100% { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) { .hero__scroll span { animation: none; } }
.hero h1 { color: #fff; font-size: clamp(2.1rem, 5vw, 3.6rem); line-height: 1.12;text-shadow: 4px 2px 2px black; }
.hero p { color: rgba(255,255,255,.92); font-size: clamp(1rem, 2vw, 1.2rem); margin-top: 20px; }
.hero__cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.hero__badges { display: flex; flex-wrap: wrap; gap: 20px; margin-top: 40px; }
.hero__badge { display: flex; align-items: center; gap: 10px; font-size: .95rem; color: rgba(255,255,255,.92); }
.hero__badge svg { width: 22px; height: 22px; color: var(--green-300); }

/* ---------- Page banner (inner pages) ---------- */
.page-banner {
  position: relative; padding: 96px 0 72px; color: #fff; text-align: center;
  background:
    radial-gradient(900px 300px at 50% -10%, rgba(31,176,196,.25), transparent 70%),
    linear-gradient(135deg, var(--green-900) 0%, var(--green-800) 50%, var(--green-700) 100%);
  overflow: hidden;
}
.page-banner::before {
  content: ""; position: absolute; inset-block-end: -60%; inset-inline-start: -10%;
  width: 400px; height: 400px; border-radius: 50%;
  background: radial-gradient(circle, rgba(31,176,196,.1), transparent 70%);
  pointer-events: none;
}
.page-banner h1 { color: #fff; font-size: clamp(1.9rem, 4vw, 3rem); }
.page-banner p { color: rgba(255,255,255,.9); max-width: 640px; margin: 14px auto 0; }
.breadcrumb { margin-top: 18px; font-size: .9rem; color: rgba(255,255,255,.8); }
.breadcrumb a:hover { color: #fff; text-decoration: underline; }

/* ---------- Cards ---------- */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 32px 28px; box-shadow: var(--shadow-sm);
  transition: transform .3s cubic-bezier(.22,1,.36,1), box-shadow .3s ease, border-color .3s ease;
  position: relative; overflow: hidden;
}
.card::before {
  content: ""; position: absolute; top: 0; inset-inline: 0; height: 3px;
  background: linear-gradient(90deg, var(--green-600), var(--green-400));
  transform: scaleX(0); transform-origin: start; transition: transform .4s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: var(--green-300); }
.card:hover::before { transform: scaleX(1); }
.card__icon {
  width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--green-50), var(--green-100)); color: var(--green-700); margin-bottom: 18px;
  transition: transform .3s ease, background .3s ease;
}
.card:hover .card__icon { transform: scale(1.08) rotate(-3deg); background: linear-gradient(135deg, var(--green-100), var(--green-300)); }
.card__icon svg { width: 26px; height: 26px; }
.card h3 { font-size: 1.15rem; margin-bottom: 8px; }
.card p { color: var(--ink-500); font-size: .96rem; margin: 0; }

/* Feature (two big pillars) */
.pillars { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.pillar {
  position: relative; border-radius: var(--radius-lg); overflow: hidden; min-height: 320px;
  display: flex; align-items: flex-end; color: #fff; box-shadow: var(--shadow-md);
}
.pillar img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; transition: transform .5s ease; }
.pillar::after { content:""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10,52,66,.05) 0%, rgba(10,52,66,.45) 50%, rgba(10,52,66,.88) 100%); z-index: 1; transition: opacity .4s ease; }
.pillar:hover img { transform: scale(1.06); }
.pillar__body { position: relative; z-index: 2; padding: 30px; }
.pillar__body h3 { color: #fff; font-size: 1.5rem; margin-bottom: 8px; }
.pillar__body p { color: rgba(255,255,255,.9); margin-bottom: 16px; }

/* ---------- Split (image + text) ---------- */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.split__media { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); position: relative; }
.split__media img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4/3; transition: transform .5s ease; }
.split__media:hover img { transform: scale(1.04); }
.split h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); margin-bottom: 16px; }
.split p { color: var(--ink-500); }
.check-list { display: grid; gap: 14px; margin-top: 20px; }
.check-list li { display: flex; gap: 12px; align-items: flex-start; padding: 6px 0; transition: transform .2s ease; }
.check-list li:hover { transform: translateX(4px); }
.check-list svg { width: 22px; height: 22px; color: var(--green-600); flex: 0 0 auto; margin-top: 2px; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.stat {
  text-align: center; padding: 32px 18px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-sm); position: relative; overflow: hidden;
  transition: transform .3s ease, box-shadow .3s ease;
}
.stat::before {
  content: ""; position: absolute; inset-block-start: 0; inset-inline: 0; height: 100%;
  background: linear-gradient(180deg, var(--green-50) 0%, transparent 60%);
  opacity: 0; transition: opacity .3s ease; pointer-events: none;
}
.stat:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.stat:hover::before { opacity: 1; }
.stat__icon { width: 44px; height: 44px; margin: 0 auto 12px; color: var(--green-600); }
.stat__icon svg { width: 100%; height: 100%; }
.stat b { display: block; font-size: 2.4rem; font-weight: 800; color: var(--green-700); line-height: 1.1; }
.stat span { color: var(--ink-500); font-size: .92rem; display: block; margin-top: 6px; }

/* ---------- Services list (grouped) ---------- */
.svc-group { margin-bottom: 44px; }
.svc-group h3 { font-size: 1.35rem; margin-bottom: 20px; display: flex; align-items: center; gap: 12px; }
.svc-group h3 .dot { width: 10px; height: 10px; border-radius: 50%; background: var(--green-500); }
.svc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.svc-item {
  display: flex; align-items: flex-start; gap: 12px; padding: 16px 18px;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm);
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.svc-item:hover { border-color: var(--green-300); box-shadow: var(--shadow-sm); transform: translateY(-2px); }
.svc-item .tick { width: 22px; height: 22px; border-radius: 50%; background: var(--green-50); color: var(--green-700); display: grid; place-items: center; flex: 0 0 auto; }
.svc-item .tick svg { width: 14px; height: 14px; }
.svc-item__body { display: flex; flex-direction: column; gap: 4px; }
.svc-item__name { font-size: .96rem; font-weight: 600; color: var(--ink-700); }
.svc-item__desc { font-size: .82rem; font-weight: 400; color: var(--ink-500); line-height: 1.45; margin: 0; }

/* Search box */
.svc-search { max-width: 480px; margin: 0 auto 40px; position: relative; }
.svc-search input {
  width: 100%; padding: 14px 46px; border: 1.5px solid var(--line); border-radius: var(--radius-full);
  font-family: inherit; font-size: 1rem; color: var(--ink-700); background: #fff; transition: border-color .18s ease;
}
.svc-search input:focus { outline: none; border-color: var(--green-500); }
.svc-search svg { position: absolute; inset-inline-start: 16px; top: 50%; transform: translateY(-50%); width: 20px; height: 20px; color: var(--ink-400); }

/* ---------- Gallery ---------- */
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.gallery a { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); position: relative; }
.gallery a::after {
  content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 60%, rgba(10,52,66,.55));
  opacity: 0; transition: opacity .3s ease; pointer-events: none; z-index: 1;
}
.gallery a:hover::after { opacity: 1; }
.gallery img { width: 100%; height: 100%; aspect-ratio: 1/1; object-fit: cover; transition: transform .5s cubic-bezier(.22,1,.36,1); }
.gallery a:hover img { transform: scale(1.1); }
.gallery a:first-child { grid-column: span 2; grid-row: span 2; }
.gallery a:first-child img { aspect-ratio: auto; }

/* ---------- CTA band ---------- */
.cta-band {
  background: linear-gradient(120deg, var(--green-900), var(--green-800) 40%, var(--green-700));
  color: #fff; border-radius: var(--radius-lg); padding: 58px 48px;
  display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap;
  box-shadow: var(--shadow-lg); position: relative; overflow: hidden;
}
.cta-band::before {
  content: ""; position: absolute; inset-block-start: -40%; inset-inline-end: -10%;
  width: 360px; height: 360px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,.08), transparent 70%);
  pointer-events: none;
}
.cta-band::after {
  content: ""; position: absolute; inset-block-end: -50%; inset-inline-start: -5%;
  width: 300px; height: 300px; border-radius: 50%;
  background: radial-gradient(circle, rgba(31,176,196,.12), transparent 70%);
  pointer-events: none;
}
.cta-band h2 { color: #fff; font-size: clamp(1.5rem, 3vw, 2.1rem); }
.cta-band p { color: rgba(255,255,255,.9); margin: 8px 0 0; }
.cta-band .cta-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Contact ---------- */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
.info-list { display: grid; gap: 20px; }
.info-item { display: flex; gap: 16px; align-items: flex-start; }
.info-item .ico { width: 48px; height: 48px; border-radius: 14px; background: linear-gradient(135deg, var(--green-50), var(--green-100)); color: var(--green-700); display: grid; place-items: center; flex: 0 0 auto; transition: transform .3s ease; }
.info-item:hover .ico { transform: scale(1.08); }
.info-item .ico svg { width: 22px; height: 22px; }
.info-item h4 { font-size: 1.02rem; margin-bottom: 3px; }
.info-item p, .info-item a { color: var(--ink-500); margin: 0; }
.info-item a:hover { color: var(--green-700); }

.hours-table { width: 100%; border-collapse: collapse; margin-top: 8px; }
.hours-table td { padding: 9px 0; border-bottom: 1px dashed var(--line); font-size: .95rem; }
.hours-table td:last-child { text-align: end; color: var(--ink-500); }
.hours-table tr.closed td:last-child { color: #c0392b; font-weight: 600; }

.form-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 32px; box-shadow: var(--shadow-md); }
.field { margin-bottom: 18px; }
.field label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 7px; color: var(--ink-700); }
.field input, .field select, .field textarea {
  width: 100%; padding: 13px 15px; border: 1.5px solid var(--line); border-radius: 12px;
  font-family: inherit; font-size: 1rem; color: var(--ink-700); background: #fff; transition: border-color .18s ease;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--green-500); }
.field textarea { min-height: 120px; resize: vertical; }

.map-embed { border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow-md); border: 1px solid var(--line); }
.map-embed iframe { width: 100%; height: 380px; border: 0; display: block; }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink-900); color: #c3d3db; padding: 64px 0 26px; position: relative; }
.site-footer::before { content: ""; position: absolute; top: 0; inset-inline: 0; height: 3px; background: linear-gradient(90deg, var(--green-700), var(--green-500), var(--green-700)); }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 36px; }
.site-footer h4 { color: #fff; font-size: 1.05rem; margin-bottom: 18px; }
.footer-brand img { height: 54px; margin-bottom: 16px; background: #fff; padding: 8px 12px; border-radius: 12px; }
.footer-brand p { color: #94a8b3; font-size: .95rem; }
.footer-links li { margin-bottom: 10px; }
.footer-links a { color: #c3d3db; font-size: .95rem; }
.footer-links a:hover { color: var(--green-300); }
.footer-contact li { display: flex; gap: 10px; margin-bottom: 12px; font-size: .93rem; color: #c3d3db; }
.footer-contact svg { width: 18px; height: 18px; color: var(--green-400); flex: 0 0 auto; margin-top: 3px; }
.footer-social { display: flex; gap: 10px; margin-top: 16px; }
.footer-social a {
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(255,255,255,.08); color: #c3d3db;
  display: grid; place-items: center;
  transition: background .2s ease, color .2s ease, transform .2s ease;
}
.footer-social a:hover { background: var(--green-700); color: #fff; transform: translateY(-2px); }
.footer-social svg { width: 18px; height: 18px; }

.contact-social { display: flex; gap: 12px; margin-top: 22px; }
.contact-social a {
  width: 42px; height: 42px; border-radius: 50%;
  background: var(--green-50); color: var(--green-700);
  display: grid; place-items: center;
  transition: background .2s ease, color .2s ease, transform .2s ease;
}
.contact-social a:hover { background: var(--green-700); color: #fff; transform: translateY(-2px); }
.contact-social svg { width: 20px; height: 20px; }

.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 44px; padding-top: 22px; text-align: center; color: #8598a3; font-size: .88rem; }

/* Floating WhatsApp */
.fab-wa {
  position: fixed; inset-block-end: 22px; inset-inline-end: 22px; z-index: 90;
  width: 58px; height: 58px; border-radius: 50%; background: #25d366; color: #fff;
  display: grid; place-items: center; box-shadow: 0 10px 26px rgba(37,211,102,.5);
  transition: transform .2s ease;
}
.fab-wa:hover { transform: scale(1.08); }
.fab-wa svg { width: 30px; height: 30px; }

/* ---------- Why Choose Us ---------- */
.why-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.why-item {
  display: flex; gap: 16px; align-items: flex-start;
  padding: 26px 24px; background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}
.why-item:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--green-300); }
.why-item__icon {
  width: 48px; height: 48px; border-radius: 14px; flex: 0 0 auto;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--green-50), var(--green-100));
  color: var(--green-700);
  transition: transform .3s ease;
}
.why-item:hover .why-item__icon { transform: scale(1.1); }
.why-item__icon svg { width: 24px; height: 24px; }
.why-item h3 { font-size: 1.05rem; margin-bottom: 6px; }
.why-item p { color: var(--ink-500); font-size: .92rem; margin: 0; }

/* ---------- Wave divider ---------- */
.wave-divider { display: block; width: 100%; height: 48px; margin-top: -1px; }

/* ---------- Preloader ---------- */
.preloader {
  position: fixed; inset: 0; z-index: 10000;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--green-900), var(--green-800));
  transition: opacity .6s ease, visibility .6s ease;
}
.preloader.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.preloader__logo { position: relative; width: 180px; height: 180px; display: grid; place-items: center; }
.preloader__img {
  width: 110px; height: auto; border-radius: 18px; background: #fff; padding: 10px;
  animation: pulse 1.8s ease-in-out infinite;
}
.preloader__ring {
  position: absolute; inset: 0; border-radius: 50%;
  border: 4px solid rgba(255,255,255,.12);
  border-top-color: var(--green-400);
  animation: spin 1s linear infinite;
}
.preloader__text {
  margin-top: 24px; color: #fff; font-size: 1.3rem; font-weight: 700;
  letter-spacing: .08em; opacity: .9;
  animation: fadeInUp 1.2s ease forwards;
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: .9; transform: none; }
}

/* ---------- Reveal animation ---------- */
[data-reveal] { opacity: 0; transform: translateY(24px);  }
[data-reveal].in { opacity: 1; transform: none; }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 9999;
  display: none; align-items: center; justify-content: center;
  background: rgba(8,32,42,.94);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
.lightbox.is-open { display: flex; animation: lbFadeIn .28s ease; }
@keyframes lbFadeIn { from { opacity: 0; } to { opacity: 1; } }

.lightbox__img-wrap {
  position: relative; max-width: 92vw; max-height: 86vh;
  display: flex; align-items: center; justify-content: center;
  animation: lbZoomIn .32s cubic-bezier(.22,1,.36,1);
}
@keyframes lbZoomIn { from { opacity: 0; transform: scale(.92); } to { opacity: 1; transform: scale(1); } }
.lightbox__img {
  max-width: 92vw; max-height: 86vh; border-radius: 10px;
  object-fit: contain; box-shadow: 0 24px 70px rgba(0,0,0,.5);
  user-select: none; -webkit-user-drag: none;
}

.lightbox__close {
  position: absolute; top: 18px; inset-inline-end: 22px;
  width: 46px; height: 46px; border: none; border-radius: 50%;
  background: rgba(255,255,255,.12); color: #fff;
  display: grid; place-items: center; cursor: pointer;
  transition: background .2s ease, transform .2s ease;
  z-index: 2;
}
.lightbox__close:hover { background: rgba(255,255,255,.28); transform: scale(1.06); }
.lightbox__close svg { width: 24px; height: 24px; }

.lightbox__nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 52px; height: 52px; border: none; border-radius: 50%;
  background: rgba(255,255,255,.1); color: #fff;
  display: grid; place-items: center; cursor: pointer;
  transition: background .2s ease, transform .2s ease;
  z-index: 2;
}
.lightbox__nav:hover { background: rgba(255,255,255,.25); transform: translateY(-50%) scale(1.08); }
.lightbox__nav:active { transform: translateY(-50%) scale(.96); }
.lightbox__nav svg { width: 28px; height: 28px; }
.lightbox__nav--prev { inset-inline-start: 16px; }
.lightbox__nav--next { inset-inline-end: 16px; }

.lightbox__counter {
  position: absolute; bottom: 20px; inset-inline: 0; text-align: center;
  color: rgba(255,255,255,.7); font-size: .9rem; font-weight: 500;
  z-index: 2; user-select: none;
}

/* Swipe hint on touch devices */
.lightbox__img-wrap.swiping { cursor: grabbing; }

/* Mobile tuning */
@media (max-width: 600px) {
  .lightbox__nav { width: 44px; height: 44px; }
  .lightbox__nav svg { width: 24px; height: 24px; }
  .lightbox__nav--prev { inset-inline-start: 8px; }
  .lightbox__nav--next { inset-inline-end: 8px; }
  .lightbox__close { top: 12px; inset-inline-end: 12px; width: 40px; height: 40px; }
  .lightbox__close svg { width: 20px; height: 20px; }
  .lightbox__counter { bottom: 14px; font-size: .82rem; }
}

/* ---------- Service detail offcanvas ---------- */
.svc-offcanvas__backdrop {
  position: fixed; inset: 0; z-index: 9998;
  background: rgba(8,32,42,.5);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  opacity: 0; visibility: hidden;
  transition: opacity .28s ease, visibility .28s ease;
}
.svc-offcanvas__backdrop.is-open { opacity: 1; visibility: visible; }

.svc-offcanvas {
  position: fixed; inset-block: 0; inset-inline-end: 0;
  z-index: 9999;
  width: min(460px, 92vw);
  background: #fff;
  box-shadow: -14px 0 40px rgba(12,36,48,.18);
  display: flex; flex-direction: column;
  transform: translateX(100%);
  transition: transform .32s cubic-bezier(.22,1,.36,1);
  visibility: hidden;
}
/* RTL: panel slides from the right (start side). LTR: from the right (end side).
   Using translateX(100%) hides it off the end edge in both directions. */
[dir="rtl"] .svc-offcanvas { transform: translateX(100%); box-shadow: 14px 0 40px rgba(12,36,48,.18); }
[dir="ltr"] .svc-offcanvas { transform: translateX(100%); }
.svc-offcanvas.is-open { transform: translateX(0); visibility: visible; }

.svc-offcanvas__head {
  padding: 22px 24px 18px;
  border-bottom: 1px solid var(--line);
  position: relative;
  background: linear-gradient(180deg, var(--green-50) 0%, #fff 100%);
}
.svc-offcanvas__group {
  display: inline-block; font-size: .74rem; font-weight: 700; letter-spacing: .04em;
  text-transform: uppercase; color: var(--green-700);
  background: rgba(255,255,255,.7); padding: 4px 10px; border-radius: var(--radius-full);
  margin-bottom: 10px;
}
[dir="rtl"] .svc-offcanvas__group { text-transform: none; }
.svc-offcanvas__title {
  font-size: 1.4rem; font-weight: 800; color: var(--ink-800);
  margin: 0; padding-inline-end: 36px; line-height: 1.3;
}
.svc-offcanvas__close {
  position: absolute; top: 18px; inset-inline-end: 18px;
  width: 38px; height: 38px; border: none; border-radius: 50%;
  background: rgba(255,255,255,.8); color: var(--ink-600);
  display: grid; place-items: center; cursor: pointer;
  transition: background .2s ease, transform .2s ease, color .2s ease;
}
.svc-offcanvas__close:hover { background: var(--green-100); color: var(--green-800); transform: rotate(90deg); }
.svc-offcanvas__close svg { width: 20px; height: 20px; }

.svc-offcanvas__body {
  padding: 22px 24px; overflow-y: auto; flex: 1 1 auto;
  display: flex; flex-direction: column; gap: 18px;
}
.svc-offcanvas__desc {
  font-size: .9rem; color: var(--ink-500); margin: 0;
  padding-inline-start: 12px; border-inline-start: 3px solid var(--green-300);
  line-height: 1.6;
}
.svc-offcanvas__article {
  font-size: 1rem; color: var(--ink-700); line-height: 1.75; margin: 0;
}
.svc-offcanvas__features-title {
  font-size: 1.05rem; font-weight: 700; color: var(--green-800);
  margin: 4px 0 0;
}
.svc-offcanvas__features { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.svc-offcanvas__features li {
  display: flex; align-items: flex-start; gap: 10px;
  font-size: .92rem; color: var(--ink-700); line-height: 1.55;
}
.svc-offcanvas__features .tick {
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--green-50); color: var(--green-700);
  display: grid; place-items: center; flex: 0 0 auto; margin-top: 1px;
}
.svc-offcanvas__features .tick svg { width: 13px; height: 13px; }

.svc-offcanvas__foot {
  padding: 16px 24px; border-top: 1px solid var(--line);
  display: flex; gap: 10px; flex-wrap: wrap; background: #fff;
}
.svc-offcanvas__foot .btn { flex: 1 1 auto; }

/* Clickable service item affordance */
.svc-item { cursor: pointer; }
.svc-item:focus-visible { outline: 2px solid var(--green-500); outline-offset: 2px; }
.svc-item__arrow {
  flex: 0 0 auto; align-self: center; color: var(--ink-400);
  display: grid; place-items: center; transition: transform .2s ease, color .2s ease;
}
.svc-item__arrow svg { width: 18px; height: 18px; }
[dir="rtl"] .svc-item__arrow svg { transform: scaleX(-1); }
.svc-item:hover .svc-item__arrow { color: var(--green-700); transform: translateX(2px); }
[dir="rtl"] .svc-item:hover .svc-item__arrow { transform: scaleX(-1) translateX(2px); }

/* Mobile tuning for offcanvas */
@media (max-width: 600px) {
  .svc-offcanvas { width: 100vw; }
  .svc-offcanvas__head { padding: 18px 18px 14px; }
  .svc-offcanvas__body { padding: 18px; }
  .svc-offcanvas__foot { padding: 14px 18px; }
  .svc-offcanvas__title { font-size: 1.2rem; }
}

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .cards, .svc-grid { grid-template-columns: repeat(2, 1fr); }
  .why-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: 1fr; gap: 30px; }
  .contact-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 760px) {
  .section { padding: 60px 0; }
  .nav-links, .nav-actions .btn { display: none; }
  .nav-toggle { display: inline-flex; }
  .nav.open .nav-links {
    display: flex; position: absolute; top: var(--header-h); inset-inline: 0;
    flex-direction: column; align-items: stretch; gap: 4px; background: #fff;
    padding: 14px 20px 20px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-md);
  }
  .nav.open .nav-links a { padding: 12px 14px; }
  .pillars, .cards, .svc-grid, .gallery, .why-grid { grid-template-columns: 1fr; }
  .gallery a:first-child { grid-column: auto; grid-row: auto; }
  .gallery { grid-template-columns: repeat(2, 1fr); }
  .cta-band { flex-direction: column; align-items: flex-start; text-align: start; }
}
@media (max-width: 460px) {
  .stats { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr; }
  .doctors-grid, .leaders-grid { grid-template-columns: 1fr; }
}

/* ---- Service group description ---- */
.svc-group__desc {
  color: var(--ink-500);
  font-size: .95rem;
  line-height: 1.6;
  margin: 0 0 16px;
  max-width: 720px;
}

/* ---- Leaders grid ---- */
.leaders-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
}
.leader-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 32px 24px;
  text-align: center;
  transition: box-shadow .25s, transform .25s;
}
.leader-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.leader-card__avatar {
  width: 88px; height: 88px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--navy));
  color: #fff; display: flex; align-items: center; justify-content: center;
  margin: 0 auto 16px;
}
.leader-card__avatar svg { width: 40px; height: 40px; }
.leader-card__avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.leader-card__avatar--fallback { background: linear-gradient(135deg, var(--brand), var(--navy)); }
.leader-card h3 { font-size: 1.15rem; font-weight: 700; margin: 0 0 4px; }
.leader-card__role {
  display: block; color: var(--brand); font-size: .9rem; font-weight: 600;
  margin-bottom: 10px;
}
.leader-card p { color: var(--ink-500); font-size: .9rem; line-height: 1.55; margin: 0; }

/* ---- Doctors grid ---- */
.doctors-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}
.doctor-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 32px 24px;
  text-align: center;
  transition: box-shadow .25s, transform .25s;
}
.doctor-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.doctor-card__avatar {
  width: 96px; height: 96px; border-radius: 50%;
  background: linear-gradient(135deg, var(--brand), var(--navy));
  color: #fff; display: flex; align-items: center; justify-content: center;
  margin: 0 auto 16px;
}
.doctor-card__avatar svg { width: 44px; height: 44px; }
.doctor-card__avatar img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.doctor-card__avatar--fallback { background: linear-gradient(135deg, var(--brand), var(--navy)); }
.doctor-card h3 { font-size: 1.2rem; font-weight: 700; margin: 0 0 4px; }
.doctor-card__role {
  display: block; color: var(--brand); font-size: .9rem; font-weight: 600;
  margin-bottom: 12px;
}
.doctor-card p { color: var(--ink-500); font-size: .9rem; line-height: 1.55; margin: 0 0 16px; }
.doctor-card .btn { display: inline-flex; align-items: center; gap: 6px; }

@media (max-width: 768px) {
  .doctors-grid, .leaders-grid { grid-template-columns: 1fr; }
}
