/* ============================================================
   V CONSULTING COMPANY
   HEADER.CSS
   Topbar + Main Header + Mega Menu + Mobile Menu
   ============================================================ */


/* ============================================================
   TOP UTILITY BAR
   ============================================================ */

.topbar {
  width: 100%;
  background: var(--navy-950);
  color: var(--muted-light);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
}

.topbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 38px;
  padding-top: 8px;
  padding-bottom: 8px;
}

.topbar-services {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
}

.topbar-services span {
  color: var(--gold-400);
  margin: 0 10px;
}

.topbar-services span:first-child {
  margin-left: 0;
}

.topbar-services i {
  color: rgba(255,255,255,0.35);
  font-style: normal;
}

.topbar-contact {
  display: flex;
  align-items: center;
  gap: 22px;
}

.topbar-contact a {
  display: inline-flex;
  align-items: center;
  gap: 7px;

  color: var(--muted-light);

  white-space: nowrap;

  transition: color 0.25s ease;
}

.topbar-contact a:hover {
  color: var(--gold-400);
}

.topbar-contact svg {
  width: 13px;
  height: 13px;
  flex-shrink: 0;
}


/* ============================================================
   MAIN HEADER
   ============================================================ */

.site-header {
  position: sticky;
  top: 0;
  z-index: 500;

  width: 100%;

  background: rgba(250, 248, 244, 0.94);

  backdrop-filter: blur(14px) saturate(1.2);
  -webkit-backdrop-filter: blur(14px) saturate(1.2);

  border-bottom: 1px solid var(--line);

  transition:
    box-shadow 0.4s ease,
    background 0.3s ease;
}

.site-header.scrolled {
  background: rgba(250, 248, 244, 0.98);

  box-shadow:
    0 10px 30px rgba(14, 23, 41, 0.07);
}


/* ============================================================
   NAVIGATION ROW
   ============================================================ */

.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;

  min-height: 82px;

  padding-top: 14px;
  padding-bottom: 14px;

  transition:
    min-height 0.35s var(--ease),
    padding 0.35s var(--ease);
}

.site-header.scrolled .nav-row {
  min-height: 68px;

  padding-top: 9px;
  padding-bottom: 9px;
}


/* ============================================================
   BRAND
   ============================================================ */

.site-header > .container > .brand {
  display: inline-flex;
  align-items: center;

  gap: 13px;

  flex-shrink: 0;
}

.site-header .brand-mark {
  width: 46px;
  height: 46px;

  display: block;

  flex-shrink: 0;

  transition:
    width 0.35s var(--ease),
    height 0.35s var(--ease);
}

.site-header.scrolled .brand-mark {
  width: 40px;
  height: 40px;
}

.site-header .brand-text {
  min-width: 0;
}

.site-header .brand-text .brand-name {
  font-family: var(--font-display);

  font-size: 1.36rem;
  font-weight: 700;

  line-height: 1.05;

  color: var(--navy-950);

  white-space: nowrap;
}

.site-header .brand-text .brand-tag {
  margin-top: 3px;

  font-size: 0.66rem;
  line-height: 1.2;

  letter-spacing: 0.09em;
  text-transform: uppercase;

  color: var(--gold-600);

  font-weight: 700;

  white-space: nowrap;
}


/* ============================================================
   DESKTOP MAIN NAV
   ============================================================ */

.main-nav {
  display: flex;
  align-items: center;

  gap: 2px;

  margin-left: auto;
  margin-right: 20px;
}

.main-nav > a,
.nav-mega-trigger {
  position: relative;

  display: inline-flex;
  align-items: center;
  justify-content: center;

  min-height: 42px;

  padding: 10px 13px;

  border: 0;
  background: transparent;

  font-family: var(--font-body);

  font-size: 0.88rem;
  font-weight: 600;

  color: var(--charcoal);

  white-space: nowrap;

  cursor: pointer;

  transition:
    color 0.25s ease,
    background 0.25s ease;
}

.main-nav > a::after,
.nav-mega-trigger::after {
  content: "";

  position: absolute;

  left: 13px;
  right: 13px;
  bottom: 3px;

  height: 2px;

  background: var(--gold-500);

  transform: scaleX(0);

  transform-origin: center;

  transition:
    transform 0.3s var(--ease);
}

.main-nav > a:hover,
.nav-mega-trigger:hover {
  color: var(--navy-950);
}

.main-nav > a:hover::after,
.nav-mega-trigger:hover::after,
.nav-mega.is-open .nav-mega-trigger::after {
  transform: scaleX(1);
}


/* ============================================================
   LEGAL SERVICES TRIGGER
   ============================================================ */

.nav-mega {
  position: static;
}

.nav-mega-trigger {
  gap: 6px;
}

.mega-arrow {
  width: 14px;
  height: 14px;

  transition:
    transform 0.3s var(--ease);
}

.nav-mega:hover .mega-arrow,
.nav-mega.is-open .mega-arrow {
  transform: rotate(180deg);
}


/* ============================================================
   MEGA MENU
   ============================================================ */

.mega-menu {
  position: absolute;

  top: 100%;
  left: 0;
  right: 0;

  width: 100%;

  background: rgba(255,255,255,0.98);

  border-top: 1px solid rgba(169,132,63,0.18);
  border-bottom: 1px solid var(--line);

  box-shadow:
    0 22px 55px rgba(14, 30, 54, 0.13);

  opacity: 0;
  visibility: hidden;
  pointer-events: none;

  transform:
    translateY(-10px);

  transition:
    opacity 0.28s ease,
    transform 0.28s var(--ease),
    visibility 0.28s ease;
}

.nav-mega:hover .mega-menu,
.nav-mega.is-open .mega-menu {
  opacity: 1;

  visibility: visible;

  pointer-events: auto;

  transform: translateY(0);
}


/* ============================================================
   MEGA INNER
   ============================================================ */

.mega-inner {
  width: min(1240px, calc(100% - 40px));

  margin: 0 auto;

  padding: 32px 0 24px;

  display: grid;

  grid-template-columns:
    1.25fr
    1fr
    1fr
    1fr;

  column-gap: 28px;
}


/* ============================================================
   MEGA INTRO
   ============================================================ */

.mega-intro {
  padding-right: 24px;

  border-right: 1px solid var(--line);
}

.mega-kicker {
  display: inline-block;

  margin-bottom: 10px;

  font-size: 0.68rem;
  font-weight: 800;

  letter-spacing: 0.14em;

  color: var(--gold-600);
}

.mega-intro h3 {
  margin: 0 0 12px;

  font-family: var(--font-display);

  font-size: 1.65rem;
  line-height: 1.08;

  color: var(--navy-950);
}

.mega-intro p {
  margin: 0 0 20px;

  max-width: 300px;

  font-size: 0.82rem;

  line-height: 1.65;

  color: var(--muted);
}

.mega-view-all {
  display: inline-flex;

  align-items: center;

  gap: 8px;

  font-size: 0.78rem;

  font-weight: 800;

  color: var(--navy-950);

  transition:
    color 0.25s ease,
    gap 0.25s ease;
}

.mega-view-all span {
  color: var(--gold-600);

  font-size: 1rem;
}

.mega-view-all:hover {
  color: var(--gold-600);
  gap: 12px;
}


/* ============================================================
   MEGA COLUMNS
   ============================================================ */

.mega-column {
  min-width: 0;
}

.mega-heading {
  margin-bottom: 10px;

  padding-bottom: 9px;

  border-bottom: 1px solid var(--line);

  color: var(--navy-950);

  font-size: 0.72rem;

  font-weight: 800;

  letter-spacing: 0.08em;

  text-transform: uppercase;
}

.mega-column > a {
  display: flex;

  flex-direction: column;

  gap: 3px;

  padding: 9px 10px;

  margin: 0 -10px;

  border-radius: 8px;

  transition:
    background 0.25s ease,
    transform 0.25s ease;
}

.mega-column > a:hover {
  background: rgba(169,132,63,0.07);

  transform: translateX(3px);
}

.mega-column strong {
  color: var(--charcoal);

  font-size: 0.82rem;

  font-weight: 700;

  line-height: 1.3;
}

.mega-column > a:hover strong {
  color: var(--gold-600);
}

.mega-column > a span {
  color: var(--muted);

  font-size: 0.68rem;

  line-height: 1.35;
}


/* ============================================================
   MEGA BOTTOM
   ============================================================ */

.mega-bottom {
  grid-column: 1 / -1;

  margin-top: 25px;

  padding-top: 18px;

  border-top: 1px solid var(--line);

  display: flex;

  align-items: center;

  justify-content: space-between;

  gap: 20px;
}

.mega-bottom > div {
  display: flex;

  align-items: baseline;

  gap: 10px;
}

.mega-bottom-label {
  color: var(--navy-950);

  font-size: 0.8rem;

  font-weight: 800;
}

.mega-bottom-text {
  color: var(--muted);

  font-size: 0.72rem;
}


/* ============================================================
   HEADER ACTIONS
   ============================================================ */

.nav-actions {
  display: flex;

  align-items: center;

  gap: 12px;

  flex-shrink: 0;
}

.nav-cta {
  display: inline-flex;
}


/* ============================================================
   HAMBURGER
   ============================================================ */

.hamburger {
  display: none;

  width: 44px;
  height: 44px;

  padding: 0;

  border: 0;

  border-radius: 50%;

  background: var(--navy-950);

  align-items: center;
  justify-content: center;

  flex-direction: column;

  gap: 5px;

  flex-shrink: 0;

  cursor: pointer;

  transition:
    background 0.25s ease,
    transform 0.25s ease;
}

.hamburger:hover {
  background: var(--navy-800);
}

.hamburger span {
  display: block;

  width: 18px;
  height: 2px;

  background: var(--gold-400);

  border-radius: 2px;

  transition:
    transform 0.3s var(--ease),
    opacity 0.2s ease;
}

.hamburger.active span:nth-child(1) {
  transform:
    translateY(7px)
    rotate(45deg);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform:
    translateY(-7px)
    rotate(-45deg);
}


/* ============================================================
   TABLET / MOBILE HEADER
   ============================================================ */

@media (max-width: 1080px) {

  .main-nav {
    display: none;
  }

  .nav-cta {
    display: none;
  }

  .hamburger {
    display: flex;
  }

}


/* ============================================================
   MOBILE MENU
   ============================================================ */

.mobile-menu {
  position: fixed;

  inset: 0;

  z-index: 1000;

  width: 100%;
  height: 100dvh;

  background: var(--navy-950);

  display: flex;
  flex-direction: column;

  padding:
    max(22px, env(safe-area-inset-top))
    28px
    max(28px, env(safe-area-inset-bottom));

  overflow-y: auto;

  overscroll-behavior: contain;

  transform: translateY(-100%);

  visibility: hidden;

  pointer-events: none;

  transition:
    transform 0.5s var(--ease),
    visibility 0.5s ease;
}

.mobile-menu.open {
  transform: translateY(0);

  visibility: visible;

  pointer-events: auto;
}


/* ============================================================
   MOBILE MENU TOP
   ============================================================ */

.mobile-menu-top {
  display: flex;

  align-items: center;

  justify-content: space-between;

  width: 100%;

  margin-bottom: 32px;
}

.mobile-menu .brand {
  display: inline-flex;

  align-items: center;

  gap: 13px;

  flex-shrink: 0;
}

.mobile-menu .brand-mark {
  width: 46px;
  height: 46px;

  flex-shrink: 0;
}

.mobile-menu .brand-text {
  min-width: 0;
}

.mobile-menu .brand-text .brand-name {
  font-family: var(--font-display);

  font-size: 1.36rem;

  font-weight: 700;

  line-height: 1.05;

  color: var(--white);

  white-space: nowrap;
}


/* ============================================================
   MOBILE CLOSE
   ============================================================ */

.mobile-menu-close {
  width: 44px;
  height: 44px;

  padding: 0;

  border: 0;

  border-radius: 50%;

  background: rgba(255,255,255,0.08);

  display: flex;

  align-items: center;
  justify-content: center;

  flex-shrink: 0;

  color: var(--gold-400);

  cursor: pointer;

  transition:
    background 0.25s ease,
    transform 0.25s ease;
}

.mobile-menu-close:hover {
  background: rgba(255,255,255,0.14);

  transform: rotate(90deg);
}

.mobile-menu-close svg {
  width: 19px;
  height: 19px;
}


/* ============================================================
   MOBILE NAV
   ============================================================ */

.mobile-nav {
  display: flex;

  flex-direction: column;

  width: 100%;
}

.mobile-nav > a,
.mobile-nav-toggle {
  display: flex;

  align-items: center;

  justify-content: space-between;

  width: 100%;

  padding: 15px 4px;

  border: 0;

  border-bottom: 1px solid rgba(255,255,255,0.09);

  background: transparent;

  color: var(--white);

  font-family: var(--font-display);

  font-size: clamp(1.25rem, 5vw, 1.5rem);

  font-weight: 600;

  line-height: 1.2;

  text-align: left;

  cursor: pointer;

  transition:
    color 0.25s ease,
    padding-left 0.25s ease;
}

.mobile-nav > a:hover,
.mobile-nav-toggle:hover {
  color: var(--gold-400);

  padding-left: 9px;
}

.mobile-nav > a small,
.mobile-nav-toggle small {
  color: var(--gold-400);

  font-family: var(--font-body);

  font-size: 0.7rem;

  font-weight: 700;

  letter-spacing: 0.08em;

  flex-shrink: 0;
}


/* ============================================================
   MOBILE LEGAL DROPDOWN
   ============================================================ */

.mobile-nav-dropdown {
  width: 100%;
}

.mobile-nav-toggle {
  position: relative;
}

.mobile-nav-right {
  display: flex;

  align-items: center;

  gap: 12px;
}

.mobile-nav-arrow {
  width: 17px;
  height: 17px;

  color: var(--gold-400);

  transition:
    transform 0.3s var(--ease);
}

.mobile-nav-dropdown.is-open .mobile-nav-arrow {
  transform: rotate(180deg);
}

.mobile-submenu {
  max-height: 0;

  overflow: hidden;

  opacity: 0;

  transition:
    max-height 0.45s var(--ease),
    opacity 0.25s ease;
}

.mobile-nav-dropdown.is-open .mobile-submenu {
  max-height: 650px;

  opacity: 1;
}

.mobile-submenu a {
  display: flex;

  align-items: center;

  padding: 12px 8px 12px 18px;

  border-bottom: 1px solid rgba(255,255,255,0.055);

  color: rgba(255,255,255,0.72);

  font-family: var(--font-body);

  font-size: 0.86rem;

  line-height: 1.35;

  transition:
    color 0.25s ease,
    padding-left 0.25s ease;
}

.mobile-submenu a::before {
  content: "";

  width: 5px;
  height: 5px;

  margin-right: 10px;

  border-radius: 50%;

  background: var(--gold-500);

  opacity: 0.8;
}

.mobile-submenu a:hover {
  color: var(--gold-400);

  padding-left: 23px;
}


/* ============================================================
   MOBILE FOOTER
   ============================================================ */

.mobile-menu-footer {
  display: flex;

  flex-direction: column;

  gap: 12px;

  margin-top: auto;

  padding-top: 30px;
}

.mobile-menu-footer > a:not(.btn) {
  display: flex;

  align-items: center;

  color: var(--muted-light);

  font-size: 0.9rem;

  line-height: 1.4;

  transition: color 0.25s ease;
}

.mobile-menu-footer > a:not(.btn):hover {
  color: var(--gold-400);
}

.mobile-menu-footer .btn {
  margin-top: 8px;
}


/* ============================================================
   TOPBAR MOBILE
   ============================================================ */

@media (max-width: 860px) {

  .topbar {
    display: none;
  }

}


/* ============================================================
   SMALL DEVICES
   ============================================================ */

@media (max-width: 560px) {

  .container {
    padding-left: 20px;
    padding-right: 20px;
  }

  .nav-row {
    min-height: 70px;

    padding-top: 10px;
    padding-bottom: 10px;
  }

  .site-header.scrolled .nav-row {
    min-height: 62px;

    padding-top: 8px;
    padding-bottom: 8px;
  }

  .site-header .brand-mark,
  .site-header.scrolled .brand-mark {
    width: 40px;
    height: 40px;
  }

  .site-header .brand-text .brand-name {
    font-size: 1.18rem;
  }

  .site-header .brand-text .brand-tag {
    display: none;
  }

  .hamburger {
    width: 40px;
    height: 40px;
  }

  .mobile-menu {
    padding-left: 20px;
    padding-right: 20px;
  }

  .mobile-menu-top {
    margin-bottom: 25px;
  }

  .mobile-menu .brand-mark {
    width: 40px;
    height: 40px;
  }

  .mobile-menu .brand-text .brand-name {
    font-size: 1.18rem;
  }

  .mobile-menu-close {
    width: 40px;
    height: 40px;
  }

  .mobile-nav > a,
  .mobile-nav-toggle {
    padding-top: 13px;
    padding-bottom: 13px;

    font-size: 1.28rem;
  }

  .mobile-submenu a {
    font-size: 0.82rem;
  }

}


/* ============================================================
   VERY SMALL DEVICES
   ============================================================ */

@media (max-width: 380px) {

  .site-header .brand-text .brand-name {
    font-size: 1.06rem;
  }

  .mobile-menu .brand-text .brand-name {
    font-size: 1.06rem;
  }

  .mobile-nav > a,
  .mobile-nav-toggle {
    font-size: 1.18rem;
  }

}