/* ==========================================================================
   AEPsiUNCAus - Expo Carreras 2026
   Estilos del Test de Tarjetas Interactivas
   Inspirado en la paleta cromática multicolor del logo oficial de AEPsiUNCAus
   ========================================================================== */

/* Barra de Progreso y Navegación del Test */
.test-header {
    margin-bottom: 14px;
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.progress-counter {
    font-size: 0.86rem;
    font-weight: 800;
    color: var(--text-primary);
    font-family: 'Outfit', sans-serif;
}

.progress-counter span {
    background: var(--logo-gradient-text);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.progress-area-name {
    font-size: 0.76rem;
    font-weight: 700;
    color: var(--logo-cyan);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.progress-track {
    width: 100%;
    height: 7px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-full);
    overflow: hidden;
    position: relative;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}

.progress-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--logo-yellow), var(--logo-orange), var(--logo-magenta), var(--logo-purple), var(--logo-blue), var(--logo-cyan), var(--logo-emerald));
    border-radius: var(--radius-full);
    transition: width 0.35s var(--ease-smooth);
    box-shadow: 0 0 14px rgba(236, 72, 153, 0.6);
}

/* ==========================================================================
   Contenedor del Mazo de Tarjetas (Card Stack)
   ========================================================================== */
.card-stack-container {
    position: relative;
    width: 100%;
    perspective: 1000px;
    margin-bottom: 16px;
}

/* Tarjeta Individual: Flujo relativo para evitar solapamiento con header/botones */
.v-card {
    position: relative;
    width: 100%;
    background: linear-gradient(145deg, rgba(26, 35, 54, 0.95) 0%, rgba(13, 18, 30, 0.98) 100%);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: var(--radius-xl);
    padding: 22px 18px;
    box-shadow: var(--shadow-card);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    user-select: none;
    cursor: grab;
    touch-action: pan-y;
    transition: transform 0.3s var(--ease-smooth), opacity 0.3s var(--ease-smooth), box-shadow 0.3s ease;
    will-change: transform, opacity;
}

.v-card:active {
    cursor: grabbing;
}

/* Badge de Categoría / Área con acento colorido */
.card-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 14px;
    border-radius: var(--radius-full);
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    margin-bottom: 12px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
}

/* Gran Ícono Central */
.card-icon-wrapper {
    width: 66px;
    height: 66px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    border: 2px solid rgba(255, 255, 255, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.3rem;
    margin-bottom: 12px;
    box-shadow: 0 8px 22px rgba(0, 0, 0, 0.35);
    transition: transform 0.25s var(--ease-bounce);
}

.v-card:hover .card-icon-wrapper {
    transform: scale(1.08) rotate(4deg);
}

/* Título y Situación */
.card-title {
    font-size: 1.25rem;
    font-weight: 800;
    color: #ffffff;
    line-height: 1.3;
    margin-bottom: 8px;
    letter-spacing: -0.01em;
}

.card-situation {
    font-size: 0.92rem;
    line-height: 1.5;
    color: #cbd5e1;
    margin-bottom: 14px;
    font-weight: 400;
}

/* Chips / Tags de afinidad */
.card-chips {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px;
    margin-top: 4px;
}

.chip-tag {
    background: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #e2e8f0;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: var(--radius-full);
}

/* ==========================================================================
   Indicadores de Swipe Dinámicos sobre la Tarjeta (Stamps)
   ========================================================================== */
.swipe-stamp {
    position: absolute;
    top: 16px;
    padding: 5px 14px;
    border-radius: var(--radius-md);
    font-family: 'Outfit', sans-serif;
    font-size: 1rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.15s ease;
    z-index: 10;
}

.stamp-love {
    right: 24px;
    color: var(--logo-emerald);
    border: 3px solid var(--logo-emerald);
    background: rgba(16, 185, 129, 0.25);
    transform: rotate(12deg);
    box-shadow: 0 0 16px rgba(16, 185, 129, 0.4);
}

.stamp-pass {
    left: 24px;
    color: var(--logo-red);
    border: 3px solid var(--logo-red);
    background: rgba(239, 68, 68, 0.25);
    transform: rotate(-12deg);
    box-shadow: 0 0 16px rgba(239, 68, 68, 0.4);
}

.stamp-maybe {
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--logo-amber);
    border: 3px solid var(--logo-amber);
    background: rgba(245, 158, 11, 0.3);
    box-shadow: 0 0 16px rgba(245, 158, 11, 0.4);
}

/* Clases de animación al reaccionar */
.v-card.swiped-right {
    transform: translate(120%, 30px) rotate(25deg) !important;
    opacity: 0 !important;
}

.v-card.swiped-left {
    transform: translate(-120%, 30px) rotate(-25deg) !important;
    opacity: 0 !important;
}

.v-card.swiped-up {
    transform: translate(0, -120%) scale(0.9) !important;
    opacity: 0 !important;
}

/* ==========================================================================
   Botonera de Reacciones Vocacionales
   ========================================================================== */
.reaction-controls {
    display: grid;
    grid-template-columns: 1fr 1.15fr 1fr;
    gap: 10px;
    width: 100%;
}

.btn-react {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 12px 6px;
    border-radius: var(--radius-lg);
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.14);
    cursor: pointer;
    transition: transform 0.2s var(--ease-bounce), box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
    outline: none;
}

.btn-react .react-icon {
    font-size: 1.45rem;
    line-height: 1;
    transition: transform 0.2s var(--ease-bounce);
}

.btn-react .react-label {
    font-size: 0.74rem;
    font-weight: 800;
    font-family: 'Outfit', sans-serif;
    letter-spacing: 0.02em;
}

/* Botón: Paso (Rojo/Coral del logo) */
.btn-react.react-pass {
    border-color: rgba(239, 68, 68, 0.35);
    color: #f87171;
}

.btn-react.react-pass:hover,
.btn-react.react-pass:active {
    background: rgba(239, 68, 68, 0.16);
    border-color: var(--logo-red);
    box-shadow: 0 8px 20px rgba(239, 68, 68, 0.35);
    transform: translateY(-2px);
}

/* Botón: Indiferente / Puede ser (Ámbar del logo) */
.btn-react.react-maybe {
    border-color: rgba(245, 158, 11, 0.35);
    color: #fbbf24;
}

.btn-react.react-maybe:hover,
.btn-react.react-maybe:active {
    background: rgba(245, 158, 11, 0.16);
    border-color: var(--logo-yellow);
    box-shadow: 0 8px 20px rgba(245, 158, 11, 0.35);
    transform: translateY(-2px);
}

/* Botón: ¡Me copa! (Verde/Teal del logo) */
.btn-react.react-love {
    border-color: rgba(16, 185, 129, 0.45);
    background: rgba(16, 185, 129, 0.12);
    color: #34d399;
}

.btn-react.react-love:hover,
.btn-react.react-love:active {
    background: rgba(16, 185, 129, 0.25);
    border-color: var(--logo-emerald);
    box-shadow: 0 8px 24px rgba(16, 185, 129, 0.45);
    transform: translateY(-3px) scale(1.03);
}

/* Botón auxiliar para deshacer */
.undo-bar {
    display: flex;
    justify-content: center;
    margin-top: 10px;
}

.btn-undo {
    background: transparent;
    border: none;
    color: #94a3b8;
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 12px;
    border-radius: var(--radius-full);
    transition: color 0.2s ease, background 0.2s ease;
}

.btn-undo:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

/* ==========================================================================
   Ajustes Responsivos para Pantallas Pequeñas y Bajas (Mobile Compact)
   ========================================================================== */
@media (max-height: 660px), (max-width: 390px) {
    .test-header {
        margin-bottom: 8px;
    }

    .progress-info {
        margin-bottom: 4px;
    }

    .progress-counter {
        font-size: 0.8rem;
    }

    .progress-area-name {
        font-size: 0.7rem;
    }

    .progress-track {
        height: 6px;
    }

    .card-stack-container {
        margin-bottom: 10px;
    }

    .v-card {
        padding: 14px 12px;
        border-radius: var(--radius-lg);
    }

    .card-badge {
        padding: 3px 10px;
        font-size: 0.68rem;
        margin-bottom: 8px;
    }

    .card-icon-wrapper {
        width: 50px;
        height: 50px;
        font-size: 1.75rem;
        margin-bottom: 8px;
    }

    .card-title {
        font-size: 1.05rem;
        margin-bottom: 6px;
        line-height: 1.25;
    }

    .card-situation {
        font-size: 0.82rem;
        line-height: 1.4;
        margin-bottom: 8px;
    }

    .card-chips {
        gap: 4px;
        margin-top: 2px;
    }

    .chip-tag {
        font-size: 0.66rem;
        padding: 2px 8px;
    }

    .swipe-stamp {
        top: 10px;
        font-size: 0.85rem;
        padding: 3px 8px;
    }
    .stamp-love { right: 10px; }
    .stamp-pass { left: 10px; }

    .reaction-controls {
        gap: 6px;
    }

    .btn-react {
        padding: 8px 4px;
        border-radius: var(--radius-md);
    }

    .btn-react .react-icon {
        font-size: 1.2rem;
    }

    .btn-react .react-label {
        font-size: 0.68rem;
    }

    .undo-bar {
        margin-top: 6px;
    }

    .btn-undo {
        padding: 3px 10px;
        font-size: 0.7rem;
    }
}
