/* หน้าเข้าสู่ระบบ: การ์ดกลางจอแบ่งสองฝั่ง ซ้ายภาพประกอบพร้อมข้อความ ขวาฟอร์มช่องกรอกแบบเส้นใต้ ปุ่มแคปซูล
   ภาพประกอบ (.login-art) เป็น SVG ชั่วคราวจนกว่าจะมีโลโก้และรูปของ go */

body,
button,
input,
.button,
.input {
    font-family: 'Anuphan', system-ui, sans-serif;
}

.login-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 24px;
    background: radial-gradient(circle at 50% 45%, #eef3f1 0%, #d5dfdb 70%, #c9d4d0 100%);
}

.login-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: min(880px, 100%);
    min-height: 520px;
    overflow: hidden;
    background: #fff;
    box-shadow: 0 30px 60px rgba(25, 45, 40, .22);
}

/* ฝั่งซ้าย: พื้นเขียวอ่อน ภาพกลาง ข้อความขาวด้านล่าง */
.login-panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1.75rem;
    padding: 3rem 2.5rem 2.5rem;
    background: #8fb7ab;
    color: #fff;
    text-align: center;
}

/* คำว่า GO สีเขียว (favicon.svg) ในวงกลมพื้นอ่อน */
.login-art {
    display: flex;
    align-items: center;
    justify-content: center;
    width: min(220px, 70%);
    aspect-ratio: 1;
    border-radius: 50%;
    background: #e6f2ef;
    box-shadow: 0 0 0 14px rgba(230, 242, 239, .35);
}

.login-art img {
    width: 62%;
    height: auto;
}

.login-panel h2 {
    font-size: 1.375rem;
    font-weight: 600;
    line-height: 1.35;
}

.login-panel p {
    max-width: 20rem;
    margin-top: .35rem;
    font-size: .875rem;
    line-height: 1.55;
    opacity: .92;
}

/* ฝั่งขวา: ชื่อระบบด้านบน หัวข้อ ฟอร์ม และลิงก์ด้านล่าง */
.login-side {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2.75rem 3rem 2rem;
}

/* โลโก้ = คำว่า GO ฟอนต์ Poppins Medium 500 */
.login-brand {
    color: #0B6E5F;
    font-family: 'Poppins', sans-serif;
    font-size: 2.25rem;
    font-weight: 500;
    letter-spacing: .02em;
    line-height: 1;
}

.login-welcome {
    margin: 2.5rem 0 1.75rem;
    color: #6b7672;
    font-size: 1.25rem;
    font-weight: 500;
}

.login-form {
    width: 100%;
    max-width: 300px;
}

.login-form .field {
    margin-bottom: 1.25rem;
}

.login-form .label {
    margin-bottom: .1rem;
    color: #8a9390;
    font-size: .75rem;
    font-weight: 500;
}

/* ช่องกรอกเส้นใต้ ไม่มีกรอบ ตอนพิมพ์เส้นเป็นสีเขียว */
.login-form .input {
    height: 2.4rem;
    padding: 0 2rem 0 0;
    border: 0;
    border-bottom: 1px solid #d5dbd9;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: #2b2f2e;
    font-size: 1rem;
}

.login-form .input:focus {
    border-bottom-color: #0B6E5F;
    box-shadow: 0 1px 0 #0B6E5F;
}

.login-password {
    position: relative;
}

.login-password button {
    position: absolute;
    right: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2.4rem;
    padding: 0;
    border: 0;
    background: none;
    color: #8a9390;
    cursor: pointer;
}

.login-password button:hover {
    color: #0B6E5F;
}

/* จองความสูงของ Turnstile ไว้ก่อนโหลด ปุ่มจะได้ไม่ขยับ */
.turnstile-field {
    display: flex;
    justify-content: center;
    min-height: 65px;
}

/* Turnstile เป็น iframe ของ Cloudflare แต่งข้างในไม่ได้ จึงตัดมุมให้โค้งแบบ room
   แล้ววาดขอบสีเดียวกับช่องกรอกทับขอบเดิมที่ถูกตัดตรงมุม */
.cf-turnstile {
    position: relative;
    border-radius: 10px;
    overflow: hidden;
    line-height: 0;
}

.cf-turnstile:not(:empty)::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 1px solid #dbdbdb;
    border-radius: 10px;
    pointer-events: none;
}

.login-submit {
    display: flex;
    justify-content: center;
    margin-top: 1.75rem;
}

.login-submit .button {
    min-width: 10rem;
    height: 2.6rem;
    border: 0;
    border-radius: 999px;
    background: #0B6E5F;
    color: #fff;
    font-weight: 600;
}

.login-submit .button:hover {
    background: #08584C;
    color: #fff;
}

.login-submit .button:focus:not(:active) {
    box-shadow: 0 0 0 .125em rgba(11, 110, 95, .25);
}

.login-submit .button.is-loading::after {
    border-color: transparent transparent #fff #fff !important;
}

.login-error {
    margin-bottom: 1.25rem;
    padding: .6rem .9rem;
    border-radius: 10px;
    background: #fdeeee;
    color: #b3261e;
    font-size: .8125rem;
}

.login-note {
    margin-top: auto;
    padding-top: 2rem;
    color: #6b7672;
    font-size: .8125rem;
    text-align: center;
}

.login-note a {
    border-bottom: 1px solid #b9d6ce;
    color: #0B6E5F;
}

/* มือถือ: ซ่อนภาพประกอบ เหลือฟอร์มเต็มการ์ด */
@media screen and (max-width: 768px) {
    .login-page {
        align-items: stretch;
        padding: 12px;
    }

    .login-card {
        grid-template-columns: 1fr;
        min-height: 0;
        border-radius: 16px;
    }

    .login-panel {
        flex-direction: row;
        gap: 1rem;
        padding: 1.1rem 1.25rem;
        text-align: left;
    }

    .login-art {
        width: 64px;
        flex: none;
        box-shadow: none;
    }

    .login-panel h2 {
        font-size: 1rem;
    }

    .login-panel p {
        display: none;
    }

    .login-side {
        padding: 2rem 1.5rem 1.5rem;
    }

    .login-welcome {
        margin: 1.5rem 0 1.25rem;
    }
}
