/* Dark Modern Auth Design */
:root {
    --primary: #8b5cf6;
    --primary-dark: #7c3aed;
    --success: #10b981;
    --success-dark: #059669;
    --danger: #ef4444;
    --white: #FFFFFF;
    --black: #000000;
    --grey-50: #f9fafb;
    --grey-100: #f3f4f6;
    --grey-200: #e5e7eb;
    --grey-300: #d1d5db;
    --grey-400: #9ca3af;
    --grey-500: #6b7280;
    --grey-600: #4b5563;
    --grey-700: #374151;
    --grey-800: #1f2937;
    --grey-900: #111827;
    --dark-bg: #0a0a0a;
    --dark-card: #1a1a1a;
    --dark-card-hover: #242424;
}

body {
    background: var(--dark-bg);
    min-height: 100vh;
    font-family: 'Inter', 'Segoe UI', sans-serif;
    color: var(--grey-200);
}

.auth-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Card Containers */
.login-card, .welcome-card {
    border: none;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.login-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
}

/* Login Card Styling */
.login-card {
    background: var(--dark-card);
    border-top: 3px solid var(--primary);
}

.login-card .card-body {
    padding: 40px;
}

/* Title Styling */
.login-card .card-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 30px;
}

/* Form Labels */
.login-card .form-label {
    font-weight: 600;
    color: var(--grey-300);
    margin-bottom: 8px;
    font-size: 14px;
}

/* Form Controls */
.login-card .form-control {
    padding: 12px 16px;
    border: 1px solid var(--grey-700);
    border-radius: 8px;
    background-color: var(--grey-900);
    font-size: 15px;
    transition: all 0.3s ease;
}

.login-card .form-control:focus {
    border-color: var(--primary);
    background-color: var(--grey-900);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2);
    outline: none;
}

.login-card .form-control::placeholder {
    color: var(--grey-500);
}

/* CAPTCHA Container */
.login-card .captcha {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 20px 0;
}

.captcha-container {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: var(--grey-900);
    border-radius: 8px;
    border: 1px solid var(--grey-700);
}

.login-card .captcha img {
    border-radius: 6px;
    width: 140px;
    height: auto;
    border: 1px solid var(--grey-700);
}

.login-card .captcha input {
    flex: 1;
    max-width: 200px;
    border: 1px solid var(--grey-700) !important;
    background: var(--grey-900) !important;
    color: var(--white) !important;
}

.captcha-container .btn-secondary {
    background: var(--grey-700);
    border: none;
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.captcha-container .btn-secondary:hover {
    background: var(--grey-600);
    transform: rotate(180deg);
}

/* Alert Styling */
.login-card .alert-danger {
    background: var(--danger);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    border: none;
    margin: 20px 0;
    font-size: 14px;
}

.login-card .alert-success {
    background: var(--success);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    border: none;
    margin: 20px 0;
    font-size: 14px;
}

.login-card .alert-warning {
    background: #f59e0b;
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    border: none;
}

.login-card .alert-info {
    background: var(--primary);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    border: none;
}

/* Primary Button */
.login-card .btn-primary {
    padding: 14px;
    width: 100%;
    background: var(--primary);
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    color: white;
    text-transform: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(139, 92, 246, 0.4);
}

.login-card .btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(139, 92, 246, 0.5);
}

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

/* OR Divider */
.login-card .or-text {
    font-size: 14px;
    color: var(--grey-500);
    text-align: center;
    position: relative;
    margin: 25px 0;
    font-weight: 500;
}

.login-card .or-text::before,
.login-card .or-text::after {
    content: '';
    position: absolute;
    top: 50%;
    width: calc(50% - 40px);
    height: 1px;
    background: var(--grey-700);
}

.login-card .or-text::before {
    left: 0;
}

.login-card .or-text::after {
    right: 0;
}

/* Social Login Buttons */
.login-card .social-login {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.login-card .social-btn {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.login-card .social-btn.btn-outline-danger {
    background: var(--grey-900);
    color: #DB4437;
    border-color: var(--grey-700);
}

.login-card .social-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.login-card .social-btn.btn-outline-danger:hover {
    background: #DB4437;
    color: white;
    border-color: #DB4437;
}

/* Welcome Card */
.welcome-card {
    background: linear-gradient(135deg, var(--grey-900) 0%, var(--black) 100%);
    color: white;
    position: relative;
    overflow: hidden;
    border: 1px solid var(--grey-800);
}

.welcome-card .card-body {
    padding: 50px 40px;
    position: relative;
    z-index: 1;
}

.welcome-card .card-title {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 20px;
    color: var(--white);
}

.welcome-card .card-text {
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 30px;
    color: var(--grey-300);
}

.welcome-card .btn-outline-primary {
    padding: 14px 32px;
    background: var(--success);
    color: white;
    border: 2px solid var(--success);
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.welcome-card .btn-outline-primary:hover {
    background: var(--success-dark);
    border-color: var(--success-dark);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.4);
}

/* Resend Verification Card */
.resend-verification .card {
    background: var(--dark-card);
    border: 1px solid var(--grey-700);
    border-radius: 8px;
}

.resend-verification .card .card-body {
    color: var(--grey-200);
}

.resend-verification .form-label {
    color: var(--grey-300);
}

.resend-verification .form-control {
    background: var(--grey-900);
    border: 1px solid var(--grey-700);
    color: var(--white);
}

.resend-verification .form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2);
}

.resend-verification .btn-secondary {
    background: var(--grey-700);
    color: white;
    border: none;
}

.resend-verification .btn-secondary:hover {
    background: var(--grey-600);
}

/* Forgot Password Link */
.login-card a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.login-card a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Checkbox Styling */
.login-card input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--success);
    cursor: pointer;
}

.login-card label {
    cursor: pointer;
    user-select: none;
    color: var(--grey-300);
}

/* Username Availability Indicator */
#username-availability {
    font-size: 13px;
    font-weight: 500;
    padding: 5px 0;
}

/* Badge Styling */
.badge {
    font-weight: 600;
}

.badge.bg-primary {
    background-color: var(--primary) !important;
}

.badge.bg-success {
    background-color: var(--success) !important;
}

/* Small text */
.small, small {
    color: var(--grey-400);
}

.text-muted {
    color: var(--grey-500) !important;
}

.text-white {
    color: var(--white) !important;
}

/* List styling in welcome card */
.welcome-card ul {
    text-align: left;
    color: var(--grey-300);
}

.welcome-card ul li {
    margin-bottom: 8px;
}

/* Icon styling in welcome card */
.welcome-card i {
    opacity: 0.9;
}

/* Responsive Design */
@media (max-width: 768px) {
    .auth-container {
        padding: 10px;
    }

    .login-card .card-body,
    .welcome-card .card-body {
        padding: 30px 25px;
    }

    .login-card .card-title {
        font-size: 26px;
    }

    .welcome-card .card-title {
        font-size: 28px;
    }

    .welcome-card .card-text {
        font-size: 14px;
    }

    .login-card .form-control {
        font-size: 14px;
        padding: 12px 15px;
    }

    .captcha-container {
        flex-direction: column;
        align-items: stretch;
    }

    .login-card .captcha img {
        width: 100%;
        max-width: 200px;
        margin: 0 auto;
    }

    .login-card .captcha input {
        max-width: 100%;
    }

    .login-card .btn-primary {
        padding: 14px;
        font-size: 15px;
    }

    .row.min-vh-100 {
        min-height: auto !important;
        padding: 20px 0;
    }

    .col-12.col-md-6:first-child {
        margin-bottom: 20px;
    }
}

@media (min-width: 769px) {
    .welcome-card {
        min-height: 600px;
        display: flex;
        align-items: center;
    }
}

/* Loading Animation */
.login-card .btn-primary:disabled {
    background: var(--grey-700);
    cursor: not-allowed;
    box-shadow: none;
}

/* Form Validation States */
.login-card .form-control:valid {
    border-color: var(--success);
}

.login-card .form-control:invalid:not(:placeholder-shown) {
    border-color: var(--danger);
}

/* Smooth Scroll */
html {
    scroll-behavior: smooth;
}

/* Print Styles */
@media print {
    body {
        background: white;
        color: black;
    }
    
    .welcome-card,
    .social-login {
        display: none;
    }
}
