* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
}

body,
button,
input {
    font-family:
        "Noto Sans Thai",
        "Segoe UI",
        Arial,
        sans-serif;
}

.login-page {
    min-height: 100vh;

    color: #183b59;

    background:
        radial-gradient(
            circle at 50% 0,
            rgba(38, 132, 198, .25),
            transparent 35%
        ),
        linear-gradient(
            135deg,
            #0b3153,
            #164f7d 55%,
            #0b3153
        );
}

.login-stage {
    min-height: 100vh;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 24px 16px;
}

.login-card {
    width: min(580px, 100%);

    overflow: hidden;

    border: 1px solid rgba(213, 233, 247, .85);
    border-radius: 14px;

    background: #fff;

    box-shadow:
        0 24px 70px rgba(0, 21, 42, .34);
}

/* HEADER */

.login-brand {
    position: relative;

    padding: 18px 22px 16px;

    color: #fff;

    background:
        linear-gradient(
            135deg,
            #164675,
            #1764a1
        );

    border-bottom: 3px solid #f3be2c;
}

.login-brand::after {
    content: "";

    position: absolute;

    width: 370px;
    height: 180px;

    right: -150px;
    top: -100px;

    border: 2px solid rgba(72, 189, 246, .16);
    border-radius: 50%;
}

.language-switch {
    position: absolute;
    z-index: 5;

    top: 13px;
    right: 14px;

    display: flex;

    padding: 3px;

    border-radius: 9px;

    background: #f6f9fc;
}

.language-switch button {
    width: 37px;
    height: 30px;

    padding: 0;

    border: 0;
    border-radius: 6px;

    cursor: pointer;

    color: #6c8093;
    background: transparent;

    font-size: 11px;
    font-weight: 800;
}

.language-switch button.is-active {
    color: #fff;
    background: #185487;
}

.brand-main {
    position: relative;
    z-index: 2;

    display: flex;
    align-items: center;

    min-height: 122px;

    padding-right: 72px;
}

.brand-logo {
    flex: 0 0 auto;

    display: block;

    width: 118px;
    height: 118px;

    object-fit: cover;

    border-radius: 10px;

    box-shadow:
        0 6px 18px rgba(0, 18, 37, .28);
}

.brand-product {
    min-width: 0;

    margin-left: 18px;
}

.brand-kicker {
    margin-bottom: 5px;

    color: #c2ddf0;

    font-size: 8px;
    font-weight: 800;

    letter-spacing: 1px;
}

.brand-product h1 {
    margin: 0;

    color: #fff;

    font-size: 25px;
    line-height: 1.1;

    font-weight: 900;
}

.brand-product p {
    margin: 6px 0 0;

    color: #ffd24f;

    font-size: 12px;
    font-weight: 800;
}

.brand-modules {
    display: flex;
    flex-wrap: wrap;

    gap: 5px;

    margin-top: 12px;
}

.brand-modules span {
    padding: 4px 8px;

    border: 1px solid rgba(215, 237, 251, .25);
    border-radius: 6px;

    color: #d5e9f7;
    background: rgba(255,255,255,.08);

    font-size: 9px;
}

/* CONTENT */

.login-content {
    padding: 25px 36px 21px;
}

.login-heading {
    text-align: center;
}

.login-heading h2 {
    margin: 0;

    color: #163953;

    font-size: 25px;
    line-height: 1.2;

    font-weight: 900;
}

.login-heading p {
    margin: 5px 0 0;

    color: #8095a7;

    font-size: 11px;
}

.login-error {
    margin-top: 15px;
    padding: 9px 11px;

    border: 1px solid #eab5b5;
    border-radius: 7px;

    color: #9b3030;
    background: #fff3f3;

    font-size: 11px;
}

.login-form {
    margin-top: 18px;
}

.login-form label {
    display: block;

    margin: 10px 0 4px;

    color: #1d405c;

    font-size: 11px;
    font-weight: 800;
}

.login-control {
    position: relative;
}

.login-control input {
    width: 100%;
    height: 47px;

    padding: 0 68px 0 43px;

    border: 1px solid #bdd0df;
    border-radius: 8px;

    outline: none;

    color: #203b51;
    background: #fff;

    font-size: 13px;
}

.login-control input:focus {
    border-color: #278fd2;

    box-shadow:
        0 0 0 3px rgba(39, 143, 210, .11);
}

.login-control input::placeholder {
    color: #9babb8;
}

.control-icon {
    position: absolute;

    left: 13px;
    top: 50%;

    width: 18px;
    height: 18px;

    transform: translateY(-50%);

    color: #8aa9be;
}

.control-icon svg {
    width: 100%;
    height: 100%;

    fill: none;
    stroke: currentColor;

    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.password-toggle {
    position: absolute;

    right: 10px;
    top: 50%;

    transform: translateY(-50%);

    padding: 5px;

    border: 0;

    cursor: pointer;

    color: #1378b9;
    background: transparent;

    font-size: 10px;
    font-weight: 900;
}

.login-submit {
    width: 100%;
    height: 49px;

    margin-top: 18px;

    border: 0;
    border-bottom: 3px solid #f3be2c;
    border-radius: 8px;

    cursor: pointer;

    color: #fff;

    background:
        linear-gradient(
            180deg,
            #287fc0,
            #175b91
        );

    font-size: 15px;
    font-weight: 900;
}

.login-authorized {
    display: flex;
    align-items: center;
    justify-content: center;

    gap: 7px;

    margin-top: 19px;

    color: #72899c;

    font-size: 9px;
}

.status-dot {
    width: 8px;
    height: 8px;

    border-radius: 50%;

    background: #20b77e;

    box-shadow:
        0 0 0 4px rgba(32, 183, 126, .12);
}

.login-footer {
    margin-top: 10px;

    text-align: center;

    color: #6f8799;

    font-size: 9px;
    font-weight: 700;
}

.login-footer small {
    display: block;

    margin-top: 3px;

    color: #2486bd;

    font-size: 7px;
    font-weight: 900;

    letter-spacing: 1.1px;
}

/* MOBILE */

@media (max-width: 560px) {

    .login-stage {
        padding: 12px;
        align-items: flex-start;
    }

    .brand-main {
        padding-top: 35px;
        padding-right: 0;
    }

    .brand-logo {
        width: 92px;
        height: 92px;
    }

    .brand-product {
        margin-left: 13px;
    }

    .brand-product h1 {
        font-size: 20px;
    }

    .login-content {
        padding: 22px 20px 20px;
    }
}

/* ==========================================================================
   R1F5 — TRANSPARENT AUTHORITATIVE AOMTANG LOGO
   ========================================================================== */

.brand-logo {
    width: 128px;
    height: 128px;

    object-fit: contain;

    padding: 0;

    border: 0;
    border-radius: 0;

    background: transparent;

    box-shadow: none;
}

/* ==========================================================================
   R1F6 — SHARP / PROMINENT AOMTANG LOGO
   ========================================================================== */

.brand-main {
    min-height: 170px;
}

.brand-logo {
    width: 170px;
    height: 170px;

    flex: 0 0 170px;

    object-fit: contain;

    padding: 0;
    border: 0;
    border-radius: 0;

    background: transparent;
    box-shadow: none;

    filter:
        drop-shadow(0 3px 5px rgba(0, 20, 45, .30))
        drop-shadow(0 0 8px rgba(34, 174, 239, .20));
}

.brand-product {
    margin-left: 20px;
}

@media (max-width: 560px) {
    .brand-logo {
        width: 125px;
        height: 125px;
        flex-basis: 125px;
    }

    .brand-main {
        min-height: 125px;
    }
}
