/**
 * Header / navegación del hero
 * Referencia: docs/referencia-visual.png
 */

.hero__header {
  padding-top: clamp(1.4rem, 3.8vh, 2.5rem);
  padding-bottom: 0;
}

.site-header__layout {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 0.75rem clamp(1rem, 2vw, 2rem);
}

.site-header__brand {
  display: inline-flex;
  flex-shrink: 0;
  line-height: normal;
  text-decoration: none;
}

.site-header__brand-mark {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
}

.site-header__brand img {
  display: block;
  width: clamp(8rem, 11vw, 11.25rem);
  height: auto;
}

.site-header__tagline {
  display: block;
  max-width: clamp(17rem, 26vw, 26rem);
  color: #ffffff;
  font-family: var(--esac-font-family-nav);
  font-size: clamp(0.8rem, 0.98vw, 1.05rem);
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0.06em;
  line-height: 1.2;
  text-align: center;
  text-transform: uppercase;
}

.site-header__right {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: clamp(0.35rem, 0.7vh, 0.55rem);
  min-width: 0;
  width: 100%;
}

/* Fila superior: redes + CTA */
.site-header__utility {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.5rem clamp(0.65rem, 1vw, 1rem);
  width: 100%;
}

.site-header__social {
  display: flex;
  align-items: center;
  gap: clamp(0.45rem, 0.6vw, 0.65rem);
}

.site-header__social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-sizing: border-box;
  width: 1.85rem;
  height: 1.85rem;
  color: #fff;
  text-decoration: none;
  line-height: 1;
  transition:
    transform 0.2s ease,
    opacity 0.2s ease,
    filter 0.2s ease;
}

.site-header__social-link:hover,
.site-header__social-link:focus-visible {
  color: #fff;
  opacity: 0.92;
  transform: translateY(-1px);
}

.site-header__social-link--facebook {
  border-radius: 50%;
  background-color: #1877f2;
  font-size: 0.95rem;
}

.site-header__social-link--facebook i {
  margin-left: 1px;
}

.site-header__social-link--youtube {
  width: 2.1rem;
  height: 1.5rem;
  border-radius: 0.35rem;
  background-color: #ff0000;
  font-size: 0.85rem;
}

.site-header__social-link--instagram {
  width: 1.85rem;
  height: 1.85rem;
  border: 1.5px solid #fff;
  border-radius: 0.4rem;
  background-color: transparent;
  font-size: 0.95rem;
}

.site-header__social-link--tiktok {
  width: auto;
  height: auto;
  min-width: 0;
  min-height: 0;
  padding: 0;
  background-color: transparent;
  font-size: 1.35rem;
}

/* Botón INSCRÍBETE AHORA */
.btn-inscribete,
.site-header__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  height: clamp(2.25rem, 3.4vh, 2.45rem);
  min-height: clamp(2.25rem, 3.4vh, 2.45rem);
  padding: 2px 1.25rem 0;
  border-radius: 0.5rem;
  font-family: var(--esac-font-family-nav);
  font-size: clamp(0.85rem, 1vw, 0.98rem);
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0.05em;
  line-height: 1;
  text-align: center;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
  transition:
    filter 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.btn-inscribete:hover,
.btn-inscribete:focus-visible,
.site-header__cta:hover,
.site-header__cta:focus-visible {
  color: #fff;
  transform: translateY(-1px);
}

/* Navegación */
.site-header__nav {
  position: relative;
  display: block;
  align-self: stretch;
  width: 100%;
}

.site-header__nav::before,
.site-header__nav::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  height: 2px;
  pointer-events: none;
}

.site-header__nav::before {
  top: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(212, 210, 210, 0.25) 20%,
    rgba(212, 210, 210, 0.55) 50%,
    rgba(212, 210, 210, 0.25) 80%,
    transparent 100%
  );
}

.site-header__nav::after {
  bottom: 0;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(212, 210, 210, 0.25) 20%,
    rgba(212, 210, 210, 0.55) 50%,
    rgba(212, 210, 210, 0.25) 80%,
    transparent 100%
  );
}

.site-header__toggler {
  display: none;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  margin: 0.35rem 0;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 0.35rem;
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
}

.site-header__menu {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.25rem clamp(0.35rem, 0.6vw, 0.65rem);
  width: 100%;
  margin: 0;
  padding: 0.3rem 0;
  box-sizing: border-box;
}

.site-header__menu-item {
  flex: 0 1 auto;
}

.site-header__menu-link {
  position: relative;
  display: inline-block;
  padding: 0.12rem 0 0.28rem;
  color: #ffffff;
  font-family: var(--esac-font-family-nav);
  font-size: clamp(0.84rem, 1vw, 1.02rem);
  font-style: italic;
  font-weight: 400;
  letter-spacing: 0.06em;
  line-height: 1.2;
  text-decoration: none;
  text-transform: uppercase;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.site-header__menu-link:hover,
.site-header__menu-link:focus-visible {
  color: #ffffff;
}

.site-header__menu-link.is-active {
  color: #e81210;
}

.site-header__menu-link.is-active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.05rem;
  height: 1px;
  background-color: #e81210;
}

/* Responsive */
@media (max-width: 1199.98px) {
  .site-header__menu {
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 0.3325rem 0.8075rem;
  }
}

@media (max-width: 991.98px) {
  .site-header__layout {
    grid-template-columns: auto 1fr;
    align-items: start;
  }

  .site-header__right {
    align-items: stretch;
    width: 100%;
  }

  .site-header__utility {
    justify-content: flex-end;
  }

  .site-header__nav {
    position: relative;
    display: flex;
    justify-content: flex-end;
  }

  .site-header__nav::before,
  .site-header__nav::after {
    display: none;
  }

  .site-header__toggler {
    display: inline-flex;
  }

  .site-header__toggler i {
    display: inline-block;
    transition: transform 0.25s ease;
  }

  .site-header__toggler[aria-expanded="true"] i {
    transform: rotate(90deg);
  }

  .site-header__menu {
    display: flex;
    position: absolute;
    top: calc(100% + 0.5rem);
    right: 0;
    z-index: 50;
    flex-direction: column;
    align-items: flex-end;
    justify-content: flex-start;
    min-width: min(100vw - 2rem, 22rem);
    padding: 0.75rem;
    border: none;
    border-radius: 0.5rem;
    background: rgba(1, 2, 2, 0.95);
    backdrop-filter: blur(8px);
    gap: 0.15rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px) scale(0.97);
    transform-origin: top right;
    pointer-events: none;
    transition:
      opacity 0.25s cubic-bezier(0.16, 1, 0.3, 1),
      transform 0.25s cubic-bezier(0.16, 1, 0.3, 1),
      visibility 0.25s;
  }

  .site-header__menu.is-open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
  }

  .site-header__menu-link {
    padding: 0.5rem 0.25rem 0.65rem;
    white-space: normal;
  }

  .site-header__menu-link.is-active::after {
    bottom: 0.35rem;
  }
}

@media (max-width: 575.98px) {
  .site-header__layout {
    position: relative;
    grid-template-columns: 1fr;
    gap: 0.75rem;
  }

  .site-header__brand {
    justify-content: center;
    max-width: calc(100% - 5rem);
    margin-inline: auto;
  }

  .site-header__right {
    align-items: stretch;
  }

  .site-header__utility {
    flex-direction: column;
    align-items: center;
  }

  .site-header__nav {
    position: absolute;
    top: 0.25rem;
    right: 0;
    z-index: 50;
    width: auto;
    margin: 0;
    justify-content: flex-end;
  }

  .site-header__toggler {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    margin: 0;
    padding: 0;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 0.45rem;
    background: rgba(0, 0, 0, 0.45);
    color: #fff;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    transition: background-color 0.2s ease, border-color 0.2s ease;
  }

  .site-header__toggler:hover,
  .site-header__toggler:focus-visible {
    background: rgba(152, 10, 8, 0.4);
    border-color: rgba(255, 255, 255, 0.5);
  }

  .site-header__menu {
    top: calc(100% + 0.5rem);
    left: auto;
    right: 0;
    min-width: min(100vw - 2rem, 20rem);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 0.5rem;
    background: rgba(1, 2, 2, 0.97);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.85);
  }
}
