﻿/* Variables CSS */
:root {
    --primary-color: #f39;
    --primary-dark: #c30;
    --primary-light: #ff66cc;
    --secondary-color: #0ea3af;
    --light-color: #f8f9fa;
    --dark-color: #212529;
    --gradient-primary: linear-gradient(135deg, #f39 0%, #ff66cc 100%);
    --gradient-secondary: linear-gradient(135deg, #0ea3af 0%, #2ecad5 100%);
    --shadow: 0 20px 40px rgba(0, 0, 0, 0.15);
    --border-radius: 20px;
}

/* Estilos específicos para los cuadritos del token */
.token-input-container {
    margin: 2rem 0;
}

.token-input {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 1.5rem;
}

.token-digit {
    width: 60px;
    height: 70px;
    font-size: 2.2rem;
    font-weight: 700;
    text-align: center;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    background: white;
    color: var(--dark-color);
    transition: all 0.3s ease;
}

    .token-digit:focus {
        border-color: var(--primary-color);
        box-shadow: 0 0 0 3px rgba(243, 153, 255, 0.2);
        outline: none;
        transform: translateY(-2px);
    }

    .token-digit.filled {
        border-color: var(--secondary-color);
        background: rgba(14, 163, 175, 0.05);
    }

/* Estilos generales del card de verificación */
.verification-card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    animation: slideIn 0.5s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-30px) scale(0.95);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.card-header-primary {
    background: var(--gradient-primary);
    color: white;
    padding: 2.5rem 2rem;
    text-align: center;
    border-bottom: none;
    position: relative;
}

.header-icon {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    display: inline-block;
    background: rgba(255, 255, 255, 0.2);
    width: 80px;
    height: 80px;
    line-height: 80px;
    border-radius: 50%;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.05);
    }

    100% {
        transform: scale(1);
    }
}

.card-body {
    padding: 2.5rem;
}

/* Mensaje de información */
.info-message {
    background: rgba(14, 163, 175, 0.1);
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 2rem;
    border-left: 4px solid var(--secondary-color);
}

.phone-display {
    font-family: 'Courier New', monospace;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--dark-color);
    background: #f8f9fa;
    padding: 0.75rem 1.5rem;
    border-radius: 10px;
    display: inline-block;
    margin: 0.5rem 0;
}

/* Botones */
.btn-verify {
    background: var(--gradient-primary);
    border: none;
    color: white;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 12px;
    width: 100%;
    transition: all 0.3s ease;
    margin-bottom: 1rem;
}

    .btn-verify:hover {
        transform: translateY(-2px);
        box-shadow: 0 10px 20px rgba(243, 153, 255, 0.3);
    }

.btn-resend {
    background: transparent;
    border: 2px solid #e0e0e0;
    color: #666;
    padding: 0.9rem 2rem;
    font-size: 1rem;
    font-weight: 500;
    border-radius: 12px;
    width: 100%;
    transition: all 0.3s ease;
}

    .btn-resend:hover {
        border-color: var(--primary-color);
        color: var(--primary-color);
        background: rgba(243, 153, 255, 0.05);
    }

/* Contador */
.timer-container {
    text-align: center;
    margin-top: 2rem;
    padding: 1rem;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
}

.timer {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.1rem;
    font-weight: 600;
}

.timer-icon {
    color: var(--primary-color);
    font-size: 1.3rem;
}

.timer-expired {
    color: #dc3545;
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

/* Footer del popup */
.popup-footer {
    text-align: center;
    padding-top: 1.5rem;
    margin-top: 1.5rem;
    border-top: 1px solid #eee;
    color: #666;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 576px) {
    .verification-card {
        border-radius: 15px;
    }

    .card-header-primary {
        padding: 2rem 1.5rem;
    }

    .card-body {
        padding: 2rem 1.5rem;
    }

    .token-digit {
        width: 50px;
        height: 60px;
        font-size: 1.8rem;
    }

    .header-icon {
        width: 60px;
        height: 60px;
        line-height: 60px;
        font-size: 2.5rem;
    }

    .phone-display {
        font-size: 1.1rem;
        padding: 0.5rem 1rem;
    }
}

@media (max-width: 400px) {
    .token-digit {
        width: 45px;
        height: 55px;
        font-size: 1.6rem;
    }

    .btn-verify, .btn-resend {
        padding: 0.8rem 1.5rem;
    }
}

/* Efecto de shake para error */
.shake {
    animation: shake 0.5s ease-in-out;
}

@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }

    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-5px);
    }

    20%, 40%, 60%, 80% {
        transform: translateX(5px);
    }
}

/* Efecto de spin para loading */
.spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}
