@font-face {
  font-family: 'Inter';
  src: url('assets/InterVariable.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #F2F2F7;
  --ink: #1D1D1F;
  --muted: #86868B;
  --tertiary: #A9A9AE;
  --line: rgba(60, 60, 67, .10);
  --card: rgba(255, 255, 255, .86);
  --orange: #FF6900;
  --orange-soft: rgba(255, 105, 0, .10);
  --green: #34C759;
  --green-ink: #1B8F3A;
  --blue: #0A84FF;
  --purple: #AF52DE;
  --teal: #30B0C7;
  --red: #FF3B30;
  --shadow: 0 1px 2px rgba(16, 24, 40, .03), 0 12px 28px rgba(16, 24, 40, .06);
  --shadow-sm: 0 1px 2px rgba(16, 24, 40, .03), 0 6px 16px rgba(16, 24, 40, .05);
  --r: 24px;
  --ease: cubic-bezier(.22, .8, .24, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: Inter, "Noto Sans SC", "Microsoft YaHei UI", system-ui, sans-serif;
  color: var(--ink);
  background:
    radial-gradient(900px 600px at 72% -10%, #ffffff, transparent 60%),
    radial-gradient(700px 520px at 12% 110%, rgba(255, 190, 150, .22), transparent 62%),
    #E9EAEE;
  display: grid;
  place-items: center;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
button:active { transform: scale(.985); }
input { font: inherit; }
svg { display: block; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

/* ---------- device ---------- */
.device {
  width: 390px;
  height: 844px;
  border-radius: 46px;
  overflow: hidden;
  position: relative;
  background: var(--bg);
  box-shadow: 0 40px 80px rgba(20, 20, 40, .18), 0 4px 14px rgba(20, 20, 40, .06), inset 0 0 0 1px rgba(255, 255, 255, .6);
}
.app {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background:
    radial-gradient(360px 260px at 6% -4%, rgba(255, 166, 110, .36), transparent 62%),
    radial-gradient(330px 240px at 102% 0%, rgba(188, 174, 255, .28), transparent 62%),
    radial-gradient(400px 300px at 48% 112%, rgba(150, 196, 255, .22), transparent 66%),
    linear-gradient(180deg, #F7F6F9 0%, #F0F1F5 100%);
  padding-top: env(safe-area-inset-top);
}
.app::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .03;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23n)'/%3E%3C/svg%3E");
  z-index: 1;
}

/* ---------- topbar ---------- */
.topbar {
  flex: none;
  height: 54px;
  padding: 0 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  z-index: 5;
}
.brand { display: flex; align-items: center; gap: 8px; }
.brand-mark {
  width: 24px; height: 24px;
  border-radius: 8px;
  display: grid; place-items: center;
  color: #fff; font-size: 11px; font-weight: 600;
  background: linear-gradient(145deg, #FF9A52, #FF5A00);
  box-shadow: 0 4px 10px rgba(255, 105, 0, .28), inset 0 1px 0 rgba(255, 255, 255, .35);
}
.brand-name { font-size: 13px; font-weight: 600; letter-spacing: .08em; }
.top-actions { display: flex; align-items: center; gap: 7px; }
.device-chip {
  display: inline-flex; align-items: center; gap: 5px;
  height: 24px; padding: 0 9px; border-radius: 20px;
  background: rgba(255, 255, 255, .66);
  border: 1px solid rgba(255, 255, 255, .9);
  box-shadow: 0 2px 8px rgba(16, 24, 40, .05);
  font-size: 9.5px; color: #6E6E73; letter-spacing: .02em;
}
.device-chip i { width: 4px; height: 4px; border-radius: 50%; background: var(--green); }
.icon-btn {
  width: 30px; height: 30px; border-radius: 50%;
  display: grid; place-items: center;
  background: rgba(255, 255, 255, .66);
  border: 1px solid rgba(255, 255, 255, .9);
  box-shadow: 0 2px 8px rgba(16, 24, 40, .05);
}
.icon-btn svg { width: 15px; height: 15px; stroke: #3A3A3C; fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- content ---------- */
.content {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 2px 16px calc(98px + env(safe-area-inset-bottom));
  position: relative;
  z-index: 2;
  scrollbar-width: none;
}
.content::-webkit-scrollbar { display: none; }

.screen { display: none; padding-top: 2px; }
.screen.is-active { display: block; animation: screenIn .26s var(--ease) both; }
@keyframes screenIn { from { opacity: 0; transform: translateY(7px); } to { opacity: 1; transform: none; } }

.title-block { margin: 2px 0 13px; }
.eyebrow { font-size: 10px; color: var(--muted); letter-spacing: .10em; }
.title-line { display: flex; align-items: center; gap: 9px; margin-top: 3px; min-height: 38px; }
h1 { font-size: 30px; font-weight: 700; letter-spacing: -.025em; line-height: 1.15; }
.pill {
  display: inline-flex; align-items: center; gap: 4px;
  height: 21px; padding: 0 8px; border-radius: 11px;
  background: var(--orange-soft); color: var(--orange);
  font-size: 9.5px; font-weight: 600; letter-spacing: .06em;
}
.pill i { width: 4px; height: 4px; border-radius: 50%; background: var(--orange); box-shadow: 0 0 0 3px rgba(255, 105, 0, .10); }
.pill.live i { animation: pulse 2s infinite; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 3px rgba(255, 105, 0, .10); } 50% { box-shadow: 0 0 0 5px rgba(255, 105, 0, .04); } }

.card {
  background: var(--card);
  border: 1px solid rgba(255, 255, 255, .92);
  border-radius: var(--r);
  box-shadow: var(--shadow);
  backdrop-filter: blur(24px) saturate(180%);
}
.muted { color: var(--muted); }
.label { font-size: 10.5px; color: var(--muted); letter-spacing: .03em; }
.hint { font-size: 10px; color: var(--tertiary); }
.verified {
  display: inline-flex; align-items: center; gap: 3px;
  font-size: 9.5px; color: var(--green-ink);
  background: rgba(52, 199, 89, .10);
  border: 1px solid rgba(52, 199, 89, .16);
  border-radius: 8px; padding: 2px 6px;
}
.link { color: var(--orange); font-size: 10.5px; font-weight: 500; }
.link.danger { color: var(--red); }

/* ---------- monitor ---------- */
.hero {
  padding: 14px 16px 12px;
  position: relative;
  overflow: hidden;
  background: linear-gradient(165deg, rgba(255, 255, 255, .96), rgba(255, 247, 240, .84));
}
.hero::before {
  content: "";
  position: absolute; right: -60px; top: -80px;
  width: 200px; height: 200px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 150, 80, .16), transparent 66%);
}
.hero-top { display: flex; align-items: center; justify-content: space-between; position: relative; }
.hero-top .muted { font-size: 10.5px; font-weight: 500; }
.live-tag { display: flex; align-items: center; gap: 4px; font-size: 9px; letter-spacing: .14em; color: var(--orange); font-weight: 600; }
.live-tag i { width: 4px; height: 4px; border-radius: 50%; background: var(--orange); box-shadow: 0 0 0 3px rgba(255, 105, 0, .12); }
.hero-main { display: flex; align-items: flex-end; margin-top: 2px; position: relative; }
.hero-num { display: flex; align-items: flex-start; gap: 5px; }
.hero-num b {
  font-size: 56px; line-height: .98; font-weight: 600; letter-spacing: -.045em;
  font-variant-numeric: tabular-nums;
}
.hero-num em { font-style: normal; font-size: 9.5px; color: var(--muted); letter-spacing: .12em; margin-top: 10px; }
.hero-side { margin-left: auto; display: flex; gap: 15px; padding-bottom: 7px; text-align: right; }
.hero-side b { display: block; font-size: 12.5px; font-weight: 600; font-variant-numeric: tabular-nums; }
.hero-side em { display: block; font-style: normal; font-size: 8.5px; color: var(--muted); letter-spacing: .08em; margin-top: 2px; }
.hero-chart { height: 62px; margin-top: 4px; position: relative; }
.hero-foot { display: flex; align-items: center; gap: 8px; margin-top: 7px; }
.hero-foot .muted { font-size: 9.5px; }
.hero-foot .delta { margin-left: auto; font-size: 10.5px; font-weight: 600; color: var(--orange); }

.chart svg { width: 100%; height: 100%; display: block; overflow: visible; }
.chart .line { fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.chart .area { stroke: none; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 10px; }
.stat { padding: 12px 13px 11px; border-radius: 22px; }
.stat-top { display: flex; align-items: center; justify-content: space-between; }
.stat-val { display: flex; align-items: baseline; gap: 2px; margin-top: 4px; }
.stat-val b { font-size: 25px; font-weight: 600; letter-spacing: -.035em; font-variant-numeric: tabular-nums; }
.stat-val span { font-size: 9.5px; color: var(--muted); }
.progress { height: 3.5px; border-radius: 4px; background: rgba(60, 60, 67, .07); overflow: hidden; margin-top: 7px; }
.progress i { display: block; height: 100%; border-radius: 4px; background: linear-gradient(90deg, #FFB340, #FF6900); transition: width .5s var(--ease); }
.stat-sub { font-size: 9px; color: var(--tertiary); margin-top: 5px; }

.load { margin-top: 10px; padding: 12px 14px 11px; }
.card-head { display: flex; align-items: center; justify-content: space-between; }
.load .card-head { margin-bottom: 5px; }
.load-row { display: grid; grid-template-columns: 30px 1fr 52px; align-items: center; gap: 8px; padding: 4.5px 0; }
.load-row span { font-size: 9.5px; color: #6E6E73; }
.load-row b { font-size: 9.5px; color: #6E6E73; text-align: right; font-weight: 500; font-variant-numeric: tabular-nums; }
.track { height: 3.5px; border-radius: 4px; background: rgba(60, 60, 67, .07); overflow: hidden; }
.track i { display: block; height: 100%; border-radius: 4px; transition: width .5s var(--ease); }

.auto-card { margin-top: 10px; width: 100%; display: flex; align-items: center; gap: 10px; padding: 11px 14px; text-align: left; border-radius: 20px; }

.timeline { margin-top: 10px; padding: 12px 14px 9px; }
.timeline .card-head { margin-bottom: 5px; }
.tl-row { display: grid; grid-template-columns: 26px 1fr 40px; align-items: center; gap: 6px; padding: 2.5px 0; }
.tl-row > span { font-size: 8.5px; color: var(--muted); }
.tl-row > b { font-size: 8.5px; font-weight: 500; color: #6E6E73; text-align: right; font-variant-numeric: tabular-nums; }
.tl-chart { height: 22px; }
.tl-chart svg { width: 100%; height: 100%; display: block; overflow: visible; }
.tl-axis { position: relative; height: 15px; margin-top: 2px; border-top: 1px solid var(--line); }
.tl-event { position: absolute; left: 62%; top: 2px; transform: translateX(-50%); font-size: 7.5px; color: var(--orange); white-space: nowrap; background: rgba(255, 105, 0, .08); border: 1px solid rgba(255, 105, 0, .16); border-radius: 7px; padding: 1px 5px; }
.dot-peach { background: #FFB27A; }
.dot-blue { background: var(--blue); }

.today { margin-top: 10px; padding: 12px 14px 11px; }
.today .card-head { margin-bottom: 8px; }
.today-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; }
.today-grid > div + div { border-left: 1px solid var(--line); padding-left: 12px; }
.today-grid b { display: block; font-size: 18px; font-weight: 600; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.today-grid em { display: block; font-style: normal; font-size: 8.5px; color: var(--tertiary); margin-top: 1px; letter-spacing: .06em; }

.activity { margin-top: 8px; padding: 10px 14px; display: flex; align-items: baseline; gap: 4px; }
.activity .label { margin-right: 6px; }
.activity b { font-size: 18px; font-weight: 600; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.activity .unit { font-size: 8.5px; color: var(--muted); }
.activity em { margin-left: auto; font-style: normal; font-size: 8.5px; color: var(--tertiary); }
.auto-icon { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; background: var(--orange-soft); color: var(--orange); flex: none; }
.auto-icon svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 1.8; }
.auto-text { flex: 1; }
.auto-text b { display: block; font-size: 11px; font-weight: 600; }
.auto-text em { display: block; font-style: normal; font-size: 9.5px; color: var(--muted); margin-top: 1px; }

/* ---------- records ---------- */
.segmented { display: flex; gap: 2px; padding: 2px; border-radius: 10px; background: rgba(118, 118, 128, .08); }
.segmented button { flex: 1; padding: 4px 8px; border-radius: 8px; font-size: 9.5px; color: #6E6E73; white-space: nowrap; }
.segmented button.is-on { background: #fff; color: var(--ink); font-weight: 600; box-shadow: 0 1px 3px rgba(0, 0, 0, .10); }
.segmented.small button { padding: 4px 7px; font-size: 9px; }

.delta-block { margin: 4px 0 10px; }
.delta-big { display: flex; align-items: baseline; gap: 5px; margin-top: 3px; }
.delta-big b { font-size: 40px; font-weight: 600; letter-spacing: -.03em; color: var(--orange); font-variant-numeric: tabular-nums; }
.delta-big span { font-size: 11px; color: var(--muted); }

.ab-card { padding: 13px 14px 9px; }
.ab-chart { height: 152px; margin-top: 7px; }
.legend { display: flex; align-items: center; gap: 5px; font-size: 8.5px; color: var(--tertiary); }
.legend i { width: 9px; height: 2px; border-radius: 2px; display: inline-block; margin-left: 4px; }
.legend i:first-child { margin-left: 0; }
.dot-grey { background: #B9B9BE; }
.dot-orange { background: var(--orange); }
.axis { display: flex; justify-content: space-between; font-size: 8.5px; color: var(--tertiary); margin-top: 4px; }

.insight { margin-top: 10px; padding: 10px 14px; }
.insight p { font-size: 9.5px; line-height: 1.6; color: #6E6E73; }
.insight p b { color: var(--orange); font-weight: 600; }
.insight-label { color: var(--tertiary); margin-right: 6px; }

.compare { display: grid; grid-template-columns: 1fr 1fr 1fr; margin: 12px 0 6px; }
.compare div { text-align: center; position: relative; }
.compare div + div::before { content: ""; position: absolute; left: 0; top: 2px; bottom: 2px; width: 1px; background: var(--line); }
.compare em { display: block; font-style: normal; font-size: 9px; color: var(--tertiary); letter-spacing: .05em; margin-bottom: 3px; }
.compare b { font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; }
.compare b.good { color: var(--green-ink); }
.compare b.warn { color: #D97706; }

.list-title { display: flex; align-items: center; justify-content: space-between; margin: 14px 2px 7px; }
.list-title span { font-size: 10px; color: var(--muted); letter-spacing: .12em; }

.session-list { padding: 2px 14px; }
.session-row { display: flex; align-items: center; gap: 10px; padding: 10px 0; }
.session-row + .session-row { border-top: 1px solid var(--line); }
.session-icon { width: 30px; height: 30px; border-radius: 9px; background: rgba(255, 105, 0, .10); color: var(--orange); display: grid; place-items: center; font-size: 11px; font-weight: 600; flex: none; }
.session-icon.grey { background: rgba(118, 118, 128, .10); color: #6E6E73; }
.session-text { flex: 1; min-width: 0; }
.session-text b { display: block; font-size: 11px; font-weight: 600; }
.session-text em { display: block; font-style: normal; font-size: 9px; color: var(--tertiary); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.session-val { font-size: 13px; font-weight: 600; color: var(--orange); font-variant-numeric: tabular-nums; }
.session-val.muted { color: var(--tertiary); }

.btn-primary {
  width: 100%; height: 44px; border-radius: 14px; margin-top: 10px;
  display: flex; align-items: center; justify-content: center; gap: 7px;
  background: var(--ink); color: #fff; font-size: 11.5px; font-weight: 600; letter-spacing: .02em;
  box-shadow: 0 8px 20px rgba(0, 0, 0, .14);
}
.btn-primary svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 1.8; }

/* ---------- tune ---------- */
.recipe { padding: 13px 15px 3px; }
.recipe-head { display: flex; align-items: center; gap: 10px; padding-bottom: 9px; }
.recipe-icon { width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; flex: none; background: linear-gradient(145deg, #FFE7D6, #FFD1B3); color: var(--orange); }
.recipe-icon svg { width: 17px; height: 17px; stroke: currentColor; fill: none; stroke-width: 1.8; }
.recipe-title { flex: 1; }
.recipe-title b { display: block; font-size: 12px; font-weight: 600; }
.recipe-title em { display: block; font-style: normal; font-size: 9px; color: var(--tertiary); margin-top: 2px; }
.switch { width: 38px; height: 22px; border-radius: 20px; background: rgba(120, 120, 128, .18); position: relative; flex: none; transition: background .2s; }
.switch::after { content: ""; position: absolute; left: 2px; top: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 2px 4px rgba(0, 0, 0, .18); transition: transform .2s var(--ease); }
.switch.is-on { background: var(--green); }
.switch.is-on::after { transform: translateX(16px); }

.recipe-row { display: flex; align-items: center; gap: 10px; min-height: 45px; border-top: 1px solid var(--line); width: 100%; text-align: left; }
.row-label { font-size: 10.5px; color: #6E6E73; width: 52px; flex: none; }
.row-value { flex: 1; display: flex; flex-direction: column; align-items: flex-end; }
.row-value b { font-size: 11px; font-weight: 600; }
.row-value em { font-style: normal; font-size: 8.5px; color: var(--tertiary); margin-top: 1px; }
.chev { width: 15px; height: 15px; stroke: #C0C0C5; fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; flex: none; }

.modes { margin-top: 10px; padding: 13px 14px 12px; }
.mode-chips { display: flex; gap: 6px; margin-top: 9px; }
.mode-chips button { flex: 1; height: 32px; border-radius: 10px; font-size: 10px; font-weight: 500; color: #6E6E73; background: rgba(118, 118, 128, .07); border: 1px solid transparent; }
.mode-chips button.is-on { background: var(--ink); color: #fff; font-weight: 600; box-shadow: 0 4px 10px rgba(0, 0, 0, .14); }
.note { margin-top: 9px; font-size: 9.5px; color: var(--tertiary); line-height: 1.55; }
.note b { color: var(--orange); font-weight: 600; }

.list-card { margin-top: 10px; padding: 3px 14px; }
.check-row { display: flex; align-items: center; gap: 9px; min-height: 36px; }
.check-row + .check-row { border-top: 1px solid var(--line); }
.check-row span:nth-child(2) { flex: 1; font-size: 10px; color: #3A3A3C; }
.check-row em { font-style: normal; font-size: 8.5px; color: var(--tertiary); }
.check-dot { width: 17px; height: 17px; border-radius: 50%; display: grid; place-items: center; background: rgba(52, 199, 89, .12); }
.check-dot svg { width: 9px; height: 9px; stroke: var(--green-ink); fill: none; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- apps ---------- */
.search-box {
  height: 40px; border-radius: 13px; display: flex; align-items: center; gap: 7px;
  padding: 0 12px; background: rgba(255, 255, 255, .82); border: 1px solid rgba(255, 255, 255, .9);
  box-shadow: var(--shadow-sm); margin-bottom: 9px;
}
.search-box svg { width: 15px; height: 15px; stroke: var(--tertiary); fill: none; stroke-width: 1.8; flex: none; }
.search-box input { flex: 1; border: 0; outline: 0; background: transparent; font-size: 11px; color: var(--ink); }
.search-box input::placeholder { color: var(--tertiary); }

.filter-chips { display: flex; gap: 6px; margin-bottom: 10px; }
.filter-chips button { height: 28px; padding: 0 12px; border-radius: 14px; font-size: 9.5px; color: #6E6E73; background: rgba(118, 118, 128, .08); }
.filter-chips button.is-on { background: var(--ink); color: #fff; font-weight: 600; }

.app-list { background: var(--card); border: 1px solid rgba(255, 255, 255, .92); border-radius: 22px; box-shadow: var(--shadow); overflow: hidden; }
.app-row { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 13px; text-align: left; }
.app-row + .app-row { border-top: 1px solid var(--line); }
.app-icon { width: 36px; height: 36px; border-radius: 11px; display: grid; place-items: center; font-size: 12px; font-weight: 600; flex: none; }
.app-meta { flex: 1; min-width: 0; }
.app-meta b { display: block; font-size: 11.5px; font-weight: 600; }
.app-meta em { display: block; font-style: normal; font-size: 9px; color: var(--tertiary); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.badge { font-size: 8.5px; padding: 2px 7px; border-radius: 8px; background: rgba(118, 118, 128, .09); color: #6E6E73; flex: none; }
.badge.active { background: rgba(52, 199, 89, .10); color: var(--green-ink); }
.badge.limited { background: rgba(255, 149, 0, .12); color: #B26A00; }
.badge.frozen { background: rgba(10, 132, 255, .10); color: #0B6BCB; }
.app-row.is-frozen .app-icon { filter: grayscale(.6); opacity: .7; }
.app-row.is-frozen .app-meta { opacity: .7; }
.empty { padding: 28px 0; text-align: center; font-size: 10px; color: var(--tertiary); }

/* ---------- settings ---------- */
.perm-card { padding: 14px 15px 13px; }
.perm-switch { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 3px; background: rgba(118, 118, 128, .08); border-radius: 11px; padding: 3px; margin-top: 10px; }
.perm-switch button { height: 30px; border-radius: 9px; font-size: 9.5px; color: #6E6E73; }
.perm-switch button.is-on { background: #fff; color: var(--ink); font-weight: 600; box-shadow: 0 1px 3px rgba(0, 0, 0, .10); }
.setting-row { display: flex; align-items: center; gap: 10px; min-height: 52px; width: 100%; text-align: left; border-top: 1px solid var(--line); }
.setting-row:first-child { border-top: 0; }
.setting-text { flex: 1; }
.setting-text b { display: block; font-size: 11px; font-weight: 600; }
.setting-text em { display: block; font-style: normal; font-size: 9px; color: var(--tertiary); margin-top: 2px; }
.setting-row .row-value { flex: none; font-size: 10px; color: var(--tertiary); }
.foot-note { margin: 16px 4px 0; font-size: 9px; line-height: 1.7; color: var(--tertiary); text-align: center; }

.device-card { margin-top: 10px; padding: 13px 15px 10px; }
.spec-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 11px 10px; margin-top: 11px; }
.spec-grid em { display: block; font-style: normal; font-size: 8.5px; color: var(--tertiary); margin-bottom: 2px; }
.spec-grid b { font-size: 11px; font-weight: 600; }
.cap-list { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 4px; }
.cap { display: flex; align-items: center; gap: 8px; min-height: 32px; font-size: 10px; color: #3A3A3C; }
.cap + .cap { border-top: 1px solid var(--line); }
.cap em { margin-left: auto; font-style: normal; font-size: 8.5px; color: var(--tertiary); }
.check-dot.off { background: rgba(118, 118, 128, .10); color: var(--tertiary); font-size: 11px; font-weight: 600; }

/* ---------- tabbar ---------- */
.tabbar {
  position: absolute;
  left: 14px; right: 14px;
  bottom: calc(14px + env(safe-area-inset-bottom));
  height: 60px;
  border-radius: 30px;
  background: rgba(255, 255, 255, .76);
  border: 1px solid rgba(255, 255, 255, .92);
  box-shadow: 0 12px 30px rgba(16, 24, 40, .12), inset 0 1px 0 rgba(255, 255, 255, .9);
  backdrop-filter: blur(30px) saturate(180%);
  display: flex;
  align-items: center;
  padding: 0 6px;
  z-index: 30;
}
.tab { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px; color: var(--tertiary); font-size: 8.5px; letter-spacing: .02em; transition: color .18s; }
.tab svg { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.tab.is-on { color: var(--orange); }
.tab.is-on svg { stroke-width: 2; }
.tab.is-on::after { content: ""; width: 3px; height: 3px; border-radius: 50%; background: var(--orange); margin-top: -1px; }

/* ---------- sheet ---------- */
.scrim {
  position: absolute; inset: 0; z-index: 50;
  background: rgba(20, 20, 30, .28);
  opacity: 0; pointer-events: none;
  transition: opacity .25s;
  backdrop-filter: blur(2px);
}
.scrim.is-open { opacity: 1; pointer-events: auto; }
.sheet {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 60;
  background: #fff;
  border-radius: 28px 28px 0 0;
  box-shadow: 0 -20px 50px rgba(16, 24, 40, .18);
  transform: translateY(110%);
  transition: transform .34s var(--ease);
  padding: 8px 18px calc(22px + env(safe-area-inset-bottom));
  max-height: 82%;
  overflow-y: auto;
}
.sheet.is-open { transform: none; }
.grabber { width: 36px; height: 5px; border-radius: 3px; background: rgba(60, 60, 67, .18); margin: 0 auto 9px; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.sheet-head h2 { font-size: 16px; font-weight: 700; letter-spacing: -.01em; }
.sheet-head .icon-btn { background: rgba(118, 118, 128, .08); border: 0; box-shadow: none; }
.sheet-body { padding-bottom: 2px; }

.option-list { display: flex; flex-direction: column; }
.option {
  display: flex; align-items: center; gap: 11px;
  min-height: 52px; text-align: left; width: 100%;
  border-top: 1px solid var(--line);
}
.option:first-child { border-top: 0; }
.option-radio { width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid rgba(60, 60, 67, .22); flex: none; display: grid; place-items: center; }
.option.is-on .option-radio { border-color: var(--orange); background: var(--orange); }
.option.is-on .option-radio::after { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #fff; }
.option-text { flex: 1; }
.option-text b { display: block; font-size: 12px; font-weight: 600; }
.option-text em { display: block; font-style: normal; font-size: 9.5px; color: var(--tertiary); margin-top: 2px; }
.option-tag { font-size: 8.5px; color: var(--tertiary); }
.sheet-note { font-size: 9.5px; color: var(--tertiary); line-height: 1.6; margin-top: 10px; }

.action-btn { width: 100%; height: 46px; border-radius: 13px; font-size: 12px; font-weight: 600; margin-top: 8px; background: rgba(118, 118, 128, .08); color: var(--ink); }
.action-btn.danger { color: var(--red); }
.action-btn.primary { background: var(--ink); color: #fff; }

/* ---------- toast ---------- */
.toast {
  position: absolute; left: 50%; bottom: calc(92px + env(safe-area-inset-bottom));
  transform: translate(-50%, 8px);
  background: rgba(29, 29, 31, .94);
  color: #fff; font-size: 10px; padding: 9px 13px; border-radius: 12px;
  opacity: 0; pointer-events: none; transition: .25s var(--ease); z-index: 70;
  max-width: 82%; text-align: center; line-height: 1.4;
}
.toast.is-show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- mobile ---------- */
@media (max-width: 500px) {
  body { display: block; background: var(--bg); }
  .device { width: 100%; height: 100dvh; border-radius: 0; box-shadow: none; }
  .app { position: absolute; inset: 0; }
}

/* ---------- v0.2 console ---------- */
.statusline { display: flex; align-items: center; gap: 5px; margin-top: 6px; font-size: 8.5px; color: var(--tertiary); letter-spacing: .02em; }
.statusline > i { width: 4px; height: 4px; border-radius: 50%; background: var(--green); }
.statusline .sep { color: rgba(60, 60, 67, .25); }
.statusline .ok { color: var(--green-ink); }

.console { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.tile { background: var(--card); border: 1px solid rgba(255, 255, 255, .92); border-radius: 18px; box-shadow: var(--shadow-sm); padding: 9px 11px 7px; backdrop-filter: blur(18px) saturate(160%); }
.t-head { display: flex; align-items: center; justify-content: space-between; }
.t-head em { font-style: normal; font-size: 8.5px; color: var(--muted); letter-spacing: .04em; }
.t-head span { font-size: 7px; color: var(--tertiary); }
.t-val { font-size: 20px; font-weight: 600; letter-spacing: -.03em; margin-top: 2px; font-variant-numeric: tabular-nums; line-height: 1.2; }
.t-val b { font: inherit; letter-spacing: inherit; }
.t-val span { font-size: 8.5px; color: var(--muted); margin-left: 1px; font-weight: 500; }
.t-sub { font-size: 7.5px; color: var(--tertiary); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.t-chart { height: 16px; margin-top: 3px; }

.cores { margin-top: 8px; padding: 11px 14px 9px; }
.core-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 5px; margin-top: 8px; align-items: end; }
.core { display: flex; flex-direction: column; align-items: center; gap: 3px; }
.core > span { font-size: 6.5px; color: var(--tertiary); }
.cbar { width: 100%; height: 26px; display: flex; align-items: flex-end; background: rgba(60, 60, 67, .06); border-radius: 4px; overflow: hidden; }
.cbar i { width: 100%; border-radius: 4px; background: linear-gradient(180deg, #FF9A52, #FF6900); transition: height .45s var(--ease); }
.core > b { font-size: 6.5px; color: var(--muted); font-weight: 500; }

/* ---------- v0.2 tools ---------- */
.tool-card { padding: 12px 15px 3px; }
.tool-card .card-head { padding-bottom: 4px; }
.tool-row { display: flex; align-items: center; gap: 10px; min-height: 47px; width: 100%; border-top: 1px solid var(--line); text-align: left; }
.tool-ico { width: 28px; height: 28px; border-radius: 9px; background: rgba(255, 105, 0, .08); display: grid; place-items: center; flex: none; color: var(--orange); }
.tool-ico svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 1.8; }
.tool-text { flex: 1; min-width: 0; }
.tool-text b { display: block; font-size: 11px; font-weight: 600; }
.tool-text em { display: block; font-style: normal; font-size: 8.5px; color: var(--tertiary); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tool-val { font-size: 9.5px; color: var(--muted); font-weight: 500; }

.tool-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.tool-tile { background: var(--card); border: 1px solid rgba(255, 255, 255, .92); border-radius: 18px; box-shadow: var(--shadow-sm); padding: 10px 12px 9px; text-align: left; display: flex; flex-direction: column; gap: 1px; min-height: 70px; backdrop-filter: blur(18px) saturate(160%); }
.tile-ico { width: 24px; height: 24px; border-radius: 8px; background: rgba(255, 105, 0, .08); color: var(--orange); display: grid; place-items: center; margin-bottom: 3px; }
.tile-ico svg { width: 13px; height: 13px; stroke: currentColor; fill: none; stroke-width: 1.8; }
.tool-tile b { font-size: 10.5px; font-weight: 600; }
.tool-tile em { font-style: normal; font-size: 8px; color: var(--tertiary); }

.option-sub { font-size: 8.5px; color: var(--tertiary); margin-top: 1px; }

.content-fade {
  position: absolute;
  left: 0; right: 0;
  bottom: calc(74px + env(safe-area-inset-bottom));
  height: 46px;
  pointer-events: none;
  z-index: 20;
  background: linear-gradient(to top, rgba(241, 241, 245, .96), rgba(241, 241, 245, 0));
}

.tool-card.modules { margin-top: 10px; }

/* detail sheets */
.cluster { padding: 12px 0; border-top: 1px solid var(--line); }
.cluster:first-of-type { border-top: 0; }
.cluster-head { display: flex; align-items: baseline; justify-content: space-between; font-size: 11px; font-weight: 600; }
.cluster-head span { font-size: 9px; color: var(--muted); font-weight: 400; }
.range { width: 100%; margin: 12px 0 5px; -webkit-appearance: none; appearance: none; height: 4px; border-radius: 4px; background: rgba(60, 60, 67, .12); outline: none; }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 2px solid var(--orange); box-shadow: 0 2px 6px rgba(0, 0, 0, .16); }
.range-meta { display: flex; justify-content: space-between; font-size: 8px; color: var(--tertiary); }

.table-head, .table-row { display: grid; grid-template-columns: 1fr 42px 52px 44px; gap: 6px; align-items: center; }
.table-head { font-size: 8px; color: var(--tertiary); padding: 4px 0 6px; border-bottom: 1px solid var(--line); }
.table-head span:not(:first-child) { text-align: right; }
.table-row { min-height: 37px; border-bottom: 1px solid var(--line); font-size: 9px; }
.table-row > b { font-size: 9.5px; font-weight: 500; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.table-row > span { text-align: right; color: var(--muted); font-variant-numeric: tabular-nums; }

.detail-stats { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 8px; }
.detail-stats > div { background: rgba(118, 118, 128, .06); border-radius: 12px; padding: 9px 10px; }
.detail-stats em { font-style: normal; font-size: 8px; color: var(--tertiary); display: block; }
.detail-stats b { font-size: 18px; font-weight: 600; font-variant-numeric: tabular-nums; }
.detail-stats span { font-size: 8px; color: var(--muted); }
.sheet-chart { height: 112px; margin: 10px 0 4px; }
.scenario-row { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-top: 1px solid var(--line); font-size: 9px; }
.scenario-row:first-of-type { border-top: 0; }
.scenario-row b { width: 54px; font-weight: 600; }
.scenario-row span { color: var(--muted); }
.scenario-row em { margin-left: auto; font-style: normal; color: var(--tertiary); font-size: 8.5px; }

html.no-anim .sheet, html.no-anim .scrim { transition: none !important; }
