/* 客户自助控制台样式 —— 由 templates/client.html 内联样式外移, 走 /c/client.css */
    :root {
      /* 中性色阶：页面只允许在这套色阶里取色 */
      --bg:            #f5f6f8;
      --surface:       #ffffff;
      --surface-sub:   #fafbfc;
      --line:          #e6e8ec;
      --line-soft:     #eff1f4;
      --line-strong:   #d6dae0;
      --ink:           #16181d;
      --ink-2:         #5c646f;
      --ink-3:         #8b939f;

      /* 单一主色，只用于"当前最该点的那一下"和焦点环 */
      --accent:        #2c5fd0;
      --accent-hover:  #24519f;
      --accent-soft:   #eef3fc;

      /* 语义色：一律"深字 + 浅底 + 同族描边"，不用高饱和大色块 */
      --ok:            #1a7f45;  --ok-bg:  #eef7f1;  --ok-line:  #cfe6d8;
      --warn:          #8a5a08;  --warn-bg:#fdf6e7;  --warn-line:#f0dfba;
      --bad:           #b22a22;  --bad-bg: #fdf1f0;  --bad-line: #f2d4d1;

      --radius:   14px;
      --radius-sm: 9px;
      --radius-xs: 6px;
      --shadow-1: 0 1px 2px rgba(16, 24, 40, .04);
      --shadow-2: 0 2px 8px rgba(16, 24, 40, .06);
      --shadow-3: 0 12px 40px rgba(16, 24, 40, .14);

      --sp-1: 4px; --sp-2: 8px; --sp-3: 12px; --sp-4: 16px;
      --sp-5: 20px; --sp-6: 24px; --sp-8: 32px; --sp-10: 40px;

      --mono: ui-monospace, SFMono-Regular, "Cascadia Mono", Consolas, "Liberation Mono", monospace;
    }

    * { box-sizing: border-box; }
    html, body { margin: 0; padding: 0; }
    body {
      background: var(--bg);
      color: var(--ink);
      font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei UI",
                   "Microsoft YaHei", "PingFang SC", "Noto Sans SC", sans-serif;
      font-size: 14px;
      line-height: 1.55;
      -webkit-font-smoothing: antialiased;
    }
    button { font: inherit; color: inherit; }
    [hidden] { display: none !important; }

    .ic { width: 16px; height: 16px; flex: none; stroke: currentColor; fill: none;
          stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
    .ic-14 { width: 14px; height: 14px; }
    .ic-18 { width: 18px; height: 18px; }
    .ic-22 { width: 22px; height: 22px; }

    :focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

    /* ---------- 顶栏 ---------- */
    .topbar {
      position: sticky; top: 0; z-index: 30;
      display: flex; align-items: center; justify-content: space-between;
      height: 56px; padding: 0 var(--sp-6);
      background: rgba(255, 255, 255, .88);
      backdrop-filter: saturate(180%) blur(8px);
      border-bottom: 1px solid var(--line);
    }
    .brand { display: flex; align-items: center; gap: var(--sp-3); font-weight: 600; letter-spacing: .2px; flex-shrink: 0; white-space: nowrap; }
    .brand-mark {
      width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center;
      background: var(--ink); color: #fff;
    }
    .brand-mark .ic { stroke-width: 1.9; }
    .topbar-right { display: flex; align-items: center; gap: var(--sp-4); min-width: 0; justify-content: flex-end; }
    .who {
      display: inline-flex; align-items: center; gap: var(--sp-2);
      color: var(--ink-2); font-size: 13px;
      padding: 4px 10px 4px 8px; border: 1px solid var(--line);
      border-radius: 999px; background: var(--surface);
      max-width: min(680px, 60vw);
      white-space: nowrap;
    }
    .who span { flex-shrink: 0; white-space: nowrap; }
    .who b { font-weight: 600; color: var(--ink); overflow: hidden;
             text-overflow: ellipsis; white-space: nowrap; min-width: 0; }

    /* ---------- 布局 ---------- */
    main { width: 100%; max-width: 1160px; margin-inline: auto;
           padding: var(--sp-8) var(--sp-6) 96px; }
    @media (min-width: 1560px) { main { max-width: 1320px; } }
    .page-head {
      display: flex; align-items: flex-end; justify-content: space-between;
      gap: var(--sp-4); margin-bottom: var(--sp-5);
    }
    .page-title { font-size: 18px; font-weight: 600; letter-spacing: -.1px; }
    .page-sub { color: var(--ink-3); font-size: 13px; margin-top: 2px; }
    .sync {
      display: flex; align-items: center; gap: var(--sp-2);
      color: var(--ink-3); font-size: 12.5px; white-space: nowrap;
    }
    .sync button {
      display: inline-flex; align-items: center; gap: 5px;
      background: none; border: 0; padding: 3px 6px; border-radius: var(--radius-xs);
      color: var(--ink-2); cursor: pointer; font-size: 12.5px;
    }
    .sync button:hover { background: #eef0f3; color: var(--ink); }

    .grid { display: grid; gap: var(--sp-5); grid-template-columns: repeat(auto-fit, minmax(min(360px, 100%), 1fr)); }
    .grid.is-single { grid-template-columns: 1fr; }

    /* ---------- 机器卡 ---------- */
    .card {
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--radius); box-shadow: var(--shadow-1);
      transition: box-shadow .18s ease, border-color .18s ease;
    }
    .card:hover { box-shadow: var(--shadow-2); }
    .card.is-off { background: var(--surface-sub); }

    .card-head {
      display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4);
      padding: var(--sp-4) var(--sp-5); border-bottom: 1px solid var(--line);
    }
    .machine-id { display: flex; align-items: center; gap: var(--sp-3); font-size: 15px; font-weight: 600; }
    .machine-id .ic { color: var(--ink-3); }
    .machine-id .num { font-family: var(--mono); font-size: 14.5px; letter-spacing: .3px; }

    .dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; flex: none; }
    .status { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 500; }
    button.status { background: none; border: 0; padding: 0; cursor: pointer; }
    .s-run  { color: var(--ok); }
    .s-off  { color: var(--ink-3); }
    .s-busy { color: var(--accent); }
    .s-busy .dot { animation: pulse 1.4s ease-in-out infinite; }
    @keyframes pulse { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: .35; transform: scale(.8); } }

    .card-body { padding: var(--sp-5); display: flex; flex-direction: column; gap: var(--sp-5); }
    .is-single .card-body {
      display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(300px, .9fr);
      gap: var(--sp-6); align-items: stretch;
    }

    .col-left { display: flex; flex-direction: column; gap: var(--sp-5); min-width: 0; }
    /* 右侧操作栏：浅灰底包裹，把按钮下方原本空着的一块也收进面板里，左右重心才平衡 */
    .col-right {
      display: flex; flex-direction: column; gap: var(--sp-3); min-width: 0;
      background: var(--line-soft); border: 1px solid var(--line);
      border-radius: var(--radius-sm); padding: var(--sp-4);
    }

    /* 租期 / 到期 */
    .facts { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-4); }
    .fact-label { font-size: 12px; color: var(--ink-3); margin-bottom: 3px; }
    .fact-value { font-size: 14px; font-weight: 550; font-variant-numeric: tabular-nums; }
    .countdown {
      display: inline-flex; align-items: center; gap: 5px; margin-top: 5px;
      font-size: 12px; color: var(--ink-2);
      background: var(--surface-sub); border: 1px solid var(--line);
      padding: 1px 7px; border-radius: 999px; font-variant-numeric: tabular-nums;
    }
    .countdown.soon { color: var(--warn); background: var(--warn-bg); border-color: var(--warn-line); }
    .countdown.over { color: var(--bad); background: var(--bad-bg); border-color: var(--bad-line); }

    /* 连接信息：外框保留，内部分隔线一律减淡，让表格看起来更精密 */
    .panel { border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
    .panel-head {
      display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3);
      padding: 9px var(--sp-4); background: var(--surface-sub);
      border-bottom: 1px solid var(--line-soft); font-size: 12.5px; color: var(--ink-2);
    }
    .panel-head .t { display: flex; align-items: center; gap: 6px; font-weight: 550; }
    .panel-foot { padding: 8px var(--sp-4); border-top: 1px solid var(--line-soft);
                  background: var(--surface-sub); }
    .rows { display: flex; flex-direction: column; }
    .row {
      display: flex; align-items: center; gap: var(--sp-3);
      padding: 9px var(--sp-4); border-bottom: 1px solid var(--line-soft);
    }
    .row:last-child { border-bottom: 0; }
    .row:hover { background: #fbfcfd; }
    .row-k { width: 72px; flex: none; font-size: 12.5px; color: var(--ink-3); }
    .row-v {
      flex: 1; min-width: 0; font-family: var(--mono); font-size: 13px;
      letter-spacing: .15px; font-variant-numeric: tabular-nums;
      overflow: hidden; text-overflow: ellipsis; white-space: nowrap; user-select: all;
    }
    .icon-btn {
      display: inline-grid; place-items: center; width: 26px; height: 26px; flex: none;
      background: none; border: 1px solid transparent; border-radius: var(--radius-xs);
      color: var(--ink-3); cursor: pointer; transition: .15s;
    }
    .icon-btn:hover { color: var(--ink); background: #f0f2f5; border-color: var(--line); }
    .icon-btn.done { color: var(--ok); }
    .link-btn {
      background: none; border: 0; padding: 0; cursor: pointer;
      color: var(--ink-2); font-size: 12.5px; text-decoration: none;
      display: inline-flex; align-items: center; gap: 4px;
    }
    .link-btn:hover { color: var(--accent); }

    .net-chip {
      display: inline-flex; align-items: center; gap: 5px; font-size: 12px;
      color: var(--ok); background: var(--ok-bg); border: 1px solid var(--ok-line);
      padding: 1px 8px; border-radius: 999px;
    }

    /* 操作区 */
    .actions { display: flex; flex-direction: column; gap: 6px; }
    .actions-title { font-size: 12px; color: var(--ink-3); margin-bottom: 0; }
    .btn-row { display: flex; gap: var(--sp-2); }
    .btn {
      position: relative; display: inline-flex; align-items: center; justify-content: center;
      gap: 6px; height: 34px; padding: 0 14px; flex: 1;
      background: var(--surface); border: 1px solid var(--line-strong);
      border-radius: var(--radius-sm); cursor: pointer; white-space: nowrap;
      font-size: 13.5px; font-weight: 500; color: var(--ink);
      transition: background .15s, border-color .15s, color .15s, transform .06s;
    }
    .btn:hover:not(:disabled) { background: #f6f7f9; border-color: #c3c9d2; }
    .btn:active:not(:disabled) { transform: translateY(.5px); }
    .btn:disabled { cursor: not-allowed; }
    .btn.primary { background: var(--accent); border-color: var(--accent); color: #fff; }
    .btn.primary:hover:not(:disabled) { background: var(--accent-hover); border-color: var(--accent-hover); }
    .btn.danger { color: var(--bad); border-color: var(--bad-line); background: var(--bad-bg); }
    .btn.danger:hover:not(:disabled) { background: #fbe7e5; border-color: #e7bfb9; }
    /* 卡片上的"重装系统"：平时与普通次级按钮无异，悬停才露红字，避免整页粉底 */
    .btn.danger-ghost:hover:not(:disabled) { color: var(--bad); border-color: var(--bad-line); background: var(--bad-bg); }
    /* 禁用态一律回到中性：不给客户留一块"看着能点"的色块（转圈中的按钮保留本色） */
    .btn:disabled:not(.busy), .btn.primary:disabled:not(.busy),
    .btn.danger:disabled:not(.busy), .btn.danger-ghost:disabled:not(.busy) {
      background: #e8ebef; border-color: #e0e4e9; color: #99a1ac;
    }
    .btn:disabled .ic { opacity: .8; }
    .btn.busy { color: transparent; pointer-events: none; }
    .btn.busy::after {
      content: ""; position: absolute; width: 15px; height: 15px;
      border: 2px solid currentColor; border-top-color: transparent; border-radius: 50%;
      color: var(--ink-2); animation: spin .7s linear infinite;
    }
    .btn.primary.busy::after { color: #fff; border-color: rgba(255,255,255,.5); border-top-color: transparent; }
    @keyframes spin { to { transform: rotate(360deg); } }
    /* 弹窗底部按钮会被复用（确认/危险两种配色），去掉配色过渡，避免切换瞬间闪一下蓝底 */
    .modal-foot .btn { transition: transform .06s; }

    .hint { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--ink-3); }

    /* 重装进行中的卡内进度 */
    .progress-card {
      border: 1px solid var(--accent); background: var(--accent-soft);
      border-radius: var(--radius-sm); padding: var(--sp-4); cursor: pointer;
    }
    .progress-top { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); }
    .progress-title { display: flex; align-items: center; gap: 8px; font-weight: 600; color: var(--accent); }
    .progress-pct { font-size: 12px; color: var(--ink-2); font-variant-numeric: tabular-nums; }
    .bar { height: 5px; border-radius: 999px; background: #dbe4f5; overflow: hidden; margin: 10px 0 8px; }
    .bar > i { display: block; height: 100%; width: 0; border-radius: 999px; background: var(--accent);
               transition: width .6s cubic-bezier(.4, 0, .2, 1); }
    .bar.indet > i { width: 32%; animation: slide 1.3s ease-in-out infinite; }
    @keyframes slide { 0% { margin-left: -32%; } 100% { margin-left: 100%; } }
    .progress-meta { display: flex; justify-content: space-between; font-size: 12px; color: var(--ink-2);
                     font-variant-numeric: tabular-nums; }

    /* 重装完成后的新密码条 */
    .reveal {
      display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); flex-wrap: wrap;
      border: 1px solid var(--ok-line); background: var(--ok-bg);
      border-radius: var(--radius-sm); padding: var(--sp-3) var(--sp-4);
    }
    .reveal .k { font-size: 12.5px; color: var(--ok); display: flex; align-items: center; gap: 6px; font-weight: 550; }
    .reveal .t { font-size: 12px; color: var(--ink-2); margin-top: 4px; }
    .reveal .v { font-family: var(--mono); font-size: 14px; letter-spacing: .5px; user-select: all;
                 background: #fff; border: 1px solid var(--ok-line); border-radius: 5px; padding: 1px 8px; }

    /* ---------- 骨架屏 ---------- */
    .sk-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: var(--sp-5); }
    .sk { border-radius: 6px; background: linear-gradient(90deg, #eef0f3 25%, #f6f7f9 37%, #eef0f3 63%);
          background-size: 400% 100%; animation: shimmer 1.4s ease infinite; }
    @keyframes shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }
    .sk.h16 { height: 16px; } .sk.h10 { height: 10px; } .sk.h34 { height: 34px; }
    .sk.w40 { width: 40%; } .sk.w60 { width: 60%; } .sk.w100 { width: 100%; }
    .sk-stack { display: flex; flex-direction: column; gap: var(--sp-4); }

    /* ---------- 空态 / 错误态 ---------- */
    .state {
      max-width: 460px; margin: 8vh auto 0; text-align: center;
      background: var(--surface); border: 1px solid var(--line);
      border-radius: var(--radius); box-shadow: var(--shadow-1); padding: var(--sp-10) var(--sp-8);
    }
    .state-ic {
      width: 44px; height: 44px; margin: 0 auto var(--sp-4); border-radius: 12px;
      display: grid; place-items: center; background: var(--surface-sub);
      border: 1px solid var(--line); color: var(--ink-3);
    }
    .state-ic.bad { background: var(--bad-bg); border-color: var(--bad-line); color: var(--bad); }
    .state h2 { margin: 0 0 6px; font-size: 16px; font-weight: 600; }
    .state p { margin: 0 0 var(--sp-5); color: var(--ink-2); font-size: 13.5px; }
    .state .btn { flex: 0 0 auto; min-width: 130px; }

    /* ---------- 输入 ---------- */
    .field { display: flex; gap: var(--sp-2); }
    .input {
      width: 100%; height: 36px; padding: 0 11px;
      border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
      background: var(--surface); color: var(--ink); font-size: 14px; font-family: var(--mono);
    }
    .input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
    .field-msg { font-size: 12.5px; color: var(--ink-3); margin-top: 8px; }

    /* ---------- 勾选 / 警示块 ---------- */
    .check { display: flex; align-items: flex-start; gap: 8px; font-size: 13px; color: var(--ink-2);
             cursor: pointer; margin-top: 14px; }
    .check input { margin: 3px 0 0; width: 15px; height: 15px; flex: none; cursor: pointer;
                   accent-color: var(--accent); }
    .check.strong { color: var(--ink); font-weight: 600; }
    .notice { margin-top: 14px; border: 1px solid var(--bad-line); background: var(--bad-bg);
              color: var(--bad); border-radius: var(--radius-sm); padding: 12px 14px;
              font-size: 13px; line-height: 1.65; }
    .notice.warn { border-color: var(--warn-line); background: var(--warn-bg); color: var(--warn); }
    .quota { margin-top: 12px; border: 1px solid var(--line); background: var(--surface-sub);
             border-radius: var(--radius-sm); padding: 10px 12px; font-size: 12.5px;
             color: var(--ink-2); line-height: 1.6; }
    .quota b { display: block; color: var(--ink); font-weight: 600; margin-top: 4px;
               font-family: var(--mono); font-size: 12px; }
    .okbox { margin-top: 12px; border: 1px solid var(--ok-line); background: var(--ok-bg);
             border-radius: var(--radius-sm); padding: 10px 12px; font-size: 12.5px;
             color: var(--ok); line-height: 1.6; }
    .okbox .l { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3);
                margin-top: 4px; font-size: 13px; }
    .okbox .a { font-family: var(--mono); font-weight: 600; user-select: all; }

    /* ---------- 重装弹窗现代优化结构 ---------- */
    .v1-machine-pill { font-family: var(--mono); font-size: 12px; font-weight: 600; padding: 1px 7px; background: var(--surface-sub); color: var(--ink-2); border-radius: 5px; border: 1px solid var(--line); }
    .v1-subtitle { font-size: 12.5px; color: var(--ink-3); margin-top: 2px; }
    .v1-danger-card { background: #fff8f8; border: 1px solid #fee2e2; border-radius: 10px; padding: 12px 14px; display: flex; gap: 10px; align-items: flex-start; margin-top: 10px; }
    .v1-danger-card .ic { width: 17px; height: 17px; color: #dc2626; flex-shrink: 0; margin-top: 2px; }
    .v1-danger-text { font-size: 13px; color: #991b1b; line-height: 1.55; }
    .v1-danger-text b { font-weight: 700; color: #7f1d1d; }
    .v1-info-list { background: var(--surface-sub); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; display: flex; flex-direction: column; gap: 8px; font-size: 12.5px; color: var(--ink-2); margin-top: 11px; }
    .v1-info-item { display: flex; align-items: center; gap: 9px; }
    .v1-info-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--ink-3); flex-shrink: 0; }
    .v1-info-item b { color: var(--ink); font-weight: 600; }
    .v1-quota-strip { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; display: flex; align-items: center; justify-content: space-between; margin-top: 11px; }
    .v1-quota-left { display: flex; flex-direction: column; gap: 2px; }
    .v1-quota-title { font-size: 12px; color: var(--ink-2); display: flex; align-items: center; gap: 6px; }
    .v1-quota-mode-badge { font-size: 11px; padding: 1px 6px; background: var(--surface-sub); border-radius: 4px; color: var(--ink-2); font-weight: 500; border: 1px solid var(--line); }
    .v1-quota-rule { font-size: 11.5px; color: var(--ink-3); }
    .v1-quota-badges { display: flex; align-items: baseline; gap: 4px; }
    .v1-quota-rem { font-size: 18px; font-weight: 700; font-family: var(--mono); color: var(--ink); }
    .v1-quota-rem.low { color: var(--bad); }
    .v1-quota-total { font-size: 12px; color: var(--ink-3); font-family: var(--mono); }
    .v1-confirm-box { margin-top: 12px; display: flex; align-items: center; gap: 9px; cursor: pointer; font-size: 13px; font-weight: 500; color: var(--ink); }

    /* ---------- 弹窗 ---------- */
    .backdrop {
      position: fixed; inset: 0; z-index: 60; display: grid; place-items: center;
      padding: var(--sp-6); background: rgba(20, 24, 32, .38);
      opacity: 0; pointer-events: none; transition: opacity .16s ease;
    }
    .backdrop.open { opacity: 1; pointer-events: auto; }
    .modal {
      width: 100%; max-width: 430px; max-height: calc(100vh - 48px);
      display: flex; flex-direction: column; background: var(--surface);
      border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-3);
      transform: translateY(6px) scale(.99); transition: transform .18s cubic-bezier(.4, 0, .2, 1);
    }
    .backdrop.open .modal { transform: none; }
    .modal-head { display: flex; align-items: center; gap: var(--sp-3); padding: var(--sp-5) var(--sp-5) 0; }
    .modal-head h3 { margin: 0; font-size: 15.5px; font-weight: 600; flex: 1; }
    .modal-ic { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; flex: none;
                background: var(--surface-sub); border: 1px solid var(--line); color: var(--ink-2); }
    .modal-ic.bad { background: var(--bad-bg); border-color: var(--bad-line); color: var(--bad); }
    .modal-ic.busy { background: var(--accent-soft); border-color: #cdd9f0; color: var(--accent); }
    .modal-ic.busy .ic { animation: spin 1.8s linear infinite; }
    .modal-body { padding: var(--sp-4) var(--sp-5) 0; color: var(--ink-2); font-size: 13.5px;
                  overflow-y: auto; flex: 1 1 auto; }
    .modal-body b { color: var(--ink); font-weight: 600; }
    .modal-foot { display: flex; gap: var(--sp-2); justify-content: flex-end; padding: var(--sp-5); }
    .modal .btn { flex: 0 0 auto; min-width: 88px; }
    .kv { display: flex; justify-content: space-between; gap: var(--sp-4); padding: 7px 0;
          border-bottom: 1px dashed var(--line); font-size: 13px; }
    .kv:last-of-type { border-bottom: 0; }
    .kv span:first-child { color: var(--ink-3); }
    .kv span:last-child { color: var(--ink); font-family: var(--mono); }

    /* ---------- 轻提示 ---------- */
    .toasts { position: fixed; right: var(--sp-6); bottom: var(--sp-6); z-index: 90;
              display: flex; flex-direction: column; gap: var(--sp-2); align-items: flex-end; }
    .toast {
      display: flex; align-items: center; gap: 9px; max-width: 380px;
      padding: 9px 14px; background: #16181d; color: #fff;
      border-radius: 10px; box-shadow: var(--shadow-3); font-size: 13.5px;
      animation: rise .22s cubic-bezier(.2, .8, .2, 1);
    }
    .toast.err { background: #7f1d1a; }
    .toast .ic { color: #fff; }
    @keyframes rise { from { opacity: 0; transform: translateY(8px); } }

    /* ---------- 响应式 ---------- */
    @media (max-width: 1000px) {
      .is-single .card-body { grid-template-columns: 1fr; }
    }
    @media (max-width: 640px) {
      .is-single .card-body { grid-template-columns: 1fr; }
      .grid { grid-template-columns: 1fr; gap: var(--sp-4); }
      /* 顶栏与页头各压成一行 */
      .topbar { height: 48px; padding: 0 var(--sp-4); }
      .brand { font-size: 15px; gap: var(--sp-2); }
      .brand-mark { width: 25px; height: 25px; border-radius: 7px; }
      .who { padding: 3px 8px; font-size: 12.5px; max-width: min(240px, 48vw); }
      .who span { display: none; }
      main { padding: var(--sp-4) var(--sp-3) 72px; }
      .page-head { align-items: baseline; gap: var(--sp-2); margin-bottom: var(--sp-4); }
      .page-head > div:first-child { display: flex; align-items: baseline; gap: 7px; min-width: 0; }
      .page-title { font-size: 17px; }
      .page-sub { margin-top: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
      .sync { margin-left: auto; }
      /* 卡片头与卡内留白收紧 */
      .card-head { padding: 10px var(--sp-3); }
      .machine-id { font-size: 14px; gap: var(--sp-2); }
      .machine-id .num { font-size: 13.5px; }
      .status { font-size: 12.5px; }
      .card-body { padding: 14px var(--sp-3); gap: var(--sp-4); }
      .col-left { gap: var(--sp-4); }
      /* 租期/到期：标签与值同一行，两行读完（原来是四行） */
      .facts { grid-template-columns: 1fr; gap: 5px; }
      .facts > div { display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 7px; }
      .fact-label { margin-bottom: 0; flex: none; }
      .fact-value { font-size: 14px; }
      .countdown { margin-top: 0; }
      /* 连接表：行距收紧，标签列沿用宽屏的 72px 固定宽，最长标签也不换行 */
      .panel-head { padding: 8px var(--sp-3); }
      .panel-foot { padding: 8px var(--sp-3); }
      .row { padding: 8px var(--sp-3); gap: var(--sp-2); }
      /* 操作区：电源/维护标题挪到按钮同一行，整块少两层高度 */
      .col-right { gap: var(--sp-2); padding: var(--sp-3); }
      .actions { flex-direction: row; align-items: center; gap: var(--sp-2); }
      .actions-title { flex: none; width: 30px; }
      .btn-row { flex: 1; gap: 6px; flex-wrap: wrap; }
      .btn { height: 36px; padding: 0 12px; font-size: 13px; min-width: 0; flex: 1 1 auto; }
      .progress-card { padding: var(--sp-3); }
      .reveal { padding: var(--sp-3); }
      .toasts { left: var(--sp-4); right: var(--sp-4); bottom: 92px; align-items: stretch; }
      .toast { max-width: none; }
    }
    @media (prefers-reduced-motion: reduce) {
      * { animation-duration: .01ms !important; animation-iteration-count: 1 !important;
          transition-duration: .01ms !important; }
    }
