/* ============================================================
   登录/注册页 - 浅色动态 UI
   ============================================================ */

:root {
    --primary: #6366f1;
    --primary-light: #818cf8;
    --primary-dark: #4f46e5;
    --accent: #8b5cf6;
    --accent2: #06b6d4;
    --danger: #ef4444;
    --success: #10b981;
    --text: #1e293b;
    --text-light: #64748b;
    --text-lighter: #94a3b8;
    --border: rgba(148, 163, 184, 0.18);
    --grad: linear-gradient(135deg, #6366f1 0%, #8b5cf6 50%, #06b6d4 100%);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

/* ---------- 阿里巴巴图标库 SVG 图标 ---------- */
.ic {
    display: inline-block;
    width: 1em;
    height: 1em;
    vertical-align: -0.125em;
    fill: currentColor;
    overflow: hidden;
    flex-shrink: 0;
}
.ic-lg { width: 1.4em; height: 1.4em; }
.ic-xl { width: 1.8em; height: 1.8em; }
.ic-2x { width: 2.4em; height: 2.4em; }
.ic-brand {
    background: var(--grad);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradMove 5s ease infinite;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    background: #eef2ff;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow: hidden;
}

/* 动态背景光斑 */
body::before, body::after {
    content: '';
    position: fixed;
    border-radius: 50%;
    filter: blur(70px);
    z-index: -1;
}
body::before {
    width: 480px; height: 480px;
    background: rgba(99,102,241,0.28);
    top: -120px; right: -100px;
    animation: drift1 12s ease-in-out infinite alternate;
}
body::after {
    width: 420px; height: 420px;
    background: rgba(139,92,246,0.22);
    bottom: -120px; left: -80px;
    animation: drift2 14s ease-in-out infinite alternate;
}
@keyframes drift1 {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(-60px, 40px) scale(1.15); }
}
@keyframes drift2 {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(50px, -50px) scale(1.1); }
}

.auth-container { width: 100%; max-width: 430px; position: relative; z-index: 1; }

/* 浮动装饰 */
.auth-container::before {
    content: '✦';
    position: absolute;
    top: -30px; right: -20px;
    font-size: 60px;
    color: rgba(139,92,246,0.2);
    animation: floaty 5s ease-in-out infinite;
}
.auth-container::after {
    content: '●';
    position: absolute;
    bottom: -35px; left: -25px;
    font-size: 50px;
    color: rgba(6,182,212,0.18);
    animation: floaty 6s ease-in-out infinite reverse;
}
@keyframes floaty {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-14px) rotate(15deg); }
}

.auth-box {
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: 22px;
    padding: 42px 38px;
    box-shadow: 0 20px 60px rgba(79,70,229,0.16);
    animation: boxIn 0.7s cubic-bezier(.2,.7,.3,1) both;
}
@keyframes boxIn {
    from { opacity: 0; transform: translateY(28px) scale(0.97); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.auth-logo {
    font-size: 28px;
    font-weight: 800;
    text-align: center;
    margin-bottom: 6px;
    background: linear-gradient(135deg, #4f46e5, #8b5cf6, #06b6d4);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradMove 5s ease infinite;
}
/* auth-logo 内的 SVG 图标使用品牌主色（渐变文字对 SVG fill 不生效） */
.auth-logo .ic { fill: #6366f1; -webkit-text-fill-color: initial; }
@keyframes gradMove {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}
.auth-subtitle { text-align: center; color: var(--text-light); font-size: 14px; margin-bottom: 30px; }

.auth-msg {
    border-radius: 10px;
    padding: 11px 15px;
    font-size: 13px;
    margin-bottom: 18px;
    animation: fadeUp 0.35s ease both;
}
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

.form-group { margin-bottom: 18px; }
.form-group label { display: block; font-size: 13px; font-weight: 600; color: var(--text-light); margin-bottom: 7px; }
.form-group input {
    width: 100%;
    padding: 13px 15px;
    border: 1.5px solid var(--border);
    border-radius: 12px;
    font-size: 15px;
    background: rgba(255,255,255,0.9);
    color: var(--text);
    transition: border-color 0.25s, box-shadow 0.25s, transform 0.15s;
}
.form-group input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(99,102,241,0.14);
    transform: scale(1.005);
}
.form-group input::placeholder { color: var(--text-lighter); }

.code-row { display: flex; gap: 10px; align-items: flex-end; }

.btn-code {
    padding: 13px 15px;
    background: linear-gradient(135deg, rgba(99,102,241,0.1), rgba(139,92,246,0.1));
    border: 1px solid rgba(99,102,241,0.25);
    border-radius: 12px;
    color: var(--primary-dark);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    height: 48px;
    transition: all 0.25s;
}
.btn-code:hover { background: linear-gradient(135deg, rgba(99,102,241,0.18), rgba(139,92,246,0.18)); transform: translateY(-1px); }
.btn-code:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }

.btn-auth {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6, #06b6d4);
    background-size: 200% 200%;
    animation: gradMove 5s ease infinite;
    border: none;
    border-radius: 12px;
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    margin-top: 8px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(99,102,241,0.3);
    transition: transform 0.2s, box-shadow 0.3s;
}
.btn-auth:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(99,102,241,0.4); }
.btn-auth:active { transform: scale(0.97); }
.btn-auth:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

.auth-links { text-align: center; margin-top: 20px; font-size: 14px; }
.auth-links a { color: var(--primary); text-decoration: none; font-weight: 600; transition: all 0.2s; }
.auth-links a:hover { text-decoration: underline; color: var(--primary-dark); }

/* 后台登录专属：深色感但保持浅色主题 */
.admin-login-body { background: linear-gradient(135deg, #eef2ff, #f5f3ff, #ecfeff); }
