/* =====================================================
   ETAPAS DEL PROCESO
===================================================== */

.etapas-contenido {
    width: 100%;
    min-width: 0;
}


/* =====================================================
   TIMELINE
===================================================== */

.etapas-timeline {
    position: relative;

    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));

    width: 100%;

    margin-top: 35px;

    padding: 0 5px;
}


/* LÍNEA */

.etapas-linea {
    position: absolute;

    top: 21px;

    left: 8.5%;
    right: 8.5%;

    height: 3px;

    background: #cbc6d0;

    z-index: 0;
}


/* =====================================================
   ETAPA
===================================================== */

.etapas-item {
    position: relative;

    z-index: 2;

    display: flex;
    flex-direction: column;
    align-items: center;

    min-width: 0;

    padding: 0 8px;

    border: 0;
    outline: none;

    background: transparent;

    font-family: inherit;
    text-align: center;

    cursor: pointer;
}


/* =====================================================
   NÚMERO
===================================================== */

.etapas-numero {
    display: flex;

    align-items: center;
    justify-content: center;

    width: 42px;
    height: 42px;

    margin-bottom: 20px;

    background: #aaa7b8;

    border: 4px solid #fff;

    color: #fff;

    border-radius: 50%;

    font-size: 14px;
    font-weight: 700;

    box-shadow:
        0 2px 8px rgba(67, 32, 82, .10);

    transition: all .3s ease;
}


/* =====================================================
   ICONO
===================================================== */

.etapas-icono {
    display: flex;

    align-items: center;
    justify-content: center;

    height: 60px;

    margin-bottom: 8px;

    color: #470a89;

    font-size: 40px;

    transition: all .3s ease;
}


/* =====================================================
   TÍTULO
===================================================== */

.etapas-item h4 {
    display: flex;

    align-items: flex-start;
    justify-content: center;

    min-height: 52px;

    margin: 0 0 12px;

    color: #352040;

    font-size: 14px;
    font-weight: 700;

    line-height: 1.3;
}


/* =====================================================
   BOTÓN
===================================================== */

.etapas-boton {
    display: flex;

    align-items: center;
    justify-content: center;

    width: 100%;
    max-width: 170px;

    min-height: 37px;

    margin-top: auto;

    padding: 8px 12px;

    background: #eeeeef;

    color: #77727b;

    border-radius: 8px;

    font-size: 12px;
    font-weight: 600;

    transition: all .25s ease;
}


/* =====================================================
   HOVER
===================================================== */

.etapas-item:hover .etapas-numero {
    background: #843a98;

    transform: scale(1.12);
}


.etapas-item:hover .etapas-icono {
    color: #843a98;

    transform: translateY(-3px);
}


.etapas-item:hover .etapas-boton {
    background: #eee3f2;

    color: #843a98;
}


/* =====================================================
   ETAPA ACTIVA
===================================================== */

.etapas-item.active .etapas-numero {
    background: #9b18a9;

    transform: scale(1.15);

    box-shadow:
        0 0 0 6px rgba(155, 24, 169, .12),
        0 4px 12px rgba(67, 32, 82, .15);
}


.etapas-item.active .etapas-icono {
    color: #9b18a9;

    transform: translateY(-3px);
}


.etapas-item.active h4 {
    color: #470a89;
}


.etapas-item.active .etapas-boton {
    background: #9b62aa;

    color: #fff;
}


/* =====================================================
   PANEL DESPLEGABLE
===================================================== */

.etapas-panel {
    position: relative;

    display: none;

    width: 100%;

    margin-top: 35px;

    padding: 32px;

    background:
        linear-gradient(
            135deg,
            #ffffff 0%,
            #fbf8fc 100%
        );

    border: 1px solid #eee4f1;

    border-radius: 18px;

    box-shadow:
        0 10px 30px rgba(67, 32, 82, .09);

    overflow: hidden;
}


/* Línea superior */

.etapas-panel::before {
    content: "";

    position: absolute;

    top: 0;
    left: 0;

    width: 100%;
    height: 4px;

    background:
        linear-gradient(
            90deg,
            #470a89,
            #9b18a9,
            #9b62aa
        );
}


/* MOSTRAR */

.etapas-panel.open {
    display: block;

    animation:
        etapasPanelEntrada
        .4s cubic-bezier(.22, 1, .36, 1);
}


@keyframes etapasPanelEntrada {

    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }

}


/* =====================================================
   ENCABEZADO PANEL
===================================================== */

.etapas-panel-encabezado {
    display: flex;

    align-items: center;

    gap: 16px;

    padding-right: 45px;

    margin-bottom: 28px;
}


.etapas-panel-numero {
    display: flex;

    align-items: center;
    justify-content: center;

    width: 55px;
    height: 55px;

    flex-shrink: 0;

    background: #9b18a9;

    color: #fff;

    border-radius: 50%;

    font-size: 19px;
    font-weight: 700;

    box-shadow:
        0 5px 15px rgba(155, 24, 169, .20);
}


.etapas-panel-etiqueta {
    display: block;

    margin-bottom: 4px;

    color: #9b18a9;

    font-size: 10px;
    font-weight: 800;

    letter-spacing: 1.5px;
}


.etapas-panel-encabezado h3 {
    margin: 0;

    color: #352040;

    font-size: 24px;
    font-weight: 700;
}


/* =====================================================
   BOTÓN CERRAR
===================================================== */

.etapas-panel-cerrar {
    position: absolute;

    top: 22px;
    right: 22px;

    display: flex;

    align-items: center;
    justify-content: center;

    width: 36px;
    height: 36px;

    padding: 0;

    border: 0;

    background: #eee3f2;

    color: #843a98;

    border-radius: 50%;

    font-size: 22px;

    cursor: pointer;

    transition: .25s ease;
}


.etapas-panel-cerrar:hover {
    background: #843a98;

    color: #fff;

    transform: rotate(90deg);
}


/* =====================================================
   CONTENIDO DEL PANEL
===================================================== */

.etapas-panel-grid {
    display: grid;

    grid-template-columns:
        minmax(0, 1.1fr)
        minmax(0, .9fr);

    gap: 40px;
}


/* INFORMACIÓN */

.etapas-panel-info h4 {
    margin: 0 0 10px;

    color: #470a89;

    font-size: 16px;
}


.etapas-panel-info p {
    margin: 0;

    color: #66616a;

    font-size: 14px;

    line-height: 1.7;
}


/* =====================================================
   FECHA
===================================================== */

.etapas-panel-fecha {
    display: flex;

    align-items: center;

    gap: 12px;

    margin-top: 20px;

    padding: 13px 16px;

    background: #f5eef8;

    border-radius: 10px;
}


.etapas-panel-fecha > i {
    color: #843a98;

    font-size: 21px;
}


.etapas-panel-fecha div {
    display: flex;

    flex-direction: column;

    gap: 2px;
}


.etapas-panel-fecha span {
    color: #9b62aa;

    font-size: 9px;
    font-weight: 800;

    letter-spacing: 1px;
}


.etapas-panel-fecha strong {
    color: #432052;

    font-size: 16px;
}


/* =====================================================
   DOCUMENTOS
===================================================== */

.etapas-documentos-titulo {
    display: flex;

    align-items: center;
    justify-content: space-between;

    gap: 10px;

    margin-bottom: 12px;
}


.etapas-documentos-titulo span {
    color: #843a98;
    font-size: 17px;
    font-weight: 800;

    letter-spacing: 1.5px;
}


.etapas-documentos-titulo small {
    color: #999;

    font-size: 10px;
}


/* DOCUMENTO */

.etapas-documento {
    display: flex;

    align-items: center;

    gap: 12px;

    width: 100%;

    margin-bottom: 9px;

    padding: 12px 14px;

    background: #f5eef8;

    border: 1px solid transparent;

    border-radius: 10px;

    color: inherit;

    text-decoration: none;

    transition: all .25s ease;
}


.etapas-documento:hover {
    background: #fff;

    border-color: #d6bddf;

    transform: translateX(4px);

    box-shadow:
        0 5px 15px rgba(67, 32, 82, .07);
}


/* PDF */

.etapas-documento-icono {
    display: flex;

    align-items: center;
    justify-content: center;

    width: 40px;
    height: 40px;

    flex-shrink: 0;

    background: #843a98;

    color: #fff;

    border-radius: 9px;

    font-size: 20px;
    font-weight: 800;
}


.etapas-documento-info {
    display: flex;

    flex: 1;

    flex-direction: column;

    gap: 2px;

    min-width: 0;
}


.etapas-documento-info strong {
    color: #432052;

    font-size: 15px;
}


.etapas-documento-info span {
    color: #888;

    font-size: 10px;
}


.etapas-documento-descarga {
color: #16011c;
font-size: 25px;
}


/* =====================================================
   TABLET
===================================================== */

@media (max-width: 950px) {

    .etapas-timeline {
        grid-template-columns: repeat(3, 1fr);

        row-gap: 40px;
    }


    /* Quitamos la línea horizontal porque ahora son 2 filas */

    .etapas-linea {
        display: none;
    }


    .etapas-panel-grid {
        grid-template-columns: 1fr;

        gap: 25px;
    }

}


/* =====================================================
   CELULAR
===================================================== */

@media (max-width: 600px) {

    .etapas-timeline {
        display: flex;

        flex-direction: column;

        gap: 10px;

        margin-top: 25px;
    }


    .etapas-item {
        display: grid;

        grid-template-columns:
            42px 48px 1fr auto;

        align-items: center;

        gap: 10px;

        width: 100%;

        padding: 12px;

        background: #faf7fb;

        border: 1px solid #eee3f2;

        border-radius: 12px;

        text-align: left;
    }


    .etapas-numero {
        width: 38px;
        height: 38px;

        margin: 0;

        border-width: 2px;
    }


    .etapas-icono {
        height: auto;

        margin: 0;

        font-size: 27px;
    }


    .etapas-item h4 {
        display: block;

        min-height: 0;

        margin: 0;

        font-size: 13px;

        text-align: left;
    }


    .etapas-item h4 br {
        display: none;
    }


    .etapas-boton {
        width: auto;

        min-height: 0;

        padding: 7px 9px;

        font-size: 0;

        border-radius: 50%;
    }


    /* Flecha en celular */

    .etapas-boton::after {
        content: "›";

        font-size: 20px;

        line-height: 1;
    }


    /* PANEL */

    .etapas-panel {
        margin-top: 18px;

        padding: 24px 18px;

        border-radius: 14px;
    }


    .etapas-panel-encabezado {
        gap: 12px;

        margin-bottom: 22px;
    }


    .etapas-panel-numero {
        width: 45px;
        height: 45px;

        font-size: 16px;
    }


    .etapas-panel-encabezado h3 {
        font-size: 19px;
    }


    .etapas-panel-cerrar {
        top: 15px;
        right: 15px;

        width: 31px;
        height: 31px;

        font-size: 19px;
    }


    .etapas-documentos-titulo {
        align-items: flex-start;

        flex-direction: column;

        gap: 3px;
    }

}


/* =====================================================
   CELULARES MUY PEQUEÑOS
===================================================== */

@media (max-width: 420px) {

    .etapas-item {
        grid-template-columns:
            34px 38px 1fr 30px;

        gap: 7px;

        padding: 10px;
    }


    .etapas-numero {
        width: 32px;
        height: 32px;

        font-size: 11px;
    }


    .etapas-icono {
        font-size: 23px;
    }


    .etapas-item h4 {
        font-size: 12px;
    }

}





/* TABLA DE LAS ETAPAS AAAA */


/* =====================================================
   CALENDARIO DEL PROCESO
===================================================== */

.calendario-proceso {
    width: 100%;
    padding: 30px 20px;
}

.calendario-contenedor {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}


/* TABLA */

.calendario-tabla {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    border: 2px solid #6d28b5;
    border-radius: 16px;
    overflow: hidden;
    font-family: Arial, Helvetica, sans-serif;
    color: rgb(63, 70, 68);
}


/* =====================================================
   ENCABEZADO
===================================================== */

.calendario-tabla thead {
    background: linear-gradient(
        135deg,
        #7135b5,
        #5c269c
    );

    color: #fff;
}

.calendario-tabla th {
    padding: 18px 25px;

    font-size: 25px;
    font-weight: 700;

    text-align: center;
}

.calendario-tabla th:first-child {
    width: 53%;
    border-right: 1px solid rgba(255,255,255,.5);
}

.calendario-tabla th:last-child {
    width: 47%;
}


/* =====================================================
   FILAS
===================================================== */

.calendario-tabla td {
    padding: 12px 30px;

    font-size: 18px;
    line-height: 1.35;

    vertical-align: middle;
}


/* Filas alternadas */

.calendario-tabla tbody tr:nth-child(odd) {
    background: #ffffff;
}

.calendario-tabla tbody tr:nth-child(even) {
    background: #f1ebf7;
}


/* =====================================================
   PRIMERA COLUMNA
===================================================== */

.calendario-tabla tbody td:first-child {
    position: relative;

    padding-left: 65px;

    border-right: 1px solid #8d52c4;
}


/* VIÑETA MORADA */

.calendario-tabla tbody td:first-child::before {
    content: "";

    position: absolute;

    left: 35px;
    top: 50%;

    width: 9px;
    height: 9px;

    background: #6d28b5;

    border-radius: 50%;

    transform: translateY(-50%);
}


/* =====================================================
   COLUMNA DE PERIODO
===================================================== */

.calendario-tabla tbody td:last-child {
    text-align: center;
}


/* =====================================================
   EFECTO HOVER
===================================================== */

.calendario-tabla tbody tr {
    transition:
        background .2s ease,
        transform .2s ease;
}

.calendario-tabla tbody tr:hover {
    background: #e8dcf2;
}


/* =====================================================
   TABLET
===================================================== */

@media (max-width: 900px) {

    .calendario-tabla th {
        font-size: 21px;
        padding: 16px;
    }

    .calendario-tabla td {
        font-size: 16px;
        padding: 12px 20px;
    }

    .calendario-tabla tbody td:first-child {
        padding-left: 45px;
    }

    .calendario-tabla tbody td:first-child::before {
        left: 20px;
    }

}


/* =====================================================
   MÓVIL
===================================================== */

@media (max-width: 650px) {

    .calendario-proceso {
        padding: 20px 12px;
    }

    /*
       En móvil eliminamos el formato tradicional
       de tabla y hacemos tarjetas.
    */

    .calendario-tabla,
    .calendario-tabla tbody,
    .calendario-tabla tr,
    .calendario-tabla td {
        display: block;
        width: 100%;
    }

    .calendario-tabla {
        border: none;
        border-radius: 0;
    }

    .calendario-tabla thead {
        display: none;
    }


    /* CADA FILA SE CONVIERTE EN TARJETA */

    .calendario-tabla tbody tr {
        margin-bottom: 15px;

        background: #fff !important;

        border: 1px solid #ded0eb;
        border-radius: 12px;

        overflow: hidden;

        box-shadow: 0 4px 14px rgba(74, 32, 105, .08);
    }


    /* ETAPA */

    .calendario-tabla tbody td:first-child {
        padding: 16px 16px 16px 45px;

        border-right: none;

        font-size: 15px;
        font-weight: 600;

        background: #f4eef8;
    }

    .calendario-tabla tbody td:first-child::before {
        left: 22px;

        width: 8px;
        height: 8px;
    }


    /* PERIODO */

    .calendario-tabla tbody td:last-child {
        padding: 13px 16px;

        font-size: 14px;

        text-align: left;

        color: #51247a;
    }


    /* ETIQUETA PERIODO */

    .calendario-tabla tbody td:last-child::before {
        content: "Periodo";

        display: block;

        margin-bottom: 4px;

        color: #6d28b5;

        font-size: 11px;
        font-weight: 700;

        text-transform: uppercase;

        letter-spacing: .8px;
    }

}













.calendario-link-etapa {
    appearance: none;
    border: 0;
    background: transparent;
    padding: 0;
    margin: 0;

    font: inherit;
    font-weight: 600;
    color: #5b259f;

    text-align: left;
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 4px;

    cursor: pointer;

    transition:
        color .2s ease,
        transform .2s ease,
        text-decoration-color .2s ease;
}

.calendario-link-etapa:hover {
    color: #8a2db3;
    text-decoration-thickness: 3px;
    transform: translateX(3px);
}

.calendario-link-etapa:focus-visible {
    outline: 2px solid #7226a5;
    outline-offset: 4px;
    border-radius: 3px;
}