/* Authentication Pages Styles */

.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 20px;
}

.auth-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    width: 100%;
    max-width: 420px;
    overflow: hidden;
}

.auth-header {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    color: white;
    padding: 30px;
    text-align: center;
}

.auth-header h1 {
    font-size: 1.5rem;
    margin: 0 0 8px 0;
    font-weight: 700;
}

.auth-header p {
    margin: 0;
    opacity: 0.8;
    font-size: 0.95rem;
}

.auth-form {
    padding: 30px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
    font-size: 0.9rem;
}

.form-group input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.2s;
    box-sizing: border-box;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-group input:invalid:not(:placeholder-shown) {
    border-color: #e74c3c;
}

.form-hint {
    display: block;
    font-size: 0.75rem;
    color: #888;
    margin-top: 6px;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    color: #555;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.forgot-link {
    color: #667eea;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
}

.forgot-link:hover {
    text-decoration: underline;
}

.auth-btn {
    width: 100%;
    padding: 14px 24px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    box-sizing: border-box;
}

.auth-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(102, 126, 234, 0.4);
}

.auth-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.auth-btn.secondary {
    background: #f0f0f0;
    color: #333;
}

.auth-btn.secondary:hover {
    background: #e0e0e0;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
}

.btn-loading {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.spinner {
    width: 20px;
    height: 20px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.auth-message {
    margin-top: 16px;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 0.9rem;
    text-align: center;
}

.auth-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.auth-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.auth-footer {
    text-align: center;
    padding: 20px 30px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

.auth-footer p {
    margin: 0;
    color: #666;
    font-size: 0.9rem;
}

.auth-footer a {
    color: #667eea;
    font-weight: 600;
    text-decoration: none;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Info Box */
.info-box {
    display: flex;
    gap: 12px;
    padding: 16px;
    background: #e8f4fd;
    border-radius: 8px;
    margin-bottom: 20px;
    align-items: flex-start;
}

.info-box svg {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
    color: #667eea;
}

.info-box p {
    margin: 0;
    font-size: 0.9rem;
    color: #333;
    line-height: 1.5;
}

/* Verification Result */
.verification-result {
    padding: 40px 30px;
    text-align: center;
}

.result-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.result-icon svg {
    width: 40px;
    height: 40px;
}

.result-icon.success {
    background: #d4edda;
    color: #28a745;
}

.result-icon.error {
    background: #f8d7da;
    color: #dc3545;
}

.verification-result h2 {
    margin: 0 0 10px 0;
    font-size: 1.5rem;
}

.verification-result p {
    color: #666;
    margin-bottom: 24px;
    line-height: 1.6;
}

/* User Menu in Header */
.user-menu {
    display: flex;
    align-items: center;
    gap: 12px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #555;
    font-size: 0.9rem;
}

.user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 0.9rem;
}

.logout-btn {
    padding: 8px 16px;
    background: #f0f0f0;
    color: #333;
    border: none;
    border-radius: 6px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
}

.logout-btn:hover {
    background: #e0e0e0;
}

/* Auth Links */
.auth-links {
    display: flex;
    gap: 12px;
}

.auth-link {
    padding: 8px 16px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s;
}

.auth-link.login {
    color: #667eea;
    background: transparent;
}

.auth-link.login:hover {
    background: rgba(102, 126, 234, 0.1);
}

.auth-link.register {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.auth-link.register:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(102, 126, 234, 0.3);
}

/* Responsive */
@media (max-width: 768px) {
    .auth-container {
        padding: 1rem;
        min-height: calc(100vh - 64px);
    }
    
    .auth-card {
        max-width: 100%;
        margin: 0;
    }
    
    .auth-header h1 {
        font-size: 1.3rem;
    }
    
    .auth-header p {
        font-size: 0.9rem;
    }
    
    .form-group input {
        font-size: 16px; /* Prevent iOS zoom */
    }
}

@media (max-width: 480px) {
    .auth-container {
        padding: 0.75rem;
    }
    
    .auth-card {
        margin: 0;
        border-radius: 12px;
    }
    
    .auth-header {
        padding: 20px 16px;
    }
    
    .auth-header h1 {
        font-size: 1.2rem;
    }
    
    .auth-form {
        padding: 20px 16px;
    }
    
    .form-group {
        margin-bottom: 16px;
    }
    
    .form-group input {
        padding: 10px 12px;
    }
    
    .form-options {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .auth-btn {
        padding: 12px 20px;
    }
    
    .auth-footer {
        padding: 16px;
    }
    
    .auth-footer p {
        font-size: 0.85rem;
    }
    
    .info-box {
        padding: 12px;
        font-size: 0.85rem;
    }
    
    .info-box svg {
        width: 20px;
        height: 20px;
    }
}
