/* ============================================================
   MIRUTAX CONSULTANCY - UNIFIED NAVBAR STYLES
   ============================================================ */

:root {
  --nav-navy: #001f3f;
  --nav-white: #ffffff;
  --nav-gold: #d4af37;
  --nav-gold-dark: #b8941f;
  --nav-gray: #6c757d;
  --nav-height: 75px;
  --nav-shadow: 0 4px 20px rgba(0, 31, 63, 0.12);
  --nav-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ============ HEADER / WRAPPER ============ */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 9999;
  background-color: var(--nav-white);
  box-shadow: var(--nav-shadow);
  transition: var(--nav-transition);
}

header.scrolled {
  box-shadow: 0 6px 30px rgba(0, 31, 63, 0.18);
}

/* ============ NAV CONTAINER ============ */
.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
  height: var(--nav-height);
  gap: 16px;
}

/* ============ LOGO ============ */
.logo-text {
  display: flex;
  align-items: center;
  text-decoration: none;
  flex-shrink: 0;
}

.logo-img {
  height: 52px;
  width: auto;
  object-fit: contain;
  transition: var(--nav-transition);
}

.logo-img:hover {
  opacity: 0.88;
  transform: scale(1.03);
}

/* ============ DESKTOP NAV ============ */
.desktop-nav {
  display: flex;
  align-items: center;
  flex: 1;
  justify-content: center;
}

.desktop-nav > ul {
  display: flex;
  align-items: center;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 4px;
}

.desktop-nav > ul > li > a {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  color: var(--nav-navy);
  text-decoration: none;
  font-family: "Inter", sans-serif;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  border-radius: 8px;
  transition: var(--nav-transition);
  white-space: nowrap;
  position: relative;
}

.desktop-nav > ul > li > a::after {
  content: "";
  position: absolute;
  bottom: 4px;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: calc(100% - 28px);
  height: 2px;
  background: var(--nav-gold);
  border-radius: 2px;
  transition: transform 0.25s ease;
}

.desktop-nav > ul > li > a:hover {
  color: var(--nav-gold);
  background-color: rgba(212, 175, 55, 0.08);
}

.desktop-nav > ul > li > a:hover::after {
  transform: translateX(-50%) scaleX(1);
}

/* ============ DROPDOWN ============ */
.desktop-nav li.dropdown {
  position: relative;
}

.desktop-nav li.dropdown > a i {
  font-size: 0.72rem;
  transition: transform 0.3s ease;
  margin-left: 2px;
}

.desktop-nav li.dropdown:hover > a i,
.desktop-nav li.dropdown.open > a i {
  transform: rotate(180deg);
}

.desktop-nav li.dropdown > a:hover,
.desktop-nav li.dropdown.open > a {
  color: var(--nav-gold);
  background-color: rgba(212, 175, 55, 0.08);
}

/* Dropdown menu */
.desktop-nav .dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  background-color: var(--nav-white);
  border-radius: 12px;
  box-shadow:
    0 20px 50px rgba(0, 31, 63, 0.15),
    0 0 0 1px rgba(0, 31, 63, 0.06);
  list-style: none;
  padding: 8px;
  min-width: 240px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 0.25s ease,
    transform 0.25s ease,
    visibility 0.25s ease;
  z-index: 10000;
}

.desktop-nav li.dropdown:hover .dropdown-menu,
.desktop-nav li.dropdown.open .dropdown-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

.desktop-nav .dropdown-menu li {
  list-style: none;
}

.desktop-nav .dropdown-menu li a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  color: var(--nav-navy);
  text-decoration: none;
  font-family: "Inter", sans-serif;
  font-size: 0.88rem;
  font-weight: 500;
  border-radius: 8px;
  transition: var(--nav-transition);
  white-space: nowrap;
}

.desktop-nav .dropdown-menu li a i {
  color: var(--nav-gold);
  width: 18px;
  text-align: center;
  font-size: 0.9rem;
  flex-shrink: 0;
}

.desktop-nav .dropdown-menu li a:hover {
  background-color: rgba(212, 175, 55, 0.1);
  color: var(--nav-gold);
  padding-left: 18px;
}

/* Invisible bridge to prevent menu from closing when moving mouse over the gap */
.desktop-nav .dropdown-menu::after {
  content: "";
  position: absolute;
  top: -12px;
  left: 0;
  right: 0;
  height: 12px;
  background: transparent;
  z-index: -1;
}

/* Dropdown arrow */
.dropdown-menu::before {
  content: "";
  position: absolute;
  top: -6px;
  left: 50%;
  transform: translateX(-50%);
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-bottom: 6px solid var(--nav-white);
  filter: drop-shadow(0 -2px 2px rgba(0, 31, 63, 0.06));
}

/* ============ HEADER CTA BUTTON ============ */
/* ============ MODERN BUTTON SYSTEM ============ */
.cta-button, .header-cta, .mobile-nav-cta, .secondary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  position: relative;
  overflow: hidden;
  z-index: 1;
  border: none;
  cursor: pointer;
  text-transform: capitalize;
  letter-spacing: 0.3px;
  font-family: "Inter", sans-serif;
}

/* Shine Reflection Effect */
.cta-button::before, .header-cta::before, .mobile-nav-cta::before, .secondary-button::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    120deg,
    transparent,
    rgba(255, 255, 255, 0.4),
    transparent
  );
  transition: all 0.6s;
  z-index: -1;
}

.cta-button:hover::before, .header-cta:hover::before, .mobile-nav-cta:hover::before, .secondary-button:hover::before {
  left: 100%;
}

/* Primary Button (Gold Gradient) */
.cta-button, .header-cta, .mobile-nav-cta {
  background: linear-gradient(135deg, var(--nav-gold) 0%, var(--nav-gold-dark) 100%);
  color: var(--nav-navy);
  box-shadow: 0 8px 20px rgba(212, 175, 55, 0.25);
}

.cta-button:hover, .header-cta:hover, .mobile-nav-cta:hover {
  transform: translateY(-5px) scale(1.03);
  box-shadow: 0 15px 30px rgba(212, 175, 55, 0.45);
  filter: brightness(1.1);
  color: var(--nav-navy);
}

.cta-button:active, .header-cta:active, .mobile-nav-cta:active {
  transform: translateY(-2px) scale(0.98);
}

/* Header & Mobile Specific Overrides */
.header-cta {
  padding: 10px 20px;
  font-size: 0.88rem;
  border-radius: 10px;
}

.mobile-nav-cta {
  margin: 24px 16px;
  border-radius: 10px;
}

/* Secondary Button (Outline/Glass) */
.secondary-button {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: 2px solid rgba(255, 255, 255, 0.8) !important;
  color: #ffffff !important;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.secondary-button:hover {
  background: #ffffff;
  color: var(--nav-navy) !important;
  transform: translateY(-5px) scale(1.03);
  box-shadow: 0 15px 30px rgba(255, 255, 255, 0.2);
  border-color: #ffffff !important;
}

/* Icon Animation within buttons */
.cta-button i, .header-cta i, .mobile-nav-cta i, .secondary-button i {
  transition: transform 0.3s ease;
}

.cta-button:hover i, .header-cta:hover i, .mobile-nav-cta:hover i, .secondary-button:hover i {
  transform: translateX(3px) scale(1.2);
}

/* ============ HAMBURGER ============ */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 44px;
  height: 44px;
  background: none;
  border: 2px solid rgba(0, 31, 63, 0.12);
  border-radius: 8px;
  cursor: pointer;
  padding: 8px;
  transition: var(--nav-transition);
  flex-shrink: 0;
}

.hamburger:hover {
  border-color: var(--nav-gold);
  background-color: rgba(212, 175, 55, 0.08);
}

.hamburger span {
  display: block;
  width: 22px;
  height: 2px;
  background-color: var(--nav-navy);
  border-radius: 2px;
  margin: 3px 0;
  transition: var(--nav-transition);
  transform-origin: center;
}

.hamburger.active span:nth-child(1) {
  transform: translateY(8px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
  transform: scaleX(0);
}

.hamburger.active span:nth-child(3) {
  transform: translateY(-8px) rotate(-45deg);
}

/* ============ MOBILE NAV ============ */
.mobile-nav {
  display: none;
  position: fixed;
  top: var(--nav-height);
  left: 0;
  width: 100%;
  height: calc(100vh - var(--nav-height));
  background-color: var(--nav-navy);
  overflow-y: auto;
  z-index: 9998;
  transform: translateX(-100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  padding: 24px 0 40px;
}

.mobile-nav.open {
  transform: translateX(0);
}

.mobile-nav > ul {
  list-style: none;
  margin: 0;
  padding: 0 16px;
}

.mobile-nav > ul > li {
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.mobile-nav > ul > li:last-child {
  border-bottom: none;
}

.mobile-nav > ul > li > a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 12px;
  color: rgba(255, 255, 255, 0.9);
  text-decoration: none;
  font-family: "Inter", sans-serif;
  font-size: 1.05rem;
  font-weight: 500;
  transition: var(--nav-transition);
  border-radius: 8px;
}

.mobile-nav > ul > li > a:hover {
  color: var(--nav-gold);
  background-color: rgba(255, 255, 255, 0.05);
}

.mobile-nav > ul > li > a i.fa-chevron-down {
  font-size: 0.8rem;
  transition: transform 0.3s ease;
}

.mobile-nav > ul > li > a.open i.fa-chevron-down {
  transform: rotate(180deg);
}

/* Mobile dropdown submenu */
.mobile-dropdown {
  list-style: none;
  margin: 0;
  padding: 0;
  max-height: 0;
  overflow: hidden;
  transition:
    max-height 0.4s ease,
    opacity 0.3s ease;
  opacity: 0;
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 8px;
  margin-bottom: 4px;
}

.mobile-dropdown.open {
  max-height: 600px;
  opacity: 1;
}

.mobile-dropdown li a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 20px;
  color: rgba(255, 255, 255, 0.75);
  text-decoration: none;
  font-family: "Inter", sans-serif;
  font-size: 0.92rem;
  font-weight: 400;
  transition: var(--nav-transition);
  border-radius: 6px;
}

.mobile-dropdown li a i {
  color: var(--nav-gold);
  width: 18px;
  text-align: center;
  font-size: 0.85rem;
}

.mobile-dropdown li a:hover {
  color: var(--nav-gold);
  background-color: rgba(255, 255, 255, 0.06);
  padding-left: 26px;
}

@media (max-width: 850px) {
  .hamburger {
    display: flex;
  }

  .mobile-nav {
    display: block;
  }
}

@media (max-width: 480px) {
  .nav-container {
    padding: 0 16px;
  }

  .logo-img {
    height: 44px;
  }
}
