/* 佛跳墙 竖向小窗口:一套变量,浅色 / 深色 / 跟随系统 */
:root {
  --bg: #f3f5f9; --bg2: #ffffff; --card: #ffffff; --line: #e6e9ef; --text: #0f172a; --muted: #6b7280; --muted2: #9aa3b2;
  --brand1: #6a44f2; --brand2: #2f8bff; --brand3: #18e3e8; --ok: #16a34a; --warn: #d97706; --danger: #e11d48;
  --ring-bg: #e7eaf1; --sheet: #ffffff; --shadow: 0 8px 30px rgba(15, 23, 42, .12); --topbar: rgba(243, 245, 249, .9);
  --radius: 18px; --ease: cubic-bezier(.2, .8, .2, 1);
  font-family: -apple-system, "Segoe UI Variable", "Segoe UI", "Microsoft YaHei UI", "PingFang SC", system-ui, sans-serif;
}
[data-theme="dark"] {
  --bg: #0c0f15; --bg2: #12161e; --card: #161b24; --line: #232a36; --text: #e7eaf0; --muted: #98a2b3; --muted2: #6b7280;
  --ring-bg: #1f2632; --sheet: #161b24; --shadow: 0 10px 40px rgba(0, 0, 0, .5); --topbar: rgba(12, 15, 21, .85);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0c0f15; --bg2: #12161e; --card: #161b24; --line: #232a36; --text: #e7eaf0; --muted: #98a2b3; --muted2: #6b7280;
    --ring-bg: #1f2632; --sheet: #161b24; --shadow: 0 10px 40px rgba(0, 0, 0, .5); --topbar: rgba(12, 15, 21, .85);
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg); color: var(--text); font-size: 14px; overflow: clip; }
body { -webkit-user-select: none; user-select: none; -webkit-font-smoothing: antialiased; }
input, textarea, .sel, pre, code { -webkit-user-select: text; user-select: text; }
button { font: inherit; color: inherit; cursor: default; }
[hidden] { display: none !important; }
.muted { color: var(--muted); } .small { font-size: 12px; } .mono { font-family: Consolas, "Cascadia Mono", monospace; }
.row { display: flex; align-items: center; gap: 10px; } .grow { flex: 1; } .center { text-align: center; }

.app { position: relative; height: 100vh; display: flex; flex-direction: column; background: var(--bg); overflow: clip; }

/* 标题栏(可拖动) */
.topbar { --wails-draggable: drag; height: 52px; display: flex; align-items: center; padding: 0 6px 0 8px; gap: 4px; background: var(--topbar); backdrop-filter: blur(12px); position: relative; z-index: 5; }
.topbar-title { position: absolute; left: 0; right: 0; text-align: center; font-weight: 600; letter-spacing: .3px; padding: 0 88px; pointer-events: none; }
.win { margin-left: auto; }
.icon-btn { --wails-draggable: no-drag; width: 38px; height: 38px; border: 0; background: transparent; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; transition: background .15s; }
.icon-btn svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
#menu-btn svg, #back-btn svg { width: 23px; height: 23px; }
body.android #menu-btn svg, body.android #back-btn svg { width: 30px; height: 30px; }
body.tv #menu-btn svg, body.tv #back-btn svg { width: 27px; height: 27px; }
.icon-btn:hover { background: rgba(127, 127, 127, .14); }
#close-btn:hover { background: var(--danger); color: #fff; }
.win { display: flex; }
body.mac .topbar-title { left: -78px; }

/* 页面栈 */
.stage { position: relative; flex: 1; overflow: clip; }
.view { position: absolute; inset: 0; overflow: auto; padding: 8px 22px 22px; animation: viewIn .32s var(--ease); }
.view.pop { animation: viewOut .25s var(--ease) forwards; }
@keyframes viewIn { from { opacity: 0; transform: translateX(24px); } to { opacity: 1; transform: none; } }
@keyframes viewOut { to { opacity: 0; transform: translateX(24px); } }
.view.home { animation-name: fadeIn; }
@keyframes fadeIn { from { opacity: 0; transform: scale(.985); } to { opacity: 1; transform: none; } }
.view::-webkit-scrollbar { width: 6px; } .view::-webkit-scrollbar-thumb { background: var(--line); border-radius: 3px; }

/* 首页 */
.home { display: flex; flex-direction: column; align-items: center; padding-top: 6px; gap: 12px; }
#home-banner:empty { display: none; } /* 空横幅也会吃掉一个 gap */
.hero { flex: 1 1 auto; width: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.power-wrap { position: relative; width: 176px; height: 176px; flex: none; }
.power-wrap > svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.ring-bg { fill: none; stroke: var(--ring-bg); stroke-width: 6; }
.ring { fill: none; stroke: url(#ringGrad); stroke-width: 6; stroke-linecap: round; stroke-dasharray: 622; stroke-dashoffset: 622; transition: stroke-dashoffset .9s var(--ease), opacity .3s; opacity: 0; }
.power-wrap.on .ring { stroke-dashoffset: 0; opacity: 1; }
.power-wrap.busy .ring { opacity: 1; stroke-dasharray: 140 482; animation: ringSpin 1.1s linear infinite; }
@keyframes ringSpin { to { stroke-dashoffset: -622; } }
.power { --wails-draggable: no-drag; position: absolute; inset: 19px; border-radius: 50%; border: 0; background: var(--card); box-shadow: var(--shadow); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 7px; transition: transform .15s var(--ease), box-shadow .3s; }
.power:active { transform: scale(.96); }
.power svg { width: 42px; height: 42px; fill: none; stroke: var(--muted2); stroke-width: 2.2; stroke-linecap: round; transition: stroke .3s, filter .3s; }
.power b { font-size: 13px; font-weight: 600; color: var(--muted); letter-spacing: 1px; }
.power-wrap.on .power svg { stroke: #2f8bff; filter: drop-shadow(0 0 10px rgba(47, 139, 255, .55)); }
.power-wrap.on .power { box-shadow: 0 0 0 1px rgba(47, 139, 255, .25), 0 12px 40px rgba(47, 139, 255, .25); }
.power-wrap.on .power b { color: #2f8bff; }
.power-wrap.busy .power svg { stroke: var(--warn); animation: pulse 1.2s ease-in-out infinite; }
.power-wrap.err .power svg { stroke: var(--danger); }
@keyframes pulse { 50% { opacity: .45; } }
/* 连上之后大字显示时长;没连上或出错才把状态那两行放出来 */
.uptime { display: flex; align-items: baseline; gap: 8px; margin-top: 12px; }
.uptime b { font-size: 27px; font-weight: 700; letter-spacing: -.5px; font-variant-numeric: tabular-nums; }
.uptime span { font-size: 12px; color: var(--muted2); }
.status-text { font-size: 18px; font-weight: 600; margin-top: 12px; }
.status-sub { color: var(--muted); font-size: 12px; margin-top: 4px; max-width: 320px; text-align: center; line-height: 1.45; }

/* 出口卡片:此刻真正在用的那条线路,点开就是节点面板 */
.idcard { width: 100%; flex: none; display: flex; align-items: center; gap: 12px; text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; box-shadow: 0 6px 20px rgba(15, 23, 42, .05); transition: transform .15s var(--ease), border-color .15s, box-shadow .2s; }
.idcard:hover { border-color: #2f8bff; box-shadow: 0 8px 24px rgba(47, 139, 255, .14); }
.idcard:active { transform: scale(.985); }
.idmid { flex: 1; min-width: 0; }
.idtop { display: flex; align-items: center; gap: 6px; min-width: 0; }
.idtop b { flex: 0 1 auto; min-width: 0; font-size: 15px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.idsub { display: block; font-size: 11.5px; color: var(--muted2); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; }
.idms { flex: none; text-align: right; min-width: 40px; }
.idms b { display: block; font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; line-height: 1.15; }
.idms span { font-size: 10px; color: var(--muted2); }
.idms.good b { color: var(--ok); } .idms.mid b { color: var(--warn); } .idms.bad b { color: var(--danger); } .idms.none b { color: var(--muted2); }

/* 速度卡:两个当前速度 + 本次总量,底下是最近一分钟的曲线 */
.speed { width: 100%; flex: none; display: flex; flex-direction: column; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px 8px; box-shadow: 0 6px 20px rgba(15, 23, 42, .05); }
.speed-row { display: flex; align-items: flex-start; gap: 14px; flex: none; }
.sp { flex: 1; min-width: 0; }
.sp.end { flex: none; text-align: right; }
.sp .k { display: flex; align-items: center; gap: 5px; font-size: 11px; color: var(--muted); }
.sp.end .k { justify-content: flex-end; }
.sp b { display: block; font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; margin-top: 2px; white-space: nowrap; }
.sp.end b { font-size: 14px; font-weight: 500; margin-top: 4px; }
.sq { width: 7px; height: 7px; border-radius: 2px; flex: none; }
.sq.d { background: var(--brand2); } .sq.u { background: var(--brand3); }
.spark { flex: none; height: 56px; width: 100%; display: block; margin-top: 6px; }

.pickers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; width: 100%; flex: none; }
.picker { border: 1px solid var(--line); background: var(--card); border-radius: 16px; padding: 10px 12px 9px; text-align: left; transition: transform .15s var(--ease), border-color .15s, box-shadow .2s; }
.picker:hover { border-color: #2f8bff; box-shadow: 0 6px 20px rgba(47, 139, 255, .12); }
.picker:active { transform: scale(.97); }
.picker span { display: block; font-size: 11px; color: var(--muted); }
.picker b { display: block; font-size: 13px; font-weight: 600; margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.picker em { font-style: normal; font-size: 11px; color: var(--muted2); }

/* 引导页 */
.onboard { display: flex; flex-direction: column; align-items: center; justify-content: center; height: 100%; text-align: center; gap: 10px; padding: 0 8px; }
.onboard .logo { width: 84px; height: 84px; margin-bottom: 4px; animation: floatY 3s ease-in-out infinite; }
@keyframes floatY { 50% { transform: translateY(-6px); } }
.onboard h1 { font-size: 22px; margin: 4px 0 0; }
.onboard p { color: var(--muted); margin: 0 0 12px; }
.onboard .field { width: 100%; }
.onboard .banner { width: 100%; box-sizing: border-box; margin-top: 4px; }

/* 通用控件 */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 12px; }
.card h3 { margin: 0 0 8px; font-size: 12px; color: var(--muted); font-weight: 600; letter-spacing: .4px; text-transform: uppercase; }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.field label { font-size: 12px; color: var(--muted); }
.field .help { font-size: 11px; color: var(--muted2); line-height: 1.4; }
input[type=text], input[type=url], input[type=number], select, textarea { width: 100%; border: 1px solid var(--line); background: var(--bg2); color: var(--text); border-radius: 12px; padding: 10px 12px; font-size: 13px; outline: none; transition: border-color .15s, box-shadow .15s; }
input:focus, select:focus, textarea:focus { border-color: #2f8bff; box-shadow: 0 0 0 3px rgba(47, 139, 255, .18); }
textarea { min-height: 80px; resize: vertical; font-family: Consolas, monospace; }
.btn { border: 1px solid var(--line); background: var(--card); color: var(--text); padding: 9px 16px; border-radius: 12px; font-size: 13px; font-weight: 500; white-space: nowrap; flex: none; transition: transform .12s var(--ease), background .15s, opacity .15s; }
.btn:hover { background: var(--bg2); } .btn:active { transform: scale(.97); } .btn:disabled { opacity: .5; }
.btn.primary { border: 0; color: #fff; background: linear-gradient(120deg, var(--brand1), var(--brand2) 60%, var(--brand3)); box-shadow: 0 6px 18px rgba(47, 139, 255, .3); }
.btn.primary:hover { filter: brightness(1.06); }
.btn.danger { color: var(--danger); } .btn.block { width: 100%; } .btn.sm { padding: 6px 11px; font-size: 12px; border-radius: 10px; }
.btn.ghost { background: transparent; border-color: transparent; }
.switch { display: inline-flex; align-items: center; gap: 10px; }
.switch input { appearance: none; width: 42px; height: 24px; border-radius: 12px; background: var(--line); position: relative; margin: 0; transition: background .2s; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: left .2s var(--ease); }
.switch input:checked { background: #2f8bff; } .switch input:checked::after { left: 21px; }
.srow { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.srow:last-child { border-bottom: 0; }
.srow .lbl { flex: 1; } .srow .lbl div { font-size: 11px; color: var(--muted2); margin-top: 2px; line-height: 1.35; }
.srow input[type=number], .srow input[type=text], .srow select { width: 130px; padding: 7px 10px; }
.seg { display: inline-flex; background: var(--bg2); border: 1px solid var(--line); border-radius: 12px; padding: 3px; position: relative; }
.seg button { border: 0; background: transparent; padding: 6px 12px; border-radius: 9px; font-size: 12px; position: relative; z-index: 1; transition: color .2s; }
.seg button.active { color: #fff; }
.seg .pill { position: absolute; top: 3px; bottom: 3px; border-radius: 9px; background: linear-gradient(120deg, var(--brand1), var(--brand2)); transition: left .25s var(--ease), width .25s var(--ease); }
.list { border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--card); }
.item { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-bottom: 1px solid var(--line); animation: itemIn .25s var(--ease) both; }
.item:last-child { border-bottom: 0; } .item:hover { background: var(--bg2); }
@keyframes itemIn { from { opacity: 0; transform: translateY(6px); } }
.item .name { flex: 1; min-width: 0; } .item .name b { display: block; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item .name span { font-size: 11px; color: var(--muted2); }
.check { width: 18px; height: 18px; border-radius: 50%; border: 2px solid var(--line); display: inline-flex; align-items: center; justify-content: center; flex: none; transition: all .2s; }
.item.current .check { border-color: #2f8bff; background: #2f8bff; }
.item.current .check::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #fff; }
.ms { font-variant-numeric: tabular-nums; font-size: 12px; min-width: 56px; text-align: right; }
.ms.good { color: var(--ok); } .ms.mid { color: var(--warn); } .ms.bad { color: var(--danger); } .ms.none { color: var(--muted2); }
.bar { height: 4px; border-radius: 2px; background: var(--line); overflow: hidden; margin-top: 4px; width: 100%; }
.bar i { display: block; height: 100%; width: 0; border-radius: 2px; background: linear-gradient(90deg, var(--brand2), var(--brand3)); transition: width .6s var(--ease); }
.tag { font-size: 10px; font-weight: 500; text-transform: none; letter-spacing: 0; padding: 2px 6px; border-radius: 6px; background: var(--bg2); border: 1px solid var(--line); color: var(--muted); flex: none; vertical-align: 1px; }
.spinner { width: 14px; height: 14px; border: 2px solid var(--line); border-top-color: #2f8bff; border-radius: 50%; animation: spin .8s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }
.empty { padding: 26px 10px; text-align: center; color: var(--muted2); font-size: 13px; }
.progress { height: 6px; background: var(--line); border-radius: 3px; overflow: hidden; }
.progress i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--brand1), var(--brand2), var(--brand3)); transition: width .3s; }
.pill-badge { background: var(--danger); color: #fff; font-size: 10px; padding: 1px 6px; border-radius: 8px; }
.banner { background: linear-gradient(120deg, rgba(225, 29, 72, .12), rgba(225, 29, 72, .04)); border: 1px solid rgba(225, 29, 72, .3); border-radius: 14px; padding: 10px 12px; font-size: 12px; margin: 4px 0 10px; display: flex; align-items: center; gap: 10px; }
pre.log { background: #0b0e14; color: #d6deeb; border-radius: 14px; padding: 12px; font-size: 11.5px; line-height: 1.5; margin: 0; white-space: pre-wrap; word-break: break-all; max-height: calc(100vh - 210px); overflow: auto; }
pre.log .warn { color: #fbbf24; } pre.log .err { color: #f87171; } pre.log .dim { color: #7c8797; }
.page-title { font-size: 20px; font-weight: 700; margin: 6px 0 12px; }
.savebar { position: sticky; bottom: -22px; margin: 10px -22px -22px; padding: 10px 22px 16px; background: var(--topbar); backdrop-filter: blur(14px); border-top: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; transition: background .25s, box-shadow .25s; }
.savebar .note { font-size: 11px; color: var(--muted2); text-align: center; line-height: 1.4; transition: color .25s; }
.savebar .btn { width: 100%; padding: 11px 16px; font-size: 14px; border-radius: 14px; }
.savebar .btn:disabled { opacity: 1; background: var(--bg2); color: var(--muted2); box-shadow: none; border: 1px solid var(--line); }
.savebar.dirty { box-shadow: 0 -10px 30px rgba(15, 23, 42, .08); }
.savebar.dirty .note { color: var(--brand2); }
.savebar.dirty .btn { animation: lift .35s var(--ease); }
@keyframes lift { from { transform: translateY(6px); opacity: .6; } }

/* 抽屉(左)与底部面板 */
.backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .35); opacity: 0; pointer-events: none; transition: opacity .25s; z-index: 8; }
.backdrop.show { opacity: 1; pointer-events: auto; }
.drawer { position: absolute; top: 0; bottom: 0; left: 0; width: 76%; max-width: 300px; background: var(--sheet); box-shadow: var(--shadow); z-index: 9; transform: translateX(-104%); transition: transform .3s var(--ease); display: flex; flex-direction: column; padding: 18px 12px 14px; }
.drawer.show { transform: none; }
.drawer-brand { display: flex; align-items: center; gap: 10px; padding: 6px 10px 18px; }
.drawer-items { flex: 1; }
.drawer-items a { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border-radius: 12px; margin-bottom: 2px; color: var(--text); transition: background .15s; }
.drawer-items a:hover { background: var(--bg2); }
.drawer-items a svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; opacity: .85; }
.drawer-foot { display: flex; align-items: center; gap: 8px; padding: 8px 12px 0; border-top: 1px solid var(--line); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted2); } .dot.on { background: var(--ok); } .dot.err { background: var(--danger); }
.sheet { position: absolute; left: 0; right: 0; bottom: 0; background: var(--sheet); border-radius: 22px 22px 0 0; box-shadow: var(--shadow); z-index: 9; transform: translateY(105%); transition: transform .32s var(--ease); max-height: 78%; display: flex; flex-direction: column; }
.sheet.show { transform: none; }
.sheet-grip { width: 38px; height: 4px; border-radius: 2px; background: var(--line); margin: 10px auto 4px; }
.sheet-head { display: flex; align-items: center; gap: 10px; padding: 6px 18px 10px; font-weight: 600; }
.sheet-body { overflow: auto; padding: 0 14px 18px; }
.sheet-body::-webkit-scrollbar { width: 6px; } .sheet-body::-webkit-scrollbar-thumb { background: var(--line); border-radius: 3px; }
.toast { position: absolute; left: 50%; bottom: 22px; transform: translate(-50%, 20px); background: #111827; color: #fff; padding: 9px 14px; border-radius: 12px; font-size: 12.5px; opacity: 0; pointer-events: none; transition: all .25s var(--ease); z-index: 20; max-width: 86%; box-shadow: 0 8px 24px rgba(0, 0, 0, .3); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
.toast.ok { background: var(--ok); } .toast.err { background: var(--danger); }

/* 路由规则 */
.item.rg .name b { white-space: normal; }
.item.rg.off .name b { color: var(--muted); }
.item.rg.builtin { background: var(--bg2); }
.item.rg .name span { white-space: normal; line-height: 1.5; }
.conds { display: flex; flex-direction: column; gap: 4px; }
.cond { display: flex; align-items: center; gap: 8px; padding: 5px 6px 5px 8px; border-radius: 10px; background: var(--bg2); font-size: 12.5px; animation: itemIn .2s var(--ease) both; }
.cond .val { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: Consolas, "Cascadia Mono", monospace; }
.icon-btn.xs { width: 24px; height: 24px; border-radius: 8px; } .icon-btn.xs svg { width: 14px; height: 14px; }
.sheet-filter { padding: 0 0 8px; } .sheet-filter input { padding: 8px 12px; }
.with-btn { position: relative; } .with-btn input { padding-right: 64px; } .with-btn > button { position: absolute; right: 6px; bottom: 5px; }
.upd-hint { font-size: 11px; color: var(--brand2); margin-top: 3px; cursor: pointer; }
.upd-hint::before { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--danger); margin-right: 5px; vertical-align: 1px; }
.view.has-bar { display: flex; flex-direction: column; }
.view.has-bar > * { flex: none; }
.view.has-bar .savebar { margin-top: auto; }
.spin { animation: spin .8s linear infinite; }
.icon-btn.muted { color: var(--muted2); } .icon-btn.muted:hover { color: var(--brand2); }
.icon-btn:disabled { opacity: .6; }

/* 浏览器面板(Linux):宽屏时居中成一张手机卡片;没有窗口按钮 */
.app.web .win { display: none; }
.app.web .topbar { --wails-draggable: no-drag; }
/* macOS 原生窗口:红绿灯按钮浮在左上角,顶栏左边留出它们的位置 */
body.mac .topbar { padding-left: 78px; }
@media (min-width: 640px) {
  body.web { background: linear-gradient(135deg, #e9edf5, #f6f7fb 55%, #e6f0ff); }
  body.web .app { width: 420px; height: min(800px, calc(100vh - 40px)); margin: 20px auto; border-radius: 22px; box-shadow: 0 20px 60px rgba(15, 23, 42, .18); border: 1px solid rgba(15, 23, 42, .06); }
  :root[data-theme="dark"] body.web { background: linear-gradient(135deg, #0b0e14, #121722 55%, #0d1320); }
  @media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) body.web { background: linear-gradient(135deg, #0b0e14, #121722 55%, #0d1320); } }
}
.login { position: absolute; inset: 0; z-index: 30; background: var(--bg); display: flex; align-items: center; justify-content: center; padding: 24px; }
.login-card { width: 100%; max-width: 320px; display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; }
.login-card h1 { font-size: 22px; margin: 4px 0 0; } .login-card p { color: var(--muted); margin: 0 0 8px; }
.login-card input { width: 100%; }

/* 设备页 */
.item.dev .dot { flex: none; }
.dev-seg button.active { color: #fff; }

/* Android:全屏没有窗口按钮;电视(body.tv)横版放大,遥控器焦点要看得见 */
.app.android .win { display: none; }
body.android .topbar { --wails-draggable: no-drag; }
body.tv { font-size: 17px; }
body.tv :is(button, a, .item, input, select, textarea):focus { outline: 3px solid var(--brand2); outline-offset: 3px; box-shadow: 0 0 0 7px rgba(47, 139, 255, .16); }
body.tv .power:focus { outline-offset: 6px; box-shadow: var(--shadow), 0 0 0 10px rgba(47, 139, 255, .16); }
body.tv .topbar { height: 64px; padding: 0 18px; } body.tv .topbar-title { font-size: 18px; }
body.tv .icon-btn { width: 46px; height: 46px; } body.tv .icon-btn svg { width: 25px; height: 25px; }
body.tv .view { padding: 12px 40px 28px; }
body.tv .view:not(.home) { max-width: 860px; margin: 0 auto; }
body.tv .home { display: grid; grid-template-columns: 1.1fr 1fr; grid-template-rows: auto auto auto 1fr; column-gap: 48px; align-items: center; }
body.tv .home #home-banner { grid-column: 1 / -1; }
body.tv .home .hero { grid-column: 1; grid-row: 2 / 5; min-height: 0; }
body.tv .home .idcard { grid-column: 2; grid-row: 2; align-self: end; }
body.tv .home .speed { grid-column: 2; grid-row: 3; margin-top: 12px; }
body.tv .home .pickers { grid-column: 2; grid-row: 4; align-self: start; grid-template-columns: 1fr; gap: 12px; margin-top: 12px; }
body.tv .idcard .idtop b { font-size: 19px; } body.tv .idcard .idsub { font-size: 13px; }
body.tv .uptime b { font-size: 34px; }
body.tv .power-wrap { width: 300px; height: 300px; } body.tv .power svg { width: 64px; height: 64px; } body.tv .power b { font-size: 16px; }
body.tv .status-text { font-size: 24px; } body.tv .status-sub { font-size: 14px; max-width: 440px; }
body.tv .stat { padding: 12px 6px; } body.tv .stat b { font-size: 18px; } body.tv .stat span { font-size: 12px; }
body.tv .picker { padding: 12px 18px 11px; display: flex; align-items: baseline; gap: 14px; } body.tv .picker b { font-size: 17px; margin-top: 0; flex: 1; } body.tv .picker span { font-size: 13px; min-width: 3em; } body.tv .picker em { font-size: 13px; }
body.tv .drawer { max-width: 380px; padding: 24px 16px 18px; } body.tv .drawer-items a { padding: 14px 16px; font-size: 17px; }
body.tv .sheet { left: 50%; right: auto; width: 680px; max-width: 92%; transform: translate(-50%, 105%); } body.tv .sheet.show { transform: translate(-50%, 0); }
body.tv .item { padding: 14px 18px; } body.tv .btn { padding: 11px 20px; font-size: 15px; }
body.tv .srow { padding: 14px 0; } body.tv .srow input[type=number], body.tv .srow input[type=text], body.tv .srow select { width: 170px; }
body.tv .card h3 { font-size: 13px; } body.tv .page-title { font-size: 24px; }
body.tv .drawer-items a:focus { background: rgba(47, 139, 255, .12); }
body.tv .item:focus { outline-offset: -3px; background: rgba(47, 139, 255, .12); } /* 列表 overflow: hidden 会裁掉外描边,描在内侧 */
/* 没有窗口按钮的壳(浏览器面板 / Android):标题独立居中,不受左右按钮有无影响(引导页没有菜单键也不会偏) */
.app.web .topbar-title { position: absolute; left: 0; right: 0; padding: 0 60px; pointer-events: none; }
body.android .icon-btn { width: 48px; height: 48px; } body.android .icon-btn svg { width: 30px; height: 30px; stroke-width: 2.2; }
body.android .topbar { height: 58px; padding: 0 8px; }
body.android .topbar-title { font-size: 16px; }
/* 抽屉:手机上更宽,条目更高更大,顶部品牌区多留一点余量 */
body.android .drawer { width: 82%; max-width: 340px; padding: 26px 14px 16px; }
body.android .drawer-brand { padding: 10px 12px 22px; gap: 14px; }
body.android .drawer-brand svg { width: 42px; height: 42px; }
body.android .drawer-brand b { font-size: 18px; }
body.android .drawer-items a { padding: 15px 14px; font-size: 16px; border-radius: 14px; margin-bottom: 4px; }
body.android .drawer-items a svg { width: 22px; height: 22px; }
body.android .drawer-foot { padding: 12px 12px 0; font-size: 13px; }

body.android .icon-btn.xs { width: 36px; height: 36px; border-radius: 10px; } body.android .icon-btn.xs svg { width: 20px; height: 20px; }

/* 应用内对话框:替代浏览器自带的 confirm / prompt(它们在 Windows 上会画成系统弹窗贴在窗口角上) */
.dialog { position: absolute; inset: 0; z-index: 12; display: flex; align-items: center; justify-content: center; padding: 24px; pointer-events: none; }
.dialog-card { pointer-events: auto; width: 100%; max-width: 340px; background: var(--sheet); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 18px 14px; animation: dlgIn .18s var(--ease); }
@keyframes dlgIn { from { opacity: 0; transform: translateY(8px) scale(.97); } }
.dialog-text { font-size: 14px; line-height: 1.55; white-space: pre-wrap; }
.dialog-card input { margin-top: 12px; }
#dialog-backdrop { z-index: 11; }
body.tv .dialog-card { max-width: 520px; padding: 24px; } body.tv .dialog-text { font-size: 17px; }

/* ---- 地区牌子:首页出口卡片与节点列表共用 ---- */
.flag { position: relative; width: 42px; height: 42px; border-radius: 14px; flex: none; display: inline-flex; align-items: center; justify-content: center; overflow: hidden; color: #fff; font-size: 13px; font-weight: 700; letter-spacing: .5px; background: linear-gradient(135deg, var(--c1, #94a3b8), var(--c2, #64748b)); }
.flag.fl { background: var(--bg2); } /* 旗子是按需取的文件,取回来之前先垫个底,别闪一块白 */
.flag-svg { width: 100%; height: 100%; display: block; object-fit: cover; }
.flag.fl::after { content: ""; position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 0 1px rgba(15, 23, 42, .16); }
.flag.sm { width: 26px; height: 26px; border-radius: 9px; font-size: 10px; letter-spacing: .3px; }
.flag.none { background: var(--bg2); border: 1px solid var(--line); color: var(--muted2); }
.flag svg { width: 58%; height: 58%; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }

/* ---- 节点行:牌子 + 名字(带倍率/协议)+ 延迟条 ---- */
.tag { font-style: normal; }
.tag.warn { background: rgba(217, 119, 6, .12); border-color: rgba(217, 119, 6, .35); color: var(--warn); }
.list .item { gap: 10px; }
.item .ntop { display: flex; align-items: center; gap: 6px; min-width: 0; }
.item .ntop b { flex: 0 1 auto; min-width: 0; }
.ntype { font-style: normal; font-size: 10px; color: var(--muted2); text-transform: uppercase; letter-spacing: .3px; margin-left: auto; flex: none; padding-left: 6px; }
.item.auto .name b { font-weight: 600; }

/* ---- 节点面板顶上的地区条:只筛选,不碰后端 ---- */
/* 自动换行,不做横向滚动:桌面端没有横向滚动条,鼠标滚轮也推不动,藏在右边的地区就点不到了 */
.chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 2px 10px; }
.chip { flex: none; border: 1px solid var(--line); background: var(--bg2); color: var(--text); font-size: 12px; padding: 5px 12px; border-radius: 999px; white-space: nowrap; transition: background .15s, color .15s, border-color .15s; }
.chip:hover { border-color: #2f8bff; }
.chip.on { color: #fff; border-color: transparent; background: linear-gradient(120deg, var(--brand1), var(--brand2)); }

/* ---- 抽屉里的状态卡:补上品牌区与菜单之间那块空当,顺手能切模式 ---- */
.drawer-state { border-radius: 16px; padding: 12px 13px; margin-bottom: 12px; background: linear-gradient(135deg, rgba(106, 68, 242, .09), rgba(24, 227, 232, .09)); border: 1px solid rgba(47, 139, 255, .2); }
.ds-top { display: flex; align-items: center; gap: 8px; }
.ds-top b { font-size: 13.5px; font-weight: 600; }
.ds-top #ds-time { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.ds-node { display: flex; align-items: center; gap: 9px; width: 100%; margin-top: 10px; padding: 0; border: 0; background: transparent; text-align: left; border-radius: 10px; transition: opacity .15s; }
.ds-node:active { opacity: .6; }
.ds-mid { flex: 1; min-width: 0; }
.ds-mid b { display: block; font-size: 13px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ds-mid span { display: block; font-size: 11px; color: var(--muted2); margin-top: 2px; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ds-modes { display: flex; gap: 3px; margin-top: 11px; padding: 3px; border-radius: 11px; background: var(--bg2); border: 1px solid var(--line); }
.ds-modes button { flex: 1; border: 0; background: transparent; color: var(--muted); font-size: 12px; padding: 6px 0; border-radius: 8px; transition: color .2s, background .2s; }
.ds-modes button:hover { color: var(--text); }
.ds-modes button.on { color: #fff; font-weight: 500; background: linear-gradient(120deg, var(--brand1), var(--brand2)); }

/* ---- 抽屉品牌区放大,和状态卡拉开层次 ---- */
.drawer-brand { padding: 4px 10px 14px; gap: 12px; }
.drawer-brand svg { width: 40px; height: 40px; }
.drawer-brand b { font-size: 19px; letter-spacing: .5px; }
.drawer-items a { padding: 12px 12px; border-radius: 13px; margin-bottom: 3px; font-size: 14.5px; }
.drawer-items a svg { width: 20px; height: 20px; }
body.android .drawer-brand svg { width: 46px; height: 46px; }
body.android .drawer-brand b { font-size: 21px; }
body.tv .drawer-brand svg { width: 52px; height: 52px; }
body.tv .drawer-brand b { font-size: 22px; }

/* ===== 二级页面:引导 / 订阅 / 规则 / 连接 / 日志 / 关于 ===== */
.pagehint { font-size: 12px; color: var(--muted2); line-height: 1.6; margin: 2px 2px 12px; }
.pagehint.center { text-align: center; }
.sechead { font-size: 11px; font-weight: 600; color: var(--muted); letter-spacing: .4px; padding: 4px 2px 7px; }
.sechead.row { display: flex; align-items: center; gap: 8px; }
.linkbtn { border: 0; background: none; color: var(--brand2); font-size: 12px; font-weight: 500; padding: 2px 4px; }
.linkbtn:hover { text-decoration: underline; }
.empty.sm { padding: 16px 10px; font-size: 12.5px; }
.card.tight { padding: 4px 14px; }

/* 虚线的"添加"卡:订阅页与规则页共用 */
.addcard { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; margin: 14px 0 4px; padding: 14px 16px; border: 1px dashed var(--line); border-radius: var(--radius); background: transparent; transition: border-color .15s, background .15s; }
.addcard:hover { border-color: #2f8bff; background: var(--card); }
.addic { width: 36px; height: 36px; border-radius: 12px; background: var(--bg2); display: flex; align-items: center; justify-content: center; flex: none; }
.addic svg { width: 18px; height: 18px; fill: none; stroke: var(--brand1); stroke-width: 1.9; stroke-linecap: round; }
.addtxt { flex: 1; min-width: 0; }
.addtxt b { display: block; font-size: 13.5px; font-weight: 500; }
.addtxt span { display: block; font-size: 11px; color: var(--muted2); margin-top: 2px; }

/* 引导页 */
.onboard { align-items: stretch; text-align: left; justify-content: flex-start; padding-top: 12px; gap: 0; }
.onboard .logo { width: 56px; height: 56px; margin: 0 0 18px; animation: none; }
.onboard h1 { font-size: 25px; letter-spacing: -.4px; margin: 0; }
.onboard p { color: var(--muted); margin: 8px 0 22px; line-height: 1.65; font-size: 13px; }
.onboard .field { margin-bottom: 10px; }
.onboard .btn.block { padding: 12px 16px; font-size: 14px; border-radius: 14px; }
.or { display: flex; align-items: center; gap: 12px; margin: 22px 0 18px; }
.or span { height: 1px; flex: 1; background: var(--line); }
.or em { font-style: normal; font-size: 11px; color: var(--muted2); }
.tipcard { display: flex; align-items: center; gap: 13px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
.tipic { width: 38px; height: 38px; border-radius: 13px; background: var(--bg2); display: flex; align-items: center; justify-content: center; flex: none; }
.tipic svg { width: 19px; height: 19px; fill: none; stroke: var(--brand1); stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.tiptxt { flex: 1; min-width: 0; }
.tiptxt b { display: block; font-size: 13.5px; font-weight: 500; }
.tiptxt span { display: block; font-size: 11px; color: var(--muted2); margin-top: 3px; line-height: 1.5; }
.grow1 { flex: 1; min-height: 18px; }
.notecard { display: flex; align-items: flex-start; gap: 9px; padding: 12px 14px; border-radius: 14px; background: rgba(47, 139, 255, .07); }
.notecard svg { width: 15px; height: 15px; flex: none; margin-top: 2px; fill: none; stroke: var(--brand2); stroke-width: 1.9; stroke-linecap: round; }
.notecard span { font-size: 11.5px; color: var(--muted); line-height: 1.6; }

/* 订阅:当前那条摊成大卡 */
.profcard { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 15px 16px; box-shadow: 0 6px 20px rgba(15, 23, 42, .05); }
.pc-top { display: flex; align-items: center; gap: 10px; }
.pc-top b { flex: 1; font-size: 15.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pc-ago { font-size: 11px; color: var(--muted2); flex: none; }
.pc-use { display: flex; align-items: baseline; gap: 6px; margin-top: 13px; }
.pc-use b { font-size: 23px; font-weight: 700; letter-spacing: -.5px; font-variant-numeric: tabular-nums; }
.pc-use span { font-size: 12px; color: var(--muted); }
.pc-bar { height: 6px; border-radius: 3px; background: var(--bg2); border: 1px solid var(--line); margin-top: 8px; overflow: hidden; }
.pc-bar i { display: block; height: 100%; border-radius: 3px; background: linear-gradient(90deg, var(--brand1), var(--brand2), var(--brand3)); transition: width .5s var(--ease); }
.pc-meta { display: flex; justify-content: space-between; gap: 10px; margin-top: 7px; font-size: 11px; color: var(--muted2); }
.pc-err { font-size: 11.5px; color: var(--danger); margin-top: 8px; line-height: 1.5; }
.pc-act { display: flex; gap: 8px; margin-top: 14px; }
.pc-act .btn { flex: 1; padding: 9px 0; border-radius: 12px; }
.pc-act .btn.icon { flex: none; width: 44px; padding: 9px 0; }
.btn.icon { display: inline-flex; align-items: center; justify-content: center; }
.btn.icon svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.icon-btn.busy svg, .btn.busy svg { animation: spin .8s linear infinite; }

/* 规则组卡片 */
.rgwrap { display: flex; flex-direction: column; gap: 10px; }
.rgcard { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 13px 14px; box-shadow: 0 4px 14px rgba(15, 23, 42, .04); }
.rgcard.off { opacity: .62; }
.rg-head { display: flex; align-items: center; gap: 10px; }
.rg-name { flex: 1; min-width: 0; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.rg-name b { font-size: 14.5px; font-weight: 600; }
.tag.brand { background: rgba(106, 68, 242, .1); border-color: rgba(106, 68, 242, .28); color: var(--brand1); }
.rg-conds { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 9px; }
.cchip { font-size: 11px; padding: 3px 7px; border-radius: 7px; background: var(--bg2); border: 1px solid var(--line); font-family: Consolas, "Cascadia Mono", monospace; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cchip.more { color: var(--muted2); font-family: inherit; }
.rg-act { display: flex; align-items: center; gap: 6px; margin-top: 11px; padding-top: 10px; border-top: 1px solid var(--line); }
.rg-act .btn.icon { width: 34px; padding: 6px 0; }

/* 默认规则的三行 */
.drow { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.drow:last-child { border-bottom: 0; }
.dtxt { flex: 1; min-width: 0; }
.dtxt b { display: block; font-size: 13.5px; font-weight: 500; }
.dtxt span { display: block; font-size: 11px; color: var(--muted2); margin-top: 2px; }
.drow select { width: auto; flex: none; max-width: 56%; padding: 6px 9px; font-size: 12.5px; }

/* 连接:三个数 + 筛选 + 列表 */
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 12px; }
.tile { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; }
.tile span { display: block; font-size: 10.5px; color: var(--muted2); }
.tile b { display: block; font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; margin-top: 2px; }
.tile b.brand { color: var(--brand2); } .tile b.dim { color: var(--muted); }
.item.conn { align-items: center; }
.cn-top { display: flex; align-items: center; gap: 8px; }
.cn-top b { flex: 1; min-width: 0; font-size: 13.5px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cn-b { font-size: 11px; color: var(--muted2); font-variant-numeric: tabular-nums; flex: none; }
.cn-sub { display: flex; align-items: center; gap: 6px; margin-top: 6px; padding-left: 14px; min-width: 0; }
.cn-sub span { font-size: 11px; color: var(--muted2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dot.on2 { background: var(--brand2); }
.item.conn .dot { width: 6px; height: 6px; flex: none; }

/* 日志 */
.view.logs { display: flex; flex-direction: column; }
.logbox { flex: 1; min-height: 200px; background: #0b0e14; border-radius: var(--radius); padding: 12px 14px; overflow: auto; font-family: Consolas, "Cascadia Mono", monospace; font-size: 11.5px; line-height: 1.8; }
.logbox::-webkit-scrollbar { width: 6px; } .logbox::-webkit-scrollbar-thumb { background: #2a3340; border-radius: 3px; }
.lrow { display: flex; gap: 8px; padding: 1px 6px; margin: 0 -6px; border-radius: 6px; }
.lt { color: #5b6472; flex: none; }
.ll { color: #8fb8ff; flex: none; width: 42px; }
.ll:empty { display: none; } /* 服务日志那一路没有级别字段,别留一条空档 */
.lx { color: #d6deeb; word-break: break-word; }
.lrow.warn { background: rgba(251, 191, 36, .08); } .lrow.warn .ll, .lrow.warn .lx { color: #fbbf24; }
.lrow.err { background: rgba(248, 113, 113, .1); } .lrow.err .ll, .lrow.err .lx { color: #f87171; }
.lrow.dim .ll, .lrow.dim .lx { color: #7c8797; }
.lempty { color: #5b6472; text-align: center; padding: 26px 0; }
.logact { display: flex; gap: 10px; margin-top: 14px; }
.logact .btn { flex: 1; padding: 11px 0; border-radius: 14px; font-size: 13.5px; }

/* 关于 */
.abrand { display: flex; flex-direction: column; align-items: center; padding: 6px 0 20px; }
.abrand svg { width: 52px; height: 52px; }
.abrand b { font-size: 18.5px; font-weight: 700; margin-top: 12px; }
.abrand span { font-size: 12px; color: var(--muted2); margin-top: 4px; font-variant-numeric: tabular-nums; }
.updcard { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin-bottom: 14px; }
.updcard.has { background: linear-gradient(135deg, rgba(106, 68, 242, .1), rgba(24, 227, 232, .1)); border-color: rgba(47, 139, 255, .28); }
.upd-head { display: flex; align-items: center; gap: 8px; }
.upd-head b { font-size: 14px; font-weight: 600; }
.upd-note { font-size: 11.5px; color: var(--muted); margin-top: 8px; line-height: 1.6; }
.updcard .btn.block { margin-top: 12px; padding: 10px 16px; border-radius: 12px; }
.list + .list { margin-top: 14px; }
.rowic { width: 17px; height: 17px; flex: none; fill: none; stroke: var(--muted); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.rowgo { width: 15px; height: 15px; flex: none; fill: none; stroke: var(--muted2); stroke-width: 1.9; stroke-linecap: round; }
.item.danger .rowic { stroke: var(--danger); }
.item.danger .name b { color: var(--danger); }

/* 设置页:顶上的搜索框与分组 */
.sgroup { margin-bottom: 16px; }
.sgroup .card.tight { padding: 2px 16px; margin-bottom: 0; }
.field.with-ic { position: relative; margin-bottom: 14px; }
.field.with-ic svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 15px; height: 15px; fill: none; stroke: var(--muted2); stroke-width: 2; stroke-linecap: round; pointer-events: none; }
.field.with-ic input { padding-left: 34px; }
.tag.warn { background: rgba(217, 119, 6, .12); border-color: rgba(217, 119, 6, .35); color: var(--warn); }

/* 续费按钮:面板给了「选购 / 续费」地址才出现。弱于卡片底下那排操作(它是外链,不是管理动作),
   但比纯文字链醒目;到期临近或流量快用尽时换成橙色。 */
.renewbtn { display: inline-flex; align-items: center; gap: 5px; flex: none;
  font-size: 12px; font-weight: 500; padding: 5px 12px; border-radius: 999px;
  color: var(--brand2); background: rgba(47, 139, 255, .09); border: 1px solid rgba(47, 139, 255, .28);
  transition: background .15s, border-color .15s; }
.renewbtn:hover { background: rgba(47, 139, 255, .17); }
.renewbtn:active { transform: scale(.97); }
.renewbtn svg { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.renewbtn.sm { font-size: 11px; padding: 3px 9px; }
.renewbtn.lg { margin-left: auto; align-self: center; font-size: 12.5px; padding: 6px 14px; }
.renewbtn.lg svg { width: 13px; height: 13px; }
.renewbtn.sm svg { width: 11px; height: 11px; }
.renewbtn.warn { color: var(--warn); background: rgba(217, 119, 6, .1); border-color: rgba(217, 119, 6, .32); }
.renewbtn.warn:hover { background: rgba(217, 119, 6, .18); }

/* 其余订阅:每条也是完整一张小卡,四个动作一个不少 */
.pmwrap { display: flex; flex-direction: column; gap: 10px; }
.profmini { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 12px 14px; box-shadow: 0 4px 14px rgba(15, 23, 42, .04); }
.pm-top { display: flex; align-items: center; gap: 11px; }
.pm-top b { flex: 1; min-width: 0; font-size: 14px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pm-meta { display: flex; align-items: center; gap: 10px; margin-top: 6px; padding-left: 29px; }
.pm-meta > span { flex: 1; min-width: 0; font-size: 11px; color: var(--muted2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pm-meta em.bad { font-style: normal; color: var(--danger); }
.pm-act { display: flex; gap: 8px; margin-top: 11px; padding-top: 10px; border-top: 1px solid var(--line); }
.pm-act .btn { flex: 1; padding: 7px 0; border-radius: 10px; }
.pm-act .btn.icon { flex: none; width: 38px; padding: 7px 0; }

/* 全局禁直连的小盾(首页状态下面)/ 刷新后待应用的提示(首页、订阅卡片、节点面板) */
.guard-pill { display: inline-flex; align-items: center; gap: 5px; margin: 6px auto 0; font-size: 11px; color: var(--brand2); background: rgba(47, 139, 255, .1); border: 1px solid rgba(47, 139, 255, .25); border-radius: 999px; padding: 3px 10px; max-width: 100%; }
.guard-pill.warn { color: var(--warn); background: rgba(217, 119, 6, .1); border-color: rgba(217, 119, 6, .3); }
.pending-pill, .pc-pending, .notice { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--muted2); background: rgba(47, 139, 255, .07); border: 1px solid rgba(47, 139, 255, .2); border-radius: 12px; padding: 8px 12px; margin: 8px 0; text-align: left; }
.pending-pill > span, .pc-pending > span, .notice > span { flex: 1; min-width: 0; }
.pending-pill { width: 100%; box-sizing: border-box; }
.pc-pending { margin: 8px 0 0; }
