
/* Estilo compacto y profesional para sección de inicio */
#index-inicio {
    background-color: #ffffff;
    padding: 30px 10%;
    color: #2d3748;
    position: relative;
}

#index-inicio::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, #f8f8f8, #ff0000, #f8f8f8);
}

#index-inicio .index-text-box {
    background: white;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.05);
    text-align: center;
    font-size: 1.1rem;
    line-height: 1.7;
    color: #2d3748;
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    font-weight: 400;
}

#index-inicio .index-text-box:before {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 2px;
    background: #ff0000;
}

/* Responsive */
@media (max-width: 768px) {
    #index-inicio {
        padding: 20px 5%;
    }
    
    #index-inicio .index-text-box {
        padding: 20px 15px;
        font-size: 1rem;
    }
}

/* Estilo para cuadros de texto */
.index-text-box {
    background: rgba(0, 0, 0, 0.05); /* Fondo gris claro */
    padding: 20px;
    border-radius: 10px; /* Bordes redondeados */
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2); /* Sombra ligera */
    text-align: justify;
    font-size: 1.1rem;
    line-height: 1.6;
    text-align: center;
}

/*...............................................................................................................................*/
/* Estilos base compartidos para todas las secciones */
.index-section-servicios {
    padding: 70px 10%;
    overflow: hidden;
}

.index-container-flex {
    display: flex;
    align-items: center;
    gap: 60px;
    max-width: 1400px;
    margin: 0 auto;
}

.index-content-box {
    flex: 1;
}

.index-content-box h2 {
    font-size: 2.2rem;
    margin-bottom: 25px;
    font-weight: 600;
    position: relative;
    padding-bottom: 15px;
}

/* LÃ­nea roja debajo de cada tÃ­tulo */
.index-content-box h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 80px;
    height: 3px;
    background-color: #ff0000;
}

.index-content-box p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 25px;
}

.index-image-box {
    flex: 1;
    text-align: center;
    position: relative;
}

.index-image-box img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.index-image-box img:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.25);
}

/* Borde rojo en una de las esquinas de la imagen */
.index-image-box::before {
    content: '';
    position: absolute;
    width: 80px;
    height: 80px;
    border-top: 3px solid #ff0000;
    border-left: 3px solid #ff0000;
    top: -15px;
    left: -3%;
    z-index: -1;
}

.index-image-box::after {
    content: '';
    position: absolute;
    width: 80px;
    height: 80px;
    border-bottom: 3px solid #ff0000;
    border-right: 3px solid #ff0000;
    bottom: -15px;
    right: -3%;
    z-index: -1;
}

/* Secciones con fondo oscuro */
.index-dark-section {
    background-color: #222;
    color: white;
}

.index-dark-section .index-content-box h2 {
    color: white;
}

.index-dark-section .index-content-box p {
    color: #e6e6e6;
}

/* Secciones con fondo claro */
.index-light-section {
    background-color: #f8f8f8;
}

.index-light-section .index-content-box h2 {
    color: #121212;
}

.index-light-section .index-content-box p {
    color: #333;
}

/* Animaciones */
.index-fade-in {
    opacity: 0;
    animation: indexFadeIn 1s forwards;
}

.index-slide-in-left {
    opacity: 0;
    transform: translateX(-50px);
    animation: indexSlideIn 1s forwards;
}

.index-slide-in-right {
    opacity: 0;
    transform: translateX(50px);
    animation: indexSlideIn 1s forwards;
}

@keyframes indexFadeIn {
    to {
        opacity: 1;
    }
}

@keyframes indexSlideIn {
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Media Queries para Responsividad */
@media (max-width: 992px) {
    .index-container-flex {
        gap: 40px;
    }
}

@media (max-width: 768px) {
    .index-container-flex {
        flex-direction: column;
        gap: 40px;
    }
    
    .index-section-servicios {
        padding: 50px 5%;
    }
    
    /* Ajuste para versiÃ³n mÃ³vil: la imagen siempre va primero */
    .index-dark-section .index-container-flex,
    .index-light-section .index-container-flex {
        flex-direction: column-reverse;
    }
    
    .index-content-box h2 {
        text-align: center;
        font-size: 1.8rem;
    }
    
    .index-content-box h2::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .index-content-box p {
        text-align: center;
    }
}
/*...............................................................................................................................*/
/* Estilos para la sección "Por qué elegirnos" (Fondo oscuro) */
#index-por-que-elegirnos {
    background-color: #222;
    padding: 60px 10%;
    text-align: center;
    color: white;
}

.index-por-que-elegirnos-container h2 {
    font-size: 2.5rem;
    margin-bottom: 40px;
    color: white;
}

.index-beneficios-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.index-beneficio {
    background-color: #333;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2);
    text-align: center;
    color: white;
}

.index-beneficio img {
    width: 200px;
    height: 200px;
    margin: 0 auto 25px;
    border: 2px solid #fff;
    border-radius: 50%;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.3);
    display: block;
    object-fit: cover;
}

.index-beneficio h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.index-beneficio p {
    font-size: 1rem;
    color: #f8f8f8;
    margin-bottom: 15px;
}
/*...............................................................................................................................*/
/* Estilos para la secciÃ³n "CTA intermedio" (Fondo blanco) */
#index-cta-intermedio {
    background-color: white; /* Fondo blanco */
    padding: 60px 10%;
    text-align: center;
    color: #222; /* Texto oscuro */
}

.index-cta-intermedio-container h2 {
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: #222; /* TÃ­tulo oscuro */
}

.index-cta-intermedio-container p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    color: #555; /* Texto gris */
}

.index-cta-button {
    display: inline-block;
    background-color: #ff0000;
    color: white;
    padding: 15px 15px;
    font-size: 1.1rem;
    border-radius: 5px;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    font-weight: 500;
    letter-spacing: 1px;
    z-index: 1;
    box-shadow: 0 5px 15px rgba(255, 0, 0, 0.3);
}

.index-cta-button:before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    z-index: -1;
}

.index-cta-button:hover {
    background-color: #d30000;
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(255, 0, 0, 0.4);
}

.index-cta-button:hover:before {
    left: 100%;
}

/*...............................................................................................................................*/

/* AnimaciÃ³n para aparecer desde la izquierda */
@keyframes indexSlideInLeft {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* AnimaciÃ³n para aparecer desde la derecha */
@keyframes indexSlideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Clases para aplicar las animaciones */
.index-slide-in-left {
    animation: indexSlideInLeft 1s ease-out forwards;
}

.index-slide-in-right {
    animation: indexSlideInRight 1s ease-out forwards;
}

/* Ocultar inicialmente los elementos que se animarÃ¡n */
.index-hidden {
    opacity: 0;
}

/* ================= RESPONSIVE MOBILE FIRST ================= */
@media (max-width: 768px) {
    .index-hero-content {
        padding: 0 20px; /* Solo padding lateral */
        text-align: center;
    }

    .index-hero-title {
        font-size: 2rem;
    }

    .index-hero-subtitle {
        font-size: 1.2rem;
    }
    
    /* Secciones de Servicios */
    .index-section-servicios {
        padding: 40px 5%;
    }
    
    .index-content-box h2 {
        font-size: 1.5rem;
    }
    
    .index-content-box p {
        font-size: 1rem;
    }
    
    .index-image-box::before,
    .index-image-box::after {
        display: none;
    }
    
    /* Por quÃ© Elegirnos */
    .index-beneficios-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .index-beneficio {
        padding: 20px;
    }
    
    .index-beneficio img {
        width: 80px;
        height: 80px;
    }
    
    /* CTA Intermedio */
    #index-cta-intermedio {
        padding: 40px 5%;
    }
    
    .index-cta-intermedio-container h2 {
        font-size: 1.8rem;
    }
    
    /* Texto General */
    .index-text-box {
        padding: 15px;
        font-size: 1rem;
        margin: 0 10px;
    }
    
    #index-inicio {
        padding: 20px 0;
    }
    
    /* Animaciones */
    .index-slide-in-left, 
    .index-slide-in-right {
        animation: none;
        opacity: 1;
        transform: none;
    }
    
    .index-fade-in {
        animation-duration: 0.5s;
    }
    
    /* ImÃ¡genes */
    .index-image-box img {
        max-width: 90%;
    }
}

@media (max-width: 480px) {
    /* Ajustes adicionales para pantallas muy pequeÃ±as */
    .index-hero-title {
        font-size: 1.8rem;
    }
    
    .index-hero-subtitle {
        font-size: 1rem;
    }
    
    .index-content-box h2 {
        font-size: 1.3rem;
    }
}