/* ===== Login Page Styles ===== */
:root {
    --login-primary: #2d2b7f;
    --login-primary-dark: #1e1b5e;
    --login-accent: #e8a020;
    --login-accent-hover: #d4900e;
    --login-border: #d4a94e;
    --login-text-light: #ffffff;
    --login-bg: #ffffff;
    --login-input-bg: #fefefe;
    --login-input-border: #d4a94e;
}

/* ===== Main Container ===== */
.login-container {
    display: flex;
    min-height: 100vh;
    width: 100%;
}

/* ===== Left Panel (Logo & Branding) ===== */
.login-left {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 60px;
    background: var(--login-bg);
    position: relative;
}

.login-branding {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    animation: brandingFadeIn 0.8s ease-out;
}

.login-logo {
    max-width: 320px;
    width: 100%;
    height: auto;
    margin-bottom: 0;
    filter: drop-shadow(0 10px 30px rgba(45, 43, 127, 0.15));
    transition: transform 0.3s ease;
}

.login-logo:hover {
    transform: scale(1.03);
}

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

/* ===== Right Panel (Form) ===== */
.login-right {
    flex: 1;
    background: linear-gradient(160deg, #3b39a0 0%, var(--login-primary) 40%, var(--login-primary-dark) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 60px;
    position: relative;
    overflow: hidden;
}

.login-right::before {
    content: '';
    position: absolute;
    top: -60%;
    right: -40%;
    width: 120%;
    height: 120%;
    background: radial-gradient(circle, rgba(255,255,255,0.04) 0%, transparent 70%);
    animation: subtleGlow 15s ease-in-out infinite;
}

.login-right::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -20%;
    width: 80%;
    height: 80%;
    background: radial-gradient(circle, rgba(232, 160, 32, 0.06) 0%, transparent 60%);
    animation: subtleGlow 20s ease-in-out infinite reverse;
}

@keyframes subtleGlow {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(-15px, -10px); }
}

.login-form-wrapper {
    width: 100%;
    max-width: 420px;
    position: relative;
    z-index: 1;
    animation: formSlideIn 0.6s ease-out;
}

@keyframes formSlideIn {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* ===== Title ===== */
.login-title {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--login-text-light);
    margin-bottom: 4px;
    line-height: 1.2;
}

.login-subtitle {
    font-size: 1.1rem;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.75);
    margin-bottom: 40px;
}

/* ===== Form Group ===== */
.login-form-group {
    margin-bottom: 24px;
}

.login-form-group label {
    font-size: 0.9rem;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 8px;
    display: block;
    letter-spacing: 0.02em;
}

.login-form-group .form-control {
    border: 2px solid var(--login-input-border);
    border-radius: 12px;
    padding: 14px 18px;
    font-size: 0.95rem;
    font-family: 'Poppins', sans-serif;
    background: var(--login-input-bg);
    color: #333;
    transition: all 0.3s ease;
    outline: none;
    box-shadow: none;
    width: 100%;
}

.login-form-group .form-control:focus {
    border-color: var(--login-accent);
    box-shadow: 0 0 0 3px rgba(232, 160, 32, 0.2);
    background: #fff;
}

.login-form-group .form-control::placeholder {
    color: #b0aec8;
    font-weight: 400;
}

/* Validation error styles */
.login-form-group .form-control.is-invalid,
.login-form-group .has-error .form-control {
    border-color: #ff6b6b;
}

.login-form-group .invalid-feedback,
.login-form-group .help-block {
    font-size: 0.8rem;
    color: #ff6b6b;
    margin-top: 4px;
}

/* ===== Login Button ===== */
.login-btn-wrapper {
    text-align: center;
    margin-top: 32px;
    margin-bottom: 16px;
}

.btn-login {
    background: var(--login-accent);
    color: #fff;
    border: none;
    border-radius: 12px;
    padding: 14px 64px;
    font-size: 1.15rem;
    font-weight: 700;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: none;
    letter-spacing: 0.02em;
    box-shadow: 0 4px 20px rgba(232, 160, 32, 0.35);
    display: inline-block;
}

.btn-login:hover {
    background: var(--login-accent-hover);
    box-shadow: 0 6px 28px rgba(232, 160, 32, 0.5);
    transform: translateY(-2px);
    color: #fff;
}

.btn-login:active {
    transform: translateY(0);
    box-shadow: 0 2px 12px rgba(232, 160, 32, 0.3);
}

/* ===== Forgot Password ===== */
.login-forgot {
    text-align: center;
    margin-bottom: 24px;
}

.login-forgot a {
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.88rem;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s;
}

.login-forgot a:hover {
    color: var(--login-accent);
    text-decoration: underline;
}

/* ===== Bottom Area ===== */
.login-bottom {
    text-align: center;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.login-register-link {
    font-size: 0.88rem;
    color: rgba(255, 255, 255, 0.7);
}

.login-register-link a {
    color: var(--login-accent);
    font-weight: 600;
    text-decoration: underline;
    transition: color 0.2s;
    margin-left: 8px;
}

.login-register-link a:hover {
    color: #f0b840;
}

/* ===== Flash Messages ===== */
.login-flash {
    margin-bottom: 20px;
}

.login-flash .alert {
    border-radius: 10px;
    font-size: 0.88rem;
    padding: 12px 18px;
    border: none;
}

.login-flash .alert-success {
    background: rgba(40, 167, 69, 0.15);
    color: #a3f7bf;
}

.login-flash .alert-danger {
    background: rgba(255, 107, 107, 0.15);
    color: #ff6b6b;
}

/* ===== Responsive ===== */
@media (max-width: 991px) {
    .login-container {
        flex-direction: column;
    }

    .login-left {
        display: none;
    }

    .login-right {
        padding: 40px 24px;
        min-height: 100vh;
    }

    .auth-body {
        overflow-y: auto;
    }
}

@media (max-width: 576px) {
    .login-right {
        padding: 30px 20px;
    }

    .login-title {
        font-size: 1.8rem;
    }

    .login-subtitle {
        font-size: 0.95rem;
        margin-bottom: 28px;
    }

    .btn-login {
        width: 100%;
        padding: 14px 24px;
    }

    .login-form-wrapper {
        max-width: 100%;
    }
}
