/* Offset for Global Fixed Header (.site-header) */
main {
  padding-top: 94px;
}

@media (max-width: 768px) {
  main {
    padding-top: 80px;
  }
}

/* =========================================
         1. LUXURY MEDICAL COLOR PALETTE (NON-AI LOOK)
         ========================================= */
:root {
  --bg-deep: #1f1a21;
  --bg-surface: #342c2f;
  --bg-glass: rgba(52, 44, 47, 0.65);
  --bg-glass-heavy: rgba(31, 26, 33, 0.9);

  /* Brand Palette */
  --primary-dark: #342825;
  --primary-mid: #b1835e4c;
  --primary-light: #a48574;
  --primary-glow: #a48574;
  --accent: #b1835e;
  --accent-hover: #a87856;
  --accent-glow: rgba(152, 107, 76, 0.35);

  /* Typography Colors */
  --white: #faf7f5;
  --text-main: #faf7f5;
  --text-secondary: #d8ceca;
  --text-muted: #cb916b;

  /* Borders & Effects */
  --border-glass: rgba(164, 133, 116, 0.22);
  --border-gold: rgba(152, 107, 76, 0.45);
  --radius-sm: 12px;
  --radius-md: 20px;
  --radius-lg: 30px;
  --radius-full: 9999px;
  --transition-smooth: all 0.45s cubic-bezier(0.16, 1, 0.3, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Cairo", "Alexandria", sans-serif;
  background-color: var(--bg-base);
  color: var(--text-primary);
  line-height: 1.8;
  overflow-x: hidden;
  direction: rtl;
  text-align: right;
  -webkit-font-smoothing: antialiased;
}

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition-smooth);
}

button {
  outline: none;
  border: none;
  font-family: inherit;
  cursor: pointer;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
  position: relative;
  z-index: 2;
}

/* Clean Minimal Background Pattern */
.bg-pattern {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(to right, rgba(164, 133, 116, 0.03) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(164, 133, 116, 0.03) 1px, transparent 1px);
  background-size: 40px 40px;
}

/* Mouse Cursor Spotlight */
.cursor-spotlight {
  position: fixed;
  width: 600px;
  height: 600px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(164, 133, 116, 0.06) 0%,
    transparent 60%
  );
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 1;
  transition:
    width 0.3s,
    height 0.3s;
}

/* =========================================
         2. SMOOTH ANIMATION CLASSES
         ========================================= */
.reveal-up {
  opacity: 0;
  transform: translateY(40px);
  transition:
    opacity 0.8s var(--ease-out-expo),
    transform 0.8s var(--ease-out-expo);
}

.reveal-up.visible {
  opacity: 1;
  transform: translateY(0);
}

.delay-100 {
  transition-delay: 100ms;
}

.delay-200 {
  transition-delay: 200ms;
}

.delay-300 {
  transition-delay: 300ms;
}

@keyframes floatSoftly {
  0% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-12px);
  }

  100% {
    transform: translateY(0px);
  }
}

@keyframes gradientShimmer {
  0% {
    background-position: 200% center;
  }

  100% {
    background-position: -200% center;
  }
}

/* =========================================
         3. BREADCRUMBS
         ========================================= */
.breadcrumb-wrap {
  padding-top: 30px;
  padding-bottom: 20px;
  position: relative;
  z-index: 2;
}

.breadcrumb-nav {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.breadcrumb-nav a:hover {
  color: var(--primary-light);
}

.breadcrumb-current {
  color: var(--accent);
  font-weight: 700;
}

/* =========================================
         4. HERO SECTION
         ========================================= */
.hero-section {
  padding: 40px 0 60px;
  position: relative;
  z-index: 2;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 50px;
  align-items: center;
}
.hero-grid > *:first-child {
    order: 2; /* العنصر الأول يروح الآخر */
}

.hero-grid > *:last-child {
    order: 1; /* العنصر التاني ييجي الأول */
}
.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--primary-teal-soft);
  color: var(--primary-teal-glow);
  padding: 6px 18px;
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 24px;
  border: 1px solid rgba(164, 133, 116, 0.2);
}

.hero-title {
  font-size: clamp(2.2rem, 4vw, 3.4rem);
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1.3;
  margin-bottom: 24px;
}

.hero-title span {
  background: linear-gradient(135deg, #C49671 0%, #B1835E 100%);
  -webkit-background-clip: text;
  color: transparent;
  animation: gradientShimmer 4s linear infinite;
}

/* Story Word Animation Box */
.story-glass-stage {
  position: relative;
  background: #1e171e;
  border: 1px solid var(--border-color);
  border-right: 4px solid var(--accent);
  border-radius: var(--radius-lg);
  padding: 28px 30px;
  margin-bottom: 30px;
}

.story-header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.live-indicator {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--primary-teal-glow);
}

.pulse-ring {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: var(--accent);
  animation: pulseGold 2s infinite;
}

@keyframes pulseGold {
  0% {
    box-shadow: none;
  }

  70% {
    box-shadow: 0 0 8px var(--accent);
  }

  100% {
    box-shadow: none;
  }
}

.replay-text-btn {
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 0.75rem;
  padding: 6px 14px;
  border-radius: 50px;
  transition: 0.3s;
}

.replay-text-btn:hover {
  background: var(--accent);
  color: var(--bg-base);
  border-color: var(--accent);
}

.word-reveal-paragraph {
  font-size: 1.05rem;
  line-height: 1.9;
  color: var(--text-primary);
  margin-bottom: 20px;
  text-align: justify;
  font-weight: 500;
}

.anim-word {
  display: inline-block;
  opacity: 0;
  filter: blur(8px);
  transform: translateY(12px) scale(0.94);
  transition:
    opacity 0.45s ease,
    filter 0.45s ease,
    transform 0.45s ease,
    color 0.3s ease;
  margin-left: 4px;
}

.anim-word.is-revealed {
  opacity: 1;
  filter: blur(0);
  transform: translateY(0) scale(1);
}

.anim-word.highlight-word.is-revealed {
  color: var(--accent);
  font-weight: 700;
}

.story-golden-conclusion {
  background: rgba(152, 107, 76, 0.08);
  border: 1px solid rgba(152, 107, 76, 0.2);
  border-radius: 12px;
  padding: 16px 20px;
  opacity: 0;
  transform: translateY(10px);
  transition: all 0.6s ease;
}

.story-golden-conclusion.box-visible {
  opacity: 1;
  transform: translateY(0);
}

.word-reveal-conclusion {
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1.8;
  margin: 0;
}

.btn-primary {
  background: var(--accent);
  color: var(--bg-base);
  padding: 14px 32px;
  border-radius: var(--radius-full);
  font-weight: 800;
  font-size: 1.05rem;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  transition: var(--transition-smooth);
  box-shadow: 0 8px 25px rgba(152, 107, 76, 0.2);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 30px var(--accent);
}

.hero-visual-stage {
  position: relative;
  display: flex;
  justify-content: center;
}

.visual-arch-frame {
  width: 100%;
  max-width: 440px;
  height: 500px;
  border-radius: 220px 220px 24px 24px;
  padding: 10px;
  background: linear-gradient(180deg, var(--primary-mid) 0%, transparent 100%);
  position: relative;
  animation: floatSoftly 6s ease-in-out infinite;
}

.visual-arch-inner {
  width: 100%;
  height: 100%;
  border-radius: 210px 210px 16px 16px;
  overflow: hidden;
  background: var(--bg-surface);
}

.visual-arch-inner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: 0.6s;
}

/* =========================================
         5. DOCTOR STATS / CASES
         ========================================= */
.stats-section {
  padding: 40px 0 60px;
  position: relative;
  z-index: 2;
}

.stats-container {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 40px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  text-align: center;
}

.stat-item {
  padding: 20px;
  border-radius: var(--radius-md);
  background: var(--bg-elevated);
  border: 1px solid rgba(255, 255, 255, 0.02);
  transition: var(--transition-smooth);
}

.stat-item:hover {
  transform: translateY(-5px);
  border-color: var(--primary-mid);
}

.stat-icon {
  font-size: 2.5rem;
  margin-bottom: 10px;
  display: block;
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 900;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 8px;
  font-family: "Alexandria", sans-serif;
}

.stat-text {
  font-size: 1rem;
  color: var(--text-secondary);
  font-weight: 600;
}

.stat-desc {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 10px;
  display: block;
}

/* =========================================================
         SERVICES DIRECTORY (Medical Terminal & Data Rows)
         ========================================================= */
.services-directory-section {
  padding: 90px 0;
  background: var(--bg-surface);
  border-top: 1px solid var(--border-thin);
  border-bottom: 1px solid var(--border-thin);
  position: relative;
  z-index: 2;
}

.directory-head {
  text-align: center;
  max-width: 750px;
  margin: 0 auto 60px;
}

.luxe-badge-outline {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--primary-mid);
  color: var(--primary-teal-glow);
  padding: 6px 18px;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 20px;
  background: rgba(164, 133, 116, 0.05);
}

.pulse-dot-cyan {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary-teal-glow);
  animation: pulseCyan 2s infinite;
}

@keyframes pulseCyan {
  0% {
    box-shadow: 0 0 0 0 rgba(164, 133, 116, 0.4);
  }

  70% {
    box-shadow: 0 0 0 6px rgba(164, 133, 116, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(164, 133, 116, 0);
  }
}

.directory-head h2 {
  font-family: "Cairo", sans-serif;
  font-size: 2.4rem;
  font-weight: 900;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.directory-head p {
  color: var(--text-secondary);
  font-size: 1.05rem;
  line-height: 1.8;
}

/* The Grid Layout */
.directory-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  /* نسبة مريحة للعين */
  gap: 40px;
}

.directory-column {
  background: var(--bg-base);
  border: 1px solid var(--border-thin);
  border-radius: 20px;
  padding: 40px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
}

/* Column Header with Scanning Laser */
.column-header {
  display: flex;
  flex-direction: column;
  margin-bottom: 30px;
  position: relative;
}

.header-icon-box {
  width: 50px;
  height: 50px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  margin-bottom: 20px;
}

.header-icon-box svg {
  width: 26px;
  height: 26px;
}

.column-header h3 {
  font-family: "Cairo", sans-serif;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--white);
  margin-bottom: 16px;
}

/* Continuous Laser Scanner under title */
.scanning-line-container {
  width: 100%;
  height: 2px;
  background: rgba(255, 255, 255, 0.05);
  position: relative;
  overflow: hidden;
  border-radius: 2px;
}

.scanner-laser {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 30%;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  animation: scanHoriz 3s ease-in-out infinite alternate;
}

@keyframes scanHoriz {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(350%);
  }
}

/* The Interactive Data Rows */
.column-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.data-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 20px;
  border-radius: 10px;
  background: transparent;
  border-right: 2px solid transparent;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  text-decoration: none;
  position: relative;
}

/* Active/Hover State */
.data-row:hover {
  background: linear-gradient(90deg, transparent, rgba(152, 107, 76, 0.05));
  border-right-color: var(--accent);
  transform: translateX(-6px);
  /* تحرك خفيف لليسار في اتجاه الـ RTL */
}

.row-node {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-light);
  transition: all 0.4s ease;
}

.row-node svg {
  width: 18px;
  height: 18px;
  transition: transform 0.4s ease;
}

.data-row:hover .row-node {
  color: var(--accent);
}

/* دوران الأيقونة بشكل هندسي جذاب */
.data-row:hover .row-node svg {
  transform: rotate(90deg) scale(1.1);
}

.row-text {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: color 0.4s ease;
}

.data-row:hover .row-text {
  color: var(--white);
}

/* --- Visual Filler Art for Column 2 --- */
.micro-art-filler {
  margin-top: auto;
  /* يدفعه للأسفل لملء الفراغ */
  padding-top: 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.micro-svg-anim {
  width: 140px;
  height: 140px;
  opacity: 0.7;
}

.spin-slow {
  animation: spin 20s linear infinite;
  transform-origin: center;
}

@keyframes spin {
  100% {
    transform: rotate(360deg);
  }
}

.draw-path-slow {
  stroke-dasharray: 200;
  stroke-dashoffset: 200;
  animation: drawInf 4s ease-in-out infinite alternate;
}

.draw-path-fast {
  stroke-dasharray: 100;
  stroke-dashoffset: 100;
  animation: drawInf 2s ease-in-out infinite alternate 1s;
}

@keyframes drawInf {
  to {
    stroke-dashoffset: 0;
  }
}

.pulse-node {
  animation: nodePulse 2s infinite alternate;
}

@keyframes nodePulse {
  0% {
    r: 3;
    opacity: 0.5;
  }

  100% {
    r: 5;
    opacity: 1;
    filter: drop-shadow(0 0 5px var(--accent));
  }
}

.micro-art-label {
  margin-top: 16px;
  font-family: monospace;
  font-size: 0.7rem;
  color: var(--primary-teal-glow);
  letter-spacing: 2px;
  opacity: 0.6;
}

/* =========================================================
         RESPONSIVE RULES
         ========================================================= */
@media (max-width: 992px) {
  .directory-grid {
    grid-template-columns: 1fr;
  }

  .directory-column {
    padding: 30px 20px;
  }

  .micro-art-filler {
    display: none;
    /* إخفاؤه في الموبايل لأنه لم يعد له حاجة لموازنة الطول */
  }
}

@media (max-width: 640px) {
  .directory-head h2 {
    font-size: 1.8rem;
  }

  .data-row {
    padding: 12px 14px;
  }

  .row-text {
    font-size: 0.95rem;
  }
}

/* =========================================
         7. ADVICE / HOPE BANNER
         ========================================= */
.advice-section {
  padding: 80px 0;
  position: relative;
  z-index: 2;
}

.advice-banner {
  background: linear-gradient(
    135deg,
    rgba(164, 133, 116, 0.15) 0%,
    rgba(31, 26, 33, 0.9) 100%
  );
  border: 1px solid var(--primary-mid);
  border-radius: var(--radius-lg);
  padding: 50px;
  display: flex;
  align-items: center;
  gap: 40px;
}

.advice-icon {
  width: 80px;
  height: 80px;
  background: rgba(164, 133, 116, 0.1);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  border: 1px solid var(--primary-mid);
  flex-shrink: 0;
}

.advice-content h3 {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--white);
  margin-bottom: 16px;
}

.advice-content p {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.9;
  margin-bottom: 20px;
}

.hope-quote {
  border-right: 3px solid var(--accent);
  padding-right: 15px;
  font-size: 1.05rem;
  font-style: italic;
  color: var(--primary-teal-glow);
  font-weight: 600;
}

/* =========================================
         8. 3D COVERFLOW GALLERY
         ========================================= */
.gallery-3d-section {
  padding: 60px 0 100px;
  position: relative;
  z-index: 2;
}

.gallery-3d-section {
  padding: 60px 0 100px;
  position: relative;
  z-index: 2;
  overflow: hidden;
  overflow-x: clip;
  contain: paint;
  width: 100%;
  max-width: 100%;
}

.carousel-3d-stage {
  position: relative;
  height: 460px;
  display: flex;
  align-items: center;
  justify-content: center;
  perspective: 1400px;
  margin: 20px 0 50px;
  touch-action: pan-y;
}

.carousel-3d-card {
  position: absolute;
  width: 360px;
  height: 430px;
  border-radius: 20px;
  overflow: hidden;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  transition: all 0.65s cubic-bezier(0.2, 0.85, 0.25, 1);
  cursor: pointer;
  box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4);
}

.carousel-3d-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  pointer-events: none;
  filter: brightness(0.85);
  transition: 0.4s;
}

.carousel-3d-card:hover img {
  filter: brightness(1);
}

.zoom-hint-btn {
  position: absolute;
  bottom: 20px;
  left: 20px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(31, 26, 33, 0.8);
  backdrop-filter: blur(8px);
  border: 1px solid var(--accent);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  opacity: 0;
  transform: scale(0.8);
  transition: var(--transition-smooth);
}

.carousel-3d-card.is-center {
  transform: translate3d(0, 0, 140px) rotateY(0deg);
  z-index: 10;
  border-color: var(--accent);
  box-shadow: 0 20px 50px rgba(152, 107, 76, 0.15);
}

.carousel-3d-card.is-center img {
  filter: brightness(1);
}

.carousel-3d-card.is-center .zoom-hint-btn {
  opacity: 1;
  transform: scale(1);
}

.carousel-3d-card.is-right-1 {
  transform: translate3d(280px, 0, -50px) rotateY(-25deg) scale(0.85);
  z-index: 8;
  filter: brightness(0.5);
}

.carousel-3d-card.is-left-1 {
  transform: translate3d(-280px, 0, -50px) rotateY(25deg) scale(0.85);
  z-index: 8;
  filter: brightness(0.5);
}

.carousel-3d-card.is-right-2 {
  transform: translate3d(500px, 0, -150px) rotateY(-40deg) scale(0.7);
  z-index: 5;
  filter: brightness(0.25);
}

.carousel-3d-card.is-left-2 {
  transform: translate3d(-500px, 0, -150px) rotateY(40deg) scale(0.7);
  z-index: 5;
  filter: brightness(0.25);
}

.carousel-3d-card.is-hidden {
  transform: translate3d(0, 0, -300px) scale(0.5);
  opacity: 0;
  pointer-events: none;
  z-index: 1;
}

.carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
}

.carousel-nav-btn {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--bg-elevated);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: 0.3s;
}

.carousel-nav-btn:hover {
  background: var(--accent);
  color: var(--bg-base);
  border-color: var(--accent);
  transform: scale(1.1);
}

.carousel-dots {
  display: flex;
  gap: 8px;
}

.carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  border: none;
  cursor: pointer;
  transition: 0.3s;
}

.carousel-dot.active {
  width: 32px;
  border-radius: 10px;
  background: var(--accent);
}

/* Lightbox Fullscreen Modal */
.lightbox-modal {
  position: fixed;
  inset: 0;
  background: rgba(31, 26, 33, 0.96);
  backdrop-filter: blur(20px);
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  visibility: hidden;
  transition: 0.4s ease;
}

.lightbox-modal.is-open {
  opacity: 1;
  visibility: visible;
}

.lightbox-modal img {
  max-width: 90vw;
  max-height: 85vh;
  border-radius: 16px;
  border: 2px solid var(--accent);
  transform: scale(0.9);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.6);
}

.lightbox-modal.is-open img {
  transform: scale(1);
}

.lightbox-close {
  position: absolute;
  top: 30px;
  right: 30px;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: var(--accent);
  color: var(--bg-base);
  font-size: 1.4rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 0.3s ease;
}

.lightbox-close:hover {
  transform: scale(1.1) rotate(90deg);
}

/* WhatsApp FAB */
.floating-contact-actions {
  position: fixed;
  bottom: 25px;
  left: 25px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.floating-btn {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-decoration: none;
  transition: 0.3s;
  background: #b1835e; 
}

.floating-btn:hover {
  transform: scale(1.1); 
}

/* =========================================
   9. RESPONSIVE DESIGN
   ========================================= */
@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .story-glass-stage {
    text-align: right;
  }

  .hero-visual-stage {
    order: -1;
    margin-bottom: 20px;
  }

  .visual-arch-frame {
    max-width: 380px;
    height: 420px;
  }

  .services-wrapper {
    grid-template-columns: 1fr;
  }

  .advice-banner {
    flex-direction: column;
    text-align: center;
    padding: 40px 24px;
  }

  .hope-quote {
    border-right: none;
    border-top: 3px solid var(--accent);
    padding-right: 0;
    padding-top: 15px;
  }

  .carousel-3d-card.is-right-1 {
    transform: translate3d(180px, 0, -50px) rotateY(-22deg) scale(0.85);
  }

  .carousel-3d-card.is-left-1 {
    transform: translate3d(-180px, 0, -50px) rotateY(22deg) scale(0.85);
  }

  .carousel-3d-card.is-right-2,
  .carousel-3d-card.is-left-2 {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translate3d(0, 0, -300px) scale(0.5);
  }
}

@media (max-width: 640px) {
  .hero-title {
    font-size: 1.9rem;
  }

  .story-glass-stage {
    padding: 20px;
  }

  .stats-container {
    padding: 20px;
    gap: 15px;
  }

  .service-card {
    padding: 24px;
  }

  .gallery-3d-section {
    padding: 50px 0 60px;
  }

  .carousel-3d-stage {
    height: 380px;
  }

  .carousel-3d-card {
    width: min(280px, 76vw);
    height: 350px;
  }

  .carousel-3d-card.is-right-1 {
    transform: translate3d(min(80px, 20vw), 0, -60px) rotateY(-18deg)
      scale(0.82);
  }

  .carousel-3d-card.is-left-1 {
    transform: translate3d(max(-80px, -20vw), 0, -60px) rotateY(18deg)
      scale(0.82);
  }

  .carousel-controls {
    gap: 10px;
  }

  .carousel-nav-btn {
    width: 42px;
    height: 42px;
    flex-shrink: 0;
  }

  .carousel-dots {
    flex-wrap: wrap;
    justify-content: center;
    max-width: calc(100% - 100px);
  }
}

.section-head-compact h2::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 80px;
  height: 3px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  border-radius: 50px;
  box-shadow: 0 0 12px var(--accent-glow);
}

.section-head-compact h2 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 900;
  color: var(--white);
  line-height: 1.4;
  position: relative;
  display: inline-block;
  text-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  padding-bottom: 15px;
}

/* =========================================
         Specialty Floating Image  
         ========================================= */
.specialty-floating-wrapper {
  position: absolute;
  bottom: 72%;
  right: -30px;
  z-index: 10;
  opacity: 0;
  /* تبدأ مخفية لتطبيق تأثير الظهور */

  /* دمج أنيميشن الظهور المتدرج (Fade In) مع أنيميشن الطفو المستمر */
  animation:
    fadeEntrance 1.2s cubic-bezier(0.2, 0.8, 0.2, 1) 0.5s forwards,
    /* الظهور أولاً */ floatAndFade 4s ease-in-out 1.7s infinite alternate;
  /* الطفو المستمر بعد الظهور */
}

.specialty-img-circle {
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: rgba(31, 26, 33, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 2px solid rgba(152, 107, 76, 0.5);
  padding: 6px;
  box-shadow:
    0 15px 30px rgba(0, 0, 0, 0.4),
    inset 0 0 15px rgba(152, 107, 76, 0.1);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition:
    transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1),
    box-shadow 0.4s ease,
    border-color 0.4s ease;
}

.specialty-img-circle img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  transition:
    transform 0.5s ease,
    filter 0.5s ease;
}

.specialty-img-circle::before {
  content: "";
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 1.5px dashed rgba(164, 133, 116, 0.6);
  animation: spinSlowly 15s linear infinite;
  pointer-events: none;
}

.specialty-img-circle::after {
  content: "";
  position: absolute;
  inset: -22px;
  background-image: url("data:image/svg+xml,%3Csvg%20xmlns='http://www.w3.org/2000/svg'%20width='210'%20height='210'%20viewBox='0%200%20210%20210'%20fill='none'%3E%3C%21--%20Geometric%20Polygonal%20Frame%20Decoration%20Wrapping%20Closely%20Around%20.specialty-img-circle%20--%3E%3Cg%20stroke='%23FFDEC0'%20stroke-width='0.85'%20opacity='0.26'%3E%3C%21--%20Polygonal%20Faceted%20Outer%20Ring%20--%3E%3Cpath%20d='M%20195.0,105.0%20L%20182.9,150.0%20L%20150.0,182.9%20L%20105.0,195.0%20L%2060.0,182.9%20L%2027.1,150.0%20L%2015.0,105.0%20L%2027.1,60.0%20L%2060.0,27.1%20L%20105.0,15.0%20L%20150.0,27.1%20L%20182.9,60.0%20Z'%20/%3E%3C%21--%20Fine%20dashed%20geometric%20orbit%20--%3E%3Ccircle%20cx='105'%20cy='105'%20r='84'%20stroke-dasharray='3%204'%20stroke-width='0.6'%20opacity='0.7'%20/%3E%3C%21--%20Radial%20Tick%20Marks%20--%3E%3Cpath%20d='M%20188.0,105.0%20L%20192.0,105.0%20M%20176.9,146.5%20L%20180.3,148.5%20M%20146.5,176.9%20L%20148.5,180.3%20M%20105.0,188.0%20L%20105.0,192.0%20M%2063.5,176.9%20L%2061.5,180.3%20M%2033.1,146.5%20L%2029.7,148.5%20M%2022.0,105.0%20L%2018.0,105.0%20M%2033.1,63.5%20L%2029.7,61.5%20M%2063.5,33.1%20L%2061.5,29.7%20M%20105.0,22.0%20L%20105.0,18.0%20M%20146.5,33.1%20L%20148.5,29.7%20M%20176.9,63.5%20L%20180.3,61.5'%20stroke-width='0.75'%20/%3E%3C%21--%20Corner%20Framing%20Brackets%20--%3E%3Cpath%20d='M%2022,36%20L%2022,22%20L%2036,22%20M%20174,22%20L%20188,22%20L%20188,36%20M%20188,174%20L%20188,188%20L%20174,188%20M%2036,188%20L%2022,188%20L%2022,174'%20stroke-width='1.1'%20opacity='0.85'%20/%3E%3C/g%3E%3C%21--%20Geometric%20Diamond%20Accents%20--%3E%3Cg%20stroke='%23FFDEC0'%20stroke-width='0.7'%20fill='none'%20opacity='0.32'%3E%3Cpath%20d='M%20199.5,105.0%20L%20202.0,102.5%20L%20204.5,105.0%20L%20202.0,107.5%20Z'%20/%3E%3Cpath%20d='M%20171.1,173.6%20L%20173.6,171.1%20L%20176.1,173.6%20L%20173.6,176.1%20Z'%20/%3E%3Cpath%20d='M%20102.5,202.0%20L%20105.0,199.5%20L%20107.5,202.0%20L%20105.0,204.5%20Z'%20/%3E%3Cpath%20d='M%2033.9,173.6%20L%2036.4,171.1%20L%2038.9,173.6%20L%2036.4,176.1%20Z'%20/%3E%3Cpath%20d='M%205.5,105.0%20L%208.0,102.5%20L%2010.5,105.0%20L%208.0,107.5%20Z'%20/%3E%3Cpath%20d='M%2033.9,36.4%20L%2036.4,33.9%20L%2038.9,36.4%20L%2036.4,38.9%20Z'%20/%3E%3Cpath%20d='M%20102.5,8.0%20L%20105.0,5.5%20L%20107.5,8.0%20L%20105.0,10.5%20Z'%20/%3E%3Cpath%20d='M%20171.1,36.4%20L%20173.6,33.9%20L%20176.1,36.4%20L%20173.6,38.9%20Z'%20/%3E%3C/g%3E%3C%21--%20Cardinal%20Node%20Dots%20--%3E%3Cg%20fill='%23FFDEC0'%20opacity='0.38'%3E%3Ccircle%20cx='105'%20cy='15'%20r='1.6'%20/%3E%3Ccircle%20cx='195'%20cy='105'%20r='1.6'%20/%3E%3Ccircle%20cx='105'%20cy='195'%20r='1.6'%20/%3E%3Ccircle%20cx='15'%20cy='105'%20r='1.6'%20/%3E%3C/g%3E%3C/svg%3E");
  background-size: contain;
  background-repeat: no-repeat;
  background-position: center;
  pointer-events: none;
  z-index: 2;
  transition: transform 0.45s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

.specialty-img-circle:hover::after {
  transform: scale(1.05) rotate(15deg);
  opacity: 0.9;
}

/* تأثير عند مرور الماوس (Hover) */
.specialty-img-circle:hover {
  transform: scale(1.1) translateY(-5px);
  box-shadow:
    0 20px 40px rgba(0, 0, 0, 0.6),
    0 0 25px rgba(152, 107, 76, 0.4);
  border-color: var(--accent);
}

.specialty-img-circle:hover img {
  transform: scale(1.08);
  filter: brightness(1.1);
  /* إضاءة خفيفة للصورة عند الماوس */
}

/* 1. أنيميشن الدخول (Fade In & Slide Up) */
@keyframes fadeEntrance {
  0% {
    opacity: 0;
    transform: translateY(30px) scale(0.9);
  }

  100% {
    opacity: 1;
    transform: translateY(0px) scale(1);
  }
}

/* 2. أنيميشن الطفو مع التلاشي الخفيف المستمر (Float & Fade Breathing) */
@keyframes floatAndFade {
  0% {
    transform: translateY(0px);
    opacity: 0.85;
    /* شفافة قليلاً في الأسفل */
  }

  100% {
    transform: translateY(-20px);
    opacity: 1;
    /* واضحة تماماً في الأعلى */
  }
}

@keyframes spinSlowly {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

/* --- إعدادات الموبايل --- */
@media (max-width: 768px) {
  .specialty-floating-wrapper {
    bottom: -72px;
    right: auto;
    left: 0px;
  }

  .specialty-img-circle {
    width: 150px;
    height: 150px;
  }

  .specialty-img-circle::before {
    inset: -5px;
  }
}
