/* ============================================
   HERO
   ============================================ */

.hero {
    position: relative;
    overflow: hidden;
    min-height: 100vh;
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding-top: 0 !important;
    padding-bottom: 0 !important;

    /* Fondo estático: se ve cuando el video está oculto (reduced-motion)
       o mientras el video carga */
    background-image: url("/site/media/hero-poster.webp");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero .hero-video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translate(-50%, -50%);
    object-fit: cover;
    z-index: 0;
    pointer-events: none;
}

.overlay {
    position: absolute;
    inset: 0;
    background-color: #000;
    opacity: 0.6;
    z-index: 1;
    pointer-events: none;
}

.hero > .container-fluid {
    position: relative;
    z-index: 2;
    width: 100%;
    flex: 0 0 auto;
}

.hero .row {
    justify-content: center;
    margin: 0;
}

.hero .content-bloc {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero .content-bloc p {
    text-align: center !important;
}

.hero .mb-4 {
    margin-bottom: 0.3rem !important;
}

.hero .content-bloc .display-1 {
    color: #fff !important;
    letter-spacing: 0.3em;
    margin-right: -0.3em;
}

.hero p {
    color: #fff;
}

.hero img {
    max-width: 30%;
    margin-bottom: 1rem;
    opacity: 0.75;
    filter: grayscale(100%);
}


/* Accesibilidad: si el usuario prefiere menos movimiento,
   ocultamos el video y queda el fondo estático del .hero */
@media (prefers-reduced-motion: reduce) {
    .hero .hero-video {
        display: none;
    }
}

/* ============================================
   PRESENTACIÓN
   ============================================ */

.presentacion {
    /* margin: 1rem 0; */
    padding: 6rem 0;
}

.presentacion .mb-4 {
    margin-bottom: 0.3rem !important;
}

.presentacion h1 {
    text-align: center;
}

.presentacion p {
    text-align: left !important;
}

.presentacion img {
    /* width: 100%; */
    height: auto;
}

@media (min-width: 992px) {
    .presentacion .text-bloc {
        padding: 0 2rem;
    }
}
@media (max-width: 991px) {
    .presentacion .image-bloc {
        margin-bottom: 1rem;
    }
    .presentacion .text-bloc {
        margin-top: 3rem;
    }
}

/* ============================================
   SERVICIOS
   ============================================ */

.card-box img {
    width: 100%;
    height: auto;
}

#servicios .btn {
    padding: 1.25rem 2rem;
    border-radius: 4px;
    border-width: 2px;
}

#servicios .btn-black-outline,
#servicios .btn-black-outline:active {
    background-color: transparent !important;
    border-color: var(--grey);
    color: var(--grey);
    transition:
        background-color 0.2s ease,
        color 0.2s ease,
        border-color 0.2s ease;
}

#servicios .btn-black-outline:hover,
#servicios .btn-black-outline:focus,
#servicios .btn-black-outline:focus-visible {
    background-color: var(--grey) !important;
    color: #fff !important;
    border-color: var(--grey-dark) !important;
    box-shadow: none !important;
}

#servicios .btn-black-outline.disabled,
#servicios .btn-black-outline:disabled {
    color: #ffffff !important;
    background-color: #232323 !important;
    border-color: #232323 !important;
}

/* ============================================
   UBICACIÓN / DATOS DE CONTACTO
   ============================================ */

.ubi__icon {
    display: flex;
    align-items: center;
    padding: 1rem;
}

#ubi #mapa-migsa {
    aspect-ratio: 16 / 9;
    width: 100%;
}

@media (max-width: 767.98px) {
    #ubi #mapa-migsa {
        aspect-ratio: 4 / 3;
    }
}

.map-marker-migsa__pin {
    width: 44px;
    height: 44px;
    background: var(--blue-main);
    border: 3px solid #fff;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
}

.map-marker-migsa__pin img {
    width: 24px;
    height: 24px;
    transform: rotate(45deg); /* contrarresta la rotación del pin */
}

/* Subrayado animado para los enlaces de contacto */
#ubi .text-primary {
    position: relative;
    text-decoration: none;
    background-image: none;
}

#ubi .text-primary::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -2px;
    height: 1px;
    background-color: currentColor;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

#ubi .text-primary:hover::after,
#ubi .text-primary:focus-visible::after {
    transform: scaleX(1);
}
