/* ==========================================================================
   Login Page Stylesheet - Accounting App (50:50 Layout)
   Brand Primary Color: #1771B8
   ========================================================================== */

:root {
    --brand-primary: #1771B8;
    --brand-primary-hover: #135d96;
    --brand-primary-light: rgba(23, 113, 184, 0.1);
    --brand-text-dark: #212529;
    --brand-text-muted: #667085;
    --brand-border: #cbd5e1;
    --brand-font: 'Kanit', system-ui, -apple-system, sans-serif;
    --left-bg-color: #94c6e7;
    --mascot-card-bg: #dcedf8;
}

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

html,
body {
    margin: 0;
    padding: 0;
    min-height: 100%;
    width: 100%;
    font-family: var(--brand-font);
    background-color: #ffffff;
    color: var(--brand-text-dark);
    -webkit-font-smoothing: antialiased;
}

/* Hide Google reCAPTCHA v3 floating badge */
.grecaptcha-badge {
    visibility: hidden !important;
}

/* ==========================================
   Wrapper Layout (Split 50:50)
   ========================================== */
.login-wrapper {
    display: flex;
    width: 100%;
    min-height: 100vh;
}

@media (min-width: 992px) {

    html,
    body {
        height: 100%;
        overflow: hidden;
    }

    .login-wrapper {
        height: 100vh;
        overflow: hidden;
    }

    .login-left-panel {
        height: 100vh;
    }

    .login-right-panel {
        height: 100vh;
    }
}

/* ==========================================
   Left Panel (50% AccPax Brand / News Banner)
   ========================================== */
.login-left-panel {
    width: 50%;
    height: 100vh;
    padding: 60px;
    margin: 0;
    position: relative;
    overflow: hidden;
    background-color: #a8cce4;
    background-image: url('../images/login_register_43.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    justify-content: center;
    align-items: center;
}

.login-banner-card {
    width: 100%;
    /* height: 100%; */
    border-radius: 0;
    /* ขอบตรงตามที่ต้องการ */
    overflow: hidden;
    /* box-shadow: 0 12px 30px rgba(18, 98, 161, 0.15); */
    /* background-color: #ffffff; */
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.login-banner-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

/* ==========================================
   Right Panel (50% Pure White)
   ========================================== */
.login-right-panel {
    width: 50%;
    background-color: #ffffff;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    padding: 40px;
}

/* Desktop Top-Right Circular Logo */
.top-brand-logo {
    position: absolute;
    top: 36px;
    right: 48px;
    z-index: 10;
}

.brand-circle-logo {
    width: 50px;
    height: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid var(--brand-primary);
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(23, 113, 184, 0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    /* background-color: #ffffff; */
}

.brand-circle-logo:hover {
    transform: scale(1.04);
    box-shadow: 0 6px 16px rgba(23, 113, 184, 0.16);
}

.brand-circle-logo img {
    width: 26px;
    height: 26px;
    object-fit: contain;
}

/* Centered Form Container */
.login-form-container {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-form-inner {
    width: 100%;
}

.login-title {
    font-size: 28px;
    font-weight: 600;
    color: var(--brand-primary);
    margin: 0 0 26px 0;
    text-align: left;
}

/* Form Controls */
.form-group-custom {
    margin-bottom: 20px;
    text-align: left;
}

.form-label-custom {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #334155;
    margin-bottom: 6px;
}

.form-label-custom .required-star {
    color: #334155;
}

.form-control-custom {
    width: 100%;
    height: 46px;
    padding: 10px 14px;
    font-size: 14px;
    font-family: var(--brand-font);
    color: var(--brand-text-dark);
    background-color: #ffffff;
    border: 1.5px solid var(--brand-border);
    border-radius: 6px;
    outline: none;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control-custom::placeholder {
    color: #94a3b8;
    font-weight: 300;
}

.form-control-custom:focus {
    border-color: var(--brand-primary);
    box-shadow: 0 0 0 3px rgba(23, 113, 184, 0.15);
}

.btn-login-submit {
    width: 100%;
    height: 46px;
    background-color: var(--brand-primary);
    border: none;
    border-radius: 6px;
    color: #ffffff;
    font-size: 15px;
    font-weight: 500;
    font-family: var(--brand-font);
    cursor: pointer;
    margin-top: 8px;
    margin-bottom: 20px;
    transition: background-color 0.2s ease, transform 0.1s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 12px rgba(23, 113, 184, 0.18);
}

.btn-login-submit:hover {
    background-color: var(--brand-primary-hover);
    box-shadow: 0 6px 16px rgba(23, 113, 184, 0.26);
}

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

.register-prompt {
    font-size: 14px;
    color: var(--brand-text-muted);
    text-align: center;
    margin: 0;
}

.register-prompt a {
    color: var(--brand-primary);
    text-decoration: none;
    font-weight: 600;
    margin-left: 4px;
    transition: color 0.15s ease;
}

.register-prompt a:hover {
    text-decoration: underline;
    color: var(--brand-primary-hover);
}

.login-alert {
    padding: 10px 14px;
    margin-bottom: 16px;
    font-size: 13px;
    border-radius: 8px;
    background-color: #fef3f2;
    border: 1px solid #fee4e2;
    color: #b42318;
    text-align: left;
}

/* Bottom Right Copyright */
.copyright-footer {
    position: absolute;
    bottom: 20px;
    right: 36px;
    z-index: 10;
    font-size: 11px;
    color: #94a3b8;
    margin: 0;
}

/* ==========================================
   RESPONSIVE DESIGN (Screens < 992px)
   ========================================== */
@media (max-width: 991.98px) {
    .login-wrapper {
        min-height: 100vh;
        width: 100%;
        position: relative;
    }

    /* Hide the left panel (banner/mascot) completely on mobile */
    .login-left-panel {
        display: none !important;
    }

    /* Mobile Login Screen with Background & Bottom Wave */
    .login-right-panel {
        width: 100%;
        min-height: 100vh;
        padding: 40px 20px 90px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        position: relative;
        overflow: hidden;
        background-color: #f1f5f9;
        background-image:
            linear-gradient(rgba(255, 255, 255, 0.85), rgba(255, 255, 255, 0.85)),
            url('../images/login_banner_01.webp');
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
    }

    /* Bottom Decorative Blue Wave/Curve */
    .login-right-panel::after {
        content: '';
        position: fixed;
        bottom: -50px;
        left: 50%;
        transform: translateX(-50%);
        width: 140vw;
        height: 125px;
        background-color: var(--brand-primary);
        border-radius: 50% 50% 0 0;
        z-index: 2;
        pointer-events: none;
    }

    /* Centered Brand Circle Logo Above Card */
    .top-brand-logo {
        position: static;
        margin-bottom: 22px;
        z-index: 5;
    }

    .brand-circle-logo {
        width: 78px;
        height: 78px;
        border: 2px solid var(--brand-primary);
        border-radius: 50%;
        /* background-color: #ffffff; */
        box-shadow: 0 6px 18px rgba(23, 113, 184, 0.15);
    }

    .brand-circle-logo img {
        width: 42px;
        height: 42px;
    }

    /* Floating White Card */
    .login-form-container {
        width: 100%;
        max-width: 360px;
        z-index: 5;
        position: relative;
    }

    .login-form-inner {
        background-color: #ffffff;
        border-radius: 20px;
        padding: 30px 22px 26px;
        box-shadow: 0 12px 32px rgba(0, 0, 0, 0.08);
    }

    .login-title {
        text-align: center;
        font-size: 21px;
        font-weight: 600;
        color: #1e293b;
        margin-bottom: 22px;
    }

    .form-group-custom {
        margin-bottom: 18px;
    }

    .form-label-custom {
        font-size: 14px;
        font-weight: 500;
        color: #334155;
        margin-bottom: 6px;
    }

    .form-control-custom {
        border-radius: 8px;
        height: 46px;
        border: 1.5px solid #d1d5db;
        background-color: #ffffff;
        font-size: 14px;
    }

    .btn-login-submit {
        height: 46px;
        border-radius: 8px;
        font-size: 15px;
        font-weight: 500;
        margin-top: 8px;
        margin-bottom: 18px;
        box-shadow: 0 4px 14px rgba(23, 113, 184, 0.22);
    }

    .register-prompt {
        font-size: 13.5px;
        color: #64748b;
        text-align: center;
    }

    .register-prompt a {
        color: var(--brand-primary);
        font-weight: 600;
    }

    .copyright-footer {
        display: none !important;
    }
}