/* ============================================
   SLIDER MEJORADO PARA DESKTOP Y MÓVIL
   ============================================ */

/* CONTENEDOR PRINCIPAL DEL SLIDER */
.hero-slider {
    width: 100vw;
    max-width: 100%;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
    background: #000; /* Fondo negro para bordes */
}

/* Ajustar para pantallas grandes */
.logo-aemps-container,
.logo-container {
    max-width: 360px;
    min-width: 240px;
}
@media (min-width: 1200px) {
    .hero-slider {
        height: 700px;
    }
}

/* WRAPPER DEL SLIDER */
.hero-slider .swiper-wrapper {
    height: 100%;
.main-nav {
    flex: 1;
    display: flex;
    justify-content: center;
}
    display: flex;
.main-nav .main-menu {
    justify-content: center;
    gap: 20px;
}
}

/* SLIDES INDIVIDUALES */
.hero-slider .swiper-slide {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

/* CONTENEDOR DE IMAGEN */
.slide-image-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* IMAGEN DEL SLIDE - AJUSTE PARA DESKTOP */
.slide-image {
    width: 100%;
    height: 100%;
    object-fit: contain; /* Cambiado de 'cover' a 'contain' para ver imagen completa */
    object-position: center;
}

/* Overlay solo si es necesario */
.image-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        rgba(0, 0, 0, 0.6) 0%, 
        rgba(0, 0, 0, 0.4) 30%, 
        rgba(0, 0, 0, 0.2) 70%, 
        rgba(0, 0, 0, 0.1) 100%);
    z-index: 2;
}

/* CONTENIDO DEL SLIDER */
.swiper-content {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 3;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
}

.swiper-texto {
    max-width: 550px;
    width: 90%;
    padding: 40px;
    background: rgba(0, 0, 0, 0.75);
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
    text-align: center;
}

/* Refuerzo de centrado en móvil */
@media (max-width: 991px) {
    .swiper-content {
        justify-content: center;
        text-align: center;
    }
    .swiper-texto {
        margin: 0 auto;
    }
}

/* TÍTULO DEL SLIDE */
.slide-title {
    font-size: 2.8rem;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 25px;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.7);
}

/* BOTÓN DEL SLIDER */
.swiper-button {
    display: inline-block;
    padding: 16px 40px;
    background: linear-gradient(135deg, #0073aa, #005a87);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    border: none;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 8px 20px rgba(0, 115, 170, 0.3);
}

.swiper-button:hover {
    background: linear-gradient(135deg, #005a87, #004a70);
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(0, 115, 170, 0.4);
}

/* NAVEGACIÓN DEL SLIDER */
.hero-slider .swiper-button-next,
.hero-slider .swiper-button-prev {
    color: white;
    background: rgba(0, 0, 0, 0.6);
    width: 60px;
    height: 60px;
    border-radius: 50%;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.hero-slider .swiper-button-next:hover,
.hero-slider .swiper-button-prev:hover {
    background: rgba(0, 115, 170, 0.9);
    transform: scale(1.1);
    border-color: rgba(255, 255, 255, 0.5);
}

.hero-slider .swiper-button-next:after,
.hero-slider .swiper-button-prev:after {
    font-size: 24px;
    font-weight: bold;
}

/* PAGINACIÓN */
.swiper-pagination {
    bottom: 30px !important;
}

.swiper-pagination-bullet {
    width: 14px;
    height: 14px;
    background: rgba(255, 255, 255, 0.6);
    opacity: 1;
    transition: all 0.3s ease;
}

.swiper-pagination-bullet-active {
    background: #0073aa;
    transform: scale(1.3);
    box-shadow: 0 0 10px rgba(0, 115, 170, 0.8);
}

/* ============================================
   MEDIA QUERIES ESPECÍFICAS PARA SLIDER
   ============================================ */

/* DESKTOP GRANDE (más de 1600px) */
@media (min-width: 1600px) {
    .hero-slider {
        height: 800px;
    }
    
    .swiper-content {
        max-width: 1600px;
    }
    
    .slide-title {
        font-size: 3.2rem;
    }
    
    .swiper-texto {
        max-width: 750px;
        padding: 50px;
    }
}

/* DESKTOP ESTÁNDAR (1200px - 1599px) */
@media (min-width: 1200px) and (max-width: 1599px) {
    .hero-slider {
        height: 650px;
    }
    
    .slide-title {
        font-size: 2.5rem;
    }
    
    .swiper-texto {
        max-width: 600px;
        padding: 35px;
    }
}

/* TABLET HORIZONTAL (992px - 1199px) */
@media (min-width: 992px) and (max-width: 1199px) {
    .hero-slider {
        height: 550px;
    }
    
    .slide-title {
        font-size: 2.2rem;
    }
    
    .swiper-texto {
        max-width: 500px;
        padding: 30px;
    }
    
    .swiper-button {
        padding: 14px 35px;
    }
}

/* TABLET VERTICAL (768px - 991px) */
@media (min-width: 768px) and (max-width: 991px) {
    .hero-slider {
        height: 500px;
    }
    
    .slide-image {
        object-fit: cover; /* En tablet, volvemos a cover para mejor visualización */
    }
    
    .swiper-content {
        padding: 0 30px;
    }
    
    .swiper-texto {
        max-width: 450px;
        padding: 25px;
        backdrop-filter: blur(5px);
    }
    
    .slide-title {
        font-size: 1.9rem;
    }
    
    .swiper-button {
        padding: 12px 30px;
        font-size: 1rem;
    }
}

/* MÓVIL GRANDE (576px - 767px) */
@media (max-width: 767px) {
    .hero-slider {
        height: 450px;
        max-width: 100vw;
        width: 100vw;
        margin-left: 0;
        margin-right: 0;
    }
    
    .slide-image {
        object-fit: cover;
        width: 100%;
        height: 100%;
    }
    
    .image-overlay {
        background: linear-gradient(180deg, 
            rgba(0, 0, 0, 0.7) 0%, 
            rgba(0, 0, 0, 0.4) 60%, 
            rgba(0, 0, 0, 0.1) 100%);
    }
    
    .swiper-content {
        padding: 0 20px;
        display: flex;
        align-items: flex-end;
        justify-content: center;
        height: 100%;
        padding-bottom: 80px;
    }
    
    .swiper-texto {
        max-width: 100%;
        padding: 20px;
        margin: 0;
        background: rgba(0, 0, 0, 0.8);
        border-radius: 10px;
    }
    
    .slide-title {
        font-size: 1.5rem;
        margin-bottom: 15px;
    }
    
    .swiper-button {
        padding: 12px 25px;
        font-size: 0.95rem;
        width: 100%;
        text-align: center;
    }
    
    .hero-slider .swiper-button-next,
    .hero-slider .swiper-button-prev {
        width: 45px;
        height: 45px;
        display: none; /* Ocultar flechas en móvil si ocupan mucho espacio */
    }
    
    .swiper-pagination {
        bottom: 15px !important;
    }
}

/* MÓVIL PEQUEÑO (menos de 576px) */
@media (max-width: 575px) {
    .hero-slider {
        height: 400px;
    }
    
    .swiper-content {
        padding: 0 15px;
        padding-bottom: 60px;
    }
    
    .swiper-texto {
        padding: 15px;
    }
    
    .slide-title {
        font-size: 1.3rem;
        margin-bottom: 12px;
    }
    
    .swiper-button {
        padding: 10px 20px;
        font-size: 0.9rem;
    }
}

/* AJUSTES ESPECIALES PARA IMÁGENES VERTICALES */
/* Si las imágenes son verticales, mejor usar object-fit: contain */
@media (min-width: 1200px) {
    .hero-slider.vertical-images .slide-image {
        object-fit: contain;
        max-height: 90%;
        max-width: 90%;
    }
    
    .hero-slider.vertical-images .slide-image-container {
        background: #000;
    }
}

/* ANIMACIÓN DE ENTRADA PARA SLIDES */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: scale(1.05);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.hero-slider .swiper-slide-active {
    animation: slideIn 0.8s ease-out;
}

/* EFECTO PARALLAX (opcional) */
.parallax-bg {
    position: absolute;
    left: 0;
    top: 0;
    width: 130%;
    height: 130%;
    -webkit-background-size: cover;
    background-size: cover;
    background-position: center;
}

/* =============================================
   ESTILOS MODERNOS PARA EL FOOTER
   ============================================= */

/* Estructura principal del footer */
.aemps-footer {
    background: linear-gradient(135deg, #1a3a5f 0%, #2c5282 100%);
    color: #ffffff;
    padding: 35px 0 20px;
    position: relative;
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
}

.container-footer {
    position: relative;
    z-index: 2;
}

/* Logo y branding */
.footer-brand .footer-logo-link {
    text-decoration: none;
    color: inherit;
}

.logo-wrapper {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-emblem {
    height: 55px;
    width: auto;
    filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.agency-name {
    font-size: 1.6rem;
    font-weight: 800;
    background: linear-gradient(90deg, #ffffff, #a3bffa);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    line-height: 1;
    margin-bottom: 3px;
}

.agency-fullname {
    font-size: 0.75rem;
    color: #cbd5e0;
    line-height: 1.3;
    max-width: 300px;
}

/* Sección de redes sociales */
.footer-social-section {
    text-align: center;
}

.social-title {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 20px;
    color: #e2e8f0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.social-icons-container {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.social-icon-link {
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-block;
}

.social-icon-wrapper {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.social-icon-wrapper i {
    font-size: 1.4rem;
    color: var(--icon-color, #ffffff);
    transition: all 0.3s ease;
}

/* Efectos hover para iconos sociales */
.social-icon-link:hover .social-icon-wrapper {
    transform: translateY(-5px) scale(1.1);
    background: rgba(255, 255, 255, 0.2);
    border-color: var(--icon-color, #ffffff);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.social-icon-link:hover i {
    transform: scale(1.1);
    filter: brightness(1.2);
}

/* Separadores */
.footer-divider {
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.3) 50%, 
        transparent 100%);
    margin: 15px 0;
}

/* Navegación del footer */
.footer-menu-list {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 25px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-menu-list li {
    margin: 5px 0;
}

.footer-menu-list a {
    color: #cbd5e0;
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    padding: 8px 15px;
    border-radius: 6px;
    transition: all 0.3s ease;
    position: relative;
}

.footer-menu-list a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 15px;
    right: 15px;
    height: 2px;
    background: var(--icon-color, #4299e1);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.footer-menu-list a:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
}

.footer-menu-list a:hover::after {
    transform: scaleX(1);
}

/* Información de contacto */
.footer-info p {
    margin-bottom: 5px;
    color: #cbd5e0;
    display: flex;
    align-items: center;
    font-size: 0.85rem;
}

.footer-info i {
    color: #4299e1;
    width: 20px;
    text-align: center;
}

.footer-info a {
    color: #cbd5e0;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-info a:hover {
    color: #ffffff;
    text-decoration: underline;
}

/* Copyright */
.footer-copyright {
    text-align: right;
}

.copyright-text p {
    color: #a0aec0;
    font-size: 0.8rem;
    line-height: 1.3;
    margin-bottom: 8px;
}

.copyright-notice {
    font-size: 0.8rem;
    opacity: 0.8;
}

.partner-logo {
    max-width: 180px;
    height: auto;
    filter: brightness(0) invert(1);
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.partner-logo:hover {
    opacity: 1;
}

/* Botón "Volver arriba" */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4299e1, #3182ce);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(66, 153, 225, 0.3);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 20px rgba(66, 153, 225, 0.4);
}

.back-to-top i {
    font-size: 1.2rem;
    transition: transform 0.3s ease;
}

.back-to-top:hover i {
    transform: translateY(-2px);
}

/* Responsive Design */
@media (max-width: 991px) {
    .footer-top-section .row,
    .footer-bottom-section .row {
        text-align: center;
    }
    
    .logo-wrapper {
        justify-content: center;
        margin-bottom: 12px;
    }
    
    .footer-copyright {
        text-align: center;
        margin-top: 12px;
    }
    
    .footer-menu-list {
        gap: 10px;
        justify-content: center;
    }
    
    .footer-menu-list a {
        padding: 5px 10px;
        font-size: 0.85rem;
    }
}

@media (max-width: 767px) {
    .aemps-footer {
        padding: 25px 0 15px;
    }
    
    .agency-name {
        font-size: 1.4rem;
    }
    
    .agency-fullname {
        font-size: 0.7rem;
    }
    
    .social-icon-wrapper {
        width: 40px;
        height: 40px;
    }
    
    .social-icon-wrapper i {
        font-size: 1rem;
    }
    
    .footer-menu-list {
        flex-direction: column;
        gap: 8px;
    }
    
    .footer-divider {
        margin: 12px 0;
    }
    
    .back-to-top {
        bottom: 15px;
        right: 15px;
        width: 40px;
        height: 40px;
    }
}

@media (max-width: 575px) {
    .social-icons-container {
        gap: 10px;
    }
    
    .social-icon-wrapper {
        width: 40px;
        height: 40px;
    }
    
    .partner-logo {
        max-width: 200px;
    }
}

/* Animaciones suaves */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.footer-top-section,
.footer-middle-section,
.footer-bottom-section {
    animation: fadeInUp 0.6s ease forwards;
}

.footer-middle-section {
    animation-delay: 0.2s;
    opacity: 0;
}

.footer-bottom-section {
    animation-delay: 0.4s;
    opacity: 0;
}

/* Mejoras de accesibilidad */
.social-icon-link:focus,
.footer-menu-list a:focus,
.back-to-top:focus {
    outline: 2px solid #4299e1;
    outline-offset: 2px;
}

/* Estados activos */
.social-icon-wrapper:active {
    transform: scale(0.95);
}

/* =============================================
   BOTONES HEADER PROFESIONALES Y MODERNOS
   ============================================= */

.btn-header-primary {
    background: linear-gradient(135deg, #0056b3, #003d7a);
    border: none;
    color: #ffffff;
    font-weight: 600;
    padding: 12px 16px;
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(0, 86, 179, 0.3);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
}

.btn-header-primary:hover {
    background: linear-gradient(135deg, #003d7a, #002855);
    box-shadow: 0 8px 25px rgba(0, 86, 179, 0.5);
    transform: translateY(-2px);
    color: #ffffff;
    text-decoration: none;
}

.btn-header-primary:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(0, 86, 179, 0.3);
}

.btn-header-secondary {
    background: linear-gradient(135deg, #e0e7ff, #f0f4ff);
    border: 2px solid #0056b3;
    color: #0056b3;
    font-weight: 600;
    padding: 10px 16px;
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(0, 86, 179, 0.15);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
}

.btn-header-secondary:hover {
    background: #0056b3;
    color: #ffffff;
    box-shadow: 0 8px 25px rgba(0, 86, 179, 0.4);
    transform: translateY(-2px);
    text-decoration: none;
}

.btn-header-secondary:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(0, 86, 179, 0.3);
}

.btn-header-success {
    background: linear-gradient(135deg, #28a745, #1e7e34);
    border: none;
    color: #ffffff;
    font-weight: 600;
    padding: 12px 16px;
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
}

.btn-header-success:hover {
    background: linear-gradient(135deg, #1e7e34, #155724);
    box-shadow: 0 8px 25px rgba(40, 167, 69, 0.5);
    transform: translateY(-2px);
    color: #ffffff;
    text-decoration: none;
}

.btn-header-success:active {
    transform: translateY(0);
    box-shadow: 0 2px 10px rgba(40, 167, 69, 0.3);
}

/* =============================================
   AJUSTES COMPACTOS HEADER/FOOTER
   ============================================= */

/* Header más compacto */
.header-top-bar {
    padding: 4px 0;
    font-size: 0.85rem;
}

.main-header {
    padding: 6px 0;
}

.header-inner {
    padding: 6px 0;
    gap: 12px;
}

.header-actions .btn {
    padding: 6px 12px;
    font-size: 0.9rem;
}

.btn-search {
    padding: 6px 10px;
}

.language-selector,
.language-selector-mobile {
    margin-bottom: 0;
}

/* Footer más compacto */
.aemps-footer {
    padding: 40px 0 20px;
}

.footer-divider {
    margin: 20px 0;
}

.logo-wrapper {
    gap: 12px;
}

.footer-emblem {
    height: 60px;
}

.agency-name {
    font-size: 1.8rem;
}

.agency-fullname {
    font-size: 0.8rem;
}

.social-icon-wrapper {
    width: 42px;
    height: 42px;
    border-radius: 10px;
}

.social-icon-wrapper i {
    font-size: 1.2rem;
}

.footer-menu-list {
    gap: 15px;
}

.footer-menu-list a {
    padding: 6px 10px;
    font-size: 0.9rem;
}

.back-to-top {
    width: 44px;
    height: 44px;
}