/* ================= VARIABLES & RESET ================= */
:root {
  --primary: #f07fb3; /* Theme Pink */
  --secondary: #2e3a8c; /* Theme Blue */
  --body-text: #64748b; /* Light Gray Text */
  --border-color: #e2e8f0;
  --white: #ffffff;
  --font-main: "Outfit", sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: Quicksand, sans-serif;
}

body {
  font-family: var(--font-main);
  color: var(--body-text);
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
}

a {
  text-decoration: none;
  transition: all 0.3s ease;
}

ul {
  list-style: none;
}

.site-header {
  
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 999;
  background: transparent;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  will-change: background, border-bottom, box-shadow;
}

.site-header.scrolled {
  background: var(--white);
  border-bottom: 1px solid var(--border-color);
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.site-header.scrolled .desktop-nav > ul > li > a {
  color: var(--secondary);
}

.site-header.scrolled .desktop-nav > ul > li > a:hover {
  color: var(--primary);
}

.site-header.scrolled .nav-toggle span {
  background: var(--secondary);
}

.site-header.scrolled .header-right .contact-widget .info .label,
.site-header.scrolled .header-right .contact-widget .info .phone {
  color: var(--secondary);
}

.site-header.scrolled .header-right .btn-appointment {
  background: var(--primary);
  color: var(--white);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 0 40px;
  height: 90px;
  max-width: 1600px;
  margin: 0 auto;
}

/* Toggle Button (Desktop Left) */
.nav-toggle {
  background: transparent;
    border: none;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    height: 18px;
    width: 25px;
    margin-right: 25px;
    z-index: 1000; /* Ensure it's above other elements */
    position: relative;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background-color: white;
  border-radius: 2px;
}
.nav-toggle span:nth-child(1) {
  width: 100%;
}
.nav-toggle span:nth-child(2) {
  width: 70%;
  margin: 4px 0;
}
.nav-toggle span:nth-child(3) {
  width: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-right: auto; /* pushes menu to right */
}

/* control logo image size */
.ivf-logo {
  height: 70px; /* adjust as needed */
  width: auto;
  display: block;
}

/* ================= DESKTOP NAVIGATION ================= */
.desktop-nav {
  flex-grow: 1;
  display: flex;
  justify-content: flex-start;
  padding-left: 70px;
}

.desktop-nav > ul {
  display: flex;
  align-items: center;
  gap: 30px;
}

.desktop-nav > ul > li > a {
  color: white;
 
  font-size: 16px;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 30px 0; /* Creates large hover area */
  font-size: 18px;
  font-weight: 500;
  line-height: 30px;
  font-weight: 700;
}

.desktop-nav > ul > li > a:hover {
  color: var(--secondary);
}

.text-xs {
  font-size: 10px;
}

/* Dropdown Logic */
.has-dropdown {
  position: relative;
}

.dropdown {
  position: absolute;
  top: 100%;
  left: 0;
  width: min(340px, calc(100vw - 30px));
  background: var(--secondary);
  border-radius: 24px;
  box-shadow: 0 20px 30px rgba(20, 30, 80, 0.22);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px) scale(0.95);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.12);
  max-height: min(420px, calc(100vh - 140px));
  overflow-y: auto;
}

.has-dropdown:hover .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.dropdown li a {
  color: var(--white);
  padding: 16px 22px;
  display: block;
  font-size: 16px;
  line-height: 1.35;
  font-weight: 500;
  transition: all 0.2s ease;
  position: relative;
  border-radius: 0;
  margin: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
}

.dropdown li:last-child a {
  border-bottom: none;
}

.dropdown li:first-child a {
  border-top-left-radius: 24px;
  border-top-right-radius: 24px;
}

.dropdown li:last-child a {
  border-bottom-left-radius: 24px;
  border-bottom-right-radius: 24px;
}

.dropdown li a:hover {
  background-color: rgba(240, 127, 179, 0.18);
  color: var(--white);
  transform: none;
  box-shadow: none;
}

/* ================= HEADER RIGHT (Contact & Button) ================= */
.header-right {
  display: flex;
  align-items: center;
  gap: 30px;
  margin-left: auto;
}

.contact-widget {
  display: flex;
  align-items: center;
  gap: 12px;
}

.icon-box {
  color: var(--primary);
  font-size: 28px;
}

@keyframes ring {
  0%,
  100% {
    transform: rotate(0deg);
  }
  25% {
    transform: rotate(-10deg);
  }
  75% {
    transform: rotate(10deg);
  }
}

.contact-widget .info {
  display: flex;
  flex-direction: column;
  white-space: nowrap;
}

.contact-widget .label {
  color: var(--secondary);
  font-size: 14px;
  font-weight: 400;
  line-height: 20px;
}

.contact-widget .phone {
  font-size: 18px;
  font-weight: 600;
  line-height: 28px;
  color: rgb(255, 255, 255);
}

.btn-appointment {
  background-color: var(--primary);
  color: var(--white);
  padding: 12px 28px;
  border-radius: 30px;
  font-weight: 500;
  box-shadow: 0 4px 6px rgba(31, 140, 157, 0.3);
  
  font-size: 16px;
  font-weight: 400;
  line-height: 20px;
}

.btn-appointment:hover {
  background-color: var(--primary);
  color: var(--white);
}

/* ================= SIDEBARS & OVERLAYS ================= */
.menu-overlay {
  position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    z-index: 9998; /* Just below sidebars */
    opacity: 0;
    visibility: hidden;
    transition: 0.3s ease;
}

.menu-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Right Info Sidebar (Desktop) */
.right-info-sidebar {
  position: fixed;
    top: 0;
    right: -450px;
    width: 400px;
    height: 100vh;
    background: var(--white);
    z-index: 9999; /* Increased z-index */
    box-shadow: -5px 0 25px rgba(0, 0, 0, 0.1);
    transition: 0.5s ease;
    overflow-y: auto;
}

.right-info-sidebar.active {
  right: 0;
}

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 25px;
  border-bottom: 1px solid var(--border-color);
}

.logo-title {
  font-size: 22px;
  color: var(--secondary);
  font-weight: 700;
}
.close-btn {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--secondary);
}
.close-btn:hover {
  color: var(--primary);
}

.sidebar-content {
  padding: 30px 25px;
}
.sidebar-content .desc {
  margin-bottom: 30px;
  line-height: 1.6;
}

.widget {
  margin-bottom: 35px;
}
.widget h4 {
  font-size: 20px;
  color: var(--secondary);
  margin-bottom: 20px;
}

.contact-list li {
  display: flex;
  gap: 15px;
  margin-bottom: 15px;
}
.contact-list i {
  color: var(--primary);
  margin-top: 4px;
}

.newsletter-form {
  position: relative;
  border-bottom: 2px solid var(--border-color);
}
.newsletter-form input {
  width: 100%;
  padding: 12px 0;
  border: none;
  outline: none;
     font-family: "Quicksand", sans-serif;
}
.newsletter-form button {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--primary);
  font-size: 18px;
  cursor: pointer;
}

.social-icons {
  display: flex;
  gap: 10px;
}
.social-icons a {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
}
.social-icons a:hover {
  background: var(--primary);
  color: var(--white);
}

/* Left Mobile Nav Sidebar */
.mobile-menu-sidebar {
  position: fixed;
  top: 0;
  left: -350px; /* Hidden state */
  width: 300px;
  height: 100vh;
  background: var(--white);
  z-index: 10000; /* Higher than overlay */
  transition: 0.5s ease;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

.mobile-menu-sidebar.active {
  left: 0;
}

.mobile-nav-links {
  padding: 20px 0;
  flex-grow: 1;
}
.mobile-nav-links li a {
  display: block;
  padding: 15px 25px;
  color: var(--secondary);
  font-weight: 500;
  border-bottom: 1px solid var(--border-color);
}
.mobile-nav-links li a:hover {
  color: var(--primary);
  background: #f8fafc;
}

.mobile-socials {
  padding: 25px;
  display: flex;
  gap: 10px;
  justify-content: center;
  background: #f8fafc;
}
.mobile-socials a {
  width: 40px;
  height: 40px;
  border: 1px solid var(--border-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary);
}

/* ================= RESPONSIVENESS (Media Queries) ================= */
.mobile-only {
  display: none;
}

@media (max-width: 1200px) {
  .desktop-nav {
    padding-left: 15px;
  }
  .desktop-nav > ul {
    gap: 15px;
  }
  .header-right {
    gap: 15px;
  }
  .btn-appointment {
    padding: 10px 20px;
  }
  .dropdown {
    width: 300px;
  }
}

@media (max-width: 992px) {
  /* Hide Desktop Elements */
  .desktop-only,
  .desktop-nav {
    display: none !important;
  }

  /* Show Mobile Elements */
  .mobile-only {
    display: block;
  }

  /* Show Mobile Toggle Button */
  .mobile-toggle {
    background: #f1f5f9;
    border: none;
    width: 45px;
    height: 45px;
    border-radius: 8px;
    color: var(--secondary);
    font-size: 20px;
    cursor: pointer;
  }

  .site-header .container {
    padding: 0 15px;
  }
}

@media (max-width: 576px) {
  .right-info-sidebar {
    width: 100%;
    right: -100%;
  }
  .mobile-menu-sidebar {
    width: 280px;
  }
}

/* Background Placeholder for testing */
.hero-placeholder {
  height: 8vh;
  background: #e2e8f0;
}
