:root {
    --primary: #1e3a5f;
    --gold: #d4af37;
    --gold-light: #f5d76e;
    --accent: #3b82f6;
    --light-bg: #f4f6f9;
    --card-bg: #ffffff;
    --text-main: #1f2937;
    --text-muted: #6b7280;
}

* { font-family: 'Inter', sans-serif; }

body {
    margin: 0;
    font-size: 14px;
    background: var(--light-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    opacity: 0;
    animation: fadeBody 0.6s ease forwards;
}

@keyframes fadeBody { to { opacity: 1; } }

.login-card {
    display: flex;
    width: 880px;
    border-radius: 14px;
    overflow: hidden;
    background: var(--card-bg);
    box-shadow: 0 15px 35px rgba(0,0,0,0.08);
    transform: translateY(30px);
    opacity: 0;
    animation: slideUp 0.6s ease 0.2s forwards;
}

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

/* LEFT PANEL */
.login-left {
    flex: 1;
    background: var(--primary);
    color: #ffffff;
    padding: 45px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-left h5 {
    font-weight: 500;
    margin-bottom: 25px;
    font-size: 15px;
    letter-spacing: 0.5px;
    color: var(--gold-light);
}

.security-tip {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    font-size: 13px;
    opacity: 0.95;
    transition: 0.3s ease;
}

.security-tip i { color: var(--gold); font-size: 14px; }
.security-tip:hover { transform: translateX(5px); color: var(--gold-light); }

/* RIGHT PANEL */
.login-right {
    flex: 1;
    padding: 45px 40px;
    text-align: center;
}

.logo { width: 70px; margin-bottom: 12px; transition: 0.4s ease; }
.logo:hover { transform: scale(1.05) rotate(2deg); }

.app-name { font-size: 18px; font-weight: 600; color: var(--primary); margin-bottom: 4px; }
.subtitle { font-size: 12px; color: var(--text-muted); margin-bottom: 25px; }

.form-control {
    border-radius: 8px;
    padding: 10px 14px 10px 38px;
    font-size: 13px;
    border: 1px solid #d1d5db;
    transition: 0.3s ease;
}

.form-control:focus {
    border-color: var(--gold);
    box-shadow: 0 0 0 2px rgba(212,175,55,0.25);
}

.input-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #6b7280;
    font-size: 14px;
}

.password-wrapper { position: relative; }
.password-wrapper i.password-toggle {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    cursor: pointer;
    color: #6b7280;
}

.btn-login {
    background: var(--primary);
    color: white;
    border-radius: 8px;
    padding: 9px;
    font-size: 13px;
    font-weight: 500;
    transition: 0.3s ease;
}

.btn-login:hover { background: var(--gold); color: #000; }

.links {
    margin-top: 14px;
    display: flex;
    justify-content: space-between;
}

.links a {
    font-size: 12px;
    text-decoration: none;
    color: var(--primary);
    transition: 0.3s ease;
}

.links a:hover { color: var(--gold); }

/* DARK MODE */
@media (prefers-color-scheme: dark) {
    :root {
        --light-bg: #0f172a;
        --card-bg: #1e293b;
        --text-main: #e5e7eb;
        --text-muted: #94a3b8;
        --primary: #334155; /* new dark blue */
    }

    body { background: var(--light-bg); color: var(--text-main); }
    .login-card { background: var(--card-bg); box-shadow: 0 15px 40px rgba(0,0,0,0.4); }
    .login-left { background: var(--primary); }
    .app-name { color: var(--gold-light); }
    .subtitle { color: var(--text-muted); }
    .form-control { background: #334155; color: #fff; border: 1px solid #475569; }
    .form-control::placeholder { color: #cbd5e1; }
    .links a { color: var(--gold-light); }
    .btn-login { background: var(--gold); color: #000; }
    .btn-login:hover { background: var(--gold-light); }
}

/* RESPONSIVE */
@media (max-width: 768px) {

    .login-card {
        flex-direction: column;
        width: 95%;
    }

    /* ✅ HIDE LEFT PANEL ON MOBILE */
    .login-left {
        display: none !important;
    }

    /* ✅ FULL WIDTH RIGHT PANEL */
    .login-right {
        flex: 1 1 100%;
        padding: 30px 20px;
    }
}
