/* Bureo shell M1: the Money screen (app/m1-money.js) on the kit. Bridge only: the classic card around #gwMoney steps aside so the
   board sits on the work panel's ground (as the Overview board), plus the few app-only bits the study's dashboard does not have
   (provider group headings, a row's right-hand amount + pill, long fix labels that wrap). Kit tokens only; flag-off look unchanged. */
html.b-m1:not(.m1-chrome) #main>section[data-view="money"]>#gwMoney{background:none;border:0;box-shadow:none;padding:0;margin:0;border-radius:0;min-width:0}
html.b-m1:not(.m1-chrome) #main>section[data-view="money"]>#gwMoney::before,html.b-m1:not(.m1-chrome) #main>section[data-view="money"]>#gwMoney::after{display:none}
html.b-m1 .m1m.k-m1{background:none;min-width:0}
html.b-m1 .m1m .k-dhead>.m1m-arow{display:contents}
html.b-m1 .m1m .k-dhead .m1m-asof{font-size:var(--k-t-sm);white-space:nowrap}
/* the rows are the study's k-du; an account row carries the balance and its feed pill on the right */
html.b-m1 .m1m .k-du{align-items:flex-start}
html.b-m1 .m1m .k-du>.k-dd{padding-top:2px}
html.b-m1 .m1m .k-du small{display:block}
html.b-m1 .m1m .m1m-wrap{display:block;overflow-wrap:anywhere}
html.b-m1 .m1m .m1m-ar{display:flex;flex-direction:column;align-items:flex-end;gap:4px;flex:none;text-align:right}
html.b-m1 .m1m .m1m-ar b{font-weight:400;font-variant-numeric:tabular-nums;white-space:nowrap}
html.b-m1 .m1m .k-du .k-btn{flex:none;align-self:center}
html.b-m1 .m1m .k-du>.k-spill{flex:none;align-self:center}
/* group headings inside a card (provider, crypto, "What closes the gap"): the kit's eyebrow, a little air above */
html.b-m1 .m1m .m1m-eb{font-size:var(--k-t-cap);margin:6px 0 0}
html.b-m1 .m1m .m1m-note{font-size:var(--k-t-sm)}
html.b-m1 .m1m>.m1m-note{padding:0 4px}
/* the legend's "lowest week" swatch = the bar's dark hatching (k-bx.k-fc.k-dk) */
html.b-m1 .m1m .k-lgd i.m1m-dk{background:repeating-linear-gradient(135deg,var(--k-text-2) 0 2px,transparent 2px 7px);box-shadow:inset 0 0 0 1px var(--k-text-2)}
html.b-m1 .m1m .m1m-warn .k-c2h{flex-wrap:wrap;padding-right:0}
html.b-m1 .m1m .k-c2h>b{min-width:0}
/* the Currencies and Model tabs keep the classic body inside a kit card; its wide tables scroll inside the card */
html.b-m1 .m1m .m1m-classic{overflow:hidden;position:relative;background:var(--ka-card);border-radius:20px;padding:12px 14px;display:flex;flex-direction:column;gap:6px;min-width:0;box-shadow:0 10px 30px -24px rgba(20,22,30,.45)}   /* the kit card (.k-card2) drawn here: see m1-money.js, the tabs */
html.b-m1 .m1m .k-ptabs button{white-space:nowrap}
/* declutter, one lime + one black per view (HQ 19 #3, HQ 20 #1–3): the lime is the hero's ring (k-ref), the black is the hero;
   this week's bar, the lowest week's tag, the open tab and the one main action are quiet (the main action is the kit's plain
   pill, as Your books' New invoice); the early warning a line under the bars (its fixes in the fold) */
html.b-m1 .k-dash.m1m:has(.k-kt.k-hero) .k-bx.k-hi,html.b-m1 .k-dash.m1m:has(.k-kt.k-hero) .k-lgd i.k-hi{background:var(--k-text-3)}
html.b-m1 .m1m .k-bx em{background:var(--ka-card);color:var(--k-text);box-shadow:0 0 0 1px var(--k-line-strong)}
html.b-m1 .m1m .k-ptabs button[aria-current]{background:var(--k-soft);color:var(--k-text);font-weight:600;box-shadow:inset 0 0 0 1.5px var(--k-line-strong)}   /* soft (one black per view) yet clearly selected: heavier + an inset ring (HQ 22) */
html.b-m1 .m1m .k-kt.k-hero em{color:inherit;opacity:.8}
html.b-m1 .m1m .m1m-low{margin:0;font-size:var(--k-t-sm);color:var(--k-warn-ink)}
html.b-m1 .m1m .m1m-low .m1m-buf{color:var(--k-text-3)}
html.b-m1 .m1m .m1m-bufp{display:none;margin:0;font-size:var(--k-t-sm);color:var(--k-text-3)}
html.b-m1 .m1m .m1-morein>.m1m-note{padding:0 4px}
/* the bars' value tag stays inside the chart: on the first bars it starts at the bar, on the last it ends at it */
html.b-m1 .m1m .k-cb:nth-child(-n+2) .k-bx em{left:0;transform:none}
html.b-m1 .m1m .k-cb:nth-last-child(-n+2) .k-bx em{left:auto;right:0;transform:none}
/* 13 weeks, no tag on the low bar (said once, under the bars: HQ 22 #2); the bars start at a round value when the data sits far
   from 0 (m1-money.js): a break mark at the foot of the axis, the value in the caption */
html.b-m1 .m1m .k-cbars.m1m-bars{padding-top:8px;position:relative}
html.b-m1 .m1m .k-cbars.m1m-cut::before{content:"";position:absolute;left:-11px;bottom:calc(1.4em + 2px);width:7px;height:5px;border-top:1.5px solid var(--k-text-3);border-bottom:1.5px solid var(--k-text-3);transform:skewY(-35deg)}
/* the axis = the month and its year, once per month (m1-money.js axis): never wrapped, free to run past its narrow bar */
html.b-m1 .m1m .k-cb small{font-family:var(--k-font);font-variant-numeric:tabular-nums;white-space:nowrap;overflow:visible;height:1.4em;line-height:1.4em;text-align:left;align-self:flex-start;width:max-content;position:relative;z-index:1}
html.b-m1 .m1m .k-cb small:not(:empty){background:var(--ka-card);padding-right:4px;border-radius:4px}
html.b-m1 .m1m .k-cb:last-child small:not(:empty){align-self:flex-end;padding:0 0 0 4px}
/* bar heights follow the closing balances: the bar is its share of the plot (the column less its label), never squeezed by flex (HQ 21 #2) */
html.b-m1 .m1m .k-cbars .k-bx{flex-shrink:0;height:calc((100% - 1.4em - 4px) * var(--f,1))}
/* a flat forecast (m1-money.js): today's balance, then one dashed line, the bars' box and axis; kit tokens only (k-cbars sizes) */
html.b-m1 .m1m .m1m-flat{display:flex;flex-direction:column;gap:4px;height:112px;padding-top:24px}
html.b-m1 .m1m .m1m-plot{position:relative;flex:1;min-height:0}
html.b-m1 .m1m .m1m-plot svg{position:absolute;inset:0;width:100%;height:100%;overflow:visible}
html.b-m1 .m1m .m1m-plot path{fill:none;stroke:var(--k-text-2);stroke-width:2;stroke-dasharray:6 5;stroke-linecap:round;vector-effect:non-scaling-stroke}
html.b-m1 .m1m .m1m-pt{position:absolute;width:9px;height:9px;border-radius:50%;background:var(--ka-card);box-shadow:inset 0 0 0 2px var(--k-text-2);transform:translate(-50%,-50%)}
html.b-m1 .m1m .m1m-pt.m1m-pt-now{width:12px;height:12px;background:var(--k-text-3);box-shadow:0 0 0 3px var(--ka-card)}
html.b-m1 .m1m .m1m-ax{display:flex;gap:6px}
html.b-m1 .m1m .m1m-ax small{flex:1;min-width:0;font-size:var(--k-t-cap);color:var(--k-text-3);text-align:center;font-variant-numeric:tabular-nums;white-space:nowrap}
html.b-m1 .m1m .m1m-ax small:first-child{text-align:left}
html.b-m1 .m1m .k-lgd i.m1m-now{background:var(--k-text-3);border-radius:50%}
html.b-m1 .m1m .k-lgd i.m1m-est{height:0;width:14px;border-radius:0;border-top:2px dashed var(--k-text-2)}
/* the shell around the Money view keeps to the same rule while Money is open (HQ 20 #1, #3, #4, #6): New chat's +, the greeting
   orb, the suggestion chip and the starter art go neutral, send and the avatar are quiet, the starters' grey lines are not cut
   ("…") and the Ctrl 0 / Ctrl K chips step aside. Scoped to the open Money view (the shell's own one-lime pass is separate) */
html.b-m1:has(#main>section[data-view="money"]:not([hidden]) .m1m) .k-mnew>span:first-child{background:var(--k-soft);color:var(--k-text)}
html.b-m1:has(#main>section[data-view="money"]:not([hidden]) .m1m) .m1-orb{filter:grayscale(1);opacity:.6}
html.b-m1[data-theme="dark"]:has(#main>section[data-view="money"]:not([hidden]) .m1m) .m1-orb{opacity:.35}
html.b-m1:has(#main>section[data-view="money"]:not([hidden]) .m1m) :is(.k-sugc,.m1c-sugc){background:var(--k-soft)}
html.b-m1:has(#main>section[data-view="money"]:not([hidden]) .m1m) :is(.k-vis,.m1k-vis).k-btn b{background:var(--k-soft);color:var(--k-text)}
html.b-m1:has(#main>section[data-view="money"]:not([hidden]) .m1m) #agForm.k-pillc .k-go{background:var(--k-soft);color:var(--k-text)}
html.b-m1:has(#main>section[data-view="money"]:not([hidden]) .m1m) .k-mco .k-av{background:var(--k-soft);color:var(--k-text)}
html.b-m1:has(#main>section[data-view="money"]:not([hidden]) .m1m) .m1-kbd{display:none}
html.b-m1:has(#main>section[data-view="money"]:not([hidden]) .m1m) :is(.k-stc,.m1k-stc) small{display:block;-webkit-line-clamp:unset;overflow:visible}
/* the fold's phone-only copy of Owed to you / Bills to pay and its phone count (m1-money.js): off on the desk */
html.b-m1 .m1m .m1m-ph,html.b-m1 .m1m .m1m-pn,html.b-m1 .m1m .m1m-cue,html.b-m1 .m1m .m1m-lwp{display:none}
html.b-m1 .m1m .m1m-cuebtn{border:0;background:none;padding:0;font:inherit;font-size:var(--k-t-md);color:var(--k-text-2);cursor:pointer;min-height:var(--k-tap)}   /* the quiet 13 px line, as the desk's (HQ 24 #2) */
html.b-m1 .m1m .m1m-cuebtn::after{content:"";display:inline-block;width:6px;height:6px;margin-left:8px;border:solid currentColor;border-width:0 1.5px 1.5px 0;transform:translateY(-2px) rotate(45deg)}
@media (max-width:860px){
  /* the axis on a phone: two bars clear each side of the low's day (desk: one); the low's label takes the phone's year */
  html.b-m1 .m1m .k-cbars small.m1m-near2{visibility:hidden}
  html.b-m1 .m1m .m1m-lwd{display:none}html.b-m1 .m1m .m1m-lwp{display:inline}
  /* the cue and the main action share the row when both fit with at least 16 px between them; else the action wraps to its own
     row (HQ 24 #3: never squeezed) */
  html.b-m1 .m1m .m1m-cue{display:inline-flex;align-items:center}
  html.b-m1 .m1m:has(>details[open]) .m1m-cue,html.b-m1 .m1m>details:not([open])>summary{display:none}
  html.b-m1 .m1m .m1m-ph{display:grid}html.b-m1 .m1m .m1m-pn{display:inline}html.b-m1 .m1m .m1m-dn{display:none}
  html.b-m1 .m1m>.m1-kts3>.k-kt:not(.k-hero){display:none}
  /* the hero keeps its ↗ (HQ 23 #4; the kit's phone rule hides it on tiles) */
  html.b-m1 .m1m>.m1-kts3>.k-kt.k-hero>.k-arr{display:grid}
  html.b-m1 .m1m .k-ptabs button{min-height:var(--k-tap);padding:5px 14px}
  html.b-m1 .m1m .k-dhead>.k-btn{min-height:var(--k-tap)}
  html.b-m1 .m1m .k-du .k-btn{min-height:var(--k-tap)}
  /* phone (HQ 19 #7, HQ 20 #5): the bars above the fold. One grid: the tabs, the hero, the chart, then the two tiles side by side,
     the one main action and the fold (the head row and the tile row open up with display:contents, so nothing is drawn twice) */
  html.b-m1 .m1m{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:10px}
  html.b-m1 .m1m>*{grid-column:1/-1;min-width:0}
  html.b-m1 .m1m>.k-dhead,html.b-m1 .m1m>.m1-kts3{display:contents}
  html.b-m1 .m1m>.k-dhead>.k-ptabs{order:0;grid-column:1/-1;justify-self:start;margin:0}
  html.b-m1 .m1m>.k-dhead>:is(.k-grow,.m1k-grow){display:none}
  /* the one main action right under the hero, before the chart: the half sheet always shows it (HQ 27 r5 fix 7); the fold's cue
     on the same row at its end, wrapping under it when the words are long (es / sl), so it is never hidden (HQ 23 #3) */
  html.b-m1 .m1m>.k-dhead>.m1m-arow{order:2;grid-column:1/-1;display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:4px 12px}
  html.b-m1 .m1m>.k-dhead>.m1m-arow>.k-btn{min-height:var(--k-tap)}
  html.b-m1 .m1m>.m1-kts3>.k-kt{order:4;grid-column:auto;grid-row:auto}
  html.b-m1 .m1m>.m1-kts3>.k-kt.k-hero{order:1;grid-column:1/-1}   /* the kit's centred hero (label, figure, caption), as Your books (HQ 22) */
  html.b-m1 .m1m>.k-dgrid{order:2}
  html.b-m1 .m1m>details{order:4}   /* the fold's line right under the chart: the cue for Owed / Bills (HQ 23 #3) */
  html.b-m1 .m1m>.m1m-classic{order:2}
  html.b-m1 .m1m .m1m-low .m1m-buf{display:none}html.b-m1 .m1m .m1m-bufp{display:block}   /* the warning keeps one line; the buffer on its own line under it */
  html.b-m1 .m1m .k-cb small,html.b-m1 .m1m .m1m-ax small{font-size:var(--k-t-cap)}
  html.b-m1 .m1m .k-cbars,html.b-m1 .m1m .m1m-flat{height:96px}
  html.b-m1 .m1m .k-cbars.m1m-bars{height:100px}   /* the plot >= 64 px: bars read as bars, not pebbles (HQ 27 r5 fix 5) */
  /* HQ 22 #5: no ↗ on the cards (the hero keeps its own); the sheet ends on a whole block (shell r3), so no fade here */
  html.b-m1 .m1m .k-card2>.k-arr{display:none}
  html.b-m1 .m1m .k-card2 .k-c2h{padding-right:0}
  /* the chart's legend on its own line under the title (one line, never squeezing the title into three) */
  html.b-m1 .m1m .k-c2h:has(>.k-lgd){flex-wrap:wrap;row-gap:4px}
  html.b-m1 .m1m .k-c2h>.k-lgd{white-space:nowrap;margin-left:auto}   /* beside the title when it fits (no ↗ on the card), else under it */
  /* the cards' round ↗ stays 30 px as drawn; its tap target is 44 px */
  html.b-m1 .m1m .k-arr::after{content:"";position:absolute;inset:-7px}
  /* the half-height sheet over the home: the starters it would cut through step aside, so the sheet has a clean top edge (HQ 20 #5) */
  html.b-m1.b-m1-sheet:has(#main>section[data-view="money"]:not([hidden]) .m1m) #m1Hero :is(.k-starters,.m1k-starters){visibility:hidden}
}
