/* Stingray Bookkeeping, Client login, "Your month" (month.html). Pass 3, PC 1, Oct 16 2026.
   Loads after portal.css and client-pass3.css. Layout and sizes only: every color and font is a name from
   those two files (so each of the four looks keeps its own surface, and a cream card turns the words navy).
   Text: 18px and more up to 699 wide, 16px and more above (sizes in rem follow the text-size setting). */

/* LOOK A WORDS: the aurora look's sans for body words now lives in client-pass3.css for every pass-3 page
   (PC 2 shared step, Oct 17); this page no longer carries its own copy. */


/* the amounts of the Breakdown rows in the figure face, as in the R2 pictures and on the report */
.m-row-r .p3-row-amt {
  font-family: var(--font-fig, var(--serif));
}

/* ---------- the top row: Back to home on the left, "Customize" on the right (PC 2 fix step, Oct 17) ---------- */
.m-backs {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 14px;
}

.m-backs > .m-customize {
  width: auto;
  margin-left: auto;
}

/* ---------- Kept in the Breakdown (the same card as the report's): the sentence sits inside it ---------- */
.m-kept .m-kept-quote {
  margin: 14px 0 0;
}

.m-kept.is-short .m-total {
  color: var(--ink);
}

/* ---------- a month not in the books yet: one plain line and the newest checked month ---------- */
.m-not-ready {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 6px;
}

.m-not-ready .lead {
  margin: 0;
}

/* ---------- the page parts ---------- */
.m-monthly,
.m-cleanup,
.m-view {
  display: flex;
  flex-direction: column;
  gap: var(--gap);
  min-width: 0;
}

.m-head {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 22px;
}

.m-title {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.m-title-when {
  color: var(--p3-gold-ink);
  font-size: .6em;
  font-weight: 500;
  letter-spacing: 0;
}

.m-switch-mount {
  width: 100%;
  max-width: 520px;
}

@media (min-width: 1024px) {
  .m-switch-mount {
    width: 460px;
  }
  /* the right column is narrow on a computer: Print and Leave a note one under the other, never squeezed */
  .m-get .p3-pair {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* a card heading with its small gold line icon in front (R2) */
.m-head-icon {
  display: flex;
  align-items: center;
  gap: 12px;
}

.m-head-icon > .icon {
  width: 1.05em;
  height: 1.05em;
  color: var(--p3-gold-ink);
}

.m-center {
  text-align: center;
}

/* ---------- Simple: the 4-dot tracker right under the title, no card around it (H2) ----------
   Full width on a phone (so "Papers in" fits one line); on a computer as wide as the left column, so it
   lines up with the "So far" card under it. Labels break evenly, the count stays with its word. */
.m-track {
  width: 100%;
  padding: 14px 4px 12px;
  /* a soft dark strip, no heading and no frame: the labels stay readable over the bright aurora art */
  border-radius: var(--p3-radius, 16px);
  background: var(--p3-quote-bg);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}

.m-page .p3-step {
  text-wrap: balance;
}

.m-track > li {
  gap: 8px;
  padding: 0 1px;
}

/* on a phone: lined up with the cards, a little less padding, so "Waiting on / you (2)" takes two lines */
@media (max-width: 699px) {
  .m-track {
    padding: 12px 0 10px;
  }
}

/* "So far in October  Oct 1 to 13" on one line when it fits, the days under it when not */
.m-sofar-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 2px 14px;
}

/* change 017: "So far, from your QuickBooks. Not checked yet. Through Oct 19." under the heading */
.m-sofar-mark {
  margin-top: 6px;
  color: var(--soft);
  font-size: var(--text-quiet);
}

@media (min-width: 1024px) {
  .m-track {
    width: calc((100% - var(--gap)) * 7 / 12);
  }
}

/* the calm line when the breakdown could not load (Simple stays on) */
.m-bd-off {
  --n-ink: var(--soft);
  --n-bg: var(--p3-line-bg);
  --n-line: var(--rule);
}

/* "Download everything" answer, under the button in the middle of its card */
.m-dl-said {
  width: 100%;
  max-width: 520px;
  text-align: left;
}

.m-btns {
  gap: 12px;
}

/* ---------- Simple: Came in / Went out / Kept as rows, label left, big figure right (H2) ---------- */
.m-figs {
  margin: 0;
  padding: 0;
  list-style: none;
}

.m-fig {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 2px 18px;
  padding: 10px 0;
  border-top: 1px solid var(--rule);
}

.m-fig:first-child {
  padding-top: 0;
  border-top: 0;
}

.m-fig-l {
  color: var(--ink);
  font: 400 1.5rem/1.2 var(--serif);
}

.m-fig-n {
  color: var(--ink);
  font: var(--w-fig, 660) 2.5rem/1.1 var(--serif);
  font-variant-numeric: lining-nums tabular-nums;
  letter-spacing: -.012em;
  white-space: nowrap;
}

.m-fig.kept .m-fig-n {
  color: var(--p3-gold-ink);
}

.m-quote p {
  margin: 0;
}

/* ---------- Breakdown: a card title with its total on the right (R2) ---------- */
.m-total-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 4px 16px;
}

.m-total {
  color: var(--p3-gold-ink);
  font: var(--w-fig, 660) 2.25rem/1.1 var(--serif);
  font-variant-numeric: lining-nums tabular-nums;
  letter-spacing: -.01em;
  white-space: nowrap;
}

/* rows: gold icon + name on the left, the amount with its change pill on the right */
.m-rows {
  margin: 0;
  padding: 0;
  list-style: none;
}

.m-row.p3-row {
  align-items: center;
}

.m-row-name {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.m-row-words {
  min-width: 0;
}

.m-ico {
  flex: none;
  width: 28px;
  height: 28px;
  color: var(--p3-gold-ink);
  vertical-align: middle;
}

.m-row-r.p3-row-r {
  gap: 6px;
}

.p3-barrow.m-barrow > .p3-row-l {
  align-self: center;
}

.p3-barrow.m-barrow > .p3-row-detail {
  padding-left: 40px;
}

.p3-barrow.m-barrow > .p3-mini-bar {
  margin-left: 40px;
}

/* the change against last month: a NEUTRAL cream outline pill with a small arrow (fix 1: never green or red,
   a "down" on a cost is good news) */
.m-chg {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 32px;
  padding: 2px 12px;
  border: 1px solid var(--soft);
  border-radius: 999px;
  background: var(--p3-line-bg);
  color: var(--ink);
  font: 600 1.125rem/1.15 var(--sans);
  white-space: nowrap;
}

.m-chg-arrow {
  width: 16px;
  height: 16px;
  stroke-width: 2.2;
}

/* "See all 6": the arrow points down, then up once the list is open */
.m-chev {
  transform: rotate(90deg);
}

#out-more.is-open .m-chev {
  transform: rotate(-90deg);
}

/* ---------- the books check: four rows with a ring, then the months ring ---------- */
.m-checks {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.m-check {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 40px;
}

.m-check-ring {
  display: inline-grid;
  flex: none;
  place-items: center;
  width: 34px;
  height: 34px;
  border: 2px solid var(--p3-gold);
  border-radius: 50%;
  color: var(--p3-gold-ink);
}

.m-check-ring > .icon {
  width: 20px;
  height: 20px;
  stroke-width: 2.2;
}

.m-check-words {
  min-width: 0;
  color: var(--ink);
}

/* "Not yet" sits inside the words of its own row: when the row wraps, it wraps under those words */
.m-check-open {
  margin-left: 6px;
  vertical-align: middle;
}

/* "Almost up to date: / 1 thing left", never "left" alone on the second line (month.js keeps the two
   pieces whole); the tax detail and the PDF line break evenly too */
#books-h,
.m-barrow > .p3-row-detail,
.m-page .p3-sub.m-center {
  text-wrap: balance;
}

.m-sent-note p {
  margin: 0;
  white-space: pre-wrap;
}

.m-ready {
  display: flex;
  align-items: center;
  gap: 18px;
}

.m-ring {
  flex: none;
  width: 76px;
  height: 76px;
}

.m-ring > svg {
  display: block;
  width: 100%;
  height: 100%;
}

.m-ring-track {
  fill: none;
  stroke: var(--p3-bar-track);
  stroke-width: 7;
}

.m-ring-part {
  fill: none;
  stroke: var(--p3-gold);
  stroke-width: 7;
  stroke-linecap: round;
}

.m-ready-words {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  padding-left: 18px;
  border-left: 1px solid var(--rule);
}

.m-ready-h {
  color: var(--ink);
  font: var(--w-head) 1.5rem/1.2 var(--serif);
}

/* ---------- Payroll and Taxes ---------- */
.m-pay-total {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 4px 16px;
}

.m-pay-total-l {
  color: var(--ink);
  font: var(--w-head) 1.75rem/1.2 var(--serif);
}

.m-tax-line {
  color: var(--ink);
  font: var(--w-head) 1.625rem/1.25 var(--serif);
}

.m-gold {
  color: var(--p3-gold-ink);
  font-variant-numeric: lining-nums tabular-nums;
}

/* ---------- where the books live, Download everything ---------- */
.m-where {
  align-items: center;
  text-align: center;
}

.m-where-line {
  color: var(--ink);
  font: 400 1.25rem/1.35 var(--serif);
}

.m-where-btn {
  width: 100%;
  max-width: 420px;
}

/* ---------- a cleanup client: the months ---------- */
.m-months {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(76px, 1fr));
  gap: 14px 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.m-month {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.m-month-words {
  color: var(--ink);
  font: 400 1.25rem/1.2 var(--serif);
}

/* ---------- the note ---------- */
.m-note-box {
  min-height: 150px;
  resize: vertical;
}

/* ---------- on paper ---------- */
@media print {
  .m-head {
    gap: 8px;
  }
  .m-ico,
  .m-head-icon > .icon {
    display: none;
  }
  /* on paper every Went out row prints, also the ones behind "See all", with their bars */
  #out-rows > li.m-extra[hidden] {
    display: grid !important;
  }
  .p3-mini-bar,
  .p3-mini-bar > span,
  .m-ring,
  .p3-split-bar > span,
  .p3-track .p3-dot {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }
  /* the tracker strip is a plain hairline box on paper (a dark strip would hide its labels) */
  .m-track {
    border: 1px solid #999;
    background: none !important;
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
  /* a long Breakdown card may go on to the next sheet between rows, not leave half a page empty */
  #view-breakdown section.panel {
    break-inside: auto;
  }
  #in-rows > li,
  #out-rows > li,
  #books-checks > li {
    break-inside: avoid;
  }
  /* the change pills and "Not yet": a plain outline on white paper */
  .m-chg,
  .m-check-open {
    border-color: #555 !important;
    background: none !important;
    color: #000 !important;
  }
  /* no grey plate or glow behind the title on paper */
  .m-title {
    text-shadow: none !important;
  }
  .m-title::before {
    display: none !important;
  }
  /* the gold words of the screen are black on paper (light gold on white cannot be read) */
  .m-title-when,
  .m-fig-n,
  .m-fig.kept .m-fig-n,
  .m-total,
  .m-gold,
  .m-check-ring {
    color: #000 !important;
  }
  .m-check-ring {
    border-color: #000 !important;
  }
  .m-ring-part {
    stroke: #000 !important;
  }
  /* a page that names QuickBooks keeps the Intuit line on paper too (portal.css hides the foot) */
  .foot {
    display: block !important;
    margin-top: 18px;
  }
  .foot > * {
    display: none !important;
  }
  .foot > #qb-mark:not([hidden]) {
    display: block !important;
    font-size: 10pt;
  }
}

/* "Customize" on a phone: as tall as "Back to home" (48px), in the same row (PC 2 fix step, Oct 17) */
@media (max-width: 699px) {
  .m-backs > .m-customize {
    min-height: 48px;
    padding-top: 4px;
    padding-bottom: 4px;
  }
}

/* THE MONEY RIVER (Oct 20 2026, PC 1; strategy\MONEY-RIVER-BUILD.md section 2): "So far in October" shows the
   river of the month so far (money-river.js; its look is money-river.css) in place of the three figures and the
   split bar, when the owner shares the month so far from their QuickBooks. */
.m-river {
  min-width: 0;
  margin-top: 4px;
}
