/* Runway in a sentence (PV-004, js/runway-ui.js). Steady mood: monochrome plus the one accent; nothing celebrates.
   Link after pocket.css and sentence-parts.css (it uses the Money · Ledger tokens). Classes are rw2-* and rw-mo* /
   rw-fact*, so the old shared rw-preset / rw-gap rules (Debt, Home value, Mortgage use them) stay untouched.
   Design: docs/design/planning-v2/proto.html?screen=runway */

.rw2 { display: flex; flex-direction: column; gap: 14px; container-type: inline-size; }
.rw2-h .pl-tool-title { font-size: 24px; font-weight: 600; letter-spacing: -.02em; }
.rw2-sub { margin: 4px 0 0; font: 400 13.5px var(--font-sans); color: var(--text-dim); }
.rw2-grid { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(300px, 1fr); gap: 14px; align-items: start; }
.rw2-card { display: grid; gap: 16px; padding: 22px; border-radius: var(--r-card); background: var(--surface); box-shadow: var(--shadow-sm); min-width: 0; }
.rw2-k { margin: 0; font: 600 15px var(--font-sans); color: var(--text); }

/* the sentence: the answer, large; the cut drags, the cushion is picked */
.rw-sent { margin: 0; font: 600 26px/1.3 var(--font-sans); letter-spacing: -.02em; color: var(--text); max-width: 34ch; text-wrap: balance; }
.rw-sent .sp-ans { color: var(--accent); }
.rw-sent-s { font-size: 18px; font-weight: 500; max-width: none; }
.rw-sent-s .sp-ans { color: var(--text); }
.rw-next { margin: 0; padding: 12px 14px; border-radius: 12px; background: var(--surface-2); font: 400 14px/1.5 var(--font-sans); color: var(--text-mid); }
.rw-next .sp-ans { color: var(--text); font-weight: 600; }
.rw2-main .sp-hint { margin: -8px 0 0; }

/* the months: one block per calendar month, filled while the money lasts; the cushion is a line, the run-out month named */
.rw-months { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 22px 6px; padding-top: 18px; }
.rw-mo { position: relative; min-width: 0; }
.rw-mo-b { position: relative; height: 64px; border-radius: 8px; background: color-mix(in srgb, var(--text) 7%, transparent); overflow: hidden; }
.rw-mo-b i { position: absolute; inset: 0 auto 0 0; background: var(--accent-fill); }
.rw-mo-c { position: absolute; top: 0; bottom: 0; width: 0; border-left: 2px dashed var(--text); }
.rw-mo-l { margin-top: 6px; font: 500 10.5px var(--font-mono); text-transform: uppercase; text-align: center; color: var(--text-dim); white-space: nowrap; }
.rw-mo-l small { font-size: 9.5px; }
.rw-mo-t { position: absolute; left: 50%; bottom: calc(100% + 3px); transform: translateX(-50%); font: 600 10.5px var(--font-sans); color: var(--text); white-space: nowrap; }
.rw-mo.is-end .rw-mo-t, .rw-mo.is-end .rw-mo-l { color: var(--accent); font-weight: 600; }
.rw-mo.is-cushion:not(.is-end) .rw-mo-l { color: var(--text); font-weight: 600; }
.rw-mo:first-child .rw-mo-t { left: 0; transform: none; }
.rw-mo:nth-child(12n) .rw-mo-t { left: auto; right: 0; transform: none; }
.rw-beyond { margin: -6px 0 0; font: 400 13px var(--font-sans); color: var(--text-dim); }

/* what we counted: tap an account to count it or not */
.rw-facts { display: grid; }
.rw-fact { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; min-height: 48px; padding: 10px 0; border: 0; border-bottom: 1px solid var(--border); background: none; color: var(--text); font: 400 14px var(--font-sans); text-align: left; }
.rw-fact:last-child { border-bottom: 0; }
.rw-fact > span:nth-child(2) { display: flex; flex-direction: column; min-width: 0; }
.rw-fact small { font: 400 12px var(--font-sans); color: var(--text-dim); }
.rw-fact .rw-by { margin-top: 2px; font-family: var(--font-mono); font-size: 11px; }
.rw-fact b { font: 600 14px var(--font-mono); font-variant-numeric: tabular-nums; }
.rw-fact-acct { width: 100%; cursor: pointer; border-radius: 0; -webkit-tap-highlight-color: transparent; }
.rw-fact-acct:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 8px; }
@media (hover: hover) { .rw-fact-acct:hover > span:nth-child(2) { color: var(--accent); } }
.rw-fact-acct.is-off { color: var(--text-mid); }
.rw-fact-acct.is-off b { color: var(--text-dim); font-weight: 500; }
.rw-ic { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: var(--surface-2); color: var(--text-mid); }
.rw-ic svg { width: 18px; height: 18px; }
.rw-fact-acct[aria-pressed="true"] .rw-ic { color: var(--accent); }
.rw-cut .rw-ic { background: none; }
.rw-fact-none { display: block; color: var(--text-dim); font-size: 13px; }
.rw2-save { min-height: 48px; padding: 0 22px; border: 0; border-radius: 999px; background: var(--accent-fill); color: var(--on-accent); font: 600 14px var(--font-sans); cursor: pointer; }
.rw2-save:hover { background: var(--accent-fill-hi); }
.rw2-save:disabled { opacity: .6; cursor: default; }
.rw2-status { margin-top: -8px; font: 400 12.5px var(--font-sans); color: var(--text-dim); }
.rw2-status:empty { display: none; }

@media (max-width: 1100px) { .rw2-grid { grid-template-columns: minmax(0, 1fr); } }
@container (max-width: 640px) {
  .rw2-card { padding: 18px 16px; }
  .rw-sent { font-size: 22px; }
  .rw-sent-s { font-size: 16px; }
  .rw-months { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .rw-mo-b { height: 44px; }
  .rw-mo:nth-child(6n) .rw-mo-t { left: auto; right: 0; transform: none; }
  .rw-mo:nth-child(6n + 1) .rw-mo-t { left: 0; transform: none; }
}
@media (max-width: 768px) { .rw2-h .pl-tool-title { font-size: 28px; } }
