/* Chrome portal compartido (header sticky + footer). Los tokens los define cada theme. */

html,
body {
  margin: 0;
  padding: 0;
}

.ac-root,
.ac-root *,
.ac-root *::before,
.ac-root *::after {
  box-sizing: border-box;
}

.ac-root {
  font-family: var(--font-sans, Inter, system-ui, sans-serif);
  background: hsl(var(--background));
  color: hsl(var(--foreground));
  font-weight: 300;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  width: 100%;
  min-height: 100dvh;
  --ac-column: min(calc(100% - 3rem), 1200px);
}

.ac-container {
  width: var(--ac-column);
  max-width: none;
  margin: 0 auto;
  padding: 0;
}

.ac-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: hsl(var(--background) / 0.72);
  border-bottom: 1px solid hsl(var(--border));
  backdrop-filter: blur(12px);
  transition: background-color 180ms ease, border-color 180ms ease;
}

.ac-header.is-scrolled {
  background: hsl(var(--background) / 0.92);
  border-bottom-color: hsl(var(--border));
}

.ac-header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--spacing-md, 1.5rem);
  min-height: 3.75rem;
}

.ac-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 1.25rem;
  font-weight: 700;
  color: hsl(var(--foreground));
  letter-spacing: -0.03em;
  text-decoration: none;
  flex-shrink: 0;
}

.ac-mark {
  display: block;
  flex-shrink: 0;
  overflow: hidden;
  border-radius: 50%;
  background: transparent;
  line-height: 0;
}

.ac-mark img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: transparent;
  clip-path: circle(50%);
}

.ac-mark--nav {
  width: 1.9rem;
  height: 1.9rem;
}

.ac-mark--footer {
  width: 5.25rem;
  height: 5.25rem;
}

.ac-footer-brand-block {
  display: flex;
  align-items: flex-start;
  gap: 1.05rem;
}

.ac-logo:hover {
  color: hsl(var(--primary));
}

.ac-nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  background: none;
  border: none;
  padding: 0.5rem;
  min-width: 44px;
  min-height: 44px;
  cursor: pointer;
}

.ac-nav-toggle span {
  width: 22px;
  height: 2px;
  background: hsl(var(--foreground));
  display: block;
}

.ac-nav-list {
  --ac-nav-gap: var(--spacing-md, 1.5rem);
  display: flex;
  align-items: center;
  flex-wrap: nowrap;
  gap: var(--ac-nav-gap);
  list-style: none;
  margin: 0;
  padding: 0;
  white-space: nowrap;
}

.ac-nav-list > li:has(> a.ac-nav-link) + li:has(> a.ac-nav-link) {
  position: relative;
}

.ac-nav-list > li:has(> a.ac-nav-link) + li:has(> a.ac-nav-link)::before {
  content: "";
  position: absolute;
  left: calc(var(--ac-nav-gap) / -2);
  top: 50%;
  width: 1px;
  height: 0.85em;
  background: hsl(var(--border));
  transform: translateY(-50%);
  pointer-events: none;
}

.ac-nav-link {
  color: hsl(var(--foreground));
  font-weight: 500;
  font-size: var(--text-sm, 0.875rem);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  padding: 0.25rem 0;
  white-space: nowrap;
}

.ac-nav-link:hover,
.ac-nav-link.is-active {
  color: hsl(var(--primary));
}

.ac-nav-has-children {
  position: relative;
}

.ac-nav-submenu {
  display: none;
  position: absolute;
  top: calc(100% + 0.35rem);
  left: 0;
  min-width: 14rem;
  margin: 0;
  padding: 0.45rem 0;
  list-style: none;
  background: hsl(var(--card));
  border: 1px solid hsl(var(--border));
  border-radius: var(--radius, 0.5rem);
  box-shadow: 0 10px 28px hsl(var(--foreground) / 0.08);
  z-index: 40;
}

/* Puente invisible: el gap visual no debe romper el :hover al bajar al panel. */
.ac-nav-submenu::before {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  top: -0.45rem;
  height: 0.45rem;
}

.ac-nav-has-children:hover > .ac-nav-submenu,
.ac-nav-has-children:focus-within > .ac-nav-submenu {
  display: block;
}

.ac-nav-submenu .ac-nav-link {
  display: block;
  padding: 0.45rem 0.9rem;
  white-space: normal;
}

@media (max-width: 1023px) {
  .ac-nav-submenu {
    position: static;
    display: block;
    min-width: 0;
    margin: 0.35rem 0 0.15rem 0.75rem;
    padding: 0;
    border: 0;
    box-shadow: none;
    background: transparent;
  }

  .ac-nav-submenu::before {
    content: none;
  }
}

.avx-brand,
.avx-ultra {
  font-weight: 700;
  letter-spacing: -0.02em;
  color: hsl(var(--primary));
}

.ac-logo .avx-brand,
.ac-footer-brand .avx-brand,
.ac-nav-link .avx-brand,
.ac-footer a .avx-brand,
.ac-footer-tagline .avx-brand,
.ac-footer-bottom .avx-brand {
  color: hsl(var(--primary));
}

.ac-logo .avx-ultra,
.ac-footer-brand .avx-ultra,
.ac-nav-link .avx-ultra,
.ac-footer a .avx-ultra,
.ac-footer-tagline .avx-ultra,
.ac-footer-bottom .avx-ultra {
  color: hsl(var(--primary));
}

.ac-btn-primary .avx-brand {
  color: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
}

.ac-nav-tools {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  flex-shrink: 0;
  padding-left: 0.5rem;
  border-left: 1px solid hsl(var(--border));
  margin-left: 0.15rem;
}

.ac-locale,
.ac-scheme {
  display: flex;
  gap: 0.35rem;
  align-items: center;
  flex-shrink: 0;
}

.ac-nav-tools .ac-scheme {
  padding-left: 0.5rem;
  border-left: 1px solid hsl(var(--border));
}

.ac-scheme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  min-width: 2.25rem;
  min-height: 2.25rem;
  padding: 0;
  border: 1px solid hsl(var(--border));
  border-radius: calc(var(--radius, 0.5rem) - 2px);
  background: hsl(var(--card) / 0.6);
  color: hsl(var(--foreground));
  cursor: pointer;
  transition: border-color 160ms ease, background-color 160ms ease, color 160ms ease;
}

.ac-scheme-toggle:hover {
  border-color: hsl(var(--primary) / 0.55);
  color: hsl(var(--primary));
}

.ac-scheme-toggle:focus-visible {
  outline: 2px solid hsl(var(--primary));
  outline-offset: 2px;
}

.ac-scheme-icon {
  width: 1.05rem;
  height: 1.05rem;
}

.ac-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.7rem 1.25rem;
  border-radius: calc(var(--radius, 0.5rem) - 2px);
  font-size: var(--text-sm, 0.875rem);
  font-weight: 600;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: var(--transition, all 0.2s ease);
  font-family: inherit;
}

.ac-btn-primary {
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground)) !important;
  box-shadow: 0 4px 12px hsl(var(--primary) / 0.3);
}

.ac-btn-primary:hover {
  background: hsl(var(--primary) / 0.9);
  transform: translateY(-1px);
}

.ac-nav-cta {
  padding: 0.45rem 0.9rem;
}
.ac-nav-cta.avx-btn--locale,
.ac-nav-link.avx-btn--locale,
.ac-btn.avx-btn--locale,
.ws-portal-btn.avx-btn--locale,
.ws-portal-text-link.avx-btn--locale {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition:
    transform 180ms ease,
    background-color 180ms ease,
    box-shadow 180ms ease;
}
.ws-portal-text-link.avx-btn--locale {
  justify-content: flex-start;
  align-self: flex-start;
  max-width: 100%;
}
.avx-btn--locale .avx-btn-sizer {
  display: grid;
  visibility: hidden;
  pointer-events: none;
  white-space: nowrap;
  font: inherit;
  font-weight: inherit;
}
.avx-btn--locale .avx-btn-sizer > span {
  grid-area: 1 / 1;
  white-space: nowrap;
}
.avx-btn--locale .avx-btn-label {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  white-space: nowrap;
  pointer-events: none;
}
.ws-portal-text-link.avx-btn--locale .avx-btn-label {
  justify-content: flex-start;
}

/* CTA text-link con flecha: el LocaleFit no debe tapar el ícono. */
.ws-portal-text-link--arrow.avx-btn--locale {
  gap: 0.4rem;
}
.ws-portal-text-link--arrow.avx-btn--locale .avx-btn-locale-core {
  position: relative;
  display: inline-grid;
  max-width: 100%;
}
.ws-portal-text-link--arrow.avx-btn--locale .avx-btn-sizer {
  display: grid;
}
.ws-portal-text-link--arrow.avx-btn--locale .avx-btn-label {
  position: absolute;
  inset: 0;
}

.ac-header a:focus-visible,
.ac-header button:focus-visible,
.ac-footer a:focus-visible,
.ac-footer button:focus-visible,
.ac-float-btn:focus-visible {
  outline: 2px solid hsl(var(--primary));
  outline-offset: 3px;
}

.ac-nav-backdrop {
  display: none;
}

.ac-footer {
  border-top: 1px solid hsl(var(--border) / 0.7);
  padding: 1.15rem 0 1rem;
  background: hsl(var(--background));
}

.ac-footer-tagline,
.ac-footer p,
.ac-footer li {
  color: hsl(var(--muted-foreground));
  font-size: var(--text-sm, 0.875rem);
}

.ac-footer-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem 1.5rem;
  min-height: 2.25rem;
}

.ac-footer-legal {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 0.15rem 0.85rem;
  list-style: none;
  padding: 0;
  margin: 0;
  min-width: 0;
}

.ac-footer-legal-spacer {
  display: block;
  min-width: 0;
}

.ac-footer-legal a {
  color: hsl(var(--muted-foreground));
  font-size: 0.75rem;
  font-weight: 400;
  text-decoration: none;
  white-space: nowrap;
}

.ac-footer-legal a:hover {
  color: hsl(var(--foreground));
  text-decoration: underline;
}

.ac-footer-legal span {
  color: hsl(var(--muted-foreground));
  font-size: 0.75rem;
  font-weight: 400;
}

/* Banner cookies — mismo lenguaje visual del chrome portal (sobre float dock) */
.ac-cookie {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 220;
  box-sizing: border-box;
  padding: 1rem 1.15rem calc(1rem + env(safe-area-inset-bottom, 0px));
  background: hsl(var(--card) / 0.97);
  border-top: 1px solid hsl(var(--border));
  box-shadow: 0 -12px 40px hsl(var(--background) / 0.55);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  color: hsl(var(--foreground));
  font-family: var(--font-sans, Inter, system-ui, sans-serif);
  font-weight: 300;
  line-height: 1.55;
}

.ac-cookie *,
.ac-cookie *::before,
.ac-cookie *::after {
  box-sizing: border-box;
}

.ac-cookie-inner {
  width: min(100%, var(--ac-column, 1120px));
  max-width: none;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.95rem 1.35rem;
}

.ac-cookie-text {
  margin: 0;
  flex: 1 1 18rem;
  font-size: 0.875rem;
  line-height: 1.55;
  color: hsl(var(--muted-foreground));
}

.ac-cookie-text a {
  color: hsl(var(--primary));
  font-weight: 600;
  text-decoration: none;
}

.ac-cookie-text a:hover {
  text-decoration: underline;
}

.ac-cookie-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  flex: 0 0 auto;
}

.ac-cookie-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.5rem;
  padding: 0.55rem 1.15rem;
  border-radius: 0.45rem;
  font-size: 0.8125rem;
  font-weight: 600;
  font-family: inherit;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background-color 160ms ease, border-color 160ms ease, color 160ms ease,
    box-shadow 160ms ease, transform 160ms ease;
}

.ac-cookie-btn--primary {
  border: none;
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  box-shadow: 0 4px 14px hsl(var(--primary) / 0.32);
}

.ac-cookie-btn--primary:hover {
  background: hsl(var(--primary) / 0.92);
  box-shadow: 0 6px 18px hsl(var(--primary) / 0.4);
}

.ac-cookie-btn--ghost {
  border: 1px solid hsl(var(--border));
  background: hsl(var(--background) / 0.35);
  color: hsl(var(--foreground));
}

.ac-cookie-btn--ghost:hover {
  border-color: hsl(var(--primary) / 0.45);
  color: hsl(var(--primary));
}

.ac-cookie-btn:focus-visible {
  outline: 2px solid hsl(var(--primary));
  outline-offset: 2px;
}

.ac-footer-links {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.1rem 1.15rem;
  margin: 0;
  min-width: 0;
}

.ac-footer-contact {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 0.05rem;
  margin: 0 0 0 auto;
  flex-shrink: 0;
}

.ac-contact {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  min-width: 40px;
  min-height: 40px;
  color: hsl(var(--muted-foreground) / 0.9);
  border-radius: 999px;
}

.ac-contact svg {
  width: 1.2rem;
  height: 1.2rem;
  flex-shrink: 0;
}

.ac-footer h4 {
  color: hsl(var(--foreground));
  font-size: var(--text-sm, 0.875rem);
  margin: 0 0 var(--spacing-sm, 1rem);
}

.ac-footer ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.ac-footer a {
  color: hsl(var(--muted-foreground));
  text-decoration: none;
  font-weight: 400;
}

.ac-footer a:hover {
  color: hsl(var(--foreground));
}

.ac-footer a.ac-contact {
  color: hsl(var(--muted-foreground));
}

.ac-footer a.ac-contact:hover {
  color: hsl(var(--primary));
}

.ac-footer-bottom {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
  border-top: 1px solid hsl(var(--border) / 0.55);
  margin-top: 0.75rem;
  padding-top: 0.7rem;
}

.ac-footer-bottom > .ac-footer-legal,
.ac-footer-bottom > .ac-footer-legal-spacer {
  flex: 1 1 auto;
  justify-content: flex-start;
}

.ac-footer-bottom p,
.ac-footer-copy {
  margin: 0;
  flex: 0 1 auto;
  font-size: 0.75rem;
  font-weight: 400;
  text-align: center;
  white-space: nowrap;
}

.ac-footer-copy-brand::after {
  content: ". ";
}

.ac-footer-copy-rights {
  display: inline;
}

.ws-build {
  flex: 1 1 auto;
  justify-self: end;
  margin: 0;
  text-align: right;
  font-size: 0.625rem;
  font-weight: 400;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.05em;
  line-height: 1;
  color: color-mix(in srgb, currentColor 38%, transparent);
  user-select: all;
  white-space: nowrap;
}

@media (max-width: 640px) {
  .ac-footer-bottom {
    flex-wrap: wrap;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    row-gap: 0.45rem;
  }

  .ac-footer-bottom > .ac-footer-legal,
  .ac-footer-bottom > .ac-footer-legal-spacer,
  .ac-footer-bottom p,
  .ac-footer-bottom .ac-footer-copy,
  .ac-footer-bottom .ws-build {
    flex: 0 1 auto;
    width: 100%;
    max-width: 100%;
    text-align: center;
    justify-content: center;
  }

  .ac-footer-bottom p,
  .ac-footer-copy {
    white-space: normal;
    line-height: 1.4;
  }

  .ac-footer-copy {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.2rem;
  }

  .ac-footer-copy-brand::after {
    content: none;
  }

  .ac-footer-legal {
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.3rem 0.75rem;
  }

  .ac-footer-legal a {
    white-space: normal;
  }
}

.ac-float {
  position: fixed;
  right: max(1.15rem, env(safe-area-inset-right));
  bottom: max(1.15rem, env(safe-area-inset-bottom));
  z-index: 160;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.7rem;
}

.ac-float-btn {
  width: 3.15rem;
  height: 3.15rem;
  min-width: 44px;
  min-height: 44px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid hsl(var(--border));
  box-shadow: 0 10px 28px hsl(220 30% 4% / 0.28);
  transition: transform 160ms ease, box-shadow 160ms ease, background-color 160ms ease;
  text-decoration: none;
  appearance: none;
  -webkit-appearance: none;
  padding: 0;
  cursor: pointer;
}

.ac-float-btn:hover {
  transform: translateY(-2px);
}

.ac-float-pdf {
  position: relative;
  background: hsl(var(--accent));
  color: hsl(var(--accent-foreground));
  border-color: transparent;
  box-shadow:
    0 6px 16px hsl(220 30% 4% / 0.16),
    0 8px 22px hsl(var(--accent) / 0.34);
}

.ac-float-pdf:hover,
.ac-float-pdf:focus-visible {
  background: hsl(var(--accent));
  box-shadow:
    0 8px 20px hsl(220 30% 4% / 0.2),
    0 10px 26px hsl(var(--accent) / 0.42);
}



.ac-float-top {
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  border-color: transparent;
  box-shadow:
    0 6px 16px hsl(220 30% 4% / 0.18),
    0 8px 22px hsl(var(--primary) / 0.34);
}

.ac-float-top:hover {
  background: hsl(var(--primary));
  box-shadow:
    0 8px 20px hsl(220 30% 4% / 0.22),
    0 10px 26px hsl(var(--primary) / 0.42);
}

html[data-ws-color-scheme="light"] .ac-float-top {
  box-shadow:
    0 6px 16px hsl(220 20% 18% / 0.12),
    0 8px 20px hsl(var(--primary) / 0.28);
}

html[data-ws-color-scheme="light"] .ac-float-top:hover {
  box-shadow:
    0 8px 18px hsl(220 20% 18% / 0.14),
    0 10px 24px hsl(var(--primary) / 0.36);
}

.ac-float-top:focus-visible {
  outline: 2px solid hsl(var(--primary-foreground));
  outline-offset: 3px;
}

.ac-float-wa {
  background: #25d366;
  color: #fff;
  border-color: transparent;
}

.ac-float-wa:hover {
  background: #1ebe5a;
}

body.ac-nav-open {
  overflow: hidden;
}

/* Tier T + M: hamburger through 1023px (guía 28) */
@media (max-width: 1023px) {
  .ac-nav-toggle {
    display: flex;
  }

  .ac-nav-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 198;
    background: hsl(220 30% 4% / 0.45);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
  }

  .ac-nav-backdrop.is-open {
    opacity: 1;
    pointer-events: auto;
  }

  .ac-nav {
    position: fixed;
    inset: 3.75rem 0 auto 0;
    background: hsl(var(--background));
    border-bottom: 1px solid hsl(var(--border));
    padding: var(--spacing-md, 1.5rem);
    transform: translateX(-100%);
    transition: transform 0.25s ease, visibility 0.25s ease;
    z-index: 199;
    max-height: calc(100dvh - 3.75rem);
    overflow-y: auto;
    visibility: hidden;
    pointer-events: none;
  }

  .ac-nav.is-open {
    transform: translateX(0);
    visibility: visible;
    pointer-events: auto;
  }

  .ac-nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: var(--spacing-sm, 1rem);
  }

  .ac-nav-list > li:has(> a.ac-nav-link) + li:has(> a.ac-nav-link)::before {
    content: none;
  }

  .ac-nav-list > li:has(> a.ac-nav-link) + li:has(> a.ac-nav-link) {
    padding-top: 0.75rem;
    margin-top: 0.15rem;
    border-top: 1px solid hsl(var(--border));
  }

  .ac-nav-tools {
    width: 100%;
    justify-content: flex-start;
    padding: 0.75rem 0 0;
    margin: 0.15rem 0 0;
    border-left: none;
    border-top: 1px solid hsl(var(--border));
  }

  .ac-nav-cta {
    width: 100%;
    justify-content: center;
    min-height: 44px;
  }
}

@media (min-width: 1024px) {
  .ac-nav {
    display: flex;
    align-items: center;
    flex-shrink: 1;
    min-width: 0;
  }

  .ac-nav-list {
    --ac-nav-gap: 0.85rem;
    gap: var(--ac-nav-gap);
  }

  .ac-nav-cta {
    padding: 0.4rem 0.85rem;
    flex-shrink: 0;
  }

  .ac-header-inner {
    gap: 1rem;
  }
}

@media (min-width: 1024px) and (max-width: 1279px) {
  .ac-nav-list {
    --ac-nav-gap: 0.65rem;
    gap: var(--ac-nav-gap);
  }

  .ac-nav-link {
    font-size: 0.8rem;
  }

  .ac-nav-cta {
    padding: 0.35rem 0.7rem;
  }

  .ac-scheme-toggle {
    width: 2rem;
    height: 2rem;
    min-width: 2rem;
    min-height: 2rem;
  }
}

@media (max-width: 767px) {
  .ac-root {
    --ac-column: min(calc(100% - 2rem), 1200px);
  }

  .ac-footer-bar {
    flex-wrap: wrap;
  }

  .ac-footer-contact {
    margin-left: auto;
  }

  .ac-mark--footer {
    width: 4.25rem;
    height: 4.25rem;
  }

  .ac-float {
    right: max(0.85rem, env(safe-area-inset-right));
    bottom: max(0.85rem, env(safe-area-inset-bottom));
    gap: 0.55rem;
  }

  .ac-float-btn {
    width: 2.85rem;
    height: 2.85rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ac-btn,
  .ac-nav,
  .ac-nav-backdrop,
  .ac-float-btn {
    transition: none;
  }

  .ac-float-btn:hover {
    transform: none;
  }
}

