/* Ajustes responsive - Recinto AIA EXPONOR */

/* ============ espacio para el encabezado fijo ============ */
/* Divi reserva los 90px del header solo en escritorio; en tablet y celular el header tapaba el inicio */
@media (max-width: 980px){
  body:not(.et-fb) #page-container{
    padding-top: 90px !important;
  }
}

/* ============ titulos grandes ============ */
/* 70px fijos partian palabras en celular ("DESARRO-LLO") */
@media (max-width: 980px){
  body .nos-hero .nos-hero__text h1{
    font-size: clamp(34px, 8.6vw, 70px) !important;
    line-height: .95;
    overflow-wrap: normal;
    word-break: normal;
    hyphens: none;
  }
}

/* la bajada del hero viene en nowrap y bajo ~1230px sacaba scroll horizontal */
@media (max-width: 1279px){
  html body .nos-hero .nos-hero__text p{
    white-space: normal !important;
  }
}

/* ============ Nosotros: columnas apiladas ============ */
@media (max-width: 980px){
  body .nos-split-row{
    flex-direction: column !important;
  }
  body .nos-split-row > .et_pb_column{
    width: 100% !important;
    margin-right: 0 !important;
  }
  body .nos-split__main{
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
}

/* ============ Cotiza: formulario y datos de contacto apilados ============ */
@media (max-width: 980px){
  body .quote-page-row{
    flex-direction: column !important;
    min-height: 0;
  }
  body .quote-page-row > .et_pb_column{
    width: 100% !important;
    margin-right: 0 !important;
  }
}

/* ============ Planifica: titulo y selector de espacio ============ */
@media (max-width: 980px){
  body .aia-tech__head .et_pb_column{
    flex-wrap: wrap;
    padding: 0 20px !important;
  }
  body .aia-tech__title{
    flex: 1 1 100%;
  }
  body .aia-tech__title h1,
  body .aia-tech__title h3{
    margin-left: 0 !important;
    font-size: clamp(22px, 5.4vw, 30px);
    line-height: 1.15;
  }
  body .aia-tech__head .aia-tech__select{
    flex: 1 1 100%;
    width: 100%;
    max-width: 100%;
  }
}

/* ============ Inicio: slider principal ============ */
/* En una columna el texto + la foto no caben en la altura fija del slide: el texto se salia por arriba.
   El slide activo pasa a ocupar su espacio real y los demas quedan superpuestos para la transicion. */
@media (max-width: 980px){
  html body:not(.et-fb) .aia-hero-slider{
    min-height: 0 !important;
  }
  html body:not(.et-fb) .aia-hero-slider .et_pb_row.aia-hero-slide.is-active{
    position: relative !important;
    inset: auto !important;
  }
  html body .aia-hero-slider .et_pb_row.aia-hero-slide > .et_pb_column:first-child{
    justify-content: flex-start;
  }
}
@media (max-width: 600px){
  html body .aia-hero-slider .et_pb_row.aia-hero-slide > .et_pb_column:last-child{
    min-height: 46vh;
  }
}

/* ============ Cartelera: filtros y pestañas de año ============ */
@media (max-width: 980px){
  body .aia-filterbar{
    grid-template-columns: 1fr 1fr !important;
  }
  body .aia-filterbar .aia-filter-q{
    grid-column: 1 / -1;
  }
}
@media (max-width: 600px){
  body .aia-filterbar{
    grid-template-columns: 1fr !important;
  }
}
/* Divi le da margen inferior a cada modulo menos al ultimo y desalineaba "2027" */
body .aia-year-tabs .et_pb_module{
  margin-bottom: 0 !important;
}

/* ============ Inicio: titular en escritorio angosto (de 981 a 1919) ============ */
@media (min-width: 981px) and (max-width: 1919px){
  html body .aia-hero-slider .et_pb_row.aia-hero-slide > .et_pb_column:first-child{
    padding: 48px 40px 48px 72px !important; /* 72px: deja libre la flecha izquierda del slider */
  }
  html body .aia-hero-slider .et_pb_row.aia-hero-slide h1,
  html body .aia-hero-slider .et_pb_row.aia-hero-slide .et_pb_text h1{
    font-size: clamp(38px, 4.2vw, 90px);
    letter-spacing: -2px;
  }
  html body .aia-hero-slider .et_pb_row.aia-hero-slide{
    grid-template-columns: 1.1fr 1fr;
  }
}
/* De 981 a 1919 el titular crece parejo hasta empalmar con los 90px de Divi.
   Antes, desde 1200 volvia el 5.8vw del tema y "COMIENZA" no cabia (se partia). */
@media (min-width: 981px) and (max-width: 1919px){
  html body .aia-hero-slider .et_pb_row.aia-hero-slide h1,
  html body .aia-hero-slider .et_pb_row.aia-hero-slide .et_pb_text h1{
    font-size: clamp(38px, calc(6.77vw - 18.3px), 90px);
  }
}
/* "PROXIMOS EVENTOS DESTACADOS": el interlineado heredado era menor que la letra y las lineas se montaban al partirse */
body .cartelera-header .et_pb_text_inner p{
  line-height: 1.05 !important;
}

/* ============ Planifica: ficha tecnica sin textos cortados con "..." ============ */
body .aia-tech__list li{
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr);
  column-gap: 16px;
}
body .aia-tech__list li strong,
body .aia-tech__list li span{
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
}
/* en celular la etiqueta va arriba del valor (como estaba) */
@media (max-width: 680px){
  body .aia-tech__list li{
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   SEGUNDA PASADA DE DISEÑO (celular y tablet)
========================================================= */

/* ============ Inicio: slider ============ */
/* Flechas y puntos arriba de la foto; el cartel de cifras compacto abajo, sin tapar la imagen */
@media (max-width: 980px){
  html body .aia-hero-slider .aia-hero-arrow{
    top: auto !important;
    bottom: calc(52vh - 58px) !important;
    transform: none !important;
    width: 40px !important;
    height: 40px !important;
  }
  html body .aia-hero-slider .aia-hero-prev{ left: auto !important; right: 64px !important; }
  html body .aia-hero-slider .aia-hero-next{ right: 16px !important; }
  html body .aia-hero-slider .aia-hero-nav{
    left: 16px !important;
    right: auto !important;
    bottom: calc(52vh - 42px) !important;
    transform: none !important;
  }
}
@media (max-width: 600px){
  html body .aia-hero-slider .aia-hero-arrow{ bottom: calc(46vh - 58px) !important; }
  html body .aia-hero-slider .aia-hero-nav{ bottom: calc(46vh - 42px) !important; }
}
@media (max-width: 980px){
  html body .aia-hero-slider .aia-hero-badge{
    left: 14px !important;
    right: auto !important;
    bottom: 14px !important;
    width: auto !important;
    max-width: calc(100% - 28px);
    padding: 12px 18px !important;
  }
  html body .aia-hero-slider .aia-hero-badge .et_pb_text_inner{
    display: grid;
    grid-auto-flow: column;
    grid-template-rows: auto auto;
    column-gap: 22px;
    align-items: end;
  }
  html body .aia-hero-slider .aia-hero-badge .stat-number{
    font-size: 28px !important;
    line-height: 1 !important;
    margin: 0 !important;
  }
  html body .aia-hero-slider .aia-hero-badge .stat-label{
    font-size: 9px !important;
    margin: 4px 0 0 !important;
  }
}

/* ============ Inicio: titulos de seccion ============ */
html body .spaces-header .et_pb_text_inner p{
  line-height: 1.08 !important;
}
@media (max-width: 980px){
  /* el bloque de vista previa de noticias depende del hover; en pantallas tactiles solo acompaña */
  html body .news-preview-block{
    min-height: 0 !important;
    height: 240px !important;
  }
}

/* ============ Cartelera: cabecera y tarjetas en celular ============ */
@media (max-width: 980px){
  html body .et_pb_section.cartelera-hero{
    min-height: 360px !important;
  }
  html body .et_pb_section.cartelera-filters{
    padding: 28px 0 !important;
  }
}
@media (max-width: 600px){
  /* foto arriba y texto abajo: en dos columnas el titulo partia palabras ("EMPRESARIA-LES") */
  body .aia-events-grid .event-card-inner{
    grid-template-columns: 1fr !important;
    min-height: 0 !important;
  }
  body .aia-events-grid .event-image{
    min-height: 0 !important;
    aspect-ratio: 16 / 9;
    border-right: 0 !important;
    border-bottom: 2px solid rgba(15,23,42,.95);
  }
  body .aia-events-grid .event-info{
    padding: 18px 20px 20px !important;
  }
  body .aia-events-grid .event-name{
    font-size: 22px !important;
  }
}

/* ============ Detalle de noticia: titular en celular ============ */
@media (max-width: 600px){
  html body .aia-news-detail h1{
    font-size: clamp(28px, 8vw, 36px) !important;
    line-height: 1 !important;
  }
}

/* ============ Pie de pagina ============ */
@media (max-width: 980px){
  /* franja: el texto corre arriba a todo el ancho y el boton queda debajo, completo */
  html body .et-l--footer .aia-footer .big-cta-row{
    flex-direction: column !important;
    align-items: stretch !important;
    padding: 0 0 18px !important;
  }
  html body .et-l--footer .aia-footer .big-cta-row > .et_pb_column:last-child{
    margin: 0 !important;
    padding: 0 20px !important;
    justify-content: center !important;
  }
  html body .et-l--footer .aia-footer .footer-cta-btn,
  html body .et-l--footer .aia-footer a.footer-cta-btn{
    max-width: none !important;
    width: 100% !important;
    box-sizing: border-box !important;
    margin: 0 !important;
    text-align: center !important;
    padding: 14px 16px !important;
  }
  html body .et-l--footer .aia-footer .big-cta-row .et_pb_button_module_wrapper{
    width: 100%;
  }
  html body .et-l--footer .aia-footer .marquee .marquee-track > span{
    font-size: 30px !important;
  }

  /* grilla: marca y ubicacion arriba, luego Explorar y Contacto lado a lado */
  html body .et-l--footer .aia-footer .footer-grid-row{
    display: grid !important;
    grid-template-columns: 1fr 1fr;
  }
  html body .et-l--footer .aia-footer .footer-grid-row > .footer-col{
    width: auto !important;
    margin: 0 !important;
    padding: 34px 24px !important;
    border-right: 0 !important;
    border-bottom: 1px solid rgba(255,255,255,.10) !important;
  }
  html body .et-l--footer .aia-footer .footer-grid-row > .footer-col:first-child{
    grid-column: 1 / -1;
    display: flex !important;
    flex-direction: column;
  }
  html body .et-l--footer .aia-footer .footer-grid-row > .footer-col:nth-child(2){
    border-right: 1px solid rgba(255,255,255,.10) !important;
  }
  html body .et-l--footer .aia-footer .footer-grid-row > .footer-col:first-child .footer-logo{
    order: -1;
    margin-bottom: 24px !important;
  }
  html body .et-l--footer .aia-footer .footer-logo img{
    max-width: 170px !important;
  }
  html body .et-l--footer .aia-footer .footer-grid-row h3{
    margin-bottom: 14px !important;
  }
  html body .et-l--footer .aia-footer .footer-grid-row .et_pb_module{
    margin-bottom: 18px !important;
  }
  html body .et-l--footer .aia-footer .footer-grid-row .et_pb_module:last-child{
    margin-bottom: 0 !important;
  }
  html body .et-l--footer .aia-footer .footer-nav ul.et-menu > li{
    padding: 0 !important;
    margin: 0 0 10px !important;
  }
  html body .et-l--footer .aia-footer .footer-nav ul.et-menu > li > a{
    font-size: 18px !important;
  }
  html body .et-l--footer .aia-footer .footer-grid-row p,
  html body .et-l--footer .aia-footer .footer-grid-row .footer-contact-info{
    font-size: 13px !important;
  }
}
@media (max-width: 400px){
  html body .et-l--footer .aia-footer .footer-grid-row > .footer-col{
    padding: 30px 18px !important;
  }
  html body .et-l--footer .aia-footer .footer-nav ul.et-menu > li > a{
    font-size: 16px !important;
  }
  html body .et-l--footer .aia-footer .footer-grid-row p,
  html body .et-l--footer .aia-footer .footer-grid-row .footer-contact-info{
    font-size: 12px !important;
  }
}

/* ============ Planifica: ficha y servicios en tablet/celular ============ */
@media (max-width: 980px){
  html body .aia-tech__panel .aia-tech__col--details{
    padding: 26px 22px 22px !important;
  }
  /* tres servicios por fila en tablet: de a uno quedaban tarjetas enormes y casi vacias */
  html body .aia-services .et_pb_row.aia-services__grid{
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 14px !important;
    margin-bottom: 14px !important;
  }
  html body .aia-services .et_pb_row.aia-services__grid > .et_pb_column{
    width: auto !important;
    margin: 0 !important;
  }
  html body .aia-services .et_pb_row.aia-services__grid .et_pb_module{
    margin-bottom: 0 !important;
    height: 100%;
  }
}
@media (max-width: 767px){
  /* en celular y tablet chica: una por fila pero horizontal y compacta (icono a la izquierda);
     en 3 columnas a ~680px "CONECTIVIDAD" no cabia en la tarjeta */
  html body .aia-services .et_pb_row.aia-services__grid{
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    margin-bottom: 10px !important;
  }
  html body .aia-service-item{
    padding: 16px 18px !important;
  }
  html body .aia-service-item .et_pb_blurb_content{
    display: flex;
    align-items: center;
    gap: 16px;
    max-width: none;
    text-align: left;
  }
  html body .aia-service-item .et_pb_main_blurb_image{
    margin: 0 !important;
    flex: 0 0 auto;
  }
  html body .aia-service-item .et_pb_blurb_container{
    padding: 0 !important;
    text-align: left !important;
  }
  html body .aia-service-item .et_pb_module_header,
  html body .aia-service-item .et_pb_blurb_description,
  html body .aia-service-item .et_pb_blurb_description p{
    text-align: left !important;
  }
}

/* ============ Inicio: fotografias generales en dos columnas ============ */
/* cada fila trae una sola columna con varias fotos: la grilla va en la columna */
@media (max-width: 980px){
  html body .et_pb_row.gallery-grid-row{
    display: block !important;
    margin-bottom: 6px !important;
  }
  html body .et_pb_row.gallery-grid-row > .et_pb_column{
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 6px !important;
    width: 100% !important;
    margin: 0 !important;
  }
  html body .et_pb_row.gallery-grid-row .gallery-tile{
    margin: 0 !important;
    height: 220px !important;
  }
  html body .et_pb_row.gallery-grid-bottom .gallery-tile:last-child{
    grid-column: 1 / -1;
  }
}
@media (max-width: 600px){
  html body .et_pb_row.gallery-grid-row .gallery-tile{
    height: 150px !important;
  }
}

/* ============ Monitores muy anchos (mas de 1920px) ============ */
/* el contenido se centra en un ancho comodo; los fondos siguen a todo el ancho */
@media (min-width: 1921px){
  html body .site-header{
    padding-left: calc((100vw - 1840px) / 2) !important;
    padding-right: calc((100vw - 1840px) / 2) !important;
  }
  html body .et_pb_section.cartelera-section{
    padding-left: calc((100vw - 1700px) / 2) !important;
    padding-right: calc((100vw - 1700px) / 2) !important;
  }
  html body .et-l--footer .aia-footer .footer-grid-row{
    padding-left: calc((100vw - 1800px) / 2) !important;
    padding-right: calc((100vw - 1800px) / 2) !important;
  }
}

/* ============ Ajustes finales (pedido del 21-10) ============ */
/* Inicio: la foto de vista previa de noticias depende del mouse; en tablet y celular no aporta */
@media (max-width: 980px){
  html body .news-preview-block{
    display: none !important;
  }
}
/* Detalle de noticia en celular: titular y texto mas contenidos */
@media (max-width: 600px){
  html body.single-post .et_pb_post_title h1.entry-title{
    font-size: clamp(24px, 7vw, 30px) !important;
    line-height: 1.05 !important;
    letter-spacing: -.5px !important;
  }
  html body.single-post #main-content .et_pb_text_inner p,
  html body.single-post #main-content .et_pb_text_inner li{
    font-size: 16px !important;
    line-height: 1.65 !important;
  }
}
/* Pie en tablet y celular: sin caja abajo; la linea entre Explorar y Contacto llega hasta el final */
@media (max-width: 980px){
  html body .et-l--footer .aia-footer .footer-grid-row > .footer-col:nth-child(2),
  html body .et-l--footer .aia-footer .footer-grid-row > .footer-col:nth-child(3){
    border-bottom: 0 !important;
    padding-bottom: 40px !important;
  }
  html body .et-l--footer .aia-footer,
  html body .et-l--footer .aia-footer .footer-grid-row{
    padding-bottom: 0 !important;
    margin-bottom: 0 !important;
  }
}
/* Detalle de noticia en tablet/celular: el cuerpo quedaba en una columna de ~226px por rellenos encadenados de Divi */
@media (max-width: 980px){
  html body.single-post .aia-news-detail .et_pb_post_content{
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  html body.single-post .et-l--post .et_pb_section{
    padding: 24px 0 !important;
  }
  html body.single-post .et-l--post .et_pb_row{
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
  }
}
@media (max-width: 600px){
  html body.single-post #main-content blockquote,
  html body.single-post #main-content blockquote p{
    font-size: 18px !important;
    line-height: 1.4 !important;
  }
}

/* ============ titulos que no cabian en celulares angostos (320-360px) ============ */
/* La palabra mas larga quedaba mas ancha que la columna y se partia */
@media (max-width: 480px){
  html body .cartelera-hero__title p{
    font-size: clamp(30px, 11vw, 44px) !important;
  }
  html body .aia-404__title h1{
    font-size: clamp(30px, 11vw, 38px) !important;
  }
}
@media (max-width: 400px){
  /* Nosotros: "ESPACIOS PARA CADA EXPERIENCIA", "UN ESPACIO. INFINITAS EXPERIENCIAS" */
  html body.page-id-83 .et_pb_text h2{
    font-size: clamp(28px, 10vw, 36px) !important;
  }
}
