/* ==========================================================================
   登录页 · 深空科技风 v5 (2026-11)
   独立于后台主题，只被 templates/login.html 引用。
   ========================================================================== */
* { margin: 0; padding: 0; box-sizing: border-box; }

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

body {
    font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
    background: #061126;
    color: #eaf1ff;
    -webkit-font-smoothing: antialiased;
}

.auth-shell {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background:
        radial-gradient(1100px 620px at 8% -10%, rgba(46, 96, 200, .30), transparent 62%),
        radial-gradient(900px 600px at 96% 8%, rgba(111, 64, 220, .24), transparent 60%),
        radial-gradient(800px 700px at 70% 108%, rgba(20, 160, 190, .16), transparent 62%),
        linear-gradient(160deg, #07142c 0%, #081a35 48%, #050d1f 100%);
}

/* ---------------- 背景装饰 ---------------- */
.auth-bg { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }

.bg-grid {
    position: absolute; inset: -20%;
    background-image:
        linear-gradient(rgba(140, 180, 255, .055) 1px, transparent 1px),
        linear-gradient(90deg, rgba(140, 180, 255, .055) 1px, transparent 1px);
    background-size: 58px 58px;
    -webkit-mask-image: radial-gradient(ellipse at 50% 40%, #000 12%, transparent 76%);
    mask-image: radial-gradient(ellipse at 50% 40%, #000 12%, transparent 76%);
    transform: perspective(900px) rotateX(14deg);
}

.orb { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .5; animation: float 14s ease-in-out infinite; }
.orb-one { width: 520px; height: 520px; top: -180px; left: -120px; background: #2b6bff; }
.orb-two { width: 420px; height: 420px; top: 12%; right: -130px; background: #7b46e8; animation-delay: -5s; }
.orb-three { width: 460px; height: 460px; bottom: -220px; left: 42%; background: #10b6c9; opacity: .28; animation-delay: -9s; }

.bg-beam {
    position: absolute; top: -30%; left: 26%; width: 140px; height: 160%;
    background: linear-gradient(180deg, transparent, rgba(96, 178, 255, .11), transparent);
    transform: rotate(24deg); filter: blur(12px);
    animation: drift 18s linear infinite;
}

.bg-ring {
    position: absolute; width: 640px; height: 640px; right: -190px; bottom: -300px;
    border: 1px solid rgba(120, 176, 255, .14); border-radius: 50%;
    box-shadow: 0 0 0 70px rgba(120, 176, 255, .025), 0 0 0 150px rgba(120, 176, 255, .018);
}

@keyframes float { 0%, 100% { transform: translate3d(0, 0, 0); } 50% { transform: translate3d(24px, -26px, 0); } }
@keyframes drift { 0% { transform: rotate(24deg) translateY(-8%); } 50% { transform: rotate(24deg) translateY(8%); } 100% { transform: rotate(24deg) translateY(-8%); } }
@keyframes pulse { 0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(52, 211, 153, .5); } 60% { opacity: .8; box-shadow: 0 0 0 8px rgba(52, 211, 153, 0); } }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }

/* ---------------- 顶部 ---------------- */
.auth-header {
    position: relative; z-index: 2;
    display: flex; align-items: center; justify-content: space-between;
    padding: 26px clamp(28px, 5vw, 76px) 8px;
    animation: rise .6s ease both;
}

.auth-brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: inherit; }
.brand-mark {
    width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center;
    font-size: 21px; color: #fff;
    background: linear-gradient(140deg, #3b82f6, #6d5bff 60%, #22d3ee);
    box-shadow: 0 10px 30px rgba(61, 106, 255, .45), inset 0 1px 0 rgba(255, 255, 255, .35);
}
.brand-text { display: flex; flex-direction: column; gap: 3px; }
.brand-text strong { font-size: 17px; font-weight: 650; letter-spacing: .6px; color: #f2f7ff; }
.brand-text small { font-size: 10px; letter-spacing: 2.1px; color: #7e93b8; }

.auth-header-right { display: flex; align-items: center; gap: 22px; font-size: 13px; color: #9db0d2; }
.auth-header-right a { color: #9db0d2; text-decoration: none; transition: color .2s; }
.auth-header-right a:hover { color: #6ee7f9; }
.live-chip {
    display: inline-flex; align-items: center; gap: 8px; padding: 7px 14px;
    border: 1px solid rgba(120, 170, 255, .22); border-radius: 999px;
    background: rgba(255, 255, 255, .045); font-size: 12px; color: #bcd0f0;
}
.live-chip i { width: 7px; height: 7px; border-radius: 50%; background: #34d399; animation: pulse 2.2s infinite; }

/* ---------------- 主区 ---------------- */
.auth-main {
    position: relative; z-index: 2; flex: 1;
    display: grid; grid-template-columns: minmax(0, 1.08fr) 452px;
    align-items: center; gap: clamp(40px, 6vw, 100px);
    padding: 34px clamp(28px, 7vw, 110px) 54px;
}

.auth-intro { animation: rise .7s .08s ease both; max-width: 680px; }
.intro-tag {
    display: inline-flex; align-items: center; gap: 9px;
    padding: 8px 16px; margin-bottom: 26px;
    border: 1px solid rgba(110, 190, 255, .28); border-radius: 999px;
    background: linear-gradient(90deg, rgba(46, 116, 255, .16), rgba(34, 211, 238, .08));
    color: #8fd8ff; font-size: 12px; letter-spacing: 1.2px;
}
.intro-tag i { color: #6ee7f9; }

.auth-intro h1 {
    font-size: clamp(38px, 4.1vw, 62px); line-height: 1.24; font-weight: 700;
    letter-spacing: 1px; color: #f4f8ff; text-shadow: 0 8px 40px rgba(20, 60, 140, .4);
}
.auth-intro h1 em {
    font-style: normal;
    background: linear-gradient(96deg, #6ee7f9 0%, #7aa8ff 46%, #b18cff 100%);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.intro-lead { margin-top: 20px; max-width: 560px; font-size: 14.5px; line-height: 2; color: #a2b4d3; }

.intro-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 34px 0 12px; }
.intro-stat {
    padding: 18px 16px; border-radius: 15px;
    border: 1px solid rgba(130, 170, 240, .16);
    background: linear-gradient(160deg, rgba(255, 255, 255, .065), rgba(255, 255, 255, .02));
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06);
    transition: transform .25s, border-color .25s;
}
.intro-stat:hover { transform: translateY(-4px); border-color: rgba(110, 210, 255, .45); }
.intro-stat b {
    display: block; font-size: 30px; font-weight: 700; letter-spacing: .5px;
    background: linear-gradient(180deg, #ffffff, #86c5ff);
    -webkit-background-clip: text; background-clip: text; color: transparent;
}
.intro-stat span { display: block; margin-top: 4px; font-size: 12px; color: #8fa4c6; }
.intro-source { display: flex; align-items: center; gap: 7px; font-size: 11.5px; color: #7089ad; }
.intro-source i { color: #4bb7d8; }

.feature-list { list-style: none; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px 22px; margin-top: 34px; }
.feature-list li { display: flex; align-items: center; gap: 13px; }
.feature-ico {
    flex: 0 0 42px; height: 42px; border-radius: 12px; display: grid; place-items: center;
    color: #8ad9ff; font-size: 16px;
    border: 1px solid rgba(110, 180, 255, .22);
    background: linear-gradient(145deg, rgba(58, 116, 220, .22), rgba(30, 60, 120, .12));
}
.feature-list b { display: block; font-size: 13.5px; font-weight: 600; color: #e2ecff; }
.feature-list small { display: block; margin-top: 3px; font-size: 11.5px; color: #7f94b6; }

/* ---------------- 登录卡片 ---------------- */
.auth-card {
    position: relative; animation: rise .7s .16s ease both;
    padding: 38px 38px 30px; border-radius: 24px;
    border: 1px solid rgba(128, 170, 255, .22);
    background: linear-gradient(158deg, rgba(23, 43, 79, .92), rgba(9, 20, 42, .95));
    box-shadow: 0 32px 90px rgba(0, 6, 24, .55), inset 0 1px 0 rgba(255, 255, 255, .08);
    backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px);
}
.card-glow {
    position: absolute; top: -1px; left: 16%; width: 68%; height: 2px;
    background: linear-gradient(90deg, transparent, #5cc8ff, #a78bfa, transparent);
    filter: blur(.4px); border-radius: 2px;
}
.card-head { text-align: center; margin-bottom: 26px; }
.card-icon {
    width: 58px; height: 58px; margin: 0 auto 14px; border-radius: 18px; display: grid; place-items: center;
    font-size: 22px; color: #fff;
    background: linear-gradient(140deg, #3b82f6, #7c5cff 65%, #22d3ee);
    box-shadow: 0 14px 34px rgba(72, 100, 255, .42), inset 0 1px 0 rgba(255, 255, 255, .35);
}
.card-head h2 { font-size: 24px; font-weight: 650; letter-spacing: 1.2px; color: #f3f7ff; }
.card-head p { margin-top: 6px; font-size: 12.5px; color: #8ba1c5; }

.auth-alert {
    padding: 11px 14px; margin-bottom: 16px; border-radius: 11px; font-size: 12.5px;
    color: #ffd3d3; border: 1px solid rgba(255, 108, 108, .32);
    background: rgba(255, 84, 84, .11);
}
.auth-alert::before { content: '\f071'; font-family: "Font Awesome 6 Free"; font-weight: 900; margin-right: 8px; }

.field { margin-bottom: 17px; }
.field > label { display: block; margin-bottom: 8px; font-size: 12.5px; font-weight: 500; color: #b7c8e6; letter-spacing: .4px; }
.control {
    display: flex; align-items: center; gap: 12px; height: 48px; padding: 0 15px;
    border: 1px solid rgba(132, 166, 225, .20); border-radius: 12px;
    background: rgba(4, 12, 28, .58); transition: border-color .2s, box-shadow .2s, background .2s;
}
.control:focus-within {
    border-color: rgba(94, 199, 255, .72); background: rgba(8, 20, 42, .78);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, .14), 0 0 24px rgba(56, 150, 255, .12) inset;
}
.control > i { width: 17px; text-align: center; font-size: 14px; color: #6f8ab6; }
.control:focus-within > i { color: #64d5ff; }
.control input, .control select {
    flex: 1; min-width: 0; height: 100%; border: 0; outline: none;
    background: transparent; color: #edf5ff; font-size: 14px;
    font-family: inherit;
}
.control input::placeholder { color: #667c9e; }
.control select { cursor: pointer; appearance: none; -webkit-appearance: none; padding-right: 20px; }
.control select option { background: #0d1b33; color: #eaf1ff; }
.select-control { position: relative; }
.select-control::after {
    content: '\f078'; font-family: "Font Awesome 6 Free"; font-weight: 900;
    position: absolute; right: 15px; font-size: 10px; color: #7089ae; pointer-events: none;
}
.field-hint { margin-top: 6px; font-size: 11px; line-height: 1.6; color: #7489aa; }

.login-btn {
    width: 100%; height: 50px; margin-top: 8px; padding: 0 20px;
    display: flex; align-items: center; justify-content: space-between;
    border: 0; border-radius: 12px; cursor: pointer;
    color: #fff; font-size: 15px; font-weight: 600; letter-spacing: 1.4px;
    font-family: inherit;
    background: linear-gradient(100deg, #2f7bff 0%, #6b5bff 52%, #16b8d8 100%);
    background-size: 180% 100%;
    box-shadow: 0 14px 34px rgba(64, 96, 255, .38), inset 0 1px 0 rgba(255, 255, 255, .28);
    transition: transform .2s, box-shadow .2s, background-position .4s;
}
.login-btn:hover:not(:disabled) { transform: translateY(-2px); background-position: 100% 0; box-shadow: 0 20px 42px rgba(64, 96, 255, .5); }
.login-btn:active:not(:disabled) { transform: translateY(0); }
.login-btn:disabled { opacity: .65; cursor: wait; }
.login-btn i:last-child { opacity: .9; font-size: 13px; }

.card-foot { margin-top: 22px; text-align: center; }
.card-foot a { color: #77d8ff; font-size: 13px; text-decoration: none; }
.card-foot a:hover { text-decoration: underline; }
.card-foot p { margin-top: 9px; font-size: 11.5px; line-height: 1.7; color: #778cab; }

/* ---------------- 试用申请按钮 / 弹窗 ---------------- */
.trial-btn {
    display: inline-flex; align-items: center; gap: 7px; padding: 8px 15px;
    border: 1px solid rgba(110, 190, 255, .35); border-radius: 999px; cursor: pointer;
    color: #cfe3ff; font-size: 13px; font-family: inherit;
    background: linear-gradient(90deg, rgba(46, 116, 255, .18), rgba(34, 211, 238, .08));
    transition: color .2s, border-color .2s, transform .2s, box-shadow .2s;
}
.trial-btn:hover { color: #6ee7f9; border-color: rgba(110, 210, 255, .6); transform: translateY(-1px); box-shadow: 0 8px 22px rgba(40, 120, 255, .2); }

.trial-modal { position: fixed; inset: 0; z-index: 60; display: none; }
.trial-modal.open { display: block; }
.trial-backdrop { position: absolute; inset: 0; background: rgba(4, 10, 24, .62); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.trial-dialog {
    position: relative; width: min(460px, 92vw); margin: 7vh auto 0;
    padding: 30px 30px 26px; border-radius: 22px;
    border: 1px solid rgba(128, 170, 255, .24);
    background: linear-gradient(158deg, rgba(23, 43, 79, .97), rgba(9, 20, 42, .98));
    box-shadow: 0 36px 96px rgba(0, 6, 24, .6), inset 0 1px 0 rgba(255, 255, 255, .08);
    animation: rise .35s ease both;
}
.trial-close {
    position: absolute; top: 16px; right: 18px; width: 32px; height: 32px; border: 0;
    border-radius: 10px; cursor: pointer; font-size: 22px; line-height: 1; color: #9bb1d4;
    background: rgba(255, 255, 255, .06); transition: background .2s, color .2s;
}
.trial-close:hover { background: rgba(255, 255, 255, .12); color: #fff; }
.trial-head { text-align: center; margin-bottom: 22px; }
.trial-head .trial-icon {
    width: 54px; height: 54px; margin: 0 auto 12px; border-radius: 16px; display: grid; place-items: center;
    font-size: 21px; color: #fff;
    background: linear-gradient(140deg, #3b82f6, #7c5cff 65%, #22d3ee);
    box-shadow: 0 14px 32px rgba(72, 100, 255, .42), inset 0 1px 0 rgba(255, 255, 255, .35);
}
.trial-head h3 { font-size: 20px; font-weight: 650; color: #f3f7ff; letter-spacing: .8px; }
.trial-head p { margin-top: 6px; font-size: 12px; line-height: 1.7; color: #8ba1c5; }
.field .req { color: #ff8d8d; }
.trial-textarea {
    width: 100%; min-height: 92px; resize: vertical; outline: none;
    border: 1px solid rgba(132, 166, 225, .2); border-radius: 12px; padding: 12px 14px;
    background: rgba(4, 12, 28, .58); color: #edf5ff; font-family: inherit; font-size: 14px;
    transition: border-color .2s, box-shadow .2s;
}
.trial-textarea:focus { border-color: rgba(94, 199, 255, .72); box-shadow: 0 0 0 3px rgba(59, 130, 246, .14); }
.trial-textarea::placeholder { color: #667c9e; }
.trial-msg { display: none; padding: 11px 14px; margin-bottom: 14px; border-radius: 11px; font-size: 12.5px; line-height: 1.6; }
.trial-msg.ok { color: #bdf5d8; border: 1px solid rgba(80, 220, 150, .4); background: rgba(60, 200, 120, .12); }
.trial-msg.err { color: #ffd3d3; border: 1px solid rgba(255, 108, 108, .32); background: rgba(255, 84, 84, .11); }

/* ---------------- 页脚 ---------------- */
.auth-footer {
    position: relative; z-index: 2;
    padding: 18px clamp(28px, 5vw, 76px) 24px;
    border-top: 1px solid rgba(140, 175, 230, .09);
    color: #6d82a5; font-size: 11.5px;
}
.footer-line { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 20px; }
.footer-sub { margin-top: 6px; justify-content: center; }
.auth-footer a { color: #7f9dc6; text-decoration: none; }
.auth-footer a:hover { color: #77d8ff; }
.footer-divider { margin: 0 10px; font-style: normal; color: #40567a; }

/* ---------------- 响应式 ---------------- */
@media (max-width: 1180px) {
    .auth-main { grid-template-columns: 1fr 410px; gap: 42px; padding-left: 5vw; padding-right: 5vw; }
    .feature-list { grid-template-columns: 1fr; gap: 12px; }
}
@media (max-width: 920px) {
    .auth-main { grid-template-columns: 1fr; gap: 36px; padding-top: 24px; }
    .auth-intro { text-align: center; margin: 0 auto; }
    .intro-lead { margin-left: auto; margin-right: auto; }
    .feature-list { grid-template-columns: repeat(2, 1fr); text-align: left; }
    .intro-source { justify-content: center; }
    .auth-card { width: 100%; max-width: 470px; margin: 0 auto; }
    .auth-header-right { display: none; }
}
@media (max-width: 560px) {
    .auth-header { padding: 20px 20px 4px; }
    .brand-text strong { font-size: 14px; }
    .brand-text small { font-size: 8px; letter-spacing: 1.2px; }
    .auth-main { padding: 20px 18px 36px; }
    .auth-intro h1 { font-size: 34px; }
    .intro-stats { grid-template-columns: repeat(2, 1fr); }
    .feature-list { grid-template-columns: 1fr; }
    .auth-card { padding: 28px 22px 24px; border-radius: 20px; }
    .auth-footer { padding: 16px 20px 22px; }
    .footer-line { justify-content: center; text-align: center; }
}
