/**
 * نبض للرعاية الطبية - Nabd Medical Care
 * نظام التنسيق الموحد والكامل والمحسّن (style.css)
 * CSS3 مع Logical Properties، دعم RTL/LTR، وتحسينات كاملة للهيرو والشريط العلوي وشاشات الموبايل (360px+)
 */

@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;500;600;700;800&family=Inter:wght@400;500;600;700;800&display=swap');

/* ==========================================================================
   1) المتغيرات الأساسية للهوية البصرية
   ========================================================================== */
:root {
  --teal: #0E8A8A;
  --teal-dark: #0A6969;
  --teal-light: #16A8A8;
  --teal-soft: rgba(14, 138, 138, 0.1);
  --navy: #0B3C5D;
  --navy-dark: #07253B;
  --navy-light: #155582;
  --mint: #E6F5F3;
  --mint-light: #F0FAF8;
  --coral: #FF6B5E;
  --coral-light: #FFEAE8;
  --coral-dark: #E65042;
  --white: #FFFFFF;
  --light: #F6FAFA;
  --surface: #FFFFFF;
  --text: #1F2D3D;
  --text-muted: #586B7D;
  --text-light: #8A9CAE;
  --border: #DDE7EB;
  --border-focus: #0E8A8A;
  --border-light: #EDF3F5;
  
  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-xl: 28px;
  --radius-full: 9999px;

  --shadow-xs: 0 1px 3px rgba(11, 60, 93, 0.04);
  --shadow-sm: 0 3px 10px rgba(11, 60, 93, 0.06);
  --shadow-md: 0 8px 24px rgba(11, 60, 93, 0.08);
  --shadow-lg: 0 16px 40px rgba(11, 60, 93, 0.12);
  --shadow-teal: 0 6px 18px rgba(14, 138, 138, 0.22);

  --transition-fast: 0.18s ease;
  --transition-normal: 0.28s ease;

  --font-ar: 'Cairo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-en: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ==========================================================================
   2) ضبط الصندوق ومنع الخروج عن الشاشة (Zero Horizontal Overflow)
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
}

html, body {
  max-width: 100%;
  overflow-x: hidden;
  margin: 0;
  padding: 0;
}

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

html[lang="ar"], body[lang="ar"] {
  font-family: var(--font-ar);
  direction: rtl;
  text-align: right;
}

html[lang="en"], body[lang="en"] {
  font-family: var(--font-en);
  direction: ltr;
  text-align: left;
}

body {
  background-color: var(--light);
  color: var(--text);
  line-height: 1.65;
  font-size: 16px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* انعكاس الأيقونات الاتجاهية */
[dir="rtl"] .dir-flip {
  transform: scaleX(1);
}
[dir="ltr"] .dir-flip {
  transform: scaleX(-1);
}

img, video, iframe {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  box-sizing: border-box;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

ul, ol {
  list-style: none;
  padding: 0;
  margin: 0;
}

/* ==========================================================================
   3) الحاويات والأقسام (Containers & Typography)
   ========================================================================== */
.container {
  width: 100%;
  max-width: 1220px;
  margin-inline: auto;
  padding-inline: 20px;
}

.container-narrow {
  width: 100%;
  max-width: 860px;
  margin-inline: auto;
  padding-inline: 20px;
}

.section {
  padding-block: 68px;
}

.section-mint {
  background-color: var(--mint);
}

.section-white {
  background-color: var(--white);
}

.section-light {
  background-color: var(--light);
}

.section-header {
  text-align: center;
  max-width: 660px;
  margin-inline: auto;
  margin-bottom: 44px;
}

.badge-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  background-color: var(--mint);
  color: var(--teal-dark);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.section-title {
  color: var(--navy);
  font-size: clamp(1.4rem, 5.5vw, 2.2rem);
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 12px;
}

.section-subtitle {
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.65;
}

/* ==========================================================================
   4) الأزرار (Buttons)
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.95rem;
  min-height: 44px;
  transition: all var(--transition-normal);
  text-align: center;
  white-space: nowrap;
}

.btn-primary {
  background-color: var(--teal);
  color: var(--white);
  box-shadow: var(--shadow-teal);
}
.btn-primary:hover {
  background-color: var(--teal-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(14, 138, 138, 0.32);
}

.btn-secondary {
  background-color: var(--navy);
  color: var(--white);
}
.btn-secondary:hover {
  background-color: var(--navy-dark);
  transform: translateY(-2px);
}

.btn-outline {
  background-color: transparent;
  color: var(--teal);
  border: 1.8px solid var(--teal);
}
.btn-outline:hover {
  background-color: var(--teal);
  color: var(--white);
}

.btn-outline-navy {
  background-color: transparent;
  color: var(--navy);
  border: 1.8px solid var(--navy);
}
.btn-outline-navy:hover {
  background-color: var(--navy);
  color: var(--white);
}

.btn-white {
  background-color: var(--white);
  color: var(--navy);
  box-shadow: var(--shadow-sm);
}
.btn-white:hover {
  background-color: var(--mint);
  color: var(--teal-dark);
}

.btn-sm {
  padding: 7px 15px;
  font-size: 0.88rem;
  min-height: 38px;
  border-radius: var(--radius-sm);
}

.btn-lg {
  padding: 14px 28px;
  font-size: 1rem;
  min-height: 48px;
  border-radius: var(--radius-md);
}

.btn-block {
  width: 100%;
}

/* ==========================================================================
   5) الشريط العلوي المضغوط (Top Bar: 36-40px، سطر واحد)
   ========================================================================== */
.site-topbar {
  background-color: var(--navy);
  color: rgba(255, 255, 255, 0.92);
  height: 38px;
  display: flex;
  align-items: center;
  font-size: 13px;
  line-height: 1;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.topbar-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  white-space: nowrap;
  gap: 16px;
  overflow: hidden;
}

.topbar-contacts {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.topbar-emergency {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--coral-light);
  font-weight: 700;
}

.topbar-emergency svg,
.topbar-phone-link svg,
.topbar-hours svg {
  width: 16px !important;
  height: 16px !important;
  flex-shrink: 0;
  display: inline-block;
  vertical-align: middle;
}

.topbar-pulse {
  width: 7px;
  height: 7px;
  background-color: var(--coral);
  border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(255, 107, 94, 0.7);
  animation: pulse-coral 2s infinite;
  display: inline-block;
  flex-shrink: 0;
}

@keyframes pulse-coral {
  0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(255, 107, 94, 0.7); }
  70% { transform: scale(1); box-shadow: 0 0 0 6px rgba(255, 107, 94, 0); }
  100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(255, 107, 94, 0); }
}

.topbar-sep {
  opacity: 0.35;
  font-size: 11px;
}

.topbar-phone-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--mint);
  font-weight: 700;
}

.topbar-hours-wrap {
  display: inline-flex;
  align-items: center;
}

.topbar-hours {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: rgba(255, 255, 255, 0.85);
}

/* ==========================================================================
   6) الهيدر وشريط التنقل الرئيسي (70px ديسكتوب / 60px موبايل مع Scrolled)
   ========================================================================== */
.site-navbar {
  background-color: var(--white);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 1000;
  height: 70px;
  transition: height var(--transition-fast), box-shadow var(--transition-fast);
}

.site-navbar.scrolled {
  height: 62px;
  box-shadow: 0 4px 18px rgba(11, 60, 93, 0.08);
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  padding-inline: 20px;
  max-width: 1220px;
  margin-inline: auto;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  min-width: 0;
}

.brand-logo-img {
  width: 42px;
  height: 42px;
  object-fit: contain;
  border-radius: var(--radius-sm);
  flex-shrink: 0;
  transition: width var(--transition-fast), height var(--transition-fast);
}

.site-navbar.scrolled .brand-logo-img {
  width: 36px;
  height: 36px;
}

.brand-texts {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.brand-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--navy);
  line-height: 1.15;
  white-space: nowrap;
}

.brand-subtitle {
  font-size: 0.74rem;
  color: var(--teal);
  font-weight: 600;
  white-space: nowrap;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 20px;
}

.nav-link {
  font-weight: 600;
  font-size: 0.94rem;
  color: var(--text);
  padding: 6px 4px;
  position: relative;
  transition: color var(--transition-fast);
  white-space: nowrap;
}

.nav-link:hover {
  color: var(--teal);
}

.nav-link.active {
  color: var(--teal);
  font-weight: 700;
}

.nav-link.active::after {
  content: '';
  position: absolute;
  bottom: -2px;
  inset-inline-start: 4px;
  inset-inline-end: 4px;
  height: 3px;
  background-color: var(--teal);
  border-radius: var(--radius-full);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.lang-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  background-color: var(--mint);
  color: var(--teal-dark);
  font-weight: 700;
  font-size: 0.86rem;
  border: 1px solid rgba(14, 138, 138, 0.22);
  transition: all var(--transition-fast);
}

.lang-btn:hover {
  background-color: var(--teal);
  color: var(--white);
}

.lang-text-mobile {
  display: none;
}

.nav-hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 8px;
  border-radius: var(--radius-sm);
  background-color: var(--light);
}

.nav-hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--navy);
  border-radius: 2px;
  transition: all var(--transition-fast);
}

.nav-hamburger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-hamburger.open span:nth-child(2) {
  opacity: 0;
}
.nav-hamburger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* القائمة الجانبية للموبايل */
.mobile-drawer {
  position: fixed;
  top: 0;
  inset-inline-end: -320px;
  width: 300px;
  max-width: 85vw;
  height: 100vh;
  background-color: var(--white);
  box-shadow: var(--shadow-lg);
  z-index: 1200;
  transition: inset-inline-end var(--transition-normal);
  display: flex;
  flex-direction: column;
  padding: 22px;
  overflow-y: auto;
}

.mobile-drawer.open {
  inset-inline-end: 0;
}

.drawer-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(11, 60, 93, 0.45);
  backdrop-filter: blur(2px);
  z-index: 1150;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-normal);
}

.drawer-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-light);
}

.drawer-close {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  background-color: var(--light);
  color: var(--navy);
}

.drawer-menu {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.drawer-link {
  display: flex;
  align-items: center;
  padding: 11px 14px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 1rem;
  color: var(--navy);
  transition: all var(--transition-fast);
}

.drawer-link:hover, .drawer-link.active {
  background-color: var(--mint);
  color: var(--teal-dark);
}

/* ==========================================================================
   7) الهيرو: صورة واضحة وتدرج جانبي خفيف خلف النص فقط
   ========================================================================== */
.hero-section {
  position: relative;
  background-color: var(--navy-dark);
  color: var(--white);
  overflow: hidden;
  height: 72vh;
  min-height: 480px;
  max-height: 580px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.hero-slider-wrap {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  pointer-events: none;
}

.hero-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.hero-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 25%;
}

/* التدرج الجانبي: شفاف فوق الصورة ومكثف خلف النص فقط بدون حجب الصورة */
.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
}

/* في العربية: من اليمين (0.80) يتلاشى لشفافية كاملة عند منتصف الصورة تقريباً */
[dir="rtl"] .hero-overlay,
html[lang="ar"] .hero-overlay {
  background: linear-gradient(
    to left,
    rgba(11, 60, 93, 0.82) 0%,
    rgba(11, 60, 93, 0.70) 25%,
    rgba(11, 60, 93, 0.35) 45%,
    rgba(11, 60, 93, 0.08) 58%,
    rgba(11, 60, 93, 0) 70%,
    rgba(11, 60, 93, 0) 100%
  );
}

/* في الإنجليزية: من اليسار (0.80) يتلاشى لشفافية كاملة عند منتصف الصورة */
[dir="ltr"] .hero-overlay,
html[lang="en"] .hero-overlay {
  background: linear-gradient(
    to right,
    rgba(11, 60, 93, 0.82) 0%,
    rgba(11, 60, 93, 0.70) 25%,
    rgba(11, 60, 93, 0.35) 45%,
    rgba(11, 60, 93, 0.08) 58%,
    rgba(11, 60, 93, 0) 70%,
    rgba(11, 60, 93, 0) 100%
  );
}

.hero-content {
  position: relative;
  z-index: 3;
  padding-block: 40px;
}

.hero-text-block {
  max-width: 620px;
  margin-bottom: 0;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background-color: rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(4px);
  padding: 5px 14px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--mint);
  margin-bottom: 14px;
}

.hero-title {
  font-size: clamp(1.6rem, 6.5vw, 2.5rem);
  font-weight: 800;
  line-height: 1.35;
  margin-bottom: 14px;
  color: var(--white);
  text-shadow: 0 2px 8px rgba(7, 37, 59, 0.55);
}

.hero-subtitle {
  font-size: 1.02rem;
  line-height: 1.7;
  color: rgba(255, 255, 255, 0.95);
  margin-bottom: 24px;
  text-shadow: 0 1px 4px rgba(7, 37, 59, 0.4);
}

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

.hero-slider-dots {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.4);
  transition: all var(--transition-fast);
}

.hero-dot.active {
  width: 28px;
  border-radius: var(--radius-full);
  background-color: var(--teal-light);
}

/* شريط الحجز السريع المتموضع تحت الهيرو */
.hero-quickbar-section {
  position: relative;
  z-index: 10;
  margin-top: -38px;
  padding-bottom: 24px;
}

.hero-quick-bar {
  background-color: var(--white);
  color: var(--text);
  border-radius: var(--radius-lg);
  padding: 22px 26px;
  box-shadow: 0 10px 32px rgba(11, 60, 93, 0.12);
  border: 1px solid var(--border-light);
  margin-top: 0;
  position: relative;
  z-index: 4;
}

.quick-bar-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.quick-bar-grid {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 14px;
  align-items: flex-end;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.form-label {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--navy);
}

.form-control, .form-select {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background-color: var(--white);
  color: var(--text);
  font-size: 0.92rem;
  min-height: 44px;
  transition: all var(--transition-fast);
  outline: none;
}

.form-control:focus, .form-select:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(14, 138, 138, 0.15);
}

/* ==========================================================================
   8) شريط المزايا (Features Strip)
   ========================================================================== */
.features-strip {
  background-color: var(--white);
  border-bottom: 1px solid var(--border-light);
  padding-block: 32px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.feature-box {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.feature-icon-wrap {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  border-radius: var(--radius-md);
  background-color: var(--mint);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-text h4 {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--navy);
  margin-bottom: 2px;
}

.feature-text p {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ==========================================================================
   9) بطاقات التخصصات (Specialties Cards)
   ========================================================================== */
.specialties-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.specialty-card {
  background-color: var(--white);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  transition: all var(--transition-normal);
  text-decoration: none;
  box-shadow: var(--shadow-xs);
}

.specialty-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: rgba(14, 138, 138, 0.3);
}

.specialty-icon-box {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-md);
  background-color: var(--mint);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  transition: all var(--transition-normal);
}

.specialty-card:hover .specialty-icon-box {
  background-color: var(--teal);
  color: var(--white);
}

.specialty-name {
  font-size: 1.08rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 8px;
}

.specialty-desc {
  font-size: 0.86rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 16px;
  flex-grow: 1;
}

.specialty-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--teal);
  margin-top: auto;
}

/* ==========================================================================
   10) بطاقات الأطباء (Doctors Cards)
   ========================================================================== */
.doctors-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

.doctor-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all var(--transition-normal);
  box-shadow: var(--shadow-xs);
}

.doctor-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: rgba(14, 138, 138, 0.25);
}

.doctor-img-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 5;
  background: linear-gradient(135deg, var(--navy), var(--teal));
  overflow: hidden;
}

.doctor-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-normal);
}

.doctor-card:hover .doctor-img-wrap img {
  transform: scale(1.03);
}

.doctor-badge-today {
  position: absolute;
  top: 12px;
  inset-inline-start: 12px;
  background-color: var(--coral);
  color: var(--white);
  font-size: 0.74rem;
  font-weight: 800;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  box-shadow: 0 4px 10px rgba(255, 107, 94, 0.35);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.doctor-avatar-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #155582, #0E8A8A);
  color: var(--white);
  font-size: 2.2rem;
  font-weight: 800;
}

.doctor-card-body {
  padding: 18px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.doctor-specialty-tag {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--teal);
  margin-bottom: 4px;
}

.doctor-name {
  font-size: 1.12rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 4px;
}

.doctor-title-sub {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
  margin-bottom: 12px;
}

.doctor-meta-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 8px;
  border-top: 1px solid var(--border-light);
  border-bottom: 1px solid var(--border-light);
  font-size: 0.82rem;
  margin-bottom: 12px;
}

.doctor-rating {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-weight: 700;
  color: #F59E0B;
}

.doctor-price-box {
  margin-bottom: 14px;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.doctor-price-num {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--navy);
}

.doctor-card-actions {
  display: flex;
  gap: 8px;
  margin-top: auto;
}

/* ==========================================================================
   11) كيف تطلب موعدك؟ والأنماط الأخرى
   ========================================================================== */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.step-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  padding: 30px 24px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  text-align: center;
}

.step-number {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--teal), var(--navy));
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  font-weight: 800;
  margin-inline: auto;
  margin-bottom: 16px;
  box-shadow: var(--shadow-teal);
}

.step-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 10px;
}

.step-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.6;
}

/* أنواع الاستشارات */
.modes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.mode-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  padding: 30px 24px;
  border: 2px solid var(--border-light);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all var(--transition-normal);
}

.mode-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--teal);
}

.mode-card.featured {
  border-color: var(--teal);
}

.mode-badge {
  position: absolute;
  top: -11px;
  inset-inline-start: 24px;
  background-color: var(--teal);
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 800;
  padding: 3px 10px;
  border-radius: var(--radius-full);
}

.mode-icon {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-md);
  background-color: var(--mint);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.mode-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 4px;
}

.mode-tagline {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.mode-price-wrap {
  display: flex;
  align-items: baseline;
  gap: 5px;
  margin-bottom: 20px;
}

.mode-price-num {
  font-size: 2rem;
  font-weight: 800;
  color: var(--navy);
}

.mode-price-currency {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--teal);
}

.mode-features-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 24px;
  flex-grow: 1;
}

.mode-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.88rem;
  color: var(--text);
}

.mode-feature-item svg {
  color: var(--teal);
  flex-shrink: 0;
  margin-top: 2px;
}

/* العدادات المتحركة */
.stats-banner {
  background: linear-gradient(135deg, var(--navy) 0%, var(--teal-dark) 100%);
  color: var(--white);
  padding-block: 54px;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  text-align: center;
}

.stat-number {
  font-size: 2.6rem;
  font-weight: 800;
  color: var(--white);
  line-height: 1.1;
  margin-bottom: 6px;
}

.stat-label {
  font-size: 0.92rem;
  color: var(--mint);
  font-weight: 600;
}

/* معرض المرافق */
.facilities-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.facility-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  cursor: pointer;
  transition: all var(--transition-normal);
}

.facility-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.facility-img-wrap {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.facility-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-normal);
}

.facility-card:hover .facility-img-wrap img {
  transform: scale(1.04);
}

.facility-zoom-btn {
  position: absolute;
  inset: 0;
  background-color: rgba(11, 60, 93, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  opacity: 0;
  transition: opacity var(--transition-fast);
}

.facility-card:hover .facility-zoom-btn {
  opacity: 1;
}

.facility-info {
  padding: 18px;
}

.facility-title {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 6px;
}

.facility-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* Lightbox */
.lightbox-modal {
  position: fixed;
  inset: 0;
  background-color: rgba(7, 37, 59, 0.92);
  backdrop-filter: blur(4px);
  z-index: 1500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-fast);
}

.lightbox-modal.open {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-content {
  max-width: 900px;
  width: 100%;
  background-color: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  position: relative;
}

.lightbox-close {
  position: absolute;
  top: 12px;
  inset-inline-end: 12px;
  width: 36px;
  height: 36px;
  background-color: rgba(11, 60, 93, 0.85);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
  cursor: pointer;
}

.lightbox-img {
  width: 100%;
  max-height: 500px;
  object-fit: cover;
}

.lightbox-caption {
  padding: 18px 20px;
}

.lightbox-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 4px;
}

.lightbox-desc {
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* آراء المرضى */
.testimonials-slider {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 22px;
}

.testimonial-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  padding: 26px 22px;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-xs);
  display: flex;
  flex-direction: column;
}

.testimonial-stars {
  display: flex;
  gap: 3px;
  color: #F59E0B;
  margin-bottom: 12px;
}

.testimonial-text {
  font-size: 0.95rem;
  color: var(--text);
  line-height: 1.65;
  margin-bottom: 20px;
  flex-grow: 1;
}

.testimonial-patient {
  display: flex;
  align-items: center;
  gap: 12px;
}

.testimonial-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--teal), var(--navy));
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.95rem;
}

.testimonial-name {
  font-weight: 800;
  font-size: 0.98rem;
  color: var(--navy);
}

.testimonial-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* بانر CTA */
.cta-banner-wrap {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  color: var(--white);
  text-align: center;
  padding-block: 60px;
  padding-inline: 20px;
  margin-block: 36px;
  box-shadow: var(--shadow-lg);
}

.cta-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
}

.cta-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(11, 60, 93, 0.92) 0%, rgba(14, 138, 138, 0.84) 100%);
  z-index: 2;
}

.cta-inner {
  position: relative;
  z-index: 3;
  max-width: 620px;
  margin-inline: auto;
}

.cta-title {
  font-size: clamp(1.4rem, 5vw, 2.1rem);
  font-weight: 800;
  margin-bottom: 12px;
  line-height: 1.3;
}

.cta-subtitle {
  font-size: 1rem;
  line-height: 1.6;
  opacity: 0.95;
  margin-bottom: 26px;
}

/* ==========================================================================
   12) الفوتر الداكن والأزرار العائمة
   ========================================================================== */
.site-footer {
  background-color: var(--navy-dark);
  color: rgba(255, 255, 255, 0.8);
  padding-top: 56px;
  margin-top: auto;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1.2fr 1.8fr;
  gap: 32px;
  margin-bottom: 40px;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.footer-brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.footer-logo-img {
  width: 40px;
  height: 40px;
  object-fit: contain;
}

.footer-brand-title {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--white);
}

.footer-desc {
  font-size: 0.86rem;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.72);
}

.footer-col-title {
  font-size: 1rem;
  font-weight: 800;
  color: var(--white);
  margin-bottom: 16px;
  position: relative;
  padding-bottom: 6px;
}

.footer-col-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  inset-inline-start: 0;
  width: 28px;
  height: 2.5px;
  background-color: var(--teal);
  border-radius: var(--radius-full);
}

.footer-links-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.footer-link {
  font-size: 0.88rem;
  color: rgba(255, 255, 255, 0.75);
  transition: all var(--transition-fast);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.footer-link:hover {
  color: var(--mint);
  transform: translateX(-3px);
}
[dir="ltr"] .footer-link:hover {
  transform: translateX(3px);
}

.footer-contact-list {
  display: flex;
  flex-direction: column;
  gap: 11px;
  font-size: 0.86rem;
}

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.footer-contact-item svg {
  color: var(--teal-light);
  flex-shrink: 0;
  margin-top: 3px;
}

.footer-social-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
}

.social-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.08);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.social-btn:hover {
  background-color: var(--teal);
  transform: translateY(-2px);
}

.footer-disclaimers {
  background-color: rgba(0, 0, 0, 0.22);
  padding: 18px 20px;
  border-radius: var(--radius-md);
  margin-bottom: 28px;
  font-size: 0.8rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.65);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.footer-bottom {
  padding-block: 18px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.82rem;
  text-align: center;
  color: rgba(255, 255, 255, 0.65);
}

/* الأزرار العائمة */
.floating-widgets {
  position: fixed;
  bottom: 22px;
  inset-inline-end: 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 1040;
}

.whatsapp-float-btn {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background-color: #25D366;
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 6px 18px rgba(37, 211, 102, 0.4);
  transition: all var(--transition-fast);
  position: relative;
}

.whatsapp-float-btn:hover {
  transform: scale(1.06);
}

.whatsapp-pulse {
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 2px solid #25D366;
  animation: pulse-wa 2.2s infinite;
  pointer-events: none;
}

@keyframes pulse-wa {
  0% { transform: scale(0.95); opacity: 0.8; }
  70% { transform: scale(1.2); opacity: 0; }
  100% { transform: scale(1.2); opacity: 0; }
}

.back-to-top-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--navy);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-fast);
  opacity: 0;
  pointer-events: none;
  align-self: center;
}

.back-to-top-btn.visible {
  opacity: 1;
  pointer-events: auto;
}

.back-to-top-btn:hover {
  background-color: var(--teal);
  transform: translateY(-2px);
}

/* الشريط الثابت السفلي على الموبايل */
.mobile-bottom-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 56px;
  background-color: var(--white);
  border-top: 1px solid var(--border);
  box-shadow: 0 -3px 14px rgba(11, 60, 93, 0.08);
  z-index: 1030;
  align-items: center;
  justify-content: space-around;
  padding-inline: 8px;
}

.mobile-bottom-btn {
  flex: 1;
  height: 42px;
  margin-inline: 4px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--navy);
  background-color: var(--light);
}

.mobile-bottom-btn.mobile-bottom-wa {
  color: #15803D;
  background-color: #DCFCE7;
}

.mobile-bottom-btn.mobile-bottom-cta {
  background-color: var(--teal);
  color: var(--white);
}

/* ==========================================================================
   13) الصفحات الداخلية: البانر، الفلاتر، وتفاصيل الطبيب
   ========================================================================== */
.page-banner {
  position: relative;
  background-color: var(--navy);
  color: var(--white);
  padding-block: 54px 38px;
  overflow: hidden;
}

.page-banner-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.22;
}

.page-banner-content {
  position: relative;
  z-index: 2;
  text-align: center;
  max-width: 720px;
  margin-inline: auto;
}

.breadcrumb {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.75);
  margin-bottom: 10px;
}

.breadcrumb a {
  color: var(--mint);
}

.page-banner-title {
  font-size: clamp(1.4rem, 5.5vw, 2.2rem);
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 10px;
}

.page-banner-desc {
  font-size: 0.98rem;
  color: rgba(255, 255, 255, 0.9);
}

/* فلاتر الأطباء */
.filter-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  margin-bottom: 30px;
}

.filter-grid {
  display: grid;
  grid-template-columns: 2fr 1.5fr 1.5fr 1fr auto;
  gap: 14px;
  align-items: flex-end;
}

.filter-checkbox-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  height: 44px;
}

.filter-checkbox-wrap input[type="checkbox"] {
  width: 17px;
  height: 17px;
  accent-color: var(--teal);
  cursor: pointer;
}

.filter-results-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.empty-state {
  text-align: center;
  padding: 54px 16px;
  background-color: var(--white);
  border-radius: var(--radius-lg);
  border: 1px dashed var(--border);
}

.empty-state-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background-color: var(--mint);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-inline: auto;
  margin-bottom: 16px;
}

.empty-state-title {
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 6px;
}

.empty-state-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  max-width: 440px;
  margin-inline: auto;
  margin-bottom: 20px;
}

/* تفاصيل الطبيب */
.doctor-profile-grid {
  display: grid;
  grid-template-columns: 1fr 1.8fr;
  gap: 32px;
  align-items: flex-start;
}

.doctor-sticky-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-light);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 85px;
}

.doctor-sticky-img {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
}

.doctor-sticky-info {
  padding: 20px;
}

.fees-breakdown-card {
  background-color: var(--mint-light);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-top: 16px;
  border: 1px solid rgba(14, 138, 138, 0.15);
}

.fee-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 7px;
  font-size: 0.88rem;
  border-bottom: 1px dashed rgba(14, 138, 138, 0.2);
}
.fee-row:last-child {
  border-bottom: none;
}

.detail-section-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  margin-bottom: 24px;
}

.detail-card-title {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--navy);
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.specialty-detail-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 24px;
}

.schedule-days-row {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 8px;
  margin-bottom: 20px;
  -webkit-overflow-scrolling: touch;
}

.schedule-day-btn {
  flex: 1;
  min-width: 88px;
  padding: 12px 8px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-md);
  text-align: center;
  background-color: var(--white);
  transition: all var(--transition-fast);
}

.schedule-day-btn:hover {
  border-color: var(--teal);
}

.schedule-day-btn.active {
  background-color: var(--teal);
  color: var(--white);
  border-color: var(--teal);
  box-shadow: var(--shadow-teal);
}

.day-btn-name {
  font-size: 0.82rem;
  font-weight: 600;
  display: block;
}

.day-btn-date {
  font-size: 1rem;
  font-weight: 800;
  display: block;
  margin-top: 3px;
}

.slots-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin-bottom: 20px;
}

.slot-btn {
  padding: 11px 8px;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  background-color: var(--white);
  color: var(--navy);
  font-weight: 700;
  font-size: 0.88rem;
  min-height: 44px;
  text-align: center;
  transition: all var(--transition-fast);
}

.slot-btn:hover:not(:disabled) {
  border-color: var(--teal);
  background-color: var(--mint);
  color: var(--teal-dark);
}

.slot-btn.active {
  background-color: var(--teal);
  color: var(--white);
  border-color: var(--teal);
}

.slot-btn:disabled {
  background-color: var(--light);
  color: var(--text-light);
  border-color: var(--border-light);
  cursor: not-allowed;
  text-decoration: line-through;
}

/* ==========================================================================
   14) معالج طلب موعد (Booking Wizard)
   ========================================================================== */
.booking-wizard {
  background-color: var(--white);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
  overflow: hidden;
}

.wizard-steps-header {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background-color: var(--light);
  border-bottom: 1px solid var(--border);
}

.wizard-step-tab {
  padding: 16px 10px;
  text-align: center;
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--text-muted);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: all var(--transition-fast);
}

.wizard-step-tab.active {
  color: var(--teal-dark);
  background-color: var(--white);
}

.wizard-step-tab.active::after {
  content: '';
  position: absolute;
  bottom: 0;
  inset-inline: 0;
  height: 3px;
  background-color: var(--teal);
}

.step-num-bubble {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background-color: var(--border);
  color: var(--navy);
  font-size: 0.78rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wizard-step-tab.active .step-num-bubble {
  background-color: var(--teal);
  color: var(--white);
}

.wizard-step-tab.completed .step-num-bubble {
  background-color: var(--navy);
  color: var(--white);
}

.wizard-body {
  padding: 32px 28px;
}

.wizard-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid var(--border-light);
}

.type-radio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 20px;
}

.type-radio-card {
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  padding: 18px 14px;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: flex;
  flex-direction: column;
}

.type-radio-card:hover {
  border-color: var(--teal-light);
}

.type-radio-card.active {
  border-color: var(--teal);
  background-color: var(--mint-light);
}

.type-radio-card .type-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background-color: var(--mint);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 10px;
}

.type-radio-card.active .type-icon {
  background-color: var(--teal);
  color: var(--white);
}

.type-radio-title {
  font-weight: 800;
  font-size: 1rem;
  color: var(--navy);
  margin-bottom: 2px;
}

.type-radio-price {
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--teal);
  margin-top: auto;
}

.form-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-bottom: 18px;
}

.form-grid-2-alt {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 18px;
  margin-bottom: 18px;
}

.booking-summary-box {
  background-color: var(--light);
  border-radius: var(--radius-lg);
  padding: 24px;
  border: 1px solid var(--border);
}

.summary-rows-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--border);
  font-size: 0.92rem;
}

.summary-label {
  font-weight: 700;
  color: var(--text-muted);
}

.summary-val {
  font-weight: 800;
  color: var(--navy);
}

.summary-total-fee {
  font-size: 1.3rem;
  color: var(--teal);
  font-weight: 800;
}

.booking-success-box {
  text-align: center;
  padding: 40px 18px;
}

.success-check-bubble {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: linear-gradient(135deg, #10B981, #0E8A8A);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-inline: auto;
  margin-bottom: 20px;
  box-shadow: 0 8px 20px rgba(16, 185, 129, 0.28);
}

.success-ref-ticket {
  background-color: var(--mint);
  border: 2px dashed var(--teal);
  border-radius: var(--radius-md);
  padding: 18px 28px;
  display: inline-block;
  margin-block: 20px;
}

.ref-code-text {
  font-size: 1.65rem;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: 2px;
}

/* ==========================================================================
   15) المدونة، الأسئلة الشائعة، واتصل بنا
   ========================================================================== */
.articles-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.article-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  display: flex;
  flex-direction: column;
  transition: all var(--transition-normal);
}

.article-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.article-img-wrap {
  aspect-ratio: 16 / 10;
  position: relative;
  overflow: hidden;
}

.article-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.article-category-badge {
  position: absolute;
  top: 12px;
  inset-inline-start: 12px;
  background-color: var(--navy);
  color: var(--white);
  font-size: 0.74rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: var(--radius-full);
}

.article-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.article-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.8rem;
  color: var(--text-light);
  margin-bottom: 8px;
}

.article-title {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--navy);
  line-height: 1.4;
  margin-bottom: 10px;
}

.article-excerpt {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 18px;
  flex-grow: 1;
}

.article-modal {
  position: fixed;
  inset: 0;
  background-color: rgba(7, 37, 59, 0.88);
  backdrop-filter: blur(4px);
  z-index: 1500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-fast);
}

.article-modal.open {
  opacity: 1;
  pointer-events: auto;
}

.article-modal-dialog {
  max-width: 780px;
  width: 100%;
  max-height: 90vh;
  background-color: var(--white);
  border-radius: var(--radius-xl);
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
  position: relative;
  padding: 30px;
}

.article-modal-close {
  position: absolute;
  top: 16px;
  inset-inline-end: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background-color: var(--light);
  color: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.article-modal-body p {
  margin-bottom: 16px;
  line-height: 1.75;
  font-size: 1rem;
  color: var(--text);
}

.article-takeaways-card {
  background-color: var(--mint);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  margin-top: 24px;
  border: 1px solid rgba(14, 138, 138, 0.2);
}

.takeaways-title {
  font-weight: 800;
  color: var(--teal-dark);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* الأكورديون */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.faq-item {
  background-color: var(--white);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-xs);
  overflow: hidden;
  transition: all var(--transition-fast);
}

.faq-item.open {
  border-color: var(--teal);
}

.faq-question-btn {
  width: 100%;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  text-align: inherit;
  font-weight: 700;
  font-size: 1rem;
  color: var(--navy);
  background-color: var(--white);
}

.faq-question-btn:hover {
  color: var(--teal);
}

.faq-chevron {
  flex-shrink: 0;
  color: var(--teal);
  transition: transform var(--transition-normal);
}

.faq-item.open .faq-chevron {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.32s ease;
  background-color: var(--light);
}

.faq-answer-inner {
  padding: 18px 20px;
  font-size: 0.92rem;
  color: var(--text);
  line-height: 1.65;
}

/* صفحة اتصل بنا */
.contact-grid {
  display: grid;
  grid-template-columns: 1.2fr 1.8fr;
  gap: 30px;
}

.contact-info-card, .contact-form-card {
  background-color: var(--white);
  border-radius: var(--radius-lg);
  padding: 28px;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
}

.contact-items-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.contact-row-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.contact-icon-bubble {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background-color: var(--mint);
  color: var(--teal);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-row-label {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text-muted);
}

.contact-row-val {
  font-size: 0.94rem;
  font-weight: 700;
  color: var(--navy);
}

.map-container {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-sm);
  margin-top: 30px;
  aspect-ratio: 16 / 7;
}

.map-container iframe {
  width: 100%;
  height: 100%;
  border: none;
}

.not-found-card {
  background-color: var(--white);
  border-radius: var(--radius-xl);
  padding: 50px 24px;
  text-align: center;
  max-width: 620px;
  margin-inline: auto;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
}

.not-found-num {
  font-size: 5rem;
  font-weight: 900;
  line-height: 1;
  color: var(--teal);
  margin-bottom: 8px;
}

.img-fallback {
  background: linear-gradient(135deg, #0B3C5D 0%, #0E8A8A 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
}

/* ==========================================================================
   16) ضبط الشاشات المتوسطة والتجاوب (Responsive Breakpoints: 1080px & 860px)
   ========================================================================== */
@media (max-width: 1080px) {
  .specialties-grid {
    grid-template-columns: repeat(3, 1fr);
  }
  .doctors-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .features-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-top {
    grid-template-columns: 1fr 1fr;
  }
  .filter-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 860px) {
  /* الشريط العلوي مخفي على الموبايل لتركيز الشاشة وسهولة الاستخدام */
  .site-topbar {
    display: none !important;
  }

  .site-navbar {
    height: 60px;
  }

  .site-navbar.scrolled {
    height: 60px;
  }

  .nav-menu, .nav-actions .nav-cta-btn {
    display: none !important;
  }

  .nav-hamburger {
    display: flex;
  }

  .brand-logo-img {
    width: 34px;
    height: 34px;
  }

  .brand-title {
    font-size: 1rem;
    max-width: 175px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .brand-subtitle {
    display: none;
  }

  .lang-text-desktop {
    display: none;
  }

  .lang-text-mobile {
    display: inline;
    font-weight: 800;
    font-size: 0.85rem;
  }

  .lang-btn {
    padding: 5px 9px;
    min-height: 36px;
  }

  /* منع تكبير الشاشة التلقائي في Safari iOS */
  input, select, textarea, .form-control, .form-select {
    font-size: 16px !important;
    min-height: 44px;
  }

  /* الهيرو على الموبايل */
  .hero-section {
    height: auto;
    min-height: 400px;
    max-height: none;
  }

  /* تدرج هيرو ناعم على الشاشات الرأسية */
  [dir="rtl"] .hero-overlay,
  html[lang="ar"] .hero-overlay,
  [dir="ltr"] .hero-overlay,
  html[lang="en"] .hero-overlay {
    background: linear-gradient(
      180deg,
      rgba(11, 60, 93, 0.84) 0%,
      rgba(11, 60, 93, 0.68) 55%,
      rgba(11, 60, 93, 0.45) 100%
    );
  }

  .hero-content {
    padding-block: 36px 24px;
  }

  .hero-title {
    font-size: clamp(1.6rem, 6.5vw, 2.1rem);
    line-height: 1.35;
  }

  .hero-subtitle {
    font-size: 0.95rem;
    line-height: 1.7;
    margin-bottom: 20px;
  }

  .hero-badge, .badge-tag {
    font-size: 0.8rem;
    padding: 4px 12px;
  }

  .hero-actions {
    flex-direction: column;
    width: 100%;
    gap: 10px;
  }

  .hero-actions .btn {
    width: 100%;
    max-width: 100%;
    min-height: 46px;
  }

  .hero-slider-dots {
    position: static;
    transform: none;
    margin-top: 18px;
  }

  /* شريط الحجز السريع تحت الهيرو على الموبايل */
  .hero-quickbar-section {
    margin-top: 0;
    padding-block: 16px 24px;
    background-color: var(--light);
  }

  .hero-quick-bar {
    padding: 18px 16px;
  }

  .quick-bar-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .section {
    padding-block: 48px;
  }

  .section-title, h2, .page-banner-title {
    font-size: clamp(1.4rem, 5.5vw, 1.8rem);
    line-height: 1.3;
  }

  h3, .card-title, .doctor-card-name, .specialty-name, .article-card-title, .faq-question-btn {
    font-size: 1.05rem;
  }

  body, p, .section-subtitle, .doctor-card-sub, .doctor-card-bio {
    font-size: 0.95rem;
  }

  .steps-grid, .modes-grid, .facilities-grid, .articles-grid, .testimonials-slider {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .doctor-profile-grid, .contact-grid {
    grid-template-columns: 1fr;
  }

  .doctor-sticky-card {
    position: static;
  }

  .specialty-detail-columns {
    grid-template-columns: 1fr;
  }

  .slots-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .type-radio-grid {
    grid-template-columns: 1fr;
  }

  .form-grid-2, .form-grid-2-alt {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .wizard-steps-header {
    grid-template-columns: repeat(2, 1fr);
  }

  /* إظهار الشريط الثابت السفلي على الموبايل */
  .mobile-bottom-bar {
    display: flex;
  }

  /* تعويض مسافة الشريط السفلي */
  body {
    padding-bottom: 64px;
  }

  .floating-widgets {
    bottom: 68px;
    inset-inline-end: 16px;
  }
}

/* ==========================================================================
   17) التوافق الدقيق مع أصغر الشاشات (Mobile 360px – 580px)
   ========================================================================== */
@media (max-width: 580px) {
  .container, .container-narrow {
    width: 100%;
    max-width: 100%;
    padding-inline: 16px;
  }

  .section {
    padding-block: 44px;
  }

  .hero-section {
    min-height: 380px;
  }

  .hero-subtitle {
    font-size: 0.95rem;
    line-height: 1.65;
  }

  /* بطاقات التخصصات: عمودان أنيقان على الموبايل 2 في الصف */
  .specialties-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }

  .specialty-card {
    padding: 16px 12px;
  }

  .specialty-icon-box {
    width: 42px;
    height: 42px;
    margin-bottom: 10px;
  }

  .specialty-icon-box svg {
    width: 22px;
    height: 22px;
  }

  .specialty-name {
    font-size: 0.92rem;
    margin-bottom: 4px;
  }

  .specialty-desc {
    display: none;
  }

  .specialty-link {
    font-size: 0.78rem;
    margin-top: 6px;
  }

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

  .features-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .footer-top {
    grid-template-columns: 1fr;
    gap: 24px;
  }

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

  .wizard-body {
    padding: 20px 14px;
  }

  .wizard-steps-header {
    grid-template-columns: repeat(2, 1fr);
  }

  .wizard-step-tab {
    padding: 10px 6px;
    font-size: 0.78rem;
  }

  .stats-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .stat-number {
    font-size: 2.2rem;
  }
}

/* ==========================================================================
   18) الحركات والطباعة
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

@media print {
  .site-navbar, .site-topbar, .site-footer, .floating-widgets, .mobile-bottom-bar, .btn {
    display: none !important;
  }
  body {
    background-color: var(--white);
    color: #000;
    padding-bottom: 0;
  }
}
