/* ═══════════════════════════════════════════════════════
   STATUS MEDICAL CENTER — MAIN STYLES
   Base reset, layout, nav, hero, page sections,
   SWOT, ecosystem, progress bars, utility overrides.
   
   Note: All Tailwind utility overrides use `html` prefix
   (specificity 0,1,1) to beat Tailwind's single-class
   rules (0,1,0) without needing !important.
═══════════════════════════════════════════════════════ */

/* ════════════════════════════════════════════════════
   RESET & BASE
════════════════════════════════════════════════════ */

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

html {
  scroll-behavior: smooth;
  margin: 0;
  padding: 0;
}

body {
  font-family: 'Roboto', -apple-system, sans-serif;
  background: var(--gray-light);
  color: var(--dark);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  margin: 0;
  /* padding-top is set in components.css via body { padding-top: calc(var(--fh-h) + 12px) } */
}

/* ── Logo image ── */
.logo-img { width: 44px; height: 44px; object-fit: contain; }

/* ── Line clamp utility ── */
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}


/* ════════════════════════════════════════════════════
   LEGACY NAV (hidden on most viewports by fh-nav)
════════════════════════════════════════════════════ */

nav.bg-white\/95 {
  background: rgba(255,255,255,0.98);
  backdrop-filter: blur(24px) saturate(2);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 2px 24px rgba(28,25,23,0.07);
}
html nav .h-20 { height: 68px; }
html nav h1.text-2xl {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--dark);
  line-height: 1.25;
}
html nav p.text-xs {
  font-size: 0.58rem;
  letter-spacing: 0.22em;
  color: var(--gold-dark);
  font-weight: 600;
}

/* Compact desktop nav menu */
.desktop-nav-menu {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-wrap: nowrap;
}

.nav-btn {
  font-size: 0.78rem;
  font-weight: 500;
  color: #44403C;
  padding: 6px 9px;
  border-radius: 8px;
  transition: color 0.18s ease, background 0.18s ease;
  letter-spacing: 0.005em;
  white-space: nowrap;
}
.nav-btn:hover { color: var(--gold-dark); background: rgba(212,175,55,0.08); }
.nav-active { border-bottom: 2px solid var(--gold); }

/* Dropdown (legacy nav) */
.dropdown-trigger { position: relative; }
.dropdown-menu {
  position: absolute; left: 0; top: 100%;
  margin-top: 4px; width: 18rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 8px;
  opacity: 0; visibility: hidden;
  transform: scale(0.95);
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s;
  z-index: 50;
}
.group:hover .dropdown-menu {
  opacity: 1; visibility: visible; transform: scale(1);
}
.group:hover .fa-chevron-down { transform: rotate(180deg); }
.dropdown-item {
  transition: all 0.18s ease;
  border-radius: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.82rem;
  color: #57534E;
  padding: 8px 12px;
  width: 100%;
  text-align: left;
}
.dropdown-item:hover {
  background: var(--gray-light);
  color: var(--gold-dark);
  padding-left: 14px;
}

/* Nav booking button */
nav .gold-gradient {
  background: var(--gold);
  color: var(--dark);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 8px 20px;
  border-radius: 50px;
  transition: all 0.2s ease;
  box-shadow: 0 2px 12px rgba(212,175,55,0.3);
}
nav .gold-gradient:hover {
  background: var(--gold-light);
  box-shadow: 0 4px 20px rgba(212,175,55,0.4);
  transform: translateY(-1px);
}


/* ════════════════════════════════════════════════════
   GOLD GRADIENT UTILITY
════════════════════════════════════════════════════ */

.gold-gradient {
  background: linear-gradient(
    135deg,
    #D4AF37 0%,
    #C09A20 25%,
    #F0D060 50%,
    #C09A20 75%,
    #D4AF37 100%
  );
  background-size: 200% 100%;
  animation: shimmer 3s ease-in-out infinite;
  position: relative;
  overflow: hidden;
}
.gold-gradient::before {
  content: '';
  position: absolute;
  top: 0; left: -100%;
  width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.3), transparent);
  transition: left 0.5s ease;
}
.gold-gradient:hover::before { left: 100%; }

.gold-gradient-soft {
  background: linear-gradient(135deg, #F0D060 0%, #D4AF37 100%);
}

/* General buttons using gold-gradient (outside nav) */
html body button.gold-gradient,
html body a.gold-gradient {
  background: var(--gold);
  color: var(--dark);
  font-weight: 600;
  transition: all 0.2s ease;
}
html body button.gold-gradient:hover,
html body a.gold-gradient:hover {
  background: var(--gold-light);
  box-shadow: 0 6px 24px rgba(212,175,55,0.35);
  transform: translateY(-1px);
}

/* Desktop: gold-gradient hover scale */
@media (min-width: 769px) {
  .gold-gradient:hover {
    transform: translateY(-1px) scale(1.02);
  }
}


/* ════════════════════════════════════════════════════
   HERO BLOCK
════════════════════════════════════════════════════ */

.hero-bg {
  background-color: #1C1917;
  background-image:
    linear-gradient(165deg, rgba(28,25,23,0.78) 0%, rgba(15,118,110,0.38) 55%, rgba(28,25,23,0.85) 100%),
    url('../fon.jpeg');
  background-size: cover;
  background-position: center 30%;
  position: relative;
  overflow: hidden;
}
.hero-bg::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 15% 50%, rgba(212,175,55,0.08) 0%, transparent 70%),
    radial-gradient(ellipse 60% 80% at 85% 20%, rgba(15,118,110,0.06) 0%, transparent 60%);
  pointer-events: none;
}

#page-home .hero-bg h1 {
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  text-shadow: 0 2px 20px rgba(0,0,0,0.3);
}
#page-home .hero-bg .text-gold-400 {
  color: var(--gold-light);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
#page-home .hero-bg .text-xl {
  font-size: 1.05rem;
  color: rgba(255,255,255,0.82);
  font-weight: 300;
  max-width: 520px;
}
#page-home .hero-bg .text-3xl {
  font-size: 1.9rem;
  font-weight: 700;
  color: var(--gold-light);
}
#page-home .hero-bg .text-sm.text-gray-300 {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.65);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

/* Glass card used in hero CTAs */
.glass-effect {
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,0.25);
  color: white;
  font-weight: 500;
}
.glass-effect:hover { background: rgba(255,255,255,0.18); }


/* ════════════════════════════════════════════════════
   SECTION HEADINGS
════════════════════════════════════════════════════ */

html .text-4xl.font-bold.text-gray-800 {
  font-size: clamp(1.6rem, 3vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  color: var(--dark);
}
.w-24.h-1.gold-gradient.rounded {
  background: linear-gradient(90deg, var(--gold), var(--teal));
  animation: none;   /* override shimmer — decorative divider doesn't need it */
  height: 3px;
  border-radius: 2px;
}
.w-24.h-1.gold-gradient.rounded.mx-auto { margin: 0 auto; }


/* ════════════════════════════════════════════════════
   PAGE SECTION HEADERS (dark backgrounds)
════════════════════════════════════════════════════ */

html .bg-gray-900.text-white.py-20,
html .bg-gray-900.text-white.py-16 {
  background: linear-gradient(145deg, #1C1917 0%, #292524 100%);
  position: relative;
  overflow: hidden;
}
html .bg-gray-900.text-white.py-20::after,
html .bg-gray-900.text-white.py-16::after {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 400px; height: 100%;
  background: radial-gradient(ellipse at right center, rgba(212,175,55,0.06) 0%, transparent 70%);
  pointer-events: none;
}
html .bg-gradient-to-r.from-gold-500,
html .bg-gradient-to-r.from-gold-500.to-gold-600 {
  background: linear-gradient(145deg, #C9971A 0%, #D4AF37 100%);
}
html .bg-gradient-to-r.from-blue-600 {
  background: linear-gradient(145deg, #1D4ED8 0%, #1E40AF 100%);
}
html .bg-gradient-to-r.from-teal-600 {
  background: linear-gradient(145deg, var(--teal) 0%, #0D9488 100%);
}

#page-paid .bg-gray-900.text-white.py-20 h1 {
  font-size: clamp(1.8rem, 3.5vw, 2.8rem);
}


/* ════════════════════════════════════════════════════
   CHIEF DOCTOR / MISSION BLOCKS
════════════════════════════════════════════════════ */

.bg-gradient-to-r.from-gold-50 {
  background: linear-gradient(145deg, #FBF8ED 0%, var(--white) 100%);
  border: 1px solid rgba(212,175,55,0.15);
  border-radius: 24px;
}

.border-l-4.border-gold-500 {
  border-left: 4px solid var(--gold);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--white);
  box-shadow: var(--shadow-md);
}


/* ════════════════════════════════════════════════════
   ECOSYSTEM CANVAS
════════════════════════════════════════════════════ */

#ecosystem-canvas {
  background: linear-gradient(180deg, #F8F6F1 0%, var(--white) 100%);
}
#ecosystem-canvas .rounded-3xl {
  border-radius: 20px;
  border: 1px solid var(--border);
}
#ecosystem-canvas .bg-white.rounded-3xl {
  box-shadow: var(--shadow-md);
}
#ecosystem-canvas .bg-gradient-to-br.from-gray-900 {
  background: linear-gradient(145deg, #1C1917 0%, #292524 100%);
  border: none;
}
#ecosystem-canvas .bg-gradient-to-br.from-pink-50 {
  background: linear-gradient(145deg, #FFF5F7 0%, #FFF0F3 100%);
}
#ecosystem-canvas .bg-gradient-to-br.from-indigo-50 {
  background: linear-gradient(145deg, #F0F4FF 0%, #EEF2FF 100%);
}
#ecosystem-canvas .bg-gradient-to-br.from-yellow-400 {
  background: linear-gradient(145deg, #C9971A 0%, #D4AF37 60%, #B8921A 100%);
}

/* Ecosystem specialist hover */
html #eco-specialists .hover\:bg-yellow-50:hover {
  background: var(--gray-light);
}
html #eco-specialists .hover\:border-yellow-200:hover {
  border-color: rgba(212,175,55,0.3);
}

/* Progress bars */
#eco-preg-bar    { background: linear-gradient(90deg, #F472B6, #EC4899); }
#eco-checkup-bar { background: linear-gradient(90deg, #818CF8, #6366F1); }


/* ════════════════════════════════════════════════════
   PAID SERVICES GRID
════════════════════════════════════════════════════ */

#paid-services-grid .rounded-xl {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--white);
  transition: all 0.3s ease;
}
@media (min-width: 769px) {
  #paid-services-grid .rounded-xl:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(212,175,55,0.25);
  }
}

/* Specialists grid doctor cards */
#specialists-grid .rounded-2xl {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--white);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
@media (min-width: 769px) {
  #specialists-grid .rounded-2xl:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(212,175,55,0.25);
  }
}

/* News preview grid */
#home-news-preview .rounded-2xl {
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}
@media (min-width: 769px) {
  #home-news-preview .rounded-2xl:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
  }
}

/* Eco stories (reviews) */
#eco-stories .rounded-2xl {
  background: var(--gray-light);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all 0.25s ease;
}
@media (min-width: 769px) {
  #eco-stories .rounded-2xl:hover {
    background: var(--white);
    box-shadow: var(--shadow-md);
    border-color: rgba(212,175,55,0.2);
  }
}


/* ════════════════════════════════════════════════════
   SWOT BLOCKS
════════════════════════════════════════════════════ */

.swot-strengths {
  background: linear-gradient(145deg, #F0FFF4 0%, #DCFCE7 100%);
  border-left: 4px solid #22C55E;
  border-radius: 0 var(--radius) var(--radius) 0;
}
.swot-weaknesses {
  background: linear-gradient(145deg, #FFF5F5 0%, #FEE2E2 100%);
  border-left: 4px solid #EF4444;
  border-radius: 0 var(--radius) var(--radius) 0;
}
.swot-opportunities {
  background: linear-gradient(145deg, #EFF6FF 0%, #DBEAFE 100%);
  border-left: 4px solid #3B82F6;
  border-radius: 0 var(--radius) var(--radius) 0;
}
.swot-threats {
  background: linear-gradient(145deg, #FFFBEB 0%, #FEF3C7 100%);
  border-left: 4px solid #F59E0B;
  border-radius: 0 var(--radius) var(--radius) 0;
}


/* ════════════════════════════════════════════════════
   KASPI SECTION
════════════════════════════════════════════════════ */

.kaspi-red  { background: linear-gradient(135deg, #EF4444 0%, #DC2626 100%); }
.kaspi-gold { background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%); }
html .bg-gradient-to-r.from-red-50 { background: #FFF5F5; }


/* ════════════════════════════════════════════════════
   FOOTER
════════════════════════════════════════════════════ */

html footer.bg-gray-900,
html .bg-gray-900 {
  background: linear-gradient(170deg, #1C1917 0%, #0F0D0C 100%);
}


/* ════════════════════════════════════════════════════
   MOBILE MENU (legacy nav)
════════════════════════════════════════════════════ */

#mobile-menu {
  background: var(--white);
  border-top: 1px solid var(--border);
  box-shadow: 0 8px 30px rgba(28,25,23,0.1);
}
#mobile-menu .border-l-2.border-gold-200 {
  border-color: rgba(212,175,55,0.25);
}


/* ════════════════════════════════════════════════════
   TEAL ACCENT OVERRIDES
════════════════════════════════════════════════════ */

html .bg-teal-600,
html .bg-teal-700   { background: var(--teal); }
html .text-teal-600,
html .text-teal-700 { color: var(--teal); }
html .border-teal-500 { border-color: var(--teal-light); }


/* ════════════════════════════════════════════════════
   WHATSAPP BUTTON
════════════════════════════════════════════════════ */

html .bg-green-500.text-white       { background: #25D366; }
html .bg-green-500.text-white:hover { background: #20BD5C; }


/* ════════════════════════════════════════════════════
   COLOUR PALETTE OVERRIDES (Tailwind → brand tokens)
   Using `html .class` (0,1,1) to beat Tailwind (0,1,0)
════════════════════════════════════════════════════ */

/* Backgrounds */
html body.bg-gray-50, html .bg-gray-50 { background: var(--gray-light); }
html .bg-white   { background: var(--white); }
html .bg-gray-100 { background: #F2EFE9; }
html .bg-pink-50  { background: #FFF5F7; }
html .bg-blue-50  { background: #EFF6FF; }
html .bg-teal-50  { background: #F0FDFA; }

/* Text */
html .text-gray-800 { color: var(--dark); }
html .text-gray-700 { color: #44403C; }
html .text-gray-600 { color: #57534E; }
html .text-gray-500 { color: #78716C; }
html .text-gold-600 { color: var(--gold-dark); }
html .text-gold-500 { color: var(--gold); }
html .text-gold-400 { color: var(--gold-light); }

/* Borders */
html .border-gray-100 { border-color: var(--border); }
html .border-gray-200 { border-color: #E8E2D9; }
html .border-gold-100 { border-color: rgba(212,175,55,0.15); }

/* Border radii */
html .rounded-2xl { border-radius: var(--radius); }
html .rounded-3xl { border-radius: var(--radius-lg); }
html .rounded-full { border-radius: 9999px; }


/* ════════════════════════════════════════════════════
   RESPONSIVE — MOBILE
════════════════════════════════════════════════════ */

@media (max-width: 768px) {
  /* Legacy nav */
  html nav .h-20    { height: auto; padding: 12px 0; }
  .desktop-nav-menu { display: none; }

  /* Grids → single column */
  #paid-services-grid { grid-template-columns: 1fr; gap: 16px; }
  #specialists-grid   { grid-template-columns: 1fr; gap: 16px; }
  #equipment-list     { grid-template-columns: 1fr; }
  #home-news-preview  { grid-template-columns: 1fr; }
  #checkup-packages   { grid-template-columns: 1fr; }

  /* Hero */
  .hero-bg { padding: 40px 20px; }
  .hero-bg h1 { font-size: 1.75rem; }
  #page-home .hero-bg h1 { font-size: 2rem; }

  /* Data tables */
  .data-table { font-size: 0.75rem; }
  .data-table th,
  .data-table td { padding: 8px 6px; }

  /* Buttons */
  .btn, html body button { font-size: 0.875rem; padding: 10px 16px; }

  /* Logo */
  .logo-img { width: 36px; height: 36px; }

  /* Type scale */
  h1 { font-size: 1.5rem; }
  h2 { font-size: 1.25rem; }
  h3 { font-size: 1.1rem; }

  /* Keep only colour transitions on mobile — no motion */
  * {
    transition:
      color 0.2s ease,
      background-color 0.2s ease,
      border-color 0.2s ease;
  }
}
