/* CONTENEDOR */
.section-fq {
    background-color: #fdfaf9;
}

/* TITULO */
.section-fq h2 {
    font-size: 30px;
    font-weight: 700;
    margin-bottom: 35px;
    color: #1e1e1e;
}

/* ========================= */
/* CATEGORIAS */
/* ========================= */

.faq-categorias {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

.faq-categoria {
    background-color: #ffffff;
    border: 1px solid #eee;
    border-radius: 14px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 8px;
}

.faq-categoria img {
    width: 45px;
    margin-bottom: 10px;
    display: block;
}

.faq-categoria h3 {
    font-size: 14px;
    font-weight: 600;
    color: #444;
}

/* HOVER */
.faq-categoria:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.06);
}

/* ACTIVA (IMPORTANTE PARA TU JS) */
.faq-categoria.active {
    background: linear-gradient(135deg, #6a5cff, #8b5cf6);
    color: #fff;
    border: none;
    box-shadow: 0 10px 25px rgba(106,92,255,0.3);
}

.faq-categoria.active h3 {
    color: #fff;
}

.faq-categoria.active img {
    filter: brightness(0) invert(1);
}

/* ========================= */
/* CONTENIDOS */
/* ========================= */

.faq-contenido {
    display: none;
    animation: fadeIn 0.3s ease;
}

.faq-contenido.active {
    display: block;
}

/* ========================= */
/* ITEMS */
/* ========================= */

.faq-item {
    background-color: #ffffff;
    border: 1px solid #eee;
    border-radius: 12px;
    margin-bottom: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
}

/* HOVER SUAVE */
.faq-item:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

/* PREGUNTA */
.faq-pregunta {
    padding: 18px 20px;
    font-size: 15px;
    font-weight: 600;
    color: #222;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* ICONO */
.faq-icono {
    font-size: 12px;
    transition: transform 0.3s ease;
}

/* RESPUESTA */
.faq-respuesta {
    max-height: 0;
    overflow: hidden;
    padding: 0 20px;
    font-size: 14px;
    color: #666;
    line-height: 1.6;
    transition: all 0.3s ease;
}

/* CUANDO ESTA ABIERTO (CLAVE PARA TU JS) */
.faq-item.open .faq-respuesta {
    max-height: 300px;
    padding: 15px 20px 20px 20px;
}

.faq-item.open .faq-icono {
    transform: rotate(180deg);
}

/* ========================= */
/* ANIMACION */
/* ========================= */

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ========================= */
/* RESPONSIVE */
/* ========================= */

@media (max-width: 1024px) {
    .faq-categorias {
        grid-template-columns: repeat(2, 1fr);
    }

    .section-fq {
        padding: 50px 30px;
    }
}
@media (max-width: 900px) {
    .section-fq h2 {
        font-size: 28px;
    }
}
@media (max-width: 600px) {
    .section-fq h2 {
        font-size: 26px;
    }
    .faq-categoria h3 {
        font-size: 13px;
    }
    .faq-pregunta {
        font-size: 14px;
    }
    .faq-categorias {
        grid-template-columns: 1fr;
    }

    .section-fq {
        padding: 40px 20px;
    }

    .faq-pregunta {
        font-size: 14px;
    }

    .faq-respuesta {
        font-size: 13px;
    }
}
@media (max-width: 400px) {
    .section-fq h2 {
        font-size: 24px;
    }
}