/* =========================================================
   global-nav.css — Navbar, Topbar, Footer & Search Dropdown
   Cargado globalmente en todo el sitio via enqueues.php
   ========================================================= */

/* ─── CSS VARIABLES (subset needed globally) ─────────────── */
:root {
  --navy: #1E2362;
  --navy-dark: #18223F;
  --navy-deep: #08111F;
  --navy-mid: #0D1535;
  --cyan: #38BDF8;
  --orange: #F97316;
  --orange-h: #EA580C;
  --white: #FFFFFF;
  --gray-bg: #F4F7FB;
  --gray-line: #DDE3EE;
  --text: #0B1426;
  --r-xs: 4px;
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 16px;
  --r-xl: 24px;
  --r-pill: 100px;
  --max: 1380px;
  --t: .2s ease;
  --t-slow: .4s ease;
}

/* Body needs top padding to compensate for the fixed header (topbar + navbar) */
body {
  padding-top: 104px; /* 40px topbar + 64px navbar */
}

/* Exception: front-page handles its own layout (topbar+navbar are inside the template) */
.home body,
body.home,
body.page-template-front-page,
.page-template-front-page body {
  padding-top: 0 !important;
}

/* ─── TOPBAR ───────────────────────────────────────────────── */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1010;
  height: 40px;
  background: #040f1a;
  display: flex;
  align-items: center;
  transition: transform .42s cubic-bezier(.4, 0, .2, 1), opacity .38s ease;
}

.topbar.hidden {
  transform: translateY(-100%);
  transition: none !important; /* Instant hide to prevent showing behind navbar */
  opacity: 0;
  pointer-events: none;
}

.topbar__inner {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.topbar__message {
  font-size: 12px;
  color: rgba(255, 255, 255, .55);
  letter-spacing: .04em;
}

.topbar__message span {
  color: var(--cyan);
  font-weight: 600;
}

.topbar__lang {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
}

.topbar__lang a {
  font-size: 11.5px;
  font-weight: 600;
  color: rgba(255, 255, 255, .45);
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 3px 8px;
  border-radius: 3px;
  transition: var(--t);
}

.topbar__lang a.active,
.topbar__lang a:hover {
  color: #fff;
  background: rgba(255, 255, 255, .1);
}

.topbar__lang span {
  color: rgba(255, 255, 255, .2);
  font-size: 10px;
}

/* ─── NAVBAR ───────────────────────────────────────────────── */
.navbar {
  position: fixed;
  top: 40px;
  left: 0;
  right: 0;
  z-index: 1000;
  height: 64px;
  background-color: #0b2437;
  border-bottom: 2px solid rgba(14, 165, 233, .4);
  transition: top .42s cubic-bezier(.4, 0, .2, 1), background .3s, box-shadow .3s, border-color .3s;
}

/* When topbar hides, navbar slides up to top:0 seamlessly */
.navbar.at-top {
  top: 0;
}

.navbar.scrolled {
  box-shadow: 0 2px 20px rgba(14, 165, 233, .15);
}

/* Lang switcher inside navbar:
   - Hidden by default (visible in topbar)
   - Appears when navbar reaches the top (at-top class) */
.navbar__actions .navbar-lang {
  display: none;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  opacity: 0;
  transition: opacity .3s ease;
}

.navbar__actions .navbar-lang a {
  color: rgba(255, 255, 255, .6);
  text-decoration: none;
  transition: color .2s;
}

.navbar__actions .navbar-lang a:hover {
  color: #fff;
}

.navbar__actions .navbar-lang span {
  color: rgba(255, 255, 255, .2);
  font-size: 10px;
}

.navbar.at-top .navbar__actions .navbar-lang {
  display: flex;
  opacity: 1;
}

/* Light scan effect on load (Greets the user) */
@keyframes initialScan {
  0% { transform: translateX(-100%); opacity: 0; }
  20% { opacity: 1; }
  80% { opacity: 1; }
  100% { transform: translateX(300%); opacity: 0; }
}

.navbar::before {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 35%;
  height: 2px;
  background: linear-gradient(90deg, transparent, #38bdf8, #fff, #38bdf8, transparent);
  animation: initialScan 2.2s cubic-bezier(.4, 0, .2, 1) forwards;
  z-index: 11;
  pointer-events: none;
}

/* Scroll progress indicator */
.navbar::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: var(--scroll-progress, 0%);
  height: 2px;
  background: linear-gradient(90deg, #38bdf8, #fff, #38bdf8);
  box-shadow: 0 0 10px rgba(56, 189, 248, 0.4);
  z-index: 10;
  pointer-events: none;
  transition: width 0.1s ease-out;
}


.navbar__inner {
  display: flex;
  align-items: center;
  height: 64px;
  gap: 32px;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 60px);
}

.navbar__logo {
  flex-shrink: 0;
  display: flex;
  align-items: center;
}

.navbar__logo img {
  height: 30px;
  width: auto;
}

/* ─── Desktop nav (hidden on mobile) ─── */
.navbar__desktop-nav {
  flex: 1;
}

.navbar__desktop-menu {
  display: flex;
  align-items: center;
  gap: 2px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.navbar__desktop-menu > li > a {
  font-size: 13.5px;
  font-weight: 500;
  color: rgba(255, 255, 255, .68);
  padding: 6px 11px;
  border-radius: var(--r-sm);
  transition: var(--t);
  white-space: nowrap;
  display: flex;
  align-items: center;
}

.navbar__desktop-menu > li > a:hover,
.navbar__desktop-menu > li.current-menu-item > a,
.navbar__desktop-menu > li.current-page-ancestor > a {
  color: #fff;
  background: rgba(255, 255, 255, .08);
}

/* ─── DESKTOP DROPDOWN SUB-MENUS ─── */
.navbar__desktop-menu li {
  position: relative;
}

/* Sub-menu indicators for Desktop */
.navbar__desktop-menu .menu-item-has-children > a::after {
  content: '▾';
  margin-left: 6px;
  font-size: 10px;
  color: var(--cyan);
  transition: transform .3s;
  display: inline-block;
}

.navbar__desktop-menu .menu-item-has-children:hover > a::after {
  transform: rotate(180deg);
}

/* Desktop Dropdown Style */
.navbar__desktop-menu .sub-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: #0b2437 !important;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: var(--r-md);
  padding: 10px 0 !important;
  list-style: none !important;
  margin: 0 !important;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all .3s cubic-bezier(.22, 1, .36, 1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  z-index: 1000;
  display: block !important;
}

.navbar__desktop-menu li:hover > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.navbar__desktop-menu .sub-menu li {
  width: 100%;
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.navbar__desktop-menu .sub-menu a {
  padding: 10px 20px !important;
  font-size: 13px !important;
  color: rgba(255, 255, 255, .7) !important;
  display: block !important;
  width: 100%;
  box-sizing: border-box;
  text-decoration: none !important;
  transition: var(--t);
  white-space: nowrap;
  background: none !important;
  font-weight: 500 !important;
  border: none !important;
}

.navbar__desktop-menu .sub-menu a:hover {
  background: rgba(255, 255, 255, .05) !important;
  color: var(--cyan) !important;
  padding-left: 24px !important;
}

/* 3rd level sub-menus (Flyout to the right) */
.navbar__desktop-menu .sub-menu .sub-menu {
  top: 0 !important;
  left: 100% !important;
  margin-top: 0 !important;
  margin-left: 0 !important;
}

.navbar__desktop-menu .sub-menu li:hover > .sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateX(0);
}

.navbar__desktop-menu .sub-menu .menu-item-has-children > a::after {
  content: '▸' !important;
  margin-left: auto;
  font-size: 12px;
  display: inline-block;
}

.navbar__desktop-menu .sub-menu .menu-item-has-children:hover > a::after {
  transform: none;
  color: #fff;
}

/* Hide redundant WPML and login items from primary desktop menu since we have custom buttons for them */
.navbar__desktop-menu .menu-login-logout,
.navbar__desktop-menu .menu-item-language,
.navbar__desktop-menu .wpml-ls-item,
.navbar__desktop-menu .wpml-ls-slot-shortcode_actions {
  display: none !important;
}


/* ─── Mobile drawer nav ─── */
.navbar__nav {
  display: none;
  position: fixed;
  top: 0;
  right: -100%;
  width: min(340px, 90vw);
  height: 100vh;
  overflow-y: auto;
  background: var(--navy-deep);
  z-index: 1000;
  flex-direction: column;
  transition: right .35s ease;
  border-left: 1px solid rgba(255, 255, 255, .08);
}

.navbar--open .navbar__nav {
  right: 0;
  display: flex;
}

@media (max-width: 991px) {
  .navbar__desktop-nav {
    display: none;
  }
  .navbar__nav {
    display: flex;
  }
}

.navbar__mobile-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, .07);
}

.navbar__mobile-close {
  background: none;
  border: none;
  color: rgba(255, 255, 255, .6);
  font-size: 24px;
  cursor: pointer;
  padding: 4px 8px;
  border-radius: var(--r-sm);
  line-height: 1;
  transition: var(--t);
}

.navbar__mobile-close:hover {
  color: #fff;
  background: rgba(255, 255, 255, .08);
}

/* Mobile menu list */
.navbar__nav-list {
  list-style: none;
  margin: 0;
  padding: 12px 0;
}

.navbar__nav-list li a {
  display: block;
  padding: 12px 24px;
  font-size: 15px;
  font-weight: 500;
  color: rgba(255, 255, 255, .72);
  transition: var(--t);
}

.navbar__nav-list li a:hover,
.navbar__nav-list li.current-menu-item > a {
  color: #fff;
  background: rgba(255, 255, 255, .06);
}

/* Submenu */
.navbar__nav-list .sub-menu {
  list-style: none;
  padding: 0;
  display: none;
  background: rgba(255, 255, 255, .03);
}

.navbar__nav-list .menu-item-has-children.is-active > .sub-menu {
  display: block;
}

.navbar__nav-list .sub-menu li a {
  padding-left: 40px;
  font-size: 14px;
  color: rgba(255, 255, 255, .5);
}

/* Mobile footer actions */
.navbar__mobile-footer {
  margin-top: auto;
  padding: 20px 24px;
  border-top: 1px solid rgba(255, 255, 255, .07);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ─── Mobile hamburger toggle ─── */
.navbar__mobile-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 36px;
  height: 36px;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  cursor: pointer;
  border-radius: var(--r-sm);
  transition: var(--t);
}

.navbar__mobile-toggle:hover {
  background: rgba(255, 255, 255, .08);
}

.hamburger-line {
  display: block;
  width: 20px;
  height: 2px;
  background: rgba(255, 255, 255, .7);
  border-radius: 2px;
  transition: var(--t);
}

@media (max-width: 991px) {
  .navbar__mobile-toggle {
    display: flex;
  }
}

/* ─── Navbar actions (right side) ─── */
.navbar__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

/* Language switcher in navbar */
.navbar-lang {
  font-size: 11.5px !important;
}

/* Auth button — premium expandable version (same as home) */
.navbar__auth-btn {
  display: flex;
  align-items: center;
  color: rgba(255, 255, 255, .7);
  text-decoration: none;
  padding: 8px;
  border-radius: 8px;
  gap: 0;
  max-width: 36px;
  overflow: hidden;
  white-space: nowrap;
  transition: all .5s cubic-bezier(.22, 1, .36, 1);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.navbar__auth-btn:hover {
  max-width: 180px;
  gap: 10px;
  padding: 8px 16px 8px 10px;
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(56, 189, 248, 0.3);
  box-shadow: 0 0 15px rgba(56, 189, 248, 0.1);
}

.navbar__auth-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.navbar__auth-icon svg {
  width: 18px;
  height: 18px;
}

.navbar__auth-label {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  opacity: 0;
  transition: opacity .3s ease .1s;
}

.navbar__auth-btn:hover .navbar__auth-label {
  opacity: 1;
}

.navbar__auth-btn--out:hover {
  border-color: rgba(249, 115, 22, 0.4);
  box-shadow: 0 0 15px rgba(249, 115, 22, 0.1);
}

/* CTA button — same as home */
.navbar__cta {
  padding: 8px 18px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  transition: all .22s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--orange);
  color: #fff;
  white-space: nowrap;
}

.navbar__cta:hover {
  background: var(--orange-h);
  box-shadow: 0 4px 16px rgba(249, 115, 22, .4);
}

.navbar__cta-icon {
  display: none;
}

.navbar__cta-icon svg {
  width: 18px;
  height: 18px;
}

.navbar__cta-text {
  display: block;
}

/* ─── SEARCH BUTTON & DROPDOWN ─────────────────────────────── */
.navbar__search-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.navbar__search {
  width: 34px;
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--r-sm);
  color: rgba(255, 255, 255, .7);
  transition: var(--t);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.navbar__search:hover,
.navbar__search.is-active {
  color: #fff;
  background: rgba(255, 255, 255, .08);
}

.navbar__search svg {
  width: 16px;
  height: 16px;
}

/* Search dropdown panel */
.navbar__search-dropdown {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  width: 340px;
  background: var(--navy-dark);
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: var(--r-md);
  box-shadow: 0 16px 48px rgba(8, 17, 31, .45);
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity .2s ease, transform .2s ease;
  pointer-events: none;
  z-index: 999;
}

.navbar__search-dropdown:not([hidden]) {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.navbar__search-form {
  display: flex;
  align-items: center;
  gap: 0;
  padding: 8px;
}

.navbar__search-form input[type="search"] {
  flex: 1;
  background: rgba(255, 255, 255, .07);
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: var(--r-sm);
  padding: 10px 14px;
  color: #fff;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: var(--t);
  min-width: 0;
  -webkit-appearance: none;
  appearance: none;
}

.navbar__search-form input[type="search"]::placeholder {
  color: rgba(255, 255, 255, .3);
}

.navbar__search-form input[type="search"]:focus {
  border-color: rgba(56, 189, 248, .4);
  background: rgba(255, 255, 255, .1);
}

/* Remove default search field X button */
.navbar__search-form input[type="search"]::-webkit-search-cancel-button {
  display: none;
}

.navbar__search-form button[type="submit"] {
  flex-shrink: 0;
  width: 38px;
  height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--orange);
  border: none;
  border-radius: var(--r-sm);
  color: #fff;
  cursor: pointer;
  margin-left: 6px;
  transition: var(--t);
}

.navbar__search-form button[type="submit"]:hover {
  background: var(--orange-h);
}

.navbar__search-form button[type="submit"] svg {
  width: 15px;
  height: 15px;
}

/* ─── OVERLAY ──────────────────────────────────────────────── */
#nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, .6);
  z-index: 999;
  backdrop-filter: blur(2px);
  display: block;
  opacity: 0;
  pointer-events: none;
  transition: opacity .35s ease;
}

#nav-overlay.is-visible {
  opacity: 1;
  pointer-events: auto;
}

/* ─── BACK TO TOP ──────────────────────────────────────────── */
.back-top {
  position: fixed;
  bottom: 80px;
  right: 28px;
  z-index: 800;
  background: var(--navy-dark);
  border: 1px solid rgba(255, 255, 255, .12);
  color: rgba(255, 255, 255, .6);
  width: 40px;
  height: 40px;
  border-radius: var(--r-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity .3s, transform .3s, background .2s;
  pointer-events: none;
}

.back-top.visible {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

.back-top:hover {
  background: var(--navy);
  color: #fff;
}

.back-top svg {
  width: 16px;
  height: 16px;
}

/* ─── BUTTONS (global, needed on inner pages) ──────────────── */
.gn-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: var(--r-sm);
  font-weight: 600;
  transition: var(--t);
  white-space: nowrap;
  cursor: pointer;
  text-decoration: none;
}

.gn-btn-primary {
  background: var(--orange);
  color: #fff;
  padding: 14px 28px;
  font-size: 15px;
}

.gn-btn-primary:hover {
  background: var(--orange-h);
}

.gn-btn-secondary {
  background: transparent;
  color: #fff;
  padding: 13px 26px;
  font-size: 15px;
  border: 1.5px solid rgba(255, 255, 255, .3);
}

.gn-btn-secondary:hover {
  border-color: rgba(255, 255, 255, .7);
  background: rgba(255, 255, 255, .06);
}

.gn-btn-sm {
  padding: 9px 18px;
  font-size: 13px;
}

/* ─── FOOTER ───────────────────────────────────────────────── */
.footer {
  background: var(--navy-deep);
  border-top: 1px solid rgba(255, 255, 255, .06);
}

.footer__top {
  padding: clamp(56px, 6vw, 80px) 0;
}

.footer__inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 60px);
}

.footer__grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr 1fr;
  gap: 48px;
}


.footer__logo img {
  height: 26px;
  width: auto;
  margin-bottom: 20px;
}

.footer__brand-desc {
  font-size: 13.5px;
  color: rgba(255, 255, 255, .38);
  line-height: 1.7;
  max-width: 260px;
  margin-bottom: 24px;
}

.footer__social {
  display: flex;
  gap: 8px;
}

.footer__social-link {
  width: 34px;
  height: 34px;
  border-radius: var(--r-sm);
  background: rgba(255, 255, 255, .06);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--t);
}

.footer__social-link:hover {
  background: rgba(255, 255, 255, .14);
  color: #fff;
}

.footer__social-link svg {
  width: 15px;
  height: 15px;
  color: rgba(255, 255, 255, .55);
}

.footer__social-link:hover svg {
  color: #fff;
}

.footer__col-title {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .3);
  margin-bottom: 18px;
}

.footer__links {
  display: flex;
  flex-direction: column;
  gap: 11px;
}

.footer__links a {
  font-size: 13.5px;
  color: rgba(255, 255, 255, .45);
  transition: var(--t);
}

.footer__links a:hover {
  color: #fff;
}

.footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, .06);
  padding: 20px 0;
}

.footer__bottom-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 60px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer__copy {
  font-size: 12.5px;
  color: rgba(255, 255, 255, .3);
}

.footer__legal {
  display: flex;
  align-items: center;
  gap: 20px;
}

.footer__legal a {
  font-size: 12px;
  color: rgba(255, 255, 255, .3);
  transition: var(--t);
}

.footer__legal a:hover {
  color: rgba(255, 255, 255, .65);
}

.footer__legal span {
  color: rgba(255, 255, 255, .12);
}

/* ─── RESPONSIVE ───────────────────────────────────────────────── */
@media (max-width: 1100px) {
  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 991px) {
  /* On mobile, topbar is hidden; navbar moves to top:0 */
  .topbar {
    display: none !important;
  }

  .navbar {
    top: 0 !important;
    height: 70px;
    transition: all 0.3s ease;
  }

  .navbar.scrolled {
    top: 0 !important;
  }

  /* Body padding: just navbar height on mobile */
  body {
    padding-top: 70px;
  }

  .navbar__inner {
    padding: 0 12px;
    gap: 8px;
    height: 70px;
  }

  .navbar__logo img {
    width: 100px;
    height: auto;
  }

  /* Hide desktop nav, show mobile elements */
  .navbar__desktop-nav {
    display: none !important;
  }

  .navbar__mobile-toggle {
    display: flex !important;
    flex-direction: column;
    justify-content: space-between;
    width: 24px;
    height: 14px;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1100;
    padding: 0;
    margin-left: 5px;
    order: 10;
    flex-shrink: 0;
  }

  .hamburger-line {
    width: 100%;
    height: 2px;
    background: #fff;
  }

  /* Mobile drawer: full-screen slide-in from right */
  .navbar__nav {
    display: flex !important;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #0b2437;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    z-index: 1050;
    opacity: 0;
    visibility: hidden;
    transform: translateX(100%);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 0;
    overflow-y: auto;
  }

  .navbar--open .navbar__nav {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
  }

  /* Hide the hamburger icon when the drawer is open so it doesn't overlap the X */
  .navbar--open .navbar__mobile-toggle {
    opacity: 0;
    pointer-events: none;
  }

  .navbar__mobile-header {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, .05);
    margin-bottom: 10px;
  }

  .navbar__mobile-footer {
    width: 100%;
    padding: 30px 20px;
    margin-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, .05);
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
    background: rgba(0,0,0,.1);
  }

  .navbar__nav-list {
    flex-direction: column;
    width: 100%;
    padding: 10px 24px;
    gap: 4px;
  }

  .navbar__nav-list li {
    width: 100%;
    text-align: left;
  }

  .navbar__nav-list li a {
    font-size: 16px;
    font-weight: 600;
    padding: 14px 0;
    width: 100%;
    text-align: left;
    color: rgba(255, 255, 255, .9);
    border-bottom: 1px solid rgba(255, 255, 255, .04);
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-between !important;
    align-items: center !important;
    transition: color 0.3s;
  }

  .navbar__nav-list .is-active > a {
    color: var(--cyan);
    border-bottom-color: rgba(14, 165, 233, 0.2);
  }

  .navbar__nav-list .menu-item-has-children {
    display: flex !important;
    flex-wrap: wrap !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
  }

  .navbar__nav-list .menu-item-has-children > a {
    flex: 1 1 0% !important;
    width: auto !important;
    display: block !important;
    padding-right: 12px !important;
  }

  .navbar__nav-list .menu-item-has-children > a::after {
    display: none !important; /* Hide old arrow completely */
  }

  .navbar__submenu-toggle {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 44px !important;
    height: 44px !important;
    min-width: 44px !important;
    min-height: 44px !important;
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    border-radius: 50% !important;
    color: rgba(255, 255, 255, 0.65) !important;
    cursor: pointer !important;
    padding: 0 !important;
    margin: 6px 0 !important;
    outline: none !important;
    flex-shrink: 0 !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    z-index: 5 !important;
  }

  .navbar__submenu-toggle:hover,
  .navbar__submenu-toggle:focus {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(56, 189, 248, 0.4) !important;
    color: #fff !important;
    box-shadow: 0 0 12px rgba(56, 189, 248, 0.15) !important;
  }

  .navbar__submenu-toggle .submenu-toggle-svg {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    display: block !important;
  }

  .navbar__nav-list .menu-item-has-children.is-active > .navbar__submenu-toggle {
    background: rgba(56, 189, 248, 0.12) !important;
    border-color: rgba(56, 189, 248, 0.5) !important;
    color: var(--cyan) !important;
    box-shadow: 0 0 10px rgba(56, 189, 248, 0.2) !important;
  }

  .navbar__nav-list .menu-item-has-children.is-active > .navbar__submenu-toggle .submenu-toggle-svg {
    transform: rotate(180deg) !important;
  }

  .navbar__nav-list .sub-menu {
    display: block !important;
    width: 100% !important;
    padding-left: 16px;
    list-style: none;
    border-left: 1.5px solid rgba(14, 165, 233, 0.3);
    margin: 0 !important;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.5s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.4s ease;
  }

  .navbar__nav-list .menu-item-has-children.is-active > .sub-menu {
    max-height: 1200px !important;
    opacity: 1 !important;
    margin-top: 4px !important;
    margin-bottom: 12px !important;
  }

  .navbar__nav-list .sub-menu li a {
    font-size: 14.5px;
    font-weight: 500;
    opacity: 0.75;
    padding: 10px 0;
    border-bottom: none;
    color: #fff;
  }

  .navbar__nav-list .sub-menu li a:hover {
    opacity: 1;
    color: var(--cyan);
  }

  /* Hide redundant items in the mobile list */
  .navbar__nav-list .menu-login-logout,
  .navbar__nav-list .menu-item-language {
    display: none !important;
  }

  .navbar__actions {
    gap: 6px;
    margin-left: auto;
    flex-shrink: 0;
  }

  .navbar__auth-label, .navbar__cta-text {
    display: none;
  }

  /* Show lang switcher always on mobile */
  .navbar-lang, .navbar__actions .navbar-lang {
    display: flex !important;
    opacity: 1 !important;
    visibility: visible !important;
    gap: 0 !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    margin: 0 8px !important;
  }

  .navbar-lang a {
    min-width: 28px !important;
    text-align: center !important;
    color: #fff !important;
    padding: 4px 2px !important;
  }

  .navbar__auth-btn, .navbar__search {
    width: 36px;
    height: 36px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255,255,255,.05);
    border: 1px solid rgba(255,255,255,.1);
  }

  /* Hide orange CTA button from mobile navbar per design */
  .navbar__cta {
    display: none !important;
  }

  .navbar__search-dropdown {
    width: calc(100vw - 40px);
    right: -10px;
  }

  .footer__grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 720px) {
  .footer__grid {
    grid-template-columns: 1fr;
  }

  .footer__bottom-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .footer__social {
    flex-wrap: wrap;
  }
}

@media (max-width: 480px) {
  .navbar__auth-btn {
    padding: 7px 10px;
  }
}


/* --- NORMALIZACION ESTRICTA DE ENLACES Y ALTURA DE BOTONES --- */
.navbar a,
.navbar-lang a,
.topbar__lang a {
  text-decoration: none !important;
}

.navbar a:hover,
.navbar-lang a:hover,
.topbar__lang a:hover {
  text-decoration: none !important;
}

/* Fijar alturas de botones para evitar variaciones de 1px entre paginas */
.navbar__cta,
.navbar__auth-btn {
  height: 38px !important;
  box-sizing: border-box !important;
  line-height: 1 !important;
  display: flex !important;
  align-items: center !important;
}

/* ── Sticky mode: Button layout optimization ── */
.navbar.scrolled .navbar__auth-btn {
  max-width: 200px !important;
  gap: 10px !important;
  padding: 8px 16px 8px 10px !important;
  color: #fff !important;
  background: rgba(255, 255, 255, 0.08) !important;
  border-color: rgba(56, 189, 248, 0.3) !important;
}

.navbar.scrolled .navbar__auth-label {
  opacity: 1 !important;
}

/* Slower, smoother transition for the CTA collapse */
.navbar__cta {
  transition: all 0.65s cubic-bezier(0.4, 0, 0.2, 1) !important;
  overflow: hidden;
  white-space: nowrap;
}

.navbar__cta-text {
  display: inline-block;
  max-width: 200px;
  opacity: 1;
  transition: max-width 0.6s ease, opacity 0.4s ease, margin 0.6s ease;
}

.navbar.scrolled .navbar__cta {
  padding: 0 !important;
  width: 40px !important;
  height: 40px !important;
  min-width: 40px !important;
  border-radius: 50% !important;
  justify-content: center !important;
}

.navbar.scrolled .navbar__cta-text {
  max-width: 0 !important;
  opacity: 0 !important;
  margin: 0 !important;
  pointer-events: none;
}

.navbar.scrolled .navbar__cta-icon {
  display: flex !important;
  margin: 0 !important;
}

.navbar.scrolled .navbar__cta-icon svg {
  width: 18px !important;
  height: 18px !important;
}

/* =============================================================
   FONT NORMALIZATION — NAVBAR & TOPBAR
   Forzamos explícitamente la fuente en cada elemento del header
   para que NUNCA hereden la fuente del body de páginas específicas
   (articulos-styles.css fija 'Work Sans', single-corporate-v2.css
   usa 'Inter', etc.). Este bloque siempre gana.
   ============================================================= */

/* Fuerza Montserrat en absolutamente todo el navbar y topbar */
.topbar,
.topbar *,
.navbar,
.navbar * {
  font-family: var(--font-base, 'Montserrat', system-ui, -apple-system, sans-serif) !important;
}

/* ── Desktop nav: items del menú principal ─────────────────── */
.navbar__desktop-menu > li > a {
  font-size: 13.5px !important;
  font-weight: 500 !important;
  letter-spacing: 0 !important;
}

/* Hover / página activa en desktop */
.navbar__desktop-menu > li > a:hover,
.navbar__desktop-menu > li.current-menu-item > a,
.navbar__desktop-menu > li.current-page-ancestor > a {
  font-weight: 500 !important;
}

/* ── Desktop sub-menu ──────────────────────────────────────── */
.navbar__desktop-menu .sub-menu a {
  font-size: 13px !important;
  font-weight: 500 !important;
}

/* ── Mobile nav: items del menú ────────────────────────────── */
.navbar__nav-list li a {
  font-weight: 600 !important;
}

.navbar__nav-list .sub-menu li a {
  font-weight: 500 !important;
}

/* ── CTA button ────────────────────────────────────────────── */
.navbar__cta {
  font-weight: 700 !important;
  font-size: 13px !important;
}

/* ── Auth button ───────────────────────────────────────────── */
.navbar__auth-label {
  font-weight: 800 !important;
  font-size: 11px !important;
}

/* ── Lang switcher — pixel-identical en TODAS las páginas ────
   El home tiene padding adicional por front-page-v2.css;
   aquí lo normalizamos para que sea igual al corporate. */
.navbar-lang a,
.navbar__actions .navbar-lang a {
  font-weight: 600 !important;
  font-size: 11.5px !important;
  padding: 3px 8px !important;
  border-radius: 3px !important;
  color: rgba(255, 255, 255, .6) !important;
  letter-spacing: .06em !important;
  text-transform: uppercase !important;
  min-width: unset !important;
}

.navbar-lang a.active,
.navbar-lang a:hover,
.navbar__actions .navbar-lang a:hover {
  color: #fff !important;
  background: rgba(255, 255, 255, .1) !important;
}

.topbar__lang a {
  font-weight: 600 !important;
  font-size: 11.5px !important;
  padding: 3px 8px !important;
  border-radius: 3px !important;
}

/* ── Search button — lupa blanca en TODAS las páginas ───────── */
.navbar__search {
  color: rgba(255, 255, 255, .7) !important;
}

.navbar__search:hover,
.navbar__search.is-active {
  color: #fff !important;
}

.navbar__search svg {
  color: inherit !important;
  fill: none !important;
  stroke: currentColor !important;
}

/* ── Alturas fijas de botones (sin variaciones entre páginas) ── */
.navbar__cta,
.navbar__auth-btn {
  height: 38px !important;
  box-sizing: border-box !important;
  line-height: 1 !important;
  display: flex !important;
  align-items: center !important;
}
@media (max-width: 991px) {
  .navbar__cta,
  .navbar__auth-btn {
    display: none !important;
  }
}
