/* =========================================================
   LOGIN SMART LIBRARY
========================================================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Segoe UI", Arial, sans-serif;
    background: #f4f7fb;
    color: #1f2937;
}

a {
    text-decoration: none;
}


/* =========================================================
   HALAMAN LOGIN
========================================================= */

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
}


/* =========================================================
   CONTAINER
========================================================= */

.login-container {
    width: 100%;
    max-width: 1150px;
    min-height: 650px;

    display: grid;
    grid-template-columns: 46% 54%;

    background: #ffffff;

    border-radius: 28px;

    overflow: hidden;

    box-shadow:
        0 20px 60px rgba(15, 23, 42, 0.12);
}


/* =========================================================
   BAGIAN KIRI
========================================================= */

.login-left {
    position: relative;

    display: flex;
    align-items: center;

    padding: 60px 55px;

    color: #ffffff;

    background:
        linear-gradient(
            135deg,
            #4f46e5,
            #4338ca,
            #3730a3
        );

    overflow: hidden;
}


/* Lingkaran dekorasi */

.login-left::before {
    content: "";
    position: absolute;

    width: 400px;
    height: 400px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.06);

    top: -180px;
    right: -180px;
}

.login-left::after {
    content: "";
    position: absolute;

    width: 300px;
    height: 300px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.05);

    bottom: -160px;
    left: -120px;
}


.login-left-overlay {
    position: absolute;
    inset: 0;

    background:
        linear-gradient(
            180deg,
            rgba(67, 56, 202, 0.1),
            rgba(30, 27, 75, 0.18)
        );
}


.login-left-content {
    position: relative;
    z-index: 2;

    width: 100%;
    text-align: center;
}


/* =========================================================
   LOGO
========================================================= */

.logo-box {
    width: 92px;
    height: 92px;

    margin: 0 auto 25px;

    background: #ffffff;

    border-radius: 20px;

    display: flex;
    align-items: center;
    justify-content: center;

    box-shadow:
        0 12px 30px rgba(0, 0, 0, 0.15);

    overflow: hidden;
}

.logo-box img {
    width: 72px;
    height: 72px;

    object-fit: contain;
}


/* =========================================================
   JUDUL KIRI
========================================================= */

.login-left h1 {
    font-size: 34px;
    font-weight: 800;

    letter-spacing: 1px;

    margin-bottom: 8px;
}

.login-left .subtitle {
    font-size: 11px;
    letter-spacing: 3px;

    font-weight: 600;

    opacity: 0.9;

    margin-bottom: 30px;
}

.login-left .deskripsi {
    max-width: 390px;

    margin: 0 auto;

    font-size: 15px;
    line-height: 1.8;

    color: rgba(255, 255, 255, 0.86);
}


/* =========================================================
   KEUNGGULAN
========================================================= */

.keunggulan {
    margin-top: 45px;
}

.keunggulan-item {
    display: flex;
    align-items: center;

    gap: 15px;

    text-align: left;

    padding: 17px 20px;

    border-radius: 18px;

    background: rgba(255, 255, 255, 0.09);

    border: 1px solid rgba(255, 255, 255, 0.1);
}

.icon-keunggulan {
    width: 43px;
    height: 43px;

    flex-shrink: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 12px;

    background: rgba(255, 255, 255, 0.14);

    font-size: 21px;
}

.keunggulan-item strong {
    display: block;

    font-size: 14px;

    margin-bottom: 4px;
}

.keunggulan-item span {
    display: block;

    font-size: 11px;

    color: rgba(255, 255, 255, 0.72);

    line-height: 1.5;
}


/* =========================================================
   BAGIAN KANAN
========================================================= */

.login-right {
    display: flex;
    align-items: center;
    justify-content: center;

    padding: 55px 70px;

    background: #ffffff;
}


.login-form-wrapper {
    width: 100%;
    max-width: 440px;
}


/* =========================================================
   HEADER FORM
========================================================= */

.form-header {
    margin-bottom: 30px;
}

.form-header h2 {
    font-size: 30px;

    color: #111827;

    font-weight: 750;

    margin-bottom: 7px;
}

.form-header p {
    color: #9ca3af;

    font-size: 14px;
}


/* =========================================================
   ERROR
========================================================= */

.alert-error {
    display: flex;
    align-items: center;

    gap: 10px;

    padding: 12px 15px;

    margin-bottom: 20px;

    border-radius: 10px;

    background: #fef2f2;

    border: 1px solid #fecaca;

    color: #dc2626;

    font-size: 13px;
}


/* =========================================================
   FORM
========================================================= */

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;

    margin-bottom: 8px;

    font-size: 13px;

    color: #374151;

    font-weight: 600;
}


.input-wrapper {
    position: relative;
}

.input-wrapper > i {
    position: absolute;

    left: 16px;
    top: 50%;

    transform: translateY(-50%);

    color: #9ca3af;

    font-size: 16px;

    pointer-events: none;
}


.input-wrapper input {
    width: 100%;

    height: 52px;

    padding: 0 48px 0 45px;

    border: 1px solid #e5e7eb;

    border-radius: 12px;

    outline: none;

    background: #fafafa;

    font-size: 14px;

    color: #1f2937;

    transition: 0.2s ease;
}

.input-wrapper input::placeholder {
    color: #b0b6c0;
}

.input-wrapper input:focus {
    border-color: #6366f1;

    background: #ffffff;

    box-shadow:
        0 0 0 4px rgba(99, 102, 241, 0.08);
}


/* =========================================================
   SHOW PASSWORD
========================================================= */

.btn-show-password {
    position: absolute;

    right: 14px;
    top: 50%;

    transform: translateY(-50%);

    border: none;

    background: transparent;

    color: #9ca3af;

    font-size: 17px;

    cursor: pointer;

    padding: 4px;
}

.btn-show-password:hover {
    color: #4f46e5;
}


/* =========================================================
   OPTIONS
========================================================= */

.login-options {
    display: flex;
    align-items: center;
    justify-content: space-between;

    margin-top: -4px;

    margin-bottom: 25px;

    font-size: 12px;
}

.remember-me {
    display: flex;
    align-items: center;

    gap: 7px;

    color: #6b7280;

    cursor: pointer;
}

.remember-me input {
    width: 15px;
    height: 15px;

    accent-color: #4f46e5;

    cursor: pointer;
}

.forgot-password {
    color: #4f46e5;

    font-weight: 600;
}

.forgot-password:hover {
    text-decoration: underline;
}


/* =========================================================
   BUTTON LOGIN
========================================================= */

.btn-login {
    width: 100%;

    height: 53px;

    border: none;

    border-radius: 12px;

    background:
        linear-gradient(
            135deg,
            #4f46e5,
            #4338ca
        );

    color: #ffffff;

    font-size: 13px;

    font-weight: 700;

    letter-spacing: 0.7px;

    cursor: pointer;

    display: flex;
    align-items: center;
    justify-content: center;

    gap: 9px;

    box-shadow:
        0 8px 20px rgba(79, 70, 229, 0.22);

    transition: 0.2s ease;
}

.btn-login:hover {
    transform: translateY(-1px);

    box-shadow:
        0 12px 25px rgba(79, 70, 229, 0.28);
}

.btn-login:active {
    transform: translateY(0);
}


/* =========================================================
   REGISTER
========================================================= */

.register-section {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 6px;

    margin-top: 28px;

    font-size: 11px;

    color: #9ca3af;

    letter-spacing: 0.3px;
}

.register-section a {
    color: #4f46e5;

    font-weight: 700;
}

.register-section a:hover {
    text-decoration: underline;
}


/* =========================================================
   BACK HOME
========================================================= */

.back-home {
    text-align: center;

    margin-top: 30px;
}

.back-home a {
    display: inline-flex;
    align-items: center;

    gap: 7px;

    color: #9ca3af;

    font-size: 12px;

    transition: 0.2s ease;
}

.back-home a:hover {
    color: #4f46e5;
}


/* =========================================================
   RESPONSIVE TABLET
========================================================= */

@media (max-width: 900px) {

    .login-container {
        grid-template-columns: 1fr;

        max-width: 520px;

        min-height: auto;
    }

    .login-left {
        padding: 45px 35px;
    }

    .login-left .deskripsi,
    .keunggulan {
        display: none;
    }

    .login-left h1 {
        font-size: 28px;
    }

    .login-left .subtitle {
        margin-bottom: 0;
    }

    .login-right {
        padding: 45px 40px;
    }
}


/* =========================================================
   RESPONSIVE MOBILE
========================================================= */

@media (max-width: 520px) {

    .login-page {
        padding: 0;

        align-items: stretch;
    }

    .login-container {
        min-height: 100vh;

        border-radius: 0;

        box-shadow: none;
    }

    .login-left {
        padding: 35px 25px;
    }

    .logo-box {
        width: 75px;
        height: 75px;

        margin-bottom: 18px;
    }

    .logo-box img {
        width: 58px;
        height: 58px;
    }

    .login-left h1 {
        font-size: 24px;
    }

    .login-left .subtitle {
        font-size: 9px;
        letter-spacing: 2px;
    }

    .login-right {
        padding: 35px 25px;
    }

    .form-header h2 {
        font-size: 26px;
    }

    .login-options {
        font-size: 11px;
    }

    .register-section {
        flex-direction: column;

        gap: 5px;
    }
}
/* =========================================================
   METODE LOGIN
========================================================= */

.login-method {
    display: flex;
    gap: 10px;
    margin-bottom: 25px;
}

.login-method-button {
    flex: 1;
    border: 1px solid #ddd;
    background: #fff;
    padding: 12px 10px;
    border-radius: 10px;
    cursor: pointer;
    font-size: 14px;
    transition: 0.2s;
}

.login-method-button:hover {
    background: #f5f5f5;
}

.login-method-button.active {
    background: #198754;
    color: #fff;
    border-color: #198754;
}

.qr-login-header {
    text-align: center;
    margin-bottom: 20px;
}

.qr-login-header > i {
    font-size: 45px;
    display: block;
    margin-bottom: 10px;
}

.qr-login-header h3 {
    margin: 0 0 8px;
}

.qr-login-header p {
    margin: 0;
    font-size: 14px;
}

#qr-reader {
    overflow: hidden;
    border-radius: 12px;
    margin-bottom: 15px;
}

#qr-reader video {
    border-radius: 12px;
}

.qr-status {
    text-align: center;
    padding: 12px;
    margin-bottom: 15px;
    font-size: 14px;
}

.btn-back-login {
    width: 100%;
    border: none;
    background: transparent;
    padding: 12px;
    margin-top: 10px;
    cursor: pointer;
    font-size: 14px;
}