/* ==========================================================================
   DHCC — Dubai Healthcare City | Global Stylesheet
   ========================================================================== */

:root {
  --color-primary: #008065;
  --color-primary-dark: #005f4b;
  --color-secondary: #1a3d36;
  --color-accent: #E8A838;
  --color-accent-dark: #c98d24;
  --color-bg: #F0F7F5;
  --color-bg-alt: #ffffff;
  --color-text: #2c2c2c;
  --color-text-muted: #575856;
  --color-border: #e1e8ea;
  --color-success: #2e8a6b;

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
  --font-heading: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  --radius-card: 8px;
  --radius-button: 4px;
  --radius-pill: 999px;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 32px rgba(0, 0, 0, 0.12);

  --container-max: 1200px;
  --container-pad: 24px;

  --header-h: 84px;
  --header-h-scrolled: 64px;

  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h-scrolled) + 12px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background: #fff;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, svg, video { max-width: 100%; height: auto; display: block; }
a { color: var(--color-primary); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--color-accent); }
button { font-family: inherit; cursor: pointer; }
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--color-secondary);
  line-height: 1.2;
  margin: 0 0 0.5em;
  font-weight: 700;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2rem, 4vw + 1rem, 3.5rem); }
h2 { font-size: clamp(1.6rem, 2.5vw + 0.6rem, 2.4rem); }
h3 { font-size: clamp(1.25rem, 1vw + 0.8rem, 1.5rem); }
p { margin: 0 0 1em; }
ul { padding-left: 1.25em; }

/* ---------- Layout helpers ---------- */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-pad);
}
.section { padding: 80px 0; }
.section-sm { padding: 56px 0; }
.section-bg { background: var(--color-bg); }
.section-dark { background: var(--color-secondary); color: #fff; }
.section-dark h1, .section-dark h2, .section-dark h3 { color: #fff; }
.text-center { text-align: center; }
.section-head { text-align: center; max-width: 720px; margin: 0 auto 48px; }
.section-head .eyebrow {
  display: inline-block;
  color: var(--color-primary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.8rem;
  margin-bottom: 12px;
}
.section-head p { color: var(--color-text-muted); font-size: 1.1rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border-radius: var(--radius-button);
  font-weight: 600;
  font-size: 0.95rem;
  border: 2px solid transparent;
  transition: all var(--transition);
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  line-height: 1;
}
.btn-primary {
  background: var(--color-primary);
  color: #fff;
}
.btn-primary:hover { background: var(--color-primary-dark); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn-accent {
  background: var(--color-accent);
  color: var(--color-secondary);
}
.btn-accent:hover { background: var(--color-accent-dark); color: var(--color-secondary); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn-outline {
  background: transparent;
  border-color: var(--color-primary);
  color: var(--color-primary);
}
.btn-outline:hover { background: var(--color-primary); color: #fff; }
.btn-light {
  background: rgba(255,255,255,0.15);
  color: #fff;
  border-color: rgba(255,255,255,0.4);
  backdrop-filter: blur(10px);
}
.btn-light:hover { background: #fff; color: var(--color-primary); }
.btn-lg { padding: 18px 36px; font-size: 1rem; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(12px);
  height: var(--header-h);
  transition: height var(--transition), box-shadow var(--transition);
  border-bottom: 1px solid transparent;
}
.site-header.scrolled {
  height: var(--header-h-scrolled);
  box-shadow: var(--shadow-sm);
  border-bottom-color: var(--color-border);
}
/* Header layout: CSS grid with 3 fixed columns — guarantees clean separation
   between logo / nav / actions in BOTH LTR and RTL. */
.nav-wrap {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  height: 100%;
  column-gap: 48px;
  min-width: 0;
}
.nav-wrap > nav {
  min-width: 0;
  display: flex;
  justify-content: center;
  overflow: visible;
}
.nav-wrap > .nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.nav-logo { display: inline-flex; align-items: center; flex-shrink: 0; }
.nav-logo img,
.nav-logo .logo-svg { height: 44px; width: auto; transition: height var(--transition); display: block; }
.site-header.scrolled .nav-logo img,
.site-header.scrolled .nav-logo .logo-svg { height: 36px; }
.footer-brand .logo-svg { height: 48px; width: auto; margin-bottom: 16px; display: block; }
.landing-topbar .nav-logo .logo-svg { height: 40px; width: auto; display: block; }
.nav-menu {
  display: flex;
  gap: 4px;
  list-style: none;
  margin: 0; padding: 0;
}
.nav-menu > li { position: relative; }
.nav-menu > li > a {
  display: block;
  padding: 10px 14px;
  color: var(--color-text);
  font-weight: 500;
  font-size: 0.95rem;
  border-radius: var(--radius-button);
  white-space: nowrap;
  letter-spacing: 0.01em;
}
.nav-menu > li > a:hover,
.nav-menu > li.active > a { color: var(--color-primary); background: var(--color-bg); }
.nav-menu .has-mega > a::after {
  content: '▾'; margin-left: 6px; font-size: 0.7em; opacity: 0.7;
}
.mega-menu {
  position: absolute;
  top: 100%; left: 50%;
  transform: translateX(-50%) translateY(8px);
  background: #fff;
  min-width: 280px;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-lg);
  padding: 12px;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition);
  list-style: none;
  margin: 0;
  border: 1px solid var(--color-border);
}
.nav-menu > li:hover .mega-menu,
.nav-menu > li:focus-within .mega-menu {
  opacity: 1; visibility: visible;
  transform: translateX(-50%) translateY(0);
}
.mega-menu li a {
  display: block;
  padding: 10px 14px;
  color: var(--color-text);
  border-radius: var(--radius-button);
  font-size: 0.9rem;
}
.mega-menu li a:hover { background: var(--color-bg); color: var(--color-primary); }
.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.lang-toggle {
  background: transparent;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  padding: 6px 14px;
  font-size: 0.85rem;
  color: var(--color-text);
  font-weight: 500;
}
.lang-toggle:hover { border-color: var(--color-primary); color: var(--color-primary); }
.icon-btn {
  background: transparent;
  border: none;
  width: 40px; height: 40px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-text);
}
.icon-btn:hover { background: var(--color-bg); color: var(--color-primary); }
.nav-toggle {
  display: none;
  background: transparent;
  border: none;
  width: 40px; height: 40px;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
}
.nav-toggle span {
  display: block;
  width: 24px; height: 2px;
  background: var(--color-text);
  transition: all var(--transition);
}
.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 {
  position: relative;
  min-height: 640px;
  padding: calc(var(--header-h) + 80px) 0 80px;
  display: flex;
  align-items: center;
  color: #fff;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(13,59,66,0.85) 0%, rgba(26,110,122,0.7) 100%);
  z-index: 1;
}
.hero-bg {
  position: absolute; inset: 0;
  background-size: cover;
  background-position: center;
  z-index: 0;
}
.hero-content {
  position: relative;
  z-index: 2;
  max-width: 720px;
}
.hero h1 { color: #fff; margin-bottom: 20px; }
.hero p.lead {
  font-size: 1.2rem;
  margin-bottom: 32px;
  color: rgba(255,255,255,0.92);
  max-width: 600px;
}
.hero-ctas { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-trust {
  margin-top: 28px;
  font-size: 0.85rem;
  color: rgba(255,255,255,0.8);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.hero-sm { min-height: 420px; }

/* ---------- Stats ---------- */
.stats-bar {
  background: #fff;
  padding: 56px 0;
  border-bottom: 1px solid var(--color-border);
}
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 32px;
  text-align: center;
}
.stat-item .stat-icon {
  width: 56px; height: 56px;
  background: var(--color-bg);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
  margin-bottom: 16px;
  font-size: 1.6rem;
}
.stat-item .stat-num {
  font-size: 2.6rem;
  font-weight: 800;
  color: var(--color-secondary);
  line-height: 1;
  font-family: var(--font-heading);
}
.stat-item .stat-num .suffix { color: var(--color-accent); }
.stat-item .stat-label {
  display: block;
  margin-top: 8px;
  color: var(--color-text-muted);
  font-size: 0.95rem;
}

/* ---------- Cards Grid ---------- */
.grid {
  display: grid;
  gap: 24px;
}
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }

.card {
  background: #fff;
  border-radius: var(--radius-card);
  padding: 32px;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  border: 1px solid var(--color-border);
}
.card:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); }
.card-icon {
  width: 56px; height: 56px;
  background: var(--color-bg);
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
  margin-bottom: 20px;
  font-size: 1.5rem;
}
.card h3 { color: var(--color-secondary); margin-bottom: 12px; }
.card p { color: var(--color-text-muted); margin-bottom: 16px; }
.card .card-link {
  font-weight: 600;
  color: var(--color-primary);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.card .card-link::after { content: '→'; transition: transform var(--transition); }
.card .card-link:hover::after { transform: translateX(4px); }

.audience-card {
  background: linear-gradient(180deg, #fff 0%, var(--color-bg) 100%);
  text-align: center;
  padding: 48px 32px;
}
.audience-card .card-icon { margin-left: auto; margin-right: auto; width: 72px; height: 72px; font-size: 2rem; }

/* ---------- News cards ---------- */
.news-card {
  background: #fff;
  border-radius: var(--radius-card);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
}
.news-card:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); }
.news-card-img {
  aspect-ratio: 16 / 9;
  background-size: cover;
  background-position: center;
  background-color: var(--color-bg);
}
.news-card-body { padding: 24px; flex: 1; display: flex; flex-direction: column; }
.news-card-meta {
  font-size: 0.8rem;
  color: var(--color-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 8px;
}
.news-card h3 { font-size: 1.15rem; margin-bottom: 12px; }
.news-card p { color: var(--color-text-muted); flex: 1; }
.news-card .card-link { margin-top: 12px; }

/* ---------- Spotlight (image-driven hero break) ---------- */
.spotlight {
  position: relative;
  padding: 120px 0;
  color: #fff;
  overflow: hidden;
  margin: 0;
}
.spotlight-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  z-index: 0;
}
.spotlight-inner {
  position: relative;
  z-index: 1;
}
.spotlight h2 { color: #fff; margin-top: 12px; max-width: 720px; }

/* ---------- Image grid (visual gallery) ---------- */
.image-grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr;
  grid-template-rows: 240px 240px;
  gap: 16px;
  grid-template-areas:
    "tall a b"
    "tall c d";
}
.image-tile {
  position: relative;
  border-radius: var(--radius-card);
  background-size: cover;
  background-position: center;
  overflow: hidden;
  text-decoration: none;
  display: flex;
  align-items: flex-end;
  transition: transform var(--transition), box-shadow var(--transition);
  box-shadow: var(--shadow-sm);
  min-height: 240px;
}
.image-tile:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.image-tile-tall {
  grid-area: tall;
  min-height: 496px;
}
.image-tile:nth-child(2) { grid-area: a; }
.image-tile:nth-child(3) { grid-area: b; }
.image-tile:nth-child(4) { grid-area: c; }
.image-tile:nth-child(5) { grid-area: d; }
.image-tile-caption {
  padding: 24px;
  width: 100%;
}
.image-tile-caption h3 {
  margin: 8px 0 0;
  font-size: 1.1rem;
}
@media (max-width: 800px) {
  .image-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
    grid-template-areas:
      "tall tall"
      "a b"
      "c d";
  }
  .image-tile-tall { min-height: 320px; }
}
@media (max-width: 500px) {
  .image-grid {
    grid-template-columns: 1fr;
    grid-template-areas:
      "tall"
      "a"
      "b"
      "c"
      "d";
  }
  .image-tile-tall { min-height: 280px; }
}

/* ---------- Newsletter banner ---------- */
.newsletter {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
  color: #fff;
  padding: 64px 0;
  border-radius: var(--radius-card);
  margin: 80px auto;
  max-width: 1140px;
}
.newsletter-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  align-items: center;
  padding: 0 48px;
}
.newsletter h2 { color: #fff; margin-bottom: 8px; }
.newsletter p { color: rgba(255,255,255,0.85); margin: 0; }
.newsletter-form {
  display: flex;
  gap: 8px;
  max-width: 480px;
}
.newsletter-form input {
  flex: 1;
  padding: 14px 18px;
  border-radius: var(--radius-button);
  border: none;
  font-size: 0.95rem;
  font-family: inherit;
}
.newsletter-form input:focus { outline: 2px solid var(--color-accent); }

/* ---------- Logo carousel ---------- */
.logos {
  padding: 64px 0;
  background: #fff;
}
.logos-track {
  display: flex;
  gap: 64px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  opacity: 0.7;
  filter: grayscale(100%);
}
.logos-track .logo-item {
  font-weight: 700;
  color: var(--color-secondary);
  font-size: 1.05rem;
  padding: 12px 24px;
  background: var(--color-bg);
  border-radius: var(--radius-pill);
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-secondary);
  color: rgba(255,255,255,0.8);
  padding: 64px 0 0;
  font-size: 0.9rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 48px;
  padding-bottom: 48px;
}
.footer-grid h4 {
  color: #fff;
  font-size: 1rem;
  margin-bottom: 18px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.footer-grid ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-grid li { margin-bottom: 10px; }
.footer-grid a { color: rgba(255,255,255,0.75); }
.footer-grid a:hover { color: var(--color-accent); }
.footer-brand img { height: 48px; margin-bottom: 16px; }
.footer-brand p { color: rgba(255,255,255,0.7); }
.footer-social {
  display: flex; gap: 12px;
  margin-top: 16px;
}
.footer-social a {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  transition: all var(--transition);
}
.footer-social a:hover { background: var(--color-accent); color: var(--color-secondary); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: 24px 0;
  text-align: center;
  color: rgba(255,255,255,0.5);
  font-size: 0.85rem;
}

/* ---------- Floating buttons ---------- */
.fab-wrap {
  position: fixed;
  bottom: 24px; right: 24px;
  z-index: 999;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.fab {
  width: 56px; height: 56px;
  border-radius: 50%;
  background: #25D366;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-lg);
  transition: all var(--transition);
  font-size: 1.5rem;
}
.fab:hover { transform: scale(1.1); color: #fff; }
.fab.back-to-top {
  background: var(--color-primary);
  font-size: 1.2rem;
  opacity: 0;
  visibility: hidden;
}
.fab.back-to-top.show { opacity: 1; visibility: visible; }

/* ---------- Forms ---------- */
.form-card {
  background: #fff;
  padding: 40px;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-md);
}
.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}
.form-field { display: flex; flex-direction: column; }
.form-field label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--color-text);
  margin-bottom: 6px;
}
.form-field input,
.form-field select,
.form-field textarea {
  padding: 12px 14px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-button);
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--color-text);
  background: #fff;
  transition: border-color var(--transition);
}
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(26,110,122,0.1);
}
.form-field textarea { min-height: 120px; resize: vertical; }

/* ---------- Process timeline ---------- */
.process {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 24px;
  position: relative;
  counter-reset: step;
}
.process-step {
  background: #fff;
  padding: 32px;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-sm);
  position: relative;
  counter-increment: step;
}
.process-step::before {
  content: counter(step);
  position: absolute;
  top: -20px; left: 32px;
  width: 44px; height: 44px;
  background: var(--color-accent);
  color: var(--color-secondary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  box-shadow: var(--shadow-sm);
}
.process-step h3 { margin-top: 16px; font-size: 1.15rem; }

/* ---------- Comparison table ---------- */
.compare-table {
  width: 100%;
  border-collapse: collapse;
  background: #fff;
  border-radius: var(--radius-card);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
.compare-table th,
.compare-table td {
  padding: 16px 20px;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}
.compare-table th { background: var(--color-bg); color: var(--color-secondary); font-weight: 600; }
.compare-table .yes { color: var(--color-success); font-weight: 600; }
.compare-table .no { color: #c44; }
.compare-table tr:last-child td { border-bottom: none; }

/* ---------- FAQ Accordion ---------- */
.faq-item {
  background: #fff;
  border-radius: var(--radius-card);
  margin-bottom: 12px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}
.faq-question {
  width: 100%;
  background: transparent;
  border: none;
  padding: 20px 24px;
  text-align: left;
  font-size: 1rem;
  font-weight: 600;
  color: var(--color-secondary);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.faq-question::after {
  content: '+';
  font-size: 1.5rem;
  color: var(--color-primary);
  transition: transform var(--transition);
  flex-shrink: 0;
}
.faq-item.open .faq-question::after { transform: rotate(45deg); }
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition);
  padding: 0 24px;
  color: var(--color-text-muted);
}
.faq-item.open .faq-answer { max-height: 500px; padding-bottom: 20px; }

/* ---------- Animations ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* ---------- Testimonials ---------- */
.testimonial {
  background: #fff;
  padding: 32px;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-sm);
  border-left: 4px solid var(--color-accent);
}
.testimonial blockquote {
  margin: 0 0 20px;
  font-style: italic;
  color: var(--color-text);
  font-size: 1.05rem;
  line-height: 1.6;
}
.testimonial-author {
  display: flex;
  gap: 12px;
  align-items: center;
}
.testimonial-avatar {
  width: 48px; height: 48px;
  border-radius: 50%;
  background: var(--color-bg);
  background-size: cover;
  background-position: center;
}
.testimonial-meta strong { display: block; color: var(--color-secondary); }
.testimonial-meta span { font-size: 0.85rem; color: var(--color-text-muted); }

/* ---------- Pill / badge ---------- */
.pill {
  display: inline-block;
  padding: 4px 12px;
  border-radius: var(--radius-pill);
  background: var(--color-bg);
  color: var(--color-primary);
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

/* ---------- Page header (non-hero pages) ---------- */
.page-hero {
  padding: calc(var(--header-h) + 60px) 0 60px;
  background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-primary) 100%);
  color: #fff;
  text-align: center;
}
.page-hero h1 { color: #fff; margin-bottom: 12px; }
.page-hero p { color: rgba(255,255,255,0.85); font-size: 1.1rem; max-width: 640px; margin: 0 auto; }

/* ---------- Search / filter bar ---------- */
.search-bar {
  background: #fff;
  padding: 24px;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-md);
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 1fr auto;
  gap: 12px;
  margin-top: -40px;
  position: relative;
  z-index: 5;
}
.search-bar select,
.search-bar input {
  padding: 12px 14px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-button);
  font-family: inherit;
  font-size: 0.9rem;
  background: #fff;
}

/* ---------- Hospitals featured ---------- */
.hospital-card {
  background: #fff;
  border-radius: var(--radius-card);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
}
.hospital-card:hover { box-shadow: var(--shadow-md); transform: translateY(-4px); }
.hospital-card-img {
  aspect-ratio: 16 / 9;
  background-size: cover;
  background-position: center;
}
.hospital-card-body { padding: 24px; }
.hospital-card .specialties {
  display: flex; flex-wrap: wrap; gap: 6px;
  margin: 12px 0;
}
.hospital-card .specialties .pill { font-size: 0.7rem; }

/* ---------- Timeline ---------- */
.timeline {
  position: relative;
  padding: 20px 0;
}
.timeline::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0; bottom: 0;
  width: 2px;
  background: var(--color-border);
  transform: translateX(-50%);
}
.timeline-item {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 24px;
  align-items: center;
  margin-bottom: 32px;
}
.timeline-item .year {
  background: var(--color-accent);
  color: var(--color-secondary);
  font-weight: 700;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  font-size: 0.9rem;
}
.timeline-item .content {
  background: #fff;
  padding: 20px;
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-sm);
}
.timeline-item:nth-child(even) .content { grid-column: 3; }
.timeline-item:nth-child(even) .year-cell { grid-column: 2; }
.timeline-item:nth-child(odd) .content { grid-column: 1; text-align: right; }
.timeline-item:nth-child(odd) .placeholder { grid-column: 3; }

/* ---------- Landing pages: Top bar (no nav) ---------- */
.landing-topbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: #fff;
  border-bottom: 1px solid var(--color-border);
  padding: 16px 0;
  box-shadow: var(--shadow-sm);
}
.landing-topbar .nav-wrap { gap: 16px; }
.landing-topbar .topbar-right {
  display: flex;
  gap: 16px;
  align-items: center;
  font-weight: 600;
  color: var(--color-secondary);
}
.landing-topbar .topbar-right a { color: var(--color-secondary); display: inline-flex; align-items: center; gap: 6px; }
.landing-topbar .topbar-right a:hover { color: var(--color-primary); }

/* ---------- Mobile / laptop: hamburger kicks in early so we never have a cramped horizontal nav ---------- */
@media (max-width: 1280px) {
  .nav-toggle { display: flex; }
  .nav-menu {
    position: fixed;
    top: var(--header-h);
    left: 0; right: 0;
    background: #fff;
    flex-direction: column;
    padding: 24px;
    gap: 4px;
    box-shadow: var(--shadow-md);
    transform: translateX(-100%);
    transition: transform var(--transition);
    border-top: 1px solid var(--color-border);
    max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
  }
  .nav-menu.open { transform: translateX(0); }
  .nav-menu > li > a { padding: 16px; border-radius: var(--radius-button); }
  .mega-menu {
    position: static;
    transform: none;
    box-shadow: none;
    border: none;
    opacity: 1; visibility: visible;
    padding-left: 16px;
    min-width: 0;
  }
  .nav-actions .btn { display: none; }
  .nav-actions .lang-toggle, .nav-actions .icon-btn { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .newsletter-inner { grid-template-columns: 1fr; padding: 0 24px; }
  .timeline::before { left: 20px; }
  .timeline-item { grid-template-columns: 50px 1fr; gap: 16px; }
  .timeline-item .content,
  .timeline-item:nth-child(odd) .content,
  .timeline-item:nth-child(even) .content {
    grid-column: 2;
    text-align: left;
  }
  .timeline-item .year-cell,
  .timeline-item:nth-child(even) .year-cell { grid-column: 1; }
  .timeline-item .placeholder { display: none; }
  .search-bar { grid-template-columns: 1fr; }
  .section { padding: 56px 0; }
  .hero { min-height: 540px; padding: calc(var(--header-h) + 48px) 0 48px; }
}

@media (max-width: 600px) {
  .footer-grid { grid-template-columns: 1fr; }
  .stats-grid { gap: 24px; }
  .stat-item .stat-num { font-size: 2rem; }
  .form-card { padding: 24px; }
  .hero-ctas { flex-direction: column; align-items: stretch; }
  .hero-ctas .btn { justify-content: center; }
}

/* ---------- RTL / Arabic ---------- */
html[lang="ar"] {
  --font-sans: 'Cairo', 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-heading: 'Cairo', 'Inter', -apple-system, sans-serif;
}
html[lang="ar"] body { font-family: var(--font-sans); }
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3, html[lang="ar"] h4 { font-family: var(--font-heading); letter-spacing: 0; }
html[lang="ar"] .eyebrow,
html[lang="ar"] .stat-label,
html[lang="ar"] .news-card-meta,
html[lang="ar"] .hero-trust { letter-spacing: 0; }

html[dir="rtl"] .nav-menu .has-mega > a::after { margin-right: 6px; margin-left: 0; }
html[dir="rtl"] .card .card-link::after { content: '←'; }
html[dir="rtl"] .card .card-link:hover::after { transform: translateX(-4px); }
html[dir="rtl"] .fab-wrap { right: auto; left: 24px; }
html[dir="rtl"] .testimonial { border-left: none; border-right: 4px solid var(--color-accent); }
html[dir="rtl"] .process-step::before { left: auto; right: 32px; }
html[dir="rtl"] .timeline::before { left: auto; right: 50%; transform: translateX(50%); }
html[dir="rtl"] .timeline-item:nth-child(odd) .content { text-align: right; }
html[dir="rtl"] .timeline-item:nth-child(even) .content { text-align: right; }
html[dir="rtl"] .footer-grid { text-align: right; }
html[dir="rtl"] ul { padding-left: 0; padding-right: 1.25em; }
html[dir="rtl"] .form-field { text-align: right; }
html[dir="rtl"] .compare-table th,
html[dir="rtl"] .compare-table td { text-align: right; }
html[dir="rtl"] .faq-question { text-align: right; }
html[dir="rtl"] .faq-answer { text-align: right; }

/* Header in RTL: dir="rtl" naturally reverses flex visual order — DO NOT add row-reverse
   (that would cancel the reversal and put items back in LTR order). */
html[dir="rtl"] .nav-menu > li > a { font-family: var(--font-sans); }
html[dir="rtl"] .mega-menu li a { text-align: right; }
html[dir="rtl"] .mega-menu li { padding-right: 0; }

/* Hero text alignment in RTL */
html[dir="rtl"] .hero-content { text-align: right; }
html[dir="rtl"] .hero-trust { text-align: right; }

/* Cards in RTL */
html[dir="rtl"] .card { text-align: right; }
html[dir="rtl"] .card-icon { margin-left: 0; margin-right: 0; }
html[dir="rtl"] .audience-card .card-icon { margin-left: auto; margin-right: auto; }
html[dir="rtl"] .audience-card { text-align: center; }
html[dir="rtl"] .stat-item { text-align: center; }

/* Form rows in RTL */
html[dir="rtl"] .form-row,
html[dir="rtl"] .search-bar { direction: rtl; }
html[dir="rtl"] input,
html[dir="rtl"] textarea,
html[dir="rtl"] select { text-align: right; }

/* Mobile nav slide-in from right in RTL */
@media (max-width: 1280px) {
  html[dir="rtl"] .nav-menu { left: auto; right: 0; transform: translateX(100%); }
  html[dir="rtl"] .nav-menu.open { transform: translateX(0); }
  html[dir="rtl"] .nav-wrap { flex-direction: row; }
  html[dir="rtl"] .nav-actions { flex-direction: row; }
  html[dir="rtl"] .mega-menu { transform: none; left: 0; }
}

/* News card metadata + body in RTL */
html[dir="rtl"] .news-card-body,
html[dir="rtl"] .hospital-card-body { text-align: right; }
html[dir="rtl"] .specialties { justify-content: flex-end; }

/* Section heads center stays center, but use right-align for body content */
html[dir="rtl"] .section-head { text-align: center; }
html[dir="rtl"] .section-head p { text-align: center; }
@media (max-width: 1280px) {
  html[dir="rtl"] .timeline::before { left: auto; right: 20px; transform: none; }
}

/* Language toggle button */
.lang-toggle {
  min-width: 56px;
  text-align: center;
  font-weight: 600;
}

/* ---------- Table responsive wrapper (added by JS) ---------- */
.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: var(--radius-card);
  margin: 0 -4px;
}
.table-scroll .compare-table { min-width: 560px; margin: 0; }

/* ---------- Mobile improvements (smaller phones) ---------- */
@media (max-width: 600px) {
  :root {
    --container-pad: 16px;
    --header-h: 64px;
    --header-h-scrolled: 56px;
  }
  .section { padding: 48px 0; }
  .section-head { margin-bottom: 32px; }
  .hero { min-height: auto; padding: calc(var(--header-h) + 40px) 0 40px; }
  .hero h1 { font-size: 1.85rem; }
  .hero p.lead { font-size: 1rem; }
  .hero-trust { font-size: 0.75rem; }
  .stats-bar { padding: 36px 0; }
  .stat-item .stat-icon { width: 44px; height: 44px; margin-bottom: 10px; }
  .card { padding: 24px; }
  .audience-card { padding: 32px 24px; }
  .form-card { padding: 20px; }
  .newsletter { padding: 40px 0; margin: 48px auto; }
  .newsletter-inner { padding: 0 20px; }
  .newsletter h2 { font-size: 1.4rem; }
  .newsletter-form { flex-direction: column; }
  .newsletter-form input,
  .newsletter-form .btn { width: 100%; }
  .news-card-body { padding: 18px; }
  .nav-logo img { height: 32px; }
  .nav-actions .btn-accent { padding: 10px 16px; font-size: 0.85rem; }
  .page-hero { padding: calc(var(--header-h) + 40px) 0 40px; }
  .page-hero h1 { font-size: 1.7rem; }
  .page-hero p { font-size: 1rem; }
  .process-step { padding: 24px; }
  .process-step::before { top: -16px; left: 24px; width: 36px; height: 36px; font-size: 0.95rem; }
  html[dir="rtl"] .process-step::before { left: auto; right: 24px; }
  .timeline-item .content { padding: 16px; font-size: 0.9rem; }
  .testimonial { padding: 24px; }
  .testimonial blockquote { font-size: 0.95rem; }
  .hospital-card-body { padding: 20px; }
  .footer-grid { gap: 28px; padding-bottom: 32px; }
  .site-footer { padding: 48px 0 0; }
  .faq-question { padding: 16px 18px; font-size: 0.95rem; }
  .faq-answer { padding: 0 18px; }
  .faq-item.open .faq-answer { padding-bottom: 16px; }
  /* Featured news article on news.html: stack on mobile */
  article[style*="grid-template-columns: 1.2fr 1fr"] { grid-template-columns: 1fr !important; }
  article[style*="grid-template-columns: 1.2fr 1fr"] > div[style*="padding:48px"] { padding: 24px !important; }
  /* Landing topbar — wrap nicely */
  .landing-topbar { padding: 12px 0; }
  .landing-topbar .nav-wrap { flex-wrap: wrap; gap: 12px; row-gap: 8px; }
  .landing-topbar .topbar-right { gap: 10px; font-size: 0.85rem; flex-wrap: wrap; }
  .landing-topbar .topbar-right .btn { padding: 8px 14px !important; font-size: 0.8rem; }
  .landing-topbar .topbar-right svg { width: 14px; height: 14px; }
  /* Maps shorter on mobile */
  iframe[src*="google.com/maps"] { height: 220px !important; }
  /* Tap targets >= 44px */
  .btn { min-height: 44px; }
  .icon-btn,
  .nav-toggle { width: 44px; height: 44px; }
  .faq-question { min-height: 56px; }
}

/* ---------- Utility ---------- */
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.text-muted { color: var(--color-text-muted); }
.text-accent { color: var(--color-accent); }
.text-primary { color: var(--color-primary); }
