/**
 * CSS Específico para Páginas de Autenticação
 * Design Premium - Corporate Blue Elegance
 */

/* ============================================
   CONTAINER DE AUTENTICAÇÃO
   ============================================ */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-body);
    position: relative;
    overflow: hidden;
    padding: var(--spacing-xl) var(--spacing-md);
}

/* Detalhe de fundo sutil - Círculo radial azul */
.auth-container::before {
    content: '';
    position: absolute;
    top: -15%;
    right: -10%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.08) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    animation: pulse 8s ease-in-out infinite;
}

/* Textura geométrica SVG quase invisível */
.auth-container::after {
    content: '';
    position: absolute;
    bottom: -10%;
    left: -5%;
    width: 500px;
    height: 500px;
    background-image: 
        radial-gradient(circle at 25% 25%, rgba(37, 99, 235, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(37, 99, 235, 0.03) 0%, transparent 50%);
    pointer-events: none;
}

@keyframes pulse {
    0%, 100% { 
        transform: scale(1); 
        opacity: 0.6; 
    }
    50% { 
        transform: scale(1.1); 
        opacity: 0.8; 
    }
}

/* ============================================
   CARD DE AUTENTICAÇÃO
   ============================================ */
.auth-card {
    background: var(--bg-surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border-subtle);
    max-width: 450px;
    width: 100%;
    padding: 3rem;
    position: relative;
    z-index: 1;
    animation: fadeInUp 0.6s ease-out;
    margin: var(--spacing-md);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============================================
   CABEÇALHO DO CARD
   ============================================ */
.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-logo {
    width: 64px;
    height: 64px;
    margin: 0 auto 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary-light);
    border-radius: var(--radius-md);
    color: var(--primary);
}

.auth-logo svg {
    width: 36px;
    height: 36px;
}

.auth-title {
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    font-size: 1.875rem;
    color: var(--text-main);
    margin-bottom: 0.5rem;
    letter-spacing: -0.5px;
}

.auth-subtitle {
    font-family: 'Poppins', sans-serif;
    font-weight: 300;
    font-size: 0.9375rem;
    color: var(--text-secondary);
    margin: 0;
}

/* ============================================
   INPUTS COM ÍCONES
   ============================================ */
.auth-input-group {
    position: relative;
    margin-bottom: 1.25rem;
}

.auth-input-label {
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    font-size: 0.875rem;
    color: var(--text-main);
    margin-bottom: 0.5rem;
    display: block;
}

.auth-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
}

.auth-input-icon {
    position: absolute;
    left: 1rem;
    width: 20px;
    height: 20px;
    color: var(--text-secondary);
    z-index: 2;
    pointer-events: none;
    transition: color var(--transition-fast);
}

.auth-input {
    font-family: 'Poppins', sans-serif;
    font-weight: 300;
    width: 100%;
    padding: 0.875rem 1rem 0.875rem 3rem;
    background: var(--bg-body);
    border: 1px solid transparent;
    border-radius: var(--radius-sm);
    color: var(--text-main);
    font-size: 0.9375rem;
    transition: all var(--transition-base);
    box-sizing: border-box;
}

/* Input com botão de senha precisa de padding extra à direita */
.auth-input-wrapper:has(.auth-input-password-toggle) .auth-input {
    padding-right: 3.5rem;
}

.auth-input::placeholder {
    color: var(--text-secondary);
    opacity: 0.6;
}

.auth-input:focus {
    outline: none;
    background: var(--bg-surface);
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-light);
}

.auth-input:focus ~ .auth-input-icon,
.auth-input:focus + .auth-input-icon {
    color: var(--primary);
}

/* Garantir que o ícone mude de cor no focus mesmo com o botão de senha */
.auth-input-wrapper:focus-within .auth-input-icon {
    color: var(--primary);
}

/* Input de senha com botão de mostrar/ocultar */
.auth-input-password-toggle {
    position: absolute;
    right: 1rem;
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color var(--transition-fast);
    z-index: 2;
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
}

.auth-input-password-toggle:hover {
    color: var(--primary);
    background: var(--primary-light);
}

.auth-input-password-toggle:active {
    transform: scale(0.95);
}

.auth-input-password-toggle svg {
    width: 18px;
    height: 18px;
    pointer-events: none;
}

/* ============================================
   BOTÕES
   ============================================ */
.auth-btn-primary {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    width: 100%;
    padding: 0.875rem 1.5rem;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    cursor: pointer;
    transition: all var(--transition-base);
    box-shadow: var(--shadow-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.auth-btn-primary:hover {
    background: var(--primary-dark);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
    color: white;
}

.auth-btn-primary:active {
    transform: translateY(0);
}

.auth-btn-primary svg {
    width: 20px;
    height: 20px;
}

/* Botão Discord */
.auth-btn-discord {
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    width: 100%;
    padding: 0.875rem 1.5rem;
    background: transparent;
    color: #5865F2;
    border: 2px solid #5865F2;
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    cursor: pointer;
    transition: all var(--transition-base);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.auth-btn-discord:hover {
    background: #5865F2;
    color: white;
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.auth-btn-discord svg {
    width: 20px;
    height: 20px;
}

/* ============================================
   LINKS AUXILIARES
   ============================================ */
.auth-link {
    font-family: 'Poppins', sans-serif;
    font-weight: 400;
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: color var(--transition-fast);
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.auth-link:hover {
    color: var(--primary);
}

.auth-link-forgot {
    text-align: right;
    display: block;
    margin-top: 0.5rem;
    margin-bottom: 0;
    font-size: 0.8125rem;
}

.auth-divider {
    text-align: center;
    margin: 1.5rem 0;
    position: relative;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--border-subtle);
}

.auth-divider span {
    background: var(--bg-surface);
    padding: 0 1rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
    position: relative;
    z-index: 1;
}

.auth-footer {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-subtle);
}

.auth-footer-text {
    font-family: 'Poppins', sans-serif;
    font-weight: 300;
    font-size: 0.875rem;
    color: var(--text-secondary);
    margin: 0;
}

.auth-footer-link {
    font-weight: 500;
    color: var(--primary);
}

/* ============================================
   ALERTAS
   ============================================ */
.auth-alert {
    font-family: 'Poppins', sans-serif;
    padding: 1rem 1.25rem;
    border-radius: var(--radius-sm);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 0.875rem;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-alert-danger {
    background: var(--danger-light);
    color: var(--danger);
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.auth-alert-success {
    background: var(--success-light);
    color: var(--success);
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.auth-alert svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

/* ============================================
   RESPONSIVIDADE
   ============================================ */
@media (max-width: 576px) {
    .auth-card {
        padding: 2rem 1.5rem;
        margin: var(--spacing-md);
    }
    
    .auth-title {
        font-size: 1.5rem;
    }
    
    .auth-container::before,
    .auth-container::after {
        display: none;
    }
}

/* ============================================
   ANIMAÇÕES DE ENTRADA
   ============================================ */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Remover animação duplicada do .auth-card */
.auth-input-group {
    animation: fadeIn 0.4s ease-out;
    animation-fill-mode: both;
}

.auth-input-group:nth-of-type(1) { animation-delay: 0.1s; }
.auth-input-group:nth-of-type(2) { animation-delay: 0.2s; }
.auth-input-group:nth-of-type(3) { animation-delay: 0.3s; }
.auth-input-group:nth-of-type(4) { animation-delay: 0.4s; }
.auth-input-group:nth-of-type(5) { animation-delay: 0.5s; }

