/* ============================================================
   登录页
   ============================================================ */

.login-theme {
    position: fixed;
    top: 20px;
    right: 24px;
    z-index: 30;
    background: var(--surface);
}

.login-shell {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    min-height: 100vh;
}

/* ---------- 左侧品牌区 ---------- */

.brand-side {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 34px;
    padding: 64px clamp(32px, 6vw, 92px);
    border-right: 1px solid var(--line-soft);
    overflow: hidden;
}

.brand-side::after {
    content: "";
    position: absolute;
    right: -120px;
    top: 50%;
    width: 420px;
    height: 420px;
    transform: translateY(-50%);
    border: 1px solid rgba(var(--accent-rgb), 0.12);
    border-radius: 50%;
    box-shadow: inset 0 0 60px -20px rgba(var(--accent-rgb), 0.35);
    pointer-events: none;
}

.brand-side::before {
    content: "";
    position: absolute;
    right: -60px;
    top: 50%;
    width: 240px;
    height: 240px;
    transform: translateY(-50%);
    border: 1px dashed rgba(var(--accent-2-rgb), 0.22);
    border-radius: 50%;
    animation: orbit 26s linear infinite;
    pointer-events: none;
}

@keyframes orbit {
    to {
        transform: translateY(-50%) rotate(360deg);
    }
}

.brand-mark {
    display: flex;
    align-items: center;
    gap: 13px;
}

.brand-name {
    font-size: 16px;
    font-weight: 650;
    letter-spacing: 0.01em;
}

.brand-sub {
    font-family: var(--mono);
    font-size: 10px;
    letter-spacing: 0.18em;
    color: var(--text-3);
    margin-top: 2px;
}

.brand-copy h1 {
    font-size: clamp(28px, 3.4vw, 42px);
    line-height: 1.22;
    letter-spacing: -0.02em;
    margin-bottom: 16px;
}

.brand-copy p {
    max-width: 440px;
    margin: 0;
    font-size: 14px;
    line-height: 1.75;
    color: var(--text-2);
}

.feature-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 14px;
    max-width: 460px;
}

.feature-list li {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    padding: 12px 14px;
    border: 1px solid var(--line-soft);
    border-radius: 10px;
    background: linear-gradient(90deg, rgba(var(--accent-rgb), 0.055), rgba(var(--accent-rgb), 0));
}

.feature-list .idx {
    font-family: var(--mono);
    font-size: 11px;
    color: var(--accent);
    padding-top: 2px;
    opacity: 0.9;
}

.feature-list b {
    display: block;
    font-size: 13.5px;
    font-weight: 600;
    margin-bottom: 2px;
}

.feature-list em {
    font-style: normal;
    font-size: 12px;
    color: var(--text-3);
    line-height: 1.5;
}

.brand-foot {
    font-size: 11px;
    letter-spacing: 0.14em;
    color: var(--text-3);
}

/* ---------- 右侧表单 ---------- */

.form-side {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px 28px;
}

.form-card {
    width: 100%;
    max-width: 392px;
    padding: 34px 32px 26px;
    box-shadow: 0 40px 90px -50px rgba(var(--accent-rgb), 0.55);
}

.form-head {
    margin-bottom: 26px;
}

.form-head h2 {
    font-size: 22px;
    margin: 10px 0 6px;
    letter-spacing: -0.015em;
}

.form-head p {
    margin: 0;
    font-size: 12.5px;
}

.pwd-wrap {
    position: relative;
}

.pwd-wrap .input {
    padding-right: 42px;
}

.pwd-toggle {
    position: absolute;
    top: 50%;
    right: 8px;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border: 0;
    background: transparent;
    color: var(--text-3);
    cursor: pointer;
    border-radius: 6px;
    transition: color 0.16s ease;
}

.pwd-toggle:hover,
.pwd-toggle.is-on {
    color: var(--accent);
}

.login-submit {
    height: 42px;
    margin-top: 4px;
    font-size: 14px;
}

.form-error {
    margin-bottom: 14px;
    padding: 9px 12px;
    font-size: 12.5px;
    color: var(--danger);
    background: rgba(var(--danger-rgb), 0.1);
    border: 1px solid rgba(var(--danger-rgb), 0.3);
    border-left: 2px solid var(--danger);
    border-radius: 7px;
    animation: shake 0.32s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-4px); }
    75% { transform: translateX(4px); }
}

.form-foot {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 22px;
    padding-top: 16px;
    border-top: 1px solid var(--line-soft);
    font-size: 11.5px;
    color: var(--text-3);
}

.dot-line {
    flex: none;
    width: 16px;
    height: 1px;
    background: var(--line-strong);
}

/* ---------- 响应式 ---------- */

@media (max-width: 940px) {
    .login-shell {
        grid-template-columns: 1fr;
    }
    .brand-side {
        display: none;
    }
    .form-side {
        min-height: 100vh;
    }
    .form-card {
        max-width: 400px;
    }
    .form-side::before {
        content: "";
        position: absolute;
        top: 12vh;
        left: 50%;
        transform: translateX(-50%);
        width: 260px;
        height: 260px;
        border-radius: 50%;
        background: radial-gradient(circle, rgba(var(--accent-rgb), 0.16), transparent 68%);
        pointer-events: none;
    }
}

/* ---------- 浅色皮肤 ---------- */

html[data-theme="light"] .brand-side {
    border-right-color: var(--line);
}

html[data-theme="light"] .brand-side::after {
    border-color: rgba(29, 95, 216, 0.12);
    box-shadow: none;
    background: radial-gradient(circle at 30% 50%, rgba(29, 95, 216, 0.05), transparent 62%);
}

html[data-theme="light"] .brand-side::before {
    border-color: rgba(29, 95, 216, 0.16);
}

html[data-theme="light"] .feature-list li {
    border-color: var(--line);
    background: #fbfcfe;
}

html[data-theme="light"] .form-card {
    border-color: var(--line);
    box-shadow: 0 18px 50px -34px rgba(15, 27, 45, 0.4);
}

html[data-theme="light"] .form-card::before,
html[data-theme="light"] .form-card::after {
    opacity: 0.5;
}

html[data-theme="light"] .brand-copy h1 {
    color: var(--text-strong);
}

html[data-theme="light"] .form-side::before {
    background: radial-gradient(circle, rgba(29, 95, 216, 0.08), transparent 68%);
}
