/* ==========================
   PROCESS — CNA PREMIUM
========================== */

.process {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 8rem 0;

    background-image:
        linear-gradient(
            180deg,
            #050a1b 0%,
            rgba(5, 10, 27, .48) 18%,
            rgba(5, 10, 27, .20) 48%,
            rgba(5, 10, 27, .55) 82%,
            #050a1b 100%
        ),
        url("../../assets/images/process-bg.png");

    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    background-color: #050a1b;
}

.process > .container {
    position: relative;
    z-index: 2;
}

/* TÍTULO */

.process-highlight {
    color: #21baff;
    background: linear-gradient(90deg, #318cff, #18d7f9);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* TIMELINE */

.process-timeline {
    position: relative;
    margin-top: 4rem;
}

/* CINTA ONDULADA */

/* CINTA LUMINOSA — ALINEACIÓN */

.process-wave {
    position: absolute;

    top: -5px;
    left: 0;

    width: 100%;
    height: 100px;

    overflow: visible;
    pointer-events: none;
    z-index: 0;
}


/* ==========================================
   CNA — PROCESS ANIMATED WAVE
========================================== */

.process-wave path {
    fill: none;
    stroke: #16c9ff;
    stroke-width: 2.5;
    stroke-linecap: round;

    filter:
        drop-shadow(0 0 5px #00bfff)
        drop-shadow(0 0 12px rgba(0, 170, 255, .8));

    stroke-dasharray: 1400;
    stroke-dashoffset: 1400;
}

/* Dibujar la cinta cuando entra en pantalla */
.process-timeline.wave-visible .process-wave path {
    animation: processDraw 2.8s ease forwards;
}

@keyframes processDraw {
    to {
        stroke-dashoffset: 0;
    }
}


/* GRID */

.process-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 3.5rem;
}

/* CADA ETAPA */

.process-step {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 0;
}

/* ICONO SUPERIOR */

.process-icon {
    position: relative;
    z-index: 3;

    width: 78px;
    height: 78px;
    margin: 6px 0 36px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 2px solid #42d9ff;
    border-radius: 50%;

    background: rgba(2, 14, 39, .96);
    color: #9ceeff;

    box-shadow:
        0 0 12px rgba(0, 195, 255, .85),
        0 0 28px rgba(0, 125, 255, .35),
        inset 0 0 18px rgba(0, 150, 255, .18);

    transition: transform .35s ease, box-shadow .35s ease;
}

.process-icon svg {
    width: 35px;
    height: 35px;
    stroke-width: 1.8;
}

.process-step:hover .process-icon {
    transform: translateY(-5px) scale(1.08);
    box-shadow:
        0 0 20px rgba(0, 210, 255, 1),
        0 0 45px rgba(0, 140, 255, .55);
}

/* CONEXIÓN PUNTEADA */

.process-icon::after {
    content: "";
    position: absolute;

    top: 100%;
    left: 50%;

    height: 37px;
    border-left: 3px dotted #7cecff;

    transform: translateX(-50%);
    filter: drop-shadow(0 0 5px #00c8ff);
}

/* TARJETAS */

.process-card {
    position: relative;
    width: 100%;
    flex: 1;
    overflow: hidden;

    border: 1px solid rgba(39, 180, 255, .72);
    border-radius: 22px;

    background: rgba(2, 9, 27, .90);

    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);

    box-shadow:
        0 14px 38px rgba(0, 0, 0, .3),
        inset 0 0 20px rgba(0, 80, 170, .08);

    transition:
        transform .35s ease,
        border-color .35s ease,
        box-shadow .35s ease;
}

.process-card:hover {
    transform: translateY(-9px);
    border-color: #5de4ff;

    box-shadow:
        0 20px 50px rgba(0, 0, 0, .45),
        0 0 30px rgba(0, 170, 255, .28);
}

/* FOTOGRAFÍA SUPERIOR */

/* IMÁGENES DE LAS TARJETAS */

.process-card-image {
    position: relative;
    width: 100%;
    height: 155px;
    overflow: hidden;
    background: #03091b;
}

.process-card-image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.7s ease;
}

/* Degradado entre fotografía y contenido */

.process-card-image::after {
    content: "";
    position: absolute;
    inset: 0;

    background: linear-gradient(
    to bottom,
    transparent 55%,
    rgba(2, 9, 27, 0.15) 70%,
    rgba(2, 9, 27, 0.65) 90%,
    #02091b 100%
);

    pointer-events: none;
}

/* Zoom suave al pasar el cursor */

.process-card:hover .process-card-image img {
    transform: scale(1.07);
}

/* CONTENIDO */

.process-card-body {
    position: relative;
    padding: 0 1.5rem 2rem;
}


.process-number {
    position: relative;
    z-index: 2;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    width: 54px;
    height: 54px;
    margin-top: -28px;
    margin-bottom: 1.2rem;

    border-radius: 50%;
    background: linear-gradient(135deg, #247dff, #16d8f3);

    color: #fff;
    font-size: 1rem;
    font-weight: 700;

    box-shadow: 0 0 22px rgba(0, 145, 255, .3);
}

.process-card h3 {
    font-size: 1.35rem;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: #fff;
}

.process-card p {
    color: #c9d5e7;
    line-height: 1.75;
    font-size: .95rem;
}

/* FLECHAS ENTRE TARJETAS */

/* FLECHAS ENTRE ETAPAS */

.process-step:not(:last-child)::after {
    content: "➜";

    position: absolute;

    top: 60%;
    right: -45px;

    transform: translateY(-50%);

    z-index: 5;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 36px;
    height: 36px;

    border: 1px solid #1acbff;
    border-radius: 50%;

    background: #04132e;
    color: #8cecff;

    font-size: 21px;

    box-shadow:
        0 0 12px rgba(0, 190, 255, .45);
}

/* RESPONSIVE */

@media (max-width: 1200px) {

    .process-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        row-gap: 3rem;
    }

    .process-wave {
        display: none;
    }

    .process-step::after {
        display: none !important;
    }
}

@media (max-width: 768px) {

    .process {
        padding: 6rem 0;
        background-position: center;
    }

    .process-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .process-timeline {
        margin-top: 3rem;
    }

    .process-icon {
        width: 68px;
        height: 68px;
        margin-bottom: 30px;
    }

    .process-icon::after {
        height: 31px;
    }

    .process-card-image {
        height: 190px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .process-wave path {
        animation: none;
        stroke-dasharray: none;
        stroke-dashoffset: 0;
    }

    .process-icon,
    .process-card,
    .process-card-image img {
        transition: none;
    }
}

/* TÍTULO DE PROCESO */

.process-title {
    max-width: 850px;
    margin-left: auto;
    margin-right: auto;
    text-align: center;
}

.process-title .process-highlight {
    display: block;
    width: fit-content;
    max-width: 100%;
    margin: 0 auto;

    background: linear-gradient(
        90deg,
        #318cff,
        #18d7f9
    );

    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

@media (max-width: 480px) {
    .process-title .process-highlight {
        font-size: inherit;
    }
}