/* Modern Authentication Styles */
:root {
    --primary-color: #0ea5e9;
    --primary-dark: #0284c7;
    --secondary-color: #0f172a;
    --accent-color: #3b82f6;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --light-color: #f8fafc;
    --dark-color: #1e293b;
    --border-color: #e2e8f0;
    --text-light: #64748b;
    --gradient-bg: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --shadow: 0 10px 25px rgba(0,0,0,0.1);
    --shadow-hover: 0 20px 40px rgba(0,0,0,0.15);
}

.auth-bg {
    background: var(--gradient-bg);
    min-height: 100vh;
    position: relative;
}

.auth-bg::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(120, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 119, 198, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 80%, rgba(120, 199, 255, 0.3) 0%, transparent 50%);
    pointer-events: none;
}

.auth-card {
    background: rgba(255, 255, 255, 0.95);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: var(--shadow);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    position: relative;
    z-index: 1;
}

.auth-card:hover {
    box-shadow: var(--shadow-hover);
    transform: translateY(-5px);
}

.auth-logo {
    width: 80px;
    height: 80px;
    background: var(--gradient-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
    box-shadow: 0 8px 25px rgba(14, 165, 233, 0.3);
}

.auth-logo i {
    font-size: 2rem;
    color: white;
}

.auth-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

.auth-subtitle {
    color: var(--text-light);
    margin-bottom: 0;
    font-size: 1rem;
}

.auth-form {
    margin-top: 2rem;
}

.form-label {
    font-weight: 600;
    color: var(--dark-color);
    margin-bottom: 0.5rem;
}

.form-control {
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.8);
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(14, 165, 233, 0.1);
    background: white;
    transform: translateY(-1px);
}

.input-group-text {
    border: 2px solid var(--border-color);
    border-right: none;
    border-radius: 12px 0 0 12px;
    background: rgba(14, 165, 233, 0.1);
    color: var(--primary-color);
    font-weight: 600;
}

.input-group .form-control {
    border-left: none;
    border-radius: 0 12px 12px 0;
}

.input-group:focus-within .input-group-text {
    border-color: var(--primary-color);
    background: rgba(14, 165, 233, 0.15);
}

.password-toggle {
    border: 2px solid var(--border-color);
    border-left: none;
    border-radius: 0 12px 12px 0;
    background: transparent;
    color: var(--text-light);
    padding: 0.75rem 1rem;
    transition: all 0.3s ease;
}

.password-toggle:hover {
    color: var(--primary-color);
    background: rgba(14, 165, 233, 0.1);
}

.auth-btn {
    background: var(--gradient-bg);
    border: none;
    border-radius: 12px;
    padding: 0.875rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    box-shadow: 0 4px 15px rgba(14, 165, 233, 0.4);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.auth-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.auth-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(14, 165, 233, 0.5);
}

.auth-btn:hover::before {
    left: 100%;
}

.auth-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
}

.auth-link::before {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary-color);
    transition: width 0.3s ease;
}

.auth-link:hover {
    color: var(--primary-dark);
    transform: translateX(2px);
}

.auth-link:hover::before {
    width: 100%;
}

.form-check-input {
    border-radius: 6px;
    border: 2px solid var(--border-color);
}

.form-check-input:checked {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.alert {
    border: none;
    border-radius: 12px;
    padding: 1rem 1.5rem;
    margin-bottom: 1.5rem;
    font-weight: 500;
}

.alert-danger {
    background: rgba(239, 68, 68, 0.1);
    color: #dc2626;
    border-left: 4px solid #ef4444;
}

.alert-success {
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
    border-left: 4px solid #10b981;
}

.alert-warning {
    background: rgba(245, 158, 11, 0.1);
    color: #d97706;
    border-left: 4px solid #f59e0b;
}

.form-text {
    font-size: 0.875rem;
    margin-top: 0.25rem;
}

/* Responsive Design */
@media (max-width: 768px) {
    .auth-card {
        padding: 2rem 1.5rem;
        margin: 1rem;
        border-radius: 16px;
    }
    
    .auth-title {
        font-size: 1.5rem;
    }
    
    .auth-logo {
        width: 60px;
        height: 60px;
    }
    
    .auth-logo i {
        font-size: 1.5rem;
    }
}

@media (max-width: 576px) {
    .auth-card {
        padding: 1.5rem 1rem;
    }
    
    .auth-form .row [class*="col-"] {
        margin-bottom: 0.5rem;
    }
}

/* Loading Animation */
.auth-btn.loading {
    pointer-events: none;
    position: relative;
    color: transparent;
}

.auth-btn.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid transparent;
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Focus States for Accessibility */
.form-control:focus,
.btn:focus,
.form-check-input:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .auth-card {
        background: rgba(15, 23, 42, 0.95);
        color: white;
    }
    
    .auth-title {
        color: white;
    }
    
    .form-label {
        color: #e2e8f0;
    }
    
    .form-control {
        background: rgba(30, 41, 59, 0.8);
        border-color: #334155;
        color: white;
    }
    
    .form-control:focus {
        background: #1e293b;
    }
    
    .input-group-text {
        background: rgba(14, 165, 233, 0.2);
        border-color: #334155;
    }
}