/* ============================================================
   TuffWrap Header + Mega Menu — vanilla CSS, no dependencies.
   Ported from the standalone component. Global resets from the
   original (body{}, a{}, ul{}) are SCOPED to the header here so
   activating the theme does not restyle the rest of the site.
   ============================================================ */
:root {
  --white: #ffffff;
  --slate-50: #f8fafc;
  --slate-100: #f1f5f9;
  --slate-200: #e2e8f0;
  --slate-300: #cbd5e1;
  --slate-500: #64748b;
  --slate-600: #475569;
  --slate-700: #334155;
  --slate-800: #1e293b;
  --sky-50: #f0f9ff;
  --sky-500: #0ea5e9;
  --sky-600: #0284c7;
  --sky-700: #0369a1;
  --red-500: #ef4444;
  --red-600: #dc2626;

  --gray: #767676;

  /* Variante panels (Industries): fondo gris del popup y panel oscuro. */
  --panel-bg: #f4f4f5;
  --panel-ink: #1c1c1c;
  --panel-ink-text: #d8d8d8;
  --panel-cta-border: #1a9bd7;

  /* Marca TuffWrap */
  --navy: #1b2a4d;
  /* enlaces de nav / teléfono */
  --brand-red: #e11b32;
  /* botón CONTACT US */

  --header-max: 124rem;
  /* max-w-[124rem] */
  --focus-ring: 0 0 0 2px rgba(14, 165, 233, 0.6);

  /* Alto aproximado del header flotante: 12px + 76px + 12px. Se usa para
     que los anclajes en página no queden debajo de la barra. */
  --tw-header-h: 100px;
}

/* El header flota sobre el contenido, así que un enlace a #ancla debe
   parar por debajo de él en vez de quedar tapado. */
html {
  scroll-padding-top: calc(var(--tw-header-h) + 12px);
}

.tw-site-header *,
.tw-site-header *::before,
.tw-site-header *::after,
.mobile-drawer *,
.mobile-drawer *::before,
.mobile-drawer *::after,
.mega-popup *,
.mega-popup *::before,
.mega-popup *::after {
  box-sizing: border-box;
}

.tw-site-header a,
.mobile-drawer a,
.mega-popup a {
  color: inherit;
  text-decoration: none;
}

.tw-site-header ul,
.mobile-drawer ul,
.mega-popup ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

/* ---------- Estructura del header ---------- */
/* Flotante: la barra se superpone al contenido en lugar de ocupar sitio en
   el flujo, de modo que un hero a sangre empieza en el borde superior y la
   tarjeta del header queda encima.
   Se ancla con left/right en vez de width:100% porque el header tiene
   padding propio y en content-box eso desbordaría a lo ancho. */
.tw-site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 99;
  box-sizing: border-box;
  padding: 12px;
  font-family: "azo-sans-web", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--slate-800);
}

/* La barra de admin de WordPress también es fixed: bajar el header para
   no quedar debajo de ella. */
.admin-bar .tw-site-header {
  top: 32px;
}

@media screen and (max-width: 782px) {
  .admin-bar .tw-site-header {
    top: 46px;
  }
}

/* Al ser flotante, el header tapa los primeros ~100px de la página. Eso es
   lo que se busca en las páginas con hero a sangre, pero no en las que
   empiezan con un título (blog, contacto…). Añadir la clase
   `tw-header-offset` al body de esas páginas les reserva el hueco.
   En Elementor: Configuración de la página → Avanzado → Clases CSS. */
body.tw-header-offset {
  padding-top: var(--tw-header-h);
}

@media (min-width: 640px) {
  .tw-site-header {
    padding: 12px 20px;
  }
}

@media (min-width: 1024px) {
  .tw-site-header {
    padding: 12px 24px;
  }
}

/* Contenedor centrado que sirve de ancla para el popup full-width. */
.tw-header-inner {
  position: relative;
  max-width: var(--header-max);
  margin: 0 auto;
}

.header-bar {
  display: flex;
  align-items: center;
  min-height: 76px;
  padding: 0 16px;
  background: var(--white);
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: 6px;
  box-shadow: 0 10px 30px -14px rgba(15, 23, 42, 0.28);
}

@media (min-width: 640px) {
  .header-bar {
    padding: 0 20px;
  }
}

@media (min-width: 1024px) {
  .header-bar {
    padding: 0 24px;
  }
}

.logo {
  margin-right: auto;
  flex-shrink: 0;
  border-radius: 2px;
  outline: none;
}

.logo:focus-visible {
  box-shadow: var(--focus-ring);
}

.logo img {
  display: block;
  height: 48px;
  width: auto;
  object-fit: contain;
}

@media (min-width: 640px) {
  .logo img {
    height: 52px;
  }
}

@media (min-width: 1280px) {
  .logo {
    margin-right: 20px;
  }
}

@media (min-width: 1536px) {
  .logo {
    margin-right: 40px;
  }
}

/* ---------- Nav principal (desktop) ---------- */
.primary-nav {
  display: none;
}

@media (min-width: 1280px) {
  .primary-nav {
    display: flex;
  }
}

.nav-list {
  display: flex;
  align-items: center;
}

.nav-trigger,
.nav-simple-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 44px;
  padding: 0 14px;
  font-size: 14px;
  font-weight: 700;
  color: var(--navy);
  white-space: nowrap;
  background: none;
  border: none;
  cursor: pointer;
  outline: none;
  transition: color 0.15s ease;
  font-family: inherit;
}

@media (min-width: 1536px) {

  .nav-trigger,
  .nav-simple-link {
    padding: 0 18px;
    font-size: 15px;
  }
}

.nav-trigger:hover,
.nav-simple-link:hover {
  color: var(--sky-600);
}

.nav-trigger:focus-visible,
.nav-simple-link:focus-visible {
  box-shadow: var(--focus-ring);
}

.nav-item.is-active>.nav-trigger,
.nav-simple-link.is-active {
  color: var(--sky-700);
}

.nav-chevron {
  width: 15px;
  height: 15px;
  color: var(--slate-500);
  transition: transform 0.2s ease;
}

.nav-item.is-open .nav-chevron {
  transform: rotate(180deg);
}

/* ---------- Acciones (teléfono + CTA) ---------- */
.header-actions {
  margin-left: auto;
  display: none;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

@media (min-width: 1280px) {
  .header-actions {
    display: flex;
  }
}

@media (min-width: 1536px) {
  .header-actions {
    gap: 24px;
  }
}

.header-phone {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  color: var(--navy);
  white-space: nowrap;
  transition: color 0.15s ease;
}

.header-phone:hover {
  color: var(--sky-700);
}

.header-phone:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

.header-phone svg {
  width: 17px;
  height: 17px;
}

@media (min-width: 1536px) {
  .header-phone {
    font-size: 15px;
  }
}

.cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  min-width: 150px;
  padding: 0 20px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--brand-red);
  border: 1px solid var(--brand-red);
  outline: none;
  transition: background-color 0.15s ease, color 0.15s ease;
}

.cta-button:hover {
  background: var(--brand-red);
  color: var(--white);
}

.cta-button:focus-visible {
  box-shadow: 0 0 0 2px rgba(225, 27, 50, 0.5);
}

@media (min-width: 1536px) {
  .cta-button {
    min-width: 178px;
    font-size: 15px;
  }
}

/* ---------- Botón hamburguesa (móvil) ---------- */
.menu-toggle {
  margin-left: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  color: var(--slate-700);
  background: none;
  border: none;
  border-radius: 2px;
  cursor: pointer;
  outline: none;
}

.menu-toggle:hover {
  background: var(--slate-50);
}

.menu-toggle:focus-visible {
  box-shadow: var(--focus-ring);
}

@media (min-width: 1280px) {
  .menu-toggle {
    display: none;
  }
}

/* ============================================================
   MEGA MENU — popup full-width anclado bajo la barra
   ============================================================ */
.mega-popup {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 4px;
  /* sideOffset */
  z-index: 100;
  background: var(--white);
  color: var(--slate-800);
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: 6px;
  box-shadow: 0 18px 45px -18px rgba(15, 23, 42, 0.35);
  /* Con el header fijo, un panel más alto que la ventana ya no se puede
     alcanzar haciendo scroll en la página: que scrollee él. */
  max-height: calc(100vh - var(--tw-header-h) - 24px);
  overflow: hidden auto;
  overscroll-behavior: contain;
  font-family: "azo-sans-web", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  /* Estado cerrado */
  opacity: 0;
  transform: translateY(4px) scale(0.98);
  transform-origin: top center;
  pointer-events: none;
  visibility: hidden;
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0s linear 0.15s;
}

.mega-popup.is-open {
  opacity: 1;
  transform: translateY(0) scale(1);
  pointer-events: auto;
  visibility: visible;
  transition: opacity 0.15s ease, transform 0.15s ease, visibility 0s;
}

/* Contenedor que hace fade/swap entre menús */
.mega-panel {
  display: none;
}

.mega-panel.is-current {
  display: block;
}

.menu-heading {
  margin: 0 0 24px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--slate-300);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.025em;
  color: var(--slate-500);
}

/* ---- Variante COLUMNS ----
   Final design (Aug 2026): first column is a narrow "overview" rail sized to
   its own content, the remaining columns share the rest of the width evenly.
   Group headings lose the grey divider in favour of a bold dark label, and
   each link picks up a red rail mirroring the brand accent used sitewide. */
.mm-columns {
  display: grid;
  grid-template-columns: minmax(140px, max-content) repeat(3, minmax(0, 1fr));
  column-gap: 48px;
  padding: 40px 48px;
}

.mm-column {
  display: flex;
  flex-direction: column;
  row-gap: 44px;
}

.mm-group-links {
  display: flex;
  flex-direction: column;
  row-gap: 0;
}

.mm-group-links .mm-link {
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.mm-group-links :last-child .mm-link {
  padding-bottom: 0;
}

.mm-columns .menu-heading {
  margin: 0 0 16px;
  padding-bottom: 0;
  border-bottom: none;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--slate-800);
}

/* Un encabezado con destino propio se vuelve ancla. Hereda el aspecto del
   rótulo para no romper la jerarquía visual: sólo cambia al pasar el ratón. */
.mm-columns .menu-heading-link {
  color: inherit;
  outline: none;
  transition: color 0.15s ease;
}

.mm-columns .menu-heading-link:hover {
  color: var(--brand-red);
}

.mm-columns .menu-heading-link:focus-visible {
  box-shadow: var(--focus-ring);
}

.mm-link {
  display: block;
  border-radius: 0;
  outline: none;
  padding-left: 16px;
  border-left: 2px solid var(--brand-red);
}

.mm-link:focus-visible {
  box-shadow: var(--focus-ring);
}

.mm-link-label {
  display: block;
  font-size: 15px;
  font-weight: 300;
  line-height: 1.375;
  text-transform: uppercase;
  color: var(--slate-800);
  transition: color 0.15s ease;
}

.mm-link-label.is-emphasized {
  color: var(--sky-700);
}

.mm-link:hover .mm-link-label {
  color: var(--sky-700);
}

.mm-link.is-active .mm-link-label {
  color: var(--sky-700);
}

.mm-link-desc {
  display: block;
  margin-top: 4px;
  font-size: 15px;
  font-weight: 300;
  line-height: 1.4;
  text-transform: none;
  color: var(--gray);
}

/* ---- Variante PANELS ----
   Diseño final (Aug 2026): el popup pasa a fondo gris y los paneles laterales
   se leen como tarjetas sobre él — el rail en blanco, el feature en oscuro —
   con la columna central transparente para que el gris haga de separación. */
.mm-panels {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2fr) minmax(0, 1.4fr);
  align-items: stretch;
  gap: 56px;
  background: var(--panel-bg);
}

.mm-panel-rail {
  background: var(--white);
  padding: 44px 40px;
}

.mm-panel-middle {
  background: transparent;
  padding: 44px 0;
}

.mm-panel-feature {
  background: var(--panel-ink);
  color: var(--white);
  padding: 44px 40px;
}

/* Los encabezados pierden el filete gris: quedan como rótulo oscuro, igual
   que en la variante columns. */
.mm-panels .menu-heading {
  margin: 0 0 24px;
  padding-bottom: 0;
  border-bottom: none;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--slate-800);
}

.mm-panel-feature .menu-heading {
  color: var(--white);
}

/* A diferencia de columns, aquí la línea roja es una sola y recorre la lista
   entera, así que vive en el contenedor y no en cada enlace. */
.mm-rail-links,
.mm-linklist {
  border-left: 2px solid var(--brand-red);
}

.mm-rail-links {
  display: flex;
  flex-direction: column;
  row-gap: 0;
}

.mm-rail-link {
  display: block;
  padding: 10px 0 10px 22px;
  font-size: 14px;
  font-weight: 500;
  text-transform: uppercase;
  color: var(--slate-700);
  outline: none;
  transition: color 0.15s ease;
}

.mm-rail-link:hover {
  color: var(--brand-red);
}

.mm-rail-link.is-active {
  color: var(--brand-red);
}

.mm-rail-link:focus-visible {
  box-shadow: var(--focus-ring);
}

/* Middle: linkList */
.mm-linklist {
  display: flex;
  flex-direction: column;
  row-gap: 0;
}

.mm-logo-strip {
  margin-top: 56px;
}

.mm-logos {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 28px;
}

/* Sellos de certificación. Altura pareja y ancho automático: los originales
   tienen proporciones distintas y alinearlos por alto es lo que los hace
   leerse como una tira. */
.mm-logo {
  height: 44px;
  width: auto;
  max-width: 96px;
  object-fit: contain;
  flex-shrink: 0;
}

/* Middle: iconRows */
.mm-iconrows {
  display: flex;
  flex-direction: column;
  row-gap: 20px;
}

.mm-iconrow {
  display: flex;
  align-items: flex-start;
  gap: 20px;
}

.mm-row-title {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--slate-800);
}

.mm-row-sub {
  display: block;
  margin-top: 2px;
  font-size: 14px;
  font-weight: 400;
  color: var(--slate-500);
}

/* Middle: stats */
.mm-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  column-gap: 24px;
}

.mm-stat-value {
  display: block;
  font-size: 30px;
  font-weight: 700;
  line-height: 1;
  color: var(--sky-700);
}

.mm-stat-label {
  display: block;
  margin-top: 8px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.25;
  text-transform: uppercase;
  letter-spacing: 0.025em;
  color: var(--slate-500);
}

.mm-tagline {
  margin: 32px 0 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--slate-600);
}

/* Feature panel */
.mm-feature-image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  margin-bottom: 24px;
}

.mm-project-title {
  margin: 0 0 12px;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.01em;
  color: var(--slate-800);
}

.mm-panel-feature .mm-project-title {
  color: var(--white);
}

.mm-feature-body {
  margin: 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--slate-600);
}

.mm-feature-section {
  margin-top: 20px;
}

.mm-feature-section-heading {
  margin: 0;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.025em;
  color: var(--sky-700);
}

/* ---- Feature sobre fondo oscuro ----
   El panel invierte el contraste, así que el cuerpo y los rótulos se
   reasignan aquí en vez de tocar las reglas base que comparten los demás
   menús (Compliance, About), todavía sobre fondo claro. */
.mm-panel-feature .mm-feature-body,
.mm-panel-feature .mm-feature-section-body {
  color: var(--panel-ink-text);
}

.mm-panel-feature .mm-feature-section-heading {
  color: var(--white);
  font-size: 14px;
  letter-spacing: 0.01em;
}

.mm-panel-feature .mm-feature-section {
  margin-top: 24px;
}

/* El CTA deja de ser sólido: contorno azul sobre el oscuro. */
.mm-panel-feature .mm-primary-cta {
  height: 52px;
  padding: 0 32px;
  font-size: 14px;
  color: var(--white);
  background: transparent;
  border: 2px solid var(--panel-cta-border);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.mm-panel-feature .mm-primary-cta:hover {
  background: var(--panel-cta-border);
  color: var(--white);
}

/* Un CTA pendiente sobre oscuro necesita su propio gris: el claro de la regla
   general desaparecería contra el fondo. */
.mm-panel-feature a.mm-primary-cta[data-placeholder] {
  border-color: #4a4a4a;
  color: #6f6f6f;
}

/* El hueco de imagen sobre oscuro no puede usar el gris claro de la regla
   base: deslumbraría más que la propia foto. */
.mm-panel-feature .media-placeholder {
  background: #333333;
}

.mm-panel-feature [data-placeholder] {
  color: #6f6f6f;
}

.mm-panel-feature [data-placeholder]:hover {
  color: #6f6f6f;
}

.mm-feature-section-body {
  margin: 8px 0 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--slate-600);
}

.mm-feature-ctas {
  margin-top: 28px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
}

.mm-primary-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 24px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.025em;
  color: var(--white);
  background: var(--sky-600);
  outline: none;
  transition: background-color 0.15s ease;
}

.mm-primary-cta:hover {
  background: var(--sky-700);
}

.mm-primary-cta:focus-visible {
  box-shadow: var(--focus-ring);
}

/* El CTA del panel central (About → "Our Advantage") es de marca, no azul:
   contorno rojo con relleno pálido, y se invierte al pasar el ratón. */
.mm-panel-middle .mm-primary-cta {
  height: 56px;
  padding: 0 40px;
  font-size: 15px;
  letter-spacing: 0.02em;
  color: var(--brand-red);
  background: rgba(225, 27, 50, 0.07);
  border: 2px solid var(--brand-red);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.mm-panel-middle .mm-primary-cta:hover {
  background: var(--brand-red);
  color: var(--white);
}

.mm-panel-middle a.mm-primary-cta[data-placeholder] {
  border-color: var(--slate-200);
  background: none;
  color: var(--slate-300);
}

/* Placeholders de imagen (mantienen el layout sin assets) */
.media-placeholder {
  background: var(--slate-200);
  border-radius: 2px;
}

.media-16x9 {
  width: 100%;
  aspect-ratio: 16 / 9;
  margin-bottom: 24px;
}

.media-icon {
  width: 64px;
  height: 44px;
  flex-shrink: 0;
}

.media-logo {
  width: 64px;
  height: 40px;
}

.mm-icon-image {
  width: 64px;
  height: 44px;
  flex-shrink: 0;
  object-fit: contain;
}

.mm-linklist-cta {
  background: #fdecec;
  border: 1px solid var(--brand-red);
  color: var(--brand-red);
  width: 100%;
}

.mm-linklist-cta:hover {
  background: var(--brand-red);
  color: var(--white);
}

.mm-feature-checklist {
  list-style: none;
  margin: 16px 0 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.mm-feature-checklist li {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 14px;
  line-height: 1.4;
  color: var(--white);
}

.mm-check-icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  color: var(--sky-500);
}

/* ============================================================
   SIDEBAR MÓVIL
   Panel lateral deslizante. Vive en <body> (lo mueve header.js) para no
   depender del contexto de apilamiento del header.
   ============================================================ */
.md-backdrop {
  position: fixed;
  inset: 0;
  z-index: 99998;
  background: rgba(15, 23, 42, 0.5);
  animation: md-fade 0.2s ease;
}

.md-backdrop[hidden] {
  display: none;
}

@keyframes md-fade {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.mobile-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  width: min(360px, 86vw);
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  background: var(--white);
  border-left: 1px solid var(--slate-200);
  box-shadow: -18px 0 45px -22px rgba(15, 23, 42, 0.45);
  padding: 0 16px 24px;
  font-family: "azo-sans-web", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  transform: translateX(100%);
  transition: transform 0.26s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-drawer.is-open {
  transform: translateX(0);
}

.mobile-drawer[hidden] {
  display: none;
}

@media (min-width: 1280px) {

  .mobile-drawer,
  .md-backdrop {
    display: none !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mobile-drawer {
    transition: none;
  }

  .md-backdrop {
    animation: none;
  }
}

/* Bloquea el scroll del documento mientras el panel está abierto. */
html.tw-drawer-open,
html.tw-drawer-open body {
  overflow: hidden;
}

.md-head {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 -16px;
  padding: 14px 16px;
  background: var(--white);
  border-bottom: 1px solid var(--slate-200);
}

.md-title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--slate-500);
}

/* Anclados bajo .mobile-drawer por lo mismo que los del header: el
   reset.css de Hello Elementor pinta `[type="button"]` con borde #c36 y
   empata en especificidad, y se carga después. Con dos clases gana esto. */
.mobile-drawer .md-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  margin-right: -10px;
  padding: 0;
  border: none;
  border-radius: 2px;
  background: none;
  color: var(--slate-700);
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

.mobile-drawer .md-close svg {
  width: 24px;
  height: 24px;
}

.mobile-drawer .md-close:hover {
  background: var(--slate-50);
}

.mobile-drawer .md-close:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

.md-nav {
  padding-top: 4px;
}

/* Fila de nivel 1: enlace + botón de acordeón, cada uno con su propio
   objetivo táctil para que se pueda ir a la sección sin abrirla. */
.md-row {
  display: flex;
  align-items: center;
  border-bottom: 1px solid var(--slate-100);
}

.md-row>a.md-top {
  flex: 1;
  display: block;
  padding: 15px 4px;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--slate-800);
}

.md-row>a.md-top.is-active {
  color: var(--sky-700);
}

.mobile-drawer .md-expand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 44px;
  height: 44px;
  padding: 0;
  border: none;
  border-radius: 2px;
  background: none;
  color: var(--slate-500);
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

.mobile-drawer .md-expand svg {
  width: 20px;
  height: 20px;
  transition: transform 0.2s ease;
}

.mobile-drawer .md-item.is-open .md-expand svg {
  transform: rotate(180deg);
}

.mobile-drawer .md-expand:hover {
  background: var(--slate-50);
  color: var(--slate-700);
}

.mobile-drawer .md-expand:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

.md-sublinks {
  padding: 6px 0 10px;
  background: var(--slate-50);
  margin: 0 -16px;
  padding-left: 16px;
  padding-right: 16px;
}

.md-sublinks[hidden] {
  display: none;
}

.md-sublinks a {
  display: block;
  padding: 11px 12px;
  font-size: 14px;
  color: var(--slate-600);
  transition: color 0.15s ease;
}

.md-sublinks a:hover,
.md-sublinks a.is-active {
  color: var(--sky-700);
}

.md-actions {
  margin-top: auto;
  padding-top: 20px;
  display: grid;
  gap: 12px;
}

.md-phone {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 44px;
  border: 1px solid var(--slate-200);
  font-size: 14px;
  font-weight: 600;
  color: var(--slate-700);
}

.md-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  border: 1px solid var(--brand-red);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--brand-red);
}

.tw-site-header .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ============================================================
   OVERRIDES — neutralizan el reset.css de Hello Elementor.
   Sus reglas [type=button]/button (borde rosa #c36, radio 3px,
   padding .5rem) empatan en especificidad con .nav-trigger, así
   que las anclamos bajo .tw-site-header para ganar el cascade.
   ============================================================ */
.tw-site-header .nav-trigger,
.tw-site-header .nav-simple-link {
  border: none;
  border-radius: 0;
  background: none;
  padding: 0 14px;
  color: var(--navy);
  font-size: 14px;
  transition: color 0.15s ease;
}

@media (min-width: 1536px) {

  .tw-site-header .nav-trigger,
  .tw-site-header .nav-simple-link {
    padding: 0 18px;
    font-size: 15px;
  }
}

.tw-site-header .nav-trigger:hover,
.tw-site-header .nav-simple-link:hover {
  background: none;
  color: var(--sky-600);
}

.tw-site-header .nav-item.is-active>.nav-trigger,
.tw-site-header .nav-simple-link.is-active {
  color: var(--sky-700);
}

.tw-site-header .menu-toggle {
  border: none;
  border-radius: 2px;
  background: none;
  padding: 0;
  width: 44px;
  height: 44px;
  color: var(--slate-700);
}

.tw-site-header .menu-toggle:hover {
  background: var(--slate-50);
  color: var(--slate-700);
}

/* El hamburguesa es solo para tablet y móvil. Va con specificity de dos
   clases y !important porque el reset del tema padre y el de un plugin se
   cargan DESPUÉS de esta hoja y reestilan `button` genéricamente; sin esto
   el botón reaparece en escritorio. */
.tw-site-header .menu-toggle {
  display: inline-flex;
}

@media (min-width: 1280px) {
  .tw-site-header .menu-toggle {
    display: none !important;
  }
}

/* ============================================================
   Enlaces pendientes
   Un enlace sin destino real (marcado mm-todo en Apariencia → Menús)
   se ve claramente como pendiente en vez de parecer funcional.
   Sigue siendo enfocable: no se oculta a la navegación por teclado.
   ============================================================ */
.tw-site-header [data-placeholder],
.mega-popup [data-placeholder],
.mobile-drawer [data-placeholder] {
  color: var(--slate-300);
  cursor: not-allowed;
  text-decoration: line-through;
  text-decoration-color: var(--slate-200);
  text-decoration-thickness: 1px;
}

/* Un enlace pendiente en la variante columns no debe llevar el riel rojo de
   marca — eso implicaría que el destino ya existe. */
.mm-link[data-placeholder] {
  border-left-color: var(--slate-200);
}

.tw-site-header [data-placeholder]:hover,
.mega-popup [data-placeholder]:hover,
.mobile-drawer [data-placeholder]:hover {
  color: var(--slate-300);
}

.mega-popup a.mm-primary-cta[data-placeholder] {
  border-color: var(--slate-200);
  background: none;
  color: var(--slate-300);
}

/* Header 2026 owns the complete header. The legacy child-theme drawer is
   rendered only as a fallback when no Elementor header template applies. */
@media (min-width: 1280px) {
  .tw-elementor-header .tw-header-mobile-drawer {
    display: none;
  }
}

@media (max-width: 1279.98px) {
  .tw-elementor-header {
    padding: 12px !important;
  }

  .tw-elementor-header .tw-header-desktop {
    display: none !important;
  }

  .tw-elementor-header .tw-header-mobile-drawer .mdn-30673 {
    padding: 0;
  }
}
