:root {
  --bg: #F2F4F7;
  --card: #FFFFFF;
  --card-2: #F8FAFC;
  --text: #1B2432;
  --text-2: #6B7789;
  --text-3: #9AA5B5;
  --line: #E5E9F0;
  --primary: #2E5C9A;
  --primary-l: #E8F0FB;
  --up: #C0392B;
  --down: #1E7B4D;
  --warn: #E8A33D;
  --shadow: 0 2px 10px rgba(24, 40, 72, .07);
  --shadow-lg: 0 8px 32px rgba(24, 40, 72, .16);
  --radius: 16px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --header-h: 56px;
  --tab-h: 56px;
  --c1: #2E5C9A;
  --c2: #3EB575;
  --c3: #E8A33D;
  --c4: #C0392B;
  --c5: #8E5BB5;
  --c6: #2AA0A8;
  --c7: #E06C9F;
  --c8: #7D8FA9;
  --c9: #6B8E23;
}

html[data-theme="dark"] {
  --bg: #12161D;
  --card: #1C222C;
  --card-2: #232A36;
  --text: #E9EEF6;
  --text-2: #98A4B6;
  --text-3: #6C7788;
  --line: #2C3543;
  --primary: #5B8FD6;
  --primary-l: #1E2A3C;
  --up: #E5544A;
  --down: #2FA96B;
  --shadow: 0 2px 10px rgba(0, 0, 0, .35);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, .5);
}

* { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

body {
  font-family: "PingFang SC", "Microsoft YaHei", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  font-size: 14px;
  line-height: 1.5;
  overscroll-behavior-y: none;
  transition: background .25s, color .25s;
}

#app {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  background: var(--bg);
  position: relative;
  box-shadow: 0 0 40px rgba(0, 0, 0, .06);
}

@media (min-width: 900px) {
  #app { max-width: 460px; }
  body { background: #E4E9F0; }
  html[data-theme="dark"] body { background: #0A0D12; }
}

/* ============ 顶栏 ============ */
.topbar {
  position: sticky; top: 0; z-index: 60;
  height: var(--header-h);
  display: flex; align-items: center; gap: 8px;
  padding: 0 14px;
  background: var(--card);
  border-bottom: 1px solid var(--line);
}
.topbar.plain { border-bottom: none; }
.topbar .tb-title { font-size: 17px; font-weight: 700; flex: 1; }
.topbar .tb-sub { font-size: 11px; color: var(--text-3); font-weight: 400; margin-left: 6px; }
.icon-btn {
  width: 34px; height: 34px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  background: var(--card-2); border: none; cursor: pointer;
  color: var(--text-2); font-size: 17px; flex: 0 0 auto;
  transition: background .15s, transform .1s;
}
.icon-btn:active { transform: scale(.92); }
.icon-btn:hover { background: var(--primary-l); color: var(--primary); }

/* ============ 页面容器 ============ */
.page { padding: 12px 14px calc(var(--tab-h) + var(--safe-b) + 24px); display: none; animation: fade .22s ease; }
.page.active { display: block; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.card {
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 16px; margin-bottom: 12px;
}
.card.tight { padding: 12px 14px; }
.card-h { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.card-h h3 { font-size: 14.5px; font-weight: 700; }
.card-h .more { font-size: 12px; color: var(--text-3); background: none; border: none; cursor: pointer; }

.sec-title { font-size: 12.5px; font-weight: 700; color: var(--text-2); margin: 16px 4px 8px; letter-spacing: .3px; }

/* ============ 圆环进度 ============ */
.hero {
  background: linear-gradient(135deg, #2E5C9A 0%, #1F4478 55%, #16335C 100%);
  border-radius: 20px; padding: 20px; color: #fff;
  box-shadow: 0 10px 28px rgba(31, 68, 120, .32);
  margin-bottom: 14px; position: relative; overflow: hidden;
}
.hero::after {
  content: ""; position: absolute; width: 200px; height: 200px; right: -70px; top: -90px;
  background: radial-gradient(circle, rgba(255,255,255,.14), transparent 68%); border-radius: 50%;
}
.hero .h-top { display: flex; justify-content: space-between; align-items: flex-start; position: relative; z-index: 1; }
.hero .h-label { font-size: 12px; opacity: .8; }
.hero .h-balance { font-size: 33px; font-weight: 800; letter-spacing: -.5px; margin: 4px 0 2px; font-variant-numeric: tabular-nums; }
.hero .h-meta { font-size: 11.5px; opacity: .72; }
.hero .h-ring { position: relative; width: 72px; height: 72px; flex: 0 0 auto; }
.hero .h-ring text { font-size: 15px; font-weight: 800; fill: #fff; }
.hero .h-ring .sub { font-size: 8px; fill: rgba(255,255,255,.75); font-weight: 400; }
.hero .h-stats { display: flex; gap: 22px; margin-top: 16px; padding-top: 14px; border-top: 1px solid rgba(255,255,255,.18); position: relative; z-index: 1; }
.hero .h-stats .s-label { font-size: 11px; opacity: .72; }
.hero .h-stats .s-val { font-size: 16.5px; font-weight: 700; font-variant-numeric: tabular-nums; }

/* ============ 记账表单 ============ */
.type-switch {
  display: flex; background: var(--card-2); border-radius: 12px; padding: 3px;
  margin-bottom: 16px; border: 1px solid var(--line);
}
.type-switch button {
  flex: 1; padding: 9px 0; border: none; background: none; border-radius: 9px;
  font-size: 14px; font-weight: 600; color: var(--text-2); cursor: pointer;
  font-family: inherit; transition: all .18s;
}
.type-switch button.on { background: var(--card); color: var(--text); box-shadow: var(--shadow); }
.type-switch button.on[data-type="expense"] { color: var(--down); }
.type-switch button.on[data-type="income"] { color: var(--up); }
.type-switch button.on[data-type="transfer"] { color: var(--primary); }

.amount-display {
  display: flex; align-items: baseline; justify-content: flex-end; gap: 8px;
  padding: 14px 4px 16px; border-bottom: 2px solid var(--line); margin-bottom: 16px;
}
.amount-display .cur { font-size: 21px; color: var(--text-3); font-weight: 600; }
.amount-display .val {
  font-size: 40px; font-weight: 800; font-variant-numeric: tabular-nums;
  letter-spacing: -1px; min-height: 48px; color: var(--text);
}
.amount-display .val.expense { color: var(--down); }
.amount-display .val.income { color: var(--up); }
.amount-display .val.transfer { color: var(--primary); }
.amount-display .val.ph { color: var(--text-3); font-size: 34px; font-weight: 500; }

.field { margin-bottom: 14px; }
.field label { display: block; font-size: 12px; color: var(--text-2); margin-bottom: 7px; font-weight: 600; }
.field input[type="text"], .field input[type="date"], .field input[type="number"], .field select, .field textarea {
  width: 100%; padding: 11px 13px; border: 1px solid var(--line); border-radius: 11px;
  background: var(--card-2); color: var(--text); font-size: 14.5px; font-family: inherit;
  outline: none; transition: border-color .15s, background .15s;
}
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--primary); background: var(--card); }
.field textarea { resize: none; min-height: 60px; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 8px 14px; border-radius: 20px; background: var(--card-2);
  border: 1px solid var(--line); font-size: 13px; color: var(--text-2);
  cursor: pointer; font-family: inherit; transition: all .15s; white-space: nowrap;
}
.chip:active { transform: scale(.95); }
.chip.on { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 600; }

.cat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 9px; }
.cat-item {
  display: flex; flex-direction: column; align-items: center; gap: 5px;
  padding: 11px 4px; border-radius: 13px; background: var(--card-2);
  border: 1.5px solid transparent; cursor: pointer; transition: all .15s;
}
.cat-item:active { transform: scale(.94); }
.cat-item.on { border-color: var(--primary); background: var(--primary-l); }
.cat-item .ci-ico {
  width: 38px; height: 38px; border-radius: 50%; display: flex;
  align-items: center; justify-content: center; font-size: 19px; background: var(--card);
}
.cat-item .ci-name { font-size: 11px; color: var(--text-2); font-weight: 600; }
.cat-item.on .ci-name { color: var(--primary); }

/* ============ 数字键盘 ============ */
.keypad {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px;
  background: var(--line); border-radius: 14px; overflow: hidden;
  margin-top: 12px; user-select: none;
}
.keypad button {
  padding: 17px 0; border: none; background: var(--card); font-size: 21px;
  font-weight: 600; color: var(--text); cursor: pointer; font-family: inherit;
  transition: background .1s;
}
.keypad button:active { background: var(--primary-l); }
.keypad button.fn { font-size: 16px; color: var(--text-2); background: var(--card-2); }
.keypad button.ok { background: var(--primary); color: #fff; font-size: 16px; }
.keypad button.ok:active { background: #1F4478; }

/* ============ 账单列表 ============ */
.rec-group { margin-bottom: 6px; }
.rec-day {
  display: flex; justify-content: space-between; align-items: baseline;
  padding: 9px 4px 6px; font-size: 12px; color: var(--text-3); font-weight: 600;
}
.rec-day .d-sum { font-size: 11.5px; }
.rec-day .d-sum b { font-weight: 700; }
.rec-list { background: var(--card); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.rec-item {
  display: flex; align-items: center; gap: 11px; padding: 12px 14px;
  border-bottom: 1px solid var(--line); cursor: pointer; transition: background .12s;
}
.rec-item:last-child { border-bottom: none; }
.rec-item:active { background: var(--card-2); }
.rec-ico {
  width: 40px; height: 40px; border-radius: 12px; display: flex;
  align-items: center; justify-content: center; font-size: 19px; flex: 0 0 auto;
  background: var(--card-2);
}
.rec-main { flex: 1; min-width: 0; }
.rec-main .r-t { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 5px; }
.rec-main .r-s { font-size: 11.5px; color: var(--text-3); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rec-amt { font-size: 15.5px; font-weight: 700; font-variant-numeric: tabular-nums; text-align: right; flex: 0 0 auto; }
.rec-amt.expense { color: var(--down); }
.rec-amt.income { color: var(--up); }
.rec-amt.transfer { color: var(--text-2); font-size: 14.5px; }

.badge {
  display: inline-block; font-size: 9.5px; padding: 1px 6px; border-radius: 6px;
  font-weight: 600; vertical-align: middle; line-height: 1.6;
}
.badge.tag { background: var(--card-2); color: var(--text-3); }
.badge.reim { background: #FFF3D6; color: #A8750F; }
.badge.reim.done { background: #E1F1E8; color: var(--down); }

/* ============ 工具栏 / 筛选 ============ */
.toolbar { display: flex; gap: 8px; margin-bottom: 12px; }
.search-box {
  flex: 1; display: flex; align-items: center; gap: 8px;
  background: var(--card); border-radius: 12px; padding: 0 12px;
  border: 1px solid var(--line); box-shadow: var(--shadow);
}
.search-box input { flex: 1; border: none; background: none; outline: none; padding: 11px 0; font-size: 14px; color: var(--text); font-family: inherit; }
.search-box .s-ico { color: var(--text-3); font-size: 15px; }

.month-bar { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.month-bar .m-nav {
  flex: 1; display: flex; align-items: center; justify-content: space-between;
  background: var(--card); border-radius: 12px; padding: 9px 12px; box-shadow: var(--shadow);
}
.month-bar .m-cur { font-size: 15px; font-weight: 700; }
.month-bar button {
  background: none; border: none; color: var(--text-2); font-size: 17px;
  cursor: pointer; padding: 2px 8px; border-radius: 8px;
}
.month-bar button:hover { background: var(--primary-l); color: var(--primary); }

.mini-stats { display: flex; gap: 10px; margin-bottom: 12px; }
.mini-stat {
  flex: 1; background: var(--card); border-radius: 13px; padding: 11px 13px;
  box-shadow: var(--shadow);
}
.mini-stat .ms-l { font-size: 11px; color: var(--text-3); }
.mini-stat .ms-v { font-size: 17px; font-weight: 800; margin-top: 3px; font-variant-numeric: tabular-nums; }
.mini-stat .ms-v.expense { color: var(--down); }
.mini-stat .ms-v.income { color: var(--up); }

/* ============ 图表 ============ */
.bar-row { display: flex; align-items: center; gap: 10px; margin-bottom: 11px; }
.bar-row .b-name { width: 62px; font-size: 12.5px; font-weight: 600; flex: 0 0 auto; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bar-row .b-track { flex: 1; height: 22px; background: var(--card-2); border-radius: 6px; overflow: hidden; position: relative; }
.bar-row .b-fill { height: 100%; border-radius: 6px; transition: width .5s cubic-bezier(.22,1,.36,1); }
.bar-row .b-val { width: 76px; text-align: right; font-size: 12.5px; font-weight: 700; font-variant-numeric: tabular-nums; flex: 0 0 auto; }
.bar-row .b-pct { width: 44px; text-align: right; font-size: 11px; color: var(--text-3); flex: 0 0 auto; }
.bar-row .b-name { display: flex; align-items: center; gap: 4px; }

.col-chart { display: flex; align-items: flex-end; gap: 6px; height: 160px; padding: 10px 0 0; }
.col-group { flex: 1; display: flex; flex-direction: column; align-items: center; height: 100%; gap: 4px; }
.col-bars { flex: 1; display: flex; align-items: flex-end; gap: 2px; width: 100%; justify-content: center; }
.col-bars .cb { width: 8px; border-radius: 3px 3px 0 0; min-height: 2px; transition: height .55s cubic-bezier(.22,1,.36,1); }
.col-bars .cb.in { background: var(--up); }
.col-bars .cb.out { background: var(--down); }
.col-lbl { font-size: 10px; color: var(--text-3); }

.legend { display: flex; gap: 14px; justify-content: center; margin-top: 10px; font-size: 11.5px; color: var(--text-2); }
.legend i { display: inline-block; width: 9px; height: 9px; border-radius: 2px; margin-right: 4px; vertical-align: middle; }

/* 环形图 */
.donut-wrap { display: flex; align-items: center; gap: 16px; }
.donut { width: 130px; height: 130px; flex: 0 0 auto; position: relative; }
.donut .d-center {
  position: absolute; inset: 0; display: flex; flex-direction: column;
  align-items: center; justify-content: center;
}
.donut .d-center .dc-l { font-size: 10px; color: var(--text-3); }
.donut .d-center .dc-v { font-size: 15px; font-weight: 800; font-variant-numeric: tabular-nums; }

/* ============ 预算 ============ */
.budget-item { margin-bottom: 15px; }
.budget-item .bi-h { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; font-size: 13px; }
.budget-item .bi-h .bn { font-weight: 600; display: flex; align-items: center; gap: 5px; }
.budget-item .bi-h .bv { font-size: 12px; color: var(--text-2); font-variant-numeric: tabular-nums; }
.budget-track { height: 9px; background: var(--card-2); border-radius: 5px; overflow: hidden; }
.budget-fill { height: 100%; border-radius: 5px; transition: width .5s cubic-bezier(.22,1,.36,1); }
.budget-fill.ok { background: var(--down); }
.budget-fill.warn { background: var(--warn); }
.budget-fill.over { background: var(--up); }

.pill { font-size: 10.5px; padding: 1.5px 8px; border-radius: 8px; font-weight: 700; }
.pill.ok { background: #E1F1E8; color: var(--down); }
.pill.warn { background: #FDF3E0; color: #A8750F; }
.pill.over { background: #FBE3E0; color: var(--up); }
html[data-theme="dark"] .pill.ok { background: #17311F; }
html[data-theme="dark"] .pill.warn { background: #33280F; }
html[data-theme="dark"] .pill.over { background: #3A1D1A; }

/* ============ 账户 ============ */
.acc-item {
  display: flex; align-items: center; gap: 12px; padding: 13px 0;
  border-bottom: 1px solid var(--line);
}
.acc-item:last-child { border-bottom: none; }
.acc-dot { width: 38px; height: 38px; border-radius: 11px; display: flex; align-items: center; justify-content: center; font-size: 17px; color: #fff; flex: 0 0 auto; }
.acc-main { flex: 1; min-width: 0; }
.acc-main .a-n { font-size: 14px; font-weight: 600; }
.acc-main .a-t { font-size: 11.5px; color: var(--text-3); margin-top: 1px; }
.acc-bal { font-size: 15.5px; font-weight: 700; font-variant-numeric: tabular-nums; }
.acc-bal.neg { color: var(--down); }

/* ============ 债务 ============ */
.debt-item { padding: 13px 0; border-bottom: 1px solid var(--line); }
.debt-item:last-child { border-bottom: none; }
.debt-h { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; }
.debt-h .dn { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 6px; }
.debt-h .dv { font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; }
.debt-meta { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--text-3); margin-bottom: 8px; }

/* ============ 底部导航 ============ */
.tabbar {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px; height: calc(var(--tab-h) + var(--safe-b));
  padding-bottom: var(--safe-b);
  background: color-mix(in srgb, var(--card) 92%, transparent);
  backdrop-filter: saturate(180%) blur(16px);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  border-top: 1px solid var(--line);
  display: flex; z-index: 70;
}
.tabbar .tab {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 3px; background: none; border: none; cursor: pointer; color: var(--text-3);
  font-family: inherit; font-size: 10.5px; font-weight: 600; transition: color .15s;
}
.tabbar .tab .t-ico { font-size: 20px; line-height: 1; transition: transform .18s; }
.tabbar .tab.on { color: var(--primary); }
.tabbar .tab.on .t-ico { transform: translateY(-1px) scale(1.1); }
.tabbar .tab.add .t-ico {
  width: 44px; height: 44px; border-radius: 50%; background: var(--primary); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 24px;
  box-shadow: 0 5px 16px rgba(46, 92, 154, .42); margin-top: -14px;
}

/* ============ 弹层 ============ */
.sheet-mask {
  position: fixed; inset: 0; background: rgba(12, 20, 34, .48);
  z-index: 100; display: none; align-items: flex-end; justify-content: center;
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}
.sheet-mask.on { display: flex; animation: maskIn .2s ease; touch-action: manipulation; }
@keyframes maskIn { from { opacity: 0; } to { opacity: 1; } }
.sheet {
  width: 100%; max-width: 480px; background: var(--card);
  border-radius: 22px 22px 0 0; max-height: 88vh; overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  /* 手机上防止内部滚动穿透到 body */
  overscroll-behavior: contain;
  animation: sheetUp .28s cubic-bezier(.22,1,.36,1);
  padding-bottom: calc(var(--safe-b) + 16px);
  pointer-events: auto;
}
@keyframes sheetUp { from { transform: translateY(100%); } to { transform: none; } }
.sheet-h {
  position: sticky; top: 0; background: var(--card); z-index: 2;
  padding: 16px 18px 12px; display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid var(--line); border-radius: 22px 22px 0 0;
  /* sticky 头部在部分移动浏览器会拦截触摸, 显式放开 */
  pointer-events: auto;
}
.sheet-h h3 { font-size: 16px; font-weight: 700; }
.sheet-b { padding: 16px 18px; }

/* 移动端: 扩大触摸目标, 提升点击可靠性 */
.list-row .icon-btn { min-width: 34px; min-height: 34px; }
.list-row { touch-action: manipulation; }
.chip, .cat-item, .keypad button, .btn, .tabbar .tab { touch-action: manipulation; }

.btn {
  width: 100%; padding: 13px; border: none; border-radius: 13px;
  font-size: 15px; font-weight: 700; font-family: inherit; cursor: pointer;
  transition: all .15s;
}
.btn:active { transform: scale(.98); }
.btn.primary { background: var(--primary); color: #fff; box-shadow: 0 4px 14px rgba(46, 92, 154, .3); }
.btn.ghost { background: var(--card-2); color: var(--text-2); border: 1px solid var(--line); }
.btn.danger { background: #FBE3E0; color: var(--up); }
html[data-theme="dark"] .btn.danger { background: #3A1D1A; }
.btn-row { display: flex; gap: 10px; margin-top: 12px; }

.list-row {
  display: flex; align-items: center; gap: 12px; padding: 14px 0;
  border-bottom: 1px solid var(--line); cursor: pointer;
}
.list-row:last-child { border-bottom: none; }
.list-row .lr-ico { width: 34px; height: 34px; border-radius: 10px; background: var(--card-2); display: flex; align-items: center; justify-content: center; font-size: 16px; }
.list-row .lr-t { flex: 1; font-size: 14px; font-weight: 600; }
.list-row .lr-v { font-size: 13px; color: var(--text-3); }
.list-row .lr-arrow { color: var(--text-3); font-size: 15px; }

.empty { text-align: center; padding: 44px 20px; color: var(--text-3); }
.empty .e-ico { font-size: 42px; margin-bottom: 10px; opacity: .5; }
.empty .e-t { font-size: 13.5px; }

/* 强化版空状态: 图标 + 主标题 + 说明 + 操作按钮 */
.empty-empty {
  text-align: center; padding: 52px 24px 48px;
  display: flex; flex-direction: column; align-items: center;
}
.empty-empty .ee-ico {
  width: 76px; height: 76px; border-radius: 24px;
  display: flex; align-items: center; justify-content: center;
  font-size: 34px; margin-bottom: 16px; opacity: .85;
  background: var(--card-2); box-shadow: 0 2px 10px rgba(0, 0, 0, .04);
}
.empty-empty .ee-t {
  font-size: 15.5px; font-weight: 700; color: var(--text-1); margin-bottom: 8px;
}
.empty-empty .ee-s {
  font-size: 12.5px; line-height: 1.7; color: var(--text-3); max-width: 260px;
}
.empty-empty .btn { width: 100%; }

.toast {
  position: fixed; bottom: calc(var(--tab-h) + var(--safe-b) + 22px); left: 50%;
  transform: translateX(-50%) translateY(16px);
  background: rgba(20, 28, 42, .93); color: #fff; padding: 10px 20px;
  border-radius: 22px; font-size: 13px; z-index: 300; opacity: 0;
  transition: all .25s; pointer-events: none; white-space: nowrap;
  backdrop-filter: blur(8px);
}
.toast.on { opacity: 1; transform: translateX(-50%) translateY(0); }

.switch { position: relative; width: 46px; height: 27px; flex: 0 0 auto; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .sl {
  position: absolute; inset: 0; background: var(--line); border-radius: 14px;
  cursor: pointer; transition: background .2s;
}
.switch .sl::before {
  content: ""; position: absolute; width: 21px; height: 21px; left: 3px; top: 3px;
  background: #fff; border-radius: 50%; transition: transform .2s; box-shadow: 0 1px 3px rgba(0,0,0,.2);
}
.switch input:checked + .sl { background: var(--primary); }
.switch input:checked + .sl::before { transform: translateX(19px); }

.grow { flex: 1; }
.mt8 { margin-top: 8px; }
.mt12 { margin-top: 12px; }
.text-2 { color: var(--text-2); }
.text-center { text-align: center; }
.nowrap { white-space: nowrap; }

::-webkit-scrollbar { width: 0; height: 0; }
