:root {
    /* Light Mode Variables */
    --primary-color: #6366f1;
    --primary-hover: #4f46e5;
    --secondary-color: #f43f5e;
    --accent-color: #8b5cf6;
    --light-bg: #f9fafb;
    --card-bg: #ffffff;
    --border-color: rgba(0, 0, 0, 0.05);
    --text-dark: #1e293b;
    --text-muted: #64748b;
    --card-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05), 0 4px 6px -2px rgba(0, 0, 0, 0.025);
    --input-bg: #f8fafc;
    --input-border: #e2e8f0;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
}

[data-bs-theme="dark"] {
    /* Dark Mode Variables */
    --primary-color: #6366f1;
    --primary-hover: #4f46e5;
    --secondary-color: #f43f5e;
    --accent-color: #8b5cf6;
    --light-bg: #0f172a;
    --card-bg: #1e293b;
    --border-color: rgba(255, 255, 255, 0.05);
    --text-dark: #f8fafc;
    --text-muted: #cbd5e1;
    --card-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.2), 0 4px 6px -2px rgba(0, 0, 0, 0.1);
    --input-bg: #334155;
    --input-border: #475569;
}

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--light-bg);
    color: var(--text-dark);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

/* Background Shapes */
.shape {
    position: absolute;
    z-index: -1;
    opacity: 0.5;
}

.shape-1 {
    top: 10%;
    left: 10%;
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: linear-gradient(45deg, var(--primary-color), var(--accent-color));
    filter: blur(50px);
}

.shape-2 {
    bottom: 10%;
    right: 10%;
    width: 250px;
    height: 250px;
    border-radius: 50%;
    background: linear-gradient(45deg, var(--secondary-color), var(--accent-color));
    filter: blur(50px);
}

.login-container {
    width: 100%;
    max-width: 1000px;
    display: flex;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: var(--card-shadow);
    background-color: var(--card-bg);
    position: relative;
}

.login-image {
    flex: 1;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    overflow: hidden;
    display: none;
}

.login-image::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 60%);
    transform: rotate(30deg);
}

.login-image-content {
    position: relative;
    z-index: 1;
    color: white;
}

.login-image-logo {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.login-image-logo-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background-color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
}

.login-image-logo-text {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 30px;
}

.login-image-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 20px;
}

.login-image-description {
    font-size: 16px;
    margin-bottom: 30px;
    opacity: 0.9;
}

.login-image-features {
    list-style: none;
    padding: 0;
    margin: 0;
}

.login-image-feature {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.login-image-feature-icon {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
}

.login-form {
    flex: 1;
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-form-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.login-logo-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
    color: white;
    font-size: 24px;
}

.login-logo-text {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 24px;
    color: var(--text-dark);
}

.login-logo-text span {
    color: var(--primary-color);
}

.login-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.login-subtitle {
    font-size: 14px;
    color: var(--text-muted);
}

.login-form-content {
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-dark);
    position: relative;
    padding-left: 12px;
}

.form-label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 16px;
    background-color: var(--primary-color);
    border-radius: 2px;
    opacity: 0.7;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border-radius: 10px;
    border: 1px solid var(--input-border);
    background-color: var(--input-bg);
    color: var(--text-dark);
    font-size: 14px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.form-control:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2);
    transform: translateY(-2px);
}

.form-check {
    display: flex;
    align-items: center;
}

.form-check-input {
    width: 18px;
    height: 18px;
    margin-right: 8px;
    cursor: pointer;
}

.form-check-label {
    font-size: 14px;
    color: var(--text-muted);
    cursor: pointer;
}

.forgot-password {
    font-size: 14px;
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

.forgot-password:hover {
    text-decoration: underline;
    color: var(--primary-hover);
}

.login-btn {
    width: 100%;
    padding: 12px;
    border-radius: 10px;
    background-color: var(--primary-color);
    color: white;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(99, 102, 241, 0.2);
    margin-bottom: 20px;
}

.login-btn:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(99, 102, 241, 0.3);
}

.login-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(99, 102, 241, 0.2);
}

.social-login {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.social-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-radius: 10px;
    background-color: var(--input-bg);
    border: 1px solid var(--input-border);
    color: var(--text-dark);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.social-btn:hover {
    background-color: var(--light-bg);
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.05);
}

.social-btn i {
    margin-right: 8px;
    font-size: 18px;
}

.social-btn.google i {
    color: #ea4335;
}

.social-btn.facebook i {
    color: #1877f2;
}

.divider {
    display: flex;
    align-items: center;
    margin: 20px 0;
    color: var(--text-muted);
    font-size: 14px;
}

.divider::before,
.divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background-color: var(--border-color);
}

.divider::before {
    margin-right: 10px;
}

.divider::after {
    margin-left: 10px;
}

.register-link {
    text-align: center;
    font-size: 14px;
    color: var(--text-muted);
}

.register-link a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.register-link a:hover {
    text-decoration: underline;
    color: var(--primary-hover);
}

.theme-toggle {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--light-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dark);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
}

.theme-toggle:hover {
    background-color: var(--input-bg);
    transform: rotate(15deg);
}

/* Responsive Adjustments */
@media (min-width: 768px) {
    .login-image {
        display: flex;
    }
}

@media (max-width: 767px) {
    .login-container {
        max-width: 500px;
    }

    .login-form {
        padding: 30px;
    }
}

/* Background Animation */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.bg-animation-shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.4;
    animation: float 15s infinite ease-in-out;
}

.shape-3 {
    top: 50%;
    right: 20%;
    width: 200px;
    height: 200px;
    background: linear-gradient(45deg, #10b981, var(--primary-color));
    animation-delay: -10s;
}

@keyframes float {
    0% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(5%, 5%) rotate(5deg);
    }
    50% {
        transform: translate(0, 10%) rotate(0deg);
    }
    75% {
        transform: translate(-5%, 5%) rotate(-5deg);
    }
    100% {
        transform: translate(0, 0) rotate(0deg);
    }
}

/* Signup Container */
.signup-container {
    width: 100%;
    max-width: 550px;
    background-color: var(--card-bg);
    border-radius: 20px;
    box-shadow: var(--card-shadow);
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.signup-header {
    text-align: center;
    padding: 40px 30px 20px;
}

.signup-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.signup-logo-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
    color: white;
    font-size: 24px;
}

.signup-logo-text {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 24px;
    color: var(--text-dark);
}

.signup-logo-text span {
    color: var(--primary-color);
}

.signup-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.signup-subtitle {
    font-size: 14px;
    color: var(--text-muted);
    margin-bottom: 30px;
}

.signup-form {
    padding: 0 30px 40px;
}

.password-field {
    position: relative;
}

.password-toggle {
    position: absolute;
    top: 50%;
    right: 30px;
    transform: translateY(-50%);
    cursor: pointer;
    color: var(--text-muted);
    transition: color 0.3s ease;
    z-index: 2;
}

.password-toggle:hover {
    color: var(--primary-color);
}

.password-requirements {
    display: none;
    margin-top: 10px;
    padding: 15px;
    border-radius: 10px;
    background-color: var(--input-bg);
    border: 1px solid var(--input-border);
}

.password-requirements h6 {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 10px;
    color: var(--text-dark);
}

.requirement-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.requirement-item {
    display: flex;
    align-items: center;
    margin-bottom: 8px;
    font-size: 13px;
    color: var(--text-muted);
    transition: all 0.3s ease;
}

.requirement-item:last-child {
    margin-bottom: 0;
}

.requirement-icon {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 8px;
    font-size: 10px;
    color: white;
    transition: all 0.3s ease;
}

.requirement-icon.default {
    background-color: var(--text-muted);
}

.requirement-icon.valid {
    background-color: var(--success-color);
}

.requirement-icon.invalid {
    background-color: var(--danger-color);
}

.requirement-text.valid {
    color: var(--success-color);
}

.requirement-text.invalid {
    color: var(--danger-color);
}

.form-check {
    display: flex;
    align-items: flex-start;
    margin-bottom: 20px;
}

.form-check-input {
    width: 18px;
    height: 18px;
    margin-right: 10px;
    margin-top: 3px;
    cursor: pointer;
}

.form-check-label {
    font-size: 14px;
    color: var(--text-muted);
    cursor: pointer;
}

.form-check-label a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.form-check-label a:hover {
    text-decoration: underline;
    color: var(--primary-hover);
}

.signup-btn {
    width: 100%;
    padding: 14px;
    border-radius: 10px;
    background-color: var(--primary-color);
    color: white;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(99, 102, 241, 0.2);
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
}

.signup-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: all 0.6s ease;
}

.signup-btn:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(99, 102, 241, 0.3);
}

.signup-btn:hover::before {
    left: 100%;
}

.signup-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(99, 102, 241, 0.2);
}

.signup-btn:disabled {
    background-color: var(--text-muted);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.signup-btn:disabled::before {
    display: none;
}

.login-link {
    text-align: center;
    font-size: 14px;
    color: var(--text-muted);
}

.login-link a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.login-link a:hover {
    text-decoration: underline;
    color: var(--primary-hover);
}

.theme-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--card-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-dark);
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10;
    box-shadow: var(--card-shadow);
}

.theme-toggle:hover {
    transform: rotate(15deg);
}

.error-feedback {
    display: none;
    color: var(--danger-color);
    font-size: 12px;
    margin-top: 5px;
}

.is-invalid {
    border-color: var(--danger-color) !important;
}

.is-invalid:focus {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2) !important;
}

/* Animation */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.signup-container {
    animation: fadeIn 0.6s ease-out;
}

/* Responsive */
@media (max-width: 576px) {
    .signup-container {
        max-width: 100%;
    }

    .signup-header {
        padding: 30px 20px 15px;
    }

    .signup-form {
        padding: 0 20px 30px;
    }
}