:root {
    --primary-color: #0d1b2a;
    --accent-color: #3b82f6;
    /* Modern Blue */
    --text-color: #e0e6ed;
    --bg-overlay: rgba(13, 27, 42, 0.85);
    --glass-bg: rgba(255, 255, 255, 0.05);
    --glass-border: rgba(255, 255, 255, 0.1);
    --input-bg: rgba(0, 0, 0, 0.2);
    --font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

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

body {
    font-family: var(--font-family);
    background-color: var(--primary-color);
    height: 100vh;
    width: 100vw;
    overflow: hidden;
    display: flex;
}

/* Split Layout */
.login-wrapper {
    display: flex;
    width: 100%;
    height: 100%;
}

/* Left Side - Image */
.visual-side {
    flex: 1;
    background-image: url('/assets/img/login_bg.png');
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 3rem;
    color: white;
}

.visual-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(13, 27, 42, 0.9), transparent);
}

.visual-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
    animation: slideUp 0.8s ease-out;
}

.visual-content h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.1;
}

.visual-content p {
    font-size: 1.1rem;
    opacity: 0.9;
    color: #e2e8f0;
}

/* Right Side - Form */
.form-side {
    width: 450px;
    /* Fixed width for better readability */
    background: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.3);
}

.login-card {
    width: 100%;
    max-width: 380px;
    animation: fadeIn 1s ease-out;
}

.logo-area {
    margin-bottom: 2rem;
    text-align: center;
}

.logo-area img {
    height: 50px;
    margin-bottom: 1rem;
}

.logo-area h2 {
    color: white;
    font-size: 1.5rem;
    font-weight: 600;
}

.form-group {
    margin-bottom: 1.5rem;
    position: relative;
}

.form-label {
    position: absolute;
    left: 1rem;
    top: 1rem;
    color: #cbd5e1;
    /* Lighter for better contrast on dark bg */
    pointer-events: none;
    transition: all 0.2s ease;
    font-size: 0.95rem;
}

.form-control {
    width: 100%;
    padding: 1rem 1rem 0.5rem;
    background: var(--input-bg);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    color: white;
    font-size: 1rem;
    outline: none;
    transition: border-color 0.3s;
    height: 56px;
    /* Material height */
}

.form-control:focus {
    border-color: var(--accent-color);
}

/* Float label when focused or has value */
.form-control:focus~.form-label,
.form-control:not(:placeholder-shown)~.form-label {
    top: 5px;
    font-size: 0.75rem;
    color: var(--accent-color);
}

.btn-login {
    width: 100%;
    padding: 1rem;
    background: var(--accent-color);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s, transform 0.1s;
    margin-top: 1rem;
}

.btn-login:hover {
    background: #2563eb;
}

.btn-login:active {
    transform: scale(0.98);
}

.error-msg {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #fca5a5;
    padding: 0.75rem;
    border-radius: 6px;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.footer-text {
    margin-top: 2rem;
    text-align: center;
    color: #94a3b8;
    /* Lighter than #64748b */
    font-size: 0.85rem;
}

/* Animations */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .visual-side {
        display: none;
        /* Hide image on mobile or make it a background overlay */
    }

    .form-side {
        width: 100%;
        background-image: url('/assets/img/login_bg.png');
        background-size: cover;
        background-position: center;
    }

    .form-side::before {
        content: '';
        position: absolute;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(13, 27, 42, 0.85);
        /* Dark overlay */
        backdrop-filter: blur(8px);
        z-index: 0;
    }

    .login-card {
        z-index: 1;
        background: rgba(255, 255, 255, 0.05);
        /* Glass card */
        padding: 2rem;
        border-radius: 16px;
        border: 1px solid var(--glass-border);
        box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    }
}
/* Helper for text contrast */
.text-secondary {
    color: #cbd5e1 !important; /* High contrast override */
    font-size: 0.9rem;
    margin-top: 0.5rem;
}
