/* ============================================================
   星坠竞技场 · 设计系统 v3(UI 全面重设计)
   令牌与官网 site.css 同源: 同一套深空黑/灰阶/强调色,
   圆角三档/间距刻度/层级分层表/动效令牌, 全站强制走令牌。
   ============================================================ */
@font-face { font-family: 'Rajdhani'; src: url('/assets/fonts/rajdhani-500.woff2') format('woff2'); font-weight: 500; font-display: swap; }
@font-face { font-family: 'Rajdhani'; src: url('/assets/fonts/rajdhani-600.woff2') format('woff2'); font-weight: 600; font-display: swap; }
@font-face { font-family: 'Rajdhani'; src: url('/assets/fonts/rajdhani-700.woff2') format('woff2'); font-weight: 700; font-display: swap; }
@font-face { font-family: 'Orbitron'; src: url('/assets/fonts/orbitron-var.woff2') format('woff2'); font-weight: 500 900; font-display: swap; }

:root {
  color-scheme: dark;
  /* —— 色板(与 site.css 同源) —— */
  --ink: #06070c;
  --ink-2: #0b0d15;
  --surface: #11141c;
  --surface-2: #161a24;
  --surface-3: #1c2230;
  --line: #232a38;
  --line-2: #2e3647;
  --muted: #8b93a6;
  --muted-2: #5f6675;
  --text: #f2f5fb;
  --text-dim: #c3c9d6;
  --cyan: #45d9ff;
  --violet: #8a63ff;
  --magenta: #ff4ca3;
  --lime: #b8f24a;
  --amber: #ffb33b;
  --danger: #ff5d73;
  --gold: #ffd23b;
  /* —— 圆角(全站仅三档) —— */
  --radius: 14px;
  --radius-sm: 8px;
  --radius-pill: 100px;
  /* —— 间距刻度 —— */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  /* —— 层级分层表 —— */
  --z-content: 1;
  --z-nav: 10;
  --z-modal: 20;
  --z-toast: 30;
  --z-loader: 40;
  /* —— 动效 —— */
  --dur-1: .15s;
  --dur-2: .25s;
  --dur-3: .4s;
  --ease: cubic-bezier(.22, .61, .36, 1);
  /* —— 字体(Noto Sans SC 中文 + Rajdhani 拉丁数字 + Orbitron HUD) —— */
  --font: 'Noto Sans SC', Inter, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', system-ui, sans-serif;
  --font-display: 'Rajdhani', 'Noto Sans SC', Inter, system-ui, sans-serif;
  --font-hud: 'Orbitron', 'Rajdhani', ui-monospace, monospace;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: var(--font);
  font-synthesis: none;
}

* { box-sizing: border-box; }
html, body, #app { width: 100%; min-width: 320px; min-height: 100%; margin: 0; }
body { overflow: hidden; background: var(--ink); color: var(--text); letter-spacing: 0; }
button, input, select, textarea { font: inherit; letter-spacing: 0; }
button { color: inherit; -webkit-tap-highlight-color: transparent; cursor: pointer; }

/* —— 全局细节规格 · 焦点 / 选区 / 滚动条 —— */
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; border-radius: 2px; }
::selection { background: rgba(69, 217, 255, .32); color: #fff; }
* { scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
*::-webkit-scrollbar { width: 8px; height: 8px; }
*::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 4px; }
*::-webkit-scrollbar-thumb:hover { background: #3d4658; }
*::-webkit-scrollbar-track { background: transparent; }
.hidden { display: none !important; }
.screen { position: fixed; inset: 0; min-width: 320px; animation: screen-fade-in var(--dur-3) var(--ease); }
.screen.game-screen { animation-duration: var(--dur-2); }
.game-overlay { animation: fade-in var(--dur-2) var(--ease); }
.game-overlay h2 { animation: slide-up .35s var(--ease) both; }
.game-overlay p.eyebrow { animation: slide-up .35s var(--ease) .05s both; }
.eyebrow { margin: 0 0 10px; color: var(--cyan); font-size: 11px; font-weight: 800; letter-spacing: 1.8px; text-transform: uppercase; }

.brand-lockup { display: flex; align-items: center; gap: 12px; }
.brand-lockup strong { display: block; font-size: 17px; line-height: 1.1; }
.brand-lockup small { display: block; margin-top: 4px; color: var(--muted); font-size: 9px; letter-spacing: 2.4px; }
.brand-mark { position: relative; width: 38px; height: 38px; border: 1px solid #566176; transform: rotate(45deg); }
.brand-mark::before, .brand-mark::after, .brand-mark i { content: ""; position: absolute; inset: 7px; border: 2px solid var(--cyan); }
.brand-mark::after { inset: 13px; border-color: var(--magenta); background: var(--violet); }
.brand-mark i { inset: -5px 15px; border-width: 0 1px; border-color: #687489; }

/* —— 登录页(实景背景 + 玻璃面板) —— */
.auth-screen { display: grid; grid-template-columns: minmax(40px, 1fr) minmax(360px, 460px); align-items: center; padding: 30px 60px; padding: max(30px, var(--safe-top)) clamp(30px, 6vw, 100px) max(30px, var(--safe-bottom)); overflow: hidden; background: var(--ink); }
.auth-photo { position: absolute; inset: 0; z-index: 0; width: 100%; height: 100%; object-fit: cover; opacity: .55; animation: auth-photo-drift 50s ease-in-out infinite alternate; }
@keyframes auth-photo-drift { 0% { transform: scale(1.02) translate(0, 0); } 100% { transform: scale(1.08) translate(-24px, 10px); } }
.auth-bg-overlay { position: absolute; inset: 0; z-index: 1; background:
  linear-gradient(90deg, rgba(6,7,12,.55), rgba(6,7,12,.15) 45%, rgba(6,7,12,.88)),
  radial-gradient(ellipse at 18% 26%, rgba(138,99,255,.14), transparent 52%),
  radial-gradient(ellipse at 78% 72%, rgba(69,217,255,.10), transparent 52%); }
#ambient-canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 2; opacity: .5; }
.auth-screen::after { content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 1; background:
  linear-gradient(0deg, rgba(6,7,12,.6) 0%, transparent 25%, transparent 75%, rgba(6,7,12,.5) 100%); }
.auth-brand { position: absolute; z-index: 3; top: max(34px, calc(var(--safe-top) + 22px)); left: clamp(30px, 5vw, 80px); }
.auth-panel { position: relative; z-index: 3; grid-column: 2; width: 100%; padding: 38px 40px 34px; border: 1px solid var(--line-2); border-radius: var(--radius); background: rgba(11,13,21,.72); backdrop-filter: blur(22px); -webkit-backdrop-filter: blur(22px); box-shadow: 0 32px 90px rgba(0,0,0,.55); overflow: hidden; }
.auth-panel::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 1px; background: linear-gradient(90deg, transparent, var(--cyan), var(--violet), transparent); }
.auth-panel h1 { max-width: 380px; margin: 0 0 28px; font-size: clamp(32px, 4vw, 46px); line-height: 1.12; font-weight: 800; }
.auth-foot { position: absolute; z-index: 3; left: clamp(30px, 5vw, 80px); bottom: max(26px, calc(var(--safe-bottom) + 16px)); margin: 0; color: var(--muted); font-size: 12px; }

/* —— 全局表单规格 —— */
.form-stack { display: grid; gap: var(--space-4); }
label { display: grid; gap: 8px; color: var(--text-dim); font-size: 12px; font-weight: 700; }
input:not([type="checkbox"]):not([type="range"]), select, textarea {
  width: 100%; min-height: 44px; padding: 10px 13px;
  border: 1px solid var(--line-2); border-radius: var(--radius-sm);
  background: rgba(6,7,12,.5); color: var(--text);
  transition: border-color var(--dur-1) var(--ease), box-shadow var(--dur-1) var(--ease), background var(--dur-1) var(--ease);
}
textarea { min-height: 0; resize: vertical; }
input::placeholder, textarea::placeholder { color: var(--muted-2); }
input:not([type="checkbox"]):not([type="range"]):hover, select:hover, textarea:hover { border-color: #465064; }
input:not([type="checkbox"]):not([type="range"]):focus, select:focus, textarea:focus { outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(69,217,255,.14); background: rgba(6,7,12,.78); }
.form-row { display: flex; gap: 14px; }
.form-row > label { flex: 1; }
.auth-options { align-items: center; justify-content: space-between; }

/* —— 开关(全站统一 toggle, 告别默认勾选框) —— */
input[type="checkbox"] {
  appearance: none; -webkit-appearance: none;
  width: 36px; height: 20px; min-height: 0; padding: 0; flex: none;
  border-radius: 100px; border: 1px solid var(--line-2); background: var(--surface-2);
  position: relative; cursor: pointer; vertical-align: middle;
  transition: background var(--dur-2) var(--ease), border-color var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease);
}
input[type="checkbox"]::after { content: ""; position: absolute; top: 50%; left: 2px; width: 14px; height: 14px; margin-top: -7px; border-radius: 50%; background: #aab2c2; transition: transform var(--dur-2) var(--ease), background var(--dur-2) var(--ease); }
input[type="checkbox"]:checked { background: rgba(69,217,255,.22); border-color: rgba(69,217,255,.7); }
input[type="checkbox"]:checked::after { transform: translateX(16px); background: var(--cyan); box-shadow: 0 0 10px rgba(69,217,255,.8); }
input[type="checkbox"]:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }

/* —— 滑条(全站统一: 音量/灵敏度) —— */
input[type="range"] {
  appearance: none; -webkit-appearance: none;
  width: 100%; height: 20px; min-height: 0; padding: 0;
  border: 0; border-radius: 0; background: transparent; cursor: pointer;
}
input[type="range"]::-webkit-slider-runnable-track { height: 4px; border-radius: 2px; background: linear-gradient(90deg, var(--cyan) var(--fill, 50%), var(--line-2) var(--fill, 50%)); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none; width: 16px; height: 16px; margin-top: -6px;
  border-radius: 50%; background: #fff; border: 2px solid var(--cyan);
  box-shadow: 0 0 10px rgba(69,217,255,.7);
  transition: transform var(--dur-1) var(--ease);
}
input[type="range"]:hover::-webkit-slider-thumb { transform: scale(1.15); }
input[type="range"]::-moz-range-track { height: 4px; border-radius: 2px; background: var(--line-2); }
input[type="range"]::-moz-range-progress { height: 4px; border-radius: 2px; background: var(--cyan); }
input[type="range"]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 2px solid var(--cyan); box-shadow: 0 0 10px rgba(69,217,255,.7); }

/* —— 登录标签页 —— */
.auth-tabs { display: flex; margin-bottom: var(--space-5); border-bottom: 1px solid var(--line); }
.auth-tab { flex: 1; padding: 12px 0; border: 0; background: transparent; color: var(--muted); font-size: 14px; font-weight: 600; cursor: pointer; border-bottom: 2px solid transparent; transition: color var(--dur-1) var(--ease), border-color var(--dur-1) var(--ease); }
.auth-tab.active { color: var(--cyan); border-bottom-color: var(--cyan); }
.auth-pane.hidden { display: none; }
.sms-code-row { align-items: flex-end; gap: 10px; }
.sms-code-row label { flex: 1; }
.form-hint { font-size: 12px; color: var(--muted); text-align: center; margin: 10px 0 0; }

/* 新增开发项1: 个人信息子系统 */
.profile-header { display: grid; grid-template-columns: 100px 1fr; gap: 20px; align-items: center; padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); margin-bottom: 20px; }
.profile-avatar { width: 100px; height: 100px; border-radius: 50%; background: linear-gradient(135deg, #45d9ff, #8a63ff); display: flex; align-items: center; justify-content: center; font-size: 40px; color: #fff; font-weight: 700; border: 3px solid var(--line); overflow: hidden; }
.profile-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }
.profile-avatar-wrap { position: relative; flex: 0 0 auto; width: 100px; height: 100px; border-radius: 50%; padding: 0; border: 0; background: none; cursor: pointer; }
.profile-avatar-wrap .profile-avatar { pointer-events: none; transition: box-shadow var(--dur-2) var(--ease), transform var(--dur-2) var(--ease); }
.profile-avatar-wrap .avatar-change-hint { position: absolute; left: 3px; right: 3px; bottom: 3px; padding: 5px 0; border-radius: 0 0 999px 999px; background: rgba(6,8,13,.72); color: #bdeeff; font-size: 11px; font-weight: 700; letter-spacing: 2px; opacity: 0; transform: translateY(6px); transition: all var(--dur-2) var(--ease); pointer-events: none; }
.profile-avatar-wrap:hover .profile-avatar, .profile-avatar-wrap:focus-visible .profile-avatar { transform: scale(1.03); box-shadow: 0 0 0 3px rgba(69,217,255,.45), 0 10px 30px rgba(69,217,255,.22); }
.profile-avatar-wrap:hover .avatar-change-hint, .profile-avatar-wrap:focus-visible .avatar-change-hint { opacity: 1; transform: translateY(0); }
/* —— 个人页子导航(设计语言化: 胶囊标签 + 青色激活) —— */
.profile-tabs { display: flex; flex-wrap: wrap; gap: var(--space-2); margin: 0 0 var(--space-4); }
.ptab-item { padding: 9px 18px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface-2); color: var(--muted); font-size: 12.5px; font-weight: 700; letter-spacing: .5px; cursor: pointer; transition: all var(--dur-1) var(--ease); }
.ptab-item:hover { border-color: var(--line-2); color: var(--text); }
.ptab-item.active { border-color: rgba(69,217,255,.55); background: rgba(69,217,255,.08); color: var(--cyan); }
.profile-meta h3 { font-size: 22px; margin: 0 0 4px; }
.profile-id { font-size: 12px; color: var(--muted); margin: 0 0 8px; }
.profile-id code { color: var(--cyan); }
.profile-bio { font-size: 13px; color: #b8bdc7; margin: 0 0 12px; }
.profile-tags { display: flex; gap: 8px; flex-wrap: wrap; }
.profile-tier-tag { padding: 4px 12px; border-radius: 12px; background: var(--cyan); color: #000; font-size: 12px; font-weight: 700; }
.profile-tags span:not(.profile-tier-tag) { padding: 4px 12px; border-radius: 12px; background: var(--surface-2); color: var(--muted); font-size: 12px; }
.profile-stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; margin-bottom: 20px; }
.profile-stat-card { padding: 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); text-align: center; }
.profile-stat-card small { display: block; color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 6px; }
.profile-stat-card b { font-size: 24px; color: var(--cyan); }
.profile-sections { display: grid; gap: 20px; }
.profile-section { padding: 18px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.profile-section h3 { font-size: 15px; margin: 0 0 14px; display: flex; align-items: center; gap: 8px; }
.profile-section h3 small { font-size: 12px; color: var(--muted); font-weight: 400; }
.profile-skins-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 10px; }
.profile-skin-item { padding: 10px; border: 1px solid var(--line); border-radius: 8px; text-align: center; background: var(--surface-2); }
.profile-skin-item .skin-swatch { width: 40px; height: 40px; border-radius: 50%; margin: 0 auto 6px; border: 2px solid var(--line); }
.profile-skin-item small { font-size: 11px; color: var(--muted); }
.profile-skin-item.locked { opacity: .4; }
.profile-achievements-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; }
.profile-achievement-item { padding: 12px; border: 1px solid var(--line); border-radius: 8px; text-align: center; background: var(--surface-2); }
.profile-achievement-item.earned { border-color: var(--cyan); background: rgba(69,217,255,.06); }
.profile-achievement-item .ach-icon { font-size: 24px; margin-bottom: 6px; display: flex; justify-content: center; align-items: center; color: var(--cyan); }
.profile-achievement-item.earned .ach-icon { color: var(--cyan); }
.profile-achievement-item:not(.earned) .ach-icon { color: var(--muted); opacity: .7; }
.profile-achievement-item b { font-size: 13px; display: block; }
.profile-achievement-item small { font-size: 11px; color: var(--muted); }
.profile-binds { display: grid; gap: 10px; }
.profile-bind-item { display: grid; grid-template-columns: 60px 1fr auto; align-items: center; padding: 10px 14px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface-2); }
.profile-bind-item span { font-size: 13px; color: var(--muted); }
.profile-bind-item b { font-size: 13px; color: var(--text); }
.profile-bind-item b.bound { color: #b8f24a; }
.privacy-settings { display: grid; gap: 12px; }
.privacy-settings label { padding: 10px 14px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface-2); cursor: pointer; }

/* 新增开发项4: 经济系统 */
.wallet-display { display: flex; align-items: center; gap: 10px; padding: 4px 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); font-size: 13px; }
.wallet-coins, .wallet-gems { display: flex; align-items: center; gap: 3px; }
.wallet-coins b { color: #ffd23b; }
.wallet-gems b { color: #45d9ff; }
.recharge-packages { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; margin-bottom: 16px; }
.recharge-package { padding: 16px; border: 2px solid var(--line); border-radius: 10px; background: var(--surface-2); text-align: center; cursor: pointer; transition: border-color .2s, transform .12s; }
.recharge-package:hover { border-color: var(--cyan); transform: translateY(-2px); }
.recharge-package .pkg-gems { font-size: 28px; color: #45d9ff; font-weight: 800; }
.recharge-package .pkg-bonus { font-size: 11px; color: #b8f24a; margin: 4px 0; }
.recharge-package .pkg-price { font-size: 18px; color: var(--text); font-weight: 700; }
.recharge-package .pkg-name { font-size: 12px; color: var(--muted); margin-top: 4px; }
.recharge-orders-section { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 16px; }
.recharge-orders-section h3 { font-size: 14px; margin: 0 0 10px; }
.recharge-order-item { display: grid; grid-template-columns: 1fr auto auto; gap: 10px; padding: 8px 12px; border: 1px solid var(--line); border-radius: 6px; margin-bottom: 6px; font-size: 12px; background: var(--surface-2); }
.recharge-order-item .order-status { padding: 2px 8px; border-radius: 10px; font-size: 11px; }
.recharge-order-item .order-status.paid { background: rgba(184,242,74,.15); color: #b8f24a; }
.recharge-order-item .order-status.pending { background: rgba(255,210,59,.15); color: #ffd23b; }

/* 新增开发项7: 成就解锁通知 */
.achievement-toast { position: fixed; top: 20px; left: 50%; transform: translateX(-50%); z-index: 9500; display: flex; align-items: center; gap: 12px; padding: 14px 24px; border: 1px solid var(--cyan); border-radius: 10px; background: rgba(13,17,25,.96); box-shadow: 0 10px 40px rgba(69,217,255,.2); animation: achSlideIn .4s ease, achFadeOut .4s ease 3.6s forwards; }
.achievement-toast .ach-toast-icon { font-size: 32px; display: flex; align-items: center; justify-content: center; color: var(--cyan); }
.achievement-toast .ach-toast-body small { display: block; color: var(--cyan); font-size: 10px; text-transform: uppercase; letter-spacing: 1px; }
.achievement-toast .ach-toast-body b { font-size: 16px; }
.achievement-toast .ach-toast-reward { font-size: 12px; color: #ffd23b; }
@keyframes achSlideIn { from { opacity: 0; transform: translateX(-50%) translateY(-20px); } to { opacity: 1; transform: translateX(-50%) translateY(0); } }
@keyframes achFadeOut { to { opacity: 0; transform: translateX(-50%) translateY(-20px); } }

/* 新增开发项5: 商城皮肤系统 */
.shop-legend { display: flex; gap: 12px; flex-wrap: wrap; font-size: 11px; }
.shop-legend span { display: flex; align-items: center; gap: 4px; color: var(--muted); }
.shop-legend span::before { content: ''; width: 10px; height: 10px; border-radius: 50%; }
.shop-legend .q-common::before { background: #9aa3b2; }
.shop-legend .q-rare::before { background: #45d9ff; }
.shop-legend .q-epic::before { background: #b85cff; }
.shop-legend .q-legendary::before { background: #ffd23b; }
.shop-legend .q-mythic::before { background: #ff4ca3; }
.shop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.shop-card { padding: 20px; border: 2px solid var(--line); border-radius: 12px; background: var(--surface); text-align: center; position: relative; overflow: hidden; transition: transform .15s, border-color .2s; }
.shop-card:hover { transform: translateY(-3px); }
.shop-card.quality-mythic { border-color: #ff4ca3; background: linear-gradient(135deg, var(--surface), rgba(255,76,163,.06)); }
.shop-card.quality-legendary { border-color: #ffd23b; }
.shop-card.quality-epic { border-color: #b85cff; }
.shop-card.quality-rare { border-color: #45d9ff; }
.shop-card.owned { opacity: .85; }
.shop-card.equipped { border-color: var(--cyan); box-shadow: 0 0 0 2px rgba(69,217,255,.3); }
.shop-card .skin-preview { width: 100px; height: 100px; margin: 0 auto 12px; border-radius: 50%; border: 2px solid var(--line); position: relative; overflow: hidden; background: radial-gradient(circle at 50% 40%, var(--surface-2), var(--ink)); }
.shop-card .skin-preview::after { content: ''; position: absolute; inset: -6px; border-radius: 50%; border: 2px solid transparent; }
.shop-card.quality-mythic .skin-preview::after { border-color: #ff4ca3; animation: spin 3s linear infinite; }
.shop-card.quality-legendary .skin-preview::after { border-color: #ffd23b; animation: spin 4s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.shop-card .skin-quality { position: absolute; top: 8px; right: 8px; padding: 2px 8px; border-radius: 10px; font-size: 10px; font-weight: 700; }
.shop-card .skin-quality.common { background: #9aa3b2; color: #000; }
.shop-card .skin-quality.rare { background: #45d9ff; color: #000; }
.shop-card .skin-quality.epic { background: #b85cff; color: #fff; }
.shop-card .skin-quality.legendary { background: #ffd23b; color: #000; }
.shop-card .skin-quality.mythic { background: #ff4ca3; color: #fff; }
.shop-card h3 { font-size: 16px; margin: 0 0 4px; }
.shop-card .skin-effect { font-size: 11px; color: var(--muted); margin: 0 0 12px; min-height: 28px; }
.shop-card .skin-price { font-size: 18px; font-weight: 800; margin-bottom: 10px; }
.shop-card .skin-price.coins { color: #ffd23b; }
.shop-card .skin-price.gems { color: #45d9ff; }
.shop-card .skin-actions { display: flex; gap: 8px; }
.shop-card .skin-actions button { flex: 1; }

/* 新增开发项6: 战队公会系统 */
.clan-panel { padding: 20px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); margin-bottom: 16px; }
.clan-header { display: grid; grid-template-columns: 1fr auto; gap: 16px; align-items: center; margin-bottom: 16px; }
.clan-header h3 { font-size: 22px; margin: 0; }
.clan-header .clan-meta { font-size: 12px; color: var(--muted); margin-top: 4px; }
.clan-fund { padding: 8px 16px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-2); text-align: center; }
.clan-fund b { display: block; font-size: 20px; color: #ffd23b; }
.clan-fund small { font-size: 11px; color: var(--muted); }
.clan-members-list { display: grid; gap: 6px; }
.clan-member-item { display: grid; grid-template-columns: 1fr auto auto; gap: 10px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface-2); align-items: center; font-size: 13px; }
.clan-member-role { padding: 2px 10px; border-radius: 10px; font-size: 11px; }
.clan-member-role.leader { background: #ffd23b; color: #000; }
.clan-member-role.officer { background: #45d9ff; color: #000; }
.clan-member-role.member { background: var(--line); color: var(--muted); }
.clan-announcements { margin-top: 16px; }
.clan-announcements h4 { font-size: 14px; margin: 0 0 10px; }
.clan-announcement-item { padding: 10px 14px; border-left: 3px solid var(--cyan); background: var(--surface-2); border-radius: 0 6px 6px 0; margin-bottom: 8px; font-size: 13px; }
.clan-announcement-item small { display: block; color: var(--muted); font-size: 11px; margin-top: 4px; }
.clan-create-form { max-width: 400px; }
.clan-invite-code { display: flex; align-items: center; gap: 10px; padding: 12px; border: 1px dashed var(--cyan); border-radius: 8px; background: rgba(69,217,255,.06); margin: 12px 0; }
.clan-invite-code code { font-size: 18px; font-weight: 700; color: var(--cyan); letter-spacing: 2px; }

/* 新增开发项2: 聊天机制 */
.chat-container { display: grid; grid-template-columns: 180px 1fr; gap: 16px; height: calc(100vh - 200px); min-height: 400px; }
.chat-sidebar { display: flex; flex-direction: column; gap: 6px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.chat-channel { padding: 10px 14px; border: 0; border-radius: 6px; background: var(--surface-2); color: var(--text); text-align: left; cursor: pointer; font-size: 13px; }
.chat-channel.active { background: var(--cyan); color: #000; font-weight: 700; }
.chat-dm-list { flex: 1; overflow-y: auto; }
.chat-dm-item { padding: 8px 14px; border-radius: 6px; background: var(--surface-2); color: var(--text); cursor: pointer; font-size: 12px; margin-bottom: 4px; }
.chat-dm-item.active { background: var(--cyan); color: #000; }
.chat-main { display: flex; flex-direction: column; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); overflow: hidden; }
.chat-messages { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.chat-message { font-size: 13px; line-height: 1.5; }
.chat-message .chat-author { font-weight: 700; color: var(--cyan); }
.chat-message .chat-time { font-size: 10px; color: var(--muted); margin-left: 8px; }
.chat-message .chat-content { color: var(--text); margin-top: 2px; }
.chat-input-form { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line); background: var(--surface-2); }
.chat-input-form input { flex: 1; padding: 10px 14px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface); color: var(--text); font-size: 13px; }
@media (max-width: 720px) {
  .chat-container { grid-template-columns: 1fr; height: calc(100vh - 180px); }
  .chat-sidebar { flex-direction: row; overflow-x: auto; }
  .shop-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); }
}

/* 新增开发项8: 管理员后台 */
.announce-list { margin-top: 16px; }
.announce-item { padding: 12px 16px; border-left: 3px solid var(--cyan); background: var(--surface-2); border-radius: 0 6px 6px 0; margin-bottom: 8px; font-size: 13px; }
.announce-item small { display: block; color: var(--muted); font-size: 11px; margin-top: 4px; }

/* ========== UI重构: 导航子菜单 ========== */
.nav-submenu { position: absolute; top: 100%; left: 0; right: 0; z-index: 50; background: var(--surface); border-bottom: 1px solid var(--line); box-shadow: 0 8px 24px rgba(0,0,0,.3); animation: slide-down .2s ease-out; }
.nav-submenu.hidden { display: none; }
.nav-submenu-inner { display: flex; gap: 8px; padding: 12px 24px; max-width: 1400px; margin: 0 auto; flex-wrap: wrap; }
.nav-submenu-item { padding: 10px 20px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-2); color: var(--text); font-size: 13px; cursor: pointer; transition: all .2s; display: flex; align-items: center; gap: 8px; }
.nav-submenu-item:hover { border-color: var(--cyan); background: rgba(69,217,255,.08); }
.nav-submenu-item.active { background: var(--cyan); color: #000; border-color: var(--cyan); }
.nav-dropdown::after { content: ' ▾'; font-size: 10px; opacity: .7; }
@keyframes slide-down { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }

/* ========== UI重构: 快捷小组件 ========== */
.quick-widgets { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 16px 0; }
.widget-card { padding: 14px 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.widget-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.widget-header h4 { font-size: 13px; margin: 0; }
.widget-summary { font-size: 12px; color: var(--muted); }
.collapsible-section { transition: max-height .3s ease, opacity .3s ease, margin .3s ease; overflow: hidden; }
.collapsible-section.collapsed { max-height: 0; opacity: 0; margin: 0; }

/* ========== UI重构: Toast通知系统 ========== */
.toast-container { position: fixed; top: 16px; right: 16px; z-index: var(--z-toast); display: flex; flex-direction: column; gap: 8px; pointer-events: none; max-width: 360px; }
.toast { display: flex; align-items: flex-start; gap: 10px; padding: 12px 16px; border-radius: 8px; background: rgba(17,20,28,.96); border: 1px solid var(--line); box-shadow: 0 8px 32px rgba(0,0,0,.4); animation: toast-in .3s ease-out; pointer-events: auto; backdrop-filter: blur(8px); }
.toast.toast-success { border-left: 3px solid var(--lime); }
.toast.toast-error { border-left: 3px solid var(--danger); }
.toast.toast-info { border-left: 3px solid var(--cyan); }
.toast.toast-warning { border-left: 3px solid var(--amber); }
.toast-icon { font-size: 18px; line-height: 1; flex-shrink: 0; }
.toast-body { flex: 1; font-size: 13px; line-height: 1.4; }
.toast-body b { display: block; font-size: 13px; margin-bottom: 2px; }
.toast-body small { color: var(--muted); font-size: 11px; }
.toast-close { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 16px; padding: 0 4px; flex-shrink: 0; }
.toast.removing { animation: toast-out .3s ease-in forwards; }
@keyframes toast-in { from { opacity: 0; transform: translateX(40px); } to { opacity: 1; transform: translateX(0); } }
@keyframes toast-out { to { opacity: 0; transform: translateX(40px); } }

/* ========== UI重构: 统一模态对话框 ========== */
.modal-overlay { position: fixed; inset: 0; z-index: var(--z-modal); display: flex; align-items: center; justify-content: center; background: rgba(9,11,17,.7); backdrop-filter: blur(4px); animation: fade-in .2s ease-out; }
.modal-overlay.hidden { display: none; }
.modal-container { width: 90%; max-width: 520px; max-height: 85vh; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 24px 64px rgba(0,0,0,.5); animation: modal-in .25s ease-out; }
@keyframes modal-in { from { opacity: 0; transform: scale(.95) translateY(10px); } to { opacity: 1; transform: scale(1) translateY(0); } }
.modal-header { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.modal-header h3 { font-size: 16px; margin: 0; }
.modal-body { flex: 1; overflow-y: auto; padding: 20px; font-size: 14px; line-height: 1.5; }
.modal-footer { display: flex; gap: 8px; justify-content: flex-end; padding: 12px 20px; border-top: 1px solid var(--line); }
.modal-footer button { min-width: 80px; }

/* ========== UI重构: 全局加载指示器 ========== */
.global-loader { position: fixed; inset: 0; z-index: var(--z-loader); display: flex; align-items: center; justify-content: center; background: rgba(9,11,17,.6); backdrop-filter: blur(2px); }
.global-loader.hidden { display: none; }
.loader-spinner { width: 40px; height: 40px; border: 3px solid var(--line); border-top-color: var(--cyan); border-radius: 50%; animation: spin .8s linear infinite; }

/* ========== UI重构: 骨架屏 ========== */
.skeleton { background: linear-gradient(90deg, var(--surface-2) 25%, var(--line) 50%, var(--surface-2) 75%); background-size: 200% 100%; animation: skeleton-shimmer 1.5s infinite; border-radius: 4px; }
@keyframes skeleton-shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }
.skeleton-card { height: 120px; border-radius: 10px; }

/* ========== UI重构: 空状态 ========== */
.empty-state { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 48px 24px; text-align: center; }
.empty-state-icon { font-size: 48px; margin-bottom: 16px; opacity: .3; }
.empty-state-title { font-size: 16px; font-weight: 700; margin-bottom: 8px; }
.empty-state-desc { font-size: 13px; color: var(--muted); max-width: 300px; line-height: 1.5; }
.empty-state-action { margin-top: 20px; }

/* ========== UI重构: 商城皮肤预览特效 ========== */
.shop-card .skin-preview { position: relative; }
.shop-card .skin-preview .preview-orbit { position: absolute; inset: -10px; border-radius: 50%; pointer-events: none; }
.shop-card.quality-mythic .preview-orbit::before, .shop-card.quality-mythic .preview-orbit::after { content: ''; position: absolute; inset: 0; border-radius: 50%; border: 2px solid transparent; }
.shop-card.quality-mythic .preview-orbit::before { border-top-color: #ff4ca3; border-right-color: #ff4ca3; animation: spin 3s linear infinite; }
.shop-card.quality-mythic .preview-orbit::after { border-bottom-color: #ffdf00; border-left-color: #ffdf00; animation: spin 4s linear infinite reverse; }
.shop-card .skin-preview .preview-particles { position: absolute; inset: 0; border-radius: 50%; overflow: hidden; }
.shop-card .skin-preview .preview-particle { position: absolute; width: 4px; height: 4px; border-radius: 50%; opacity: .8; }
.shop-card.quality-legendary .preview-particle { background: #ffd23b; animation: particle-float 2s ease-in-out infinite; }
.shop-card.quality-mythic .preview-particle { background: #ff4ca3; animation: particle-float 1.5s ease-in-out infinite; }
@keyframes particle-float { 0%, 100% { transform: translateY(0) scale(1); opacity: .8; } 50% { transform: translateY(-12px) scale(1.5); opacity: .4; } }

/* ========== UI重构: 移动端导航优化 ========== */
@media (max-width: 768px) {
  .main-nav { gap: 0; }
  .nav-item { padding: 8px 12px; font-size: 12px; }
  .nav-submenu-inner { padding: 10px 14px; gap: 6px; }
  .nav-submenu-item { padding: 8px 14px; font-size: 12px; }
  .quick-widgets { grid-template-columns: 1fr; }
  .account-menu .wallet-display { display: none; }
  .modal-container { width: 95%; max-height: 90vh; }
  .toast-container { left: 12px; right: 12px; max-width: none; }
}

/* 新增开发项3: 小组组队赛 */
.party-section { margin-bottom: 24px; }
.party-panel { padding: 16px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.party-empty { text-align: center; padding: 12px; }
.party-empty p { color: var(--muted); font-size: 13px; margin: 0 0 12px; }
.party-join-form { display: flex; gap: 8px; margin-top: 12px; max-width: 300px; margin-left: auto; margin-right: auto; }
.party-join-form input { flex: 1; padding: 8px 12px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface-2); color: var(--text); font-size: 13px; text-align: center; }
.party-active .party-info { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; font-size: 13px; }
.party-active .party-info code { color: var(--cyan); font-weight: 700; font-size: 16px; letter-spacing: 2px; }
.party-members-list { display: grid; gap: 6px; margin-bottom: 12px; }
.party-member { display: grid; grid-template-columns: 32px 1fr auto; gap: 10px; align-items: center; padding: 8px 12px; border: 1px solid var(--line); border-radius: 6px; background: var(--surface-2); font-size: 13px; }
.party-member .pm-avatar { width: 28px; height: 28px; border-radius: 50%; background: linear-gradient(135deg, var(--cyan), #8a63ff); display: flex; align-items: center; justify-content: center; color: #fff; font-size: 12px; font-weight: 700; }
.party-member .pm-role { font-size: 11px; padding: 2px 8px; border-radius: 10px; background: var(--cyan); color: #000; }
@media (max-width: 720px) {
  .profile-header { grid-template-columns: 70px 1fr; gap: 14px; padding: 14px; }
  .profile-avatar { width: 70px; height: 70px; font-size: 28px; }
  .profile-meta h3 { font-size: 18px; }
}
.check { display: flex; align-items: center; gap: 8px; cursor: pointer; font-size: 12px; color: var(--text-dim); }
.check input { margin: 0; }
/* 注意: .check 内的 checkbox 不再压缩尺寸, 统一走全局 toggle 规格(36×20) */
.text-button { border: 0; padding: 0; background: none; color: var(--cyan); cursor: pointer; font-size: 12px; transition: color var(--dur-1) var(--ease), opacity var(--dur-1) var(--ease); }
.text-button:hover { opacity: .8; }
.primary-button, .secondary-button { min-height: 44px; border: 1px solid transparent; border-radius: var(--radius-sm); padding: 0 18px; font-weight: 700; letter-spacing: .3px; cursor: pointer; transition: border-color var(--dur-1) var(--ease), background-color var(--dur-1) var(--ease), color var(--dur-1) var(--ease), transform var(--dur-1) var(--ease), box-shadow var(--dur-1) var(--ease); }
.primary-button:disabled, .secondary-button:disabled { cursor: not-allowed; filter: grayscale(.7); opacity: .5; }
.primary-button { border-color: rgba(69,217,255,.55); background: linear-gradient(135deg, rgba(69,217,255,.18), rgba(138,99,255,.18)); color: var(--cyan); }
.primary-button:hover { border-color: var(--cyan); background: linear-gradient(135deg, rgba(69,217,255,.28), rgba(138,99,255,.28)); color: #bdeeff; transform: translateY(-1px); box-shadow: 0 8px 26px rgba(69,217,255,.22); }
.primary-button:active { transform: translateY(1px); box-shadow: none; }
.primary-button.wide { display: flex; align-items: center; justify-content: space-between; width: 100%; height: 52px; padding-inline: 20px; }
.primary-button.wide b { font-size: 22px; }
.secondary-button { border-color: var(--line-2); background: rgba(22,26,36,.6); color: var(--text-dim); }
.secondary-button:hover { border-color: rgba(69,217,255,.45); background: var(--surface-3); color: var(--text); }
.secondary-button:active { transform: translateY(1px); }
.form-message { min-height: 18px; margin: 0; color: var(--danger); font-size: 12px; }
.form-message.success { color: var(--lime); }
.demo-account { display: flex; align-items: center; gap: 8px; margin-top: 20px; color: var(--muted); font-size: 11px; }
.demo-account code { padding: 4px 7px; border: 1px solid #394150; color: #d7dce5; }

.lobby-screen { overflow-y: auto; background: #0c0f15; }
/* 大厅真美术背景: 星空海景 + 上下暗化遮罩, 固定不随滚动, 内容面板浮于其上
   注意: 不可在此规则里写 position(会以同优先级覆盖 .screen 的 fixed, 导致页面无法滚动) */
.lobby-screen::before {
  content: ""; position: fixed; inset: -4%; z-index: 0; pointer-events: none;
  background: url('/assets/img/site/hero_bg.jpg') center / cover no-repeat;
  animation: lobby-bg-drift 70s ease-in-out infinite alternate;
  will-change: transform;
}
@keyframes lobby-bg-drift {
  0% { transform: scale(1.04) translate(0, 0); }
  50% { transform: scale(1.09) translate(-1.2%, 1%); }
  100% { transform: scale(1.05) translate(1%, -0.8%); }
}
/* —— 背景动效层: 极光呼吸 + 流星扫过 + 粒子画布(纯 CSS 变换, 不触发重排) —— */
.lobby-screen > .lobby-fx { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden; }
.lobby-fx #lobby-fx-canvas { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .85; }
.lobby-fx .fx-aurora { position: absolute; width: 46vw; height: 46vw; border-radius: 50%; filter: blur(70px); mix-blend-mode: screen; opacity: .12; will-change: transform, opacity; }
.fx-aurora-a { left: -12vw; top: -14vw; background: radial-gradient(circle, #45d9ff, transparent 65%); animation: aurora-a 26s ease-in-out infinite alternate; }
.fx-aurora-b { right: -14vw; top: 6vh; background: radial-gradient(circle, #8a63ff, transparent 65%); animation: aurora-b 34s ease-in-out infinite alternate; }
.fx-aurora-c { left: 28vw; bottom: -18vw; background: radial-gradient(circle, #2f7bff, transparent 65%); animation: aurora-c 42s ease-in-out infinite alternate; }
@keyframes aurora-a {
  0% { transform: translate(0, 0) scale(1); opacity: .1; }
  100% { transform: translate(9vw, 5vh) scale(1.22); opacity: .17; }
}
@keyframes aurora-b {
  0% { transform: translate(0, 0) scale(1.1); opacity: .14; }
  100% { transform: translate(-7vw, 8vh) scale(0.92); opacity: .08; }
}
@keyframes aurora-c {
  0% { transform: translate(0, 0) scale(0.95); opacity: .09; }
  100% { transform: translate(-5vw, -6vh) scale(1.18); opacity: .15; }
}
.lobby-fx .fx-star { position: absolute; top: 12%; left: -8%; width: 150px; height: 2px; border-radius: 2px; background: linear-gradient(90deg, transparent, rgba(234,252,255,.9), transparent); opacity: 0; transform: rotate(-14deg); animation: shooting-star 11s ease-in infinite; }
.fx-star-b { top: 34%; animation-duration: 17s; animation-delay: 6s; animation-timing-function: linear; }
@keyframes shooting-star {
  0%, 78% { opacity: 0; transform: rotate(-14deg) translateX(0); }
  80% { opacity: 0; }
  84% { opacity: .95; }
  94% { opacity: .5; }
  100% { opacity: 0; transform: rotate(-14deg) translateX(120vw); }
}
@media (prefers-reduced-motion: reduce) {
  .lobby-screen::before, .lobby-fx .fx-aurora, .lobby-fx .fx-star { animation: none; }
}
.lobby-screen::after {
  content: ""; position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(6,7,12,.66) 0%, rgba(6,7,12,.36) 30%, rgba(6,7,12,.5) 60%, rgba(6,7,12,.86) 100%);
}
.lobby-screen > * { position: relative; z-index: 1; }
.topbar { position: sticky; z-index: 20; top: 0; display: grid; grid-template-columns: minmax(230px, 1fr) auto minmax(230px, 1fr); align-items: center; height: 72px; padding: 0 40px; padding: 0 clamp(20px, 4vw, 64px); border-bottom: 1px solid #2b313d; background: rgba(12,15,21,.96); }
.brand-lockup.compact .brand-mark { width: 30px; height: 30px; }
.main-nav { align-self: stretch; display: flex; }
.nav-item { position: relative; min-width: 96px; border: 0; background: transparent; color: var(--muted); cursor: pointer; font-size: 13px; font-weight: 700; transition: color .18s ease, background-color .18s ease; }
.nav-item::after { content: ""; position: absolute; right: 18px; bottom: 0; left: 18px; height: 2px; background: var(--cyan); transform: scaleX(0); transform-origin: center; transition: transform .2s ease; }
.nav-item:hover { background: rgba(255,255,255,.025); color: #dce2ec; }
.nav-item.active { color: var(--text); }
.nav-item.active::after { transform: scaleX(1); }
.account-menu { justify-self: end; display: flex; align-items: center; gap: 9px; font-size: 13px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--lime); box-shadow: 0 0 10px rgba(184,242,74,.7); animation: status-pulse 2.4s ease-in-out infinite; }
.icon-button { width: 36px; height: 36px; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: rgba(22,26,36,.6); cursor: pointer; font-size: 18px; transition: border-color var(--dur-1) var(--ease), background-color var(--dur-1) var(--ease), color var(--dur-1) var(--ease), transform var(--dur-1) var(--ease); }
.icon-button:hover { border-color: rgba(69,217,255,.45); background: var(--surface-3); color: var(--cyan); }
.icon-button:active { transform: scale(.94); }
.icon-button.muted { color: var(--muted-2); }

.lobby-view { width: min(1440px, 100%); margin: 0 auto; padding: 0 40px 54px; padding: 0 clamp(22px, 4vw, 64px) 54px; }
.launch-band { position: relative; display: grid; grid-template-columns: minmax(300px, 1fr) minmax(300px, 1.2fr) minmax(250px, .8fr); align-items: center; min-height: 430px; border-bottom: 1px solid #303744; overflow: hidden; }
.launch-band::before { content: ""; position: absolute; right: 22%; bottom: 42px; left: 25%; height: 1px; background: #3a4351; box-shadow: 0 -80px 0 rgba(58,67,81,.32), 0 80px 0 rgba(58,67,81,.18); transform: perspective(420px) rotateX(70deg); }
.mode-copy, .launch-action { position: relative; z-index: 3; }
.mode-copy h2 { margin: 0; font-size: 64px; font-size: clamp(46px, 6vw, 82px); line-height: .95; transition: color .24s ease; }
.mode-copy > p:not(.eyebrow) { margin: 15px 0 0; color: #aab1bf; }
.mode-copy .mode-description { max-width: 390px; min-height: 38px; margin-top: 9px; color: #737e90; font-size: 11px; line-height: 1.65; }
.mode-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.mode-copy .mode-tags { margin-top: 21px; }
.mode-tags span { padding: 6px 9px; border: 1px solid #3c4554; color: #b5bdca; font-size: 10px; transition: border-color .2s ease, color .2s ease; }
.mech-display { position: relative; height: 390px; }
.mech-display::after { content: ""; position: absolute; top: 50%; left: 50%; width: 36px; height: 1px; background: rgba(255,255,255,.34); box-shadow: -58px 0 0 rgba(255,255,255,.1), 58px 0 0 rgba(255,255,255,.1); transform: translate(-50%,-50%); animation: scanner-pulse 2.8s ease-in-out infinite; }
.orbit { position: absolute; top: 50%; left: 50%; border: 1px solid rgba(69,217,255,.26); border-radius: 50%; transform: translate(-50%,-50%) rotate(-15deg); }
.orbit::before { content: ""; position: absolute; top: 50%; left: -4px; width: 7px; height: 7px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 14px rgba(69,217,255,.9); transform: translateY(-50%); }
.orbit-a { width: 340px; height: 140px; animation: orbit-drift 10s linear infinite; }
.orbit-b { width: 270px; height: 270px; border-color: rgba(255,76,163,.16); animation: orbit-breathe 4.8s ease-in-out infinite; }
.orbit-b::before { top: -4px; left: 50%; background: var(--magenta); box-shadow: 0 0 14px rgba(255,76,163,.72); transform: translateX(-50%); }
.mech-art { position: absolute; top: 50%; left: 50%; width: 180px; height: 120px; transform: translate(-50%,-50%) rotate(-8deg); filter: drop-shadow(0 28px 20px rgba(0,0,0,.65)); animation: mech-hover 3.8s ease-in-out infinite; }
.mech-art .t1 { left: 44px; }.mech-art .t2 { right: 44px; }
.lobby-screen[data-mode="core_rush"] .mode-copy h2 { color: #ffd18a; }
.lobby-screen[data-mode="core_rush"] .mode-tags span { border-color: rgba(255,179,59,.42); color: #e2c28e; }
.lobby-screen[data-mode="core_rush"] .mech-art .cockpit { background: var(--amber); box-shadow: 0 0 28px rgba(255,179,59,.8); }
.lobby-screen[data-mode="storm_survival"] .mode-copy h2 { color: #ff8eb6; }
.lobby-screen[data-mode="storm_survival"] .mode-tags span { border-color: rgba(255,76,163,.42); color: #e7a5c5; }
.lobby-screen[data-mode="storm_survival"] .mech-art .cockpit { background: var(--magenta); box-shadow: 0 0 28px rgba(255,76,163,.8); }
.launch-band.mode-changing .mode-copy { animation: mode-copy-in .34s ease-out; }
.launch-band.mode-changing .mech-art { animation: mech-switch .42s ease-out, mech-hover 3.8s .42s ease-in-out infinite; }
.launch-action { justify-self: end; width: min(100%, 270px); }
.online-line { display: flex; align-items: center; justify-content: flex-end; gap: 8px; margin-bottom: 13px; color: var(--muted); font-size: 11px; }

.mode-option { position: relative; display: grid; grid-template-columns: 34px 1fr; grid-template-rows: auto auto; min-height: 78px; padding: 14px 16px; border: 0; border-right: 1px solid #303744; background: #10141c; color: #8f98a8; text-align: left; cursor: pointer; overflow: hidden; transition: background-color .2s ease, color .2s ease, transform .12s ease; }
.mode-option:last-child { border-right: 0; }
.mode-option > span { grid-row: 1 / 3; align-self: center; color: #4f596b; font: 800 11px ui-monospace, monospace; transition: color .2s ease, transform .2s ease; }
.mode-option b { color: #dce2ec; font-size: 13px; }
.mode-option small { margin-top: 3px; font-size: 9px; }
.mode-option::after { content: ""; position: absolute; right: 0; bottom: 0; left: 0; height: 2px; background: var(--cyan); transform: scaleX(0); transform-origin: left; transition: transform .24s ease; }
.mode-option:hover { background: #171c26; }
.mode-option:hover > span { color: #8d99ab; transform: translateX(2px); }
.mode-option:active { transform: scale(.985); }
.mode-option.active { background: #19202a; color: #b7c0ce; }
.mode-option.active > span, .mode-option.active b { color: var(--cyan); }
@media (max-width: 720px) {
  .mode-option:nth-child(2n) { border-right: 0; }
  .mode-option:nth-child(-n+2) { border-bottom: 1px solid #303744; }
}
.mode-option.active::after { transform: scaleX(1); }

.dashboard-grid { display: grid; grid-template-columns: 1.15fr .85fr .9fr; gap: 1px; margin-top: 34px; background: #303744; border: 1px solid #303744; }
.dashboard-grid article { min-height: 190px; padding: 24px; background: #131720; transition: background-color .2s ease, box-shadow .2s ease; }
.dashboard-grid article:hover { z-index: 1; background: #171c26; box-shadow: inset 0 2px 0 rgba(69,217,255,.38); }
.panel-heading { display: flex; align-items: start; justify-content: space-between; gap: 20px; }
.panel-heading h3, .brief-panel h3 { margin: 0; font-size: 20px; }
.level-badge { padding: 8px; border: 1px solid var(--violet); color: #cfc3ff; font-size: 10px; }
.stat-grid { display: grid; grid-template-columns: repeat(4,1fr); margin: 30px 0 0; }
.stat-grid div + div { padding-left: 18px; border-left: 1px solid #303744; }
.stat-grid dt { color: var(--muted); font-size: 10px; }
.stat-grid dd { margin: 8px 0 0; font-size: 22px; font-weight: 800; }
.mission-icon { color: var(--magenta); font-size: 26px; text-shadow: 0 0 18px rgba(255,76,163,.8); }
.progress-track { height: 6px; margin-top: 42px; background: #292f3b; }
.progress-track i { display: block; height: 100%; background: var(--magenta); }
.mission-foot { display: flex; justify-content: space-between; margin-top: 12px; color: var(--muted); font-size: 11px; }
.brief-row { display: flex; gap: 15px; padding: 14px 0; border-top: 1px solid #2d3440; }
.brief-time { color: var(--cyan); font-family: ui-monospace, monospace; font-weight: 800; }
.brief-time.warm { color: var(--amber); }
.brief-row b, .brief-row small { display: block; }
.brief-row b { font-size: 12px; }.brief-row small { margin-top: 5px; color: var(--muted); font-size: 10px; }

.data-view { padding-top: 54px; }
.view-heading { display: flex; justify-content: space-between; align-items: end; margin-bottom: 28px; }
.view-heading h2 { margin: 0; font-size: 34px; }
.table-wrap { overflow: auto; border: 1px solid #303744; background: #12161e; }
table { width: 100%; border-collapse: collapse; font-size: 12px; }
th, td { height: 54px; padding: 0 18px; border-bottom: 1px solid #292f3a; text-align: left; white-space: nowrap; }
th { color: var(--muted); font-size: 10px; text-transform: uppercase; }
tbody tr:hover { background: #191e28; }
td:first-child { color: var(--cyan); font-weight: 800; }

.game-screen { background: #070910; touch-action: none; }
#game-canvas { display: block; width: 100%; height: 100%; }
.game-vignette { position: absolute; inset: 0; pointer-events: none; box-shadow: inset 0 0 130px rgba(0,0,0,.65); }
.game-topbar { position: absolute; top: max(18px, calc(var(--safe-top) + 8px)); right: 24px; left: 24px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: start; pointer-events: none; }
.hud-block { display: grid; grid-template-columns: auto auto; grid-template-rows: auto auto; width: max-content; padding: 12px 16px; border: 1px solid var(--line); border-left: 2px solid var(--cyan); border-radius: var(--radius-sm); background: rgba(10,13,19,.76); backdrop-filter: blur(12px); }
.hud-block small { grid-column: 1 / 3; color: var(--muted); font-size: 10px; letter-spacing: 1px; }
.hud-block strong { font-size: 30px; line-height: 1; }
.hud-block > span { align-self: end; margin-left: 8px; color: var(--muted-2); font-size: 10px; }
.rank-hud { justify-self: end; border: 1px solid var(--line); border-right: 2px solid var(--magenta); border-left: 0; border-radius: var(--radius-sm); text-align: right; }
.rank-hud strong i { color: var(--magenta); font-size: 15px; font-style: normal; }
.timer-hud { min-width: 160px; padding: 8px 18px; border: 1px solid var(--line); border-top: 2px solid var(--violet); border-radius: var(--radius-sm); background: rgba(10,13,19,.82); backdrop-filter: blur(12px); text-align: center; }
.timer-hud small, .timer-hud span { display: block; color: var(--muted); font-size: 10px; }
.timer-hud strong { display: block; margin: 3px 0; font-family: var(--font-display); font-size: 28px; font-weight: 700; }
.shield-hud { position: absolute; top: max(104px, calc(var(--safe-top) + 94px)); left: 24px; width: 240px; }
.shield-label { display: flex; justify-content: space-between; margin-bottom: 7px; font-size: 10px; text-transform: uppercase; }
.shield-track { height: 7px; border: 1px solid rgba(255,255,255,.2); background: rgba(0,0,0,.48); }
.shield-track i { display: block; width: 100%; height: 100%; background: var(--cyan); transition: width .16s linear, background .2s; }
.buff-chip { width: max-content; margin-top: 8px; padding: 5px 8px; border: 1px solid var(--violet); border-radius: var(--radius-sm); background: rgba(17,20,28,.82); color: #d7d0ff; font-size: 10px; }
.net-hud { position: absolute; right: 24px; bottom: max(19px, calc(var(--safe-bottom) + 9px)); display: flex; align-items: center; gap: 6px; padding: 7px 10px; background: rgba(9,11,17,.68); color: #a8b0bf; font: 9px ui-monospace, monospace; }
.net-hud .status-dot { display: inline-block; }.net-hud i { width: 1px; height: 10px; background: #4b5361; }
.match-ranking { position: absolute; top: max(104px, calc(var(--safe-top) + 94px)); right: 24px; width: 190px; padding: 12px; background: rgba(10,13,19,.72); backdrop-filter: blur(6px); }
.match-ranking h3 { margin: 0 0 9px; color: var(--muted); font-size: 10px; letter-spacing: 1px; text-transform: uppercase; }
.match-ranking ol { display: grid; gap: 4px; margin: 0; padding: 0; list-style: none; }
.match-ranking li { display: grid; grid-template-columns: 20px 1fr auto; align-items: center; min-height: 24px; padding: 0 5px; font-size: 10px; }
.match-ranking li b { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.match-ranking li.me { background: rgba(69,217,255,.16); color: var(--cyan); }
.match-ranking li.out { color: #687181; text-decoration: line-through; }
.minimap { position: absolute; right: 24px; bottom: max(54px, calc(var(--safe-bottom) + 44px)); width: 180px; height: 120px; border: 1px solid #475062; background: rgba(6,8,13,.74); }
.event-feed { position: absolute; left: 24px; bottom: max(28px, calc(var(--safe-bottom) + 18px)); display: grid; gap: 5px; width: 280px; pointer-events: none; }
.event-feed p { margin: 0; padding: 7px 10px; border-left: 2px solid var(--cyan); background: rgba(9,12,18,.76); color: #ced4df; font-size: 10px; animation: feed-in .2s ease-out; }
@keyframes feed-in { from { opacity: 0; transform: translateX(-12px); } }
.guide-chip { position: absolute; bottom: 17%; left: 50%; display: flex; align-items: center; gap: 10px; min-width: 220px; padding: 10px 14px; border: 1px solid rgba(69,217,255,.55); background: rgba(10,13,19,.82); transform: translateX(-50%); }
.guide-chip span { color: var(--cyan); font: 800 10px ui-monospace, monospace; }.guide-chip b { font-size: 11px; }
.game-control-bar { position: absolute; top: 12px; right: 12px; display: flex; gap: 8px; z-index: 20; }
.game-ctrl-btn { width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 8px; background: rgba(17,20,28,.92); color: var(--text); font-size: 18px; display: grid; place-items: center; transition: border-color .15s ease, background .15s ease; }
.game-ctrl-btn:hover { border-color: var(--cyan); background: rgba(69,217,255,.12); }
.game-ctrl-btn.active { border-color: var(--cyan); background: rgba(69,217,255,.18); color: var(--cyan); }

.pause-overlay { gap: 22px; }
.pause-actions { display: flex; gap: 12px; margin-top: 8px; }

.ai-suggestion-toast { position: absolute; top: 50%; left: 50%; z-index: 22; display: grid; gap: 6px; min-width: 320px; max-width: 80vw; padding: 20px 24px; border: 1px solid var(--amber); border-radius: 10px; background: rgba(12,15,22,.96); box-shadow: 0 24px 60px rgba(0,0,0,.6); transform: translate(-50%,-50%); text-align: center; }
.ai-suggestion-toast b { color: var(--amber); font-size: 14px; }
.ai-suggestion-toast span { color: var(--muted); font-size: 11px; }
.toast-actions { display: flex; gap: 10px; justify-content: center; margin-top: 6px; }

.touch-controls { display: none; }
.game-overlay { position: absolute; z-index: 12; top: 50%; left: 50%; display: grid; justify-items: center; min-width: min(440px, calc(100vw - 36px)); padding: 34px 38px; border: 1px solid var(--line-2); border-top: 2px solid var(--cyan); border-radius: var(--radius); background: rgba(12,15,22,.92); backdrop-filter: blur(16px); box-shadow: 0 30px 90px rgba(0,0,0,.56); transform: translate(-50%,-50%); text-align: center; }
.game-overlay h2 { margin: 0; font-size: 25px; }.game-overlay > p:not(.eyebrow) { color: var(--muted); font-size: 12px; }
.radar-loader { position: relative; width: 74px; height: 74px; margin-bottom: 20px; border: 1px solid #4d5769; border-radius: 50%; overflow: hidden; }
.radar-loader::before, .radar-loader::after { content: ""; position: absolute; top: 50%; left: 0; width: 100%; height: 1px; background: #3a4352; }.radar-loader::after { transform: rotate(90deg); }
.radar-loader i { position: absolute; top: 50%; left: 50%; width: 50%; height: 2px; background: var(--cyan); transform-origin: left; animation: radar 1.3s linear infinite; box-shadow: 12px 0 12px var(--cyan); }
.radar-loader.small { width: 38px; height: 38px; margin: 0 12px 0 0; }
@keyframes radar { to { transform: rotate(360deg); } }
.countdown-overlay { position: absolute; top: 50%; left: 50%; display: grid; justify-items: center; transform: translate(-50%,-50%); text-shadow: 0 5px 24px #000; }
.countdown-overlay small, .countdown-overlay span { font-size: 11px; letter-spacing: 2px; text-transform: uppercase; }.countdown-overlay strong { color: var(--cyan); font: 900 140px/.9 ui-monospace, monospace; font: 900 clamp(100px,20vw,190px)/.9 ui-monospace, monospace; }
.reconnect-overlay { position: absolute; top: 18px; left: 50%; display: grid; grid-template-columns: auto auto; align-items: center; padding: 9px 13px; border: 1px solid var(--amber); background: rgba(14,16,22,.94); transform: translateX(-50%); }
.reconnect-overlay .radar-loader { grid-row: 1 / 3; }.reconnect-overlay b, .reconnect-overlay small { display: block; }.reconnect-overlay b { font-size: 12px; }.reconnect-overlay small { color: var(--muted); font-size: 10px; }
.result-ranking { width: 100%; margin: 22px 0; }
.result-ranking div { display: grid; grid-template-columns: 34px 1fr auto; padding: 9px; border-top: 1px solid #303744; text-align: left; font-size: 12px; }.result-ranking .me { color: var(--cyan); }
.result-ranked-info { text-align: center; margin-bottom: 16px; }
.result-ranked-info p { margin: 4px 0; }
#result-ranked-points { font-size: 18px; color: #b8f24a; font-weight: 700; }
.result-streak { font-size: 12px; color: var(--muted); }
.death-overlay { border-top-color: var(--danger); }
.overlay-actions { display: flex; gap: 10px; width: 100%; margin-top: 16px; }
.overlay-actions button { flex: 1; }
.spectator-bar { position: absolute; z-index: 11; bottom: max(24px, calc(var(--safe-bottom) + 14px)); left: 50%; display: flex; align-items: center; gap: 9px; min-height: 48px; padding: 6px 7px 6px 13px; border-top: 2px solid var(--amber); background: rgba(10,13,19,.9); transform: translateX(-50%); }
.spectator-bar > span { color: var(--amber); font-size: 10px; font-weight: 800; }
.spectator-bar > b { width: 110px; overflow: hidden; text-align: center; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.spectator-bar .icon-button { width: 32px; height: 32px; }
.spectator-bar .secondary-button { min-height: 34px; font-size: 10px; }

.onboarding-overlay { position: fixed; z-index: 60; inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(4,6,10,.78); backdrop-filter: blur(7px); }
.onboarding-panel { width: min(520px, 100%); padding: 34px; border-top: 2px solid var(--cyan); background: #121720; box-shadow: 0 28px 90px rgba(0,0,0,.52); }
.onboarding-progress { display: flex; gap: 6px; margin-bottom: 28px; }
.onboarding-progress i { flex: 1; height: 3px; background: #353d4a; border-radius: 2px; }
.onboarding-progress i.active { background: var(--cyan); }
.onboarding-panel h2 { margin: 0; font-size: 30px; }
.onboarding-panel > p:not(.eyebrow) { min-height: 50px; margin: 14px 0 28px; color: #a6afbe; font-size: 13px; line-height: 1.8; }
.onboarding-actions { display: flex; align-items: center; justify-content: space-between; }

/* —— 弹窗统一规格(毛玻璃 + 流光顶线 + 居中 + 进出场) —— */
.modal { width: min(460px, calc(100vw - 32px)); padding: 26px; border: 1px solid var(--line-2); border-radius: var(--radius); background: rgba(13,16,24,.86); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); color: var(--text); box-shadow: 0 28px 80px rgba(0,0,0,.6); overflow: visible; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); margin: 0; }
.modal::before { content: ""; position: absolute; top: -1px; left: 10%; right: 10%; height: 1px; background: linear-gradient(90deg, transparent, var(--cyan), var(--violet), transparent); }
.modal[open] { animation: modal-pop var(--dur-2) var(--ease); }
@keyframes modal-pop { 0% { opacity: 0; transform: translate(-50%, calc(-50% + 8px)) scale(.96); } 100% { opacity: 1; transform: translate(-50%, -50%) scale(1); } }
.modal::backdrop { background: rgba(6,7,12,.66); backdrop-filter: blur(4px); }
.modal:not([open]) { display: none; }
.modal[open] { position: fixed; z-index: 100; top: 50%; left: 50%; margin: 0; transform: translate(-50%,-50%); }
.modal::backdrop { background: rgba(4,5,8,.78); backdrop-filter: blur(5px); }
.modal-heading { display: flex; justify-content: space-between; align-items: start; }.modal-heading h2 { margin: 0 0 12px; }

@keyframes status-pulse {
  0%, 100% { opacity: .72; box-shadow: 0 0 7px rgba(184,242,74,.48); }
  50% { opacity: 1; box-shadow: 0 0 15px rgba(184,242,74,.88); }
}
@keyframes scanner-pulse {
  0%, 100% { opacity: .24; transform: translate(-50%,-50%) scaleX(.65); }
  50% { opacity: .9; transform: translate(-50%,-50%) scaleX(1.15); }
}
@keyframes orbit-drift {
  from { transform: translate(-50%,-50%) rotate(-15deg); }
  to { transform: translate(-50%,-50%) rotate(345deg); }
}
@keyframes orbit-breathe {
  0%, 100% { opacity: .5; transform: translate(-50%,-50%) rotate(0) scale(.98); }
  50% { opacity: 1; transform: translate(-50%,-50%) rotate(45deg) scale(1.03); }
}
@keyframes mode-copy-in {
  from { opacity: .35; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes mech-switch {
  from { opacity: .35; transform: translate(-50%,-50%) rotate(-18deg) scale(.88); }
  to { opacity: 1; transform: translate(-50%,-50%) rotate(-8deg) scale(1); }
}
@keyframes mech-hover {
  0%, 100% { transform: translate(-50%,-50%) rotate(-8deg) translateY(0); }
  50% { transform: translate(-50%,-50%) rotate(-5deg) translateY(-10px); }
}
@keyframes screen-fade-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes card-select-ripple { 0% { box-shadow: 0 0 0 0 rgba(69,217,255,.5); } 100% { box-shadow: 0 0 0 12px rgba(69,217,255,0); } }
@keyframes pop-in { 0% { opacity: 0; transform: scale(.85); } 100% { opacity: 1; transform: scale(1); } }
@keyframes slide-up { from { opacity: 0; transform: translateY(16px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }

@media (hover: none), (pointer: coarse) {
  .joystick { position: absolute; bottom: max(32px, calc(var(--safe-bottom) + 22px)); left: 25px; width: 118px; height: 118px; border: 1px solid rgba(255,255,255,.25); border-radius: 50%; background: rgba(11,14,20,.42); }
  .joystick::after { content: ""; position: absolute; inset: 35%; border: 1px solid rgba(69,217,255,.35); border-radius: 50%; }
  .joystick i { position: absolute; top: 50%; left: 50%; width: 52px; height: 52px; margin: -26px; border: 2px solid var(--cyan); border-radius: 50%; background: rgba(25,31,42,.88); box-shadow: 0 0 18px rgba(69,217,255,.24); }
  .touch-button { position: absolute; display: grid; place-items: center; width: 72px; height: 72px; border: 1px solid #657083; border-radius: 50%; background: rgba(17,22,30,.75); color: white; }
  .touch-button b { font-size: 24px; line-height: 1; }.touch-button span { font-size: 9px; }.touch-button.skill { right: 25px; bottom: max(38px, calc(var(--safe-bottom) + 28px)); border-color: var(--magenta); }.touch-button.dash { right: 96px; bottom: max(96px, calc(var(--safe-bottom) + 86px)); width: 54px; height: 54px; opacity: .55; border-color: var(--cyan); }.touch-button.dash b { font-size: 18px; }.touch-button.dash span { font-size: 10px; }.touch-button.switch-target { display: none; }
  .touch-button:active { transform: scale(.94); background: rgba(40,48,61,.92); }
  .touch-button.skill .lock-hint { position: absolute; top: -16px; font-size: 10px; color: rgba(255,77,109,.7); white-space: nowrap; }
  .aim-zone { position: absolute; right: 18px; bottom: max(24px, calc(var(--safe-bottom) + 14px)); width: 184px; height: 184px; border: 1px solid rgba(255,76,163,.12); border-radius: 50%; pointer-events: none; }
  .aim-zone i { position: absolute; top: 50%; left: 50%; width: 34px; height: 34px; border: 1px solid rgba(255,76,163,.28); border-radius: 50%; transform: translate(-50%,-50%); }
}

@media (max-width: 620px) {
  .auth-panel { padding: 28px 22px 24px; }.auth-panel h1 { font-size: 32px; }.auth-brand .brand-lockup small { display: none; }
  .topbar { height: 62px; }.topbar .brand-lockup strong { font-size: 14px; }.account-menu #top-username, .account-menu .status-dot { display: none; }
  .launch-band { display: flex; min-height: auto; padding: 36px 0 30px; flex-direction: column; align-items: stretch; }.mode-copy h2 { font-size: 54px; }.mech-display { height: 250px; }.orbit-a { width: 260px; height: 110px; }.orbit-b { width: 220px; height: 220px; }.mech-art { animation-name: mech-hover-mobile; }.launch-band.mode-changing .mech-art { animation: mech-switch-mobile .42s ease-out, mech-hover-mobile 3.8s .42s ease-in-out infinite; }.launch-action { width: 100%; }.online-line { justify-content: flex-start; }.mode-selector { margin-inline: -22px; overflow-x: auto; grid-template-columns: repeat(3,minmax(150px,1fr)); }.mode-option { min-height: 68px; padding: 13px; }.dashboard-grid { display: block; margin-top: 20px; border: 0; background: none; }.dashboard-grid article { min-height: 0; border-bottom: 1px solid #303744; }.stat-grid dd { font-size: 18px; }.data-view { padding-top: 30px; }.view-heading { align-items: center; }.view-heading h2 { font-size: 25px; }
  .game-topbar { top: max(9px, var(--safe-top)); right: 10px; left: 10px; }.hud-block { padding: 8px 10px; }.hud-block strong { font-size: 22px; }.hud-block > span { display: none; }.timer-hud { min-width: 118px; padding: 6px 8px; }.timer-hud strong { font-size: 21px; }.timer-hud span { display: none; }.shield-hud { top: max(78px, calc(var(--safe-top) + 68px)); left: 12px; width: min(180px, calc(100vw - 168px)); }.match-ranking { top: max(78px, calc(var(--safe-top) + 68px)); right: 10px; width: 145px; }.match-ranking li { grid-template-columns: 16px 1fr auto; }.match-ranking li:nth-child(n+5) { display: none; }
  /* 优化19: 竖屏小地图紧凑显示, 半透明不遮挡 */
  .minimap { width: 80px; height: 54px; right: 8px; bottom: auto; top: max(78px, calc(var(--safe-top) + 68px)); opacity: .55; border-color: rgba(71,80,98,.4); background: rgba(6,8,13,.4); z-index: 5; }
  .minimap:active { opacity: .9; }
  .net-hud { top: max(235px, calc(var(--safe-top) + 225px)); right: 10px; bottom: auto; }.net-hud i, #hud-bandwidth, #hud-bandwidth + * { display: none; }.event-feed { top: max(205px, calc(var(--safe-top) + 195px)); bottom: auto; left: 12px; width: min(210px, calc(100vw - 140px)); }.event-feed p:nth-child(n+3) { display: none; }.guide-chip { bottom: 26%; }.countdown-overlay strong { font-size: 110px; }
  .onboarding-panel { padding: 28px 22px; }.onboarding-panel h2 { font-size: 25px; }.spectator-bar { right: 10px; bottom: max(12px, calc(var(--safe-bottom) + 7px)); left: 10px; justify-content: center; transform: none; }.spectator-bar > b { width: 78px; }
}

@media (max-height: 560px) and (orientation: landscape) {
  .game-topbar { top: 7px; }.shield-hud, .match-ranking { top: 70px; }.match-ranking li:nth-child(n+4) { display: none; }
  /* 优化19: 手机端显示紧凑半透明小地图, 不遮挡操作区域 */
  .minimap { width: 100px; height: 66px; right: 8px; bottom: auto; top: 60px; opacity: .6; border-color: rgba(71,80,98,.5); background: rgba(6,8,13,.5); }
  .minimap:active { opacity: .9; }
  .event-feed { top: 145px; bottom: auto; left: 130px; width: 220px; }.guide-chip { bottom: 12px; }.net-hud { bottom: 8px; }.joystick { width: 92px; height: 92px; }.touch-button { width: 62px; height: 62px; }.touch-button.dash { right: 100px; bottom: 70px; }
  .aim-zone { width: 150px; height: 130px; }.spectator-bar { bottom: 7px; }
}

/* ===== Skin row (机甲涂装) ===== */
.skin-block { margin-top: 18px; padding-top: 16px; border-top: 1px solid #303744; }
.skin-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 8px; }
.skin-chip { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid #303744; border-radius: 10px; background: rgba(20,26,38,.6); color: #d7e2ea; cursor: pointer; transition: border-color .18s, transform .18s, background .18s; }
.skin-chip:hover { border-color: var(--cyan); background: rgba(40,52,72,.8); }
.skin-chip:active { transform: scale(.96); }
.skin-chip.active { border-color: var(--cyan); background: linear-gradient(135deg, rgba(69,217,255,.18), rgba(124,92,255,.18)); box-shadow: 0 0 12px rgba(69,217,255,.32); }
.skin-swatch { width: 18px; height: 18px; border-radius: 50%; box-shadow: 0 0 8px rgba(255,255,255,.18); }
.skin-chip span { font-size: 12px; font-weight: 600; }

/* ===== Mobile touch weapon row + skill SVG ===== */
.touch-weapon-row { position: absolute; right: 16px; bottom: max(150px, calc(var(--safe-bottom) + 130px)); display: grid; gap: 6px; }
.touch-weapon { display: grid; place-items: center; width: 46px; height: 46px; border: 1px solid #657083; border-radius: 12px; background: rgba(17,22,30,.82); color: white; transition: transform .12s, border-color .12s; }
.touch-weapon b { font-size: 14px; line-height: 1; }
.touch-weapon span { font-size: 10px; opacity: .72; }
.touch-weapon:active { transform: scale(.94); border-color: var(--cyan); background: rgba(40,52,72,.92); }
.touch-weapon.active { border-color: var(--cyan); background: linear-gradient(135deg, rgba(69,217,255,.24), rgba(124,92,255,.24)); }

.skill-svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; transform: rotate(-90deg); }
.skill-ring-bg { fill: none; stroke: rgba(255,255,255,.18); stroke-width: 4; }
.skill-ring-fg { fill: none; stroke: var(--cyan); stroke-width: 4; stroke-linecap: round; stroke-dasharray: 163.36; stroke-dashoffset: 163.36; transition: stroke-dashoffset .12s linear; }
.skill-cd { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; font: 800 22px/1 ui-monospace, monospace; color: #fff; text-shadow: 0 1px 3px rgba(0,0,0,.6); z-index: 2; }
.game-screen .touch-weapon-row { display: none !important; }
#touch-skill.cooling .skill-ring-fg { stroke: var(--magenta); }
#touch-skill.cooling > b, #touch-skill.cooling > span { opacity: .35; }

/* ===== Weapon selection overlay ===== */
.weapon-select-overlay { text-align: center; }
.weapon-select-overlay .eyebrow { color: var(--cyan); }
.weapon-select-overlay h2 { margin: 6px 0 4px; }
.weapon-select-hint { color: #8895a6; font-size: 13px; margin: 0 0 24px; }
.weapon-cards { display: flex; gap: 16px; margin-bottom: 24px; flex-wrap: nowrap; justify-content: center; max-width: 720px; margin-left: auto; margin-right: auto; }
.weapon-card { display: flex; flex-direction: column; align-items: center; gap: 8px; flex: 1 1 0; min-width: 0; max-width: 220px; padding: 24px 16px; border: 2px solid #2a3340; border-radius: 16px; background: rgba(17,22,30,.88); color: #d7e2ea; cursor: pointer; transition: border-color .2s, transform .2s, background .2s; }
.weapon-card:hover { border-color: #4a5666; transform: translateY(-3px); background: rgba(25,32,42,.92); }
.weapon-card.selected { border-color: var(--cyan); background: linear-gradient(135deg, rgba(69,217,255,.16), rgba(138,99,255,.16)); box-shadow: 0 0 30px rgba(69,217,255,.2); animation: card-select-ripple .5s ease-out, pop-in .3s ease-out; }
.weapon-card.selected .weapon-icon { color: var(--cyan); text-shadow: 0 0 16px var(--cyan); }
.weapon-card:active { transform: scale(.96) translateY(-2px); }
.weapon-icon { font-size: 36px; color: #657083; transition: color .2s; }
.weapon-card h3 { margin: 0; font-size: 18px; color: #fff; }
.weapon-card p { margin: 0; font-size: 12px; color: #8895a6; text-align: center; line-height: 1.5; }
.weapon-stats { list-style: none; padding: 0; margin: 4px 0 0; display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.weapon-stats li { font-size: 11px; padding: 3px 8px; border-radius: 6px; background: rgba(255,255,255,.06); color: #a0afc0; }
.weapon-select-overlay .primary-button:disabled { opacity: .4; cursor: not-allowed; }

/* ===== Skill orb HUD ===== */
.skill-orb-hud { position: absolute; top: max(130px, calc(var(--safe-top) + 120px)); right: 12px; width: 150px; padding: 10px 12px; border: 1px solid #2a3340; border-radius: 12px; background: rgba(11,14,20,.82); display: flex; align-items: center; gap: 10px; z-index: 50; transition: opacity .3s ease, transform .3s ease, box-shadow .3s ease; animation: orb-hud-in .35s ease-out; }
@keyframes orb-hud-in { from { opacity: 0; transform: translateX(20px) scale(.9); } to { opacity: 1; transform: translateX(0) scale(1); } }
.skill-orb-hud::before { content: ""; position: absolute; inset: -1px; border-radius: 13px; background: linear-gradient(135deg, var(--cyan), var(--violet)); z-index: -1; opacity: .3; transition: opacity .3s; }
.skill-orb-hud:hover::before { opacity: .6; }
.orb-icon { font-size: 20px; line-height: 1; }
.orb-info { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.orb-info b { font-size: 13px; color: #fff; }
.orb-info span { font-size: 11px; color: #8895a6; }
.orb-bar { height: 4px; border-radius: 2px; background: rgba(255,255,255,.1); overflow: hidden; }
.orb-bar i { display: block; height: 100%; background: var(--cyan); border-radius: 2px; transition: width .15s linear; }

/* ===== Combo display ===== */
.combo-display { position: absolute; top: 45%; left: 50%; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; pointer-events: none; z-index: 50; animation: combo-pop .3s ease-out; }
.combo-display b { font-size: 64px; font-weight: 900; color: #ffd23b; text-shadow: 0 0 30px rgba(255,210,59,.6), 0 4px 8px rgba(0,0,0,.5); line-height: 1; }
.combo-display span { font-size: 14px; font-weight: 700; color: #ffd23b; letter-spacing: .2em; }
@keyframes combo-pop { 0% { transform: translate(-50%, -50%) scale(.5); opacity: 0; } 50% { transform: translate(-50%, -50%) scale(1.15); } 100% { transform: translate(-50%, -50%) scale(1); opacity: 1; } }

@media (max-width: 620px) {
  .weapon-cards { flex-direction: column; gap: 10px; }
  .weapon-card { width: 100%; max-width: 280px; padding: 16px; }
  .skill-orb-hud { width: 130px; top: max(155px, calc(var(--safe-top) + 145px)); }
  .combo-display b { font-size: 48px; }
}

@keyframes mech-hover-mobile {
  0%, 100% { transform: translate(-50%,-50%) rotate(-8deg) scale(.82) translateY(0); }
  50% { transform: translate(-50%,-50%) rotate(-5deg) scale(.82) translateY(-8px); }
}
@keyframes mech-switch-mobile {
  from { opacity: .35; transform: translate(-50%,-50%) rotate(-18deg) scale(.7); }
  to { opacity: 1; transform: translate(-50%,-50%) rotate(-8deg) scale(.82); }
}

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; } }


/* 每日任务 */
.daily-tasks-section { padding: 0 28px 22px; border-bottom: 1px solid #303744; }
.daily-tasks-section .view-heading { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 14px; }
.daily-task-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.daily-task-card { padding: 14px; border: 1px solid var(--line); border-radius: 4px; background: #0b1018; display: grid; gap: 8px; }
.daily-task-card.done { border-color: var(--cyan); }
.daily-task-card.claimed { opacity: .55; }
.daily-task-info b { font-size: 14px; }
.daily-task-info small { display: block; color: var(--muted); font-size: 11px; margin-top: 3px; }
.daily-task-card .progress-track { height: 4px; }
.daily-task-actions { display: flex; align-items: center; justify-content: flex-end; }
.daily-task-actions button { padding: 6px 14px; font-size: 12px; }
.claimed-label { font-size: 12px; color: var(--muted); }

.join-bar { display: flex; gap: 10px; padding: 14px 28px; background: var(--ink-2); border-bottom: 1px solid var(--line); }
.join-bar .secondary-button { flex: 1; max-width: 220px; }

.modal-heading { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 18px; }
.modal-heading h2 { font-size: 22px; }
.modal-heading .modal-close { font-size: 22px; line-height: 1; padding: 2px 8px; }

.difficulty-cards { display: grid; gap: 12px; margin-bottom: 18px; }
.practice-hint { color: var(--muted); font-size: 12px; margin: -4px 0 14px; }
.difficulty-card { position: relative; display: grid; grid-template-columns: 90px 1fr; gap: 8px 16px; padding: 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: rgba(11,16,24,.6); color: var(--text-dim); text-align: left; cursor: pointer; transition: border-color var(--dur-1) var(--ease), background var(--dur-1) var(--ease); }
.difficulty-card:hover, .difficulty-card.active { border-color: rgba(69,217,255,.5); background: var(--surface-2); }
.difficulty-card .difficulty-badge { width: 90px; height: 90px; border-radius: 50%; display: grid; place-items: center; font-size: 18px; font-weight: 800; color: #fff; }
.difficulty-badge.easy { background: linear-gradient(135deg, rgba(184,242,74,.9), rgba(57,230,195,.7)); }
.difficulty-badge.normal { background: linear-gradient(135deg, rgba(69,217,255,.9), rgba(138,99,255,.75)); }
.difficulty-badge.hard { background: linear-gradient(135deg, rgba(255,76,163,.9), rgba(255,51,0,.7)); }
.difficulty-info { display: grid; gap: 4px; align-content: center; }
.difficulty-card b { font-size: 15px; color: var(--text); }
.difficulty-card small { font-size: 11px; color: var(--muted); display: block; margin-top: 2px; }
.difficulty-stats { display: grid; gap: 4px; margin-top: 8px; }
.difficulty-stats .stat { display: grid; grid-template-columns: 36px 1fr; align-items: center; gap: 8px; font-size: 10px; color: var(--muted); }
.difficulty-stats .stat > i { font-style: normal; }
.difficulty-stats .stat-bar { display: block; height: 5px; border-radius: 3px; background: #1f2632; overflow: hidden; }
.difficulty-stats .stat-bar > i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, #45d9ff, #8a63ff); }
.recommend-tag { position: absolute; top: 8px; right: 10px; padding: 2px 8px; border-radius: 10px; font-size: 10px; font-weight: 700; background: rgba(69,217,255,.16); color: #45d9ff; border: 1px solid rgba(69,217,255,.4); }
.recommend-tag.hot { background: rgba(255,87,87,.16); color: #ff7a7a; border-color: rgba(255,87,87,.4); }
.difficulty-card:hover { border-color: #45d9ff; background: #11192a; }
.difficulty-card.active { border-color: #45d9ff; background: rgba(69,217,255,.08); box-shadow: 0 0 0 1px #45d9ff inset; }

.rooms-dialog { max-width: 640px; }
.rooms-list { display: grid; gap: 10px; max-height: 50vh; overflow-y: auto; margin-bottom: 14px; }
.rooms-empty { color: #8f98a8; text-align: center; padding: 18px; }
.room-card { display: grid; gap: 6px; padding: 14px; border: 1px solid #2c3543; border-radius: 4px; background: #0e131c; color: #dce2ec; text-align: left; cursor: pointer; transition: border-color .18s ease, background .18s ease; }
.room-card:hover { border-color: #45d9ff; background: #131c2a; }
.room-card-head { display: flex; justify-content: space-between; align-items: center; }
.room-card-head b { font-size: 16px; font-family: ui-monospace, monospace; color: #45d9ff; }
.room-card-head span { font-size: 12px; color: #8f98a8; }
.room-card-meta { display: flex; gap: 14px; font-size: 11px; color: #b6bdca; }
.room-card-meta span { display: flex; align-items: center; gap: 4px; }

/* 优化13: 全屏房间面板 */
.host-panel-fullscreen { width: 100vw; max-width: 100vw; height: 100vh; max-height: 100vh; border: 0; border-radius: 0; background: #0a0d14; color: var(--text); padding: 0; display: none; flex-direction: column; }
.host-panel-fullscreen[open] { display: flex; }
.host-panel-fullscreen::backdrop { opacity: 0; background: transparent; }
.host-fs-header { display: flex; justify-content: space-between; align-items: center; padding: 16px 24px; border-bottom: 1px solid #1e2533; background: #0d1119; }
.host-fs-title h2 { font-size: 20px; margin: 0; }
.host-fs-title h2 code { color: var(--cyan); font-size: 16px; }
.host-fs-close { font-size: 24px; }
.host-fs-body { flex: 1; display: grid; grid-template-columns: 1fr 340px; gap: 20px; padding: 20px 24px; overflow-y: auto; }
.host-fs-left, .host-fs-right { display: flex; flex-direction: column; gap: 20px; }
.host-fs-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.host-stat-item { padding: 12px; border: 1px solid #2c3543; border-radius: 6px; background: #0b1018; text-align: center; }
.host-stat-item small { display: block; color: #8f98a8; font-size: 10px; margin-bottom: 4px; text-transform: uppercase; letter-spacing: 1px; }
.host-stat-item b { font-size: 15px; color: var(--cyan); }
.host-fs-section { background: #0d1119; border: 1px solid #1e2533; border-radius: 8px; padding: 16px; }
.host-fs-section h3 { font-size: 14px; margin: 0 0 12px 0; display: flex; align-items: center; gap: 8px; }
.host-fs-section h3 small { font-size: 11px; color: var(--muted); font-weight: 400; }
.host-fs-roster { display: grid; gap: 8px; }
.roster-card { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid #2c3543; border-radius: 6px; background: #0b1018; }
.roster-card.roster-bot { opacity: 0.7; border-style: dashed; }
.roster-card.roster-host { border-color: var(--cyan); }
.roster-skin { width: 32px; height: 32px; border-radius: 50%; border: 2px solid currentColor; flex-shrink: 0; }
.roster-skin[data-skin="nova"] { background: linear-gradient(135deg, #45d9ff, #8a63ff); }
.roster-skin[data-skin="pulse"] { background: linear-gradient(135deg, #ffb33b, #ff5d73); }
.roster-skin[data-skin="photon"] { background: linear-gradient(135deg, #9cff5a, #3ad9a3); }
.roster-skin[data-skin="drift"] { background: linear-gradient(135deg, #b85cff, #5c7cff); }
.roster-skin[data-skin="ember"] { background: linear-gradient(135deg, #ff5d5d, #ffb33b); }
.roster-info { flex: 1; min-width: 0; }
.roster-info b { font-size: 14px; display: block; }
.roster-info small { font-size: 11px; color: var(--muted); }
.roster-status { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }
.roster-status.online { background: #b8f24a; }
.roster-status.offline { background: #657083; }
.roster-empty { padding: 16px; text-align: center; color: var(--muted); font-size: 12px; border: 1px dashed #2c3543; border-radius: 6px; }
.host-ai-controls { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.host-ai-diff { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); }
.host-ai-diff select { padding: 8px 10px; border: 1px solid var(--line); border-radius: 4px; background: #0b1018; color: var(--text); font-size: 13px; }
.host-ai-buttons { display: flex; gap: 8px; }
.host-ai-note { font-size: 11px; color: var(--muted); margin: 10px 0 0 0; }
.host-ai-note b { color: var(--cyan); }
.host-invite-box { display: flex; flex-direction: column; gap: 10px; }
.host-invite-label { font-size: 12px; color: var(--muted); margin: 0; }
.host-share-row { display: flex; gap: 8px; }
.host-share-input { flex: 1; padding: 10px 12px; border: 1px solid #2c3543; border-radius: 6px; background: #0b1018; color: var(--cyan); font-family: ui-monospace, monospace; font-size: 14px; }
.host-password-display { font-size: 12px; color: var(--muted); margin: 0; }
.host-password-display code { color: var(--magenta); }
.host-admin-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.host-start-hint { font-size: 11px; color: var(--muted); margin: 8px 0 0 0; text-align: center; }
@media (max-width: 720px) {
  .host-fs-body { grid-template-columns: 1fr; }
  .host-fs-stats { grid-template-columns: repeat(2, 1fr); }
  .host-fs-header { padding: 12px 16px; }
  .host-fs-body { padding: 12px 16px; }
}

.lock-settings-body { display: grid; gap: var(--space-4); padding: 8px 0; }
.setting-row { display: flex; align-items: center; gap: var(--space-3); }
.setting-row label { font-size: 13px; color: var(--text); flex: 1; display: flex; align-items: center; gap: 8px; }
.setting-row label .icon-svg { color: var(--muted); }
.setting-row input[type="range"] { flex: 1.6; }
.setting-row select { min-width: 0; flex: 1.2; }
.setting-row span { font-size: 12px; color: var(--muted); min-width: 32px; text-align: right; font-variant-numeric: tabular-nums; }
.setting-hint { font-size: 11px; color: var(--muted); line-height: 1.6; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: rgba(6,7,12,.4); margin: 0; }

#host-code { background: rgba(6,7,12,.5); padding: 4px 10px; border-radius: var(--radius-sm); border: 1px solid var(--line); color: var(--cyan); font-family: var(--font-num); font-size: 16px; letter-spacing: 1px; }

/* —— 音频设置面板(精致小卡规格) —— */
/* —— 音频设置面板(精致小卡规格; 非 modal 常驻可调, 固定居中避免"先右下后居中"跳动) —— */
.audio-panel { max-width: 430px; position: fixed; top: 50%; left: 50%; margin: 0; transform: translate(-50%, -50%); }
.audio-panel[open] { animation: modal-pop-center var(--dur-2) var(--ease); }
.audio-panel[open]::backdrop { opacity: 0; }
@keyframes modal-pop-center {
  0% { opacity: 0; transform: translate(-50%, calc(-50% + 8px)) scale(.96); }
  100% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}
.audio-settings { display: grid; gap: var(--space-4); padding: var(--space-1) 0; }
.audio-settings .setting-row { padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: rgba(6,7,12,.4); }
.audio-settings .setting-row .row-icon { width: 28px; height: 28px; flex: none; display: grid; place-items: center; border-radius: var(--radius-sm); background: rgba(69,217,255,.08); color: var(--cyan); }
.audio-settings .setting-row input[type="range"] { flex: 2; }
.audio-settings .setting-row span { min-width: 44px; font-size: 13px; color: var(--cyan); font-family: var(--font-num); font-weight: 600; }
.audio-switch-row { display: flex; align-items: center; gap: var(--space-3); padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: rgba(6,7,12,.4); }
.audio-switch-row .row-icon { width: 28px; height: 28px; flex: none; display: grid; place-items: center; border-radius: var(--radius-sm); background: rgba(69,217,255,.08); color: var(--cyan); }
.audio-switch-row span { flex: 1; font-size: 13px; color: var(--text); }
#audio-test { margin-top: var(--space-1); }

/* 赛季系统 */
.season-badge-row { display: flex; gap: 12px; align-items: center; margin: 12px 0; padding: 10px; border: 1px solid var(--line); border-radius: 4px; background: #0b1018; }
.season-tier-badge { display: flex; align-items: center; gap: 10px; }
.season-tier-badge .tier-icon { width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; border-radius: 50%; font-size: 18px; background: linear-gradient(135deg, #45d9ff33, #7c5cff33); border: 1px solid var(--cyan); color: var(--cyan); }
.season-tier-badge .tier-info small { display: block; color: var(--muted); font-size: 10px; }
.season-tier-badge .tier-info b { font-size: 14px; }
.season-progress { flex: 1; }
.season-progress small { display: block; color: var(--muted); font-size: 10px; margin-bottom: 4px; }
.season-progress .progress-track { height: 4px; }

.season-hero { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; margin-bottom: 20px; }
.season-hero-tier, .season-hero-progress, .season-hero-next { padding: 18px; border: 1px solid var(--line); border-radius: 4px; background: #0b1018; }
.season-hero-tier { display: flex; align-items: center; gap: 14px; }
.tier-icon.big { width: 56px; height: 56px; font-size: 28px; }
.season-hero-tier small, .season-hero-progress small, .season-hero-next small { display: block; color: var(--muted); font-size: 11px; }
.season-hero-tier b, .season-hero-next b { font-size: 18px; }
.season-hero-progress .progress-track { height: 6px; margin: 8px 0; }
.season-hero-next { text-align: center; }

.tier-ladder { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin-bottom: 24px; }
.tier-card { padding: 12px; border: 1px solid var(--line); border-radius: 4px; background: #0b1018; text-align: center; transition: all .2s; }
.tier-card.earned { border-color: var(--cyan); background: linear-gradient(135deg, #45d9ff11, #7c5cff11); }
.tier-card.current { border-color: #ffd23b; box-shadow: 0 0 12px #ffd23b33; }
.tier-card .tier-icon { width: 32px; height: 32px; margin: 0 auto 8px; font-size: 16px; }
.tier-card b { font-size: 13px; }
.tier-card small { display: block; color: var(--muted); font-size: 10px; margin-top: 4px; }

/* 优化20: 赛季统计卡片 */
.season-stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 10px; margin-bottom: 24px; }
.season-stat-card { padding: 14px; border: 1px solid var(--line); border-radius: 8px; background: #0b1018; text-align: center; }
.season-stat-card small { display: block; color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 6px; }
.season-stat-card b { display: block; font-size: 22px; color: var(--cyan); margin-bottom: 4px; }
.season-stat-card span { font-size: 10px; color: var(--muted); }

.season-leaderboard { margin-top: 20px; }

/* 赛季奖励横幅 */
.season-reward-banner { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 22px; margin-bottom: 20px; border: 1px solid #ffd23b55; border-radius: 4px; background: linear-gradient(135deg, #1a1610, #0e131c); }
.reward-banner-info h3 { font-size: 18px; color: #ffd23b; }
.reward-banner-info p { font-size: 13px; margin: 4px 0; }
.reward-list { list-style: none; padding: 0; margin: 8px 0 0; }
.reward-list li { font-size: 12px; color: #dce2ec; padding: 2px 0; }
.reward-list li::before { content: '◆ '; color: #ffd23b; }
.season-history { margin-top: 24px; }

/* 好友系统 */
.friend-add { display: flex; gap: 10px; margin-bottom: 16px; }
.friend-add label { flex: 1; }
.friend-requests { margin-bottom: 24px; }
.friend-requests h3, .friend-list h3 { font-size: 15px; margin-bottom: 12px; }
.friend-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; }
.friend-card { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border: 1px solid var(--line); border-radius: 4px; background: #0b1018; }
.friend-card-info { display: flex; align-items: center; gap: 10px; }
.friend-avatar { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, #45d9ff, #7c5cff); display: flex; align-items: center; justify-content: center; font-weight: bold; color: #0b1018; }
.friend-card b { font-size: 14px; }
.friend-card small { display: block; color: var(--muted); font-size: 11px; }
.friend-card .online-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; margin-right: 4px; }
.friend-card .online-dot.online { background: #45d9ff; box-shadow: 0 0 6px #45d9ff; }
.friend-card .online-dot.offline { background: #5a6478; }
.friend-card-actions { display: flex; gap: 6px; }
.friend-card-actions button { padding: 6px 12px; font-size: 11px; }

@media (max-width: 720px) {
  .entry-cards { grid-template-columns: 1fr; gap: 10px; padding: 14px; }
  .entry-card { padding: 14px; }
  .entry-card .entry-icon { width: 36px; height: 36px; font-size: 18px; }
  .entry-card .entry-body b { font-size: 14px; }
  .entry-card .entry-body small { font-size: 10px; }
  .daily-tasks-section { padding: 0 14px 18px; }
  .daily-task-cards { grid-template-columns: 1fr; }
  .join-bar { padding: 10px 14px; }
  .difficulty-card { grid-template-columns: 70px 1fr; padding: 12px; }
  .difficulty-card .difficulty-badge { width: 70px; height: 70px; font-size: 14px; }
  .season-hero { grid-template-columns: 1fr; gap: 10px; }
  .season-badge-row { flex-direction: column; align-items: stretch; gap: 10px; }
  .tier-ladder { grid-template-columns: repeat(2, 1fr); }
  .friend-add { flex-direction: column; }
  .season-reward-banner { flex-direction: column; text-align: center; }
}

/* ========== 美术圣经 v2: 内联图标 + 空港机甲立绘 + 质感微调 ========== */
.icon-svg { display: inline-block; vertical-align: -3px; flex: none; }
.icon-button .icon-svg { display: block; margin: auto; }
.wallet-coins .icon-svg, .wallet-gems .icon-svg { color: #b5bdca; }
.wallet-coins .icon-svg { color: #ffd23b; }
.wallet-gems .icon-svg { color: #b8f2ff; }
.toast-icon .icon-svg, .toast .icon-svg { color: currentColor; }
.empty-state-icon .icon-svg { opacity: .8; }
.mech-art svg { width: 100%; height: 100%; filter: drop-shadow(0 0 30px rgba(69,217,255,.30)); }
.lobby-screen[data-mode="core_rush"] .mech-art svg { filter: drop-shadow(0 0 30px rgba(255,179,59,.30)); }
.lobby-screen[data-mode="storm_survival"] .mech-art svg { filter: drop-shadow(0 0 30px rgba(255,76,163,.32)); }

/* ========== 美术圣经 v2: 机甲精灵统一预览(商城/空港/档案与局内同源) ========== */
.mech-sprite { display: block; width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 16px 20px rgba(0,0,0,.55)); pointer-events: none; user-select: none; }
.shop-card .skin-preview .mech-sprite { transform: rotate(-18deg) scale(1.06); }
.skin-preview .mech-sprite { animation: sprite-hover 3.6s ease-in-out infinite; }
@keyframes sprite-hover { 0%, 100% { translate: 0 0; } 50% { translate: 0 -6px; } }
.skin-thumb { position: relative; width: 64px; height: 64px; border-radius: 10px; border: 1px solid #3c4554; background: radial-gradient(circle at 50% 42%, rgba(69,217,255,.12), rgba(16,22,32,.75)); overflow: hidden; }
.skin-thumb .mech-sprite { transform: rotate(-18deg) scale(1.18); }
.profile-skin-item.locked .skin-thumb { filter: grayscale(.85) brightness(.6); }


/* ========== UI重设计: 作战页二级菜单向导 ========== */
.battle-launch { display: grid; grid-template-columns: 1fr 1fr 1.2fr; gap: var(--space-5); }
@media (max-width: 900px) {
}

/* ========== UI重设计: 对战页双板块 + 玩法弹窗 + 房间页 ========== */
.duo-boards { display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-4); padding: var(--space-4) 28px var(--space-5); }
.board-card { position: relative; display: flex; align-items: center; gap: var(--space-4); padding: var(--space-5); border: 1px solid var(--line); border-radius: var(--radius); background: linear-gradient(160deg, rgba(16,20,30,.88), rgba(10,13,20,.94)); cursor: pointer; overflow: hidden; transition: border-color var(--dur-2) var(--ease), box-shadow var(--dur-2) var(--ease), transform var(--dur-2) var(--ease); }
.board-card::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 2px; background: linear-gradient(90deg, transparent, var(--board-accent, var(--cyan)), transparent); opacity: .4; transition: opacity var(--dur-2) var(--ease); }
.board-card::after { content: ""; position: absolute; right: -70px; bottom: -70px; width: 190px; height: 190px; border-radius: 50%; background: radial-gradient(circle, var(--board-accent, var(--cyan)), transparent 70%); opacity: 0; transition: opacity var(--dur-3) var(--ease); pointer-events: none; }
.board-solo { --board-accent: #45d9ff; --board-accent-2: #2f7bff; }
.board-team { --board-accent: #b85cff; --board-accent-2: #ff4ca3; }
.board-icon-tile { flex: 0 0 auto; width: 58px; height: 58px; display: grid; place-items: center; font-size: 26px; border-radius: 14px; background: linear-gradient(140deg, var(--board-accent), var(--board-accent-2)); box-shadow: 0 6px 24px rgba(0,0,0,.45), inset 0 1px 0 rgba(255,255,255,.25); }
.board-body { flex: 1; min-width: 0; }
.board-card h3 { margin: 0; font-size: 21px; font-family: var(--font-display); font-weight: 700; color: var(--text); display: flex; align-items: baseline; gap: 8px; }
.board-card h3 small { font-size: 10px; letter-spacing: 2.5px; color: var(--muted); font-weight: 700; }
.board-card p { margin: 5px 0 9px; color: var(--muted); font-size: 12.5px; line-height: 1.5; }
.board-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.board-tags span { padding: 3px 10px; border: 1px solid var(--line-2); border-radius: 999px; font-size: 10.5px; color: var(--muted); }
.board-cta { flex: 0 0 auto; display: inline-flex; align-items: center; gap: 6px; padding: 9px 15px; border: 1px solid var(--line-2); border-radius: 999px; font-size: 12px; color: var(--board-accent, var(--cyan)); font-weight: 700; letter-spacing: .5px; white-space: nowrap; transition: all var(--dur-2) var(--ease); }
.board-cta i { font-style: normal; transition: transform var(--dur-2) var(--ease); }
.board-card:hover { border-color: var(--board-accent); transform: translateY(-3px); box-shadow: 0 18px 48px rgba(0,0,0,.4), 0 0 0 1px var(--board-accent); }
.board-card:hover::before { opacity: 1; }
.board-card:hover::after { opacity: .14; }
.board-card:hover .board-cta { border-color: transparent; color: #fff; background: linear-gradient(120deg, var(--board-accent), var(--board-accent-2)); }
.board-card:hover .board-cta i { transform: translateX(4px); }
.ptm-body { display: grid; gap: var(--space-4); margin-bottom: var(--space-4); }
.ptm-plays { display: grid; gap: var(--space-2); }
.ptm-play { display: grid; gap: 2px; padding: 12px 16px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); color: var(--text-dim); text-align: left; cursor: pointer; transition: all var(--dur-1) var(--ease); }
.ptm-play b { font-size: 14px; color: var(--text); }
.ptm-play small { font-size: 11px; color: var(--muted); }
.ptm-play:hover { border-color: var(--line-2); background: var(--surface-3); }
.ptm-play.active { border-color: rgba(69,217,255,.55); background: rgba(69,217,255,.06); box-shadow: inset 2px 0 0 var(--cyan); }
.ptm-play.active b { color: var(--cyan); }
.ptm-config .bl-sub.hidden { display: none; }
.ptm-config .bl-sub-label { margin: 0 0 var(--space-2); color: var(--muted); font-size: 11px; font-weight: 700; }
.ptm-config .bl-diffs { display: flex; gap: var(--space-2); }
.ptm-config .bl-diff { flex: 1; padding: 9px 0; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: var(--surface-2); color: var(--muted); font-size: 12px; font-weight: 700; cursor: pointer; text-align: center; transition: all var(--dur-1) var(--ease); }
.ptm-config .bl-diff:hover { border-color: var(--line-2); color: var(--text); }
.ptm-config .bl-diff.active { border-color: rgba(69,217,255,.55); background: rgba(69,217,255,.1); color: var(--cyan); }
#ptm-start { width: 100%; font-size: 16px; }
/* —— 玩法弹窗: 会战模式选择行 —— */
.ptm-modes { display: flex; flex-wrap: wrap; gap: var(--space-2); }
.ptm-mode { flex: 1 1 calc(33% - var(--space-2)); padding: 10px 0; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); color: var(--muted); font-size: 12px; font-weight: 700; cursor: pointer; text-align: center; transition: all var(--dur-1) var(--ease); }
.ptm-mode:hover { border-color: var(--line-2); color: var(--text); }
.ptm-mode.active { border-color: rgba(69,217,255,.55); background: rgba(69,217,255,.08); color: var(--cyan); }
/* —— 房间页: 团队匹配入口条 —— */
.party-queue-bar { display: flex; align-items: center; gap: var(--space-4); flex-wrap: wrap; padding: var(--space-3) 0 var(--space-4); }
.party-queue-bar .kv-line { margin: 0; flex: 1; min-width: 200px; }
.party-queue-bar .btn-primary { flex-shrink: 0; }
/* —— 房间页 .btn 家族(此前缺失定义导致裸样式) —— */
.btn { min-height: 40px; border: 1px solid var(--line-2); border-radius: var(--radius-sm); padding: 0 16px; background: var(--surface-2); color: var(--text-dim); font-weight: 700; letter-spacing: .3px; cursor: pointer; transition: all var(--dur-1) var(--ease); }
.btn:hover { border-color: var(--cyan); color: var(--text); transform: translateY(-1px); }
.btn:disabled { cursor: not-allowed; filter: grayscale(.7); opacity: .5; }
.btn-sm { min-height: 34px; padding: 0 14px; font-size: 12px; }
.btn-primary { border-color: rgba(69,217,255,.55); background: linear-gradient(135deg, rgba(69,217,255,.18), rgba(138,99,255,.18)); color: var(--cyan); }
.btn-primary:hover { border-color: var(--cyan); background: linear-gradient(135deg, rgba(69,217,255,.28), rgba(138,99,255,.28)); color: #bdeeff; box-shadow: 0 8px 26px rgba(69,217,255,.22); }
.btn-ghost { border-color: transparent; background: transparent; color: var(--muted); }
.btn-ghost:hover { border-color: var(--line-2); color: var(--text); }

/* —— 按钮: 大号出战按钮(醒目配色, 非灰色) —— */
.btn-start {
  min-height: 50px; padding: 0 36px;
  border: 0; border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--cyan), var(--violet));
  color: #fff; font-size: 16px; font-weight: 800; letter-spacing: 1.5px;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(69,217,255,.35), inset 0 1px 0 rgba(255,255,255,.2);
  transition: transform var(--dur-1) var(--ease), box-shadow var(--dur-1) var(--ease), filter var(--dur-1) var(--ease);
}
.btn-start:hover { transform: translateY(-2px); box-shadow: 0 8px 30px rgba(69,217,255,.45), inset 0 1px 0 rgba(255,255,255,.3); filter: brightness(1.1); }
.btn-start:active { transform: translateY(1px); box-shadow: 0 2px 10px rgba(69,217,255,.2); }

/* —— 登录页入场动效 —— */
.auth-panel { animation: auth-panel-in .6s var(--ease) both; }
@keyframes auth-panel-in {
  0% { opacity: 0; transform: translateY(24px) scale(.98); }
  100% { opacity: 1; transform: none; }
}
.auth-panel .auth-tabs { animation: auth-fade .5s var(--ease) .15s both; }
.auth-panel .form-stack { animation: auth-fade .5s var(--ease) .25s both; }
.auth-panel .primary-button { animation: auth-fade .5s var(--ease) .35s both; }
.auth-brand { animation: auth-brand-in .7s var(--ease) both; }
@keyframes auth-brand-in {
  0% { opacity: 0; transform: translateX(-16px); }
  100% { opacity: 1; transform: none; }
}
.auth-foot { animation: auth-fade .5s var(--ease) .5s both; }
@keyframes auth-fade {
  0% { opacity: 0; transform: translateY(8px); }
  100% { opacity: 1; transform: none; }
}
/* —— 房间页: 房间列表 + 详情 + 操作栏(参照经典射击游戏房间大厅) —— */
.rooms-layout { display: grid; grid-template-columns: 1fr 300px; gap: var(--space-4); align-items: stretch; }
.rooms-list-panel { display: flex; flex-direction: column; }
.rooms-page-count { color: var(--muted); font-size: 12px; }
.rooms-page-list { display: flex; flex-direction: column; gap: 8px; max-height: 46vh; overflow-y: auto; padding-right: 4px; }
.room-row { display: grid; grid-template-columns: 92px 1fr 100px 84px; align-items: center; gap: 10px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); cursor: pointer; text-align: left; transition: all var(--dur-1) var(--ease); }
.room-row:hover { border-color: var(--line-2); background: var(--surface-3); }
.room-row.selected { border-color: rgba(69,217,255,.55); background: rgba(69,217,255,.07); box-shadow: inset 3px 0 0 var(--cyan); }
.room-row-code { font-weight: 700; font-size: 15px; color: var(--text); letter-spacing: 1.5px; }
.room-row-mode { color: var(--text-dim); font-size: 13px; font-weight: 600; }
.room-row-players { color: var(--muted); font-size: 12px; }
.room-row-state { font-size: 11px; text-align: center; padding: 3px 0; border-radius: 999px; border: 1px solid var(--line-2); color: var(--muted); }
.room-row-state.waiting { color: #7dff9e; border-color: rgba(125,255,158,.3); }
.room-row-state.running { color: #ffd18a; border-color: rgba(255,209,138,.3); }
.rooms-empty { color: var(--muted); text-align: center; padding: 44px 0; }
.room-brief-panel { display: flex; flex-direction: column; }
.room-brief { display: grid; gap: var(--space-2); min-height: 190px; align-content: start; margin-bottom: var(--space-3); }
.room-brief-code { font-size: 27px; font-weight: 800; letter-spacing: 4px; color: var(--text); }
.room-brief-row { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); }
.room-brief-row b { color: var(--text-dim); font-weight: 600; }
.rooms-actions { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); margin-top: var(--space-4); padding-top: var(--space-4); border-top: 1px solid var(--line); }
.rooms-actions-right { display: flex; gap: var(--space-3); }
.create-room-form { min-width: 380px; }
.tool-form { display: grid; gap: var(--space-3); }
@media (max-width: 720px) {
  .duo-boards { grid-template-columns: 1fr; padding: var(--space-4) 14px; }
  .rooms-layout { grid-template-columns: 1fr; }
  .rooms-actions { flex-direction: column; align-items: stretch; }
}

/* ===== 好友中心 v2(F1): 工具条/申请卡/好友网格/角标 ===== */
.friend-toolbar { display: flex; gap: var(--space-3); align-items: center; margin-bottom: var(--space-3); }
.friend-search-wrap { position: relative; flex: 1; display: flex; align-items: center; }
.friend-search-icon { position: absolute; left: 12px; width: 16px; height: 16px; color: var(--muted); pointer-events: none; }
.friend-search-wrap input { width: 100%; padding-left: 36px; }
.friend-search-results { position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: var(--z-nav); background: var(--surface-2); border: 1px solid var(--line-2); border-radius: var(--radius-sm); box-shadow: 0 12px 32px rgba(0,0,0,.5); overflow: hidden; }
.friend-search-row { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-bottom: 1px solid var(--line); cursor: pointer; }
.friend-search-row:last-child { border-bottom: none; }
.friend-search-row:hover { background: var(--surface-3); }
.friend-search-row .friend-avatar { width: 30px; height: 30px; font-size: 13px; }
.friend-search-row .s-name { font-size: 13px; }
.friend-search-row .s-name small { color: var(--muted); margin-left: 6px; font-weight: 400; }
.friend-search-row .s-tier { margin-left: auto; font-size: 10px; padding: 2px 8px; border-radius: var(--radius-pill); border: 1px solid var(--line-2); color: var(--text-dim); }
.friend-search-empty { padding: 12px; color: var(--muted); font-size: 12px; text-align: center; }
.friend-shortid { font-family: var(--font-display); letter-spacing: 2px; font-weight: 600; }
.friend-count-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 18px; height: 18px; padding: 0 5px; margin-left: 8px; border-radius: var(--radius-pill); background: var(--magenta); color: #fff; font-size: 11px; font-weight: 700; vertical-align: 2px; }
.friend-count-plain { margin-left: 8px; color: var(--muted); font-size: 12px; font-weight: 400; }
.friend-list h3, .friend-requests h3 { display: flex; align-items: center; }
.friend-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 10px; }
.friend-card { display: flex; align-items: center; justify-content: space-between; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); transition: border-color var(--dur-1) var(--ease), transform var(--dur-1) var(--ease); }
.friend-card:hover { border-color: var(--line-2); transform: translateY(-1px); }
.friend-card.pinned { border-color: rgba(255, 210, 59, .35); }
.friend-card .friend-avatar { position: relative; width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(135deg, var(--cyan), var(--violet)); display: flex; align-items: center; justify-content: center; font-weight: 700; color: var(--ink); overflow: visible; }
.friend-card .friend-avatar img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.friend-card .pin-flag { position: absolute; top: -4px; right: -4px; width: 14px; height: 14px; color: var(--gold); }
.friend-card .online-dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; flex: none; }
.friend-card .online-dot.online { background: var(--cyan); box-shadow: 0 0 6px var(--cyan); }
.friend-card .online-dot.inmatch { background: var(--magenta); box-shadow: 0 0 6px var(--magenta); }
.friend-card .online-dot.offline { background: var(--muted-2); }
.friend-meta-row { display: flex; align-items: center; gap: 6px; margin-top: 2px; }
.friend-group-tag { font-size: 10px; padding: 1px 7px; border-radius: var(--radius-pill); border: 1px solid var(--line-2); color: var(--muted); }
.friend-status-text { font-size: 11px; color: var(--muted); }
.friend-status-text.online { color: var(--cyan); }
.friend-status-text.inmatch { color: var(--magenta); }
.friend-card-actions { display: flex; gap: 6px; align-items: center; }
.friend-card-actions button { padding: 6px 10px; font-size: 11px; }
.friend-more-wrap { position: relative; }
.friend-more-menu { position: absolute; right: 0; top: calc(100% + 4px); z-index: var(--z-nav); min-width: 132px; background: var(--surface-2); border: 1px solid var(--line-2); border-radius: var(--radius-sm); padding: 4px; box-shadow: 0 12px 32px rgba(0,0,0,.5); }
.friend-more-menu button { display: block; width: 100%; text-align: left; padding: 8px 10px; font-size: 12px; background: none; border: none; color: var(--text-dim); border-radius: 6px; cursor: pointer; }
.friend-more-menu button:hover { background: var(--surface-3); color: var(--text); }
.friend-more-menu button.danger { color: var(--danger); }
.request-note { margin-top: 2px; font-size: 11px; color: var(--muted); }
.request-source { font-size: 10px; color: var(--muted-2); }
.nav-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 16px; height: 16px; margin-left: 6px; padding: 0 4px; border-radius: var(--radius-pill); background: var(--magenta); color: #fff; font-size: 10px; font-weight: 700; vertical-align: 1px; }
.ptab-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 15px; height: 15px; margin-left: 5px; padding: 0 4px; border-radius: var(--radius-pill); background: var(--magenta); color: #fff; font-size: 10px; font-weight: 700; }
.nav-badge.hidden, .ptab-badge.hidden { display: none; }
@media (max-width: 720px) {
  .friend-toolbar { flex-direction: column; align-items: stretch; }
  .friend-grid { grid-template-columns: 1fr; }
}
/* 好友中心图标尺寸约束(符号表 SVG 无全局默认尺寸) */
.friend-shortid .icon { width: 14px; height: 14px; flex: none; margin-right: 6px; }
.friend-search-icon { width: 15px; height: 15px; }
/* 全局 input 规则带 :not() 双伪类特异性更高, 用 ID 选择器保证搜索框留出图标位 */
#friend-search { padding-left: 36px; }
/* ===== 星际信箱(邮件系统 X1) ===== */
.mail-button { position: relative; display: inline-flex; align-items: center; justify-content: center; color: var(--text-dim); }
.mail-panel { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); width: min(560px, calc(100vw - 32px)); max-height: min(640px, calc(100vh - 48px)); margin: 0; padding: 0; border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--surface); color: var(--text); overflow: hidden; }
.mail-panel[open] { animation: modal-pop var(--dur-2) var(--ease); }
.mail-panel::backdrop { background: rgba(3, 4, 8, .55); backdrop-filter: blur(6px); }
.mail-panel-head { display: flex; align-items: center; justify-content: space-between; padding: var(--space-4) var(--space-5); border-bottom: 1px solid var(--line); }
.mail-head-actions { display: flex; gap: var(--space-2); align-items: center; }
.mail-panel .icon-button { width: 32px; height: 32px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--surface-2); color: var(--text-dim); font-size: 16px; }
.mail-list { max-height: min(520px, calc(100vh - 160px)); overflow-y: auto; padding: var(--space-3) var(--space-4) var(--space-4); display: grid; gap: var(--space-2); }
.mail-item { border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); overflow: hidden; }
.mail-item.unread { border-left: 3px solid var(--cyan); }
.mail-item .mail-row { display: flex; align-items: center; gap: 10px; padding: 12px 14px; cursor: pointer; }
.mail-item .mail-icon { width: 30px; height: 30px; flex: none; display: flex; align-items: center; justify-content: center; border-radius: 8px; background: var(--surface-3); color: var(--cyan); }
.mail-item .mail-icon svg { width: 15px; height: 15px; }
.mail-item.type-system .mail-icon { color: var(--gold); }
.mail-item.type-notice .mail-icon { color: var(--muted); }
.mail-item .mail-title { font-size: 13px; font-weight: 600; }
.mail-item .mail-title small { margin-left: 8px; color: var(--muted); font-weight: 400; }
.mail-item .mail-date { margin-left: auto; font-size: 11px; color: var(--muted-2); font-family: var(--font-display); }
.mail-item .mail-claim { padding: 5px 12px; font-size: 11px; }
.mail-item .mail-body { padding: 0 14px 12px 54px; font-size: 12px; color: var(--text-dim); }
.mail-item .mail-attach { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.mail-item .mail-attach span { display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: var(--radius-pill); border: 1px solid var(--line-2); font-size: 11px; color: var(--amber); }
.mail-item.claimed .mail-attach span { color: var(--muted); }
.mail-empty { padding: var(--space-6); text-align: center; color: var(--muted); font-size: 13px; }
/* ===== 赛季战队(G1) ===== */
.clan-season-row { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-3); padding: 10px 14px; margin-top: 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); }
.clan-tier-badge { font-size: 12px; font-weight: 700; padding: 3px 12px; border-radius: var(--radius-pill); border: 1px solid; }
.clan-season-points, .clan-season-rank { font-size: 12px; color: var(--muted); }
.clan-season-points b, .clan-season-rank b { color: var(--text); font-family: var(--font-display); font-size: 15px; margin-left: 2px; }
.clan-protect-tag { font-size: 10px; padding: 2px 9px; border-radius: var(--radius-pill); background: rgba(255, 76, 163, .12); color: var(--magenta); }
.clan-kick-btn { color: var(--danger); }
/* ===== 飞行日志(MR1) ===== */
.match-logs { display: grid; gap: 6px; margin-top: 8px; }
.mh-row { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); color: var(--text-dim); font-size: 12px; text-align: left; cursor: pointer; transition: border-color var(--dur-1) var(--ease); }
.mh-row:hover { border-color: var(--line-2); }
.mh-mode { color: var(--text); font-weight: 600; }
.mh-queue { color: var(--muted); }
.mh-badge { padding: 2px 9px; border-radius: var(--radius-pill); border: 1px solid var(--line-2); color: var(--text-dim); }
.mh-badge.win { border-color: rgba(184, 242, 74, .5); color: var(--lime); }
.mh-badge.deserted { border-color: rgba(255, 93, 115, .5); color: var(--danger); }
.mh-kills { margin-left: auto; }
.mh-date { font-family: var(--font-display); color: var(--muted-2); }
.mh-deserted { color: var(--danger); }
.mh-filters { margin-bottom: 10px; }
.mh-filters select { width: 160px; }
.mh-list { display: grid; gap: 6px; max-height: 50vh; overflow-y: auto; }
/* ===== 羁绊系统(F2) ===== */
.bond-wrap { display: inline-flex; align-items: center; gap: 5px; }
.bond-bar { display: inline-block; width: 56px; height: 4px; border-radius: 2px; background: var(--line); overflow: hidden; }
.bond-bar b { display: block; height: 100%; border-radius: 2px; background: linear-gradient(90deg, var(--cyan), var(--gold)); }
.bond-tier { font-size: 10px; font-style: normal; }
.friend-like-btn { display: inline-flex; align-items: center; gap: 3px; }
.friend-like-btn .icon { width: 12px; height: 12px; color: var(--magenta); }
.gift-row { display: flex; align-items: center; gap: 8px; padding: 6px 0; }
/* ===== 聊天富化(C1): 快捷短语/轮盘/卡片 ===== */
.chat-quick-phrases { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 12px 0; }
.chat-phrase-chip { padding: 4px 12px; border: 1px solid var(--line-2); border-radius: var(--radius-pill); background: var(--surface-2); color: var(--text-dim); font-size: 11px; cursor: pointer; transition: all var(--dur-1) var(--ease); }
.chat-phrase-chip:hover { border-color: rgba(69, 217, 255, .5); color: var(--cyan); }
.chat-quick-tag { color: var(--cyan) !important; }
.chat-card { margin-top: 4px; display: inline-block; min-width: 200px; padding: 10px 14px; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: var(--surface-2); text-align: left; }
.chat-card b { font-size: 12px; color: var(--amber); }
.chat-card p { margin: 4px 0 8px; font-size: 12px; color: var(--text-dim); }
.quick-chat-btn { position: absolute; right: 16px; bottom: 96px; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line-2); background: rgba(6, 8, 13, .8); color: var(--text-dim); display: flex; flex-direction: column; align-items: center; justify-content: center; font-size: 10px; z-index: var(--z-content); }
.quick-wheel { position: absolute; right: 70px; bottom: 80px; z-index: var(--z-content); display: grid; grid-template-columns: repeat(2, 1fr); gap: 6px; padding: 10px; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: rgba(6, 8, 13, .92); }
.quick-wheel-item { padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface-2); color: var(--text-dim); font-size: 12px; cursor: pointer; white-space: nowrap; }
.quick-wheel-item:hover { border-color: var(--cyan); color: var(--cyan); }
/* ===== 星轨战令(P1) ===== */
.pass-head { display: flex; align-items: center; gap: var(--space-4); padding: var(--space-4); border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); flex-wrap: wrap; }
.pass-level-box { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 64px; height: 64px; border-radius: var(--radius); background: linear-gradient(135deg, rgba(69, 217, 255, .18), rgba(138, 99, 255, .18)); border: 1px solid var(--line-2); }
.pass-level-box b { font-family: var(--font-display); font-size: 26px; color: var(--cyan); }
.pass-level-box small { color: var(--muted); font-size: 10px; }
.pass-progress { flex: 1; min-width: 200px; display: grid; gap: 6px; }
.pass-progress-top { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); }
.pass-bar { display: block; width: 100%; height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.pass-bar b { display: block; height: 100%; background: linear-gradient(90deg, var(--cyan), var(--gold)); border-radius: 3px; }
.pass-actions { display: flex; flex-direction: column; gap: 6px; align-items: stretch; }
.pass-owned-tag { padding: 6px 14px; border-radius: var(--radius-pill); border: 1px solid var(--gold); color: var(--gold); font-size: 12px; text-align: center; }
.pass-track { display: flex; gap: 6px; overflow-x: auto; padding: var(--space-3) 0; }
.pass-cell { flex: none; width: 92px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); padding: 8px; text-align: center; }
.pass-cell.current { border-color: var(--cyan); box-shadow: 0 0 10px rgba(69, 217, 255, .25); }
.pass-cell-level { font-family: var(--font-display); font-weight: 700; color: var(--text); font-size: 14px; }
.pass-cell-free, .pass-cell-prem { margin-top: 6px; padding: 6px 4px; border-radius: 6px; font-size: 11px; min-height: 42px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; }
.pass-cell-free { background: rgba(184, 242, 74, .05); }
.pass-cell-prem { background: rgba(255, 210, 59, .05); }
.pass-cell-prem.locked { opacity: .45; }
.pass-rw { display: inline-flex; align-items: center; gap: 3px; color: var(--text-dim); }
.pass-rw.unlock { color: var(--gold); }
.pass-claimed { color: var(--lime); }
.pass-weekly { margin-top: var(--space-4); display: grid; gap: 8px; }
.pass-weekly h4 small { color: var(--muted); font-weight: 400; }
.pass-weekly-row { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); font-size: 12px; }
.pass-weekly-row span:first-child { min-width: 150px; }
/* ===== 兑换中心修复(溢出+弹窗层级) ===== */
#recharge-dialog { max-height: min(640px, calc(100vh - 48px)); overflow-y: auto; }
#recharge-dialog .recharge-packages { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; margin-bottom: 14px; }
#recharge-dialog .recharge-order-item { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 6px; margin-bottom: 6px; font-size: 12px; background: var(--surface-2); flex-wrap: wrap; }
/* toast 在原生 dialog 上层: dialog 是 top-layer, toast 容器需提升 */
body:has(dialog[open]) #toast-container { position: fixed !important; z-index: 9999 !important; }
/* ===== 星域行动(活动中心 A1) ===== */
.activity-center-preview { display: flex; flex-wrap: wrap; gap: 10px; }
.activity-chip { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; padding: 10px 16px; border: 1px solid var(--line-2); border-radius: var(--radius-sm); background: var(--surface-2); color: var(--text); cursor: pointer; text-align: left; transition: border-color var(--dur-1) var(--ease); }
.activity-chip:hover { border-color: var(--cyan); }
.activity-chip b { font-size: 13px; }
.activity-chip small { color: var(--muted); font-size: 11px; }
.activity-dialog { width: min(640px, calc(100vw - 32px)); }
.activity-dialog-body { max-height: 60vh; overflow-y: auto; padding: var(--space-3) var(--space-4) var(--space-4); display: grid; gap: var(--space-3); }
.activity-block { border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); padding: var(--space-3); }
.activity-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; flex-wrap: wrap; }
.activity-head b { font-size: 14px; }
.activity-tasks { display: grid; gap: 6px; }
.recharge-history-item .rh-status.pending { background: rgba(255,210,59,.12); color: var(--amber); }
/* ===== 充值结果面板 ===== */
.recharge-result-panel { text-align: center; padding: 24px 16px; }
.recharge-result-panel .rr-icon { display: inline-flex; align-items: center; justify-content: center; width: 56px; height: 56px; border-radius: 50%; font-size: 28px; font-weight: 700; margin-bottom: 12px; }
.recharge-result-panel.success .rr-icon { background: rgba(184,242,74,.15); color: var(--lime); }
.recharge-result-panel.fail .rr-icon { background: rgba(255,93,115,.15); color: var(--danger); }
.recharge-result-panel h3 { margin: 8px 0 4px; font-size: 18px; }
.recharge-result-panel p { color: var(--text-dim); font-size: 13px; margin: 4px 0; }
.recharge-result-panel .rr-sub { color: var(--muted); font-size: 12px; }
.recharge-result-panel .primary-button { margin-top: 16px; }
/* ===== 购买历史(E1) ===== */
.recharge-history-item { display: flex; align-items: center; justify-content: space-between; padding: 10px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); margin-bottom: 6px; }
.recharge-history-item .rh-left { display: flex; align-items: center; gap: 10px; }
.recharge-history-item .rh-icon { display: flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 8px; background: rgba(69,217,255,.1); color: var(--cyan); }
.recharge-history-item .rh-info b { font-size: 13px; color: var(--text); }
.recharge-history-item .rh-info small { display: block; color: var(--muted); font-size: 11px; }
.recharge-history-item .rh-status { padding: 3px 10px; border-radius: var(--radius-pill); font-size: 11px; }
.recharge-history-item .rh-status.done { background: rgba(184,242,74,.12); color: var(--lime); }
.recharge-history-item .rh-status.pending { background: rgba(255,210,59,.12); color: var(--amber); }
/* ===== 打击感视觉(FB2) ===== */
.low-hp-overlay { position: fixed; inset: 0; pointer-events: none; z-index: var(--z-content); opacity: 0; transition: opacity 0.3s ease; background: radial-gradient(ellipse at center, transparent 50%, rgba(255, 40, 40, 0.25) 80%, rgba(200, 20, 20, 0.4) 100%); }
.low-hp-overlay.active { opacity: 1; animation: lowHpPulse 1.2s ease-in-out infinite; }
@keyframes lowHpPulse { 0%, 100% { opacity: 0.6; } 50% { opacity: 1; } }
/* ===== 星域商城(E1) ===== */
.shop-tabs { display: flex; align-items: center; gap: var(--space-2); margin-bottom: var(--space-3); }
.shop-tab { padding: 8px 18px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--surface-2); color: var(--muted); font-size: 13px; cursor: pointer; transition: all var(--dur-1) var(--ease); white-space: nowrap; flex: none; }
.shop-tab:hover { border-color: var(--line-2); color: var(--text); }
.shop-tab.active { border-color: rgba(69, 217, 255, .55); color: var(--cyan); background: rgba(69, 217, 255, .08); }
.shop-search { width: 180px; margin-left: auto; padding: 8px 14px; border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--surface); color: var(--text); font-size: 12px; }
.shop-bundle { align-items: flex-start; }
.shop-bundle .bundle-icon { display: flex; align-items: center; justify-content: center; width: 74px; height: 74px; margin: 10px auto; border-radius: var(--radius); border: 1px solid var(--line-2); background: linear-gradient(135deg, var(--surface-3), var(--surface-2)); color: var(--amber); }
.shop-bundle .bundle-contents { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.shop-bundle .bundle-contents span { display: inline-flex; align-items: center; gap: 4px; padding: 3px 9px; border-radius: var(--radius-pill); border: 1px solid var(--line-2); font-size: 11px; color: var(--amber); }
/* ===== 星际通讯(C0) ===== */
.chat-channel-list { display: grid; gap: 6px; }
.chat-channel { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface-2); color: var(--text-dim); text-align: left; cursor: pointer; position: relative; transition: border-color var(--dur-1) var(--ease); }
.chat-channel:hover { border-color: var(--line-2); }
.chat-channel.active { border-color: rgba(69, 217, 255, .55); background: rgba(69, 217, 255, .06); }
.chat-channel .cc-name { color: var(--text); font-size: 13px; font-weight: 600; display: flex; align-items: center; gap: 5px; }
.chat-channel .cc-preview { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); font-size: 11px; }
.chat-channel .chat-unread { position: absolute; top: 8px; right: 10px; min-width: 17px; height: 17px; padding: 0 5px; border-radius: var(--radius-pill); background: var(--magenta); color: #fff; font-size: 10px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.chat-dm-title { margin: 14px 0 6px; color: var(--muted); font-size: 11px; letter-spacing: 1px; }
.chat-dm-list { display: grid; gap: 6px; }
.chat-main-head { display: flex; align-items: center; gap: 10px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.chat-main-head b { font-size: 14px; }
.chat-main-head .icon-button { width: 28px; height: 28px; border-radius: 6px; border: 1px solid var(--line); background: var(--surface-2); color: var(--text-dim); }
.chat-message.mine { text-align: right; }
.chat-message.mine .chat-author { color: var(--cyan); }
.chat-message.mine .chat-content { display: inline-block; text-align: left; padding: 8px 12px; background: rgba(69, 217, 255, .10); border: 1px solid rgba(69, 217, 255, .28); border-radius: 10px; }
.chat-message.system { text-align: center; }
.chat-message.system .chat-content { display: inline-block; padding: 6px 14px; background: none; border: 1px dashed var(--line-2); color: var(--muted); text-align: center; font-size: 11px; border-radius: var(--radius-pill); }
.chat-read { font-size: 10px; color: var(--muted-2); margin-left: 6px; }
@media (max-width: 720px) {
  .chat-container.show-chat .chat-sidebar { display: none; }
  .chat-container:not(.show-chat) .chat-main { display: none; }
  .chat-container.show-chat .chat-main { display: flex; }
  #chat-back.hidden { display: none; }
}
