:root {
    --login-blue: #2f8ff1;
    --login-blue-dark: #1774d6;
    --login-ink: #182235;
    --login-subtle: #8b97a8;
    --login-border: #e6eaf0;
}

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

* { box-sizing: border-box; }

body {
    min-height: 100vh;
    min-height: 100svh;
    overflow: hidden;
    color: var(--login-ink);
    background: #061d4d center / cover no-repeat fixed;
    font-family: Inter, "PingFang SC", "Microsoft YaHei", sans-serif;
    -webkit-font-smoothing: antialiased;
}

body::before {
    position: fixed;
    z-index: 0;
    inset: 0;
    background:
        radial-gradient(circle at 50% 46%, rgba(0, 126, 255, .22), transparent 36%),
        linear-gradient(180deg, rgba(2, 20, 58, .2), rgba(2, 16, 49, .58));
    pointer-events: none;
    content: "";
}

body::after {
    position: fixed;
    z-index: 0;
    inset: 0;
    background-image: radial-gradient(circle, rgba(91, 175, 255, .48) 0 1px, transparent 1.5px);
    background-position: 0 0;
    background-size: 112px 94px;
    opacity: .12;
    pointer-events: none;
    content: "";
}

.layui-hide { display: none !important; }

.login-shell {
    position: relative;
    z-index: 1;
    display: grid;
    min-height: 100vh;
    min-height: 100svh;
    grid-template-rows: 1fr auto;
}

.login-stage {
    display: grid;
    width: 100%;
    padding: 54px 40px 28px;
    align-items: center;
    justify-items: center;
}

.login-card {
    display: grid;
    width: min(1120px, 100%);
    min-height: 620px;
    overflow: hidden;
    border-radius: 10px;
    background: #fff;
    box-shadow: 0 28px 80px rgba(0, 13, 43, .4), 0 4px 18px rgba(0, 14, 46, .18);
    grid-template-columns: 1fr 1fr;
}

.login-visual {
    position: relative;
    min-width: 0;
    overflow: hidden;
    color: #fff;
    background-color: #123d86;
    background-image: var(--login-background-image, linear-gradient(135deg, #123d86, #0bb5eb));
    background-position: center 18%;
    background-size: auto 155%;
}

.login-visual::before {
    position: absolute;
    z-index: 0;
    inset: 0;
    background: linear-gradient(135deg, rgba(4, 30, 78, .96), rgba(7, 91, 173, .86) 55%, rgba(3, 24, 65, .96));
    content: "";
}

.login-visual::after {
    position: absolute;
    z-index: 0;
    right: -150px;
    bottom: -180px;
    width: 580px;
    height: 580px;
    border: 1px solid rgba(142, 221, 255, .22);
    border-radius: 50%;
    box-shadow: 0 0 0 26px rgba(35, 178, 255, .05), 0 0 0 52px rgba(35, 178, 255, .04);
    content: "";
}

.visual-overlay { position: absolute; z-index: 1; inset: 0; background: linear-gradient(90deg, rgba(4, 24, 66, .34), rgba(4, 40, 94, .16)); backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px); }
.visual-content { position: relative; z-index: 2; display: flex; height: 100%; min-height: 620px; padding: 46px 56px 43px; flex-direction: column; }

.visual-brand { display: flex; align-items: center; gap: 13px; }
.brand-mark { display: grid; width: 47px; height: 47px; flex: 0 0 47px; place-items: center; }
.brand-mark img { display: block; width: 47px; height: 47px; object-fit: contain; filter: drop-shadow(0 4px 10px rgba(0,0,0,.15)); }
.brand-copy { display: flex; min-width: 0; flex-direction: column; gap: 4px; }
.brand-copy strong { overflow: hidden; color: #fff; font-size: 18px; font-weight: 700; line-height: 1.2; text-overflow: ellipsis; white-space: nowrap; }
.brand-copy span { color: rgba(229, 247, 255, .75); font-size: 11px; letter-spacing: .1em; }

.visual-utility { display: flex; margin-top: 62px; padding-left: 16px; border-left: 2px solid rgba(126, 231, 255, .8); flex-direction: column; gap: 7px; }
.visual-utility span { color: #8ceaff; font-size: 9px; font-weight: 700; letter-spacing: .2em; }
.visual-utility strong { color: rgba(244, 252, 255, .92); font-size: 16px; font-weight: 500; letter-spacing: .04em; }

.visual-copy { margin-top: 52px; margin-bottom: 0; padding: 0; }
.visual-copy h1 { margin: 22px 0 16px; color: #fff; font-family: "Source Han Sans SC", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif; font-size: clamp(36px, 3vw, 46px); font-weight: 600; letter-spacing: .015em; line-height: 1.34; text-shadow: 0 4px 22px rgba(0, 23, 72, .24); }
.visual-copy h1 em { display: block; color: #b9edff; font-style: normal; white-space: nowrap; }
.visual-copy p { margin: 0; color: rgba(232, 246, 255, .82); font-size: 14px; letter-spacing: .05em; }

.visual-assurance { display: flex; margin-top: 64px; padding-top: 18px; border-top: 1px solid rgba(195, 239, 255, .24); align-items: center; gap: 26px; }
.visual-assurance span { display: inline-flex; align-items: center; gap: 7px; color: rgba(228, 247, 255, .78); font-size: 11px; white-space: nowrap; }
.visual-assurance i { color: #8eeaff; font-size: 12px; }

.login-panel { display: flex; min-width: 0; padding: 76px 58px 45px; flex-direction: column; background: #fff; }
.panel-heading { width: min(100%, 450px); margin: auto auto 38px; }
.panel-heading h1 { margin: 0; color: #152137; font-size: 37px; font-weight: 600; letter-spacing: -.045em; line-height: 1.25; }
.panel-heading p { margin: 12px 0 0; color: #b5becb; font-size: 15px; }
.login-bottom { width: min(100%, 450px); margin: 0 auto; }

.center .item { position: relative; display: flex; width: 100%; height: 66px; margin-bottom: 16px; padding: 0 17px; align-items: center; border: 1px solid var(--login-border); border-radius: 3px; background: #f7f8fa; transition: border-color .18s ease, box-shadow .18s ease, background .18s ease; }
.center .item:focus-within { border-color: #83bbf3; background: #fff; box-shadow: 0 0 0 3px rgba(47, 143, 241, .1); }
.field-icon { display: grid; width: 22px; height: 22px; margin-right: 12px; flex: 0 0 22px; color: #7c899b; place-items: center; }
.field-icon svg { width: 20px; height: 20px; }
.field-content { display: flex; min-width: 0; flex: 1; flex-direction: column; gap: 3px; }
.field-label { color: #929dae; font-size: 12px; line-height: 1.15; }
.field-content input { width: 100%; height: 21px; padding: 0; border: 0; outline: 0; color: #26364d; background: transparent; font: inherit; font-size: 15px; line-height: 21px; }
.field-content input::placeholder { color: #aab4c1; }
.bind-password { position: relative; display: grid; width: 24px; height: 24px; margin-left: 8px; flex: 0 0 24px; cursor: pointer; place-items: center; }
.bind-password::before { width: 16px; height: 10px; border: 1.6px solid #93a0b0; border-radius: 11px 11px 9px 9px; content: ""; transform: rotate(-8deg); }
.bind-password::after { position: absolute; width: 2px; height: 19px; border-radius: 2px; background: #93a0b0; content: ""; transform: rotate(45deg); }
.bind-password.icon-5::after { display: none; }
.captcha-item { padding-right: 8px !important; }
.captcha-item .validateImg { width: 106px; height: 40px; margin-left: 10px; flex: 0 0 106px; border-radius: 3px; object-fit: cover; cursor: pointer; }

.tip { display: flex; min-height: 30px; align-items: center; justify-content: space-between; color: #99a4b3; font-size: 12px; }
.remember-wrap, .help-wrap { position: relative; display: inline-flex; align-items: center; }
.icon-nocheck { display: inline-grid; width: 15px; height: 15px; margin-right: 7px; border: 1px solid #cbd3de; border-radius: 2px; background: #fff; cursor: pointer; place-items: center; }
.icon-nocheck.icon-check { border-color: var(--login-blue); background: var(--login-blue); }
.icon-nocheck.icon-check::after { width: 7px; height: 4px; border-bottom: 2px solid #fff; border-left: 2px solid #fff; content: ""; transform: rotate(-45deg) translate(1px, -1px); }
.login-tip { cursor: pointer; }
.forget-password { padding: 0; border: 0; color: var(--login-blue); background: transparent; font: inherit; cursor: pointer; }
.forget-password:hover { color: var(--login-blue-dark); }

.login-help-popover { position: absolute; right: -10px; bottom: 31px; display: none; width: 258px; padding: 14px; border: 1px solid #e2e8f1; border-radius: 7px; background: #fff; box-shadow: 0 14px 32px rgba(33, 50, 78, .16); }
.help-wrap.open .login-help-popover { display: flex; flex-direction: column; gap: 11px; }
.help-popover-arrow { position: absolute; right: 18px; bottom: -6px; width: 10px; height: 10px; border-right: 1px solid #e2e8f1; border-bottom: 1px solid #e2e8f1; background: #fff; transform: rotate(45deg); }
.help-popover-title { color: #25334b; font-size: 12px; font-weight: 700; }
.help-popover-title i { margin-right: 5px; color: var(--login-blue); }
.help-popover-item { display: flex; flex-direction: column; gap: 3px; }
.help-popover-item b { color: #35445b; font-size: 12px; font-weight: 600; }
.help-popover-item small { color: #8b98aa; font-size: 11px; }
.help-popover-close { align-self: flex-start; padding: 0; border: 0; color: var(--login-blue); background: transparent; font-size: 11px; cursor: pointer; }

.login-action { margin: 25px 0 0 !important; }
.login-btn { display: flex; width: 100%; min-height: 56px; padding: 0 18px; align-items: center; justify-content: center; gap: 10px; border: 0; border-radius: 2px; color: #fff; background: var(--login-blue); box-shadow: 0 7px 15px rgba(47, 143, 241, .2); font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; transition: background .18s ease, box-shadow .18s ease, transform .18s ease; }
.login-btn:hover { background: var(--login-blue-dark); box-shadow: 0 9px 20px rgba(47, 143, 241, .28); transform: translateY(-1px); }
.login-btn:active { transform: translateY(0); }
.login-btn:disabled { opacity: .7; cursor: wait; transform: none; }
.panel-foot { display: flex; margin: auto auto 0; padding-top: 25px; align-items: center; justify-content: center; gap: 6px; color: #bdc6d1; font-size: 11px; }
.panel-foot i { color: #45bd91; }

.footer { width: fit-content; max-width: calc(100% - 48px); margin: 0 auto 12px; padding: 8px 18px 9px; border: 1px solid rgba(174, 222, 255, .18); border-radius: 999px; color: rgba(236, 248, 255, .9); background: rgba(2, 18, 53, .72); font-size: 11px; line-height: 1.5; text-align: center; text-shadow: 0 1px 3px rgba(0, 0, 0, .32); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.footer a { color: inherit; text-decoration: none; }
.footer a:hover { color: #fff; }
.padding-5 { padding: 0 7px; }

.layui-layer.login-status-toast { min-width: 280px; border: 1px solid rgba(255, 255, 255, .2); border-radius: 8px; background: rgba(16, 32, 58, .95); box-shadow: 0 14px 32px rgba(10, 22, 44, .22); }
.layui-layer.login-status-toast .layui-layer-content { display: flex; min-height: 62px; padding: 14px 18px 14px 58px !important; align-items: center; }
.layui-layer.login-status-toast .layui-layer-face { top: 50% !important; left: 20px !important; display: grid; width: 27px; height: 27px; margin-top: -14px; border: 1px solid currentColor; border-radius: 50%; font-size: 16px !important; line-height: 27px !important; background: rgba(255,255,255,.05); place-items: center; }
.layui-layer.login-status-success .layui-layer-face { color: #55d3a5 !important; }
.layui-layer.login-status-error .layui-layer-face { color: #ff8395 !important; }
.login-toast-copy { display: flex; min-width: 0; flex-direction: column; gap: 3px; }
.login-toast-copy strong { overflow: hidden; color: #fff; font-size: 14px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.login-toast-copy span { color: #aebbd0; font-size: 11px; }

@media (max-width: 900px) {
    .login-stage { padding: 36px 24px 24px; }
    .login-card { width: min(760px, 100%); min-height: 0; grid-template-columns: 43% 57%; }
    .visual-content { min-height: 560px; padding: 36px 35px 32px; }
    .visual-copy h1 { font-size: 38px; }
    .visual-features { flex-direction: column; align-items: flex-start; gap: 10px; }
    .login-panel { padding: 54px 40px 35px; }
}

@media (max-width: 640px) {
    html, body { height: auto; }
    body { overflow-x: hidden; overflow-y: auto; background-attachment: scroll; }
    .login-shell { min-height: 100svh; }
    .login-stage { padding: 22px 14px 20px; }
    .login-card { display: block; width: min(440px, 100%); border-radius: 8px; }
    .login-visual { min-height: 260px; }
    .visual-content { min-height: 260px; padding: 25px 25px 22px; }
    .brand-mark, .brand-mark img { width: 38px; height: 38px; }
    .brand-mark { flex-basis: 38px; }
    .brand-copy strong { font-size: 16px; }
    .visual-copy { margin-top: 28px; padding: 0; }
    .visual-utility { margin-top: 28px; padding-left: 11px; }
    .visual-utility strong { font-size: 14px; }
    .visual-copy h1 { margin: 12px 0 8px; font-size: 29px; }
    .visual-copy p { font-size: 12px; }
    .visual-assurance { display: none; }
    .login-panel { padding: 31px 25px 25px; }
    .panel-heading { margin-bottom: 26px; }
    .panel-heading h1 { font-size: 27px; }
    .panel-heading p { font-size: 13px; }
    .panel-foot { padding-top: 22px; }
    .footer { padding-bottom: 16px; }
}

@media (prefers-reduced-motion: reduce) {
    .center .item, .login-btn { transition: none; }
}
