
:root {
    --primary-blue: #073980;
    --primary-blue-dark: #052a5e;
    --accent-red: #c0392b;
    --accent-red-dark: #a5301f;
    --text-dark: #1f2937;
    --text-gray: #6b7280;
    --text-light: #9ca3af;
    --border-color: #e5e7eb;
    --white: #ffffff;
    --error-red: #dc2626;
    --success-green: #059669;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    min-height: 100vh;
    position: relative;
}

.login-container {
    position: relative;
    z-index: 2;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

.login-wrapper {
    display: flex;
    max-width: 1200px;
    width: 100%;
    background: var(--white);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

/* Brand Section */
.login-brand {
    flex: 1;
    background: var(--primary-blue);
    padding: 3rem;
    color: var(--white);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.brand-header {
    margin-bottom: 3rem;
}

.logo {
    width: 80px;
    height: 80px;
    background: var(--white);
    border-radius: 12px;
    padding: 0.75rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

    .logo img {
        width: 100%;
        height: 100%;
        object-fit: contain;
    }

.brand-title {
    font-size: 2.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: var(--white);
}

.brand-subtitle {
    font-size: 1rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 300;
}

.brand-features {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.feature {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.feature-icon {
    width: 24px;
    height: 24px;
    border: 2px solid var(--accent-red);
    border-radius: 50%;
    flex-shrink: 0;
    position: relative;
}

    .feature-icon::after {
        content: '';
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 8px;
        height: 8px;
        background: var(--accent-red);
        border-radius: 50%;
    }

.feature span {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.95);
    font-weight: 400;
}

/* Form Section */
.login-form-section {
    flex: 1;
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
    max-width: 500px;
}

.form-header {
    margin-bottom: 2rem;
}

.form-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.form-subtitle {
    font-size: 0.95rem;
    color: var(--text-gray);
    font-weight: 400;
}

.form-subtitle ol {
    margin: 0.75rem 0 0 1.1rem;
    padding: 0;
    color: var(--text-gray);
    font-size: 0.88rem;
    line-height: 1.6;
}

.error-message {
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 8px;
    padding: 0.875rem 1rem;
    margin-bottom: 1.5rem;
    color: var(--error-red);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

    .error-message::before {
        content: '\f071';
        font-family: 'bootstrap-icons';
        font-size: 1.1rem;
    }

.login-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 0;
}

.input-icon-wrap {
    position: relative;
}

    .input-icon-wrap i {
        position: absolute;
        top: 50%;
        left: 1rem;
        transform: translateY(-50%);
        color: var(--text-light);
    }

    .input-icon-wrap .form-control {
        padding-left: 2.6rem;
    }

.form-control {
    width: 100%;
    padding: 0.875rem 1rem;
    font-size: 0.95rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    transition: all 0.2s ease;
    font-family: 'Poppins', sans-serif;
    background: var(--white);
}

    .form-control:focus {
        outline: none;
        border-color: var(--primary-blue);
        box-shadow: 0 0 0 3px rgba(7, 57, 128, 0.12);
    }

    .form-control::placeholder {
        color: var(--text-light);
    }

.field-validation-error {
    color: var(--error-red);
    font-size: 0.85rem;
    margin-top: 0.25rem;
    display: block;
}

.btn-primary {
    width: 100%;
    padding: 0.875rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--white);
    background: var(--accent-red);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 0.5rem;
}

    .btn-primary:hover {
        background: var(--accent-red-dark);
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(192, 57, 43, 0.35);
    }

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

    .btn-primary .btn-spinner {
        display: none;
        width: 1rem;
        height: 1rem;
        border: 2px solid currentColor;
        border-right-color: transparent;
        border-radius: 50%;
        animation: btn-spin 0.65s linear infinite;
        vertical-align: middle;
        margin-right: 0.5rem;
    }

    .btn-primary.loading .btn-spinner {
        display: inline-block;
    }

    .btn-primary.loading {
        opacity: 0.8;
        cursor: not-allowed;
        pointer-events: none;
    }

@keyframes btn-spin {
    to {
        transform: rotate(360deg);
    }
}

.form-footer {
    margin-top: 1.5rem;
    text-align: center;
}

.form-footer-links {
    margin-top: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.form-footer-link {
    color: var(--text-gray);
    font-size: 0.9rem;
}

    .form-footer-link a,
    a.form-footer-link {
        color: var(--primary-blue);
        text-decoration: none;
        font-weight: 600;
    }

        .form-footer-link a:hover,
        a.form-footer-link:hover {
            color: var(--accent-red);
            text-decoration: underline;
        }

.footer-text {
    margin-top: 2rem;
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-light);
}

.footer-link {
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: 600;
}

    .footer-link:hover {
        color: var(--accent-red);
    }

.alert {
    border-radius: 8px;
    padding: 0.875rem 1rem;
    margin-top: 1.25rem;
    font-weight: 500;
    font-size: 0.9rem;
}

.alert-danger {
    background-color: rgba(220, 53, 69, 0.1);
    border: 1px solid rgba(220, 53, 69, 0.2);
    color: var(--error-red);
}

.alert-success {
    background-color: rgba(5, 150, 105, 0.1);
    border: 1px solid rgba(5, 150, 105, 0.2);
    color: var(--success-green);
}

.alert-info {
    background-color: rgba(7, 57, 128, 0.08);
    border: 1px solid rgba(7, 57, 128, 0.2);
    color: var(--primary-blue);
}

/* Responsive Design */
@media (max-width: 968px) {
    .login-wrapper {
        flex-direction: column;
    }

    .login-brand {
        padding: 2.5rem 2rem;
    }

    .brand-title {
        font-size: 1.875rem;
    }

    .login-form-section {
        padding: 2.5rem 2rem;
        max-width: none;
    }
}

@media (max-width: 576px) {
    .login-container {
        padding: 1rem;
    }

    .login-brand {
        padding: 2rem 1.5rem;
    }

    .logo {
        width: 60px;
        height: 60px;
    }

    .brand-title {
        font-size: 1.5rem;
    }

    .brand-subtitle {
        font-size: 0.9rem;
    }

    .login-form-section {
        padding: 2rem 1.5rem;
    }

    .form-title {
        font-size: 1.5rem;
    }

    .brand-features {
        gap: 1rem;
    }

    .feature span {
        font-size: 0.875rem;
    }
}
