/* Session 3b proving shell. Not one of the three screens CLAUDE.md Part 8
   concentrates design effort on — clean and unremarkable, per that section,
   but still follows the same system: one typeface, one accent colour, one
   corner radius, no gradients, no unlabelled icons. */

:root {
  /* D-550 (13 Nov 26): every colour the stylesheet once gave as a fixed value, named. Each holds the value
     it replaced in light and dark alike (no dark-mode value below), so no colour moved in either mode;
     reports/13nov-away-report.md lists each with its class and reason. */
  --dark-site-text-button-ink: #000000;
  --site-button-ink: #ffffff;
  --pr-primary-ink: #ffffff;
  --gauge-band-ink: #1c1c1e;
  --gauge-under-fill: #d1d1d6;
  --gauge-average-fill: #e5e5ea;
  --gauge-prodigious-fill: #ffffff;
  --site-sheet-attention-ink: #000000;
  --site-attention-words-line: rgba(0, 0, 0, 0.55);
  --band-head-ink: #000000;
  --more-tile-ink: #000000;
  --fetch-secondary-ink: #000000;
  --fetch-secondary-line: rgba(0, 0, 0, 0.6);
  --dark-site-secondary-ink: #0d1712;
  --dark-site-is-ready-ink: #000000;
  --idle-warning-ink: #000000;
  --idle-stay-line: #000000;
  --on-photo-fill: rgba(10, 29, 23, 0.86);
  --on-photo-fill-2: rgba(10, 29, 23, 0.5);
  --on-photo-fill-3: rgba(10, 29, 23, 0.1);
  --site-section-viewer-fill: #f7f4ee;
  --on-photo-fill-4: rgba(23, 48, 40, 0.72);
  --on-photo-ink: #f2f3ea;
  --on-photo-line: rgba(166, 193, 177, 0.33);
  --on-photo-fill-5: rgba(23, 48, 40, 0.6);
  --print-fill: #ffffff;
  --print-ink: #111111;
  --print-line: #222222;
  --fo-seg-button-ink: #ffffff;
  --on-photo-fill-6: #1a2d22;
  --on-photo-ink-2: #ffffff;
  --fo-eyebrow-ink: #d8e2d7;
  --on-photo-ink-3: #e3ebe4;
  --print-fill-2: rgba(5, 15, 11, 0.92);
  --on-photo-fill-7: #0a1d17;
  --on-photo-fill-8: rgba(10, 29, 23, 0.83);
  --on-photo-fill-9: rgba(10, 29, 23, 0.36);
  --on-photo-fill-10: rgba(10, 29, 23, 0.05);
  --on-photo-ink-4: rgba(255, 255, 255, 0.92);
  --on-photo-line-2: rgba(255, 255, 255, 0.28);
  --on-photo-fill-11: rgba(255, 255, 255, 0.13);
  --on-photo-fill-12: rgba(9, 23, 16, 0.32);
  --on-photo-fill-13: rgba(9, 23, 16, 0.48);
  --dark-ins-cat-icon-ink: #ffffff;
  --on-photo-fill-14: #050c09;
  --on-photo-fill-15: rgba(10, 29, 23, 0.84);
  --on-photo-fill-16: rgba(10, 29, 23, 0.46);
  --on-photo-fill-17: rgba(10, 29, 23, 0.12);
  --on-photo-fill-18: #1d3a2d;
  --on-photo-fill-19: #2b4d3d;
  --on-photo-fill-20: #3f6453;
  --on-photo-fill-21: #eef3ec;
  --on-photo-fill-22: #e5eee6;
  --on-photo-fill-23: #d6e5da;
  --on-photo-ink-5: #1d3a2d;
  --on-photo-line-3: rgba(255, 255, 255, 0.27);
  --on-photo-shadow: rgba(255, 255, 255, 0.06);
  --on-photo-shadow-2: rgba(255, 255, 255, 0.05);
  --on-photo-line-4: rgba(54, 80, 66, 0.17);
  --on-photo-shadow-3: rgba(54, 80, 66, 0.05);
  --on-photo-shadow-4: rgba(54, 80, 66, 0.03);
  --on-photo-fill-24: rgba(255, 255, 255, 0.16);
  --on-photo-fill-25: rgba(255, 255, 255, 0.72);
  --on-photo-ink-6: #2b4d3d;
  --inc-natives-fill: rgba(255, 255, 255, 0.14);
  --inc-floating-fill: rgba(251, 250, 246, 0.94);
  --inc-floating-ink: #365042;
  --on-photo-fill-26: #10261c;
  --on-photo-fill-27: #1b3a2c;
  --on-photo-fill-28: #2a5040;
  --on-photo-fill-29: #1f3329;
  --on-photo-fill-30: #243b2f;
  --on-photo-fill-31: rgba(255, 255, 255, 0.1);
  --on-photo-line-5: rgba(255, 255, 255, 0.12);
  --on-photo-shadow-5: rgba(255, 255, 255, 0.03);
  --on-photo-shadow-6: rgba(255, 255, 255, 0.02);
  --on-photo-shadow-7: rgba(22, 53, 39, 0.17);
  --shadow: rgba(21, 53, 39, 0.06);
  --shadow-2: rgba(29, 54, 37, 0.14);
  --shadow-3: rgba(29, 54, 37, 0.02);
  --shadow-4: rgba(29, 54, 37, 0.016);
  --shadow-5: rgba(29, 54, 37, 0.09);
  --shadow-6: rgba(29, 54, 37, 0.018);
  --shadow-7: rgba(29, 54, 37, 0.13);
  --on-photo-fill-32: rgba(20, 30, 42, 0.38);
  --on-photo-shadow-8: rgba(18, 32, 25, 0.25);
  --on-photo-shadow-9: rgba(29, 54, 37, 0.094);
  --shadow-8: rgba(29, 54, 37, 0.027);
  --shadow-9: rgba(29, 54, 37, 0.035);
  --shadow-10: rgba(29, 54, 37, 0.1);
  --on-photo-fill-33: rgba(10, 29, 23, 0.08);
  --shadow-11: rgba(21, 53, 39, 0.1);
  --on-photo-fill-34: rgba(255, 255, 255, 0.86);
  --on-photo-ink-7: #17211d;
  --on-photo-ink-8: #f3f2e9;
  --on-photo-fill-35: rgba(18, 43, 33, 0.6);
  --on-photo-line-6: rgba(255, 255, 255, 0.22);
  --inv-primary-ink: #ffffff;
  --on-photo-fill-36: rgba(14, 39, 37, 0.86);
  --on-photo-fill-37: rgba(15, 39, 36, 0.7);
  --on-photo-fill-38: rgba(15, 39, 36, 0.24);
  --on-photo-fill-39: rgba(13, 33, 26, 0.06);
  --on-photo-ink-9: #e9dcc6;
  --due-period-ink: #e2bd87;
  --on-photo-ink-10: #fff8ed;
  --on-photo-ink-11: #eeeee6;
  --due-group-dot-fill: #be9d64;
  --on-photo-fill-40: rgba(15, 39, 36, 0.26);
  --on-photo-fill-41: rgba(13, 33, 26, 0.1);
  --goals-is-feature-fill: #ffffff;
  --goals-is-feature-ink: #ffffff;
  --goals-move-kicker-ink: #e7f2ec;
  --goals-is-feature-ink-2: #eef5f0;
  --ins-see-all-ink: #ffffff;
  --gr-card-line: #a8741a;
  --gr-btn-ink: #ffffff;
  --bsw-explore-open-line: #224938;
  --bsw-explore-open-fill: #224938;
  --bsw-explore-open-ink: #ffffff;
  --shadow-12: rgba(18, 47, 33, 0.035);
  --bsw-cat-bar-fill: #ebe6db;
  --bsw-cat-bar-fill-2: #295140;
  --bsw-cat-bar-fill-3: #8d5f58;
  --bsw-cat-bar-fill-4: #b67f76;
  --bsw-btn-ink: #f3f7f4;
  --dark-bsw-card-line: #405248;
  --dark-bsw-table-line: #2c3d33;
  --dark-bsw-explore-chips-fill: #1a2a21;
  --dark-bsw-alert-fill: #17261e;
  --dark-bsw-is-review-line: #5a4a26;
  --dark-bsw-is-review-fill: #221f14;
  --dark-bsw-is-review-fill-2: #1b1a12;
  --dark-bsw-badge-fill: #24352b;
  --dark-bsw-badge-ink: #c9d6cd;
  --dark-bsw-badge-fill-2: #3a3018;
  --dark-bsw-badge-ink-2: #e8cf8f;
  --alw-tabs-ink: #ffffff;
  --on-photo-fill-42: #2c3a33;
  --on-photo-shadow-10: rgba(34, 51, 68, 0.07);
  --on-photo-fill-43: rgba(14, 26, 20, 0.9);
  --on-photo-fill-44: rgba(16, 28, 22, 0.72);
  --on-photo-fill-45: rgba(16, 28, 22, 0.35);
  --alw-eyebrow-ink: #dbe6df;
  --on-photo-ink-12: #eef3ef;
  --on-photo-ink-13: #dce7e0;
  --on-photo-ink-14: #dbe9e2;
  --alw-is-warn-fill: #8a433c;
  --alw-bar-fill: #ebe6db;
  --alw-rule-block-fill: #4f7a62;
  --alw-is-breach-fill: #c2706e;
  --alw-is-unmeasured-fill: #b9b3a6;
  --shadow-13: rgba(35, 55, 76, 0.02);
  --on-photo-fill-46: #74908a;
  --dark-alw-toolbar-line: #405248;
  --dark-alw-dl-line: #2c3d33;
  --dark-alw-line-fill: #2c3d33;
  --dark-alw-pill-fill: #1a2a21;
  --dark-alw-is-danger-line: #6a3a35;
  --dark-alw-is-danger-fill: #2e1d1a;
  --dark-alw-is-danger-ink: #f0b9b0;
  --dark-alw-is-warn-line: #5a4a26;
  --dark-alw-is-warn-fill: #3a3018;
  --dark-alw-is-warn-ink: #e8cf8f;
  --dark-alw-priority-fill: #2a1d1a;
  --dark-alw-priority-fill-2: #16231c;
  --dark-alw-bar-fill-fill: #7fb08f;
  --dark-alw-tabs-line: #7fb08f;
  --dark-alw-tabs-ink: #0e1a14;
  --spw-tabs-ink: #ffffff;
  --on-photo-shadow-11: rgba(39, 53, 73, 0.05);
  --on-photo-fill-47: #40586a;
  --on-photo-fill-48: rgba(14, 26, 20, 0.82);
  --on-photo-fill-49: rgba(14, 26, 20, 0.35);
  --on-photo-ink-15: #e4eaf0;
  --shadow-14: rgba(31, 41, 55, 0.1);
  --on-photo-shadow-12: rgba(26, 41, 48, 0.027);
  --on-photo-shadow-13: rgba(37, 53, 72, 0.098);
  --on-photo-fill-50: #9cb9c1;
  --spw-badge-fill: rgba(255, 255, 255, 0.9);
  --spw-badge-ink: #3d4a57;
  --spw-empty-line: #cbd3cc;
  --on-photo-line-7: #405248;
  --dark-spw-table-line: #2c3d33;
  --dark-spw-pill-fill: #1a2a21;
  --dark-spw-feature-fill: #17251d;
  --dark-spw-feature-fill-2: #1b2a22;
  --dark-spw-feature-fill-3: #22281e;
  --dark-spw-watch-ink: #e8cf8f;
  --dark-spw-empty-line: #4a5c52;
  --dark-spw-is-dark-line: #7fb08f;
  --dark-spw-is-dark-fill: #7fb08f;
  --dark-spw-is-dark-ink: #0e1a14;
  --shadow-15: rgba(36, 56, 78, 0.086);
  --on-photo-shadow-14: rgba(36, 56, 72, 0.03);
  --on-photo-fill-51: #f2e2d1;
  --on-photo-fill-52: #3d5048;
  --on-photo-shadow-15: rgba(39, 59, 73, 0.125);
  --on-photo-fill-53: rgba(14, 26, 20, 0.3);
  --cfw-tiny-ink: #ffffff;
  --on-photo-fill-54: #ffffff;
  --on-photo-ink-16: #243847;
  --cfw-pulse-fill: #b9754d;
  --shadow-16: rgba(233, 212, 192, 0.3);
  --cfw-priority-state-line: #e8cab2;
  --cfw-priority-dates-line: #ebe5df;
  --on-photo-fill-55: #f7eddd;
  --on-photo-fill-56: #4a5d5b;
  --on-photo-fill-57: rgba(14, 26, 20, 0.6);
  --dark-cfw-seg-fill: #1a2a21;
  --on-photo-fill-58: #2a241c;
  --on-photo-fill-59: #33291f;
  --on-photo-line-8: #5a4a3a;
  --dark-cfw-priority-dates-line: #4a3e33;
  --on-photo-fill-60: #4a3a2a;
  --dark-cfw-priority-button-fill: #7fb08f;
  --dark-cfw-priority-button-ink: #0e1a14;
  --dark-cfw-priority-state-line: #6a5440;
  --shadow-17: rgba(38, 56, 41, 0.125);
  --shadow-18: rgba(33, 52, 38, 0.02);
  --txw-country-line: #bacbbd;
  --shadow-19: rgba(26, 39, 31, 0.1);
  --txw-art-fill: #edf4fe;
  --txw-art-ink: #3f6f9f;
  --txw-art-fill-2: #f8f0e7;
  --txw-art-ink-2: #8a5a2c;
  --on-photo-fill-61: #193e32;
  --on-photo-fill-62: rgba(7, 29, 19, 0.94);
  --on-photo-fill-63: rgba(7, 29, 19, 0.4);
  --on-photo-fill-64: #13211b;
  --on-photo-fill-65: rgba(13, 30, 24, 0.94);
  --on-photo-fill-66: rgba(13, 30, 24, 0.86);
  --on-photo-fill-67: rgba(13, 30, 24, 0.2);
  --on-photo-ink-17: #f4efe3;
  --txw-micro-ink: #e6efe9;
  --txw-file-copy-ink: #ffffff;
  --txw-file-copy-ink-2: #f0f6f1;
  --shadow-20: rgba(21, 41, 32, 0.055);
  --dark-txw-is-waiting-fill: #1a2a21;
  --dark-txw-is-active-fill: #20362a;
  --dark-txw-country-fill: #1f2a33;
  --dark-txw-country-ink: #a9c4dd;
  --dark-txw-art-fill: #2a241c;
  --dark-txw-art-ink: #e8c39f;
  --dark-txw-selectors-line: #405248;
  --dark-txw-country-line: #5f8a6d;
  --dark-txw-tabs-line: #7fb08f;
  --dark-txw-tabs-fill: #7fb08f;
  --dark-txw-tabs-ink: #0e1a14;
  --base: 8px;
  --accent: #2563eb;
  --text: #111827;
  /* D-156, Session 8g: darkened from #6b7280 (4.44:1 on the warm off-white
     page) to reach 4.5:1 there: 4.65:1 on #f7f5f2, 4.84:1 on #f9fafb,
     5.06:1 on white. */
  --text-muted: #686f7c;
  /* Help lines are one colour wherever they sit (Avi's ruling, 4 Oct 26): on a
     card and on the page's own background, the section fade included. 6.41:1
     on the white card, 5.89:1 on the page, 4.72:1 or more on every section's
     fade at its strongest (src/help-line.test.mjs works these out). */
  --text-help: #595f6b;
  --border: #d1d5db;
  --error: #b91c1c;
  --error-bg: #fef2f2;
  /* D-156, Session 8g: "needs attention" notices that are not errors (the
     entry page's period warning, the rates page's note, the net worth
     page's withheld total) sit on pale orange, not pale red; their words
     carry the meaning, the text keeps its own colour (16.3:1). */
  --attention-bg: #fff4e6;
  /* 16 px since 4 Oct 26 (Avi's choice of sample 6; D-224): the one corner
     radius, on every card, band, box, button and tile. 8 px before. */
  --radius: 16px;
  --bg: #f9fafb;
  --card-bg: #ffffff;

  /* Part 8: four type sizes, Apple's iOS text styles (Footnote, Body,
     Title 2, Large Title), nothing off the scale. Every font-size in
     this file is one of these four — meta text, body/controls, headings,
     the one headline figure. */
  --size-meta: 13px;
  --size-body: 17px;
  --size-heading: 22px;
  --size-headline: 34px;

  /* Part 8 as revised 28 Sep 26: Apple's system colours, copied from the
     HIG Color page (developer.apple.com, color.json, read 28 Sep 26; Apple
     last changed the values 9 Jun 2025). Light mode takes Apple's
     "Increased Contrast" value, because every default fails 4.5:1 as text
     on white. Each status colour is 4.5:1 or better as text on a card
     (white here, 1C1C1E in dark mode), never on the page background.
     Defined only: no page uses these yet. Track 1 builds move the pages
     onto them and retire --accent, --bg, --card-bg and --error above. */
  --color-accent: rgb(30, 110, 244);   /* blue, Increased Contrast: 4.57:1 on white */
  --plus-ink: #ffffff;                 /* the plus on the "+" mark: white on the accent, 4.57:1 */
  --color-red: rgb(233, 21, 45);       /* money owed; "not saved": 4.56:1 on white */
  --color-orange: rgb(197, 83, 0);     /* needs attention: 4.55:1 on white */
  --color-green: rgb(0, 137, 50);      /* saved: 4.54:1 on white */
  --color-page: #f7f5f2;               /* warm off-white page (not an Apple colour) */
  --color-card: #ffffff;
  /* One hue per section, Apple's blues, teals, indigos and purples only,
     for the soft fade at the top of each section's page. Placeholders:
     Avi chooses the colours from screenshots (register item 104). */
  /* Session 8i follow-up (Avi's choice, 1 Oct 26, D-180): Summary indigo,
     Accounts teal, values as on the sample page Avi chose from (d0c7655). */
  --section-summary: rgb(97, 85, 245);    /* indigo */
  --section-accounts: rgb(0, 195, 208);   /* teal */
  /* Session 8j follow-up (Avi's choice on the iPhone, 2 Oct 26): Entry in
     mint, Apple's system mint default (HIG color.json, read 1 Oct 26; last
     changed 16 Dec 2025). */
  --section-entry: rgb(0, 200, 179);      /* mint */
  --section-exceptions: rgb(203, 48, 224); /* purple */
  --section-viewer: rgb(0, 192, 232);     /* cyan */
  /* Overnight 6 Oct 26 (Avi's ruling, Part 6; D-248): every page has a section
     colour. Two hues the palette already held, as More's and Add's tiles:
     More in the blue of the "An account" tile, Record a document in the brown
     of its own tile. The other pages reuse the tokens above. */
  --section-more: rgb(64, 156, 255);      /* blue (.tile-blue) */
  --section-document: rgb(196, 150, 112); /* brown (.tile-brown) */
  /* 4.2 Investments (D-386; 4.1 Q5, D-385): the section's one hue, violet, on its tile's heading (5.71:1 on white) and its
     page's fade; never red, orange or green (Part 8). */
  --section-investments: rgb(137, 68, 171);  /* Part A, 21 Oct 26: Apple's increased-contrast purple, 6.04:1 on white; the violet
                                                  rgb(124, 58, 237) read as the Summary headings' indigo rgb(86, 74, 222) */
  /* D-550, the follow-up of 13 Nov 26, item 5 (question 1 of reports/13nov-away-report.md): the tint and ink each
     script set as a fixed value, named. Each holds the value it replaced in light and dark alike (no dark-mode value),
     so no colour moved in either mode. Insurance's categories (src/insurance-dash-logic.ts CATEGORY_LOOK): */
  --ins-life-tint: #edf3ff; --ins-life-ink: #5c8add;
  --ins-health-tint: #eaf7f1; --ins-health-ink: #4c9e7c;
  --ins-motor-tint: #f1edff; --ins-motor-ink: #8b72d5;
  --ins-home-tint: #fbf3e7; --ins-home-ink: #ca9957;
  --ins-landlord-tint: #eaf6f4; --ins-landlord-ink: #50a598;
  --ins-income-tint: #efeffc; --ins-income-ink: #848ad2;
  --ins-travel-tint: #e9f3fc; --ins-travel-ink: #5a98c5;
  --ins-other-tint: #eef1f6; --ins-other-ink: #7a8798;
  /* Debt's kinds (src/debts-page.ts LOOK) and Phone & Access's kinds of service (src/code-phones-page.ts LOOK and
     SERVICE_LOOK), which share four of Debt's pairs: */
  --kind-green-tint: #e7f0ea; --kind-green-ink: #3e6f57;
  --kind-blue-tint: #e9eff7; --kind-blue-ink: #56789f;
  --kind-amber-tint: #f6eee3; --kind-amber-ink: #9b6d35;
  --kind-violet-tint: #eeecf5; --kind-violet-ink: #6d6396;
  --kind-grey-tint: #eef0ee; --kind-grey-ink: #5f6b66;
  --kind-rose-tint: #f5ebe8; --kind-rose-ink: #9a5d4f;
}

/* The same tokens in dark mode: treatment B (D-180, 1 Oct 26), with the card
   on Apple's Gray 6 dark (1C1C1E) since 4 Oct 26 (D-224). Red and orange take
   Apple's increased-contrast dark values; every ratio below is on that card. */
@media (prefers-color-scheme: dark) {
  :root {
    --color-accent: rgb(0, 145, 255);   /* focus ring and primary button: 5.27:1 on 1C1C1E (3:1 needed) */
    --plus-ink: #000000;                /* the plus on the "+" mark: black on the accent, 6.5:1 */
    /* Dark treatment B (Avi's choice, 1 Oct 26, D-180): Apple's
       increased-contrast red and orange, on the Gray 5 card. */
    --color-red: rgb(255, 97, 101);     /* 5.79:1 on 1C1C1E */
    --color-orange: rgb(255, 160, 86);  /* 8.44:1 on 1C1C1E */
    --color-green: rgb(48, 209, 88);    /* 8.42:1 on 1C1C1E */
    --color-page: #000000;
    /* Apple's Gray 6 dark, R 28 G 28 B 30 (HIG Color page, read 4 Oct 26; its
       last change is dated 16 December 2025). Avi's choice of sample 6, 4 Oct 26
       (D-224); Gray 5 (2C2C2E) before, D-180. 1.23:1 against the black page. */
    --color-card: #1c1c1e;
    --section-summary: rgb(109, 124, 255);
    --section-accounts: rgb(0, 210, 224);
    --section-entry: rgb(0, 218, 195);
    --section-exceptions: rgb(219, 52, 242);
    --section-viewer: rgb(60, 211, 254);
    --section-more: rgb(100, 180, 255);
    --section-document: rgb(214, 172, 136);
    --section-investments: rgb(218, 143, 255);  /* Part A, 21 Oct 26: Apple's increased-contrast purple, 7.58:1 on the Gray 6 card; the violet rgb(190, 160, 255) read as the headings' rgb(167, 170, 255) */
  }

  /* D-156, Session 8g: the primary action in dark mode takes Apple's dark
     accent with a dark label. White on rgb(0, 145, 255) is 3.23:1 and
     fails; black is 6.49:1. The secondary and text buttons are unchanged. */
  button:not(.secondary):not(.text-button),
  a.primary {
    background: var(--color-accent);
    color: var(--dark-site-text-button-ink);
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: calc(var(--base) * 3);
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  /* Text with no size of its own (the 404 page's paragraph) would take the
     browser's 16px, which is off Part 8's scale since 28 Sep 26. */
  font-size: var(--size-body);
}

/* D-567 (16 Nov 26): a link, box, list or text area that no class rule colours takes its words' named colour, never
   the browser's own blue or black. :where() weighs nothing, so every existing rule still wins (measured unchanged on
   every page, light and dark, the day it was added); tests/fixed-colours.py check 6 holds it. */
:where(a, input, select, textarea) {
  color: inherit;
}

.card {
  width: 100%;
  max-width: 360px;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: calc(var(--base) * 4);
}

/* Part E, 4b (Avi's ruling of 4 Oct 26): page headings at weight 600, as the
   sheets' names; a heading's own default is 700. */
h1 {
  font-size: var(--size-heading);
  font-weight: 600;
  margin: 0 0 calc(var(--base) * 3);
}

/* Part E, 4a: the benchmark's explanation, folded under one line. */
.benchmark-how > summary {
  padding: calc(var(--base) * 1) 0;
  cursor: pointer;
}

label {
  display: block;
  font-size: var(--size-meta);
  color: var(--text-muted);
  margin-bottom: calc(var(--base) * 1);
}

input {
  width: 100%;
  font-size: var(--size-body); /* 16px or more avoids iOS auto-zoom on focus */
  min-height: calc(var(--base) * 6);
  padding: 0 calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: inherit;
}

input:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

/* The overnight session of 25-26 Oct 26, Part G (Avi, 25 Oct 26): a file box
   took the base rule's 48 px minimum height, and Safari draws its "Choose
   File" button at the top left of the box, so the button sat at the top of a
   tall empty box. One rule for every file box (the Import cards' three today):
   no minimum height, the same padding above and below, so the box hugs its
   button, centred, at the base rule's left and right padding. The second
   selector outranks ".sheet-card form input", which sets the same 48 px. */
input[type="file"],
.sheet-card form input[type="file"] {
  min-height: 0;
  padding: var(--base) calc(var(--base) * 2);
  line-height: normal;
}

input[type="file"]::file-selector-button {
  font: inherit;
  margin: 0 calc(var(--base) * 2) 0 0;
}

/* Session 8d: selects take the same ring (the browser's own was showing on
   every select, found in the 8d screenshot check). */
select:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

button {
  width: 100%;
  font-family: inherit; /* browsers do not pass the typeface to buttons (Session 8c: Sign out was Arial) */
  font-size: var(--size-body);
  font-weight: 600;
  min-height: calc(var(--base) * 6);
  padding: 0 calc(var(--base) * 2);
  border: none;
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--site-button-ink);
  cursor: pointer;
}

/* The long session of 5 Nov 26's closing: 0.75, not 0.6, so a disabled button's words still read at 4.5:1 or more
   through its fade (Import's "Run the dry run" read 3.82:1 at 0.6 on the save bar, D-495's contrast as seen). */
button:disabled {
  opacity: 0.75;
  cursor: default;
}

button.secondary,
a.secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  width: 100%;
  font-size: var(--size-body);
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  min-height: calc(var(--base) * 6);
  padding: 0 calc(var(--base) * 2);
  background: transparent;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text);
  cursor: pointer;
}

a.secondary {
  margin-bottom: calc(var(--base) * 2);
}

.error {
  font-size: var(--size-meta);
  color: var(--error);
  background: var(--error-bg);
  border-radius: var(--radius);
  padding: calc(var(--base) * 1) calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 2);
}

.error[hidden] {
  display: none;
}

#signed-in-view[hidden] {
  display: none;
}

#signed-in-view p {
  font-size: var(--size-meta);
  color: var(--text-muted);
}

#signed-in-view strong {
  display: block;
  font-size: var(--size-body);
  color: var(--text);
  margin-bottom: calc(var(--base) * 2);
  word-break: break-all;
}

/* Session 6 — the net worth summary. Monarch's structure (Part 8): the
   figure, the date and staleness readable at arm's length, without
   scrolling. Same tokens as the sign-in shell above — one typeface, one
   accent, one radius. Tabular figures throughout so columns align. */

body.report-body {
  display: block;
  align-items: initial;
  justify-content: initial;
  padding: calc(var(--base) * 3) calc(var(--base) * 2);
}

.report-card {
  width: 100%;
  max-width: 480px;
  margin: 0 auto;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: calc(var(--base) * 4) calc(var(--base) * 3);
}

#gate {
  font-size: var(--size-body);
  color: var(--text-muted);
}

#gate[hidden] {
  display: none;
}

#content[hidden] {
  display: none;
}

/* A plain text link, not a button: no fill, no accent colour (Part 8 keeps
   the accent for the primary action). Tall enough to hit with a thumb. */
.back-link {
  display: inline-flex;
  align-items: center;
  min-height: calc(var(--base) * 6);
  margin-bottom: calc(var(--base) * 1);
  font-size: var(--size-meta);
  color: var(--text-muted);
  text-decoration: underline;
}

.back-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.report-controls {
  display: flex;
  gap: calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 2);
}

.report-controls > div {
  flex: 1;
}

.report-controls label {
  margin-bottom: calc(var(--base) * 1);
}

.report-controls select,
.report-controls input {
  width: 100%;
  font-size: var(--size-body);
  min-height: calc(var(--base) * 6);
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: inherit;
  background: var(--card-bg);
  color: var(--text);
}

#rate-date {
  font-size: var(--size-meta);
  color: var(--text-muted);
  margin: 0 0 calc(var(--base) * 2);
}

#rate-date[hidden] {
  display: none;
}

/* Session 7 (D-94): when the figures on screen were read. Same style as
   the rate date directly above it. */
#read-at {
  font-size: var(--size-meta);
  color: var(--text-muted);
  margin: 0 0 calc(var(--base) * 2);
}

#read-at[hidden] {
  display: none;
}

.headline {
  display: block;
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  border-radius: var(--radius);
  padding: calc(var(--base) * 2) calc(var(--base) * 1);
  margin: 0 0 calc(var(--base) * 2) calc(var(--base) * -1);
  cursor: pointer;
  font-family: inherit;
}

.headline:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.headline[hidden] {
  display: none;
}

#headline-currency {
  display: block;
  font-size: var(--size-meta);
  color: var(--text-muted);
  margin-bottom: calc(var(--base) * 1);
}

#headline-currency[hidden] {
  display: none;
}

#headline-amount {
  display: block;
  font-size: var(--size-headline);
  font-weight: 600;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}

#withheld {
  font-size: var(--size-body);
  color: var(--text);
  background: var(--attention-bg);
  border-radius: var(--radius);
  padding: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
}

#withheld[hidden] {
  display: none;
}

#load-error[hidden] {
  display: none;
}

#lines {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--border);
}

.report-line {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0 calc(var(--base) * 2);
  padding: calc(var(--base) * 2) 0;
  border-bottom: 1px solid var(--border);
  font-variant-numeric: tabular-nums;
}

.report-line-label {
  font-size: var(--size-body);
  color: var(--text);
  grid-column: 1;
}

.report-line-native {
  font-size: var(--size-meta);
  color: var(--text-muted);
  grid-column: 1;
}

.report-line-converted {
  grid-column: 2;
  grid-row: 1;
  font-size: var(--size-body);
  color: var(--text);
  text-align: right;
}

.report-line-flag {
  display: inline-block;
  grid-column: 1 / -1;
  font-size: var(--size-meta);
  color: var(--text-muted);
}

/* Session 7 (D-93): which build this page is, in small muted text at the
   foot of the card on every page. Filled in by app/build-id.js. */
.build-id {
  font-size: var(--size-meta);
  color: var(--text-muted);
  margin: calc(var(--base) * 3) 0 0;
  font-variant-numeric: tabular-nums;
}

/* Session 8 — the entry screen (Copilot Money's craft, designed from
   scratch: Part 8), the sign-out row on every signed-in page, and the
   stale-count line on the net worth page. Same tokens: one typeface, one
   accent (the Save button, or "Enter another" once the form is replaced), one
   radius, no shadows, the four type sizes. */

[hidden] {
  display: none !important;
}

/* Back on the left, Sign out on the right: both words, never icons. */
.top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: calc(var(--base) * 1);
}

.top-row .back-link {
  margin-bottom: 0;
}

/* Session 8j (A6): "Back to start" on every owner page, and beside it the
   link back to where the page was opened from, when there is one. */
.top-links {
  display: flex;
  flex-wrap: wrap;
  column-gap: calc(var(--base) * 3);
}

button.text-button {
  width: auto;
  min-height: calc(var(--base) * 6);
  padding: 0 calc(var(--base) * 1);
  margin-right: calc(var(--base) * -1);
  background: none;
  border: none;
  font-size: var(--size-meta);
  font-weight: 400;
  color: var(--text-muted);
  text-decoration: underline;
}

button.text-button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* D-394 (25 Oct 26): a holding row's two actions, Update units and Correct, under the row on the account page and on the
   Investments page (there as links to the account's page): the text-button look, in one row, a line under them as a row has. */
.row-actions {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2);
  padding: 0 0 var(--base) calc(var(--base) * 2);
  border-bottom: 1px solid var(--border);
}

.row-actions > .text-button {
  width: auto;
  min-height: calc(var(--base) * 5);
  margin: 0;
  padding: 0 var(--base);
  background: none;
  border: none;
  font-size: var(--size-meta);
  font-weight: 400;
  color: var(--text-muted);
  text-decoration: underline;
}

.row-actions > a.text-button:focus-visible,
.row-actions > button.text-button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.holding-block > .row-button {
  border-bottom: none;
}

.holding-block:last-child > .row-actions,
.card-rows > .row-actions:last-child {
  border-bottom: none;
}

/* The start page's primary action: the accent, like the Save button. */
a.primary {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  font-size: var(--size-body);
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  min-height: calc(var(--base) * 6);
  padding: 0 calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 2);
  border-radius: var(--radius);
  background: var(--accent);
  color: var(--pr-primary-ink);
}

#stale-count {
  font-size: var(--size-body);
  color: var(--text);
  margin: 0 0 calc(var(--base) * 2);
}

#entry-form select,
#entry-form input,
#rates-form input {
  width: 100%;
  font-size: var(--size-body);
  min-height: calc(var(--base) * 6);
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: inherit;
  background: var(--card-bg);
  color: var(--text);
  margin-bottom: calc(var(--base) * 1);
}

#entry-form label,
#rates-form label {
  margin-top: calc(var(--base) * 1);
}

.amount-row {
  display: flex;
  gap: calc(var(--base) * 1);
}

#entry-form #amount {
  flex: 1;
  min-width: 0;
  font-variant-numeric: tabular-nums;
}

#entry-form :is(#currency, #update-currency) {
  width: auto;
  flex: 0 0 auto;
}

.field-note {
  font-size: var(--size-meta);
  color: var(--text-help);
  margin: 0 0 calc(var(--base) * 1);
  font-variant-numeric: tabular-nums;
}

.notice {
  font-size: var(--size-meta);
  color: var(--text);
  background: var(--attention-bg);
  border-radius: var(--radius);
  padding: calc(var(--base) * 1);
  margin: 0 0 calc(var(--base) * 1);
}

/* Session 8e: the Add pages' "More details (optional)" fold looks like the
   entry screen's Source row. */
#source-details,
.more-details {
  margin: calc(var(--base) * 1) 0 calc(var(--base) * 2);
}

#source-details summary,
.more-details summary {
  font-size: var(--size-meta);
  color: var(--text-muted);
  min-height: calc(var(--base) * 6);
  display: flex;
  align-items: center;
  cursor: pointer;
}

/* Save stays at the bottom of the screen, in reach of the thumb. */
.save-bar {
  position: sticky;
  bottom: 0;
  background: var(--card-bg);
  padding: calc(var(--base) * 2) 0;
  margin-top: calc(var(--base) * 1);
}

.confirmation {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: calc(var(--base) * 3);
}

.confirmation:focus {
  outline: none;
}

.confirmation h2 {
  font-size: var(--size-heading);
  margin: 0 0 calc(var(--base) * 2);
}

.confirmation p {
  font-size: var(--size-body);
  margin: 0 0 calc(var(--base) * 1);
}

.confirmation p.field-note {
  font-size: var(--size-meta);
}

.confirmation .confirm-figure {
  font-size: var(--size-headline);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}

.confirmation .confirm-figure.long {
  font-size: var(--size-heading);
}

.confirmation .confirm-figure .confirm-owed {
  color: var(--color-red);
}

.confirm-currency {
  font-size: var(--size-heading);
  font-weight: 600;
  color: var(--text-muted);
}

.confirmation button {
  margin-top: calc(var(--base) * 2);
}

dialog {
  width: calc(100% - var(--base) * 4);
  max-width: 400px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: calc(var(--base) * 3);
  color: var(--text);
  background: var(--card-bg);
}

dialog::backdrop {
  background: rgba(17, 24, 39, 0.4);
}

dialog p {
  font-size: var(--size-body);
  margin: 0 0 calc(var(--base) * 2);
}

dialog button + button,
dialog #reason-block {
  margin-top: calc(var(--base) * 1);
}

#form-note {
  font-size: var(--size-body);
  color: var(--text);
}

/* Session 8b — T8 on the net worth page (rulings 4a to 4c). The contingent and
   legal-total lines sit under the total, like the stale count. Records not
   counted are listed apart at the foot, in their own currency only, with no
   converted figure and no total. Same tokens and type sizes. */
#contingent,
#legal-total {
  font-size: var(--size-body);
  color: var(--text);
  margin: 0 0 calc(var(--base) * 2);
}

#not-counted {
  margin-top: calc(var(--base) * 4);
}

#not-counted h2 {
  font-size: var(--size-body);
  font-weight: 600;
  margin: 0 0 calc(var(--base) * 1);
}

#not-counted-lines {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--border);
}

/* Session 8c — the viewer's list (YNAB's clarity, Part 8: plain sentences,
   no jargon, no abbreviations) and the owner's exception list. Same tokens:
   one typeface, one accent, one radius, no shadows, the four type sizes. */
.list-intro {
  font-size: var(--size-body);
  color: var(--text);
  margin: 0 0 calc(var(--base) * 3);
}

.list-group {
  margin-top: calc(var(--base) * 4);
}

.list-group h2 {
  font-size: var(--size-heading);
  margin: 0 0 calc(var(--base) * 1);
}

.list-items {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--border);
}

.list-item {
  padding: calc(var(--base) * 2) 0;
  border-bottom: 1px solid var(--border);
}

.list-item h3 {
  font-size: var(--size-body);
  font-weight: 600;
  margin: 0 0 calc(var(--base) * 1);
}

.list-line {
  font-size: var(--size-body);
  margin: 0 0 calc(var(--base) * 1);
  font-variant-numeric: tabular-nums;
}

.list-line.muted {
  color: var(--text-muted);
}

.list-documents {
  margin-top: calc(var(--base) * 1);
}

.list-document {
  padding-left: calc(var(--base) * 2);
  border-left: 1px solid var(--border);
  margin-bottom: calc(var(--base) * 1);
}

.list-line.filed-at {
  font-size: var(--size-meta);
  color: var(--text-muted);
  overflow-wrap: anywhere;
}

.closed-box {
  margin-top: calc(var(--base) * 4);
}

.closed-box summary {
  font-size: var(--size-body);
  font-weight: 600;
  min-height: calc(var(--base) * 6);
  display: flex;
  align-items: center;
  cursor: pointer;
}

/* Session 8d: the exchange-rates page's table. Tabular figures so the rates
   align (Part 8); sizes, gaps and borders from the tokens above. */
.rates-table {
  width: 100%;
  border-collapse: collapse;
  margin: calc(var(--base) * 2) 0;
  font-size: var(--size-body);
}

.rates-table th,
.rates-table td {
  text-align: left;
  padding: var(--base) 0;
  border-bottom: 1px solid var(--border);
}

.rates-table thead th {
  font-size: var(--size-meta);
  color: var(--text-muted);
  font-weight: 400;
}

.rates-table tbody th {
  font-weight: 400;
}

.rates-table thead th:not(:first-child) {
  text-align: right;
}

.rates-table td {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

/* The brief of 12 Nov 26, Part 10 (D-544 (4)): each figure in its own column, kept clear of the one before it and never
   broken across lines, right-aligned under its heading (the harness's "columns" check measures it). */
.rates-table :is(th, td):not(:first-child) {
  padding-left: calc(var(--base) * 2);
  white-space: nowrap;
}

/* The brief of 12 Nov 26, Part 8 (D-544 (4)): "a long title wraps at 28 px". A panel's title too long for one line at
   38 px is marked long-title by the shared panel code (src/panel-title.ts) and set at 28 px, wrapping, never cut. */
@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-top .entry-bar .entry-bar-title.long-title,
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-head .record-title.long-title,
  body.sheet-body:not(.section-viewer) .records-quick #search-view .entry-bar h2.long-title,
  body.sheet-body:not(.section-viewer) .search-view.sheet-search .entry-bar h2.long-title,
  body.sheet-body:not(.section-viewer) .records-quick #entry-form #record-title.long-title,
  body.sheet-body:not(.section-viewer) .ins .ins-drawer-title h2.long-title,
  body.sheet-body:not(.section-viewer) .ins .inv-drawer-title.long-title,
  body.sheet-body:not(.section-viewer) .inc .inc-drawer-title.long-title,
  body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-drawer-title.long-title,
  /* What's Due's item panel and its information panel set their heading by id (38 px), which outranked the lines above. */
  body.sheet-body:not(.section-viewer) #due-sheet .due-sheet-title.long-title,
  body.sheet-body:not(.section-viewer) #due-info-sheet .due-sheet-title.long-title {
    font-size: var(--size-display);
    line-height: 1.15;
    white-space: normal;
    overflow-wrap: anywhere;
  }
}

/* The brief of 12 Nov 26 (D-544 (4), completing Part 8's one bar): from 768 px the shared search is a panel like every
   other, so its name is the panel title, Georgia 38 px under the ✕, 28 px and wrapping when too long for one line
   (src/panel-title.ts marks it). It was the bar's 17 px, the one panel left at that size. */
@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) .search-view.sheet-search .entry-bar {
    display: block;
  }
  body.sheet-body:not(.section-viewer) .search-view.sheet-search .entry-bar > .entry-bar-space {
    display: none;
  }
  body.sheet-body:not(.section-viewer) .search-view.sheet-search .entry-bar h2 {
    margin: calc(var(--base) * 2) 0 0;
    font-family: Georgia, "Times New Roman", serif;
    font-size: var(--size-headline);
    font-weight: 400;
    line-height: 1.05;
    letter-spacing: -0.5px;
    white-space: normal;
    text-align: left;
  }
}

/* Session 8e — the Import page. Same tokens, same four sizes. Section 1's
   lines wrap anywhere, so a long line never widens the page. */
/* (Part G, 25-26 Oct 26: the #import-form rules went; no page has that id since the staged import, 16 Oct 26.
   The file box takes the shared input[type="file"] rule.) */

#report h2 {
  font-size: var(--size-heading);
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 1);
}

.report-lines {
  font-size: var(--size-meta);
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
  padding-left: calc(var(--base) * 3);
  margin: 0 0 calc(var(--base) * 2);
}

.check-row {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1);
  font-size: var(--size-body);
  color: var(--text);
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 1);
}

.check-row input {
  width: auto;
  min-height: 0;
  margin: 0;
}
/* D-590 (12), the overnight brief of 18 Nov 26, Part 4B (8): the site's standard tick box, 24 px, in the accent; the
   label round it is the tap target (the whole row where a sheet's row holds it). */
.check-row input[type="checkbox"],
.check-row input[type="radio"] {
  flex: none;
  width: 24px;
  height: 24px;
  accent-color: var(--color-accent);
}

#report details summary {
  font-size: var(--size-meta);
  color: var(--text-muted);
  min-height: calc(var(--base) * 6);
  display: flex;
  align-items: center;
  cursor: pointer;
}

/* Session 8e (Avi's rulings B1–B3): the entries under "Stays with you". */
#choices select,
#choices input {
  width: 100%;
  font-size: var(--size-body);
  min-height: calc(var(--base) * 6);
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  font-family: inherit;
  background: var(--card-bg);
  color: var(--text);
  margin-bottom: calc(var(--base) * 1);
}

/* Session 8p (the full sweep's first measure of Section 2, D-209): its choice
   boxes take the shared look of every choice box, as the report controls' and
   the sheets' do; without it Mac Safari drew its own box and ignored the size. */
#choices select {
  -webkit-appearance: none;
  appearance: none;
  padding-right: calc(var(--base) * 5);
  background-image: url("select-arrow.svg");
  background-repeat: no-repeat;
  background-position: right calc(var(--base) * 2) center;
}

#choices label {
  margin-top: calc(var(--base) * 1);
  overflow-wrap: anywhere;
}

/* Session 8h — the balance sheet, the Accounts page and an account's history
   (D-156, D-170). The first pages on the revised look: white cards on the warm
   page, Summary blue fading from the top of the page into the page colour,
   behind the top bar only (never behind text or figures, which sit on cards;
   off when printing and under prefers-contrast: more). Red means money owed
   and nothing else; orange means needs attention, always with its words. Same
   four sizes, one radius, no shadows. These pages follow the colour scheme,
   so their text colours are set here for dark mode too. */

body.sheet-body {
  /* The page's one section hue: Summary blue on the balance sheet; the
     Accounts page and an account's history take the Accounts colour (Avi's
     close-out ruling, 29 Sep 26; D-170). */
  --section: var(--section-summary);
  display: block;
  align-items: initial;
  justify-content: initial;
  padding: calc(var(--base) * 3) calc(var(--base) * 2);
  background-color: var(--color-page);
  background-image: linear-gradient(to bottom,
    color-mix(in srgb, var(--section) 16%, var(--color-page)) 0,
    var(--color-page) calc(var(--base) * 40));
  background-repeat: no-repeat;
}

@media (prefers-color-scheme: dark) {
  /* Dark treatment B (D-180): white text and a lighter grey on the Gray 5 card. */
  body.sheet-body {
    --text: #ffffff;              /* 17.01:1 on 1C1C1E */
    --text-muted: #c7c7cc;        /* 10.10:1 on 1C1C1E */
    --text-help: #c7c7cc;         /* 10.10:1 on the card, 9.79:1 or more on every fade */
    --border: #3a3a3c;
    --card-bg: #1c1c1e;           /* Apple's Gray 6 dark (D-224) */
    color: var(--text);
  }
}

body.sheet-body.section-accounts {
  --section: var(--section-accounts);
}

/* Session 8j: the entry screen's own section colour, mint (Avi, 2 Oct 26). */
body.sheet-body.section-entry {
  --section: var(--section-entry);
}

/* 4.2 Investments (D-386): the section's page takes its own hue (D-385). */
body.sheet-body.section-investments {
  --section: var(--section-investments);
}

@media print, (prefers-contrast: more) {
  body.sheet-body {
    background-image: none;
  }
}

.sheet-page {
  max-width: 1040px;
  margin: 0 auto;
}

.sheet-page h1 {
  font-size: var(--size-heading);
  margin: 0 0 calc(var(--base) * 2);
}

.sheet-card {
  background: var(--color-card);
  border-radius: var(--radius);
  padding: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
  color: var(--text);
}

.sheet-card h2 {
  font-size: var(--size-body);
  font-weight: 600;
  margin: 0 0 calc(var(--base) * 2);
}

/* Fixes session, 6 Oct 26 (D-251): the place an alert item moves to takes a
   brief tint of the page's own section hue (src/arrival.ts), then fades. Its
   rows stay on the card's own colour, so every figure keeps the contrast it
   has on the card (money owed is 4.56:1 on white, with no room for a tint);
   the tint shows round them and behind the heading. Under "reduce motion"
   the tint appears and goes without the fade. */
.sheet-card.arrived {
  background-color: color-mix(in srgb, var(--section) 24%, var(--color-card));
}
.sheet-card.arrived-fading {
  transition: background-color 500ms ease-out;
}
.sheet-card.arrived > .sheet-list,
.sheet-card.arrived-fading > .sheet-list {
  background-color: var(--color-card);
}
@media (prefers-reduced-motion: reduce) {
  .sheet-card.arrived-fading {
    transition: none;
  }
}

.sheet-meta {
  font-size: var(--size-meta);
  color: var(--text-muted);
  margin: 0 0 calc(var(--base) * 1);
}

/* D-408: the "Rates of <date>" line is a link to Exchange rates' "Rates in use"
   card at that date, on Summary, Accounts, Net worth and the Balance sheet: the
   line's own muted words, underlined, never the browser's blue. */
#rate-date a {
  color: inherit;
  text-decoration: underline;
}

.sheet-headline {
  font-size: var(--size-headline);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  margin: 0 0 calc(var(--base) * 1);
  overflow-wrap: anywhere;
}

.sheet-attention {
  font-size: var(--size-body);
  color: var(--color-orange);
  margin: 0 0 calc(var(--base) * 1);
}

/* The net worth page's own #stale-count and #withheld rules would otherwise
   win here; their pale box would carry light text in dark mode. */
.sheet-body #stale-count,
.sheet-body #withheld {
  color: var(--color-orange);
  background: none;
  padding: 0;
  margin: 0 0 calc(var(--base) * 1);
}

.sheet-attention-word {
  font-size: var(--size-meta);
  color: var(--color-orange);
}

.sheet-figure {
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.sheet-figure.owed {
  color: var(--color-red);
}

.sheet-actions {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 1);
  margin-top: calc(var(--base) * 2);
}

.sheet-actions button.secondary,
.sheet-actions a.secondary {
  width: auto;
  flex: 1 1 calc(var(--base) * 18);
  margin: 0;
}

.sheet-columns {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0 calc(var(--base) * 2);
}

@media (min-width: 1140px) { /* Session 8k: 900 px of content beside the 240 px sidebar (D-195) */
  .sheet-columns {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

/* The composition bar (item 91): decoration only, hidden from screen readers;
   Session 8k (D-193): each category in its own colour, named in the list. */
.sheet-bar {
  display: flex;
  height: calc(var(--base) * 2);
  border-radius: var(--radius);
  overflow: hidden;
  margin: 0 0 calc(var(--base) * 2);
  background: var(--border);
}

.sheet-bar-segment {
  display: block;
  height: 100%;
}

/* Session 8k (D-193): each segment is drawn in its category's colour (below). */

.sheet-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--border);
}

.sheet-row {
  border-bottom: 1px solid var(--border);
  font-size: var(--size-body);
}

.sheet-row.sheet-meta {
  padding: calc(var(--base) * 2) 0;
  margin: 0;
}

/* .sheet-row-plain (Session 8l): the same row where it is not a link: the
   viewer's balance sheet, whose categories open nothing (D-155). */
.sheet-row-link,
.sheet-row-plain {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0 calc(var(--base) * 2);
  padding: calc(var(--base) * 2) 0;
  min-height: calc(var(--base) * 6);
  color: var(--text);
  text-decoration: none;
}

.sheet-row-link > .sheet-figure,
.sheet-row-plain > .sheet-figure {
  grid-column: 2;
  grid-row: 1;
  text-align: right;
}

.sheet-row-link > :not(.sheet-figure) {
  grid-column: 1 / -1;
}

.sheet-row-link > .sheet-row-name,
.sheet-row-plain > .sheet-row-name {
  grid-column: 1;
  grid-row: 1;
}

.sheet-row-link .sheet-meta {
  margin: 0;
}

.sheet-chevron {
  font-size: var(--size-meta);
  color: var(--text-muted);
  text-decoration: underline;
}

/* 5 Oct 26 (Avi's ruling, 4 Oct 26): the same row where a tap unfolds its
   details in place instead of opening a page: the viewer's list, which is the
   owner's Accounts list read-only. A button drawn as the row; its details sit
   under it, inside the same list row. */
button.sheet-row-link[type] {
  width: 100%;
  margin: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  color: var(--text); /* a button's own dark-mode label colour is for filled buttons: this row is text on the card */
  font-size: var(--size-body);
  font-weight: 400;
  text-align: left;
  cursor: pointer;
}

.sheet-figure.none {
  font-weight: 400;
  color: var(--text-muted);
}

.row-details {
  padding: 0 0 calc(var(--base) * 2);
}

.row-details[hidden] {
  display: none;
}

.row-details > .list-line {
  margin: 0 0 var(--base);
}

.sheet-row-link:focus-visible,
.sheet-body a:focus-visible,
.sheet-body button:focus-visible,
.sheet-body select:focus-visible,
.sheet-body input:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.sheet-foot {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  font-size: var(--size-body);
  font-weight: 600;
  margin: calc(var(--base) * 2) 0 0;
}

.sheet-card h2.sheet-foot {
  margin-top: 0;
}

.sheet-group {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  font-size: var(--size-meta);
  font-weight: 600;
  color: var(--text-muted);
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 1);
}

/* Each control keeps its full text; on a phone they sit one above the other. */
.sheet-body .report-controls {
  flex-wrap: wrap;
}

.sheet-body .report-controls > div {
  min-width: calc(var(--base) * 20);
}

/* Session 8h follow-up (Avi's iPhone, 30 Sep 26): Safari gives a date box its
   own minimum width, so at 100% of its column it ran past the card's edge.
   Here it may shrink to its column and never exceed it. */
.sheet-body .report-controls input[type="date"] {
  display: block;
  min-width: 0;
  max-width: 100%;
}

/* iPhone Safari only (the one browser with that touch property): its own
   drawing of the date box is what sets that width; the box is drawn like the
   other fields instead. Tapping it still opens the phone's date picker. */
@supports (-webkit-touch-callout: none) {
  .sheet-body .report-controls input[type="date"] {
    -webkit-appearance: none;
    appearance: none;
  }

  .sheet-body .report-controls input[type="date"]::-webkit-date-and-time-value {
    text-align: left;
  }
}

/* A line holding one text link ("See all accounts", "Fetch rates"): no
   paragraph margins, so the card ends at the link's own tap area. */
.sheet-link-line {
  margin: 0;
}

.sheet-link-line .back-link {
  margin-bottom: 0;
}

.sheet-body .report-controls select,
.sheet-body .report-controls input {
  background: var(--color-card);
  color: var(--text);
}

.sheet-body button.secondary,
.sheet-body a.secondary {
  color: var(--text);
}

.sheet-body dialog {
  background: var(--color-card);
  color: var(--text);
  max-width: min(560px, calc(100vw - var(--base) * 4));
  max-height: calc(100vh - var(--base) * 8);
  overflow: auto;
}

/* Part C (found while measuring every question box, 4 Oct 26): a heading in a
   box took the browser's own size and weight (25.5 px, 700), off the type
   scale. The Filter box is the one with a heading. */
.sheet-body dialog h2 {
  font-size: var(--size-heading);
  font-weight: 600;
  margin: 0 0 calc(var(--base) * 1);
}

.filter-group {
  border: none;
  border-top: 1px solid var(--border);
  padding: calc(var(--base) * 1) 0;
  margin: 0;
}

.filter-group legend {
  padding: 0;
}

.filter-group label.choice {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1);
  min-height: calc(var(--base) * 6);
  font-size: var(--size-body);
  color: var(--text);
  margin: 0;
}

.filter-group label.choice.indent {
  padding-left: calc(var(--base) * 3);
}

.filter-group input[type="checkbox"] {
  width: auto;
  min-height: 0;
  margin: 0;
}

.sheet-chart {
  display: block;
  max-width: 100%;
}

.sheet-chart-label {
  font-size: var(--size-meta);
  fill: var(--text-muted);
  font-variant-numeric: tabular-nums;
}

.sheet-chart-axis {
  stroke: var(--border);
  stroke-width: 1;
}

.sheet-chart-marker {
  stroke: var(--text-muted);
  stroke-width: 1;
  stroke-dasharray: 4 4;
}

/* Session 8k (D-193): history lines in full colour: Summary's colour for net
   worth, an account's category colour for its own history (the class on the
   line), red for what is owed. Grey only for a comparison mark. */
.sheet-chart-line {
  stroke: var(--cat, var(--summary-text));
  stroke-width: 2;
  fill: none;
}

circle.sheet-chart-line {
  fill: var(--cat, var(--summary-text));
}

.sheet-chart-line.owed {
  stroke: var(--color-red);
}

circle.sheet-chart-line.owed {
  fill: var(--color-red);
}

.sheet-table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--size-body);
}

.sheet-table th,
.sheet-table td {
  text-align: left;
  padding: var(--base) calc(var(--base) * 1) var(--base) 0;
  border-bottom: 1px solid var(--border);
  vertical-align: top;
}

.sheet-table thead th {
  font-size: var(--size-meta);
  color: var(--text-muted);
  font-weight: 400;
}

/* The source column stays on every width (T32); it wraps rather than hides. */
.sheet-table td:nth-child(3) {
  font-size: var(--size-meta);
  color: var(--text-muted);
  overflow-wrap: anywhere;
}

/* The goal's figures table (D-472) carries two figures beside each date; on the phone a figure may take a second line
   at the space before its currency code, the number itself never broken (the batch close's full sweep of 31 Oct 26: the
   table ran wider than the phone's screen). */
#goal-chart-section .sheet-table td.sheet-figure {
  white-space: normal;
  overflow-wrap: normal;
}

/* Session 8i — the Overview, Income by year and the net worth page on the
   card look (session-8i-proposal.md A1-A8; D-156, D-161). Summary blue on all
   three. Same four sizes, one radius, no shadows; red only for money owed and
   past due, orange for needs attention, each with its words. */

.sheet-page.narrow {
  max-width: 720px;
}

.sheet-card h3 {
  font-size: var(--size-body);
  font-weight: 600;
  margin: calc(var(--base) * 2) 0 calc(var(--base) * 1);
}

/* A8, the report date box on iPhone Safari: the date box and the Currency box
   beside it are drawn to one fixed height, the same padding and line height,
   on every page with the two side by side (the three 8h pages, the Overview
   and the net worth page). The select is drawn like the date box, with its own
   arrow, so neither keeps Safari's own drawing. */
.sheet-body .report-controls select,
.sheet-body .report-controls input {
  box-sizing: border-box;
  height: calc(var(--base) * 6);
  min-height: calc(var(--base) * 6);
  line-height: calc(var(--base) * 3);
  padding: 0 calc(var(--base) * 2);
  margin: 0;
}

.sheet-body .report-controls select {
  -webkit-appearance: none;
  appearance: none;
  padding-right: calc(var(--base) * 5);
  /* Its own file: the site's Content-Security-Policy (app/_headers) allows
     images from the site only, so an image written inline is blocked. */
  background-image: url("select-arrow.svg");
  background-repeat: no-repeat;
  background-position: right calc(var(--base) * 2) center;
}

/* D-402 (25 Oct 26; the overnight sweep's finding, question 8): the choice
   boxes in the entry sheet's Source fold are drawn as the select above, with
   its arrow, not by Safari. Mac Safari drew them natively (25 px, square)
   while the phone drew them as every other box. Their height and padding
   come from the entry form's own rule (#entry-form select), which is why
   this one names #entry-form: an id outranks the rule above.
   The long session of 10 Nov 26, Part 8: the property value's Kind of valuation (sql/164, 3 Nov 26) is the entry form's
   other choice box and had been left native on the laptop (Safari's 5 px corner, no padding) while the phone drew the
   box: found when the closing first measured Update's views on both screens. Every choice box of the form's rows takes
   this rule; the currency keeps its own (the amount row's). */
.sheet-body #entry-form :is(.source-row, #valuation-fields) > select {
  -webkit-appearance: none;
  appearance: none;
  padding-right: calc(var(--base) * 5);
  background-image: url("select-arrow.svg");
  background-repeat: no-repeat;
  background-position: right calc(var(--base) * 2) center;
}

/* Fields outside the report controls (Income by year's forms) follow the
   colour scheme too. */
.sheet-body input,
.sheet-body select {
  background-color: var(--color-card);
  color: var(--text);
  border-color: var(--border);
}

/* The net worth headline is a button (it toggles the currency). The dark-mode
   rule for the primary action must not paint it: it is not an action colour. */
body.sheet-body button.headline {
  background: none;
  color: var(--text);
  width: 100%;
}

.sheet-body #headline-amount {
  color: var(--text);
}

.sheet-body #headline-currency {
  color: var(--text-muted);
}

.own-owe {
  margin: 0 0 calc(var(--base) * 1);
}

.own-owe > div {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  padding: calc(var(--base) * 1) 0;
  border-top: 1px solid var(--border);
  font-size: var(--size-body);
}

.own-owe dt {
  color: var(--text);
}

.own-owe dd {
  margin: 0;
}

.meaning {
  font-size: var(--size-body);
  line-height: 1.5;
  margin: 0;
}

.sheet-body .report-line-label,
.sheet-body .report-line-converted {
  color: var(--text);
}

.sheet-chart-box {
  width: 100%;
  overflow: hidden;
  margin: 0 0 calc(var(--base) * 2);
}

.sheet-table td a {
  color: var(--text);
}

.sheet-table td.sheet-date {
  white-space: nowrap;
}

/* Spending's categories under their groups (sql/180, the long day session of 3 Nov 26): each group's row carries its
   amount, its categories indented one step under it. */
.sheet-table tr.group-total th,
.sheet-table tr.group-total td {
  font-weight: 600;
}

.sheet-table td.in-group {
  padding-left: calc(var(--base) * 2);
}

/* Allocation's drift over twelve months (Q3, the long day session of 3 Nov 26): one line per group in the section's
   hue, each with its own dash, the key drawing the same sample beside each name; the figures table is the record. */
.drift-svg {
  display: block;
  width: 100%;
  height: auto;
}

.drift-path {
  fill: none;
  stroke: var(--section-investments);
  stroke-width: 2.5;
  stroke-linejoin: round;
}

circle.drift-path {
  fill: var(--section-investments);
}

.drift-legend {
  list-style: none;
  margin: 0 0 calc(var(--base) * 2);
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--base) calc(var(--base) * 3);
}

.drift-key {
  display: flex;
  align-items: center;
  gap: var(--base);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.drift-sample {
  width: 32px;
  height: 8px;
  flex: none;
}

.drift-sample line {
  stroke: var(--section-investments);
  stroke-width: 2.5;
}

/* Allocation Q5: the two figures under a breach, set apart from the breach's own lines. */
.rule-arithmetic {
  margin-top: var(--base);
  padding-top: var(--base);
  border-top: 1px solid var(--border);
}

.sheet-table .sheet-detail {
  display: block;
  margin: 0;
}

/* The alert line: about today, each count a link to its rows. */
.alert-block {
  border-top: 1px solid var(--border);
  margin-top: calc(var(--base) * 2);
  padding-top: calc(var(--base) * 1);
}

.alert-line {
  font-size: var(--size-body);
  color: var(--text);
  margin: 0 0 calc(var(--base) * 1);
}

.alert-part {
  color: var(--color-orange);
  font-weight: 600;
}

.alert-part.owed,
.owed-words {
  color: var(--color-red);
}

.attention-words {
  color: var(--color-orange);
}

.overview-columns {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0 calc(var(--base) * 2);
}

@media (min-width: 1140px) { /* Session 8k: 900 px of content beside the 240 px sidebar (D-195) */
  .overview-columns {
    grid-template-columns: 3fr 2fr;
    align-items: start;
  }
}

/* The chart is left off the phone (build-manual.md Session 8i step 1); a link
   opens the net worth page, which has it. */
.overview-phone-only {
  display: none;
}

@media (max-width: 767px) {
  .overview-series {
    display: none;
  }

  .overview-phone-only {
    display: block;
    margin-bottom: calc(var(--base) * 2);
  }
}

/* The benchmark gauge: three labelled bands of equal width, greys and a tint
   of the section hue, never red, orange or green; a marker where the compared
   figure falls. Decoration: the words under it carry the result (D-156). */
.gauge {
  position: relative;
  display: flex;
  margin: 0 0 calc(var(--base) * 2);
  border-radius: var(--radius);
  overflow: hidden;
}

.gauge-band {
  flex: 1 1 0;
  min-height: calc(var(--base) * 5);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  font-size: var(--size-meta);
  color: var(--gauge-band-ink);
  padding: 0 calc(var(--base) * 1);
}

.gauge-under { background: var(--gauge-under-fill); }
.gauge-average { background: var(--gauge-average-fill); }
.gauge-prodigious { background: color-mix(in srgb, var(--section-summary) 30%, var(--gauge-prodigious-fill)); }

.gauge-marker {
  position: absolute;
  top: 0;
  bottom: 0;
  width: calc(var(--base) * 1);
  transform: translateX(-50%);
  background: var(--text);
  border-radius: var(--radius);
}

/* Fixes session, 6 Oct 26 (D-253): the line under the gauge is normal
   weight; only the band's name in it is bold (.band-name). */
.benchmark-band {
  font-size: var(--size-body);
  font-weight: 400;
  margin: 0 0 calc(var(--base) * 2);
}

.benchmark-lines {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 3fr);
  gap: calc(var(--base) * 1) calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
  font-size: var(--size-meta);
}

.benchmark-lines dt {
  color: var(--text-muted);
}

.benchmark-lines dd {
  margin: 0;
  text-align: right;
  white-space: normal;
}

/* Income by year. */
.stack-form {
  border-top: 1px solid var(--border);
  padding-top: calc(var(--base) * 1);
  margin-top: calc(var(--base) * 2);
}

.stack-form button {
  margin-top: calc(var(--base) * 1);
}

.form-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0 calc(var(--base) * 2);
}

.form-row > div {
  flex: 1 1 calc(var(--base) * 18);
}

.form-row select {
  width: 100%;
  min-height: calc(var(--base) * 6);
  font-size: var(--size-body);
  font-family: inherit;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0 calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 2);
}

.correct-form select {
  width: 100%;
  min-height: calc(var(--base) * 6);
  font-size: var(--size-body);
  font-family: inherit;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0 calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 2);
}

.income-row {
  padding: calc(var(--base) * 2) 0;
}

.income-row-head {
  font-size: var(--size-body);
  font-variant-numeric: tabular-nums;
  margin: 0 0 calc(var(--base) * 1);
}

.saved-line {
  font-size: var(--size-body);
  color: var(--color-green);
  margin: 0 0 calc(var(--base) * 1);
}

/* Session 8i follow-up (D-180): muted text that sits on the section fade, not
   on a card ("Back to start", "Sign out", a page's opening line), is measured
   against the fade at its strongest, the top of the page. In light mode the
   usual grey is 3.74:1 there on indigo, so it takes a darker grey: 4.68:1 on
   indigo's top, 5.11:1 on teal's. In dark mode the usual grey passes (9.9:1 or
   better). The fade itself is unchanged (D-156). */
body.sheet-body {
  --text-on-fade: #5a606c;
}

@media (prefers-color-scheme: dark) {
  body.sheet-body {
    --text-on-fade: var(--text-muted);
  }
}

.sheet-body #content > .top-row .back-link,
.sheet-body #content > .top-row button.text-button,
.sheet-body #content > p.sheet-meta,
.sheet-body #content > p.list-line,
.sheet-body #content > p.sheet-link-line .back-link,
.sheet-body .build-id {
  color: var(--text-on-fade);
}

/* ------------------------------------------------------------ Session 8j ---
   The account page's Nominations and "This account" cards (A2, A3), and the
   searchable picker (D-158; A3's nominees, A4's account picker). Sizes on
   the 13/17 scale, the one radius, no shadow; the list sits in the page's
   flow under its box, so nothing floats over content. */
.sheet-card form label {
  margin-top: calc(var(--base) * 2);
}

.sheet-card form input,
.sheet-card form select {
  width: 100%;
  font-family: inherit; /* browsers don't pass the typeface to form controls */
  font-size: var(--size-body);
  min-height: calc(var(--base) * 6);
  background: var(--color-card);
  color: var(--text);
  margin-bottom: calc(var(--base) * 1);
}

.sheet-card fieldset {
  border: none;
  padding: 0;
  margin: 0 0 calc(var(--base) * 2);
}

.sheet-card legend {
  font-size: var(--size-body);
  font-weight: 600;
  color: var(--text);
  padding: 0;
  margin-bottom: calc(var(--base) * 1);
}

.sheet-card label.choice {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1);
  min-height: calc(var(--base) * 6);
  font-size: var(--size-body);
  color: var(--text);
  margin: 0;
}

.sheet-card form label.choice input[type="radio"] {
  width: auto;
  min-height: 0;
  margin: 0;
  accent-color: var(--color-accent);
}




.sheet-card > button.secondary {
  margin-top: calc(var(--base) * 1);
}

.nomination-lines {
  margin: 0 0 calc(var(--base) * 1);
  padding-left: calc(var(--base) * 2);
  font-size: var(--size-body);
}

#nomination-history summary,
#periods-earlier summary {
  font-size: var(--size-body);
  cursor: pointer;
  min-height: calc(var(--base) * 6);
  display: flex;
  align-items: center;
}

.picker-list {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--color-card);
  max-height: calc(var(--base) * 40);
  overflow-y: auto;
  margin: 0 0 calc(var(--base) * 2);
}

.picker-heading {
  font-size: var(--size-meta);
  font-weight: 600;
  color: var(--text-muted);
  padding: calc(var(--base) * 1) calc(var(--base) * 2) 0;
}

.picker-option {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: calc(var(--base) * 6);
  padding: calc(var(--base) * 1) calc(var(--base) * 2);
  font-size: var(--size-body);
  color: var(--text);
  cursor: pointer;
}

/* Not the accent as text: it is 4.31:1 on the dark card (D-180). Bold, in
   the text colour, says it is an action. */
.picker-option.picker-action {
  font-weight: 600;
}

.picker-option.active {
  outline: 2px solid var(--color-accent);
  outline-offset: -2px;
  border-radius: var(--radius);
}

.picker-note {
  font-size: var(--size-meta);
  color: var(--text-muted);
}

.picker-empty {
  font-size: var(--size-meta);
  color: var(--text-muted);
  padding: calc(var(--base) * 1) calc(var(--base) * 2) calc(var(--base) * 2);
}

/* Session 8j (D-158): the entry screen's sum keys, C + − × ÷ =, a row of six
   equal buttons directly above the amount, each at least 48 px tall for a
   thumb; plain secondary buttons, so Save stays the one primary. */
.calc-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: calc(var(--base) * 1);
  margin-bottom: calc(var(--base) * 1);
}

button.secondary.calc-key {
  min-height: calc(var(--base) * 6);
  padding: 0;
  font-size: var(--size-heading);
  font-weight: 600;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
}

button.secondary.calc-key:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* The amount, large at the top (YNAB 6348): Apple's largest of the four sizes. */
#entry-form #amount {
  font-size: var(--size-headline);
  font-weight: 600;
}

.confirm-actions {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 1);
  margin-top: calc(var(--base) * 2);
}

.confirm-actions button,
.confirm-actions a.primary {
  margin: 0;
}

/* Session 8j (A5): the date-box fix from 81197ca, on every date box of the
   pages restyled in 8j and on Record a document and Exchange rates (Avi,
   30 Sep 26): the box may shrink to its column and never exceed it; on
   iPhone Safari it is drawn like the other fields, and a tap still opens
   the phone's date picker. */
.sheet-body input[type="date"],
#document-form input[type="date"],
#rates-form input[type="date"],
#in-use input[type="date"] {
  display: block;
  min-width: 0;
  max-width: 100%;
}

@supports (-webkit-touch-callout: none) {
  .sheet-body input[type="date"],
  #document-form input[type="date"],
  #rates-form input[type="date"],
  #in-use input[type="date"] {
    -webkit-appearance: none;
    appearance: none;
  }

  .sheet-body input[type="date"]::-webkit-date-and-time-value,
  #document-form input[type="date"]::-webkit-date-and-time-value,
  #rates-form input[type="date"]::-webkit-date-and-time-value,
  #in-use input[type="date"]::-webkit-date-and-time-value {
    text-align: left;
    margin: 0;
  }
}

/* Session 8j fixes (Avi's iPhone re-check, 2 Oct 26): with Safari's own
   drawing off, the date text sat at the top of the box. The box is one fixed
   48 px high, border included, with even side padding, and laid out so the
   date text sits in its vertical centre.
   Round 6 (Avi's iPhone, 3 Oct 26): the Report date boxes sit outside a form
   and kept only their height rule (Session 8i, A8), so their text was still
   at the top. The rule reaches every date box, in a form or not, and a date
   box added later.
   4 Oct 26 (Avi's laptop check of build e6d187bf; D-223): this rule was
   inside the iPhone-only block above, so in Mac Safari the box stayed
   "display: block" (the fits-its-column rules) and the date text sat at the
   top there. It is now for every browser: one rule, both screens.
   26 Oct 26 (the full sweep): the Rates in use box (D-408) is named by its
   card's id in the fits-its-column rule above, which outranks ".sheet-body
   input", so it went back to "display: block" with its date at the top. It
   is named here too. */
.sheet-body .report-controls input[type="date"],
.sheet-body input[type="date"],
.sheet-body form input[type="date"],
#document-form input[type="date"],
#rates-form input[type="date"],
#in-use input[type="date"] {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  height: calc(var(--base) * 6);
  min-height: calc(var(--base) * 6);
  padding: 0 calc(var(--base) * 2);
  line-height: calc(var(--base) * 3);
}

/* Fixes session, 6 Oct 26 (Avi's check of 1d5d342c, step 10; D-252): an
   empty date box was narrower than a filled one, because a box in a row took
   the width of its text and an empty box on the iPhone has none. Every date
   box in a row (.pill-date) now has one width, enough for the longest date
   and for "Choose a date"; every other date box already fills its column.
   On the iPhone an empty box says "Choose a date" in the placeholder grey,
   drawn from the mark src/date-boxes.ts keeps (no style rule can see whether
   a date box is empty). Mac Safari shows its own dd/mm/yyyy instead. */
:root {
  --date-box-width: calc(var(--base) * 18);
}
.sheet-body input.pill-date[type="date"] {
  box-sizing: border-box;
  width: var(--date-box-width);
  flex: none;
}
@supports (-webkit-touch-callout: none) {
  .sheet-body input[type="date"][data-empty]::before,
  #document-form input[type="date"][data-empty]::before,
  #rates-form input[type="date"][data-empty]::before {
    content: "Choose a date";
    color: var(--text-muted);
    white-space: nowrap;
  }
}

/* The entry amount at the largest size needs the card's whole width; the
   currency sits below it. */
.sheet-body #entry-form .amount-row {
  flex-wrap: wrap;
}

.sheet-body #entry-form #amount {
  flex: 1 1 100%;
}

.sheet-body #entry-form :is(#currency, #update-currency) {
  flex: 0 0 auto;
  min-width: calc(var(--base) * 16);
}


/* ------------------------------------------------------------ Session 8k ---
   The Health look (D-193) and the tab bar (D-194, D-195). Same four sizes, one
   radius, no shadows.
   - Each balance sheet category owns one colour: Apple's increased-contrast
     value in each mode (HIG color.json, read 2 Oct 26), 4.5:1 or better on the
     card, so the same value serves as text and as a chart mark. Liabilities
     are reds. Gold & Silver takes orange, which is no longer a status colour.
   - Needs attention is a yellow band with black words, or a small yellow mark
     beside grey words; never yellow text on white.
   - The bar: along the bottom on a phone; from 768 px wide (the app's own
     phone/laptop line, where the Overview's chart appears) a sidebar on the
     left. Neutral; only the selected item is coloured, with a short bar so
     colour is not the only sign. */
:root {
  --cat-property: rgb(149, 109, 81);         /* brown   4.58:1 on white */
  --cat-cash-at-bank: rgb(30, 110, 244);     /* blue    4.57:1 (the accent, accepted by Avi) */
  --cat-deposits-at-bank: rgb(0, 126, 174);  /* cyan    4.57:1 */
  --cat-super: rgb(0, 129, 152);             /* teal    4.57:1 */
  --cat-insurance: rgb(0, 133, 117);         /* mint    4.55:1 */
  --cat-equity: rgb(86, 74, 222);            /* indigo  6.12:1 */
  --cat-esop: rgb(60, 52, 155);              /* indigo, second shade 9.74:1 */
  --cat-mutual-funds: rgb(176, 47, 194);     /* purple  5.21:1 */
  --cat-cryptocurrency: rgb(123, 33, 136);   /* purple, second shade 8.69:1 */
  --cat-gold-and-silver: rgb(197, 83, 0);    /* orange  4.55:1 */
  --cat-other-investments: #6b7280;          /* grey    4.83:1 */
  --cat-home-loans: rgb(233, 21, 45);        /* red     4.56:1 */
  --cat-vehicle-loans: rgb(163, 15, 31);     /* red, second shade 7.94:1 */
  --cat-credit-cards: rgb(231, 18, 77);      /* pink-red 4.57:1 */
  --cat-other-loans: rgb(162, 13, 54);       /* pink-red, second shade 7.93:1 */
  --band-yellow: rgb(255, 204, 0);           /* black on it 13.9:1 */
  --tab-selected: rgb(30, 110, 244);         /* 4.57:1 on the white bar */
  --summary-text: rgb(86, 74, 222);          /* Summary's card names, as text: 6.12:1 */
}

@media (prefers-color-scheme: dark) {
  :root {
    --cat-property: rgb(219, 166, 121);        /* on Gray 5: 6.47:1 */
    --cat-cash-at-bank: rgb(92, 184, 255);     /* 6.47:1 */
    --cat-deposits-at-bank: rgb(109, 217, 255);/* 8.64:1 */
    --cat-super: rgb(59, 221, 236);            /* 8.45:1 */
    --cat-insurance: rgb(84, 223, 203);        /* 8.49:1 */
    --cat-equity: rgb(167, 170, 255);          /* 6.53:1 */
    --cat-esop: rgb(193, 196, 255);            /* 8.37:1 */
    --cat-mutual-funds: rgb(234, 141, 255);    /* 6.47:1 */
    --cat-cryptocurrency: rgb(240, 175, 255);  /* 8.15:1 */
    --cat-gold-and-silver: rgb(255, 160, 86);  /* 6.91:1 */
    --cat-other-investments: #aeaeb2;          /* 6.30:1 */
    --cat-home-loans: rgb(255, 97, 101);       /* 4.74:1 */
    --cat-vehicle-loans: rgb(255, 144, 147);   /* 6.41:1 */
    --cat-credit-cards: rgb(255, 138, 196);    /* 6.43:1 */
    --cat-other-loans: rgb(255, 173, 214);     /* 8.10:1 */
    --band-yellow: rgb(255, 214, 0);           /* black on it 14.9:1 */
    --tab-selected: rgb(92, 184, 255);         /* 6.47:1 on the Gray 5 bar (the dark accent is 4.31:1 as text) */
    --summary-text: rgb(167, 170, 255);        /* 6.53:1 */
  }
}

.cat-property { --cat: var(--cat-property); }
.cat-cash-at-bank { --cat: var(--cat-cash-at-bank); }
.cat-deposits-at-bank { --cat: var(--cat-deposits-at-bank); }
.cat-super { --cat: var(--cat-super); }
.cat-insurance { --cat: var(--cat-insurance); }
.cat-equity { --cat: var(--cat-equity); }
.cat-esop { --cat: var(--cat-esop); }
.cat-mutual-funds { --cat: var(--cat-mutual-funds); }
.cat-cryptocurrency { --cat: var(--cat-cryptocurrency); }
.cat-gold-and-silver { --cat: var(--cat-gold-and-silver); }
.cat-other-investments { --cat: var(--cat-other-investments); }
.cat-home-loans { --cat: var(--cat-home-loans); }
.cat-vehicle-loans { --cat: var(--cat-vehicle-loans); }
.cat-credit-cards { --cat: var(--cat-credit-cards); }
.cat-other-loans { --cat: var(--cat-other-loans); }

/* A category's name in its colour, with a dot in the same colour (the dot is
   the one radius on a small square). */
.cat-name {
  color: var(--cat, var(--text));
}

.cat-name::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: var(--base);
  border-radius: var(--radius);
  background: var(--cat, var(--border));
}

.sheet-bar-segment[class*="cat-"] {
  background: var(--cat);
}

/* Needs attention: the yellow band, black words on it. Replaces orange text
   and the pale orange box (D-156) on every page. */
.sheet-attention,
.notice,
#withheld,
.sheet-body #withheld,
.sheet-body #stale-count {
  background: var(--band-yellow);
  color: var(--site-sheet-attention-ink);
  border-radius: var(--radius);
  padding: var(--base) calc(var(--base) * 2);
}

.sheet-attention a,
.notice a,
#withheld a {
  color: var(--site-sheet-attention-ink);
}

/* A single row's attention words (stale; due soon; a closed account's open
   item): grey words with a small yellow mark beside them. */
.attention-words,
.sheet-attention-word {
  color: var(--text-muted);
}

/* D-239, D-243: a benchmark band's name inside its sentence: weight 600 in
   the text colour, the rest of its sentence 400 (#benchmark-sentence).
   Under-accumulator alone carries the same yellow mark; never yellow text and
   no colour behind the words. */
.band-name {
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
}

.attention-words::before,
.sheet-attention-word::before,
.band-name-attention::before {
  content: "";
  display: inline-block;
  width: 10px;
  height: 10px;
  margin-right: var(--base);
  border-radius: var(--radius);
  background: var(--band-yellow);
  border: 1px solid var(--site-attention-words-line);
}

/* The Overview's alert line sits in the band card's white body: its parts in
   the text colour, owed in red. */
.alert-part {
  color: var(--text);
}

/* The band card: a yellow head with its words, a plain card below. */
.band-card {
  background: var(--color-card);
  color: var(--text);
  border-radius: var(--radius);
  overflow: hidden;
  margin: 0 0 calc(var(--base) * 2);
}

.band-head {
  background: var(--band-yellow);
  color: var(--band-head-ink);
  font-size: var(--size-meta);
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  margin: 0;
  padding: var(--base) calc(var(--base) * 2);
}

.band-card.is-clear .band-head {
  display: none;
}

.band-body {
  padding: var(--base) calc(var(--base) * 2) calc(var(--base) * 2);
}

.band-body > :last-child {
  margin-bottom: 0;
}

/* Summary's cards (D-193): the card's name in its colour, one plain sentence,
   then the figure. */
.summary-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0 calc(var(--base) * 2);
}

/* 5 Oct 26 (Avi's layout, 4 Oct 26): on the laptop, Net worth is the larger
   tile on the left, as tall as What you own over What you owe on its right
   (each card keeps its own 16 px foot, so Net worth's height is exactly What
   you own, the gap and What you owe); Wealth benchmark sits below them across
   the whole width, as Card payments due does, its lines and rows using the
   space to the right. From 1,140 px, where Summary's other cards already sit
   in two columns beside the sidebar (D-195). The phone keeps its stacked order. */
@media (min-width: 1140px) {
  .summary-cards {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "net own"
      "net owe"
      "gaps gaps"
      "tiles tiles"
      "benchmark benchmark";
    align-items: stretch;
  }

  .summary-cards > .section-tiles { grid-area: tiles; }
  /* D-425 (c) (27 Oct 26): the list a comparison's count opens, across the row right under the three cards (hidden,
     its row takes no height: the cards' row gap is 0). */
  .summary-cards > #comparison-gaps { grid-area: gaps; }

  .summary-cards > section[aria-labelledby="net-label"] { grid-area: net; }
  .summary-cards > section[aria-labelledby="own-label"] { grid-area: own; }
  .summary-cards > section[aria-labelledby="owe-label"] { grid-area: owe; }

  .summary-cards > #benchmark {
    grid-area: benchmark;
    display: grid;
    grid-template-columns: 1fr 1fr;
    column-gap: calc(var(--base) * 3);
    align-items: start;
  }

  .summary-cards > #benchmark > * {
    grid-column: 1 / -1;
  }

  .summary-cards > #benchmark > #benchmark-figures {
    grid-column: 1;
  }

  .summary-cards > #benchmark > #benchmark-figures:not([hidden]) ~ .card-rows {
    grid-column: 2;
    margin-top: 0;
    border-top: none;
  }
}

/* The four tiles' names at the size of the Assets and Liabilities headings,
   on both screens (Avi, 4 Oct 26); each keeps its colour. */
.summary-name,
.sheet-card h2.summary-name {
  font-size: var(--size-body);
  font-weight: 600;
  color: var(--summary-text);
  margin: 0 0 var(--base);
}

.summary-name.owe {
  color: var(--color-red);
}

/* 4.1 navigation (D-385, Avi's rulings of 20 Oct 26): the sections' tiles sit right after the net worth group and
   before the wealth benchmark, one per row on the phone and two to a row on the laptop (from 1,140 px, where Summary's
   cards sit in two columns). A tile is one card that opens its section's page: its name in the section's own colour
   (Q5), one line under it (a count until its figure exists, Q4), a chevron at the right; no button, no chart. */
.section-tiles {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0 calc(var(--base) * 2);
}

.summary-tile {
  display: flex;
  align-items: center;
  gap: var(--base);
  text-decoration: none;
  color: var(--text);
}

.summary-tile .tile-words {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.summary-tile .summary-name {
  display: block;
}

.summary-tile .summary-sentence {
  display: block;
  margin: 0;
}

.summary-tile .row-chevron {
  flex: none;
  color: var(--text-muted);
}

.summary-tile:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.summary-tile.tile-investments .summary-name {
  color: var(--section-investments);
}

@media (min-width: 1140px) {
  .section-tiles {
    grid-template-columns: 1fr 1fr;
  }
}

/* D-253, D-257: a sentence is normal weight; only its key words are bold
   (.key-word; the benchmark's band name, .band-name). */
.summary-sentence {
  font-size: var(--size-body);
  font-weight: 400;
  margin: 0 0 var(--base);
}

/* D-257: a key word inside a sentence (src/key-words.ts): 600 in the
   sentence's own colour, against the 400 around it; a figure with its
   currency is kept on one line. */
.key-word {
  font-weight: 600;
  white-space: nowrap;
}

/* D-418: in a withheld comparison, the count is a button that opens the list
   of records with no balance by that date (src/key-words.ts): the sentence's
   own size and weight, underlined like every text button. */
.summary-sentence .sentence-opens {
  display: inline;
  min-height: 0;
  margin: 0;
  padding: 0;
  font-size: inherit;
  font-weight: 400;
  line-height: inherit;
  vertical-align: baseline;
}

/* D-418: the list the count opens spans the cards' row; each record is a link
   to its page, in the text colour (the browser's own link colour is 1.81:1 on
   the dark card), underlined so it reads as a link. */
.comparison-gaps {
  grid-column: 1 / -1;
}

.comparison-gaps a {
  color: var(--text);
  text-decoration: underline;
}

/* D-450 (6) (28-29 Oct 26): a plain link inside a help line (the Prices page's "Source: Bank Negara Malaysia", BNM's
   terms) takes the same colour for the same reason; a link with a class of its own (entry's back-link) keeps its own. */
.field-note a:not([class]) {
  color: var(--text);
  text-decoration: underline;
}

/* ------------------------------------------------------------- the tab bar */
.tab-bar {
  position: fixed;
  z-index: 20;
  background: var(--color-card);
  color: var(--text);
}

.tab-bar ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.tab-bar a {
  color: var(--text-muted);
  text-decoration: none;
}

.tab-bar a:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: -2px;
}

.tab-icon {
  width: 24px;
  height: 24px;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.tab-who {
  font-size: var(--size-meta);
  color: var(--text-muted);
  margin: 0 0 var(--base);
  overflow-wrap: anywhere; /* an email has no spaces: it wraps inside the sidebar */
}

/* Phone: the floating bar along the bottom, clear of the home indicator. The
   page keeps room below its content so nothing is left under the bar. */
@media (max-width: 767px) {
  body.sheet-body {
    padding-bottom: calc(var(--base) * 13 + env(safe-area-inset-bottom));
  }

  .tab-bar {
    left: calc(var(--base) * 2);
    right: calc(var(--base) * 2);
    bottom: calc(var(--base) + env(safe-area-inset-bottom));
    border: 1px solid var(--border);
    border-radius: var(--radius);
  }

  .tab-main {
    display: flex;
  }

  .tab-main li {
    flex: 1 1 0;
  }

  .tab-main a {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: calc(var(--base) * 7);
    font-size: var(--size-meta);
    font-weight: 600;
  }

  .tab-main a.is-selected,
  .tab-main a.is-selected-phone {
    color: var(--tab-selected);
  }

  .tab-main a.is-selected::after,
  .tab-main a.is-selected-phone::after {
    content: "";
    position: absolute;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: calc(var(--base) * 3);
    height: 3px;
    background: var(--tab-selected);
  }

  .tab-pages,
  .tab-group-name,
  .tab-foot {
    display: none;
  }
}

/* Laptop: the sidebar (D-195). The four destinations, then More's pages, then
   "Signed in as [name]" and Sign out, shown once the page has shown its
   content (so never to a signed-out visitor). */
@media (min-width: 768px) {
  body.sheet-body {
    padding-left: calc(var(--base) * 33); /* the 240 px sidebar and a 24 px gutter */
    padding-right: calc(var(--base) * 3);
  }

  .tab-bar {
    top: 0;
    bottom: 0;
    left: 0;
    width: calc(var(--base) * 30); /* 240 px */
    display: flex;
    flex-direction: column;
    border-right: 1px solid var(--border);
    padding: calc(var(--base) * 3) calc(var(--base) * 2);
    overflow-y: auto;
  }

  .tab-main a,
  .tab-pages a {
    display: flex;
    align-items: center;
    gap: var(--base);
    min-height: calc(var(--base) * 6);
    padding: 0 var(--base);
    border-left: 4px solid transparent;
    font-size: var(--size-body);
    font-weight: 600;
  }

  .tab-pages a {
    font-weight: 400;
  }

  .tab-main a.is-selected,
  .tab-pages a.is-selected {
    color: var(--tab-selected);
    border-left-color: var(--tab-selected);
  }

  .tab-pages {
    margin-top: calc(var(--base) * 2);
    padding-top: calc(var(--base) * 2);
    border-top: 1px solid var(--border);
  }

  /* D-385: the sections' list sits under the four tabs with no heading; Records and Tools each carry a small heading
     (13 pt, muted) in place of the line above the list. */
  .tab-group-name {
    margin: calc(var(--base) * 2) 0 0;
    padding: 0 var(--base);
    font-size: var(--size-meta);
    font-weight: 600;
    color: var(--text-muted);
  }

  .tab-group-name + .tab-pages {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
  }

  .tab-foot {
    display: none;
    margin-top: auto;
    padding-top: calc(var(--base) * 2);
    border-top: 1px solid var(--border);
  }

  body:is(.vm-content, #vm-never.vm-never) .tab-foot {
    display: block;
  }

  .tab-foot button.text-button {
    color: var(--text-muted);
  }
}

/* ------------------------------------------- Update: "Due for an update" */
.due-update h2 {
  font-size: var(--size-body);
  font-weight: 600;
  margin: 0 0 var(--base);
}

.due-tiles {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--base);
  margin: 0 0 var(--base);
}

/* Each tile is a button, but never the screen's primary one: a card with a
   stripe in its category's colour. */
.due-tiles button.due-tile[type] {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  gap: var(--base);
  width: 100%;
  min-height: calc(var(--base) * 11);
  padding: var(--base) calc(var(--base) * 2);
  text-align: left;
  font-weight: 400;
  background: var(--color-card);
  color: var(--text);
  border: 1px solid var(--border);
  border-left: var(--base) solid var(--cat, var(--border));
  border-radius: var(--radius);
  touch-action: manipulation;
}

.due-tiles button.due-tile[aria-pressed="true"] {
  outline: 2px solid var(--tab-selected);
  outline-offset: -2px;
}

.due-name {
  font-size: var(--size-body);
  font-weight: 600;
  overflow-wrap: anywhere;
}

.due-last {
  font-size: var(--size-body);
  font-variant-numeric: tabular-nums;
}

.due-last.owed {
  color: var(--color-red);
}

.due-when {
  font-size: var(--size-meta);
  color: var(--text-muted);
}

.due-update > .sheet-meta {
  color: var(--text-on-fade);
  margin-bottom: calc(var(--base) * 2);
}

/* The confirmation: a top edge in the account's colour, "Saved" in green, and
   the change in one sentence. */
.confirmation[class*="cat-"] {
  border-top: var(--base) solid var(--cat);
}

.confirmation h2 {
  color: var(--color-green);
}

.confirmation p.confirm-change {
  font-weight: 400;
}

/* ------------------------------------------------------- More: the tiles */
/* Overnight 6 Oct 26 (D-248): More has its section colour too (its tiles had
   stood in for it); a page opened from More takes its tile's hue, below. */
body.sheet-body.section-more {
  --section: var(--section-more);
}

body.sheet-body.section-document {
  --section: var(--section-document);
}

/* Exchange rates: its tile is cyan, the hue of her pages. Import: its tile is
   mint, Update's hue. */
body.sheet-body.section-rates {
  --section: var(--section-viewer);
}

body.sheet-body.section-import {
  --section: var(--section-entry);
}

.more-tiles {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--base);
}

.more-tiles .more-tile {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--base);
  box-sizing: border-box;
  width: 100%;
  min-height: calc(var(--base) * 12);
  padding: calc(var(--base) * 2);
  border-radius: var(--radius);
  font-size: var(--size-body);
  font-weight: 600;
  text-align: left;
  text-decoration: none;
  color: var(--more-tile-ink);
  /* Session 8k second fixes, B2 (Avi's ruling, 3 Oct 26; D-200): Health's
   * Browse tiles. One hue, strong to light (D-193), the proposal's measured
   * pairs: black text 7.42:1 or better across every tile, in both modes. */
  background-image: linear-gradient(110deg, var(--tile-strong), var(--tile-light));
}

/* The icon: solid, black, top left. It follows the name in the page, so the
 * name is read first; the layout puts it on top. */
.more-tiles .tile-icon {
  order: -1;
  width: calc(var(--base) * 4);
  height: calc(var(--base) * 4);
  fill: currentColor;
  stroke: none;
  flex: none;
}

.tile-blue { --tile-strong: rgb(64, 156, 255); --tile-light: rgb(160, 206, 255); }
.tile-teal { --tile-strong: rgb(48, 200, 212); --tile-light: rgb(152, 228, 234); }
.tile-purple { --tile-strong: rgb(218, 120, 236); --tile-light: rgb(236, 188, 245); }
.tile-brown { --tile-strong: rgb(196, 150, 112); --tile-light: rgb(226, 204, 184); }
/* Indigo starts lighter than Health's: black on full indigo is 4.1:1. */
.tile-indigo { --tile-strong: rgb(150, 142, 255); --tile-light: rgb(200, 196, 255); }
.tile-cyan { --tile-strong: rgb(80, 200, 240); --tile-light: rgb(170, 228, 248); }
.tile-mint { --tile-strong: rgb(40, 210, 180); --tile-light: rgb(150, 234, 218); }

.more-tiles .more-tile:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* The day session of 27 Oct 26, Part 1.4 (L-104; Avi's check-list step 6): on Add, the "Institutions, people and
   properties" row touched the residency tile above it. It keeps the page's gap between cards (two base units), the
   same gap the cards above the tiles have. The Add page only; the harness's spacing check lists any other view. */
.records-row {
  margin-top: calc(var(--base) * 2);
}

/* D-385: More's list has the sidebar's order and headings: the sections first with no heading, then Records, then Tools. */
.more-group-name {
  font-size: var(--size-body);
  font-weight: 600;
  margin: calc(var(--base) * 2) 0 var(--base);
}

/* 4.2 Investments: its tile's hue, violet; black text 7.4:1 or better across the tile. */
.tile-violet { --tile-strong: rgb(196, 140, 232); --tile-light: rgb(226, 196, 245); }  /* purple since 21 Oct 26 (Part A); black text 8.26:1 and 13.45:1 */

.more-tiles .more-tile.more-plain,
.more-tiles button.more-signout[type] {
  justify-content: space-between;
  background: var(--color-card);
  background-image: none;
  color: var(--text);
  border: 1px solid var(--border);
}

@media print, (prefers-contrast: more) {
  .more-tiles .more-tile {
    background-image: none;
    background-color: var(--color-card);
    color: var(--text);
    border: 1px solid var(--border);
  }
}

/* --------------------- the phone's Sign out, top right of every owner page (D-197) */
.top-signout {
  display: none;
}

@media (max-width: 767px) {
  body.sheet-body:is(.vm-content, #vm-never.vm-never) .top-signout {
    display: block;
    position: absolute;
    top: calc(var(--base) * 3);
    right: calc(var(--base) * 2);
  }

  .top-signout button.text-button {
    width: auto;
    min-height: calc(var(--base) * 6);
    margin: 0;
    padding: 0;
    color: var(--text-on-fade);
  }

  /* Room on the first line for it. */
  body.sheet-body:is(.vm-content, #vm-never.vm-never) #content > h1:first-child,
  body.sheet-body:is(.vm-content, #vm-never.vm-never) #content > .top-row {
    padding-right: calc(var(--base) * 11);
  }
}

/* Session 8k fixes: "Fetch today's rates" inside the yellow box: the message
   and the button read as one band, black on yellow in both modes. */
.sheet-attention:has(+ .fetch-box:not([hidden])),
.sheet-body #withheld:has(+ .fetch-box:not([hidden])) {
  border-bottom-left-radius: 0;
  border-bottom-right-radius: 0;
  margin-bottom: 0;
}

.fetch-box {
  border-top-left-radius: 0;
  border-top-right-radius: 0;
  padding-top: 0;
  padding-bottom: calc(var(--base) * 2);
  margin: 0 0 var(--base);
}

.fetch-box button.secondary {
  color: var(--fetch-secondary-ink);
  border-color: var(--fetch-secondary-line);
  background: transparent;
  margin: 0;
}

.fetch-box .fetch-result {
  color: var(--fetch-secondary-ink);
  font-size: var(--size-body);
  margin: var(--base) 0 0;
}

/* Exceptions in their own section colour (purple, D-156's placeholder kept). */
body.sheet-body.section-exceptions {
  --section: var(--section-exceptions);
}

/* Session 8l: the viewer's two pages in their own section colour (cyan,
   D-156's placeholder kept), on the same cards, rows and bar as the owner's
   pages. Her list's intro sits on a card of its own (Part 8: text on cards);
   an empty line in a balance sheet card is quiet. */
body.sheet-body.section-viewer {
  --section: var(--section-viewer);
}

.sheet-card.list-intro {
  margin: 0 0 calc(var(--base) * 2);
}

.sheet-row.is-empty {
  color: var(--text-muted);
  padding: calc(var(--base) * 2) 0;
}

/* Session 8k: the sign-in form on the D-156 look, light and dark treatment B.
   Start is only the sign-in form now (D-194), and the viewer's page until 8l. */
body.signin-body {
  background: var(--color-page);
}

body.signin-body .card {
  background: var(--color-card);
  border: none;
}

/* The re-check fixes, item C5: the Start page's two plain notes (app/index.html). The fallback is laid out from the
   start but invisible, and becomes visible after 4 seconds unless signin.js, once it runs, has removed it; with
   JavaScript off, the <noscript> note shows instead and this one never does. */
.start-note p {
  margin: 0;
}
.start-fallback {
  visibility: hidden;
  animation: start-fallback-shows 0s linear 4s forwards;
}
@keyframes start-fallback-shows {
  to { visibility: visible; }
}
@media (scripting: none) {
  .start-fallback { display: none; }
}

@media (prefers-color-scheme: dark) {
  body.signin-body {
    --text: #ffffff;
    --text-muted: #c7c7cc;
    --text-help: #c7c7cc;         /* 10.10:1 on the card, 9.79:1 or more on every fade */
    --border: #3a3a3c;
    color: var(--text);
  }

  body.signin-body input {
    background: var(--color-card);
    color: var(--text);
  }
}

/* The overnight session of 8 Nov 26, Part 10 (the 7 Nov report's question 7): the sign-in card in the owner pages'
   ivory and forest, colour values only: the page ivory, the card on the mockups' paper, forest the one accent (the Sign
   in button and the focus ring), the ink, muted and line colours the owner pages' (D-485, D-490). Light: ink 12.9:1 on
   the paper, the muted ink 5.6:1, the button's words 10.9:1 on forest. Dark (Midnight Estate, D-494): the canvas, the
   card, the light-green accent with dark words on it (9.3:1). The help colour stays the shared one, light and dark,
   as src/help-line.test.mjs holds (#595f6b 6.2:1 on the paper; #c7c7cc on Midnight Estate's card). Placed after the
   sign-in page's first dark block so it wins in both modes. Nothing else of the page changes. */
body.signin-body {
  --color-page: #f5f2ea;
  --color-card: #fbfaf6;
  --accent: #274638;
  --color-accent: #274638;
  --text: #21342a;
  --text-muted: #586c61;
  --border: #c4cdc0;
  --error: #a3443a;
  --error-bg: #f6e6e2;
  --band-yellow: #fff3db; /* the review family's band, as the owner pages' (D-494); its words #000 at 18.3:1 */
  --shadow-card: 0 6px 20px rgba(29, 54, 37, 0.05); /* the owner pages' card shadow (D-494), for the sign-in card (D-591) */
  /* The v1.4 sign-in sample's corners (D-591), each set once: the card, the photograph, the icon tiles, fields and
     button, and the "Private access" pill. The owner pages' corner tokens are set on their own body only. */
  --radius-signin-card: 28px;
  --radius-signin-tile: 12px;
  --radius-signin-pill: 999px;
  color: var(--text);
}

body.signin-body input {
  background: var(--color-card);
  color: var(--text);
}

@media (prefers-color-scheme: dark) {
  body.signin-body {
    --color-page: #0b1411;
    --color-card: #13211b;
    --accent: #b5d9b8;
    --color-accent: #b5d9b8;
    --text: #f3f2e9;
    --text-muted: #a4b3a6;
    --text-help: #c7c7cc;
    --border: #405248;
    --error: #f08a7e;
    --error-bg: #3a2522;
    --band-yellow: #ffc66d; /* the review family's dark accent as the band; the notice's black words on it 13.0:1 */
    --shadow-card: 0 6px 20px rgba(0, 0, 0, 0.15);
    color: var(--text);
  }

  /* The Sign in button's words dark on the light-green accent (Part 10, 8 Nov 26): colour only. */
  body.signin-body button:not(.secondary),
  body.signin-body a.primary {
    color: var(--dark-site-secondary-ink);
  }
}

/* The sign-in page in the v1.4 sign-in sample's look (the day brief of 18 Nov 26, Part 3; D-591): the brand at the top
   left, "Private access" at the right; one photograph across the whole page, fading into the page colour at the top
   and the left behind the story, the card standing on the photograph at the right from 1,024 px (Avi, 18 Nov 26: "the
   picture in my sample was spread across the page and the sign on box was on top of it"); on narrower screens the
   short story first, over the faint photograph, then the card, as the sample's phone. Look only: every element the sign-in code reads keeps
   its id, and the whole layout is #start-card, which the code shows only once it knows nobody is signed in (D-356), so
   a signed-in arrival never paints it. The photograph is a licensed stock photo (app/photo-credits.md), drawn as a
   background over the page colour, so a missing file leaves the colour, never a broken image. No "Remember me", no
   "Forgot password?" (D-591). The card takes the cards' one shadow (Part 8). */
/* The page fills the body edge to edge: the body is a centred flex box with three base units of padding, which the
   negative margin takes back; the fields and icon tiles sit on the page colour, as the sample's do. */
.signin-page {
  box-sizing: border-box;
  flex: 1;
  align-self: stretch;
  margin: calc(var(--base) * -3);
  min-height: 100vh;
  padding: calc(var(--base) * 3) calc(var(--base) * 2) calc(var(--base) * 4);
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 3);
  /* One hue only: the page colour fading out over the photograph (Part 8's gradient rule). */
  background-color: var(--color-page);
  background-image:
    linear-gradient(180deg, var(--color-page) 0%, color-mix(in srgb, var(--color-page) 88%, transparent) 40%,
      color-mix(in srgb, var(--color-page) 62%, transparent) 100%),
    url("/photos/signin-lake-house-sunset.jpg");
  background-size: cover;
  background-position: center bottom;
  background-repeat: no-repeat;
}
/* The overnight brief of 18-19 Nov 26, Part 8a (D-597): the photograph is Avi's own image, "Family Wealth Login
   Dashboard.png", cropped to its scenery (the house, the pool, the lake at sunset, the rising bars and line) with none
   of its baked-in words; every word and the form are the page's own. */
.signin-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
}
.signin-brand {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2);
  margin: 0;
  color: var(--accent);
}
.signin-brand-mark { width: 40px; height: 40px; flex: none; }
.signin-brand-words { display: flex; flex-direction: column; }
.signin-brand-name {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text);
}
.signin-brand-caption {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.signin-private {
  display: inline-flex;
  align-items: center;
  gap: var(--base);
  margin: 0;
  min-height: 36px;
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius-signin-pill);
  background: var(--color-card);
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  flex: none;
}
.signin-private svg { width: 16px; height: 16px; color: var(--accent); }
.signin-main {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 3);
}
.signin-story { display: flex; flex-direction: column; gap: calc(var(--base) * 2); }
.signin-eyebrow {
  margin: 0;
  color: var(--accent);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}
.signin-display {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 28px;
  line-height: 1.1;
  color: var(--text);
}
.signin-display em { font-style: normal; color: var(--accent); }
.signin-intro { margin: 0; color: var(--text-muted); font-size: 17px; line-height: 1.5; }
.signin-benefits {
  display: none; /* the sample's phone carries no benefits; they show from 1,024 px */
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: calc(var(--base) * 2);
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}
.signin-benefits li { display: flex; flex-direction: column; gap: var(--base); }
.signin-benefit-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-signin-tile);
  background: var(--color-page);
  color: var(--accent);
}
.signin-benefit-icon svg { width: 18px; height: 18px; stroke-width: 1.7; }
body.signin-body .signin-card {
  box-sizing: border-box;
  width: 100%;
  max-width: none;
  margin: 0;
  padding: calc(var(--base) * 4) calc(var(--base) * 3);
  border: 1px solid var(--border);
  border-radius: var(--radius-signin-card);
  background: var(--color-card);
  box-shadow: var(--shadow-card);
}
.signin-card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-signin-tile);
  background: var(--color-page);
  color: var(--accent);
}
.signin-card-icon svg { width: 22px; height: 22px; }
body.signin-body .signin-card h1 {
  margin: calc(var(--base) * 2) 0 var(--base);
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400; /* D-497: Georgia headings at regular weight (the overnight brief of 18-19 Nov 26, Part 8b) */
  font-size: 38px;
  line-height: 1.1;
  color: var(--text);
}
.signin-sub { margin: 0 0 calc(var(--base) * 3); color: var(--text-muted); font-size: 15px; }
.signin-field { margin: 0 0 calc(var(--base) * 2); }
body.signin-body .signin-field label { display: block; margin: 0 0 var(--base); font-size: 13px; font-weight: 600; color: var(--text); }
body.signin-body .signin-field input {
  box-sizing: border-box;
  width: 100%;
  min-height: 52px;
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius-signin-tile);
  background: var(--color-page);
  font-size: 17px;
}
body.signin-body .signin-card button[type="submit"] {
  width: 100%;
  min-height: 56px;
  margin-top: var(--base);
  border-radius: var(--radius-signin-tile);
  font-size: 17px;
  font-weight: 600;
}
.signin-only {
  margin: calc(var(--base) * 3) 0 0;
  padding-top: calc(var(--base) * 2);
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
}
body.signin-body .signin-card .build-id { margin-top: var(--base); text-align: center; }
@media (min-width: 1024px) {
  .signin-page {
    padding: calc(var(--base) * 4) calc(var(--base) * 7) calc(var(--base) * 5);
    gap: calc(var(--base) * 5);
    /* As Avi's image draws it (Part 8a): the scenery at the bottom left, under the story, the card standing beside it
       on the right; the page colour solid where the story's words sit and fading into the photograph's sky, and
       fading over its right edge, so no edge of the photograph shows. */
    background-image:
      /* The photograph is 66% of the width wide and 389/848 of that tall, about 30.3vw; the fade starts at its top. */
      linear-gradient(180deg, var(--color-page) 0%, var(--color-page) calc(100% - 30.3vw),
        transparent calc(100% - 14vw)),
      linear-gradient(90deg, transparent 0%, transparent 48%, var(--color-page) 64%),
      url("/photos/signin-lake-house-sunset.jpg");
    background-size: auto, auto, 66% auto;
    background-position: 0 0, 0 0, left bottom;
  }
  .signin-main {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(400px, 1fr);
    gap: calc(var(--base) * 3);
    align-items: start;
  }
  .signin-story { padding-top: calc(var(--base) * 2); max-width: 640px; }
  .signin-display { font-size: 52px; }
  .signin-benefits {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    max-width: 560px;
  }
  body.signin-body .signin-card { padding: calc(var(--base) * 7); }
}
@media (prefers-contrast: more), print {
  body.signin-body .signin-card { box-shadow: none; }
  .signin-page { background-image: none; }
}

/* Session 8k fixes (Avi's check of build 6cb63378): Summary's "What you owe"
   figure in red, as every owed figure (Part 8). This rule was lost when the
   "+ Add" styles were removed earlier the same day; tests/session-8k-fixes.py
   now checks every owed class has its red rule. */
.sheet-headline.owed {
  color: var(--color-red);
}

/* A full-size tappable row to another page (Summary's "Net worth over time"
   on the phone): 48 px tall, 17 px, on a card. */
.row-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: calc(var(--base) * 6);
  padding: 0 calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
  background: var(--color-card);
  color: var(--text);
  border-radius: var(--radius);
  font-size: var(--size-body);
  font-weight: 600;
  text-decoration: none;
}

.row-link:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* Phone only: the laptop has the chart on Summary itself. */
a.row-link.overview-phone-only {
  display: none;
}

@media (max-width: 767px) {
  a.row-link.overview-phone-only {
    display: flex;
  }
}

/* ------------------- Session 8k second fixes, B4 (D-200): chart figures folded */
.figures-fold > summary {
  display: flex;
  align-items: center;
  min-height: calc(var(--base) * 6);
  font-size: var(--size-body);
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  list-style: none;
}

.figures-fold > summary::-webkit-details-marker {
  display: none;
}

.figures-fold > summary:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
  border-radius: var(--radius);
}


/* A tap on a point: its date and figure in a small label (chart-points.ts). */
.chart-point-hit {
  fill: transparent;
  stroke: none;
  cursor: pointer;
}

.chart-point-box {
  fill: var(--color-card);
  stroke: var(--border);
  stroke-width: 1;
}

.chart-point-text {
  font-size: var(--size-meta);
  font-weight: 600;
  fill: var(--text);
  font-variant-numeric: tabular-nums;
}

.chart-point-text.owed {
  fill: var(--color-red);
}

.chart-point-mark {
  fill: var(--text);
}

/* ------------------- Session 8k second fixes, B1 (D-200): Health's add-data sheet
   The choice, a full-screen search, and one sheet per account: Cancel and Save
   at the top, the account's round icon in its category colour, one grouped
   card. Same four sizes, one radius, no shadows. */
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

button.search-open[type] {
  display: flex;
  align-items: center;
  gap: var(--base);
  width: 100%;
  min-height: calc(var(--base) * 6);
  margin: calc(var(--base) * 2) 0;
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--color-card);
  color: var(--text-muted);
  font-size: var(--size-body);
  text-align: left;
  font-weight: 400;
  cursor: pointer;
}

button.search-open[type]:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.search-icon,
.round-icon-svg {
  width: calc(var(--base) * 3);
  height: calc(var(--base) * 3);
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}

/* The search fills the screen above the keypad; the list scrolls within it. */
.search-view:not([hidden]) {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: flex;
  flex-direction: column;
  padding: calc(var(--base) * 2);
  padding-top: max(calc(var(--base) * 2), env(safe-area-inset-top));
  background: var(--color-page);
  box-sizing: border-box;
}

.search-view .search-list:not([hidden]) {
  flex: 1 1 auto;
  max-height: none;
  overflow-y: auto;
}

body.entry-searching {
  overflow: hidden;
}

.entry-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 2);
}

/* Part D (Avi's ruling 4 on part A's report, 3 Oct 26): weight 600, as the
   shared sheet's bar and search; a heading's own default is 700. */
.entry-bar h2 {
  margin: 0;
  font-size: var(--size-body);
  font-weight: 600;
  text-align: center;
}

.entry-bar-space {
  width: calc(var(--base) * 6);
}

/* Round 3, Simulator check (3 Oct 26): the keypad is up as soon as the sheet
   opens, and iOS scrolls the amount into view, taking the large name under
   the status bar. The name also sits in the pinned bar, between Cancel and
   Save, as Health's add-data sheet titles its bar. Hidden from screen
   readers: the heading below names the account for them. */
.entry-bar-title {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  font-size: var(--size-body);
  font-weight: 600;
  color: var(--text);
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

button.round-button[type] {
  display: flex;
  align-items: center;
  justify-content: center;
  width: calc(var(--base) * 6);
  height: calc(var(--base) * 6);
  min-height: calc(var(--base) * 6);
  margin: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 50%;
  background: var(--color-card);
  color: var(--text);
  flex: none;
}

/* Save: grey until the amount is a figure it can save, then the accent. */
button.round-button.round-save[type] {
  color: var(--text-muted);
}

button.round-button.round-save.is-ready[type] {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: var(--site-button-ink);
}

button.round-button[type]:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.record-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: calc(var(--base) * 10);
  height: calc(var(--base) * 10);
  margin: 0 auto calc(var(--base) * 1);
  border-radius: 50%;
  background: var(--color-card);
}

.record-icon svg {
  width: calc(var(--base) * 5);
  height: calc(var(--base) * 5);
  fill: none;
  stroke: var(--cat, var(--text));
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.record-title {
  margin: 0;
  font-size: var(--size-heading);
  font-weight: 600;
  text-align: center;
}

/* Off the cards, over the section fade: the text colour, not the grey (L-48). */
.record-sub {
  margin: 0 0 calc(var(--base) * 1);
  font-size: var(--size-meta);
  color: var(--text);
  text-align: center;
}

.search-card {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
}

.entry-notes > :last-child {
  margin-bottom: 0;
}

.entry-sheet .calc-row {
  margin-top: calc(var(--base) * 2);
}

/* One grouped card: a row each for As at, the amount, the due date, Source. */
.sheet-body .entry-group {
  padding: 0 calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 1);
}
/* The evening brief of 17 Nov 26, Part 2's closing (L-104's spacing check): a card's rows ending in a row link, then its
   button's own card (Held in, Secured on, the broker's cash, leases, auto-pays, a loan's changes, a residency period's
   facts), keep a base unit between them so the link never touches the card under it. */
.sheet-body .card-rows:not(:empty) + .entry-group.sheet-card,
.sheet-body .card-rows:not(:empty) + .sheet-attention[hidden] + .entry-group.sheet-card {
  margin-top: var(--base);
}
/* Part 8c's closing (D-598): Held in's holders warning sits between its rows and its button's card; hidden, the gap
   above stays as before (the second selector); shown, the band keeps its own margins. */

.entry-group .group-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  min-height: calc(var(--base) * 6);
  padding: calc(var(--base) * 1) 0;
  border-bottom: 1px solid var(--border);
}

.entry-group .group-row:last-child {
  border-bottom: none;
}

/* A row followed only by a hidden last row is the last one shown, so no line under it either (16 Oct 26, D-365): the
   holder sheet's Reason, hidden on a first row, and the nomination sheet's "in force" row, hidden unless asked. */
.entry-group .group-row:has(+ .group-row[hidden]:last-child) {
  border-bottom: none;
}

.entry-group .group-row > label {
  margin: 0;
  color: var(--text-muted);
  font-size: var(--size-body);
  font-weight: 400;
}

.sheet-body #entry-form .entry-group input.pill-date {
  /* One width, filled or empty (D-252, the rule after the date-box rules). */
  width: var(--date-box-width);
  flex: none;
  margin: 0;
}

.sheet-body #entry-form .entry-group .amount-row {
  flex-wrap: nowrap;
}

.sheet-body #entry-form .entry-group #amount {
  flex: 1 1 auto;
  margin: 0;
  border: none;
  padding-left: 0;
  background: transparent;
}

.amount-unit {
  flex: none;
  font-size: var(--size-body);
  font-weight: 600;
  color: var(--text-muted);
}

.sheet-body #entry-form .entry-group :is(#currency, #update-currency) {
  min-width: calc(var(--base) * 14);
  margin: 0;
}

.entry-group .source-row {
  display: block;
}

.entry-group .source-row > summary {
  display: flex;
  align-items: center;
  gap: var(--base);
  min-height: calc(var(--base) * 5);
  cursor: pointer;
  list-style: none;
  color: var(--text-muted);
}

.entry-group .source-row > summary::-webkit-details-marker {
  display: none;
}

.entry-group .source-row > summary .source-words {
  margin-left: auto;
  color: var(--text);
}

#currency-change {
  display: block;
  margin: 0 0 calc(var(--base) * 1);
}

#currency-change[hidden] {
  display: none;
}

/* The phone's Sign out (D-197) stays on the choice; on the sheet and the
   search, its corner is Save's and Cancel's. */
@media (max-width: 767px) {
  body.sheet-body:is(.vm-entry, #vm-never.vm-never) .top-signout,
  body.sheet-body:is(.vm-search, #vm-never.vm-never) .top-signout,
  body.sheet-body:is(.vm-confirm, #vm-never.vm-never) .top-signout {
    display: none;
  }
}

/* Simulator check, 3 Oct 26 (iOS Safari): focusing the amount scrolls the page,
   which took Cancel and Save off the top. The sheet's bar stays pinned at the
   top while it is open, and on the phone the tab bar steps aside for the sheet
   and the search, which are modal with their own Cancel (as Health's add-data
   sheet). The bar is still in every page (T59); it returns on leaving them. */
.entry-sheet .entry-bar {
  position: sticky;
  top: var(--visible-top, 0);
  z-index: 20;
  margin: 0 calc(var(--base) * -2) calc(var(--base) * 2);
  padding: calc(var(--base) * 1) calc(var(--base) * 2);
  padding-top: max(calc(var(--base) * 1), env(safe-area-inset-top));
  background: var(--color-page);
}

/* Round 3 (3 Oct 26): what iOS scrolls above the pinned bar (the large name)
   showed behind the status bar; the bar's own background now reaches up to
   the screen's top edge, so nothing shows above it. */
.entry-sheet .entry-bar::before {
  content: "";
  position: absolute;
  right: 0;
  bottom: 100%;
  left: 0;
  height: 100vh;
  background: var(--color-page);
}

@media (max-width: 767px) {
  body.sheet-body:is(.vm-entry, #vm-never.vm-never) .tab-bar,
  body.sheet-body:is(.vm-search, #vm-never.vm-never) .tab-bar {
    display: none;
  }
}

/* Round 3 (iOS 27 simulator, 3 Oct 26): on any owner page, while a field has
   the keyboard up, iOS lifted the floating bar above the keyboard, over the
   form (seen on "No longer used"). On the phone the bar steps aside while a
   field is being typed in, as the iPhone's own tab bars do under the keyboard,
   and returns when it closes. */
@media (max-width: 767px) {
  body:has(input:not([type="checkbox"], [type="radio"], [type="button"], [type="submit"]):focus, textarea:focus, select:focus) .tab-bar {
    display: none;
  }
}

button.search-open[type] {
  justify-content: flex-start;
}

/* ===================== Session 8n: the month-end copy and the data check (D-12, Parts C and D) */

/* A two-line row that opens nothing (a file and its fingerprint; a bank and its
   stalest account): the same lines as a row that opens. */
.group-row > .row-lines,
.check-row > .row-lines {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: var(--base) 0;
}

.group-row > .row-lines .row-note,
.check-row > .row-lines .row-note {
  color: var(--text-muted);
  font-size: var(--size-meta);
  overflow-wrap: anywhere;
}

/* A note that needs attention (a bank past the rule; a count that differs): the
   same red as money owed and "not saved" (Part 8), with its words. */
.row-note.row-note-bad {
  color: var(--color-red);
}

.file-list .row-note {
  font-variant-numeric: tabular-nums;
}

.confirm-actions.stacked button {
  margin: 0;
}

/* The statement, on screen: the same four sizes; each record's head a 17 px heading. */
.statement .statement-pages h2 {
  margin-top: calc(var(--base) * 3);
}

.statement .statement-pages h3 {
  font-size: var(--size-body);
  font-weight: 600;
  margin: calc(var(--base) * 2) 0 var(--base);
}

.statement .statement-pages p {
  margin: 0 0 var(--base);
}

.statement-foot {
  font-weight: 600;
}

/* Printing the statement (Save as PDF through Safari's own Print): the
   statement alone, every page of it, in black on white. */
@media print {
  body.sheet-body.copy-page {
    padding: 0;
    background: var(--color-card);
  }
  body.copy-page .tab-bar,
  body.copy-page .top-signout,
  body.copy-page .build-id,
  body.copy-page #content > :not(#month-end-statement) {
    display: none !important;
  }
  body.copy-page #month-end-statement {
    display: block;
    background: var(--color-card);
    color: var(--text);
    padding: 0;
  }
  body.copy-page #month-end-statement-fold > summary {
    display: none;
  }
  body.copy-page #month-end-statement-fold:not([open]) > .statement-pages {
    display: block;
  }
  /* The brief of 12 Nov 26, Part 10 (D-544 (4)): in its panel on Records (a printed panel prints alone, below), the
     statement prints alone too: the Make the copy tab and the line before a copy left out, the Statement tab printed
     whichever tab is shown. Display only. */
  body.sheet-body > #tool-panel-month-end-copy .tool-tab-pane:not(:has(> #month-end-statement)),
  body.sheet-body > #tool-panel-month-end-copy :is(#month-end-statement-none, #month-end-statement-fold > summary) {
    display: none !important;
  }
  body.sheet-body > #tool-panel-month-end-copy .tool-tab-pane:has(> #month-end-statement),
  body.sheet-body > #tool-panel-month-end-copy #month-end-statement-fold:not([open]) > .statement-pages {
    display: block !important;
  }
  body.sheet-body > #tool-panel-month-end-copy #month-end-statement {
    background: var(--color-card);
    color: var(--text);
    padding: 0;
  }
}


/* ---------- Session 8k step 9, part A (D-202): every owner form as a sheet
   session-8k-forms-proposal.md section 2 (ruled by Avi, 3 Oct 26); src/sheet.ts
   draws the bar. It shares Update's bar, round buttons and grouped rows above
   (D-200). Same sizes (13, 17, 22), one radius, no shadows; ✓ or the word is
   the screen's one primary action. */
.form-sheet[hidden],
.sheet-saved[hidden] {
  display: none;
}

/* The bar and the "Not saved" card under it, pinned together at the visible
   top (as Update's bar: the keypad moves only what is seen on iOS). */
.form-sheet .sheet-top {
  position: sticky;
  top: var(--visible-top, 0);
  z-index: 20;
  margin: 0 calc(var(--base) * -2) calc(var(--base) * 2);
  padding: calc(var(--base) * 1) calc(var(--base) * 2);
  padding-top: max(calc(var(--base) * 1), env(safe-area-inset-top));
  background: var(--color-page);
}

.form-sheet .sheet-top::before {
  content: "";
  position: absolute;
  right: 0;
  bottom: 100%;
  left: 0;
  height: 100vh;
  background: var(--color-page);
}

.form-sheet .sheet-top .entry-bar {
  margin-bottom: 0;
}

/* Stage 14 (the brief of 11 Nov 26, Part 8): a tool in its side panel brings a result into view (Export's Made card)
   below the panel's pinned top, not under it. */
.tool-panel section {
  scroll-margin-top: calc(var(--base) * 14);
}

.form-sheet .sheet-top .sheet-refused {
  margin: calc(var(--base) * 1) 0 0;
}

/* A serious action's word in place of ✓ (Close, Reopen): faint until the form
   can be saved, then the accent. Never red: red is money owed and "not saved". */
button.word-button[type] {
  flex: none;
  width: auto;
  min-width: calc(var(--base) * 6);
  height: calc(var(--base) * 6);
  min-height: calc(var(--base) * 6);
  margin: 0;
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--color-card);
  color: var(--text-muted);
  font-size: var(--size-body);
  font-weight: 600;
}

button.word-button.is-ready[type] {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: var(--site-button-ink);
}

button.word-button[type]:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

@media (prefers-color-scheme: dark) {
  /* As the primary button in dark mode (D-156): white on the dark accent is
     3.23:1 and fails as words; black is 6.49:1. */
  button.word-button.is-ready[type] {
    color: var(--dark-site-is-ready-ink);
  }
}

.form-sheet .sheet-head {
  margin: calc(var(--base) * 1) 0 calc(var(--base) * 2);
}

/* Two weights only on a sheet, 400 and 600 (a heading's own default is 700). */
.form-sheet .record-title,
.sheet-saved h2 {
  font-weight: 600;
}

.form-sheet .sheet-attention {
  font-size: var(--size-meta);
  margin: 0 0 calc(var(--base) * 1);
}
/* Goals' growth warning (above 20%, accepted) on the house amber band, its words carrying it (brief of 7 Nov 26 (b),
   Part 7 item 2; v1.4's review family). */
.form-sheet #goal-assume-problem[data-tone="review"] {
  color: var(--fo-review-accent);
  background: var(--fo-review-bg);
  border: 1px solid var(--fo-review-border);
  border-radius: var(--radius-metric);
  padding: var(--base) calc(var(--base) * 2);
}

/* A group's name and its one line of help sit off the cards, over the section
   fade. The name is in the text colour (L-48: the plain grey is 4.1:1 on the
   fade at its strongest); the help line is in the one help colour, which
   passes there too (Avi's ruling, 4 Oct 26). */
.form-sheet .group-name,
.form-sheet .group-help {
  font-size: var(--size-meta);
  color: var(--text);
}

.form-sheet .group-help {
  color: var(--text-help);
}

.form-sheet .group-name {
  margin: calc(var(--base) * 2) calc(var(--base) * 2) calc(var(--base) * 1);
}

.form-sheet .group-help {
  margin: 0 calc(var(--base) * 2) calc(var(--base) * 2);
}

/* A help line that ends a card (Add a holding's decimal places, under a new instrument's rows): its gap is padding, so
   it stays inside the card; a last child's margin passed through the card's edge and the words touched it (the
   closing of 14 Nov 26, group Q5b; L-104's spacing check). */
.form-sheet .sheet-card > .group-help:last-child {
  margin-bottom: 0;
  padding-bottom: calc(var(--base) * 2);
}

/* A help line that starts a card (the close sheet's "Record a newer balance for each open account at this bank; this
   clears by itself.", D-582): its top margin is 0, so its words touched the card's inside top, on every page that
   borrows the sheet and on both screens (the closing of 17 Nov 26 evening; the brief's 2c B3 card). The card's own
   padding above it, as its last line has below. */
.form-sheet .sheet-card > .group-help:first-child {
  padding-top: calc(var(--base) * 2);
}

/* Rows: the label on the left in grey, the value on the right. */
.form-sheet .group-row[hidden] {
  display: none;
}

.form-sheet .group-row > label,
.form-sheet .group-row > .row-label {
  flex: 0 1 auto;
  margin: 0;
  color: var(--text-muted);
  font-size: var(--size-body);
  font-weight: 400;
}

.sheet-body .form-sheet .group-row > input:not(.pill-date),
.sheet-body .form-sheet .group-row > select {
  flex: 1 1 0;
  width: auto;
  min-width: calc(var(--base) * 10);
  min-height: calc(var(--base) * 4);
  margin: 0;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  color: var(--text);
  font-family: inherit;
  font-size: var(--size-body);
  text-align: right;
}

.sheet-body .form-sheet .group-row > select {
  -webkit-appearance: none;
  appearance: none;
  background-image: none;
  text-align-last: right;
  cursor: pointer;
  /* A long choice is cut with "…", never mid-letter at the row's edge. */
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.form-sheet .group-row > input::placeholder {
  color: var(--text-muted);
  opacity: 1;
}

.sheet-body .form-sheet .entry-group input.pill-date {
  /* One width, filled or empty (D-252, the rule after the date-box rules). */
  width: var(--date-box-width);
  flex: none;
  margin: 0;
}

.form-sheet .row-chevron {
  flex: none;
  color: var(--text-muted);
  font-size: var(--size-body);
}

/* A row that opens the full-screen search: the whole value side is the button. */
button.row-open[type] {
  flex: 1 1 0;
  display: block;
  width: auto;
  min-width: 0;
  min-height: calc(var(--base) * 4);
  margin: 0;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  color: var(--text);
  font-size: var(--size-body);
  font-weight: 400;
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

button.row-open.is-empty[type] {
  color: var(--text-muted);
}

button.row-open[type]:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.form-sheet .row-value {
  flex: 1 1 0;
  min-width: 0;
  color: var(--text);
  font-size: var(--size-body);
  text-align: right;
}

/* Part C: a nominee's row on the Nominations sheet. The name opens the
   full-screen search and takes the room; the share sits beside it with its
   unit; "Remove" shows only when there is more than one nominee. */
.form-sheet .nominee-row > button.row-open[type] {
  text-align: left;
}

.sheet-body .form-sheet .nominee-row > input:not(.pill-date) {
  flex: 0 0 calc(var(--base) * 8);
  min-width: 0;
}

.form-sheet .nominee-row > button.text-button[type] {
  flex: none;
  margin: 0;
  min-height: calc(var(--base) * 4);
}

.form-sheet .nominee-row > button.text-button[hidden] {
  display: none;
}

/* A two-way choice: two buttons side by side in the row. The chosen one is
   filled in the text colour and bold, so colour is not the only sign. */
.form-sheet .group-row.two-way-row {
  padding: 0;
}

.form-sheet .two-way {
  display: flex;
  flex: none;
  gap: calc(var(--base) * 1);
}

.form-sheet .two-way[hidden] {
  display: none;
}

button.two-way-option[type] {
  width: auto;
  height: calc(var(--base) * 5);
  min-height: calc(var(--base) * 5);
  margin: 0;
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--color-card);
  color: var(--text);
  font-size: var(--size-body);
  font-weight: 400;
}

button.two-way-option[aria-pressed="true"][type] {
  background: var(--text);
  border-color: var(--text);
  color: var(--color-card);
  font-weight: 600;
}

button.two-way-option[type]:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* Session 8q (Avi's ruling on his check of 9 Oct 26, step 6): a two-way choice
   whose words can't sit beside its label at 375 px ("Nominees are"): the label
   on its own line, the two buttons on the line below, side by side, sharing
   the card's width; a button's words wrap rather than run past the card. The
   same on the laptop. */
.form-sheet .group-row.two-way-row.two-way-below {
  flex-direction: column;
  align-items: stretch;
  gap: calc(var(--base) * 1);
  padding: calc(var(--base) * 1) 0;
}

.form-sheet .two-way-below .two-way {
  min-width: 0;
}

.form-sheet .two-way-below button.two-way-option[type] {
  flex: 1 1 0;
  min-width: 0;
  height: auto;
  padding: calc(var(--base) * 1);
  white-space: normal;
}

/* A field the page refuses: its row underlined in red; the words are in the
   "Not saved" card under the bar. */
.form-sheet .entry-group .group-row.is-bad {
  border-bottom: 2px solid var(--color-red);
}

/* "More details": the last group, folded to one row. */
.form-sheet details.more-group > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  min-height: calc(var(--base) * 6);
  padding: calc(var(--base) * 1) 0;
  color: var(--text);
  font-size: var(--size-body);
  cursor: pointer;
  list-style: none;
}

.form-sheet details.more-group > summary::-webkit-details-marker {
  display: none;
}

.form-sheet details.more-group > summary .row-value {
  color: var(--text-muted);
}

.form-sheet details.more-group[open] > summary {
  border-bottom: 1px solid var(--border);
}

.form-sheet details.more-group > summary:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* On the phone the sheet takes the page's place: the rest of the page steps aside for it. From 768 px the sheet is a
   panel over the page, which stays where it was behind it, dimmed (D-485, superseding part E and D-218). */
@media (max-width: 767px) {
  body.sheet-open #content > :not(.form-sheet):not(.sheet-saved):not(dialog):not(.sheet-path) {
    display: none !important;
  }

  /* D-559 P2 (a), the brief of 16 Nov 26: every panel fills the phone's screen, a sheet nested inside a page's section
     included. Each part of #content that holds the open sheet (marked "sheet-path" by src/sheet.ts, never a :has()
     naming [hidden], src/view-marks.test.mjs) gives up its own box (its frame, padding and place in a grid), and every
     other part beside it steps aside, so the sheet starts at the screen's top as a direct one does. The !important is
     the rule's whole point: a page rule naming an ID (Summary's hero, `:is(main#base, main)`) had outranked the
     step-aside rule and kept the hero showing over Mark as paid. */
  body.sheet-open #content .sheet-path {
    display: contents !important;
  }

  body.sheet-open #content .sheet-path > :not(.form-sheet):not(.sheet-saved):not(dialog):not(.sheet-path) {
    display: none !important;
  }
}

/* The phone: the tab bar and Sign out step aside for the sheet and its search
   (D-200's rule); both return when it closes. The bar is still in every page
   (T59). */
@media (max-width: 767px) {
  body.sheet-body:is(.vm-form-sheet, .vm-never.vm-never) .tab-bar,
  body.sheet-body:is(.vm-sheet-search, .vm-never.vm-never) .tab-bar {
    display: none;
  }

  /* Named through #content so it outranks the rule that shows Sign out (D-197). */
  body.sheet-body:is(.vm-content-form-sheet, #vm-never.vm-never.vm-never) .top-signout,
  body.sheet-body:is(.vm-content-saved, #vm-never.vm-never.vm-never) .top-signout,
  body.sheet-body:is(.vm-content, #vm-never.vm-never):is(.vm-sheet-search, .vm-never.vm-never) .top-signout {
    display: none;
  }
}

.search-view.sheet-search:not([hidden]) {
  z-index: 50;
}

/* The search's name in its bar: the bar's own weight, as the sheet's title. */
.sheet-search .entry-bar h2 {
  font-weight: 600;
}

/* The laptop: Update's own search sits beside the sidebar, its bar and list in the page's column (Update's entry page
   stays a page, D-485). The shared sheets, their Saved cards and the shared search open as the right-hand panel (the
   D-485 block at the end of this sheet). The small question boxes ("Cancel this entry?", the Filter box) are dialogs
   and stay as they are. */
@media (min-width: 768px) {
  /* Every gap in base units (Part 8): 126 is the sidebar's 30, a gutter of 3 each side and the column's 90 (720 px). */
  .search-view:not([hidden]) {
    left: calc(var(--base) * 30);
    padding-right: max(calc(var(--base) * 3), calc((100vw - var(--base) * 126) / 2 + var(--base) * 3));
    padding-left: max(calc(var(--base) * 3), calc((100vw - var(--base) * 126) / 2 + var(--base) * 3));
    padding-top: calc(var(--base) * 3);
  }
}

/* ---------- Session 8k step 9, part B (D-207): a page that is a list whose
   rows open sheets (Income by year). The same grouped cards, sizes and one
   radius as the sheets above; a row is one button: its name, its value, "›".
   Group names and help sit off the cards, over the section fade, in the text
   colour (L-48), as on the sheets. */
.row-list .group-name,
.row-list .group-help {
  font-size: var(--size-meta);
  font-weight: 400;
  color: var(--text);
}

.row-list .group-help {
  color: var(--text-help);
}

.row-list .group-name {
  margin: calc(var(--base) * 2) calc(var(--base) * 2) calc(var(--base) * 1);
}

.row-list .group-help {
  margin: 0 calc(var(--base) * 2) calc(var(--base) * 2);
}

.row-list .group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 1);
}

.row-list .group-head .group-name {
  margin-bottom: 0;
}

/* X.6 and X.7 (D-469 (7) to (9), the batch-close session of 30 Oct 26; Avi's checks of 29 and 30 Oct 26): every card
   built from a block in code (Debts, Property, What's due, Insurance, Allocation, Commitments, Spending, Goals, Code
   phones, Documents; the account page's holders, auto-pays and leases) follows the card pattern of Accounts and Summary:
   its name at the body size, 600; a figure at the body size in tabular figures; a note at the meta size; the card's own
   padding on every side (the entry group's zero vertical padding is for a form's grouped rows, and left a block's first
   line against the card's top edge); the first line no more inset than the rest (the group name's side margins are for
   a name standing off a card, over the section fade). One rule for every such card (D-209, D-223). */
.sheet-body .entry-group.due-block,
.sheet-body .entry-group.rule-block,
.sheet-body .entry-group.recommend-block,
.sheet-body .entry-group.holder-block {
  padding: calc(var(--base) * 2);
}

.row-list .entry-group.due-block > .group-name,
.row-list .entry-group.rule-block > .group-name,
.row-list .entry-group.recommend-block > .group-name,
.entry-group.due-block > .group-name,
.entry-group.rule-block > .group-name,
.entry-group.recommend-block > .group-name,
.entry-group.holder-block > .group-name {
  margin: 0 0 var(--base);
  font-size: var(--size-body);
  font-weight: 600;
  color: var(--text);
}

.entry-group.due-block > .sheet-figure,
.entry-group.rule-block > .sheet-figure {
  display: block;
  font-size: var(--size-body);
  margin: 0 0 var(--base);
}

.entry-group.due-block > .sheet-meta,
.entry-group.rule-block > .sheet-meta,
.entry-group.recommend-block > .sheet-meta {
  margin: 0 0 var(--base);
}

/* The extended spacing check's first find (the Mac rounds of 30 Oct 26): a sheet's grouped card whose first line is a
   headline, not a row (the holding sheet's "1,234.500 units"), sat on the card's top edge, and its open "Earlier" fold's
   last line on the bottom edge; the card's own padding where a line, not a row, is first or last. */
.form-sheet .entry-group > .sheet-headline:first-child {
  padding-top: calc(var(--base) * 2);
}

/* D-469 (X.20, 30 Oct 26): one line of help under a row inside a grouped card (the Amend sheet's code-phone digits),
   where the field would otherwise be misread; the group's one help line. */
.form-sheet .entry-group > .row-help {
  margin: 0;
  padding: 0 calc(var(--base) * 2) var(--base);
}

/* D-469 (X.8, 30 Oct 26): the Prices page's Indian mutual funds card: MFapi.in and AMFI's file side by side on the
   laptop, one under the other on the phone (375 px holds one column of buttons and a file box). */
.source-pair {
  display: grid;
  gap: calc(var(--base) * 2);
}

.source-block > h3 {
  margin-top: 0;
}

/* D-472 (30 Oct 26, Part 6): a goal's progress bar (Summary's hue, the fill its share of the target) with a thin marker
   at the even-pace point for today; its words stand beside it (never colour alone). The small one on Summary's card. */
.goal-bar {
  position: relative;
  overflow: visible;
  margin: var(--base) 0;
}

.goal-pace-mark {
  position: absolute;
  top: calc(var(--base) * -1);
  bottom: calc(var(--base) * -1);
  width: 2px;
  transform: translateX(-50%);
  background: var(--text);
}

.goal-bar-small {
  height: var(--base);
  margin: var(--base) 0;
}

.goal-pace-line {
  stroke: var(--text-muted);
}

@media (min-width: 1140px) {
  .source-pair {
    grid-template-columns: 1fr 1fr;
    align-items: start;
  }
}

.form-sheet .entry-group > details.more-group[open]:last-child {
  padding-bottom: calc(var(--base) * 2);
}

/* The batch close of 30 Oct 26 (the first full sweep with the extended spacing check, three real finds): a grouped card
   whose first child is a note line (the card's "Valid until" line), the nomination lines list first in the Confirm
   sheet's card, and an open More details fold whose last child is a help line, each get the card's own padding on that
   side; the block cards have their own padding (above) and are left out. */
.entry-group.sheet-card:not(.due-block):not(.rule-block):not(.recommend-block):not(.holder-block) > .sheet-meta:first-child {
  padding-top: calc(var(--base) * 2);
}

/* Part 5 of 4 Nov 26 (the Property rounds): a card of note lines alone (the Property panel's Lease and Documents tabs)
   let its last line's margin collapse through the card's bottom edge; that side gets the card's padding too. */
.entry-group.sheet-card:not(.due-block):not(.rule-block):not(.recommend-block):not(.holder-block) > .sheet-meta:last-child {
  margin-bottom: 0;
  padding-bottom: calc(var(--base) * 2);
}

/* The list's own bottom margin collapses through the card's edge; padding does not. */
.entry-group.sheet-card > .nomination-lines:first-child {
  margin-bottom: 0;
  padding-top: calc(var(--base) * 2);
  padding-bottom: calc(var(--base) * 2);
}

details.entry-group.more-group[open] > .field-note:last-child {
  margin-bottom: 0;
  padding-bottom: calc(var(--base) * 2);
}

button.row-button[type],
a.row-button {
  box-sizing: border-box;
  text-decoration: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  width: 100%;
  min-height: calc(var(--base) * 6);
  margin: 0;
  padding: calc(var(--base) * 1) 0;
  border: none;
  border-bottom: 1px solid var(--border);
  border-radius: 0;
  background: transparent;
  color: var(--text);
  font-size: var(--size-body);
  font-weight: 400;
  text-align: left;
}

/* The last row shown has no line under it (a row after it may be hidden). */
button.row-button[type]:not(:has(~ :not([hidden]))),
a.row-button:not(:has(~ :not([hidden]))) {
  border-bottom: none;
}

/* The overnight brief of 18-19 Nov 26, Part 5's closing: a read-only fact row in a panel (a div, not a control) takes the
   row's look above, with no pointer; before, it had none, and its figure sat on the card's bottom edge. Its last row has
   no line under it (fact rows are never hidden, so :last-child serves). */
div.row-button.row-static {
  box-sizing: border-box;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  width: 100%;
  min-height: calc(var(--base) * 6);
  margin: 0;
  padding: calc(var(--base) * 1) 0;
  border-bottom: 1px solid var(--border);
  color: var(--text);
  font-size: var(--size-body);
  font-weight: 400;
  cursor: default;
}
div.row-button.row-static:last-child {
  border-bottom: none;
}

button.row-button[hidden],
a.row-button[hidden] {
  display: none;
}

button.row-button[type]:focus-visible,
a.row-button:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* Part C (R2): a folded row in a list ("Earlier years"): one row until it is
   opened, then the rows it holds, in the same card. */
details.fold-row > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  min-height: calc(var(--base) * 6);
  padding: calc(var(--base) * 1) 0;
  color: var(--text);
  font-size: var(--size-body);
  cursor: pointer;
  list-style: none;
}

details.fold-row > summary::-webkit-details-marker {
  display: none;
}

details.fold-row > summary .row-value {
  flex: 1 1 0;
  color: var(--text-muted);
  text-align: right;
  font-variant-numeric: tabular-nums;
}


details.fold-row[open] > summary {
  border-bottom: 1px solid var(--border);
}


details.fold-row > summary:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* The last row of a card has no line under it. */
.entry-group > :last-child > .row-button:last-child,
.entry-group > details.fold-row:not([open]):last-child > summary,
.card-rows > .row-button:last-child {
  border-bottom: none;
}

/* Part C (R3): rows at the foot of a card that is not a list (the benchmark's
   card on Summary: Benchmark details, Income by year). */
.card-rows {
  margin-top: calc(var(--base) * 1);
  border-top: 1px solid var(--border);
}

/* A benchmark prompt that opens Benchmark details: the prompt's own words, as
   a button in the text's own size and colour, underlined as a link is. */
button.prompt-open[type] {
  width: auto;
  min-height: calc(var(--base) * 6);
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
  color: inherit;
  font-size: var(--size-meta);
  font-weight: 400;
  text-align: left;
  text-decoration: underline;
}

button.prompt-open[type]:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* A row that adds to its list ("Add an amount"): bold, in the text colour,
   with the "+" mark before its words. */
button.row-button.add-row[type] {
  justify-content: flex-start;
  gap: calc(var(--base) * 1);
  font-weight: 600;
}

/* ---------- Session 8k step 9, part C (Avi's rulings 7-9 and 12, 4 Oct 26):
   the "+" mark on every row that adds a record. A 24 px circle in the accent,
   its plus white in light mode and black in dark. The accent's third use
   (Part 8): the primary action, the focus ring, and this mark. A mark needs
   3:1 against what is behind it; the accent as text would need 4.5:1, which
   it misses on the dark card (4.31:1, D-180), so the words stay in the text
   colour. */
.plus-mark {
  flex: none;
  width: calc(var(--base) * 3);
  height: calc(var(--base) * 3);
}

.plus-mark circle {
  fill: var(--color-accent);
}

.plus-mark path {
  fill: none;
  stroke: var(--plus-ink);
  stroke-width: 2;
  stroke-linecap: round;
}

/* In a search list: the mark, then the words, on one line. */
.picker-option.adds-row {
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: calc(var(--base) * 1);
}

/* The mark alone as a button (Income by year's "Add a year"): a 48 px target
   round the 24 px mark, with its spoken label. */
button.plus-button[type] {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: calc(var(--base) * 6);
  min-height: calc(var(--base) * 6);
  margin: 0;
  padding: 0;
  border: none;
  background: transparent;
}

button.plus-button[type]:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: -2px;
}

.row-button .row-name {
  flex: 0 1 auto;
}

.row-button .row-value {
  flex: 1 1 0;
  min-width: 0;
  color: var(--text-muted);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.row-button .row-chevron {
  flex: none;
  color: var(--text-muted);
}

/* Session 8m (D-265, D-266): a row with two lines of words: its name, and a
   note under it (where a document is kept; a period's person and dates). The
   lines take the row's width and wrap, so a long name never pushes the note
   off the phone's edge (found by the two-screen check, 7 Oct 26). */
.row-button .row-lines {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
  text-align: left;
}

.row-button .row-lines .row-name {
  flex: none;
}

.row-button .row-note {
  color: var(--text-muted);
  font-size: var(--size-meta);
}

/* 4.2 Investments: an instrument's row on the Investments page (its total units, and the date or "dates differ"), and
   the accounts under it, indented, each a link to the account's page. Units are tabular figures with no currency. */
.instrument-row {
  display: flex;
  align-items: center;
  gap: var(--base);
  min-height: calc(var(--base) * 6);
  padding: var(--base) 0;
  border-bottom: 1px solid var(--border);
}

.instrument-row .row-lines {
  flex: 1 1 0;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.instrument-row .row-name {
  font-weight: 600;
}

.instrument-row .row-note {
  color: var(--text-muted);
  font-size: var(--size-meta);
}

.instrument-row .row-value {
  flex: none;
  color: var(--text);
  font-variant-numeric: tabular-nums;
  text-align: right;
}

/* D-444 (28 Oct 26): a button row too, so the Allocation page's classes sit indented under their group (as specific
   as the row button's own rule, which sets its padding). */
button.row-button[type].row-indent,
a.row-button.row-indent {
  padding-left: calc(var(--base) * 3);
}

.row-list .row-empty {
  margin: 0;
  padding: calc(var(--base) * 2) 0;
  color: var(--text-muted);
  font-size: var(--size-body);
}

/* An amount's currency, as a unit beside it: the phone's own picker opens on a tap. */
.sheet-body .form-sheet .group-row > select.unit-select {
  flex: none;
  min-width: 0;
  color: var(--text-muted);
  font-weight: 600;
}

/* "Earlier values", folded under a Correct sheet's rows. */
.form-sheet .earlier-lines {
  padding: calc(var(--base) * 1) 0;
}

.form-sheet .earlier-lines .sheet-meta {
  margin: 0 0 calc(var(--base) * 1);
}

/* The idle sign-out (src/signin-box/idle.ts; Avi's rulings of 14 Oct 26). The warning at 14 minutes: the yellow band of "needs
   attention", black words on it, at the foot of the screen (his ruling 1 of the band session, which moved it from the
   top, away from the phone's top-right Sign out): on the phone just above the tab bar, full width, the words on the
   left and "Stay signed in" on the right; on the laptop at the foot of the page's column, fixed, so on screen while
   the page scrolls. Over any open sheet: every sheet's ✓ sits in its bar pinned at the top, and while the band shows
   the page, a Save pinned to the foot and the full-screen search all make room for it. "Stay signed in" is a plain
   button on the band, so a page keeps its one primary action. The body size (17), the one radius, no shadow. */
.idle-warning {
  position: fixed;
  z-index: 60;
  bottom: calc(var(--base) + env(safe-area-inset-bottom));
  left: calc(var(--base) * 2);
  right: calc(var(--base) * 2);
  box-sizing: border-box;
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  padding: var(--base) calc(var(--base) * 2);
  border-radius: var(--radius);
  background: var(--band-yellow);
  color: var(--idle-warning-ink);
}

.idle-warning[hidden] {
  display: none;
}

.idle-warning-words {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  font-size: var(--size-body);
  color: var(--idle-warning-ink);
}

button.secondary.idle-stay {
  flex: none;
  width: auto;
  white-space: nowrap;
  color: var(--idle-warning-ink);
  border-color: var(--idle-stay-line);
}

/* The phone. Above the tab bar: its own gap of 1 unit, its row of 7, its two 1 px borders, then the band's gap of 1.
   Where the bar steps aside (the same rules as the tab bar's, above: a sheet, a search, the keyboard), the band takes
   the foot. While it shows, the page keeps room under its content for the bar and the band; a Save pinned to the foot
   sits above the band, and the search's list ends above it. */
@media (max-width: 767px) {
  .tab-bar ~ .idle-warning {
    bottom: calc(var(--base) * 9 + 2px + env(safe-area-inset-bottom));
  }

  body.sheet-body:is(.vm-entry, #vm-never.vm-never) .tab-bar ~ .idle-warning,
  body.sheet-body:is(.vm-search, #vm-never.vm-never) .tab-bar ~ .idle-warning,
  body:has(input:not([type="checkbox"], [type="radio"], [type="button"], [type="submit"]):focus, textarea:focus, select:focus) .tab-bar ~ .idle-warning,
  body.sheet-body:is(.vm-form-sheet, .vm-never.vm-never) .tab-bar ~ .idle-warning,
  body.sheet-body:is(.vm-sheet-search, .vm-never.vm-never) .tab-bar ~ .idle-warning {
    bottom: calc(var(--base) + env(safe-area-inset-bottom));
  }

  body.sheet-body:is(.vm-idle, .vm-never.vm-never) {
    padding-bottom: calc(var(--base) * 22 + env(safe-area-inset-bottom));
  }

  body.sheet-body:is(.vm-idle, .vm-never.vm-never) .save-bar {
    bottom: calc(var(--base) * 17 + 2px + env(safe-area-inset-bottom));
  }

  body.sheet-body:is(.vm-idle, .vm-never.vm-never) .search-view:not([hidden]) {
    padding-bottom: calc(var(--base) * 10 + env(safe-area-inset-bottom));
  }
}

/* The laptop: the foot of the page's column, which starts past the 240 px sidebar and its gutter and is no wider than
   the page (.sheet-page), centred as it is. While it shows, the same room as on the phone. */
@media (min-width: 768px) {
  .idle-warning {
    left: calc(var(--base) * 33);
    right: calc(var(--base) * 3);
    bottom: calc(var(--base) * 3);
    max-width: 1040px;
    margin: 0 auto;
  }

  .sheet-page.narrow ~ .idle-warning {
    max-width: 720px;
  }

  body.sheet-body:is(.vm-idle, .vm-never.vm-never) {
    padding-bottom: calc(var(--base) * 12);
  }

  body.sheet-body:is(.vm-idle, .vm-never.vm-never) .save-bar {
    bottom: calc(var(--base) * 11);
  }

  body.sheet-body:is(.vm-idle, .vm-never.vm-never) .search-view:not([hidden]) {
    padding-bottom: calc(var(--base) * 11);
  }
}

#idle-note[hidden] {
  display: none;
}

/* Once signed out for idleness, nothing of the page shows while the sign-in page opens: its figures are withdrawn as
   after a failed read (above), and the whole page is covered. */
:root[data-idle-signed-out] body > * { visibility: hidden !important; }

/* The signed-out arrival (D-356, 17 Oct 26; Avi's ruling of 15 Oct 26). A signed-in page shows nothing but the plain
   page colour until its shared arrival code (src/signin-box/arrive.ts, run through the page's one client) has found someone
   signed in and marked the root element "data-arrived"; a signed-out visitor is taken to the sign-in page before any
   of its layout (the bar, the heading, the cards, Sign out: every direct child of the body) has shown, and the
   section fade waits with it, so the page looks like the sign-in page's own background. The one exception is the
   page's own plain note, written into every signed-in page by tools/tab-bar.mjs: laid out from the start but
   invisible, it becomes visible after 4 seconds unless the page's code has started ("data-arriving") or arrived, as
   the Start page's note does (C5); with JavaScript off it shows at once. Never a blank page (D-302).
   The quick check of f57c94e, L3 (18 Oct 26): the second exception is the arrival code's own line, "Checking who is
   signed in…", which the code adds to the body after 4 seconds without an answer and takes off once it has one; it
   never shows once the layout does. */
:root:not([data-arrived]) body.sheet-body > :not(.arrival-note):not(.arrival-checking) { visibility: hidden; }
:root:not([data-arrived]) body.sheet-body { background-image: none; }
.arrival-note {
  visibility: hidden;
  animation: start-fallback-shows 0s linear 4s forwards;
  max-width: 360px;
  margin: calc(var(--base) * 4) auto;
  padding: calc(var(--base) * 3);
  background: var(--color-card);
  border-radius: var(--radius);
  color: var(--text);
}
.arrival-note p { margin: 0; }
.arrival-checking {
  max-width: 360px;
  margin: calc(var(--base) * 4) auto;
  padding: 0 calc(var(--base) * 3);
  color: var(--text);
  text-align: center;
}
.arrival-checking[hidden],
:root[data-arrived] .arrival-checking { display: none; }
:root[data-arriving] .arrival-note,
:root[data-arrived] .arrival-note { display: none; }
@media (scripting: none) {
  .arrival-note { visibility: visible; animation: none; }
}

/* ---- Part A and Part B of the overnight session of 21 Oct 26 (Avi's check and rulings of 20 Oct 26; D-389) ---- */

/* Part A: a tile alone on its row fills the page's column (two to a row otherwise, D-385). The phone is unchanged. */
@media (min-width: 1140px) {
  .section-tiles > .summary-tile:only-child {
    grid-column: 1 / -1;
  }
}

/* Part A (D-389): the Investments page's summary line ("N holdings of N instruments in N accounts") at the 17 size;
   "Figures read at …" stays a 13 meta line. */
.section-line {
  font-size: var(--size-body);
  font-weight: 400;
  color: var(--text);
  margin: 0 0 var(--base);
}

/* Part B (D-389): the laptop sidebar, top to bottom: Summary, the sections, the three folded groups (Coming soon,
   Records, Tools), Update, Add; More is the phone's only. Each group is a <details>: its <summary> is the heading,
   ▸ folded and ▾ open before the word (the state is also what a screen reader says); a placeholder is a disabled,
   greyed button with "Soon", never a link. */
.tab-fold-mark::before {
  content: "▸";
  display: inline-block;
  width: calc(var(--base) * 2);
}

details[open] > summary .tab-fold-mark::before {
  content: "▾";
}

/* B4 of the overnight session of 25 Oct 26 (D-398; D-209, D-223): every other fold on every page and sheet shows the same
   mark before its words, from this one rule: ▸ folded, ▾ open. The mark is drawn, not spoken (the empty alternative text):
   a screen reader says the summary's words and its expanded or collapsed state. The native marker is hidden here for every
   fold. The trailing › chevrons are gone from folds: › opens a page or a sheet; a fold opens in place. */
details > summary {
  list-style: none;
}

details > summary::-webkit-details-marker {
  display: none;
}

details:not(.tab-fold):not(.more-fold) > summary::before {
  content: "▸" / "";
  display: inline-block;
  flex: none;
  width: calc(var(--base) * 2);
}

details:not(.tab-fold):not(.more-fold)[open] > summary::before {
  content: "▾" / "";
}

details:not(.tab-fold):not(.more-fold) > summary > .row-value {
  margin-left: auto;
}

.tab-fold > summary,
.more-fold > summary {
  list-style: none;
  cursor: pointer;
}

.tab-fold > summary::-webkit-details-marker,
.more-fold > summary::-webkit-details-marker {
  display: none;
}

.tab-fold > summary:focus-visible,
.more-fold > summary:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* A placeholder is a disabled button: the page's own rules for a disabled primary button (white or, in dark mode,
   black on the accent at 0.6 opacity) must not reach it, so these name the element and two classes. */
.tab-pages button[data-soon],
.tab-pages button[data-soon]:disabled {
  display: flex;
  align-items: center;
  gap: var(--base);
  width: 100%;
  min-height: calc(var(--base) * 6);
  margin: 0;
  padding: 0 var(--base);
  border: none;
  border-left: 4px solid transparent;
  font-size: var(--size-body);
  font-weight: 400;
  text-align: left;
  text-decoration: none;
  color: var(--text-muted);
  background: none;
  opacity: 1;
  cursor: default;
}

.more-tiles button.more-tile.more-soon,
.more-tiles button.more-tile.more-soon:disabled {
  margin: 0;
  text-decoration: none;
  color: var(--text-muted);
  background-image: none;
  background-color: var(--color-card);
  opacity: 1;
  cursor: default;
}

/* D-437 (28 Oct 26): the Prices page's gold button, a placeholder until the page asks the price server for it: greyed
   words, no 0.6 fade, named by the element and two classes for the same reason as the placeholders above. */
button.secondary.placeholder-button,
button.secondary.placeholder-button:disabled {
  color: var(--text-muted);
  opacity: 1;
  cursor: default;
}

.soon-mark {
  font-size: var(--size-meta);
  font-weight: 600;
  color: var(--text-muted);
  margin-left: auto;
  padding-left: var(--base);
}

@media (max-width: 767px) {
  .tab-section,
  .tab-group,
  .tab-nav-group {
    display: none;
  }
}

/* D-525 (2), D-526 (4) (the combined session of 9 Nov 26, Part 12): the sidebar's four groups, each under its label in
   small capitals as the v14 reference draws it (its 10 px raised to our smallest size, 11 px, D-508; its 700 to 600,
   src/minimalism.test.mjs), in the navigation's quieter ivory; nothing folds. */
@media (min-width: 768px) {
  .tab-nav-group {
    margin-top: calc(var(--base) * 2);
  }

  .tab-nav-label {
    margin: 0 0 var(--base);
    padding: 0 calc(var(--base) * 2);
    font-size: var(--size-meta);
    font-weight: 600;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--text-muted);
  }

  .tab-nav-group > .tab-pages {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
  }
}

body.sheet-body:not(.section-viewer) .tab-nav-label {
  color: var(--nav-quiet);
}

/* More's page on the phone: the same four groups, each label over its tiles. */
.more-group-label {
  margin: calc(var(--base) * 3) 0 var(--base);
  font-family: inherit;
  font-size: var(--size-meta);
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* P.4 (4d, 20-21 Nov 26): Help, folded on More, each page's one line under its name; the draft mark a review band
   with its words (never colour alone). */
.help-draft {
  margin-top: calc(var(--base) * 3);
}

.help-draft summary {
  cursor: pointer;
  font-size: var(--size-body);
  font-weight: 600;
  min-height: 44px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--base);
}

.help-draft-mark {
  background: var(--band-yellow);
  color: var(--band-head-ink);
  font-size: var(--size-meta);
  font-weight: 600;
  padding: calc(var(--base) / 2) var(--base);
  border-radius: var(--radius-pill);
}

.help-list dt {
  margin-top: calc(var(--base) * 2);
  font-weight: 600;
}

.help-list dd {
  margin: calc(var(--base) / 2) 0 0;
}

/* The Records workspace (D-526 (1); Part 13) and Data Assurance (Part 14): the heading block and the tab row from the
   shared pieces (.ins), the panels outside them so Quick Balance Update keeps the Update page's own look; its column as
   wide as the Update page's was (720 px). */
/* .ins.records-top: two classes, so the shared .ins rule's own margin (0 auto, later in this sheet) does not win. */
body.sheet-body:not(.section-viewer) .ins.records-top {
  margin: 0 0 calc(var(--base) * 3);
}

body.sheet-body:not(.section-viewer) .records-top .records-heading h1 {
  margin: var(--base) 0;
}

/* The seven Data Maintenance pages (restarted 10 Nov 26, Part 14) take this heading too. On the phone their eyebrow
   gives way, since the crumb above it already names the page: Documents' four filters stay in view without scrolling
   (T91, X.17; the phone round of Part 14 found Country under the tab bar). */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .records-top:not(#records-page) .records-heading .ins-eyebrow {
    display: none;
  }
  /* Documents' four filters two by two, as on the laptop and in the template's filter row, so all four are in view
     under the new heading (T91, X.17); their boxes, choices and behaviour are unchanged. */
  body.sheet-body:has(#documents-page) .report-controls:has(#filter-category, #filter-institution) {
    flex-wrap: nowrap;
  }
  body.sheet-body:has(#documents-page) .report-controls:has(#filter-category, #filter-institution) > div {
    min-width: 0;
  }
}

body.sheet-body:not(.section-viewer) .records-top .records-tabs {
  margin-top: calc(var(--base) * 2);
}

/* Quick Balance Update's sheet, search and Saved card take the page as they did on the Update page, whose heading sat
   in the choice and left with it: the workspace's heading and tab row step aside while one is open (as the phone's
   tab bar does) and come back on leaving it. Without this the sheet opened 441 px down the phone's screen, and the
   scroll that brought it up counted as use (9 Nov 26 combined, found by the closing's phone round). */
/* From 768 px the three are the Update balance panel over the page (the brief of 11 Nov 26, Part 9), so the page's top
   stays where it is behind it; the phone keeps the step aside. */
@media (max-width: 767px) {
  body:is(.vm-entry, #vm-never.vm-never) .records-top,
  body:is(.vm-search, #vm-never.vm-never) .records-top,
  body:is(.vm-confirm, #vm-never.vm-never) .records-top,
  body:is(.vm-records, #vm-never):is(.vm-entry, #vm-never.vm-never) .fo-topbar,
  body:is(.vm-records, #vm-never):is(.vm-search, #vm-never.vm-never) .fo-topbar,
  body:is(.vm-records, #vm-never):is(.vm-confirm, #vm-never.vm-never) .fo-topbar {
    display: none;
  }
}

.records-card {
  margin-bottom: calc(var(--base) * 2);
}

.records-card h1,
.records-card h2 {
  margin-top: 0;
}

.records-tiles .records-soon {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--base);
  background: var(--color-card);
  border: 1px solid var(--border);
  color: var(--text);
}

.records-soon-words {
  font-size: var(--size-meta);
  font-weight: 400;
  color: var(--text-muted);
}

.records-note {
  margin-top: calc(var(--base) * 2);
}

/* D-528 (5) (the long session of 10 Nov 26, Part 4): each tab as the v14 template draws it. The tabs' tops (hero, What
   deserves attention, summary) run the page's full width, as on every dashboard; only Quick Balance Update's sheet,
   search and Saved card keep the Update page's 720 px column. Each tab's hero carries its own photograph (D-510). */
.records-quick :is(#entry-form, #search-view, #confirmation) {
  max-width: 720px;
}

body.sheet-body:not(.section-viewer) .ins.records-overview {
  margin: 0;
  max-width: none;
}

body.sheet-body:not(.section-viewer) .ins.records-overview .ins-hero {
  margin-top: 0;
}

body.sheet-body:not(.section-viewer) .ins .ins-hero.records-hero-quick {
  background-image: linear-gradient(95deg, var(--on-photo-fill), var(--on-photo-fill-2) 55%, var(--on-photo-fill-3)), url("/photos/balconies-golden-light.webp");
}

body.sheet-body:not(.section-viewer) .ins .ins-hero.records-hero-maintenance {
  background-image: linear-gradient(95deg, var(--on-photo-fill), var(--on-photo-fill-2) 55%, var(--on-photo-fill-3)), url("/photos/house-at-dusk.webp");
}

body.sheet-body:not(.section-viewer) .ins .ins-hero.records-hero-master {
  background-image: linear-gradient(95deg, var(--on-photo-fill), var(--on-photo-fill-2) 55%, var(--on-photo-fill-3)), url("/photos/villa-by-the-water.webp");
}

body.sheet-body:not(.section-viewer) .records-overview .gr-summary {
  margin-bottom: calc(var(--base) * 4);
}

body.sheet-body:not(.section-viewer) .records-overview .records-tools .ins-section-heading {
  margin-bottom: calc(var(--base) * 2);
}

/* Data Maintenance's tools are links drawn as the shared tiles: no underline, the tile's own colours. */
body.sheet-body:not(.section-viewer) .records-overview a.gr-tile[href],
body.sheet-body:not(.section-viewer) .records-overview a.gr-tile[href] :is(h3, p) {
  text-decoration: none;
  color: var(--text);
}

/* The balance update queue as the template draws it: one full-width row per account, under the shared section heading (.ins). */
body.sheet-body:not(.section-viewer) .records-quick :is(#due-update, #stale-update) .due-tiles {
  grid-template-columns: minmax(0, 1fr);
}

/* The tab row as the template's app tabs: a box holding the three, a space round each, the chosen one in the accent
   with its own ink, each 44 px tall. Our corners, weight and accent stay (D-497, Part 8): the switch's corners, words
   at 600, gaps in base units; the template's 16 px box and 12 px tabs are a difference listed in the report. */
body.sheet-body:not(.section-viewer) .records-top .records-tabs.ins-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  padding: calc(var(--base) * 0.75);
  border-radius: var(--radius-switch);
  background: var(--color-card);
  border: 1px solid var(--border);
  width: fit-content;
  max-width: 100%;
}

body.sheet-body:not(.section-viewer) .records-top .records-tabs > button[type][role="tab"] {
  min-height: 44px;
  padding: 0 calc(var(--base) * 2);
  border-radius: var(--radius-switch-button);
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: var(--size-meta);
  font-weight: 600;
  cursor: pointer;
}

body.sheet-body:not(.section-viewer) .records-top .records-tabs > button[type][role="tab"][aria-selected="true"] {
  background: var(--color-accent);
  color: var(--plus-ink);
}

@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .records-top .records-tabs.ins-tabs {
    width: auto;
  }

  /* One row on the phone: three equal tabs, a long name on two lines inside its 44 px. */
  body.sheet-body:not(.section-viewer) .records-top .records-tabs.ins-tabs {
    flex-wrap: nowrap;
  }

  body.sheet-body:not(.section-viewer) .records-top .records-tabs > button[type][role="tab"] {
    flex: 1 1 0;
    min-width: 0;
    padding: 0 var(--base);
    white-space: normal;
    line-height: 1.2;
  }
}

@media (min-width: 768px) {
  .tab-phone-only {
    display: none;
  }

  .tab-section {
    margin-top: calc(var(--base) * 2);
    padding-top: calc(var(--base) * 2);
    border-top: 1px solid var(--border);
  }

  .tab-section + .tab-section {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
  }

  .tab-group {
    margin-top: var(--base);
  }

  .tab-group + .tab-group {
    margin-top: 0;
  }

  /* After the groups, Update and Add stand apart as the tabs do above. */
  .tab-group + li:not(.tab-group) {
    margin-top: calc(var(--base) * 2);
    padding-top: calc(var(--base) * 2);
    border-top: 1px solid var(--border);
  }

  .tab-fold > summary.tab-group-name {
    display: flex;
    align-items: center;
    min-height: calc(var(--base) * 6);
    margin: 0;
    padding: 0 var(--base);
    border-left: 4px solid transparent;
    font-size: var(--size-body);
    font-weight: 600;
    color: var(--text);
  }

  .tab-fold > .tab-pages {
    margin-top: 0;
    padding-top: 0;
    border-top: none;
  }

}

/* Part B: More's page keeps its one-hue tiles (D-193), each group folded under its heading as in the sidebar. */
.more-fold {
  margin-top: var(--base);
}

.more-fold > summary.more-group-name {
  display: flex;
  align-items: center;
  min-height: calc(var(--base) * 6);
  margin: 0;
}

.more-fold[open] > summary.more-group-name {
  margin-bottom: var(--base);
}

/* D-441 (27 Oct 26): the tiles after the last fold (Sign out) keep the gap the folds keep between themselves; with
   Tools open its last tile stood against Sign out, 0 px (the spacing check, L-104). */
.more-fold + .more-tiles {
  margin-top: var(--base);
}

/* 9 Nov 26 combined (found by Part 18's round): with the groups shown as headed lists, the last group's tiles stood
   against Sign out's own list, 0 px (the spacing check, L-104); the same gap as between the folds. */
.more-tiles + .more-tiles {
  margin-top: var(--base);
}

.more-tiles button.more-tile.more-soon {
  background-image: none;
  background-color: var(--color-card);
  border: 1px solid var(--border);
  font: inherit;
  font-size: var(--size-body);
  font-weight: 600;
  text-align: left;
}

.more-tiles button.more-soon .soon-mark {
  margin-left: 0;
  padding-left: 0;
}

/* ---------- Session 8k step 9, part B (D-211): serious actions set apart.
   "Close this account", "No longer used", "Close this" (an exception) and any
   action of the same kind sit in their own group at the bottom of their page
   (on a list, at the foot of their item), as rows in the text colour. Never
   red: red is money owed and "not saved" (Part 8). The sheet each opens keeps
   its yellow band and its required reason. */
.serious-group {
  margin-top: calc(var(--base) * 3);
}

.serious-group[hidden] {
  display: none;
}

.serious-group .row-button,
.serious-group .row-button .row-name {
  color: var(--text);
}

/* ---------- Session 8k step 9, part C (Avi's ruling R4, 4 Oct 26): a list
   whose items are cards, one each (the exception list). The list's own lines
   go; each card keeps the page's one radius and has no shadow. */
.list-items.card-list {
  border-top: none;
  margin: 0 0 calc(var(--base) * 2);
}

.card-list > .list-item {
  border-bottom: none;
  padding: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
}

.card-list > .list-item > :last-child {
  margin-bottom: 0;
}

.card-list > .list-item > h3 {
  margin-top: 0;
}

/* The band's own card holds the count alone now (the items are cards below). */
.band-body > .list-intro {
  margin: 0;
}

.band-body > .list-intro + .list-line {
  margin-top: calc(var(--base) * 1);
}

/* The Closed fold: its heading is a card, and its items are cards under it. */
.closed-box > summary.sheet-card {
  padding: 0 calc(var(--base) * 2);
}

/* At the foot of an item on a list: set off by a line, no card of its own. */
.list-item > .serious-group {
  margin-top: calc(var(--base) * 2);
  border-top: 1px solid var(--border);
}

.list-item > .serious-group .row-button {
  border-bottom: none;
  padding-bottom: 0;
}

/* Session 8p (Avi's ruling 8, 8 Oct 26): a share fixed by "Sole" (100%) is shown,
   not editable, in the muted text colour; its focus ring is not offered. One rule
   for every page that sets a share (D-223). */
.group-row input[data-typed="share"][readonly] {
  color: var(--text-muted);
}

/* The review round's fix session, item 3.7, G 2d-1 (D-209: every figure page): after a failed read, the figures read
   before are withdrawn until a read works again (src/sheet-page.ts, showLoadError and figuresRead). */
:root[data-figures-withdrawn] [data-figures] { display: none !important; }
/* The brief of 12 Nov 26, Part 10 (D-544 (4)): a tool's side panel keeps the mark to itself (panelShowLoadError). */
[data-figures-scope][data-figures-withdrawn] [data-figures] { display: none !important; }

/* The brief of 12 Nov 26, Part 10 (D-544 (4); the 11 Nov report's question 19 (b)): a printed panel. With a tool's
   panel open, only the panel prints, in the page's flow at the paper's width: no page behind it, no dimmed cover, no
   bar (✕) and no tab row; the tab shown prints. Display only. */
@media print {
  body.sheet-body:is(.vm-tool-panel, .vm-never.vm-never) > :not(.tool-panel:not([hidden])) {
    display: none !important;
  }
  body.sheet-body > .tool-panel:not([hidden]) {
    position: static !important;
    inset: auto !important;
    width: auto !important;
    max-width: none !important;
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
    transform: none !important;
  }
  body.sheet-body > .tool-panel:not([hidden]) :is(.sheet-top, .tool-tabs) {
    display: none !important;
  }
}

/* =====================================================================================================================
   D-485 (the long overnight session of 3 Nov 26, Part 2): the dashboards' look on every owner page, taken from the five
   frozen mockups (Balance Sheet, Investments, Allocation, Tax, What's Due) by their computed styles. Owner pages only:
   her two pages (body.section-viewer) keep their look until 4.14. Written once here, over the rules above, so every
   page, sheet and card takes it from one place (D-209, D-223).

   Colours. Ivory and stone behind, forest green and charcoal ink, muted status colours; cards stay white, so every
   category's colour keeps the contrast measured for it (D-193). Every text and background pair is 4.5:1 or more against
   what is behind it (L-48), light: ink 13.32:1 on ivory and 12.32:1 at the top of its fade; the muted ink 5.31:1 on
   ivory, 4.91:1 at the top of the fade, 5.84:1 on a card, 4.77:1 on stone; the sidebar's words 11.28:1 (its quieter
   words 7.91:1) on forest; the primary action's words 9.96:1; money owed 5.84:1 on a card and 5.45:1 on ivory; needs
   attention 5.65:1 on a card and 4.63:1 on its band; saved 6.02:1. Dark: ink 15.31:1 on the page; the muted ink 8.49:1
   on the page and 7.58:1 or more on a card; the sidebar's words 15.16:1; the primary action's dark words 9.27:1; money
   owed 6.56:1, needs attention 8.27:1, saved 8.60:1. Red still means money owed and "not saved"; yellow still means
   needs attention, with its words; status never by colour alone.

   The type scale, one for every owner page: 11 · 13 · 15 · 17 · 20 · 28 · 38 · 52 px (the five mockups' sizes, merged:
   11 captions, 13 notes, 15 secondary rows, 17 body and controls, 20 card titles, 28 page headings on the phone and
   section display headings, 38 page headings on the laptop and headline figures, 52 the hero's heading on the laptop).
   Georgia for the page's large heading, display headings and the hero; the system font for everything else.

   Gradients, as the mockups use them: the page's own warm fade from the top, and soft fades inside the new pages'
   hero, tiles and bars (the page shell below), each one hue; text and figures readable over them, measured; none under
   prefers-contrast: more or in print. ===================================================================================== */
body.sheet-body:not(.section-viewer) {
  --ivory: #f5f2ea;
  --ivory-top: #efe9dc;
  --stone: #ebe6db;
  --forest: #20382d;
  --forest-2: #274638;
  /* v1.4's light ink, muted, secondary and line (D-494; the overnight session of 3-4 Nov 26, Part 2a): the reference
     page's --text, --muted, --secondary and --line. */
  --text: #21342a;
  --text-muted: #586c61; /* v1.4's #607569, a shade darker to hold 4.5:1 on stone and the page's fade (L-48) */
  --text-help: #51675b;
  --text-on-fade: #51675b;
  --border: #c4cdc0;
  --bg: var(--ivory);
  --color-page: var(--ivory);
  --color-accent: var(--forest-2);
  /* D-532 (2) (Avi's answer of 10 Nov 26): the base button and focus ring read --accent, which this palette did not
     set, so a plain primary on an owner page (Import's "Write to the database", Exchange rates' "Fetch rates") was
     the base blue. Forest, as every other primary here: white words 10.9:1 on it. Dark keeps its own rule (the
     accent with dark words, line 112), now the pale green through --forest-2. */
  --accent: var(--forest-2);
  --plus-ink: #ffffff;
  --color-red: #a3443a;
  --color-orange: #8a5a1c;
  --color-green: #2e6b52;
  --error: #a3443a;
  --error-bg: #f6e6e2;
  --attention-bg: #f4ead3;
  --nav-bg: var(--forest);
  --nav-text: #edf4ef;
  --nav-quiet: #b9d3c4;
  --nav-line: rgba(237, 244, 239, 0.16);
  --nav-selected-bg: rgba(237, 244, 239, 0.12);
  --serif: Georgia, "Times New Roman", serif;
  --size-caption: 11px;
  --size-small: 15px;
  --size-heading: 20px;
  --size-display: 28px;
  --size-headline: 38px;
  --size-hero: 52px;
  --tile-fade: linear-gradient(#fcfbf8, #f2eee5);
  --shadow-card: 0 6px 20px rgba(29, 54, 37, 0.05); /* v1.4's card shadow (D-494) */
  --shadow-lift: 0 23px 48px rgba(29, 54, 37, 0.115); /* the same card under a mouse: the samples' hover, in forest (6 Nov 26) */
  --shadow-panel: -22px 0 70px rgba(29, 54, 37, 0.14); /* the right-hand panel: the samples' drawer, in forest (6 Nov 26) */
  --shadow-quick-look: 0 16px 55px rgba(22, 31, 49, 0.17); /* the v1.1 references' hover card (src/quick-look.ts) */
  /* The mockups' shapes (L-113, the fidelity pass of 3 Nov 26): cards 24 px, the tiles inside them 20 px, the hero
     28 px, switches, chips and tags as pills. */
  --radius-card: 24px;
  --radius-tile: 20px;
  --radius-hero: 28px;
  --radius-pill: 999px;
  /* The mockups' hero card fade (paper to their second panel colour, one hue), the darker lead ink under a hero's
     heading (#314139), the forest's words on paper (#365042), the pills' stone and words (#eee7db, #405248) and the bars'
     forest fade (#295140 to #50705b). */
  --hero-fade: linear-gradient(135deg, #fbfaf6 0%, #f1ede3 100%);
  --text-lead: #314139;
  --forest-ink: #365042;
  --chip-bg: #eee7db;
  --chip-ink: #405248;
  --edit-section-bg: #f1f2ea; /* D-646, the approved demo of 23 Nov 26 (.esec): an Edit record section's tint */
  /* D-653 (1), the approved demo of 22 Nov 26 (.esec.s1 to .s4): Edit record's four sections, each its own tint. */
  --edit-sec-1: #eef3ef;
  --edit-sec-2: #f4efe6;
  --edit-sec-3: #eef0f4;
  --edit-sec-4: #f3eef2;
  --bar-fill: linear-gradient(90deg, #295140, #50705b);
  background-color: var(--ivory);
  background-image: linear-gradient(to bottom, var(--ivory-top) 0, var(--site-section-viewer-fill) calc(var(--base) * 42), var(--ivory) 100%);
  color: var(--text);
  /* v1.4's body text, 15 px at 1.55, which every block without a size of its own inherits; a control or row that sets
     the body size keeps it. */
  font-size: var(--size-small);
  line-height: 1.55;
}

/* A sheet keeps the line height it had before v1.4's body text (the overnight session of 3-4 Nov 26): its rows and help
   lines are sized to fit the phone's one screen, and 1.55 ran Phone & Access's Add a line 2.6 px past it. */
body.sheet-body:not(.section-viewer) .form-sheet {
  line-height: normal;
}

/* Cards and panels on the mockups' ivory paper, not white (L-113: the overnight session kept them white "to keep the
   category colours at their measured contrast"; reversed by the brief of 3 Nov 26, day, Part 1c: the surface stays the
   mockups' and a colour that falls below 4.5:1 on it takes a darker shade of its own hue). Light mode only: the dark
   surfaces and colours are unchanged. Each shade below is at least 4.6:1 on stone (#ebe6db), the darkest surface it
   sits on, and 5.48:1 or more on the paper; the colours already above that keep their values. */
@media not (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) {
    --paper: #fbfaf6;
    --color-card: var(--paper);
    --card-bg: var(--paper);
    --cat-property: rgb(129, 94, 70);
    --cat-cash-at-bank: rgb(26, 96, 212);
    --cat-deposits-at-bank: rgb(0, 109, 151);
    --cat-super: rgb(0, 112, 132);
    --cat-insurance: rgb(0, 115, 101);
    --cat-mutual-funds: rgb(166, 44, 183);
    --cat-gold-and-silver: rgb(171, 72, 0);
    --cat-other-investments: rgb(96, 102, 115);
    --cat-home-loans: rgb(203, 18, 39);
    --cat-credit-cards: rgb(202, 16, 67);
  }
}

/* Dark: v1.4's Midnight Estate (D-494; the v1.4 kit's UNIFIED-LIGHT-DARK-SPEC section 6): canvas #0B1411, card #13211B,
   raised #1B2D24, text #F3F2E9, muted #BECBC1, accent #B5D9B8. */
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) {
    --ivory: #0b1411;
    --ivory-top: #0f1a15;
    --stone: #1b2d24;
    --paper: #13211b;
    --color-card: var(--paper);
    --card-bg: var(--paper);
    --forest: #0b1411;
    --forest-2: #b5d9b8;
    --text: #f3f2e9;
    --text-muted: #a4b3a6;
    --text-help: #becbc1;
    --text-on-fade: #becbc1;
    --border: #405248;
    --plus-ink: #0d1712;
    --color-red: #f08a7e;
    --color-orange: #e2b36b;
    --color-green: #7fcf9f;
    --error: #f08a7e;
    --error-bg: #3a2522;
    --attention-bg: #3a3220;
    --nav-text: #e3ece6;
    --nav-quiet: #a9b6ad;
    --nav-line: rgba(227, 236, 230, 0.14);
    --nav-selected-bg: rgba(227, 236, 230, 0.1);
    --tile-fade: linear-gradient(#1d211e, #181b19);
    --hero-fade: linear-gradient(135deg, #1f2621 0%, #181d1a 100%);
    --text-lead: #c9d4cc;
    --forest-ink: #cfe3d6;
    --chip-bg: #26302a;
    --edit-section-bg: #1d2a1f;
    --edit-sec-1: #17281f;
    --edit-sec-2: #262419;
    --edit-sec-3: #1a2230;
    --edit-sec-4: #261d26;
    --chip-ink: #dbe6de;
    --bar-fill: var(--forest-2);
    --shadow-card: 0 6px 20px rgba(0, 0, 0, 0.15);
    --shadow-lift: 0 22px 48px rgba(0, 0, 0, 0.3);
    --shadow-panel: -22px 0 70px rgba(0, 0, 0, 0.4);
    --shadow-quick-look: 0 16px 55px rgba(0, 0, 0, 0.4);
    background-image: linear-gradient(to bottom, var(--ivory-top) 0, var(--ivory) calc(var(--base) * 42));
  }

}

/* The primary action takes the forest accent through the --color-accent token the button rules above already read
   (white words 10.40:1; in dark mode their black words on the light green, 10.64:1), so no rule of its own here: one with
   this block's weight would out-rank every button's own background (row buttons, tiles, two-way choices). */

/* Cards: the mockups' ivory paper, their 24 px corners and their one soft shadow (one depth). */
body.sheet-body:not(.section-viewer) .sheet-card {
  border-color: var(--border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}

/* Georgia for the page's large heading (Tax Q2 a): 28 px on the phone, 38 px on the laptop. Regular weight, never bold:
   Avi's ruling 2 of 3 Nov 26 ("Headings are Georgia 400, never bold"), superseding ruling 4b's 600 on the owner pages;
   her pages keep 600. A dashboard's section heading is v1.4's panel heading, 29 px at 1.1 on the laptop. */
body.sheet-body:not(.section-viewer) .sheet-page h1,
body.sheet-body:not(.section-viewer) .display-heading {
  font-family: var(--serif);
  font-size: var(--size-display);
  font-weight: 400;
  letter-spacing: -0.02em;
}

/* v1.4's panel heading keeps its 1.1 line on the phone too, and so does every display heading outside a dashboard
   section (Tax's three; the long session of 5 Nov 26, Part 4: they fell back to the body's 1.55, 43.4 px against the
   samples' 28.6 on the phone and 31 on the laptop). */
body.sheet-body:not(.section-viewer) .display-heading {
  line-height: 1.1;
}

@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) .sheet-page h1 {
    font-size: var(--size-headline);
  }

  body.sheet-body:not(.section-viewer) .dash-section .display-heading {
    font-size: 28px;
  }
}

/* The navigation in the mockups' forest green: its words ivory, the selected entry on a lighter band with the bar at its
   edge (the laptop) or above it (the phone) and its own weight, so the choice is never shown by colour alone. */
body.sheet-body:not(.section-viewer) .tab-bar {
  background: var(--nav-bg);
  border-color: var(--nav-bg);
  color: var(--nav-text);
}

body.sheet-body:not(.section-viewer) .tab-bar a,
body.sheet-body:not(.section-viewer) .tab-bar summary,
body.sheet-body:not(.section-viewer) .tab-group-name,
body.sheet-body:not(.section-viewer) .tab-who,
body.sheet-body:not(.section-viewer) .tab-foot button.text-button {
  color: var(--nav-quiet);
}

body.sheet-body:not(.section-viewer) .tab-main a.is-selected,
body.sheet-body:not(.section-viewer) .tab-main a.is-selected-phone,
body.sheet-body:not(.section-viewer) .tab-pages a.is-selected {
  color: var(--nav-text);
  background: var(--nav-selected-bg);
  border-left-color: var(--nav-text);
}

body.sheet-body:not(.section-viewer) .tab-main a.is-selected::after,
body.sheet-body:not(.section-viewer) .tab-main a.is-selected-phone::after {
  background: var(--nav-text);
}

/* 9 Nov 26 combined, Part 15: on the laptop the sidebar marks the open page's own entry only; the phone tab a page
   sits under (Summary for a dashboard) is marked on the phone's bar alone, never as a second selected entry. */
@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) .tab-main a.is-selected-phone {
    color: var(--nav-quiet);
    background: none;
    border-left-color: transparent;
  }

  body.sheet-body:not(.section-viewer) .tab-main a.is-selected-phone::after {
    display: none;
  }
}

body.sheet-body:not(.section-viewer) .tab-bar a:focus-visible,
body.sheet-body:not(.section-viewer) .tab-bar summary:focus-visible {
  outline-color: var(--nav-text);
}

body.sheet-body:not(.section-viewer) .tab-pages,
body.sheet-body:not(.section-viewer) .tab-foot,
body.sheet-body:not(.section-viewer) .tab-bar li {
  border-color: var(--nav-line);
}

/* The laptop's sidebar as the mockups draw it (Balance Sheet: 15 px entries about 46 px tall, 14 px corners, the chosen
   one on a lighter rounded band; here 48 px and 16 px inside, on the base unit): no bar at the edge; every entry in the regular weight and the chosen one in
   its own weight as well as on its band, so the choice is never shown by colour alone. The site's name heads it, in
   Georgia (the mockups' "Household Wealth" and "My Wealth" above their lists). */
@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) .tab-bar::before {
    content: "Valeon";
    display: block;
    margin: 0 var(--base) calc(var(--base) * 2);
    font-size: var(--size-heading);
    font-weight: 600;
    line-height: 1.1;
    color: var(--nav-text);
  }

  /* v1.4's navigation (D-494; the overnight session of 3-4 Nov 26, Part 2e): 14 px entries at 1.55 with 13 px corners,
     each icon on its own 22 px rounded tile; the chosen one on the lighter band inside a fine line, in 580 against the
     others' 400, so the choice is never shown by colour alone. */
  body.sheet-body:not(.section-viewer) .tab-main a,
  body.sheet-body:not(.section-viewer) .tab-pages a {
    min-height: calc(var(--base) * 6);
    padding: var(--base) calc(var(--base) * 2);
    border: 1px solid transparent;
    border-radius: var(--radius-button);
    font-size: 15px;
    font-weight: 400;
    line-height: 1.55;
  }

  body.sheet-body:not(.section-viewer) .tab-main a.is-selected,
  body.sheet-body:not(.section-viewer) .tab-pages a.is-selected {
    border-color: var(--nav-selected-line);
    background: var(--nav-selected-band);
    color: var(--nav-selected-ink);
    font-weight: 580;
  }

  body.sheet-body:not(.section-viewer) .tab-bar .tab-icon {
    width: 22px;
    height: 22px;
    padding: 0;
    border-radius: var(--radius-nav-icon);
    background: var(--nav-icon-tile);
    color: var(--nav-icon-ink);
    font-size: 13px;
    font-weight: 580;
    line-height: 1.55;
  }
}

/* The sidebar's group headings and Coming soon's placeholders, on the forest (the quieter ivory, 7.91:1). */
body.sheet-body:not(.section-viewer) .tab-fold > summary.tab-group-name {
  color: var(--nav-text);
}

body.sheet-body:not(.section-viewer) .tab-pages button[data-soon],
body.sheet-body:not(.section-viewer) .tab-pages button[data-soon]:disabled,
body.sheet-body:not(.section-viewer) .tab-bar .soon-mark {
  color: var(--nav-quiet);
}

@media print, (prefers-contrast: more) {
  body.sheet-body:not(.section-viewer) {
    background-image: none;
  }

  body.sheet-body:not(.section-viewer) .sheet-card {
    box-shadow: none;
  }
}

/* ---------- The right-hand panel (D-485, superseding D-218 and the laptop parts of D-202; Avi's ruling 2F): from 768 px
   wide every sheet the shared sheet code opens, its Saved card and the shared search open as a panel 480 px wide from the
   right edge, full height, over the page, the page dimmed behind it (the mockups' dimmer) and inert (D-217), the panel's
   left edge rounded. The sheet's own bar and rules are unchanged (✕ top left, the form's name, ✓ or its word top right;
   D-219). A sheet opened from a panel takes its place at the same width; closing it shows the one beneath with its
   answers kept. The page behind does not scroll and is where it was after. About 250 ms of motion, none under reduced
   motion; nothing waits on it. The phone is unchanged: the sheet takes the screen. */
body.sheet-body {
  --dimmer: rgba(14, 20, 17, 0.28);
}

@media (prefers-color-scheme: dark) {
  body.sheet-body {
    --dimmer: rgba(0, 0, 0, 0.55);
  }
}

@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer).sheet-open {
    overflow: hidden;
  }

  :root:has(body.sheet-body:not(.section-viewer).sheet-open) {
    overflow: hidden;
  }

  body.sheet-body:not(.section-viewer).sheet-open::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 55;
    background: var(--dimmer);
  }

  body.sheet-body:not(.section-viewer) .form-sheet:not([hidden]),
  body.sheet-body:not(.section-viewer) .sheet-saved:not([hidden]),
  body.sheet-body:not(.section-viewer) .search-view.sheet-search:not([hidden]) {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: auto;
    z-index: 60;
    width: 480px;
    max-width: 100vw;
    margin: 0;
    padding: 0 calc(var(--base) * 3) calc(var(--base) * 3);
    overflow-y: auto;
    overscroll-behavior: contain;
    /* The mockups' drawer's ivory paper (#fbfaf6), the same shadow; its left edge rounded as D-485 has it. */
    background: var(--color-card);
    border-radius: var(--radius) 0 0 var(--radius);
    box-shadow: var(--shadow-panel);
    animation: panel-in 250ms ease-out;
  }

  body.sheet-body:not(.section-viewer) .sheet-saved:not([hidden]),
  body.sheet-body:not(.section-viewer) .search-view.sheet-search:not([hidden]) {
    padding-top: calc(var(--base) * 3);
  }

  /* The bar stays pinned at the panel's top as it scrolls; its backing reaches the panel's edges. */
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-top {
    top: 0;
    margin: 0 calc(var(--base) * -3) calc(var(--base) * 2);
    padding: calc(var(--base) * 2) calc(var(--base) * 3);
  }

  body.sheet-body:not(.section-viewer) .form-sheet .sheet-top::before {
    display: none;
  }
}

/* D-536 (1), the brief of 11 Nov 26, Part 7: every side panel takes the approved Income source panel's look, measured
   from it (archive/fidelity/2026-11-11/panel-standard.md): the panel's corners 24 px on the left, its content inset
   32 px; the small-capitals label at the top with the round ✕ 32 px from the right edge; the title in Georgia 38 px
   under them; the record's own line 13 px. The ✓ or the action's word sits beside the ✕, still the screen's one
   primary action. The sheet's fields, its checks and its save are unchanged; the phone keeps its bar (D-504). */
body.sheet-body:not(.section-viewer) .form-sheet .sheet-label {
  display: none;
}
@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) .form-sheet:not([hidden]),
  body.sheet-body:not(.section-viewer) .sheet-saved:not([hidden]),
  body.sheet-body:not(.section-viewer) .search-view.sheet-search:not([hidden]) {
    border-radius: var(--radius-card) 0 0 var(--radius-card);
    padding: 0 calc(var(--base) * 4) calc(var(--base) * 4);
  }
  body.sheet-body:not(.section-viewer) .sheet-saved:not([hidden]),
  body.sheet-body:not(.section-viewer) .search-view.sheet-search:not([hidden]) {
    padding-top: calc(var(--base) * 3);
  }
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-top {
    position: sticky;
    z-index: 2;
    margin: 0 calc(var(--base) * -4) calc(var(--base) * 2);
    padding: calc(var(--base) * 3) calc(var(--base) * 4) calc(var(--base) * 2);
    background: var(--color-card);
  }
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-label {
    min-height: 34px;
    margin: 0;
    /* D-544 (4): between the ✕ at the left and the ✓ at the right, wrapping, never cut short. */
    display: flex;
    align-items: center;
    padding: 0 calc(var(--base) * 7); /* clear of the 34 px ✕ and ✓ */
    color: var(--ins-quiet, var(--text-muted));
    font-size: 11px;
    font-weight: 700;
    line-height: 16px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    white-space: normal;
  }
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-top .entry-bar {
    display: block;
    min-height: 0;
    margin: 0;
    padding: 0;
  }
  /* D-544 (4), the brief of 12 Nov 26, Part 8: one shared bar, the round ✕ at the left and the round ✓ at the right,
     a serious action's word being the ✓'s spoken label (src/sheet.ts). */
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-top .entry-bar > button.secondary[type] {
    position: absolute;
    top: calc(var(--base) * 3);
    left: calc(var(--base) * 4);
    right: auto;
  }
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-top .entry-bar > button.round-save[type] {
    position: absolute;
    top: calc(var(--base) * 3);
    right: calc(var(--base) * 4);
  }
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-top .entry-bar > .entry-bar-space {
    display: none;
  }
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-top .entry-bar .entry-bar-title {
    display: block;
    margin: calc(var(--base) * 2) 0 0;
    color: var(--text);
    font-family: Georgia, "Times New Roman", serif;
    font-size: var(--size-headline); /* 38 px, the Income panel's (D-536 (1)); a long one 28 px (.long-title) */
    font-weight: 400;
    line-height: 1.05;
    letter-spacing: -0.5px;
    white-space: normal;
    text-align: left;
  }
  /* A panel that draws its record's own heading takes that heading as its title, and the sheet's name ("Amend
     instrument", "What you'll do") takes the small-capitals label's place at the top, so it is still said. */
  body.sheet-body:not(.section-viewer) .form-sheet:has(.sheet-head .record-title) .sheet-top .sheet-label {
    display: none;
  }
  body.sheet-body:not(.section-viewer) .form-sheet:has(.sheet-head .record-title) .sheet-top .entry-bar .entry-bar-title {
    min-height: 34px;
    margin: 0;
    display: flex;
    align-items: center;
    padding: 0 calc(var(--base) * 7); /* clear of the 34 px ✕ and ✓ */
    color: var(--ins-quiet, var(--text-muted));
    font-family: inherit;
    font-size: 11px;
    font-weight: 700;
    line-height: 16px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    white-space: normal;
  }
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-head .record-title {
    margin: 0 0 var(--base);
    font-family: Georgia, "Times New Roman", serif;
    font-size: var(--size-headline); /* 38 px, the Income panel's (D-536 (1)); a long one 28 px (.long-title) */
    font-weight: 400;
    line-height: 1.05;
    letter-spacing: -0.5px;
    white-space: normal;
  }
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-head,
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-head > * {
    text-align: left;
  }
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-head .record-sub {
    font-size: 13px;
    color: var(--text-muted);
  }
  /* The tab row's buttons on one line, each as wide as its words, as on the Income panel (29 px high). */
  body.sheet-body:not(.section-viewer) .form-sheet [role="tablist"] > button[type] {
    /* 11 Nov 26: width auto, so each tab starts from its words, not from the shared button's 100% (which shared the row
       out equally and ran "Complete / evidence", 122 px of words, past its 104 px tab). */
    width: auto;
    flex: 1 1 auto;
    white-space: nowrap;
  }
  body.sheet-body:not(.section-viewer) .form-sheet .sheet-head > p:first-child:not(.record-sub) {
    margin: 0 0 calc(var(--base) * 2);
    color: var(--forest-2, var(--color-accent));
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
  }
}

@keyframes panel-in {
  from {
    transform: translateX(32px);
    opacity: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.sheet-body:not(.section-viewer) .form-sheet:not([hidden]),
  body.sheet-body:not(.section-viewer) .sheet-saved:not([hidden]),
  body.sheet-body:not(.section-viewer) .search-view.sheet-search:not([hidden]) {
    animation: none;
  }
}

/* ---------- The page shell for the new dashboards (D-485, D-486; the long overnight session of 3 Nov 26, Part 2f;
   src/shell.ts): the hero (a photograph beside the words, never under them, with its drawn illustration beneath for when
   the photo cannot be shown), the summary tiles, the selector strip, the quick look and the placeholder card. Text never
   sits on a photograph; on a fade it is measured (the muted ink 5.0:1 at the fade's foot). Owner pages only. */
/* The hero as the mockups draw it (L-113): one card with 28 px corners, the photograph filling its share of it edge to
   edge (on top on the phone and up to 1,099 px, the mockups' one-column width; beside the words from 1,100 px, the
   words taking 1.3 parts to the photo's 1, Balance Sheet's split), the words on the card's own soft fade, never on the
   photograph. */
body.sheet-body .dash-hero {
  display: grid;
  gap: 0;
  margin: 0 0 calc(var(--base) * 3);
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-hero, var(--radius));
  overflow: hidden;
  background-color: var(--color-card);
  background-image: var(--hero-fade, var(--tile-fade));
  box-shadow: var(--shadow-card);
}

body.sheet-body .dash-hero-art {
  position: relative;
  min-height: calc(var(--base) * 25);
  overflow: hidden;
  background-color: var(--stone);
}

/* The drawn illustration under the photo: a house in fine lines, the forest's colour on stone. */
body.sheet-body .dash-hero-drawing {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  fill: none;
  stroke: var(--forest-2);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: 0.5;
}

body.sheet-body .dash-hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

body.sheet-body .dash-hero-photo[hidden] {
  display: none;
}

/* On the phone the page's Sign out sits at the top right (D-197): a hero that opens the page starts below it, so the
   card never covers it (seen on the three dashboards' phone screenshots, 3 Nov 26). */
@media (max-width: 767px) {
  body.sheet-body:is(.vm-content, #vm-never.vm-never) #content > .dash-hero:first-child {
    margin-top: calc(var(--base) * 6);
  }
}

/* A photograph whose subject sits low in the frame (Property's house on the dune): cropped from the bottom, not the sky. */
body.sheet-body .dash-hero-photo.photo-low {
  object-position: center 85%;
}

body.sheet-body .dash-hero-text {
  min-width: 0;
  padding: calc(var(--base) * 3);
}

body.sheet-body:not(.section-viewer) .sheet-page .dash-hero h1 {
  margin: 0 0 calc(var(--base) * 2);
  font-size: var(--size-headline);
  line-height: 1.02;
}

/* The eyebrow: the mockups' widely spaced capitals (0.18em). */
body.sheet-body .dash-eyebrow {
  margin: 0 0 var(--base);
  font-size: var(--size-caption);
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* The line under the heading: body size, in the darker lead ink the mockups use for it. */
body.sheet-body .dash-subtitle {
  max-width: calc(var(--base) * 65);
  margin: 0 0 calc(var(--base) * 2);
  font-size: var(--size-body);
  line-height: 1.5;
  color: var(--text-lead, var(--text-muted));
}

/* A headline figure: bold, as the mockups' figures are, and never broken inside a number. */
body.sheet-body .dash-figure {
  margin: 0 0 calc(var(--base) * 2);
  font-size: var(--size-headline);
  font-weight: 600;
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
  overflow-wrap: normal;
}

body.sheet-body .dash-figure.owed,
body.sheet-body .dash-tile-figure.owed,
body.sheet-body .row-value.owed {
  color: var(--color-red);
}

body.sheet-body .dash-view {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: var(--base);
  margin: 0 0 calc(var(--base) * 2);
}

/* The switches as the mockups' pills: the one chosen filled in the forest with ivory words and in its own weight (so
   never by colour alone), the others on the paper with the forest's words. */
body.sheet-body button.dash-switch[type] {
  width: auto;
  min-height: calc(var(--base) * 5);
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill, var(--radius));
  background: var(--color-card);
  color: var(--forest-ink, var(--text));
  font-size: var(--size-small);
  font-weight: 600;
}

body.sheet-body button.dash-switch[aria-pressed="true"] {
  border-color: var(--color-accent);
  background: var(--color-accent);
  color: var(--plus-ink, var(--site-button-ink));
  font-weight: 600;
}

/* The currency and date boxes in the shared report controls (A8), inside the switches' row: no margin of their own. */
body.sheet-body .dash-view > .report-controls {
  gap: var(--base);
  margin: 0;
}

body.sheet-body .dash-currency {
  display: flex;
  flex-direction: column;
  gap: var(--base);
  font-size: var(--size-meta);
  color: var(--text-muted);
}

/* The summary tiles: the mockups' metric cards (the paper, 20 px corners, the card shadow), the label in spaced capitals,
   the figure bold at 28 px. Each tile is as wide as its figure needs, side by side while they fit, so a figure is never
   broken inside a number (Property's four tiles, 3 Nov 26). */
body.sheet-body .dash-tiles {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  margin: 0 0 calc(var(--base) * 2);
}

body.sheet-body .dash-tiles[hidden] {
  display: none;
}

body.sheet-body .dash-tile {
  /* As wide as its figure at least (its least width is its figure's, which never wraps: the figures ran out of their
     tiles at 820 px), growing to share the row, the next tile wrapping below when two no longer fit; short figures sit
     side by side on the phone, as the Insurance mockup's three counts do (the fidelity pass, 390 px). */
  flex: 1 1 calc(var(--base) * 12);
  max-width: 100%;
  padding: calc(var(--base) * 2) calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius-tile, var(--radius));
  background-color: var(--color-card);
  box-shadow: var(--shadow-card);
}

body.sheet-body .dash-tile-label {
  margin: 0 0 var(--base);
  font-size: var(--size-caption);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}

body.sheet-body .dash-tile-figure {
  margin: 0;
  font-size: var(--size-display);
  font-weight: 600;
  line-height: 1.08;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* A tile whose figure is words (a placeholder's "comes with ...") wraps as a sentence. */
body.sheet-body .dash-tile-figure.placeholder-words {
  font-size: var(--size-small);
  font-weight: 400;
  white-space: normal;
}

/* Each section of a dashboard is a card of its own, as the mockups draw them: the paper, 24 px corners, the shadow, its
   heading inside it; the cards within it sit on the paper as the mockups' inner tiles do (20 px corners, the soft fade,
   no shadow of their own). */
body.sheet-body .dash-section {
  margin: 0 0 calc(var(--base) * 3);
  padding: calc(var(--base) * 3);
  border: 1px solid var(--border);
  border-radius: var(--radius-card, var(--radius));
  background: var(--color-card);
  box-shadow: var(--shadow-card);
}

body.sheet-body .dash-section > .display-heading {
  margin: 0 0 var(--base);
}

/* v1.4 pads its panels 18 px on the phone (Part 5, 4 Nov 26): 20 on the 4 px grid (D-496 Q8). */
@media (max-width: 720px) {
  body.sheet-body:not(.section-viewer) .dash-section {
    padding: calc(var(--base) * 2);
  }
}

body.sheet-body:not(.section-viewer) .dash-section .sheet-card {
  border-radius: var(--radius-tile, var(--radius));
  background-color: var(--color-card);
  background-image: var(--tile-fade);
  box-shadow: none;
}

body.sheet-body .dash-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(calc(var(--base) * 32), 1fr));
  gap: calc(var(--base) * 2);
}

body.sheet-body .dash-card {
  margin: 0;
  padding: calc(var(--base) * 2);
}

body.sheet-body .dash-card > p {
  margin: 0 0 var(--base);
}

/* A plain link in a dashboard's section ("Open the exception list ›", "Net worth over time ›"): the forest accent,
   underlined, never the browser's blue (1.81:1 on a dark card, the every-view dark round of 3 Nov 26). */
body.sheet-body .dash-section a:not([class]),
body.sheet-body .dash-section .sheet-meta a,
body.sheet-body #budget-placeholder .sheet-meta a {
  color: var(--color-accent);
  text-decoration: underline;
}

/* A later part's place on the page: what comes and the piece that brings it, in the muted ink on a plain card. */
body.sheet-body .placeholder-card {
  padding: calc(var(--base) * 2);
  border-style: dashed;
  box-shadow: none;
}

body.sheet-body .placeholder-words {
  margin: 0;
  color: var(--text-muted);
}

/* The selector strip: tiles that pick a part of the page; the cards not linked to it fade to about a third, none moves
   or hides; the tile chosen is marked by its border, outline and weight as well as its colour. */
body.sheet-body .selector-strip {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  margin: 0 0 calc(var(--base) * 2);
}

body.sheet-body button.selector-tile[type] {
  width: auto;
  min-height: calc(var(--base) * 5);
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill, var(--radius));
  background: var(--color-card);
  color: var(--forest-ink, var(--text));
  font-size: var(--size-small);
  font-weight: 600;
}

body.sheet-body button.selector-tile[aria-pressed="true"],
body.sheet-body button.selector-tile[aria-selected="true"] {
  border-color: var(--color-accent);
  background: var(--color-accent);
  color: var(--plus-ink, var(--site-button-ink));
  font-weight: 600;
}

body.sheet-body button.selector-tile[hidden] {
  display: none;
}

/* The highlight strips (ruling 6 of the overnight brief of 3-4 Nov 26; D-492): the cards linked to the tile chosen are
   ringed in the accent; the rest fade as the reference fades them, its own opacity (.36, Insurance v1.1's ".dimmed";
   D-495, D-496: no contrast minimum while a highlight is chosen). The whole card fades, so money owed keeps its red and
   its minus sign; nothing moves, hides or is stored, and no figure changes. */
body.sheet-body:not(.section-viewer) [data-links] {
  transition: opacity 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

body.sheet-body:not(.section-viewer) [data-links].is-faded {
  opacity: 0.36;
}

body.sheet-body:not(.section-viewer) [data-links].is-linked {
  border-color: color-mix(in srgb, var(--color-accent) 55%, var(--color-card));
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--color-accent) 16%, transparent);
}

/* The hover lift (the overnight brief of 3-4 Nov 26; D-492): the references lift a card 4-5 px with a deeper shadow
   and a strip tile 2 px, over 0.18-0.21 s, measured by tools/behaviour-compare.py. With a mouse only (a finger has no
   hover) and not under reduced motion; nothing moves the layout, since a transform takes no room. The deeper shadow is
   the hover state of the one card shadow, not a second depth at rest. */
@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  body.sheet-body:not(.section-viewer) .due-block,
  body.sheet-body:not(.section-viewer) .portfolio-card,
  body.sheet-body:not(.section-viewer) .policy-category {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
  }

  body.sheet-body:not(.section-viewer) .due-block:hover,
  body.sheet-body:not(.section-viewer) .portfolio-card:hover,
  body.sheet-body:not(.section-viewer) .policy-category:hover,
  body.sheet-body:not(.section-viewer) #liability-list > .due-block:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lift);
  }

  body.sheet-body:not(.section-viewer) button.selector-tile[type] {
    transition: transform 0.18s ease;
  }

  body.sheet-body:not(.section-viewer) button.selector-tile[type]:hover {
    transform: translateY(-2px);
  }
}

/* The Quick look (src/quick-look.ts; 4 Nov 26, Part 3): the v1.1 references' hover card, beside its card, inside the
   window, over the page, moving nothing; 238 px wide, 16 px corners, their shadow; the title 13 px and the hint 11 px
   on our type scale (the references' 12 px and 10 px are off it). Shown by .is-shown, never on a touch. */
body.sheet-body .quick-look {
  position: fixed;
  top: var(--quick-top, 0);
  left: var(--quick-left, 0);
  z-index: 100;
  width: 238px;
  padding: calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius-quick-look);
  background: var(--color-card);
  color: var(--text);
  box-shadow: var(--shadow-quick-look);
  pointer-events: none;
  visibility: hidden;
  opacity: 0;
  transform: translateY(5px) scale(0.98);
  transition: opacity 0.17s, transform 0.17s;
}

body.sheet-body .quick-look.is-shown {
  visibility: visible;
  opacity: 1;
  transform: none;
}

body.sheet-body .quick-look-title {
  margin-bottom: var(--base);
  font-size: var(--size-meta);
  font-weight: 700;
}

body.sheet-body .quick-look-row {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin-top: var(--base);
  font-size: 11px;
}

body.sheet-body .quick-look-row span {
  color: var(--text-muted);
}

body.sheet-body .quick-look-row strong {
  font-weight: 700;
  text-align: right;
}

body.sheet-body .quick-look-row strong.is-not-recorded {
  font-weight: 400;
  color: var(--text-muted);
}

body.sheet-body .quick-look-hint {
  margin-top: calc(var(--base) * 2);
  padding-top: var(--base);
  border-top: 1px solid var(--border);
  color: var(--text-muted);
  font-size: 11px;
}

@media (prefers-reduced-motion: reduce) {
  body.sheet-body .quick-look { transition: none; transform: none; }
}

/* Property in the shell (the long overnight session of 3 Nov 26, Part 4; D-485, D-486): each card's chips (its loans,
   its policies, its rent, in words) and its debt-to-value bar (decoration: the words above it say the ratio), and the
   panel's tabs, marked by border, outline and weight as the selector's tiles are. */
body.sheet-body .chip-line {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  margin: var(--base) 0;
}

/* A portfolio card as the mockup's (Property, 3 Nov 26 fidelity pass): its photograph across the card's top, flush with
   its edges, then the name and three figures across (label above, figure below), then the bar and the chips. */
body.sheet-body .portfolio-card {
  overflow: hidden;
}

body.sheet-body .card-photo {
  position: relative;
  height: calc(var(--base) * 22);
  margin: calc(var(--base) * -2) calc(var(--base) * -2) calc(var(--base) * 2);
  background-color: var(--stone);
}

body.sheet-body .portfolio-card .prop-titleline > .group-name {
  margin: 0;
  font-size: var(--size-heading);
  font-weight: 600;
}

/* Part 5 of the long day session of 4 Nov 26 (the reference's card): the name with its lease status in words beside it,
   and a tag on the photo saying whether the property is yours. */
body.sheet-body .portfolio-card .prop-titleline {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--base);
  margin: 0 0 var(--base);
}

body.sheet-body .card-photo .photo-tag {
  position: absolute;
  z-index: 1;
  top: calc(var(--base) * 2);
  left: calc(var(--base) * 2);
  /* Whole base units (Part 8): the tag's height comes from its line, not a half-unit padding. */
  padding: 0 calc(var(--base) * 2);
  line-height: calc(var(--base) * 3);
  border-radius: var(--radius-pill);
  background: var(--on-photo-fill-4);
  color: var(--on-photo-ink);
  font-size: 11px;
  font-weight: 600;
}

body.sheet-body .dash-section > .group-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
}

body.sheet-body .dash-section > .group-head .display-heading {
  margin: 0 0 var(--base);
}

body.sheet-body .dash-section > .group-head .count-label {
  margin: 0;
  font-size: var(--size-meta);
  color: var(--text-muted);
}

/* The value under the name repeats the Market value cell when the cells are drawn; a property that is not yours keeps it. */
body.sheet-body .portfolio-card:has(> .figure-cells) > .sheet-figure {
  display: none;
}

body.sheet-body .figure-cells {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(calc(var(--base) * 18), 1fr));
  gap: var(--base) calc(var(--base) * 2);
  margin: calc(var(--base) * 2) 0 var(--base);
}

body.sheet-body .figure-cell-label {
  margin: 0 0 var(--base);
  font-size: var(--size-caption);
  color: var(--text-muted);
}

body.sheet-body .figure-cell-figure {
  margin: 0;
  font-size: var(--size-body);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

@media (min-width: 1100px) {
  body.sheet-body .portfolio-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: calc(var(--base) * 2);
    align-items: start;
  }

  body.sheet-body .dash-grid.dash-even:not([hidden]) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* The mockups' pills: stone, the forest's words, bold, no border. */
body.sheet-body .chip {
  padding: var(--base) var(--base);
  border: 0;
  border-radius: var(--radius-pill, var(--radius));
  background: var(--chip-bg, var(--stone));
  color: var(--chip-ink, var(--text));
  font-size: var(--size-meta);
  font-weight: 600;
}

/* The mockups' bars: 16 px tall, stone, rounded at both ends, filled with a soft fade of the forest (one hue). */
body.sheet-body .debt-bar {
  height: calc(var(--base) * 2);
  margin: var(--base) 0;
  border-radius: var(--radius-pill, var(--radius));
  background: var(--stone);
  overflow: hidden;
}

body.sheet-body .debt-bar-fill {
  display: block;
  width: var(--debt-share, 0%);
  height: 100%;
  border-radius: var(--radius-pill, var(--radius));
  background: var(--bar-fill, var(--color-accent));
}

/* The highlight strip's tiles (PROGRESS.md Next 0b; Insurance v1.1's "People & assets", its values rounded to the 4 px
   grid, D-496): the tiles in a row inside the section's own card (which is the reference's strip card); each tile a
   round picture over its name and kind, on the card's own paper with no edge; the tile chosen lightly tinted with a
   ring (forest, the one accent, where the reference is blue), its words in the page's ink. */
body.sheet-body .selector-strip:has(> .strip-tile) {
  gap: calc(var(--base) * 2);
}

body.sheet-body button.strip-tile[type] {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: var(--base);
  min-width: calc(var(--base) * 14);
  min-height: 0;
  padding: var(--base) calc(var(--base) * 2) var(--base);
  border: 1px solid transparent;
  border-radius: var(--radius-strip-tile);
  background: var(--color-card);
  color: var(--text);
  font-weight: 400;
}

body.sheet-body button.strip-tile[type][aria-pressed="true"] {
  border-color: color-mix(in srgb, var(--color-accent) 45%, var(--color-card));
  background: color-mix(in srgb, var(--color-accent) 8%, var(--color-card));
  color: var(--text);
}

body.sheet-body .strip-name {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  color: var(--text);
}

body.sheet-body .strip-kind {
  font-size: 11px;
  font-weight: 400;
  color: var(--text-muted);
}

/* Part 2b (the long day session of 3 Nov 26), at the reference's size since 4 Nov: each tile's picture in a round frame
   with a light edge and a soft shadow, a person's drawn portrait, a car's drawing, or a property's photograph over its
   drawn house (shown if the photo cannot be). */
body.sheet-body .strip-art {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  width: 68px;
  height: 68px;
  overflow: hidden;
  border: 3px solid var(--color-card);
  border-radius: 50%;
  background: var(--stone);
  color: var(--text-muted);
  box-shadow: var(--shadow-card);
}

body.sheet-body .strip-art .strip-drawing {
  width: calc(var(--base) * 4);
  height: calc(var(--base) * 4);
}

@media (max-width: 560px) {
  body.sheet-body .selector-strip:has(> .strip-tile) {
    justify-content: space-around;
    gap: var(--base);
  }

  body.sheet-body button.strip-tile[type] {
    min-width: 84px;
    padding: var(--base) 0;
  }

  body.sheet-body .strip-art {
    width: calc(var(--base) * 6);
    height: calc(var(--base) * 6);
  }

  body.sheet-body .strip-name {
    font-size: 11px;
  }
}

body.sheet-body .strip-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

body.sheet-body .strip-photo[hidden] {
  display: none;
}

/* The category panel's three tabs (Overview, Policies, Documents): the dashboards' switches, in one row. */
body.sheet-body .category-tabs {
  margin: 0 0 calc(var(--base) * 2);
}

body.sheet-body button.dash-switch[aria-selected="true"] {
  border-color: var(--color-accent);
  background: var(--color-accent);
  color: var(--plus-ink, var(--site-button-ink));
}

body.sheet-body .strip-drawing {
  width: calc(var(--base) * 3);
  height: calc(var(--base) * 3);
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* The categories as the Insurance mockup's grid of cards (the fidelity pass, L-113): each a card with its icon tile, its
   name and how many are in force; its policies inside it as tiles; a category holding a policy spans two columns so its
   lines read whole. */
body.sheet-body .policy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(calc(var(--base) * 19), 1fr));
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
}

body.sheet-body .policy-category {
  margin: 0;
  padding: calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius-card, var(--radius));
  background: var(--color-card);
  box-shadow: var(--shadow-card);
}

body.sheet-body .category-top {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
}

body.sheet-body .category-top:last-child {
  margin-bottom: 0;
}

body.sheet-body .category-icon {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: calc(var(--base) * 6);
  height: calc(var(--base) * 6);
  border-radius: var(--radius-tile, var(--radius));
  background: var(--chip-bg, var(--stone));
  color: var(--cat-insurance, var(--forest-ink, var(--text)));
}

body.sheet-body .category-icon svg {
  width: calc(var(--base) * 3);
  height: calc(var(--base) * 3);
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

body.sheet-body .category-top .category-name {
  margin: 0;
  font-size: var(--size-body);
  font-weight: 600;
}

body.sheet-body .category-count {
  margin: 0;
  font-size: var(--size-meta);
  color: var(--text-muted);
}

/* The long day session of 4 Nov 26 (Part 5, Insurance; the reference's category card): the line under the name, the
   arrow (decoration), a hairline, and the foot with the policies, what they cover and one status in words, its mark
   beside the words, never colour alone. */
body.sheet-body .category-line {
  margin: 0;
  font-size: var(--size-meta);
  color: var(--text-muted);
}

body.sheet-body .category-top .card-arrow {
  flex: 0 0 auto;
  align-self: flex-start;
  width: calc(var(--base) * 2);
  height: calc(var(--base) * 2);
  margin-left: auto;
  fill: none;
  stroke: var(--text-muted);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

body.sheet-body .policy-category .card-divider {
  height: 1px;
  margin: 0 0 var(--base);
  background: var(--border);
}

body.sheet-body .policy-category .card-foot {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--base);
  margin: 0 0 calc(var(--base) * 2);
  font-size: var(--size-meta);
  color: var(--text-muted);
}

body.sheet-body .policy-category .card-foot:last-child {
  margin-bottom: 0;
}

body.sheet-body .policy-category .category-people {
  min-width: 0;
}

body.sheet-body .card-status {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: var(--base);
  font-weight: 600;
  color: var(--text);
}

body.sheet-body .card-status::before {
  content: "";
  width: var(--base);
  height: var(--base);
  border-radius: 50%;
  background: var(--text-muted);
}

body.sheet-body .card-status.attention::before {
  background: var(--color-orange);
}

/* A property card's status sits beside its name as a pill (the reference's lease pill). */
body.sheet-body .prop-titleline .card-status {
  padding: 0 var(--base);
  line-height: calc(var(--base) * 3);
  border-radius: var(--radius-pill);
  background: var(--attention-bg);
  font-size: var(--size-caption);
  line-height: 1.4;
}

body.sheet-body .prop-titleline .card-status::before {
  content: none;
}

body.sheet-body .group-head .count-label {
  margin: 0;
  font-size: var(--size-meta);
  color: var(--text-muted);
}

/* Protection review (the reference's review panel): each policy needing attention, Review opening its own page. */
body.sheet-body .review-panel {
  margin: calc(var(--base) * 3) 0 0;
  padding: calc(var(--base) * 3);
}

body.sheet-body .review-panel .group-name {
  margin: 0;
}

body.sheet-body .review-row {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2);
  margin: calc(var(--base) * 2) 0 0;
  padding: calc(var(--base) * 2) 0 0;
  border-top: 1px solid var(--border);
}

body.sheet-body .review-words {
  flex: 1 1 auto;
  min-width: 0;
}

body.sheet-body .review-words p {
  margin: 0;
}

body.sheet-body .review-title {
  font-weight: 600;
}

body.sheet-body a.review-action {
  flex: 0 0 auto;
  padding: var(--base) calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius-switch-button);
  background: var(--color-card);
  color: var(--text);
  font-size: var(--size-meta);
  font-weight: 600;
  text-decoration: none;
}

@media (hover: hover) {
  body.sheet-body:not(.section-viewer) a.review-action:hover {
    background: var(--fo-hover);
  }
}

@media (max-width: 767px) {
  body.sheet-body a.review-action {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }
}

/* The hero's three pills (the reference's feature pills): the hero note pill, in a row. */
body.sheet-body:not(.section-viewer) .fo-hero-pills:not([hidden]) {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  margin: calc(var(--base) * 2) 0 0;
}

body.sheet-body:not(.section-viewer) .fo-hero-pills .fo-hero-note {
  display: inline-block;
  margin: 0;
  padding: var(--base) calc(var(--base) * 2);
  border: 1px solid var(--on-photo-line);
  border-radius: var(--radius-pill);
  background: var(--on-photo-fill-5);
  color: var(--on-photo-ink);
  font-size: 13px;
  font-weight: 600;
}

body.sheet-body .policy-category .sheet-card {
  margin: 0;
  border-radius: var(--radius-tile, var(--radius));
  background-color: var(--color-card);
  background-image: var(--tile-fade);
  box-shadow: none;
}

body.sheet-body .policy-category > .sheet-card + .sheet-card,
body.sheet-body .policy-category > .category-details + .sheet-card {
  margin-top: calc(var(--base) * 2);
}

/* Two across on the phone (the mockup's 390 px), so a category's mark sits above its name there. */
@media (max-width: 767px) {
  body.sheet-body .policy-category {
    padding: calc(var(--base) * 2);
  }

  body.sheet-body .category-top {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--base);
  }

  body.sheet-body .policy-category.has-policies {
    grid-column: 1 / -1;
  }
}

@media (min-width: 768px) {
  body.sheet-body .policy-grid {
    grid-template-columns: repeat(auto-fill, minmax(calc(var(--base) * 30), 1fr));
  }

  body.sheet-body .policy-category.has-policies {
    grid-column: span 2;
  }
}

/* From 768 px: the hero's photo stands taller and the heading takes the hero size. */
@media (min-width: 768px) {
  body.sheet-body .dash-hero-art {
    min-height: calc(var(--base) * 30);
  }

  body.sheet-body .dash-hero-text {
    padding: calc(var(--base) * 4);
  }

  body.sheet-body:not(.section-viewer) .sheet-page .dash-hero h1 {
    font-size: var(--size-hero);
  }

  /* A dashboard's page uses the width beside the sidebar, as the mockups' pages do (no 1,040 px measure). */
  body.sheet-body .sheet-page:has(.dash-hero) {
    max-width: none;
  }
}

/* From 1,100 px (the mockups' two-column width): the words and the photograph side by side, the photograph flush to the
   hero's top, right and bottom edges; a dashboard marked dash-grid sets its sections in Balance Sheet's two columns
   (1.2 parts to 0.8), a section marked dash-wide across both. */
@media (min-width: 1100px) {
  body.sheet-body .dash-hero {
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    align-items: stretch;
    min-height: calc(var(--base) * 40);
  }

  body.sheet-body .dash-hero-art {
    order: 2;
    min-height: 0;
  }

  body.sheet-body .dash-grid:not([hidden]) {
    display: grid;
    grid-template-columns: minmax(0, 1.22fr) minmax(0, 0.78fr); /* v1.4's section grid (D-494) */
    column-gap: calc(var(--base) * 2);
    row-gap: calc(var(--base) * 2);
    align-items: start;
  }

  body.sheet-body .dash-grid > :not(.dash-section),
  body.sheet-body .dash-grid > .dash-wide {
    grid-column: 1 / -1;
  }

  /* Inside a section of the two-column grid, assets above liabilities, as the mockup's composition is one list: two
     columns there broke "1,096,000.00 AUD" across lines. */
  body.sheet-body .dash-grid .dash-section .sheet-columns {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* Debts in the shell (Part 3 of the long day session of 3 Nov 26; src/debts-page.ts): what is owed per currency in the
   hero, side by side and never added; the section heads with their switch; the Coming up rows (the date, PAYMENT or
   CHANGE in words, the liability and what is due); the reconciliation rows. */
body.sheet-body .debt-totals {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base) calc(var(--base) * 3);
  margin: 0 0 calc(var(--base) * 2);
}

body.sheet-body .debt-totals[hidden] {
  display: none;
}

body.sheet-body .debt-total .dash-figure {
  margin: 0;
}

body.sheet-body .debt-total-note {
  flex-basis: 100%;
  margin: 0;
  font-size: var(--size-meta);
  color: var(--text-muted);
}

body.sheet-body .dash-section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--base);
  margin: 0 0 var(--base);
}

body.sheet-body .dash-section-head .display-heading,
body.sheet-body .dash-section-head .dash-view {
  margin: 0;
}

body.sheet-body .coming-row,
body.sheet-body .reconcile-row {
  display: grid;
  grid-template-columns: calc(var(--base) * 14) minmax(0, 1fr);
  gap: var(--base) calc(var(--base) * 2);
  padding: var(--base) 0;
  border-top: 1px solid var(--border);
}

body.sheet-body .coming-row:first-child,
body.sheet-body .reconcile-row:first-child {
  border-top: 0;
}

body.sheet-body .coming-row p,
body.sheet-body .reconcile-row p {
  margin: 0;
}

body.sheet-body .coming-kind {
  font-size: var(--size-caption);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* Part 5 of 4 Nov 26 (Debts): the kind as the reference's event tag, a pill, and each liability a card (24 px, the
   card shadow) as the reference's loan cards, not a tile. */
body.sheet-body .coming-row .coming-kind {
  display: inline-block;
  padding: 0 var(--base);
  line-height: calc(var(--base) * 3);
  border-radius: var(--radius-pill);
  background: var(--chip-bg);
  letter-spacing: 0.08em;
}

body.sheet-body #liability-list > .due-block {
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}

/* Part 5 of 4 Nov 26 (Tax): the specialist pieces as the reference's grid of tiles, four across on the laptop and two
   on the phone (its 13 px gap at Q8's 12), each a tile with no shadow of its own. */
body.sheet-body #tax-pieces, body.sheet-body #budget-pieces {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 2);
}

@media (min-width: 1024px) {
  body.sheet-body #tax-pieces, body.sheet-body #budget-pieces {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

body.sheet-body #tax-pieces > .tax-piece, body.sheet-body #budget-pieces > .tax-piece {
  margin: 0;
  border-radius: var(--radius-tile);
  box-shadow: none;
}

/* A tile's name at the reference's size (14 px, drawn at the scale's 15, Part 8); its weight stays the
   sheets' 600, since nothing outside the headings test's list asks for 700. */
body.sheet-body #tax-pieces > .tax-piece > .group-name, body.sheet-body #budget-pieces > .tax-piece > .group-name {
  font-size: var(--size-small);
}

body.sheet-body .debt-figures {
  margin: 0 0 var(--base);
  font-variant-numeric: tabular-nums;
}

@media (max-width: 767px) {
  body.sheet-body .coming-row,
  body.sheet-body .reconcile-row {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media print, (prefers-contrast: more) {
  body.sheet-body .dash-hero,
  body.sheet-body .dash-tile {
    background-image: none;
    box-shadow: none;
  }
}

/* Cash Flow (the short evening session of 3 Nov 26, Part 2a; D-491): each account's 13-week line in its own currency,
   on its own scale; the zero line where it is crossed; a shortfall in the owed red with its words. The figures are the
   cells' and the panel's table; the line is decoration. */
body.sheet-body .cash-card-name {
  margin: 0;
  font-size: var(--size-body);
  font-weight: 600;
}

body.sheet-body .cash-line {
  display: block;
  width: 100%;
  height: calc(var(--base) * 10);
  margin: calc(var(--base) * 2) 0 0;
}

body.sheet-body .cash-path {
  fill: none;
  stroke: var(--section-summary);
  stroke-width: 2.5;
  stroke-linejoin: round;
  stroke-linecap: round;
}

body.sheet-body .cash-path.is-short {
  stroke: var(--color-red);
}

body.sheet-body .cash-zero {
  stroke: var(--text-muted);
  stroke-width: 1;
  stroke-dasharray: 4 4;
}

body.sheet-body .figure-cell-figure.owed,
body.sheet-body .cash-weeks td.owed,
body.sheet-body .cash-status.is-short {
  color: var(--color-red);
}

body.sheet-body .cash-status {
  margin: 0 0 var(--base);
}

/* =====================================================================================================================
   The v1.4 action system (D-494; the overnight brief of 3-4 Nov 26, Part 2a and 2d). One semantic registry, critical,
   review, information and verified, with the kit's paired light and dark values exactly (tokens/semantic-action-colors
   .json, tokens/unified-action-theme.css). Every owner page's warning, attention and yellow band styles, its saved green
   and its information styles read these. Not changed: liabilities' red and minus sign (T46, T52; --color-red), the
   category colours, chart colours and her pages (4.14). A negative figure, a fall or a variance alone never takes the
   critical family (v1.4 C09): only a record's own severity does (src/action-severity.ts).
   ===================================================================================================================== */
body.sheet-body:not(.section-viewer) {
  --fo-action-bg: #fff0ee;
  --fo-action-border: #b42336;
  --fo-action-accent: #b42336;
  --fo-action-title: #51191f;
  --fo-action-body: #21342a;
  --fo-action-cta-text: #ffffff;
  /* 8 Nov 26 (the overnight brief, Part 4): the critical names Phone & Access and Property read were never defined, so
     their critical tags drew no colour; they are the action family's own, in light and dark alike (declared once here,
     each read through to the action token the dark blocks set). */
  --fo-critical-accent: var(--fo-action-accent);
  --fo-critical-bg: var(--fo-action-bg);
  --fo-review-bg: #fff3db;
  --fo-review-border: #a86d16;
  /* D-496 (Avi's ruling 3 of 4 Nov 26, "Agree with your recommendations"): the light review and information accents are
     #8A560A and #24638B, as in his spec text; the other tokens are the kit's. */
  --fo-review-accent: #8a560a;
  --fo-review-title: #49300c;
  --fo-review-body: #21342a;
  --fo-review-cta-text: #ffffff;
  --fo-info-bg: #eef5fa;
  --fo-info-accent: #24638b;
  --fo-success-bg: #dcefe1;
  --fo-success-accent: #197347;
  --fo-action-shadow: var(--shadow-card); /* D-502, kept: one shadow (v1.4's own red-tinted 0 12px 28px gave way) */
  --fo-action-glow: radial-gradient(circle, rgba(180, 35, 54, 0.06), transparent 70%);
  --fo-review-glow: radial-gradient(circle, rgba(168, 109, 22, 0.08), transparent 70%);
  /* The banner's corners, the v1.4 sample's: 22 px (17 px on the phone), its button 13 px. */
  --radius-action: 22px;
  --radius-action-phone: 17px;
  --radius-button: 13px;
  /* The existing alert styles, now the registry's: attention is the review family, saved is verified. The small yellow
     mark beside a row's attention words stays the one shared mark (D-239), its own yellow. */
  --attention-bg: var(--fo-review-bg);
  --color-orange: var(--fo-review-accent);
  --color-green: var(--fo-success-accent);
}

@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) {
    --fo-action-bg: #3d171f;
    --fo-action-border: #ff626b;
    --fo-action-accent: #ff626b;
    --fo-action-title: #fff4f2;
    --fo-action-body: #f3f2e9;
    --fo-action-cta-text: #250b10;
    --fo-review-bg: #332614;
    --fo-review-border: #eab35a;
    --fo-review-accent: #ffc66d;
    --fo-review-title: #f3f2e9;
    --fo-review-body: #f3f2e9;
    --fo-review-cta-text: #2c1a06;
    --fo-info-bg: #172c37;
    --fo-info-accent: #a9d0ed;
    --fo-success-bg: #173a2a;
    --fo-success-accent: #b5e6c0;
    --fo-action-shadow: var(--shadow-card);
    --fo-action-glow: radial-gradient(circle, rgba(255, 97, 105, 0.15), transparent 69%);
    --fo-review-glow: radial-gradient(circle, rgba(255, 198, 109, 0.13), transparent 69%);
  }
}

/* The yellow band (D-193) is the review family now: its surface, its title ink and a rail in its border colour. */
body.sheet-body:not(.section-viewer) .sheet-attention,
body.sheet-body:not(.section-viewer) .notice,
body.sheet-body:not(.section-viewer) #withheld,
body.sheet-body:not(.section-viewer) #stale-count,
body.sheet-body:not(.section-viewer) .band-head {
  background: var(--fo-review-bg);
  color: var(--fo-review-title);
  box-shadow: inset 4px 0 0 var(--fo-review-border);
}

body.sheet-body:not(.section-viewer) .sheet-attention a,
body.sheet-body:not(.section-viewer) .notice a,
body.sheet-body:not(.section-viewer) #withheld a {
  color: var(--fo-review-title);
}

/* The overnight brief of 18 Nov 26, Part 2's closing: "Fetch today's rates" sits on the review band's surface here, so
   its button and its result take the band's own ink; the old black (Session 8k's yellow band) read 1.43:1 on the dark
   surface. */
body.sheet-body:not(.section-viewer) .fetch-box button.secondary,
body.sheet-body:not(.section-viewer) .fetch-box .fetch-result {
  color: var(--fo-review-title);
  border-color: var(--fo-review-border);
}

/* The featured action (v1.4 FeaturedMaterialAction, C01-C08; src/featured-action.ts): the v1.4 sample's priority banner,
   its values exactly, with the heading in Georgia regular (Avi's ruling 2). A projection of one existing record: its
   button opens that record and nothing is done automatically. */
body.sheet-body:not(.section-viewer) .fo-action {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 284px; /* v1.4's button column, within 4 px */
  align-items: center;
  gap: calc(var(--base) * 3);
  position: relative;
  isolation: isolate;
  overflow: hidden;
  margin: calc(var(--base) * 2) 0;
  padding: calc(var(--base) * 3) calc(var(--base) * 3) calc(var(--base) * 3) calc(var(--base) * 4);
  border: 2px solid var(--fo-action-border);
  border-radius: var(--radius-action);
  background: var(--fo-action-bg);
  box-shadow: var(--fo-action-shadow);
  color: var(--fo-action-body);
}

body.sheet-body:not(.section-viewer) .fo-action::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 9px;
  background: var(--fo-action-border);
}

body.sheet-body:not(.section-viewer) .fo-action::after {
  content: "";
  position: absolute;
  right: 130px;
  top: -100px;
  width: 300px;
  height: 240px;
  background: var(--fo-action-glow);
  pointer-events: none;
  z-index: -1;
}

body.sheet-body:not(.section-viewer) .fo-action-label {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2);
  flex-wrap: wrap;
  margin: 0 0 calc(var(--base) * 1);
  font-size: 13px;
  font-weight: 850;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--fo-action-title);
}

body.sheet-body:not(.section-viewer) .fo-action-symbol {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--fo-action-accent);
  color: var(--fo-action-cta-text);
  font-size: 20px;
  font-weight: 900;
  line-height: 1;
}

body.sheet-body:not(.section-viewer) .fo-action .fo-action-title {
  margin: 0;
  font: 400 var(--size-display) / 1.14 var(--serif);
  letter-spacing: -0.02em;
  color: var(--fo-action-title);
}

body.sheet-body:not(.section-viewer) .fo-action-body {
  margin: calc(var(--base) * 1) 0 0;
  max-width: 760px;
  font-size: 17px;
  line-height: 1.55;
  color: var(--fo-action-body);
}

body.sheet-body:not(.section-viewer) .fo-action-meta {
  margin: calc(var(--base) * 1) 0 0;
  font-size: 13px;
  color: var(--text-help);
}

/* The page's footnote (the build line), as v1.4's in the muted ink, at the scale's 13 px for v1.4's 12 (D-502, kept:
   our type scale). */
body.sheet-body:not(.section-viewer) .build-id {
  font-size: 13px;
  color: var(--text-muted);
}
/* The pages built from their samples show no build line (the brief of 6 Nov 26, Parts 3.5, 4.10 and 6): it stays in
   the page, read by the tools and a screen reader, out of view. */
body.sheet-body:not(.section-viewer):has(#ins-page) .build-id,
body.sheet-body:not(.section-viewer):has(#inc-page) .build-id,
body.sheet-body:not(.section-viewer):has(#debt-page) .build-id,
body.sheet-body:not(.section-viewer):has(#pa-page) .build-id,
body.sheet-body:not(.section-viewer):has(#pr-page) .build-id {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  margin: 0;
  padding: 0;
}

body.sheet-body:not(.section-viewer) .fo-action-actions {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  min-width: 185px;
  gap: calc(var(--base) * 1);
  z-index: 1;
}

body.sheet-body:not(.section-viewer) .fo-action .fo-action-cta {
  min-height: 51px;
  padding: calc(var(--base) * 2) calc(var(--base) * 3);
  border: 0 solid transparent;
  border-radius: var(--radius-button);
  background: var(--fo-action-accent);
  color: var(--fo-action-cta-text);
  font-size: 17px;
  font-weight: 850;
  box-shadow: none;
  cursor: pointer;
}

body.sheet-body:not(.section-viewer) .fo-action .fo-action-cta:hover {
  filter: brightness(1.06);
}

body.sheet-body:not(.section-viewer) .fo-action .fo-action-cta:focus-visible {
  outline: 3px solid currentColor;
  outline-offset: 4px;
}

body.sheet-body:not(.section-viewer) .fo-action-note {
  margin: 0;
  font-size: 11px;
  text-align: center;
  color: var(--text-help);
}

body.sheet-body:not(.section-viewer) .fo-action.is-review {
  border-color: var(--fo-review-border);
  background: var(--fo-review-bg);
  color: var(--fo-review-body);
}

body.sheet-body:not(.section-viewer) .fo-action.is-review::before {
  background: var(--fo-review-border);
}

body.sheet-body:not(.section-viewer) .fo-action.is-review::after {
  background: var(--fo-review-glow);
}

body.sheet-body:not(.section-viewer) .fo-action.is-review .fo-action-symbol,
body.sheet-body:not(.section-viewer) .fo-action.is-review .fo-action-cta {
  background: var(--fo-review-accent);
  color: var(--fo-review-cta-text);
}

/* The review family's label and title keep the page's ink, as the v1.4 sample draws them (measured, the overnight
   session of 3-4 Nov 26); the amber is the border, rail, symbol and button. */
body.sheet-body:not(.section-viewer) .fo-action.is-review .fo-action-label,
body.sheet-body:not(.section-viewer) .fo-action.is-review .fo-action-title {
  color: var(--text);
}

body.sheet-body:not(.section-viewer) .fo-action.is-review .fo-action-body {
  color: var(--fo-review-body);
}

body.sheet-body:not(.section-viewer) .fo-quiet {
  margin: calc(var(--base) * 1) 0 calc(var(--base) * 2);
  font-size: 13px;
  color: var(--text-muted);
}

@media (max-width: 860px) {
  body.sheet-body:not(.section-viewer) .fo-action {
    grid-template-columns: 1fr;
    gap: calc(var(--base) * 2);
  }

  body.sheet-body:not(.section-viewer) .fo-action-actions {
    width: 100%;
    min-width: 0;
  }
}

@media (max-width: 720px) {
  body.sheet-body:not(.section-viewer) .fo-action {
    gap: calc(var(--base) * 2);
    margin: calc(var(--base) * 1) 0 calc(var(--base) * 2);
    padding: calc(var(--base) * 2) calc(var(--base) * 2) calc(var(--base) * 2) calc(var(--base) * 3);
    border-radius: var(--radius-action-phone);
  }

  body.sheet-body:not(.section-viewer) .fo-action .fo-action-title {
    font-size: var(--size-display);
  }

  body.sheet-body:not(.section-viewer) .fo-action-body {
    font-size: 15px;
  }

  body.sheet-body:not(.section-viewer) .fo-action .fo-action-cta {
    width: 100%;
  }

  body.sheet-body:not(.section-viewer) .fo-action-label {
    font-size: 13px;
  }
}

@media (prefers-reduced-motion: reduce) {
  body.sheet-body:not(.section-viewer) .fo-action * {
    animation: none !important;
    transition: none !important;
  }
}

@media print {
  body.sheet-body:not(.section-viewer) .fo-action {
    background: var(--print-fill);
    color: var(--print-ink);
    border: 2px solid var(--print-line);
    box-shadow: none;
    break-inside: avoid;
  }

  body.sheet-body:not(.section-viewer) .fo-action-cta {
    display: none;
  }
}

/* =====================================================================================================================
   The page top (D-494; the overnight brief of 3-4 Nov 26, Part 2f; src/page-top.ts): v1.4's top bar, photo hero and
   metric cards, its values, each gap in whole base units within 4 px of the sample's. The top bar holds the crumb,
   Latest | Month-end, "Another month-end ›", the currency pills and Appearance (Avi's ruling 1).
   ===================================================================================================================== */
body.sheet-body:not(.section-viewer) {
  --radius-photo-hero: 27px;
  --radius-photo-hero-phone: 22px;
  --radius-metric: 21px;
  --radius-metric-phone: 15px;
  --radius-attention: 17px;
  --radius-detail-button: 12px;
  --radius-nav-icon: 8px;
  --radius-strip-tile: 17px; /* the highlight strip's tile, Insurance v1.1's (PROGRESS.md Next 0b) */
  --radius-switch: 13px; /* the Appearance switch's box and its buttons, the kit's .theme-switch (D-497) */
  --radius-switch-button: 12px; /* the box's corner less its 1 px edge, the buttons filling it edge to edge */
  --radius-quick-look: 16px; /* the v1.1 references' hover card (src/quick-look.ts) */
  --radius-icon-box: 16px; /* Insurance's category icon box, its sample's (D-503) */
  --radius-icon-box-small: 12px; /* Insurance's review mark and document icon, its sample's (D-503) */
  --radius-panel-button: 11px; /* the samples' panel foot buttons (.drawer-actions button), and the sheets' word buttons (6 Nov 26) */
  --radius-block: 25px; /* the samples' attention block, people strip and panel edge (6 Nov 26) */
  --radius-review: 23px; /* the samples' review panel (6 Nov 26) */
  --radius-cat-icon: 15px; /* the samples' card icon (6 Nov 26) */
  --radius-light-button: 10px; /* the samples' light buttons and review actions (6 Nov 26) */
  --radius-modal: 26px; /* the Income sample's centred .modal (6 Nov 26) */
  --radius-source-thumb: 14px; /* the Income sample's source thumbnail in its panel (6 Nov 26 (b)) */
  --radius-tab-inner: 8px; /* a forest tab inside its pill, the pill's 11 px less its 3 px inset (6 Nov 26 (b)) */
  --radius-chip-inner: 9px; /* a forest segment inside its 12 px switch, less its 3 px inset (6 Nov 26 (b)) */
  --radius-phase: 8px; /* the Debt sample's interest-only and principal-and-interest bar ends (6 Nov 26 (b)) */
  --radius-photo-card: 25px; /* the Property sample's photo card (6 Nov 26 (c)) */
  --radius-small-chip: 7px; /* the Property sample's card chips (6 Nov 26 (c)) */
  --radius-stat-box: 14px; /* the samples' boxed figures: Property's return stats, Phone & Access's loss and impact boxes (6 Nov 26 (c)) */
  --radius-record-tile: 18px; /* the Property sample's Records & evidence tiles (6 Nov 26 (c)) */
  --radius-stat: 13px; /* the Property sample's panel stat boxes (6 Nov 26 (c)) */
  --radius-record: 15px; /* the samples' record and document blocks in a panel; Phone & Access's loss block (6 Nov 26 (c)) */
  --radius-doc-icon: 10px; /* the Property sample's document icon (6 Nov 26 (c)) */
  --radius-chip-v14: 100px; /* the v14 samples' Explore chips (the brief of 12 Nov 26, Part 13) */
  --radius-share-bar: 2px; /* Balance Sheet & Net Worth's share bars, the approved lower-half demo's (the day brief of 19 Nov 26, Part 2) */
  --fo-control-line: #778578; /* v1.4's --control: a control's outline */
  /* v1.4's sidebar, the same in both themes: the chosen entry's band, line and ink; the icon tiles. */
  --nav-selected-band: #274b37;
  --nav-selected-line: #50705b;
  --nav-selected-ink: #fffbef;
  --nav-icon-tile: #2d4b39;
  --nav-icon-ink: #d9e7db;
  --fo-hero-shadow: var(--shadow-card); /* D-502, kept: one shadow (v1.4's deeper 0 16px 44px gave way) */
  --fo-metric-shadow: 0 6px 20px rgba(29, 54, 37, 0.05);
  --fo-hero-a: rgba(17, 39, 27, 0.88);
  --fo-hero-b: rgba(20, 44, 29, 0.57);
  --fo-hero-c: rgba(9, 20, 15, 0.14);
  --fo-emphasis-border: #6f8977;
}

@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) {
    --fo-hero-shadow: var(--shadow-card);
    --fo-control-line: #61796c;
    --fo-metric-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    --fo-hero-a: rgba(5, 15, 11, 0.92);
    --fo-hero-b: rgba(8, 20, 14, 0.61);
    --fo-hero-c: rgba(5, 15, 10, 0.18);
  }
}

body.sheet-body:not(.section-viewer) .fo-topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
  /* D-590 (3): the top bar stays on screen while the page scrolls, its switches always in reach, on the page's own
     ivory so nothing scrolls through it; under the tab bar (20), the search (30 and up) and every panel, which cover
     it, and over the page's cards. */
  position: sticky;
  top: 0;
  z-index: 15;
  background: var(--color-page);
}
/* The brief of 18-19 Nov 26, Part 2 item 1: one shared rule, on every page and screen, so anything a page scrolls to
   (scrollIntoView, an anchor, a focus) stops a step below the bar that stays on screen, never under it. The bar's own
   height comes from src/page-top.ts (keepRoomUnderTopBar, --fo-topbar-h); a page with no top bar keeps none. */
:root:has(body.sheet-body:not(.section-viewer) .fo-topbar) {
  scroll-padding-top: calc(var(--fo-topbar-h, calc(var(--base) * 0)) + var(--base));
}

body.sheet-body:not(.section-viewer) .fo-crumb {
  margin: 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}

body.sheet-body:not(.section-viewer) .fo-tools {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: var(--base);
}

/* A pill switch: the choices in one pill track, the one in force filled in the accent with its own ink, so never by
   colour alone (aria-pressed says it too). */
body.sheet-body:not(.section-viewer) .fo-seg {
  display: inline-flex;
  align-items: center;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--color-card);
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-help);
}

body.sheet-body:not(.section-viewer) button.fo-seg-button[type],
body.sheet-body:not(.section-viewer) button.fo-chip-button[type] {
  width: auto;
  min-height: 0;
  padding: var(--base) calc(var(--base) * 2);
  border: 0;
  border-radius: var(--radius-pill);
  background: transparent;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 600;
  line-height: 1.55;
  white-space: nowrap;
}

body.sheet-body:not(.section-viewer) button.fo-seg-button[aria-pressed="true"] {
  background: var(--color-accent);
  color: var(--plus-ink, var(--fo-seg-button-ink));
}

body.sheet-body:not(.section-viewer) button.fo-chip-button[type] {
  border: 1px solid var(--border);
  background: var(--color-card);
}

body.sheet-body:not(.section-viewer) button.fo-seg-button[type]:hover,
body.sheet-body:not(.section-viewer) button.fo-chip-button[type]:hover {
  color: var(--text);
}

body.sheet-body:not(.section-viewer) button.fo-seg-button[aria-pressed="true"]:hover {
  color: var(--plus-ink, var(--fo-seg-button-ink));
}

/* Button hovers (the long day session of 4 Nov 26, Part 3; v1.4's .outlinebtn:hover, --hover): an outline button not
   pressed takes the pale green behind its words under a mouse; never on a touch screen, where a hover sticks, and never
   on a disabled one. The words keep their own colour (contrast is measured on the hovered state by the harness). */
body.sheet-body:not(.section-viewer) {
  --fo-hover: #e3e9dd;
}

@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) {
    --fo-hover: #23372b;
  }
}

@media (hover: hover) {
  body.sheet-body:not(.section-viewer) button.secondary[type]:not(:disabled):not([aria-pressed="true"]):hover,
  body.sheet-body:not(.section-viewer) button.fo-chip-button[type]:not(:disabled):hover {
    background: var(--fo-hover);
  }
}

/* The Appearance switch (D-497; the Records & Assurance kit v1.1's segmented control, .theme-switch): Light | Dark |
   System in one rounded box, the choice in force in the accent (forest; the pale green in dark mode) with its own ink,
   and aria-pressed saying it too, never by colour alone; at least 44 px tall on the phone. The kit's 4 px inset and 3 px
   gap are below one base unit (Part 8's spacing rule), so the buttons fill the box edge to edge; its 800 weight is our
   700 (Part 8: no heavier weight). */
body.sheet-body:not(.section-viewer) .fo-appearance {
  display: flex;
  align-items: stretch;
  gap: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
}

body.sheet-body:not(.section-viewer) .fo-appearance[hidden] {
  display: none;
}

body.sheet-body:not(.section-viewer) .fo-appearance button[data-appearance] {
  width: auto;
  min-height: 0;
  margin: 0;
  padding: var(--base) var(--base);
  border: 0;
  border-radius: var(--radius-switch-button);
  background: transparent;
  color: var(--text-muted);
  box-shadow: none;
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
}

body.sheet-body:not(.section-viewer) .fo-appearance button[data-appearance][aria-pressed="true"] {
  background: var(--color-accent);
  color: var(--plus-ink);
}

@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .fo-appearance button[data-appearance] {
    min-height: 44px;
  }
}

/* The page's own date and currency boxes, driven by the pills: kept for the address and the page's code, never shown. */
body.sheet-body:not(.section-viewer) .fo-driven[hidden] {
  display: none;
}

/* The photo hero (ruling 3): the photograph fills the hero; a fade from the left keeps the words over it at 4.5:1 or
   more against what is actually behind them. Its heading is Georgia regular (ruling 2). */
body.sheet-body:not(.section-viewer) .dash-hero.fo-hero {
  display: block;
  position: relative;
  isolation: isolate;
  min-height: 278px;
  margin: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-photo-hero);
  overflow: hidden;
  background: var(--on-photo-fill-6);
  box-shadow: var(--fo-hero-shadow);
}

body.sheet-body:not(.section-viewer) .fo-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, var(--fo-hero-a) 0%, var(--fo-hero-b) 50%, var(--fo-hero-c) 100%);
}

body.sheet-body:not(.section-viewer) .fo-hero-photo {
  position: absolute;
  inset: 0;
  z-index: -2;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 56%;
}

body.sheet-body:not(.section-viewer) .fo-hero-photo[hidden] {
  display: none;
}

body.sheet-body:not(.section-viewer) .fo-hero-copy {
  position: relative;
  max-width: 620px;
  padding: calc(var(--base) * 4) calc(var(--base) * 5);
  color: var(--on-photo-ink-2);
}

body.sheet-body:not(.section-viewer) .fo-eyebrow {
  margin: 0;
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.19em;
  text-transform: uppercase;
  color: var(--fo-eyebrow-ink);
}

body.sheet-body:not(.section-viewer) .sheet-page .fo-hero h1 {
  margin: calc(var(--base) * 2) 0 var(--base);
  font: 400 var(--size-hero) / 1.03 var(--serif);
  letter-spacing: -0.03em;
  color: var(--on-photo-ink-2);
}

body.sheet-body:not(.section-viewer) .fo-hero-line {
  max-width: 540px;
  margin: 0;
  font-size: 17px;
  line-height: 1.55;
  color: var(--on-photo-ink-3);
}

body.sheet-body:not(.section-viewer) .fo-hero-note:not([hidden]),
body.sheet-body:not(.section-viewer) #rate-date.fo-hero-note:not([hidden]) {
  display: inline-block;
  margin: calc(var(--base) * 2) 0 0;
  padding: var(--base) calc(var(--base) * 2);
  border: 1px solid var(--on-photo-line);
  border-radius: var(--radius-pill);
  background: var(--on-photo-fill-5);
  color: var(--on-photo-ink);
  font-size: 13px;
}

body.sheet-body:not(.section-viewer) .fo-hero-note a {
  color: inherit;
}

/* The metric cards: four in a row on the laptop, two from 1,100 px down; the first the emphasis card. */
/* 4 Nov 26 (Avi's check of 4 Nov, step 2): each card takes three rows of the row's grid (its eyebrow, its figure, its
   note) as a subgrid, so a two-line eyebrow in one card moves the figures and notes of the whole row together and every
   note starts at the same height. The space between rows of cards is each card's own bottom margin, as the grid's row
   gap would also open inside the cards. A subgrid cannot be a size container, so the row is the container, and
   --fo-card is one card's width worked out from it for each layout below (the figure's measure). */
body.sheet-body:not(.section-viewer) .fo-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  column-gap: calc(var(--base) * 2);
  row-gap: 0;
  margin: calc(var(--base) * 2) 0 var(--base);
  container-type: inline-size;
  --fo-card: calc((100cqi - var(--base) * 6) / 4);
  --fo-card-padding: calc(var(--base) * 5);
}

body.sheet-body:not(.section-viewer) .fo-metrics > .fo-metric {
  display: grid;
  grid-row: span 3;
  grid-template-rows: subgrid;
  row-gap: 0;
  align-content: start;
  margin-bottom: calc(var(--base) * 2);
}

/* A page with three figures (Insurance's counts) fills the row with three; a row the page has not filled yet stays
   hidden. */
body.sheet-body:not(.section-viewer) .fo-metrics.fo-metrics-three {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  --fo-card: calc((100cqi - var(--base) * 4) / 3);
}

/* Debts: what is owed per currency leads, wider, as the reference's first summary card (1.2fr); each currency's figure
   on its own line, never added, at the scale's 20. */
body.sheet-body:not(.section-viewer) .fo-metrics.fo-metrics-owed {
  grid-template-columns: minmax(0, 1.2fr) repeat(3, minmax(0, 1fr));
  --fo-card: calc((100cqi - var(--base) * 6) / 4.2);
}

body.sheet-body:not(.section-viewer) .fo-metric .debt-totals {
  flex-direction: column;
  gap: var(--base);
  margin: calc(var(--base) * 2) 0 0;
}

body.sheet-body:not(.section-viewer) .fo-metric .debt-total .dash-tile-label {
  margin: 0;
  font-size: 11px;
  color: var(--text-muted);
}

body.sheet-body:not(.section-viewer) .fo-metric .debt-total .dash-figure {
  font: 400 20px / 1.2 var(--serif);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

body.sheet-body:not(.section-viewer) .fo-metric .debt-total-note {
  font-size: 11px;
}

body.sheet-body:not(.section-viewer) .fo-metrics[hidden] {
  display: none;
}

body.sheet-body:not(.section-viewer) .fo-metric {
  min-width: 0;
  min-height: 131px;
  padding: calc(var(--base) * 3) calc(var(--base) * 2) calc(var(--base) * 2) calc(var(--base) * 3);
  border: 1px solid var(--border);
  border-radius: var(--radius-metric);
  background: var(--color-card);
  box-shadow: var(--fo-metric-shadow);
}

body.sheet-body:not(.section-viewer) .fo-metric.emphasis {
  border-color: var(--fo-emphasis-border);
  background: linear-gradient(160deg, var(--stone), var(--color-card));
}

body.sheet-body:not(.section-viewer) .fo-metric .dash-eyebrow {
  margin: 0;
  font-size: 11px;
  font-weight: 730;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

body.sheet-body:not(.section-viewer) .fo-metric-figure {
  margin: calc(var(--base) * 2) 0 var(--base);
  /* 4 Nov 26: v1.4's size, but never more than its card holds: a figure of up to 15 characters (-100,000,000.00) is
     about 8.6 of its own font size wide, so 11.5% of the card's width keeps it inside; before, -34,290,846.63 INR ran
     87 px past a 232 px card at 1,280 px. It also breaks at the space before its currency code. The harness's
     "inside" step holds every figure in its card. */
  font: 550 min(clamp(26px, 2.25vw, 39px), calc((var(--fo-card) - var(--fo-card-padding)) / 10)) / 1.1 var(--serif);
  font-variant-numeric: tabular-nums;
  /* 4 Nov 26 (Avi's check of 4 Nov, step 2): one line always, the currency code beside the number at half its size
     (.fo-metric-code, written by setMetricFigure), so every card's figure and note stand at the same heights along a
     row. The number and its code together are at most about 9.8 of the font size wide, hence 10% of the card. */
  white-space: nowrap;
  color: var(--text);
}

body.sheet-body:not(.section-viewer) .fo-metric-code {
  font-size: 0.5em;
  font-weight: 650;
  letter-spacing: 0.04em;
}

body.sheet-body:not(.section-viewer) .fo-metric-figure.owed {
  color: var(--color-red);
}

body.sheet-body:not(.section-viewer) .fo-metric-help {
  margin: 0;
  font-size: 13px;
  color: var(--text-help);
}

/* The laptop's frame, as v1.4's: a 224 px sidebar and a 40 px gutter on the right (the left gutter stays 40 px, the
   page's 33 base units less the narrower sidebar). Her pages keep theirs. */
@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) {
    padding-right: calc(var(--base) * 5);
  }

  /* 4 Nov 26: the idle warning band keeps to the page's column in this frame too: the same 40 px gutter on the right,
     and the full width on a page with a hero, as its column has (the band ran 16 px past the column at 1,280 px). */
  body.sheet-body:not(.section-viewer) .idle-warning {
    right: calc(var(--base) * 5);
  }

  body.sheet-body:not(.section-viewer):has(.sheet-page .dash-hero) .idle-warning {
    max-width: none;
  }

  /* Restarted 10 Nov 26, Part 16: and on a page whose column the sample's layout lifts to the full width (.ins directly
     under #content: Financial Records and the seven Data Maintenance pages), found by the closing's idle view on
     Exchange rates, whose band stayed at 720 px once its hero gave way to the heading. */
  body.sheet-body:not(.section-viewer):has(.sheet-page > #content > .ins) .idle-warning {
    max-width: none;
  }

  body.sheet-body:not(.section-viewer) .tab-bar {
    width: calc(var(--base) * 28);
    padding: calc(var(--base) * 4) calc(var(--base) * 2);
  }

  body.sheet-body:not(.section-viewer) .search-view:not([hidden]) {
    left: calc(var(--base) * 28);
  }
}

body.sheet-body:not(.section-viewer) .fo-under-metrics > :not([hidden]) {
  margin: 0 0 calc(var(--base) * 2);
}

@media (max-width: 1100px) {
  body.sheet-body:not(.section-viewer) .fo-metrics,
  body.sheet-body:not(.section-viewer) .fo-metrics.fo-metrics-three,
  body.sheet-body:not(.section-viewer) .fo-metrics.fo-metrics-owed {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    --fo-card: calc((100cqi - var(--base) * 2) / 2);
  }
}

/* The phone (v1.4 below 720 px): the top bar, then the featured action before the hero, then the metric cards. The top
   bar starts below the page's Sign out at the top right (D-197). */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) #content.dash-grid:has(> .fo-topbar):not([hidden]) {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
  }

  body.sheet-body:not(.section-viewer) #content > .fo-topbar {
    order: -2;
    margin-top: calc(var(--base) * 6);
  }

  /* D-590 (4), the overnight brief of 18 Nov 26, Part 4A (3): one place for each top-bar control on every page. The
     page's heading and the Appearance switch share the first row, the switch at the right edge; a full-width break
     follows; then the page's own controls, the currency first, from the left. Before this the controls wrapped where the
     words ran out, and the Appearance switch started in five places across the pages. */
  body.sheet-body:not(.section-viewer) .fo-topbar {
    row-gap: 0;
    column-gap: var(--base);
  }
  body.sheet-body:not(.section-viewer) .fo-topbar > .fo-tools {
    display: contents;
  }
  body.sheet-body:not(.section-viewer) .fo-topbar > .fo-crumb {
    order: 0;
    flex: 1 1 0;
    min-width: 0;
  }
  body.sheet-body:not(.section-viewer) .fo-topbar > .fo-tools > .fo-appearance {
    order: 1;
    margin-left: auto;
    align-self: flex-start;
  }
  body.sheet-body:not(.section-viewer) .fo-topbar::after {
    content: "";
    order: 1;
    flex-basis: 100%;
    height: 0;
  }
  body.sheet-body:not(.section-viewer) .fo-topbar > .fo-tools > :not(.fo-appearance) {
    order: 3;
    margin-top: var(--base);
  }
  body.sheet-body:not(.section-viewer) .fo-topbar > .fo-tools > #currency-pills {
    order: 2;
  }

  body.sheet-body:not(.section-viewer) #content > .fo-featured {
    order: -1;
  }
}

@media (max-width: 720px) {
  body.sheet-body:not(.section-viewer) .dash-hero.fo-hero {
    min-height: 240px;
    border-radius: var(--radius-photo-hero-phone);
  }

  body.sheet-body:not(.section-viewer) .sheet-page .fo-hero h1 {
    font-size: var(--size-headline);
  }

  body.sheet-body:not(.section-viewer) .fo-hero-line {
    font-size: 13px;
  }

  body.sheet-body:not(.section-viewer) .fo-hero-note:not([hidden]),
  body.sheet-body:not(.section-viewer) #rate-date.fo-hero-note:not([hidden]) {
    font-size: 11px;
  }

  body.sheet-body:not(.section-viewer) .fo-hero-copy {
    padding: calc(var(--base) * 3);
  }

  /* 4 Nov 26 (question 19 of the overnight report, D-496): one card to a row on the phone, so a long figure keeps
     v1.4's 27 px. */
  body.sheet-body:not(.section-viewer) .fo-metrics,
  body.sheet-body:not(.section-viewer) .fo-metrics.fo-metrics-three,
  body.sheet-body:not(.section-viewer) .fo-metrics.fo-metrics-owed {
    grid-template-columns: minmax(0, 1fr);
    column-gap: var(--base);
    --fo-card: 100cqi;
    --fo-card-padding: calc(var(--base) * 4);
  }

  body.sheet-body:not(.section-viewer) .fo-metrics > .fo-metric {
    margin-bottom: var(--base);
  }

  body.sheet-body:not(.section-viewer) .fo-metric {
    min-height: 110px;
    padding: calc(var(--base) * 2);
    border-radius: var(--radius-metric-phone);
  }

  body.sheet-body:not(.section-viewer) .fo-metric-figure {
    font-size: min(27px, calc((var(--fo-card) - var(--fo-card-padding)) / 10));
  }

  body.sheet-body:not(.section-viewer) .fo-metric .dash-eyebrow {
    font-size: 11px;
  }

  body.sheet-body:not(.section-viewer) .fo-metric-help {
    font-size: 11px;
  }
}

/* v1.4's panel head (Part 2e): a small-capitals kicker above a section's heading and a one-line subtitle under it,
   both in the page's own words. */
body.sheet-body:not(.section-viewer) .fo-kicker {
  margin: 0 0 calc(var(--base) * 1);
  font-size: 11px;
  font-weight: 720;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-muted);
}

body.sheet-body:not(.section-viewer) .fo-subtitle {
  margin: calc(var(--base) * 1) 0 calc(var(--base) * 3);
  font-size: 13px;
  color: var(--text-help);
}

body.sheet-body:not(.section-viewer) .fo-pill {
  display: inline-block;
  padding: var(--base) var(--base);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  background: var(--stone);
  font-size: 11px;
  font-weight: 650;
  color: var(--text-help);
  white-space: nowrap;
}

/* v1.4's category rows on Balance Sheet's composition: name and caption, a bar of the share, the value. */
body.sheet-body:not(.section-viewer) #composition .row-button.fo-category {
  display: grid;
  /* The value column holds an eight-figure amount and its code ("1,096,000.00 AUD" needs 105 px; the closing of
     11 Nov 26 found it running past a 95 px column). */
  grid-template-columns: minmax(110px, 1.1fr) 2.1fr 120px;
  gap: calc(var(--base) * 2);
  align-items: center;
  padding: calc(var(--base) * 2) 0;
  font-size: 15px;
  line-height: 1.55;
}

body.sheet-body:not(.section-viewer) #composition .fo-category .row-name {
  font-size: 15px;
  font-weight: 650;
  line-height: 1.55;
}

body.sheet-body:not(.section-viewer) #composition .fo-category .row-note {
  font-size: 13px;
  font-weight: 650;
  line-height: 1.55;
  color: var(--text-muted);
}

body.sheet-body:not(.section-viewer) #composition .fo-category .row-value {
  font-size: 15px;
  font-weight: 740;
  line-height: 1.55;
  text-align: right;
  color: var(--text);
}

body.sheet-body:not(.section-viewer) #composition .fo-category .row-value.owed {
  color: var(--color-red);
}

body.sheet-body:not(.section-viewer) #composition .fo-category .row-chevron {
  display: none;
}

/* On the phone (v1.4's 720 px step, Part 5 of 4 Nov 26): name and value side by side, the bar under them across the
   row, the gap 8 and the row 12 top and bottom (the sample's 7 and 12, on the grid). */
@media (max-width: 720px) {
  body.sheet-body:not(.section-viewer) #composition .row-button.fo-category {
    grid-template-columns: 1fr 1fr;
    gap: var(--base);
    padding: calc(var(--base) * 2) 0;
  }

  body.sheet-body:not(.section-viewer) #composition .fo-category .fo-cat-bar {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}

body.sheet-body:not(.section-viewer) .fo-cat-bar {
  display: block;
  height: 13px;
  overflow: hidden;
  border-radius: var(--radius-pill);
  background: var(--stone);
}

body.sheet-body:not(.section-viewer) .fo-cat-bar > span {
  display: block;
  height: 100%;
  border-radius: var(--radius-pill);
  background: var(--color-accent);
}

body.sheet-body:not(.section-viewer) #liabilities-groups .fo-cat-bar > span {
  background: var(--color-red);
}

/* v1.4's attention cards (Balance Sheet's assurance): 17 px corners; with something to check, the review family's
   ground, border and rail, its button filled in the review accent. */
body.sheet-body:not(.section-viewer) .dash-section .sheet-card.fo-attention {
  /* v1.4's attention card is padded 21 px by 20 (Part 5, 4 Nov 26): 24, the nearest whole base unit (Part 8); the
     difference is D-496 Q8's accepted grid rounding. */
  padding: calc(var(--base) * 3);
  border-radius: var(--radius-attention);
  background: var(--stone);
}

body.sheet-body:not(.section-viewer) .dash-section .sheet-card.fo-attention.is-review {
  border: 1.5px solid var(--fo-review-border);
  border-left-width: 6px;
  background-color: var(--fo-review-bg);
}

body.sheet-body:not(.section-viewer) .fo-attention.is-review .fo-pill {
  border-color: transparent;
  background: var(--fo-review-accent);
  color: var(--fo-review-cta-text);
  font-size: 13px;
  font-weight: 800;
  line-height: 1.55;
}

/* What's due's item cards (Q43, Part 5 of 4 Nov 26): v1.4's attention cards in the list, each item's family by the
   banner's own table (src/action-severity.ts dueSeverity), its tag above the name in words. Critical takes the action
   family's ground, border and 7 px rail, review the review family's with a 6 px rail, information stays plain. The
   cards take v1.4's attention corners and padding, as Balance Sheet's assurance cards do (24, a whole base unit). */
body.sheet-body:not(.section-viewer) #due-list .entry-group.due-block {
  padding: calc(var(--base) * 3);
  border-radius: var(--radius-attention);
}

body.sheet-body:not(.section-viewer) #due-list .due-block > .fo-attention-tags {
  margin: 0 0 var(--base);
}

body.sheet-body:not(.section-viewer) #due-list .due-block.is-critical {
  border: 1.5px solid var(--fo-action-border);
  border-left-width: 7px;
  background-color: var(--fo-action-bg);
}

body.sheet-body:not(.section-viewer) #due-list .due-block.is-review {
  border: 1.5px solid var(--fo-review-border);
  border-left-width: 6px;
  background-color: var(--fo-review-bg);
}

body.sheet-body:not(.section-viewer) #due-list .due-block.is-critical .fo-pill,
body.sheet-body:not(.section-viewer) #due-list .due-block.is-review .fo-pill {
  border-color: transparent;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.55;
}

body.sheet-body:not(.section-viewer) #due-list .due-block.is-critical .fo-pill {
  background: var(--fo-action-accent);
  color: var(--fo-action-cta-text);
}

body.sheet-body:not(.section-viewer) #due-list .due-block.is-review .fo-pill {
  background: var(--fo-review-accent);
  color: var(--fo-review-cta-text);
}

/* The card's name, as v1.4's card title: the system font at 20 px (a card's name, not a heading). */
body.sheet-body:not(.section-viewer) .fo-attention .group-name {
  margin: var(--base) 0 0;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.25;
}

body.sheet-body:not(.section-viewer) .fo-attention .group-name + .sheet-meta {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-help);
}

body.sheet-body:not(.section-viewer) .fo-attention.is-review .group-name + .sheet-meta {
  font-size: 15px;
  color: var(--text);
}

body.sheet-body:not(.section-viewer) .fo-attention-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  margin: calc(var(--base) * 2) 0 0;
}

body.sheet-body:not(.section-viewer) .fo-attention-actions a.fo-attention-cta,
body.sheet-body:not(.section-viewer) .fo-attention-actions a.fo-attention-outline {
  display: inline-block;
  padding: var(--base) calc(var(--base) * 2);
  border: 1px solid var(--fo-review-accent);
  border-radius: var(--radius-detail-button);
  font-size: 15px;
  font-weight: 760;
  line-height: 1.55;
  text-decoration: none;
}

body.sheet-body:not(.section-viewer) .fo-attention-actions a.fo-attention-cta {
  border-color: transparent;
  background: var(--fo-review-accent);
  color: var(--fo-review-cta-text);
}

body.sheet-body:not(.section-viewer) .fo-attention-actions a.fo-attention-cta {
  min-height: 47px;
}

body.sheet-body:not(.section-viewer) .fo-attention-actions a.fo-attention-outline {
  border-color: var(--fo-control-line);
  background: var(--stone);
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
}

body.sheet-body:not(.section-viewer) .fo-attention-source {
  margin: calc(var(--base) * 2) 0 0;
  font-size: 13px;
  color: var(--text-muted);
}

@media print, (prefers-contrast: more) {
  body.sheet-body:not(.section-viewer) .fo-hero::before {
    background: var(--print-fill-2);
  }
}


/* ===================================================================================================================
   Part 2 of the long session of 5 Nov 26: the shared fixes, one change for every page (D-223). Each is checked by
   src/shared-fixes.test.mjs and on both screens by the harness.
   =================================================================================================================== */

/* The linked card's ring in the accent itself (its old 55% mix with the card was below 3:1 against the card beside it):
   10:1 or more on the paper in light and in dark. Linked cards keep their full strength; only the others fade. */
body.sheet-body:not(.section-viewer) [data-links].is-linked {
  border-color: var(--color-accent);
  box-shadow: 0 0 0 2px var(--color-accent);
}

/* The whole card opens it (src/shell.ts cardOpens, cardFollows): one button or link laid over the card edge to edge, so
   a tap or a click anywhere on it lands on that control (the harness's tap: the hit test at its middle finds it). The
   card's own words let the tap through to it; its own links and buttons sit above it and keep working. The control has
   no words of its own on screen (its label is for screen readers); the keyboard's focus ring outlines the whole card. */
body.sheet-body:not(.section-viewer) .has-card-open {
  position: relative;
  cursor: pointer;
}

body.sheet-body:not(.section-viewer) .has-card-open > :not(.card-open) {
  position: relative;
  z-index: 1;
  pointer-events: none;
}

body.sheet-body:not(.section-viewer) .has-card-open :is(a, button, summary, input, select, textarea, label) {
  pointer-events: auto;
}

body.sheet-body:not(.section-viewer) .has-card-open > :is(a, button):not(.card-open) {
  z-index: 2;
}

body.sheet-body:not(.section-viewer) .has-card-open > .card-open,
body.sheet-body:not(.section-viewer) .has-card-open > button.card-open[type] {
  position: absolute;
  inset: 0;
  z-index: 0;
  display: block;
  width: auto;
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: var(--radius-card);
  background: transparent;
  box-shadow: none;
  opacity: 1;
  color: transparent;
  font-size: 0;
  cursor: pointer;
}

body.sheet-body:not(.section-viewer) .has-card-open > .card-open:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

/* Insurance: the policy blocks follow the card's first parts, as they followed its Details row. */
body.sheet-body .policy-category > .card-foot + .sheet-card {
  margin-top: calc(var(--base) * 2);
}

/* No button's words are underlined (Avi's check of 4-5 Nov 26): a text button, a row's action and a prompt read as
   buttons by their place and colour. The attribute is repeated so the rule outweighs each underlining rule above. */
body.sheet-body button[type][type],
body.sheet-body button:not([type]) {
  text-decoration: none;
}

/* The metric figure at v1.4's size where it fits, smaller only as far as its own width needs (--fo-fig-ems, set from
   its words by src/page-top.ts watchMetricFigures): a short count no longer shrinks to the longest amount's size.
   Unset, a figure is taken as 10 of its size wide (the rule of 4 Nov). D-568 (16 Nov 26): never above the fitted
   figure's 28 px (tools/text-roles.json); before, 2.25vw reached 28.8 px at 1,280 px and up to 39 px wider. */
body.sheet-body:not(.section-viewer) .fo-metric-figure {
  font-size: min(clamp(26px, 2.25vw, 28px), calc((var(--fo-card) - var(--fo-card-padding)) / var(--fo-fig-ems, 10)));
}

@media (max-width: 720px) {
  body.sheet-body:not(.section-viewer) .fo-metric-figure {
    font-size: min(27px, calc((var(--fo-card) - var(--fo-card-padding)) / var(--fo-fig-ems, 10)));
  }
}

/* Debts' "What is owed" card: the figures and the note one under another, never wrapping into a second column (the note
   ran past the card's right edge on the phone, 4 Nov 26). */
body.sheet-body:not(.section-viewer) .fo-metric .debt-totals {
  flex-wrap: nowrap;
}

/* Every segmented switch as the Appearance switch (Avi's ruling 5 of 5 Nov 26; the kit's .theme-switch): the choices in
   one rounded box on the card, the one in force filled in the accent with its own ink (aria-pressed or aria-selected says
   it too, never by colour alone), the others in the muted ink; at least 44 px tall on the phone. Serves the pill
   switches (.fo-seg), the switches in a section's head (.dash-view role group: Coming up's days, What's due's grouping,
   Spending's workspace, the period switches) and the panels' tabs (Insurance's category tabs, Property's tabs). */
body.sheet-body:not(.section-viewer) :is(.fo-seg, .dash-view[role="group"], .dash-view[role="tablist"], .selector-strip[role="tablist"]) {
  display: inline-flex;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 0;
  width: fit-content;
  max-width: 100%;
  padding: 0;
  overflow-x: auto;
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
}

body.sheet-body:not(.section-viewer) :is(.fo-seg, .dash-view[role="group"], .dash-view[role="tablist"], .selector-strip[role="tablist"]) > button[type] {
  flex: 0 0 auto;
  width: auto;
  min-height: 0;
  margin: 0;
  padding: var(--base);
  border: 0;
  border-radius: var(--radius-switch-button);
  background: transparent;
  box-shadow: none;
  transform: none;
  color: var(--text-muted);
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}

body.sheet-body:not(.section-viewer) :is(.fo-seg, .dash-view[role="group"], .dash-view[role="tablist"], .selector-strip[role="tablist"]) > button[type]:is([aria-pressed="true"], [aria-selected="true"]):not(:disabled) {
  background: var(--color-accent);
  color: var(--plus-ink);
}

@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) :is(.fo-seg, .dash-view[role="group"], .dash-view[role="tablist"], .selector-strip[role="tablist"]) > button[type] {
    min-height: 44px;
  }
}

/* "No urgent action." as a quiet card (Avi's check of 4-5 Nov 26): the featured action's slot with no record keeps its
   place as a flat card on the paper, its words muted, so the page does not open on a lone grey line. */
body.sheet-body:not(.section-viewer) .fo-quiet {
  margin: var(--base) 0 calc(var(--base) * 2);
  padding: calc(var(--base) * 2) calc(var(--base) * 3);
  border: 1px solid var(--border);
  border-radius: var(--radius-tile);
  background: var(--color-card);
}

/* One weight for every card's name (Avi's ruling 2 of 5 Nov 26), the sheets' 600: a list card's name was 400 and a
   block card's 600. A form's own group names are left as they are. */
body.sheet-body:not(.section-viewer) :is(.entry-group, .sheet-card):not(.form-sheet *) > .group-name {
  font-weight: 600;
}

/* Budget: the hero and the placeholder card under it a whole base unit apart (they nearly touched, 4 Nov 26). */
body.sheet-body:not(.section-viewer) #content > .dash-hero + .sheet-card {
  margin-top: var(--base);
}

/* Insurance's category panel, built to Insurance v1.1's drawer (5 Nov 26, Part 3): the count and status under the
   heading, two figure tiles, the sample's detail labels and rows, the connected people, the quiet coverage note, and the
   foot's Close and Edit details. The sample's sizes moved to the scale (10 to 11, 12 to 13, 25 to 28); its greys are
   our muted ink and stone, so dark mode follows the tokens. */
body.sheet-body #category-sheet .drawer-line {
  margin: 0 0 var(--base);
  font-size: 13px;
  color: var(--text-muted);
}
body.sheet-body #category-sheet .drawer-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--base) * 2);
  margin: calc(var(--base) * 2) 0 calc(var(--base) * 3);
}
body.sheet-body #category-sheet .drawer-stat {
  background: var(--stone);
  border-radius: var(--radius-quick-look);
  padding: calc(var(--base) * 2);
  min-height: 88px;
}
body.sheet-body #category-sheet .drawer-stat small {
  display: block;
  font-size: 11px;
  color: var(--text-muted);
}
body.sheet-body #category-sheet .drawer-stat strong {
  display: block;
  margin-top: calc(var(--base) * 2);
  font-size: 17px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
body.sheet-body #category-sheet .detail-label {
  margin: calc(var(--base) * 3) 0 var(--base);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1.1px;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body #category-sheet .detail-row {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  padding: calc(var(--base) * 2) 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
body.sheet-body #category-sheet .detail-row span {
  color: var(--text-muted);
}
body.sheet-body #category-sheet .detail-row strong {
  text-align: right;
  font-weight: 600;
  max-width: 240px;
}
body.sheet-body #category-sheet .covered-row {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2);
  margin: var(--base) 0;
  font-size: 13px;
}
body.sheet-body #category-sheet .covered-row small {
  margin-left: auto;
  font-size: 11px;
  color: var(--text-muted);
}
body.sheet-body #category-sheet .quiet-note {
  background: var(--stone);
  border-radius: var(--radius-button);
  padding: calc(var(--base) * 2);
  font-size: 11px;
  line-height: 1.65;
  color: var(--text-muted);
}
/* The panel's foot, Close (and on Insurance Edit details), as the samples' drawers end; Debts and Property since the
   same session's Part 4. */
body.sheet-body :is(#category-sheet, #liability-sheet, #property-sheet) .drawer-actions {
  display: flex;
  gap: var(--base);
  margin-top: calc(var(--base) * 3);
  padding-top: calc(var(--base) * 2);
  border-top: 1px solid var(--border);
}
body.sheet-body :is(#category-sheet, #liability-sheet, #property-sheet) .drawer-actions button {
  flex: 1;
  min-height: 44px;
  border-radius: var(--radius-button);
  font-size: 13px;
  font-weight: 600;
}

/* What's Due's item panel, v1.4's drawer (the long session of 5 Nov 26, Part 3): its heading at the drawer's size (the
   sample's 36 px, 38 on the scale; 28 on the phone), Georgia as every display heading, regular weight (ruling 2); its
   rows; its one action filled red on an urgent item and amber on one to review, as the sample's card button, the words
   in the banner's own button colours (4.5:1 or more, light and dark); a note's row in the outline style below it. */
body.sheet-body:not(.section-viewer) #due-sheet .due-sheet-title {
  font-size: 38px;
  font-weight: 400;
  line-height: 1.15;
  margin: calc(var(--base) * 2) 0 var(--base);
}
body.sheet-body:not(.section-viewer) #due-sheet .due-sheet-rows {
  margin-top: calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) :is(#due-sheet, #due-info-sheet) .detail-row {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  padding: calc(var(--base) * 2) 0;
  border-bottom: 1px solid var(--border);
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) :is(#due-sheet, #due-info-sheet) .detail-row span {
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) :is(#due-sheet, #due-info-sheet) .detail-row strong {
  text-align: right;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #due-sheet .due-sheet-actions {
  display: grid;
  gap: calc(var(--base) * 2);
  margin-top: calc(var(--base) * 3);
}
/* D-523 (4) (the session of 8 Nov 26 (b), Part 2; Avi: "Why is it so Bright Red when it is a Action Button?"): the
   item's action is the site's forest primary button whatever the item's severity; red is kept for a passed date, on its
   tag and its date. */
body.sheet-body:not(.section-viewer) #due-sheet :is(a.due-action, button.due-action[type]) {
  background: var(--color-accent);
  color: var(--plus-ink);
  border: 1px solid var(--color-accent);
  border-radius: var(--radius-button);
  min-height: 44px;
  font-size: 15px;
  font-weight: 600;
  /* Found on the 1,440 panel picture of 7 Nov 26: the coloured action's words and chevron touched its edges. */
  padding-inline: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #due-sheet :is(a.due-action, button.due-action[type]) :is(.row-name, .row-chevron) {
  color: inherit;
}
/* D-523 (5) (Part 3): the lead-time panel, one row per setting: its name on the left; its value and a small Change on
   the right, on the same row, in the panel's body size (15 px); a changed setting's note under it, 13 px. */
body.sheet-body:not(.section-viewer) #due-info-sheet .lead-row {
  align-items: center;
}
body.sheet-body:not(.section-viewer) #due-info-sheet .lead-value {
  display: flex;
  align-items: baseline;
  gap: calc(var(--base) * 2);
  flex-shrink: 0;
}
body.sheet-body:not(.section-viewer) #due-info-sheet button.lead-change[type] {
  width: auto;
  min-height: 0;
  padding: calc(var(--base) * 0.5) 0;
  border: 0;
  background: none;
  color: var(--forest-ink);
  font-size: 15px;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}
body.sheet-body:not(.section-viewer) #due-info-sheet button.lead-change[type]:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}
body.sheet-body:not(.section-viewer) #due-info-sheet .lead-note {
  margin: var(--base) 0 0;
  font-size: 13px;
  color: var(--text-muted);
}
/* D-523 (6) (Part 4; Avi: "Look at the saved screen button color, not consistent with the site"): every Saved card's
   button on the owner pages is the site's forest primary, never the base blue (--accent, which the owner palette does
   not set). Its secondary ("Add another") keeps the outline style. */
body.sheet-body:not(.section-viewer) .sheet-saved .confirm-actions button:not(.secondary) {
  background: var(--color-accent);
  color: var(--plus-ink);
}
/* The restarted session of 10 Nov 26, Stage 4's closing: a link styled as the primary action (a Saved card's "Done",
   <a class="primary">) reads --accent with white words (line 597); since D-532 (2) --accent is --forest-2 here, the
   pale green in dark, where white read 1.55:1. Its words take the accent's own ink, as the buttons above do: white on
   forest in light, the dark ink on the pale green in dark. */
body.sheet-body:not(.section-viewer) a.primary {
  color: var(--plus-ink);
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) #due-sheet .due-sheet-title {
    font-size: 28px;
  }
}

/* Insurance's panel tabs fill the panel's width, three equal parts, as Insurance v1.1's drawer tabs do; their look is
   the shared switch's (Avi's ruling 5 of 5 Nov 26). */
body.sheet-body:not(.section-viewer) #category-sheet .category-tabs {
  display: flex;
  width: 100%;
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #category-sheet .category-tabs > button[type] {
  flex: 1;
}

/* D-502's kept list: one shadow, flat where the sample is flat. Each part below is drawn with no shadow in its
   sample, so it rests flat here too; the hover lift (the @media (hover: hover) rules) still shows. One selector a line,
   each scoped to the owner's pages, with no list nested inside another (the owner-scope check reads one level).
   The brief of 12 Nov 26, Part 5 (D-544 (1)): Cash Flow's and Goals' heroes left this list; every hero takes Insurance's
   shadow (the base hero rules at the end of the file). */
body.sheet-body:not(.section-viewer) :is(#allocation-tiles .fo-metric, #cash-tiles .fo-metric, #spending-tiles .fo-metric, #tax-tiles .fo-metric, #review-panel, #category-policies .due-block, #category-documents .due-block, #due-list .due-block):not(:hover),
body.sheet-body:not(.section-viewer):has(#cash-tiles) .dash-section:has(#outlook-list):not(:hover),
body.sheet-body:not(.section-viewer):has(#cash-tiles) .dash-section:has(#account-list):not(:hover),
body.sheet-body:not(.section-viewer):has(#cash-tiles) .dash-section:has(#left-out-list):not(:hover),
body.sheet-body:not(.section-viewer):has(#cash-tiles) .cash-piece[data-piece="horizon"]:not(:hover),
body.sheet-body:not(.section-viewer):has(#cash-tiles) .cash-piece[data-piece="sustainability"]:not(:hover),
body.sheet-body:not(.section-viewer):has(#liability-list) section[aria-labelledby="coming-heading"]:not(:hover),
body.sheet-body:not(.section-viewer):has(#property-list) section[aria-labelledby="due-heading"]:not(:hover),
body.sheet-body:not(.section-viewer):has(#property-list) section[aria-labelledby="return-heading"]:not(:hover) {
  box-shadow: none;
}

/* D-502 ruling 3: Income's "Add income" is the sample's small button in its section's heading, in place of our adding
   row: v1.4's 12 px button corner (its token), padding in whole base units (the sample's 9 / 12 px is off the grid,
   D-496-grid), the caption size (the sample's 10 px, on our scale), the muted ink; the sample's 46 px on the phone
   (over Apple's 44 px) and its 32 px from 768 px. */
body.sheet-body:not(.section-viewer) .group-head > button.secondary.head-button[type] {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: var(--base);
  width: auto;
  min-height: 46px;
  margin: 0;
  padding: var(--base);
  border-radius: var(--radius-detail-button);
  font-size: var(--size-caption);
  font-weight: 600;
  line-height: normal;
  color: var(--text-muted);
  background: var(--color-card);
}
@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) .group-head > button.secondary.head-button[type] {
    min-height: 32px;
  }
}

/* =====================================================================================================================
   The Insurance page built from its sample (the Insurance session of 5 Nov 26; D-503): Family-Office v1.1's
   dashboards/insurance/02-current-design, its rules ported in its order and scoped to the page (#ins-page, class ins),
   then Avi's rulings on top: Georgia headings at regular weight; ivory paper cards on the ivory and stone page, never
   white; forest charcoal text; forest in place of every blue; the type scale (11 / 13 / 15 / 17 / 20 / 28 / 38 / 52) and
   1.55 line spacing; spacing in whole base units; cards 24 px, tiles 20 px, the hero 28 px; one shadow at rest and the
   forest lift on hover; Active, Renewal soon and Review needed in words (amber for a renewal soon, red only once its date
   has passed, src/action-severity.ts's colours); every switch and tab the Appearance switch's; the panels 480 px, the
   whole screen on the phone; Midnight Estate in dark mode. Each size, gap and corner the sample has off those is moved
   to the nearest step (the session report lists them).
   ===================================================================================================================== */
/* Every page built on the sample's layout (its root .ins: Insurance, Debt, Income, Phone access, Property, Investments,
   What's Due, Goals) takes the full column, 1,136 px at 1,440. The tick list of 7 Nov 26 found Investments, What's Due
   and Goals at the plain page's 1,040 px: each earlier page had lifted the cap with its own rule, these three had none. */
@media (min-width: 768px) {
  body.sheet-body .sheet-page:has(> #content > .ins) {
    max-width: none;
  }
  /* Home takes the same column as every other page (the overnight brief of 18-19 Nov 26, Part 7, item 1; D-597): it
     had kept the plain page's 1,040 px, narrower than the Balance Sheet beside it from 1,440 px. */
  body.sheet-body .sheet-page:has(> #content.home) {
    max-width: none;
  }
}
body.sheet-body:not(.section-viewer) #content.home {
  max-width: 1456px;
  margin-inline: auto;
}
body.sheet-body:not(.section-viewer) .ins {
  --ins-ink: var(--text);
  --ins-quiet: var(--text-muted);
  /* The Insurance fixes of 5 Nov 26, item 3: card borders and divider lines at the sample's faint strength (its #e9ebf0
     on white), as our own palette's border mixed into the card's paper, so dark mode takes Midnight Estate's own. */
  --ins-line: color-mix(in srgb, var(--border) 45%, var(--paper));
  --ins-surface: var(--stone);
  max-width: 1456px;
  margin: 0 auto;
  color: var(--ins-ink);
  font-size: var(--size-small);
  line-height: 1.55;
}
body.sheet-body:not(.section-viewer) .ins[hidden] {
  display: none;
}
/* The brief of 12 Nov 26, Part 2: inside a grid an auto margin shrinks the block to its contents (Balance Sheet & Net
   Worth's What deserves attention was 894 of 976 px at 1,280, narrow while its items were read and narrow for good with
   none); a grid's own area already centres it, so the block stretches across its area from first paint. Only the
   dashboard grid holds one today; the harness's "full width from first paint" view measures it. */
body.sheet-body:not(.section-viewer) .dash-grid > .ins {
  margin-inline: 0;
}
body.sheet-body:not(.section-viewer) .ins * {
  box-sizing: border-box;
}
/* The site's own button rule (full width, 48 px, the accent behind) is undone inside the page; each button below sets
   its own look as the sample's does. */
body.sheet-body:not(.section-viewer) .ins button[type] {
  width: auto;
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: inherit;
  font: inherit;
  line-height: 1.55;
  text-align: inherit;
  box-shadow: none;
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) .ins :is(button, [role="button"], [tabindex]):focus-visible {
  outline: 3px solid var(--forest-2);
  outline-offset: 3px;
}
body.sheet-body:not(.section-viewer) .ins a {
  color: var(--forest-ink);
}
body.sheet-body:not(.section-viewer) .ins :is(h1, h2, h3) {
  font-family: var(--serif);
  font-weight: 400;
  letter-spacing: 0;
  color: var(--ins-ink);
}

/* The photo hero (the sample's foh-hero): the kit's photograph under its dark gradient, the eyebrow, the heading, the
   sentence and three pills of our counts. */
body.sheet-body:not(.section-viewer) .ins .ins-hero {
  margin: calc(var(--base) * 3) 0;
  min-height: 315px;
  position: relative;
  display: flex;
  align-items: flex-end;
  border-radius: var(--radius-hero);
  overflow: hidden;
  background-color: var(--on-photo-fill-7);
  background-image: linear-gradient(95deg, var(--on-photo-fill-8), var(--on-photo-fill-9) 60%, var(--on-photo-fill-10)), url("/photos/kit-foh-hero-villa.webp");
  background-size: cover;
  background-position: center;
  box-shadow: var(--shadow-card);
  isolation: isolate;
}

/* Insurance's own hero (Brief 1 of 3 of 7 Nov 26 (c), Part 5; D-516): the other pages keep theirs. */
body.sheet-body:not(.section-viewer) .ins .ins-hero.ins-own-hero {
  background-image: linear-gradient(95deg, var(--on-photo-fill-8), var(--on-photo-fill-9) 60%, var(--on-photo-fill-10)), url("/photos/insurance-hero-pool-pavilion.webp");
}
body.sheet-body:not(.section-viewer) .ins .ins-heroinner {
  position: relative;
  z-index: 1;
  width: 100%;
  padding: calc(var(--base) * 5);
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) .ins .ins-eyebrow {
  font-size: 13px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-hero .ins-eyebrow {
  color: var(--on-photo-ink-4);
}
body.sheet-body:not(.section-viewer) .ins .ins-hero h2 {
  font-size: var(--size-hero);
  line-height: 1.1;
  color: var(--on-photo-ink-2);
  margin: 0 0 calc(var(--base) * 2);
  max-width: 760px;
}
body.sheet-body:not(.section-viewer) .ins .ins-hero p {
  font-size: 17px;
  line-height: 1.55;
  color: var(--on-photo-ink-4);
  max-width: 650px;
  margin: 0 0 calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) .ins .ins-feature-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-feature {
  border: 1px solid var(--on-photo-line-2);
  background: var(--on-photo-fill-11);
  color: var(--on-photo-ink-2);
  backdrop-filter: blur(6px);
  padding: var(--base) calc(var(--base) * 2);
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 13px;
}

/* What deserves attention (the sample's foh-intel): its heading and tabs, the two-column cards, then the green strip. */
body.sheet-body:not(.section-viewer) .ins .ins-intel {
  padding: calc(var(--base) * 3);
  margin: calc(var(--base) * 3) 0;
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  background: var(--paper);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .ins .ins-intel-top {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  align-items: flex-start;
  margin-bottom: calc(var(--base) * 3);
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) .ins .ins-intel .ins-eyebrow {
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .ins-intel h2 {
  font-size: var(--size-display);
  line-height: 1.2;
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-sub {
  font-size: 15px;
  color: var(--ins-quiet);
  margin: 0;
}
/* Every switch and tab on the page takes the Appearance switch's look (Avi's ruling): one rounded box with a line, the
   card behind, the choice in force in the accent with its own ink, aria-pressed or aria-selected saying it too. */
body.sheet-body:not(.section-viewer) .ins :is(.ins-tabs, .ins-drawer-tabs) {
  display: flex;
  align-items: stretch;
  gap: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
}
body.sheet-body:not(.section-viewer) .ins :is(.ins-tabs, .ins-drawer-tabs) > button[type],
body.sheet-body:not(.section-viewer) .ins .ins-light-btn[type] {
  padding: var(--base) calc(var(--base) * 2);
  border-radius: var(--radius-switch-button);
  background: transparent;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .ins :is(.ins-tabs, .ins-drawer-tabs) > button[type]:is([aria-pressed="true"], [aria-selected="true"]),
body.sheet-body:not(.section-viewer) .ins .ins-light-btn[type][aria-pressed="true"] {
  background: var(--color-accent);
  color: var(--plus-ink);
}
body.sheet-body:not(.section-viewer) .ins .ins-light-btn[type] {
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
}
/* The Insurance fixes of 5 Nov 26, item 10: "Add vehicle" carries Add policy's "+" mark, drawn the same, at its size. */
body.sheet-body:not(.section-viewer) .ins .ins-light-btn.ins-add-btn[type] {
  display: inline-flex;
  align-items: center;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-light-btn.ins-add-btn svg {
  flex: none;
}
body.sheet-body:not(.section-viewer) .ins .ins-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-card {
  padding: calc(var(--base) * 3);
  background: var(--ivory);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-tile);
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-card[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) .ins .ins-card[data-level="critical"] {
  border-left: 5px solid var(--fo-action-accent);
  background: var(--fo-action-bg);
}
body.sheet-body:not(.section-viewer) .ins .ins-card[data-level="review"] {
  border-left: 5px solid var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) .ins .ins-kicker {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--base);
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) .ins .ins-tag {
  display: inline-block;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 11px;
  font-weight: 700;
  color: var(--fo-review-accent);
  background: var(--fo-review-bg);
  padding: var(--base) var(--base);
  border-radius: var(--radius-pill);
  line-height: 1.2;
}
body.sheet-body:not(.section-viewer) .ins .ins-tag.alert {
  color: var(--fo-action-accent);
  background: var(--fo-action-bg);
}
body.sheet-body:not(.section-viewer) .ins .ins-card[data-level="critical"] .ins-tag.alert {
  background: var(--paper);
}
body.sheet-body:not(.section-viewer) .ins .ins-tag.owner {
  color: var(--forest-ink);
  background: var(--chip-bg);
}
body.sheet-body:not(.section-viewer) .ins .ins-card h3 {
  font-size: 20px;
  line-height: 1.25;
  margin: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-card p {
  color: var(--ins-quiet);
  font-size: 15px;
  line-height: 1.55;
  margin: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-meta {
  font-size: 13px;
  color: var(--ins-quiet);
  margin-top: auto;
}
body.sheet-body:not(.section-viewer) .ins .ins-btn[type] {
  border: 1px solid var(--color-accent);
  border-radius: var(--radius-pill);
  padding: var(--base) calc(var(--base) * 2);
  font-size: 13px;
  font-weight: 700;
  background: var(--color-accent);
  color: var(--plus-ink);
  align-self: flex-start;
}
body.sheet-body:not(.section-viewer) .ins .ins-btn.ghost[type] {
  background: transparent;
  color: var(--forest-ink);
}
body.sheet-body:not(.section-viewer) .ins .ins-quiet {
  margin: 0;
  padding: calc(var(--base) * 2);
  border-radius: var(--radius-tile);
  background: var(--stone);
  color: var(--ins-quiet);
  font-size: 13px;
}

/* The page title, its eyebrow and Add policy. */
body.sheet-body:not(.section-viewer) .ins .ins-page-title {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: calc(var(--base) * 3);
  margin: calc(var(--base) * 4) 0 calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) .ins .ins-page-eyebrow {
  font-size: 11px;
  letter-spacing: 0.16em;
  color: var(--ins-quiet);
  font-weight: 700;
  text-transform: uppercase;
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-page-title h1 {
  font-size: var(--size-headline);
  line-height: 1.1;
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-subtitle {
  font-size: 15px;
  margin: 0;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .ins-primary-btn[type] {
  border-radius: var(--radius-switch);
  background: var(--color-accent);
  color: var(--plus-ink);
  display: flex;
  align-items: center;
  gap: var(--base);
  font-size: 13px;
  font-weight: 700;
  padding: calc(var(--base) * 2);
  white-space: nowrap;
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .ins .ins-primary-btn[type]:active {
  transform: translateY(1px);
}

/* The three metric cards. */
body.sheet-body:not(.section-viewer) .ins .ins-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 4);
}
body.sheet-body:not(.section-viewer) .ins .ins-metric {
  padding: calc(var(--base) * 3);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .ins .ins-metric-heading {
  display: flex;
  align-items: center;
  gap: var(--base);
  font-size: 13px;
  color: var(--ins-quiet);
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) .ins .ins-metric-heading svg {
  width: 16px;
  height: 16px;
  flex: none;
}
body.sheet-body:not(.section-viewer) .ins .ins-metric-value {
  font-size: var(--size-display);
  line-height: 1.1;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-metric-tail {
  color: var(--ins-quiet);
  font-size: 11px;
  margin-top: var(--base);
}

/* Section headings, People & assets and its round tiles. D-632 (1), D-640 (the overnight brief of 21-22 Nov 26, Part 11):
   the same heading on Spending (.spw) and Tax (.txw), which are not inside .ins; Data Assurance is. The small line above
   a heading is Insurance's own small label (.ins-eyebrow), inside the heading (D-640 (1)). */
body.sheet-body:not(.section-viewer) :is(.spw, .txw) {
  --ins-ink: var(--text);
  --ins-quiet: var(--text-muted);
}
body.sheet-body:not(.section-viewer) :is(.ins, .spw, .txw) .ins-section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 3);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) :is(.ins, .spw, .txw) .ins-section-heading h2 {
  font-size: 20px;
  line-height: 1.25;
  margin: 0;
}
body.sheet-body:not(.section-viewer) :is(.spw, .txw) .ins-section-heading h2 {
  font-family: var(--serif);
  font-weight: 400;
  color: var(--ins-ink);
}
body.sheet-body:not(.section-viewer) :is(.ins, .spw, .txw) .ins-section-heading p {
  font-size: 13px;
  color: var(--ins-quiet);
  margin: var(--base) 0 0;
}
body.sheet-body:not(.section-viewer) :is(.ins, .spw, .txw) .ins-section-heading > div:first-child {
  min-width: 0;
}
body.sheet-body:not(.section-viewer) :is(.spw, .txw) .ins-section-heading .ins-eyebrow {
  font-size: 13px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) :is(.ins, .spw, .txw) .ins-section-heading p.ins-eyebrow,
body.sheet-body:not(.section-viewer) :is(.ins, .spw, .txw) .ins-section-heading div.ins-eyebrow {
  margin: 0 0 var(--base);
  color: var(--ins-ink);
}
body.sheet-body:not(.section-viewer) .ins .ins-heading-buttons {
  display: flex;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-entities {
  display: flex;
  gap: calc(var(--base) * 2);
  flex-wrap: wrap;
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  padding: calc(var(--base) * 3);
  margin-bottom: calc(var(--base) * 4);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .ins .ins-entity[type] {
  border: 1px solid transparent;
  border-radius: var(--radius-tile);
  min-width: 114px;
  padding: var(--base) calc(var(--base) * 2);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--base);
  text-align: center;
  transition: background 0.18s, border 0.18s, transform 0.18s;
}
body.sheet-body:not(.section-viewer) .ins .ins-entity[type]:hover {
  background: var(--fo-hover);
  transform: translateY(-2px);
}
body.sheet-body:not(.section-viewer) .ins .ins-entity[type].selected {
  background: var(--fo-success-bg);
  border-color: var(--forest-2);
}
body.sheet-body:not(.section-viewer) .ins .ins-entity-img {
  width: 67px;
  height: 67px;
  display: block;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--paper);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .ins .ins-entity-img .ins-thumb {
  display: block;
  width: 100%;
  height: 100%;
}
/* The Insurance fixes of 5 Nov 26, item 2: a property's or vehicle's bundled photograph fills its round tile. */
body.sheet-body:not(.section-viewer) .ins .ins-thumb-photo {
  object-fit: cover;
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) .ins .ins-entity-label {
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}
body.sheet-body:not(.section-viewer) .ins .ins-entity-kind {
  font-size: 11px;
  color: var(--ins-quiet);
  line-height: 1.2;
}
body.sheet-body:not(.section-viewer) .ins .ins-entities-none {
  margin: 0;
  color: var(--ins-quiet);
  font-size: 13px;
}

/* Your insurance: the category cards, four across from 1,160 px, three below it, two below 820 px. */
body.sheet-body:not(.section-viewer) .ins .ins-category-header {
  margin-bottom: calc(var(--base) * 2);
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) .ins .ins-category-header .ins-section-heading {
  margin: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-count-label {
  color: var(--ins-quiet);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .ins .ins-card-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-ic[type] {
  position: relative;
  min-height: 263px;
  padding: calc(var(--base) * 3) calc(var(--base) * 3) calc(var(--base) * 2);
  border: 1px solid var(--ins-line);
  background: var(--paper);
  border-radius: var(--radius-card);
  display: flex;
  flex-direction: column;
  text-align: left;
  box-shadow: var(--shadow-card);
  transition: transform 0.2s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 0.2s, border-color 0.2s, opacity 0.2s, background 0.2s;
  isolation: isolate;
}
body.sheet-body:not(.section-viewer) .ins .ins-ic[type]:hover {
  z-index: 5;
  transform: translateY(-5px);
  box-shadow: var(--shadow-lift);
}
body.sheet-body:not(.section-viewer) .ins .ins-ic[type]:active {
  transform: translateY(-2px);
}
body.sheet-body:not(.section-viewer) .ins .ins-ic[type].dimmed {
  opacity: 0.36;
}
/* The sample's ring (a light border and a faint 2 px ring, .related), in forest for its blue. */
body.sheet-body:not(.section-viewer) .ins .ins-ic[type].related {
  border-color: color-mix(in srgb, var(--forest-2) 45%, var(--paper));
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--forest-2) 16%, transparent);
}
body.sheet-body:not(.section-viewer) .ins .ins-card-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  min-height: 48px;
}
body.sheet-body:not(.section-viewer) .ins .ins-cat-icon {
  width: 51px;
  height: 51px;
  border-radius: var(--radius-icon-box);
  background: var(--tint);
  color: var(--ink);
  display: grid;
  place-items: center;
  flex: none;
}
body.sheet-body:not(.section-viewer) .ins .ins-cat-icon svg {
  width: 24px;
  height: 24px;
}
body.sheet-body:not(.section-viewer) .ins .ins-card-arrow {
  width: 18px;
  height: 18px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .ins-card-mid {
  margin-top: calc(var(--base) * 4);
  min-height: 64px;
}
body.sheet-body:not(.section-viewer) .ins .ins-card-mid h3 {
  margin: 0 0 var(--base);
  font-size: 20px;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
body.sheet-body:not(.section-viewer) .ins .ins-card-mid p {
  font-size: 11px;
  color: var(--ins-quiet);
  line-height: 1.4;
  margin: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-card-bottom {
  margin-top: auto;
}
body.sheet-body:not(.section-viewer) .ins .ins-mini-entities {
  display: flex;
  align-items: center;
  height: 32px;
  margin-bottom: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-mini {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--paper);
  margin-left: calc(var(--base) * -0.75);
  flex: none;
}
body.sheet-body:not(.section-viewer) .ins .ins-mini:first-child {
  margin-left: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-mini .ins-thumb {
  display: block;
  width: 100%;
  height: 100%;
}
body.sheet-body:not(.section-viewer) .ins .ins-mini-text {
  font-size: 11px;
  color: var(--ins-quiet);
  margin-left: var(--base);
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .ins .ins-card-divider {
  height: 1px;
  background: var(--ins-line);
  margin-bottom: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--base);
  color: var(--ins-quiet);
  font-size: 11px;
  font-weight: 600;
}
/* A status in its words with a dot: Active in green, Renewal soon in amber, Review needed (its date has passed) in red,
   No policy recorded quiet (src/action-severity.ts's colours). */
body.sheet-body:not(.section-viewer) .ins .ins-status {
  display: inline-flex;
  align-items: center;
  gap: var(--base);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  color: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) .ins .ins-status::before {
  content: "";
  display: inline-block;
  background: currentColor;
  width: 5px;
  height: 5px;
  border-radius: 50%;
}
body.sheet-body:not(.section-viewer) .ins .ins-status[data-level="review"] {
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) .ins .ins-status[data-level="critical"] {
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) .ins .ins-status[data-level="none"] {
  color: var(--ins-quiet);
}

/* Protection review. */
body.sheet-body:not(.section-viewer) .ins .ins-review-panel {
  margin-top: calc(var(--base) * 4);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  padding: calc(var(--base) * 3);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .ins .ins-review-header {
  display: flex;
  gap: var(--base);
  align-items: center;
  margin-bottom: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-review-header svg {
  width: 17px;
  height: 17px;
  color: var(--ins-quiet);
}
/* "Open What's due ›" (the evidence panel) and "Open the policy ›" (the panel's Policies) are underlined, in the
   accent, so each reads as a link at rest (the brief of 6 Nov 26, Part 3.3, superseding the fixes of 5 Nov 26, item 7);
   a keyboard's focus rings it. */
body.sheet-body:not(.section-viewer) a.ins-link {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}
body.sheet-body:not(.section-viewer) a.ins-link:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}
/* The Insurance fixes of 5 Nov 26, item 4: 20 px, the scale's step for a card's heading (the sample's .review h2 rule
   never applies to its heading, so its 15 px was an accident of the sample). */
body.sheet-body:not(.section-viewer) .ins .ins-review-header h2 {
  font-size: 20px;
  line-height: 1.3;
  margin: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-review-row {
  display: flex;
  gap: calc(var(--base) * 2);
  align-items: center;
  border-top: 1px solid var(--ins-line);
  padding: calc(var(--base) * 2) 0 0;
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-review-dot {
  width: 33px;
  height: 33px;
  flex: 0 0 33px;
  border-radius: var(--radius-icon-box-small);
  display: grid;
  place-items: center;
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) .ins .ins-review-dot[data-level="critical"] {
  background: var(--fo-action-bg);
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) .ins .ins-review-copy {
  min-width: 0;
  flex: 1;
}
body.sheet-body:not(.section-viewer) .ins .ins-review-copy b {
  font-size: 13px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) .ins .ins-review-copy p {
  font-size: 11px;
  color: var(--ins-quiet);
  margin: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-review-action[type] {
  border: 1px solid var(--border);
  background: var(--color-card);
  border-radius: var(--radius-switch);
  padding: var(--base) calc(var(--base) * 2);
  color: var(--ins-ink);
  font-size: 11px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) .ins .ins-read-at {
  margin: calc(var(--base) * 3) 0 0;
  color: var(--ins-quiet);
  font-size: 11px;
}

/* Quick look: fixed beside the card, 238 px wide, shown on a mouse's hover and a keyboard's focus, never a touch. */
body.sheet-body:not(.section-viewer) .ins .ins-hover-card {
  position: fixed;
  z-index: 100;
  pointer-events: none;
  opacity: 0;
  transform: translateY(5px) scale(0.98);
  transition: opacity 0.17s, transform 0.17s;
  width: 238px;
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-quick-look);
  box-shadow: var(--shadow-quick-look);
  padding: calc(var(--base) * 2);
  visibility: hidden;
}
body.sheet-body:not(.section-viewer) .ins .ins-hover-card.visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  visibility: visible;
}
body.sheet-body:not(.section-viewer) .ins .ins-hover-title {
  font-size: 13px;
  font-weight: 700;
  margin-bottom: var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-hover-row {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin-top: var(--base);
  font-size: 11px;
}
body.sheet-body:not(.section-viewer) .ins .ins-hover-row span {
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .ins-hover-row strong {
  font-weight: 700;
  text-align: right;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .ins .ins-hover-hint {
  margin-top: calc(var(--base) * 2);
  padding-top: calc(var(--base) * 2);
  border-top: 1px solid var(--ins-line);
  color: var(--ins-quiet);
  font-size: 11px;
}

/* The category panel: fixed at the right edge, 480 px, over the dimmed page; its title and tabs stay while its content
   scrolls; Close and Edit at its foot. */
body.sheet-body:not(.section-viewer) .ins .ins-backdrop {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: var(--on-photo-fill-12);
  backdrop-filter: blur(3px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.24s;
}
body.sheet-body:not(.section-viewer) .ins .ins-backdrop.visible {
  opacity: 1;
  pointer-events: auto;
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer {
  position: fixed;
  z-index: 201;
  top: 0;
  right: 0;
  width: min(480px, 100%);
  height: 100dvh;
  background: var(--paper);
  box-shadow: var(--shadow-panel); /* the sample's drawer shadow, in forest (the brief of 6 Nov 26, Part 3.7) */
  transform: translateX(105%);
  transition: transform 0.28s cubic-bezier(0.19, 0.78, 0.25, 1);
  display: flex;
  flex-direction: column;
  outline: none;
  border-radius: var(--radius-card) 0 0 var(--radius-card);
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer.open {
  transform: translateX(0);
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-head {
  flex-shrink: 0;
  padding: calc(var(--base) * 3) calc(var(--base) * 4) calc(var(--base) * 3);
  border-bottom: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-topline {
  display: flex;
  flex-direction: row-reverse; /* D-544 (4): the round ✕ at the left, the label beside it */
  justify-content: flex-end;
  gap: calc(var(--base) * 2);
  align-items: center;
  color: var(--ins-quiet);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-weight: 700;
  margin-bottom: calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) .ins .ins-close-btn[type] {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--stone);
  color: var(--ins-ink);
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-title {
  display: flex;
  gap: calc(var(--base) * 2);
  align-items: center;
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-title .ins-cat-icon {
  width: 55px;
  height: 55px;
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-title h2 {
  font-size: var(--size-display);
  line-height: 1.15;
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-title p {
  font-size: 13px;
  color: var(--ins-quiet);
  margin: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-tabs {
  margin: calc(var(--base) * 3) 0 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-tabs > button[type] {
  flex: 1;
  text-align: center;
}
/* D-637 (2), the approved demo of 22 Nov 26: a record panel's tabs run the full width. Each takes its words with the
   Appearance switch's side padding (D-575) and an equal share of the width left over, so the segments are equal where
   the words allow and "Documents" is never cut on Property's seven (CP2 of 22 Nov 26; the report's question). */
body.sheet-body:not(.section-viewer) :is(.ins .ins-drawer-tabs, .tool-tabs).record-tabs {
  box-sizing: border-box;
  display: flex;
  flex-wrap: nowrap;
  height: var(--control-h);
  padding: 0;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
}
/* The shared switch rule sizes each button to its words and no more; a record panel's tabs also share the spare width,
   so that rule leaves .record-tabs out and this one gives its buttons the switch's look. */
body.sheet-body:not(.section-viewer) :is(.ins .ins-drawer-tabs, .tool-tabs).record-tabs > button[type] {
  box-sizing: border-box;
  display: flex;
  flex: 1 0 auto;
  align-items: center;
  justify-content: center;
  min-width: max-content;
  margin: 0;
  padding: 0 var(--base);
  border: 0;
  border-radius: var(--radius-switch-button);
  box-shadow: none;
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
}
/* The phone: a record panel's tab is at least 44 px wide, the tap size (D-571); a row wider than the screen scrolls
   sideways on one line, as the shared switches do. */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) :is(.ins .ins-drawer-tabs, .tool-tabs).record-tabs > button[type] {
    width: 44px; /* the flex basis; the shared phone rule keeps it at least its words (min-width: max-content) */
  }
}
body.sheet-body:not(.section-viewer) #pr-tabs.record-tabs {
  margin-inline: calc(var(--base) * -3);
  max-width: none;
}
body.sheet-body:not(.section-viewer) .ins .debt-history-row {
  padding: var(--base) 0;
  border-bottom: 1px solid var(--border);
}
body.sheet-body:not(.section-viewer) .ins .debt-history-row b {
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .ins .debt-history-row p {
  margin: calc(var(--base) / 4) 0 0;
  font-size: 13px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-content {
  overflow: auto;
  padding: calc(var(--base) * 3) calc(var(--base) * 4) calc(var(--base) * 4);
  flex: 1;
  overscroll-behavior: contain;
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) .ins .ins-stat {
  background: var(--stone);
  border-radius: var(--radius-tile);
  padding: calc(var(--base) * 2);
  min-height: 89px;
}
body.sheet-body:not(.section-viewer) .ins .ins-stat small {
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .ins-stat strong {
  display: block;
  font-size: 17px;
  font-weight: 700;
  margin-top: var(--base);
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .ins .ins-detail-label {
  text-transform: uppercase;
  font-size: 11px;
  color: var(--ins-quiet);
  font-weight: 700;
  letter-spacing: 0.1em;
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-detail-label:first-child {
  margin-top: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-detail-row {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  padding: calc(var(--base) * 2) 0;
  border-bottom: 1px solid var(--ins-line);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .ins .ins-detail-row span {
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .ins-detail-row strong {
  text-align: right;
  font-weight: 700;
  max-width: 240px;
}
body.sheet-body:not(.section-viewer) .ins .ins-covered-row {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2);
  margin: var(--base) 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-covered-row .ins-mini {
  width: 34px;
  height: 34px;
  margin-left: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-covered-row b {
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .ins .ins-covered-row small {
  font-size: 11px;
  color: var(--ins-quiet);
  margin-left: auto;
}
body.sheet-body:not(.section-viewer) .ins :is(.ins-policy-box, .ins-doc-box) {
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-tile);
  padding: calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins :is(.ins-policy-box, .ins-doc-box) b {
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .ins .ins-policy-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-provider {
  color: var(--ins-quiet);
  font-size: 11px;
  margin: var(--base) 0 var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-pill {
  border-radius: var(--radius-pill);
  background: var(--fo-success-bg);
  color: var(--fo-success-accent);
  font-size: 11px;
  padding: calc(var(--base) / 2) var(--base);
  font-weight: 700;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .ins .ins-pill[data-level="review"] {
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) .ins .ins-pill[data-level="critical"] {
  background: var(--fo-action-bg);
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) .ins .ins-pill[data-level="none"] {
  background: var(--stone);
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .ins-policy-attrs {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin-top: var(--base);
  border-top: 1px solid var(--ins-line);
  padding-top: var(--base);
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .ins-policy-attrs strong {
  color: var(--ins-ink);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .ins .ins-doc-box {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-doc-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-icon-box-small);
  background: var(--stone);
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .ins-doc-box p {
  font-size: 11px;
  color: var(--ins-quiet);
  margin: calc(var(--base) / 2) 0 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-quiet-note {
  background: var(--stone);
  border-radius: var(--radius-tile);
  padding: calc(var(--base) * 2);
  font-size: 11px;
  color: var(--ins-quiet);
  line-height: 1.55;
}
/* One gap above every note that follows something in its container, on every page built from a sample: two notes
   stacked, or a note under a row or a button, never touch (Avi's check of 6 Nov 26 b, step 3; D-223: once, here,
   not page by page). 16 px, the samples' own .detail-note spacing. */
body.sheet-body:not(.section-viewer) .ins * + .ins-quiet-note {
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-actions {
  padding: calc(var(--base) * 2) calc(var(--base) * 4);
  border-top: 1px solid var(--ins-line);
  display: flex;
  gap: var(--base);
  flex-shrink: 0;
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-actions button[type] {
  flex: 1;
  padding: calc(var(--base) * 1.5);
  border-radius: var(--radius-panel-button);
  font-size: 12px;
  font-weight: 730;
  text-align: center;
}
body.sheet-body:not(.section-viewer) .ins .ins-secondary-action[type] {
  border: 1px solid var(--border);
  background: var(--color-card);
  color: var(--ins-ink);
}
body.sheet-body:not(.section-viewer) .ins .ins-filled-action[type] {
  border: 1px solid var(--color-accent);
  background: var(--color-accent);
  color: var(--plus-ink);
}
/* D-641 (3), the approved demo of 22 Nov 26: a record panel's footer, Full page (Close's secondary look) then Edit record
   (the main button), on the right, each sized to its words, both one height. Insurance's category panel keeps its own. */
body.sheet-body:not(.section-viewer) .ins .ins-record-foot {
  justify-content: flex-end;
}
body.sheet-body:not(.section-viewer) .ins .ins-record-foot button[type] {
  flex: none;
  height: 40px; /* the demo's; the phone's 44 px tap size still wins below 768 px */
  padding: 0 calc(var(--base) * 2.25);
  white-space: nowrap;
}

/* Inspect evidence & handoff (the sample's foh-overlay): the same 480 px panel at the right edge, over the dimmed page. */
body.sheet-body:not(.section-viewer) .ins .ins-overlay[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) .ins .ins-overlay {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: var(--on-photo-fill-13);
  display: flex;
  justify-content: flex-end;
}
body.sheet-body:not(.section-viewer) .ins .ins-evidence {
  width: min(480px, 100%);
  height: 100%;
  background: var(--paper);
  padding: calc(var(--base) * 4);
  box-shadow: var(--shadow-quick-look);
  overflow-y: auto;
}
/* The evidence panel's close is the drawer's round ✕ at the top right, in place of "Close ×" (the brief of 6 Nov 26 (b),
   Part 4.1), on Income, Insurance and Debt alike. */
body.sheet-body:not(.section-viewer) .ins .ins-evidence-x[type] {
  margin: 0 0 0 auto;
}
body.sheet-body:not(.section-viewer) .ins .ins-evidence-x + .ins-evidence-eyebrow {
  margin-top: var(--base);
}
body.sheet-body:not(.section-viewer) .ins .ins-evidence-eyebrow {
  margin-top: calc(var(--base) * 3);
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .ins-evidence h2 {
  font-size: var(--size-display);
  line-height: 1.15;
  margin: var(--base) 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-evidence p {
  color: var(--ins-quiet);
  font-size: 15px;
  line-height: 1.55;
}
body.sheet-body:not(.section-viewer) .ins .ins-evidence dl {
  margin: calc(var(--base) * 3) 0;
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) .ins .ins-evidence dl div {
  padding: calc(var(--base) * 2) 0;
  border-bottom: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) .ins .ins-evidence dt {
  font-size: 11px;
  font-weight: 700;
  color: var(--ins-quiet);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
body.sheet-body:not(.section-viewer) .ins .ins-evidence dd {
  margin: calc(var(--base) / 2) 0 0;
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) .ins .ins-evidence dd a {
  color: var(--forest-ink);
}
body.sheet-body:not(.section-viewer) .ins .ins-close[type] {
  background: var(--fo-success-bg);
  color: var(--forest-ink);
  padding: var(--base) calc(var(--base) * 2);
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .ins .ins-helper {
  font-size: 13px;
  color: var(--ins-quiet);
  margin-top: calc(var(--base) * 2);
}

/* Dark mode, Midnight Estate: the category icons keep their drawn ink on a dark tint of their own hue (their light
   tints, kept as drawn in light mode, glare on the dark card). */
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) .ins .ins-cat-icon {
    background: color-mix(in srgb, var(--ink) 24%, var(--paper));
    color: color-mix(in srgb, var(--ink) 55%, var(--dark-ins-cat-icon-ink));
  }
  body.sheet-body:not(.section-viewer) .ins .ins-hero {
    background-color: var(--on-photo-fill-14);
  }
  /* The Insurance fixes of 5 Nov 26, item 8: an amber attention card takes the dark green card colour (it sat on the
     near-black canvas) and keeps its amber edge. */
  body.sheet-body:not(.section-viewer) .ins .ins-card[data-level="review"] {
    background: var(--paper);
  }
}

@media (max-width: 1160px) {
  body.sheet-body:not(.section-viewer) .ins .ins-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 820px) {
  body.sheet-body:not(.section-viewer) .ins .ins-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) .ins .ins-entities {
    gap: var(--base);
    padding: calc(var(--base) * 2);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-entity[type] {
    min-width: 100px;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-page-title {
    align-items: flex-start;
  }
}
/* The phone (D-504: laptop first, the phone kept working): the sample's 740 px and 560 px rules on our scale; the
   panels take the whole screen. */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .ins .ins-hero {
    min-height: 210px;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-heroinner {
    padding: calc(var(--base) * 3);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-hero h2 {
    font-size: 38px;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-hero p {
    font-size: 15px;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-intel {
    padding: calc(var(--base) * 2);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-cards {
    grid-template-columns: 1fr;
  }
  /* The panel's tabs scroll sideways too (the phone round of 7 Nov 26: Property's "Documents" was cut at the edge). */
  body.sheet-body:not(.section-viewer) .ins :is(.ins-tabs, .ins-drawer-tabs) {
    width: 100%;
    overflow-x: auto;
  }
  body.sheet-body:not(.section-viewer) .ins :is(.ins-tabs, .ins-drawer-tabs) > button[type],
  body.sheet-body:not(.section-viewer) .ins .ins-light-btn[type],
  body.sheet-body:not(.section-viewer) .ins .ins-review-action[type] {
    min-height: 44px;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-page-title {
    flex-direction: column;
    align-items: stretch;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-page-title .ins-primary-btn[type] {
    align-self: flex-start;
    min-height: 44px;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-page-title h1 {
    font-size: var(--size-display);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-metrics {
    gap: var(--base);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-metric {
    padding: calc(var(--base) * 2) var(--base);
    border-radius: var(--radius-tile);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-metric-heading {
    font-size: 11px;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-metric-heading svg {
    display: none;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-metric-value {
    font-size: 20px;
  }
  body.sheet-body:not(.section-viewer) :is(.ins, .spw, .txw) .ins-section-heading {
    flex-wrap: wrap;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-entities {
    justify-content: space-around;
    padding: var(--base);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-entity[type] {
    min-width: 83px;
    padding: var(--base) calc(var(--base) / 2);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-entity-img {
    width: 50px;
    height: 50px;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-card-grid {
    gap: var(--base);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-ic[type] {
    padding: calc(var(--base) * 2);
    min-height: 236px;
    border-radius: var(--radius-tile);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-card-mid {
    margin-top: calc(var(--base) * 3);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-card-mid h3 {
    font-size: 15px;
  }
  /* Two cards across at 375 px leave too little room for "No policy" and "No policy recorded" on one line: the status
     goes under the count (the phone safety round of 5 Nov 26). */
  body.sheet-body:not(.section-viewer) .ins .ins-card-foot {
    flex-wrap: wrap;
    row-gap: calc(var(--base) / 2);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-cat-icon {
    width: 42px;
    height: 42px;
  }
  body.sheet-body:not(.section-viewer) .ins :is(.ins-drawer, .ins-evidence) {
    width: 100%;
    border-radius: 0;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-drawer-head,
  body.sheet-body:not(.section-viewer) .ins .ins-drawer-content {
    padding: calc(var(--base) * 3) calc(var(--base) * 2);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-drawer-actions {
    padding: calc(var(--base) * 2);
  }
  body.sheet-body:not(.section-viewer) .ins .ins-drawer-actions button[type],
  body.sheet-body:not(.section-viewer) .ins .ins-close-btn[type] {
    min-height: 44px;
    min-width: 44px;
  }
  body.sheet-body:not(.section-viewer) .ins .ins-evidence {
    padding: calc(var(--base) * 3) calc(var(--base) * 2);
  }
}
@media (prefers-reduced-motion: reduce) {
  body.sheet-body:not(.section-viewer) .ins :is(.ins-ic, .ins-entity, .ins-hover-card, .ins-backdrop, .ins-drawer) {
    transition-duration: 0.01ms;
  }
}

/* =====================================================================================================================
   The Income page rebuilt from its sample (the Income session of 5 Nov 26): Family-Office v1.1's
   dashboards/income/02-current-design, its rules ported in its order and scoped to the page (#inc-page, classes ins inc).
   The page shares Insurance's pieces through the class ins (the attention cards and their tabs, the 480 px panel, its
   tabs, the evidence panel, the switches); the rules below are the Income sample's own sections. Avi's rulings on top:
   Georgia headings at regular weight; ivory paper cards, never white; forest in place of the sample's blues and navy;
   the type scale (11 / 13 / 15 / 17 / 20 / 28 / 38 / 52) and 1.55 line spacing; whole base units; cards 24 px, tiles
   20 px, the two large cards 28 px as the hero; one shadow at rest and the forest lift on hover; every switch the
   Appearance switch's; Midnight Estate in dark mode. Figures to the cent, never shortened.
   ===================================================================================================================== */
@media (min-width: 768px) {
  body.sheet-body .sheet-page:has(#inc-page) {
    max-width: none;
  }
}
/* The switches inside the page (Report in, View, the chart's): the Appearance switch's look, restated here because the
   page's own button rule (from Insurance's, through the class ins) would otherwise undo it. */
body.sheet-body:not(.section-viewer) .inc .inc-switch {
  display: inline-flex;
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) .inc .inc-switch > button[type] {
  padding: var(--base) calc(var(--base) * 2);
  border-radius: var(--radius-switch-button);
  background: transparent;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .inc .inc-switch > button[type][aria-pressed="true"] {
  background: var(--color-accent);
  color: var(--plus-ink);
}
/* The sample's light buttons (FX insights, Add income, Review queue and the rest): one line, the card behind. */
body.sheet-body:not(.section-viewer) .inc .inc-button[type] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--base);
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
  color: var(--ins-ink);
  padding: var(--base) calc(var(--base) * 2);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
  transition: transform 0.2s, box-shadow 0.2s;
}
body.sheet-body:not(.section-viewer) .inc .inc-button[type]:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card);
}

/* Income's own photo hero (the brief of 6 Nov 26, Part 4.2): Insurance's hero, its own photograph, the band's words and
   badges on it; the band is gone. */
body.sheet-body:not(.section-viewer) .inc .inc-photo-hero {
  /* A forest-toned photograph in place of the blue glass one (the brief of 6 Nov 26 (b), Part 3.2). */
  background-image: linear-gradient(95deg, var(--on-photo-fill-15), var(--on-photo-fill-16) 60%, var(--on-photo-fill-17)), url("/photos/income-hero-arched-facade.webp");
  background-size: cover;
  background-position: center 50%;
}

/* The title row: the eyebrow, "Income.", the line, and the Reporting period and Report in controls. */
body.sheet-body:not(.section-viewer) .inc .inc-title-row {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 3);
  align-items: flex-end;
  margin: calc(var(--base) * 4) 0 calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) .inc .inc-controls {
  display: flex;
  align-items: flex-end;
  gap: calc(var(--base) * 2);
  flex-wrap: wrap;
  justify-content: flex-end;
}
body.sheet-body:not(.section-viewer) .inc .inc-control {
  display: flex;
  flex-direction: column;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) .inc .inc-control :is(label, .inc-control-label) {
  font-size: 11px;
  color: var(--ins-quiet);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding-left: calc(var(--base) / 2);
}
/* The Reporting period box is the sample's .select (the brief of 6 Nov 26, Part 4.6): a hairline outline, a 12 px
   corner, 11 px at 710, 11/32/11/12 padding, the arrow at the right, 200 px at most. */
body.sheet-body:not(.section-viewer) .inc .inc-select {
  /* The same shape as the Report in switch beside it (Avi's check of 6 Nov 26 b, step 4: "You just fixed the width
     and not the shape"): Safari drew its own rounded button for a select left at appearance: auto, ignoring the
     corner, border and padding below; drawn by us, it takes the switch's corner, hairline and fill, with the shared
     choice box's arrow. */
  -webkit-appearance: none;
  appearance: none;
  width: auto;
  min-height: 0;
  max-width: 200px;
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background-color: var(--color-card);
  background-image: url("select-arrow.svg");
  background-repeat: no-repeat;
  background-position: right calc(var(--base) * 1.25) center;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 710;
  /* The same height as the Report in switch beside it (the brief of 6 Nov 26 (b), Part 3.3): its 1 px border, its
     buttons' base-unit padding and 1.2 line. */
  line-height: 1.2;
  box-sizing: border-box;
  height: calc(var(--base) * 2 + 1.2em + 2px);
  padding: 0 calc(var(--base) * 4) 0 calc(var(--base) * 1.5);
}
/* The source panel in the sample's order (the brief of 6 Nov 26 (b), Part 3.4): the label, the large title, its line,
   the two figures, the tabs, then the pane's source card, note, rows and two buttons. */
body.sheet-body:not(.section-viewer) .inc .inc-drawer-eyebrow {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--forest-2);
}
body.sheet-body:not(.section-viewer) .inc .inc-drawer-title {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 38px;
  line-height: 1.05;
  letter-spacing: -0.5px;
  margin: calc(var(--base) * 1.5) 0 var(--base);
}
body.sheet-body:not(.section-viewer) .inc .inc-drawer-desc {
  font-size: 13px;
  color: var(--ins-quiet);
  margin: 0 0 calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) .inc #inc-drawer .ins-drawer-tabs {
  margin: calc(var(--base) * 2.5) 0 calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) .inc .inc-source-item[type] {
  display: grid;
  grid-template-columns: 52px 1fr auto;
  align-items: center;
  gap: calc(var(--base) * 1.5);
  width: 100%;
  margin: 0 0 var(--base);
  padding: calc(var(--base) * 1.5);
  border: 1px solid var(--border);
  border-radius: var(--radius-tile);
  background: var(--color-card);
  color: var(--ins-ink);
  text-align: left;
}
body.sheet-body:not(.section-viewer) .inc .inc-source-thumb {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-source-thumb);
  overflow: hidden;
}
body.sheet-body:not(.section-viewer) .inc .inc-source-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
body.sheet-body:not(.section-viewer) .inc .inc-source-words {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 0.5);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-source-words strong {
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) .inc .inc-source-words small {
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .inc .inc-notice {
  margin: calc(var(--base) * 1.5) 0 calc(var(--base) * 2);
  padding: calc(var(--base) * 1.75);
  border-radius: var(--radius-tile);
  /* Stone, as every other note, not the information family's pale blue (the brief of 6 Nov 26 (c), Part 2.3). */
  background: var(--stone);
  border: 1px solid var(--border);
  font-size: 13px;
  line-height: 1.5;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) .inc .inc-btnrow {
  display: flex;
  gap: var(--base);
  flex-wrap: wrap;
  margin: calc(var(--base) * 2.5) 0 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-customdates {
  display: flex;
  gap: var(--base);
  align-items: center;
  flex-wrap: wrap;
  margin: 0 0 calc(var(--base) * 2);
  font-size: 13px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .inc .inc-customdates[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) .inc .inc-customdates input {
  width: auto;
  min-height: 0;
  margin-left: var(--base);
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
  color: var(--ins-ink);
  padding: var(--base);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .inc .inc-range-error {
  flex-basis: 100%;
  margin: 0;
  color: var(--error);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .inc .inc-period-note {
  margin-bottom: calc(var(--base) * 2);
}

/* The two large cards (the sample's .hero.cash and .hero.gross): forest in place of its navy and blue, one hue each. */
body.sheet-body:not(.section-viewer) .inc .inc-summary-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) .inc .inc-hero {
  position: relative;
  border-radius: var(--radius-hero);
  overflow: hidden;
  min-height: 240px;
  padding: calc(var(--base) * 3);
  display: flex;
  flex-direction: column;
  isolation: isolate;
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .inc .inc-hero.cash {
  background: linear-gradient(125deg, var(--on-photo-fill-18) 0%, var(--on-photo-fill-19) 58%, var(--on-photo-fill-20) 110%);
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) .inc .inc-hero.gross {
  background: linear-gradient(128deg, var(--on-photo-fill-21) 0%, var(--on-photo-fill-22) 52%, var(--on-photo-fill-23) 100%);
  color: var(--on-photo-ink-5);
  border: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) .inc .inc-hero::before {
  content: "";
  position: absolute;
  inset: auto -56px -116px auto;
  width: 360px;
  height: 360px;
  border: 1px solid var(--on-photo-line-3);
  border-radius: 50%;
  box-shadow: 0 0 0 40px var(--on-photo-shadow), 0 0 0 80px var(--on-photo-shadow-2);
  z-index: -1;
}
body.sheet-body:not(.section-viewer) .inc .inc-hero.gross::before {
  border-color: var(--on-photo-line-4);
  box-shadow: 0 0 0 40px var(--on-photo-shadow-3), 0 0 0 80px var(--on-photo-shadow-4);
}
body.sheet-body:not(.section-viewer) .inc .inc-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  font-size: 13px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) .inc .inc-heropill {
  font-size: 11px;
  padding: var(--base) calc(var(--base) * 2);
  border-radius: var(--radius-pill);
  background: var(--on-photo-fill-24);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
body.sheet-body:not(.section-viewer) .inc .inc-hero.gross .inc-heropill {
  background: var(--on-photo-fill-25);
  color: var(--on-photo-ink-6);
}
body.sheet-body:not(.section-viewer) .inc .inc-amount {
  font-size: var(--size-headline);
  font-weight: 700;
  line-height: 1.1;
  margin-top: calc(var(--base) * 3);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .inc .inc-herodesc {
  font-size: 13px;
  margin-top: var(--base);
  opacity: 0.92;
}
body.sheet-body:not(.section-viewer) .inc .inc-natives {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .inc .inc-natives span {
  font-size: 11px;
  font-weight: 700;
  padding: calc(var(--base) / 2) var(--base);
  border-radius: var(--radius-pill);
  background: var(--inc-natives-fill);
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .inc .inc-hero.gross .inc-natives span {
  background: var(--on-photo-fill-25);
}
body.sheet-body:not(.section-viewer) .inc .inc-bottom {
  margin-top: auto;
  display: flex;
  gap: var(--base);
  justify-content: space-between;
  align-items: flex-end;
  padding-top: calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) .inc .inc-bottom small {
  font-size: 11px;
  max-width: 320px;
  line-height: 1.55;
  opacity: 0.92;
}
body.sheet-body:not(.section-viewer) .inc .inc-herospark {
  width: 134px;
  height: 39px;
  opacity: 0.6;
}

/* The scope bar: View (Household, Individual, Shared / joint), FX insights and the caption. */
body.sheet-body:not(.section-viewer) .inc .inc-scopebar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: calc(var(--base) * 2);
  flex-wrap: wrap;
  padding: calc(var(--base) * 2) calc(var(--base) * 3);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .inc .inc-scope-controls {
  display: flex;
  gap: calc(var(--base) * 2);
  align-items: center;
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) .inc .inc-view-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .inc .inc-hint {
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .inc .inc-scope-note {
  margin: var(--base) 0 0;
  font-size: 13px;
  color: var(--ins-quiet);
}

/* Your income sources: the sample's photo cards, two across, the scene drawing over the card's words. */
body.sheet-body:not(.section-viewer) .inc .inc-sectionhead {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: calc(var(--base) * 2);
  margin: calc(var(--base) * 4) 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .inc .inc-sectionhead h2 {
  font-size: 20px;
  line-height: 1.25;
  margin: 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-sectionhead p {
  font-size: 13px;
  color: var(--ins-quiet);
  margin: var(--base) 0 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-source-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .inc .inc-source-card[type] {
  display: flex;
  flex-direction: column;
  min-width: 0;
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  overflow: hidden;
  background: var(--paper);
  text-align: left;
  box-shadow: var(--shadow-card);
  transition: transform 0.21s, box-shadow 0.21s, border-color 0.21s;
}
body.sheet-body:not(.section-viewer) .inc .inc-source-card[type]:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lift);
}
body.sheet-body:not(.section-viewer) .inc .inc-scene {
  height: 192px;
  position: relative;
  overflow: hidden;
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) .inc .inc-scene .inc-art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s;
}
body.sheet-body:not(.section-viewer) .inc .inc-source-card[type]:hover .inc-art {
  transform: scale(1.06);
}
body.sheet-body:not(.section-viewer) .inc .inc-floating {
  position: absolute;
  z-index: 3;
  top: calc(var(--base) * 2);
  left: calc(var(--base) * 2);
  padding: var(--base) calc(var(--base) * 2);
  background: var(--inc-floating-fill);
  color: var(--inc-floating-ink);
  font-size: 11px;
  font-weight: 700;
  border-radius: var(--radius-pill);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
body.sheet-body:not(.section-viewer) .inc .inc-roundarr {
  position: absolute;
  z-index: 3;
  right: calc(var(--base) * 2);
  top: calc(var(--base) * 2);
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--inc-floating-fill);
  color: var(--inc-floating-ink);
}
body.sheet-body:not(.section-viewer) .inc .inc-scenebody {
  padding: calc(var(--base) * 3);
  flex: 1;
  display: flex;
  flex-direction: column;
}
body.sheet-body:not(.section-viewer) .inc .inc-sceneline {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .inc .inc-scenebody h3 {
  font-size: 20px;
  line-height: 1.25;
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) .inc .inc-catdesc {
  color: var(--ins-quiet);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .inc .inc-catamount {
  font-size: 20px;
  font-weight: 700;
  margin: calc(var(--base) * 3) 0 var(--base);
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .inc .inc-cathint {
  color: var(--ins-quiet);
  font-size: 11px;
}
body.sheet-body:not(.section-viewer) .inc .inc-cardfoot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--base);
  border-top: 1px solid var(--ins-line);
  padding-top: calc(var(--base) * 2);
  margin-top: auto;
  font-size: 11px;
  font-weight: 700;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .inc .inc-cathint + .inc-cardfoot,
body.sheet-body:not(.section-viewer) .inc .inc-later + .inc-cardfoot {
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .inc .inc-later {
  margin: calc(var(--base) * 3) 0 0;
  padding: calc(var(--base) * 2);
  border-radius: var(--radius-tile);
  background: var(--stone);
  color: var(--ins-quiet);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .inc .inc-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  display: inline-block;
  margin-right: var(--base);
  background: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) .inc .inc-pill {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--base) * 0.625); /* the sample's 5 px inside a pill (Part 9 of 22 Nov 26, D-508) */
  padding: calc(var(--base) / 2) var(--base);
  border-radius: var(--radius-pill);
  font-size: 11px;
  font-weight: 700;
  background: var(--stone);
  color: var(--ins-quiet);
  white-space: nowrap;
}
/* A source not chosen by the scope's highlight would fade (the reference's fade, D-495); nothing is linked yet. */
body.sheet-body:not(.section-viewer) .inc .inc-source-card.dimmed {
  opacity: 0.45;
}

/* Income over time and Income Intelligence, side by side. */
body.sheet-body:not(.section-viewer) .inc .inc-lower-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: calc(var(--base) * 2);
  margin-top: calc(var(--base) * 4);
}
body.sheet-body:not(.section-viewer) .inc .inc-panel {
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  padding: calc(var(--base) * 3);
  min-width: 0;
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .inc .inc-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .inc .inc-panel-head h3 {
  font-size: 20px;
  line-height: 1.25;
  margin: 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-panel-head p {
  font-size: 13px;
  color: var(--ins-quiet);
  margin: var(--base) 0 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-chart-toolbar {
  display: flex;
  gap: var(--base);
  align-items: flex-start;
  flex-wrap: wrap;
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .inc .inc-subcontrols {
  display: flex;
  gap: var(--base);
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) .inc .inc-subcontrols[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) .inc .inc-chart {
  height: 232px;
}
body.sheet-body:not(.section-viewer) .inc .inc-chart svg {
  display: block;
  width: 100%;
  height: 100%;
}
body.sheet-body:not(.section-viewer) .inc .inc-chart .inc-bar {
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) .inc .inc-chart .inc-bar:focus-visible {
  outline: none;
  stroke: var(--forest-2);
  stroke-width: 3;
}
body.sheet-body:not(.section-viewer) .inc .inc-bar-readout {
  margin: var(--base) 0 0;
  font-size: 13px;
  color: var(--ins-ink);
  font-variant-numeric: tabular-nums;
}
/* B9 (Q4): the chart's figures under it; the table scrolls inside its card, never the page, if wider than the screen. */
body.sheet-body:not(.section-viewer) .inc .inc-figures {
  margin: var(--base) 0 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-figures-scroll {
  overflow-x: auto;
}
body.sheet-body:not(.section-viewer) .inc .inc-figures table {
  width: 100%;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .inc .inc-legend {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2);
  margin-top: var(--base);
  font-size: 11px;
  color: var(--ins-quiet);
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) .inc .inc-legend i {
  display: inline-block;
  width: 11px;
  height: 8px;
  border-radius: var(--radius-pill);
  background: var(--inc-bar-1);
  margin-right: var(--base);
}
body.sheet-body:not(.section-viewer) .inc .inc-legend i.alt {
  background: var(--inc-bar-2);
}
body.sheet-body:not(.section-viewer) .inc {
  --inc-bar-1: #2f5444;
  --inc-bar-2: #9cbfa8;
  --inc-grid: color-mix(in srgb, var(--border) 45%, var(--paper));
}
body.sheet-body:not(.section-viewer) .inc .inc-trend-summary {
  font-size: 11px;
  line-height: 1.55;
  color: var(--ins-quiet);
  padding: var(--base) 0 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-insight {
  display: flex;
  gap: calc(var(--base) * 2);
  align-items: flex-start;
  border: 1px solid var(--ins-line);
  padding: calc(var(--base) * 2);
  border-radius: var(--radius-tile);
  margin-top: calc(var(--base) * 2);
  background: var(--ivory);
}
body.sheet-body:not(.section-viewer) .inc .inc-square {
  display: grid;
  place-items: center;
  min-width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--fo-success-bg);
  color: var(--forest-ink);
}
body.sheet-body:not(.section-viewer) .inc .inc-insight b {
  font-size: 13px;
  display: block;
}
body.sheet-body:not(.section-viewer) .inc .inc-insight p {
  font-size: 11px;
  margin: var(--base) 0 0;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .inc .inc-alertlist {
  display: grid;
}
body.sheet-body:not(.section-viewer) .inc .inc-alert {
  display: flex;
  gap: calc(var(--base) * 1.25); /* the sample's 10 px between a row's mark and its words (Part 9 of 22 Nov 26, D-508) */
  align-items: center;
  border-top: 1px solid var(--ins-line);
  padding: calc(var(--base) * 2) 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-alert:first-child {
  border-top: 0;
  padding-top: 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-sym {
  min-width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) .inc .inc-alert b {
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .inc .inc-alert small {
  font-size: 11px;
  color: var(--ins-quiet);
  display: block;
  margin-top: calc(var(--base) / 2);
  line-height: 1.55;
}
body.sheet-body:not(.section-viewer) .inc .inc-alert .inc-alert-action[type] {
  margin-left: auto;
  color: var(--forest-ink);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .inc .inc-btnrow {
  display: flex;
  gap: var(--base);
  flex-wrap: wrap;
  margin-top: var(--base);
}

/* The three small cards: Month-end assurance, Tax evidence and Non-income inflows. */
body.sheet-body:not(.section-viewer) .inc .inc-bottom-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: calc(var(--base) * 2);
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .inc .inc-micro {
  padding: calc(var(--base) * 3);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  min-width: 0;
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .inc .inc-micro-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) .inc .inc-micro-top b {
  font-size: 13px;
}
/* The three cards read alike (the brief of 6 Nov 26, Part 4.9): a large "Not yet" at the sample's 23 px, then "Comes
   with …" small. */
body.sheet-body:not(.section-viewer) .inc .inc-micro strong {
  font-size: 23px;
  letter-spacing: -0.7px;
  font-weight: 700;
  display: block;
  margin: calc(var(--base) * 1.75) 0 calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) .inc .inc-micro .inc-micro-when {
  display: block;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  margin: 0 0 calc(var(--base) * 0.75);
}
body.sheet-body:not(.section-viewer) .inc .inc-micro p {
  font-size: 11px;
  color: var(--ins-quiet);
  margin: 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-micro button[type] {
  color: var(--forest-ink);
  font-size: 11px;
  font-weight: 700;
  padding: calc(var(--base) * 2) 0 0;
}

/* Income by year (kept from the old page; the benchmark reads it): its rows inside one of the sample's panels. */
body.sheet-body:not(.section-viewer) .inc .inc-years {
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .inc .inc-years-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) .inc .inc-years-head .group-name {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ins-quiet);
  margin: 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-years-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ins-quiet);
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) .inc .inc-years-help {
  font-size: 11px;
  color: var(--ins-quiet);
  margin: var(--base) 0 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-years .row-button[type] {
  display: flex;
  width: 100%;
  align-items: center;
  gap: calc(var(--base) * 2);
  padding: calc(var(--base) * 2) 0;
  border-top: 1px solid var(--ins-line);
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) .inc .inc-years .row-value {
  margin-left: auto;
  font-variant-numeric: tabular-nums;
}

/* The source panel's art, and its records and tiles (the panel itself is Insurance's, through the class ins). */
body.sheet-body:not(.section-viewer) .inc .inc-drawer-art {
  width: 72px;
  height: 56px;
  border-radius: var(--radius-icon-box-small);
  overflow: hidden;
  flex: none;
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) .inc .inc-drawer-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) .inc .inc-record-row[type] {
  display: flex;
  width: 100%;
  gap: calc(var(--base) * 2);
  align-items: flex-start;
  padding: calc(var(--base) * 2) 0;
  border-top: 1px solid var(--ins-line);
  text-align: left;
}
body.sheet-body:not(.section-viewer) .inc .inc-record-row b {
  font-size: 13px;
  display: block;
}
body.sheet-body:not(.section-viewer) .inc .inc-record-row small {
  font-size: 11px;
  color: var(--ins-quiet);
  display: block;
  margin-top: calc(var(--base) / 2);
}
body.sheet-body:not(.section-viewer) .inc .inc-record-row .inc-mark {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-top: var(--base);
  flex: none;
  background: var(--forest-2);
}
body.sheet-body:not(.section-viewer) .inc .inc-record-row .inc-mark[data-level="review"] {
  background: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) .inc .inc-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  margin: calc(var(--base) * 2) 0;
}
body.sheet-body:not(.section-viewer) .inc .inc-table th {
  text-align: left;
  color: var(--ins-quiet);
  font-weight: 700;
  font-size: 11px;
  padding: var(--base);
  border-bottom: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) .inc .inc-table td {
  padding: var(--base);
  border-bottom: 1px solid var(--ins-line);
  vertical-align: top;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .inc .inc-table .end {
  text-align: right;
  white-space: nowrap;
}

/* Dark mode, Midnight Estate: the cash card keeps its forest; the gross card takes the dark card's raised green with
   light words; the bars the light accent and its paler second. */
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) .inc {
    --inc-bar-1: #b5d9b8;
    --inc-bar-2: #7fae8f;
  }
  body.sheet-body:not(.section-viewer) .inc .inc-hero.cash {
    background: linear-gradient(125deg, var(--on-photo-fill-26) 0%, var(--on-photo-fill-27) 58%, var(--on-photo-fill-28) 110%);
  }
  body.sheet-body:not(.section-viewer) .inc .inc-hero.gross {
    background: linear-gradient(128deg, var(--stone) 0%, var(--on-photo-fill-29) 52%, var(--on-photo-fill-30) 100%);
    color: var(--text);
  }
  body.sheet-body:not(.section-viewer) .inc .inc-hero.gross .inc-heropill,
  body.sheet-body:not(.section-viewer) .inc .inc-hero.gross .inc-natives span {
    background: var(--on-photo-fill-31);
    color: var(--text);
  }
  body.sheet-body:not(.section-viewer) .inc .inc-hero.gross::before {
    border-color: var(--on-photo-line-5);
    box-shadow: 0 0 0 40px var(--on-photo-shadow-5), 0 0 0 80px var(--on-photo-shadow-6);
  }
}

@media (max-width: 1100px) {
  body.sheet-body:not(.section-viewer) .inc .inc-lower-grid {
    grid-template-columns: 1fr;
  }
  body.sheet-body:not(.section-viewer) .inc .inc-title-row {
    align-items: flex-start;
  }
}
/* The phone (D-504: laptop first, the phone kept working): one column; the panels take the whole screen (Insurance's). */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .inc .inc-title-row {
    flex-direction: column;
    align-items: stretch;
  }
  body.sheet-body:not(.section-viewer) .inc .inc-controls {
    justify-content: flex-start;
  }
  body.sheet-body:not(.section-viewer) .inc :is(.inc-summary-grid, .inc-source-grid, .inc-bottom-grid) {
    grid-template-columns: 1fr;
  }
  body.sheet-body:not(.section-viewer) .inc .inc-hero {
    min-height: 0;
    padding: calc(var(--base) * 2) calc(var(--base) * 3);
  }
  body.sheet-body:not(.section-viewer) .inc .inc-amount {
    font-size: var(--size-display);
    white-space: normal;
  }
  body.sheet-body:not(.section-viewer) .inc .inc-scopebar {
    align-items: flex-start;
    padding: calc(var(--base) * 2);
  }
  body.sheet-body:not(.section-viewer) .inc .inc-scene {
    height: 176px;
  }
  body.sheet-body:not(.section-viewer) .inc .inc-panel {
    padding: calc(var(--base) * 2);
  }
  body.sheet-body:not(.section-viewer) .inc :is(.inc-switch > button[type], .inc-button[type], .inc-select, .inc-micro button[type]) {
    min-height: 44px;
  }
}
@media (prefers-reduced-motion: reduce) {
  body.sheet-body:not(.section-viewer) .inc :is(.inc-source-card, .inc-art, .inc-button) {
    transition-duration: 0.01ms;
  }
}
/* A source's panel carries the sample's five tabs; at 480 px each takes the 8 px step either side, so all five fit. */
body.sheet-body:not(.section-viewer) .inc #inc-tabs > button[type] {
  padding-left: var(--base);
  padding-right: var(--base);
}

/* ---------------------------------------------------------------------------------------------------------------------
   The shared sheet takes the side panel's look, once, for every owner page (the brief of 6 Nov 26, Part 2; Avi: "Side
   Panel's round. That's more visually subtle"; "Match it my sample"; on the whole site, "Yes"). Read from the Insurance
   sample's panel as drawn: its round ✕ (.close-btn, 34 px, a stone fill, no border) and its foot buttons
   (.drawer-actions button: 12 px padding, an 11 px corner, 12 px type at 730); the category panel's type for rows:
   values 15 px, labels 13 px. Every sheet the shared code draws (src/sheet.ts) and Update's own bar take it. Her pages
   (.section-viewer) are left alone. On the phone a typed value stays at 16 px, so Safari does not zoom, and every button
   keeps a 44 px target. */
body.sheet-body:not(.section-viewer) .entry-bar button.round-button[type] {
  width: 34px;
  height: 34px;
  min-height: 34px;
  border: none;
  background: var(--stone);
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .entry-bar button.round-button.round-save.is-ready[type] {
  background: var(--color-accent);
  color: var(--plus-ink);
}
body.sheet-body:not(.section-viewer) .entry-bar button.word-button[type] {
  height: auto;
  min-height: 0;
  min-width: 0;
  padding: calc(var(--base) * 1.5) calc(var(--base) * 2.25);
  border: 1px solid var(--border);
  border-radius: var(--radius-panel-button);
  background: var(--color-card);
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 730;
  line-height: 1.2;
}
body.sheet-body:not(.section-viewer) .entry-bar button.word-button.is-ready[type] {
  border-color: var(--color-accent);
  background: var(--color-accent);
  color: var(--plus-ink);
}
body.sheet-body:not(.section-viewer) .entry-bar .entry-bar-title {
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) .entry-group .group-row > label,
body.sheet-body:not(.section-viewer) .form-sheet .group-row > .row-label,
body.sheet-body:not(.section-viewer) .form-sheet .group-name,
body.sheet-body:not(.section-viewer) .form-sheet .group-help {
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .form-sheet .group-row > input:not(.pill-date),
body.sheet-body:not(.section-viewer) .form-sheet .group-row > select,
body.sheet-body:not(.section-viewer) .form-sheet .group-row > textarea,
body.sheet-body:not(.section-viewer) .form-sheet .row-value,
body.sheet-body:not(.section-viewer) .form-sheet details.more-group > summary,
body.sheet-body:not(.section-viewer) #entry-form .entry-group .group-row:not(.amount-row) > :is(input, select):not(.pill-date) {
  font-size: 15px;
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .entry-bar button.round-button[type] {
    width: 44px;
    height: 44px;
    min-height: 44px;
  }
  body.sheet-body:not(.section-viewer) .entry-bar button.word-button[type] {
    min-height: 44px;
  }
  body.sheet-body:not(.section-viewer) .form-sheet .group-row > input:not(.pill-date),
  body.sheet-body:not(.section-viewer) .form-sheet .group-row > select,
  body.sheet-body:not(.section-viewer) .form-sheet .group-row > textarea,
  body.sheet-body:not(.section-viewer) #entry-form .entry-group .group-row:not(.amount-row) > :is(input, select):not(.pill-date) {
    font-size: 16px;
  }
}

/* ------------------------------------------------------------------------------------------------------------------
   Insurance at its sample's drawn values (the brief of 6 Nov 26, Part 3.8: "the sample's drawn layout, sizes, spacing,
   corners, line spacing, boldness, shadow strength and behaviour win"). Measured by tools/measure-pairs.mjs into
   archive/fidelity/2026-11-06/insurance-measures.md. Avi's rulings still win over the sample: Georgia headings at
   regular weight (at the sample's sizes), forest shadows for its blue-grey, no text under 11 px (the card foot's 10.5
   and the status's 10 stay 11). Scoped to Insurance's own container. */
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page),
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) :is(.ins-entity[type], .ins-ic[type]) {
  font-size: 16px;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-hero {
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 2.75);
  box-shadow: 0 20px 45px var(--on-photo-shadow-7);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-heroinner {
  padding: calc(var(--base) * 4.75) calc(var(--base) * 5);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-hero .ins-eyebrow {
  font-size: 12px;
  line-height: normal;
  letter-spacing: 2.4px;
  margin: 0 0 calc(var(--base) * 1.875);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-hero h2 {
  font-size: 57.6px;
  line-height: 1.03;
  letter-spacing: -2px;
  margin: 0 0 calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-hero p {
  line-height: 1.5;
  margin: 0 0 calc(var(--base) * 2.75);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-feature {
  font-size: 12px;
  font-weight: 650;
  line-height: normal;
  padding: var(--base) calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-intel {
  padding: calc(var(--base) * 3) calc(var(--base) * 3.125);
  margin: calc(var(--base) * 2.5) 0 calc(var(--base) * 3);
  border-radius: var(--radius-block);
  box-shadow: 0 10px 30px var(--shadow);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-intel h2 {
  font-size: 29px;
  line-height: 1.18;
  letter-spacing: -0.725px;
  margin: 0 0 calc(var(--base) * 0.75);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-intel .ins-sub {
  font-size: 14px;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-tab[type] {
  font-size: 12px;
  line-height: normal;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.75);
  border-radius: var(--radius-pill);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-card {
  padding: calc(var(--base) * 2.75);
  gap: calc(var(--base) * 1.125);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-card h3 {
  line-height: 24.4px;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-card p {
  font-size: 14px;
  line-height: 1.58;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-tag {
  font-weight: 750;
  line-height: normal;
  padding: calc(var(--base) * 0.75) calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-card .ins-btn[type] {
  font-weight: 750;
  line-height: normal;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 2);
}
/* The page title's eyebrow, heading and line: the shared title block at the end (.gr-title, D-521 (1)). */
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-primary-btn[type] {
  line-height: normal;
  padding: calc(var(--base) * 1.625) calc(var(--base) * 2.125);
  gap: calc(var(--base) * 1.125);
  box-shadow: 0 7px 17px var(--shadow-2);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-metric {
  padding: calc(var(--base) * 2.875) calc(var(--base) * 3.125) calc(var(--base) * 2.5);
  border-radius: var(--radius-metric);
  box-shadow: 0 4px 15px var(--shadow-3);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-metric-heading {
  font-size: 12px;
  line-height: normal;
  gap: calc(var(--base) * 1.125);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-metric-value {
  font-size: 30px;
  font-weight: 740;
  line-height: 1.1;
  letter-spacing: -0.9px;
  margin: calc(var(--base) * 2.5) 0 0;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-metric-tail {
  line-height: normal;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #assurance-page, .spw, .txw) .ins-section-heading h2 {
  line-height: normal;
  letter-spacing: -0.5px;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #assurance-page, .spw, .txw) .ins-section-heading p:not(.ins-eyebrow) {
  line-height: 18.85px;
  margin: calc(var(--base) * 0.875) 0 0;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-light-btn[type] {
  font-size: 12px;
  font-weight: 690;
  line-height: normal;
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.625);
  border-radius: var(--radius-light-button);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-entities {
  padding: calc(var(--base) * 2.625) calc(var(--base) * 2.875);
  margin: 0 0 calc(var(--base) * 4.375);
  gap: calc(var(--base) * 1.875);
  border-radius: var(--radius-block);
  box-shadow: 0 4px 13px var(--shadow-4);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-entity[type] {
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.625) calc(var(--base) * 1.375);
  gap: calc(var(--base) * 0.875);
  border-radius: var(--radius-strip-tile);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-entity-img {
  box-shadow: 0 3px 14px var(--shadow-5);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-entity-label {
  font-size: 12px;
  font-weight: 730;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-category-header {
  margin: 0 0 calc(var(--base) * 2.25);
  gap: calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-count-label {
  font-size: 12px;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-card-grid {
  gap: calc(var(--base) * 2.375);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-ic[type] {
  padding: calc(var(--base) * 2.625) calc(var(--base) * 2.625) calc(var(--base) * 2.125);
  box-shadow: 0 3px 13px var(--shadow-6);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-ic[type]:hover {
  box-shadow: var(--shadow-lift);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-ic[type].related:hover {
  box-shadow: 0 21px 44px var(--shadow-7);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-cat-icon {
  border-radius: var(--radius-cat-icon);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-card-mid {
  margin: calc(var(--base) * 3.75) 0 0;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-card-mid p {
  font-size: 11.5px;
  line-height: 1.35;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-card-foot {
  font-weight: 580;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-status {
  font-weight: 720;
  line-height: normal;
  gap: calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-review-panel {
  padding: calc(var(--base) * 2.75) calc(var(--base) * 3);
  margin: calc(var(--base) * 3.75) 0 0;
  border-radius: var(--radius-review);
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-review-copy {
  line-height: normal;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-review-action[type] {
  line-height: normal;
  padding: var(--base) calc(var(--base) * 2);
  border-radius: var(--radius-light-button);
}
/* D-536 (1): the panel's corners are the Income source panel's 24 px (25 px before 11 Nov 26). */
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-drawer {
  border-radius: var(--radius-card) 0 0 var(--radius-card);
}
/* D-536 (1): every drawer's title as the Income source panel draws it: the record's mark above, then the title in
   Georgia 38 px at regular weight, then its one line at 13 px. */
body.sheet-body:not(.section-viewer) .ins .ins-drawer-title {
  display: block;
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-title .ins-cat-icon {
  margin-bottom: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .ins-drawer-title h2,
body.sheet-body:not(.section-viewer) .ins .inv-drawer-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 38px;
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.5px;
  margin: 0 0 var(--base);
}
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) :is(.ins-hero, .ins-intel, .ins-primary-btn[type], .ins-metric, .ins-entities, .ins-entity-img),
  body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page) .ins-ic[type]:not(:hover) {
    box-shadow: var(--shadow-card);
  }
}

/* ------------------------------------------------------------------------------------------------------------------
   Income's pop-ups (FX insights, the review queue, outlook, stress test, month-end, tax, non-income) are the sample's
   .modal (the brief of 6 Nov 26, Part 4.4): centred, 810 px, a 26 px corner, over the page dimmed and blurred. Inspect
   evidence stays the right-hand panel (Part 4.5). The overlay names its tool in data-tool. */
body.sheet-body:not(.section-viewer) #inc-overlay:not([data-tool="evidence"]) {
  justify-content: center;
  align-items: center;
  background: var(--on-photo-fill-32);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}
body.sheet-body:not(.section-viewer) #inc-overlay:not([data-tool="evidence"]) .ins-evidence {
  width: min(810px, calc(100vw - 28px));
  height: auto;
  max-height: calc(100vh - 34px);
  border-radius: var(--radius-modal);
  box-shadow: 0 25px 85px var(--on-photo-shadow-8);
  padding: calc(var(--base) * 2.875) calc(var(--base) * 3.5) calc(var(--base) * 3.75);
}
body.sheet-body:not(.section-viewer) #inc-overlay:not([data-tool="evidence"]) .ins-evidence h2 {
  font-size: 24px;
  margin: calc(var(--base) / 2) 0 calc(var(--base) * 0.625);
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) #inc-overlay:not([data-tool="evidence"]) .ins-evidence {
    border-radius: var(--radius-modal);
    padding: calc(var(--base) * 2.25);
  }
  body.sheet-body:not(.section-viewer) #inc-overlay:not([data-tool="evidence"]) .ins-evidence h2 {
    font-size: 20px;
  }
}

/* ------------------------------------------------------------------------------------------------------------------
   Income at its sample's drawn values (the brief of 6 Nov 26, Part 4.12), measured by tools/measure-pairs.mjs into
   archive/fidelity/2026-11-06/income-measures*.md. The rulings still win: Georgia headings at regular weight at the
   sample's sizes, forest for its blue-grey shadows, nothing under 11 px (the sample's 10 px text is 11). Scoped to
   Income's own container. */
body.sheet-body:not(.section-viewer) #inc-page,
body.sheet-body:not(.section-viewer) #inc-page :is(.inc-source-card[type], .inc-scene, .inc-roundarr) {
  font-size: 16px;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) #inc-page .ins-hero {
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 2.75);
  box-shadow: 0 20px 45px var(--on-photo-shadow-7);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-heroinner {
  padding: calc(var(--base) * 4.75) calc(var(--base) * 5);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-hero .ins-eyebrow {
  font-size: 12px;
  line-height: normal;
  letter-spacing: 2.4px;
  margin: 0 0 calc(var(--base) * 1.875);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-hero h2 {
  font-size: 57.6px;
  line-height: 1.03;
  letter-spacing: -2px;
  margin: 0 0 calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-hero p {
  line-height: 1.5;
  margin: 0 0 calc(var(--base) * 2.75);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-feature {
  font-size: 12px;
  font-weight: 650;
  line-height: normal;
  padding: var(--base) calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-intel {
  padding: calc(var(--base) * 3) calc(var(--base) * 3.125);
  margin: calc(var(--base) * 2.5) 0 calc(var(--base) * 3);
  border-radius: var(--radius-block);
  box-shadow: 0 10px 30px var(--shadow);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-intel h2 {
  font-size: 29px;
  line-height: 1.18;
  letter-spacing: -0.725px;
  margin: 0 0 calc(var(--base) * 0.75);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-intel .ins-sub {
  font-size: 14px;
  line-height: 1.55;
}
body.sheet-body:not(.section-viewer) #inc-page .ins-tab[type] {
  font-size: 12px;
  line-height: normal;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.75);
  border-radius: var(--radius-pill);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-card {
  padding: calc(var(--base) * 2.75);
  gap: calc(var(--base) * 1.125);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-card h3 {
  letter-spacing: -0.65px;
}
body.sheet-body:not(.section-viewer) #inc-page .ins-card p {
  font-size: 14px;
  line-height: 1.58;
}
body.sheet-body:not(.section-viewer) #inc-page .ins-tag {
  font-weight: 750;
  line-height: normal;
  padding: calc(var(--base) * 0.75) calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #inc-page .ins-card .ins-btn[type] {
  font-weight: 750;
  line-height: normal;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-title-row {
  margin: 0 0 calc(var(--base) * 3.25);
  gap: calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-control :is(label, .inc-control-label) {
  font-weight: 740;
  line-height: normal;
  letter-spacing: normal;
  text-transform: none;
  padding: 0 0 0 calc(var(--base) * 0.375);
  margin: 0;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-control {
  gap: calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-summary-grid {
  margin: 0 0 calc(var(--base) * 2.75);
  gap: calc(var(--base) * 2.125);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-hero {
  padding: calc(var(--base) * 3.125) calc(var(--base) * 3.5) calc(var(--base) * 2.5);
  border-radius: var(--radius-photo-hero);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-hero.cash {
  box-shadow: 0 22px 45px var(--on-photo-shadow-9);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-hero.gross {
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-line {
  font-size: 12px;
  font-weight: 720;
  line-height: normal;
  gap: calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-heropill {
  font-weight: 720;
  line-height: normal;
  letter-spacing: normal;
  padding: calc(var(--base) * 0.875) calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-amount {
  font-size: clamp(35px, 3.1vw, 48px);
  font-weight: 810;
  line-height: 1.05;
  letter-spacing: -1.9px;
  margin: calc(var(--base) * 3.375) 0 0;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-herodesc {
  font-size: 11px;
  line-height: normal;
  margin: calc(var(--base) * 1.25) 0 0;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-bottom small {
  line-height: 1.5;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-scopebar {
  padding: calc(var(--base) * 1.75) calc(var(--base) * 2.25);
  margin: calc(var(--base) * 2.25) 0 0;
  gap: calc(var(--base) * 1.5);
  border-radius: var(--radius-review);
  box-shadow: 0 4px 18px var(--shadow-8);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-button[type] {
  font-weight: 760;
  line-height: normal;
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.5);
  gap: calc(var(--base) * 0.875);
  border-radius: var(--radius-detail-button);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-sectionhead {
  margin: calc(var(--base) * 4.25) 0 calc(var(--base) * 2);
  gap: calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-sectionhead h2 {
  font-size: 21px;
  line-height: normal;
  letter-spacing: -0.65px;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-sectionhead p {
  font-size: 11px;
  line-height: 1.55;
  margin: calc(var(--base) * 0.75) 0 0;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-source-grid {
  gap: calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-source-card[type] {
  border-radius: var(--radius-modal);
  box-shadow: 0 5px 19px var(--shadow-9);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-source-card[type]:hover {
  box-shadow: 0 25px 50px var(--shadow-10);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-floating {
  font-weight: 790;
  line-height: normal;
  letter-spacing: normal;
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.375);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-roundarr {
  border-radius: var(--radius-panel-button);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-scenebody {
  padding: calc(var(--base) * 2.5) calc(var(--base) * 2.875) calc(var(--base) * 2.375);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-scenebody h3 {
  line-height: normal;
  letter-spacing: -0.75px;
  margin: 0 0 calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-catdesc {
  font-size: 11px;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-catamount {
  font-size: 22px;
  font-weight: 770;
  letter-spacing: -0.7px;
  margin: calc(var(--base) * 2.5) 0 calc(var(--base) * 0.75);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-cardfoot {
  font-weight: 680;
  line-height: normal;
  padding: calc(var(--base) * 1.75) 0 0;
  margin: calc(var(--base) * 2.25) 0 0;
  gap: calc(var(--base) * 1.125);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-sceneline .inc-pill {
  font-weight: 780;
  line-height: normal;
  padding: calc(var(--base) * 0.75) calc(var(--base) * 1.125);
  gap: calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-lower-grid {
  margin: calc(var(--base) * 4.25) 0 0;
  gap: calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) #inc-page .inc-panel {
  padding: calc(var(--base) * 2.75) calc(var(--base) * 2.875);
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-panel-head h3 {
  font-size: 17px;
  line-height: normal;
  letter-spacing: -0.65px;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-panel-head p {
  font-size: 11px;
  line-height: 1.55;
  margin: calc(var(--base) * 0.75) 0 0;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-bottom-grid {
  margin: calc(var(--base) * 2.25) 0 0;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-micro {
  padding: calc(var(--base) * 2.375) calc(var(--base) * 2.5);
  border-radius: var(--radius-tile);
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-micro-top b {
  font-size: 12px;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-micro strong {
  line-height: normal;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-micro p {
  line-height: 1.5;
}
body.sheet-body:not(.section-viewer) #inc-page .inc-micro button[type] {
  font-weight: 780;
  line-height: normal;
  padding: calc(var(--base) * 1.625) 0 0;
  border-radius: 0;
}
/* The pop-up's close: the sample's round ✕ at the top right (the brief of 6 Nov 26: the panel's round ✕ wins). The words
   "Close ×" stay the button's spoken name; only the drawn mark shows. */
body.sheet-body:not(.section-viewer) #inc-overlay:not([data-tool="evidence"]) .ins-evidence {
  position: relative;
}
body.sheet-body:not(.section-viewer) #inc-overlay:not([data-tool="evidence"]) #inc-tool-close {
  position: absolute;
  top: calc(var(--base) * 2.5);
  right: calc(var(--base) * 2.5);
  width: 34px;
  height: 34px;
  padding: 0;
  margin: 0;
  border-radius: 50%;
  font-size: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
body.sheet-body:not(.section-viewer) #inc-overlay:not([data-tool="evidence"]) #inc-tool-close::before {
  content: "×";
  font-size: 20px;
  line-height: 1;
}
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) #inc-page :is(.ins-hero, .ins-intel, .inc-hero.cash, .inc-scopebar),
  body.sheet-body:not(.section-viewer) #inc-page .inc-source-card[type]:not(:hover) {
    box-shadow: var(--shadow-card);
  }
}

/* The Debt page at its sample's drawn values (the brief of 6 Nov 26, Part 6; Family-Office v1.1's dashboards/debt/
   02-current-design): Insurance's and Income's ported parts (.ins) with the debt sample's own values on top, scoped to
   Debt's own container. The rulings still win: Georgia headings at regular weight, forest for its blue-grey, nothing
   under 11 px, money owed red with its minus sign. */
body.sheet-body:not(.section-viewer) #debt-page {
  font-size: 16px;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-photo-hero {
  /* A warmer, stronger photograph (the brief of 6 Nov 26 (b), Part 2.10): a beach house in low sun, the calm sky behind
     the heading; the forest fade keeps the words at 4.5:1. */
  background-image: linear-gradient(95deg, var(--on-photo-fill-15), var(--on-photo-fill-16) 55%, var(--on-photo-fill-33)), url("/photos/debt-hero-two-storey-sunset.webp");
  background-size: cover;
  background-position: center 46%;
}
body.sheet-body:not(.section-viewer) #debt-page .ins-hero {
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 2.75);
  box-shadow: 0 20px 45px var(--on-photo-shadow-7);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-heroinner {
  padding: calc(var(--base) * 4.75) calc(var(--base) * 5);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-hero .ins-eyebrow {
  font-size: 12px;
  letter-spacing: 2.4px;
  margin: 0 0 calc(var(--base) * 1.875);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-hero h2 {
  font-size: 57.6px;
  line-height: 1.03;
  letter-spacing: -2px;
  margin: 0 0 calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-hero p {
  line-height: 1.5;
  margin: 0 0 calc(var(--base) * 2.75);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-feature {
  font-size: 12px;
  font-weight: 650;
  padding: var(--base) calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-intel {
  padding: calc(var(--base) * 3) calc(var(--base) * 3.125);
  margin: calc(var(--base) * 2.5) 0 calc(var(--base) * 3);
  border-radius: var(--radius-block);
  box-shadow: 0 10px 30px var(--shadow);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-intel h2 {
  font-size: 29px;
  line-height: 1.18;
  letter-spacing: -0.725px;
  margin: 0 0 calc(var(--base) * 0.75);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-intel .ins-sub {
  font-size: 14px;
  line-height: 1.55;
}
body.sheet-body:not(.section-viewer) #debt-page .ins-tab[type] {
  font-size: 12px;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.75);
  border-radius: var(--radius-pill);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-card {
  padding: calc(var(--base) * 2.75);
  gap: calc(var(--base) * 1.125);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-card h3 {
  letter-spacing: -0.65px;
}
body.sheet-body:not(.section-viewer) #debt-page .ins-card p {
  font-size: 14px;
  line-height: 1.58;
}
body.sheet-body:not(.section-viewer) #debt-page .ins-card .ins-btn[type] {
  font-weight: 750;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 2);
}
/* The four metric cards: the first wider, as drawn. */
body.sheet-body:not(.section-viewer) #debt-page .debt-metrics {
  grid-template-columns: 1.2fr 1fr 1fr 1fr;
  gap: calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 4);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-metric {
  min-height: 147px;
  padding: calc(var(--base) * 2.75) calc(var(--base) * 3);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #debt-page .ins-metric-value {
  font-size: 30px;
  letter-spacing: -1px;
  margin-top: calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-currencies {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 1.5) calc(var(--base) * 2.5);
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-currency label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.4px;
  color: var(--ins-quiet);
  margin-bottom: calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-currency-value {
  font-size: 21px;
  font-weight: 760;
  letter-spacing: -0.6px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #debt-page .owed,
body.sheet-body:not(.section-viewer) #debt-page .debt-big.owed,
body.sheet-body:not(.section-viewer) #debt-page .debt-currency-value.owed {
  color: var(--color-red);
}
/* Your liabilities: the sample's loan cards, on Insurance's card (hover lift, ring, fade). */
/* Insurance is the baseline (Avi's check of 6 Nov 26; the brief of 6 Nov 26 (b), Part 2.1): the page as wide as
   Insurance's, the cards its 263 px with its padding, four to a row at its 19 px gap. */
@media (min-width: 768px) {
  body.sheet-body .sheet-page:has(#debt-page) {
    max-width: none;
  }
}
body.sheet-body:not(.section-viewer) #debt-page .ins-card-grid {
  gap: calc(var(--base) * 2.375);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card[type] {
  min-height: 263px;
  padding: calc(var(--base) * 2.625) calc(var(--base) * 2.625) calc(var(--base) * 2.125);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card .ins-cat-icon {
  width: 49px;
  height: 49px;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card-name {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 16px;
  font-weight: 760;
  letter-spacing: -0.45px;
  margin: calc(var(--base) * 2.375) 0 calc(var(--base) * 0.625);
  /* Nothing on a card is cut with "…" (the brief of 6 Nov 26 (c), Part 2.4): a long name wraps. */
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card-sub {
  font-size: 11px;
  color: var(--ins-quiet);
  min-height: 30px;
  line-height: 1.35;
  margin: 0;
}
/* The balance, then the rate under it on every card (a credit card's limit beside the rate), each line at the same
   place on every card of a row (Avi's check of 6 Nov 26, steps 7 and 8). */
body.sheet-body:not(.section-viewer) #debt-page .debt-card-main {
  display: flex;
  flex-direction: column;
  gap: var(--base);
  margin: var(--base) 0 0;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card-terms {
  display: grid;
  /* Each column as wide as its own words, so "19.99% a year" and "10,000.00 AUD" sit whole side by side in Insurance's
     230 px card at 1,280 (the brief of 6 Nov 26 (c), Part 2.4); two equal halves wrapped both. */
  grid-template-columns: auto auto;
  justify-content: space-between;
  gap: var(--base);
}
/* A loan's rate alone takes the card's width. */
body.sheet-body:not(.section-viewer) #debt-page .debt-card-terms > .debt-card-rate:only-child {
  grid-column: 1 / -1;
}
/* A figure is never cut (the brief of 6 Nov 26 (c), Part 2.4): the rate and the limit keep every character. */
body.sheet-body:not(.section-viewer) #debt-page .debt-card-terms .debt-rate {
  overflow-wrap: normal;
}
/* 7 px over the name, not 8: with the card's 1 px border drawn (as Safari always drew it), 8 px left the content
   0.07 px past Insurance's 263 px (the closing of 6 Nov 26 (b); the harness had not drawn the border, its light
   block dropped). */
body.sheet-body:not(.section-viewer) #debt-page .debt-card-name {
  margin: calc(var(--base) * 0.875) 0 calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card .ins-cat-icon {
  width: 40px;
  height: 40px;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card[type] .ins-card-bottom {
  margin-top: auto;
  padding-top: calc(var(--base) * 0.75);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card[type] .ins-card-top {
  height: 40px;
  min-height: 0;
  align-items: center;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card-main .debt-smallkey {
  line-height: 1.2;
  margin-bottom: calc(var(--base) * 0.375);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card-main .debt-big {
  line-height: 1.2;
}
/* The foot in two lines on every card, the payment then its status, so no card's foot wraps differently from its
   neighbour's and every card stays at Insurance's 263 px. */
body.sheet-body:not(.section-viewer) #debt-page .debt-card .ins-card-divider {
  display: none;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card[type] .ins-card-foot {
  flex-direction: column;
  align-items: flex-start;
  gap: calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card[type] .ins-card-foot > span:first-child {
  max-width: 100%;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card[type] .ins-card-top {
  height: 36px;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card[type] .ins-cat-icon {
  width: 36px;
  height: 36px;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card-sub {
  min-height: 0;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-card .ins-card-foot {
  flex-wrap: wrap;
  row-gap: calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-smallkey {
  font-size: 11px;
  color: var(--ins-quiet);
  margin-bottom: calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-big {
  font-size: 19px;
  font-weight: 770;
  letter-spacing: -0.75px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-rate {
  font-size: 13px;
  font-weight: 730;
  overflow-wrap: break-word;
}
body.sheet-body:not(.section-viewer) #debt-page .is-not-recorded {
  color: var(--ins-quiet);
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-big.is-not-recorded {
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) #debt-page .ins-status[data-level="ok"] {
  color: var(--fo-success-accent);
}
/* Coming up and Balance reconciliation, side by side. */
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-below {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(330px, 1fr);
  gap: calc(var(--base) * 2.25);
  margin-top: calc(var(--base) * 3.75);
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-panel {
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  padding: calc(var(--base) * 2.75) calc(var(--base) * 2.875);
  box-shadow: var(--shadow-card);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(var(--base) * 1.5);
  margin-bottom: calc(var(--base) * 2.5);
}
/* The brief of 17 Nov 26, A1 (the branch-a closing's tables): a button in the head keeps its own width and the heading
   block wraps instead; on the phone Property's "Explore return" was squeezed to 79 px with its words 99 px wide. */
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-panel-head > button {
  flex: none;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-panel h2 {
  font-size: 17px;
  letter-spacing: -0.25px;
  margin: 0;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-panel-head p {
  color: var(--ins-quiet);
  font-size: 11px;
  line-height: 1.45;
  margin: calc(var(--base) * 0.75) 0 0;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-segmented {
  display: flex;
  gap: calc(var(--base) * 0.25);
  padding: calc(var(--base) * 0.375);
  background: var(--stone);
  border-radius: var(--radius-panel-button);
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-segmented button[type] {
  font-size: 11px;
  font-weight: 700;
  color: var(--ins-quiet);
  background: transparent;
  border: 0;
  border-radius: var(--radius-tab-inner);
  padding: var(--base) calc(var(--base) * 2);
  min-height: 0;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-segmented button[aria-pressed="true"] {
  background: var(--paper);
  color: var(--text);
  box-shadow: 0 1px 4px var(--shadow-11);
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-event {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr) auto;
  gap: calc(var(--base) * 1.875);
  align-items: center;
  padding: calc(var(--base) * 1.75) 0;
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-event:first-child {
  border-top: 0;
  padding-top: 0;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-date-chip {
  background: var(--stone);
  border-radius: var(--radius-panel-button);
  padding: calc(var(--base) * 1.125) calc(var(--base) * 0.625);
  text-align: center;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-date-chip b {
  display: block;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-date-chip span {
  display: block;
  font-size: 11px;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--ins-quiet);
  font-weight: 740;
  margin-top: calc(var(--base) * 0.375);
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-event-title {
  font-size: 13px;
  font-weight: 730;
  line-height: 1.4;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-event-desc {
  font-size: 11px;
  color: var(--ins-quiet);
  line-height: 1.55;
  margin-top: calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-event-tag[type] {
  border: 0;
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.625) var(--base);
  min-height: 0;
  background: var(--fo-success-bg);
  color: var(--forest-2);
  font-size: 11px;
  font-weight: 740;
  text-transform: uppercase;
  letter-spacing: 0.3px;
  white-space: nowrap;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-event-tag[data-coming-tag="change"] {
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-recon-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: calc(var(--base) * 1.5);
  padding: calc(var(--base) * 1.875) 0;
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-recon-row:first-child {
  border-top: 0;
  padding-top: 0;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-recon-row strong {
  display: block;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-recon-row small {
  display: block;
  color: var(--ins-quiet);
  font-size: 11px;
  margin-top: calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-recon-right {
  text-align: right;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-recon-right b {
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-recon-right span {
  display: block;
  font-size: 11px;
  margin-top: calc(var(--base) * 0.5);
  color: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-recon-right span[data-level="review"] {
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-review[type] {
  margin-top: calc(var(--base) * 0.875);
  padding: calc(var(--base) * 0.75) calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #debt-page :is(.debt-panel-note, .debt-empty) {
  background: var(--stone);
  border-radius: var(--radius-panel-button);
  padding: calc(var(--base) * 1.75);
  font-size: 11px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: calc(var(--base) * 1.5) 0 0;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-empty {
  margin: 0;
  font-size: 13px;
}
/* The panel's contents: the sample's two figure boxes, linked lines, the repayment record, the projection controls and
   chart, the variance box and the documents. */
body.sheet-body:not(.section-viewer) #debt-page .debt-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-stat {
  background: var(--stone);
  border-radius: var(--radius-icon-box-small);
  padding: calc(var(--base) * 1.875);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-stat small {
  display: block;
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-stat b {
  display: block;
  font-size: 19px;
  font-weight: 760;
  letter-spacing: -0.6px;
  margin-top: calc(var(--base) * 1.125);
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-linked-line {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.25);
  padding: calc(var(--base) * 0.875) 0;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-linked-img {
  width: 34px;
  height: 34px;
  margin: 0;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-linked-line b {
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-linked-line small {
  margin-left: auto;
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-open-link {
  display: inline-block;
  margin: calc(var(--base) * 2) 0 0;
  text-decoration: none;
}
body.sheet-body:not(.section-viewer) #debt-page .ins-drawer-content .ins-btn {
  margin-top: calc(var(--base) * 2);
  margin-right: var(--base);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-record {
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-icon-box-small);
  padding: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-record-title {
  font-size: 13px;
  font-weight: 760;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-phase {
  margin-top: calc(var(--base) * 1.875);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-phase-head {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 1.5);
  font-size: 11px;
  margin-bottom: calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-phase-head span,
body.sheet-body:not(.section-viewer) #debt-page .debt-phase-legend {
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-phase-bar {
  display: flex;
  height: 11px;
  gap: calc(var(--base) * 0.375);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-phase-io {
  width: 8%;
  background: var(--forest-2);
  border-radius: var(--radius-phase) 0 0 var(--radius-phase);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-phase-pi {
  flex: 1;
  background: color-mix(in srgb, var(--forest-2) 25%, var(--paper));
  border-radius: 0 var(--radius-phase) var(--radius-phase) 0;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-phase-legend {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  margin-top: var(--base);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-projection-controls {
  display: flex;
  gap: calc(var(--base) * 0.625);
  background: var(--stone);
  border-radius: var(--radius-icon-box-small);
  padding: calc(var(--base) / 2);
  margin-top: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-projection-controls button[type] {
  flex: 1;
  border: 0;
  background: transparent;
  padding: calc(var(--base) * 1.125) 0;
  min-height: 0;
  border-radius: var(--radius-chip-inner);
  font-size: 11px;
  font-weight: 730;
  color: var(--ins-quiet);
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-projection-controls button[type] {
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
}
/* The panel's tabs are Insurance's forest pills (the shared .ins rule), no longer the debt sample's underlined words
   (Avi's check of 6 Nov 26; the brief of 6 Nov 26 (b), Part 2.9). The year and rate switches take the Appearance
   switch's forest style below, with Coming up's. */
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) :is(.debt-segmented, .debt-projection-controls) {
  display: flex;
  align-items: stretch;
  gap: 0;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) :is(.debt-segmented, .debt-projection-controls) button[type] {
  padding: var(--base) calc(var(--base) * 2);
  border: 0;
  border-radius: var(--radius-switch-button);
  background: transparent;
  color: var(--text-muted);
  box-shadow: none;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  min-height: 0;
}
body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) :is(.debt-segmented, .debt-projection-controls) button[type][aria-pressed="true"] {
  background: var(--color-accent);
  color: var(--plus-ink);
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-scenario-note {
  margin: var(--base) 0 0;
  font-size: 11px;
  line-height: 1.5;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-higher {
  stroke: var(--fo-review-accent);
  stroke-dasharray: 6 4;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-legends {
  display: flex;
  flex-wrap: wrap;
  gap: 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-foot {
  flex-basis: 100%;
  margin: calc(var(--base) * -1) 0 calc(var(--base) * 2);
  font-size: 11px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-io {
  margin-bottom: calc(var(--base) * 1.5);
}
/* D-646, the approved demo of 23 Nov 26 (.modelled): the label on every modelled figure. */
body.sheet-body .debt-modelled {
  display: inline-block;
  margin-left: calc(var(--base) * 0.75);
  padding: calc(var(--base) * 0.25) var(--base);
  border-radius: var(--radius-pill);
  background: var(--chip-bg);
  color: var(--text-muted);
  font-size: var(--size-caption, 11px);
  font-weight: 650;
  letter-spacing: .08em;
  text-transform: uppercase;
}
/* D-646, the approved demo of 23 Nov 26 (.esec): an Edit record section with fields of its own (a loan's Loan terms),
   a tinted card holding its heading (17 px), one line (13 px) and its rows; the repayment type a switch across the
   full width in two equal halves (15 px; Avi's words on the demo). */
body.sheet-body .form-sheet .edit-section {
  margin: calc(var(--base) * 2) 0;
  padding: calc(var(--base) * 1.75) calc(var(--base) * 2) calc(var(--base) * 0.75);
  border: 1px solid var(--ins-line, var(--border));
  border-radius: var(--radius-tile);
  background: var(--edit-section-bg);
}
body.sheet-body .form-sheet .edit-section-title {
  margin: calc(var(--base) * 0.25) 0;
  font-size: var(--size-body);
  font-weight: 650;
  color: var(--text);
}
body.sheet-body .form-sheet .edit-section-note {
  margin: 0 0 calc(var(--base) * 0.75);
  font-size: var(--size-meta);
  color: var(--text-muted);
}
body.sheet-body .form-sheet .edit-section .entry-group,
body.sheet-body .form-sheet .edit-section .group-help {
  margin-left: 0;
  margin-right: 0;
}
body.sheet-body .form-sheet .terms-type-row {
  display: block;
}
body.sheet-body .form-sheet .terms-switch {
  display: grid;
  grid-template-columns: 1fr 1fr;
  margin-top: var(--base);
  border: 1px solid var(--ins-line, var(--border));
  border-radius: var(--radius-pill);
  overflow: hidden;
}
body.sheet-body .form-sheet .terms-half {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: var(--base) calc(var(--base) * 0.75);
  font-size: var(--size-small, 15px);
  font-weight: 600;
  text-align: center;
  color: var(--text);
  cursor: pointer;
}
body.sheet-body .form-sheet .terms-half input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
body.sheet-body .form-sheet .terms-half:has(input:checked) {
  background: var(--accent);
  color: var(--ivory);
}
body.sheet-body .form-sheet .terms-half:has(input:focus-visible) {
  outline: 2px solid var(--text);
  outline-offset: -4px;
}
/* D-653 (1), the approved demo of 22 Nov 26: Edit record's sections, each its own tint, with "n of N" above its heading;
   every row in the sheet in the one row size. */
body.sheet-body .form-sheet .edit-section.edit-sec-1 { background: var(--edit-sec-1); }
body.sheet-body .form-sheet .edit-section.edit-sec-2 { background: var(--edit-sec-2); }
body.sheet-body .form-sheet .edit-section.edit-sec-3 { background: var(--edit-sec-3); }
body.sheet-body .form-sheet .edit-section.edit-sec-4 { background: var(--edit-sec-4); }
body.sheet-body .form-sheet .edit-section.edit-sec-5 { background: var(--edit-section-bg); }
body.sheet-body .form-sheet .edit-section-num {
  margin: 0;
  font-size: var(--size-caption, 11px);
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body .form-sheet .edit-section .entry-group,
body.sheet-body .form-sheet .edit-section .sheet-card {
  background: transparent;
  box-shadow: none;
}
/* D-653 (1): the record panel's footer, Full page then Edit record, on the right, kept at the panel's foot. */
body.sheet-body .form-sheet .record-foot {
  position: sticky;
  bottom: 0;
  display: flex;
  justify-content: flex-end;
  gap: calc(var(--base) * 1.25);
  margin: calc(var(--base) * 2) calc(var(--base) * -3) 0;
  padding: calc(var(--base) * 1.75) calc(var(--base) * 3);
  border-top: 1px solid var(--border);
  background: var(--color-card);
}
body.sheet-body .form-sheet .record-foot button[type] {
  height: 40px;
  padding: 0 calc(var(--base) * 2.25);
  border-radius: var(--radius-pill);
  font-size: var(--size-small, 15px);
  font-weight: 600;
  white-space: nowrap;
}
body.sheet-body .form-sheet .record-balance-figure {
  font-size: var(--size-heading);
  font-weight: 650;
  font-variant-numeric: tabular-nums;
}
/* D-652 (1): a save made over a record's panel, said at the panel's top. */
body.sheet-body:not(.section-viewer) .panel-saved {
  margin: calc(var(--base) * 1) 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .panel-saved p {
  margin: 0;
}
/* D-653 (1): the Debt and Property panels' Documents card, its first row "＋ Record a document". */
body.sheet-body:not(.section-viewer) .ins .panel-documents button.row-button.add-row[type] {
  display: flex;
  align-items: center;
  width: 100%;
  min-height: 44px;
  padding: calc(var(--base) * 1.5) 0;
  border: 0;
  border-bottom: 1px solid var(--ins-line, var(--border));
  background: transparent;
  color: var(--text);
  font-size: var(--size-small, 15px);
  font-weight: 600;
  text-align: left;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-box {
  padding: calc(var(--base) * 1.25) 0 0;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart {
  display: block;
  width: 100%;
  height: 150px;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-axis {
  stroke: var(--ins-line);
  fill: none;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-mid {
  stroke: var(--ins-line);
  stroke-dasharray: 3 4;
  fill: none;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-area {
  fill: var(--forest-2);
  fill-opacity: 0.1;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-line {
  fill: none;
  stroke: var(--forest-2);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-end {
  fill: var(--forest-2);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-scale {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--ins-quiet);
  margin-top: calc(var(--base) * -2.5);
  padding: 0 calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-legend {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 0.875);
  color: var(--ins-quiet);
  font-size: 11px;
  margin: calc(var(--base) * 1.5) 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-legend::before {
  content: "";
  width: 13px;
  height: 3px;
  background: var(--forest-2);
  border-radius: var(--radius-pill);
}
/* The legend's two marks (the brief of 6 Nov 26 (c), Part 2.5): solid for the current rate, dashed for one point more,
   drawn as the chart's own lines are (.debt-chart-higher: the review accent, 6 on and 4 off). This rule sits after the
   solid one above, which has the same weight and used to win, so both marks were drawn solid. */
body.sheet-body:not(.section-viewer) #debt-page .debt-chart-legend.debt-legend-higher::before {
  width: 20px;
  border-radius: 0;
  background: repeating-linear-gradient(90deg, var(--fo-review-accent) 0 6px, transparent 6px 10px);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-figures {
  margin-top: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-variance {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 1.25);
  margin: calc(var(--base) * 1.625) 0 calc(var(--base) * 0.5);
  padding: calc(var(--base) * 1.75);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-icon-box-small);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-variance[data-level="review"] {
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-doc {
  display: flex;
  gap: calc(var(--base) * 1.5);
  align-items: center;
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-icon-box-small);
  padding: calc(var(--base) * 1.875);
  margin-bottom: calc(var(--base) * 1.375);
}
body.sheet-body:not(.section-viewer) #debt-page .debt-doc-badge {
  width: 37px;
  height: 37px;
  display: grid;
  place-items: center;
  border-radius: var(--radius-icon-box-small);
  background: var(--stone);
  color: var(--ins-quiet);
  flex: none;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-doc b {
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #debt-page .debt-doc p {
  margin: calc(var(--base) * 0.625) 0 0;
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #debt-page .ins-detail-row strong.is-not-recorded {
  font-weight: 600;
}
@media (max-width: 1170px) {
  body.sheet-body:not(.section-viewer) #debt-page .ins-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) #debt-page .debt-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-below {
    grid-template-columns: 1fr 1fr;
  }
}
@media (max-width: 820px) {
  body.sheet-body:not(.section-viewer) #debt-page .ins-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-below {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 560px) {
  body.sheet-body:not(.section-viewer) #debt-page .ins-hero h2 {
    font-size: 38px;
  }
  body.sheet-body:not(.section-viewer) #debt-page .debt-card[type] {
    min-height: 262px;
    padding: calc(var(--base) * 1.875);
  }
  body.sheet-body:not(.section-viewer) #debt-page .debt-big {
    font-size: 17px;
  }
  body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-event {
    grid-template-columns: 60px minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) :is(#debt-page, #pa-page, #pr-page) .debt-event-tag[type] {
    grid-column: 2;
    justify-self: start;
  }
}
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) #debt-page :is(.ins-hero, .ins-intel) {
    box-shadow: var(--shadow-card);
  }
}

/* =====================================================================================================================
   Phone & Access built from its sample (the brief of 6 Nov 26 (b), Part 5): Family-Office v1.1's dashboards/phone-access/
   02-current-design, on Insurance's measured values (the shared :is(#ins-page, #pa-page, #pr-page) rules above: Insurance is the
   baseline, its width and its 270 x 263 cards) and Debt's panels and forest switch (:is(#debt-page, #pa-page, #pr-page)). The
   sample's own sizes are in archive/fidelity/2026-11-06-b/phone-access-measures.md. The rulings still win: Georgia
   headings at regular weight, forest for the sample's blue, nothing under 11 px, last digits only. Scoped to #pa-page.
   ===================================================================================================================== */
@media (min-width: 768px) {
  body.sheet-body .sheet-page:has(#pa-page) {
    max-width: none;
  }
}
body.sheet-body:not(.section-viewer) #pa-page .pa-photo-hero {
  /* Its own photograph: a dark timber cabin at dusk, its windows lit, a forest behind; the forest fade keeps the words
     at 4.5:1. */
  background-image: linear-gradient(95deg, var(--on-photo-fill), var(--on-photo-fill-2) 55%, var(--on-photo-fill-17)), url("/photos/phone-access-hero-cliff-house.webp");
  background-size: cover;
  background-position: center 58%;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-title-buttons {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.5);
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-count-line {
  margin: 0 0 calc(var(--base) * 4);
  font-size: 13px;
  color: var(--ins-quiet);
}
/* Your numbers and Connected services: Insurance's card (hover lift, ring, fade), four to a row at its 19 px gap, 263 px. */
body.sheet-body:not(.section-viewer) #pa-page .pa-card[type] {
  min-height: 263px;
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-card[type] .ins-card-top {
  height: 40px;
  min-height: 0;
  align-items: center;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-card[type] .ins-cat-icon {
  width: 40px;
  height: 40px;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-country {
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--ins-quiet);
  margin: calc(var(--base) * 2) 0 0;
  display: flex;
  align-items: center;
  gap: var(--base);
}
/* 7 Nov 26 (Part 1 item 6): "Country not recorded" in plain case; a country's name keeps the sample's capitals. */
body.sheet-body:not(.section-viewer) #pa-page .pa-country.pa-country-none {
  text-transform: none;
  letter-spacing: 0;
}
/* Part 3 item 6: the sample's .flag (25 px, line height 1) before the country's name. */
body.sheet-body:not(.section-viewer) #pa-page .pa-flag {
  font-size: 25px;
  line-height: 1;
  letter-spacing: 0;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-card-name {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 17px;
  font-weight: 770;
  letter-spacing: -0.42px;
  line-height: 1.25;
  margin: calc(var(--base) * 0.75) 0 calc(var(--base) * 0.75);
  /* Wraps, never cut off with an ellipsis (6 Nov 26 (c), Part 5: "Plan not kn…" at 1,280). */
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-mask {
  font-size: 13px;
  font-weight: 680;
  letter-spacing: 0.25px;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-card-sub {
  font-size: 11px;
  color: var(--ins-quiet);
  line-height: 1.4;
  margin: calc(var(--base) * 0.75) 0 0;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-owner {
  display: flex;
  align-items: center;
  gap: var(--base);
  margin: calc(var(--base) * 1.75) 0 0;
  font-size: 11px;
  color: var(--ins-quiet);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-owner > span:first-of-type {
  min-width: 0;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-owner .ins-mini {
  width: 22px;
  height: 22px;
  flex: none;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-chip {
  margin-left: auto;
  flex: none;
  background: var(--stone);
  color: var(--text);
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.625) var(--base);
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-card[type] .ins-card-bottom {
  margin-top: auto;
  padding-top: calc(var(--base) * 1.5);
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-card[type] .ins-card-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--base);
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-card[type] .ins-card-foot > span:first-child {
  flex: none;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-card[type] .ins-card-foot > .ins-status {
  min-width: 0;
  white-space: normal;
  text-align: right;
}
body.sheet-body:not(.section-viewer) #pa-page .ins-status {
  font-size: 11px;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #pa-page .ins-status[data-level="ok"] {
  color: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) #pa-page .ins-status[data-level="quiet"] {
  color: var(--ins-quiet);
}
/* A service's lines as country pills, its last digits only. */
body.sheet-body:not(.section-viewer) #pa-page .pa-pills {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 0.625);
  margin: calc(var(--base) * 1.5) 0 0;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-pill {
  background: var(--stone);
  color: var(--text);
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.625) var(--base);
  font-size: 11px;
  font-weight: 730;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
/* The category filter and search: the filter the Appearance switch's forest style (every switch forest). */
body.sheet-body:not(.section-viewer) #pa-page .pa-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2.25);
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-cats {
  display: flex;
  flex-wrap: wrap;
  gap: 0;
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-cats button[type] {
  padding: var(--base) calc(var(--base) * 2);
  border: 0;
  border-radius: var(--radius-switch-button);
  background: transparent;
  color: var(--text-muted);
  box-shadow: none;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  min-height: 0;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-cats button[type][aria-pressed="true"] {
  background: var(--color-accent);
  color: var(--plus-ink);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-search {
  position: relative;
  display: block;
  width: 240px;
  max-width: 100%;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-search-icon {
  position: absolute;
  left: calc(var(--base) * 1.375);
  top: 50%;
  transform: translateY(-50%);
  color: var(--ins-quiet);
  display: flex;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-search input {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
  color: var(--text);
  padding: var(--base) calc(var(--base) * 1.5) var(--base) calc(var(--base) * 4.5);
  font-size: 13px;
  min-height: 0;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-help {
  margin: calc(var(--base) * 2) 0 0;
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #pa-page section + section {
  margin-top: calc(var(--base) * 4.375);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-below > section + section {
  margin-top: 0;
}
/* What's due and Access readiness. */
body.sheet-body:not(.section-viewer) #pa-page .pa-below {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}
body.sheet-body:not(.section-viewer) #pa-page .debt-event-tag[data-level="critical"] {
  background: var(--fo-critical-bg);
  color: var(--fo-critical-accent);
}
body.sheet-body:not(.section-viewer) #pa-page .debt-event-tag[data-level="review"] {
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-selected {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-selected small {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-selected strong {
  display: block;
  font-size: 15px;
  margin-top: calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-bar {
  display: flex;
  gap: calc(var(--base) * 0.875);
  margin: calc(var(--base) * 1.5) 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-bar > span {
  height: 10px;
  min-width: 12px;
  border-radius: var(--radius-pill);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-bar > [data-impact="untested"] { background: var(--fo-critical-accent); opacity: 0.55; }
body.sheet-body:not(.section-viewer) #pa-page .pa-bar > [data-impact="tested"] { background: var(--fo-success-accent); opacity: 0.6; }
body.sheet-body:not(.section-viewer) #pa-page .pa-bar > [data-impact="recovery"] { background: var(--fo-review-accent); opacity: 0.55; }
body.sheet-body:not(.section-viewer) #pa-page .pa-bar > [data-impact="contact"] { background: var(--ins-quiet); opacity: 0.45; }
body.sheet-body:not(.section-viewer) #pa-page .pa-key {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: calc(var(--base) * 1.25);
  padding: calc(var(--base) * 1.5) 0;
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-key b {
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-key small {
  display: block;
  font-size: 11px;
  color: var(--ins-quiet);
  margin-top: calc(var(--base) * 0.625);
  line-height: 1.5;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-key > span {
  font-size: 13px;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-note {
  margin: calc(var(--base) * 1.5) 0 0;
  font-size: 11px;
  line-height: 1.55;
  color: var(--ins-quiet);
}
/* The panels' rows. */
body.sheet-body:not(.section-viewer) #pa-page .pa-impact {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--base) calc(var(--base) * 1.5);
  padding: calc(var(--base) * 1.75) 0;
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-impact b {
  display: block;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-impact small {
  display: block;
  font-size: 11px;
  line-height: 1.5;
  color: var(--ins-quiet);
  margin-top: calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-impact .ins-btn[type] {
  margin-top: var(--base);
}
/* 6 Nov 26 (c), Part 3 item 5: the panel's buttons in the sample's light outline (.outline: 1 px line, 11 px radius,
   9 x 12 padding, 11 px heavy words in the muted ink, the line darkening on hover), on our card colour. */
body.sheet-body:not(.section-viewer) #pa-page .ins-drawer .ins-btn[type] {
  border: 1px solid var(--border);
  border-radius: var(--radius-panel-button);
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.5);
  background: var(--color-card);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 720;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #pa-page .ins-drawer .ins-btn[type]:hover {
  border-color: var(--text-muted);
  color: var(--text);
}
/* Part 3 item 10: Test number loss, the sample's .sim-toggle tile with its tick in forest, its .risk-card in the review
   family, and a row that would lose its codes marked in the same family (the words say it too). */
body.sheet-body:not(.section-viewer) #pa-page .pa-loss {
  display: flex;
  gap: calc(var(--base) * 1.5);
  align-items: center;
  background: var(--stone);
  border-radius: var(--radius-record);
  padding: calc(var(--base) * 1.875);
  margin: 0 0 calc(var(--base) * 2.25);
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-loss input {
  accent-color: var(--color-accent);
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  margin: 0;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-loss b {
  display: block;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-loss small {
  display: block;
  color: var(--ins-quiet);
  font-size: 11px;
  margin-top: calc(var(--base) * 0.5);
  line-height: 1.4;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-loss-card {
  background: var(--fo-review-bg);
  border: 1px solid var(--fo-review-border);
  border-radius: var(--radius-stat-box);
  padding: calc(var(--base) * 1.75);
  margin: 0 0 calc(var(--base) * 2.125);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-loss-card strong {
  font-size: 13px;
  color: var(--fo-review-title);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-loss-card p {
  font-size: 11px;
  line-height: 1.6;
  color: var(--fo-review-body);
  margin: calc(var(--base) * 0.75) 0 0;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-impact.pa-would-lose {
  border: 1px solid var(--fo-review-border);
  border-radius: var(--radius-stat-box);
  background: var(--fo-review-bg);
  padding: calc(var(--base) * 1.75);
  margin: var(--base) 0;
}
/* Part 3 items 3 and 4: the sample's two figure tiles (.metric-mini, .mini-box) at the top of a line's and a service's panel. */
body.sheet-body:not(.section-viewer) #pa-page .pa-mini {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--base) * 1.125);
  margin: 0 0 calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-mini-box {
  background: var(--stone);
  border-radius: var(--radius-stat-box);
  padding: calc(var(--base) * 1.75);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-mini-box small {
  display: block;
  font-size: 11px;
  color: var(--ins-quiet);
  margin-bottom: calc(var(--base) * 0.875);
}
body.sheet-body:not(.section-viewer) #pa-page .pa-mini-box b {
  font-size: 19px;
  letter-spacing: -0.4px;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #pa-page .ins-detail-row strong.is-not-recorded,
body.sheet-body:not(.section-viewer) #pa-page .is-not-recorded {
  color: var(--ins-quiet);
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) #pa-page .pa-panel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  margin-top: calc(var(--base) * 2);
}
@media (max-width: 1170px) {
  body.sheet-body:not(.section-viewer) #pa-page .ins-card-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) #pa-page .pa-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 820px) {
  body.sheet-body:not(.section-viewer) #pa-page .ins-card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) #pa-page .pa-below {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 560px) {
  body.sheet-body:not(.section-viewer) #pa-page .ins-hero h2 {
    font-size: 38px;
  }
  body.sheet-body:not(.section-viewer) #pa-page .ins-card-grid {
    grid-template-columns: 1fr;
  }
  body.sheet-body:not(.section-viewer) #pa-page .pa-card[type] {
    min-height: 0;
  }
  body.sheet-body:not(.section-viewer) #pa-page .pa-search {
    width: 100%;
  }
}
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) #pa-page :is(.ins-hero, .ins-intel) {
    box-shadow: var(--shadow-card);
  }
}

/* =====================================================================================================================
   Property built from its sample (the brief of 6 Nov 26 (c), Part 4): Family-Office v1.1's dashboards/property/
   02-current-design, on Insurance's measured values (the shared :is(#ins-page, #pa-page, #pr-page) rules: its width, hero,
   intel, title, metrics, entity tiles and panel) and Debt's panels and forest switch (:is(#debt-page, #pa-page, #pr-page)).
   The portfolio's photo cards are drawn as the sample draws them (two to a row, 170 px photograph). The rulings still win:
   Georgia headings at regular weight, forest for the sample's blue, nothing under 11 px, red only on a passed date (secured
   debt keeps its minus sign in ink). Scoped to #pr-page.
   ===================================================================================================================== */
@media (min-width: 768px) {
  body.sheet-body .sheet-page:has(#pr-page) {
    max-width: none;
  }
}
body.sheet-body:not(.section-viewer) #pr-page .pr-photo-hero {
  /* Its own photograph: a modern house at dusk, warm light in its windows; the forest fade keeps the words at 4.5:1. */
  background-image: linear-gradient(95deg, var(--on-photo-fill), var(--on-photo-fill-2) 55%, var(--on-photo-fill-3)), url("/photos/property-hero-modern-dusk.webp");
  background-size: cover;
  background-position: center 55%;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-bottom: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-not-yet {
  color: var(--ins-quiet);
}
/* The sample keeps each figure on one line (nowrap). Ours carry cents and a currency code, so the longest
   (-1,005,700.00 AUD) is wider than the tile at 28 px: the figure steps down with the tile's own width, never
   above the sample's 28 px, and never wraps its code under it (6 Nov 26 (c), Part 5). */
body.sheet-body:not(.section-viewer) #pr-page .pr-metrics .ins-metric {
  container-type: inline-size;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-metrics .ins-metric-value {
  font-size: min(28px, 10.5cqi);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-code {
  font-size: clamp(11px, 6cqi, 15px); /* D-508: the smallest text is 11 px (10.8 px at 1,280 before) */
  font-weight: 700;
  letter-spacing: 0;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-count-line {
  margin: 0 0 calc(var(--base) * 1);
  font-size: 13px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-count-line + section,
body.sheet-body:not(.section-viewer) #pr-page .pr-count-line[hidden] + section {
  margin-top: calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) #pr-page section + section {
  margin-top: calc(var(--base) * 4.375);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-below > section + section {
  margin-top: 0;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-below {
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  margin-top: calc(var(--base) * 4.375);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-records-section {
  margin-top: calc(var(--base) * 4.375);
}
/* Your portfolio: the sample's .portfolio-grid and .prop-card, its hover lift, ring and fade. */
body.sheet-body:not(.section-viewer) #pr-page .pr-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-card[type] {
  display: block;
  width: 100%;
  min-width: 0;
  padding: 0;
  margin: 0;
  text-align: left;
  font: inherit;
  color: var(--text);
  background: var(--color-card);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-photo-card);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  cursor: pointer;
  transition: transform 0.22s ease, box-shadow 0.22s ease, opacity 0.22s ease;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-card[type]:hover {
  transform: translateY(-5px);
}
body.sheet-body:not(.section-viewer) #pr-page :is(.pr-card[type], .debt-event, .ins-card).dimmed {
  opacity: 0.42;
}
body.sheet-body:not(.section-viewer) #pr-page :is(.pr-card[type], .ins-card).related {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}
body.sheet-body:not(.section-viewer) #pr-page .debt-event.related .debt-event-title {
  color: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-card-image {
  position: relative;
  height: 170px;
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) #pr-page :is(.pr-card-photo, .pr-drawer-art) {
  position: absolute;
  inset: 0;
  display: block;
  overflow: hidden;
}
body.sheet-body:not(.section-viewer) #pr-page :is(.pr-card-photo, .pr-drawer-art) img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-photo-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-photo-tag {
  position: absolute;
  top: 16px;
  left: 16px;
  background: var(--on-photo-fill-34);
  color: var(--on-photo-ink-7);
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.75) calc(var(--base) * 1.25);
  font-size: 11px;
  font-weight: 780;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-photo-arrow {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--on-photo-fill-34);
  color: var(--on-photo-ink-7);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-card-body {
  padding: calc(var(--base) * 2.625) calc(var(--base) * 2.875) calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-titleline {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-titleline > div {
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-card-title {
  font-size: 20px;
  font-weight: 770;
  letter-spacing: -0.4px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-card-place {
  font-size: 11px;
  color: var(--ins-quiet);
  margin-top: calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) #pr-page .ins-status {
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.625) calc(var(--base) * 1.125);
  background: var(--stone);
  color: var(--text);
}
body.sheet-body:not(.section-viewer) #pr-page .ins-status[data-level="ok"] {
  background: var(--fo-success-bg, var(--stone));
  color: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) #pr-page .ins-status[data-level="review"] {
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #pr-page .ins-status[data-level="critical"] {
  background: var(--fo-critical-bg);
  color: var(--fo-critical-accent);
}
body.sheet-body:not(.section-viewer) #pr-page .ins-status[data-level="quiet"] {
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-card-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: calc(var(--base) * 1.25);
  margin: calc(var(--base) * 2.5) 0 calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-metric small {
  display: block;
  font-size: 11px;
  color: var(--ins-quiet);
  margin-bottom: calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-metric b {
  display: block;
  font-size: 17px;
  font-weight: 750;
  letter-spacing: -0.3px;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-valued {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--base);
  margin: 0 0 calc(var(--base) * 1.5);
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-progress {
  height: 7px;
  border-radius: var(--radius-pill);
  background: var(--stone);
  overflow: hidden;
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-progress > i {
  display: block;
  height: 100%;
  border-radius: var(--radius-pill);
  background: var(--color-accent);
  opacity: 0.7;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-card-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--base);
  border-top: 1px solid var(--ins-line);
  padding-top: calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-chips {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 0.75);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-chip {
  background: var(--stone);
  color: var(--text);
  border-radius: var(--radius-small-chip);
  padding: calc(var(--base) * 0.75) var(--base);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-loan-ratio {
  font-size: 11px;
  color: var(--ins-quiet);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-card-note {
  margin: calc(var(--base) * 1.25) 0 0;
  font-size: 11px;
  line-height: 1.5;
  color: var(--ins-quiet);
}
/* What's due: Debt's events, the review family ahead and the critical family only once a date has passed. */
body.sheet-body:not(.section-viewer) #pr-page .debt-event-tag[data-level="critical"] {
  background: var(--fo-critical-bg);
  color: var(--fo-critical-accent);
}
body.sheet-body:not(.section-viewer) #pr-page .debt-event-tag[data-level="review"] {
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
/* Owner return view: the sample's .returnrow and .returnstat. */
body.sheet-body:not(.section-viewer) #pr-page .pr-returnrow {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 1.375);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-returnstat {
  background: var(--stone);
  border-radius: var(--radius-stat-box);
  padding: calc(var(--base) * 1.875);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-returnstat span {
  display: block;
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-returnstat b {
  display: block;
  font-size: 20px;
  font-weight: 750;
  letter-spacing: -0.4px;
  margin: calc(var(--base) * 0.875) 0 calc(var(--base) * 0.625);
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-returnstat b.is-not-recorded {
  font-size: 17px;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-returnstat small {
  display: block;
  font-size: 11px;
  line-height: 1.45;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-mini-note {
  margin: calc(var(--base) * 1.75) 0 0;
  font-size: 11px;
  line-height: 1.55;
  color: var(--ins-quiet);
}
/* Records & evidence: the sample's .records and .record-tile. */
body.sheet-body:not(.section-viewer) #pr-page .pr-records {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record-tile[type] {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--base);
  min-height: 145px;
  min-width: 0;
  padding: calc(var(--base) * 2);
  margin: 0;
  text-align: left;
  font: inherit;
  color: var(--text);
  background: var(--color-card);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-record-tile);
  box-shadow: var(--shadow-card);
  cursor: pointer;
  transition: transform 0.22s ease;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record-tile[type]:hover:not([disabled]) {
  transform: translateY(-3px);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record-icon {
  width: 37px;
  height: 37px;
  border-radius: var(--radius-icon-box-small);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--stone);
  color: var(--color-accent);
  margin-bottom: calc(var(--base) * 0.75);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record-tile b {
  font-size: 13px;
  font-weight: 760;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record-tile > span:last-child {
  font-size: 11px;
  line-height: 1.5;
  color: var(--ins-quiet);
}
/* The panel: the sample's stat grid, records, documents; the profile photograph round. */
body.sheet-body:not(.section-viewer) #pr-page .pr-drawer-photo {
  position: relative;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  overflow: hidden;
  flex: none;
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 1.25);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-stat {
  background: var(--stone);
  border-radius: var(--radius-stat);
  padding: calc(var(--base) * 1.875);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-stat small {
  display: block;
  font-size: 11px;
  color: var(--ins-quiet);
  margin-bottom: calc(var(--base) * 0.75);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-stat b {
  display: block;
  font-size: 17px;
  font-weight: 750;
  letter-spacing: -0.3px;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record {
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-record);
  padding: calc(var(--base) * 1.875);
  margin: 0 0 calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record-head strong {
  display: block;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record-head small {
  display: block;
  font-size: 11px;
  color: var(--ins-quiet);
  margin-top: calc(var(--base) * 0.5);
  line-height: 1.45;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record-pill {
  flex: none;
  background: var(--stone);
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.625) calc(var(--base) * 1.125);
  font-size: 11px;
  font-weight: 750;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-record .ins-detail-row {
  margin-top: calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-doc {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.5);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-record);
  padding: calc(var(--base) * 1.5) calc(var(--base) * 1.875);
  margin: 0 0 calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-doc b {
  font-size: 13px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) #pr-page .pr-doc-icon {
  width: 37px;
  height: 39px;
  flex: none;
  border-radius: var(--radius-doc-icon);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--stone);
  color: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #pr-page .pr-open-link {
  display: inline-flex;
  margin-top: calc(var(--base) * 1.5);
  text-decoration: none;
}
body.sheet-body:not(.section-viewer) #pr-page .ins-drawer :is(.ins-btn[type], a.ins-btn) {
  border: 1px solid var(--border);
  border-radius: var(--radius-panel-button);
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.5);
  background: var(--color-card);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 720;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #pr-page .ins-drawer :is(.ins-btn[type], a.ins-btn):hover {
  border-color: var(--text-muted);
  color: var(--text);
}
body.sheet-body:not(.section-viewer) #pr-page .ins-detail-row strong.is-not-recorded,
body.sheet-body:not(.section-viewer) #pr-page .is-not-recorded {
  color: var(--ins-quiet);
  font-weight: 600;
}
@media (max-width: 1170px) {
  body.sheet-body:not(.section-viewer) #pr-page .pr-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) #pr-page .pr-records {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 820px) {
  body.sheet-body:not(.section-viewer) #pr-page .pr-grid,
  body.sheet-body:not(.section-viewer) #pr-page .pr-below {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 560px) {
  body.sheet-body:not(.section-viewer) #pr-page .ins-hero h2 {
    font-size: 38px;
  }
  body.sheet-body:not(.section-viewer) #pr-page .pr-records,
  body.sheet-body:not(.section-viewer) #pr-page .pr-returnrow {
    grid-template-columns: 1fr;
  }
  body.sheet-body:not(.section-viewer) #pr-page .pr-card-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) #pr-page :is(.ins-hero, .ins-intel) {
    box-shadow: var(--shadow-card);
  }
}

/* ---- Investments, rebuilt from its sample (the brief of 7 Nov 26, Part 2): Family_Office_Investments_Premium_v1_4's
   drawn values, read from the running sample at 1,440 px (D-508; nothing under 11 px), scoped to Investments' own
   container. The rulings win: Georgia headings at regular weight; forest for the sample's accents; amber, never red,
   for an item to review (red is for passed dates only); figures in tabular numerals. */
body.sheet-body:not(.section-viewer) #inv-page {
  font-size: 15px;
  line-height: 1.5;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-photo-hero {
  /* Its own photograph (D-516; app/photo-credits.md): a facade in golden light, the dark sky behind the heading; the
     forest fade keeps the words at 4.5:1. */
  background-image: linear-gradient(95deg, var(--on-photo-fill), var(--on-photo-fill-2) 52%, var(--on-photo-fill-3)), url("/photos/investments-hero-golden-facade.webp");
  background-size: cover;
  background-position: center 40%;
  min-height: 284px;
  border-radius: var(--radius-photo-hero);
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) #inv-page .ins-heroinner {
  padding: calc(var(--base) * 4.25) calc(var(--base) * 5.25);
}
body.sheet-body:not(.section-viewer) #inv-page .ins-hero .ins-eyebrow {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 2.2px;
  margin: 0 0 calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #inv-page .ins-hero h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 57px;
  line-height: 1.12;
  letter-spacing: -1.5px;
  color: var(--on-photo-ink-8);
  margin: 0 0 calc(var(--base) * 1.5);
  max-width: 760px;
}
body.sheet-body:not(.section-viewer) #inv-page .ins-hero p {
  font-size: 17px;
  line-height: 1.5;
  max-width: 620px;
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-hero-note {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  color: var(--on-photo-ink-2);
  background: var(--on-photo-fill-35);
  border: 1px solid var(--on-photo-line-6);
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.875) calc(var(--base) * 1.75);
}
/* The six tabs in the sample's style (Avi's check of build f1a1a7d9, Investments step 2; values from
   Family_Office_Investments_Premium_v1_4.html .tabs/.tab): words on a thin rule, the chosen tab dark with a 3 px
   forest underline in place of the sample's navy; hover on the sample's soft ground. Only this row; the shared pill
   elsewhere is untouched (#inv-tabs outranks it). */
body.sheet-body:not(.section-viewer) #inv-page #inv-tabs {
  display: flex;
  flex-wrap: nowrap;
  overflow-x: auto;
  gap: calc(var(--base) * 0.75);
  margin: 0 0 calc(var(--base) * 2);
  padding: 0;
  border: 0;
  border-bottom: 1px solid var(--ins-line);
  border-radius: 0;
  background: transparent;
  scrollbar-width: thin;
}
body.sheet-body:not(.section-viewer) #inv-page #inv-tabs > button[type] {
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.2;
  padding: calc(var(--base) * 1.625) calc(var(--base) * 2.125) calc(var(--base) * 1.5);
  min-height: 44px;
  border: 0;
  border-bottom: 3px solid transparent;
  border-radius: 0;
  background: transparent;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #inv-page #inv-tabs > button[type]:hover {
  color: var(--text);
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) #inv-page #inv-tabs > button[type][aria-selected="true"] {
  color: var(--text);
  background: transparent;
  border-bottom-color: var(--forest-2);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-panel[hidden] {
  display: none;
}
/* The action for review: amber, its words carrying its status. */
body.sheet-body:not(.section-viewer) #inv-page .inv-priority {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2.5);
  padding: calc(var(--base) * 3.125) calc(var(--base) * 3.375) calc(var(--base) * 3.125) calc(var(--base) * 3.125);
  border-radius: var(--radius-review);
  border: 2px solid var(--fo-review-border);
  background: var(--fo-review-bg);
  margin: 0 0 calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority[data-level="calm"] {
  border-color: var(--ins-line);
  background: var(--paper);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority-label {
  display: flex;
  align-items: center;
  gap: var(--base);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority[data-level="calm"] .inv-priority-label {
  color: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-dot {
  display: inline-grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--fo-review-accent);
  color: var(--fo-review-cta-text);
  font-size: 12px;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority[data-level="calm"] .inv-dot {
  background: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 32px;
  line-height: 1.2;
  color: var(--fo-review-title);
  margin: calc(var(--base) * 1.25) 0 var(--base);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority[data-level="calm"] h2 {
  color: var(--text);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority p {
  margin: 0 0 var(--base);
  color: var(--text);
  max-width: 720px;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority-evidence {
  font-size: 12px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority-aside {
  display: grid;
  gap: var(--base);
  justify-items: center;
  text-align: center;
  flex: 0 0 275px;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority-aside small {
  font-size: 11px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-priority-button[type] {
  width: 275px;
  max-width: 100%;
  padding: calc(var(--base) * 2.125) calc(var(--base) * 2.25);
  border-radius: var(--radius-button);
  font-size: 14px;
  font-weight: 800;
  background: var(--fo-review-accent);
  border-color: var(--fo-review-accent);
  color: var(--fo-review-cta-text);
}
/* The figures: four cards and the strip under them. */
body.sheet-body:not(.section-viewer) #inv-page .inv-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-metric {
  min-height: 158px;
  padding: calc(var(--base) * 2.375) calc(var(--base) * 2.5) calc(var(--base) * 2.25);
  border-radius: var(--radius-metric);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-metric.featured {
  border-color: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-metric .ins-metric-heading {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-metric .ins-metric-value {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 28px;
  line-height: 1.2;
  margin-top: calc(var(--base) * 1.5);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-metric .ins-metric-tail {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: calc(var(--base) * 1);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-strip {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  align-items: center;
  gap: calc(var(--base) * 2);
  min-height: 71px;
  padding: calc(var(--base) * 1.5) calc(var(--base) * 2.5);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-record-tile);
  background: var(--paper);
  margin: 0 0 calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-strip span {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-strip strong {
  font-size: 17px;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-strip-switch {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-strip-switch > span {
  display: inline;
}
/* The currency switch: the Appearance switch's look, restated as Income does, since the page's own button rule would
   otherwise undo it. */
body.sheet-body:not(.section-viewer) #inv-page .inv-switch {
  display: inline-flex;
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-switch > button[type] {
  padding: var(--base) calc(var(--base) * 2);
  border-radius: var(--radius-switch-button);
  background: transparent;
  border: 0;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  min-height: 0;
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-switch > button[type][aria-pressed="true"] {
  background: var(--color-accent);
  color: var(--plus-ink);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-rate-line {
  font-size: 13px;
  color: var(--fo-review-title);
  background: var(--fo-review-bg);
  border-radius: var(--radius-detail-button);
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.75);
  margin: 0 0 calc(var(--base) * 2);
}
/* Cards, heads and grids. */
body.sheet-body:not(.section-viewer) #inv-page .inv-grid-2 {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: calc(var(--base) * 2.25); /* 18 px, the Investments sample's grid-2 (D-569's layout standard, D-508) */
  margin: calc(var(--base) * 2.5) 0;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-grid-even {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--base) * 2.5);
  margin: 0 0 calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-card {
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: calc(var(--base) * 3);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-card + .inv-card {
  margin-top: 0;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-lab > div > .inv-card + .inv-card {
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #inv-page :is(.inv-card, .inv-panel) h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 24px;
  line-height: 1.25;
  margin: 0 0 calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-section-head p,
body.sheet-body:not(.section-viewer) #inv-page .inv-caption {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-section {
  margin: calc(var(--base) * 3) 0;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.625) calc(var(--base) * 1.25);
  background: var(--stone);
  color: var(--text);
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-pill[data-level="ok"] {
  background: var(--fo-success-bg);
  color: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-pill[data-level="review"] {
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
/* Investment Intelligence and Action & Assurance. */
body.sheet-body:not(.section-viewer) #inv-page .inv-insight {
  display: grid;
  grid-template-columns: 38px 1fr auto;
  gap: calc(var(--base) * 1.5);
  align-items: start;
  padding: calc(var(--base) * 1.875) 0;
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-insight-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-detail-button);
  background: var(--stone);
  color: var(--color-accent);
  font-size: 17px;
}
body.sheet-body:not(.section-viewer) #inv-page :is(.inv-insight, .inv-action-row) h3 {
  font-size: 15px;
  font-weight: 400; /* D-497: Georgia headings at regular weight (the overnight brief of 18-19 Nov 26, Part 8b) */
  line-height: 1.35;
  margin: 0 0 calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #inv-page :is(.inv-insight, .inv-action-row) p {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-muted);
  margin: 0;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-action-row {
  display: grid;
  grid-template-columns: 10px 1fr;
  gap: calc(var(--base) * 1.5);
  padding: calc(var(--base) * 1.625) 0;
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-bullet {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  margin-top: calc(var(--base) * 0.75);
  background: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-bullet[data-level="review"] {
  background: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-bullet[data-level="ok"] {
  background: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-bullet[data-level="info"] {
  background: var(--fo-info-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-textbtn[type] {
  background: none;
  border: 0;
  padding: calc(var(--base) * 0.75) 0 0;
  min-height: 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--color-accent);
  cursor: pointer;
}
/* "Review →" in the house amber, "Open the holding →" in forest (Avi's check of build f1a1a7d9, Investments step 4). */
body.sheet-body:not(.section-viewer) #inv-page .inv-textbtn.is-review[type] {
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-notice {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text);
  background: var(--stone);
  border-radius: var(--radius-stat-box);
  padding: calc(var(--base) * 1.5) calc(var(--base) * 1.75);
  margin-top: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-placeholder {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-muted);
  border: 1px dashed var(--ins-line);
  border-radius: var(--radius-stat-box);
  padding: calc(var(--base) * 2);
  margin: calc(var(--base) * 1.5) 0;
}
/* Buttons: forest outline; the primary filled forest. */
body.sheet-body:not(.section-viewer) #inv-page .inv-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: calc(var(--base) * 0.75);
  min-height: 40px;
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.875);
  border-radius: var(--radius-detail-button);
  border: 1px solid var(--ins-line);
  background: var(--paper);
  color: var(--color-accent);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-button.primary {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: var(--inv-primary-ink);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-btnrow {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  margin-top: calc(var(--base) * 1.75);
}
/* Underlying holdings: the search, the table. */
body.sheet-body:not(.section-viewer) #inv-page .inv-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  align-items: center;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-search {
  min-height: 40px;
  width: 220px;
  padding: var(--base) calc(var(--base) * 1.75);
  border-radius: var(--radius-detail-button);
  border: 1px solid var(--ins-line);
  background: var(--paper);
  color: var(--text);
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-table-card {
  padding: calc(var(--base) * 0.875) calc(var(--base) * 0.875) calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-table-wrap {
  overflow-x: auto;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-table {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-table th {
  font-size: 11px;
  font-weight: 700;
  text-align: left;
  color: var(--text-muted);
  background: var(--stone);
  padding: calc(var(--base) * 1.625) calc(var(--base) * 1.5);
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-table td {
  font-size: 13px;
  padding: calc(var(--base) * 1.625) calc(var(--base) * 1.5);
  border-bottom: 1px solid var(--ins-line);
  vertical-align: top;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-table :is(th, td).right {
  text-align: right;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-table tbody tr:hover {
  background: color-mix(in srgb, var(--color-accent) 6%, transparent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-row-open[type] {
  display: block;
  text-align: left;
  background: none;
  border: 0;
  padding: 0;
  min-height: 0;
  color: inherit;
  font: inherit;
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-row-open[type]:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: var(--radius-tab-inner);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-item-main {
  display: block;
  font-weight: 700;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-item-sub {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-muted {
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-empty {
  color: var(--text-muted);
  text-align: center;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-nowrap {
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-tiny {
  font-size: 12px;
  color: var(--text-muted);
  margin: var(--base) 0 0;
}
/* The leaderboard: each holding's share of its currency, a forest bar (decoration; the figure is its words). */
body.sheet-body:not(.section-viewer) #inv-page .inv-board-currency {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  margin: calc(var(--base) * 1.75) 0 calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-rank-row {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) 60px;
  gap: calc(var(--base) * 1.25);
  align-items: center;
  padding: var(--base) 0;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-bar {
  height: 10px;
  border-radius: var(--radius-pill);
  background: var(--stone);
  overflow: hidden;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-bar > span {
  display: block;
  height: 100%;
  background: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-rank-row b {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
/* Pairs, fields and the lab. */
body.sheet-body:not(.section-viewer) #inv-page .inv-pair,
body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-pair {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 1.75);
  padding: calc(var(--base) * 1.25) 0;
  border-bottom: 1px solid var(--ins-line);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-pair > b {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-field {
  display: grid;
  gap: calc(var(--base) * 0.75);
  margin: calc(var(--base) * 1.5) 0;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-field > * {
  margin: 0;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-field label {
  font-size: 13px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) #inv-page :is(.inv-select, .inv-field input[type="text"]) {
  min-height: 44px;
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.5);
  border-radius: var(--radius-detail-button);
  border: 1px solid var(--ins-line);
  background: var(--paper);
  color: var(--text);
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-field input[type="range"] {
  accent-color: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-lab {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--base) * 2.5);
  align-items: start;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-lab-note {
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-projection {
  background: var(--stone);
  border-radius: var(--radius-record-tile);
  padding: calc(var(--base) * 2.25);
  margin: 0 0 calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-kicker {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #inv-page .inv-big {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 31px;
  line-height: 1.25;
  font-variant-numeric: tabular-nums;
  margin: calc(var(--base) * 0.75) 0;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-error {
  font-size: 13px;
  color: var(--color-red);
  margin: calc(var(--base) * 0.75) 0;
}
/* The holding's panel. */
body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-drawer-title {
  /* D-536 (1): the Income source panel's title, Georgia 38 px (28 px before 11 Nov 26). */
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 38px;
  line-height: 1.05;
  letter-spacing: -0.5px;
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-drawer-sub {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-drawer-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: calc(var(--base) * 1.25);
  margin: 0 0 calc(var(--base) * 1.75);
}
body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: calc(var(--base) * 1.75) 0 calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-placeholder {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text-muted);
  border: 1px dashed var(--ins-line);
  border-radius: var(--radius-stat-box);
  padding: calc(var(--base) * 2);
  margin: calc(var(--base) * 1.5) 0;
}
body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-btnrow {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-button {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.875);
  border-radius: var(--radius-detail-button);
  border: 1px solid var(--ins-line);
  background: var(--paper);
  color: var(--color-accent);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-tiny {
  font-size: 12px;
  color: var(--text-muted);
  margin: calc(var(--base) * 1.5) 0 0;
}
@media (max-width: 1100px) {
  body.sheet-body:not(.section-viewer) #inv-page .inv-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) #inv-page .inv-strip {
    grid-template-columns: 1fr 1fr 1fr;
  }
  body.sheet-body:not(.section-viewer) #inv-page .inv-strip-switch {
    grid-column: 1 / -1;
  }
}
@media (max-width: 820px) {
  body.sheet-body:not(.section-viewer) #inv-page :is(.inv-grid-2, .inv-grid-even, .inv-lab) {
    grid-template-columns: 1fr;
  }
  body.sheet-body:not(.section-viewer) #inv-page .inv-priority {
    flex-direction: column;
    align-items: stretch;
  }
  body.sheet-body:not(.section-viewer) #inv-page .inv-priority-aside {
    flex: none;
  }
  body.sheet-body:not(.section-viewer) #inv-page .inv-section-head {
    flex-direction: column;
  }
}
@media (max-width: 560px) {
  body.sheet-body:not(.section-viewer) #inv-page .ins-hero h2 {
    font-size: 38px;
  }
  body.sheet-body:not(.section-viewer) #inv-page .ins-heroinner {
    padding: calc(var(--base) * 3) calc(var(--base) * 2.75);
  }
  body.sheet-body:not(.section-viewer) #inv-page .inv-strip {
    grid-template-columns: 1fr;
  }
  body.sheet-body:not(.section-viewer) #inv-page .inv-priority h2 {
    font-size: 26px;
  }
  /* The phone round of 7 Nov 26: at 28 px and nowrap a figure ran out of its 171 px tile and off the side; 20 px as on
     Goals and Insurance, and wrapping allowed for words such as "None recorded". */
  body.sheet-body:not(.section-viewer) #inv-page .inv-metric .ins-metric-value {
    font-size: 20px;
    white-space: normal;
  }
  body.sheet-body:not(.section-viewer) #inv-page .inv-search {
    width: 100%;
  }
  body.sheet-body:not(.section-viewer) #inv-page .inv-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
  }
  body.sheet-body:not(.section-viewer) #inv-page .inv-tabs > button[type] {
    flex: 0 0 auto;
  }
  /* The sample's phone size for the tab row (v1.4 .tab at its narrow width: 11px 13px, 11 px words). */
  body.sheet-body:not(.section-viewer) #inv-page #inv-tabs {
    margin-bottom: calc(var(--base) * 1.75);
  }
  body.sheet-body:not(.section-viewer) #inv-page #inv-tabs > button[type] {
    padding: calc(var(--base) * 1.375) calc(var(--base) * 1.625);
    font-size: 11px;
  }
}

/* ---- What's Due, rebuilt from its sample (the brief of 7 Nov 26, Part 3): Family-Office v1.1's whats-due
   02-current-design, its drawn values read from the running sample at 1,440 px (D-508; nothing under 11 px), v1.4
   winning where the two disagree, scoped to the page's own container. The rulings win: Georgia headings at regular
   weight; forest for the sample's accents; red only for a passed date, amber for review; figures in tabular numerals. */
body.sheet-body:not(.section-viewer) #due-page {
  font-size: 15px;
  line-height: 1.52;
}
body.sheet-body:not(.section-viewer) #due-page .due-photo-hero {
  /* Its own photograph (D-516; app/photo-credits.md), laid as an image so a missing one falls back to the forest: the
     deep forest of the other photo heroes, fixed in both modes (the accent turns pale green in dark, behind white words). */
  background-image: none;
  background-color: var(--on-photo-fill-7);
  min-height: 355px;
  border-radius: var(--radius-photo-hero);
  margin: calc(var(--base) * 3) 0 0;
  align-items: center;
}
body.sheet-body:not(.section-viewer) #due-page .due-hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 52%;
  z-index: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-photo-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(90deg, var(--on-photo-fill-36) 0%, var(--on-photo-fill-37) 34%, var(--on-photo-fill-38) 70%, var(--on-photo-fill-39) 100%);
}
body.sheet-body:not(.section-viewer) #due-page .ins-heroinner {
  padding: calc(var(--base) * 7.5) calc(var(--base) * 5.75) calc(var(--base) * 7.5);
}
body.sheet-body:not(.section-viewer) #due-page .ins-hero .ins-eyebrow {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 2.4px;
  color: var(--on-photo-ink-9);
  margin: 0 0 calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) #due-page .ins-hero h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 57.6px; /* Insurance's heading size (Avi's check of build f1a1a7d9, step 6). */
  line-height: 1.12;
  letter-spacing: -2px;
  color: var(--on-photo-ink-2);
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) #due-page .due-period {
  color: var(--due-period-ink);
}
body.sheet-body:not(.section-viewer) #due-page .ins-hero p {
  font-size: 20px;
  line-height: 1.5;
  color: var(--on-photo-ink-10);
  max-width: 620px;
  margin: 0;
}
body.sheet-body:not(.section-viewer) #due-page .ins-hero p.due-hero-caption {
  font-size: 11px;
  letter-spacing: 1.3px;
  color: var(--on-photo-ink-11);
  /* Under the chips since the brief of 12 Nov 26, Part 5 (D-544 (2)): the chips sit under the line as Insurance's do. */
  margin: calc(var(--base) * 2) 0 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-hero-note {
  display: inline-block;
  font-size: 12px;
  font-weight: 600;
  color: var(--on-photo-ink-2);
  background: var(--on-photo-fill-35);
  border: 1px solid var(--on-photo-line-6);
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.875) calc(var(--base) * 1.75);
}

/* v1.4's four counts, the summary cards after the attention section (D-520; off the photograph). */
body.sheet-body:not(.section-viewer) #due-page .due-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: calc(var(--base) * 1.5);
  margin: 0 0 calc(var(--base) * 3);
  position: relative;
  z-index: 1;
}
body.sheet-body:not(.section-viewer) #due-page .due-metrics[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) #due-page .due-metric[type] {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: calc(var(--base) * 0.625);
  min-height: 114px;
  padding: calc(var(--base) * 2.25) calc(var(--base) * 2.125);
  border-radius: var(--radius-metric);
  text-align: left;
  color: var(--text);
  cursor: pointer;
  font: inherit;
}
body.sheet-body:not(.section-viewer) #due-page .due-metric.is-urgent[type] {
  background: var(--fo-action-bg);
  border-color: var(--fo-action-border);
}
body.sheet-body:not(.section-viewer) #due-page .due-metric .ins-metric-heading {
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.2px;
}
body.sheet-body:not(.section-viewer) #due-page .due-metric .ins-metric-value {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 38px;
  line-height: 1;
  margin: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-metric.is-urgent .ins-metric-value {
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-metric[data-metric="waiting"] .ins-metric-value {
  font-size: 28px;
}
body.sheet-body:not(.section-viewer) #due-page .due-metric .ins-metric-tail {
  font-size: 11px;
  margin: 0;
}

/* Section headings, as the sample's toolbars. */
body.sheet-body:not(.section-viewer) #due-page .due-section {
  margin: calc(var(--base) * 4.5) 0 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-toolbar {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: calc(var(--base) * 2.5);
  margin: var(--base) 0 calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) #due-page .due-eyebrow {
  font-size: 11px;
  letter-spacing: 2.4px;
  font-weight: 780;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #due-page .due-toolbar h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 38px;
  line-height: 1.12;
  margin: calc(var(--base) * 0.75) 0 calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) #due-page .due-toolbar p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-link[type] {
  border: 0;
  background: transparent;
  color: var(--color-accent);
  font-size: 13px;
  font-weight: 750;
  padding: 0;
  min-height: 0;
  white-space: nowrap;
  text-align: left;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) #due-page .due-link[type]:hover {
  text-decoration: underline;
}

/* Requires your attention: three cards; a passed date carries the red rail and its words. */
body.sheet-body:not(.section-viewer) #due-page .due-attention-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #due-page .due-attention {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 1.125);
  min-height: 250px;
  min-width: 0;
  padding: calc(var(--base) * 2.625) calc(var(--base) * 2.5);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) #due-page .due-attention.is-past {
  border-left: 4px solid var(--fo-action-accent);
  background: var(--fo-action-bg);
}
body.sheet-body:not(.section-viewer) #due-page .due-attention h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 28px;
  line-height: 1.12;
  margin: 0;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #due-page .due-attention p {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-muted);
  margin: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-attention .due-smallcap {
  font-size: 11px;
  letter-spacing: 1.1px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-attention .due-smallcap.is-past {
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-card-bottom {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 1.25);
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) #due-page .due-small[type] {
  border: 1px solid var(--ins-line);
  background: var(--paper);
  color: var(--color-accent);
  border-radius: var(--radius-detail-button);
  padding: var(--base) calc(var(--base) * 2);
  font-size: 12px;
  font-weight: 750;
  min-height: 36px;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) #due-page .due-small.is-primary[type] {
  background: var(--fo-action-accent);
  border-color: var(--fo-action-accent);
  color: var(--fo-action-cta-text);
}

/* The pills: each status in words, its tone one meaning only. */
body.sheet-body:not(.section-viewer) #due-page .due-badges {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 0.625);
  margin: var(--base) 0 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-pill {
  display: inline-block;
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.5) calc(var(--base) * 1.125);
  font-size: 11px;
  font-weight: 750;
  background: color-mix(in srgb, var(--border) 30%, var(--paper));
  color: var(--text);
}
body.sheet-body:not(.section-viewer) #due-page .due-pill.is-danger {
  background: var(--fo-action-bg);
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-pill.is-review {
  background: var(--fo-review-bg);
  color: var(--fo-review-title);
}
body.sheet-body:not(.section-viewer) #due-page .due-pill.is-info {
  background: var(--fo-info-bg);
  color: var(--text);
}
body.sheet-body:not(.section-viewer) #due-page .due-pill.is-success {
  background: var(--fo-success-bg);
  color: var(--text);
}

/* Upcoming actions and the side column. */
body.sheet-body:not(.section-viewer) #due-page .due-work {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(270px, 0.8fr);
  gap: calc(var(--base) * 2.375);
  margin: calc(var(--base) * 4) 0 0;
}
body.sheet-body:not(.section-viewer) #due-page :is(.due-work-main, .due-work-side) {
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-filters {
  display: grid;
  grid-template-columns: minmax(190px, 1.8fr) minmax(140px, 1fr);
  gap: calc(var(--base) * 0.875);
  margin: 0 0 calc(var(--base) * 1.875);
}
body.sheet-body:not(.section-viewer) #due-page .due-search {
  display: flex;
  align-items: center;
  gap: var(--base);
  padding: 0 calc(var(--base) * 1.5);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-button);
  background: var(--paper);
}
body.sheet-body:not(.section-viewer) #due-page .due-search span {
  font-size: 22px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #due-page .due-search input {
  min-width: 0;
  width: 100%;
  padding: calc(var(--base) * 1.5) 0;
  border: 0;
  outline: none;
  background: transparent;
  font-size: 13px;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) #due-page .due-search:focus-within {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}
body.sheet-body:not(.section-viewer) #due-page .due-filters select {
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-button);
  padding: calc(var(--base) * 1.375) var(--base);
  color: var(--text);
  font-size: 13px;
  min-width: 0;
}
/* The brief of 11 Nov 26, Part 21: the filter row by area, one pill per area with its count, wrapping on a narrow
   screen; the chosen one in the accent, as the page's other switches. */
body.sheet-body:not(.section-viewer) #due-page .due-areas.ins-tabs {
  flex-wrap: wrap;
  gap: var(--base);
  width: auto;
  border: 0;
  background: transparent;
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #due-page .due-areas.ins-tabs > button[type] {
  border: 1px solid var(--ins-line);
  background: var(--paper);
}
body.sheet-body:not(.section-viewer) #due-page .due-areas.ins-tabs > button[type][aria-pressed="true"] {
  border-color: var(--color-accent);
  background: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-switches {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 1.5);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #due-page .due-views {
  margin: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-grouping {
  margin: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-panel[hidden] {
  display: none;
}

/* The timeline's bands: a heading bar with its dot and count, then each item as the sample's row. */
body.sheet-body:not(.section-viewer) #due-page .due-window {
  margin: 0 0 var(--base);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-record-tile);
  overflow: hidden;
}
body.sheet-body:not(.section-viewer) #due-page .due-group-head {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.625);
  padding: calc(var(--base) * 2) calc(var(--base) * 2.25);
  background: linear-gradient(90deg, color-mix(in srgb, var(--border) 20%, var(--paper)), var(--paper));
}
body.sheet-body:not(.section-viewer) #due-page .due-window.is-past .due-group-head {
  background: linear-gradient(90deg, var(--fo-action-bg), var(--paper));
}
body.sheet-body:not(.section-viewer) #due-page .due-group-head h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 20px;
  line-height: 1.2;
  margin: 0;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) #due-page .due-group-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--due-group-dot-fill);
  flex: none;
}
body.sheet-body:not(.section-viewer) #due-page .due-window.is-past .due-group-dot {
  background: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-group-count {
  margin-left: auto;
  color: var(--text-muted);
  font-size: 11px;
}
body.sheet-body:not(.section-viewer) #due-page .due-row {
  position: relative;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  align-items: start;
  gap: calc(var(--base) * 1.875);
  padding: calc(var(--base) * 2) calc(var(--base) * 2.25);
  border-top: 1px solid var(--ins-line);
  background: var(--paper);
  margin: 0;
  border-radius: 0;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) #due-page .due-row:hover {
  background: color-mix(in srgb, var(--color-accent) 4%, var(--paper));
}
body.sheet-body:not(.section-viewer) #due-page .due-row > .card-open {
  position: absolute;
  inset: 0;
  z-index: 1;
  width: 100%;
  height: 100%;
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) #due-page .due-row > .card-open:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: -2px;
}
body.sheet-body:not(.section-viewer) #due-page .due-chip {
  display: grid;
  justify-items: center;
  min-width: 62px;
  padding: calc(var(--base) * 0.75) calc(var(--base) * 0.625);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-stat-box);
  background: color-mix(in srgb, var(--border) 18%, var(--paper));
  line-height: 1.2;
}
body.sheet-body:not(.section-viewer) #due-page .due-chip.is-past {
  background: var(--fo-action-bg);
  border-color: var(--fo-action-border);
}
body.sheet-body:not(.section-viewer) #due-page .due-chip-month {
  font-size: 11px;
  letter-spacing: 1px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #due-page .due-chip-day {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 28px;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #due-page .due-chip.is-past .due-chip-day {
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-row-copy {
  min-width: 0;
}
/* The quality session of 21 Nov 26 (D-629, PAGE-RULES.md section 2): an item's title is its name line in the system
   font at the body size and 600, never a large Georgia heading (the sample drew it in Georgia at 20 px). */
body.sheet-body:not(.section-viewer) #due-page .due-row .group-name {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-weight: 600;
  font-size: var(--size-body);
  line-height: 1.3;
  margin: 0 0 calc(var(--base) * 0.25);
  color: var(--text);
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #due-page .due-meta {
  font-size: 11px;
  color: var(--text-muted);
  margin: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-next {
  font-size: 13px;
  color: var(--text);
  margin: var(--base) 0 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-row .due-autopay,
body.sheet-body:not(.section-viewer) #due-page .due-row .due-plan {
  margin: calc(var(--base) * 0.75) 0 0;
  font-size: 12px;
}
body.sheet-body:not(.section-viewer) #due-page .due-row-go {
  align-self: center;
  font-size: 12px;
  font-weight: 750;
  color: var(--color-accent);
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #due-page .due-empty {
  border: 1px dashed var(--ins-line);
  padding: calc(var(--base) * 2.75);
  border-radius: var(--radius-record-tile);
  color: var(--text-muted);
  background: var(--paper);
  font-size: 13px;
  margin: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-fold {
  margin: 0 0 var(--base);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-record-tile);
  overflow: hidden;
}
body.sheet-body:not(.section-viewer) #due-page .due-fold > summary {
  padding: calc(var(--base) * 2) calc(var(--base) * 2.25);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  font-weight: 400;
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) #due-page .due-help {
  font-size: 12px;
  color: var(--text-muted);
  margin: var(--base) 0 calc(var(--base) * 2);
}

/* The side column's cards, the month at a glance and the big calendar. */
body.sheet-body:not(.section-viewer) #due-page .due-card {
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  background: var(--paper);
  padding: calc(var(--base) * 2.5);
  margin: 0 0 calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) #due-page .due-card h3,
body.sheet-body:not(.section-viewer) #due-page .due-calendar-big h3 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 28px;
  line-height: 1.12;
  margin: calc(var(--base) * 0.5) 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #due-page .due-card p {
  font-size: 12px;
  color: var(--text-muted);
  margin: calc(var(--base) * 1.5) 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-guard {
  background: color-mix(in srgb, var(--color-accent) 8%, var(--paper));
}
body.sheet-body:not(.section-viewer) #due-page .due-panel-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}
body.sheet-body:not(.section-viewer) #due-page .due-icon[type] {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  min-height: 36px;
  padding: 0;
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-detail-button);
  background: var(--paper);
  color: var(--color-accent);
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) #due-page :is(.due-cal-weekdays, .due-cal-grid) {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  text-align: center;
  gap: calc(var(--base) * 0.625);
}
body.sheet-body:not(.section-viewer) #due-page .due-cal-weekdays {
  font-size: 11px;
  font-weight: 800;
  color: var(--text-muted);
  margin: 0 0 calc(var(--base) * 1.125);
}
body.sheet-body:not(.section-viewer) #due-page .due-cal-day[type] {
  position: relative;
  display: grid;
  place-items: center;
  height: 35px;
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--text);
  font-size: 11px;
  font-weight: 400;
  box-shadow: none;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #due-page .due-cal-day.has-items[type] {
  background: var(--fo-review-bg);
}
body.sheet-body:not(.section-viewer) #due-page .due-cal-day.has-items::after {
  content: "";
  position: absolute;
  bottom: 3px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-cal-day.is-past[type] {
  background: var(--fo-action-bg);
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-cal-day.is-past::after {
  background: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-cal-day.is-today[type] {
  outline: 1px solid var(--color-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-cal-day.is-chosen[type] {
  outline: 3px solid var(--color-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-cal-day[type]:hover {
  background: color-mix(in srgb, var(--color-accent) 10%, var(--paper));
}
body.sheet-body:not(.section-viewer) #due-page .due-calendar-big {
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  padding: calc(var(--base) * 2.75);
  background: var(--paper);
}
body.sheet-body:not(.section-viewer) #due-page .due-calendar-big .due-cal-day[type] {
  height: 64px;
  border-radius: var(--radius-stat-box);
  border: 1px solid var(--ins-line);
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) #due-page .due-calendar-big .due-cal-weekdays {
  font-size: 12px;
}
body.sheet-body:not(.section-viewer) #due-page .due-month-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2.5);
  margin: calc(var(--base) * 1.5) 0 calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) #due-page .due-month-row h3 {
  margin: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-calendar-big .due-month-list-heading {
  font-size: 20px;
  margin: calc(var(--base) * 2.5) 0 calc(var(--base) * 1.625);
  padding-top: calc(var(--base) * 2.5);
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) #due-page #due-month-list .due-row {
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-stat-box);
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) #due-page .due-date-line {
  display: flex;
  gap: calc(var(--base) * 1.375);
  align-items: flex-start;
  padding: calc(var(--base) * 1.5) 0;
  border-top: 1px solid var(--ins-line);
  font-size: 12px;
}
body.sheet-body:not(.section-viewer) #due-page .due-date-num {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  width: 58px;
  flex: none;
  color: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-date-line .due-link[type] {
  white-space: normal;
}
body.sheet-body:not(.section-viewer) #due-page .due-date-line p.due-meta {
  margin: calc(var(--base) * 0.25) 0 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-audit {
  position: relative;
  border-left: 2px solid color-mix(in srgb, var(--color-accent) 35%, var(--paper));
  margin-left: var(--base);
  padding: 0 0 calc(var(--base) * 2.625) calc(var(--base) * 2.375);
}
body.sheet-body:not(.section-viewer) #due-page .due-audit::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 4px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-audit p {
  margin: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-audit .due-audit-event {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  margin: calc(var(--base) * 0.375) 0;
}

/* The four tiles. */
body.sheet-body:not(.section-viewer) #due-page .due-features {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: calc(var(--base) * 1.375);
  margin: calc(var(--base) * 4) 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #due-page .due-feature[type] {
  display: flex;
  align-items: flex-start;
  gap: calc(var(--base) * 1.5);
  min-width: 0;
  padding: calc(var(--base) * 2.875) calc(var(--base) * 2);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  background: var(--paper);
  color: var(--text);
  text-align: left;
  font: inherit;
  box-shadow: none;
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) #due-page .due-feature[type]:hover {
  border-color: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-feature-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 43px;
  height: 43px;
  border-radius: var(--radius-detail-button);
  background: color-mix(in srgb, var(--color-accent) 10%, var(--paper));
  color: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #due-page .due-feature-copy {
  display: grid;
  gap: calc(var(--base) * 0.75);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #due-page .due-feature-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  line-height: 1.12;
}
body.sheet-body:not(.section-viewer) #due-page .due-feature-text {
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #due-page .due-feature-go {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #due-page #read-at {
  margin: 0 0 calc(var(--base) * 2);
}

/* The panels' eyebrow and closing note. */
body.sheet-body:not(.section-viewer) :is(#due-sheet, #due-info-sheet) .due-sheet-eyebrow {
  font-size: 11px;
  letter-spacing: 2.4px;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) :is(#due-sheet, #due-info-sheet) .due-sheet-note {
  font-size: 12px;
  color: var(--text);
  background: color-mix(in srgb, var(--color-accent) 8%, var(--paper));
  border-left: 3px solid var(--color-accent);
  border-radius: var(--radius-tab-inner);
  padding: calc(var(--base) * 1.75);
  margin: calc(var(--base) * 2) 0;
}
body.sheet-body:not(.section-viewer) #due-info-sheet .due-sheet-title {
  font-size: 38px;
}

@media (max-width: 1280px) {
  body.sheet-body:not(.section-viewer) #due-page .due-work {
    grid-template-columns: minmax(0, 1.45fr) minmax(250px, 0.8fr);
  }
  body.sheet-body:not(.section-viewer) #due-page .due-features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) #due-page .due-filters {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) #due-page .due-search {
    grid-column: 1 / -1;
  }
}
@media (max-width: 880px) {
  body.sheet-body:not(.section-viewer) #due-page .due-work {
    grid-template-columns: minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) #due-page .due-attention-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) #due-page .due-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin: 0 0 calc(var(--base) * 3);
  }
  body.sheet-body:not(.section-viewer) #due-page .ins-hero h2 {
    font-size: 57px;
  }
}
@media (max-width: 560px) {
  body.sheet-body:not(.section-viewer) #due-page .due-photo-hero {
    min-height: 260px;
  }
  body.sheet-body:not(.section-viewer) #due-page .ins-heroinner {
    padding: calc(var(--base) * 3.5) calc(var(--base) * 2.5) calc(var(--base) * 5);
  }
  body.sheet-body:not(.section-viewer) #due-page .ins-hero h2 {
    font-size: 52px;
  }
  body.sheet-body:not(.section-viewer) #due-page .ins-hero p {
    font-size: 15px;
  }
  body.sheet-body:not(.section-viewer) #due-page .due-metrics {
    gap: calc(var(--base) * 0.75);
    margin: 0 0 calc(var(--base) * 2.5);
  }
  body.sheet-body:not(.section-viewer) #due-page .due-metric[type] {
    min-height: 86px;
    padding: calc(var(--base) * 1.5) calc(var(--base) * 1.25);
  }
  body.sheet-body:not(.section-viewer) #due-page .due-metric .ins-metric-value {
    font-size: 28px;
  }
  body.sheet-body:not(.section-viewer) #due-page .due-toolbar {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--base);
  }
  body.sheet-body:not(.section-viewer) #due-page .due-toolbar h2 {
    font-size: 28px;
  }
  body.sheet-body:not(.section-viewer) #due-page .due-attention-grid,
  body.sheet-body:not(.section-viewer) #due-page .due-features,
  body.sheet-body:not(.section-viewer) #due-page .due-filters {
    grid-template-columns: minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) #due-page .due-attention {
    min-height: 0;
  }
  body.sheet-body:not(.section-viewer) #due-page .due-row {
    grid-template-columns: 50px minmax(0, 1fr);
    gap: calc(var(--base) * 1.25);
    padding: calc(var(--base) * 1.5);
  }
  body.sheet-body:not(.section-viewer) #due-page .due-chip {
    min-width: 49px;
  }
  body.sheet-body:not(.section-viewer) #due-page .due-row-go {
    grid-column: 2;
  }
  body.sheet-body:not(.section-viewer) #due-page .due-calendar-big .due-cal-day[type] {
    height: 46px;
  }
}
/* The sample's rows are plain: a passed date shows on its date chip and its words, never as a tinted row; the earlier
   item cards' rails (Q43) stay for no row on this page. */
body.sheet-body:not(.section-viewer) #due-page .due-row.due-block:is(.is-critical, .is-review, .is-information) {
  border: 0;
  border-top: 1px solid var(--ins-line);
  border-radius: 0;
  background-color: var(--paper);
  padding: calc(var(--base) * 2) calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) #due-page #due-month-list .due-row.due-block:is(.is-critical, .is-review, .is-information) {
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-stat-box);
}
body.sheet-body:not(.section-viewer) #due-page .due-metrics .due-metric[type] {
  background: var(--paper);
  border: 1px solid var(--ins-line);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) #due-page .due-metrics .due-metric.is-urgent[type] {
  background: var(--fo-action-bg);
  border-color: var(--fo-action-border);
}
body.sheet-body:not(.section-viewer) #due-page .due-metrics .due-metric[type]:hover {
  border-color: var(--color-accent);
}
@media (max-width: 560px) {
  body.sheet-body:not(.section-viewer) #due-page .due-row.due-block:is(.is-critical, .is-review, .is-information) {
    padding: calc(var(--base) * 1.5);
  }
}

/* ---- Goals, rebuilt from its sample (the brief of 7 Nov 26, Part 4): Family-Office v1.1's goals 02-current-design, its
   drawn values read from the sample's own styles at 1,440 px (D-508; nothing under 11 px), scoped to the page's own
   container. The rulings win: Georgia headings at regular weight; ivory cards and forest for the sample's blue; one-hue
   fades only (the sample's two-hue covers become the forest's own fade); red only for a passed date, amber for review;
   figures in tabular numerals; status always in words. */
body.sheet-body:not(.section-viewer) #goals-page {
  font-size: 15px;
  line-height: 1.52;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-photo-hero {
  /* Its own photograph (D-516; app/photo-credits.md), laid as an image so a missing one falls back to the forest: the
     deep forest of the other photo heroes, fixed in both modes (the accent turns pale green in dark, behind white words). */
  background-image: none;
  background-color: var(--on-photo-fill-7);
  min-height: 330px;
  border-radius: var(--radius-photo-hero);
  margin: calc(var(--base) * 3) 0 0;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 50%;
  z-index: 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-photo-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(90deg, var(--on-photo-fill-36) 0%, var(--on-photo-fill-37) 36%, var(--on-photo-fill-40) 72%, var(--on-photo-fill-41) 100%);
}
body.sheet-body:not(.section-viewer) #goals-page .ins-heroinner {
  position: relative;
  z-index: 1;
  padding: calc(var(--base) * 7) calc(var(--base) * 5.75) calc(var(--base) * 6);
}
body.sheet-body:not(.section-viewer) #goals-page .ins-hero .ins-eyebrow {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 2.4px;
  text-transform: uppercase;
  color: var(--on-photo-ink-9);
  margin: 0 0 calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #goals-page .ins-hero h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 57px;
  line-height: 1.08;
  letter-spacing: -1.5px;
  color: var(--on-photo-ink-2);
  margin: 0 0 calc(var(--base) * 1.25);
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goals-page .ins-hero p {
  font-size: 15px;
  line-height: 1.65;
  color: var(--on-photo-ink-10);
  max-width: 620px;
  margin: 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-hero-button[type] {
  position: relative;
  z-index: 1;
  align-self: flex-end;
  margin: 0 calc(var(--base) * 5.75) calc(var(--base) * 6) 0;
  display: inline-flex;
  align-items: center;
  gap: var(--base);
  padding: calc(var(--base) * 1.5) calc(var(--base) * 2.125);
  border: 0;
  border-radius: var(--radius-button);
  background: var(--paper);
  color: var(--color-accent);
  font-size: 13px;
  font-weight: 700;
  min-height: 44px;
  white-space: nowrap;
  box-shadow: var(--shadow-card);
}

/* The sample's four counts, under the hero. */
body.sheet-body:not(.section-viewer) #goals-page .goals-metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: calc(var(--base) * 1.75);
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-metrics[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-metric {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: calc(var(--base) * 0.75);
  min-height: 120px;
  min-width: 0;
  padding: calc(var(--base) * 2.25) calc(var(--base) * 2.625);
  border-radius: var(--radius-metric);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  box-shadow: var(--shadow-card);
  color: var(--text);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-metric .ins-metric-heading {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-metric .ins-metric-value {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 28px;
  line-height: 1.1;
  margin: calc(var(--base) * 0.5) 0 0;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-metric .ins-metric-tail {
  font-size: 11px;
  line-height: 1.4;
  color: var(--text-muted);
  margin: 0;
}
/* The closing of 7 Nov 26: the metric cards of a row share their heading, figure and note lines, so a heading that
   wraps ("Household investment assets · AUD" at 1,280) or a smaller figure (Awaiting others' "Not yet") no longer
   lifts or drops one card's note against its neighbours'. Each card lays its three lines on its row's own lines
   (subgrid); with nothing wrapping, every line sits where it did. Goals is left out: its cards' figures are one size
   and its row never misaligned, and a subgrid card does not hold its 120 px floor (it measured 117). */
body.sheet-body:not(.section-viewer) :is(#inv-page .inv-metrics, #due-page .due-metrics) > :is(.inv-metric, .due-metric) {
  display: grid;
  grid-row: span 3;
  grid-template-rows: subgrid;
  align-content: start;
  justify-items: start;
}
body.sheet-body:not(.section-viewer) #inv-page .inv-metrics > .inv-metric {
  row-gap: 0;
  justify-items: stretch;
}
body.sheet-body:not(.section-viewer) #due-page .due-metrics > .due-metric {
  row-gap: calc(var(--base) * 0.625);
}

/* Section heads, as the sample's. */
body.sheet-body:not(.section-viewer) #goals-page .goals-section {
  margin: calc(var(--base) * 5.375) 0 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-section[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2.125);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-head h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 28px;
  line-height: 1.15;
  margin: 0 0 calc(var(--base) * 0.75);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-head p {
  font-size: 13px;
  color: var(--text-muted);
  margin: 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-head p.goals-pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  color: var(--text);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-pill);
  padding: var(--base) calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-head-tools {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.5);
  flex-wrap: wrap;
  justify-content: flex-end;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-outline[type] {
  border: 1px solid var(--ins-line);
  background: var(--paper);
  color: var(--color-accent);
  border-radius: var(--radius-detail-button);
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.625);
  font-size: 12px;
  font-weight: 700;
  min-height: 40px;
  box-shadow: none;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-empty {
  font-size: 13px;
  color: var(--text-muted);
  margin: var(--base) 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-empty[hidden] {
  display: none;
}

/* Your Next Moves: Needs attention beside Opportunities. */
body.sheet-body:not(.section-viewer) #goals-page .goals-moves {
  display: grid;
  grid-template-columns: minmax(0, 1.22fr) minmax(0, 0.83fr);
  gap: calc(var(--base) * 2.375);
}
/* Worth a look alone, once Needs attention became the shared attention section (D-520). */
body.sheet-body:not(.section-viewer) #goals-page .goals-moves.is-single {
  grid-template-columns: minmax(0, 1fr);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-panel {
  min-width: 0;
  padding: calc(var(--base) * 2.75);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 1.25);
  margin: 0 0 calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-panel-heading h3 {
  font-size: 15px;
  font-weight: 400; /* D-497 (the overnight brief of 18-19 Nov 26, Part 8b) */
  margin: 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-panel-heading span {
  font-size: 11px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.5);
  margin: calc(var(--base) * 1.25) 0 0;
  padding: calc(var(--base) * 1.75) calc(var(--base) * 2);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-record-tile);
  background: var(--paper);
  transition: border-color 0.17s, transform 0.17s;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move.has-card-open:hover {
  border-color: var(--color-accent);
  transform: translateY(-2px);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move.is-attention {
  border-left: 3px solid var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move.is-feature {
  flex-direction: column;
  align-items: flex-start;
  min-height: 220px;
  padding: calc(var(--base) * 3) calc(var(--base) * 3.25);
  border: 0;
  border-radius: var(--radius-card);
  background: linear-gradient(117deg, var(--forest) 0%, color-mix(in srgb, var(--forest) 80%, var(--goals-is-feature-fill)) 100%);
  color: var(--goals-is-feature-ink);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move .goals-move-copy {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 0.625);
  min-width: 0;
  flex: 1;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move strong {
  font-size: 13px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move span {
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move.is-feature .goals-move-kicker {
  font-size: 11px;
  letter-spacing: 1.2px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--goals-move-kicker-ink);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move.is-feature strong {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 28px;
  line-height: 1.15;
  color: var(--goals-is-feature-ink);
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 0.75);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move.is-feature span {
  font-size: 13px;
  color: var(--goals-is-feature-ink-2);
  max-width: 80%;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move.is-feature .goals-move-go {
  margin-top: auto;
  font-size: 13px;
  font-weight: 700;
  color: var(--goals-is-feature-ink);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-move-go {
  font-size: 15px;
  color: var(--text-muted);
}
/* D-521 (4), 8 Nov 26: the note fits its text (it stood 96 px tall for one line), with a note's spacing. */
body.sheet-body:not(.section-viewer) #goals-page .goals-look-intro {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 0.75);
  margin: 0 0 calc(var(--base) * 1.5);
  padding: calc(var(--base) * 1.5) calc(var(--base) * 2);
  font-size: 13px;
  line-height: 1.5;  border-radius: var(--radius-record-tile);
  background: color-mix(in srgb, var(--color-accent) 9%, var(--paper));
}
body.sheet-body:not(.section-viewer) #goals-page .goals-look-intro strong {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 20px;
  line-height: 1.2;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-look-intro span {
  font-size: 12px;
  color: var(--text-muted);
}

/* Financial Safety: two tiles, each the forest's own soft fade. */
body.sheet-body:not(.section-viewer) #goals-page .goals-safety {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-safety-tile {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-height: 252px;
  min-width: 0;
  padding: calc(var(--base) * 3);
  border-radius: var(--radius-card);
  border: 1px solid var(--ins-line);
  background: linear-gradient(115deg, var(--paper) 0%, color-mix(in srgb, var(--color-accent) 14%, var(--paper)) 100%);
  transition: transform 0.2s, box-shadow 0.2s;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-safety-tile.has-card-open:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-safety-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.15px;
  text-transform: uppercase;
  color: var(--color-accent);
  margin: 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-safety-tile h3 {
  font-size: 17px;
  font-weight: 700;
  margin: calc(var(--base) * 2.25) 0 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-safety-metric {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 38px;
  line-height: 1.1;
  margin: var(--base) 0 0;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-safety-metric.is-empty {
  font-size: 28px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #goals-page :is(.goals-safety-foot, .goals-safety-chain) {
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: var(--base) 0 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-safety-bottom {
  margin-top: auto;
  padding-top: calc(var(--base) * 2.75);
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.625);
  width: 100%;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-safety-bottom .goal-bar {
  flex: 0 0 64%;
  margin: 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-safety-bottom .goal-status {
  font-size: 11px;
  font-weight: 700;
  color: var(--text);
  margin: 0;
}

/* The lifecycle switch: the shared switch's look, forest for the choice in force. */
body.sheet-body:not(.section-viewer) #goals-page .goals-lifecycle {
  display: flex;
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-lifecycle[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-lifecycle > button[type] {
  padding: var(--base) calc(var(--base) * 1.75);
  border: 0;
  border-radius: var(--radius-switch-button);
  background: transparent;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  min-height: 36px;
  box-shadow: none;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-lifecycle > button[type][aria-pressed="true"] {
  background: var(--color-accent);
  color: var(--plus-ink);
}
body.sheet-body:not(.section-viewer) #goals-page button.row-button.add-row.goals-add[type] {
  width: auto;
  min-height: 40px;
  padding: var(--base) calc(var(--base) * 1.75) var(--base) calc(var(--base) * 1.25);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-detail-button);
  background: var(--paper);
  font-size: 12px;
  font-weight: 700;
  gap: var(--base);
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #goals-page button.goals-add[hidden] {
  display: none;
}

/* The sample's goal cards, three across: kept for .goals-grid. All Goals itself is the shared record grid at Property's
   portfolio size, two a row (D-524 (3), 9 Nov 26 combined, Part 4). */
body.sheet-body:not(.section-viewer) #goals-page .goals-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-card {
  display: flex;
  flex-direction: column;
  min-height: 356px;
  min-width: 0;
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  background: var(--paper);
  box-shadow: var(--shadow-card);
  transition: transform 0.2s, border-color 0.2s;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-card.has-card-open:hover {
  transform: translateY(-4px);
  border-color: var(--color-accent);
  z-index: 3;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-cover {
  position: relative;
  height: 154px;
  flex-shrink: 0;
  clip-path: inset(0 round var(--radius-card) var(--radius-card) 0 0);
  background: linear-gradient(110deg, color-mix(in srgb, var(--color-accent) 30%, var(--paper)) 0%, color-mix(in srgb, var(--color-accent) 8%, var(--paper)) 100%);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 calc(var(--base) * 4);
  color: color-mix(in srgb, var(--color-accent) 70%, var(--paper));
}
body.sheet-body:not(.section-viewer) #goals-page .goals-cover svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}
/* A goal card's photograph (Brief 1 of 3 of 7 Nov 26 (c), Part 5; D-516): it fills the cover; the tag sits over it. */
body.sheet-body:not(.section-viewer) #goals-page .goals-cover-photo {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 calc(var(--base) * 4);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-cover-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-cover-tag {
  z-index: 1;
  position: absolute;
  top: calc(var(--base) * 1.75);
  left: calc(var(--base) * 1.875);
  border-radius: var(--radius-pill);
  background: var(--paper);
  color: var(--text);
  font-size: 11px;
  font-weight: 700;
  padding: var(--base) calc(var(--base) * 1.375);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-main {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  padding: calc(var(--base) * 2.25) calc(var(--base) * 2.375) calc(var(--base) * 2.375);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-kicker {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.3px;
  text-transform: uppercase;
  color: var(--color-accent);
  margin: 0 0 var(--base);
}
/* Each goal's name is the shared record card's title, set once for every page in the shared rule below (D-632 (3); the
   overnight brief of 21-22 Nov 26, Part 10); Goals' own rule of 21 Nov 26 went into it. */
body.sheet-body:not(.section-viewer) #goals-page .goals-card .group-name {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 20px;
  line-height: 1.2;
  margin: 0 0 calc(var(--base) * 0.625);
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-sub {
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-bottom {
  margin-top: auto;
  padding-top: calc(var(--base) * 1.5);
  display: flex;
  flex-direction: column;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-card .sheet-figure {
  font-size: 12px;
  font-weight: 700;
  margin: 0;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-card .goal-bar {
  margin: 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-card .goal-status {
  font-size: 12px;
  color: var(--text);
  margin: 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-card .goal-status.is-behind {
  align-self: flex-start;
  background: var(--fo-review-bg);
  border-radius: var(--radius-pill);
  padding: calc(var(--base) * 0.375) calc(var(--base) * 1.125);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-note {
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goals-page a.goals-open {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--base) * 0.5);
  align-self: flex-start;
  font-size: 12px;
  font-weight: 700;
  color: var(--color-accent);
  text-decoration: none;
  min-height: 28px;
}
body.sheet-body:not(.section-viewer) #goals-page a.goals-open:hover {
  text-decoration: underline;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-card .row-button {
  min-height: 44px;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-ended {
  margin: calc(var(--base) * 2.5) 0 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-fold > summary {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-accent);
  margin: 0 0 calc(var(--base) * 1.5);
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-chart {
  margin: calc(var(--base) * 3) 0 0;
}

/* Milestones & What's Due beside Monthly Review & Integrity. */
body.sheet-body:not(.section-viewer) #goals-page .goals-below {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 2.375);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-box {
  min-width: 0;
  padding: calc(var(--base) * 2.5);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-box h3 {
  font-size: 15px;
  font-weight: 400; /* D-497 (the overnight brief of 18-19 Nov 26, Part 8b) */
  margin: 0 0 calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-event {
  display: flex;
  gap: calc(var(--base) * 1.5);
  padding: calc(var(--base) * 1.25) 0;
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-event:first-child {
  border-top: 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-datebox {
  flex: 0 0 auto;
  width: 64px;
  min-height: 56px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-detail-button);
  background: color-mix(in srgb, var(--color-accent) 8%, var(--paper));
}
body.sheet-body:not(.section-viewer) #goals-page .goals-datebox strong {
  font-size: 15px;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-datebox span {
  font-size: 11px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-datebox.is-past {
  background: var(--fo-action-bg);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-datebox.is-past strong {
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-event-info {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 0.5);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-event-info strong {
  font-size: 13px;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goals-page .goals-event-info span {
  font-size: 12px;
  line-height: 1.45;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #goals-page .goals-link {
  display: inline-block;
  margin: calc(var(--base) * 1.5) 0 0;
  font-size: 13px;
  font-weight: 700;
  color: var(--color-accent);
  text-decoration: none;
}
body.sheet-body:not(.section-viewer) :is(#goals-page, #goal-panel-sheet, #goals-info-sheet) .goals-nested {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 0.625);
  margin: calc(var(--base) * 1.125) 0 0;
  padding: calc(var(--base) * 1.625) calc(var(--base) * 1.75);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-stat-box);
  background: var(--paper);
}
body.sheet-body:not(.section-viewer) :is(#goals-page, #goal-panel-sheet) .goals-nested strong {
  font-size: 13px;
  font-weight: 700;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) :is(#goals-page, #goal-panel-sheet) .goals-nested span {
  font-size: 12px;
  line-height: 1.5;
  color: var(--text-muted);
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goals-page #read-at {
  margin: calc(var(--base) * 2.5) 0 calc(var(--base) * 2);
}

/* The goal's panel: the sample's drawer in the shared 480 px panel. */
body.sheet-body:not(.section-viewer) :is(#goal-panel-sheet, #goals-info-sheet) .goals-sheet-eyebrow {
  font-size: 11px;
  letter-spacing: 1.5px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 var(--base);
}
body.sheet-body:not(.section-viewer) :is(#goal-panel-sheet, #goals-info-sheet) .goals-sheet-title {
  /* D-536 (1): the Income source panel's title, 38 px (28 px before 11 Nov 26); 28 px on the phone, below. */
  font-family: Georgia, "Times New Roman", serif;
  font-size: 38px;
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -0.5px;
  margin: calc(var(--base) * 1.5) 0 var(--base);
  overflow-wrap: anywhere;
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) :is(#goal-panel-sheet, #goals-info-sheet) .goals-sheet-title {
    font-size: 28px;
    line-height: 1.15;
    letter-spacing: 0;
  }
}
/* Overnight 8 Nov 26, Part 8: What's Due's panel tabs share these rules (one style for both panels); the tool panels'
   tabs since the brief of 12 Nov 26, Part 10 (D-544 (4), src/tool-panels.ts). */
body.sheet-body:not(.section-viewer) :is(#goal-panel-sheet .goals-panel-tabs, #due-sheet .due-panel-tabs, .tool-panel .tool-tabs, #record-panel .tool-tabs) {
  display: flex;
  width: 100%;
  margin: calc(var(--base) * 2) 0 calc(var(--base) * 2.5);
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
}
body.sheet-body:not(.section-viewer) :is(#goal-panel-sheet .goals-panel-tabs, #due-sheet .due-panel-tabs, .tool-panel .tool-tabs, #record-panel .tool-tabs) > button[type] {
  /* D-536 (1): the Income source panel's tabs, 29 px high, one line each, as wide as their words (36 px and wrapping
     before 11 Nov 26). Width auto: each tab starts from its words, not the shared button's 100%. */
  width: auto;
  flex: 1 1 auto;
  min-width: 0;
  padding: var(--base) var(--base);
  border: 0;
  border-radius: var(--radius-switch-button);
  background: transparent;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  min-height: 0;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) :is(#goal-panel-sheet .goals-panel-tabs, #due-sheet .due-panel-tabs, .tool-panel .tool-tabs, #record-panel .tool-tabs) > button[type][aria-selected="true"] {
  background: var(--color-accent);
  color: var(--plus-ink);
}
/* D-637 (2): a record panel's tabs are equal segments across the full width, as Debt's and Property's are. */
body.sheet-body:not(.section-viewer) #record-panel .tool-tabs.record-tabs > button[type] {
  flex: 1 0 auto;
}
body.sheet-body:not(.section-viewer) #due-sheet .due-pane[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) :is(#due-sheet, #due-info-sheet) .due-tab-line {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text);
  margin: var(--base) 0;
}
body.sheet-body:not(.section-viewer) #due-sheet .due-pane > .row-button {
  margin-top: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #due-sheet .due-pane > .due-audit + .due-audit {
  margin-top: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-pane[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-pane h3 {
  font-size: 13px;
  font-weight: 700;
  margin: calc(var(--base) * 2.75) 0 var(--base);
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-stat {
  display: flex;
  flex-direction: column;
  gap: var(--base);
  min-height: 82px;
  min-width: 0;
  padding: calc(var(--base) * 2);
  border-radius: var(--radius-stat-box);
  background: color-mix(in srgb, var(--color-accent) 7%, var(--paper));
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-stat span {
  font-size: 11px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-stat strong {
  font-size: 17px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .detail-row {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  padding: calc(var(--base) * 1.625) 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .detail-row span {
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .detail-row strong {
  text-align: right;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  max-width: 63%;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goal-bar {
  margin: calc(var(--base) * 2) 0 var(--base);
}
body.sheet-body:not(.section-viewer) :is(#goal-panel-sheet, #goals-info-sheet) :is(.goals-pane-line, .goals-projection-line) {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text);
  margin: calc(var(--base) * 1.25) 0 0;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-projection-line {
  font-size: 15px;
}
/* Overnight 8 Nov 26, Part 7: the Projection tab's chart. Zero growth the chart's own solid line; the typed growth dashed
   in the same hue; the target thin and muted. Each line is named in words under the chart, never by colour alone. */
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-projection-chart {
  margin: calc(var(--base) * 2) 0;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-projection-chart .sheet-chart-box {
  overflow: hidden;
}
/* D-523 (the session of 8 Nov 26 (b), Part 5; Avi: no purple): the site's own colours, each line named on the chart in
   its colour. At zero growth forest and solid; at your growth green and dashed; the needed path copper and dotted; the
   target thin and muted. */
body.sheet-body:not(.section-viewer) #goal-panel-sheet :is(.goal-projection-zero, .goal-projection-typed, .goal-projection-needed) {
  fill: none;
  stroke-width: 2;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goal-projection-zero {
  stroke: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goal-projection-typed {
  stroke: var(--color-green);
  stroke-dasharray: 6 4;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goal-projection-needed {
  stroke: var(--color-orange);
  stroke-dasharray: 2 4;
  stroke-linecap: round;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goal-projection-target {
  stroke: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goal-projection-label {
  font-size: 11px;
  font-weight: 600;
  fill: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goal-projection-label.is-zero { fill: var(--color-accent); }
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goal-projection-label.is-typed { fill: var(--color-green); }
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goal-projection-label.is-needed { fill: var(--color-orange); }
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-projection-nopay {
  margin: 0 0 var(--base);
  font-size: 13px;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-projection-key {
  font-size: 13px;
  line-height: 1.6;
  color: var(--text);
  margin: var(--base) 0;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-callout {
  font-size: 12px;
  line-height: 1.6;
  color: var(--text);
  background: color-mix(in srgb, var(--color-accent) 8%, var(--paper));
  border-left: 3px solid var(--color-accent);
  border-radius: var(--radius-tab-inner);
  padding: calc(var(--base) * 1.75);
  margin: calc(var(--base) * 2) 0;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-nested.is-reached strong::after {
  content: " ✓";
  color: var(--color-accent);
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet #goal-assume {
  margin: calc(var(--base) * 2) 0 0;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet #goal-assume[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) #goal-panel-sheet .goals-sheet-actions {
  display: grid;
  gap: calc(var(--base) * 1.5);
  margin-top: calc(var(--base) * 3);
}

@media (max-width: 1100px) {
  body.sheet-body:not(.section-viewer) #goals-page .goals-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 880px) {
  body.sheet-body:not(.section-viewer) #goals-page .goals-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) #goals-page :is(.goals-moves, .goals-below, .goals-safety) {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 560px) {
  body.sheet-body:not(.section-viewer) #goals-page .goals-photo-hero {
    min-height: 260px;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-end;
  }
  body.sheet-body:not(.section-viewer) #goals-page .ins-heroinner {
    padding: calc(var(--base) * 3.5) calc(var(--base) * 2.5) 0;
  }
  body.sheet-body:not(.section-viewer) #goals-page .goals-hero-button[type] {
    align-self: flex-start;
    margin: calc(var(--base) * 1.5) 0 calc(var(--base) * 3) calc(var(--base) * 2.5);
  }
  body.sheet-body:not(.section-viewer) #goals-page .ins-hero h2 {
    font-size: 38px;
  }
  body.sheet-body:not(.section-viewer) #goals-page .goals-metrics {
    gap: var(--base);
  }
  body.sheet-body:not(.section-viewer) #goals-page .goals-metric {
    min-height: 96px;
    padding: calc(var(--base) * 1.5) calc(var(--base) * 1.75);
  }
  body.sheet-body:not(.section-viewer) #goals-page .goals-metric .ins-metric-value {
    font-size: 20px;
  }
  body.sheet-body:not(.section-viewer) #goals-page .goals-head {
    flex-direction: column;
    align-items: flex-start;
  }
  body.sheet-body:not(.section-viewer) #goals-page .goals-head-tools {
    justify-content: flex-start;
  }
  body.sheet-body:not(.section-viewer) #goals-page .goals-lifecycle {
    flex-wrap: wrap;
  }
  body.sheet-body:not(.section-viewer) #goals-page .goals-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) #goals-page .goals-move.is-feature span {
    max-width: 100%;
  }
}

/* Goals: the sample's bars, a soft blue fill on a pale track (its .bar), the even-pace mark kept; the reserve's and the
   support's on the tile's lighter track. The fill is decoration: every figure is written beside it. The same blue reads
   on the light and the dark card; the track is mixed from the page's own text and card, so it follows the theme. */
body.sheet-body:not(.section-viewer) :is(#goals-page, #goal-panel-sheet) .goal-bar {
  /* The shared bar paints its fill from --section-summary; on Goals that is the sample's soft blue. */
  --section-summary: #6d9bd2;
  background: color-mix(in srgb, var(--text) 10%, var(--paper));
}
body.sheet-body:not(.section-viewer) #goals-page .goals-safety-bottom .goal-bar {
  background: color-mix(in srgb, var(--paper) 67%, transparent);
}

/* ===================================================================================================================
   Avi's ground rules on every finished page (D-520; the brief of 7 Nov 26 (b), Part 2): the shared pieces, built once.
   Scoped to the eight built pages only (never her pages: section-viewer is excluded, and none of these ids is hers).
   The values are Insurance's drawn values (the :is(#ins-page, #pa-page, #pr-page) rules above), carried to all eight.
   =================================================================================================================== */
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-hero .ins-eyebrow {
  font-size: 12px;
  letter-spacing: 2.4px;
  text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-hero h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 57.6px;
  line-height: 1.03;
  letter-spacing: -2px;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-hero .ins-feature {
  font-size: 12px;
  font-weight: 650;
  padding: var(--base) calc(var(--base) * 2);
}
/* What deserves attention: two cards filling the width; a card past the first two is drawn hidden (data-over), and
   See all opens the panel that lists every item (src/attention-limit.ts). */
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
/* The brief of 17 Nov 26, A5 (Avi's item 5; D-577): one card keeps half the width, as two do; it no longer stretches to
   the full width. The phone shows one card a row (below). */
body.sheet-body:not(.section-viewer) .ins .ins-cards > .ins-card[data-over] {
  display: none;
}
/* D-528 (2) (the long session of 10 Nov 26, Part 3): one shared button for every See all (n), Show fewer and Show all
   on every page: the attention sections' and the card sections' See all (src/attention-limit.ts, src/card-fold.ts), the
   strips' See all (src/strip-fold.ts) and the strips' Show all (Insurance, Property, Debt, Phone & Access). The same
   height, padding, colours, corners and type; Avi: "See how these 2 buttons sitting next each other but visually
   different . Need to match. Should be across all the pages." :is() over the ids outranks the pages' own light-button
   rules, so a strip's Show all takes this look whatever its page says. */
body.sheet-body:not(.section-viewer) .ins :is(button.gr-see-all, button.gr-search, #ins-all, #pr-all, #debt-all, #pa-all)[type],
body.sheet-body:not(.section-viewer) .ins :is(button.gr-see-all, button.gr-search, #ins-all, #pr-all, #debt-all, #pa-all)[type][aria-pressed] {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 2.5);
  border: 1px solid var(--forest);
  border-radius: var(--radius-pill);
  background: var(--forest);
  color: var(--ins-see-all-ink);
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  line-height: normal;
  white-space: nowrap;
  cursor: pointer;
}
@media (max-width: 767px) {
  /* The phone's least touch height, for every one of them alike. */
  body.sheet-body:not(.section-viewer) .ins :is(button.gr-see-all, button.gr-search, #ins-all, #pr-all, #debt-all, #pa-all)[type] {
    min-height: 44px;
  }
}
body.sheet-body:not(.section-viewer) :is(.gr-see-all, .gr-search, .gr-search-box)[hidden] {
  display: none;
}
/* Master Records' Search (D-528 (6), Part 5): the button carries the search glass before its word; tapped, it becomes a
   box the See all's height, a pill with a line, the card behind and the text colour. */
body.sheet-body:not(.section-viewer) .ins button.gr-search[type] {
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) .ins button.gr-search[type] svg {
  width: 16px;
  height: 16px;
}
body.sheet-body:not(.section-viewer) .ins .gr-search-wrap {
  display: inline-flex;
}
body.sheet-body:not(.section-viewer) .ins input.gr-search-box {
  box-sizing: border-box;
  width: min(280px, 60vw);
  height: 38px;
  margin: 0;
  padding: 0 calc(var(--base) * 2);
  border: 1px solid var(--forest);
  border-radius: var(--radius-pill);
  background: var(--color-card);
  color: var(--text);
  font: inherit;
  font-size: 16px;
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .ins input.gr-search-box {
    height: 44px;
  }
}
/* D-528 (3): See all on its own line directly below its section's heading block, right-aligned; nothing of the heading
   row moves. The line's margins (a step under the heading block, the section's gap above the cards) are set by
   src/heading-line.ts from where the browser put it. */
body.sheet-body:not(.section-viewer) .gr-see-all-line {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .gr-see-all-line[hidden] {
  display: none;
}
/* D-535 (the brief of 11 Nov 26, Part 3): laid over the heading row, under the switch or at the end of the heading's
   line, so it takes no line of its own; src/heading-line.ts sets top and right from where the browser put the switch
   and the heading, and leaves this class off where it would touch them (the phone), where the line wraps as above. */
body.sheet-body:not(.section-viewer) .gr-see-all-line.gr-see-all-beside {
  position: absolute;
  z-index: 1;
  margin: 0;
}
/* Master Records' heading keeps Add and Update on its line (D-524 (1)'s place, which D-528 (3) left for those two):
   the heading and the buttons share one line, wrapping under it on the phone. Part 3 removed the shared line rule this
   leant on; found by the Records views of Part 4 (10 Nov 26). */
body.sheet-body:not(.section-viewer) .ins .master-heading .master-head-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  column-gap: calc(var(--base) * 1.5);
  row-gap: var(--base);
}
body.sheet-body:not(.section-viewer) .ins .master-heading .master-head-line > h2 {
  flex: 1 1 auto;
  min-width: 0;
}
/* A card past the fold of a folded section (src/card-fold.ts, D-528 (4)): hidden as [hidden] is, whatever the card's own layout. */
body.sheet-body:not(.section-viewer) .ins [data-folded] {
  display: none !important;
}
body.sheet-body:not(.section-viewer) .gr-attention-list {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .gr-attention-list .ins-card {
  display: flex;
  flex-direction: column;
  gap: var(--base);
  padding: calc(var(--base) * 2.5);
  background: var(--ivory);
  border: 1px solid color-mix(in srgb, var(--text) 12%, transparent);
  border-left: 4px solid var(--gr-card-line);
  border-radius: var(--radius-tile);
}
body.sheet-body:not(.section-viewer) .gr-attention-list .ins-card h3 {
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 20px;
}
body.sheet-body:not(.section-viewer) .gr-attention-list .ins-card p,
body.sheet-body:not(.section-viewer) .gr-attention-list .ins-meta {
  margin: 0;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .gr-attention-list .ins-kicker {
  display: flex;
  justify-content: space-between;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) .gr-attention-list .ins-tag {
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 1px;
  text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) .gr-attention-list .ins-btn[type] {
  align-self: flex-start;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 2);
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--forest);
  color: var(--gr-btn-ink);
  font: inherit;
  font-size: 13px;
  font-weight: 750;
  cursor: pointer;
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-cards {
    grid-template-columns: minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-hero h2 {
    font-size: 38px;
  }
}

/* ======================================================================================================================
   The shared pieces of the eight finished pages (D-520; Brief 1 of 3 of 7 Nov 26, Part 3), built once (D-223) and drawn
   by src/shared-pieces.ts: summary cards (Property's), the People & assets strip (Insurance's), the category tile
   (Insurance's "Your insurance") and the record card (Property's "Your portfolio"). Each takes its model's drawn values
   as they stood on 7 Nov 26, read from the running page. New classes only, under .ins on an owner page: no class her
   pages use is changed (D-237).
   ===================================================================================================================== */
body.sheet-body:not(.section-viewer) .ins .gr-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 4);
  font-size: 16px;
  line-height: normal;
}
/* A note line under the cards (Property's "4 properties yours …") sits close beneath them. */
body.sheet-body:not(.section-viewer) .ins .gr-summary:has(+ p) {
  margin-bottom: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) .ins .gr-summary[data-count="3"] {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
body.sheet-body:not(.section-viewer) .ins .gr-summary-value {
  container-type: inline-size;
  min-width: 0;
}
/* :is(article, button[type]) weighs the card above the page's button reset (.ins button[type]), so a card drawn as a
   button (What's Due's counts) keeps its padding, paper and border (7 Nov 26 (c), Part 6). */
body.sheet-body:not(.section-viewer) .ins .gr-summary-card:is(article, button[type]) {
  min-width: 0;
  padding: calc(var(--base) * 2.875) calc(var(--base) * 3.125) calc(var(--base) * 2.5);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-metric);
  box-shadow: 0 4px 15px var(--shadow-3);
  /* Label, figure and line on three rows shared with the cards beside it, so each row's lines start at one height
     whatever a card's figure holds (one figure, or one per currency). */
  display: grid;
  grid-row: span 3;
  grid-template-rows: subgrid;
  row-gap: 0;
}
body.sheet-body:not(.section-viewer) .ins .gr-summary-label {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.125);
  font-size: 12px;
  font-weight: 600;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-summary-label svg {
  width: 16px;
  height: 16px;
  flex: none;
}
/* The figure to the cent with its currency: never above 28 px, stepping down with the card's own width, never wrapped. */
body.sheet-body:not(.section-viewer) .ins .gr-summary-figure {
  margin: calc(var(--base) * 2.5) 0 0;
  font-size: min(28px, 10.5cqi);
  font-weight: 740;
  line-height: 1.1;
  letter-spacing: -0.9px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) .ins .gr-summary-figure[data-owed] {
  color: var(--color-red);
}
/* A card holding one figure per currency (Debt's totals, never added across): each its own line, a step smaller. */
body.sheet-body:not(.section-viewer) .ins .gr-summary-figures {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) .ins .gr-summary-figures > .gr-summary-figure {
  font-size: min(20px, 8cqi);
}
body.sheet-body:not(.section-viewer) .ins .gr-summary-figure[data-not-yet] {
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-summary-code {
  font-size: clamp(11px, 6cqi, 15px);
  font-weight: 700;
  letter-spacing: 0;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .ins .gr-summary-line {
  margin: var(--base) 0 0;
  font-size: 11px;
  line-height: 1.4;
  color: var(--ins-quiet);
}
/* A card that opens something (What's Due's counts) is a button: the same card, its parts spans laid as blocks. */
body.sheet-body:not(.section-viewer) .ins button.gr-summary-card[type] {
  font: inherit;
  text-align: left;
  color: var(--text);
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) .ins button.gr-summary-card[type]:hover {
  border-color: var(--color-accent);
}
body.sheet-body:not(.section-viewer) .ins button.gr-summary-card :is(.gr-summary-value, .gr-summary-figure, .gr-summary-line) {
  display: block;
}
/* Needs action now: the action band, as What deserves attention's critical card; the words say why. */
body.sheet-body:not(.section-viewer) .ins .gr-summary-card[data-urgent]:is(article, button[type]) {
  background: var(--fo-action-bg);
  border-color: var(--fo-action-border);
}
body.sheet-body:not(.section-viewer) .ins .gr-summary-card[data-urgent] .gr-summary-figure {
  color: var(--fo-action-accent);
}

/* People & assets: round portraits or photographs, a name and a kind; choosing one highlights only. */
body.sheet-body:not(.section-viewer) .ins .gr-people {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 1.875);
  padding: calc(var(--base) * 2.625) calc(var(--base) * 2.875);
  margin: 0 0 calc(var(--base) * 4.375);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-block);
  box-shadow: 0 4px 13px var(--shadow-4);
  font-size: 16px;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) .ins .gr-person[type] {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: calc(var(--base) * 0.875);
  min-width: 114px;
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.625) calc(var(--base) * 1.375);
  border: 1px solid transparent;
  border-radius: var(--radius-strip-tile);
  background: transparent;
  color: var(--text);
  font: inherit;
  text-align: center;
  cursor: pointer;
  transition: background 0.18s, border 0.18s, transform 0.18s;
}
body.sheet-body:not(.section-viewer) .ins .gr-person[type]:hover {
  background: var(--fo-hover);
  transform: translateY(-2px);
}
body.sheet-body:not(.section-viewer) .ins .gr-person[type].selected {
  background: var(--fo-success-bg);
  border-color: var(--forest-2);
}
body.sheet-body:not(.section-viewer) .ins .gr-person-pic {
  display: block;
  width: 67px;
  height: 67px;
  border-radius: 50%;
  overflow: hidden;
  border: 3px solid var(--paper);
  box-shadow: 0 3px 14px var(--shadow-5);
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) .ins .gr-person-pic :is(img, svg) {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) .ins .gr-person-name {
  font-size: 12px;
  font-weight: 730;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) .ins .gr-person-kind {
  font-size: 11px;
  line-height: 1.2;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-people-none {
  margin: 0;
  font-size: 13px;
  color: var(--ins-quiet);
}

/* The category tile: an icon in a tinted square, the arrow at the top right, a Georgia title, one line, the people
   covered, and a count and status at its foot. */
body.sheet-body:not(.section-viewer) .ins .gr-tile-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: calc(var(--base) * 2.375);
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-grid[data-count="2"] {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-grid[data-count="3"] {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
body.sheet-body:not(.section-viewer) .ins .gr-tile[type],
body.sheet-body:not(.section-viewer) .ins a.gr-tile[href],
body.sheet-body:not(.section-viewer) .ins div.gr-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 263px;
  margin: 0;
  padding: calc(var(--base) * 2.625) calc(var(--base) * 2.625) calc(var(--base) * 2.125);
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  box-shadow: 0 3px 13px var(--shadow-6);
  color: var(--text);
  font: inherit;
  font-size: 16px;
  line-height: normal;
  text-align: left;
  isolation: isolate;
  transition: transform 0.2s cubic-bezier(0.2, 0.7, 0.2, 1), box-shadow 0.2s, border-color 0.2s, opacity 0.2s;
}
body.sheet-body:not(.section-viewer) .ins :is(.gr-tile[type], a.gr-tile[href]) {
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) .ins :is(.gr-tile[type], a.gr-tile[href]):hover {
  z-index: 5;
  transform: translateY(-5px);
  box-shadow: var(--shadow-lift);
}
body.sheet-body:not(.section-viewer) .ins :is(.gr-tile[type], a.gr-tile[href]):active {
  transform: translateY(-2px);
}
body.sheet-body:not(.section-viewer) .ins .gr-tile.dimmed {
  opacity: 0.36;
}
body.sheet-body:not(.section-viewer) .ins .gr-tile.related {
  border-color: color-mix(in srgb, var(--forest-2) 45%, var(--paper));
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--forest-2) 16%, transparent);
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  min-height: 48px;
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 51px;
  height: 51px;
  border-radius: var(--radius-cat-icon);
  background: var(--tint, var(--fo-success-bg));
  color: var(--ink, var(--forest-2));
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-icon svg {
  width: 24px;
  height: 24px;
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-arrow {
  display: block;
  width: 18px;
  height: 18px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-mid {
  margin: calc(var(--base) * 3.75) 0 0;
  min-height: 64px;
  /* 11 Nov 26: kept inside its tile; without it a heading longer than the tile ("Month-end statement load" on the
     phone, 177 px of words in 135 px) widened the box and the page past the screen. */
  min-width: 0;
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-mid h3 {
  margin: 0 0 var(--base);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 20px;
  font-weight: 400;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-mid p {
  margin: 0;
  font-size: 11.5px;
  line-height: 1.35;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-figure {
  margin: calc(var(--base) * 1.5) 0 0;
  font-size: 17px;
  font-weight: 750;
  letter-spacing: -0.3px;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-figure[data-owed] {
  color: var(--color-red);
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-bottom {
  margin-top: auto;
}
/* A tile's further lines (Goals' Financial Safety) sit a little apart under its figure; its bar above the foot. */
body.sheet-body:not(.section-viewer) .ins .gr-tile-mid > p + p,
body.sheet-body:not(.section-viewer) .ins .gr-tile-figure + p {
  margin-top: var(--base);
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-bottom > .goal-bar {
  margin: calc(var(--base) * 2) 0;
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-people {
  display: flex;
  align-items: center;
  height: 32px;
  margin: calc(var(--base) * 1.5) 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-face {
  display: block;
  flex: none;
  width: 28px;
  height: 28px;
  margin-left: calc(var(--base) * -0.75);
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid var(--paper);
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-face:first-child {
  margin-left: 0;
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-face :is(img, svg) {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-people-words {
  margin-left: var(--base);
  font-size: 11px;
  white-space: nowrap;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-people-words:first-child {
  margin-left: 0;
}
body.sheet-body:not(.section-viewer) .ins .gr-tile-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--base);
  padding-top: calc(var(--base) * 2);
  border-top: 1px solid var(--ins-line);
  font-size: 11px;
  font-weight: 580;
  color: var(--ins-quiet);
}

/* A status in its words with a dot, on a tile's foot and a record card's title line: never colour alone. */
body.sheet-body:not(.section-viewer) .ins .gr-status {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--base) * 0.625);
  font-size: 11px;
  font-weight: 720;
  line-height: normal;
  white-space: nowrap;
  color: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) .ins .gr-status::before {
  content: "";
  display: inline-block;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: currentColor;
}
body.sheet-body:not(.section-viewer) .ins .gr-status[data-level="review"] {
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) .ins .gr-status[data-level="critical"] {
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) .ins .gr-status[data-level="none"],
body.sheet-body:not(.section-viewer) .ins .gr-status[data-level="quiet"] {
  color: var(--ins-quiet);
}
/* On a record card the status is a pill, as on Property's portfolio card. */
body.sheet-body:not(.section-viewer) .ins .gr-record .gr-status {
  padding: calc(var(--base) * 0.625) calc(var(--base) * 1.125);
  border-radius: var(--radius-pill);
  background: var(--stone);
  color: var(--text);
  font-weight: 750;
}
body.sheet-body:not(.section-viewer) .ins .gr-record .gr-status:is([data-level="ok"], [data-level="verified"]) {
  background: var(--fo-success-bg, var(--stone));
  color: var(--fo-success-accent);
}
body.sheet-body:not(.section-viewer) .ins .gr-record .gr-status[data-level="review"] {
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) .ins .gr-record .gr-status[data-level="critical"] {
  background: var(--fo-action-bg);
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) .ins .gr-record .gr-status:is([data-level="quiet"], [data-level="none"]) {
  color: var(--ins-quiet);
}

/* The record card: a photograph across the top with its kind chip and arrow over it, then the title and status, its
   figures, and chips and a note at its foot. */
body.sheet-body:not(.section-viewer) .ins .gr-record-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-grid[data-count="3"] {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
/* 8 Nov 26, Part 5: a column from the top, not a block. A card is a button, and a browser centres a button's content
   in its height, so a card stretched to its row's tallest dropped its cover below its own top edge (Phone & Access's
   lines with no country, 32 px). */
body.sheet-body:not(.section-viewer) .ins .gr-record[type],
body.sheet-body:not(.section-viewer) .ins div.gr-record {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  width: 100%;
  min-width: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  background: var(--color-card);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-photo-card);
  box-shadow: var(--shadow-card);
  color: var(--text);
  font: inherit;
  font-size: 16px;
  line-height: normal;
  text-align: left;
  transition: transform 0.22s ease, box-shadow 0.22s ease, opacity 0.22s ease;
}
body.sheet-body:not(.section-viewer) .ins .gr-record[type] {
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) .ins .gr-record[type]:hover {
  transform: translateY(-5px);
}
body.sheet-body:not(.section-viewer) .ins .gr-record.dimmed {
  opacity: 0.42;
}
body.sheet-body:not(.section-viewer) .ins .gr-record.related {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-image {
  position: relative;
  display: block;
  flex: 0 0 170px;
  height: 170px;
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-photo {
  position: absolute;
  inset: 0;
  display: block;
  overflow: hidden;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-photo img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-fallback {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-chip {
  position: absolute;
  top: 16px;
  left: 16px;
  max-width: calc(100% - 80px);
  padding: calc(var(--base) * 0.75) calc(var(--base) * 1.25);
  border-radius: var(--radius-pill);
  background: var(--on-photo-fill-34);
  color: var(--on-photo-ink-7);
  font-size: 11px;
  font-weight: 780;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-arrow {
  position: absolute;
  top: 14px;
  right: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--on-photo-fill-34);
  color: var(--on-photo-ink-7);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-body {
  display: block;
  padding: calc(var(--base) * 2.625) calc(var(--base) * 2.875) calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-titleline {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: calc(var(--base) * 1.5);
}
/* 8 Nov 26, Part 5: a long status ("Behind by 4,218.21 AUD") drops under the title rather than crushing it to a
   word a line; the title keeps at least 150 px beside a pill. */
body.sheet-body:not(.section-viewer) .ins .gr-record-titleline > span:first-child {
  display: block;
  flex: 1 1 150px;
  min-width: 0;
}
/* D-632 (3) (the overnight brief of 21-22 Nov 26, Part 10): a record card's own title (Goals, Debt, Income, Property,
   Phone & Access) is the card's name line in the system font at the body size, 17 px, and 600, as What's Due's item
   titles are; one look for one element (D-209), in place of the card heading's 20 px at 770. The text roles hold it
   at 17 px as the record title role (tools/text-roles.json); tests/page-rules.py check 7 fails on any other. */
body.sheet-body:not(.section-viewer) .ins .gr-record-title {
  display: block;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: var(--size-body);
  font-weight: 600;
  letter-spacing: normal;
  line-height: 1.3;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-place {
  display: block;
  margin-top: calc(var(--base) * 0.625);
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-figures {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: calc(var(--base) * 1.25);
  margin: calc(var(--base) * 2.5) 0 calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-figures[data-count="2"] {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
body.sheet-body:not(.section-viewer) .ins .gr-record-figure {
  display: block;
  min-width: 0;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-figure small {
  display: block;
  margin-bottom: calc(var(--base) * 0.625);
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-figure b {
  display: block;
  font-size: 17px;
  font-weight: 750;
  letter-spacing: -0.3px;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-figure b[data-owed] {
  color: var(--color-red);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-figure b[data-not-recorded] {
  color: var(--ins-quiet);
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--base);
  margin: 0 0 calc(var(--base) * 1.5);
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-bar {
  display: block;
  height: 7px;
  margin: 0 0 calc(var(--base) * 2);
  overflow: hidden;
  border-radius: var(--radius-pill);
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-bar > i {
  display: block;
  height: 100%;
  border-radius: var(--radius-pill);
  background: var(--color-accent);
  opacity: 0.7;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-foot {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--base);
  padding-top: calc(var(--base) * 1.625);
  border-top: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-chips {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 0.75);
  min-width: 0;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-chips > span {
  padding: calc(var(--base) * 0.75) var(--base);
  border-radius: var(--radius-small-chip);
  background: var(--stone);
  color: var(--text);
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-aside {
  font-size: 11px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-note {
  display: block;
  margin: calc(var(--base) * 1.25) 0 0;
  font-size: 11px;
  line-height: 1.5;
  color: var(--ins-quiet);
}
/* D-521, 8 Nov 26: the record card's list of figures (a row each, label left, value right), its row of pills under the
   title, the bar's even-pace marker, and the controls after the notes. */
body.sheet-body:not(.section-viewer) .ins .gr-record-list {
  display: block;
  margin: 0 0 calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: calc(var(--base) * 1.5);
  padding: calc(var(--base) * 0.75) 0;
  border-top: 1px solid var(--ins-line);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-row small {
  min-width: 0;
  font-size: 13px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-row b {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: right;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-row b[data-owed] {
  color: var(--color-red);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-row b[data-not-recorded] {
  color: var(--ins-quiet);
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-pills {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 0.75);
  margin: calc(var(--base) * 1.5) 0 0;
}
body.sheet-body:not(.section-viewer) .ins .gr-pill {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--base) * 0.75);
  min-width: 0;
  max-width: 100%;
  padding: calc(var(--base) * 0.5) calc(var(--base) * 1.25);
  border-radius: var(--radius-pill);
  background: var(--stone);
  color: var(--text);
  font-size: 11px;
  font-weight: 700;
  line-height: 16px;
}
body.sheet-body:not(.section-viewer) .ins .gr-pill > span:last-child {
  min-width: 0;
  overflow-wrap: anywhere;
}
body.sheet-body:not(.section-viewer) .ins .gr-pill-lead {
  display: inline-flex;
  flex: none;
  width: 18px;
  height: 18px;
  overflow: hidden;
  border-radius: 50%;
}
body.sheet-body:not(.section-viewer) .ins .gr-pill-lead > * {
  width: 100%;
  height: 100%;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-bar:has(.gr-record-marker) {
  position: relative;
  overflow: visible;
}
body.sheet-body:not(.section-viewer) .ins .gr-record-marker {
  position: absolute;
  top: calc(var(--base) * -0.75);
  bottom: calc(var(--base) * -0.75);
  width: 2px;
  transform: translateX(-50%);
  background: var(--text);
}
body.sheet-body:not(.section-viewer) .ins .gr-record-after {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
  margin: calc(var(--base) * 1.5) 0 0;
}

@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) .ins .gr-tile-icon {
    background: color-mix(in srgb, var(--ink, var(--forest-2)) 24%, var(--paper));
    color: color-mix(in srgb, var(--ink, var(--forest-2)) 55%, var(--dark-ins-cat-icon-ink));
  }
  body.sheet-body:not(.section-viewer) .ins :is(.gr-summary-card, .gr-people, .gr-person-pic),
  body.sheet-body:not(.section-viewer) .ins .gr-tile:not(:hover) {
    box-shadow: var(--shadow-card);
  }
}
@media (max-width: 1170px) {
  body.sheet-body:not(.section-viewer) .ins .gr-summary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) .ins .gr-tile-grid:not([data-count="2"]) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (max-width: 820px) {
  body.sheet-body:not(.section-viewer) .ins .gr-tile-grid:is(*, [data-count="2"], [data-count="3"]) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) .ins .gr-record-grid:is(*, [data-count="3"]) {
    grid-template-columns: minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) .ins .gr-people {
    gap: var(--base);
    padding: calc(var(--base) * 2);
  }
  body.sheet-body:not(.section-viewer) .ins .gr-person[type] {
    min-width: 100px;
  }
}
@media (max-width: 560px) {
  body.sheet-body:not(.section-viewer) .ins .gr-summary:is(*, [data-count="3"]) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--base);
  }
  body.sheet-body:not(.section-viewer) .ins .gr-summary-card:is(article, button[type]) {
    padding: calc(var(--base) * 2);
  }
  body.sheet-body:not(.section-viewer) .ins .gr-people {
    justify-content: space-around;
    padding: var(--base);
  }
  body.sheet-body:not(.section-viewer) .ins .gr-person[type] {
    min-width: 83px;
    padding: var(--base) calc(var(--base) / 2);
  }
  body.sheet-body:not(.section-viewer) .ins .gr-person-pic {
    width: 50px;
    height: 50px;
  }
  body.sheet-body:not(.section-viewer) .ins .gr-tile-grid:is(*, [data-count="2"], [data-count="3"]) {
    gap: var(--base);
  }
  body.sheet-body:not(.section-viewer) .ins :is(.gr-tile[type], div.gr-tile) {
    min-height: 236px;
    padding: calc(var(--base) * 2);
    border-radius: var(--radius-tile);
  }
  body.sheet-body:not(.section-viewer) .ins .gr-tile-mid {
    margin-top: calc(var(--base) * 3);
  }
  body.sheet-body:not(.section-viewer) .ins .gr-tile-mid h3 {
    font-size: 15px;
    /* 11 Nov 26: on the phone's half-width tile a long heading wraps rather than losing its words to "…". */
    white-space: normal;
  }
  body.sheet-body:not(.section-viewer) .ins .gr-tile-icon {
    width: 42px;
    height: 42px;
  }
  body.sheet-body:not(.section-viewer) .ins .gr-tile-foot {
    flex-wrap: wrap;
    row-gap: calc(var(--base) / 2);
  }
  body.sheet-body:not(.section-viewer) .ins .gr-record-figures:is(*, [data-count="2"]) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ======================================================================================================================
   Avi's rulings of 8 Nov 26 (D-521), built once (D-223):
   (1) the page's title block before its summary section, as Insurance's and Income's: a small-capitals label, the page
       name in the Georgia heading, one line, the page's main button on the right where it has one. Insurance's drawn
       values (they stood under :is(#ins-page, #pa-page, #pr-page) until 8 Nov 26); every page's own title rule is gone.
   (3) every hero's spacing between label, headline, line and chips is Insurance's: 15, 13 and 22 px at 1,440.
   ===================================================================================================================== */
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .gr-title {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: calc(var(--base) * 3);
  margin: calc(var(--base) * 4) 0 calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .gr-title .gr-title-eyebrow {
  font-size: 11px;
  font-weight: 730;
  line-height: normal;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--ins-quiet);
  margin: 0 0 calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .gr-title .gr-title-heading {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  font-size: 43.2px;
  line-height: 1.1;
  letter-spacing: -1.8px;
  margin: 0 0 calc(var(--base) * 1.375);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .gr-title .gr-title-line {
  font-size: 15px;
  line-height: 24px;
  color: var(--ins-quiet);
  margin: 0;
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-hero .ins-heroinner > .ins-eyebrow {
  line-height: normal;
  margin: 0 0 calc(var(--base) * 1.875);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-hero .ins-heroinner > h2 {
  font-size: 57.6px;
  line-height: 1.03;
  letter-spacing: -2px;
  margin: 0 0 calc(var(--base) * 1.625);
}
/* The hero's line (a classed paragraph, What's Due's caption, keeps its own size and margin). */
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-hero .ins-heroinner > p:not([class]) {
  font-size: 17px;
  line-height: 1.5;
  margin: 0 0 calc(var(--base) * 2.75);
}
body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-hero .ins-heroinner > .ins-feature-row {
  margin: 0;
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .gr-title {
    flex-direction: column;
    align-items: stretch;
  }
  body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .gr-title .gr-title-heading {
    font-size: var(--size-display);
  }
  body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-hero .ins-heroinner > h2 {
    font-size: 38px;
  }
  body.sheet-body:not(.section-viewer) :is(#ins-page, #pa-page, #pr-page, #inc-page, #debt-page, #inv-page, #due-page, #goals-page, .records-overview) .ins-hero .ins-heroinner > p:not([class]) {
    font-size: 15px;
  }
}

/* Master Records (D-526 (2); Part 16): the shared pieces' heading, switch and tiles; each registry a section of tiles. */
body.sheet-body:not(.section-viewer) .ins.master {
  margin: 0;
}

/* The heading's block runs the full width, so Add and Update sit at the right-hand end of the heading's own line
   (D-524 (1)'s place), and the headings take the dashboards' section size (28 px, on the type scale). */
body.sheet-body:not(.section-viewer) .ins.master .master-heading > div {
  flex: 1 1 auto;
  min-width: 0;
}

body.sheet-body:not(.section-viewer) .ins.master .ins-section-heading h2 {
  font-size: 28px;
}

/* On the heading's line, Add and Update take See all's compact size (the line's buttons, D-524 (1)). */
body.sheet-body:not(.section-viewer) .ins.master .master-heading .ins-heading-buttons > button {
  padding: calc(var(--base) * 1.25) calc(var(--base) * 2.5);
  font-size: 13px;
  line-height: 20px;
}

body.sheet-body:not(.section-viewer) .master-lifecycle {
  margin: calc(var(--base) * 2) 0;
}

body.sheet-body:not(.section-viewer) .master-registries {
  margin-bottom: calc(var(--base) * 4);
}

/* The registry tiles as a switch (the brief of 11 Nov 26, Part 13): the chosen registry's tile as a chosen person's
   tile is drawn (the success paper, the forest line), its state also spoken (aria-pressed), never colour alone. */
body.sheet-body:not(.section-viewer) .ins .master-registries .gr-tile[type].selected {
  background: var(--fo-success-bg);
  border-color: var(--forest-2);
}

body.sheet-body:not(.section-viewer) .master-registry {
  margin-top: calc(var(--base) * 4);
  scroll-margin-top: calc(var(--base) * 2);
}

body.sheet-body:not(.section-viewer) .master-registry h2:focus {
  outline: none;
}

body.sheet-body:not(.section-viewer) .master-count {
  margin: 0;
}

/* Add's kinds in the 480 px panel (Part 17): the shared category tiles, two to a row. */
body.sheet-body:not(.section-viewer) .ins.master-add {
  margin: 0;
}

body.sheet-body:not(.section-viewer) .ins.master-add .gr-tile-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 1.5);
}

/* D-528 (6) (the long session of 10 Nov 26, Part 5): in Insurance's policy panel look: each kind a compact card of the
   panel's grouped cards (their paper, line and corners), not a dashboard tile's height; the icon, the name and its one
   line kept. */
body.sheet-body:not(.section-viewer) .ins.master-add .gr-tile[type] {
  min-height: 0;
  padding: calc(var(--base) * 2);
  background: var(--color-card);
  border-radius: var(--radius-tile);
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) .ins.master-add .gr-tile[type]:hover {
  transform: none;
  box-shadow: none;
  border-color: var(--forest);
}
body.sheet-body:not(.section-viewer) .ins.master-add .gr-tile-mid {
  margin-top: var(--base);
}
body.sheet-body:not(.section-viewer) .ins.master-add .gr-tile-mid h3 {
  margin: 0 0 calc(var(--base) * 0.5);
  font-size: 17px;
}

/* The line under a search (Update's: where balances are updated). */
body.sheet-body:not(.section-viewer) .sheet-search-foot {
  margin: calc(var(--base) * 2) calc(var(--base) * 2) 0;
}

/* Data Assurance v3 (D-529; the restarted session of 10 Nov 26, Stage 4): Data_Assurance_Investment_Style_v3's workbench,
   a vertical Workspaces sub-navigation beside the workspace, on our own palette (cards on ivory paper, forest for the
   chosen workspace, the shared status pill .gr-status for every status, its words always beside its colour). The
   template's 9 to 10 px text is drawn at our floor, 11 px (Part 8). On the phone the sub-navigation scrolls sideways
   above the workspace, as the template's own phone layout does. Scoped to #assurance-page. */
/* The brief of 11 Nov 26, Part 17: the hero's photograph, behind the dashboards' own fade (the Records heroes'), so the
   words on the left sit on the dark side of it. */
body.sheet-body:not(.section-viewer) #assurance-page .ins-hero.da-hero {
  margin-bottom: calc(var(--base) * 4);
  background-image: linear-gradient(95deg, var(--on-photo-fill), var(--on-photo-fill-2) 55%, var(--on-photo-fill-3)), url("/photos/glass-facade-dusk.webp");
}

body.sheet-body:not(.section-viewer) #assurance-page .da-workbench {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: calc(var(--base) * 2);
  align-items: start;
}
@media (min-width: 1024px) {
  body.sheet-body:not(.section-viewer) #assurance-page .da-workbench {
    grid-template-columns: 232px minmax(0, 1fr);
    gap: calc(var(--base) * 3);
  }
  body.sheet-body:not(.section-viewer) #assurance-page .da-subnav {
    position: sticky;
    top: 16px;
  }
}
body.sheet-body:not(.section-viewer) #assurance-page .da-subnav {
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-card);
  padding: calc(var(--base) * 1.5) calc(var(--base) * 1);
}
body.sheet-body:not(.section-viewer) #assurance-page .da-navtitle {
  margin: 0;
  padding: calc(var(--base) * 1) calc(var(--base) * 1.5) calc(var(--base) * 1.5);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #assurance-page #da-subnav-items {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) #assurance-page .da-nav {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.5);
  width: 100%;
  min-height: 48px;
  margin: 0;
  padding: calc(var(--base) * 1.5);
  border: 0;
  border-radius: var(--radius-detail-button);
  background: none;
  color: var(--ins-quiet);
  text-align: left;
  font: inherit;
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-nav:hover {
  background: var(--ins-surface);
}
body.sheet-body:not(.section-viewer) #assurance-page .da-nav[aria-pressed="true"] {
  background: color-mix(in srgb, var(--forest-2) 14%, var(--paper));
  color: var(--ins-ink);
  font-weight: 700;
}
/* The line under the chosen workspace's name is read on its tint: the ink, not the muted grey (4.25:1 there, the
   closing of 10 Nov 26). */
body.sheet-body:not(.section-viewer) #assurance-page .da-nav[aria-pressed="true"] .da-navmeta {
  color: var(--ins-ink);
}
@media (max-width: 1023px) {
  body.sheet-body:not(.section-viewer) #assurance-page .da-navtitle {
    display: none;
  }
  body.sheet-body:not(.section-viewer) #assurance-page #da-subnav-items {
    flex-direction: row;
    overflow-x: auto;
    gap: calc(var(--base) * 1);
  }
  body.sheet-body:not(.section-viewer) #assurance-page .da-nav {
    width: auto;
    min-width: 136px;
    flex: 0 0 auto;
  }
}
body.sheet-body:not(.section-viewer) #assurance-page .da-navicon {
  flex: 0 0 24px;
  display: grid;
  place-items: center;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-navtxt {
  display: block;
  min-width: 0;
  font-size: 13px;
  line-height: 1.3;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-navmeta {
  display: block;
  margin-top: calc(var(--base) * 0.25);
  font-size: 11px;
  font-weight: 400;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #assurance-page .da-ncount {
  margin-left: auto;
  min-width: 24px;
  padding: calc(var(--base) * 0.25) calc(var(--base) * 1);
  border-radius: var(--radius-pill);
  background: var(--fo-review-bg);
  color: var(--fo-review-title);
  font-size: 11px;
  font-weight: 700;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
/* D-632 (1), D-640 (the overnight brief of 21-22 Nov 26, Part 11): every section heading on the page is Insurance's
   shared heading (.ins-section-heading, its rules near Insurance's); the template's own heading rules are retired. The
   space above What needs attention is kept as it was. */
body.sheet-body:not(.section-viewer) #assurance-page .da-subhead {
  margin-top: calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) #assurance-page #da-counts,
body.sheet-body:not(.section-viewer) #assurance-page #da-activity-counts {
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #assurance-page .da-section {
  background: var(--paper);
  border: 1px solid var(--ins-line);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  padding: calc(var(--base) * 2.5);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #assurance-page #da-categories {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 1.5);
  margin: calc(var(--base) * 2) 0 calc(var(--base) * 2.5);
}
@media (max-width: 479px) {
  body.sheet-body:not(.section-viewer) #assurance-page #da-categories {
    grid-template-columns: minmax(0, 1fr);
  }
}
/* The template's five category cards are compact, three to a row on the laptop (the side-by-side picture of 10 Nov 26):
   placed after the two-column rule so it holds; each card in the compact look of Master Records' Add panel (D-528 (6)),
   not a dashboard tile's height. */
@media (min-width: 1024px) {
  body.sheet-body:not(.section-viewer) #assurance-page #da-categories {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
body.sheet-body:not(.section-viewer) #assurance-page #da-categories .gr-tile {
  min-height: 0;
  padding: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #assurance-page #da-categories .gr-tile-mid {
  margin-top: var(--base);
}
body.sheet-body:not(.section-viewer) #assurance-page #da-categories .gr-tile-mid h3 {
  margin: 0 0 calc(var(--base) * 0.5);
  font-size: 17px;
  /* A category's name is never cut short ("Missing Transaction Categorisation" in a third of the workspace). */
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: calc(var(--base) * 1.5);
  padding: calc(var(--base) * 1.5) 0;
  border-bottom: 1px solid var(--ins-line);
}
body.sheet-body:not(.section-viewer) #assurance-page .da-row:last-child {
  border-bottom: 0;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-row-words {
  flex: 1 1 240px;
  min-width: 0;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-row-name {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-row-line,
body.sheet-body:not(.section-viewer) #assurance-page .da-source-meta {
  margin: calc(var(--base) * 0.25) 0 0;
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #assurance-page .da-table-wrap {
  overflow-x: auto;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-table th {
  padding: calc(var(--base) * 1);
  border-bottom: 1px solid var(--ins-line);
  text-align: left;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) #assurance-page .da-table td {
  padding: calc(var(--base) * 1.5) calc(var(--base) * 1);
  border-bottom: 1px solid var(--ins-line);
  vertical-align: middle;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-table tr:last-child td {
  border-bottom: 0;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-table .right {
  text-align: right;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-source-name {
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-table .gr-status + .da-source-meta {
  margin-top: calc(var(--base) * 0.5);
}
/* The brief of 11 Nov 26, Part 18: the activity and the category as the template draws them, measured from its running
   page (Data_Assurance_Investment_Style_v3: .coverage-strip, .ledger, .priority-row, the drawer). The coverage strip is a
   grey band, each figure bold; the table at the template's 12 px; each item one row, its title in bold over one line, its
   category's badge and Investigate on the right, a line between rows. The smallest text stays 11 px (D-508). */
body.sheet-body:not(.section-viewer) #assurance-page .da-strip {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 1.5);
  margin: calc(var(--base) * 0.5) 0 calc(var(--base) * 2);
  padding: calc(var(--base) * 1.5);
  border-radius: var(--radius-light-button);
  background: var(--ins-surface);
  color: var(--ins-quiet);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-strip b {
  color: var(--text);
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-table {
  font-size: 12px;
}
/* Part 18's template headings (Georgia 28 px for a workspace's title, the system font at 17 px for each section's) were
   retired by D-640: every heading on the page is Insurance's shared heading. */
/* Part 18: every status on the page and in its panel is the template's filled badge (.pill: 6 px corners, its family's
   tint behind its words; the 7 px corner token, the template's 6 px), its words always with it (never colour alone). */
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .gr-status {
  display: inline-flex;
  align-items: center;
  padding: calc(var(--base) * 0.625) calc(var(--base) * 0.875);
  border-radius: var(--radius-small-chip);
  background: var(--fo-success-bg, var(--stone));
  color: var(--fo-success-accent);
  font-size: 11px;
  font-weight: 700;
  line-height: normal;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .gr-status::before {
  content: none;
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .gr-status[data-level="review"] {
  background: var(--fo-review-bg);
  color: var(--fo-review-accent);
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .gr-status[data-level="critical"] {
  background: var(--fo-action-bg);
  color: var(--fo-action-accent);
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .gr-status:is([data-level="quiet"], [data-level="none"]) {
  background: var(--stone);
  color: var(--ins-quiet, var(--text-muted));
}
body.sheet-body:not(.section-viewer) #assurance-page .da-table .da-source-name {
  font-size: 12px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) #assurance-page .da-table .da-actions .ins-light-btn[type] + .ins-light-btn[type] {
  margin-left: var(--base);
}
/* The brief of 12 Nov 26, Part 11 (Avi's check of e0d6bb96, item 12): Load and Inspect stay in view on every source row.
   The table scrolls sideways in its box once the window is narrower than about 1,280 px, and the Actions column, its last,
   was then past the box's right edge, out of sight. It is held at the box's right edge, on the section's paper, so the
   other columns pass beneath it; at full width nothing moves. */
body.sheet-body:not(.section-viewer) #assurance-page .da-table :is(th, td):last-child {
  position: sticky;
  right: 0;
  background: var(--paper);
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .da-prows {
  margin: 0;
  padding: 0;
  list-style: none;
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .da-prows > .list-item.da-prow {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.5);
  padding: calc(var(--base) * 1.5) 0;
  border-top: 1px solid var(--ins-line, var(--border));
  border-bottom: 0;
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .da-prows > .list-item.da-prow:first-child {
  border-top: 0;
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .da-prow .da-row-words {
  flex: 1 1 auto;
  min-width: 0;
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .da-prow .da-row-name {
  margin: 0;
  font-size: 12px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .da-prow .da-row-line {
  margin: calc(var(--base) * 0.375) 0 0;
  font-size: 11px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .da-prow > .gr-status {
  flex: 0 0 auto;
}
body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .da-prow > button[type] {
  flex: 0 0 auto;
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .da-prows > .list-item.da-prow {
    flex-wrap: wrap;
  }
  body.sheet-body:not(.section-viewer) :is(#assurance-page, #da-detail-sheet) .da-prow .da-row-words {
    flex-basis: 100%;
  }
}
/* The panel (the template's drawer, at the panel standard, D-536 (1)): rows with the name on the left and the value on
   the right, the items in the same rows as the page, then the actions at its foot, the one primary first. */
body.sheet-body:not(.section-viewer) #da-detail-sheet .da-detail-rows {
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #da-detail-sheet .detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: calc(var(--base) * 2);
  padding: calc(var(--base) * 1.5) 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) #da-detail-sheet .detail-row span {
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) #da-detail-sheet .detail-row strong {
  text-align: right;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}
/* In the panel each item is the template's mini card (.mini-item): a line round it, 9 px corners, 13 px inside, 9 px
   between cards. */
body.sheet-body:not(.section-viewer) #da-detail-sheet .da-prows {
  display: grid;
  gap: calc(var(--base) * 1.125);
  margin-top: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) #da-detail-sheet .da-prows > .list-item.da-prow,
body.sheet-body:not(.section-viewer) #da-detail-sheet .da-prows > .list-item.da-prow:first-child {
  flex-wrap: wrap;
  padding: calc(var(--base) * 1.625);
  border: 1px solid var(--border);
  border-radius: var(--radius-chip-inner);
}
body.sheet-body:not(.section-viewer) #da-detail-sheet .da-prow .da-row-words {
  flex: 1 1 0;
}
/* The template's mini card carries no badge: the panel's title already names the category. */
body.sheet-body:not(.section-viewer) #da-detail-sheet .da-prow > .gr-status {
  display: none;
}
body.sheet-body:not(.section-viewer) #da-detail-sheet .da-detail-list-head {
  margin: calc(var(--base) * 3) 0 var(--base);
  font-size: 15px;
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) #da-detail-sheet .da-detail-note {
  margin: calc(var(--base) * 2) 0 0;
  padding: calc(var(--base) * 1.5);
  border-radius: var(--radius-light-button);
  background: var(--stone);
  color: var(--text-muted);
  font-size: 11px;
}
body.sheet-body:not(.section-viewer) #da-detail-sheet .da-detail-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--base);
  margin-top: calc(var(--base) * 3);
  padding-top: calc(var(--base) * 2);
  border-top: 1px solid var(--border);
}
body.sheet-body:not(.section-viewer) #da-detail-sheet :is(.ins-light-btn, .ins-primary-btn, .da-detail-close)[type] {
  width: auto;
  min-height: 34px;
  margin: 0;
  padding: var(--base) calc(var(--base) * 2);
  border: 1px solid var(--border);
  border-radius: var(--radius-switch);
  background: var(--color-card);
  color: var(--text);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) #da-detail-sheet .ins-primary-btn[type] {
  border-color: var(--color-accent);
  background: var(--color-accent);
  color: var(--plus-ink);
}

/* ---------------------------------------------------------------------------------------------------------------------
   Update balance (the brief of 11 Nov 26, Part 9): Quick Balance Update's search, sheet and Saved card (src/entry.ts,
   unchanged) are, from 768 px, one side panel at the panel standard (D-536 (1)): 480 px at the window's right edge,
   full height, over the page dimmed and inert behind it (src/update-panel.ts); its small-capitals label at the top
   with the round ✕ 32 px from the right edge and the ✓ beside it; the account's name in Georgia 38 under them. The
   queue stays drawn behind the panel. The phone keeps the full-screen sheet (D-504). The round "+" at the bottom right
   of every owner page opens the panel at its search (tools/tab-bar.mjs). */
body.sheet-body:not(.section-viewer) .records-quick .sheet-label {
  display: none;
}
body.sheet-body .update-fab {
  display: none;
}
body.sheet-body:not(.section-viewer):is(.vm-content, #vm-never.vm-never) .update-fab {
  position: fixed;
  right: calc(var(--base) * 4);
  bottom: calc(var(--base) * 4);
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--color-accent);
  color: var(--plus-ink);
  box-shadow: var(--shadow-card);
  text-decoration: none;
}
body.sheet-body .update-fab svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.25;
  stroke-linecap: round;
}
body.sheet-body:not(.section-viewer) .update-fab:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 3px;
}
body.sheet-body.sheet-open .update-fab,
body.sheet-body:is(.vm-entry, .vm-search, .vm-confirm, #vm-never.vm-never) .update-fab,
body.sheet-body:is(.vm-dialog, i.vm-never) .update-fab {
  display: none !important;
}
/* On the phone it sits above the floating bar, at the right (the brief of 11 Nov 26, Part 10 (1)). */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer):is(.vm-content, #vm-never.vm-never) .update-fab {
    right: calc(var(--base) * 2);
    bottom: calc(var(--base) * 12 + env(safe-area-inset-bottom));
    width: 48px;
    height: 48px;
  }
}
@media print {
  body.sheet-body .update-fab {
    display: none !important;
  }
}
@media (min-width: 768px) {
  /* The page's own [hidden] rule is !important (line 503); the queue stays drawn behind the panel. */
  body.sheet-body:not(.section-viewer).update-panel-open #choose-view[hidden] {
    display: block !important;
  }
  body.sheet-body:not(.section-viewer) .records-quick :is(#entry-form, #search-view, #confirmation):not([hidden]) {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: auto;
    z-index: 60;
    width: 480px;
    max-width: 100vw;
    margin: 0;
    padding: 0 calc(var(--base) * 4) calc(var(--base) * 4);
    overflow-y: auto;
    overscroll-behavior: contain;
    background: var(--color-card);
    border: 0;
    border-radius: var(--radius-card) 0 0 var(--radius-card);
    box-shadow: var(--shadow-panel);
    animation: panel-in 250ms ease-out;
  }
  /* Moving from one of the three to another inside the open panel does not slide it in again. */
  body.sheet-body:not(.section-viewer).update-panel-settled .records-quick :is(#entry-form, #search-view, #confirmation):not([hidden]) {
    animation: none;
  }
  body.sheet-body:not(.section-viewer) .records-quick #confirmation:not([hidden]) {
    padding-top: calc(var(--base) * 3);
  }
  body.sheet-body:not(.section-viewer) .records-quick :is(#entry-form, #search-view) .entry-bar {
    position: sticky;
    top: 0;
    z-index: 2;
    display: block;
    margin: 0 calc(var(--base) * -4) calc(var(--base) * 2);
    padding: calc(var(--base) * 3) calc(var(--base) * 4) calc(var(--base) * 2);
    background: var(--color-card);
  }
  body.sheet-body:not(.section-viewer) .records-quick :is(#entry-form, #search-view) .entry-bar::before {
    display: none;
  }
  body.sheet-body:not(.section-viewer) .records-quick .sheet-label {
    min-height: 34px;
    margin: 0;
    /* D-544 (4): between the ✕ at the left and the ✓ at the right, wrapping, never cut short. */
    display: flex;
    align-items: center;
    padding: 0 calc(var(--base) * 7); /* clear of the 34 px ✕ and ✓ */
    color: var(--ins-quiet, var(--text-muted));
    font-size: 11px;
    font-weight: 700;
    line-height: 16px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    white-space: normal;
  }
  body.sheet-body:not(.section-viewer) .records-quick #confirmation .sheet-label {
    margin-bottom: calc(var(--base) * 2);
  }
  body.sheet-body:not(.section-viewer) .records-quick .entry-bar :is(#cancel, #search-cancel) {
    position: absolute;
    top: calc(var(--base) * 3);
    left: calc(var(--base) * 4);
    right: auto;
    border-radius: 50%;
  }
  body.sheet-body:not(.section-viewer) .records-quick .entry-bar #save {
    position: absolute;
    top: calc(var(--base) * 3);
    right: calc(var(--base) * 4);
    border-radius: 50%;
  }
  body.sheet-body:not(.section-viewer) .records-quick .entry-bar :is(.entry-bar-space, #bar-title) {
    display: none;
  }
  body.sheet-body:not(.section-viewer) .records-quick #search-view .entry-bar h2 {
    margin: calc(var(--base) * 2) 0 0;
    font-family: Georgia, "Times New Roman", serif;
    font-size: var(--size-headline); /* 38 px, the Income panel's (D-536 (1)); a long one 28 px (.long-title) */
    font-weight: 400;
    line-height: 1.05;
    letter-spacing: -0.5px;
    white-space: normal;
    text-align: left;
  }
  body.sheet-body:not(.section-viewer) .records-quick #entry-form :is(#record-icon, #record-title, .record-sub) {
    margin-left: 0;
    margin-right: 0;
    text-align: left;
  }
  body.sheet-body:not(.section-viewer) .records-quick #entry-form #record-icon {
    margin-bottom: calc(var(--base) * 2);
  }
  body.sheet-body:not(.section-viewer) .records-quick #entry-form #record-title {
    margin-top: 0;
    font-family: Georgia, "Times New Roman", serif;
    font-size: var(--size-headline); /* 38 px, the Income panel's (D-536 (1)); a long one 28 px (.long-title) */
    font-weight: 400;
    line-height: 1.05;
    letter-spacing: -0.5px;
    white-space: normal;
  }
  body.sheet-body:not(.section-viewer) .records-quick #entry-form .record-sub {
    font-size: 13px;
    color: var(--text-muted);
  }
}

/* The Balance update queue (the brief of 11 Nov 26, Part 11 (1)): the shared category tiles (Insurance's), each in its
   balance sheet category's colour (D-193): the icon's square tinted with it, the icon drawn in it. The Update page's own
   four tiles and its search button stay in the page for src/entry.ts (unchanged) and src/update-panel.ts, unseen: the
   queue and the round + take their places. */
body.sheet-body:not(.section-viewer) .records-quick :is(#due-update, #search-open) {
  display: none;
}
body.sheet-body:not(.section-viewer) .records-queue-grid .gr-tile[class*="cat-"] {
  --ink: var(--cat);
  --tint: color-mix(in srgb, var(--cat) 12%, var(--paper));
}
body.sheet-body:not(.section-viewer) .records-queue .queue-as-at {
  margin: 0;
  font-size: 11px;
  color: var(--ins-quiet);
}
body.sheet-body:not(.section-viewer) .records-queue .records-queue-heading {
  margin-bottom: calc(var(--base) * 2);
}

/* ===================================================================================================================
   One base standard (D-544 (1), (2); the brief of 12 Nov 26, Part 5): every owner page's hero takes Insurance's
   measured values (archive/fidelity/2026-11-12/base-insurance.md), whichever of the two hero shapes it is built from
   (.ins-hero with .ins-heroinner, or the dashboards' .fo-hero with .fo-hero-copy). Each page keeps its own photograph,
   its fade and its words. Last in the file and led by :is(main#base, main), which counts as an id, so it outranks the
   page-by-page hero rules above (each led by one id) without naming every page; her pages are left out
   (section-viewer). The harness's basecheck measures it on every page, both screens.
   =================================================================================================================== */
body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) {
  display: flex;
  align-items: flex-end;
  min-height: 315px;
  border-radius: var(--radius-hero);
  box-shadow: 0 20px 45px var(--on-photo-shadow-7);
}
body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) > :is(.ins-heroinner, .fo-hero-copy) {
  width: 100%;
  max-width: none;
  padding: calc(var(--base) * 4.75) calc(var(--base) * 5);
}
body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) :is(.ins-eyebrow, .fo-eyebrow) {
  margin: 0 0 calc(var(--base) * 1.875);
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 12px;
  font-weight: 700;
  line-height: normal;
  letter-spacing: 2.4px;
  text-transform: uppercase;
  color: var(--on-photo-ink-4);
}
body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) :is(.ins-heroinner, .fo-hero-copy) > :is(h1, h2) {
  max-width: 760px;
  margin: 0 0 calc(var(--base) * 1.625);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 57.6px;
  font-weight: 400;
  line-height: 1.03;
  letter-spacing: -2px;
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) :is(.ins-heroinner, .fo-hero-copy) > :is(h1, h2) + p {
  max-width: 650px;
  margin: 0 0 calc(var(--base) * 2.75);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.5;
  letter-spacing: normal;
  color: var(--on-photo-ink-4);
}
body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) .ins-feature-row {
  margin: 0;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) .ins-feature {
  padding: var(--base) calc(var(--base) * 2);
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 650;
  line-height: normal;
}
/* D-544 (8): Balance Sheet's "Exchange rates of <date>" is a chip beside the count chips, the row's gap between. */
body.sheet-body:not(.section-viewer) .bs-chips .bs-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--base);
}
body.sheet-body:not(.section-viewer) .bs-chips .bs-rate-chip[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) :is(main#base, main) .fo-hero .bs-rate-chip {
  margin: 0;
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) :is(main#base, main) .fo-hero .bs-rate-chip a {
  color: inherit;
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) {
    min-height: 210px;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) :is(.ins-heroinner, .fo-hero-copy) > :is(h1, h2) {
    font-size: 38px;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) :is(.ins-heroinner, .fo-hero-copy) > :is(h1, h2) + p {
    font-size: 15px;
  }
}

/* One base standard, Part 6 (D-544; the brief of 12 Nov 26): every "What deserves attention" block, its cards, every
   tile and every summary card at Insurance's measured size; a card or tile holding more words grows, never less than
   Insurance's. Led by :is(main#base, main) as the hero block above is. */
body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel {
  padding: calc(var(--base) * 3) calc(var(--base) * 3.125);
  border-radius: var(--radius-block);
  box-shadow: 0 10px 30px var(--shadow);
}
body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-intel-top .ins-eyebrow {
  margin: 0 0 calc(var(--base) * 2);
  font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  font-size: 13px;
  font-weight: 700;
  line-height: normal;
  letter-spacing: 2.6px;
  text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-intel-top h2 {
  margin: 0 0 calc(var(--base) * 0.75);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 29px;
  font-weight: 400;
  line-height: 1.18;
  letter-spacing: -0.725px;
  text-transform: none;
}
body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-intel-top .ins-sub {
  margin: 0;
  font-size: 14px;
  font-weight: 400;
  line-height: normal;
  letter-spacing: normal;
  text-transform: none;
}
body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-tab {
  min-height: 35px;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.75);
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card {
  min-height: 208px;
  padding: calc(var(--base) * 2.75);
  border-radius: var(--radius-tile);
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) :is(main#base, main) .gr-tile-grid > * {
  min-height: 275px;
  padding: calc(var(--base) * 2.625);
  border-radius: var(--radius-card);
  box-shadow: 0 3px 13px var(--shadow-6);
}
body.sheet-body:not(.section-viewer) :is(main#base, main) .gr-summary > * {
  min-height: 135px;
  padding: calc(var(--base) * 2.875) calc(var(--base) * 3.125);
  border-radius: var(--radius-metric);
  box-shadow: 0 4px 15px var(--shadow-3);
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-tab {
    min-height: 44px;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card {
    min-height: 280px;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .gr-tile-grid > * {
    min-height: 261px;
    padding: calc(var(--base) * 2);
    border-radius: var(--radius-tile);
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .gr-summary > * {
    min-height: 124px;
    padding: calc(var(--base) * 2);
  }
}
/* In dark, Insurance's hero and attention block take the card shadow (its own page's dark rule); so does every page's. */
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero, .ins-intel) {
    box-shadow: var(--shadow-card);
  }
}

/* =====================================================================================================================
   Balance Sheet & Net Worth's body from its v14 sample (the brief of 12 Nov 26, Part 13; D-544 (7); D-508: the sample's
   drawn sizes win inside its body). FamilyOffice_Premium_v14_Complete/balance-sheet: the Explore band, then the
   workspace's .grid (1.2 to 0.8) and two .split rows (1 to 1), 22 px apart; its cards 22 px in, 24 px corners, the
   sample's faint shadow; .mini stat tiles, the .bar-stack rows, .alert cards, .table rows and .trow lists, each at the
   sample's measured size. Colours are our tokens, so dark mode takes Midnight Estate's. Headings stay Georgia at regular
   weight (ruling 2).
   ===================================================================================================================== */
body.sheet-body:not(.section-viewer) .bsw .bsw-explore {
  grid-column: 1 / -1;
  margin: calc(var(--base) * 1) 0 0;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-explore-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: calc(var(--base) * 3);
}
/* The words take the row beside the button, up to the sample's 820 px line. */
body.sheet-body:not(.section-viewer) .bsw .bsw-explore-head > div {
  flex: 1 1 auto;
  max-width: 818px;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-explore h2 {
  margin: calc(var(--base) * 0.75) 0 calc(var(--base) * 0.875);
  font-size: clamp(25px, 2.4vw, 34px);
  line-height: 1.18;
  letter-spacing: -0.65px;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-explore-line {
  max-width: 820px;
  margin: 0;
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.5;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-explore-open {
  flex: none;
  padding: calc(var(--base) * 1.5) calc(var(--base) * 2.125);
  border: 1px solid var(--bsw-explore-open-line);
  border-radius: var(--radius-detail-button);
  background: var(--bsw-explore-open-fill);
  color: var(--bsw-explore-open-ink);
  font-size: 12px;
  font-weight: 750;
  line-height: 1.5;
  white-space: nowrap;
  text-decoration: none;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-explore-chips {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 1);
  margin: calc(var(--base) * 2.125) 0 0;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-explore-chips span {
  padding: calc(var(--base) * 0.875) calc(var(--base) * 1.375);
  border: 1px solid var(--bsw-chip-line);
  border-radius: var(--radius-chip-v14);
  background: var(--bsw-chip);
  color: var(--text-muted);
  font-size: 11px;
  line-height: 15px;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-card {
  margin: 0;
  padding: calc(var(--base) * 2.75);
  border-color: var(--bsw-line);
  border-radius: var(--radius-card);
  box-shadow: 0 12px 36px var(--shadow-12);
}
body.sheet-body:not(.section-viewer) .bsw .bsw-card .fo-kicker {
  font-weight: 400;
  line-height: 1.5;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-card > .display-heading {
  margin: 0 0 calc(var(--base) * 0.75);
  font-size: 28px;
  line-height: 1.1;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-subhead {
  margin: 0 0 calc(var(--base) * 2.25);
  color: var(--text-muted);
  font-size: 15px;
}
/* D-641 (the approved demo of 22 Nov 26): the line under a shared-scale chart's heading, "Bars are drawn to the same
   scale, …", at 13 px in the muted ink, with the demo's space under it. */
body.sheet-body:not(.section-viewer) .bsw .bsw-scale {
  margin: 0 0 calc(var(--base) * 1.75);
  color: var(--text-muted);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-card .fo-kicker {
  margin-bottom: calc(var(--base) * 1.25);
}
/* The evening brief of 17 Nov 26, Part 2a (Q2): "Explore your balance sheet". The heading and its muted line on the
   left, the four-tab switch at the top right (its height is D-575's one control height, set by that rule); under them
   a light stone panel of three lines, What it tells you, A question it answers, Data (L-135's purpose line). On the
   phone the switch drops under the heading and scrolls sideways on one line. */
body.sheet-body:not(.section-viewer) .bsw .explore-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .bsw .explore-head .display-heading {
  margin: 0 0 calc(var(--base) * 0.75);
  font-size: 28px;
  line-height: 1.1;
}
body.sheet-body:not(.section-viewer) .bsw .explore-head .bsw-subhead {
  margin-bottom: 0;
}
body.sheet-body:not(.section-viewer) .bsw #explore-tabs {
  max-width: 100%;
  overflow-x: auto;
}
body.sheet-body:not(.section-viewer) .bsw .explore-purpose {
  display: grid;
  gap: var(--base);
  margin: calc(var(--base) * 2) 0;
  padding: calc(var(--base) * 2);
  border-radius: var(--radius-tile);
  background: var(--stone);
}
body.sheet-body:not(.section-viewer) .bsw .explore-purpose[hidden] {
  display: none;
}
/* D-590 (6), the overnight brief of 18 Nov 26, Part 4A (5): the tabs' purpose opens from an ⓘ beside the tab row, by
   tap; a round icon button at the switch's height on the laptop, a 44 px target on the phone (below). */
body.sheet-body:not(.section-viewer) .bsw .explore-pick {
  display: flex;
  align-items: center;
  gap: var(--base);
  max-width: 100%;
}
body.sheet-body:not(.section-viewer) .bsw .explore-pick > #explore-tabs {
  min-width: 0;
}
body.sheet-body:not(.section-viewer) .bsw .explore-info {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: var(--control-h);
  height: var(--control-h);
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
}
body.sheet-body:not(.section-viewer) .bsw .explore-info[aria-expanded="true"] {
  background: var(--stone);
  color: var(--text);
}
body.sheet-body:not(.section-viewer) .bsw .explore-info:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .bsw .explore-info {
    width: 44px;
    height: 44px;
  }
}
body.sheet-body:not(.section-viewer) .bsw .explore-purpose dt {
  margin: 0;
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) .bsw .explore-purpose dd {
  margin: 0;
  color: var(--text);
  font-size: 13px;
  line-height: 1.5;
}
body.sheet-body:not(.section-viewer) .bsw .explore-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 200px;
  margin: 0;
  border: 1px dashed var(--border);
  border-radius: var(--radius-tile);
  text-align: center;
}
body.sheet-body:not(.section-viewer) .bsw .explore-placeholder[hidden] {
  display: none;
}
/* D-641 (2), the approved demo of 22 Nov 26: Geography's and Ownership's two halves, Assets left and Debts right, side
   by side from 768 px and one under the other on the phone, then the net line under a rule. */
body.sheet-body:not(.section-viewer) .bsw .explore-halves {
  display: grid;
  grid-template-columns: 1fr;
  gap: calc(var(--base) * 4);
}
@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) .bsw .explore-halves {
    grid-template-columns: 1fr 1fr;
  }
}
body.sheet-body:not(.section-viewer) .bsw .explore-halves[hidden],
body.sheet-body:not(.section-viewer) .bsw .explore-netline[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) .bsw .explore-half {
  min-width: 0;
}
body.sheet-body:not(.section-viewer) .bsw .explore-half-head {
  margin: 0 0 calc(var(--base) * 1.25);
  color: var(--text);
  font-size: 15px;
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) .bsw .explore-netline {
  margin: calc(var(--base) * 0.75) 0 0;
  padding-top: calc(var(--base) * 1.5);
  border-top: 1px solid var(--border);
  color: var(--text);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .bsw .explore-netline b {
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) .bsw .explore-netline .explore-net-owed {
  color: var(--color-red);
}
/* The brief of 17 Nov 26, A2 and A3 (D-574, D-576): the one line under Balance Sheet's totals ("N records left out of
   these figures ›") and Allocation's "N holdings have no price … ›" are quiet text links (the text-button look, never a
   second primary), starting at the page's left edge like the line above them. */
body.sheet-body:not(.section-viewer) :is(button.bsw-left-out, button.al-price-gaps)[type] {
  display: block;
  margin: 0;
  padding: 0;
  text-align: start;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) .bsw :is(.bsw-grid, .bsw-split) {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: calc(var(--base) * 2.75);
}
@media (min-width: 1100px) {
  body.sheet-body:not(.section-viewer) .bsw .bsw-split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
}
body.sheet-body:not(.section-viewer) .bsw .bsw-stat-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 2);
  margin-bottom: calc(var(--base) * 2.25);
}
/* Four across from 1,100 px, each at least its words' width, as the sample's repeat(4, 1fr) draws them. */
@media (min-width: 1100px) {
  body.sheet-body:not(.section-viewer) .bsw .bsw-stat-row {
    grid-template-columns: repeat(4, 1fr);
  }
}
body.sheet-body:not(.section-viewer) .bsw .bsw-mini {
  padding: calc(var(--base) * 2);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-tile);
  background: linear-gradient(180deg, var(--paper), var(--stone));
}
body.sheet-body:not(.section-viewer) .bsw .bsw-mini p {
  margin: 0;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-k {
  margin-bottom: calc(var(--base) * 1.25) !important;
  color: var(--text-muted);
  font-size: 11px;
  line-height: 1.5;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-v {
  font-size: 28px;
  font-weight: 700;
  line-height: 1.08;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-d {
  margin-top: calc(var(--base) * 0.875) !important;
  color: var(--text-muted);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-none {
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .bsw .bsw-note {
  margin: calc(var(--base) * 1.75) 0 0;
  color: var(--text-muted);
  font-size: 13px;
}
/* The bar stack: our composition's group rows as the sample's .bar-item rows (name, a 16 px bar, the amount), assets
   then liabilities, with no frame of their own inside the card. */
body.sheet-body:not(.section-viewer) .bsw .bsw-bars {
  gap: calc(var(--base) * 1.5);
  margin-top: calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) .bsw .bsw-bars > .sheet-card {
  margin: 0;
  padding: calc(var(--base) * 0.75) 0;
  border: 0;
  background: none;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-bars .group-name {
  margin: 0 0 calc(var(--base) * 0.75);
  color: var(--text-muted);
  font-family: inherit;
  font-size: 11px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-bars .sheet-bar {
  display: none;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-bars .card-rows {
  display: grid;
  gap: calc(var(--base) * 1.5);
  border: 0;
  background: none;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) .bsw #composition.bsw-bars .row-button.fo-category {
  display: grid;
  /* The sample's 160 px name and 120 px amount, given back 2.65% of the row each, so the bar keeps the sample's share of
     the row at 1,440 and at 1,280 on our wider column. */
  grid-template-columns: calc(136px + 2.65%) minmax(0, 1fr) calc(120px + 2.65%);
  align-items: center;
  gap: calc(var(--base) * 1.75);
  min-height: 0;
  padding: 0;
  border: 0;
  background: none;
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) .bsw #composition.bsw-bars .fo-category .row-chevron {
  display: none;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-bars .fo-category .row-note {
  display: none;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-bars .fo-cat-bar {
  display: block;
  height: 16px;
  overflow: hidden;
  border-radius: var(--radius-pill);
  background: var(--bsw-cat-bar-fill);
}
body.sheet-body:not(.section-viewer) .bsw .bsw-bars .fo-cat-bar > span {
  display: block;
  height: 100%;
  border-radius: var(--radius-pill);
  background: linear-gradient(90deg, var(--bsw-cat-bar-fill-2), var(--nav-selected-line));
}
body.sheet-body:not(.section-viewer) .bsw .bsw-bars #liabilities-groups .fo-cat-bar > span {
  background: linear-gradient(90deg, var(--bsw-cat-bar-fill-3), var(--bsw-cat-bar-fill-4));
}
body.sheet-body:not(.section-viewer) .bsw .bsw-bars .row-value {
  text-align: right;
}
/* Review Required: the sample's .alert cards (a badge, the heading, the line and the button at the right; the source
   and second link under them); a card with something to check takes the sample's .alert.med look, its badge in words. */
body.sheet-body:not(.section-viewer) .bsw .bsw-alerts {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert {
  padding: calc(var(--base) * 2) calc(var(--base) * 2.25);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-action);
  background: linear-gradient(180deg, var(--bsw-alert-top), var(--bsw-alert-bottom));
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert.is-review {
  border-color: var(--bsw-review-line);
  background: linear-gradient(180deg, var(--bsw-review-top), var(--bsw-review-bottom));
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: calc(var(--base) * 1.75);
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert-text {
  flex: 1;
  min-width: 0;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-badge {
  display: inline-block;
  padding: calc(var(--base) * 0.875) calc(var(--base) * 1.375);
  border-radius: var(--radius-pill);
  background: var(--bsw-badge);
  color: var(--bsw-badge-ink);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert.is-review .bsw-badge {
  background: var(--bsw-review-badge);
  color: var(--bsw-review-badge-ink);
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert-heading {
  margin: calc(var(--base) * 0.75) 0 calc(var(--base) * 0.625);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.15;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert-line {
  margin: 0;
  color: var(--text-muted);
  font-size: 15px;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert-meta {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 1.5);
  margin: calc(var(--base) * 1.5) 0 0;
  color: var(--text-muted);
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-btn {
  flex: none;
  padding: calc(var(--base) * 1.375) calc(var(--base) * 1.875);
  border-radius: var(--radius-pill);
  background: var(--forest);
  color: var(--bsw-btn-ink);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}
/* Wealth movement and the liquidity bridge: the sample's .table. */
body.sheet-body:not(.section-viewer) .bsw .bsw-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-table :is(th, td) {
  padding: calc(var(--base) * 1.5) 0;
  border-bottom: 1px solid var(--bsw-line);
  line-height: 1.5;
  text-align: left;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-table th {
  color: var(--text-muted);
  border-bottom-color: var(--bsw-line);
  font-size: 11px;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-table :is(th, td):first-child {
  width: 77%;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-table :is(th, td):last-child {
  text-align: right;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-table .bsw-total td {
  font-weight: 700;
}
/* Ownership & Exposure and the snapshot: the sample's .trow rows (a name and its line, the figure at the right). */
body.sheet-body:not(.section-viewer) .bsw .bsw-list {
  display: grid;
  gap: calc(var(--base) * 0.5) calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) .bsw .bsw-list > :is(.dash-card, .bsw-row) {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: calc(var(--base) * 1.25);
  margin: 0;
  padding: calc(var(--base) * 1.75) 0;
  border: 0;
  border-bottom: 1px solid var(--bsw-line);
  border-radius: 0;
  background: none;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-list > .dash-card > .group-name {
  margin: 0;
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-list > .dash-card > .sheet-meta {
  grid-column: 1;
  margin: 0;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-list > .dash-card > .sheet-figure {
  grid-column: 2;
  grid-row: 1 / span 2;
  margin: 0;
  font-size: 15px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-row p {
  margin: 0;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-row-name,
body.sheet-body:not(.section-viewer) .bsw .bsw-row-value {
  font-size: 15px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-row-sub {
  color: var(--text-muted);
  font-size: 13px;
}
@media (max-width: 720px) {
  body.sheet-body:not(.section-viewer) .bsw .bsw-explore-head {
    flex-direction: column;
    align-items: flex-start;
  }
  body.sheet-body:not(.section-viewer) .bsw .bsw-card {
    padding: calc(var(--base) * 2.25);
  }
  body.sheet-body:not(.section-viewer) .bsw .bsw-stat-row {
    grid-template-columns: minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) .bsw .bsw-bars .fo-category {
    grid-template-columns: minmax(0, 1fr) auto 12px;
    row-gap: calc(var(--base) * 0.75);
  }
  body.sheet-body:not(.section-viewer) .bsw .bsw-bars .fo-cat-bar {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}
body.sheet-body:not(.section-viewer) .bsw .bsw-strip {
  margin-top: calc(var(--base) * 2.25);
}
/* The sample's own line, chip and alert colours (light; Midnight Estate's in dark), and its 1.2 to 0.8 grid with 22 px
   between the columns. */
body.sheet-body:not(.section-viewer) .bsw {
  --bsw-line: #ddd7ca;
  --bsw-chip: #f0f4ed;
  --bsw-chip-line: #e6e8e0;
  --bsw-alert-top: #fffefb;
  --bsw-alert-bottom: #f5f0e7;
  --bsw-review-line: #e1d4b5;
  --bsw-review-top: #fffdf8;
  --bsw-review-bottom: #f6f0e2;
  --bsw-badge: #ece7db;
  --bsw-badge-ink: #46554b;
  --bsw-review-badge: #eee3c9;
  --bsw-review-badge-ink: #755516;
}
@media (prefers-color-scheme: dark) {
  /* The day brief of 19 Nov 26, Part 2 (the look gate in dark): the line colour itself in Midnight Estate's card line, so
     every rule drawing --bsw-line (the net worth line, the benchmark's inputs line) is dark too; it was light. */
  body.sheet-body:not(.section-viewer) .bsw { --bsw-line: var(--dark-bsw-card-line); }
  body.sheet-body:not(.section-viewer) .bsw :is(.bsw-card, .bsw-mini, .bsw-alert, .bsw-explore-chips span) {
    border-color: var(--dark-bsw-card-line);
  }
  body.sheet-body:not(.section-viewer) .bsw .bsw-table :is(th, td),
  body.sheet-body:not(.section-viewer) .bsw .bsw-list > :is(.dash-card, .bsw-row) {
    border-bottom-color: var(--dark-bsw-table-line);
  }
  body.sheet-body:not(.section-viewer) .bsw .bsw-explore-chips span {
    background: var(--dark-bsw-explore-chips-fill);
  }
  body.sheet-body:not(.section-viewer) .bsw .bsw-alert {
    background: linear-gradient(180deg, var(--dark-bsw-alert-fill), var(--paper));
  }
  body.sheet-body:not(.section-viewer) .bsw .bsw-alert.is-review {
    border-color: var(--dark-bsw-is-review-line);
    background: linear-gradient(180deg, var(--dark-bsw-is-review-fill), var(--dark-bsw-is-review-fill-2));
  }
  body.sheet-body:not(.section-viewer) .bsw .bsw-badge {
    background: var(--dark-bsw-badge-fill);
    color: var(--dark-bsw-badge-ink);
  }
  body.sheet-body:not(.section-viewer) .bsw .bsw-alert.is-review .bsw-badge {
    background: var(--dark-bsw-badge-fill-2);
    color: var(--dark-bsw-badge-ink-2);
  }
}
@media (min-width: 1100px) {
  body.sheet-body:not(.section-viewer) .bsw .bsw-grid {
    grid-template-columns: 1.2fr 0.8fr;
  }
  /* The sample's two cards stop shrinking at their contents' width (611 and 295 px at 1,280, its fr columns' automatic
     minimum), so below about 1,400 px its composition keeps 611 px and Review Required 295; ours keep the same, scaled
     to our column (D-508). */
  body.sheet-body:not(.section-viewer) .bsw #bsw-workspace {
    min-width: 623px;
  }
  body.sheet-body:not(.section-viewer) .bsw section[aria-labelledby="assurance-heading"] {
    min-width: 292px;
  }
}

/* =====================================================================================================================
   Allocation's body from its v14 sample (the brief of 12 Nov 26, Part 14; D-544 (7); D-508: the sample's drawn sizes win
   inside its body). FamilyOffice_Premium_v14_Complete/allocation: the Explore band (Balance Sheet's, shared through
   .bsw), then the workspace: the toolbar (17 px corners), the photo panel (26 px), each .section with its head (24 px
   bold title, 14 px line), the .priority card (22 px), the .twocol papers (1.55 to 1, 20 px corners, 22 px in), the
   .bar-row split, the .grid3 photo cards (18 px), the .grid2 papers, the .drawer-dl rows, the .option cards and the
   .notice (14 px). Colours are our tokens: forest for the selected view and the bars (D-490), the status families for a
   breach; dark mode sets its own below. Headings in the sample's system font, as it draws them.
   ===================================================================================================================== */
body.sheet-body:not(.section-viewer) .alw {
  --alw-quiet: #f1efe8;
  --alw-prio-top: #fbf1ec;
  --alw-prio-line: #e8cdc6;
  --alw-prio-ink: #93453c;
  --alw-notice: #eef2ec;
}
body.sheet-body:not(.section-viewer) .alw .bsw-explore {
  margin: calc(var(--base) * 4) 0 0;
}
body.sheet-body:not(.section-viewer) .alw .alw-workspace {
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 4);
  font-size: 14px;
  line-height: 21px;
}
body.sheet-body:not(.section-viewer) .alw .alw-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: calc(var(--base) * 1.5);
  margin: 0 0 calc(var(--base) * 2.125);
  padding: calc(var(--base) * 1.75) calc(var(--base) * 2);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-attention);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .alw .alw-label {
  font-size: 11px;
  font-weight: 800;
  line-height: 16.5px;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .alw .alw-tabs {
  display: flex;
  gap: calc(var(--base) * 1);
}
body.sheet-body:not(.section-viewer) .alw .alw-tabs button {
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.625);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-light-button);
  background: var(--card-bg);
  color: var(--text-muted);
  font: inherit;
  font-size: 13px;
  font-weight: 750;
  line-height: 19.5px;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .alw .alw-tabs button[aria-pressed="true"] {
  border-color: var(--forest);
  background: var(--forest);
  color: var(--alw-tabs-ink);
}
body.sheet-body:not(.section-viewer) .alw .alw-tabs button:disabled {
  opacity: 1;
  cursor: default;
}
body.sheet-body:not(.section-viewer) .alw .alw-toolbar select {
  width: auto;
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 4) calc(var(--base) * 1.25) calc(var(--base) * 1.5);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-light-button);
  font-family: inherit;
  font-size: 13px;
}
body.sheet-body:not(.section-viewer) .alw .alw-toolbar-note {
  flex-basis: 100%;
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .alw .alw-pill {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--base) * 0.625);
  padding: calc(var(--base) * 0.875) calc(var(--base) * 1.375);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-chip-v14);
  background: var(--alw-quiet);
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 18px;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .alw .alw-pill.is-danger {
  border-color: var(--alw-prio-line);
  background: var(--alw-prio-top);
  color: var(--alw-prio-ink);
}
body.sheet-body:not(.section-viewer) .alw .alw-pill.is-warn {
  border-color: var(--bsw-review-line);
  background: var(--bsw-review-badge);
  color: var(--bsw-review-badge-ink);
}
/* The photo panel: our own photograph under the sample's left-to-right shade, the words and figures over the dark side. */
body.sheet-body:not(.section-viewer) .alw .alw-hero {
  position: relative;
  overflow: hidden;
  margin: 0 0 calc(var(--base) * 2.5);
  min-height: 370px;
  border-radius: var(--radius-modal);
  background: var(--on-photo-fill-42);
  box-shadow: 0 16px 42px var(--on-photo-shadow-10);
}
body.sheet-body:not(.section-viewer) .alw .alw-hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) .alw .alw-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(90deg, var(--on-photo-fill-43) 0%, var(--on-photo-fill-44) 45%, var(--on-photo-fill-45) 100%);
}
body.sheet-body:not(.section-viewer) .alw .alw-hero-contents {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 370px;
  padding: calc(var(--base) * 4.125) calc(var(--base) * 4.5);
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) .alw .alw-eyebrow {
  margin: 0;
  font-size: 11px;
  font-weight: 800;
  line-height: 16.5px;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--alw-eyebrow-ink);
}
body.sheet-body:not(.section-viewer) .alw .alw-hero h2 {
  max-width: 750px;
  margin: calc(var(--base) * 1) 0;
  font-size: clamp(30px, 3vw, 43px);
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -0.8px;
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) .alw .alw-hero-line {
  max-width: 570px;
  margin: 0;
  font-size: 15px;
  line-height: 22.5px;
  color: var(--on-photo-ink-12);
}
body.sheet-body:not(.section-viewer) .alw .alw-hero-stats {
  display: flex;
  flex-wrap: wrap;
}
body.sheet-body:not(.section-viewer) .alw .alw-hero-stat {
  min-width: 244px;
  padding: 0 calc(var(--base) * 3.375) 0 0;
}
body.sheet-body:not(.section-viewer) .alw .alw-hero-stat .alw-k {
  margin: 0 0 calc(var(--base) * 0.375);
  font-size: 13px;
  line-height: 19.5px;
  color: var(--on-photo-ink-13);
}
body.sheet-body:not(.section-viewer) .alw .alw-hero-stat .alw-v {
  margin: 0;
  font-size: clamp(26px, 2.6vw, 36px);
  font-weight: 730;
  line-height: 1.15;
  letter-spacing: -1px;
  color: var(--on-photo-ink-2);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .alw .alw-hero-stat .alw-d {
  margin: calc(var(--base) * 0.375) 0 0;
  font-size: 12px;
  line-height: 18px;
  color: var(--on-photo-ink-14);
}
/* Each section and its head. */
body.sheet-body:not(.section-viewer) .alw .alw-section {
  margin: calc(var(--base) * 3.5) 0 0;
}
body.sheet-body:not(.section-viewer) .alw .alw-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 1.75);
}
body.sheet-body:not(.section-viewer) .alw .alw-head h2 {
  margin: 0;
  font-family: inherit;
  font-size: 24px;
  font-weight: 700;
  line-height: 28.8px;
  letter-spacing: -0.6px;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) .alw .alw-head p {
  margin: calc(var(--base) * 0.375) 0 0;
  font-size: 14px;
  line-height: 21px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .alw .alw-btn {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--base) * 1.125);
  padding: calc(var(--base) * 1.5) calc(var(--base) * 2.125);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-detail-button);
  background: var(--card-bg);
  color: var(--text);
  font-size: 13px;
  font-weight: 750;
  line-height: 19.5px;
  text-decoration: none;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .alw .alw-btn.is-sm {
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.5);
  font-size: 12px;
  line-height: 18px;
}
body.sheet-body:not(.section-viewer) .alw .alw-btn.is-warn {
  border: 0;
  background: var(--alw-is-warn-fill);
  color: var(--alw-tabs-ink);
}
/* The featured breach. */
body.sheet-body:not(.section-viewer) .alw .alw-priority {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 221px;
  gap: calc(var(--base) * 3.125);
  align-items: center;
  padding: calc(var(--base) * 3.375);
  border: 1px solid var(--alw-prio-line);
  border-radius: var(--radius-action);
  background: linear-gradient(120deg, var(--alw-prio-top), var(--card-bg) 80%);
}
body.sheet-body:not(.section-viewer) .alw .alw-overline {
  margin: 0;
  font-size: 12px;
  font-weight: 850;
  line-height: 18px;
  letter-spacing: 1.1px;
  text-transform: uppercase;
  color: var(--alw-prio-ink);
}
body.sheet-body:not(.section-viewer) .alw .alw-priority h3 {
  margin: calc(var(--base) * 1.25) 0;
  font-family: inherit;
  font-size: 28px;
  font-weight: 700;
  line-height: 33.3px;
  letter-spacing: -0.8px;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) .alw .alw-priority-line {
  margin: calc(var(--base) * 1) 0;
  font-size: 16px;
  line-height: 24px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .alw .alw-summary {
  margin: calc(var(--base) * 1.125) 0 0;
  font-size: 13px;
  line-height: 19.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .alw .alw-aside {
  display: grid;
  align-self: start;
  margin-top: calc(var(--base) * 3.75);
  justify-items: stretch;
  gap: calc(var(--base) * 1);
  text-align: right;
}
body.sheet-body:not(.section-viewer) .alw .alw-big {
  margin: 0;
  justify-self: end;
  width: 215px;
  font-size: 37px;
  font-weight: 770;
  line-height: 55.5px;
  letter-spacing: -1.2px;
  color: var(--alw-prio-ink);
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .alw .alw-aside .alw-btn {
  justify-self: end;
  justify-content: center;
  min-width: 210px;
}
body.sheet-body:not(.section-viewer) .alw .alw-metric {
  flex: 0 1 auto;
  width: 337px;
}
body.sheet-body:not(.section-viewer) .alw .alw-quiet {
  margin: 0;
  padding: calc(var(--base) * 2.5) calc(var(--base) * 2.75);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-action);
  background: var(--card-bg);
  color: var(--text-muted);
}
/* The papers and their grids. */
body.sheet-body:not(.section-viewer) .alw :is(.alw-twocol, .alw-grid2, .alw-grid3) {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: calc(var(--base) * 2);
}
@media (min-width: 1000px) {
  body.sheet-body:not(.section-viewer) .alw .alw-twocol {
    grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
    align-items: start;
  }
  body.sheet-body:not(.section-viewer) .alw .alw-grid2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-items: start;
  }
  body.sheet-body:not(.section-viewer) .alw .alw-grid3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
body.sheet-body:not(.section-viewer) .alw .alw-paper {
  margin: 0;
  padding: calc(var(--base) * 2.75);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-tile);
  background: var(--card-bg);
  box-shadow: 0 12px 36px var(--shadow-12);
}
body.sheet-body:not(.section-viewer) .alw .alw-lead {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) .alw .alw-metric .alw-k {
  margin: 0;
  font-family: inherit;
  font-size: 13px;
  font-weight: 400;
  line-height: 19.5px;
  letter-spacing: 0;
  text-transform: none;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .alw .alw-strong {
  margin: 0;
  font-size: clamp(24px, 2.3vw, 33px);
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -1.1px;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .alw .alw-metric .alw-d {
  margin: 0;
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .alw .alw-line {
  height: 1px;
  margin: calc(var(--base) * 1.875) 0;
  background: var(--bsw-line);
}
body.sheet-body:not(.section-viewer) .alw .alw-footnote {
  margin: calc(var(--base) * 1.875) 0 0;
  font-size: 12px;
  line-height: 19.2px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .alw .alw-footnote:empty {
  display: none;
}
/* The split by class, the sample's .bar-row: name, bar, figures. */
body.sheet-body:not(.section-viewer) .alw .alw-bar-row {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr) auto;
  align-items: center;
  gap: calc(var(--base) * 1.625);
  padding: calc(var(--base) * 1.125) 0;
  font-size: 14px;
  line-height: 21px;
}
body.sheet-body:not(.section-viewer) .alw .alw-bar-row.row-indent .alw-bar-name {
  padding-left: calc(var(--base) * 2);
  font-weight: 400;
}
body.sheet-body:not(.section-viewer) .alw .alw-bar {
  display: block;
  height: 9px;
  overflow: hidden;
  border-radius: var(--radius-tile);
  background: var(--alw-bar-fill);
}
body.sheet-body:not(.section-viewer) .alw .alw-bar-fill {
  display: block;
  height: 100%;
  border-radius: var(--radius-tile);
  background: var(--forest);
}
body.sheet-body:not(.section-viewer) .alw .alw-pct {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: right;
  white-space: nowrap;
}
/* Against your rules, the sample's .minor policy rows: a status dot (decoration), the rule, its lines. */
body.sheet-body:not(.section-viewer) .alw #against-list .rule-block {
  display: flex;
  align-items: flex-start;
  gap: calc(var(--base) * 1.5);
  margin: 0;
  padding: calc(var(--base) * 2) 0;
  border: 0;
  border-bottom: 1px solid var(--bsw-line);
  border-radius: 0;
  background: none;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) .alw #against-list .rule-block + .rule-block {
  margin-top: calc(var(--base) * 0.5);
}
body.sheet-body:not(.section-viewer) .alw #against-list .rule-block > .rule-body {
  flex: 1 1 auto;
  min-width: 0;
}
body.sheet-body:not(.section-viewer) .alw #against-list .rule-block::before {
  content: "";
  flex: 0 0 auto;
  margin-top: calc(var(--base) * 0.625);
  width: 11px;
  height: 11px;
  border-radius: var(--radius-pill);
  background: var(--alw-rule-block-fill);
}
body.sheet-body:not(.section-viewer) .alw #against-list .rule-block.is-breach::before {
  background: var(--alw-is-breach-fill);
}
body.sheet-body:not(.section-viewer) .alw #against-list .rule-block.is-unmeasured::before {
  background: var(--alw-is-unmeasured-fill);
}
body.sheet-body:not(.section-viewer) .alw #against-list .rule-block .group-name {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  line-height: 21px;
}
body.sheet-body:not(.section-viewer) .alw .alw-later {
  margin: calc(var(--base) * 2) 0 0;
}
body.sheet-body:not(.section-viewer) .alw .alw-later ul {
  margin: calc(var(--base) * 1) 0 0;
  padding: 0;
  list-style: none;
}
body.sheet-body:not(.section-viewer) .alw .alw-later li {
  display: grid;
  gap: calc(var(--base) * 0.25);
  padding: calc(var(--base) * 1.125) 0;
  border-bottom: 1px solid var(--bsw-line);
  font-size: 13px;
  line-height: 19.5px;
}
body.sheet-body:not(.section-viewer) .alw .alw-later .placeholder-words {
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
/* Where the exposure comes from: the sample's photo cards. */
body.sheet-body:not(.section-viewer) .alw .alw-account {
  display: block;
  overflow: hidden;
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-record-tile);
  background: var(--card-bg);
  box-shadow: 0 8px 24px var(--shadow-13);
  color: var(--text);
  text-decoration: none;
}
body.sheet-body:not(.section-viewer) .alw .alw-account:hover {
  transform: translateY(-2px);
}
body.sheet-body:not(.section-viewer) .alw .alw-account-photo {
  display: block;
  width: 100%;
  height: 140px;
  object-fit: cover;
  background: var(--on-photo-fill-46);
}
body.sheet-body:not(.section-viewer) .alw .alw-copy {
  display: block;
  padding: calc(var(--base) * 2) calc(var(--base) * 2.25) calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) .alw .alw-account-name {
  display: block;
  margin: 0 0 calc(var(--base) * 0.375);
  font-size: 18px;
  font-weight: 700;
  line-height: 27px;
}
body.sheet-body:not(.section-viewer) .alw .alw-number {
  display: block;
  margin: calc(var(--base) * 1.125) 0;
  font-size: 26px;
  font-weight: 750;
  line-height: 39px;
  letter-spacing: -0.8px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .alw .alw-detail {
  display: block;
  font-size: 13px;
  line-height: 19.5px;
  color: var(--text-muted);
}
/* Drift and gross exposure. */
body.sheet-body:not(.section-viewer) .alw .alw-paper-heading {
  margin: 0 0 calc(var(--base) * 1);
  font-family: inherit;
  font-size: 20px;
  font-weight: 700;
  line-height: 30px;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) .alw .alw-tiny {
  margin: 0 0 calc(var(--base) * 1.25);
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .alw .alw-dl {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: calc(var(--base) * 1.5);
  padding: calc(var(--base) * 1.375) 0;
  border-bottom: 1px solid var(--bsw-line);
  font-size: 14px;
  line-height: 21px;
}
body.sheet-body:not(.section-viewer) .alw .alw-dl > span:last-child {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: right;
}
body.sheet-body:not(.section-viewer) .alw .alw-dl .owed {
  color: var(--color-red);
}
/* A link in a definition row reads in the row's own ink, underlined, so it keeps its contrast in dark (group C's
   closing found the forest link at 1.77:1 on the dark paper). */
body.sheet-body:not(.section-viewer) .alw .alw-dl a {
  color: inherit;
  text-decoration: underline;
}
body.sheet-body:not(.section-viewer) .alw .alw-notice {
  margin: calc(var(--base) * 1.75) 0;
  padding: calc(var(--base) * 1.875) calc(var(--base) * 2.125);
  border-radius: var(--radius-stat-box);
  background: var(--alw-notice);
  font-size: 14px;
  line-height: 21px;
  color: var(--text);
}
/* The options under a breach, the sample's .option cards. */
body.sheet-body:not(.section-viewer) .alw .alw-option {
  margin: 0;
  padding: calc(var(--base) * 1.875);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-stat-box);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .alw .alw-option h4 {
  margin: calc(var(--base) * 1.25) 0 0;
  font-size: 16px;
  font-weight: 700;
  line-height: 24px;
}
body.sheet-body:not(.section-viewer) .alw .alw-option p {
  margin: calc(var(--base) * 0.625) 0;
  font-size: 13px;
  line-height: 19.5px;
  color: var(--text-muted);
}
@media (max-width: 720px) {
  body.sheet-body:not(.section-viewer) .alw .alw-head {
    flex-wrap: wrap;
    align-items: flex-start;
  }
  body.sheet-body:not(.section-viewer) .alw .alw-hero h2 {
    font-size: 30px;
    line-height: 36px;
  }
  body.sheet-body:not(.section-viewer) .alw .alw-hero-contents {
    padding: calc(var(--base) * 3);
    gap: calc(var(--base) * 3);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-priority {
    grid-template-columns: minmax(0, 1fr);
    padding: calc(var(--base) * 2.5);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-aside {
    justify-items: start;
    text-align: left;
  }
  body.sheet-body:not(.section-viewer) .alw .alw-bar-row {
    grid-template-columns: minmax(0, 1fr) auto;
  }
  body.sheet-body:not(.section-viewer) .alw .alw-bar-row .alw-bar {
    grid-column: 1 / -1;
    grid-row: 2;
  }
}
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) .alw :is(.alw-toolbar, .alw-tabs button, .alw-toolbar select, .alw-pill, .alw-btn, .alw-paper, .alw-quiet, .alw-account, .alw-option) {
    border-color: var(--dark-alw-toolbar-line);
  }
  body.sheet-body:not(.section-viewer) .alw :is(.alw-dl, .alw-later li, #against-list .rule-block) {
    border-bottom-color: var(--dark-alw-dl-line);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-line {
    background: var(--dark-alw-line-fill);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-pill {
    background: var(--dark-alw-pill-fill);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-pill.is-danger,
  body.sheet-body:not(.section-viewer) .alw .alw-priority {
    border-color: var(--dark-alw-is-danger-line);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-pill.is-danger {
    background: var(--dark-alw-is-danger-fill);
    color: var(--dark-alw-is-danger-ink);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-pill.is-warn {
    border-color: var(--dark-alw-is-warn-line);
    background: var(--dark-alw-is-warn-fill);
    color: var(--dark-alw-is-warn-ink);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-priority {
    background: linear-gradient(120deg, var(--dark-alw-priority-fill), var(--dark-alw-priority-fill-2) 80%);
  }
  body.sheet-body:not(.section-viewer) .alw :is(.alw-overline, .alw-big) {
    color: var(--dark-alw-is-danger-ink);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-bar {
    background: var(--dark-alw-line-fill);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-bar-fill {
    background: var(--dark-alw-bar-fill-fill);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-tabs button[aria-pressed="true"] {
    border-color: var(--dark-alw-tabs-line);
    background: var(--dark-alw-bar-fill-fill);
    color: var(--dark-alw-tabs-ink);
  }
  body.sheet-body:not(.section-viewer) .alw .alw-notice {
    background: var(--dark-alw-pill-fill);
  }
}

/* =====================================================================================================================
   Spending's body from its v14 sample (the brief of 12 Nov 26, Part 15; D-544 (7), (9); D-508: the sample's drawn sizes
   win inside its body, none under 11 px). FamilyOffice_Premium_v14_Complete/spending: the Explore band (shared through
   .bsw), then the workspace: the toolbar with Spending and Commitments as its tabs (D-491), the filter bar (20 px
   corners), the hero's white card beside its photograph (27 px), each section's head, the four photo cards (23 px), the
   feature band (24 px), the two-column panels (24 px), the empty state (dashed, 24 px), the three insights (22 px) and
   the assurance band (23 px). Colours are our tokens: forest for the selected tab and the bars (D-490); dark mode sets
   its own below.
   ===================================================================================================================== */
body.sheet-body:not(.section-viewer) .spw {
  --spw-quiet: #f1efe8;
  --spw-feature: linear-gradient(125deg, #eef1ea 0%, #f7f6f0 57%, #f8f2ea 100%);
  --spw-watch: #8a5f2c;
}
body.sheet-body:not(.section-viewer) .spw .bsw-explore {
  margin: calc(var(--base) * 4) 0 0;
}
body.sheet-body:not(.section-viewer) .spw .spw-workspace {
  margin: calc(var(--base) * 3) 0 calc(var(--base) * 4);
  font-size: 14px;
  line-height: 21px;
}
body.sheet-body:not(.section-viewer) .spw .spw-toolbar,
body.sheet-body:not(.section-viewer) .spw .spw-filter {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 3);
  padding: calc(var(--base) * 1.75) calc(var(--base) * 2);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-tile);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .spw .spw-toolbar {
  justify-content: flex-start;
}
body.sheet-body:not(.section-viewer) .spw .spw-filter {
  padding: calc(var(--base) * 1.875) calc(var(--base) * 2) calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) .spw .spw-filter-side {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: calc(var(--base) * 1);
}
body.sheet-body:not(.section-viewer) .spw .spw-label {
  margin: 0 calc(var(--base) * 0.5) 0 0;
  font-size: 11px;
  font-weight: 800;
  line-height: 13.5px;
  letter-spacing: 0.3px;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-tabs {
  display: flex;
  gap: calc(var(--base) * 1);
  margin: 0;
}
body.sheet-body:not(.section-viewer) .spw .spw-tabs button {
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.625);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-light-button);
  background: var(--card-bg);
  color: var(--text-muted);
  font: inherit;
  font-size: 13px;
  font-weight: 750;
  line-height: 19.5px;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .spw .spw-tabs button[aria-pressed="true"] {
  border-color: var(--forest);
  background: var(--forest);
  color: var(--spw-tabs-ink);
}
body.sheet-body:not(.section-viewer) .spw .spw-filter select {
  width: auto;
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.375) calc(var(--base) * 4) calc(var(--base) * 1.375) calc(var(--base) * 1.5);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-panel-button);
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  line-height: normal;
}
body.sheet-body:not(.section-viewer) .spw #spw-period {
  min-width: 136px;
  opacity: 1;
}
body.sheet-body:not(.section-viewer) .spw #spw-currency {
  min-width: 128px;
}
body.sheet-body:not(.section-viewer) .spw #spw-purpose {
  min-width: 146px;
}
body.sheet-body:not(.section-viewer) .spw .spw-pill {
  display: inline-flex;
  align-items: center;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.625);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-pill);
  background: var(--spw-quiet);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 690;
  line-height: 16.5px;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .spw .spw-micro {
  font-size: 11px;
  font-weight: 800;
  line-height: 15px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-tag {
  padding: calc(var(--base) * 0.875) calc(var(--base) * 1.125);
  border-radius: var(--radius-pill);
  background: var(--spw-quiet);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 13.5px;
}
/* The hero: a white card with the month's two figures beside the photograph with its words. */
body.sheet-body:not(.section-viewer) .spw .spw-hero {
  display: grid;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 4);
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-main {
  padding: calc(var(--base) * 3.375) calc(var(--base) * 3.75) calc(var(--base) * 3.125);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-photo-hero);
  background: var(--card-bg);
  box-shadow: 0 15px 48px var(--on-photo-shadow-11);
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-top {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(var(--base) * 1);
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-main h2 {
  margin: calc(var(--base) * 1.875) 0 calc(var(--base) * 2.125);
  font-family: inherit;
  font-size: 23px;
  font-weight: 765;
  line-height: 34.5px;
  letter-spacing: -0.3px;
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-metrics {
  display: grid;
  gap: calc(var(--base) * 1.875);
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-metric {
  padding: calc(var(--base) * 0.625) calc(var(--base) * 2.5) calc(var(--base) * 0.5) 0;
}
body.sheet-body:not(.section-viewer) .spw .spw-metric-label {
  margin: 0 0 calc(var(--base) * 1.375);
  font-size: 11px;
  font-weight: 670;
  line-height: 16.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-big {
  margin: 0;
  font-size: clamp(26px, 2.55vw, 37px);
  font-weight: 790;
  line-height: 1.5;
  letter-spacing: -0.8px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .spw .spw-small {
  margin: calc(var(--base) * 1.25) 0 0;
  font-size: 11px;
  line-height: 15px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-visual {
  position: relative;
  overflow: hidden;
  min-height: 265px;
  border-radius: var(--radius-photo-hero);
  background: var(--on-photo-fill-47);
  box-shadow: 0 15px 48px var(--on-photo-shadow-11);
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-visual::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, var(--on-photo-fill-48) 0%, var(--on-photo-fill-49) 100%);
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-copy {
  position: relative;
  z-index: 1;
  max-width: 300px;
  padding: calc(var(--base) * 3.625);
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-copy .spw-micro {
  display: block;
  color: var(--on-photo-ink-15);
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-copy h3 {
  margin: calc(var(--base) * 6.25) 0 calc(var(--base) * 1.5);
  font-family: inherit;
  white-space: nowrap;
  font-size: 26px;
  font-weight: 700;
  line-height: 29.64px;
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) .spw .spw-hero-copy p {
  margin: 0;
  max-width: 300px;
  font-size: 11px;
  line-height: 17.6px;
  color: var(--on-photo-ink-15);
}
/* Each section: its eyebrow, title and line, its actions on the right. */
body.sheet-body:not(.section-viewer) .spw .spw-section {
  margin: 0 0 calc(var(--base) * 4.25);
}
/* D-632 (1), D-640 (Part 11 of the overnight brief of 21-22 Nov 26): each section's heading is Insurance's shared heading
   (.ins-section-heading); the sample's own (22 px at 790, its line at 800) is retired. Its buttons stay on its right
   (D-640 (4)), the words taking the rest of the row. */
body.sheet-body:not(.section-viewer) .spw .spw-head > div:first-child {
  flex: 1 1 0;
  min-width: 0;
}
body.sheet-body:not(.section-viewer) .spw .spw-actions {
  display: flex;
  flex: 0 0 auto;
  flex-wrap: wrap;
  gap: calc(var(--base) * 1);
}
body.sheet-body:not(.section-viewer) .spw .spw-btn {
  display: inline-flex;
  align-items: center;
  width: auto;
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.5);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-detail-button);
  background: var(--card-bg);
  color: var(--text-muted);
  font: inherit;
  font-size: 11px;
  font-weight: 740;
  line-height: 16.5px;
  text-decoration: none;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .spw .spw-btn.is-dark {
  padding: calc(var(--base) * 1.625) calc(var(--base) * 2.125);
  border: 0;
  border-radius: var(--radius-button);
  background: var(--forest);
  color: var(--spw-tabs-ink);
  font-size: 12px;
  font-weight: 710;
  line-height: 18px;
  box-shadow: 0 9px 23px var(--shadow-14);
}
body.sheet-body:not(.section-viewer) .spw .spw-btn.is-sm {
  margin: calc(var(--base) * 1.5) 0 0;
}
/* The four groups as photo cards (sql/180), each a link to its categories' table. */
body.sheet-body:not(.section-viewer) .spw .spw-photo-grid {
  display: grid;
  gap: calc(var(--base) * 1.875);
}
body.sheet-body:not(.section-viewer) .spw .spw-photo-card {
  display: block;
  overflow: hidden;
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-review);
  background: var(--card-bg);
  box-shadow: 0 4px 15px var(--on-photo-shadow-12);
  color: var(--text);
  font-size: 16px;
  line-height: 24px;
  text-decoration: none;
}
body.sheet-body:not(.section-viewer) .spw .spw-photo-card {
  transition: transform 0.22s, box-shadow 0.22s;
}
body.sheet-body:not(.section-viewer) .spw .spw-photo-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 45px var(--on-photo-shadow-13);
}
@media (prefers-reduced-motion: reduce) {
  body.sheet-body:not(.section-viewer) .spw .spw-photo-card { transition: none; }
}
body.sheet-body:not(.section-viewer) .spw .spw-photo {
  position: relative;
  display: block;
  height: 160px;
  background: var(--on-photo-fill-50);
}
body.sheet-body:not(.section-viewer) .spw .spw-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) .spw .spw-badge {
  position: absolute;
  top: calc(var(--base) * 1.5);
  left: calc(var(--base) * 1.5);
  padding: calc(var(--base) * 0.875) calc(var(--base) * 1.25);
  border-radius: var(--radius-chip-v14);
  background: var(--spw-badge-fill);
  color: var(--spw-badge-ink);
  font-size: 11px;
  font-weight: 800;
  line-height: 13.5px;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) .spw .spw-photo-body {
  display: block;
  padding: calc(var(--base) * 2.375) calc(var(--base) * 2.5) calc(var(--base) * 2.125);
}
body.sheet-body:not(.section-viewer) .spw .spw-photo-body > span {
  display: block;
}
body.sheet-body:not(.section-viewer) .spw .spw-photo-name {
  margin: 0 0 calc(var(--base) * 0.5);
  font-size: 16px;
  font-weight: 700;
  line-height: 24px;
}
body.sheet-body:not(.section-viewer) .spw .spw-photo-desc,
body.sheet-body:not(.section-viewer) .spw .spw-photo-under {
  font-size: 11px;
  line-height: 15px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-photo-desc {
  min-height: 31px;
}
body.sheet-body:not(.section-viewer) .spw .spw-photo-figure {
  margin: calc(var(--base) * 1.75) 0 calc(var(--base) * 0.375);
  font-size: 22px;
  font-weight: 780;
  line-height: 33px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .spw .spw-photo-body > .spw-photo-foot {
  display: flex;
  justify-content: space-between;
  gap: calc(var(--base) * 1);
  margin: calc(var(--base) * 2.125) 0 0;
  padding: calc(var(--base) * 1.5) 0 0;
  border-top: 1px solid var(--bsw-line);
  font-size: 11px;
  line-height: 15px;
  color: var(--text-muted);
}
/* The Commitments tab's feature band. */
body.sheet-body:not(.section-viewer) .spw .spw-feature {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2.5);
  margin: calc(var(--base) * 2.25) 0 0;
  padding: calc(var(--base) * 2.75) calc(var(--base) * 3.375);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-card);
  background: var(--spw-feature);
}
body.sheet-body:not(.section-viewer) .spw .spw-feature h3 {
  margin: calc(var(--base) * 1.125) 0 calc(var(--base) * 0.875);
  font-size: 18px;
  font-weight: 700;
  line-height: 27px;
}
body.sheet-body:not(.section-viewer) .spw .spw-feature p {
  margin: 0;
  max-width: 650px;
  font-size: 11px;
  line-height: 18.15px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-feature-actions {
  display: grid;
  justify-items: end;
  gap: calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) .spw .spw-feature .spw-watch {
  font-size: 11px;
  font-weight: 770;
  line-height: 16.5px;
  color: var(--spw-watch);
}
/* The two-column panels: the register beside the categories, the loans beside the purposes. */
body.sheet-body:not(.section-viewer) .spw .spw-twocol {
  display: grid;
  gap: calc(var(--base) * 2.125);
  margin: calc(var(--base) * 2.25) 0 0;
}
body.sheet-body:not(.section-viewer) .spw .spw-panel {
  min-width: 0;
  padding: calc(var(--base) * 2.75) calc(var(--base) * 2.875);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-card);
  background: var(--card-bg);
  box-shadow: 0 12px 36px var(--shadow-12);
}
body.sheet-body:not(.section-viewer) .spw .spw-panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(var(--base) * 1.5);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .spw .spw-panel-head h3 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  line-height: 24px;
}
body.sheet-body:not(.section-viewer) .spw .spw-panel-head p {
  margin: calc(var(--base) * 0.875) 0 0;
  font-size: 11px;
  line-height: 15.2px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-table-scroll {
  overflow-x: auto;
}
body.sheet-body:not(.section-viewer) .spw .spw-table {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .spw .spw-table th {
  padding: calc(var(--base) * 1.375) calc(var(--base) * 1.125);
  border-bottom: 1px solid var(--bsw-line);
  font-size: 11px;
  font-weight: 720;
  line-height: 15px;
  text-align: left;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-table td {
  padding: calc(var(--base) * 1.625) calc(var(--base) * 1.125);
  border-bottom: 1px solid var(--bsw-line);
  font-size: 11px;
  line-height: 16.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-table td a {
  color: var(--text);
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) .spw .spw-table .num {
  text-align: right;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .spw .spw-panel #spending-list > .sheet-card,
body.sheet-body:not(.section-viewer) .spw .spw-panel #purpose-list > .sheet-card {
  margin: 0 0 calc(var(--base) * 2);
  padding: calc(var(--base) * 0.75) 0;
  border: 0;
  box-shadow: none;
  background: transparent;
}
/* 6.2 (sql/213): the accepted statements, one panel each, apart from one another as the page's other panels are. */
body.sheet-body:not(.section-viewer) .spw .spw-statements {
  display: grid;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .spw .spw-quiet {
  margin: 0;
  font-size: 11px;
  line-height: 16.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-loan-total,
body.sheet-body:not(.section-viewer) .spw .spw-loan-line {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: calc(var(--base) * 1);
  margin: 0;
  padding: calc(var(--base) * 1.25) 0;
  border-bottom: 1px solid var(--bsw-line);
  font-size: 13px;
  line-height: 19.5px;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .spw .spw-loan-line {
  font-size: 11px;
  line-height: 16.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-loan-line a {
  color: var(--text);
  font-weight: 700;
}
/* Actual spending: the empty state until statement lines load (6.1). */
body.sheet-body:not(.section-viewer) .spw .spw-empty {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2.625);
  padding: calc(var(--base) * 4);
  border: 1px dashed var(--spw-empty-line);
  border-radius: var(--radius-card);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .spw .spw-empty-mark {
  display: grid;
  flex: 0 0 76px;
  place-items: center;
  width: 76px;
  height: 76px;
  border-radius: var(--radius-action);
  background: var(--spw-quiet);
  color: var(--text-muted);
  font-size: 34px;
  line-height: 51px;
}
body.sheet-body:not(.section-viewer) .spw .spw-empty h3 {
  margin: 0 0 calc(var(--base) * 1);
  font-size: 19px;
  font-weight: 700;
  line-height: 28.5px;
}
body.sheet-body:not(.section-viewer) .spw .spw-empty p {
  margin: 0 0 calc(var(--base) * 1);
  max-width: 615px;
  font-size: 12px;
  line-height: 21px;
  color: var(--text-muted);
}
/* The three insights, and the assurance band. */
body.sheet-body:not(.section-viewer) .spw .spw-insights {
  display: grid;
  gap: calc(var(--base) * 1.875);
  margin: calc(var(--base) * 2.75) 0 0;
}
body.sheet-body:not(.section-viewer) .spw .spw-insight {
  font-size: 16px;
  line-height: 24px;
  padding: calc(var(--base) * 2.625);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-action);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .spw .spw-emblem {
  display: grid;
  place-items: center;
  width: 39px;
  height: 39px;
  margin: 0 0 calc(var(--base) * 1.75);
  border-radius: var(--radius-button);
  background: var(--spw-quiet);
  font-size: 19px;
  line-height: 28.5px;
}
body.sheet-body:not(.section-viewer) .spw .spw-insight h3 {
  margin: 0 0 calc(var(--base) * 1);
  font-size: 14px;
  font-weight: 700;
  line-height: 21px;
}
body.sheet-body:not(.section-viewer) .spw .spw-insight p {
  margin: 0;
  font-size: 11px;
  line-height: 18.7px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .spw .spw-insight .spw-pill {
  margin: calc(var(--base) * 1.5) 0 0;
}
body.sheet-body:not(.section-viewer) .spw .spw-insight #invest-list > .sheet-card {
  margin: calc(var(--base) * 1) 0 0;
  padding: calc(var(--base) * 0.75) 0;
  border: 0;
  box-shadow: none;
  background: transparent;
}
body.sheet-body:not(.section-viewer) .spw .spw-assurance {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin: calc(var(--base) * 2.125) 0 calc(var(--base) * 4);
  padding: calc(var(--base) * 2.625) calc(var(--base) * 3);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-review);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .spw .spw-assurance h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  line-height: 22.5px;
}
body.sheet-body:not(.section-viewer) .spw .spw-assurance p {
  margin: calc(var(--base) * 0.875) 0 0;
  font-size: 11px;
  line-height: 16.5px;
  color: var(--text-muted);
}
@media (min-width: 1000px) {
  body.sheet-body:not(.section-viewer) .spw .spw-hero {
    grid-template-columns: minmax(0, 1.56fr) minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) .spw .spw-hero-metrics {
    grid-template-columns: 1fr 1fr;
  }
  body.sheet-body:not(.section-viewer) .spw .spw-photo-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) .spw .spw-twocol {
    grid-template-columns: minmax(0, 1.33fr) minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) .spw .spw-insights {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
@media (min-width: 600px) and (max-width: 999px) {
  body.sheet-body:not(.section-viewer) .spw .spw-photo-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 720px) {
  body.sheet-body:not(.section-viewer) .spw .spw-hero-main,
  body.sheet-body:not(.section-viewer) .spw .spw-panel,
  body.sheet-body:not(.section-viewer) .spw .spw-feature,
  body.sheet-body:not(.section-viewer) .spw .spw-empty {
    padding: calc(var(--base) * 2.5);
  }
  body.sheet-body:not(.section-viewer) .spw .spw-feature-actions {
    justify-items: start;
  }
  body.sheet-body:not(.section-viewer) .spw .spw-empty {
    flex-direction: column;
  }
}
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) .spw :is(.spw-toolbar, .spw-filter, .spw-tabs button, .spw-filter select, .spw-pill, .spw-btn, .spw-hero-main, .spw-photo-card, .spw-feature, .spw-panel, .spw-insight, .spw-assurance, .spw-hero-metric, .spw-photo-foot) {
    border-color: var(--on-photo-line-7);
  }
  body.sheet-body:not(.section-viewer) .spw :is(.spw-table th, .spw-table td, .spw-loan-total, .spw-loan-line) {
    border-bottom-color: var(--dark-spw-table-line);
  }
  body.sheet-body:not(.section-viewer) .spw :is(.spw-pill, .spw-tag, .spw-emblem, .spw-empty-mark) {
    background: var(--dark-spw-pill-fill);
  }
  body.sheet-body:not(.section-viewer) .spw .spw-feature {
    background: linear-gradient(125deg, var(--dark-spw-feature-fill) 0%, var(--dark-spw-feature-fill-2) 57%, var(--dark-spw-feature-fill-3) 100%);
  }
  body.sheet-body:not(.section-viewer) .spw .spw-feature .spw-watch {
    color: var(--dark-spw-watch-ink);
  }
  body.sheet-body:not(.section-viewer) .spw .spw-empty {
    border-color: var(--dark-spw-empty-line);
  }
  body.sheet-body:not(.section-viewer) .spw .spw-btn.is-dark,
  body.sheet-body:not(.section-viewer) .spw .spw-tabs button[aria-pressed="true"] {
    border-color: var(--dark-spw-is-dark-line);
    background: var(--dark-spw-is-dark-fill);
    color: var(--dark-spw-is-dark-ink);
  }
}

/* =====================================================================================================================
   Cash Flow's body from its v14 sample (the brief of 12 Nov 26, Part 16; D-544 (7); D-508: the sample's drawn sizes win
   inside its body, none under 11 px). FamilyOffice_Premium_v14_Complete/cash-flow: the Explore band (shared through
   .bsw), then the workspace: the toolbar (scenario, View in, purpose), the hero's white card beside its photograph, the
   13-week outlook (the Action Centre beside the chart), the account cards, the longer view and the purposes, each
   panel at the sample's corners. Colours are our tokens; dark mode sets its own below.
   ===================================================================================================================== */
body.sheet-body:not(.section-viewer) .cfw {
  --cfw-quiet: #f1efe8;
  --cfw-warm: #fbf7f1;
  --cfw-warm-line: #e8dacc;
  --cfw-warm-ink: #8a5a3c;
  --cfw-line-ink: #4f7d63;
}
body.sheet-body:not(.section-viewer) .cfw .bsw-explore {
  margin: calc(var(--base) * 4) 0 0;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-workspace {
  margin: calc(var(--base) * 3.25) 0 calc(var(--base) * 4);
  font-size: 16px;
  line-height: 24px;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: calc(var(--base) * 1.125);
  margin: 0 0 calc(var(--base) * 2.75);
  padding: calc(var(--base) * 1.625) calc(var(--base) * 2.125);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-tile);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-label {
  margin: 0;
  font-size: 11px;
  font-weight: 850;
  line-height: 16.5px;
  letter-spacing: 1.1px;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-seg {
  display: flex;
  gap: calc(var(--base) * 0.375);
  margin: 0;
  padding: calc(var(--base) * 0.375);
  border-radius: var(--radius-panel-button);
  background: var(--cfw-quiet);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-seg button {
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.75);
  border: 0;
  border-radius: var(--radius-tab-inner);
  background: transparent;
  color: var(--text-muted);
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  line-height: 18px;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-seg button[aria-pressed="true"] {
  background: var(--card-bg);
  color: var(--text);
  box-shadow: 0 2px 8px var(--shadow-15);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-seg button:disabled {
  opacity: 1;
  cursor: not-allowed;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-toolbar select {
  width: auto;
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.375);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-light-button);
  background: var(--card-bg);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  font-weight: 750;
  line-height: 19.5px;
}
body.sheet-body:not(.section-viewer) .cfw :is(.cfw-pill, .cfw-tag) {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--base) * 0.625);
  margin: 0;
  padding: calc(var(--base) * 0.75) calc(var(--base) * 1.125);
  border-radius: var(--radius-chip-v14);
  background: var(--cfw-quiet);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 800;
  line-height: 16.5px;
  letter-spacing: 0.1px;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-pill {
  padding: calc(var(--base) * 1.375) calc(var(--base) * 1.625);
  border: 1px solid var(--bsw-line);
  background: var(--card-bg);
  font-size: 12px;
  font-weight: 750;
  line-height: 18px;
}
/* The hero: the white card beside its photograph. */
body.sheet-body:not(.section-viewer) .cfw .cfw-hero {
  display: grid;
  gap: calc(var(--base) * 2.25);
  margin: 0 0 calc(var(--base) * 3.875);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-main {
  min-width: 0;
  padding: calc(var(--base) * 3) calc(var(--base) * 3.625) calc(var(--base) * 2.5);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-block);
  background: var(--card-bg);
  box-shadow: 0 12px 37px var(--on-photo-shadow-14);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-eyebrow {
  margin: 0;
  font-size: 11px;
  font-weight: 850;
  line-height: 16.5px;
  letter-spacing: 1.55px;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-main h2 {
  margin: calc(var(--base) * 1.25) 0 calc(var(--base) * 2.125);
  font-family: inherit;
  font-size: 27px;
  font-weight: 700;
  line-height: 30.78px;
  letter-spacing: -1.15px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 1.875);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-stat {
  min-width: 0;
  padding-left: calc(var(--base) * 1.875);
  border-left: 1px solid var(--bsw-line);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-stat:first-child {
  padding-left: 0;
  border-left: 0;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-stat:nth-child(3) {
  grid-column: 1 / -1;
  padding: calc(var(--base) * 1.5) 0 0;
  border-left: 0;
  border-top: 1px solid var(--bsw-line);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-stat small {
  display: block;
  margin: 0 0 calc(var(--base) * 1);
  font-size: 12px;
  line-height: 15.6px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-stat b {
  display: block;
  overflow-wrap: anywhere;
  font-size: clamp(20px, 1.95vw, 28px);
  font-weight: 800;
  line-height: 1.5;
  letter-spacing: -1px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-stat em {
  display: block;
  margin: calc(var(--base) * 0.5) 0 0;
  font-size: 11.5px;
  font-style: normal;
  line-height: 17.25px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .owed {
  color: var(--color-red);
}
/* Each owed figure named in its own rule, so no later rule of the figure's own can take its red (Part 8's rule). */
body.sheet-body:not(.section-viewer) .cfw .cfw-amount.owed {
  color: var(--color-red);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-figure.owed {
  color: var(--color-red);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-foot {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 0.875);
  margin: calc(var(--base) * 1.25) 0 0;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-foot .cfw-tag {
  line-height: 15px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.375);
  width: 100%;
  min-height: 81px;
  margin: calc(var(--base) * 1.625) 0 0;
  padding: calc(var(--base) * 1.75) calc(var(--base) * 1.625);
  border: 1px solid var(--cfw-warm-line);
  border-radius: var(--radius-button);
  background: var(--cfw-warm);
  color: var(--text);
  font: inherit;
  text-align: left;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action-mark {
  display: grid;
  flex: 0 0 29px;
  place-items: center;
  width: 29px;
  height: 29px;
  border-radius: 50%;
  background: var(--on-photo-fill-51);
  color: var(--cfw-warm-ink);
  font-size: 15px;
  font-weight: 900;
  line-height: 22.5px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action strong {
  display: block;
  margin: 0 0 calc(var(--base) * 0.375);
  font-size: 16px;
  font-weight: 700;
  line-height: 24px;
  letter-spacing: -0.25px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action small {
  display: block;
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action-arrow {
  margin-left: auto;
  font-size: 12px;
  font-weight: 800;
  line-height: 18px;
  white-space: nowrap;
  color: var(--cfw-warm-ink);
}
body.sheet-body:not(.section-viewer) .cfw :is(.cfw-hero-calm, .cfw-calm) {
  margin: calc(var(--base) * 1.625) 0 0;
  font-size: 13px;
  line-height: 21.45px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-cover {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  overflow: hidden;
  min-height: 358px;
  padding: calc(var(--base) * 3.875) calc(var(--base) * 4);
  border-radius: var(--radius-block);
  background: var(--on-photo-fill-52);
  box-shadow: 0 14px 42px var(--on-photo-shadow-15);
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-cover img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, var(--on-photo-fill-48) 0%, var(--on-photo-fill-53) 85%);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-cover > :not(img) {
  position: relative;
  z-index: 1;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-tiny {
  margin: 0;
  font-size: 12px;
  font-weight: 850;
  line-height: 18px;
  letter-spacing: 1.45px;
  text-transform: uppercase;
  color: var(--cfw-tiny-ink);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-cover h3 {
  max-width: 300px;
  margin: calc(var(--base) * 10) 0 calc(var(--base) * 1.5);
  font-family: inherit;
  font-size: clamp(30px, 3.25vw, 46.8px);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -1.6px;
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-cover p:not(.cfw-tiny) {
  max-width: 310px;
  margin: 0 0 calc(var(--base) * 1.875);
  font-size: 15px;
  line-height: 24px;
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-cover-btn {
  margin-top: auto;
  padding: calc(var(--base) * 1.75) calc(var(--base) * 2.25);
  border-radius: var(--radius-panel-button);
  background: var(--on-photo-fill-54);
  color: var(--on-photo-ink-16);
  font-size: 13px;
  font-weight: 850;
  line-height: 19.5px;
  text-decoration: none;
}
/* Each section's head, its panels and their parts. */
body.sheet-body:not(.section-viewer) .cfw .cfw-section {
  margin: calc(var(--base) * 4.75) 0 0;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-head > div:first-child {
  flex: 1 1 0;
  min-width: 260px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-head h2 {
  margin: calc(var(--base) * 1) 0 calc(var(--base) * 0.75);
  font-family: inherit;
  font-size: clamp(26px, 2.8vw, 36px);
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: -1.4px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-head p:not(.cfw-eyebrow) {
  margin: calc(var(--base) * 0.5) 0;
  font-size: 14px;
  line-height: 22.4px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-actions {
  display: flex;
  flex: none;
  flex-wrap: wrap;
  align-items: center;
  gap: calc(var(--base) * 1);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-btn {
  display: inline-flex;
  align-items: center;
  gap: calc(var(--base) * 0.875);
  margin: 0;
  padding: calc(var(--base) * 1.375) calc(var(--base) * 1.625);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-panel-button);
  background: var(--card-bg);
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 750;
  line-height: 18px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-btn.cfw-right {
  margin-left: auto;
}
body.sheet-body:not(.section-viewer) .cfw :is(.cfw-panels, .cfw-lower) {
  display: grid;
  gap: calc(var(--base) * 2.25);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-lower {
  margin: calc(var(--base) * 2.125) 0 0;
  gap: calc(var(--base) * 2.125); /* 17 px, the Cash Flow sample's lower rows (D-569's layout standard, D-508) */
}
body.sheet-body:not(.section-viewer) .cfw .cfw-panel {
  min-width: 0;
  padding: calc(var(--base) * 3) calc(var(--base) * 3.25);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-review);
  background: var(--card-bg);
  box-shadow: 0 12px 36px var(--shadow-12);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-panel-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(var(--base) * 1.125);
  margin: 0 0 calc(var(--base) * 1.875);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-panel h3 {
  margin: 0 0 calc(var(--base) * 0.625);
  font-size: 21px;
  font-weight: 700;
  line-height: 31.5px;
  letter-spacing: -0.7px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-panel-top p {
  margin: 0;
  font-size: 13px;
  line-height: 21.45px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-chart {
  height: 330px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-chart svg {
  width: 100%;
  height: 100%;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-grid {
  stroke: var(--bsw-line);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-zero {
  stroke: var(--color-red);
  stroke-dasharray: 5 5;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-axis {
  fill: var(--text-muted);
  font-size: 11px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-line {
  fill: none;
  stroke: var(--cfw-line-ink);
  stroke-width: 3.5;
  stroke-linejoin: round;
  stroke-linecap: round;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-legend {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 2.125);
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: calc(var(--base) * 0.75);
  border-radius: 50%;
  background: var(--cfw-line-ink);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-dot.is-zero {
  background: var(--color-red);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-footnote {
  margin: calc(var(--base) * 1.5) 0 0;
  font-size: 13px;
  line-height: 21.45px;
  color: var(--text-muted);
}
/* The Action Centre: the first account below zero as the sample's priority card, the rest as its smaller rows. */
body.sheet-body:not(.section-viewer) .cfw .cfw-overline {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.125);
  margin: 0 0 calc(var(--base) * 1.625);
  font-size: 11px;
  font-weight: 850;
  line-height: 16.5px;
  letter-spacing: 1.25px;
  text-transform: uppercase;
  color: var(--cfw-warm-ink);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-pulse {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cfw-pulse-fill);
  box-shadow: 0 0 0 4px var(--shadow-16);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority {
  margin: 0;
  padding: calc(var(--base) * 2.75) calc(var(--base) * 2.75) calc(var(--base) * 2.25);
  border: 1px solid var(--cfw-warm-line);
  border-radius: var(--radius-record-tile);
  background: var(--cfw-warm);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 1.25);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-over {
  font-size: 11px;
  font-weight: 850;
  line-height: 16.5px;
  letter-spacing: 1.25px;
  text-transform: uppercase;
  color: var(--cfw-warm-ink);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-state {
  padding: calc(var(--base) * 0.875) calc(var(--base) * 1.125);
  border: 1px solid var(--cfw-priority-state-line);
  border-radius: var(--radius-chip-v14);
  font-size: 11px;
  font-weight: 850;
  line-height: 15px;
  letter-spacing: 0.7px;
  text-transform: uppercase;
  color: var(--cfw-warm-ink);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority h4 {
  margin: calc(var(--base) * 2.25) 0 calc(var(--base) * 1.125);
  font-size: clamp(20px, 2.2vw, 29px);
  font-weight: 780;
  line-height: 1.16;
  letter-spacing: -1px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-figure {
  margin: 0;
  overflow-wrap: anywhere;
  font-size: clamp(30px, 3.6vw, 51px);
  font-weight: 830;
  line-height: 1.06;
  letter-spacing: -1.8px;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-figure span {
  display: block;
  margin: calc(var(--base) * 0.75) 0 0;
  font-size: 13px;
  font-weight: 650;
  line-height: 17.55px;
  letter-spacing: 0;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-summary {
  margin: calc(var(--base) * 1.75) 0 calc(var(--base) * 2.25);
  font-size: 15px;
  line-height: 23.25px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-dates {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: calc(var(--base) * 1.5);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-dates > div {
  padding: calc(var(--base) * 1.5) calc(var(--base) * 1.625);
  border: 1px solid var(--cfw-priority-dates-line);
  border-radius: var(--radius-detail-button);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-dates small {
  display: block;
  margin: 0 0 calc(var(--base) * 0.875);
  font-size: 11px;
  font-weight: 800;
  line-height: 15px;
  letter-spacing: 1.1px;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-dates strong {
  font-size: 16px;
  font-weight: 700;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 1.75);
  width: 100%;
  min-height: 60px;
  margin: 0;
  padding: calc(var(--base) * 1.875) calc(var(--base) * 2.125);
  border: 0;
  border-radius: var(--radius-panel-button);
  background: var(--forest);
  color: var(--cfw-tiny-ink);
  font: inherit;
  font-size: 15px;
  font-weight: 800;
  line-height: 22.5px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-evidence {
  margin: calc(var(--base) * 1.5) 0 0;
  font-size: 11px;
  line-height: 18.15px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-secondary {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 1.625);
  width: 100%;
  min-height: 0;
  margin: calc(var(--base) * 1.125) 0 0;
  padding: calc(var(--base) * 1.875) calc(var(--base) * 1.75);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-button);
  background: var(--card-bg);
  color: var(--text);
  font: inherit;
  text-align: left;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-secondary-mark {
  display: grid;
  flex: 0 0 39px;
  place-items: center;
  width: 39px;
  height: 39px;
  border-radius: var(--radius-light-button);
  background: var(--cfw-warm);
  color: var(--cfw-warm-ink);
  font-size: 19px;
  font-weight: 800;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-secondary small {
  display: block;
  margin: 0 0 calc(var(--base) * 0.625);
  font-size: 11px;
  font-weight: 800;
  line-height: 15px;
  letter-spacing: 1.15px;
  text-transform: uppercase;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-secondary strong {
  display: block;
  margin: 0 0 calc(var(--base) * 0.75);
  font-size: 14px;
  font-weight: 700;
  line-height: 17.5px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-secondary em {
  display: block;
  font-size: 12px;
  font-style: normal;
  line-height: 16.2px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-secondary-arrow {
  margin-left: auto;
  font-size: 18px;
  line-height: 27px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action {
  transition: background 0.2s;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action:hover {
  background: var(--on-photo-fill-55);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-priority-button:hover {
  background: var(--forest-2);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-secondary:hover {
  background: var(--cfw-quiet);
}
@media (prefers-reduced-motion: reduce) {
  body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action { transition: none; }
}
/* The account cards. */
body.sheet-body:not(.section-viewer) .cfw .cfw-accounts {
  display: grid;
  gap: calc(var(--base) * 2.125);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-account {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-metric);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-cover {
  position: relative;
  height: 151px;
  overflow: hidden;
  background: var(--on-photo-fill-56);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-cover::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, var(--on-photo-fill-57), transparent);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-country {
  position: absolute;
  z-index: 1;
  bottom: calc(var(--base) * 1.5);
  left: calc(var(--base) * 2);
  font-size: 12px;
  font-weight: 850;
  line-height: 18px;
  letter-spacing: 1.3px;
  text-transform: uppercase;
  color: var(--cfw-tiny-ink);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-account-body {
  padding: calc(var(--base) * 2.5) calc(var(--base) * 2.625) calc(var(--base) * 2.75);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-account .cash-card-name {
  margin: 0;
  font-size: 16px;
  font-weight: 780;
  line-height: 24px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-sub {
  margin: calc(var(--base) * 0.75) 0 calc(var(--base) * 1.25);
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-amount {
  margin: 0;
  font-size: 31px;
  font-weight: 790;
  line-height: 46.5px;
  letter-spacing: -0.7px;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-account .cash-line {
  display: block;
  width: 100%;
  height: 64px;
  margin: calc(var(--base) * 1) 0 0;
}
body.sheet-body:not(.section-viewer) .cfw :is(.cfw-small, .cash-status) {
  margin: calc(var(--base) * 1) 0 0;
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-minifoot {
  display: flex;
  flex-wrap: wrap;
  gap: calc(var(--base) * 0.5);
  margin: calc(var(--base) * 1.375) 0 0;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-account .row-button {
  margin: calc(var(--base) * 1.5) 0 0;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-by-currency {
  margin: calc(var(--base) * 2.125) 0 0;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-by-currency .due-block {
  margin: calc(var(--base) * 1) 0 0;
  box-shadow: none;
}
/* The longer view, the purposes and the assurance rows. */
body.sheet-body:not(.section-viewer) .cfw .cfw-empty {
  display: grid;
  place-items: center;
  min-height: 200px;
  padding: calc(var(--base) * 3);
  border: 1px dashed var(--bsw-line);
  border-radius: var(--radius-tile);
  text-align: center;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-empty p {
  margin: 0;
  font-size: 13px;
  line-height: 21.45px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-notice {
  margin: calc(var(--base) * 2) 0 0;
  padding: calc(var(--base) * 1.625) calc(var(--base) * 1.75);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-button);
  background: var(--cfw-quiet);
  font-size: 13px;
  line-height: 21.45px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-purposes {
  display: grid;
  gap: calc(var(--base) * 1.625);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-purpose {
  display: flex;
  align-items: flex-start;
  gap: calc(var(--base) * 1.875);
  padding: calc(var(--base) * 2.5);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-tile);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-emblem {
  padding: calc(var(--base) * 1.875);
  border-radius: var(--radius-button);
  background: var(--cfw-quiet);
  font-size: 23px;
  line-height: 34.5px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-purpose strong {
  font-size: 16px;
  font-weight: 700;
  line-height: 24px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-purpose p {
  margin: calc(var(--base) * 0.875) 0;
  font-size: 13px;
  line-height: 20.8px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 1.5);
  padding: calc(var(--base) * 1.625) 0;
  border-bottom: 1px solid var(--bsw-line);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-row strong {
  font-size: 13px;
  font-weight: 700;
  line-height: 19.5px;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-row small {
  display: block;
  margin: calc(var(--base) * 0.625) 0 0;
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-row .cfw-tag {
  flex: none;
}
body.sheet-body:not(.section-viewer) .cfw .cfw-left-out .left-out {
  margin: 0;
  padding: calc(var(--base) * 1.625) 0;
  border-bottom: 1px solid var(--bsw-line);
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .cfw .cfw-left-out > :last-child {
  border-bottom: 0;
}
@media (min-width: 1000px) {
  body.sheet-body:not(.section-viewer) .cfw .cfw-hero {
    grid-template-columns: minmax(0, 0.905fr) minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-panels {
    grid-template-columns: minmax(0, 0.95fr) minmax(0, 1fr);
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-chart-panel {
    order: 2;
  }
  body.sheet-body:not(.section-viewer) .cfw :is(.cfw-accounts, .cfw-purposes) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-lower {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (min-width: 600px) and (max-width: 999px) {
  body.sheet-body:not(.section-viewer) .cfw .cfw-accounts {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 720px) {
  body.sheet-body:not(.section-viewer) .cfw :is(.cfw-hero-main, .cfw-panel, .cfw-hero-cover) {
    padding: calc(var(--base) * 2.5);
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-head h2 {
    font-size: 28px;
    line-height: 36px;
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-hero-cover h3 {
    margin-top: calc(var(--base) * 4);
    font-size: 34px;
    line-height: 38px;
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-chart {
    height: 220px;
  }
}
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) .cfw {
    --cfw-warm-ink: #e8c39f;
    --cfw-line-ink: #8fc4a3;
  }
  body.sheet-body:not(.section-viewer) .cfw :is(.cfw-seg, .cfw-pill, .cfw-tag, .cfw-notice, .cfw-emblem, .cfw-secondary:hover) {
    background: var(--dark-cfw-seg-fill);
  }
  body.sheet-body:not(.section-viewer) .cfw :is(.cfw-hero-action, .cfw-priority, .cfw-secondary-mark) {
    background: var(--on-photo-fill-58);
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action:hover {
    background: var(--on-photo-fill-59);
  }
  body.sheet-body:not(.section-viewer) .cfw :is(.cfw-hero-action, .cfw-priority) {
    border-color: var(--on-photo-line-8);
  }
  body.sheet-body:not(.section-viewer) .cfw :is(.cfw-toolbar, .cfw-toolbar select, .cfw-pill, .cfw-btn, .cfw-hero-main, .cfw-panel, .cfw-account, .cfw-purpose, .cfw-secondary, .cfw-notice, .cfw-empty, .cfw-row, .cfw-left-out .left-out, .cfw-stat) {
    border-color: var(--on-photo-line-7);
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-priority-dates > div {
    border-color: var(--dark-cfw-priority-dates-line);
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-hero-action-mark {
    background: var(--on-photo-fill-60);
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-priority-button {
    background: var(--dark-cfw-priority-button-fill);
    color: var(--dark-cfw-priority-button-ink);
  }
  body.sheet-body:not(.section-viewer) .cfw .cfw-priority-state {
    border-color: var(--dark-cfw-priority-state-line);
  }
}

/* =====================================================================================================================
   Tax's body from its v14 sample (the brief of 12 Nov 26, Part 17; D-544 (7); Tax v2, "Insurance-style"; D-508: the
   sample's drawn sizes win inside its body, none under 11 px). FamilyOffice_Premium_v14_Complete/tax: the Explore band
   (shared through .bsw), then the workspace: the selector row, three counts, People & taxpayers, the jurisdiction cards,
   Documents by country and year, Tax review; a country's file (its hero, filters, tabs and panels) in the home's place.
   Colours are our tokens; dark mode sets its own below. No tax figure is drawn anywhere.
   ===================================================================================================================== */
body.sheet-body:not(.section-viewer) .txw {
  --txw-quiet: #f1efe8;
  --txw-mint: #e7f0e6;
  --txw-mint-line: #95b19e;
  --txw-warn-ink: #8a5a2c;
  --txw-good-ink: #2f6b55;
}
body.sheet-body:not(.section-viewer) .txw .bsw-explore {
  margin: calc(var(--base) * 4) 0 0;
}
body.sheet-body:not(.section-viewer) .txw .txw-workspace {
  margin: calc(var(--base) * 3.25) 0 calc(var(--base) * 4);
  font-size: 15px;
  line-height: 22.5px;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) .txw .txw-readline .sheet-meta {
  margin: 0 0 calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) .txw :is(.txw-selectors, .txw-filters) {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: calc(var(--base) * 1.5);
  margin: 0 0 calc(var(--base) * 2.5);
  padding: calc(var(--base) * 1.875) calc(var(--base) * 2.25);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-record-tile);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .txw .txw-select {
  display: flex;
  flex-direction: column;
  gap: calc(var(--base) * 0.5);
  margin: 0;
  font-size: 11px;
  font-weight: 780;
  line-height: 16.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-select select {
  width: auto;
  min-width: 164px;
  max-width: 240px;
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.25);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-panel-button);
  background: var(--card-bg);
  color: var(--text);
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  line-height: 21px;
}
body.sheet-body:not(.section-viewer) .txw .txw-period {
  flex: 1;
  min-width: 180px;
  margin: 0;
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw :is(.txw-btn, .txw-tag) {
  display: inline-flex;
  align-items: center;
  margin: 0;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 1.75);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-detail-button);
  background: var(--card-bg);
  color: var(--text);
  font-size: 12px;
  font-weight: 740;
  line-height: 18px;
  text-decoration: none;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .txw .txw-btn.is-waiting {
  background: var(--txw-quiet);
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-tag {
  padding: calc(var(--base) * 0.625) calc(var(--base) * 1.125);
  border-radius: var(--radius-chip-v14);
  background: var(--txw-quiet);
  font-size: 11px;
  font-weight: 730;
  line-height: 16.5px;
}
body.sheet-body:not(.section-viewer) .txw .txw-metrics {
  display: grid;
  gap: calc(var(--base) * 2);
  margin: 0 0 calc(var(--base) * 4);
}
body.sheet-body:not(.section-viewer) .txw .txw-metric {
  min-height: 129px;
  margin: 0;
  padding: calc(var(--base) * 2.625) calc(var(--base) * 3);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-action);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .txw .txw-metric-label {
  margin: 0;
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-metric-figure {
  margin: calc(var(--base) * 1.75) 0 0;
  font-size: 30px;
  font-weight: 700;
  line-height: 34.5px;
  letter-spacing: -0.8px;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .txw .txw-metric-help {
  margin: calc(var(--base) * 0.625) 0 0;
  font-size: 11px;
  line-height: 16.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-section {
  margin: 0 0 calc(var(--base) * 4.125);
}
/* D-632 (1), D-640 (Part 11 of the overnight brief of 21-22 Nov 26): every section heading on Tax, home and country file
   alike, is Insurance's shared heading (.ins-section-heading); the sample's own heading rules are retired. */
body.sheet-body:not(.section-viewer) .txw .txw-counter {
  flex-shrink: 0;
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-people {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 2.125);
  padding: calc(var(--base) * 2.375) calc(var(--base) * 2.75);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-card);
  background: var(--card-bg);
}
body.sheet-body:not(.section-viewer) .txw .txw-person {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: calc(var(--base) * 0.625);
  flex: none;
  width: auto;
  min-width: 119px;
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.25) calc(var(--base) * 2);
  border: 1px solid transparent;
  border-radius: var(--radius-attention);
  background: transparent;
  color: var(--text);
  font: inherit;
  transition: transform 0.19s, border-color 0.19s, background-color 0.19s;
}
body.sheet-body:not(.section-viewer) .txw button.txw-person:hover {
  transform: translateY(-3px);
  background: var(--txw-quiet);
}
body.sheet-body:not(.section-viewer) .txw .txw-person.is-active {
  border-color: var(--txw-mint-line);
  background: var(--txw-mint);
}
body.sheet-body:not(.section-viewer) .txw .txw-person.is-waiting .txw-avatar {
  opacity: 0.6;
}
body.sheet-body:not(.section-viewer) .txw .txw-avatar {
  display: grid;
  place-items: center;
  width: 68px;
  height: 68px;
  overflow: hidden;
  border: 3px solid var(--card-bg);
  border-radius: var(--radius-pill);
  box-shadow: 0 3px 13px var(--shadow-17);
}
body.sheet-body:not(.section-viewer) .txw .txw-avatar svg {
  width: 100%;
  height: 100%;
}
body.sheet-body:not(.section-viewer) .txw .txw-person b {
  font-size: 12px;
  line-height: 18px;
}
body.sheet-body:not(.section-viewer) .txw .txw-person small {
  font-size: 11px;
  line-height: 16.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-world {
  display: grid;
  gap: calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .txw .txw-country {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  min-height: 262px;
  margin: 0;
  padding: calc(var(--base) * 2.75);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-card);
  background: var(--card-bg);
  color: var(--text);
  font: inherit;
  text-align: left;
  box-shadow: 0 3px 14px var(--shadow-18);
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
body.sheet-body:not(.section-viewer) .txw .txw-country[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) .txw .txw-country:hover {
  transform: translateY(-5px);
  border-color: var(--txw-country-line);
  box-shadow: 0 20px 42px var(--shadow-19);
}
body.sheet-body:not(.section-viewer) .txw .txw-arrow {
  position: absolute;
  top: calc(var(--base) * 2.125);
  right: calc(var(--base) * 2.625);
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-art {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  margin: 0 0 calc(var(--base) * 2.375);
  border-radius: var(--radius-cat-icon);
  background: var(--txw-mint);
  color: var(--forest-ink);
}
body.sheet-body:not(.section-viewer) .txw .txw-country[data-country="AU"] .txw-art {
  background: var(--txw-art-fill);
  color: var(--txw-art-ink);
}
body.sheet-body:not(.section-viewer) .txw .txw-country[data-country="IN"] .txw-art {
  background: var(--txw-art-fill-2);
  color: var(--txw-art-ink-2);
}
body.sheet-body:not(.section-viewer) .txw .txw-art svg {
  width: 32px;
  height: 32px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}
body.sheet-body:not(.section-viewer) .txw .txw-country h3 {
  margin: 0 0 calc(var(--base) * 0.25);
  font-family: inherit;
  font-size: 22px;
  font-weight: 700;
  line-height: 33px;
}
body.sheet-body:not(.section-viewer) .txw .txw-caption {
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-mini {
  display: flex;
  align-items: center;
  gap: calc(var(--base) * 0.75);
  margin: calc(var(--base) * 2) 0 calc(var(--base) * 1.625);
  font-size: 11px;
  line-height: 16.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-mini-dot {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: var(--radius-pill);
  background: var(--txw-mint);
  color: var(--forest-ink);
  font-size: 11px;
  font-weight: 800;
}
body.sheet-body:not(.section-viewer) .txw .txw-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0;
  width: 100%;
  margin-top: auto;
  padding-top: calc(var(--base) * 1.625);
  border-top: 1px solid var(--bsw-line);
  font-size: 11px;
  line-height: 16.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-status {
  font-size: 11px;
  font-weight: 750;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-status.is-review {
  color: var(--txw-warn-ink);
}
body.sheet-body:not(.section-viewer) .txw .txw-status.is-good {
  color: var(--txw-good-ink);
}
body.sheet-body:not(.section-viewer) .txw .txw-expected {
  display: grid;
  gap: calc(var(--base) * 1.5);
}
body.sheet-body:not(.section-viewer) .txw .txw-expected .tax-expected[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) .txw .txw-closing {
  margin: 0 0 calc(var(--base) * 2.5);
  padding: calc(var(--base) * 2.875) calc(var(--base) * 3);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-review);
  background: var(--card-bg);
}
/* Tax review's heading: Insurance's shared heading (D-640 (3)); its counter stays on its right (D-640 (4)). */
body.sheet-body:not(.section-viewer) .txw .txw-review-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: calc(var(--base) * 1.875);
  padding: calc(var(--base) * 1.5) 0;
  border-top: 1px solid var(--bsw-line);
}
body.sheet-body:not(.section-viewer) .txw .txw-review-row b {
  font-size: 13px;
  line-height: 19.5px;
}
body.sheet-body:not(.section-viewer) .txw .txw-review-row small {
  display: block;
  margin-top: calc(var(--base) * 0.5);
  font-size: 11px;
  line-height: 16.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-review-row button {
  flex-shrink: 0;
  width: auto;
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.125) calc(var(--base) * 1.625);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-panel-button);
  background: var(--card-bg);
  color: var(--text);
  font: inherit;
  font-size: 12px;
  font-weight: 650;
  line-height: 18px;
}
/* 4a of the overnight brief of 20-21 Nov 26 (D-621): the residency indication under the day log, one block a year. */
body.sheet-body:not(.section-viewer) .txw .txw-indication {
  display: grid;
  gap: var(--base);
  padding: calc(var(--base) * 2) 0;
  border-top: 1px solid var(--border);
  font-size: 13px;
  line-height: 19.5px;
}
body.sheet-body:not(.section-viewer) .txw .txw-indication p { margin: 0; }
/* 4b (D-602): the rate source line and what the authority's page says, on the Rates card. */
body.sheet-body:not(.section-viewer) .txw .txw-rate-source { margin: 0; font-size: 13px; line-height: 19.5px; color: var(--text-muted); }
body.sheet-body:not(.section-viewer) .txw #txw-rate-source { color: var(--text); font-weight: 600; }
body.sheet-body:not(.section-viewer) .txw .txw-indication small { color: var(--text-muted); font-size: 11px; line-height: 16.5px; }
body.sheet-body:not(.section-viewer) .txw .txw-indication-tests {
  display: grid;
  gap: calc(var(--base) * 0.5);
  margin: 0;
  padding-left: calc(var(--base) * 2.5);
}
body.sheet-body:not(.section-viewer) .txw .txw-indication-tests li { display: grid; }
body.sheet-body:not(.section-viewer) .txw #txw-indication h4 { margin: calc(var(--base) * 2) 0 0; font-size: 15px; }
body.sheet-body:not(.section-viewer) .txw .txw-empty {
  margin: 0;
  padding: calc(var(--base) * 2.25);
  border-radius: var(--radius-button);
  background: var(--txw-quiet);
  font-size: 13px;
  line-height: 19.5px;
  color: var(--text-muted);
}
/* A country's file. */
body.sheet-body:not(.section-viewer) .txw .txw-back {
  width: auto;
  min-height: 0;
  margin: 0;
  padding: calc(var(--base)) 0 calc(var(--base) * 2.5);
  border: 0;
  background: none;
  color: var(--forest-ink);
  font: inherit;
  font-size: 13px;
  font-weight: 780;
  line-height: 19.5px;
}
body.sheet-body:not(.section-viewer) .txw .txw-file-hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 155px;
  margin: 0 0 calc(var(--base) * 2.5);
  padding: calc(var(--base) * 3.25) calc(var(--base) * 4.5);
  overflow: hidden;
  border-radius: var(--radius-block);
  background: var(--on-photo-fill-61);
  color: var(--on-photo-ink-2);
}
body.sheet-body:not(.section-viewer) .txw .txw-file-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 44%;
}
body.sheet-body:not(.section-viewer) .txw .txw-file-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(95deg, var(--on-photo-fill-62), var(--on-photo-fill-63));
}
body.sheet-body:not(.section-viewer) .txw .txw-file-copy {
  position: relative;
  z-index: 1;
}
body.sheet-body:not(.section-viewer) .txw .txw-micro {
  margin: 0;
  font-size: 11px;
  font-weight: 800;
  line-height: 16.5px;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--txw-micro-ink);
}
body.sheet-body:not(.section-viewer) .txw .txw-file-copy h2 {
  margin: calc(var(--base) * 0.75) 0 calc(var(--base) * 0.875);
  font-family: inherit;
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -1.65px;
  color: var(--txw-file-copy-ink);
}
body.sheet-body:not(.section-viewer) .txw .txw-file-copy p {
  margin: 0;
  font-size: 14px;
  line-height: 21px;
  color: var(--txw-file-copy-ink-2);
}
body.sheet-body:not(.section-viewer) .txw .txw-tabs {
  display: flex;
  gap: calc(var(--base) * 0.75);
  margin: 0 0 calc(var(--base) * 0.75);
  padding: calc(var(--base) * 0.625) 0 calc(var(--base) * 1.75);
  overflow-x: auto;
}
body.sheet-body:not(.section-viewer) .txw .txw-tabs button {
  width: auto;
  min-height: 0;
  margin: 0;
  padding: calc(var(--base) * 1.375) calc(var(--base) * 1.625);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-detail-button);
  background: var(--card-bg);
  color: var(--text);
  font: inherit;
  font-size: 12px;
  font-weight: 730;
  line-height: 18px;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .txw .txw-tabs button[hidden] {
  display: none;
}
body.sheet-body:not(.section-viewer) .txw .txw-tabs button[aria-pressed="true"] {
  border-color: var(--forest);
  background: var(--forest);
  color: var(--txw-file-copy-ink);
}
/* D-640 (2): a tab's heading is Insurance's shared heading with Insurance's measured 32 px above it, measured as
   Insurance's is, from the box above (the tab row; its 6 px margin collapses into this), in place of the sample's 34 px
   bold heading. */
body.sheet-body:not(.section-viewer) .txw .txw-panel > .txw-heading:first-child {
  margin-top: calc(var(--base) * 4);
}
body.sheet-body:not(.section-viewer) .txw :is(.txw-two, .txw-three) {
  display: grid;
  gap: calc(var(--base) * 2.125);
}
body.sheet-body:not(.section-viewer) .txw .txw-three {
  gap: calc(var(--base) * 1.75);
  margin: 0 0 calc(var(--base) * 2);
}
body.sheet-body:not(.section-viewer) .txw .txw-stat {
  min-width: 0;
  padding: calc(var(--base) * 2.625);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-record-tile);
  background: var(--txw-quiet);
}
body.sheet-body:not(.section-viewer) .txw .txw-stat small {
  display: block;
  margin: 0 0 calc(var(--base) * 0.625);
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-stat strong {
  font-size: 28px;
  font-weight: 740;
  line-height: 1.35;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .txw .txw-stat p {
  margin: calc(var(--base) * 0.5) 0 0;
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-card {
  min-width: 0;
  margin: 0 0 calc(var(--base) * 2);
  padding: calc(var(--base) * 3);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-action);
  background: var(--card-bg);
  box-shadow: 0 22px 55px var(--shadow-20);
}
body.sheet-body:not(.section-viewer) .txw .txw-card h3 {
  margin: 0 0 calc(var(--base) * 1.125);
  font-family: inherit;
  font-size: 20px;
  font-weight: 700;
  line-height: 28px;
  letter-spacing: -0.35px;
}
body.sheet-body:not(.section-viewer) .txw .txw-card > p {
  margin: 0 0 calc(var(--base) * 1.5);
  font-size: 13px;
  line-height: 19.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-card .txw-waits {
  display: inline-flex;
  margin: 0;
  padding: calc(var(--base) * 0.625) calc(var(--base) * 1.125);
  border-radius: var(--radius-chip-v14);
  background: var(--txw-quiet);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 730;
  line-height: 16.5px;
}
body.sheet-body:not(.section-viewer) .txw .txw-cardcontent {
  margin-top: calc(var(--base) * 1.375);
}
body.sheet-body:not(.section-viewer) .txw .txw-cardcontent .tax-expected {
  margin: 0;
  box-shadow: none;
}
body.sheet-body:not(.section-viewer) .txw .txw-issue {
  margin: 0 0 calc(var(--base) * 1.25);
  padding: calc(var(--base) * 2);
  border: 1px solid var(--bsw-line);
  border-radius: var(--radius-button);
  background: var(--txw-quiet);
}
body.sheet-body:not(.section-viewer) .txw .txw-issue b {
  display: block;
  font-size: 14px;
  line-height: 21px;
}
body.sheet-body:not(.section-viewer) .txw .txw-issue p {
  margin: calc(var(--base) * 0.5) 0 calc(var(--base) * 1.25);
  font-size: 13px;
  line-height: 19.5px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-listrow {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: calc(var(--base) * 2.5);
  padding: calc(var(--base) * 1.875) 0;
  border-bottom: 1px solid var(--bsw-line);
}
body.sheet-body:not(.section-viewer) .txw .txw-listrow:last-child {
  border-bottom: 0;
}
body.sheet-body:not(.section-viewer) .txw .txw-listrow b {
  display: block;
  font-size: 14px;
  line-height: 19px;
}
body.sheet-body:not(.section-viewer) .txw .txw-listrow small {
  display: block;
  margin-top: calc(var(--base) * 0.5);
  font-size: 12px;
  line-height: 18px;
  color: var(--text-muted);
}
body.sheet-body:not(.section-viewer) .txw .txw-btnlink {
  flex-shrink: 0;
  width: auto;
  min-height: 0;
  margin: 0;
  padding: calc(var(--base)) 0;
  border: 0;
  background: transparent;
  color: var(--forest-ink);
  font: inherit;
  font-size: 12px;
  font-weight: 750;
  line-height: 18px;
  text-decoration: none;
}
@media (min-width: 1000px) {
  body.sheet-body:not(.section-viewer) .txw :is(.txw-metrics, .txw-world, .txw-three) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  body.sheet-body:not(.section-viewer) .txw .txw-two {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 720px) {
  body.sheet-body:not(.section-viewer) .txw :is(.txw-selectors, .txw-filters) {
    padding: calc(var(--base) * 1.5);
  }
  body.sheet-body:not(.section-viewer) .txw .txw-select {
    flex: 1;
    min-width: 125px;
  }
  body.sheet-body:not(.section-viewer) .txw .txw-select select {
    width: 100%;
    min-width: 0;
    font-size: 16px;
  }
  body.sheet-body:not(.section-viewer) .txw .txw-people {
    gap: calc(var(--base) * 0.625);
    padding: calc(var(--base) * 1.5);
  }
  body.sheet-body:not(.section-viewer) .txw .txw-person {
    flex: 1;
    min-width: 0;
  }
  body.sheet-body:not(.section-viewer) .txw .txw-country {
    min-height: 225px;
  }
  body.sheet-body:not(.section-viewer) .txw .txw-file-hero {
    padding: calc(var(--base) * 2.625);
  }
}
@media (prefers-reduced-motion: reduce) {
  body.sheet-body:not(.section-viewer) .txw :is(.txw-person, .txw-country) {
    transition: none;
  }
}
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) .txw {
    --txw-warn-ink: #e8c39f;
    --txw-good-ink: #8fc4a3;
    --txw-mint-line: #6f9c7d;
  }
  body.sheet-body:not(.section-viewer) .txw :is(.txw-btn.is-waiting, .txw-tag, .txw-stat, .txw-issue, .txw-empty, .txw-card .txw-waits, button.txw-person:hover) {
    background: var(--dark-txw-is-waiting-fill);
  }
  body.sheet-body:not(.section-viewer) .txw :is(.txw-person.is-active, .txw-art, .txw-mini-dot) {
    background: var(--dark-txw-is-active-fill);
  }
  body.sheet-body:not(.section-viewer) .txw .txw-country:is([data-country="AU"], [data-country="IN"]) .txw-art {
    background: var(--dark-txw-country-fill);
    color: var(--dark-txw-country-ink);
  }
  body.sheet-body:not(.section-viewer) .txw .txw-country[data-country="IN"] .txw-art {
    background: var(--dark-txw-art-fill);
    color: var(--dark-txw-art-ink);
  }
  body.sheet-body:not(.section-viewer) .txw :is(.txw-selectors, .txw-filters, .txw-select select, .txw-btn, .txw-tag, .txw-metric, .txw-people, .txw-country, .txw-closing, .txw-review-row, .txw-review-row button, .txw-tabs button, .txw-stat, .txw-card, .txw-issue, .txw-listrow, .txw-foot) {
    border-color: var(--dark-txw-selectors-line);
  }
  body.sheet-body:not(.section-viewer) .txw .txw-country:hover {
    border-color: var(--dark-txw-country-line);
  }
  body.sheet-body:not(.section-viewer) .txw .txw-tabs button[aria-pressed="true"] {
    border-color: var(--dark-txw-tabs-line);
    background: var(--dark-txw-tabs-fill);
    color: var(--dark-txw-tabs-ink);
  }
}

/* A page still to come, in the sidebar and on More (the brief of 12 Nov 26, Part 17; D-544 (7)): Budget, greyed and not
   a link, its words saying "Coming soon" so the state is never shown by colour alone. Laid out as its neighbours. */
body.sheet-body:not(.section-viewer) .tab-pages .tab-soon {
  display: flex;
  align-items: center;
  gap: var(--base);
  min-height: calc(var(--base) * 6);
  padding: var(--base) calc(var(--base) * 2);
  border: 1px solid transparent;
  border-radius: var(--radius-button);
  color: var(--nav-quiet);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.55;
  cursor: default;
}
body.sheet-body:not(.section-viewer) .tab-pages .tab-soon .tab-icon {
  opacity: 0.6;
}
body.sheet-body:not(.section-viewer) .tab-soon-word {
  margin-left: auto;
  font-size: 11px;
  font-weight: 600;
  line-height: 16.5px;
  white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .more-tiles .more-tile.is-soon {
  background: var(--color-card);
  color: var(--text-muted);
  cursor: default;
}
body.sheet-body:not(.section-viewer) .more-tiles .more-tile.is-soon .tab-soon-word {
  display: block;
  margin: var(--base) 0 0;
}

/* 6.1 (the overnight brief of 20-21 Nov 26, Part 6 step 2): Data Assurance's "Load a statement" panel's dry-run report,
   in a quiet card as the detail panel's note, and each statement held apart under "Statement lines held apart". */
body.sheet-body:not(.section-viewer) #da-load-sheet .sl-report {
  margin: calc(var(--base) * 2) 0 0;
  padding: calc(var(--base) * 2);
  border-radius: var(--radius-tile);
  background: var(--stone);
  font-size: 15px;
  line-height: 1.5;
}
body.sheet-body:not(.section-viewer) #da-load-sheet .sl-report p {
  margin: 0 0 calc(var(--base) / 2);
}
body.sheet-body:not(.section-viewer) #da-held .da-held-item {
  display: grid;
  gap: calc(var(--base) / 2);
  padding: calc(var(--base) * 2);
  border-radius: var(--radius-tile);
  background: var(--paper);
}
body.sheet-body:not(.section-viewer) #da-held .da-held-item + .da-held-item {
  margin-top: var(--base);
}
body.sheet-body:not(.section-viewer) #da-held .da-held-name {
  margin: 0;
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) #da-held .da-held-item > p {
  margin: 0;
}
body.sheet-body:not(.section-viewer) #da-held .da-held-item > .ins-light-btn {
  justify-self: start;
}

/* =====================================================================================================================
   D-564 (the brief of 14 Nov 26 (3); Avi's check of build 99924844): every dashboard's top lines up with Insurance's,
   the base (D-544). The laptop only: the phone and her pages are unchanged (D-504). Measured on every dashboard by the
   harness's basecheck (tools/two-screen-harness.js: "hero top in page", "attention top in page", the attention cards'
   heights, the tab row's place and the section heading after the attention block).
   (1) The hero starts 24 px under the top bar and is exactly 315 px high on every page, so What deserves attention
       starts at the same height everywhere. Balance Sheet's top bar switches take the Appearance switch's height.
   (3) Every attention card is Insurance's: 208 px high, its heading and its sentence one line each, cut with an
       ellipsis when longer (the whole text is in the card's own panel).
   (5) The attention block's tab row stays at its top right, as Insurance's: a long line beside it wraps instead.
   (2) The section heading after the attention block, on the pages built from .fo-hero as well.
   Last in the file and led by :is(main#base, main), as the base blocks above.
   ===================================================================================================================== */
@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) :is(main#base, main) :is(.ins-hero, .fo-hero) {
    height: 315px;
    margin-bottom: calc(var(--base) * 2.75);
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) #content > .fo-topbar + .fo-hero {
    margin-top: calc(var(--base) * 3);
  }
  /* Balance Sheet & Net Worth's page is a grid (16 px between rows), where margins do not collapse. */
  body.sheet-body:not(.section-viewer) :is(main#base, main) #content.dash-grid > .fo-topbar {
    margin-bottom: var(--base);
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) #content.dash-grid > .fo-topbar + .fo-hero {
    margin-top: 0;
    margin-bottom: 0;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) #content.dash-grid > .bs-attention > .ins-intel {
    margin-top: calc(var(--base) * 0.75);
    margin-bottom: 0;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) #content.dash-grid > .fo-title .gr-title {
    margin: calc(var(--base) * 2) 0 0;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) #content.dash-grid > .fo-title + .fo-metrics {
    margin-top: var(--base);
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .fo-topbar :is(button.fo-seg-button[type], button.fo-chip-button[type]) {
    padding-top: calc(var(--base) * 0.5);
    padding-bottom: calc(var(--base) * 0.5);
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel {
    margin-top: calc(var(--base) * 2.5);
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-intel-top {
    flex-wrap: nowrap;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-intel-top > :first-child {
    flex: 1 1 auto;
    min-width: 0;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-intel-top > .ins-tabs {
    flex: none;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card {
    height: 208px;
    gap: calc(var(--base) * 1.125);
    overflow: hidden;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card .ins-kicker {
    flex: none;
    flex-wrap: nowrap;
    overflow: hidden;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card .ins-tag {
    flex: none;
    padding: calc(var(--base) * 0.75) calc(var(--base) * 1.25);
    font-weight: 750;
    line-height: normal;
    white-space: nowrap;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card > :is(h3, p) {
    flex: none;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card > h3 {
    font-size: 20px;
    line-height: 24.4px;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card > p {
    font-size: 14px;
    line-height: 1.58;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card > .ins-meta {
    flex: none;
    margin-top: auto;
    overflow: hidden;
    font-size: 13px;
    line-height: normal;
    white-space: nowrap;
    text-overflow: ellipsis;
  }
  /* The overnight brief of 18-19 Nov 26, Part 4a: a card with a second action holds its two buttons in one row, each
     drawn as a card's own button (src/ground-rules.ts attentionCard's second). */
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card > .ins-btn-row {
    flex: none;
    display: flex;
    flex-wrap: nowrap;
    gap: var(--base);
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card > .ins-btn[type],
  body.sheet-body:not(.section-viewer) :is(main#base, main) .ins-intel .ins-card > .ins-btn-row > .ins-btn[type] {
    flex: none;
    padding: calc(var(--base) * 1.25) calc(var(--base) * 2);
    font-weight: 750;
    line-height: normal;
  }
  /* (2) The section heading, as Insurance's title block (D-521 (1)), for the pages built from .fo-hero. */
  body.sheet-body:not(.section-viewer) :is(main#base, main) .fo-title {
    grid-column: 1 / -1;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .fo-title .gr-title {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: calc(var(--base) * 3);
    margin: calc(var(--base) * 4) 0 calc(var(--base) * 3);
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .fo-title .gr-title .gr-title-eyebrow {
    margin: 0 0 calc(var(--base) * 1.5);
    font-size: 11px;
    font-weight: 730;
    line-height: normal;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    color: var(--text-muted);
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .fo-title .gr-title .gr-title-heading {
    margin: 0 0 calc(var(--base) * 1.375);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 43.2px;
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: -1.8px;
  }
  body.sheet-body:not(.section-viewer) :is(main#base, main) .fo-title .gr-title .gr-title-line {
    margin: 0;
    font-size: 15px;
    line-height: 24px;
    color: var(--text-muted);
  }
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .fo-title {
    display: none;
  }
}
/* D-564 (3), item 6: Balance Sheet's Review Required cards (the shared card of that kind, every one). The badge and the
   card's button share the first row, the button at the top right on every card; the heading and the line run the
   card's full width under them, so a button never squeezes the words. A button and a link look and measure the same
   (a <button> took the page's full-width, 48 px form button and covered "Records left out"). */
body.sheet-body:not(.section-viewer) .bsw .bsw-alert-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  column-gap: calc(var(--base) * 1.75);
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert-text {
  display: contents;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert-text > .bsw-badge {
  grid-column: 1;
  grid-row: 1;
  justify-self: start;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert-top > .bsw-btn {
  grid-column: 2;
  grid-row: 1;
}
body.sheet-body:not(.section-viewer) .bsw .bsw-alert-text > :is(.bsw-alert-heading, .bsw-alert-line) {
  grid-column: 1 / -1;
}
body.sheet-body:not(.section-viewer) .bsw :is(a, button[type]).bsw-btn {
  display: block;
  width: auto;
  min-height: 0;
  margin: 0;
  border: 0;
  box-shadow: none;
  font-family: inherit;
  line-height: 1.55;
  white-space: nowrap;
  cursor: pointer;
}
/* Item 7: the gaps panel's records by reason, each reason a folded card (the sheet's "More details" fold). */
body.sheet-body:not(.section-viewer) .form-sheet .gaps-groups {
  display: grid;
  gap: calc(var(--base) * 2);
  margin: calc(var(--base) * 2) 0;
}
body.sheet-body:not(.section-viewer) .form-sheet .gaps-groups > details.gaps-group > summary::marker {
  content: "";
}
body.sheet-body:not(.section-viewer) .form-sheet .gaps-groups > details.gaps-group {
  margin: 0;
}
body.sheet-body:not(.section-viewer) .form-sheet .gaps-groups .gaps-group-heading {
  min-width: 0;
  font-weight: 600;
}
body.sheet-body:not(.section-viewer) .form-sheet .gaps-groups details.gaps-group[open] > summary .row-value {
  transform: rotate(90deg);
}

/* P3 (D-559 (a), D-570; the phone phase, 16 Nov 26): on the phone every row of tabs stays one line and scrolls
   sideways, each tab keeping its words whole, with a fade at the edge where more tabs lie past it. The fade follows
   the row's own scroll (a scroll-linked animation): at the start only the right edge fades, at the end only the left,
   and a row that fits has no fade at all (its scroll timeline is inactive, so the fade's widths keep their 0 px).
   Where the browser has no scroll-linked animation the row still scrolls, without the fade. Records' three tabs keep
   their own rule (equal tabs, a long name on two lines). The mask only shapes what is drawn; its colour is never
   seen. */
@property --tab-fade-left {
  syntax: "<length>";
  inherits: false;
  initial-value: 0px;
}
@property --tab-fade-right {
  syntax: "<length>";
  inherits: false;
  initial-value: 0px;
}
@keyframes tab-row-fade {
  from { --tab-fade-left: 0px; --tab-fade-right: 28px; }
  to { --tab-fade-left: 28px; --tab-fade-right: 0px; }
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) :is(.ins-tabs, .ins-drawer-tabs, .tool-tabs, .txw-tabs, .spw-tabs, .alw-tabs, [role="tablist"]):not(.records-tabs) {
    /* Page rules that let a row wrap, or shrink its tabs to fit, are outweighed here on purpose: one row, whole words. */
    flex-wrap: nowrap !important;
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    -webkit-mask-image: linear-gradient(to right, transparent 0, var(--text) var(--tab-fade-left), var(--text) calc(100% - var(--tab-fade-right)), transparent 100%);
    mask-image: linear-gradient(to right, transparent 0, var(--text) var(--tab-fade-left), var(--text) calc(100% - var(--tab-fade-right)), transparent 100%);
  }
  body.sheet-body:not(.section-viewer) :is(.ins-tabs, .ins-drawer-tabs, .tool-tabs, .txw-tabs, .spw-tabs, .alw-tabs, [role="tablist"]):not(.records-tabs)::-webkit-scrollbar {
    display: none;
  }
  body.sheet-body:not(.section-viewer) :is(.ins-tabs, .ins-drawer-tabs, .tool-tabs, .txw-tabs, .spw-tabs, .alw-tabs, [role="tablist"]):not(.records-tabs) > :is(button, [role="tab"]) {
    flex-shrink: 0 !important;
    min-width: max-content !important;
  }
  @supports (animation-timeline: scroll()) {
    body.sheet-body:not(.section-viewer) :is(.ins-tabs, .ins-drawer-tabs, .tool-tabs, .txw-tabs, .spw-tabs, .alw-tabs, [role="tablist"]):not(.records-tabs) {
      animation: tab-row-fade linear both;
      animation-timeline: scroll(self inline);
    }
  }
}

/* P5 (D-559 (a), D-570; 16 Nov 26): a shorter hero on the phone, about 200 px, keeping the eyebrow, the heading and the
   chips and dropping the sentence (each hero's plain line, and What's due's caption), so the first figure shows sooner.
   The chips stay on one line that scrolls sideways, each whole, as the tab rows do (P3). Both hero families: the
   sample-built pages' .ins-hero and the shared .dash-hero.fo-hero. Her pages are left alone (D-504). */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) main :is(.ins-hero, .dash-hero.fo-hero) {
    min-height: 0 !important;
  }
  /* The hero's words sit 24 px from its top and bottom and 20 px from its sides (38 and 40 on the laptop). */
  body.sheet-body:not(.section-viewer) main .ins-hero .ins-heroinner,
  body.sheet-body:not(.section-viewer) main .dash-hero.fo-hero .fo-hero-copy {
    padding: calc(var(--base) * 3) calc(var(--base) * 2.5) !important;
  }
  /* Goals' and Insurance's lines stay: on a single goal or policy they carry its status, or say it is not recorded.
     Balance Sheet's line stays when it is dated (a past month-end): it says which date the figures are for. */
  body.sheet-body:not(.section-viewer) main .ins-hero .ins-heroinner > p:not(#goals-hero-line),
  body.sheet-body:not(.section-viewer) main .dash-hero.fo-hero .fo-hero-line:not(#insurance-line):not([data-dated]) {
    display: none !important;
  }
  /* Balance Sheet's chips and its rates chip share one line that scrolls, as every hero's chips do. */
  body.sheet-body:not(.section-viewer) main .dash-hero.fo-hero .bs-chips .bs-chip-row {
    flex-wrap: nowrap !important;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
  }
  body.sheet-body:not(.section-viewer) main .dash-hero.fo-hero .bs-chips .bs-chip-row > * {
    flex-shrink: 0;
    margin: 0;
  }
  body.sheet-body:not(.section-viewer) main .dash-hero.fo-hero .bs-chips .bs-chip-row > .ins-feature-row {
    max-width: none;
    overflow-x: visible;
  }
  body.sheet-body:not(.section-viewer) main :is(.ins-hero, .dash-hero.fo-hero) .ins-feature-row {
    flex-wrap: nowrap !important;
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
  }
  body.sheet-body:not(.section-viewer) main :is(.ins-hero, .dash-hero.fo-hero) .ins-feature-row::-webkit-scrollbar {
    display: none;
  }
  body.sheet-body:not(.section-viewer) main :is(.ins-hero, .dash-hero.fo-hero) .ins-feature-row > * {
    flex-shrink: 0 !important;
    white-space: nowrap;
  }
}

/* The phone audit's own breaks (reports/phone-audit-13nov.md, ranks 3 to 5; D-570; 16 Nov 26). Each kept the page from
   fitting the phone's width or cut a box's words short:
   - Cash Flow's action row was sized to its one-line width (flex: none), 400 px on a 375 px screen, so the page scrolled
     sideways; on the phone it takes the row's width and its parts wrap.
   - The Rates in use table (Exchange rates, and its copy in Data Maintenance's panel) is five columns of figures, 442 px
     at 375; on the phone it scrolls sideways inside its own card, never the page, every figure whole.
   - Tax's year box was 150 px beside the taxpayer box, cutting "2026 (this year)"; on the phone each box takes the row's
     width, and is 44 px high to tap. */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .cfw .cfw-actions {
    flex: 1 1 100%;
    min-width: 0;
  }
  body.sheet-body:not(.section-viewer) .rates-table {
    display: block;
    max-width: 100%;
    overflow-x: auto;
    overscroll-behavior-x: contain;
  }
  body.sheet-body:not(.section-viewer) .txw .txw-select {
    flex: 1 1 100%;
  }
  /* Safari keeps a native select at its own height under min-height (42 px measured), so the height is set. */
  body.sheet-body:not(.section-viewer) .txw .txw-select select {
    min-height: 44px;
    height: 44px;
  }
}

/* D-571, the brief of 16 Nov 26, part 2, Part 3 (2): the shared controls 44 px to tap on the phone, in one place (D-223):
   every button, the chips and switches, the panel's ✕ and ✓, and the buttons and links in rows that are drawn as
   buttons. A minimum only, so a control already larger keeps its size, and the laptop is unchanged. Left out: the tab
   bar (measured on its own), What's due's calendar days (seven to a row, a page's own grid) and a button inside a
   sentence (the line's height, as an inline link). */
@media (max-width: 767px) {
  /* :where() keeps the rule's weight at the page's own level, so a control a page draws larger (a dashboard's tile at
     Insurance's 261 px) keeps its size; a minimum still outranks a set height. */
  body.sheet-body:not(.section-viewer) :where(button, [role=button], a.chip, .fo-seg-button, .ins-btn, .ins-light-btn, .ins-primary-btn, .inv-button, .inv-textbtn, .alw-btn, .spw-btn, .bsw-btn, .goals-open, .row-button, .two-way-option, .lead-change, .debt-event-tag, .due-link, .round-button):where(:not(.tab-bar *, .due-cal-day, .sentence-opens)) {
    min-height: 44px;
    min-width: 44px;
  }
  /* The brief of 17 Nov 26 (A3's phone round): an attention card's button. The dashboards' ".ins button[type]" sets
     min-height 0 at a class's weight, which the minimum above (kept at no weight) could not reach, so every page's card
     button was 38 px on the phone; one rule here gives each its 44 (D-571, D-223). */
  body.sheet-body:not(.section-viewer) .ins .ins-btn[type] {
    min-height: 44px;
  }
  /* Half D of 17 to 18 Nov 26 (N5): a holding's panel's buttons. The panel's own rule sets 40 px at an id's weight, which
     the minimum above could not reach, so Amend instrument, Change category, New units, Fix a mistake and Open the account
     were 40 px on the phone, on the Investments page and wherever the panel now opens (D-571, D-223). */
  body.sheet-body:not(.section-viewer) #inv-page #inv-drawer .inv-button {
    min-height: 44px;
  }
  /* Half D of 17 to 18 Nov 26 (N9): an Add form opened on the page you're on (Property's Add property, Debts' Add
     liability; src/add-anywhere.ts). Its boxes and choices were the form's own height on the phone, under 44 px; a new
     place may add no control under it (D-571), so the borrowed form's take 44 here. Records' and the Add pages' copies
     of the same form are on D-571's starting list, left for the phone phase (the report's question). */
  body.sheet-body:not(.section-viewer) form[id^="sp-add-"] :is(input:not([type=hidden], [type=checkbox], [type=radio]), select) {
    min-height: 44px;
  }
  /* The brief of 17 Nov 26 evening, Part 2c (the afternoon's Q10, ruled by D-588): the same Add forms on Master Records
     and the Add pages (every box an id starting master-add-), taken off D-571's starting list; and Q4, Allocation's
     class rename sheet (Name and Reason). The same rule, one place (D-209, D-223). */
  body.sheet-body:not(.section-viewer) :is(input, select)[id^="master-add-"]:not([type=hidden], [type=checkbox], [type=radio]),
  body.sheet-body:not(.section-viewer) #class-rename-sheet :is(input:not([type=hidden], [type=checkbox], [type=radio]), select) {
    min-height: 44px;
  }
  /* The brief of 17 Nov 26 afternoon, Part 3a (D-586): the auto-pay sheets' boxes and choices (Set up an auto-pay,
     Change the auto-pay), first filled on the phone by the Paid from views and found under 44 px; the same rule. */
  body.sheet-body:not(.section-viewer) :is(#autopay-sheet, #autopay-change-sheet) :is(input:not([type=hidden], [type=checkbox], [type=radio]), select) {
    min-height: 44px;
  }
  /* Part 3b (the same brief): the loan's Change the links sheet (Secured on, Offset account, Reason), whose Secured on
     box's words changed with the loan's kind and so left tools/tap-size-list.json; the same rule, not a new listing. */
  body.sheet-body:not(.section-viewer) #links-sheet :is(input:not([type=hidden], [type=checkbox], [type=radio]), select) {
    min-height: 44px;
  }
  /* Part 3c (the same brief, D-587): each tick on Apply to other accounts is its whole row, 44 px high on the phone. */
  body.sheet-body:not(.section-viewer) #apply-targets label.check-row {
    display: flex;
    align-items: center;
    flex: 1;
    min-height: 44px;
  }
  /* Half D of 17 to 18 Nov 26 (N10): a record's panel's Details, Documents and History tabs. Their shared rule sets
     min-height 0 at an id's weight, so they were 29 px on the phone wherever the panel opens, Property and Debts now
     among them (D-571); one rule here gives them 44 on every page (D-209, D-223). */
  body.sheet-body:not(.section-viewer) #record-panel .tool-tabs > button[type] {
    min-height: 44px;
  }
}

/* ONE CONTROL HEIGHT (D-575; the brief of 17 Nov 26, A6; Avi's item 1: "all should be consistent across pages. This is
   becoming frequent issue. can you please define it for such boxes?"; Q-A yes, in-page controls too). The reference is
   the Appearance switch (D-497, D-502 kept): its words 11 px at 700, a base unit each side, its box 1 px outlined with the
   switch's rounding, 31.2 px tall on the laptop and 46 px on the phone (its buttons 44 px, the tap size). Every control
   takes the same: a switch is any row of two or more buttons marked pressed or selected outside a form or a panel (a row
   of tiles, whose buttons hold a heading, a paragraph, a picture or a list, is not a switch, nor are Update's due tiles,
   the pickers of a person or asset, or Data Assurance's list of activities), its selected segment filling the box's inner
   height in the accent with its own ink; a plain control is a button in the top bar's tools or a See all. Width follows
   the words, height never does; a row wider than its place scrolls sideways on one line. One rule, last in the sheet, so
   no page's own rule can change a height (D-223). Measured on every view by the two-screen harness (controls) and
   refused by tools/two-screen-table.py on any difference from the Appearance switch. Each selector is written whole, a
   list at the top level with no comma inside brackets, as the stylesheet readers of the tests split a list at its
   commas (tests/session-8i-overview.py read a bare "span" from :is(div, nav, span, p) and coloured every word). */
body.sheet-body:not(.section-viewer) {
  --control-h: 31.2px;
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) {
    --control-h: 46px;
  }
}
body.sheet-body:not(.section-viewer) div:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)),
body.sheet-body:not(.section-viewer) div:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)),
body.sheet-body:not(.section-viewer) nav:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)),
body.sheet-body:not(.section-viewer) nav:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)),
body.sheet-body:not(.section-viewer) span:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)),
body.sheet-body:not(.section-viewer) span:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)),
body.sheet-body:not(.section-viewer) p:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)),
body.sheet-body:not(.section-viewer) p:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) {
  /* Its display is left to the page, so a switch marked hidden stays hidden (src/view-marks.test.mjs keeps the page's
     speed: no selector with a has-test names the hidden mark). */
  box-sizing: border-box !important;
  flex-wrap: nowrap !important;
  align-items: stretch !important;
  gap: 0 !important;
  white-space: nowrap !important;
  width: max-content !important;
  max-width: 100% !important;
  height: var(--control-h) !important;
  min-height: 0 !important;
  padding: 0 !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  scrollbar-width: none;
  border: 1px solid var(--border) !important;
  border-radius: var(--radius-switch) !important;
  background: var(--color-card) !important;
}
body.sheet-body:not(.section-viewer) div:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile))::-webkit-scrollbar,
body.sheet-body:not(.section-viewer) div:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile))::-webkit-scrollbar,
body.sheet-body:not(.section-viewer) nav:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile))::-webkit-scrollbar,
body.sheet-body:not(.section-viewer) nav:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile))::-webkit-scrollbar,
body.sheet-body:not(.section-viewer) span:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile))::-webkit-scrollbar,
body.sheet-body:not(.section-viewer) span:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile))::-webkit-scrollbar,
body.sheet-body:not(.section-viewer) p:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile))::-webkit-scrollbar,
body.sheet-body:not(.section-viewer) p:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile))::-webkit-scrollbar {
  display: none;
}
body.sheet-body:not(.section-viewer) div:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
body.sheet-body:not(.section-viewer) div:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
body.sheet-body:not(.section-viewer) nav:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
body.sheet-body:not(.section-viewer) nav:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
body.sheet-body:not(.section-viewer) span:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
body.sheet-body:not(.section-viewer) span:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
body.sheet-body:not(.section-viewer) p:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
body.sheet-body:not(.section-viewer) p:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button {
  box-sizing: border-box !important;
  flex: 0 0 auto !important;
  vertical-align: top !important;
  align-items: center !important;
  justify-content: center !important;
  width: auto !important;
  min-width: max-content !important;
  height: 100% !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 var(--base) !important;
  border: 0 !important;
  border-radius: var(--radius-switch-button) !important;
  box-shadow: none !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  white-space: nowrap !important;
}
/* The phone: a segment with short words ("All", "Dark") is still 44 px wide, and every segment and plain control at
   least 44 px tall, the tap size (D-571; the harness reads its minimum height). */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) div:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
  body.sheet-body:not(.section-viewer) div:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
  body.sheet-body:not(.section-viewer) nav:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
  body.sheet-body:not(.section-viewer) nav:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
  body.sheet-body:not(.section-viewer) span:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
  body.sheet-body:not(.section-viewer) span:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
  body.sheet-body:not(.section-viewer) p:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
  body.sheet-body:not(.section-viewer) p:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(.record-tabs):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button,
  body.sheet-body:not(.section-viewer) .fo-tools > button:not([hidden]),
  body.sheet-body:not(.section-viewer) .fo-tools > a:not([hidden]),
  body.sheet-body:not(.section-viewer) button.gr-see-all:not([hidden]),
  body.sheet-body:not(.section-viewer) button.gr-search:not([hidden]),
  body.sheet-body:not(.section-viewer) button#ins-all:not([hidden]),
  body.sheet-body:not(.section-viewer) button#pr-all:not([hidden]),
  body.sheet-body:not(.section-viewer) button#debt-all:not([hidden]),
  body.sheet-body:not(.section-viewer) button#pa-all:not([hidden]) {
    min-width: 44px !important;
    min-height: 44px !important;
  }
}
body.sheet-body:not(.section-viewer) div:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button[aria-pressed="true"],
body.sheet-body:not(.section-viewer) div:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button[aria-selected="true"],
body.sheet-body:not(.section-viewer) nav:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button[aria-pressed="true"],
body.sheet-body:not(.section-viewer) nav:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button[aria-selected="true"],
body.sheet-body:not(.section-viewer) span:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button[aria-pressed="true"],
body.sheet-body:not(.section-viewer) span:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button[aria-selected="true"],
body.sheet-body:not(.section-viewer) p:has(> button[aria-pressed] ~ button[aria-pressed]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button[aria-pressed="true"],
body.sheet-body:not(.section-viewer) p:has(> button[aria-selected] ~ button[aria-selected]):not([id$="-entities"]):not(#pa-people):not(#da-subnav-items):not(form *):not(.form-sheet *):not(.sheet-saved *):not(dialog *):not(:has(> button div)):not(:has(> button p)):not(:has(> button h2)):not(:has(> button h3)):not(:has(> button h4)):not(:has(> button img)):not(:has(> button ul)):not(:has(> button dl)):not(:has(> button.due-tile)) > button[aria-selected="true"] {
  background: var(--color-accent) !important;
  color: var(--plus-ink) !important;
}
body.sheet-body:not(.section-viewer) .fo-tools > button:not([hidden]),
body.sheet-body:not(.section-viewer) .fo-tools > a:not([hidden]),
body.sheet-body:not(.section-viewer) button.gr-see-all:not([hidden]),
body.sheet-body:not(.section-viewer) button.gr-search:not([hidden]),
body.sheet-body:not(.section-viewer) button#ins-all:not([hidden]),
body.sheet-body:not(.section-viewer) button#pr-all:not([hidden]),
body.sheet-body:not(.section-viewer) button#debt-all:not([hidden]),
body.sheet-body:not(.section-viewer) button#pa-all:not([hidden]) {
  box-sizing: border-box !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  height: var(--control-h) !important;
  min-height: 0 !important;
  padding: 0 var(--base) !important;
  border: 1px solid var(--border) !important;
  border-radius: var(--radius-switch) !important;
  font-size: 11px !important;
  font-weight: 700 !important;
  line-height: 1.2 !important;
  white-space: nowrap !important;
}
/* The phone's search box (the brief of 18-19 Nov 26, Part 2 item 2; the phone pause report's question 2, Avi's yes of
   18 Nov 26): Quick Balance Update's and Master Records' Search takes Insurance's search box on the phone (the layout
   standard's 375 px figures, tools/two-screen-harness.js BASE): 44 px tall, 13 px words, 20 px padding, a pill. One
   shared rule for every button.gr-search; the laptop keeps the row's control height above. Scoped to the page's main
   (the sample scope, D-508), as its 20 px padding is the standard's figure, not a whole base unit. */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) :is(main#base, main) button.gr-search:not([hidden]) {
    height: 44px !important;
    padding: 0 calc(var(--base) * 2.5) !important;
    border-radius: var(--radius-pill) !important;
    font-size: 13px !important;
  }
}
/* The chart kit (the brief of 17 Nov 26, Half C; D-581; src/chart-kit.ts, src/chart-draw.ts). The Home sample's chart
   palette as named colours (D-550), light and Midnight Estate dark (D-494): glows on lines, a fading tint under the main
   line, two shades of one hue within a bar or arc, shaded balls for debts. Words in a chart sit on the card's paper, in
   the page's own text colours, so they keep 4.5:1 (measured by the harness against what is behind them, L-48). */
body.sheet-body:not(.section-viewer) {
  --chart-assets: #2b956e;
  --chart-debt: #c9423d;
  --chart-net: #c98a2e;
  --chart-teal: #2f9f93;
  --chart-violet: #8466c4;
  --chart-rose: #c8667a;
  --chart-gold: #c99a3f;
  --chart-rest: #8a8f99;
  --chart-track: #e7e1d4;
  --chart-bubble-light: #ffffff;
  --chart-bubble-shade: #2a1f3f;
  /* Question 1 of reports/19nov-day-report.md, built on its recommendation (b) (D-605): the approved demo's soft
     shading inside each category dot, as two named colours, a chart-like mark under D-581. */
  --chart-dot-shade: rgba(0, 0, 0, 0.25);
  --chart-dot-light: rgba(255, 255, 255, 0.45);
}
@media (prefers-color-scheme: dark) {
  body.sheet-body:not(.section-viewer) {
    --chart-assets: #65d9a9;
    --chart-debt: #ff9a94;
    --chart-net: #ffc673;
    --chart-teal: #68e1d0;
    --chart-violet: #bd99f0;
    --chart-rose: #f2a2aa;
    --chart-gold: #f2c47b;
    --chart-rest: #a9b0ba;
    --chart-track: #24362c;
    --chart-bubble-light: #ffffff;
    --chart-bubble-shade: #0b1411;
  }
}
body.sheet-body:not(.section-viewer) .ck-box { width: 100%; min-width: 0; overflow: hidden; }
body.sheet-body:not(.section-viewer) .ck-chart { display: block; max-width: 100%; height: auto; overflow: visible; font-family: inherit; }
body.sheet-body:not(.section-viewer) .ck-box-line, body.sheet-body:not(.section-viewer) .ck-box-bridge { min-height: 260px; }
body.sheet-body:not(.section-viewer) .ck-box-ring { display: flex; justify-content: center; }
body.sheet-body:not(.section-viewer) .ck-axis { stroke: var(--border); stroke-width: 1; }
body.sheet-body:not(.section-viewer) .ck-zero { stroke: var(--text-muted); }
body.sheet-body:not(.section-viewer) .ck-axis-label { fill: var(--text-muted); font-size: 11px; font-variant-numeric: tabular-nums; }
body.sheet-body:not(.section-viewer) .ck-step-label { font-size: 11px; }
body.sheet-body:not(.section-viewer) .ck-connector { stroke: var(--border); stroke-width: 1; stroke-dasharray: 3 3; }
body.sheet-body:not(.section-viewer) .ck-rest { stroke: var(--chart-rest); stroke-width: 1.5; stroke-dasharray: 4 3; }
body.sheet-body:not(.section-viewer) .ck-track { stroke: var(--chart-track); }
body.sheet-body:not(.section-viewer) .ck-track-bar { fill: var(--chart-track); }
body.sheet-body:not(.section-viewer) .ck-centre-big { fill: var(--text); font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; }
body.sheet-body:not(.section-viewer) .ck-centre-long { font-size: 15px; }
body.sheet-body:not(.section-viewer) .ck-centre-small { fill: var(--text-muted); font-size: 13px; }
body.sheet-body:not(.section-viewer) .ck-bubble-name,
body.sheet-body:not(.section-viewer) .ck-bar-name { fill: var(--text); font-size: 13px; font-weight: 600; }
body.sheet-body:not(.section-viewer) .ck-bubble-figure { fill: var(--color-red); font-size: 13px; font-variant-numeric: tabular-nums; }
body.sheet-body:not(.section-viewer) .ck-bar-figures { fill: var(--text-muted); font-size: 13px; font-variant-numeric: tabular-nums; }
/* D-641 (1), the approved demo of 22 Nov 26: a bar row's note on the right of its name line ("Loan to value 48.6%"), and
   money owed in its figures line red with its minus sign (T46). */
body.sheet-body:not(.section-viewer) .ck-bar-note { fill: var(--text-muted); font-size: 13px; font-variant-numeric: tabular-nums; }
body.sheet-body:not(.section-viewer) .ck-bar-figures .ck-bar-owed { fill: var(--color-red); }
body.sheet-body:not(.section-viewer) .ck-hit { fill: transparent; stroke: none; cursor: pointer; }
body.sheet-body:not(.section-viewer) .ck-hit:focus { outline: none; }
/* A focused point carries the accent as its focus ring (Part 8), as the v1.4 sample's points carry theirs (the behaviour
   gate, 17 Nov 26). */
body.sheet-body:not(.section-viewer) .ck-hit:focus-visible { stroke: var(--color-accent); stroke-width: 2.5; outline: 3px solid var(--color-accent); outline-offset: 2px; }
/* Record by record's fold takes the pale hover of the page's other rows under a mouse (the sample's ledger rows do). */
@media (hover: hover) {
  body.sheet-body:not(.section-viewer) #lines-fold > summary:hover { background: var(--fo-hover); }
}
body.sheet-body:not(.section-viewer) .ck-legend { display: flex; flex-wrap: wrap; gap: calc(var(--base) * 3); margin: calc(var(--base) * 1) 0 0; color: var(--text-muted); font-size: 13px; }
body.sheet-body:not(.section-viewer) .ck-key::before { content: ""; display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: var(--base); background: var(--chart-assets); }
body.sheet-body:not(.section-viewer) .ck-key-debt::before { background: var(--chart-debt); }
body.sheet-body:not(.section-viewer) .ck-key-net::before { background: var(--chart-net); }
body.sheet-body:not(.section-viewer) .ck-range { margin: calc(var(--base) * 2) 0; }
body.sheet-body:not(.section-viewer) .ck-pair { display: grid; grid-template-columns: 1fr; gap: calc(var(--base) * 3); }
body.sheet-body:not(.section-viewer) .ck-placeholder { display: flex; flex-direction: column; justify-content: center; gap: calc(var(--base) * 1); padding: calc(var(--base) * 4);
  border: 1px dashed var(--border); border-radius: var(--radius-tile); color: var(--text-muted); font-size: 13px; }
body.sheet-body:not(.section-viewer) .ck-placeholder-head { color: var(--text); font-weight: 600; font-size: 15px; margin: 0; }
body.sheet-body:not(.section-viewer) .ck-placeholder p { margin: 0; }
body.sheet-body:not(.section-viewer) .ck-where { display: grid; grid-template-columns: minmax(240px, 280px) minmax(0, 1fr); gap: calc(var(--base) * 6); align-items: start; }
body.sheet-body:not(.section-viewer) .ck-ring-side { min-width: 0; }
@media (max-width: 1023px) {
  body.sheet-body:not(.section-viewer) .ck-where { grid-template-columns: minmax(0, 1fr); }
}
/* The v1.4 sample's first row: the trend wider than the bridge (its 571 and 414 px at 1,280), and each chart 8 px under
   its card's words (the look gate, 17 Nov 26). */
@media (min-width: 1100px) {
  body.sheet-body:not(.section-viewer) .bsw .bsw-split.ck-split-trend { grid-template-columns: minmax(0, 1.38fr) minmax(0, 1fr); }
}
body.sheet-body:not(.section-viewer) .ck-box { padding-top: var(--base); }
/* Beside the ring the category rows carry no bar, which had given them their height; on the phone each keeps the 44 px a
   finger needs (D-571; seen by the harness's tap-size check, 17 Nov 26). */
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .bsw #composition.bsw-bars .row-button.fo-category { min-height: 44px; }
}
/* No glow or tint under reduced motion, more contrast or print (D-581; Part 8). */
@media (prefers-reduced-motion: reduce), (prefers-contrast: more), print {
  body.sheet-body:not(.section-viewer) .ck-glow { filter: none; }
  body.sheet-body:not(.section-viewer) .ck-fade { display: none; }
}
/* Home (the day brief of 18 Nov 26, Part 1; D-581, D-591), from the v1.4 Home sample: a slim photo banner, four figure
   cards, then the sample's twelve-column grid (wealth 7 beside income 5; mix 3, budget 2, goals 3 and the debts over the
   payments 4; Next focus 8). Sizes from the scale (Part 8), the sample's below 11 px raised to 11 (D-508). Stacked in one
   column under 1,024 px; the phone keeps this order until the phone phase (D-504). */
body.sheet-body:not(.section-viewer) .home .home-banner {
  position: relative; display: flex; align-items: flex-end; justify-content: space-between; gap: calc(var(--base) * 2);
  /* 24 px under the top bar, so the banner starts where every page's hero starts (D-569); 16 px under it, the grid's gap. */
  min-height: 80px; margin: calc(var(--base) * 3) 0 calc(var(--base) * 2); padding: calc(var(--base) * 2) calc(var(--base) * 3);
  border-radius: var(--radius-hero); overflow: hidden; isolation: isolate; background: var(--on-photo-fill-64); box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .home .home-banner-photo {
  position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 50% 62%;
}
/* One hue, deep forest, fading to clear over the photo: the words sit on its solid part, 4.5:1 or more (L-48). */
body.sheet-body:not(.section-viewer) .home .home-banner::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(90deg, var(--on-photo-fill-65) 0%, var(--on-photo-fill-66) 42%, var(--on-photo-fill-67) 100%);
}
body.sheet-body:not(.section-viewer) .home .home-banner-copy { min-width: 0; }
body.sheet-body:not(.section-viewer) .home .home-kicker {
  margin: 0; color: var(--on-photo-ink-17); font-size: 11px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase;
}
body.sheet-body:not(.section-viewer) .home .home-banner h1 {
  /* The page title role sets 38 px from 768 px (D-568); the phone keeps 28 until its phase (D-504). */
  /* Georgia comes from the page heading rule (.sheet-page h1), the one place large headings take it. */
  margin: 0; color: var(--on-photo-ink-2); font-weight: 400; font-size: 28px; line-height: 1.1; letter-spacing: 0;
}
body.sheet-body:not(.section-viewer) .home .home-banner-line { margin: calc(var(--base) * 0.25) 0 0; color: var(--on-photo-ink-17); font-size: 13px; line-height: 1.35; }
body.sheet-body:not(.section-viewer) .home .home-date-chip {
  flex: none; margin: 0; padding: calc(var(--base) * 0.75) calc(var(--base) * 1.5); border-radius: var(--radius-pill); background: var(--on-photo-fill-66); border: 1px solid var(--on-photo-line-2);
  color: var(--on-photo-ink-2); font-size: 11px; font-weight: 700; font-variant-numeric: tabular-nums; white-space: nowrap;
}
body.sheet-body:not(.section-viewer) .home .home-grid {
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: calc(var(--base) * 2); align-items: stretch;
}
body.sheet-body:not(.section-viewer) .home .home-grid > * { min-width: 0; }
body.sheet-body:not(.section-viewer) .home .home-kpi { grid-column: span 3; }
/* The notices under the figure cards are grid items of their own, so a hidden one leaves no gap. */
body.sheet-body:not(.section-viewer) .home .home-under { display: contents; }
body.sheet-body:not(.section-viewer) .home .home-under > * { grid-column: 1 / -1; min-width: 0; margin: 0; }
body.sheet-body:not(.section-viewer) .home .home-wealth { grid-column: span 7; }
body.sheet-body:not(.section-viewer) .home .home-flows { grid-column: span 5; }
/* Part 3 of the brief of 20-21 Nov 26: Investment mix, Goals and Debts one equal row of three, Budget used removed until
   6.6; Upcoming payments beside Next focus under it. Each card of the row stretches to the row's height. */
body.sheet-body:not(.section-viewer) .home .home-mix { grid-column: span 4; }
body.sheet-body:not(.section-viewer) .home .home-goals { grid-column: span 4; }
body.sheet-body:not(.section-viewer) .home .home-debts { grid-column: span 4; }
body.sheet-body:not(.section-viewer) .home .home-payments { grid-column: span 4; }
body.sheet-body:not(.section-viewer) .home .home-focus { grid-column: span 8; }
/* With the sidebar, a 1,280 px window leaves about 1,000 px: the row of three stays, and Upcoming payments and Next
   focus each take the width. */
@media (max-width: 1439px) {
  body.sheet-body:not(.section-viewer) .home .home-payments { grid-column: 1 / -1; }
  body.sheet-body:not(.section-viewer) .home .home-focus { grid-column: 1 / -1; }
}
@media (max-width: 1023px) {
  body.sheet-body:not(.section-viewer) .home .home-kpi { grid-column: span 6; }
  body.sheet-body:not(.section-viewer) .home .home-wealth, body.sheet-body:not(.section-viewer) .home .home-flows,
  body.sheet-body:not(.section-viewer) .home .home-mix, body.sheet-body:not(.section-viewer) .home .home-goals,
  body.sheet-body:not(.section-viewer) .home .home-debts { grid-column: 1 / -1; }
}
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .home .home-grid > * { grid-column: 1 / -1 !important; }
  body.sheet-body:not(.section-viewer) .home .home-banner { min-height: 72px; padding: calc(var(--base) * 2); }
}
/* The figure cards: an icon, the name, the figure at 28 and one line under it, in the shared summary card's box (the
   dashboards' .fo-metric: its padding, corner, shadow and least height; Part 7, item 2, D-597). Four in a row take the
   shared row's width, and the cards of one row take one height (the grid stretches them). */
body.sheet-body:not(.section-viewer) .home .home-kpi {
  display: flex; align-items: flex-start; gap: calc(var(--base) * 1.5); min-height: 131px; margin: 0;
  padding: calc(var(--base) * 3) calc(var(--base) * 2) calc(var(--base) * 2) calc(var(--base) * 3);
  border: 1px solid var(--border); border-radius: var(--radius-metric); background: var(--color-card); box-shadow: var(--fo-metric-shadow);
}
body.sheet-body:not(.section-viewer) .home .home-kpi-icon svg,
body.sheet-body:not(.section-viewer) .home .home-card-icon,
body.sheet-body:not(.section-viewer) .home .home-focus-mark svg {
  width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round;
}
body.sheet-body:not(.section-viewer) .home .home-kpi-icon { flex: none; color: var(--accent); padding-top: calc(var(--base) * 0.25); }
body.sheet-body:not(.section-viewer) .home .home-kpi-words { display: flex; flex-direction: column; gap: calc(var(--base) * 0.5); min-width: 0; flex: 1; container-type: inline-size; }
body.sheet-body:not(.section-viewer) .home .home-kpi-open {
  display: flex; flex-direction: column; gap: calc(var(--base) * 0.5); align-items: flex-start; margin: 0; padding: 0; border: 0; background: none;
  color: inherit; font: inherit; text-align: left; cursor: pointer; min-height: 44px;
}
body.sheet-body:not(.section-viewer) .home .home-kpi-open:focus-visible { outline: 3px solid var(--color-accent, var(--accent)); outline-offset: 4px; border-radius: var(--radius-nav-icon); }
body.sheet-body:not(.section-viewer) .home .home-kpi-name { color: var(--text-muted); font-size: 13px; }
body.sheet-body:not(.section-viewer) .home .home-kpi-figure {
  /* The net worth figure carries the dashboards' fitted-figure class (.fo-metric-figure: its code at half size, D-502),
     in Home's own face and spacing, as the sample draws it. */
  margin: 0; font-family: inherit;
  color: var(--text); font-weight: 600; line-height: 1.15; font-variant-numeric: tabular-nums; white-space: nowrap;
  /* The full figure on one line, at 28 when it fits and smaller only when it would run out of its card, as the
     dashboards' figure cards are fitted (src/page-top.ts setMetricFigure writes --fo-fig-ems). */
  font-size: min(28px, calc(100cqi / var(--fo-fig-ems, 10)));
}
body.sheet-body:not(.section-viewer) .home .home-kpi-figure.owed { color: var(--color-red); }
body.sheet-body:not(.section-viewer) .home .home-kpi-figure.home-kpi-none,
body.sheet-body:not(.section-viewer) .home .home-kpi-none { font-size: 20px; color: var(--text-muted); font-weight: 600; white-space: normal; }
body.sheet-body:not(.section-viewer) .home .home-kpi-line { margin: 0; color: var(--text-muted); font-size: 13px; line-height: 1.35; }
body.sheet-body:not(.section-viewer) .placeholder-words { color: var(--text-muted); font-size: 13px; }
/* The chart cards: the sample's paper, its 24 px corner and card shadow; the title at 17 with its icon. */
body.sheet-body:not(.section-viewer) .home .home-card {
  display: flex; flex-direction: column; gap: var(--base); margin: 0; padding: calc(var(--base) * 2.5);
  border: 1px solid var(--border); border-radius: var(--radius-card); background: var(--color-card); box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .home .home-card-head { display: flex; align-items: center; justify-content: space-between; gap: var(--base); flex-wrap: wrap; }
body.sheet-body:not(.section-viewer) .home .home-card-title {
  display: flex; align-items: center; gap: var(--base); margin: 0; color: var(--text); font-size: 17px !important; font-weight: 600; line-height: 1.25;
}
body.sheet-body:not(.section-viewer) .home .home-card-icon { flex: none; color: var(--accent); }
body.sheet-body:not(.section-viewer) .home .home-card-figure { margin: 0; font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; }
body.sheet-body:not(.section-viewer) .home .home-card-figure.owed { color: var(--color-red); }
body.sheet-body:not(.section-viewer) .home .home-card .ck-range { margin: 0; }
/* A placeholder's words sit in the middle of their card (Part 7, item 3). */
body.sheet-body:not(.section-viewer) .home .home-placeholder-box { flex: 1; min-height: 160px; align-items: center; text-align: center; }
body.sheet-body:not(.section-viewer) .home .home-legend { display: flex; flex-wrap: wrap; gap: var(--base) calc(var(--base) * 2.5); margin: 0; font-size: 13px; color: var(--text-muted); }
body.sheet-body:not(.section-viewer) .home .home-legend-item { display: inline-flex; align-items: center; gap: calc(var(--base) * 0.75); }
body.sheet-body:not(.section-viewer) .home .home-legend-figure { color: var(--text); font-weight: 600; font-variant-numeric: tabular-nums; }
body.sheet-body:not(.section-viewer) .home .home-legend-figure.owed { color: var(--color-red); }
body.sheet-body:not(.section-viewer) .home .home-swatch { flex: none; display: inline-block; width: 9px; height: 9px; border-radius: 50%; background: var(--chart-assets); }
body.sheet-body:not(.section-viewer) .home .home-legend-debt .home-swatch { background: var(--chart-debt); }
body.sheet-body:not(.section-viewer) .home .home-legend-net .home-swatch { background: var(--chart-net); }
body.sheet-body:not(.section-viewer) .home .home-note { margin: 0; color: var(--text-muted); font-size: 11px; line-height: 1.4; }
body.sheet-body:not(.section-viewer) .home .home-mix-body { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--base); }
body.sheet-body:not(.section-viewer) .home .home-mix-list,
body.sheet-body:not(.section-viewer) .home .home-goal-list,
body.sheet-body:not(.section-viewer) .home .home-due-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
body.sheet-body:not(.section-viewer) .home .home-mix-open,
body.sheet-body:not(.section-viewer) .home .home-goal-open,
body.sheet-body:not(.section-viewer) .home .home-due-open {
  display: grid; width: 100%; min-height: 44px; margin: 0; padding: calc(var(--base) * 0.75) calc(var(--base) * 0.5); border: 0; border-radius: var(--radius-icon-box-small); background: none;
  color: var(--text); font: inherit; font-size: 13px; text-align: left; cursor: pointer;
}
/* A class's row: its swatch, name and share on the first line, its full figure under the name. */
body.sheet-body:not(.section-viewer) .home .home-mix-open {
  grid-template-columns: 9px minmax(0, 1fr) auto; grid-template-areas: "dot name share" ". figure figure"; align-items: center; column-gap: var(--base); row-gap: calc(var(--base) * 0.25);
}
body.sheet-body:not(.section-viewer) .home .home-mix-open > .home-swatch { grid-area: dot; }
body.sheet-body:not(.section-viewer) .home .home-mix-name { grid-area: name; font-weight: 600; overflow-wrap: break-word; }
body.sheet-body:not(.section-viewer) .home .home-mix-share { grid-area: share; }
body.sheet-body:not(.section-viewer) .home .home-mix-figure { grid-area: figure; color: var(--text-muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
body.sheet-body:not(.section-viewer) .home .home-mix-figure.owed { color: var(--color-red); }
body.sheet-body:not(.section-viewer) .home .home-mix-share { color: var(--text-muted); font-variant-numeric: tabular-nums; min-width: 4.5ch; text-align: right; }
/* A goal's words never break inside a word (Part 7, item 3: Goals showed "TEST FIXT URE Hous e depo sit"): the row wraps,
   the name taking the room and the status beside it, or under it when the two do not fit; each wraps only at its own
   spaces, and a word breaks only when it is wider than the whole row (break-word, never anywhere). The bar and the
   figure take a line each. */
body.sheet-body:not(.section-viewer) .home .home-goal-open { display: flex; flex-wrap: wrap; align-items: center; row-gap: calc(var(--base) * 0.75); column-gap: var(--base); }
body.sheet-body:not(.section-viewer) .home .home-goal-open > .goals-bar,
body.sheet-body:not(.section-viewer) .home .home-goal-open > div { flex: 1 0 100%; }
body.sheet-body:not(.section-viewer) .home .home-goal-name { flex: 1 1 12ch; min-width: 0; font-weight: 600; overflow-wrap: break-word; }
body.sheet-body:not(.section-viewer) .home .home-goal-status { flex: 0 1 auto; margin-left: auto; min-width: 0; color: var(--text-muted); font-size: 11px; font-weight: 700; text-align: right; overflow-wrap: break-word; }
body.sheet-body:not(.section-viewer) .home .home-goal-figure { flex: 1 0 100%; color: var(--text-muted); font-size: 11px; font-variant-numeric: tabular-nums; }
/* Part 3 of the brief of 20-21 Nov 26: Goals' four counts, a figure over its word each, in one row of four. */
body.sheet-body:not(.section-viewer) .home .home-counts { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--base); }
body.sheet-body:not(.section-viewer) .home .home-count {
  display: flex; flex-direction: column; align-items: flex-start; gap: calc(var(--base) * 0.25); padding: var(--base); border-radius: var(--radius-icon-box-small);
  background: var(--fo-hover, var(--chart-track));
}
body.sheet-body:not(.section-viewer) .home .home-count-figure { color: var(--text); font-size: 17px; font-weight: 600; font-variant-numeric: tabular-nums; line-height: 1.2; }
body.sheet-body:not(.section-viewer) .home .home-count-label { color: var(--text-muted); font-size: 11px; font-weight: 600; line-height: 1.3; overflow-wrap: normal; word-break: keep-all; }
/* Debts: one shaded bar split by kind (decoration: each kind's figure is in the list under it), the kinds' figures, then
   the three largest debts on one line each, the name ending "…" when it does not fit. */
body.sheet-body:not(.section-viewer) .home .home-debt-bar { display: flex; height: 12px; border-radius: var(--radius-pill); overflow: hidden; background: var(--chart-track); }
body.sheet-body:not(.section-viewer) .home .home-debt-bar[hidden] { display: none; }
body.sheet-body:not(.section-viewer) .home .home-debt-part { flex-basis: 0; min-width: 3px; }
body.sheet-body:not(.section-viewer) .home .home-debt-part + .home-debt-part { border-left: 2px solid var(--color-card); }
body.sheet-body:not(.section-viewer) .home .home-debt-kinds,
body.sheet-body:not(.section-viewer) .home .home-debt-top { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
body.sheet-body:not(.section-viewer) .home .home-debt-kind {
  display: grid; grid-template-columns: 9px minmax(0, 1fr) auto; align-items: center; column-gap: var(--base); min-height: 28px; font-size: 13px;
}
body.sheet-body:not(.section-viewer) .home .home-debt-kind-name { color: var(--text); overflow-wrap: normal; }
body.sheet-body:not(.section-viewer) .home .home-debt-kind-figure,
body.sheet-body:not(.section-viewer) .home .home-debt-figure { font-variant-numeric: tabular-nums; white-space: nowrap; text-align: right; }
body.sheet-body:not(.section-viewer) .home .home-debt-kind-figure.owed,
body.sheet-body:not(.section-viewer) .home .home-debt-figure.owed { color: var(--color-red); }
body.sheet-body:not(.section-viewer) .home .home-debt-top { border-top: 1px solid var(--border); padding-top: calc(var(--base) * 0.5); }
body.sheet-body:not(.section-viewer) .home .home-debt-open {
  display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; column-gap: var(--base); width: 100%; min-height: 44px; margin: 0;
  padding: calc(var(--base) * 0.5); border: 0; border-radius: var(--radius-icon-box-small); background: none; color: var(--text); font: inherit; font-size: 13px;
  text-align: left; cursor: pointer;
}
body.sheet-body:not(.section-viewer) .home .home-debt-name { min-width: 0; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
body.sheet-body:not(.section-viewer) .home .home-debt-rate { color: var(--text-muted); font-size: 11px; font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (hover: hover) { body.sheet-body:not(.section-viewer) .home .home-debt-open:hover { background: var(--fo-hover); } }
body.sheet-body:not(.section-viewer) .home .home-debt-open:focus-visible { outline: 3px solid var(--color-accent, var(--accent)); outline-offset: 2px; }
body.sheet-body:not(.section-viewer) .home .home-due-row + .home-due-row { border-top: 1px solid var(--border); }
body.sheet-body:not(.section-viewer) .home .home-due-open { grid-template-columns: 40px minmax(0, 1fr) auto; column-gap: calc(var(--base) * 1.5); align-items: center; }
body.sheet-body:not(.section-viewer) .home .home-due-chip {
  display: flex; flex-direction: column; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: var(--radius-icon-box-small);
  background: var(--fo-hover, var(--chart-track)); color: var(--text); line-height: 1.05;
}
body.sheet-body:not(.section-viewer) .home .home-due-month { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; }
body.sheet-body:not(.section-viewer) .home .home-due-day { font-size: 15px; font-weight: 600; font-variant-numeric: tabular-nums; }
body.sheet-body:not(.section-viewer) .home .home-due-words { display: flex; flex-direction: column; gap: calc(var(--base) * 0.25); min-width: 0; }
body.sheet-body:not(.section-viewer) .home .home-due-title { font-weight: 600; overflow-wrap: break-word; }
body.sheet-body:not(.section-viewer) .home .home-due-detail { color: var(--text-muted); font-size: 11px; overflow-wrap: break-word; }
body.sheet-body:not(.section-viewer) .home .home-due-badge { padding: calc(var(--base) * 0.375) var(--base); border-radius: var(--radius-pill); background: var(--fo-hover, var(--chart-track)); color: var(--text); font-size: 11px; font-weight: 700; white-space: nowrap; }
body.sheet-body:not(.section-viewer) .home .home-due-badge.owed-words { color: var(--color-red); }
@media (hover: hover) {
  body.sheet-body:not(.section-viewer) .home .home-mix-open:hover,
  body.sheet-body:not(.section-viewer) .home .home-goal-open:hover,
  body.sheet-body:not(.section-viewer) .home .home-due-open:hover { background: var(--fo-hover); }
}
body.sheet-body:not(.section-viewer) .home .home-mix-open:focus-visible,
body.sheet-body:not(.section-viewer) .home .home-goal-open:focus-visible,
body.sheet-body:not(.section-viewer) .home .home-due-open:focus-visible,
body.sheet-body:not(.section-viewer) .home .home-focus-open:focus-visible { outline: 3px solid var(--color-accent, var(--accent)); outline-offset: 2px; }
body.sheet-body:not(.section-viewer) .home .home-open { align-self: flex-end; margin-top: auto; display: inline-flex; align-items: center; min-height: 44px; color: var(--accent); font-size: 13px; font-weight: 600; text-decoration: underline; }
/* Next focus: one line, the sample's slim card with the accent mark at the left. */
body.sheet-body:not(.section-viewer) .home .home-focus {
  display: flex; align-items: center; flex-wrap: wrap; gap: var(--base) calc(var(--base) * 2); margin: 0; padding: calc(var(--base) * 1.5) calc(var(--base) * 2.5);
  border: 1px solid var(--border); border-left: 4px solid var(--chart-debt); border-radius: var(--radius-tile); background: var(--color-card); box-shadow: var(--shadow-card);
}
body.sheet-body:not(.section-viewer) .home .home-focus-mark { color: var(--chart-gold); display: inline-flex; }
body.sheet-body:not(.section-viewer) .home .home-focus-name { margin: 0; color: var(--text); font-size: 15px !important; font-weight: 600; }
body.sheet-body:not(.section-viewer) .home .home-focus-words { flex: 1 1 240px; margin: 0; color: var(--text); font-size: 13px; overflow-wrap: break-word; }
body.sheet-body:not(.section-viewer) .home .home-focus-open {
  min-height: 44px; margin: 0 0 0 auto; padding: 0 var(--base); border: 0; background: none; color: var(--accent); font: inherit; font-size: 13px; font-weight: 600; cursor: pointer;
}
body.sheet-body:not(.section-viewer) .home .home-focus-note { flex-basis: 100%; margin: 0; }
body.sheet-body:not(.section-viewer) .home .home-meta { margin: calc(var(--base) * 2) 0 0; }
/* Balance Sheet & Net Worth's lower half (the overnight brief of 18-19 Nov 26, Part 5; Avi's approved demo of 18 Nov):
   the insight chip under each heading, the category rows (a dot, the name, the figure, the share in its own column and a
   thin bar of it under them), the net worth line, the property legend and the snapshot's two figures. Named colours
   only (D-550); sizes on the scale (D-568). */
body.sheet-body:not(.section-viewer) .bs-insight {
  display: inline-block;
  margin: calc(var(--base) * 1) 0 calc(var(--base) * 2);
  padding: calc(var(--base) * 1) calc(var(--base) * 2);
  border-radius: var(--radius-pill);
  background: var(--chip-bg);
  color: var(--chip-ink);
  font-size: 13px;
  line-height: 1.4;
  color: var(--text);
}
body.sheet-body:not(.section-viewer) .bs-insight[hidden] { display: none; }
body.sheet-body:not(.section-viewer) .bs-insight b { font-weight: 600; }
body.sheet-body:not(.section-viewer) .bsw #composition.bsw-bars .row-button.fo-category.bs-row {
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr) auto 52px;
  grid-template-rows: auto auto;
  column-gap: calc(var(--base) * 1.25);
  row-gap: calc(var(--base) * 1.25);
  align-items: center;
  padding: calc(var(--base) * 1) calc(var(--base) * 0.75);
  border-radius: var(--radius-detail-button);
  cursor: pointer;
  font-variant-numeric: tabular-nums;
}
body.sheet-body:not(.section-viewer) .bsw #composition.bsw-bars .bs-row:hover { background: var(--chip-bg); }
body.sheet-body:not(.section-viewer) .bsw #composition.bsw-bars .card-rows:has(.bs-row) { gap: 0; }
body.sheet-body:not(.section-viewer) .bsw #composition .bs-row .bs-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--cat, var(--chart-assets));
  box-shadow: inset -2px -2px 3px var(--chart-dot-shade), inset 2px 2px 3px var(--chart-dot-light);
}
body.sheet-body:not(.section-viewer) .bsw #composition .bs-row .row-lines { min-width: 0; }
body.sheet-body:not(.section-viewer) .bsw #composition .bs-row .row-value { font-weight: 600; white-space: nowrap; text-align: right; }
body.sheet-body:not(.section-viewer) .bsw #composition .bs-row .bs-pct { text-align: right; color: var(--text-muted); font-size: 13px; }
body.sheet-body:not(.section-viewer) .bsw #composition .bs-row .bs-share-bar {
  grid-column: 2 / 5;
  height: 4px;
  margin-top: calc(var(--base) * -0.5);
  overflow: hidden;
  border-radius: var(--radius-share-bar);
  background: var(--chart-track);
}
body.sheet-body:not(.section-viewer) .bsw #composition .bs-row .bs-share-bar > i { display: block; height: 100%; border-radius: var(--radius-share-bar); background: var(--cat, var(--chart-assets)); }
/* Each side's heading as the approved demo (the day brief of 19 Nov 26, Part 2): its name on the left, its total with
   the currency code on the right, in the ink at the row figure's size. */
body.sheet-body:not(.section-viewer) .bsw #composition .group-name {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0;
}
body.sheet-body:not(.section-viewer) .bsw #composition .bs-side-total { margin-left: var(--base); color: var(--text); font-size: 15px; letter-spacing: 0; text-transform: none; font-variant-numeric: tabular-nums; white-space: nowrap; }
body.sheet-body:not(.section-viewer) .bsw #composition .bs-side-total.owed { color: var(--color-red); }
/* D-617 (Avi's check of 20 Nov 26): net worth to the right of the heading and the chip, level with the heading, with no
   band of its own; below 768 px it follows the chip, left-aligned. */
/* One grid, row for row: the two kickers on the first row, the heading and the figure on the second (each centred on
   it), the chip under the heading. The two wrappers give their children to the grid (display: contents). */
body.sheet-body:not(.section-viewer) .bsw .bsw-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  justify-content: space-between;
  align-items: center;
  column-gap: calc(var(--base) * 3);
}
body.sheet-body:not(.section-viewer) .bsw .bsw-head-text { display: contents; }
body.sheet-body:not(.section-viewer) .bsw .bsw-head-text > .fo-kicker { grid-column: 1; grid-row: 1; }
body.sheet-body:not(.section-viewer) .bsw .bsw-head-text > h2 { grid-column: 1; grid-row: 2; }
body.sheet-body:not(.section-viewer) .bsw .bsw-head-text > .bs-insight { grid-column: 1 / -1; grid-row: 3; justify-self: start; }
body.sheet-body:not(.section-viewer) .bsw .bs-netline { display: contents; text-align: right; }
body.sheet-body:not(.section-viewer) .bsw .bs-netline[hidden] { display: none; }
body.sheet-body:not(.section-viewer) .bsw .bs-netline .fo-kicker { margin: 0; grid-column: 2; grid-row: 1; justify-self: end; }
body.sheet-body:not(.section-viewer) .bsw .bs-netline .bs-net { grid-column: 2; grid-row: 2; justify-self: end; white-space: nowrap; }
@media (max-width: 767px) {
  body.sheet-body:not(.section-viewer) .bsw .bsw-head { grid-template-columns: minmax(0, 1fr); }
  body.sheet-body:not(.section-viewer) .bsw .bs-netline .fo-kicker { grid-column: 1; grid-row: 4; justify-self: start; margin-top: calc(var(--base) * 2); }
  body.sheet-body:not(.section-viewer) .bsw .bs-netline .bs-net { grid-column: 1; grid-row: 5; justify-self: start; }
}
body.sheet-body:not(.section-viewer) .bs-net { margin: 0; font-family: Georgia, "Times New Roman", serif; font-size: 28px; font-weight: 400; font-variant-numeric: tabular-nums; }
body.sheet-body:not(.section-viewer) .bs-net.owed { color: var(--color-red); }
body.sheet-body:not(.section-viewer) .bs-legend { display: flex; flex-wrap: wrap; gap: calc(var(--base) * 2); margin: calc(var(--base) * 1) 0 0; color: var(--text-muted); font-size: 13px; }
body.sheet-body:not(.section-viewer) .bs-key { display: inline-block; width: 10px; height: 10px; margin-right: calc(var(--base) * 1); border-radius: 50%; vertical-align: middle; }
body.sheet-body:not(.section-viewer) .bs-key-equity { background: var(--chart-assets); }
body.sheet-body:not(.section-viewer) .bs-key-loan { background: var(--chart-debt); }
body.sheet-body:not(.section-viewer) .bs-pair { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: calc(var(--base) * 2); margin-top: calc(var(--base) * 1); }
body.sheet-body:not(.section-viewer) .bs-pair[hidden] { display: none; }
body.sheet-body:not(.section-viewer) .bs-pair p { margin: 0; }
body.sheet-body:not(.section-viewer) .bs-pair-key { color: var(--text-muted); font-size: 13px; }
body.sheet-body:not(.section-viewer) .bs-pair-figure { font-size: 20px; font-weight: 600; font-variant-numeric: tabular-nums; }
@media (min-width: 1100px) {
  body.sheet-body:not(.section-viewer) .bsw .ck-where { grid-template-columns: 300px minmax(0, 1fr); gap: calc(var(--base) * 3); }
  body.sheet-body:not(.section-viewer) .bsw #composition.bsw-bars { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: calc(var(--base) * 3); margin-top: 0; }
}
body.sheet-body:not(.section-viewer) .explore-owed { margin-top: calc(var(--base) * 3); }
body.sheet-body:not(.section-viewer) .explore-owed[hidden] { display: none; }
body.sheet-body:not(.section-viewer) .explore-owed .group-name { margin: 0 0 calc(var(--base) * 1); }
/* The wealth benchmark, redesigned (the overnight brief of 18-19 Nov 26, Part 6; Avi's approved demo of 18 Nov): the
   heading with its ⓘ, the gauge beside the four tiles, the inputs line, and the ratio year by year. Named colours only
   (D-550); sizes on the scale (D-568). */
body.sheet-body:not(.section-viewer) .bm-head { display: flex; align-items: center; gap: calc(var(--base) * 1); }
body.sheet-body:not(.section-viewer) .bm-formula {
  max-width: 640px;
  margin: calc(var(--base) * 1) 0;
  padding: calc(var(--base) * 1) calc(var(--base) * 2);
  border-radius: var(--radius-tile);
  background: var(--chip-bg);
  color: var(--chip-ink);
  font-size: 13px;
  line-height: 1.5;
}
body.sheet-body:not(.section-viewer) .bm-formula[hidden] { display: none; }
body.sheet-body:not(.section-viewer) .bm-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: calc(var(--base) * 3); align-items: center; }
body.sheet-body:not(.section-viewer) .bm-side { min-width: 0; }
body.sheet-body:not(.section-viewer) .bm-tiles { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: calc(var(--base) * 2); }
body.sheet-body:not(.section-viewer) .bm-tile { padding: calc(var(--base) * 2); border-radius: var(--radius-tile); background: var(--chip-bg); min-width: 0; }
body.sheet-body:not(.section-viewer) .bm-tile p { margin: 0; }
body.sheet-body:not(.section-viewer) .bm-tile-name { color: var(--text-muted); font-size: 11px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }
body.sheet-body:not(.section-viewer) .bm-tile-figure { color: var(--text); font-size: 20px; font-weight: 600; font-variant-numeric: tabular-nums; overflow-wrap: normal; }
body.sheet-body:not(.section-viewer) .bm-tile-figure.owed { color: var(--color-red); }
body.sheet-body:not(.section-viewer) .bm-tile-note { color: var(--text-muted); font-size: 13px; }
body.sheet-body:not(.section-viewer) .bm-inputs { margin: calc(var(--base) * 2) 0 0; padding-top: calc(var(--base) * 2); border-top: 1px solid var(--bsw-line); color: var(--text-muted); font-size: 13px; }
body.sheet-body:not(.section-viewer) .ck-box-gauge { display: flex; justify-content: center; }
body.sheet-body:not(.section-viewer) .ck-gauge-edge { stroke: var(--card-bg); stroke-width: 3; }
body.sheet-body:not(.section-viewer) .ck-gauge-needle { stroke: var(--text); stroke-width: 5; stroke-linecap: round; }
body.sheet-body:not(.section-viewer) .ck-gauge-hub { fill: var(--text); }
body.sheet-body:not(.section-viewer) .ck-gauge-ratio { fill: var(--text); font-size: 28px; font-weight: 600; font-variant-numeric: tabular-nums; }
body.sheet-body:not(.section-viewer) .ck-ref { stroke: var(--border); stroke-width: 1; stroke-dasharray: 5 5; }
/* The gauge beside the tiles only where its column holds it at full size (460 px); narrower, it sits above them. */
@media (min-width: 1200px) {
  body.sheet-body:not(.section-viewer) .bm-grid { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: calc(var(--base) * 4); }
}
@media (max-width: 560px) {
  body.sheet-body:not(.section-viewer) .bm-tiles { grid-template-columns: minmax(0, 1fr); }
}
/* D-606 (Avi's check of 19 Nov 26: "Did we not agree that font of the numbers will System one across all sections of
   the pages?"): every figure (amounts, percentages, ratios, counts, dates) in the system font; Georgia is for headings
   only (D-485). One shared rule, after every page's own rules and just before the text roles (which set sizes only and
   must stay last, tests/text-roles.py), over every figure the harness found drawn in Georgia (the figure check of
   tools/two-screen-table.py, D-606, fails on any other). The hero metric keeps its fitted size and its 600 weight
   (Georgia at 550 was the Home sample's, rejected by Avi). */
body.sheet-body:not(.section-viewer) :is(.fo-metric-figure, .bs-net, .ins-metric-value, #inv-page .inv-big, #goals-page .goals-safety-metric, #due-page .due-chip-day, #due-page .due-date-num) {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
body.sheet-body:not(.section-viewer) :is(.fo-metric-figure, .bs-net) { font-weight: 600; }
/* The quality session of 21 Nov 26 (D-629, PAGE-RULES.md section 2): a card's own item title is the card's name line in
   the system font, at the body size and 600, never a large Georgia heading; on a sample-built dashboard the section's
   Georgia rule for its headings would otherwise reach it (Data Assurance's "Other things to look at", the
   exception items). Section headings keep Georgia. */
body.sheet-body:not(.section-viewer) .ins :is(p.group-name, .item-title) {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: var(--size-body);
  font-weight: 600;
  letter-spacing: 0;
}

/* 6.5's first piece: the category that moved most and each month's total read in the text colour, said in words too. */
body.sheet-body:not(.section-viewer) .spw .spw-table tr.is-moved th,
body.sheet-body:not(.section-viewer) .spw .spw-table tr.spw-total :is(th, td) {
  color: var(--text);
}

/* TEXT ROLES (D-568) begin: written by tools/make-text-roles.py from tools/text-roles.json; never edit by hand. */
@media (min-width: 768px) {
  body.sheet-body:not(.section-viewer) {
    --role-page-title: 38px;
    --role-section-heading: 28px;
    --role-eyebrow: 11px;
    --role-card-heading: 20px;
    --role-record-title: 17px;
    --role-subtitle: 15px;
    --role-chip-or-switch: 11px;
    --role-status-word: 11px;
    --role-button: 13px;
    --role-value: 15px;
    --role-label: 13px;
    --role-table-header: 11px;
    --role-table-text: 13px;
    --role-help-line: 11px;
    --role-body: 13px;
  }
  body.sheet-body:not(.section-viewer) :where(.ins-section-heading p, .ins-quiet, .sheet-meta, .build-id, .group-help, .field-note, .master-count):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-body) !important; }
  body.sheet-body:not(.section-viewer) :where(.gr-summary-line, .gr-tile-people-words, .gr-tile-mid p, .queue-as-at, .records-soon-words):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-help-line) !important; }
  body.sheet-body:not(.section-viewer) :where(td):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-table-text) !important; }
  body.sheet-body:not(.section-viewer) :where(th):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-table-header) !important; }
  body.sheet-body:not(.section-viewer) :where(label, .row-label, .gr-summary-label, dt, .spw-metric-label, .txw-metric-label):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-label) !important; }
  body.sheet-body:not(.section-viewer) :where(input, select, textarea, .two-way-option, .row-value, dd, .check-row):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *, #entry-form #amount)) { font-size: var(--role-value) !important; }
  body.sheet-body:not(.section-viewer) :where(.ins-primary-btn, .ins-light-btn, .ins-btn, .bsw-btn, .inv-button, .inv-textbtn, .alw-btn, .spw-btn, .due-link, .goals-hero-button, .goals-outline, .text-button):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *, #pa-page .pa-panel-actions .ins-btn)) { font-size: var(--role-button) !important; }
  body.sheet-body:not(.section-viewer) :where(.gr-status, .txw-status):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-status-word) !important; }
  body.sheet-body:not(.section-viewer) :where(.fo-seg-button, .ins-tag, .due-pill, .spw-pill, .alw-pill, .inv-pill, .inc-pill, .bsw-badge, .spw-badge, .gr-record-chip, #pa-page .pa-panel-actions .ins-btn, .ins-tab, .tool-tab, .fo-chip-button, .gr-see-all, .gr-search):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-chip-or-switch) !important; }
  body.sheet-body:not(.section-viewer) :where(.gr-title-line, .ins-subtitle, .bsw-subhead, .ins-sub):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-subtitle) !important; }
  body.sheet-body:not(.section-viewer) :where(.gr-record-title):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-record-title) !important; }
  body.sheet-body:not(.section-viewer) :where(.ins-section-heading h2, .ins-review-header h2, h3, .due-feature-title):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-card-heading) !important; }
  body.sheet-body:not(.section-viewer) :where(.ins-eyebrow, .gr-title-eyebrow, .ins-page-eyebrow, .dash-eyebrow, .fo-crumb, .fo-eyebrow, .fo-kicker, .spw-eyebrow, .cfw-eyebrow, .alw-eyebrow, .due-eyebrow, .sheet-label, h3.group-name, .form-sheet:has(.sheet-head .record-title) .entry-bar-title):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *)) { font-size: var(--role-eyebrow) !important; }
  body.sheet-body:not(.section-viewer) :where(.ins-intel h2, .display-heading, .fo-action-title, .records-quick-heading, .long-title):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *, .form-sheet .sheet-head .record-title:not(.long-title))) { font-size: var(--role-section-heading) !important; }
  body.sheet-body:not(.section-viewer) :where(h1, .gr-title-heading, .entry-bar-title, .form-sheet .sheet-head .record-title):not(:where(.ins-hero, .ins-hero *, .fo-hero, .fo-hero *, .row-chevron, .sheet-chevron, .spw-emblem, .cfw-emblem, .inv-insight-icon, .fo-action-symbol, .spw-empty-mark, .txw-arrow, .txw-mini-dot, .inc-square, .gr-summary-figure, .gr-summary-figure *, .fo-metric-figure, .fo-metric-figure *, .long-title, .form-sheet:has(.sheet-head .record-title) .entry-bar-title)) { font-size: var(--role-page-title) !important; }
}
/* TEXT ROLES (D-568) end */
