:root {
  --bg: #f3f4f8; --card: #ffffff; --ink: #0f172a; --muted: #6b7489; --line: #eceef4; --field: #f1f3f9;
  --acc: #5b5bd6; --acc2: #7c5cf0; --acc-soft: #ececfd;
  --ok: #12a05c; --ok-soft: #e3f6ec; --bad: #e0365a; --bad-soft: #fde8ed; --warn: #d98a0b; --warn-soft: #fdf1da; --info: #1e88d6; --info-soft: #e2f1fc;
  --r: 22px; --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px rgba(15, 23, 42, .06);
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #0b0f1a; --card: #141a2a; --ink: #e9edf7; --muted: #8b95ab; --line: #1f2740; --field: #1b2236;
    --acc: #8b8cf5; --acc2: #a58bff; --acc-soft: #23284a;
    --ok: #3ccf86; --ok-soft: #12311f; --bad: #ff6b8b; --bad-soft: #3a1620; --warn: #f3b13e; --warn-soft: #3a2b0e; --info: #5db6f5; --info-soft: #112b40;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 8px 24px rgba(0, 0, 0, .3); }
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.4 var(--font); -webkit-font-smoothing: antialiased; font-feature-settings: "tnum", "cv11"; }
body { padding-bottom: calc(112px + env(safe-area-inset-bottom)); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
b { font-weight: 600; }
.i { display: block; flex: none; }
.mut { color: var(--muted); } .ok { color: var(--ok); } .bad { color: var(--bad); } .warn { color: var(--warn); } .info { color: var(--info); }
.pos { color: var(--ok); } .neg { color: var(--bad); } .acc { color: var(--acc); }
em { font-style: normal; color: var(--muted); font-weight: 400; }

/* topo */
.top { position: sticky; top: 0; z-index: 5; display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: calc(10px + env(safe-area-inset-top)) 16px 10px; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.brand { display: flex; align-items: center; gap: 7px; font-weight: 700; font-size: 18px; letter-spacing: -.3px; color: var(--acc); }
.brand span:nth-child(2) { color: var(--ink); }
.dot { width: 7px; height: 7px; border-radius: 50%; background: #c3c8d4; margin-left: 0 !important; } .dot.ok { background: #34c77b; } .dot.busy { background: var(--warn); } .dot.err { background: var(--bad); }
.monthnav { display: flex; align-items: center; background: var(--card); border-radius: 99px; box-shadow: var(--shadow); padding: 3px; }
.monthnav button { background: none; border: 0; padding: 6px 8px; border-radius: 99px; color: var(--muted); display: grid; place-items: center; }
.monthnav .mlabel { font-weight: 600; font-size: 14px; color: var(--ink); min-width: 106px; padding: 6px 4px; }
.iconbtn { width: 38px; height: 38px; border-radius: 50%; border: 0; background: var(--card); box-shadow: var(--shadow); display: grid; place-items: center; color: var(--muted); }
.iconbtn.on { color: var(--acc); background: var(--acc-soft); }
main { max-width: 640px; margin: 0 auto; padding: 4px 16px 16px; animation: fade .25s ease; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } }
h2 { font-size: 17px; font-weight: 700; letter-spacing: -.2px; margin: 26px 2px 10px; }
h3 { font-size: 13px; font-weight: 600; margin: 0; flex: 1; color: var(--muted); text-transform: uppercase; letter-spacing: .6px; }
.lbl { font-size: 11px; font-weight: 500; color: var(--muted); letter-spacing: .3px; display: block; }
.hint { font-size: 13px; color: var(--muted); margin: 6px 0; }
.sub { font-size: 12.5px; color: var(--muted); }
.card { background: var(--card); border-radius: var(--r); padding: 16px; margin-bottom: 12px; box-shadow: var(--shadow); }
.card.soft { display: flex; gap: 10px; align-items: center; color: var(--muted); }
.bignum { font-size: 28px; font-weight: 700; letter-spacing: -.5px; }

/* hero */
.hero { margin-top: 6px; border-radius: 28px; padding: 20px 20px 16px; color: #fff; position: relative; overflow: hidden;
  background: radial-gradient(120% 90% at 100% 0%, #9b7dff 0%, transparent 55%), linear-gradient(135deg, #4a4ad0, #6a4de0); box-shadow: 0 14px 34px rgba(91, 91, 214, .35); }
.hero-top { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.hl { font-size: 13px; opacity: .8; font-weight: 500; }
.hnum { font-size: 36px; font-weight: 700; letter-spacing: -1px; line-height: 1.15; margin: 2px 0 8px; }
.hchip { display: inline-block; background: rgba(255, 255, 255, .18); border-radius: 99px; padding: 4px 11px; font-size: 12.5px; font-weight: 500; }
.ringw { position: relative; width: 78px; height: 78px; flex: none; } .ringw svg { width: 100%; height: 100%; }
.rbg { fill: none; stroke: rgba(255, 255, 255, .22); stroke-width: 7; } .rfg { fill: none; stroke: #fff; stroke-width: 7; stroke-linecap: round; transition: stroke-dasharray .7s ease; }
.ringw span { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; font-weight: 700; font-size: 20px; } .ringw small { font-size: 11px; font-weight: 500; opacity: .8; display: inline; }
.hbar { height: 5px; background: rgba(255, 255, 255, .22); border-radius: 3px; overflow: hidden; margin-top: 16px; } .hbar i { display: block; height: 100%; background: #fff; border-radius: 3px; transition: width .6s; }
.hfoot { display: flex; justify-content: space-between; font-size: 12px; opacity: .85; margin-top: 7px; }

.tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 12px 0; } .tiles.three { grid-template-columns: repeat(3, 1fr); }
.tile { background: var(--card); border-radius: 20px; padding: 14px; box-shadow: var(--shadow); min-width: 0; position: relative; }
.tile b { display: block; font-size: 19px; font-weight: 700; letter-spacing: -.4px; margin-top: 2px; white-space: nowrap; } .tile small { font-size: 11.5px; color: var(--muted); }
.three .tile { padding: 12px; } .three .tile b { font-size: 16px; }
.ti { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; margin-bottom: 8px; }
.ti.up { background: var(--ok-soft); color: var(--ok); } .ti.dn { background: var(--bad-soft); color: var(--bad); } .ti.wn { background: var(--warn-soft); color: var(--warn); } .ti.bl { background: var(--acc-soft); color: var(--acc); }
.perday { display: flex; align-items: center; justify-content: space-around; text-align: center; } .perday b { display: block; font-size: 24px; font-weight: 700; letter-spacing: -.5px; } .perday small { color: var(--muted); font-size: 12px; }
.perday .sep { width: 1px; align-self: stretch; background: var(--line); }

/* alertas */
.alert { display: flex; align-items: center; gap: 12px; padding: 12px 14px; margin-bottom: 8px; border-radius: 18px; background: var(--card); box-shadow: var(--shadow); }
.alert[data-go] { cursor: pointer; } .alert[data-go]:active { transform: scale(.99); } .alert > div { flex: 1; min-width: 0; } .alert .sub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ai { width: 38px; height: 38px; border-radius: 13px; display: grid; place-items: center; flex: none; background: var(--line); }
.alert.bad .ai { background: var(--bad-soft); color: var(--bad); } .alert.warn .ai { background: var(--warn-soft); color: var(--warn); }
.alert.info .ai { background: var(--info-soft); color: var(--info); } .alert.ok .ai { background: var(--ok-soft); color: var(--ok); } .chev { color: var(--muted); }

/* listas */
.group { margin-bottom: 18px; } .ghead { display: flex; align-items: baseline; gap: 8px; padding: 0 6px 8px; } .ghead .sum { font-size: 13px; font-weight: 600; }
.gcard { background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; }
.gbar { height: 3px; background: var(--line); } .gbar i { display: block; height: 100%; background: var(--ok); transition: width .5s; } .gbar i.over { background: var(--bad); } .gbar i.warn { background: var(--warn); }
.gbar.thick { height: 8px; border-radius: 4px; overflow: hidden; } .gbar.thick i { border-radius: 4px; }
.row { display: flex; align-items: center; gap: 12px; padding: 12px 14px; cursor: pointer; transition: background .15s; }
.row + .row { border-top: 1px solid var(--line); } .row:active { background: var(--field); }
.row .main { flex: 1; min-width: 0; } .row .name { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row .sub { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .dotsep { font-style: normal; margin: 0 5px; opacity: .5; }
.row .amt { text-align: right; flex: none; } .row .amt b { display: block; font-weight: 600; } .row .amt small { color: var(--muted); font-size: 11.5px; }
.st-pago .name, .st-ign .name { color: var(--muted); } .st-pago .amt b { color: var(--muted); font-weight: 500; } .st-pago .amt b.pos { color: var(--ok); } .st-ign { opacity: .5; }
.ico { width: 40px; height: 40px; border-radius: 14px; display: grid; place-items: center; flex: none; background: hsl(var(--h) 85% 94%); color: hsl(var(--h) 55% 40%); }
@media (prefers-color-scheme: dark) { .ico { background: hsl(var(--h) 35% 20%); color: hsl(var(--h) 75% 74%); } }
.chk { width: 28px; height: 28px; border-radius: 50%; border: 2px solid #d5d9e4; background: none; padding: 0; display: grid; place-items: center; color: #fff; flex: none; transition: transform .15s, background .2s; }
@media (prefers-color-scheme: dark) { .chk { border-color: #36405d; } }
.chk:active { transform: scale(.85); } .st-pago .chk { background: var(--ok); border-color: var(--ok); } .st-parcial .chk { border-color: var(--warn); } .st-atraso .chk { border-color: var(--bad); }
.mini { height: 4px; background: var(--line); border-radius: 2px; margin-top: 6px; overflow: hidden; } .mini i { display: block; height: 100%; background: var(--ok); border-radius: 2px; } .mini.warn i { background: var(--warn); } .mini.over i { background: var(--bad); }
.bud { padding: 8px 0; cursor: pointer; } .bt { display: flex; justify-content: space-between; font-size: 14px; font-weight: 500; margin-bottom: 7px; }

/* chips, seg, busca */
.chips { display: flex; gap: 8px; flex-wrap: wrap; margin: 8px 0; } .chips.scroll { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-left: -16px; margin-right: -16px; padding: 2px 16px; }
.sheet .chips.scroll { margin-left: -18px; margin-right: -18px; padding-left: 18px; padding-right: 18px; }
.chip { flex: none; border: 0; background: var(--card); box-shadow: var(--shadow); border-radius: 99px; padding: 8px 15px; font-size: 14px; font-weight: 500; white-space: nowrap; color: var(--ink); }
.chip.on { background: var(--acc); color: #fff; } .chip i { font-style: normal; opacity: .6; margin-left: 4px; font-size: 12px; }
.chip.big { border-radius: 18px; text-align: left; padding: 11px 16px; min-width: 120px; } .chip.big b { display: block; font-size: 17px; font-weight: 700; letter-spacing: -.3px; margin-top: 1px; }
.seg { display: flex; background: var(--field); border-radius: 14px; padding: 3px; margin: 10px 0 14px; }
.seg button { flex: 1; border: 0; background: none; padding: 8px; border-radius: 11px; color: var(--muted); font-weight: 500; transition: all .2s; }
.seg button.on { background: var(--card); color: var(--ink); box-shadow: 0 1px 4px rgba(15, 23, 42, .12); font-weight: 600; }
.search { margin: 6px 0 4px; border-radius: 99px !important; padding-left: 18px !important; background: var(--card) !important; box-shadow: var(--shadow); }
.link { background: none; border: 0; color: var(--acc); padding: 10px; font-weight: 600; width: 100%; } .alert .link { width: auto; flex: none; padding: 4px 8px; }

/* dock */
.dock { position: fixed; z-index: 6; left: 12px; right: 12px; bottom: calc(10px + env(safe-area-inset-bottom)); max-width: 460px; margin: 0 auto; background: color-mix(in srgb, var(--card) 92%, transparent);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-radius: 28px; box-shadow: 0 10px 34px rgba(15, 23, 42, .18); display: flex; align-items: center; padding: 6px; }
.dock button[data-tab] { flex: 1; border: 0; background: none; border-radius: 20px; padding: 7px 0 6px; color: var(--muted); font-size: 10.5px; font-weight: 500; display: flex; flex-direction: column; align-items: center; gap: 3px; transition: all .2s; }
.dock button.on { color: var(--acc); background: var(--acc-soft); font-weight: 600; }
.fab { flex: none; width: 54px; height: 54px; border-radius: 20px; border: 0; margin: 0 6px; color: #fff; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--acc), var(--acc2)); box-shadow: 0 8px 20px rgba(91, 91, 214, .45); transition: transform .15s; } .fab:active { transform: scale(.92); }

/* sheet e formulários */
dialog { border: 0; border-radius: 30px 30px 0 0; padding: 0; width: 100%; max-width: 560px; margin: auto auto 0; background: var(--bg); color: var(--ink); max-height: 94vh; }
dialog::backdrop { background: rgba(10, 14, 26, .5); backdrop-filter: blur(3px); } dialog[open] { animation: up .28s cubic-bezier(.2, .8, .2, 1); } @keyframes up { from { transform: translateY(40px); opacity: 0; } }
.sheet { padding: 22px 18px calc(20px + env(safe-area-inset-bottom)); position: relative; }
.sheet::before { content: ""; position: absolute; top: 8px; left: 50%; width: 38px; height: 4px; margin-left: -19px; border-radius: 2px; background: var(--line); }
.sheet h2 { margin: 6px 0 10px; font-size: 20px; }
.sh-head { display: flex; gap: 12px; align-items: center; margin: 6px 0 14px; } .sh-head h2 { margin: 0; } .sh-head .ico { width: 46px; height: 46px; border-radius: 16px; }
.tw { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 10px; color: var(--muted); } .tw b { color: var(--ink); }
label { display: block; font-size: 12px; font-weight: 500; color: var(--muted); margin: 16px 2px 6px; }
input, select, textarea { width: 100%; padding: 13px 14px; border: 2px solid transparent; border-radius: 15px; background: var(--field); min-width: 0; outline: none; transition: border-color .15s; }
input:focus, select:focus, textarea:focus { border-color: var(--acc); background: var(--card); }
.bigin { font-size: 38px; font-weight: 700; letter-spacing: -1px; text-align: center; padding: 16px; background: var(--card); box-shadow: var(--shadow); }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.actions { display: flex; gap: 8px; margin-top: 18px; flex-wrap: wrap; }
.btn { border: 0; background: var(--card); box-shadow: var(--shadow); padding: 14px 18px; border-radius: 16px; font-weight: 600; }
.btn.pri { background: linear-gradient(135deg, var(--acc), var(--acc2)); color: #fff; flex: 1; box-shadow: 0 6px 18px rgba(91, 91, 214, .35); }
.btn.gold { background: var(--acc); color: #fff; } .btn.danger { color: var(--bad); } .btn.sm { padding: 6px 12px; font-size: 13px; border-radius: 11px; }
.sugs { display: grid; gap: 8px; margin-top: 10px; }
.sug { display: flex; align-items: center; gap: 12px; background: var(--card); border: 0; box-shadow: var(--shadow); border-radius: 16px; padding: 9px 12px; text-align: left; }
.sug .ico { width: 36px; height: 36px; border-radius: 12px; } .sug span:nth-child(2) { flex: 1; min-width: 0; } .sug b { display: block; font-weight: 500; } .sug small { color: var(--muted); } .sug em { font-size: 13px; font-weight: 600; color: var(--ink); }
.empty { text-align: center; padding: 56px 16px; color: var(--muted); } .empty h2 { color: var(--ink); } .bigico { width: 72px; height: 72px; border-radius: 24px; background: var(--acc-soft); color: var(--acc); display: grid; place-items: center; margin: 0 auto 14px; }

/* gráficos */
.chart { width: 100%; height: auto; } .chart .zero { stroke: var(--line); stroke-width: 1.2; stroke-dasharray: 3 3; } .chart .ln { fill: none; stroke: var(--acc); stroke-width: 2.4; stroke-linejoin: round; stroke-linecap: round; }
.chart .area { fill: var(--acc); opacity: .1; } .chart .today { stroke: var(--info); stroke-dasharray: 2 2; } .chart .dotm { fill: var(--acc); stroke: var(--card); stroke-width: 2; } .chart text { font-size: 9px; fill: var(--muted); font-family: var(--font); }
.donutc { display: flex; align-items: center; gap: 16px; } .donut { width: 148px; flex: none; } .donut .dt { font-size: 10px; font-weight: 700; fill: var(--ink); font-family: var(--font); } .donut .ds { font-size: 5.5px; fill: var(--muted); font-family: var(--font); }
.legend { flex: 1; font-size: 13px; min-width: 0; } .legend div { display: flex; align-items: center; gap: 8px; margin: 5px 0; } .legend i { width: 9px; height: 9px; border-radius: 3px; flex: none; }
.legend span { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .legend b { font-weight: 600; }
.cmpr { display: flex; align-items: center; gap: 12px; margin: 10px 0; } .cmpr .ico { width: 34px; height: 34px; border-radius: 11px; } .cmpr span:nth-child(2) { flex: 1; }
.cmp { display: flex; align-items: center; gap: 10px; margin: 11px 0; font-size: 14px; } .cmp .n { width: 36%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cmp .b { flex: 1; height: 8px; background: var(--line); border-radius: 4px; overflow: hidden; } .cmp .b i { display: block; height: 100%; background: linear-gradient(90deg, var(--acc), var(--acc2)); border-radius: 4px; } .cmp .v { width: 76px; text-align: right; font-weight: 600; }
.months { display: flex; align-items: flex-end; gap: 6px; height: 124px; } .months div { flex: 1; text-align: center; font-size: 10px; color: var(--muted); display: flex; flex-direction: column; justify-content: flex-end; height: 100%; }
.months i { display: block; background: linear-gradient(180deg, var(--acc2), var(--acc)); border-radius: 6px 6px 3px 3px; margin-bottom: 5px; min-height: 3px; }
.toast { position: fixed; left: 50%; bottom: calc(100px + env(safe-area-inset-bottom)); transform: translate(-50%, 10px); background: #141a2c; color: #fff; padding: 12px 18px; border-radius: 16px;
  opacity: 0; pointer-events: none; transition: all .25s; z-index: 30; white-space: nowrap; box-shadow: 0 10px 28px rgba(0, 0, 0, .35); font-weight: 500; font-size: 14px; }
.toast.on { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; } .toast button { background: none; border: 0; color: #a9a9ff; font-weight: 700; margin-left: 12px; }
@media (max-width: 370px) { .hnum { font-size: 30px; } .tile b { font-size: 17px; } }

/* ajustes */
.alert.bad, .alert.warn, .alert.info, .alert.ok { color: var(--ink); }
dialog { background: var(--card); }
.sheet .card, .sheet .sug, .sheet .chip:not(.on), .sheet .btn:not(.pri), .sheet .tile { background: var(--field); box-shadow: none; }
.sheet .bigin { background: var(--field); box-shadow: none; border: 2px solid transparent; }
.sheet .bigin:focus { background: var(--card); border-color: var(--acc); }
.sheet .seg { background: var(--field); } .sheet .seg button.on { background: var(--card); box-shadow: 0 1px 4px rgba(15, 23, 42, .15); }
.sheet .alert { background: var(--field); box-shadow: none; }
.sheet .gcard { background: var(--field); box-shadow: none; } .sheet .row + .row { border-color: var(--card); }
.sheet input, .sheet select { background: var(--field); }
.sheet input:focus, .sheet select:focus { background: var(--card); border-color: var(--acc); }

/* ---- calmaria: menos cor, menos peso ---- */
.hero { background: linear-gradient(135deg, #39436b, #4a5686); box-shadow: 0 8px 22px rgba(57, 67, 107, .2); border-radius: 26px; padding: 20px; }
.hnum { font-size: 34px; font-weight: 600; letter-spacing: -.8px; }
.hchip { background: rgba(255, 255, 255, .14); font-weight: 400; }
.hfoot { margin-top: 18px; padding-top: 12px; border-top: 1px solid rgba(255, 255, 255, .14); font-size: 12.5px; opacity: .9; }
.rbg { stroke: rgba(255, 255, 255, .16); } .rfg { stroke: #fff; stroke-width: 6; } .rbg { stroke-width: 6; } .ringw span { font-weight: 600; }
.strip { display: grid; grid-template-columns: repeat(4, 1fr); background: var(--card); border-radius: var(--r); box-shadow: var(--shadow); padding: 14px 4px; margin: 12px 0; }
.strip > div { padding: 0 10px; min-width: 0; } .strip > div + div { border-left: 1px solid var(--line); }
.strip b { display: block; font-size: 15px; font-weight: 600; margin-top: 3px; white-space: nowrap; letter-spacing: -.2px; }
h2 { font-size: 15px; font-weight: 600; margin: 26px 4px 10px; }
b { font-weight: 600; } .row .name { font-weight: 450; } .row .amt b { font-weight: 550; }
.ico { background: var(--acc-soft); color: var(--acc); }
@media (prefers-color-scheme: dark) { .ico { background: var(--acc-soft); color: var(--acc); } }
.ai { background: var(--field); color: var(--muted); }
.alert { box-shadow: none; border: 1px solid var(--line); border-radius: 16px; }
.alert b { font-weight: 500; }
.alert.bad .ai { background: var(--bad-soft); color: var(--bad); } .alert.warn .ai { background: var(--warn-soft); color: var(--warn); }
.alert.info .ai, .alert.ok .ai { background: var(--field); color: var(--muted); }
.gcard { box-shadow: none; border: 1px solid var(--line); } .card, .tile, .chip, .iconbtn, .monthnav { box-shadow: none; border: 1px solid var(--line); }
.chip.on { border-color: var(--acc); } .search { box-shadow: none; }
.gbar i { background: var(--acc); opacity: .75; } .gbar i.over { background: var(--bad); opacity: 1; } .gbar i.warn { background: var(--warn); opacity: 1; }
.mini i { background: var(--acc); opacity: .75; } .st-pago .gbar i { background: var(--ok); }
.chk { border-color: #dde1e9; } .st-pago .chk { background: var(--ok); border-color: var(--ok); opacity: .9; }
h3 { font-weight: 500; letter-spacing: .5px; font-size: 12px; }
.dock { box-shadow: 0 6px 24px rgba(20, 30, 50, .12); border: 1px solid var(--line); }
.fab { background: var(--acc); box-shadow: 0 4px 12px rgba(57, 67, 107, .28); border-radius: 18px; }
.btn.pri { background: var(--acc); box-shadow: none; } .btn { box-shadow: none; border: 1px solid var(--line); }
.bigin { font-weight: 600; } .bigin { box-shadow: none; }
.chart .ln { stroke: var(--acc); } .cmp .b i, .months i { background: var(--acc); opacity: .85; }
.bt { font-weight: 450; }
.toast { background: #232a3d; }
.empty .btn.pri { padding: 14px 24px; }
@media (prefers-color-scheme: dark) { .chk { border-color: #36405d; } .gcard, .card, .alert { border-color: var(--line); } }

/* ---- paleta calma (sobrescreve tokens) ---- */
:root {
  --bg: #f6f7f9; --card: #ffffff; --ink: #1c2333; --muted: #7b8394; --line: #eef0f3; --field: #f2f4f7;
  --acc: #55608f; --acc2: #66719f; --acc-soft: #eceff7;
  --ok: #3f8f6b; --ok-soft: #e8f3ee; --bad: #c9505f; --bad-soft: #f8eaec; --warn: #b98332; --warn-soft: #f7efe0; --info: #4b86b4; --info-soft: #e8f0f6;
  --r: 20px; --shadow: 0 1px 2px rgba(20, 30, 50, .04), 0 4px 16px rgba(20, 30, 50, .04);
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #0f131c; --card: #171c28; --ink: #e6e9f0; --muted: #8a93a6; --line: #232a3a; --field: #1d2333;
    --acc: #9aa5dc; --acc2: #a9b2e3; --acc-soft: #232a45;
    --ok: #5fbf95; --ok-soft: #14301f; --bad: #e8808c; --bad-soft: #3a1c22; --warn: #e0b060; --warn-soft: #33290f; --info: #78aed6; --info-soft: #13293a;
    --shadow: 0 1px 2px rgba(0, 0, 0, .35); }
}

/* orçamentos variáveis */
.addb { width: 32px; height: 32px; border-radius: 50%; border: 0; background: var(--acc-soft); color: var(--acc); display: grid; place-items: center; flex: none; padding: 0; transition: transform .15s; }
.addb:active { transform: scale(.88); } .st-var .name { font-weight: 450; }
.h2s { display: flex; justify-content: space-between; align-items: baseline; } .h2s em { font-size: 13px; font-weight: 500; }
.buds { padding: 6px 16px; } .bud { padding: 12px 0; } .bud + .bud { border-top: 1px solid var(--line); }
.bud .bl { display: flex; align-items: center; gap: 12px; margin-bottom: 9px; } .bud .bl > div:first-child { flex: 1; min-width: 0; }
.bn { font-weight: 450; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .br { text-align: right; } .br b { display: block; font-weight: 550; } .br small { font-size: 11.5px; color: var(--muted); }
.bud .gbar.thick { height: 6px; } .row .mini { height: 3px; }

.sheet .alert .sub { white-space: normal; }

/* dicas e guia */
.tip { display: flex; align-items: center; gap: 12px; padding: 12px 14px; margin: 4px 0 12px; border-radius: 16px; background: var(--acc-soft); }
.tip .ai { background: var(--card); color: var(--acc); } .tip > div { flex: 1; min-width: 0; } .tip b { font-weight: 550; } .tip .link { width: auto; flex: none; padding: 4px 6px; }
.helpcard { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 8px; }
.gstep { display: flex; gap: 12px; margin: 14px 0; } .gstep .ai { background: var(--acc-soft); color: var(--acc); } .gstep b { font-weight: 550; display: block; margin-bottom: 2px; }
.gstep .sub { white-space: normal; line-height: 1.45; }
.kb { display: flex; align-items: center; gap: 12px; margin: 8px 0; font-size: 14px; } .kb span { color: var(--muted); }
kbd { min-width: 44px; text-align: center; padding: 4px 8px; border-radius: 8px; background: var(--field); border: 1px solid var(--line); font: 600 12px var(--font); }
.toast[data-lvl="warn"] { background: #8a5d12; } .toast[data-lvl="bad"] { background: #a8384a; }
.sheet .tip { background: var(--field); }
