/* ============================================================
   卡密代理系统 · 登录页样式
   风格：二次元炫酷 · 深色霓虹
   ============================================================ */

.login-body {
    min-height: 100vh;
    display: grid;
    grid-template-columns: 1fr 1fr;
    background-color: #0b0d14;
    background-image:
        radial-gradient(800px 440px at 85% -8%, rgba(139, 92, 246, .14), transparent 60%),
        radial-gradient(600px 400px at 105% 110%, rgba(236, 72, 153, .10), transparent 60%),
        linear-gradient(to right, rgba(139, 92, 246, .05) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(139, 92, 246, .05) 1px, transparent 1px);
    background-size: 100% 100%, 100% 100%, 28px 28px, 28px 28px;
}

/* 左侧品牌区 */
.login-brand {
    background:
        radial-gradient(640px 420px at -8% -12%, rgba(139, 92, 246, .30), transparent 60%),
        radial-gradient(520px 520px at 112% 112%, rgba(236, 72, 153, .24), transparent 62%),
        linear-gradient(180deg, #0e1018 0%, #0a0c12 100%);
    color: #fff;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 48px 52px;
    position: relative;
    overflow: hidden;
}
.login-brand::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(to right, rgba(139, 92, 246, .07) 1px, transparent 1px),
        linear-gradient(to bottom, rgba(139, 92, 246, .07) 1px, transparent 1px);
    background-size: 34px 34px;
    pointer-events: none;
}
.login-brand::after {
    content: "";
    position: absolute;
    right: -140px;
    bottom: -140px;
    width: 440px;
    height: 440px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(236, 72, 153, .30), transparent 68%);
}
.login-brand .brand-top { display: flex; align-items: center; gap: 11px; position: relative; z-index: 1; }
.login-brand .mark {
    width: 34px; height: 34px; border-radius: 8px;
    background: var(--grad);
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 4px 16px rgba(139, 92, 246, .55);
}
.login-brand .mark svg { width: 19px; height: 19px; }
.login-brand .bname { font-size: 17px; font-weight: 600; letter-spacing: .5px; }
.login-brand .bsub { font-size: 11px; color: var(--sidebar-text); letter-spacing: 2px; font-family: var(--font-mono); }

.login-brand .brand-mid { position: relative; z-index: 1; max-width: 420px; }
.login-brand .brand-mid h2 { font-size: 30px; font-weight: 650; line-height: 1.35; margin: 0 0 14px; letter-spacing: -.3px; }
.login-brand .brand-mid p { font-size: 14.5px; color: var(--sidebar-text); line-height: 1.8; margin: 0; }

/* 终端风格卡密演示 */
.term {
    margin-top: 34px;
    background: rgba(8, 9, 14, .8);
    border: 1px solid rgba(139, 92, 246, .22);
    border-radius: 10px;
    overflow: hidden;
    font-family: var(--font-mono);
    font-size: 12.5px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .4);
}
.term .term-head {
    display: flex; align-items: center; gap: 6px;
    padding: 9px 12px; border-bottom: 1px solid rgba(139, 92, 246, .16);
    background: rgba(139, 92, 246, .05);
}
.term .term-head .c { width: 10px; height: 10px; border-radius: 50%; }
.term .term-head .c.r { background: #f43f5e; box-shadow: 0 0 8px rgba(244, 63, 94, .7); }
.term .term-head .c.y { background: #fbbf24; box-shadow: 0 0 8px rgba(251, 191, 36, .7); }
.term .term-head .c.g { background: #34d399; box-shadow: 0 0 8px rgba(52, 211, 153, .7); }
.term .term-head .ttl { margin-left: 8px; color: #7d8598; font-size: 11px; }
.term .term-body { padding: 14px 16px; color: #9aa3b8; line-height: 2; }
.term .term-body .g { color: #34d399; }
.term .term-body .k { color: #67e8f9; }
.term .term-body .cursor { display: inline-block; width: 8px; height: 15px; background: var(--accent); vertical-align: -2px; box-shadow: 0 0 8px rgba(139, 92, 246, .8); animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }

.login-brand .brand-foot { position: relative; z-index: 1; font-size: 12px; color: #565e70; }

/* 右侧表单区 */
.login-form { display: flex; align-items: center; justify-content: center; padding: 40px; }
.login-card { width: 100%; max-width: 380px; }
.login-card h1 { font-size: 22px; font-weight: 650; margin: 0 0 6px; letter-spacing: -.3px; color: #fff; }
.login-card .sub { font-size: 13.5px; color: var(--muted); margin: 0 0 28px; }

/* 角色切换 */
.role-switch {
    display: flex;
    background: rgba(15, 17, 26, .8);
    border: 1px solid #232838;
    border-radius: var(--r-sm);
    padding: 3px;
    margin-bottom: 24px;
}
.role-switch button {
    flex: 1;
    height: 36px;
    border: none;
    background: transparent;
    border-radius: 5px;
    font-size: 13.5px;
    font-weight: 500;
    color: var(--muted);
    cursor: pointer;
    transition: all .15s ease;
    font-family: var(--font-sans);
}
.role-switch button.active {
    background: var(--grad);
    color: #fff;
    box-shadow: 0 2px 10px rgba(139, 92, 246, .4);
}

.login-card .field + .field { margin-top: 16px; }
.login-card .field label { color: #d8dce8; }
.login-card .submit { width: 100%; margin-top: 24px; height: 44px; font-size: 15px; }
.login-card .login-error { min-height: 20px; margin-top: 14px; font-size: 13px; color: #fb7185; }
.login-card .login-tip { margin-top: 22px; font-size: 12px; color: #565e70; text-align: center; }

@media (max-width: 820px) {
    .login-body { grid-template-columns: 1fr; }
    .login-brand { display: none; }
}
