/* ====== Layout ====== */
#m-.hero-header,
.hero-header{
  padding: var(--block-py, 28px) 0;
}

#m- .hero-header__container,
.hero-header .hero-header__container{
  width: min(100%, var(--container-w, 1200px));
  margin: 0 auto;
  padding: 0 16px;

  display: flex;
  justify-content: space-between;
  align-items: flex-start; /* H1 y video alineados arriba */
  gap: var(--grid-gap, 40px);
}

@media (max-width: 900px){
  #m- .hero-header__container,
  .hero-header .hero-header__container{
    flex-direction: column;
    align-items: center; /* título centrado visualmente si lo alineas center */
  }
}

/* ====== Columna izquierda ====== */
.hero-header__col--left{
  flex: 1;
  display:grid;
  gap: 12px;
}

.hero-header__title{
  margin:0;
  font-family: var(--title-font, Poppins, sans-serif);
  font-size: var(--title-size, 56px);
  font-weight: var(--title-weight, 800);
  color: var(--title-color, #111);
  text-align: var(--title-align, left);
  line-height: 1.08;
}

.hero-header__subtitle{
  font-family: var(--sub-font, Poppins, sans-serif);
  font-size: var(--sub-size, 20px);
  font-weight: var(--sub-weight, 500);
  color: var(--sub-color, #222);
  text-align: var(--sub-align, left);
  line-height: 1.6;
}

.hero-header__ctas{
  display:flex; flex-wrap:wrap; gap: 16px; align-items:center;
}

/* ====== CTA botón ====== */
.hero-header__btn{
  background: var(--btn-bg, #111);
  color: var(--btn-text, #fff);
  padding: var(--btn-py, 18px) var(--btn-px, 28px);
  border: 0;
  border-radius: var(--btn-radius, 14px);
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transition: transform .06s ease, background-color .2s ease, opacity .2s ease;
}
.hero-header__btn:hover{ background: var(--btn-bg-hover, #222); transform: translateY(-1px); }
.hero-header__btn:focus{ outline: 2px solid #000; outline-offset: 2px; }

/* ====== CTA enlace ====== */
.hero-header__link{
  color: var(--link-color, #111);
  font-weight: 700;
  text-decoration: var(--link-underline, underline);
  text-underline-offset: 3px;
}
.hero-header__link:hover{ color: var(--link-color-hover, #00f); }

/* ====== Columna derecha (VIDEO) ====== */
.hero-header__col--right{
  flex: 1;
  display: flex;
  align-items: flex-start;   /* alinea arriba */
  width: 100%;
}
@media (max-width: 900px){
  .hero-header__col--right{
    align-self: stretch;      /* ocupa el ancho completo en móvil */
    width: 100%;
  }
}

/* Wrapper del player */
.hero-aspect{
  width: 100%;
  max-width: 100%;
  border-radius: var(--video-radius, 12px);
  overflow: hidden;
  background: #000;
}

/* Relación de aspecto moderna */
.hero-aspect--16x9{ aspect-ratio: 16 / 9; }
.hero-aspect--4x3 { aspect-ratio: 4 / 3; }
.hero-aspect--1x1 { aspect-ratio: 1 / 1; }

/* Fallback para navegadores sin aspect-ratio */
@supports not (aspect-ratio: 1 / 1) {
  .hero-aspect{ position: relative; }
  .hero-aspect::before{ content:""; display:block; width:100%; }
  .hero-aspect--16x9::before{ padding-top:56.25%; }
  .hero-aspect--4x3::before { padding-top:75%; }
  .hero-aspect--1x1::before { padding-top:100%; }
  .hero-aspect > *{ position:absolute; inset:0; }
}

/* Forzamos el player a ocupar el wrapper */
.hero-aspect iframe,
.hero-aspect video,
.hero-aspect .hs-video-wrapper,
.hero-aspect .hs-video-embed,
.hero-aspect [data-hs-responsive-embed],
.hero-aspect .vidyard-player{
  width: 100% !important;
  height: 100% !important;
  display: block !important;
}

/* ====== Modales ====== */
.hero-modal{ 
  display: none !important;
  position: fixed; inset: 0; z-index: 9999;
}
.hero-modal.is-open{ display: block !important; }
.hero-modal[aria-hidden="true"]{ display:none !important; }
.hero-modal[aria-hidden="false"]{ display:block !important; }

.hero-modal__backdrop{
  position: fixed; inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 9998;
}
.hero-modal__dialog{
  position: fixed;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  width: min(92vw, 720px);
  max-height: 85vh;
  overflow:auto;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(0,0,0,.25);
  padding: 24px;
  z-index: 9999;
}
.hero-modal__title{ margin: 0 0 12px 0; font: 600 22px/1.3 var(--sub-font, Poppins, sans-serif); }
.hero-modal__close{
  position:absolute; top:8px; right:12px;
  background:transparent; border:0; font-size:28px; line-height:1; cursor:pointer;
}
