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

html, body {
    width: 100%;
    height: 100%;
    overflow: hidden;
    font-family: 'Plus Jakarta Sans', sans-serif;
    background: #fff;
}

/* Sembunyikan scrollbar di semua browser */
::-webkit-scrollbar {
    display: none;
}

* {
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.auth-wrap {
    display: flex;
    width: 100%;
    height: 100vh;
    min-height: 0;
    overflow: hidden;
}

/* ─── Sisi Kiri (Visual) ─── */
.visual-side {
    flex: 1.2;
    position: relative;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5%;
    overflow: hidden;
}

.visual-bg {
    position: absolute;
    inset: 0;
    background: url('https://absensi.rsumitradelima.com/assets/images/login_image.jpg') center / cover no-repeat;
    opacity: 0.25;
}

.visual-deco {
    position: absolute;
    bottom: -60px;
    right: -60px;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background: rgba(102, 126, 234, 0.08);
    border: 1px solid rgba(102, 126, 234, 0.12);
    pointer-events: none;
}

.visual-deco2 {
    position: absolute;
    top: -40px;
    left: -40px;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: rgba(118, 75, 162, 0.10);
    border: 1px solid rgba(118, 75, 162, 0.15);
    pointer-events: none;
}

.visual-content {
    position: relative;
    z-index: 2;
    color: #fff;
    max-width: 460px;
    width: 100%;
}

.badge-pill {
    display: inline-block;
    background: rgba(102, 126, 234, 0.35);
    border: 1px solid rgba(102, 126, 234, 0.5);
    color: #a5b4fc;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding: 5px 14px;
    border-radius: 999px;
    margin-bottom: 20px;
}

.visual-content h1 {
    font-size: clamp(1.8rem, 3.2vw, 3rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -1.5px;
    margin-bottom: 16px;
    color: #fff;
}

.visual-content p {
    font-size: 0.95rem;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.6;
}

/* ─── Sisi Kanan (Form) ─── */
.form-side {
    flex: 0.8;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(1.25rem, 3vw, 2.5rem);
    overflow-y: auto;
    overflow-x: hidden;
    min-height: 0;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.form-side::-webkit-scrollbar {
    display: none;
}

.login-box {
    width: 100%;
    max-width: 400px;
}

/* ─── Brand Icon ─── */
.brand-icon {
    width: 52px;
    height: 52px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 22px;
    box-shadow: 0 6px 18px rgba(102, 126, 234, 0.28);
}

.brand-icon svg {
    width: 24px;
    height: 24px;
    stroke: #fff;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ─── Judul ─── */
.title-main {
    font-size: clamp(1.5rem, 2.5vw, 1.9rem);
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.8px;
    line-height: 1.15;
    margin-bottom: 4px;
}

.title-sub {
    font-size: 0.95rem;
    color: #64748b;
    font-weight: 500;
    margin-bottom: 30px;
    display: block;
}

/* ─── Field ─── */
.field-group {
    margin-bottom: 18px;
}

.field-label {
    display: block;
    font-size: 10.5px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.1px;
    color: #475569;
    margin-bottom: 8px;
}

.field-wrap {
    position: relative;
}

.field-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    display: flex;
    align-items: center;
}

.field-icon svg {
    width: 16px;
    height: 16px;
    stroke: #94a3b8;
    fill: none;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.field-input {
    width: 100%;
    height: 52px;
    padding: 0 15px 0 44px;
    border: 2px solid #f1f5f9;
    background: #f8fafc;
    border-radius: 13px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #1e293b;
    outline: none;
    font-family: 'Plus Jakarta Sans', sans-serif;
    transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}

.field-input:focus {
    background: #fff;
    border-color: #667eea;
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.12);
}

.field-input::placeholder {
    color: #b8c2cc;
    font-weight: 500;
}

.error-msg {
    display: block;
    font-size: 12px;
    color: #ef4444;
    margin-top: 5px;
}

/* ─── Row Opsi ─── */
.row-opts {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.check-wrap {
    display: flex;
    align-items: center;
    gap: 7px;
    cursor: pointer;
}

.check-wrap input[type="checkbox"] {
    width: 15px;
    height: 15px;
    accent-color: #667eea;
    cursor: pointer;
}

.check-wrap span {
    font-size: 12.5px;
    color: #64748b;
    font-weight: 500;
}

.link-help {
    font-size: 12.5px;
    color: #667eea;
    font-weight: 700;
    text-decoration: none;
}

/* ─── Tombol Submit ─── */
.btn-login {
    width: 100%;
    height: 54px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    border-radius: 13px;
    color: #fff;
    font-size: 0.95rem;
    font-weight: 700;
    font-family: 'Plus Jakarta Sans', sans-serif;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    box-shadow: 0 8px 22px rgba(102, 126, 234, 0.35);
    transition: transform 0.2s, box-shadow 0.2s;
    margin-bottom: 18px;
}

.btn-login:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 28px rgba(102, 126, 234, 0.45);
}

.btn-login svg {
    width: 16px;
    height: 16px;
    stroke: #fff;
    fill: none;
    stroke-width: 2.5;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* ─── Footer ─── */
.footer-note {
    text-align: center;
    font-size: 10.5px;
    color: #94a3b8;
    font-weight: 600;
    letter-spacing: 0.3px;
}

/* ─── Responsive: Tablet & HP ─── */
@media (max-width: 768px) {
    .visual-side {
        display: none;
    }

    .form-side {
        flex: 1;
        width: 100%;
        height: 100vh;
        padding: 1.5rem;
        align-items: flex-start;
        padding-top: 10vh;
    }

    .login-box {
        max-width: 100%;
    }

    .title-main {
        font-size: 1.55rem;
    }
}

/* ─── Layar Pendek Desktop ─── */
@media (max-height: 620px) and (min-width: 769px) {
    .form-side {
        align-items: flex-start;
        padding-top: 1.5rem;
    }

    .brand-icon {
        width: 42px;
        height: 42px;
        margin-bottom: 14px;
    }

    .field-group {
        margin-bottom: 12px;
    }

    .field-input {
        height: 46px;
    }

    .btn-login {
        height: 48px;
        margin-bottom: 12px;
    }

    .title-sub {
        margin-bottom: 20px;
    }
}

/* ─── HP Landscape / Layar Sangat Pendek ─── */
@media (max-height: 500px) and (max-width: 768px) {
    .form-side {
        padding-top: 1.5rem;
    }

    .brand-icon {
        display: none;
    }

    .field-group {
        margin-bottom: 10px;
    }

    .field-input {
        height: 44px;
    }

    .btn-login {
        height: 46px;
    }

    .title-sub {
        margin-bottom: 16px;
    }
}
