* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}


/* =====================
   NAVBAR LAYOUT
===================== */

.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  z-index: 1200;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  padding: 1rem 2rem;
  background: black;
  font-family: sans-serif;
}

/* Logo */
.logo {
  height: 40px;
}

/* =====================
   CENTER NAV
===================== */

.nav-center {
  display: flex;
  justify-content: center;
  gap: 2rem;
  list-style: none;
  margin: 0%;
}

/* TOP-LEVEL LINKS ONLY */
.nav-center > li > a {
  color: white;
  text-decoration: none;
  font-size: 20px;
  position: relative;
  padding: 12px 0;
  transition: color 0.3s ease;
}

/* White hover rectangle */
.nav-center > li > a::before {
  content: "";
  position: absolute;
  left: 50%;
  right: 50%;
  top: -6px;
  bottom: -6px;
  background: white;
  z-index: -1;
  transition: all 0.3s ease;
}

/* Expand on hover */
.nav-center > li > a:hover::before {
  left: -16px;
  right: -16px;
}

.nav-center > li > a:hover {
  color: black;
}


/* =====================
   DROPDOWNS
===================== */

.dropdown {
  position: relative;
}

/* Dropdown container */
.dropdown-menu {
  position: absolute;
  top: 130%;
  left: 0;
  background: white;
  list-style: none;
  padding: 20px 24px;
  min-width: 200px;

  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.25s ease;
}

/* Show on hover */
.dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* DROPDOWN LINKS → BLACK */
.dropdown-menu li a {
  display: block;
  color: black;
  text-decoration: none;
  font-size: 18px;
  padding: 8px 0;
}

/* Dropdown hover */
.dropdown-menu li a:hover {
  color: #eb0028;
}

/* Prevent hover rectangle inside dropdown */
.dropdown-menu a::before {
  display: none;
}

/* =====================
   CTA BUTTON
===================== */

.cta-btn {
  padding: 10px 22px;
  font-size: 16px;
  background: #eb0028;
  color: white;
  border: none;
  border-radius: 30px;
  cursor: pointer;
}

.nav-center > li {
  position: relative;
}

.nav-center > li > a::before {
  pointer-events: none;
}

.mobile-cta {
  display: none;
}

/* Active top-level link */
.nav-center > li > a.active {
  color: #eb0028;   /* Red text */
}



/* DESKTOP DROPDOWN HOVER ONLY */
@media (min-width: 769px) {
  .dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    display: block;
  }
}


/* =====================
   HAMBURGER (MOBILE)
===================== */

.hamburger {
  display: none;
  background: none;
  border: none;
  font-size: 26px;
  color: white;
  cursor: pointer;
}

/* =====================
   MOBILE
===================== */

@media (max-width: 768px) {
  .navbar {
    grid-template-columns: auto auto;
  }

  .nav-center {
    position: absolute;
    top: 70px;
    left: 0;
    right: 0;
    background: #111;
    flex-direction: column;
    align-items: center;
    padding: 2rem 0;
    display: none;
  }

  .nav-center.show {
    display: flex;
  }

  .nav-center > li {
    width: 100%;
    text-align: center;
  }

  /* MOBILE DROPDOWN */
  .dropdown-menu {
    position: static;
    display: none;
    opacity: 1;
    visibility: visible;
    transform: none;

    background: white;
    padding: 16px 0;
    margin-top: 8px;
    z-index: 1200;
  }

  .dropdown-menu li a:hover {
    color: #eb0028;
  }

  .dropdown.open .dropdown-menu {
    display: block;
  }

  /* Dropdown text → BLACK on mobile */
  .dropdown-menu li a {
    color: black;
    padding: 10px 0;
  }

  .dropdown-menu li a:hover {
    color: #eb0028;
  }

  /* Kill hover behavior on mobile */
  .dropdown:hover .dropdown-menu {
    display: none;
  }

  .dropdown-menu {
    position: static;
    display: none;
    opacity: 1;
    visibility: visible;
    transform: none;

    background: white;
    padding: 16px 0;
    margin-top: 8px;
  }

  .dropdown.open .dropdown-menu {
    display: block;
  }

  .hamburger {
    display: block;
    justify-self: end;
  }

  .nav-right {
    display: none;
  }

  /* Top-level nav links hover on mobile → text white */
.nav-center > li > a:hover {
  color: #eb0028;
}

/* Optional: maintain hover rectangle effect only on desktop */
.nav-center > li > a::before {
  display: none; /* hide hover rectangle on mobile */
}

/* Mobile dropdown links hover → text red (same as before) */
.dropdown-menu li a:hover {
  color: #eb0028;
}

.nav-center .mobile-cta {
    display: block;
    padding: 12px 22px;
    margin: 16px auto 0;
    background: #eb0028;
    color: white;
    border-radius: 30px;
    cursor: pointer;
    text-align: center;
    width: 80%;
    font-size: 16px;
    text-decoration: none;
  }

}

/* Active dropdown link */
.dropdown-menu li a.active {
  color: #eb0028;  /* Red text */
}


