/* IP 管理 · 设计系统 · 素白（2026-11-18 重写）
   One quiet material: white surfaces on a light grey canvas, hairline edges and a
   soft shadow, one radius scale (cards 18, tiles 12, fields 10, controls round)
   and one spacing scale. No gradients, glass or tinted backgrounds: depth comes
   from spacing, rounded corners and type. Black capsules mark the selected item
   and the main action; blue is only for links and live state.
   Every control is our own because Argon restyles bare button/select/input/table/
   checkbox/h1–h4 globally; lists use CSS grid, never <table>. */

.ce-app, .ce-sheet, .ce-modal-host, .ce-menu {
  --c-canvas: #f5f5f7; --c-surface: #fff; --c-surface-2: #fafafc;
  --c-fill: rgba(118,118,128,.08); --c-fill-2: rgba(118,118,128,.14); --c-hover: rgba(0,0,0,.025);
  --c-line: rgba(0,0,0,.06); --c-line-2: rgba(0,0,0,.1);
  --c-label: #1d1d1f; --c-label-2: #6e6e73; --c-label-3: #86868b; --c-label-4: #c7c7cc;
  --c-ink: #1d1d1f; --c-ink-text: #fff;
  --c-accent: #0071e3; --c-accent-text: #0066cc; --c-accent-tint: rgba(0,113,227,.09);
  --c-green: #34c759; --c-green-text: #248a3d; --c-green-tint: rgba(52,199,89,.13);
  --c-red: #ff3b30; --c-red-text: #d70015; --c-red-tint: rgba(255,59,48,.1);
  --c-orange: #ff9500; --c-orange-text: #c93400; --c-orange-tint: rgba(255,149,0,.13);
  --c-violet: #8e6cf2; --c-pink: #ff2d55; --c-teal: #30b0c7;
  --sh-card: 0 0 0 .5px rgba(0,0,0,.05), 0 1px 2px rgba(0,0,0,.03), 0 6px 20px -10px rgba(0,0,0,.08);
  --sh-lift: 0 0 0 .5px rgba(0,0,0,.06), 0 2px 4px rgba(0,0,0,.03), 0 14px 32px -14px rgba(0,0,0,.14);
  --sh-ctl: 0 0 0 .5px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.05);
  --sh-pop: 0 0 0 .5px rgba(0,0,0,.08), 0 18px 48px -12px rgba(0,0,0,.22);
  --r-card: 18px; --r-tile: 12px; --r-ctl: 10px; --r-sheet: 24px; --r-pill: 999px;
  --sp-1: 4px; --sp-2: 8px; --sp-3: 12px; --sp-4: 16px; --sp-5: 20px; --sp-6: 24px; --sp-7: 32px;
  --f-sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI Variable Text", "Segoe UI", "PingFang SC", "HarmonyOS Sans SC", "Microsoft YaHei UI", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  --f-mono: "SF Mono", "JetBrains Mono", "Cascadia Mono", ui-monospace, Menlo, Consolas, monospace;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-darkmode="false"]) .ce-app, :root:not([data-darkmode="false"]) .ce-sheet, :root:not([data-darkmode="false"]) .ce-modal-host, :root:not([data-darkmode="false"]) .ce-menu {
    --c-canvas: #0f0f11; --c-surface: #1c1c1e; --c-surface-2: #232325;
    --c-fill: rgba(118,118,128,.18); --c-fill-2: rgba(118,118,128,.26); --c-hover: rgba(255,255,255,.04);
    --c-line: rgba(255,255,255,.07); --c-line-2: rgba(255,255,255,.12);
    --c-label: #f5f5f7; --c-label-2: #a1a1a6; --c-label-3: #8e8e93; --c-label-4: #48484a;
    --c-ink: #f5f5f7; --c-ink-text: #1d1d1f;
    --c-accent: #0a84ff; --c-accent-text: #409cff; --c-accent-tint: rgba(10,132,255,.18);
    --c-green: #30d158; --c-green-text: #30d158; --c-green-tint: rgba(48,209,88,.16);
    --c-red: #ff453a; --c-red-text: #ff6961; --c-red-tint: rgba(255,69,58,.16);
    --c-orange: #ff9f0a; --c-orange-text: #ffb340; --c-orange-tint: rgba(255,159,10,.16);
    --sh-card: 0 0 0 .5px rgba(255,255,255,.06); --sh-lift: 0 0 0 .5px rgba(255,255,255,.08), 0 14px 32px -14px rgba(0,0,0,.6);
    --sh-ctl: 0 0 0 .5px rgba(255,255,255,.12); --sh-pop: 0 0 0 .5px rgba(255,255,255,.1), 0 18px 48px -12px rgba(0,0,0,.7);
  }
}
[data-darkmode="true"] .ce-app, [data-darkmode="true"] .ce-sheet, [data-darkmode="true"] .ce-modal-host, [data-darkmode="true"] .ce-menu {
  --c-canvas: #0f0f11; --c-surface: #1c1c1e; --c-surface-2: #232325;
  --c-fill: rgba(118,118,128,.18); --c-fill-2: rgba(118,118,128,.26); --c-hover: rgba(255,255,255,.04);
  --c-line: rgba(255,255,255,.07); --c-line-2: rgba(255,255,255,.12);
  --c-label: #f5f5f7; --c-label-2: #a1a1a6; --c-label-3: #8e8e93; --c-label-4: #48484a;
  --c-ink: #f5f5f7; --c-ink-text: #1d1d1f;
  --c-accent: #0a84ff; --c-accent-text: #409cff; --c-accent-tint: rgba(10,132,255,.18);
  --c-green: #30d158; --c-green-text: #30d158; --c-green-tint: rgba(48,209,88,.16);
  --c-red: #ff453a; --c-red-text: #ff6961; --c-red-tint: rgba(255,69,58,.16);
  --c-orange: #ff9f0a; --c-orange-text: #ffb340; --c-orange-tint: rgba(255,159,10,.16);
  --sh-card: 0 0 0 .5px rgba(255,255,255,.06); --sh-lift: 0 0 0 .5px rgba(255,255,255,.08), 0 14px 32px -14px rgba(0,0,0,.6);
  --sh-ctl: 0 0 0 .5px rgba(255,255,255,.12); --sh-pop: 0 0 0 .5px rgba(255,255,255,.1), 0 18px 48px -12px rgba(0,0,0,.7);
}

/* ---------- reset inside our scope (beats Argon's bare element rules) ---------- */
.ce-app, .ce-sheet { font-family: var(--f-sans); font-size: 14px; line-height: 1.5; color: var(--c-label); -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; text-rendering: optimizeLegibility; }
.ce-app *, .ce-sheet * { box-sizing: border-box; }
.ce-app button, .ce-app input, .ce-app select, .ce-app textarea,
.ce-sheet button, .ce-sheet input, .ce-sheet select, .ce-sheet textarea {
  margin: 0; padding: 0; border: 0; border-radius: 0; background: none; box-shadow: none; outline: none;
  font: inherit; line-height: normal; color: inherit; text-transform: none; min-width: 0; width: auto; height: auto; transition: none; }
.ce-app a, .ce-sheet a { color: var(--c-accent-text); text-decoration: none !important; }
.ce-app small, .ce-sheet small { font-size: 12px; line-height: 1.4; }
.ce-app p, .ce-sheet p { margin: 0; }
.ce-app [hidden], .ce-sheet [hidden] { display: none !important; }
.ce-mono { font-family: var(--f-mono); font-size: .94em; font-variant-numeric: tabular-nums; letter-spacing: 0; }
.ce-num { font-variant-numeric: tabular-nums; }
.ce-2 { color: var(--c-label-2); } .ce-3 { color: var(--c-label-3); }
.ce-grow { flex: 1 1 auto; }
.ce-app :focus-visible, .ce-sheet :focus-visible { outline: 2px solid var(--c-accent) !important; outline-offset: 2px; }

/* ---------- type ---------- */
.ce-title { font-size: 28px; font-weight: 600; letter-spacing: -.022em; line-height: 1.15; }
.ce-h2 { font-size: 16px; font-weight: 600; letter-spacing: -.01em; }
.ce-h3 { font-size: 15px; font-weight: 600; letter-spacing: -.005em; }
.ce-caption { font-size: 12.5px; color: var(--c-label-3); }
.ce-section-head { display: flex; align-items: baseline; gap: 10px; padding: 0 2px; margin: 28px 0 12px; }
.ce-section-head .ce-h3 { font-size: 17px; }
.ce-footnote { padding: 12px 2px 0; font-size: 12px; line-height: 1.7; color: var(--c-label-3); max-width: 880px; }
.ce-app details.ce-fold { margin-top: 14px; }
.ce-app details.ce-fold > summary { display: inline-flex; align-items: center; gap: 6px; list-style: none; cursor: pointer; font-size: 12.5px; color: var(--c-label-3); }
.ce-app details.ce-fold > summary::-webkit-details-marker { display: none; }
.ce-app details.ce-fold > summary::after { content: "›"; font-size: 15px; transition: transform .2s; }
.ce-app details.ce-fold[open] > summary::after { transform: rotate(90deg); }

/* ---------- icons, dots, tags, badges ---------- */
.ce-icon { display: inline-block; width: 16px; height: 16px; flex: none; vertical-align: -3px; }
.ce-icon svg, svg.ce-icon { width: 100%; height: 100%; display: block; }
.ce-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--c-label-4); flex: none; display: inline-block; }
.ce-dot.ce-ok { background: var(--c-green); } .ce-dot.ce-fail { background: var(--c-red); } .ce-dot.ce-wait { background: var(--c-orange); } .ce-dot.ce-info { background: var(--c-accent); }
.ce-dot.ce-live { background: var(--c-green); animation: ce-pulse 2.2s infinite; }
@keyframes ce-pulse { 0% { box-shadow: 0 0 0 0 rgba(52,199,89,.45); } 70% { box-shadow: 0 0 0 6px rgba(52,199,89,0); } 100% { box-shadow: 0 0 0 0 rgba(52,199,89,0); } }
.ce-tag { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 9px; border-radius: var(--r-pill); font-size: 11.5px; font-weight: 500; background: var(--c-fill); color: var(--c-label-2); white-space: nowrap; max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.ce-tag.ce-ok { background: var(--c-green-tint); color: var(--c-green-text); }
.ce-tag.ce-fail { background: var(--c-red-tint); color: var(--c-red-text); }
.ce-tag.ce-wait { background: var(--c-orange-tint); color: var(--c-orange-text); }
.ce-tag.ce-info { background: var(--c-accent-tint); color: var(--c-accent-text); }
/* status capsules beside a page title: white, round, quiet */
.ce-chip-s, .ce-ed-badge { display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 13px; border-radius: var(--r-pill); background: var(--c-surface); box-shadow: var(--sh-ctl); color: var(--c-label-2); font-size: 12.5px; font-weight: 500; white-space: nowrap; font-variant-numeric: tabular-nums; }
a.ce-chip-s { color: var(--c-accent-text); }
.ce-ed-badge > i { width: 7px; height: 7px; border-radius: 50%; background: var(--c-red); flex: none; }
.ce-ed-badge.ce-fail, .ce-chip-s.ce-fail { color: var(--c-red-text); } .ce-chip-s.ce-wait { color: var(--c-orange-text); }
.ce-chip-s.ce-mono { font-family: var(--f-sans); }

/* ---------- buttons: round capsules; black = main action ---------- */
.ce-app .ce-btn, .ce-sheet .ce-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 34px; padding: 0 15px; border-radius: var(--r-pill); background: var(--c-surface); box-shadow: var(--sh-ctl); color: var(--c-label); font-size: 13px; font-weight: 500; cursor: pointer; white-space: nowrap; user-select: none; transition: background-color .15s, color .15s, opacity .15s, transform .12s; }
.ce-app .ce-btn:hover, .ce-sheet .ce-btn:hover { background: var(--c-surface-2); }
.ce-app .ce-btn:active, .ce-sheet .ce-btn:active { transform: scale(.97); }
.ce-app .ce-btn .ce-icon, .ce-sheet .ce-btn .ce-icon { width: 15px; height: 15px; color: currentColor; }
.ce-app .ce-btn.ce-fill, .ce-sheet .ce-btn.ce-fill { background: var(--c-ink); color: var(--c-ink-text); box-shadow: none; }
.ce-app .ce-btn.ce-fill:hover, .ce-sheet .ce-btn.ce-fill:hover { background: var(--c-ink); opacity: .86; }
.ce-app .ce-btn.ce-tint, .ce-sheet .ce-btn.ce-tint { background: var(--c-fill); color: var(--c-label); box-shadow: none; }
.ce-app .ce-btn.ce-tint:hover, .ce-sheet .ce-btn.ce-tint:hover { background: var(--c-fill-2); }
.ce-app .ce-btn.ce-danger, .ce-sheet .ce-btn.ce-danger { background: var(--c-surface); color: var(--c-red-text); }
.ce-app .ce-btn.ce-fill.ce-danger, .ce-sheet .ce-btn.ce-fill.ce-danger { background: var(--c-red); color: #fff; box-shadow: none; }
.ce-app .ce-btn.ce-text, .ce-sheet .ce-btn.ce-text { height: 30px; padding: 0 10px; background: transparent; box-shadow: none; color: var(--c-accent-text); }
.ce-app .ce-btn.ce-text:hover, .ce-sheet .ce-btn.ce-text:hover { background: var(--c-fill); }
.ce-app .ce-btn.ce-text.ce-danger, .ce-sheet .ce-btn.ce-text.ce-danger { color: var(--c-red-text); }
.ce-app .ce-btn.ce-text.ce-danger:hover, .ce-sheet .ce-btn.ce-text.ce-danger:hover { background: var(--c-red-tint); }
.ce-app .ce-btn.ce-mute, .ce-sheet .ce-btn.ce-mute { color: var(--c-label-2); }
.ce-app .ce-btn.ce-small, .ce-sheet .ce-btn.ce-small { height: 28px; padding: 0 12px; font-size: 12.5px; }
.ce-app .ce-btn.ce-big, .ce-sheet .ce-btn.ce-big { height: 38px; padding: 0 19px; font-size: 14px; }
.ce-app .ce-btn:disabled, .ce-sheet .ce-btn:disabled { opacity: .4; cursor: default; transform: none; }
.ce-app .ce-btn.ce-icon-btn, .ce-sheet .ce-btn.ce-icon-btn { width: 32px; height: 32px; padding: 0; color: var(--c-label-3); }
.ce-app .ce-btn.ce-icon-btn:hover, .ce-sheet .ce-btn.ce-icon-btn:hover { color: var(--c-label); }
/* two-step destructive buttons */
.ce-arm-text { display: none; font-size: 12.5px; font-weight: 500; white-space: nowrap; }
.ce-arm.ce-armed .ce-arm-idle { display: none; }
.ce-arm.ce-armed .ce-arm-text { display: inline; }
.ce-app .ce-btn.ce-arm.ce-armed, .ce-sheet .ce-btn.ce-arm.ce-armed { width: auto; padding: 0 12px; gap: 5px; background: var(--c-red); color: #fff; box-shadow: none; animation: ce-pop-in .2s cubic-bezier(.2,.8,.2,1); }

/* ---------- fields ---------- */
.ce-app .ce-input, .ce-sheet .ce-input { width: 100%; height: 36px; padding: 0 12px; border-radius: var(--r-ctl); background: var(--c-fill); color: var(--c-label); font-size: 14px; transition: box-shadow .15s, background-color .15s; }
.ce-app textarea.ce-input, .ce-sheet textarea.ce-input { height: auto; padding: 9px 12px; line-height: 1.6; }
.ce-app .ce-input::placeholder, .ce-sheet .ce-input::placeholder { color: var(--c-label-3); }
.ce-app .ce-input:focus-visible, .ce-sheet .ce-input:focus-visible { outline: none !important; }
.ce-app .ce-input:focus, .ce-sheet .ce-input:focus { background: var(--c-surface); box-shadow: 0 0 0 1px var(--c-accent), 0 0 0 4px var(--c-accent-tint); }
.ce-app .ce-input:disabled, .ce-sheet .ce-input:disabled { color: var(--c-label-3); }
.ce-sheet .ce-file, .ce-app .ce-file { font-size: 13px; color: var(--c-label-2); }
.ce-sheet .ce-file::file-selector-button, .ce-app .ce-file::file-selector-button { margin-right: 10px; height: 32px; padding: 0 14px; border: 0; border-radius: var(--r-pill); background: var(--c-fill); color: var(--c-label); font: 500 12.5px var(--f-sans); cursor: pointer; }
/* inline editable text: reads as text, becomes a field on hover/focus */
.ce-app .ce-inline, .ce-sheet .ce-inline { width: 100%; height: 32px; margin-left: -9px; padding: 0 9px; border-radius: 8px; font-size: 15px; font-weight: 500; color: var(--c-label); background: transparent; cursor: text; transition: background-color .15s, box-shadow .15s; }
.ce-app .ce-inline:hover, .ce-sheet .ce-inline:hover { background: var(--c-fill); }
.ce-app .ce-inline:focus, .ce-sheet .ce-inline:focus { background: var(--c-surface); box-shadow: 0 0 0 1px var(--c-accent), 0 0 0 4px var(--c-accent-tint); }
/* select (native or our own list) */
.ce-app .ce-select, .ce-sheet .ce-select, .ce-app select.ce-input, .ce-sheet select.ce-input { height: 34px; padding: 0 32px 0 13px; border-radius: var(--r-ctl); background-color: var(--c-fill); color: var(--c-label); font-size: 13px; cursor: pointer; -webkit-appearance: none; appearance: none; max-width: 100%;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M3 4.5l3 3 3-3' fill='none' stroke='%2386868b' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 11px center; background-size: 12px; }
.ce-app .ce-select:hover, .ce-sheet .ce-select:hover { background-color: var(--c-fill-2); }
.ce-app .ce-dd, .ce-sheet .ce-dd { display: inline-flex; align-items: center; text-align: left; vertical-align: middle; transition: background-color .15s, box-shadow .15s; }
.ce-app .ce-dd[aria-expanded="true"], .ce-sheet .ce-dd[aria-expanded="true"] { background-color: var(--c-surface); box-shadow: 0 0 0 1px var(--c-accent), 0 0 0 4px var(--c-accent-tint); }
.ce-dd-label { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* option list (attached to <body>) */
.ce-menu { position: fixed; z-index: 2000000; box-sizing: border-box; max-width: min(440px, calc(100vw - 16px)); overflow-y: auto; overscroll-behavior: contain; padding: 5px; border-radius: 14px; background: var(--c-surface); box-shadow: var(--sh-pop);
  font-family: var(--f-sans); font-size: 13px; line-height: 1.3; color: var(--c-label); -webkit-font-smoothing: antialiased; transform-origin: top center; animation: ce-menu-in .16s cubic-bezier(.2,.8,.2,1); }
.ce-menu.ce-up { transform-origin: bottom center; }
.ce-menu.ce-menu-out { animation: ce-menu-out .12s ease forwards; pointer-events: none; }
.ce-menu-item { display: grid; grid-template-columns: 16px minmax(0, 1fr); align-items: center; gap: 7px; min-height: 32px; padding: 0 14px 0 8px; border-radius: 9px; cursor: pointer; user-select: none; }
.ce-menu-item > span:last-child { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-menu-item .ce-icon { display: inline-flex; width: 14px; height: 14px; visibility: hidden; }
.ce-menu-item .ce-icon svg { stroke-width: 2.4; }
.ce-menu-item.ce-on { font-weight: 500; }
.ce-menu-item.ce-on .ce-icon { visibility: visible; }
.ce-menu-item.ce-act { background: var(--c-fill); }
.ce-menu.ce-mono .ce-menu-item { font-family: var(--f-mono); font-size: 12.5px; font-variant-numeric: tabular-nums; }
@keyframes ce-menu-in { from { opacity: 0; transform: scale(.96) translateY(-4px); } }
@keyframes ce-menu-out { to { opacity: 0; transform: scale(.98); } }
/* stepper  − [ n ] + */
.ce-stepper { display: inline-flex; align-items: center; height: 34px; padding: 2px; border-radius: var(--r-pill); background: var(--c-fill); flex: none; }
.ce-app .ce-stepper button, .ce-sheet .ce-stepper button { width: 30px; height: 30px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; color: var(--c-label-2); font-size: 17px; line-height: 1; cursor: pointer; transition: background-color .15s, transform .12s; }
.ce-app .ce-stepper button:hover, .ce-sheet .ce-stepper button:hover { background: var(--c-surface); color: var(--c-label); box-shadow: var(--sh-ctl); }
.ce-app .ce-stepper button:active, .ce-sheet .ce-stepper button:active { transform: scale(.92); }
.ce-app .ce-stepper button:disabled, .ce-sheet .ce-stepper button:disabled { color: var(--c-label-4); background: transparent; box-shadow: none; cursor: default; }
.ce-app .ce-stepper input, .ce-sheet .ce-stepper input { width: 46px; height: 30px; text-align: center; font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--c-label); }
.ce-stepper.ce-zero input { color: var(--c-label-3); }
/* switch (iOS) */
.ce-app .ce-switch, .ce-sheet .ce-switch { position: relative; width: 44px; height: 26px; border-radius: var(--r-pill); background: var(--c-fill-2); cursor: pointer; flex: none; transition: background-color .2s; }
.ce-app .ce-switch::after, .ce-sheet .ce-switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 2px 6px rgba(0,0,0,.18), 0 0 0 .5px rgba(0,0,0,.04); transition: transform .22s cubic-bezier(.3,.7,.4,1.2); }
.ce-app .ce-switch[aria-checked="true"], .ce-sheet .ce-switch[aria-checked="true"] { background: var(--c-green); }
.ce-app .ce-switch[aria-checked="true"]::after, .ce-sheet .ce-switch[aria-checked="true"]::after { transform: translateX(18px); }
/* checkbox (Argon forces appearance:none !important; we draw our own) */
.ce-app input.ce-check, .ce-sheet input.ce-check { width: 18px !important; height: 18px !important; margin: 0 !important; padding: 0 !important; border-radius: 6px !important; border: 1.5px solid var(--c-label-4) !important; background: transparent none !important; cursor: pointer; flex: none; position: static !important; top: auto !important; -webkit-appearance: none !important; appearance: none !important; }
.ce-app input.ce-check:checked, .ce-sheet input.ce-check:checked { border-color: var(--c-ink) !important; background: var(--c-ink) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-7' fill='none' stroke='%23fff' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 100% no-repeat !important; }

/* ---------- segmented controls: a white tray, the selected item a black capsule ---------- */
.ce-seg, .ce-ed-tabs, .ce-ed-seg { position: relative; display: inline-flex; align-items: center; gap: 2px; padding: 3px; border-radius: var(--r-pill); background: var(--c-surface); box-shadow: var(--sh-ctl); max-width: 100%; overflow-x: auto; scrollbar-width: none; box-sizing: border-box; }
.ce-seg::-webkit-scrollbar, .ce-ed-tabs::-webkit-scrollbar { display: none; }
.ce-app .ce-seg button, .ce-ed .ce-ed-tab, .ce-ed .ce-ed-seg button { position: relative; z-index: 1; display: inline-flex; align-items: center; height: 28px; padding: 0 13px; border: 0; border-radius: var(--r-pill); background: none; color: var(--c-label-2); font: inherit; font-size: 13px; font-weight: 500; cursor: pointer; white-space: nowrap; transition: background-color .18s, color .18s, transform .12s; }
.ce-app .ce-seg button:hover, .ce-ed .ce-ed-tab:hover, .ce-ed .ce-ed-seg button:hover { color: var(--c-label); }
.ce-app .ce-seg button:active, .ce-ed .ce-ed-tab:active, .ce-ed .ce-ed-seg button:active { transform: scale(.95); }
.ce-app .ce-seg button.ce-on, .ce-ed .ce-ed-tab.ce-on, .ce-ed .ce-ed-seg button.ce-on { background: var(--c-ink); color: var(--c-ink-text); }
.ce-seg .ce-count { margin-left: 6px; font-weight: 500; opacity: .55; font-variant-numeric: tabular-nums; }
.ce-seg-lg button { height: 32px !important; padding: 0 16px !important; font-size: 13.5px !important; }
/* sliding highlight (cloud-exit.js adds the thumb) */
.ce-seg-thumb { position: absolute; top: 3px; bottom: 3px; left: 0; width: 0; border-radius: var(--r-pill); background: var(--c-ink); transition: left .32s cubic-bezier(.3,.7,.2,1), width .32s cubic-bezier(.3,.7,.2,1); pointer-events: none; }
.ce-app .ce-seg.ce-has-thumb button.ce-on { background: transparent; }

/* ---------- page frame ---------- */
.ce-app { container: ceapp / inline-size; max-width: 1680px; margin: 0 auto; padding: 4px 0 32px; }
.ce-hero { display: flex; align-items: center; justify-content: space-between; gap: 12px 18px; flex-wrap: wrap; margin: 0 0 20px; padding: 0; position: relative; z-index: 1; }
.ce-hero-text { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.ce-hero-sub { font-size: 13px; color: var(--c-label-3); }
.ce-hero-side { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ce-toolbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0 0 12px; }
.ce-toolbar .ce-spec { margin-left: auto; }
.ce-banner { display: flex; align-items: center; gap: 10px; padding: 11px 16px; border-radius: var(--r-tile); font-size: 13px; margin-bottom: 12px; background: var(--c-surface); box-shadow: var(--sh-card); color: var(--c-label-2); }
.ce-banner.ce-fail { color: var(--c-red-text); }
.ce-banner.ce-wait { color: var(--c-orange-text); }
.ce-banner.ce-fail::before, .ce-banner.ce-wait::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; flex: none; }

/* ---------- surfaces ---------- */
.ce-panel, .ce-dpanel { background: var(--c-surface); border-radius: var(--r-card); box-shadow: var(--sh-card); overflow: hidden; }
.ce-panel + .ce-panel { margin-top: 12px; }
.ce-dpanel { padding: 18px 20px; }
.ce-dpanel-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 12px; }
.ce-pad { padding: 18px 20px; }
.ce-empty { padding: 44px 20px; text-align: center; color: var(--c-label-3); font-size: 13px; }
.ce-empty .ce-h3 { color: var(--c-label); margin-bottom: 4px; }
.ce-dempty { padding: 28px 16px; text-align: center; color: var(--c-label-3); font-size: 13px; }

/* summary strip: one small white card per number */
.ce-panel.ce-strip { display: grid; gap: 12px; margin-bottom: 16px; background: none; box-shadow: none; border-radius: 0; overflow: visible; }
.ce-stat, .ce-tile { position: relative; display: block; min-width: 0; padding: 16px 18px; border-radius: var(--r-card); background: var(--c-surface); box-shadow: var(--sh-card); color: inherit; }
.ce-stat-k, .ce-tile-k { display: block; font-size: 13px; color: var(--c-label-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-stat-v, .ce-tile-v { display: block; margin-top: 6px; font-size: 24px; font-weight: 500; letter-spacing: -.02em; line-height: 1.2; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-stat-n, .ce-tile-n { display: block; margin-top: 3px; font-size: 12px; color: var(--c-label-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
a.ce-stat.ce-stat-link { transition: box-shadow .2s; }
a.ce-stat.ce-stat-link:hover { box-shadow: var(--sh-lift); }
div.ce-stat.ce-stat-link { cursor: pointer; transition: box-shadow .2s; }
div.ce-stat.ce-stat-link:hover, div.ce-stat.ce-stat-link:focus-visible { box-shadow: var(--sh-lift); outline: none; }
.ce-stat.ce-ok .ce-stat-v { color: var(--c-green-text); } .ce-stat.ce-wait .ce-stat-v { color: var(--c-orange-text); } .ce-stat.ce-fail .ce-stat-v { color: var(--c-red-text); }
/* monthly traffic (traffic.js) */
.ce-month > .ce-tile-k, .ce-month > .ce-stat-k { display: block; }
.ce-month-columns { display: grid; gap: 6px; width: 100%; margin-top: 6px; }
.ce-month-account { min-width: 0; }
.ce-month-value { display: block; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ce-month-value.ce-month-unknown { color: var(--c-label-3); }
.ce-month-free + .ce-month-name::before, .ce-month-excess + .ce-month-name::before { content: ""; display: inline-block; width: 6px; height: 6px; margin-right: 5px; border-radius: 50%; vertical-align: 1px; background: var(--c-green); }
.ce-month-excess + .ce-month-name::before { background: var(--c-orange); }
.ce-month-columns:not(.ce-month-count-1) .ce-month-account + .ce-month-account { padding-left: 12px; box-shadow: inset 1px 0 0 var(--c-line); }
.ce-month-count-2 .ce-month-value { font-size: 20px; }
.ce-month-count-3 .ce-month-value { font-size: 17px; }
.ce-month-name { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ce-month-more { cursor: pointer; transition: box-shadow .2s; }
.ce-month-more:hover { box-shadow: var(--sh-lift); }
.ce-month-value[data-stale="true"] { text-decoration: underline dotted var(--c-label-3); text-underline-offset: 4px; }
.ce-month-list { margin-top: 14px; max-height: 55vh; overflow-y: auto; }
.ce-month-row { display: flex !important; gap: 12px; align-items: center; }
.ce-month-list-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; }

/* ---------- grouped list rows ---------- */
.ce-list { display: flex; flex-direction: column; }
.ce-row { display: grid; align-items: center; gap: 14px; padding: 12px 20px; min-height: 56px; position: relative; transition: background-color .15s; }
.ce-row + .ce-row::before { content: ""; position: absolute; top: 0; left: 20px; right: 20px; height: 1px; background: var(--c-line); }
.ce-row:hover { background: var(--c-hover); }
.ce-row.ce-static:hover { background: transparent; }
.ce-cell { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ce-cell > strong, .ce-cell > .ce-strong { font-size: 14px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-cell > span, .ce-cell > small { font-size: 12.5px; color: var(--c-label-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-cell .ce-err { color: var(--c-red-text); white-space: normal; }
.ce-acts { display: flex; gap: 2px; align-items: center; justify-content: flex-end; flex-wrap: wrap; }
.ce-avatar { width: 34px; height: 34px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex: none; font-size: 13px; font-weight: 600; color: var(--c-label-2); background: var(--c-fill); }
.ce-avatar.ce-a1 { color: #0066cc; background: rgba(0,113,227,.1); } .ce-avatar.ce-a2 { color: #b25000; background: rgba(255,149,0,.13); }
.ce-avatar.ce-a3 { color: #5e3fd1; background: rgba(142,108,242,.13); } .ce-avatar.ce-a4 { color: #248a3d; background: rgba(52,199,89,.13); }
.ce-avatar.ce-a5 { color: #d70015; background: rgba(255,59,48,.1); } .ce-avatar.ce-a6 { color: #a2307a; background: rgba(255,45,85,.1); }
.ce-state { width: 34px; height: 34px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; flex: none; background: var(--c-fill); color: var(--c-label-3); }
.ce-state.ce-ok { background: var(--c-green-tint); color: var(--c-green-text); } .ce-state.ce-fail { background: var(--c-red-tint); color: var(--c-red-text); }
.ce-state.ce-wait { background: var(--c-orange-tint); color: var(--c-orange-text); } .ce-state.ce-info { background: var(--c-accent-tint); color: var(--c-accent-text); }
.ce-state-no { font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -.02em; }
.ce-progress { height: 4px; border-radius: var(--r-pill); background: var(--c-fill-2); overflow: hidden; }
.ce-progress i { display: block; height: 100%; border-radius: var(--r-pill); background: var(--c-accent); transition: width .4s ease; }
.ce-progress-live i { animation: ce-breathe 1.6s ease-in-out infinite; }
@keyframes ce-breathe { 50% { opacity: .55; } }
/* row layouts */
.ce-row-account { grid-template-columns: 34px minmax(160px, 1fr) auto auto; }
.ce-row-setting { grid-template-columns: minmax(0, 1fr) auto; min-height: 54px; }
.ce-row-setting .ce-input { width: 260px; text-align: right; background: transparent; padding-right: 0; color: var(--c-label-2); }
.ce-row-setting .ce-input:focus { text-align: left; padding: 0 12px; color: var(--c-label); background: var(--c-surface); }
.ce-row-add { grid-template-columns: 34px 1fr; color: var(--c-accent-text); cursor: pointer; font-weight: 500; }
.ce-row-quote { grid-template-columns: minmax(90px, 1fr) minmax(120px, 1.1fr) 150px auto; padding: 10px 12px 10px 18px; }
.ce-row-quote.ce-best .ce-quote-price strong { color: var(--c-green-text); }
.ce-row-form { grid-template-columns: 110px minmax(0, 1fr); padding: 10px 16px; min-height: 52px; }
.ce-row-form > label { font-size: 13px; color: var(--c-label-2); }
.ce-row-launch { grid-template-columns: minmax(0, 1fr) auto; gap: 16px; padding: 10px 14px 10px 22px; }
.ce-row-test { grid-template-columns: minmax(0, 1fr) auto auto; gap: 12px; padding: 10px 14px 10px 18px; }
.ce-row-direct { grid-template-columns: 34px minmax(0, 1fr) auto; }
.ce-row-direct .ce-cell > span { display: flex; align-items: center; gap: 4px; }
.ce-test-res .ce-tag { max-width: 260px; }
.ce-cfg-v { font-size: 13px; color: var(--c-label); min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-quote-price { display: flex; align-items: baseline; justify-content: flex-end; gap: 4px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ce-quote-price strong { font-size: 16px; font-weight: 600; }
.ce-quote-price small { color: var(--c-label-3); }
.ce-quote-bar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 12px; }
.ce-quote-bar .ce-caption { margin-left: auto; }

/* ---------- sheets (LuCI .modal tagged by sheet()) ---------- */
#modal_overlay:has(> .ce-modal-host) { background: rgba(0,0,0,.32); -webkit-backdrop-filter: none; backdrop-filter: none; }
.modal.ce-modal-host { display: block; width: calc(100% - 32px); max-width: 540px; margin: 8vh auto 40px; padding: 0; border-radius: var(--r-sheet) !important; background: var(--c-surface); color: var(--c-label); box-shadow: var(--sh-pop); overflow: hidden; animation: ce-sheet-in .24s cubic-bezier(.2,.8,.2,1); }
.modal.ce-modal-host.ce-wide { max-width: 720px; }
.modal.ce-modal-host > h4 { display: none; }
.modal.ce-modal-host > * { margin: 0; }
@keyframes ce-sheet-in { from { opacity: 0; transform: translateY(12px) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes ce-sheet-out { to { opacity: 0; transform: translateY(12px) scale(.985); } }
#modal_overlay { transition: opacity .18s ease; }
#modal_overlay.ce-closing { opacity: 0 !important; }
.modal.ce-modal-host.ce-closing { animation: ce-sheet-out .17s ease forwards; }
.ce-sheet-head { display: flex; align-items: flex-start; gap: 12px; padding: 24px 24px 6px; }
.ce-sheet-head .ce-grow { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.ce-sheet-title { font-size: 20px; font-weight: 600; letter-spacing: -.02em; line-height: 1.25; }
.ce-sheet-sub { font-size: 13px; color: var(--c-label-3); line-height: 1.55; }
.ce-app .ce-close, .ce-sheet .ce-close { width: 30px; height: 30px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; background: var(--c-fill); color: var(--c-label-2); cursor: pointer; flex: none; font-size: 18px; line-height: 1; }
.ce-sheet .ce-close:hover { background: var(--c-fill-2); color: var(--c-label); }
.ce-sheet-body { padding: 14px 24px 8px; max-height: 64vh; overflow-y: auto; }
.ce-sheet-foot { display: flex; align-items: center; gap: 10px; padding: 16px 24px 22px; }
.ce-sheet-foot .ce-grow { font-size: 13px; color: var(--c-label-2); }
.ce-sheet-foot .ce-total { font-size: 22px; font-weight: 600; color: var(--c-label); font-variant-numeric: tabular-nums; margin: 0 3px; }
.ce-sheet .ce-group { background: var(--c-fill); border-radius: var(--r-tile); overflow: hidden; }
.ce-sheet .ce-group .ce-row:hover { background: transparent; }
.ce-sheet .ce-group .ce-row + .ce-row::before { left: 16px; right: 16px; }
.ce-sheet .ce-group .ce-input { background: var(--c-surface); }
.ce-sheet .ce-group .ce-select { background-color: var(--c-surface); }
.ce-sheet .ce-group .ce-stepper { background: var(--c-surface); }
.ce-sheet .ce-group-label { font-size: 12.5px; font-weight: 500; color: var(--c-label-3); margin: 18px 4px 8px; }
.ce-sheet .ce-group-label:first-child { margin-top: 0; }
.ce-sheet .ce-note { font-size: 12px; line-height: 1.65; color: var(--c-label-3); margin: 10px 4px 0; }
.ce-config { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: var(--r-tile); background: var(--c-fill); margin-bottom: 14px; }
.ce-config .ce-grow { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.ce-config strong { font-size: 14px; font-weight: 600; }
.ce-config span { font-size: 12px; color: var(--c-label-2); }
.ce-config .ce-price { font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ce-config .ce-price small { font-size: 12px; font-weight: 500; color: var(--c-label-3); }
.ce-force-delete-note { display: flex; gap: 14px; padding: 18px; border-radius: var(--r-tile); background: var(--c-fill); line-height: 1.7; }
.ce-force-delete-note > .ce-icon { color: var(--c-red); margin-top: 4px; flex-shrink: 0; }
.ce-force-delete-note p { margin: 4px 0 0; color: var(--c-label-2); }

/* ---------- launch-progress cards (launch.js reuses the server card names) ---------- */
.ce-ncards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: 12px; }
.ce-ncard { display: flex; flex-direction: column; min-width: 0; background: var(--c-surface); border-radius: var(--r-card); box-shadow: var(--sh-card); overflow: hidden; }
.ce-ncard .ce-nc-top { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 16px 16px 12px; }
.ce-nc-id strong { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-nc-id span { font-size: 12px; color: var(--c-label-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-ncard > .ce-nc-err { margin: 0 12px 12px; padding: 7px 11px; border-radius: 10px; background: var(--c-red-tint); color: var(--c-red-text); font-size: 12px; }
.ce-dcards { display: grid; gap: 12px; }

/* ---------- page bars: a note on the left, actions on the right ---------- */
.ce-page { display: grid; grid-template-columns: minmax(0, 1fr); gap: 12px; min-width: 0; }
.ce-page > .ce-toolbar, .ce-page > .ce-banner { margin: 0; }
.ce-pagebar { gap: 8px; }
.ce-pagebar-note { display: inline-flex; align-items: center; gap: 7px; min-width: 0; font-size: 12.5px; color: var(--c-label-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-pagefoot { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 0 2px; }
.ce-pagefoot .ce-fold { margin: 0; }
.ce-search { position: relative; display: inline-flex; align-items: center; min-width: 0; }
.ce-search > .ce-icon { position: absolute; left: 13px; color: var(--c-label-3); pointer-events: none; }
.ce-app .ce-search .ce-search-input { width: 280px; height: 34px; padding: 0 14px 0 35px; border-radius: var(--r-pill); background: var(--c-surface); box-shadow: var(--sh-ctl); font-size: 13px; }
.ce-app .ce-search .ce-search-input:focus { box-shadow: 0 0 0 1px var(--c-accent), 0 0 0 4px var(--c-accent-tint); }
.ce-app .ce-search .ce-search-input::-webkit-search-cancel-button { cursor: pointer; }
/* related tools read as one capsule group */
.ce-device-link-tools { display: inline-flex; align-items: center; gap: 0; padding: 2px; border-radius: var(--r-pill); background: var(--c-surface); box-shadow: var(--sh-ctl); flex-wrap: nowrap; max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.ce-device-link-tools::-webkit-scrollbar { display: none; }
.ce-app .ce-device-link-tools .ce-btn { flex: none; height: 30px; padding: 0 12px; background: transparent; box-shadow: none; color: var(--c-label-2); }
.ce-app .ce-device-link-tools .ce-btn:hover { background: var(--c-fill); color: var(--c-label); }
.ce-app .ce-device-link-tools .ce-btn .ce-icon { color: var(--c-label-3); }
.ce-inline-switch { display: inline-flex; align-items: center; gap: 10px; font-size: 12.5px; color: var(--c-label-2); cursor: pointer; }
.ce-app .ce-inline-switch .ce-switch { width: 38px; height: 22px; }
.ce-app .ce-inline-switch .ce-switch::after { width: 18px; height: 18px; }
.ce-app .ce-inline-switch .ce-switch[aria-checked="true"]::after { transform: translateX(16px); }
/* "⋯" menus */
.ce-app .ce-btn.ce-more svg { stroke-width: 3.2; }
.ce-menu.ce-menu-actions { min-width: 160px; }
.ce-menu-actions .ce-menu-item { grid-template-columns: minmax(0, 1fr); padding: 0 14px; }
.ce-menu-actions .ce-menu-item:hover { background: var(--c-fill); }
.ce-menu-actions .ce-menu-item.ce-danger { color: var(--c-red-text); }
/* a thin meter under a summary number */
.ce-stat-meter { display: block; height: 4px; margin-top: 12px; border-radius: var(--r-pill); background: var(--c-fill-2); overflow: hidden; }
.ce-stat-meter i { display: block; height: 100%; border-radius: inherit; background: var(--c-ink); transition: width .4s ease; }
.ce-stat.ce-wait .ce-stat-meter i { background: var(--c-orange); }
.ce-panel.ce-strip { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.4fr); }
.ce-panel.ce-strip.ce-strip-quota { grid-template-columns: repeat(3, minmax(0, 1fr)) minmax(0, 1.4fr); }
.ce-panel.ce-strip.ce-strip-devices { grid-template-columns: repeat(4, minmax(0, 1fr)); }
/* bulk actions float at the bottom of the page while rows are ticked */
.ce-selbar { position: sticky; bottom: 20px; z-index: 40; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; width: min(100%, 680px); margin: 6px auto 0; padding: 9px 10px 9px 20px; border-radius: 22px; background: var(--c-surface); box-shadow: var(--sh-pop); animation: ce-rise .22s cubic-bezier(.3,.7,.2,1); }
.ce-selbar-n { display: inline-flex; align-items: baseline; gap: 2px; font-size: 13.5px; color: var(--c-label-2); }
.ce-selbar-n strong { font-size: 17px; font-weight: 600; color: var(--c-label); }
.ce-app .ce-selbar .ce-btn.ce-arm.ce-arm-label:not(.ce-armed) { color: var(--c-red-text); }

/* ---------- lists in one white panel: a header line, then rows split by hairlines ---------- */
.ce-list-head { display: flex; align-items: center; gap: 10px; min-height: 48px; padding: 6px 20px 6px 14px; box-shadow: inset 0 -1px 0 var(--c-line); }
.ce-list-head .ce-caption { font-variant-numeric: tabular-nums; }
/* server cards: white tiles like the device cards, 4–5 per row on a desktop, one on phones.
   Line 1: number, IPv4, actions. Line 2: device, place, time used. Line 3: traffic and cost.
   Line 4: the WeChat slots. */
.ce-app .ce-panel.ce-slist { display: grid; grid-template-columns: repeat(auto-fill, minmax(268px, 1fr)); gap: 10px; padding: 0; overflow: visible; background: none; box-shadow: none; border-radius: 0; }
.ce-slist > .ce-srow { position: relative; display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; grid-template-areas: "no ip acts" "no dev dev" "met met met" "wx wx wx" "err err err"; align-items: center; gap: 6px 10px; min-width: 0; padding: 12px; border-radius: 16px; background: var(--c-surface); box-shadow: var(--sh-card); overflow: visible; transition: box-shadow .18s; }
.ce-slist > .ce-srow:hover { box-shadow: var(--sh-lift); }
.ce-slist > .ce-srow:has(.ce-cookie-all-ok) { background: rgba(52,199,89,.08); }
.ce-slist > .ce-srow:has(.ce-cookie-all-ok)::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: var(--c-surface); }
.ce-srow.ce-gone { opacity: .55; }
.ce-srow > .ce-state { grid-area: no; align-self: start; width: 30px; height: 30px; border-radius: 9px; font-size: 13.5px; }
.ce-srow > .ce-state svg { width: 15px; height: 15px; }
.ce-srow > .ce-nc-id { grid-area: ip; display: flex; flex-direction: row; align-items: center; gap: 6px; min-width: 0; }
.ce-nc-headline .ce-nc-address { min-width: 0; font-family: var(--f-sans); font-size: 13.5px; font-weight: 600; letter-spacing: -.01em; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-nc-headline .ce-tag { flex: none; }
.ce-srow > .ce-nc-dev { grid-area: dev; display: flex; align-items: baseline; gap: 4px 10px; min-width: 0; margin-top: -4px; font-size: 12px; color: var(--c-label-2); white-space: nowrap; overflow: hidden; }
.ce-nc-dev > span { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-nc-dev .ce-nc-device-name { flex: 0 1 auto; font-weight: 500; color: var(--c-label); }
.ce-nc-dev.ce-free .ce-nc-device-name { font-weight: 400; color: var(--c-label-3); }
.ce-nc-dev .ce-nc-zone { flex: 0 1 auto; color: var(--c-label-3); }
.ce-nc-dev .ce-nc-time { flex: none; margin-left: auto; color: var(--c-label-3); font-variant-numeric: tabular-nums; }
/* traffic and cost: one quiet strip of four */
.ce-srow > .ce-nc-metrics { grid-area: met; display: flex; justify-content: space-between; gap: 8px; min-width: 0; padding: 6px 10px; border-radius: 10px; background: var(--c-fill); }
.ce-nc-m { display: flex; flex: 0 1 auto; align-items: baseline; gap: 3px; min-width: 0; }
.ce-nc-m small { flex: none; font-size: 11px; color: var(--c-label-3); line-height: 1.4; white-space: nowrap; }
.ce-nc-m strong { min-width: 0; font-size: 12px; font-weight: 600; color: var(--c-label-2); font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-nc-m.ce-idle strong { color: var(--c-label-4); font-weight: 500; }
.ce-srow > .ce-cookie-row { grid-area: wx; gap: 4px; margin: 0; padding: 0; min-width: 0; }
.ce-srow > .ce-cookie-row .ce-cookie-label, .ce-srow > .ce-cookie-row .ce-cookie-settings, .ce-srow > .ce-cookie-row > .ce-grow { display: none; }
.ce-app .ce-srow > .ce-cookie-row .ce-cookie-button { flex: 1 1 0; min-width: 0; height: 28px; padding: 0 6px; gap: 5px; }
.ce-srow > .ce-nc-acts { grid-area: acts; display: flex; align-items: center; justify-content: flex-end; gap: 0; margin: -4px -7px -4px 0; padding: 0; min-height: 0; box-shadow: none; }
.ce-app .ce-srow > .ce-nc-acts .ce-btn.ce-icon-btn { width: 30px; height: 30px; }
/* 代理 */
.ce-proxy-add { padding: 12px; display: flex; flex-direction: column; gap: 10px; margin-bottom: 14px; }
.ce-proxy-text { width: 100%; min-height: 88px; resize: vertical; font-family: var(--f-mono, ui-monospace, monospace); font-size: 13px; }
.ce-proxy-foot { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.ce-proxy-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 0 4px 8px; }
.ce-tag.ce-bad { background: var(--c-red-tint); color: var(--c-red-text); }
/* 推送下载 */
.ce-push-top { padding: 0; margin-bottom: 14px; overflow: hidden; }
.ce-push-address { display: flex; align-items: center; gap: 10px; padding: 14px 16px; }
.ce-push-address.ce-warn { color: var(--c-orange-text); font-size: 13px; }
.ce-push-where { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ce-push-where small { font-size: 12px; color: var(--c-label-3); }
.ce-app a.ce-push-url { font-size: 20px; font-weight: 600; letter-spacing: -.01em; color: var(--c-label); text-decoration: none; overflow-wrap: anywhere; }
.ce-push-up { position: relative; display: flex; align-items: center; flex-wrap: wrap; gap: 10px; padding: 12px 16px; border-top: 1px solid var(--c-line); }
.ce-push-up a { color: var(--c-accent-text); }
.ce-push-bar { position: absolute; left: 0; right: 0; top: -1px; height: 2px; background: var(--c-fill); }
.ce-push-bar > i { display: block; height: 100%; background: var(--c-accent); transition: width .15s; }
.ce-push-list { padding: 0; overflow: hidden; }
.ce-push-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px 10px 14px; }
.ce-push-row + .ce-push-row { border-top: 1px solid var(--c-line); }
.ce-push-no { flex: none; width: 18px; text-align: center; font-size: 12px; font-weight: 600; color: var(--c-label-3); font-variant-numeric: tabular-nums; }
.ce-push-icon { flex: none; width: 40px; height: 40px; border-radius: 9px; object-fit: contain; }
.ce-push-glyph { display: grid; place-items: center; background: var(--c-fill); color: var(--c-label-3); }
.ce-push-id { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ce-push-id strong { font-size: 14px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ce-push-id small { font-size: 12px; color: var(--c-label-3); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ce-app .ce-push-term { flex: none; min-width: 92px; }
@media (max-width: 560px) { .ce-push-row { flex-wrap: wrap; } .ce-push-id { flex-basis: calc(100% - 90px); } .ce-push-row .ce-push-term { margin-left: 70px; } }
/* 云服务器 → 口令池 */
.ce-pw-text { width: 100%; min-height: 64px; resize: vertical; }
.ce-pw-amount { max-width: 140px; }
.ce-pw-add { display: flex; justify-content: flex-end; margin: 8px 0 14px; }
.ce-pw-list { display: flex; flex-direction: column; border-radius: 12px; background: var(--c-surface); box-shadow: var(--sh-card); overflow: hidden; margin-bottom: 12px; }
.ce-pw-row { display: grid; grid-template-columns: 24px minmax(0, 1fr) auto auto; align-items: center; gap: 10px; min-height: 44px; padding: 7px 8px 7px 12px; font-size: 13px; }
.ce-pw-row + .ce-pw-row { border-top: 1px solid var(--c-line); }
.ce-pw-row.ce-pw-used { padding-right: 12px; color: var(--c-label-2); }
.ce-pw-no { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; border-radius: 7px; background: var(--c-fill); font-size: 12px; font-weight: 600; }
.ce-pw-main { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.ce-pw-preview { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ce-pw-meta { display: flex; flex-wrap: wrap; gap: 4px; }
.ce-pw-chip { padding: 1px 7px; border-radius: 6px; background: var(--c-fill); color: var(--c-label-2); font-size: 11.5px; line-height: 18px; white-space: nowrap; }
.ce-pw-chip.ce-pw-manual { background: var(--c-accent-tint); color: var(--c-accent-text); }
.ce-pw-chip.ce-pw-ok { background: var(--c-green-tint); color: var(--c-green-text); }
.ce-pw-chip.ce-pw-bad { background: var(--c-red-tint); color: var(--c-red-text); }
.ce-pw-chip.ce-pw-busy { background: var(--c-orange-tint); color: var(--c-orange-text); }
.ce-pw-row small { color: var(--c-label-3, var(--c-label-2)); font-size: 11.5px; }
.ce-pw-settings { margin-bottom: 4px; }
.ce-pw-empty { padding: 14px; border-radius: 12px; background: var(--c-fill); color: var(--c-label-2); font-size: 13px; text-align: center; margin-bottom: 12px; }
/* 云服务器: Ctrl / Shift selection and the phone's play / pause. */
.ce-slist > .ce-srow.ce-picked { box-shadow: 0 0 0 2px var(--c-accent), var(--sh-card); }
.ce-slist > .ce-srow.ce-picked:hover { box-shadow: 0 0 0 2px var(--c-accent), var(--sh-lift); }
.ce-app .ce-srow .ce-run { color: var(--c-label-2); }
.ce-app .ce-srow .ce-run.ce-run-idle, .ce-app .ce-srow .ce-run.ce-run-paused { color: var(--c-accent); }
.ce-app .ce-srow .ce-run.ce-run-running { color: var(--c-label); }
.ce-app .ce-srow .ce-run.ce-run-queued .ce-icon { animation: ce-run-wait 1.2s ease-in-out infinite alternate; }
.ce-app .ce-srow .ce-run[disabled] { opacity: .35; }
@keyframes ce-run-wait { to { opacity: .35; } }
.ce-pick-note { display: inline-flex; align-items: center; gap: 4px; color: var(--c-accent-text); }
.ce-pick-note .ce-btn { height: 26px; padding: 0 8px; }
.ce-srow > .ce-nc-err { grid-area: err; margin: 0; padding: 6px 10px; border-radius: 10px; background: var(--c-red-tint); color: var(--c-red-text); font-size: 12px; line-height: 1.45; }
.ce-app .ce-nc-acts .ce-btn.ce-icon-btn { flex: none; background: transparent; box-shadow: none; }
.ce-app .ce-nc-acts .ce-btn.ce-icon-btn:hover { background: var(--c-fill); }
.ce-app .ce-nc-acts .ce-btn.ce-danger:not(.ce-armed), .ce-app .ce-dc-acts .ce-btn.ce-danger:not(.ce-armed) { color: var(--c-red); }
.ce-app .ce-nc-acts .ce-btn.ce-danger:not(.ce-armed):hover, .ce-app .ce-dc-acts .ce-btn.ce-danger:not(.ce-armed):hover { color: var(--c-red-text); background: var(--c-red-tint); }

/* device cards: white tiles, 4–5 per row on a desktop, one on phones. Line 1: number
   (green while online; press to select), IP, 代理 / 直连 / 禁用. Line 2: route and today's
   traffic. Line 3: the WeChat slots, more and delete. */
.ce-app .ce-panel.ce-dlist { display: grid; grid-template-columns: repeat(auto-fill, minmax(268px, 1fr)); gap: 10px; padding: 0; overflow: visible; background: none; box-shadow: none; border-radius: 0; }
.ce-dlist > .ce-list-head { grid-column: 1 / -1; flex-wrap: wrap; min-height: 40px; padding: 0 2px 2px 4px; box-shadow: none; }
.ce-dlist > .ce-dpanel-empty { grid-column: 1 / -1; }
.ce-dlist > .ce-drow { position: relative; display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; grid-template-areas: "no ip mode" "no meta acts" "no wx wx"; align-items: center; gap: 6px 10px; min-width: 0; padding: 12px; border-radius: 16px; background: var(--c-surface); box-shadow: var(--sh-card); transition: box-shadow .18s; }
.ce-dlist > .ce-drow:hover { background: var(--c-surface); box-shadow: var(--sh-lift); }
.ce-dlist > .ce-drow.ce-sel, .ce-dlist > .ce-drow.ce-sel:hover { box-shadow: 0 0 0 2px var(--c-ink), var(--sh-card); }
/* all three WeChat slots working: a faint green card (the colour sits on a white underlay) */
.ce-dlist > .ce-drow:not(.ce-dgap)::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit; background: var(--c-surface); }
.ce-dlist > .ce-drow:has(.ce-cookie-all-ok), .ce-dlist > .ce-drow:has(.ce-cookie-all-ok):hover { background: rgba(52,199,89,.08); }
.ce-drow.ce-gone { opacity: .55; }
/* one left edge for the IP, the route line and the WeChat slots; the number keeps its own column */
.ce-drow > .ce-dc-top { display: contents; }
.ce-drow > .ce-dc-top > .ce-dno { grid-area: no; align-self: start; }
.ce-drow > .ce-dc-top > .ce-dc-id { grid-area: ip; }
.ce-drow > .ce-dc-top > .ce-mode { grid-area: mode; justify-self: end; }
.ce-app .ce-dno, .ce-sheet .ce-dno { width: 30px; height: 30px; padding: 0; border: 0; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; flex: none; font: inherit; font-size: 13.5px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -.02em; color: var(--c-label); background: var(--c-fill); }
.ce-app button.ce-dno { cursor: pointer; transition: box-shadow .15s, background-color .15s; }
.ce-app button.ce-dno:hover { box-shadow: inset 0 0 0 1.5px var(--c-label-4); }
.ce-app .ce-dno.ce-online, .ce-sheet .ce-dno.ce-online { background: var(--c-green-tint); color: var(--c-green-text); }
.ce-app .ce-dno.ce-picked, .ce-app .ce-dno.ce-picked:hover { background: var(--c-ink); color: var(--c-ink-text); box-shadow: none; }
.ce-dc-id { flex: 1 1 auto; min-width: 0; }
.ce-dc-ip { display: block; font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* the three modes: a small capsule tray; the chosen one is filled (proxy black, direct orange, off red) */
.ce-mode { display: inline-flex; flex: none; gap: 1px; padding: 2px; border-radius: var(--r-pill); background: var(--c-fill); }
.ce-app .ce-mode > button { height: 24px; padding: 0 7px; border: 0; border-radius: var(--r-pill); background: none; color: var(--c-label-2); font: inherit; font-size: 12px; font-weight: 500; white-space: nowrap; cursor: pointer; transition: background-color .15s, color .15s; }
.ce-app .ce-mode > button:hover { color: var(--c-label); }
.ce-app .ce-mode > button.ce-on { color: #fff; cursor: default; }
.ce-app .ce-mode > button.ce-mode-proxy.ce-on { background: var(--c-ink); color: var(--c-ink-text); }
.ce-app .ce-mode > button.ce-mode-direct.ce-on { background: var(--c-orange); }
.ce-app .ce-mode > button.ce-mode-off.ce-on { background: var(--c-red); }
.ce-app .ce-mode > button[aria-busy="true"] { opacity: .6; }
/* folded: only the current mode shows; pressing it slides the other two out to its left */
.ce-mode.ce-mode-fold { padding: 0; background: none; transition: background-color .18s, padding .18s; }
.ce-mode.ce-mode-fold.ce-open { padding: 2px; background: var(--c-fill); }
.ce-app .ce-mode.ce-mode-fold > button.ce-on { cursor: pointer; }
.ce-app .ce-mode.ce-mode-fold > button.ce-mode-alt { animation: ce-mode-in .2s cubic-bezier(.3,.7,.2,1) both; }
.ce-app .ce-mode.ce-mode-fold > button.ce-mode-alt + button.ce-mode-alt { animation-delay: .03s; }
@keyframes ce-mode-in { from { opacity: 0; transform: translateX(14px); max-width: 0; padding: 0; } to { opacity: 1; transform: none; max-width: 60px; } }
/* 待绑定: new devices until the phone app sets their number */
.ce-plist-search { width: 100%; margin-bottom: 12px; }
.ce-sheet .ce-panel.ce-dlist.ce-plist { display: grid; gap: 10px; background: none; box-shadow: none; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); max-height: 60vh; overflow: auto; padding: 2px; }
.ce-dlist > .ce-drow.ce-pcard { grid-template-areas: "no ip acts" "no meta meta"; }
.ce-app .ce-dno.ce-pno, .ce-sheet .ce-dno.ce-pno { font-size: 12px; font-weight: 500; color: var(--c-label-3); background: none; box-shadow: inset 0 0 0 1.5px var(--c-line); }
.ce-app .ce-dno.ce-pno.ce-online, .ce-sheet .ce-dno.ce-pno.ce-online { color: var(--c-green-text); box-shadow: inset 0 0 0 1.5px var(--c-green); background: none; }
.ce-drow > .ce-dc-meta { grid-area: meta; display: flex; align-items: baseline; gap: 4px 12px; min-width: 0; margin-top: -4px; padding: 0; font-size: 12px; color: var(--c-label-3); white-space: nowrap; overflow: hidden; }
.ce-dc-route { color: var(--c-label-2); font-variant-numeric: tabular-nums; overflow: hidden; text-overflow: ellipsis; }
.ce-dc-route.ce-warn { color: var(--c-orange-text); } .ce-dc-route.ce-off { color: var(--c-red-text); } .ce-dc-route.ce-direct { color: var(--c-orange-text); }
.ce-dc-today { display: inline-flex; align-items: baseline; gap: 4px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.ce-dc-today small { font-size: 11.5px; color: var(--c-label-3); }
.ce-dc-today strong { font-size: 12px; font-weight: 600; color: var(--c-label-2); }
.ce-dc-today.ce-idle strong { color: var(--c-label-3); font-weight: 500; }
.ce-dc-alias { overflow: hidden; text-overflow: ellipsis; }
.ce-drow > .ce-cookie-row { grid-area: wx; gap: 4px; margin: 2px 0 0; padding: 0; min-width: 0; }
.ce-drow > .ce-cookie-row .ce-cookie-label, .ce-drow > .ce-cookie-row .ce-cookie-settings, .ce-drow > .ce-cookie-row > .ce-grow { display: none; }
/* in a card the three slots share the line equally (one size whatever they show);
   pressing a slot opens the same dialog as 设置 */
.ce-app .ce-drow > .ce-cookie-row .ce-cookie-button { flex: 1 1 0; min-width: 0; height: 28px; padding: 0 6px; gap: 5px; }
.ce-drow > .ce-cookie-row .ce-wechat-svg { width: 18px; height: 18px; }
/* icon buttons are wider than their glyphs: pull them out so the trash lines up with the mode tray */
.ce-drow > .ce-dc-acts { grid-area: acts; display: flex; align-items: center; justify-content: flex-end; gap: 0; margin: -4px -7px -4px 0; padding: 0; box-shadow: none; }
.ce-app .ce-dc-acts .ce-btn.ce-icon-btn, .ce-sheet .ce-dc-acts .ce-btn.ce-icon-btn { width: 30px; height: 30px; }
/* an unused number keeps its slot: only a faint outlined number where the badge would be */
.ce-dlist > .ce-drow.ce-dgap { display: flex; align-items: flex-start; background: none; box-shadow: inset 0 0 0 1.5px var(--c-line); pointer-events: none; }
.ce-drow.ce-dgap .ce-dno { background: none; color: var(--c-label-4); font-weight: 500; }
/* the list head's switch for many devices */
.ce-bulk { display: inline-flex; align-items: center; gap: 8px; }
.ce-bulk-k { font-size: 12.5px; color: var(--c-label-3); white-space: nowrap; }
.ce-mode.ce-mode-bulk { background: var(--c-surface); box-shadow: var(--sh-ctl); }
.ce-app .ce-mode.ce-mode-bulk > button { height: 26px; padding: 0 11px; font-size: 12.5px; }
.ce-app .ce-mode.ce-mode-bulk > button.ce-armed { color: #fff; }
.ce-app .ce-mode.ce-mode-bulk > button.ce-mode-proxy.ce-armed { background: var(--c-ink); color: var(--c-ink-text); }
.ce-app .ce-mode.ce-mode-bulk > button.ce-mode-direct.ce-armed { background: var(--c-orange); }
.ce-app .ce-mode.ce-mode-bulk > button.ce-mode-off.ce-armed { background: var(--c-red); }
  grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "top acts" "exit wx"; }
.ce-direct-list { margin-bottom: 4px; }

/* narrower: two lines per row; phones: a stacked card per row */
@container ceapp (max-width: 760px) {
  .ce-pagebar .ce-pagebar-note { display: none; }
  .ce-search, .ce-app .ce-search .ce-search-input { width: 100%; }
  .ce-device-link-tools { width: 100%; }
  .ce-panel.ce-strip, .ce-panel.ce-strip.ce-strip-quota, .ce-panel.ce-strip.ce-strip-devices { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .ce-strip > .ce-month { grid-column: 1 / -1; }
  .ce-list-head { padding: 6px 16px 6px 10px; flex-wrap: wrap; }
  .ce-selbar { bottom: 12px; padding: 9px 10px 9px 16px; }
}

/* ---------- WeChat Cookie slots: solid capsules, state at a glance ---------- */
.ce-cookie-row { display: flex; align-items: center; gap: 6px; padding: 0 16px; margin-top: 10px; }
.ce-cookie-label { flex: none; min-width: 36px; margin-right: 6px; font-size: 12.5px; color: var(--c-label-2); }
.ce-wechat-svg { display: block; width: 20px; height: 20px; flex: none; }
.ce-app .ce-cookie-button { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 5px; min-width: 50px; height: 32px; padding: 0 10px; border: 0; border-radius: var(--r-pill); background: var(--c-fill); color: var(--c-label-3); cursor: pointer; font: inherit; transition: transform .12s, opacity .15s; }
.ce-app .ce-cookie-button:hover { opacity: .88; }
.ce-app .ce-cookie-button:active { transform: scale(.95); }
.ce-cookie-count { font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: -.01em; white-space: nowrap; }
.ce-app .ce-cookie-row .ce-cookie-ok { background: var(--c-green); color: #fff; }
.ce-app .ce-cookie-row .ce-cookie-fail { background: var(--c-red); color: #fff; }
.ce-app .ce-cookie-row .ce-cookie-done { background: var(--c-accent); color: #fff; }
.ce-cookie-row .ce-cookie-ok .ce-wechat-svg circle { fill: var(--c-green); }
.ce-cookie-row .ce-cookie-fail .ce-wechat-svg circle { fill: var(--c-red); }
.ce-cookie-row .ce-cookie-done .ce-wechat-svg circle { fill: var(--c-accent); }
.ce-cookie-empty { color: var(--c-label-3); } .ce-cookie-ok { color: var(--c-green-text); } .ce-cookie-fail { color: var(--c-red-text); } .ce-cookie-done { color: var(--c-accent-text); }
.ce-cookie-pending::after { content: ""; position: absolute; top: -2px; right: -2px; width: 9px; height: 9px; border-radius: 50%; background: var(--c-accent); box-shadow: 0 0 0 2px var(--c-surface); animation: ce-cookie-pulse 1.2s ease-in-out infinite alternate; }
@keyframes ce-cookie-pulse { to { opacity: .35; } }
.ce-app .ce-cookie-row .ce-cookie-settings { height: 30px; padding: 0 8px; font-size: 12.5px; }
/* cookie dialog */
.ce-cookie-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 16px; }
.ce-sheet .ce-cookie-tab { display: flex; justify-content: center; align-items: center; gap: 7px; min-height: 44px; padding: 8px; border: 0; border-radius: var(--r-tile); background: var(--c-fill); font: inherit; font-size: 13px; cursor: pointer; transition: box-shadow .15s; }
.ce-sheet .ce-cookie-tab.ce-cookie-ok { background: var(--c-green-tint); }
.ce-sheet .ce-cookie-tab.ce-cookie-fail { background: var(--c-red-tint); }
.ce-sheet .ce-cookie-tab.ce-cookie-done { background: var(--c-accent-tint); }
.ce-cookie-tab.ce-selected { box-shadow: 0 0 0 2px var(--c-ink); }
.ce-cookie-identity { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px 12px; }
.ce-cookie-identity .ce-cookie-state { font-size: 12px; font-weight: 500; }
.ce-cookie-identity .ce-cookie-username { margin: 0; }
.ce-cookie-info { font-size: 14px; line-height: 1.8; font-weight: 500; white-space: pre-line; margin-bottom: 14px; }
.ce-cookie-username { color: var(--c-label); font-size: 19px; line-height: 1.5; font-weight: 600; overflow-wrap: anywhere; }
.ce-cookie-recent { color: var(--c-label-3); font-size: 12px; font-weight: 400; }
.ce-cookie-help { color: var(--c-label-3); font-size: 12px; line-height: 1.7; }
.ce-cookie-field { display: flex; flex-direction: column; gap: 7px; margin: 14px 0; color: inherit; font-size: 13px; }
.ce-cookie-field .ce-input { width: 100%; min-width: 0; }
.ce-cookie-entry-links { width: 100%; resize: vertical; min-height: 140px; font-size: 13px; line-height: 1.8; }
.ce-sheet .ce-cookie-value { min-height: 38px; height: 38px; padding: 8px 12px; resize: none; font-family: var(--f-mono); font-size: 12px; overflow-wrap: anywhere; }
.ce-cookie-outcome { min-height: 20px; margin-top: 12px; font-size: 13px; line-height: 1.7; overflow-wrap: anywhere; color: var(--c-label-2); }
.ce-cookie-outcome.ce-ok { color: var(--c-green-text); } .ce-cookie-outcome.ce-fail { color: var(--c-red-text); }
.ce-cookie-confirm { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 8px; padding: 12px; margin-top: 12px; border-radius: var(--r-tile); background: var(--c-fill); font-size: 13px; }
.ce-cookie-confirm > span { flex: 1; }
.ce-blacklist-section { margin-top: 16px; border-top: 1px solid var(--c-line); padding-top: 8px; }
.ce-blacklist-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 13px; }
.ce-blacklist-rows { max-height: 220px; overflow-y: auto; border-radius: 12px; background: var(--c-fill); }
.ce-blacklist-row { display: grid; gap: 4px; padding: 9px 12px; font-size: 13px; overflow-wrap: anywhere; }
.ce-blacklist-row + .ce-blacklist-row { border-top: 1px solid var(--c-line); }
.ce-blacklist-row small, .ce-blacklist-empty { color: var(--c-label-2); font-size: 12px; }
.ce-blacklist-empty { padding: 12px; text-align: center; }
.ce-blacklist-section .ce-cookie-confirm[hidden] { display: none; }
.ce-cookie-replace { box-sizing: border-box; width: min(340px, calc(100vw - 32px)); margin: auto; padding: 20px; border: 0; border-radius: var(--r-tile); background: var(--c-surface); color: var(--c-label); box-shadow: 0 16px 48px rgba(0, 0, 0, .18); font-size: 13px; line-height: 1.7; }
.ce-cookie-replace::backdrop { background: rgba(0, 0, 0, .25); }
.ce-cookie-replace strong { font-size: 15px; }
.ce-cookie-replace p { margin: 6px 0 16px; color: var(--c-label-2); }
.ce-cookie-replace-foot { display: flex; justify-content: flex-end; gap: 8px; }
.ce-cookie-boot-warning { flex: 1 0 100%; line-height: 1.7; color: var(--c-label-2); }
.ce-cookie-boot-warning strong { color: var(--c-label); }
.ce-cookie-boot-warning p { margin: 4px 0 0; }
.ce-sheet .ce-cookie-foot { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.ce-cookie-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.ce-cookie-counter { display: flex; align-items: center; gap: 8px; color: var(--c-label-2); font-size: 12.5px; white-space: nowrap; }
.ce-cookie-count-value { display: inline-flex; align-items: center; gap: 4px; font-variant-numeric: tabular-nums; }
.ce-sheet .ce-cookie-count-input { width: 52px; height: 34px; padding: 5px; text-align: center; }
.ce-cookie-count-input::-webkit-inner-spin-button { -webkit-appearance: none; appearance: none; }
.ce-sheet .ce-cookie-trash { width: 34px; min-width: 34px; padding: 0; flex: none; color: var(--c-label-3); }
.ce-cookie-trash svg { width: 18px; height: 18px; display: block; }
/* 绑定设备: the sheet is only as wide as the code, so nothing sits empty on the right */
.modal.ce-modal-host:has(> .ce-pair-sheet) { max-width: 360px; }
.ce-pair-sheet .ce-sheet-body { text-align: center; padding-top: 18px; padding-bottom: 6px; }
.ce-pair-code { margin: 0 0 12px; padding: 14px 0 14px .3em; border-radius: 18px; background: var(--c-fill); font-size: clamp(40px, 11vw, 52px); font-weight: 600; letter-spacing: .3em; font-variant-numeric: tabular-nums; color: var(--c-label); line-height: 1.3; }
.ce-pair-sheet .ce-cookie-outcome { font-size: 13px; font-variant-numeric: tabular-nums; color: var(--c-label-3); }
.ce-pair-sheet .ce-cookie-outcome.ce-ok { color: var(--c-green-text); font-weight: 600; }
.ce-pair-sheet .ce-cookie-outcome.ce-fail { color: var(--c-red-text); }
.ce-pair-sheet .ce-sheet-foot { justify-content: center; padding-top: 10px; }
.ce-pair-sheet .ce-sheet-foot .ce-btn { min-width: 140px; }
.ce-keepalive-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 10px; max-height: 48vh; overflow: auto; margin-top: 14px; }
.ce-keepalive-card { display: grid; gap: 10px; padding: 14px; border-radius: var(--r-tile); background: var(--c-fill); }
.ce-keepalive-card > strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ce-keepalive-card > small { color: var(--c-label-2); font-variant-numeric: tabular-nums; }
.ce-keepalive-slots { display: flex; gap: 8px; flex-wrap: wrap; }
.ce-keepalive-chip { display: inline-flex; align-items: center; gap: 5px; padding: 5px 9px; border-radius: var(--r-pill); font-size: 12px; color: var(--c-label-2); background: var(--c-surface); }
.ce-keepalive-chip .ce-wechat-svg { width: 18px; height: 18px; }
.ce-keepalive-chip.ce-cookie-ok { color: #fff; background: var(--c-green); }
.ce-keepalive-chip.ce-cookie-ok .ce-wechat-svg circle { fill: var(--c-green); }
.ce-keepalive-chip.ce-cookie-fail { color: #fff; background: var(--c-red); }
.ce-keepalive-chip.ce-cookie-fail .ce-wechat-svg circle { fill: var(--c-red); }
.ce-keepalive-schedule { box-shadow: inset 0 1px 0 var(--c-line); margin-top: 18px; padding-top: 16px; }
.ce-schedule-toggle { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.ce-schedule-fields { display: flex; align-items: flex-end; flex-wrap: wrap; gap: 12px; }
.ce-schedule-fields .ce-cookie-field { flex: 1; min-width: 120px; margin: 12px 0 0; }
.ce-schedule-fields .ce-btn { margin-top: 12px; }

/* ---------- launch progress (launch.js) ---------- */
.ce-build-counts, .ce-build-filters, .ce-build-pagination, .ce-build-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.ce-build-filters { margin: 10px 0; }
.ce-build-grid { grid-template-columns: repeat(auto-fill, minmax(min(210px, 100%), 1fr)); gap: 10px; max-height: 28vh; overflow-y: auto; padding: 2px; }
.ce-build-grid .ce-build-card { cursor: pointer; min-width: 0; background: var(--c-fill); box-shadow: none; }
.ce-build-card .ce-nc-top { padding: 12px 12px 8px; }
.ce-build-card .ce-nc-id > strong { font-size: 13px; }
.ce-build-card.ce-build-selected { box-shadow: 0 0 0 2px var(--c-ink); }
.ce-build-card-body { padding: 0 12px 12px; display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.ce-build-ip { font-size: 14px; font-weight: 600; }
.ce-build-stage { font-size: 12px; color: var(--c-label-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ce-build-clock { font-variant-numeric: tabular-nums; white-space: nowrap; }
.ce-build-progress-label { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.ce-build-percent { color: var(--c-label); font-size: 14px; font-variant-numeric: tabular-nums; }
.ce-build-progress { height: 6px; margin: 4px 0; border-radius: var(--r-pill); background: var(--c-fill-2); overflow: hidden; }
.ce-build-progress-fill { display: block; width: 100%; height: 100%; border-radius: inherit; background: var(--c-accent); transform: scaleX(0); transform-origin: left; transition: transform .4s ease; }
.ce-build-success .ce-build-progress-fill { background: var(--c-green); }
.ce-build-error .ce-build-progress-fill { background: var(--c-orange); }
.ce-build-detail { margin-top: 14px; padding-top: 14px; box-shadow: inset 0 1px 0 var(--c-line); }
.ce-build-detail:empty { display: none; }
.ce-build-detail-title { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; margin-bottom: 10px; font-size: 13px; }
.ce-build-good { color: var(--c-green-text); } .ce-build-bad { color: var(--c-red-text); }
.ce-build-actions, .ce-build-pagination { margin-top: 10px; justify-content: flex-end; }
.ce-build-check { display: block; width: 28px; height: 28px; padding: 4px; border-radius: 50%; color: var(--c-green-text); background: var(--c-green-tint); animation: ce-build-pop .25s ease-out both; }
.ce-build-check path { fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 28; stroke-dashoffset: 28; animation: ce-build-tick .35s .1s ease-out forwards; }
@keyframes ce-build-tick { to { stroke-dashoffset: 0; } }
@keyframes ce-build-pop { from { opacity: 0; transform: scale(.7); } to { opacity: 1; transform: scale(1); } }
.ce-build-card.ce-build-success { animation: ce-build-fade .22s var(--ce-build-exit-delay, 2780ms) ease-in forwards; }
@keyframes ce-build-fade { to { opacity: 0; transform: translateY(-3px); } }

/* ---------- task records ---------- */
.ce-jobs { display: grid; gap: 14px; }
.ce-jbar { display: flex; align-items: center; gap: 10px 12px; flex-wrap: wrap; }
.ce-tasks { --t-cols: minmax(150px, 1.1fr) 80px 118px minmax(200px, 2.6fr) 58px 92px 112px; }
.ce-thead, .ce-trow { display: grid; grid-template-columns: var(--t-cols); align-items: center; gap: 14px; padding: 0 20px; }
.ce-thead { height: 40px; font-size: 12px; color: var(--c-label-3); box-shadow: inset 0 -1px 0 var(--c-line); }
.ce-tday { padding: 14px 20px 6px; font-size: 12px; font-weight: 600; color: var(--c-label-2); }
.ce-trow { min-height: 48px; padding-top: 6px; padding-bottom: 6px; box-shadow: inset 0 -1px 0 var(--c-line); transition: background-color .15s; }
.ce-tasks > :last-child { box-shadow: none; }
.ce-trow:hover { background: var(--c-hover); }
.ce-tc { min-width: 0; font-size: 13px; }
.ce-tc-name { display: flex; align-items: center; gap: 9px; }
.ce-tk { display: inline-flex; align-items: center; justify-content: center; flex: none; width: 26px; height: 26px; border-radius: 8px; background: var(--c-fill); color: var(--c-label-2); }
.ce-trow-error .ce-tk { background: var(--c-red-tint); color: var(--c-red-text); }
.ce-trow-running .ce-tk, .ce-trow-queued .ce-tk { background: var(--c-accent-tint); color: var(--c-accent-text); }
.ce-tc-name strong { font-weight: 500; white-space: nowrap; }
.ce-tc-name small { font-size: 12px; color: var(--c-label-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-tc-prog { display: flex; align-items: center; gap: 8px; }
.ce-tc-prog .ce-progress { flex: 1; }
.ce-tc-prog span { font-size: 12px; color: var(--c-label-2); font-variant-numeric: tabular-nums; }
.ce-trow-success .ce-progress i { background: var(--c-green); }
.ce-tc-note { display: flex; align-items: center; gap: 7px; color: var(--c-label-2); }
.ce-tc-note > span { min-width: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; line-height: 1.45; overflow-wrap: anywhere; }
.ce-tc-note.ce-tc-err { color: var(--c-red-text); }
.ce-tc-time, .ce-tc-dur { font-size: 12.5px; color: var(--c-label-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.ce-tc-acts { display: flex; align-items: center; justify-content: flex-end; gap: 2px; }
.ce-app .ce-tc-acts .ce-btn.ce-icon-btn { width: 28px; height: 28px; }
.ce-app .ce-tc-acts .ce-btn.ce-icon-btn:hover { color: var(--c-red-text); background: var(--c-red-tint); }
.ce-console { max-height: 360px; overflow: auto; margin: 0 -20px -18px; box-shadow: inset 0 1px 0 var(--c-line); font-size: 12.5px; line-height: 1.5; }
.ce-cl { display: grid; grid-template-columns: 150px 40px minmax(0, 1fr); align-items: baseline; gap: 12px; padding: 6px 20px; }
.ce-cl + .ce-cl { box-shadow: inset 0 1px 0 var(--c-line); }
.ce-cl:hover { background: var(--c-hover); }
.ce-cl time { color: var(--c-label-3); white-space: nowrap; font-family: var(--f-mono); font-size: 11.5px; }
.ce-cl-lv { justify-self: start; padding: 0 7px; border-radius: var(--r-pill); background: var(--c-fill); color: var(--c-label-2); font-size: 11px; font-weight: 500; text-align: center; }
.ce-cl-warning .ce-cl-lv { background: var(--c-orange-tint); color: var(--c-orange-text); }
.ce-cl-error .ce-cl-lv { background: var(--c-red-tint); color: var(--c-red-text); }
.ce-cl-msg { color: var(--c-label); overflow-wrap: anywhere; white-space: pre-wrap; }
.ce-cl-error .ce-cl-msg { color: var(--c-red-text); }

/* ---------- running task strip (dashboard) ---------- */
.ce-dtask { display: flex; align-items: center; gap: 10px 14px; flex-wrap: wrap; padding: 12px 18px; margin-bottom: 12px; border-radius: var(--r-card); background: var(--c-surface); box-shadow: var(--sh-card); font-size: 13px; color: var(--c-label-2); }
.ce-dtask strong { font-weight: 600; color: var(--c-label); }
.ce-dtask b { font-weight: 600; color: var(--c-label); font-variant-numeric: tabular-nums; }
.ce-dtask .ce-progress { flex: 1 1 160px; max-width: 360px; height: 6px; }
.ce-dtask.ce-fail b { color: var(--c-red-text); }

/* ---------- shared stat cards (dashboard and console) ---------- */
.ce-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; }
.ce-kpi, .ce-ed .ce-ed-kpi { display: flex; flex-direction: column; gap: 6px; min-width: 0; padding: 16px 18px 16px; border-radius: var(--r-card); background: var(--c-surface); box-shadow: var(--sh-card); color: inherit; transition: box-shadow .2s; }
a.ce-kpi:hover { box-shadow: var(--sh-lift); }
.ce-kpi-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 22px; }
.ce-kpi-k { font-size: 13px; color: var(--c-label-2); }
.ce-kpi-v { font-size: 28px; font-weight: 500; letter-spacing: -.022em; line-height: 1.15; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-kpi-foot { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--c-label-3); min-width: 0; }
.ce-kpi-n { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ========== 仪表盘 ========== */
.ce-ed { --ed-orange: #ff9500; --ed-pink: #ff375f; --ed-green: #34c759; --ed-violet: #8e6cf2; --ed-blue: #0071e3; --ed-teal: #30b0c7;
  --ed-track: rgba(0,0,0,.08); --ed-bar: rgba(0,113,227,.2); --ed-bar-hover: rgba(0,113,227,.34); --ed-heat: 52,199,89; }
@media (prefers-color-scheme: dark) { :root:not([data-darkmode="false"]) .ce-ed { --ed-track: rgba(255,255,255,.12); --ed-bar: rgba(10,132,255,.3); --ed-bar-hover: rgba(10,132,255,.45); } }
[data-darkmode="true"] .ce-ed { --ed-track: rgba(255,255,255,.12); --ed-bar: rgba(10,132,255,.3); --ed-bar-hover: rgba(10,132,255,.45); }
.ce-ed .ce-t-orange { --tone: var(--ed-orange); } .ce-ed .ce-t-pink { --tone: var(--ed-pink); } .ce-ed .ce-t-green { --tone: var(--ed-green); }
.ce-ed .ce-t-violet { --tone: var(--ed-violet); } .ce-ed .ce-t-blue { --tone: var(--ed-blue); } .ce-ed .ce-t-teal { --tone: var(--ed-teal); }
/* header: title left; period tabs, dates, version and fullscreen right */
.ce-ed > .ce-ed-hero { position: relative; z-index: 20; margin-bottom: 16px; }
.ce-ed .ce-ed-heroside { display: flex; align-items: center; gap: 10px 12px; flex-wrap: wrap; justify-content: flex-end; min-width: 0; }
.ce-ed .ce-ed-span { display: inline-flex; align-items: center; gap: 6px; color: var(--c-label-3); font-size: 12.5px; white-space: nowrap; }
.ce-ed .ce-ed-actions { display: inline-flex; align-items: center; gap: 8px; }
.ce-ed .ce-ed-fullbtn { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 14px 0 12px; border: 0; border-radius: var(--r-pill); cursor: pointer; background: var(--c-ink); color: var(--c-ink-text); font: inherit; font-size: 12.5px; font-weight: 500; transition: opacity .15s, transform .12s; }
.ce-ed .ce-ed-fullbtn:hover { opacity: .86; } .ce-ed .ce-ed-fullbtn:active { transform: scale(.96); }
/* left group: title, version, dates (the only part whose width changes, so it goes last) */
.ce-ed .ce-ed-lead { display: flex; align-items: center; gap: 8px 12px; flex-wrap: wrap; min-width: 0; }
.ce-ed .ce-ed-version { display: inline-flex; align-items: center; height: 24px; padding: 0 9px; margin-top: 3px; border-radius: var(--r-pill); background: var(--c-fill); color: var(--c-label-2); font-size: 12px; font-weight: 500; letter-spacing: .01em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ce-ed .ce-ed-lead > .ce-ed-badge { height: 26px; margin-top: 3px; }
.ce-ed .ce-ed-when { position: relative; display: inline-flex; align-items: center; margin-top: 3px; }
.ce-ed .ce-ed-when > .ce-ed-span:not(.ce-ed-span-btn) { padding-left: 2px; }
/* custom dates: a calendar popover under the dates; opening it never moves the page */
.ce-ed .ce-ed-span-btn { height: 30px; padding: 0 10px 0 12px; border: 0; border-radius: var(--r-pill); background: var(--c-surface); box-shadow: var(--sh-ctl); color: var(--c-label); font: inherit; font-size: 12.5px; cursor: pointer; }
.ce-ed .ce-ed-span-btn[aria-expanded="true"] { box-shadow: 0 0 0 2px var(--c-ink); }
.ce-ed .ce-ed-caret { width: 6px; height: 6px; margin: -3px 0 0 2px; border: solid currentColor; border-width: 0 1.5px 1.5px 0; transform: rotate(45deg); opacity: .5; transition: transform .2s; }
.ce-ed .ce-ed-span-btn[aria-expanded="true"] .ce-ed-caret { transform: rotate(-135deg); margin-top: 3px; }
.ce-ed .ce-ed-pop { position: absolute; top: calc(100% + 10px); left: 0; z-index: 30; width: max-content; padding: 14px; border-radius: 20px; background: var(--c-surface); box-shadow: var(--sh-pop); animation: ce-menu-in .16s cubic-bezier(.2,.8,.2,1); transform-origin: top left; }
.ce-ed .ce-ed-pop-ok { height: 34px; padding: 0 18px; border: 0; border-radius: var(--r-pill); background: var(--c-ink); color: var(--c-ink-text); font: inherit; font-size: 13px; font-weight: 500; cursor: pointer; }
.ce-ed .ce-cal { display: grid; grid-template-columns: 96px auto; gap: 14px; max-width: calc(100vw - 32px); }
.ce-ed .ce-cal-side { display: flex; flex-direction: column; gap: 2px; padding-right: 12px; box-shadow: inset -1px 0 0 var(--c-line); }
.ce-ed .ce-cal-quick { height: 32px; padding: 0 10px; border: 0; border-radius: 9px; background: none; color: var(--c-label-2); font: inherit; font-size: 13px; text-align: left; cursor: pointer; white-space: nowrap; }
.ce-ed .ce-cal-quick:hover { background: var(--c-fill); color: var(--c-label); }
.ce-ed .ce-cal-quick.ce-on { background: var(--c-ink); color: var(--c-ink-text); }
.ce-ed .ce-cal-main { display: grid; gap: 12px; min-width: 0; }
.ce-ed .ce-cal-fields { display: flex; align-items: flex-end; gap: 8px; }
.ce-ed .ce-cal-field { display: grid; gap: 5px; font-size: 11.5px; color: var(--c-label-3); }
.ce-ed .ce-cal-field .ce-input { width: 132px; height: 34px; font-variant-numeric: tabular-nums; }
.ce-ed .ce-cal-field .ce-input.ce-bad { box-shadow: 0 0 0 2px var(--c-red); }
.ce-ed .ce-cal-dash { width: 10px; height: 1.5px; margin-bottom: 16px; background: var(--c-label-4); }
.ce-ed .ce-cal-months { position: relative; display: grid; grid-template-columns: repeat(2, 236px); gap: 22px; }
.ce-ed .ce-cal-nav { position: absolute; top: -2px; z-index: 1; width: 28px; height: 28px; border: 0; border-radius: 50%; background: none; color: var(--c-label-2); cursor: pointer; }
.ce-ed .ce-cal-nav::before { content: ""; position: absolute; left: 50%; top: 50%; width: 7px; height: 7px; border: solid currentColor; border-width: 0 0 1.6px 1.6px; transform: translate(-30%, -50%) rotate(45deg); }
.ce-ed .ce-cal-nav.ce-next::before { transform: translate(-70%, -50%) rotate(-135deg); }
.ce-ed .ce-cal-nav.ce-prev { left: -4px; } .ce-ed .ce-cal-nav.ce-next { right: -4px; }
.ce-ed .ce-cal-nav:hover:not(:disabled) { background: var(--c-fill); color: var(--c-label); }
.ce-ed .ce-cal-nav:disabled { opacity: .3; cursor: default; }
.ce-ed .ce-cal-mt { height: 24px; line-height: 24px; text-align: center; font-size: 13px; font-weight: 600; color: var(--c-label); }
.ce-ed .ce-cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); row-gap: 2px; margin-top: 6px; }
.ce-ed .ce-cal-w { height: 24px; line-height: 24px; text-align: center; font-size: 11px; color: var(--c-label-3); }
.ce-ed .ce-cal-d { position: relative; height: 32px; padding: 0; border: 0; background: none; color: var(--c-label); font: inherit; font-size: 13px; font-variant-numeric: tabular-nums; cursor: pointer; }
.ce-ed .ce-cal-d::before { content: ""; position: absolute; inset: 1px 3px; z-index: -1; border-radius: 9px; }
.ce-ed .ce-cal-d { z-index: 0; }
.ce-ed .ce-cal-d:hover:not(:disabled)::before { background: var(--c-fill); }
.ce-ed .ce-cal-d.ce-in { background: var(--c-fill); }
.ce-ed .ce-cal-d.ce-a { border-radius: 10px 0 0 10px; } .ce-ed .ce-cal-d.ce-b { border-radius: 0 10px 10px 0; } .ce-ed .ce-cal-d.ce-a.ce-b { border-radius: 10px; }
.ce-ed .ce-cal-d.ce-a, .ce-ed .ce-cal-d.ce-b { color: var(--c-ink-text); }
.ce-ed .ce-cal-d.ce-a::before, .ce-ed .ce-cal-d.ce-b::before, .ce-ed .ce-cal-d.ce-a:hover::before, .ce-ed .ce-cal-d.ce-b:hover::before { inset: 0; background: var(--c-ink); border-radius: 10px; }
.ce-ed .ce-cal-d.ce-today:not(.ce-a):not(.ce-b) { color: var(--c-accent-text); font-weight: 600; }
.ce-ed .ce-cal-d.ce-has::after { content: ""; position: absolute; left: 50%; bottom: 4px; width: 3px; height: 3px; margin-left: -1.5px; border-radius: 50%; background: var(--ed-orange); }
.ce-ed .ce-cal-d:disabled { color: var(--c-label-4); cursor: default; }
.ce-ed .ce-cal-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 10px; box-shadow: inset 0 1px 0 var(--c-line); }
.ce-ed .ce-cal-note { font-size: 12.5px; color: var(--c-label-3); font-variant-numeric: tabular-nums; }
@media (max-width: 620px) {
  .ce-ed .ce-cal { grid-template-columns: minmax(0, 1fr); width: calc(100vw - 32px); }
  .ce-ed .ce-cal-side { flex-direction: row; flex-wrap: wrap; padding: 0 0 10px; box-shadow: inset 0 -1px 0 var(--c-line); }
  .ce-ed .ce-cal-months { grid-template-columns: minmax(0, 1fr); }
  .ce-ed .ce-cal-months > .ce-cal-month:first-of-type { display: none; }
  .ce-ed .ce-cal-field .ce-input { width: 100%; } .ce-ed .ce-cal-field { flex: 1; }
}
/* stat cards: title + badge, value with its context on one row, tick meter */
.ce-ed .ce-ed-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-bottom: 12px; }
.ce-ed .ce-ed-kpi-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 22px; }
.ce-ed .ce-ed-kpi-t { font-size: 13px; color: var(--c-label-2); }
.ce-ed .ce-ed-chip { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; border-radius: var(--r-pill); background: var(--c-fill); color: var(--c-label-2); font-size: 11.5px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.ce-ed .ce-ed-chip.ce-ed-rise { color: var(--c-green-text); background: var(--c-green-tint); }
.ce-ed .ce-ed-chip.ce-ed-fall { color: var(--c-red-text); background: var(--c-red-tint); }
.ce-ed .ce-ed-kpi-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; min-width: 0; }
.ce-ed .ce-ed-kpi-v { font-size: 30px; line-height: 1.1; font-weight: 500; letter-spacing: -.025em; color: var(--c-label); font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.ce-ed .ce-ed-kpi-side { display: grid; justify-items: end; gap: 1px; flex: none; text-align: right; padding-bottom: 2px; }
.ce-ed .ce-ed-kpi-side span { font-size: 11.5px; color: var(--c-label-3); white-space: nowrap; }
.ce-ed .ce-ed-kpi-side b { font-size: 13px; font-weight: 500; color: var(--c-label-2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.ce-ed .ce-ed-price { display: inline-flex; align-items: center; gap: 4px; padding: 0; border: 0; background: none; color: var(--c-accent-text); font: inherit; font-size: 13px; font-weight: 500; cursor: pointer; }
.ce-ed .ce-ed-price:hover { opacity: .75; }
.ce-ed .ce-ed-ticks { position: relative; height: 22px; margin-top: 6px; background: repeating-linear-gradient(90deg, var(--ed-track) 0 2px, transparent 2px 7px); }
.ce-ed .ce-ed-ticks > i { position: absolute; inset: 0 auto 0 0; background: repeating-linear-gradient(90deg, var(--tone) 0 2px, transparent 2px 7px); transition: width .5s cubic-bezier(.2,.8,.2,1); }
/* panels */
.ce-ed .ce-ed-row { display: grid; gap: 12px; margin-bottom: 12px; }
.ce-ed .ce-ed-row-a { grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr); }
.ce-ed .ce-ed-row-b { grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr) minmax(0, 1fr); }
.ce-ed .ce-ed-panel { display: flex; flex-direction: column; min-width: 0; padding: 18px 20px; border-radius: var(--r-card); background: var(--c-surface); box-shadow: var(--sh-card); }
.ce-ed .ce-ed-head { display: flex; align-items: center; justify-content: space-between; gap: 8px 12px; flex-wrap: wrap; margin-bottom: 14px; min-height: 32px; }
.ce-ed .ce-ed-titles { display: flex; align-items: baseline; gap: 4px 10px; flex-wrap: wrap; min-width: 0; }
.ce-ed .ce-ed-title { font-size: 16px; font-weight: 600; letter-spacing: -.01em; color: var(--c-label); }
.ce-ed .ce-ed-sub { font-size: 12.5px; color: var(--c-label-3); font-variant-numeric: tabular-nums; }
.ce-ed .ce-ed-tools { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ce-ed .ce-ed-empty { display: grid; place-items: center; min-height: 120px; color: var(--c-label-3); font-size: 13px; text-align: center; flex: 1; }
/* trend: labelled bars */
.ce-ed .ce-ed-trend-stats { display: flex; gap: 6px 22px; flex-wrap: wrap; margin: -6px 0 14px; font-size: 12.5px; color: var(--c-label-3); }
.ce-ed .ce-ed-trend-stats b { color: var(--c-label); font-weight: 600; font-variant-numeric: tabular-nums; }
.ce-ed .ce-ed-plot { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; height: 236px; flex: 1; min-height: 200px; }
.ce-ed .ce-ed-plot.ce-labeled { grid-template-columns: minmax(0, 1fr); }
.ce-ed .ce-ed-axis { display: flex; flex-direction: column; justify-content: space-between; padding: 24px 0 32px; font-size: 11px; color: var(--c-label-3); text-align: right; font-variant-numeric: tabular-nums; }
.ce-ed .ce-ed-axis span { line-height: 1; }
.ce-ed .ce-ed-cols { display: flex; gap: 10px; align-items: stretch; min-width: 0; }
.ce-ed .ce-ed-plot.ce-dense .ce-ed-cols { gap: 4px; }
.ce-ed .ce-ed-col { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 8px; cursor: default; }
.ce-ed .ce-ed-col-track { position: relative; flex: 1; display: flex; align-items: flex-end; margin-top: 24px; border-radius: 10px; background: var(--c-fill); }
.ce-ed .ce-ed-plot.ce-dense .ce-ed-col-track { border-radius: 5px; }
.ce-ed .ce-ed-col-fill { display: block; width: 100%; border-radius: 10px; background: var(--ed-bar); transition: height .45s cubic-bezier(.2,.8,.2,1), background-color .2s; }
.ce-ed .ce-ed-plot.ce-dense .ce-ed-col-fill { border-radius: 5px; }
.ce-ed .ce-ed-col:hover .ce-ed-col-fill { background: var(--ed-bar-hover); }
.ce-ed .ce-ed-col.ce-future .ce-ed-col-track { opacity: .5; }
.ce-ed .ce-ed-val { position: absolute; left: 50%; bottom: calc(var(--h, 0%) + 6px); transform: translateX(-50%); z-index: 2; white-space: nowrap; pointer-events: none; font-size: 11.5px; font-weight: 600; color: var(--c-label-2); font-variant-numeric: tabular-nums; }
.ce-ed .ce-ed-plot.ce-dense .ce-ed-val { font-size: 10px; letter-spacing: -.02em; }
.ce-ed .ce-ed-col-x { align-self: center; height: 22px; line-height: 22px; padding: 0 8px; border-radius: var(--r-pill); font-size: 11px; color: var(--c-label-3); white-space: nowrap; font-variant-numeric: tabular-nums; }
.ce-ed .ce-ed-plot.ce-dense .ce-ed-col-x { padding: 0 3px; font-size: 10.5px; }
.ce-ed .ce-ed-plot.ce-crowd .ce-ed-col-x.ce-alt { visibility: hidden; }
/* records */
.ce-ed .ce-ed-stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; flex: 1; align-content: stretch; }
.ce-ed .ce-ed-stat { position: relative; display: grid; align-content: center; gap: 2px; min-width: 0; padding: 12px 14px 12px 18px; border-radius: var(--r-tile); background: var(--c-fill); }
.ce-ed .ce-ed-stat::before { content: ""; position: absolute; left: 8px; top: 14px; bottom: 14px; width: 3px; border-radius: 3px; background: var(--tone); }
.ce-ed .ce-ed-stat span { font-size: 12px; color: var(--c-label-3); }
.ce-ed .ce-ed-stat strong { font-size: 19px; font-weight: 500; color: var(--c-label); font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.015em; }
.ce-ed .ce-ed-stat em { font-style: normal; font-size: 11.5px; color: var(--c-label-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* earnings heatmap */
.ce-ed .ce-ed-heat { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.ce-ed .ce-ed-heat-sum { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 16px; margin: -4px 0 12px; }
.ce-ed .ce-ed-heat-sum strong { font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.ce-ed .ce-ed-heat-sum span { font-size: 12px; color: var(--c-label-3); font-variant-numeric: tabular-nums; }
.ce-ed .ce-ed-heat-box { position: relative; width: 100%; flex: 1; display: flex; align-items: center; min-height: 0; }
.ce-ed .ce-ed-heat-svg { display: block; overflow: visible; touch-action: pan-y; }
.ce-ed .ce-ed-heat-svg text { font-family: var(--f-sans); font-size: 10.5px; fill: var(--c-label-3); }
.ce-ed .ce-ed-hcell { fill: rgba(0,0,0,.05); transform-box: fill-box; transform-origin: center; animation: ce-hcell .55s cubic-bezier(.23,1,.32,1) both; animation-delay: var(--d, 0s); }
.ce-ed .ce-ed-hcell.ce-l1 { fill: rgba(var(--ed-heat), .28); } .ce-ed .ce-ed-hcell.ce-l2 { fill: rgba(var(--ed-heat), .52); }
.ce-ed .ce-ed-hcell.ce-l3 { fill: rgba(var(--ed-heat), .76); } .ce-ed .ce-ed-hcell.ce-l4 { fill: rgb(var(--ed-heat)); }
@media (prefers-color-scheme: dark) { :root:not([data-darkmode="false"]) .ce-ed .ce-ed-hcell { fill: rgba(255,255,255,.06); } :root:not([data-darkmode="false"]) .ce-ed .ce-ed-hcell.ce-l1 { fill: rgba(var(--ed-heat), .28); } :root:not([data-darkmode="false"]) .ce-ed .ce-ed-hcell.ce-l2 { fill: rgba(var(--ed-heat), .52); } :root:not([data-darkmode="false"]) .ce-ed .ce-ed-hcell.ce-l3 { fill: rgba(var(--ed-heat), .76); } :root:not([data-darkmode="false"]) .ce-ed .ce-ed-hcell.ce-l4 { fill: rgb(var(--ed-heat)); } }
@keyframes ce-hcell { from { opacity: 0; transform: scale(.4); } to { opacity: 1; transform: scale(1); } }
.ce-ed .ce-ed-heat-tip { position: absolute; z-index: 3; transform: translate(-50%, calc(-100% - 8px)); padding: 7px 10px; border-radius: 10px; background: var(--c-surface); box-shadow: var(--sh-pop); font-size: 12px; line-height: 1.4; white-space: nowrap; pointer-events: none; }
.ce-ed .ce-ed-heat-tip b { display: block; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--c-label); }
.ce-ed .ce-ed-heat-tip span { color: var(--c-label-3); }
/* weekday profile */
.ce-ed .ce-ed-wd { display: grid; gap: 6px; flex: 1; align-content: space-between; }
.ce-ed .ce-ed-wd-row { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 10px; font-size: 12.5px; color: var(--c-label-2); }
.ce-ed .ce-ed-wd-bar { height: 10px; border-radius: var(--r-pill); background: var(--c-fill); overflow: hidden; }
.ce-ed .ce-ed-wd-bar i { display: block; height: 100%; border-radius: var(--r-pill); background: var(--ed-bar); transition: width .5s cubic-bezier(.2,.8,.2,1); }
.ce-ed .ce-ed-wd-row b { font-weight: 500; color: var(--c-label); font-variant-numeric: tabular-nums; min-width: 64px; text-align: right; }
.ce-ed .ce-ed-wd-row.ce-on span, .ce-ed .ce-ed-wd-row.ce-on b { color: var(--c-label); font-weight: 600; }
.ce-ed .ce-ed-wd-row.ce-on .ce-ed-wd-bar i { background: var(--c-accent); }
/* lines and traffic: the gauge after the reference card, three numbers under it */
.ce-ed .ce-ed-opsmeta { font-size: 12.5px; color: var(--c-label-3); font-variant-numeric: tabular-nums; white-space: nowrap; }
.ce-ed .ce-ed-opsbox { display: flex; flex-direction: column; justify-content: center; flex: 1; gap: 6px; }
.ce-ed .ce-ed-gauge { position: relative; display: grid; justify-items: center; margin: 0 auto; width: 100%; max-width: 330px; }
.ce-ed .ce-ed-gauge-svg { width: 100%; height: auto; overflow: visible; }
.ce-ed .ce-ed-gauge-paint { overflow: visible; pointer-events: none; }
.ce-ed .ce-ed-gauge-pointer { fill: none; stroke: #ff6a00; stroke-width: 1.3; stroke-dasharray: 2.6 2.4; }
.ce-ed .ce-ed-gauge.ce-over .ce-ed-gauge-pointer { stroke: var(--c-red); }
.ce-ed .ce-ed-gauge-tick { fill: none; stroke: var(--c-label-4); stroke-width: 1; opacity: .45; }
.ce-ed .ce-ed-gauge-tick.ce-on { stroke: var(--c-label); opacity: .82; }
.ce-ed .ce-ed-gauge-limit { fill: none; stroke: #ff6a00; stroke-width: 1.2; stroke-dasharray: 2.4 2.4; }
.ce-ed .ce-ed-gauge.ce-over .ce-ed-gauge-limit { stroke: var(--c-red); }
.ce-ed .ce-ed-gauge-label { font-family: var(--f-sans); font-size: 11.5px; fill: var(--c-label-2); font-variant-numeric: tabular-nums; }
.ce-ed .ce-ed-gauge-label.ce-limit { fill: var(--c-red-text); font-weight: 600; }
.ce-ed .ce-ed-gauge-needle { fill: #ff6a00; }
.ce-ed .ce-ed-gauge.ce-over .ce-ed-gauge-needle { fill: var(--c-red); }
/* the three numbers sit in the card itself: no tiles */
.ce-ed .ce-ed-ops { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding-top: 10px; }
.ce-ed .ce-ed-ops > div { display: grid; gap: 4px; justify-items: center; text-align: center; min-width: 0; }
.ce-ed .ce-ed-ops span { font-size: 12.5px; color: var(--c-label-3); white-space: nowrap; }
.ce-ed .ce-ed-ops b { font-size: 18px; font-weight: 500; letter-spacing: -.01em; color: var(--c-label); white-space: nowrap; font-variant-numeric: tabular-nums; }
.ce-ed .ce-ed-ops > .ce-over b { color: var(--c-red-text); }

/* tall windows (F11, portrait monitors): the board fills the height like fullscreen
   instead of leaving the space under it empty; top and bottom margins match */
@media (min-width: 1101px) and (min-height: 700px) {
  #main:has(> .ce-ed) { padding-bottom: 30px; }
  #main > .ce-ed:not(.ce-ed-full) { display: flex; flex-direction: column; min-height: calc(100vh - 60px); min-height: calc(100dvh - 60px); padding-bottom: 0; }
  #shell-status:not(:empty) + #main > .ce-ed:not(.ce-ed-full) { min-height: calc(100dvh - 116px); }
  #main > .ce-ed:not(.ce-ed-full) > * { flex: none; }
  #main > .ce-ed:not(.ce-ed-full) > .ce-ed-row-a { flex: 1.45 1 auto; }
  #main > .ce-ed:not(.ce-ed-full) > .ce-ed-row-b { flex: 1 1 auto; margin-bottom: 0; }
}

/* fullscreen: the board fills the screen; rows stretch with the window height and
   numbers grow with its width */
html.ce-ed-lock, html.ce-ed-lock body { overflow: hidden !important; }
#main > .ce-ed.ce-ed-full, .ce-ed.ce-ed-full { position: fixed; inset: 0; z-index: 880; display: flex; flex-direction: column; gap: clamp(10px, 1.5vh, 18px); max-width: none; margin: 0;
  padding: clamp(18px, 3.2vh, 44px) clamp(18px, 3vw, 56px) clamp(18px, 3vh, 40px); overflow: auto; overscroll-behavior: contain; background: var(--c-canvas); animation: ce-fade .2s ease both; }
.ce-ed.ce-ed-full > * { margin: 0 !important; flex: none; }
.ce-ed.ce-ed-full > .ce-ed-row-a { flex: 1.45 1 0; min-height: 300px; }
.ce-ed.ce-ed-full > .ce-ed-row-b { flex: 1 1 0; min-height: 250px; }
.ce-ed.ce-ed-full .ce-ed-plot { height: auto; min-height: 160px; }
.ce-ed.ce-ed-full .ce-title { font-size: clamp(26px, 1.9vw, 36px); }
.ce-ed.ce-ed-full .ce-ed-kpi-v { font-size: clamp(28px, 2.2vw, 46px); }
.ce-ed.ce-ed-full .ce-ed-kpi-t { font-size: clamp(13px, .9vw, 17px); } .ce-ed.ce-ed-full .ce-ed-title { font-size: clamp(16px, 1.05vw, 20px); }
.ce-ed.ce-ed-full .ce-ed-kpi-side b, .ce-ed.ce-ed-full .ce-ed-trend-stats { font-size: clamp(12.5px, .8vw, 15px); }
.ce-ed.ce-ed-full .ce-ed-stat strong { font-size: clamp(18px, 1.35vw, 26px); }
.ce-ed.ce-ed-full .ce-ed-ticks { height: clamp(20px, 2.6vh, 34px); }
.ce-ed.ce-ed-full .ce-ed-val { font-size: clamp(11px, .72vw, 14px); }
.ce-ed.ce-ed-full .ce-ed-gauge { max-width: clamp(240px, 19vw, 400px); }
.ce-ed.ce-ed-full .ce-ed-ops b { font-size: clamp(18px, 1.25vw, 24px); }
@media (max-height: 760px) { .ce-ed.ce-ed-full > .ce-ed-row-a, .ce-ed.ce-ed-full > .ce-ed-row-b { flex: none; } .ce-ed.ce-ed-full .ce-ed-plot { height: 230px; } }

/* ---------- motion: on user actions only, never on the periodic refresh ---------- */
@keyframes ce-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes ce-rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes ce-pop-in { from { opacity: 0; transform: translateY(6px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes ce-bump-k { 40% { transform: scale(1.2); } 100% { transform: none; } }
.ce-app { animation: ce-fade .3s ease both; }
.ce-enter > * { animation: ce-rise .32s cubic-bezier(.2,.8,.2,1) both; }
.ce-enter > :nth-child(2) { animation-delay: .04s; } .ce-enter > :nth-child(3) { animation-delay: .08s; } .ce-enter > :nth-child(n+4) { animation-delay: .12s; }
.ce-enter .ce-ncards > *, .ce-enter .ce-dcards > *, .ce-enter .ce-list > *, .ce-stagger > * { animation: ce-pop-in .3s cubic-bezier(.2,.8,.2,1) both; }
.ce-enter .ce-ncards > :nth-child(2), .ce-enter .ce-dcards > :nth-child(2), .ce-enter .ce-list > :nth-child(2) { animation-delay: .03s; }
.ce-enter .ce-ncards > :nth-child(3), .ce-enter .ce-dcards > :nth-child(3), .ce-enter .ce-list > :nth-child(3) { animation-delay: .06s; }
.ce-enter .ce-ncards > :nth-child(n+4), .ce-enter .ce-dcards > :nth-child(n+4), .ce-enter .ce-list > :nth-child(n+4) { animation-delay: .09s; }
.ce-bump { animation: ce-bump-k .26s ease; }
.ce-sheet.ce-fresh .ce-row-quote, .ce-sheet.ce-fresh .ce-row-launch { animation: ce-pop-in .3s cubic-bezier(.2,.8,.2,1) both; }
@media (prefers-reduced-motion: reduce) {
  .ce-app, .ce-app *, .ce-sheet, .ce-sheet *, .modal.ce-modal-host, #modal_overlay, .ce-menu { animation: none !important; transition: none !important; }
  .ce-build-check path { stroke-dashoffset: 0; }
}

/* ---------- LuCI (outside the web shell): the app keeps its own light canvas ---------- */
body:not(.shell-body) .ce-app:not(.ce-app .ce-app) { padding: 24px; border-radius: 26px; background: var(--c-canvas); }

/* ---------- responsive: follow the app's own width (LuCI's sidebar narrows it) ---------- */
@container ceapp (max-width: 1280px) {
  .ce-ed .ce-ed-row-b { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .ce-ed .ce-ed-heatp { grid-column: 1 / -1; }
}
@container ceapp (max-width: 1100px) {
  .ce-ed .ce-ed-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ce-ed .ce-ed-row-a { grid-template-columns: minmax(0, 1fr); }
  .ce-ed .ce-ed-stats { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@container ceapp (max-width: 980px) {
  .ce-tasks { --t-cols: minmax(120px, 1fr) 76px minmax(0, 2fr) 92px; }
  .ce-tc-prog, .ce-tc-time { display: none; }
  .ce-thead > :nth-child(3), .ce-thead > :nth-child(5) { display: none; }
}
@container ceapp (max-width: 700px) {
  .ce-title { font-size: 26px; }
  .ce-hero { margin-bottom: 16px; }
  .ce-stat, .ce-tile { padding: 13px 15px; }
  .ce-stat-v, .ce-tile-v { font-size: 20px; }
  .ce-toolbar { gap: 6px; }
  .ce-toolbar .ce-spec { display: none; }
  .ce-section-head { margin: 22px 0 10px; flex-wrap: wrap; row-gap: 2px; }
  .ce-row-account { grid-template-columns: 34px minmax(0, 1fr) auto; }
  .ce-row-account .ce-acts { grid-column: 2 / -1; justify-content: flex-start; }
  .ce-row-setting .ce-input { width: 150px; }
  .ce-trow { grid-template-columns: minmax(0, 1fr) auto auto; grid-template-areas: "name state acts" "note note dur"; gap: 2px 8px; padding: 10px 14px; }
  .ce-thead { display: none; }
  .ce-tc-name { grid-area: name; } .ce-tc-state { grid-area: state; } .ce-tc-note { grid-area: note; padding-left: 35px; } .ce-tc-dur { grid-area: dur; text-align: right; } .ce-tc-acts { grid-area: acts; }
  .ce-cl { grid-template-columns: auto minmax(0, 1fr); gap: 2px 10px; padding: 7px 16px; }
  .ce-cl-msg { grid-column: 1 / -1; }
  .ce-console { margin: 0 -16px -16px; }
  .ce-dpanel { padding: 16px; }
  /* dashboard */
  .ce-ed > .ce-ed-hero { margin-bottom: 12px; }
  .ce-ed .ce-ed-heroside { width: 100%; justify-content: space-between; }
  .ce-ed .ce-ed-tabs { width: 100%; }
  .ce-ed .ce-ed-tab { flex: 1; justify-content: center; padding: 0 6px; }
  .ce-ed .ce-ed-pop { left: 0; right: 0; flex-wrap: wrap; }
  .ce-ed .ce-ed-pop label { flex: 1 1 120px; }
  .ce-ed .ce-ed-pop .ce-input { width: 100%; }
  .ce-ed .ce-ed-pop-ok { flex: 1 1 100%; }
  .ce-ed .ce-ed-kpis { gap: 10px; }
  .ce-ed .ce-ed-kpi { padding: 13px 14px; gap: 4px; }
  .ce-ed .ce-ed-kpi-row { flex-direction: column; align-items: flex-start; gap: 2px; }
  .ce-ed .ce-ed-kpi-v { font-size: 22px; max-width: 100%; }
  .ce-ed .ce-ed-kpi-side { display: flex; gap: 4px; justify-items: start; text-align: left; }
  .ce-ed .ce-ed-ticks { height: 18px; }
  .ce-ed .ce-ed-row-b { grid-template-columns: minmax(0, 1fr); }
  .ce-ed .ce-ed-panel { padding: 16px; }
  .ce-ed .ce-ed-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ce-ed .ce-ed-plot { height: 200px; min-height: 180px; gap: 8px; }
  .ce-ed .ce-ed-cols { gap: 5px; }
  .ce-ed .ce-ed-col-x { padding: 0 2px; font-size: 10.5px; }
  .ce-ed .ce-ed-plot.ce-dense .ce-ed-col-x.ce-alt { visibility: hidden; }
  .ce-ed .ce-ed-val:not(.ce-on) { font-size: 10px; }
  body:not(.shell-body) .ce-app:not(.ce-app .ce-app) { padding: 16px 12px 24px; border-radius: 22px; }
}
@container ceapp (max-width: 340px) { .ce-ed .ce-ed-kpis { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 600px) {
  .modal.ce-modal-host { width: 100%; margin: 10vh 0 0; border-radius: 26px 26px 0 0 !important; }
  .ce-sheet-head { padding: 20px 18px 4px; } .ce-sheet-body { padding: 12px 18px 6px; } .ce-sheet-foot { padding: 14px 18px calc(18px + env(safe-area-inset-bottom)); flex-wrap: wrap; }
  .ce-row-quote { grid-template-columns: minmax(0, 1fr) auto; }
  .ce-row-quote > :nth-child(2) { grid-column: 1; grid-row: 2; }
  .ce-row-quote > :nth-child(4) { grid-column: 2; grid-row: 2; }
  .ce-row-form { grid-template-columns: 1fr; gap: 6px; }
  .ce-build-grid { max-height: 20vh; }
  .ce-sheet .ce-cookie-foot { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
  .ce-cookie-foot > .ce-cookie-actions { grid-column: 1 / -1; }
  .ce-cookie-foot > .ce-grow { display: none; }
}

/* 白名单规则 sheet: numbered groups in matching order, fixed first and last lines */
.ce-wl-state { display: flex; align-items: center; gap: 6px; margin: 0 0 12px; }
/* two groups per row; the fixed lines and the group being edited span the row */
.ce-wl-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; align-items: start; }
.ce-wl-fixed, .ce-wl-group.ce-open { grid-column: 1 / -1; }
@media (max-width: 600px) { .ce-wl-list { grid-template-columns: minmax(0, 1fr); } }
.ce-wl-fixed { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 14px; border-radius: var(--r-tile); background: var(--c-fill); font-size: 13px; color: var(--c-label-2); }
.ce-wl-fixed-text { display: flex; flex-direction: column; min-width: 0; }
.ce-wl-fixed-text small { font-size: 11.5px; color: var(--c-label-3); }
.ce-wl-group { border-radius: var(--r-tile); background: var(--c-surface); box-shadow: inset 0 0 0 1px var(--c-line); }
.ce-wl-group.ce-open { box-shadow: inset 0 0 0 1.5px var(--c-label-4); }
.ce-wl-top { display: flex; align-items: center; gap: 0; padding-right: 4px; }
.ce-wl-head { flex: 1 1 auto; display: flex; align-items: center; gap: 8px; min-width: 0; padding: 8px 4px 8px 10px; cursor: pointer; }
.ce-wl-no { flex: none; width: 24px; height: 24px; border-radius: 7px; display: inline-flex; align-items: center; justify-content: center; background: var(--c-fill); font-size: 12px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--c-label-2); }
.ce-wl-title { flex: 1 1 auto; display: flex; flex-direction: column; min-width: 0; }
.ce-wl-title strong { font-size: 13.5px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-wl-title span { font-size: 12px; color: var(--c-label-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ce-wl-tools { display: flex; flex: none; }
.ce-app .ce-wl-tools .ce-btn.ce-icon-btn, .ce-sheet .ce-wl-tools .ce-btn.ce-icon-btn { width: 28px; height: 28px; font-size: 14px; }
.ce-wl-body { padding: 0 12px 12px; }
.ce-wl-items-row { display: block; }
.ce-sheet .ce-wl-items { width: 100%; min-height: 72px; resize: vertical; font-size: 12.5px; line-height: 1.6; padding: 8px 10px; }
.ce-sheet .ce-wl-act { align-self: center; }
.ce-sheet .ce-wl-act > button { height: 26px; padding: 0 14px; border: 0; border-radius: var(--r-pill); background: none; color: var(--c-label-2); font: inherit; font-size: 12.5px; font-weight: 500; cursor: pointer; }
.ce-sheet .ce-wl-act > button.ce-on { color: #fff; cursor: default; }
.ce-sheet .ce-wl-act > button.ce-mode-proxy.ce-on { background: var(--c-ink); color: var(--c-ink-text); }
.ce-sheet .ce-wl-act > button.ce-mode-off.ce-on { background: var(--c-red); }
.ce-wl-group.ce-wl-shadowed { box-shadow: inset 0 0 0 1.5px var(--c-red); }
.ce-wl-warn { margin: -2px 10px 8px 42px; font-size: 12px; line-height: 1.5; color: var(--c-red-text); }
.ce-app .ce-wl-tools .ce-btn.ce-icon-btn, .ce-sheet .ce-wl-tools .ce-btn.ce-icon-btn { width: 26px; height: 26px; }
