/* ==========================================================================
   AAI CHILDREN'S CLINIC & VACCINATION CENTER
   Core Stylesheet & Design System
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800&family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&display=swap');

:root {
  /* Color Palette */
  --primary: #1e3a8a;          /* Clinic Navy Blue */
  --primary-hover: #172554;
  --primary-light: #2563eb;
  --primary-soft: #eff6ff;
  --primary-subtle: #dbeafe;

  --secondary: #0d9488;        /* Medical Teal / Growth */
  --secondary-hover: #0f766e;
  --secondary-soft: #f0fdfa;
  --secondary-light: #ccfbf1;

  --accent: #f59e0b;           /* Warm Amber Sunshine */
  --accent-hover: #d97706;
  --accent-soft: #fef3c7;

  --whatsapp: #25d366;
  --whatsapp-hover: #1ebd5a;

  --dark: #0f172a;             /* Slate text */
  --dark-muted: #334155;
  --text-muted: #64748b;
  --text-light: #94a3b8;

  --bg-page: #f8fafc;
  --bg-surface: #ffffff;
  --bg-surface-alt: #f1f5f9;
  --bg-warm: #fcfbf9;

  --border-color: #e2e8f0;
  --border-subtle: #f1f5f9;

  /* Typography */
  --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-heading: 'Outfit', 'Plus Jakarta Sans', sans-serif;

  /* Elevation Shadows */
  --shadow-xs: 0 1px 2px 0 rgba(15, 23, 42, 0.04);
  --shadow-sm: 0 2px 4px 0 rgba(15, 23, 42, 0.05);
  --shadow-md: 0 6px 16px -2px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 12px 28px -4px rgba(15, 23, 42, 0.10);
  --shadow-xl: 0 24px 44px -8px rgba(30, 58, 138, 0.14);
  --shadow-card: 0 10px 30px -5px rgba(30, 58, 138, 0.07);

  /* Border Radii */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --radius-full: 9999px;

  /* Container & Layout */
  --container-max: 1240px;
  --header-height: 84px;
  --topbar-height: 40px;
  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Box Sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

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

body {
  font-family: var(--font-body);
  color: var(--dark-muted);
  background-color: var(--bg-page);
  line-height: 1.65;
  font-weight: 400;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Typography Base */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  color: var(--dark);
  line-height: 1.25;
  font-weight: 700;
  letter-spacing: -0.015em;
}

h1 { font-size: clamp(2.25rem, 4vw, 3.25rem); font-weight: 800; }
h2 { font-size: clamp(1.85rem, 3vw, 2.5rem); }
h3 { font-size: clamp(1.35rem, 2vw, 1.75rem); }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.1rem; }

p {
  margin-bottom: 1rem;
  color: var(--dark-muted);
}

p:last-child {
  margin-bottom: 0;
}

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

a:hover {
  color: var(--primary-light);
}

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

ul, ol {
  list-style: none;
}

/* Layout Utilities */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

.section {
  padding: 5rem 0;
  position: relative;
}

.section-sm {
  padding: 3.5rem 0;
}

.section-alt {
  background-color: var(--bg-surface);
}

.section-muted {
  background-color: var(--bg-surface-alt);
}

.section-header {
  text-align: center;
  max-width: 780px;
  margin: 0 auto 3.5rem;
}

.section-header.text-left {
  text-align: left;
  margin-left: 0;
}

.section-subtitle {
  font-size: 1.05rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-top: 0.85rem;
}

/* Badges */
.badge-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 0.4rem 1rem;
  border-radius: var(--radius-full);
  background-color: var(--primary-soft);
  color: var(--primary);
  margin-bottom: 1rem;
}

.badge-tag.secondary {
  background-color: var(--secondary-soft);
  color: var(--secondary);
}

.badge-tag.accent {
  background-color: var(--accent-soft);
  color: #b45309;
}

.badge-tag svg {
  width: 14px;
  height: 14px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.85rem 1.75rem;
  border-radius: var(--radius-md);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
  white-space: nowrap;
  line-height: 1.2;
}

.btn-sm {
  padding: 0.55rem 1.15rem;
  font-size: 0.875rem;
  border-radius: var(--radius-sm);
}

.btn-lg {
  padding: 1rem 2.25rem;
  font-size: 1.05rem;
  border-radius: var(--radius-md);
}

.btn-primary {
  background-color: var(--primary);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(30, 58, 138, 0.25);
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(30, 58, 138, 0.35);
}

.btn-secondary {
  background-color: var(--secondary);
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(13, 148, 136, 0.25);
}

.btn-secondary:hover {
  background-color: var(--secondary-hover);
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(13, 148, 136, 0.35);
}

.btn-outline {
  background-color: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.btn-outline:hover {
  background-color: var(--primary-soft);
  color: var(--primary);
  border-color: var(--primary);
}

.btn-outline-white {
  background-color: transparent;
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.7);
}

.btn-outline-white:hover {
  background-color: #ffffff;
  color: var(--primary);
}

.btn-whatsapp {
  background-color: var(--whatsapp);
  color: #ffffff;
}

.btn-whatsapp:hover {
  background-color: var(--whatsapp-hover);
  color: #ffffff;
}

.btn-white {
  background-color: #ffffff;
  color: var(--primary);
  box-shadow: var(--shadow-md);
}

.btn-white:hover {
  background-color: #f8fafc;
  color: var(--primary-hover);
}

/* ==========================================================================
   Top Notification / Utility Bar
   ========================================================================== */
.top-bar {
  background-color: var(--dark);
  color: #e2e8f0;
  font-size: 0.825rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
  z-index: 101;
}

.top-bar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.5rem 0;
  gap: 1rem;
}

.top-bar-left, .top-bar-right {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.top-bar-item {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  color: #cbd5e1;
}

.top-bar-item a {
  color: #ffffff;
  font-weight: 500;
}

.top-bar-item a:hover {
  color: var(--accent);
}

.top-bar-item svg {
  width: 14px;
  height: 14px;
  color: var(--accent);
  flex-shrink: 0;
}

/* High-Contrast Instagram Links for Dark Topbar & Footer */
.topbar-insta-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: #ffffff !important;
  font-weight: 700 !important;
  text-decoration: none;
  transition: var(--transition);
}

.topbar-insta-link:hover {
  color: #f472b6 !important;
}

.insta-icon-circle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
  color: #ffffff !important;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(225, 48, 108, 0.4);
}

.insta-icon-circle svg {
  color: #ffffff !important;
  width: 12px !important;
  height: 12px !important;
}

.footer-insta-icon-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 6px;
  background: linear-gradient(45deg, #f09433, #e6683c, #dc2743, #cc2366, #bc1888);
  color: #ffffff !important;
  flex-shrink: 0;
  margin-top: 0.15rem;
  box-shadow: 0 2px 8px rgba(225, 48, 108, 0.4);
}

.footer-insta-icon-wrap svg {
  color: #ffffff !important;
  width: 14px !important;
  height: 14px !important;
  margin-top: 0 !important;
}

.footer-insta-link {
  color: #ffffff !important;
  font-weight: 600;
  text-decoration: none;
  transition: var(--transition);
}

.footer-insta-handle {
  color: #f472b6 !important; /* Bright high-contrast rose that pops brilliantly on dark background */
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color 0.2s ease;
}

.footer-insta-link:hover .footer-insta-handle {
  color: #ffffff !important;
}

/* ==========================================================================
   Main Header & Navigation
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.site-header.scrolled {
  box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  min-height: 80px;
  padding-top: 0.35rem;
  padding-bottom: 0.35rem;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
  line-height: 1;
}

.brand-logo-img {
  height: 56px;
  width: auto;
  max-width: 250px;
  object-fit: contain;
  display: block;
  transition: transform 0.2s ease;
}

.brand-link:hover .brand-logo-img {
  transform: scale(1.02);
}

/* Main Navigation Menu */
.main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
}

.nav-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.35rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  font-size: 0.925rem;
  font-weight: 600;
  color: var(--dark-muted);
  padding: 0.5rem 0.25rem;
  position: relative;
  text-decoration: none;
  line-height: 1.4;
  white-space: nowrap;
  transition: var(--transition);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2.5px;
  background-color: var(--primary);
  border-radius: var(--radius-full);
  transition: width 0.2s ease;
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

/* Header Actions & Mobile Trigger */
.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.header-phone-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-weight: 700;
  font-size: 0.88rem;
  color: var(--primary);
  background: var(--primary-soft);
  padding: 0.55rem 0.95rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--primary-subtle);
  white-space: nowrap;
  line-height: 1.2;
  transition: var(--transition);
}

.header-phone-btn:hover {
  background: var(--primary-subtle);
  color: var(--primary-hover);
}

.header-phone-btn svg {
  width: 15px;
  height: 15px;
  color: var(--primary);
  flex-shrink: 0;
}

.header-actions .btn-consultation {
  padding: 0.55rem 1.15rem;
  font-size: 0.88rem;
  white-space: nowrap;
  line-height: 1.2;
}

/* Hamburger Toggle */
.mobile-nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border-color);
  color: var(--dark);
  cursor: pointer;
  padding: 0.45rem;
  border-radius: var(--radius-sm);
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.mobile-nav-toggle:hover {
  background-color: var(--bg-surface-alt);
  border-color: var(--text-light);
}

.mobile-nav-toggle svg {
  width: 24px;
  height: 24px;
  display: block;
}

/* Hamburger Toggle */
.mobile-nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--dark);
  font-size: 1.5rem;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: var(--radius-sm);
}

.mobile-nav-toggle svg {
  width: 26px;
  height: 26px;
  display: block;
}

/* Mobile Slide-out Menu */
.mobile-menu-drawer {
  position: fixed;
  top: 0;
  right: -100%;
  width: 320px;
  max-width: 85vw;
  height: 100vh;
  background-color: #ffffff;
  z-index: 200;
  padding: 2rem 1.5rem;
  box-shadow: var(--shadow-xl);
  transition: right 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
}

.mobile-menu-drawer.open {
  right: 0;
}

.mobile-backdrop {
  position: fixed;
  inset: 0;
  background-color: rgba(15, 23, 42, 0.4);
  backdrop-filter: blur(4px);
  z-index: 199;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}

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

.mobile-drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.mobile-close-btn {
  background: none;
  border: none;
  color: var(--dark-muted);
  cursor: pointer;
  padding: 0.4rem;
  border-radius: var(--radius-sm);
}

.mobile-drawer-links {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.mobile-drawer-link {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--dark);
  padding: 0.75rem 0.5rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.mobile-drawer-link.active,
.mobile-drawer-link:hover {
  background-color: var(--primary-soft);
  color: var(--primary);
}

.mobile-drawer-actions {
  margin-top: auto;
  padding-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background-color: #0b1329;
  color: #94a3b8;
  padding-top: 4.5rem;
  padding-bottom: 5.5rem; /* Extra padding for mobile bottom bar */
  font-size: 0.925rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

@media (min-width: 769px) {
  .site-footer {
    padding-bottom: 3rem;
  }
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1.4fr;
  gap: 3rem;
  margin-bottom: 3.5rem;
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.footer-brand-title {
  color: #ffffff;
  font-size: 1.35rem;
  font-weight: 800;
  line-height: 1.2;
}

.footer-brand-desc {
  color: #94a3b8;
  font-size: 0.9rem;
  line-height: 1.65;
}

.footer-doctor-badge {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 0.85rem 1.15rem;
  border-radius: var(--radius-md);
  margin-top: 0.5rem;
}

.footer-doctor-name {
  color: #ffffff;
  font-weight: 700;
  font-size: 0.95rem;
}

.footer-doctor-cred {
  color: var(--secondary);
  font-size: 0.8rem;
  font-weight: 600;
}

.footer-heading {
  color: #ffffff;
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 1.35rem;
  position: relative;
  padding-bottom: 0.5rem;
}

.footer-heading::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 28px;
  height: 2px;
  background-color: var(--secondary);
  border-radius: var(--radius-full);
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-links a {
  color: #94a3b8;
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.footer-links a:hover {
  color: #ffffff;
  transform: translateX(3px);
}

.footer-contact-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  line-height: 1.5;
}

.footer-contact-item svg {
  width: 18px;
  height: 18px;
  color: var(--secondary);
  flex-shrink: 0;
  margin-top: 0.2rem;
}

.footer-contact-item a {
  color: #ffffff;
  font-weight: 600;
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.25rem;
  font-size: 0.85rem;
}

.footer-bottom a {
  color: #94a3b8;
}

.footer-bottom a:hover {
  color: #ffffff;
}

/* ==========================================================================
   Mobile Fixed Bottom Navigation Bar (Call & WhatsApp)
   ========================================================================== */
.mobile-bottom-bar {
  display: none;
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: #ffffff;
  box-shadow: 0 -4px 20px rgba(15, 23, 42, 0.12);
  border-top: 1px solid var(--border-color);
  z-index: 99;
  padding: 0.65rem 1rem calc(0.65rem + env(safe-area-inset-bottom, 0));
}

@media (max-width: 768px) {
  body {
    padding-bottom: calc(64px + env(safe-area-inset-bottom, 0));
  }
  .mobile-bottom-bar {
    display: block;
  }
}

.mobile-bottom-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  align-items: center;
}

.mobile-bottom-btn {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-full);
  font-size: 0.925rem;
  font-weight: 700;
  text-align: center;
  text-decoration: none;
  line-height: 1.2;
  letter-spacing: 0.02em;
  transition: var(--transition);
}

.mobile-bottom-btn svg {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.mobile-btn-call {
  background: var(--primary);
  color: #ffffff;
  box-shadow: 0 3px 10px rgba(30, 58, 138, 0.25);
}

.mobile-btn-call:hover,
.mobile-btn-call:active {
  background: var(--primary-hover);
  color: #ffffff;
}

.mobile-btn-whatsapp {
  background: #25D366;
  color: #ffffff;
  box-shadow: 0 3px 10px rgba(37, 211, 102, 0.28);
}

.mobile-btn-whatsapp:hover,
.mobile-btn-whatsapp:active {
  background: #20ba5a;
  color: #ffffff;
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */
@media (max-width: 1140px) {
  .nav-links {
    gap: 0.95rem;
  }
  .nav-link {
    font-size: 0.865rem;
  }
  .header-actions .btn-consultation {
    padding: 0.5rem 0.85rem;
    font-size: 0.825rem;
  }
}

@media (max-width: 1024px) {
  .main-nav {
    display: none;
  }
  .header-actions .btn-consultation {
    display: none;
  }
  .mobile-nav-toggle {
    display: inline-flex;
  }
  .header-container {
    min-height: 70px;
  }
  .brand-logo-img {
    height: 48px;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
  }
}

@media (max-width: 768px) {
  .top-bar {
    display: none;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .section {
    padding: 3.5rem 0;
  }
  .section-header {
    margin-bottom: 2.5rem;
  }
}

@media (max-width: 480px) {
  .header-phone-btn span {
    display: none;
  }
  .header-phone-btn {
    padding: 0.55rem;
    border-radius: 50%;
  }
  .brand-logo-img {
    height: 44px;
    max-width: 200px;
  }
}
