@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    background: #f5f6f8;
    color: #111;
}

.login-page {
    min-height: 100vh;
    display: flex;
    background: #ffffff;
}

.left-panel {
    flex: 1.1;
    position: relative;
    background:
        linear-gradient(rgba(10, 20, 40, 0.55), rgba(10, 20, 40, 0.65)),
        url('../img/login-bg.jpg') center/cover no-repeat;
    display: flex;
    align-items: flex-end;
    padding: 50px;
    overflow: hidden;
}

.overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 205, 0, 0.08), rgba(0, 0, 0, 0.25));
}

.left-content {
    position: relative;
    z-index: 2;
    width: 100%;
    color: #fff;
}

.brand-logo {
    margin-bottom: 40px;
}

.brand-logo img {
    width: 180px;
    max-width: 100%;
    object-fit: contain;
    background: rgba(255,255,255,0.08);
    padding: 10px 14px;
    border-radius: 14px;
    backdrop-filter: blur(6px);
}

.hero-text h1 {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.15;
    margin-bottom: 18px;
    max-width: 560px;
}

.hero-text p {
    font-size: 1rem;
    line-height: 1.8;
    max-width: 560px;
    color: rgba(255,255,255,0.9);
}

.right-panel {
    flex: 0.9;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    padding: 40px;
}

.login-card {
    width: 100%;
    max-width: 470px;
    background: #fff;
    border-radius: 28px;
    padding: 42px 36px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
    border: 1px solid #f0f0f0;
}

.login-header h2 {
    font-size: 2.2rem;
    font-weight: 800;
    color: #111;
    margin-bottom: 10px;
}

.login-header p {
    color: #666;
    font-size: 0.98rem;
    margin-bottom: 30px;
}

.login-form .form-group {
    margin-bottom: 22px;
}

.login-form label {
    display: block;
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 10px;
    color: #222;
}

.input-icon {
    position: relative;
}

.input-icon i:first-child {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: #777;
    font-size: 0.95rem;
}

.input-icon input {
    width: 100%;
    height: 54px;
    border: 1.5px solid #e4e6eb;
    border-radius: 14px;
    padding: 0 48px 0 46px;
    font-size: 0.98rem;
    outline: none;
    transition: all 0.25s ease;
    background: #fff;
}

.input-icon input:focus {
    border-color: #ffcd00;
    box-shadow: 0 0 0 4px rgba(255, 205, 0, 0.18);
}

.toggle-password {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    color: #777;
    font-size: 1rem;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 26px;
    flex-wrap: wrap;
}

.remember-me {
    display: flex !important;
    align-items: center;
    gap: 8px;
    font-size: 0.94rem;
    font-weight: 500 !important;
    color: #555 !important;
    margin-bottom: 0 !important;
}

.remember-me input {
    accent-color: #ffcd00;
    width: 16px;
    height: 16px;
}

.forgot-link {
    color: #777;
    text-decoration: none;
    font-size: 0.94rem;
    transition: 0.2s ease;
}

.forgot-link:hover {
    color: #111;
}

.login-btn {
    width: 100%;
    height: 54px;
    border: none;
    border-radius: 999px;
    background: #111;
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.25s ease;
}

.login-btn:hover {
    background: #ffcd00;
    color: #111;
    transform: translateY(-1px);
}

.login-footer {
    margin-top: 24px;
    text-align: center;
    color: #999;
    font-size: 0.9rem;
}

/* Popup */
.popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 20px;
}

.popup-overlay.show {
    display: flex;
}

.popup-box {
    width: 100%;
    max-width: 380px;
    background: #fff;
    border-radius: 22px;
    padding: 30px 26px;
    text-align: center;
    box-shadow: 0 18px 45px rgba(0,0,0,0.18);
    animation: popupFade 0.25s ease;
}

.popup-box.error .popup-icon {
    width: 70px;
    height: 70px;
    margin: 0 auto 14px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 205, 0, 0.16);
    color: #d19b00;
    font-size: 2rem;
}

.popup-box h3 {
    font-size: 1.4rem;
    margin-bottom: 10px;
    color: #111;
}

.popup-box p {
    color: #666;
    line-height: 1.6;
    margin-bottom: 20px;
}

.popup-box button {
    border: none;
    background: #111;
    color: #fff;
    padding: 12px 24px;
    border-radius: 999px;
    cursor: pointer;
    font-weight: 600;
    transition: 0.2s ease;
}

.popup-box button:hover {
    background: #ffcd00;
    color: #111;
}

@keyframes popupFade {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@media (max-width: 576px) {
    .login-page {
        flex-direction: column;
    }

    .left-panel {
        min-height: 430px;
        padding: 22px 20px 140px;
        align-items: flex-start;
        background-position: center top;
    }

    .left-content {
        margin-top: 0;
    }

    .brand-logo {
        margin-bottom: 42px;
    }

    .brand-logo img {
        width: 150px;
    }

    .hero-text h1 {
        font-size: 1.95rem;
        line-height: 1.1;
        margin-bottom: 18px;
        max-width: 260px;
    }

    .hero-text p {
        font-size: 0.95rem;
        line-height: 1.55;
        max-width: 310px;
    }

    .right-panel {
        padding: 0 14px 18px;
        margin-top: -70px;
        position: relative;
        z-index: 3;
    }

    .login-card {
        padding: 30px 22px;
        border-radius: 26px;
    }

    .login-header h2 {
        font-size: 1.8rem;
    }

    .input-icon input {
        height: 52px;
    }

    .login-btn {
        height: 52px;
    }
}

@media (max-width: 576px) {
    .left-panel {
        min-height: 460px;
        padding: 22px 20px 160px;
        align-items: flex-start;
    }

    .left-content {
        margin-top: 4px;
    }

    .brand-logo {
        margin-bottom: 18px;
    }

    .brand-logo img {
        width: 150px;
    }

    .hero-text h1 {
        font-size: 1.7rem;
        line-height: 1.15;
        margin-bottom: 10px;
    }

    .hero-text p {
        font-size: 0.92rem;
        line-height: 1.5;
        max-width: 92%;
    }

    .right-panel {
        padding: 16px;
        margin-top: -38px;
        position: relative;
        z-index: 3;
    }

    .login-card {
        padding: 26px 18px;
    }

    .login-header h2 {
        font-size: 1.8rem;
    }

    .input-icon input {
        height: 50px;
    }

    .login-btn {
        height: 50px;
    }
}

