:root {
  --bg: #f5f5f7; --card: #ffffff; --ink: #1d1d1f; --ink2: #6e6e73; --ink3: #86868b; --line: #e5e5ea; --line2: #f0f0f2;
  --accent: #0071e3; --accent-soft: #e8f1fd; --good: #1a8a3a; --good-soft: #e6f6ea; --bad: #d70015; --bad-soft: #fdecee;
  --warn: #b25000; --warn-soft: #fff4e5; --chart-spend: #8e8e93; --chart-rev: #0071e3; --chart-profit: #34c759; --chart-loss: #ff3b30;
  --radius: 18px; --shadow: 0 1px 2px rgba(0,0,0,.04), 0 4px 16px rgba(0,0,0,.04);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', Roboto, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #000; --card: #1c1c1e; --ink: #f5f5f7; --ink2: #a1a1a6; --ink3: #8e8e93; --line: #38383a; --line2: #2c2c2e;
    --accent: #2997ff; --accent-soft: #0b2a4a; --good: #30d158; --good-soft: #0f2e18; --bad: #ff453a; --bad-soft: #3a1210;
    --warn: #ff9f0a; --warn-soft: #3a2608; --chart-spend: #636366; --chart-rev: #2997ff; --shadow: none;
  }
}
:root[data-theme="dark"] {
  --bg: #000; --card: #1c1c1e; --ink: #f5f5f7; --ink2: #a1a1a6; --ink3: #8e8e93; --line: #38383a; --line2: #2c2c2e;
  --accent: #2997ff; --accent-soft: #0b2a4a; --good: #30d158; --good-soft: #0f2e18; --bad: #ff453a; --bad-soft: #3a1210;
  --warn: #ff9f0a; --warn-soft: #3a2608; --chart-spend: #636366; --chart-rev: #2997ff; --shadow: none;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 15px; line-height: 1.45; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--accent); text-decoration: none; }
.num { font-variant-numeric: tabular-nums; }
.muted { color: var(--ink2); }
.small { font-size: 13px; }
.good { color: var(--good); } .bad { color: var(--bad); } .warn { color: var(--warn); }

/* boot / login */
.boot { min-height: 100vh; display: grid; place-items: center; }
.spinner { width: 28px; height: 28px; border-radius: 50%; border: 3px solid var(--line); border-top-color: var(--accent); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px 16px; }
.login-card { width: 100%; max-width: 380px; text-align: center; }
.login-card .logo { width: 56px; height: 56px; margin: 0 auto 20px; border-radius: 14px; background: var(--accent); display: grid; place-items: center; }
.login-card h1 { font-size: 30px; font-weight: 700; letter-spacing: -.02em; margin: 0 0 6px; }
.login-card p { margin: 0 0 28px; color: var(--ink2); }
.field { display: block; text-align: left; margin-bottom: 12px; }
.field span { display: block; font-size: 13px; color: var(--ink2); margin: 0 0 6px 2px; }
.input, select.input { width: 100%; height: 44px; padding: 0 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); outline: none; transition: border-color .15s, box-shadow .15s; }
.input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft); }
.input.sm { height: 34px; border-radius: 9px; padding: 0 10px; font-size: 14px; }
.btn { height: 40px; padding: 0 18px; border-radius: 980px; border: 0; background: var(--accent); color: #fff; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; justify-content: center; white-space: nowrap; transition: filter .15s, opacity .15s; }
.btn:hover { filter: brightness(1.08); }
.btn:disabled { opacity: .5; cursor: default; }
.btn.block { width: 100%; height: 46px; margin-top: 8px; font-size: 16px; }
.btn.ghost { background: transparent; color: var(--accent); }
.btn.ghost:hover { background: var(--accent-soft); filter: none; }
.btn.light { background: var(--line2); color: var(--ink); }
.btn.danger { background: transparent; color: var(--bad); }
.btn.danger:hover { background: var(--bad-soft); filter: none; }
.btn.sm { height: 32px; padding: 0 12px; font-size: 13px; }
.err { color: var(--bad); font-size: 14px; min-height: 20px; margin-top: 10px; }

/* layout */
.top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); border-bottom: 1px solid var(--line); }
.top-in { max-width: 1240px; margin: 0 auto; padding: 0 24px; height: 56px; display: flex; align-items: center; gap: 20px; }
.brand { font-weight: 700; letter-spacing: -.01em; display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.brand i { width: 26px; height: 26px; border-radius: 7px; background: var(--accent); display: grid; place-items: center; }
.nav { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; flex: 1; }
.nav::-webkit-scrollbar { display: none; }
.nav button { border: 0; background: none; padding: 7px 13px; border-radius: 980px; cursor: pointer; color: var(--ink2); font-weight: 500; white-space: nowrap; }
.nav button:hover { color: var(--ink); }
.nav button.on { background: var(--ink); color: var(--bg); }
.who { position: relative; }
.avatar { width: 32px; height: 32px; border-radius: 50%; border: 0; background: var(--line); font-weight: 600; cursor: pointer; }
.menu { position: absolute; right: 0; top: 40px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 10px 40px rgba(0,0,0,.12); min-width: 220px; padding: 6px; display: none; }
.menu.open { display: block; }
.menu .hd { padding: 10px 12px 8px; border-bottom: 1px solid var(--line); margin-bottom: 4px; }
.menu button { display: block; width: 100%; text-align: left; border: 0; background: none; padding: 9px 12px; border-radius: 9px; cursor: pointer; }
.menu button:hover { background: var(--line2); }
main { max-width: 1240px; margin: 0 auto; padding: 28px 24px 80px; }
.page-hd { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 22px; }
.page-hd h1 { font-size: 34px; letter-spacing: -.025em; font-weight: 700; margin: 0; line-height: 1.1; }
.page-hd .sub { color: var(--ink2); margin-top: 6px; }
.controls { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.seg { display: inline-flex; background: var(--line2); border-radius: 10px; padding: 2px; overflow-x: auto; max-width: 100%; }
.seg button { border: 0; background: none; padding: 6px 12px; border-radius: 8px; cursor: pointer; font-size: 14px; color: var(--ink); white-space: nowrap; }
.seg button.on { background: var(--card); box-shadow: 0 1px 3px rgba(0,0,0,.12); font-weight: 600; }
.dates { display: inline-flex; align-items: center; gap: 6px; }
.dates input { height: 34px; border-radius: 9px; border: 1px solid var(--line); background: var(--card); padding: 0 8px; }
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 20px; }
.filters select { height: 34px; border-radius: 980px; border: 1px solid var(--line); background: var(--card); padding: 0 30px 0 14px; appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%2386868b' fill='none' stroke-width='1.5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; cursor: pointer; }
.filters select.set { border-color: var(--accent); color: var(--accent); }
.status { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--ink2); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--good); flex: none; }
.dot.warn { background: var(--warn); } .dot.bad { background: var(--bad); }

/* cards */
.grid { display: grid; gap: 16px; }
.kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px 22px; min-width: 0; }
.card h2 { font-size: 19px; font-weight: 600; letter-spacing: -.01em; margin: 0 0 4px; }
.card .hint { color: var(--ink2); font-size: 13px; margin: 0 0 14px; }
.card-hd { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.kpi .label { color: var(--ink2); font-size: 13px; font-weight: 500; }
.kpi .value { font-size: 28px; font-weight: 700; letter-spacing: -.02em; margin: 6px 0 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.kpi.hero { grid-column: span 2; background: linear-gradient(135deg, var(--card), var(--card)); }
.kpi.hero .value { font-size: 44px; }
.delta { font-size: 13px; font-weight: 600; display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 980px; }
.delta.up { color: var(--good); background: var(--good-soft); }
.delta.down { color: var(--bad); background: var(--bad-soft); }
.delta.flat { color: var(--ink2); background: var(--line2); }
.kpi .foot { color: var(--ink3); font-size: 12px; margin-top: 6px; }
.two { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); margin-top: 16px; }
.cols2 { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 16px; }

/* chart */
.chart { width: 100%; height: 260px; display: block; }
.chart text { fill: var(--ink3); font-size: 11px; font-family: var(--font); }
.chart .grid-l { stroke: var(--line2); }
.legend { display: flex; gap: 16px; flex-wrap: wrap; font-size: 13px; color: var(--ink2); }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.tip { position: fixed; pointer-events: none; background: var(--ink); color: var(--bg); border-radius: 10px; padding: 8px 12px; font-size: 13px; z-index: 50; display: none; white-space: nowrap; }

/* insights */
.ins { list-style: none; margin: 0; padding: 0; }
.ins li { display: flex; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line2); }
.ins li:first-child { border-top: 0; padding-top: 2px; }
.ins .ic { width: 28px; height: 28px; border-radius: 8px; flex: none; display: grid; place-items: center; font-size: 14px; }
.ins .ic.bad { background: var(--bad-soft); } .ins .ic.good { background: var(--good-soft); } .ins .ic.warn { background: var(--warn-soft); } .ins .ic.info { background: var(--accent-soft); }

/* tables */
.tbl-wrap { overflow-x: auto; margin: 0 -22px; padding: 0 22px; }
table.t { width: 100%; border-collapse: collapse; font-size: 14px; }
.t th { text-align: right; font-weight: 500; color: var(--ink2); font-size: 12px; padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; cursor: pointer; user-select: none; position: sticky; top: 0; background: var(--card); }
.t th:first-child, .t td:first-child { text-align: left; padding-left: 0; }
.t th.sorted { color: var(--ink); }
.t td { text-align: right; padding: 11px 10px; border-bottom: 1px solid var(--line2); white-space: nowrap; font-variant-numeric: tabular-nums; }
.t tr:last-child td { border-bottom: 0; }
.t tbody tr:hover td { background: var(--line2); }
.t tfoot td { font-weight: 700; border-top: 1px solid var(--line); border-bottom: 0; }
.t td.name { font-weight: 500; max-width: 320px; overflow: hidden; text-overflow: ellipsis; }
.t tr.click { cursor: pointer; }
.bar { height: 6px; border-radius: 3px; background: var(--line2); min-width: 60px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--accent); border-radius: 3px; }
.pill { display: inline-block; padding: 2px 9px; border-radius: 980px; font-size: 12px; font-weight: 600; background: var(--line2); color: var(--ink2); }
.pill.good { background: var(--good-soft); color: var(--good); } .pill.bad { background: var(--bad-soft); color: var(--bad); } .pill.warn { background: var(--warn-soft); color: var(--warn); } .pill.blue { background: var(--accent-soft); color: var(--accent); }
.heat td.cell { min-width: 96px; }
.empty { text-align: center; color: var(--ink2); padding: 48px 16px; }
.empty b { display: block; font-size: 17px; color: var(--ink); margin-bottom: 6px; }

/* admin */
.subnav { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 20px; }
.subnav button { border: 1px solid var(--line); background: var(--card); border-radius: 980px; padding: 7px 14px; cursor: pointer; font-weight: 500; }
.subnav button.on { border-color: var(--ink); background: var(--ink); color: var(--bg); }
.subnav .badge { display: inline-block; min-width: 18px; padding: 0 5px; border-radius: 9px; background: var(--bad); color: #fff; font-size: 11px; margin-left: 6px; line-height: 18px; text-align: center; }
.rows .row { display: grid; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line2); }
.rows .row:last-child { border-bottom: 0; }
.rows .row.hd { color: var(--ink2); font-size: 12px; padding-top: 0; }
.prod-row { grid-template-columns: minmax(160px, 1.2fr) minmax(200px, 2fr) auto auto; }
.acc-row { grid-template-columns: minmax(200px, 2fr) minmax(150px, 1.2fr) 140px 140px minmax(90px, .8fr) auto; }
.kw { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; min-height: 34px; padding: 3px 6px; border: 1px solid var(--line); border-radius: 9px; background: var(--card); }
.kw span { background: var(--accent-soft); color: var(--accent); border-radius: 6px; padding: 2px 4px 2px 8px; font-size: 13px; display: inline-flex; align-items: center; gap: 2px; }
.kw span button { border: 0; background: none; color: inherit; cursor: pointer; padding: 0 4px; font-size: 14px; line-height: 1; }
.kw input { border: 0; outline: none; background: none; flex: 1; min-width: 80px; height: 26px; font-size: 14px; }
.actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 16px; flex-wrap: wrap; }
.check { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; margin: 4px 14px 4px 0; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); }
.secret-row { display: grid; grid-template-columns: 200px minmax(0, 1fr) 150px; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line2); }
.modal-bg { position: fixed; inset: 0; background: rgba(0,0,0,.35); display: grid; place-items: center; z-index: 60; padding: 16px; }
.modal { background: var(--card); border-radius: 22px; width: 100%; max-width: 560px; max-height: 90vh; overflow: auto; padding: 26px; box-shadow: 0 20px 60px rgba(0,0,0,.25); }
.modal h2 { margin: 0 0 16px; font-size: 22px; letter-spacing: -.01em; }
.box { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; max-height: 180px; overflow: auto; }
.toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(20px); background: var(--ink); color: var(--bg); padding: 12px 18px; border-radius: 14px; font-size: 14px; opacity: 0; pointer-events: none; transition: all .25s; z-index: 70; max-width: calc(100vw - 32px); }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.bad { background: var(--bad); color: #fff; }
.note { background: var(--warn-soft); color: var(--warn); border-radius: 12px; padding: 12px 14px; font-size: 14px; margin-bottom: 16px; }
.note.info { background: var(--accent-soft); color: var(--accent); }

@media (max-width: 1000px) {
  .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .two, .cols2 { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 720px) {
  .top-in { padding: 0 16px; gap: 10px; }
  .brand span { display: none; }
  main { padding: 20px 16px 60px; }
  .page-hd h1 { font-size: 28px; }
  .kpi .value { font-size: 22px; }
  .kpi.hero .value { font-size: 32px; }
  .card { padding: 16px; }
  .tbl-wrap { margin: 0 -16px; padding: 0 16px; }
  .prod-row, .acc-row, .secret-row { grid-template-columns: minmax(0, 1fr); }
  .rows .row.hd { display: none; }
}

/* ---------------------------------------------------------------- v2: clearer, phone-first refinements */
:root { --line: var(--line2); }
.headline { font-size: 19px; line-height: 1.5; letter-spacing: -.01em; margin: -6px 0 20px; color: var(--ink); max-width: 900px; }
.headline b { font-weight: 600; }
.iconbtn { width: 34px; height: 34px; border-radius: 50%; border: 0; background: transparent; color: var(--ink2); display: grid; place-items: center; cursor: pointer; flex: none; transition: background .15s, color .15s; }
.iconbtn:hover { background: var(--line2); color: var(--ink); }
.nbadge { display: inline-block; min-width: 17px; height: 17px; line-height: 17px; padding: 0 5px; margin-left: 6px; border-radius: 9px; background: var(--bad); color: #fff; font-size: 11px; font-weight: 600; text-align: center; vertical-align: 1px; }

/* KPI cards: number + sparkline, formula hint, gentle hover */
.card { transition: transform .2s ease, box-shadow .2s ease; }
.kpi:hover, .grid.cols2 > .card:hover, .grid.two > .card:hover { transform: translateY(-2px); box-shadow: 0 2px 4px rgba(0,0,0,.04), 0 12px 32px rgba(0,0,0,.08); }
.kpi .label { display: flex; align-items: center; gap: 4px; }
.kinfo { border: 0; background: none; padding: 2px; margin: -2px 0; color: var(--ink3); cursor: pointer; display: inline-grid; place-items: center; border-radius: 50%; }
.kinfo:hover { color: var(--accent); background: var(--accent-soft); }
.kpi-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; }
.kpi-row .value { min-width: 0; }
.spark { width: 96px; height: 32px; flex: none; margin-bottom: 10px; overflow: visible; }
.kpi.hero .spark { width: 45%; max-width: 260px; height: 56px; }
.t tbody tr { transition: background .12s; }
.btn, .seg button, .nav button, .subnav button { transition: background .15s, color .15s, box-shadow .15s, transform .1s; }
.btn:active, .seg button:active, .tabbar button:active { transform: scale(.97); }
#view { animation: fadeUp .28s ease both; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { #view { animation: none; } .card, .btn { transition: none; } .kpi:hover { transform: none; } }

/* Loading skeleton instead of a spinner */
.sk, .sk-line { background: linear-gradient(90deg, var(--line2) 25%, var(--card) 50%, var(--line2) 75%); background-size: 200% 100%; animation: shimmer 1.3s ease-in-out infinite; border-radius: var(--radius); }
.sk-line { border-radius: 8px; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

/* Phone sort selector (hidden on desktop where headers sort) */
.msort { display: none; font-size: 13px; color: var(--ink2); margin-bottom: 10px; align-items: center; gap: 8px; }
.msort select { height: 32px; border-radius: 9px; border: 1px solid var(--line); background: var(--card); padding: 0 8px; }

/* Bottom tab bar (phones) */
.tabbar { display: none; }

@media (max-width: 720px) {
  .top .nav { display: none; }
  .top-in { height: 52px; justify-content: space-between; }
  .brand span { display: inline; font-size: 16px; }
  .tabbar { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 6px 4px calc(6px + env(safe-area-inset-bottom)); background: color-mix(in srgb, var(--card) 80%, transparent); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); border-top: 1px solid var(--line); }
  .tabbar button { flex: 1; border: 0; background: none; color: var(--ink3); display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 11px; font-weight: 500; padding: 4px 0; cursor: pointer; position: relative; }
  .tabbar button.on { color: var(--accent); }
  .tabbar .nbadge { position: absolute; top: 0; left: 50%; margin-left: 6px; }
  main { padding-bottom: calc(96px + env(safe-area-inset-bottom)); }
  .toast { bottom: calc(84px + env(safe-area-inset-bottom)); }
  .page-hd { margin-bottom: 14px; }
  .page-hd .controls { width: 100%; justify-content: space-between; }
  .filters { position: sticky; top: 52px; z-index: 15; margin: 0 -16px 16px; padding: 10px 16px; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .filters::-webkit-scrollbar { display: none; }
  .filters .seg { flex: none; overflow: visible; }
  .filters select { flex: none; max-width: 170px; }
  .headline { font-size: 17px; margin: 0 0 16px; }
  .kpis { gap: 10px; }
  .kpi.hero .value { font-size: 34px; }
  .kpi .value { font-size: 21px; }
  .spark { width: 64px; height: 26px; }
  .kpi.hero .kpi-row { flex-direction: column; align-items: stretch; gap: 2px; }
  .kpi.hero .value { overflow: visible; }
  .kpi.hero .spark { width: 100%; max-width: none; height: 40px; margin: 2px 0 8px; }
  .kpi .foot { font-size: 11px; }
  .kpi:hover, .grid.cols2 > .card:hover, .grid.two > .card:hover { transform: none; box-shadow: var(--shadow); }
  .chart { height: 200px; }
  .barcol { display: none; }
  /* Wide tables become a list of cards: name on top, key figures as label / value rows */
  .msort { display: flex; }
  .tbl-wrap:has(table.cards) { margin: 0; padding: 0; overflow: visible; }
  table.cards, table.cards tbody, table.cards tfoot { display: block; }
  table.cards thead { display: none; }
  table.cards tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); box-sizing: border-box; width: 100%; gap: 2px 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
  table.cards tbody tr:hover td { background: none; }
  table.cards td { display: flex; justify-content: space-between; gap: 6px; min-width: 0; flex-wrap: wrap; padding: 3px 0; border: 0; font-size: 14px; text-align: right; }
  table.cards td::before { content: attr(data-label); color: var(--ink2); font-size: 12px; text-align: left; }
  table.cards td.name { grid-column: 1 / -1; font-size: 16px; font-weight: 600; padding: 0 0 6px; max-width: none; white-space: normal; }
  table.cards td.name::before { content: none; }
  table.cards td.xtra { display: none; }
  table.cards tfoot td { font-size: 13px; }
  table.cards tfoot tr { border-bottom: 0; background: var(--line2); border-radius: 12px; padding: 12px; margin-top: 8px; }
}
@media (max-width: 380px) { table.cards tr { grid-template-columns: 1fr; } }

/* iOS-style switch (alert settings) */
.switch { appearance: none; -webkit-appearance: none; width: 44px; height: 26px; border-radius: 13px; background: var(--line); position: relative; cursor: pointer; flex: none; margin: 2px 0 0; transition: background .2s; }
.switch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.25); transition: transform .2s; }
.switch:checked { background: var(--good); }
.switch:checked::after { transform: translateX(18px); }
.switch:disabled { opacity: .6; cursor: default; }
