*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    /* Suppresses the WebView's default tap-highlight flash (14 July 2026, Rocky — looked like a
       stray "yellow circle" on tapped cards/buttons). This app already gives its own tap
       feedback (scale/opacity transitions on buttons/cards), so the browser's built-in highlight
       is pure visual noise on top of that. */
    -webkit-tap-highlight-color: transparent;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--lg-bg);
    color: var(--lg-text-1);
    height: 100dvh;
    overflow: hidden;
}

/* ── App shell — structure adapted from Project Memory's pm-app/pm-app-column
   (theme-clean-shell.css). No gradient/hero background system ported over — Logit's home
   screen is flat-brand, not the colourful gradient hero PM uses. ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Outer app container — full viewport height, positioning context for the fixed
 *   modal overlay. Adapted from Project Memory's pm-app.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-app
 * @tags        layout
 * @called-by   index.html (#lg-app)
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-app {
    width: 100%;
    height: 100dvh;
    position: relative;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Column wrapping every lg-panel-*, safe-area padding top/bottom. Adapted from
 *   Project Memory's pm-app-column (no desktop max-width constraint — Logit is phone-only).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-app-column
 * @tags        layout
 * @called-by   index.html (.lg-app-column)
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-app-column {
    width: 100%;
    height: 100dvh;
    display: flex;
    flex-direction: column;
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Base panel styles shared by every top-level view — hidden by default; lgActive
 *   (lgSwitchPanel, navComponent.js) shows the current one. Same mechanism as Project Memory's
 *   pm-panel-base attribute selector.
 * @apps        memri-logit
 * @type        css-attribute-selector
 * @name        lg-panel-base
 * @tags        layout
 * @called-by   index.html (matched by attribute selector — all lg-panel-* elements)
 * @depends-on  none
 * @updated     2026-07-11
 */
[class*="lg-panel-"] {
    display: none;
}

[class*="lg-panel-"].lg-active {
    display: flex;
    flex-direction: column;
    height: 100dvh;
    overflow: hidden;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Home panel hero — title + tagline on a flat brand-colour band. Simplified,
 *   non-gradient version of Project Memory's pm-hero (no logo/avatar assets exist yet).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-hero
 * @tags        home
 * @called-by   index.html (#lg-panel-home)
 * @depends-on  --lg-brand
 * @updated     2026-07-11
 */
/**
 * @pm-registry
 * @prefix      lg
 * @description Full-width hero card at the top of Home, sitting inside lg-home-groups as the
 *   first element (reworked 14 July 2026 — Rocky: "It needs to be same width and alignment as
 *   the Icon Buttons," so it moved from a separate lg-hero banner above the tile grid into the
 *   grid's own container, inheriting identical horizontal padding for free rather than needing
 *   matching values kept in sync by hand). Same surface/border/shadow look as lg-home-button
 *   (Rocky: get rid of the solid blue background, use "the same frosted see-through as the icon
 *   buttons" — lg-home-button doesn't literally use backdrop-filter, but this app has no busy
 *   background behind Home to blur anyway; matching its actual light surface-card look is what
 *   reads as "the same as the other buttons" here) rather than a bold solid-colour block. Not a
 *   real `<button>` — nothing to navigate to, so it doesn't pretend to be tappable.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-hero-card
 * @tags        home
 * @called-by   index.html (.lg-hero-card)
 * @depends-on  --lg-radius-medium, --lg-surface, --lg-border, --lg-shadow-small
 * @updated     2026-07-14
 */
.lg-hero-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px;
    border-radius: var(--lg-radius-medium);
    background: var(--lg-surface);
    border: 1.5px solid var(--lg-border);
    box-shadow: var(--lg-shadow-small);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Button wrapper around lg-hero-image (14 July 2026) — tapping the mascot opens the
 *   About page (lg-panel-about, "Our Story"). Plain button-reset styling (no border/background/
 *   padding of its own) so it doesn't look like a button, just a tappable picture.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-hero-image-btn
 * @tags        home
 * @called-by   index.html (.lg-hero-image-btn)
 * @depends-on  none
 * @updated     2026-07-14
 */
.lg-hero-image-btn {
    background: none;
    border: none;
    padding: 0;
    line-height: 0;
    cursor: pointer;
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description The full, uncropped logo illustration in lg-hero-card — 14 July 2026, Rocky's
 *   chosen mascot (a wombat happily digging up a burrow of receipts, cube-shaped coins popping
 *   out beside it — a nod to real wombat trivia, cube-shaped droppings, without being gross
 *   about it). Not cropped at all (`object-fit: contain`, full scene — Rocky: "can't you just
 *   use the whole picture") and not circular (an earlier version was both cropped and circular —
 *   Rocky: "way too small and too round... I want the whole picture"). Width is viewport-
 *   relative via `clamp()`, same responsive technique as lg-home-button-icon's font-size, so the
 *   image scales with the tile icons rather than staying a fixed size regardless of screen width
 *   (Rocky: "reactive and change size the way the icon buttons do"). Sized up 50% same session
 *   (Rocky: still too small) — `clamp(90px, 26vw, 150px)` became `clamp(135px, 39vw, 225px)`,
 *   same bounds × 1.5. Source swapped to Rocky's own crop
 *   (`wombat-digger-logo-pics/Digger-logo-top-app.png`) the same pass.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-hero-image
 * @tags        home
 * @called-by   index.html (.lg-hero-image)
 * @depends-on  none
 * @updated     2026-07-14
 */
.lg-hero-image {
    width: clamp(135px, 39vw, 225px);
    height: auto;
    border-radius: 10px;
    object-fit: contain;
    display: block;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Title/tagline text column in lg-hero-card, next to the mascot image.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-hero-text
 * @tags        home
 * @called-by   index.html (.lg-hero-text)
 * @depends-on  none
 * @updated     2026-07-14
 */
.lg-hero-text {
    display: flex;
    flex-direction: column;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description App title text inside lg-hero-card. Dark-on-light text tokens (14 July 2026,
 *   replacing white) once the card's background stopped being solid brand-colour blue.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-hero-title
 * @tags        home
 * @called-by   index.html (.lg-hero-title)
 * @depends-on  --lg-text-1
 * @updated     2026-07-14
 */
.lg-hero-title {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--lg-text-1);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Tagline text inside lg-hero-card, below the title — single line ("Log Every
 *   Expense Bill Every Hour", 14 July 2026, replacing an earlier two-line "Finding Every
 *   Expense" / "Logging Every Hour" version from the same session — Rocky's own wording,
 *   matching Expenses and Timesheet, the app's two "killer features").
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-hero-tagline
 * @tags        home
 * @called-by   index.html (.lg-hero-tagline)
 * @depends-on  --lg-text-2
 * @updated     2026-07-14
 */
.lg-hero-tagline {
    font-size: 0.85rem;
    color: var(--lg-text-2);
    margin-top: 2px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description "Our Story" mascot image on the About page (14 July 2026, reworked same day) —
 *   now lives inside lg-panel-content like lg-about-text below it, so it's the same width as the
 *   story text column rather than spanning edge-to-edge (Rocky: "make the picture same width as
 *   the text"). Rounded corners added since it's no longer a full-bleed edge-to-edge image (same
 *   10px radius as lg-hero-image).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-about-image
 * @tags        home
 * @called-by   index.html (.lg-about-image)
 * @depends-on  none
 * @updated     2026-07-14
 */
.lg-about-image {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 10px;
    margin-bottom: 12px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Story paragraph text on the About page, inside the normal padded
 *   lg-panel-content area below lg-about-image. Justified (14 July 2026, Rocky) — straight edges
 *   on both sides read tidier for the short story-block paragraphs here than the app's usual
 *   ragged-right body text.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-about-text
 * @tags        home
 * @called-by   index.html (.lg-about-text)
 * @depends-on  --lg-text-1
 * @updated     2026-07-14
 */
.lg-about-text {
    font-size: 0.95rem;
    line-height: 1.5;
    color: var(--lg-text-1);
    text-align: justify;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Tap link at the bottom of the About/Story page only (14 July 2026), opens Contact
 *   & Support. Larger and forced single-line (Rocky: "should be on one line and larger") — a
 *   separate class from lg-about-footer-link since that one's shared with Contact & Support's own
 *   email/website buttons, which don't need either treatment.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-about-story-footer-link
 * @tags        home
 * @called-by   index.html (.lg-about-story-footer-link)
 * @depends-on  --lg-brand
 * @updated     2026-07-14
 */
.lg-about-story-footer-link {
    display: block;
    width: 100%;
    text-align: center;
    background: none;
    border: none;
    padding: 12px 0 4px;
    font-size: 1.05rem;
    font-weight: 700;
    white-space: nowrap;
    color: var(--lg-brand);
    cursor: pointer;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Plain-text tap link (14 July 2026) — used on the About page (opens Contact &
 *   Support) and inside Contact & Support itself (mailto:/website links via `window.open(url,
 *   '_system')`, same system-browser-handoff pattern lgAuthService.js already uses for Zitadel
 *   login links). A real `<button>`, not an `<a href>` — this app has no anchor tags anywhere
 *   else, so every tappable thing stays consistent as a button.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-about-footer-link
 * @tags        home
 * @called-by   index.html (.lg-about-footer-link)
 * @depends-on  --lg-brand
 * @updated     2026-07-14
 */
.lg-about-footer-link {
    display: block;
    width: 100%;
    text-align: center;
    background: none;
    border: none;
    padding: 10px 0;
    font-size: 0.9rem;
    color: var(--lg-brand);
    cursor: pointer;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description "Digger is part of the WombatEx Family" line on the Contact & Support panel
 *   (14 July 2026), centered directly under the header image.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-contact-family-line
 * @tags        home
 * @called-by   index.html (.lg-contact-family-line)
 * @depends-on  --lg-text-1
 * @updated     2026-07-14
 */
.lg-contact-family-line {
    text-align: center;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--lg-text-1);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description WombatEx tagline ("Apps to make life easier") on Contact & Support, centered
 *   under lg-contact-family-line.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-contact-tagline
 * @tags        home
 * @called-by   index.html (.lg-contact-tagline)
 * @depends-on  --lg-text-2
 * @updated     2026-07-14
 */
.lg-contact-tagline {
    text-align: center;
    font-size: 0.9rem;
    color: var(--lg-text-2);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Two-line header title — big top line, smaller sub line underneath. First built
 *   14 July 2026 for the About panel ("Digger" / "Receipts In – Deductions Out"); reused as-is
 *   19 July 2026 for the Balance Sheet panel ("Balance Sheet" / "What I Own and What I Owe",
 *   Rocky's own confirmed wording) rather than adding a near-duplicate class — this was never
 *   actually About-specific, just its first consumer. Still doesn't touch the shared, single-line
 *   lg-header-title used by every other panel.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-about-header-title
 * @tags        home, balance-sheet
 * @called-by   index.html (.lg-about-header-title, About and Balance Sheet panels)
 * @depends-on  none
 * @updated     2026-07-19
 */
.lg-about-header-title {
    display: flex;
    flex-direction: column;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Top line of lg-about-header-title — "Digger," bigger and bolder than the shared
 *   lg-header-title used elsewhere, since this page's header doubles as a mini logo lockup.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-about-header-title-main
 * @tags        home
 * @called-by   index.html (.lg-about-header-title-main)
 * @depends-on  --lg-text-1
 * @updated     2026-07-14
 */
.lg-about-header-title-main {
    font-size: 1.3rem;
    font-weight: 800;
    line-height: 1.2;
    color: var(--lg-text-1);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bottom line of lg-about-header-title — "Receipts In – Deductions Out," Rocky's
 *   own pun, smaller/muted under the bigger "Digger" line above it.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-about-header-title-sub
 * @tags        home
 * @called-by   index.html (.lg-about-header-title-sub)
 * @depends-on  --lg-text-2
 * @updated     2026-07-14
 */
.lg-about-header-title-sub {
    font-size: 0.78rem;
    font-weight: 500;
    color: var(--lg-text-2);
    margin-top: 1px;
}

/* ── Home tile groups — adapted from Project Memory's pm-home-group/pm-home-button
   (theme-clean-home.css), swapping the overlay-on-gradient tokens PM uses (its tiles sit on a
   colour gradient) for Logit's plain surface/border tokens (its tiles sit on flat background). ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Column of labelled home-panel tile groups — also the scroll container for both
 *   Home and More (14 July 2026 fix: was `flex-shrink: 0` with no overflow handling, so tiles
 *   past the bottom of the viewport were silently clipped by `[class*="lg-panel-"].lg-active`'s
 *   `overflow: hidden` on any phone shorter than the one this was built/tested on — Rocky: "just
 *   in case a user's phone is not as long as mine"). Same `flex: 1; overflow-y: auto` pattern
 *   lg-panel-content already uses for every other panel.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-home-groups
 * @tags        home
 * @called-by   index.html (.lg-home-groups)
 * @depends-on  none
 * @updated     2026-07-14
 */
.lg-home-groups {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 16px 12px;
    flex: 1;
    overflow-y: auto;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description A single labelled group of home-panel tiles (e.g. "Manage").
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-home-group
 * @tags        home
 * @called-by   index.html (.lg-home-group)
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-home-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Section label above a lg-home-button-row.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-home-group-label
 * @tags        home
 * @called-by   index.html (.lg-home-group-label)
 * @depends-on  --lg-text-2
 * @updated     2026-07-11
 */
.lg-home-group-label {
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--lg-text-2);
    padding-left: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description A row of equally-spaced home-panel tiles.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-home-button-row
 * @tags        home
 * @called-by   index.html (.lg-home-button-row)
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-home-button-row {
    display: flex;
    gap: 10px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Individual home-panel navigation tile — icon above label, taps into
 *   lgSwitchPanel. Adapted from Project Memory's pm-home-button. Uses a fixed 50%-based flex
 *   basis rather than flex:1 so a lone button in an under-full row (e.g. Settings, alone in
 *   the last row) stays the same size as a paired one instead of stretching full-width.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-home-button
 * @tags        home
 * @called-by   index.html (.lg-home-button)
 * @depends-on  --lg-radius-medium, --lg-shadow-small
 * @updated     2026-07-12
 */
.lg-home-button {
    /* Fixed two-per-row basis (not flex: 1) so a lone button in its own row — e.g. Settings —
       keeps the same size as a paired one instead of stretching to fill the row. */
    flex: 0 1 calc(50% - 5px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 16px 6px;
    aspect-ratio: 1;
    border-radius: var(--lg-radius-medium);
    background: var(--lg-surface);
    border: 1.5px solid var(--lg-border);
    box-shadow: var(--lg-shadow-small);
    transition: transform 0.15s, background 0.15s;
    cursor: pointer;
}

.lg-home-button:active {
    transform: scale(0.95);
    background: var(--lg-surface-2);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Emoji icon inside lg-home-button. Sized up 13 July 2026 (Rocky: "tiny icons
 *   surrounded by big buttons" — original 1.8rem read as lost inside the square button tile),
 *   dialled back 30% the same day (4.5rem read as a little too large) to a fixed 3.15rem, then
 *   made viewport-relative (still same session) — Rocky asked whether the buttons scale to the
 *   actual phone screen: lg-home-button itself already does (flex: 0 1 calc(50% - 5px) of the
 *   real viewport width, aspect-ratio:1 keeps it square), but this icon was still a fixed rem
 *   size regardless of screen width, so it looked proportionally larger on a small phone and
 *   smaller on a large one. clamp() ties it to 12vw (roughly the same visual weight the fixed
 *   3.15rem had on a mid-size phone) between a 2.6rem floor (small phones) and 3.6rem ceiling
 *   (large phones), so the whole tile — button and icon together — scales as one unit.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-home-button-icon
 * @tags        home
 * @called-by   index.html (.lg-home-button-icon)
 * @depends-on  none
 * @updated     2026-07-13
 */
.lg-home-button-icon {
    font-size: clamp(2.6rem, 12vw, 3.6rem);
    line-height: 1;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Text label inside lg-home-button.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-home-button-label
 * @tags        home
 * @called-by   index.html (.lg-home-button-label)
 * @depends-on  --lg-text-1
 * @updated     2026-07-11
 */
.lg-home-button-label {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--lg-text-1);
}

/* ── Panel header — direct port of Project Memory's pm-header/pm-header-title/
   pm-header-actions/pm-header-icon-btn (theme-clean-shell.css). Also reused, unmodified, as
   the modal header title text (matches PM's own pm-modal-place-edit.html, which reuses
   pm-header-title inside its modal header rather than a separate class). ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Standard panel header — title left, action buttons right. Direct port of
 *   Project Memory's pm-header.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-header
 * @tags        layout
 * @called-by   index.html (.lg-header, Vehicles/Settings panels), lgVehicleForm (modal header)
 * @depends-on  --lg-border, --lg-surface
 * @updated     2026-07-11
 */
.lg-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px 12px;
    border-bottom: 1px solid var(--lg-border);
    background: var(--lg-surface);
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Panel title text inside lg-header — also reused unmodified as the modal header
 *   title (lgVehicleForm), matching Project Memory's own pm-header-title reuse pattern.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-header-title
 * @tags        layout
 * @called-by   index.html (.lg-header-title), lgVehicleForm (.lg-modal-header)
 * @depends-on  --lg-text-1
 * @updated     2026-07-11
 */
.lg-header-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--lg-text-1);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Wraps the Transactions panel's header title + badge in a column so the badge sits
 *   on its own line underneath "Transactions" (17 July 2026 follow-up — the inline version wrapped
 *   awkwardly once a 4th header icon button was added, squeezing the title's available width).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-header-title-group
 * @tags        bank-reconciliation
 * @called-by   index.html (Transactions panel header)
 * @depends-on  none
 * @updated     2026-07-17
 */
.lg-bank-header-title-group {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description "⏳ N" backlog count on its own line under the Transactions panel's header title
 *   (17 July 2026 — Rocky: an hourglass + counter at the top of the screen; first tried on the
 *   Banking hub's tile, moved here per his correction; moved to its own line same day, after the
 *   inline version started wrapping awkwardly once a 4th header icon button existed). Deliberately
 *   lighter/smaller than lg-header-title itself so it reads as a count, not part of the bold title
 *   text. Empty (no count) when nothing is pending — see lgBankStatementsList._loadHeaderBadge.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-header-badge
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  --lg-text-2
 * @updated     2026-07-17
 */
.lg-bank-header-badge {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--lg-text-2);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Right-side button group inside lg-header.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-header-actions
 * @tags        layout
 * @called-by   index.html (.lg-header-actions)
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Icon-only button in lg-header-actions (the ✕ back-to-Home button).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-header-icon-btn
 * @tags        layout
 * @called-by   index.html (.lg-header-icon-btn)
 * @depends-on  --lg-radius-small, --lg-text-1
 * @updated     2026-07-11
 */
.lg-header-icon-btn {
    background: none;
    border: none;
    font-size: 1.2rem;
    cursor: pointer;
    padding: 6px 8px;
    border-radius: var(--lg-radius-small);
    color: var(--lg-text-1);
    transition: background 0.15s;
    line-height: 1;
}

.lg-header-icon-btn:active {
    background: var(--lg-surface-2);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Scroll container for non-home panel content. Direct port of Project Memory's
 *   pm-panel-content.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-panel-content
 * @tags        layout
 * @called-by   index.html (.lg-panel-content, Vehicles/Settings panels)
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-panel-content {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description A single status line + optional action row inside the Settings panel (platform
 *   line, auth line + button).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-settings-status-row
 * @tags        settings
 * @called-by   index.html (.lg-settings-status-row)
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-settings-status-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

/* ── Buttons — pm-button-action/pm-button-action-small/pm-button-secondary/
   pm-button-delete-large ported directly from Project Memory's theme-clean-buttons.css
   (same padding/radius/weight values, swapped to --lg-* tokens). ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Primary action button — full width, brand-colour fill. Direct port of Project
 *   Memory's pm-button-action. Used for Save in the vehicle modal and the Add Vehicle CTA.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-button-action
 * @tags        buttons
 * @called-by   index.html (#lg-add-vehicle-btn), lgVehicleForm (Save button)
 * @depends-on  --lg-radius-full, --lg-brand
 * @updated     2026-07-11
 */
.lg-button-action {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px 20px;
    border-radius: var(--lg-radius-full);
    background: var(--lg-brand);
    color: #fff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: background 0.15s, transform 0.1s;
}

.lg-button-action:active {
    background: var(--lg-brand-dark);
    transform: scale(0.98);
}

.lg-button-action:disabled {
    opacity: 0.5;
    pointer-events: none;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Compact version of lg-button-action — same brand fill, smaller padding/font.
 *   Direct port of Project Memory's pm-button-action-small. Used for the Settings sign-in/out
 *   button. No longer used by card Edit actions (12 July 2026) — those switched to the
 *   icon-only lg-button-icon/RHS pattern.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-button-action-small
 * @tags        buttons
 * @called-by   index.html (#lg-auth-btn)
 * @depends-on  --lg-radius-full, --lg-brand
 * @updated     2026-07-12
 */
.lg-button-action-small {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 9px 18px;
    border-radius: var(--lg-radius-full);
    background: var(--lg-brand);
    color: #fff;
    font-size: 0.88rem;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: background 0.15s, transform 0.1s;
}

.lg-button-action-small:active {
    background: var(--lg-brand-dark);
    transform: scale(0.97);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Secondary action button — a REAL button (bordered, muted fill), not link-style
 *   text. Direct port of Project Memory's pm-button-secondary, added there specifically to
 *   replace pm-button-text after Rocky repeatedly flagged link-style Cancel/secondary actions
 *   as looking dated and easy to mistake for a link. Not yet used by Task 4 (the vehicle modal
 *   closes via the ✕ icon, no separate Cancel button), kept available for the next screen that
 *   needs a real secondary action.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-button-secondary
 * @tags        buttons
 * @called-by   none yet — available for future secondary/cancel actions
 * @depends-on  --lg-radius-full, --lg-brand, --lg-surface-2, --lg-text-1
 * @updated     2026-07-11
 */
.lg-button-secondary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px 20px;
    border-radius: var(--lg-radius-full);
    background: var(--lg-surface-2);
    color: var(--lg-text-1);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    border: 1.5px solid var(--lg-brand);
    transition: background 0.15s, transform 0.1s;
}

.lg-button-secondary:active {
    transform: scale(0.98);
    opacity: 0.85;
}

.lg-button-secondary:disabled {
    opacity: 0.5;
    pointer-events: none;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Compact modifier on lg-button-secondary — auto width instead of the base class's
 *   full-width 100%, centered in a column-flex footer via `align-self`. First use, 15 July 2026 —
 *   the fuzzy-match candidate list's lone "New Expense" fallback button (lg-bank-txn-detail-modal),
 *   Rocky: "the button... is too big" when it was the only, full-width button in a
 *   lg-modal-footer.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-button-secondary-compact
 * @tags        buttons, bank-reconciliation
 * @called-by   lgBankTransactionDetail
 * @depends-on  lg-button-secondary
 * @updated     2026-07-15
 */
.lg-button-secondary-compact {
    width: auto;
    align-self: center;
    padding: 10px 22px;
    font-size: 0.9rem;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Low-emphasis secondary action button — small, lightly-frosted pill (never
 *   underlined text — Rocky's standing rule, repeated many times, finally written down 17 July
 *   2026: an underlined "text link" reads as a legacy web pattern and should never appear in this
 *   app). Sizes to its own content (inline-flex, no width:100%) so it sits as a small pill rather
 *   than stretching to fill its container like lg-button-secondary/lg-button-action do —
 *   `align-self` (17 July 2026 follow-up) was the missing piece: without any value, a flex parent
 *   with the (very common) default `align-items: stretch` — e.g. lg-modal-body — stretched this
 *   button to full width, turning the intended small pill into what Rocky described as "just a
 *   grey highlight" bar. First set to `flex-start`, then changed to `center` same day (Rocky: "the
 *   pill is not centered in the modal, it is left aligned") — centered horizontally within its
 *   container reads better for a standalone action sitting alone in a vertical form, rather than
 *   hugging the left edge. 14 July
 *   2026, first use: "Manage expense types…" under the Type of Expense select; reused since for
 *   "+ Add Income Category…" and lgJobForm's "↻ Use latest Timesheet entry" link. Briefly swapped
 *   to lg-button-secondary (full-width) for that link same day when the pill's own real bugs
 *   (missing `align-self`, clipped height) made it look wrong — once those were fixed here
 *   properly, switched straight back per Rocky: "what you had before was better... a simple line
 *   of text with a frosted highlight over it. It doesn't need to be a full size button."
 *   `white-space: nowrap` + `overflow-x: hidden` + ellipsis (same day) keeps its label on one
 *   line; `overflow-x` (not plain `overflow: hidden`) plus `line-height: 1.4` and more vertical
 *   padding fixed the vertical-clipping bug — the ↻ glyph's natural line height exceeded the box,
 *   and `overflow: hidden` clips both axes, not just the horizontal one ellipsis needs.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-button-link
 * @tags        buttons, modals
 * @called-by   lgExpenseTypePicker, lgIncomeTypePicker, lgJobForm
 * @depends-on  --lg-surface-2, --lg-border, --lg-radius-full, --lg-text-1
 * @updated     2026-07-17
 */
.lg-button-link {
    display: inline-flex;
    align-self: center;
    align-items: center;
    justify-content: center;
    line-height: 1.4;
    gap: 6px;
    background: var(--lg-surface-2);
    border: 1px solid var(--lg-border);
    border-radius: var(--lg-radius-full);
    padding: 8px 14px;
    color: var(--lg-text-1);
    font-size: 0.85rem;
    font-weight: 600;
    white-space: nowrap;
    max-width: 100%;
    overflow-x: hidden;
    overflow-y: visible;
    text-overflow: ellipsis;
    cursor: pointer;
}

.lg-button-link:active {
    opacity: 0.8;
    transform: scale(0.97);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Larger modifier on lg-button-link — bigger frosted highlight/touch target, same
 *   pill shape. First use: the Categories tab's "Select multiple to move…" toggle (18 July 2026,
 *   Rocky: "needs the highlight around select multiple to move to be a bit bigger").
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-cb-bulk-toggle-lg
 * @tags        buttons, expenses, bank-reconciliation
 * @called-by   lgCategoryBrowser
 * @depends-on  lg-button-link
 * @updated     2026-07-18
 */
.lg-cb-bulk-toggle-lg {
    padding: 12px 20px;
    font-size: 0.95rem;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Compact circular ghost icon button. Introduced 12 July 2026 for pencil/trash
 *   icons on the RHS of each card, then relocated the same day once cards became tap-to-edit —
 *   now used only for the Delete (🗑️) icon inside lg-modal-header-actions on each edit modal's
 *   header, next to the ✕ close button (Rocky: cards should tap straight into edit, with
 *   Delete "at the top of the edit card modal", specifically a small low-emphasis icon rather
 *   than a prominent full-width red button competing with Save — "definitely" the header-icon
 *   option over a full-width button). Adapted from Project Memory's pm-button-inline (44px/
 *   1.8rem base, shrunk to 31px/1.26rem inside pm-card-reminder-actions). No background/border —
 *   the emoji carries its own color; lg-button-icon-delete tints it via --lg-danger.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-button-icon
 * @tags        buttons, modals
 * @called-by   lgVehicleForm, lgJobForm, lgRouteForm, lgTripForm (header Delete icon)
 * @depends-on  none
 * @updated     2026-07-12
 */
.lg-button-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 31px;
    height: 31px;
    border-radius: 50%;
    font-size: 1.15rem;
    line-height: 1;
    cursor: pointer;
    border: none;
    background: none;
    flex-shrink: 0;
    transition: opacity 0.15s;
}

.lg-button-icon:active {
    opacity: 0.6;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Danger-colour modifier on lg-button-icon, used for the Delete icon specifically.
 *   See lg-button-icon's own docblock for the full context.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-button-icon-delete
 * @tags        buttons, modals
 * @called-by   lgVehicleForm, lgJobForm, lgRouteForm, lgTripForm (header Delete icon)
 * @depends-on  --lg-danger
 * @updated     2026-07-12
 */
.lg-button-icon-delete {
    color: var(--lg-danger);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Close button (✕) inside lg-modal-header. Direct port of Project Memory's
 *   pm-button-close.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-button-close
 * @tags        buttons, modals
 * @called-by   lgVehicleForm (.lg-modal-header)
 * @depends-on  --lg-radius-full, --lg-surface-2, --lg-text-2
 * @updated     2026-07-11
 */
.lg-button-close {
    width: 32px;
    height: 32px;
    border-radius: var(--lg-radius-full);
    background: var(--lg-surface-2);
    color: var(--lg-text-2);
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    border: none;
    transition: background 0.15s;
}

.lg-button-close:active {
    background: var(--lg-border);
}

/* ── Modal — direct port of Project Memory's pm-modal-overlay/pm-modal/pm-modal-header/
   pm-modal-body/pm-modal-footer (theme-clean-modals.css). Same header/body/footer-as-plain-
   siblings structure as pm-modal-place-edit.html — no <form> wrapper. ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Full-screen overlay backdrop, shared by every modal in the app (Vehicle, Trip,
 *   Route, Job, Place, Expense). Hidden by default, lg-active makes it visible. Direct port of
 *   Project Memory's pm-modal-overlay. `--lg-overlay-dark-mid` darkened from 0.45 to 0.75 alpha
 *   (13 July 2026) — with nested modals (e.g. Place opened on top of the Trip form via "📍 Save
 *   as Place"), a single 0.45 backdrop left the modal underneath legible enough to be confusing
 *   (Rocky: looked like two Save buttons). Every lg-modal-overlay shares this one token, so the
 *   fix applies uniformly to all nesting cases, not just Place-on-Trip.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-modal-overlay
 * @tags        modals
 * @called-by   index.html (every #lg-*-modal-overlay), every lg*Form component
 * @depends-on  --lg-z-modal, --lg-overlay-dark-mid
 * @updated     2026-07-13
 */
.lg-modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: var(--lg-overlay-dark-mid);
    z-index: var(--lg-z-modal);
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.lg-modal-overlay.lg-active {
    display: flex;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Modal card shell — header/body/footer stacked in a fixed-height column, body
 *   scrolls independently. Direct port of Project Memory's pm-modal.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-modal
 * @tags        modals
 * @called-by   lgVehicleForm
 * @depends-on  --lg-radius-large, --lg-shadow-large
 * @updated     2026-07-11
 */
.lg-modal {
    background: var(--lg-bg);
    border-radius: var(--lg-radius-large);
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: var(--lg-shadow-large);
    overflow: hidden;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Full-size modifier on lg-modal — true edge-to-edge, no gap around any side.
 *   First use: lgInvoiceForm (13 August 2026, multi-job invoicing) — Rocky found the standard
 *   dialog size cramped once an invoice could show a Contact, a growing Jobs list, an Add Job
 *   picker, and a full line-item list all at once, cutting content off at the sides. Scoped as an
 *   additive modifier class rather than changing lg-modal itself, which every other form in this
 *   app still uses at its normal dialog size. **13 August 2026 follow-up**: the first version only
 *   filled the space lg-modal-overlay's own 24px padding left available, still leaving a visible
 *   margin on every side — Rocky: "is there any reason why the invoice modal is not full width?"
 *   — fixed by also zeroing that padding on this specific overlay (`#lg-invoice-modal-overlay`,
 *   the only overlay that ever hosts a fullscreen modal), rather than touching the shared
 *   `.lg-modal-overlay` class every other modal still relies on for its own 24px inset.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-modal-fullscreen
 * @tags        modals
 * @called-by   lgInvoiceForm
 * @depends-on  lg-modal, #lg-invoice-modal-overlay
 * @updated     2026-08-13
 */
.lg-modal-fullscreen {
    max-width: 100%;
    max-height: 100%;
    width: 100%;
    height: 100%;
    border-radius: 0;
}

#lg-invoice-modal-overlay {
    padding: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Groups the header Delete icon (edit mode only) with the ✕ close button so
 *   lg-modal-header's title/close space-between layout still works with a third element —
 *   both live in this one flex group on the right, title stays alone on the left. Added
 *   12 July 2026 when Delete moved from the modal footer into the header.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-modal-header-actions
 * @tags        modals
 * @called-by   lgVehicleForm, lgJobForm, lgRouteForm, lgTripForm
 * @depends-on  none
 * @updated     2026-07-12
 */
.lg-modal-header-actions {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Modal header — title left, close button (and optionally the Delete icon, via
 *   lg-modal-header-actions) right. Fixed at top, does not scroll with the body. Direct port of
 *   Project Memory's pm-modal-header.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-modal-header
 * @tags        modals
 * @called-by   lgVehicleForm, lgJobForm, lgRouteForm, lgTripForm
 * @depends-on  --lg-border
 * @updated     2026-07-12
 */
.lg-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--lg-border);
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Scrollable content area inside the modal. Direct port of Project Memory's
 *   pm-modal-body.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-modal-body
 * @tags        modals
 * @called-by   lgVehicleForm
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Visually grouped "action area" card for a modal's secondary buttons (Timesheet/
 *   Expenses/Logbook/Attachments on lgJobForm) — a tinted background one step darker than the
 *   modal's own white body (--lg-surface, between --lg-bg and the buttons' own --lg-surface-2)
 *   so it reads as one cohesive card distinct from both the form fields above it and Save below
 *   it, rather than the buttons floating loose in the scroll. 28 July 2026, Rocky: "I want to
 *   create an 'ACTION AREA' look" — also fixes a real inconsistency he caught (Take Photo/Choose
 *   from Device had only 6px of gap between them, borrowed from lg-form-row's tighter internal
 *   spacing, vs. the 16px row-to-row gap every other button here got) — every direct button
 *   child of this container gets the same 16px gap via its own flex column, no per-button
 *   lg-form-row wrapper needed.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-job-action-area
 * @tags        jobs, modals
 * @called-by   lgJobForm
 * @depends-on  --lg-surface, --lg-radius-medium
 * @updated     2026-07-28
 */
.lg-job-action-area {
    display: flex;
    flex-direction: column;
    gap: 16px;
    padding: 16px;
    background: var(--lg-surface);
    border-radius: var(--lg-radius-medium);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description A `<select>` styled to look identical to `.lg-button-secondary` (13 August 2026,
 *   Rocky: "why is add to invoice a different box then the other buttons") — the Job form's "🧾 Add
 *   to Invoice…" picker needed multiple choices, unlike the single-target Timesheet/Expenses/
 *   Logbook buttons it sits alongside, so it's a real `<select>` under the hood, but with the
 *   browser's native select chrome stripped (`appearance: none` + no border-radius override) and
 *   its own text centered (`text-align-last`, Chromium/WebView support) so it's visually
 *   indistinguishable at rest from its sibling buttons.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-select-as-button
 * @tags        jobs, invoices, modals
 * @called-by   lgJobForm ("🧾 Add to Invoice…" select)
 * @depends-on  lg-button-secondary, --lg-radius-full, --lg-surface-2, --lg-text-1, --lg-brand
 * @updated     2026-08-13
 */
.lg-select-as-button {
    display: block;
    width: 100%;
    padding: 14px 20px;
    border-radius: var(--lg-radius-full);
    background: var(--lg-surface-2);
    color: var(--lg-text-1);
    font-size: 1rem;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    border: 1.5px solid var(--lg-brand);
    appearance: none;
    -webkit-appearance: none;
    text-align: center;
    text-align-last: center;
}

.lg-select-as-button:active {
    transform: scale(0.98);
    opacity: 0.85;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Collapsible panel revealed by tapping the "📎 Attachments" button in
 *   lg-job-action-area (28 July 2026, Rocky: "if the counter is 0 and there are no attachments
 *   it is not taking up screen space") — Take Photo/Choose from Device buttons, then the chip
 *   list underneath both (Rocky: attachments need to be under the buttons, not above them).
 *   Same 16px gap as its parent action-area card, so the panel doesn't read as a different
 *   rhythm once expanded.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-jf-attachments-panel
 * @tags        jobs
 * @called-by   lgJobForm
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-jf-attachments-panel {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Modal footer — action buttons, fixed at bottom, does not scroll with the body.
 *   Direct port of Project Memory's pm-modal-footer, with an added column layout since the
 *   vehicle modal stacks Save above Delete rather than a single row.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-modal-footer
 * @tags        modals
 * @called-by   lgVehicleForm
 * @depends-on  --lg-border
 * @updated     2026-07-11
 */
.lg-modal-footer {
    padding: 16px 20px;
    border-top: 1px solid var(--lg-border);
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* ── Forms — direct port of Project Memory's pm-form-row/pm-form-row-split/pm-form-label/
   pm-input (theme-clean-forms.css). ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Standard form field wrapper — label stacked above input. Direct port of Project
 *   Memory's pm-form-row.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-form-row
 * @tags        forms
 * @called-by   lgVehicleForm
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-form-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Two-column form row modifier — splits a lg-form-row into two equal-width
 *   lg-form-col fields (Purchase price + Purchase date side by side). Direct port of Project
 *   Memory's pm-form-row-split.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-form-row-split
 * @tags        forms
 * @called-by   lgVehicleForm
 * @depends-on  lg-form-row
 * @updated     2026-07-11
 */
.lg-form-row-split {
    flex-direction: row;
    gap: 12px;
}

.lg-form-row-split .lg-form-col {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

/**
 * @pm-registry
 * @description A label + some extra inline content (e.g. a checkbox) sharing one header line
 *   above a full-width field below it — 28 July 2026, Rocky: putting the Business checkbox in its
 *   own lg-form-row-split column next to Purpose "cut it in half," which "looked terrible." This
 *   keeps Purpose's textarea full width — only the label row itself is a flex row, "Purpose" on
 *   the left, the Business checkbox+label (in its own lg-form-row-inline) pushed to the right via
 *   justify-content: space-between.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-form-label-row
 * @tags        forms
 * @called-by   lgTripForm
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-form-label-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

/* Excluded word combinations list (Settings, schema v35, 18 July 2026) — a plain label + remove
   button row, one per saved combination. */
.lg-exclude-phrase-row {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Inline form row — label/checkbox side by side on one line. Direct port of
 *   Project Memory's pm-form-row-inline. Used for the trip form's Business trip checkbox.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-form-row-inline
 * @tags        forms
 * @called-by   lgTripForm
 * @depends-on  lg-form-row
 * @updated     2026-07-11
 */
.lg-form-row-inline {
    flex-direction: row;
    align-items: center;
    gap: 10px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Wraps a text input with a small icon-button action beside it (e.g. lgTripForm's
 *   "📍 Save as Place" next to Start point/Destination) — the input takes the remaining space
 *   (flex:1, min-width:0, same guard as lg-form-row-split's known narrow-screen flexbox bug),
 *   the button stays fixed-width via lg-button-icon.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-input-with-action
 * @tags        forms
 * @called-by   lgTripForm
 * @depends-on  lg-input, lg-button-icon
 * @updated     2026-07-13
 */
.lg-input-with-action {
    display: flex;
    align-items: center;
    gap: 8px;
}

.lg-input-with-action .lg-input {
    flex: 1;
    min-width: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Positioning context for a Places autocomplete (Task 7b) — wraps a text input
 *   (optionally itself wrapped in lg-input-with-action) so its paired lg-autocomplete-suggestions
 *   box can position absolutely right underneath.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-autocomplete
 * @tags        forms
 * @called-by   lgTripStart, lgTripForm
 * @depends-on  none
 * @updated     2026-07-13
 */
.lg-autocomplete {
    position: relative;
}

/**
 * @pm-registry
 * @description A small icon-only button pinned inside an input's own right edge, vertically
 *   centered (28 July 2026) — same absolute-positioning technique as
 *   lg-bank-search-clear-btn, generalized for reuse. First use: Start Trip's "↩️ Return trip"
 *   suggestion, replacing an earlier always-visible full-width lg-button-link pill Rocky found
 *   didn't look good sitting under Destination every time it showed. Needs the input itself to
 *   reserve right-side padding — see lg-input-has-suffix-btn — and its parent to be
 *   position:relative (lg-autocomplete already is).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-input-suffix-btn
 * @tags        forms
 * @called-by   lgTripStart
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-input-suffix-btn {
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    font-size: 1.1rem;
    line-height: 1;
    cursor: pointer;
    padding: 4px;
}

/**
 * @pm-registry
 * @description Modifier applied to an `.lg-input` whenever an lg-input-suffix-btn sits inside its
 *   wrapper, reserving enough right-side padding that typed text never runs under the icon.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-input-has-suffix-btn
 * @tags        forms
 * @called-by   lgTripStart
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-input-has-suffix-btn {
    padding-right: 36px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Dropdown list of matching Place suggestions, positioned directly under its
 *   lg-autocomplete wrapper. Hidden by default (lg-hidden) — shown/populated by
 *   lgUtils.lgWirePlaceAutocomplete as the user types.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-autocomplete-suggestions
 * @tags        forms
 * @called-by   lgUtils (lgWirePlaceAutocomplete)
 * @depends-on  --lg-bg, --lg-border, --lg-radius-small, --lg-shadow-small
 * @updated     2026-07-13
 */
.lg-autocomplete-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 4px;
    background: var(--lg-bg);
    border: 1px solid var(--lg-border);
    border-radius: var(--lg-radius-small);
    box-shadow: var(--lg-shadow-small);
    max-height: 180px;
    overflow-y: auto;
    z-index: 5;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description One tappable suggestion row inside lg-autocomplete-suggestions.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-autocomplete-item
 * @tags        forms
 * @called-by   lgUtils (lgWirePlaceAutocomplete)
 * @depends-on  --lg-text-1, --lg-surface-2
 * @updated     2026-07-13
 */
.lg-autocomplete-item {
    padding: 10px 14px;
    font-size: 0.92rem;
    color: var(--lg-text-1);
    cursor: pointer;
}

.lg-autocomplete-item:active {
    background: var(--lg-surface-2);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Label above a form input. Direct port of Project Memory's pm-form-label.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-form-label
 * @tags        forms
 * @called-by   lgVehicleForm
 * @depends-on  --lg-text-2
 * @updated     2026-07-11
 */
.lg-form-label {
    font-size: 0.82rem;
    font-weight: 700;
    color: var(--lg-text-2);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Small non-uppercase, non-bold aside inside a lg-form-label — e.g. the Expense
 *   form's Amount label explaining it auto-fills from Litres × Price/litre when Category is
 *   Fuel (Task 9 step 2). Toggled via lg-hidden alongside whatever field it's explaining.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-form-label-hint
 * @tags        forms, expenses
 * @called-by   lgExpenseEditForm
 * @depends-on  --lg-text-3
 * @updated     2026-07-13
 */
.lg-form-label-hint {
    font-weight: 400;
    text-transform: none;
    letter-spacing: normal;
    color: var(--lg-text-3);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description One row inside the Type of Expense picker (lgExpenseTypePicker, 14 July 2026 —
 *   replaced the old inline "Manage expense types…" list, which Rocky found "looks really bad"
 *   crammed under the select on the main Add Expense modal). A built-in row is just a tappable
 *   label; a custom row adds its two-tap-confirm Delete + rename icons, name left, icons right.
 *   lg-etp-row-selected highlights whichever row matches the value the picker was opened with.
 *   Reused as-is by lgIncomeTypePicker (15 July 2026) and lgPersonalTypePicker (17 July 2026) —
 *   same row/list pattern, different data. Border + shadow added, and the row list wrapped in
 *   lg-list-edge-modal (18 July 2026 follow-up — Rocky, comparing against the Categories tab's own
 *   entries screen: these rows were "a narrower rounded corner pill style that doesnt go directly
 *   to the edge of the screen... make it so the personal and business cards match all the other
 *   straight through cards") — same border/shadow/edge-to-edge treatment as lg-card-expense,
 *   including the square-corner override below, rather than a second near-duplicate card style.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-etp-row
 * @tags        forms, expenses, income, bank-reconciliation
 * @called-by   lgExpenseTypePicker, lgIncomeTypePicker, lgPersonalTypePicker
 * @depends-on  --lg-surface-2, --lg-radius-medium, --lg-brand, --lg-border, --lg-shadow-small
 * @updated     2026-07-18
 */
.lg-etp-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 14px;
    border-radius: var(--lg-radius-medium);
    background: var(--lg-surface-2);
    border: 1px solid var(--lg-border);
    box-shadow: var(--lg-shadow-small);
    margin-bottom: 6px;
}

:root[data-card-style="square"] .lg-etp-row {
    border-radius: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Highlight modifier on lg-etp-row for whichever row matches the value the picker
 *   was opened with. See lg-etp-row's own docblock for the full context.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-etp-row-selected
 * @tags        forms, expenses, income
 * @called-by   lgExpenseTypePicker, lgIncomeTypePicker
 * @depends-on  --lg-brand
 * @updated     2026-07-15
 */
.lg-etp-row-selected {
    border: 1.5px solid var(--lg-brand);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Tappable name/label area of a lg-etp-row, left of its lg-etp-row-actions icons.
 *   See lg-etp-row's own docblock for the full context.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-etp-row-label
 * @tags        forms, expenses, income
 * @called-by   lgExpenseTypePicker, lgIncomeTypePicker
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-etp-row-label {
    flex: 1;
    padding: 4px 0;
    cursor: pointer;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Right-side icon group (✏️ rename, 🗑️ two-tap-delete) on a custom lg-etp-row. See
 *   lg-etp-row's own docblock for the full Type of Expense picker layout this belongs to.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-etp-row-actions
 * @tags        forms, expenses, income
 * @called-by   lgExpenseTypePicker, lgIncomeTypePicker
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-etp-row-actions {
    display: flex;
    gap: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Right-side wrapper on a custom lg-etp-row (17 July 2026, category counts) grouping
 *   the count badge and lg-etp-row-actions together as one flex item, so lg-etp-row's own
 *   `justify-content: space-between` still cleanly splits label (left) from everything else
 *   (right) regardless of whether a count is showing.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-etp-row-right
 * @tags        forms, expenses, bank-reconciliation
 * @called-by   lgExpenseTypePicker, lgPersonalTypePicker
 * @depends-on  none
 * @updated     2026-07-17
 */
.lg-etp-row-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Right-aligned "N" count on a lg-etp-row (17 July 2026, `show_category_counts`
 *   Settings toggle) — how many transactions/expenses already use this category. Muted, small —
 *   reads as a count, not part of the row's own tappable label.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-etp-row-count
 * @tags        forms, expenses, bank-reconciliation
 * @called-by   lgExpenseTypePicker, lgPersonalTypePicker
 * @depends-on  --lg-text-2
 * @updated     2026-07-17
 */
.lg-etp-row-count {
    font-size: 0.8rem;
    color: var(--lg-text-2);
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Row of tappable receipt chips (schema v8, an expense can carry more than one
 *   receipt — see lgExpenseEditForm's own docblock for the "servo receipt is fuel + a
 *   non-deductible drink" example that motivated this). Sits below the Take Photo/Upload
 *   buttons, hidden via lg-hidden until at least one receipt is attached, wraps onto a new line
 *   once it has more than fit one row.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-chips
 * @tags        forms, expenses
 * @called-by   lgExpenseEditForm
 * @depends-on  none
 * @updated     2026-07-13
 */
.lg-receipt-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Column wrapper around one receipt/attachment chip plus its optional label caption
 *   underneath (28 July 2026, Rocky: "add a name works but needs to display under the pdf icon in
 *   attachments") — lg-receipt-chips stays a flex-wrap row of these, so multiple chip+caption
 *   pairs still wrap onto new lines together rather than the chip and its caption drifting apart.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-chip-wrap
 * @tags        forms, expenses, jobs
 * @called-by   lgExpenseEditForm, lgJobForm
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-receipt-chip-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    width: 64px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Small caption under a receipt/attachment chip showing its label — only rendered
 *   when a label is set. Truncated to 10 characters + "…" in JS (exact character count, per
 *   Rocky's own spec) before reaching this element, so overflow/ellipsis here is just a safety
 *   net, not the primary truncation mechanism.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-chip-label
 * @tags        forms, expenses, jobs
 * @called-by   lgExpenseEditForm, lgJobForm
 * @depends-on  --lg-text-2
 * @updated     2026-07-28
 */
.lg-receipt-chip-label {
    font-size: 0.7rem;
    color: var(--lg-text-2);
    max-width: 64px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description One receipt chip — a small square photo thumbnail or PDF icon, tappable to open
 *   lgReceiptViewer, with a small Remove button overlaid in the corner.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-chip
 * @tags        forms, expenses
 * @called-by   lgExpenseEditForm
 * @depends-on  --lg-radius-medium, --lg-border, --lg-surface-2
 * @updated     2026-07-13
 */
.lg-receipt-chip {
    position: relative;
    width: 64px;
    height: 64px;
    border-radius: var(--lg-radius-medium);
    border: 1px solid var(--lg-border);
    background: var(--lg-surface-2);
    cursor: pointer;
    overflow: hidden;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Photo thumbnail filling a receipt chip.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-chip-img
 * @tags        forms, expenses
 * @called-by   lgExpenseEditForm
 * @depends-on  none
 * @updated     2026-07-13
 */
.lg-receipt-chip-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Document icon filling a receipt chip when the attached file is a PDF (no
 *   thumbnail possible).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-chip-pdf-icon
 * @tags        forms, expenses
 * @called-by   lgExpenseEditForm
 * @depends-on  none
 * @updated     2026-07-13
 */
.lg-receipt-chip-pdf-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    font-size: 1.8rem;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Full-viewport black backdrop for the shared Receipt/PDF Viewer (Task 9) — a
 *   photo (pinch-zoom, lg-receipt-viewer-img) or an in-app-rendered PDF (lg-receipt-viewer-pdf +
 *   its nav pill), never both at once. Plain fixed overlay, not a .lg-modal-overlay — there's no
 *   header/body/footer form shell here, just full-screen content and a close button, same
 *   structural pattern as the Task 8 test harness's lg-media-test-preview-expanded it replaces.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-viewer
 * @tags        shared, expenses
 * @called-by   lgReceiptViewer
 * @depends-on  --lg-z-modal
 * @updated     2026-07-13
 */
.lg-receipt-viewer {
    display: none;
    position: fixed;
    inset: 0;
    background: #000;
    z-index: var(--lg-z-modal);
}

.lg-receipt-viewer.lg-active {
    display: block;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Close button for the Receipt/PDF Viewer — fixed top-right, safe-area-aware (same
 *   status-bar-clearance fix as lg-media-test-preview-close needed, 13 July 2026).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-viewer-close
 * @tags        shared, expenses
 * @called-by   lgReceiptViewer
 * @depends-on  --lg-z-modal
 * @updated     2026-07-13
 */
.lg-receipt-viewer-close {
    position: fixed;
    top: calc(env(safe-area-inset-top) + 16px);
    right: 16px;
    z-index: calc(var(--lg-z-modal) + 1);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Delete button for the Receipt/PDF Viewer — fixed top-left, safe-area-aware,
 *   mirrors lg-receipt-viewer-close's positioning exactly. Hidden unless the caller passed an
 *   onDelete callback to open() (28 July 2026, Rocky: "you cant really tell if you want to
 *   delete the photo or doc until you can see it full screen" — deleting used to be a tiny ✕ on
 *   a 64px chip, 2px from a much larger tap target that opened the viewer, making it very easy
 *   to delete something by accident; moved here where there's room for a real tap target and the
 *   user is actually looking at the thing before deciding).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-viewer-delete
 * @tags        shared, expenses, jobs
 * @called-by   lgReceiptViewer
 * @depends-on  --lg-z-modal
 * @updated     2026-07-28
 */
.lg-receipt-viewer-delete {
    position: fixed;
    top: calc(env(safe-area-inset-top) + 16px);
    left: 16px;
    z-index: calc(var(--lg-z-modal) + 1);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Full-viewport photo in the Receipt/PDF Viewer — pinch-zoom/pan target
 *   (lgReceiptViewer._wirePhotoZoom). touch-action:none hands all gesture handling to that JS
 *   rather than the WebView's own default scroll/zoom.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-viewer-img
 * @tags        shared, expenses
 * @called-by   lgReceiptViewer
 * @depends-on  none
 * @updated     2026-07-13
 */
.lg-receipt-viewer-img {
    position: fixed;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: contain;
    touch-action: none;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Scrollable container the in-app PDF viewer's canvas renders into — ported from
 *   Project Memory's proven pm-lightbox-pdf. Panning a zoomed-in page is just this container's
 *   native overflow:auto scroll in both directions (no custom pan/transform logic needed) — only
 *   pinch-to-zoom itself is custom JS (lgReceiptViewer._wirePdfPinchZoom). `overscroll-behavior:
 *   contain` (28 July 2026, bug fix — Rocky: swiping left/right on a PDF "cause it to close
 *   instantly") — at 1x zoom the canvas exactly fits the container width, so a horizontal swipe
 *   has no native content to scroll to and immediately overscrolls past the boundary; without
 *   `contain` that overscroll was chaining past this element to the WebView/OS's own unclaimed-
 *   swipe handling (Android's edge-swipe-back gesture, almost certainly), closing the viewer
 *   instead of reaching lgReceiptViewer's own swipe-to-navigate listener on the overlay.
 *   Deliberately does NOT also set `touch-action: pan-y` — a first attempt at this fix did, and it
 *   broke dragging a zoomed-in page around (Rocky: "user cant drag the pdf around once it is
 *   zoomed in which is nessecary to see parts of the doc") by telling the browser to only ever
 *   allow native vertical panning here, which blocks the horizontal half of the native scroll
 *   this container depends on once zoomed. `overscroll-behavior: contain` alone is the correct,
 *   narrower fix — it stops scroll/gesture chaining at the boundary without restricting which
 *   directions native panning is allowed to move in. Photos don't need any of this:
 *   lg-receipt-viewer-img uses `touch-action: none` instead, since panning there is 100% custom
 *   JS (translate transform, not native scroll) regardless of zoom level.
 *   `text-align: center` (not `display:flex; justify-content:center`), 28 July 2026 — bug fix,
 *   Rocky: zoomed in, "i can zoom and darg all the way to RHS of document but not LHS." Classic
 *   flexbox-centering-overflow bug: when a flex child grows past its `justify-content: center`
 *   parent, most browsers only ever extend the *scrollable* area on the end side (right, in LTR)
 *   — scrollLeft starts at 0 and the start-side overflow is simply unreachable, even though it's
 *   visually centered before zooming. `text-align: center` + `display: inline-block` on the
 *   canvas produces the same centered-at-1x look without that asymmetry — an inline-block's
 *   overflow scrolls symmetrically in both directions once it's larger than its container.
 *   Bottom padding grew 80px → 140px same day (landscape bug fix — see _renderPdfPage's own
 *   docblock) to properly clear the now-taller 3-row bottom bar (slider + nav pill + label bar).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-viewer-pdf
 * @tags        shared, expenses
 * @called-by   lgReceiptViewer
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-receipt-viewer-pdf {
    width: 100%;
    height: 100%;
    overflow: auto;
    text-align: center;
    padding: 60px 0 140px;
    box-sizing: border-box;
    overscroll-behavior: contain;
}

.lg-receipt-viewer-pdf canvas {
    display: inline-block;
    background: #fff;
    box-shadow: var(--lg-shadow-small);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Fixed bottom-center stack for the PDF page slider, the prev/next/counter pill,
 *   and the label bar — 28 July 2026, replacing lg-receipt-viewer-pdf-nav's own independent fixed
 *   positioning so all three can stack vertically via plain flex-column flow instead of each
 *   needing its own hand-tuned `bottom` offset. Always present (photos just show none of its
 *   children, or only the label bar); each child toggles its own lg-hidden.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-viewer-bottom-bar
 * @tags        shared, expenses, jobs
 * @called-by   lgReceiptViewer
 * @depends-on  --lg-z-modal
 * @updated     2026-07-28
 */
.lg-receipt-viewer-bottom-bar {
    position: fixed;
    bottom: calc(20px + env(safe-area-inset-bottom));
    left: 0;
    right: 0;
    z-index: calc(var(--lg-z-modal) + 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 0 16px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Page-jump slider for a multi-page PDF, 28 July 2026 — Rocky: "at the bottom of
 *   the pdf could be a page slider to scroll to different parts of doc." Sits above the prev/
 *   next pill inside lg-receipt-viewer-bottom-bar; hidden for single-page PDFs (a 1-1 range slider
 *   is a no-op) and for photos, same as the pill itself.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-viewer-pdf-page-slider-row
 * @tags        shared, expenses, jobs
 * @called-by   lgReceiptViewer
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-receipt-viewer-pdf-page-slider-row {
    width: 100%;
    max-width: 320px;
}

.lg-receipt-viewer-pdf-page-slider-row input[type="range"] {
    width: 100%;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Page prev/next + counter pill for the in-app PDF viewer — ported from Project
 *   Memory's proven pm-lightbox-pdf-nav. Always shown while a PDF is open, even for a single-page
 *   document (next/prev just no-op at the bounds) — same simplification PM's own lightbox uses.
 *   Positioning moved to the parent lg-receipt-viewer-bottom-bar (28 July 2026) — this class now
 *   only carries the pill's own visual styling.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-viewer-pdf-nav
 * @tags        shared, expenses
 * @called-by   lgReceiptViewer
 * @depends-on  --lg-radius-full
 * @updated     2026-07-28
 */
.lg-receipt-viewer-pdf-nav {
    display: flex;
    align-items: center;
    gap: 14px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: var(--lg-radius-full);
    padding: 8px 18px;
    color: #fff;
}

.lg-receipt-viewer-pdf-nav button {
    background: none;
    border: none;
    color: #fff;
    font-size: 1.4rem;
    cursor: pointer;
    line-height: 1;
}

.lg-receipt-viewer-pdf-nav span {
    font-size: 0.85rem;
    font-weight: 600;
    min-width: 40px;
    text-align: center;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Tappable caption bar showing the current photo/PDF's label (or a placeholder
 *   inviting one), 28 July 2026 — Rocky: "the pdf should probably have a filename under it or
 *   allow user to edit and enter a name. otherwise user has no idea what it is." Tapping the text
 *   swaps it for an inline text input (lg-receipt-viewer-label-input) — no separate edit modal,
 *   consistent with this app's "every modal does one thing"/2-modal-max convention for something
 *   this small. Only shown when the caller passed an onRename callback to open() (Settings/
 *   Invoice callers have no per-item label concept). Same frosted-pill styling as the PDF nav
 *   pill for visual consistency within the same bottom-bar stack.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-receipt-viewer-label-bar
 * @tags        shared, expenses, jobs
 * @called-by   lgReceiptViewer
 * @depends-on  --lg-radius-full
 * @updated     2026-07-28
 */
.lg-receipt-viewer-label-bar {
    display: flex;
    align-items: center;
    max-width: 100%;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    border-radius: var(--lg-radius-full);
    padding: 8px 18px;
    color: #fff;
}

.lg-receipt-viewer-label-bar span {
    font-size: 0.85rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 220px;
    cursor: pointer;
}

.lg-receipt-viewer-label-bar input {
    background: none;
    border: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.6);
    color: #fff;
    font-size: 0.85rem;
    font-weight: 600;
    width: 200px;
    outline: none;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Standard single-line text/number/date/select input. Direct port of Project
 *   Memory's pm-input.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-input
 * @tags        forms
 * @called-by   lgVehicleForm
 * @depends-on  --lg-radius-small, --lg-border, --lg-brand
 * @updated     2026-07-11
 */
.lg-input {
    width: 100%;
    padding: 10px 14px;
    border-radius: var(--lg-radius-small);
    border: 1.5px solid var(--lg-border);
    background: var(--lg-bg);
    color: var(--lg-text-1);
    font-size: 0.95rem;
    font-family: inherit;
    -webkit-appearance: none;
    appearance: none;
}

.lg-input:focus {
    outline: none;
    border-color: var(--lg-brand);
}

/* Locked/calculated field state (14 July 2026, first use: Timesheet's Hours worked/Minutes,
   disabled whenever Start time/End time/Break has anything in it — Rocky: seeing the field
   silently get overwritten after Save was confusing, needed to visibly read as "calculated"
   while the modal is still open). Greyed background + muted text, no extra label text needed. */
.lg-input:disabled {
    background: var(--lg-surface-2);
    color: var(--lg-text-3);
    cursor: not-allowed;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Modifier on .lg-input for a <button> standing in for a field that opens a picker
 *   modal instead of a native <select> — 14 July 2026, first use: Type of Expense
 *   (lgExpenseTypePicker). Left-aligns text (buttons default to centered) and adds a "▾" affordance
 *   so it still reads as a tappable field, not a plain button.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-input-button
 * @tags        forms
 * @called-by   lgExpenseEditForm
 * @depends-on  lg-input
 * @updated     2026-07-14
 */
.lg-input-button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    text-align: left;
    cursor: pointer;
}

.lg-input-button::after {
    content: '▾';
    color: var(--lg-text-3);
    margin-left: 8px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Marks a required field as invalid — red border, briefly (cleared automatically by
 *   lgUtils.lgFlagInvalidField once the user edits it). Introduced 13 July 2026 after Rocky hit a
 *   real UX bug: a form's Save button silently no-op'd on a missing required field (Place's Name,
 *   Route's Place pickers) with zero visible feedback, reading as "Save is broken" rather than
 *   "you need to fill this in."
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-input-error
 * @tags        forms
 * @called-by   lgUtils (lgFlagInvalidField)
 * @depends-on  --lg-danger
 * @updated     2026-07-13
 */
.lg-input-error {
    border-color: var(--lg-danger) !important;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Settings' uploaded business logo preview. Bug fix, 14 July 2026 — Rocky: "the
 *   uploaded logo is squa[s]hed into a rectangle even when it is a square or circle." Root cause:
 *   this img sits in a flex-column `.lg-form-row`, whose default `align-items: stretch` resolves
 *   the img's width to a fixed 120px (clamped from a full-width stretch by the old inline
 *   `max-width`) before height is computed — with width already a definite value, `max-height:80px`
 *   then clamped height independently, so width and height stopped scaling together, distorting
 *   anything not already 120:80. Fixed with an explicit fixed box (120×80) plus
 *   `object-fit: contain`, which always preserves the source image's real aspect ratio inside that
 *   box regardless of the surrounding flex layout, letterboxing rather than stretching.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-business-logo-preview
 * @tags        settings, invoices
 * @called-by   settingsComponent (index.html)
 * @depends-on  --lg-radius-small
 * @updated     2026-07-14
 */
.lg-business-logo-preview {
    width: 120px;
    height: 80px;
    object-fit: contain;
    border-radius: var(--lg-radius-small);
    margin-top: 8px;
    cursor: pointer;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bottom-of-screen toast message (lgUtils.lgShowToast) — fixed, centered, fades in/
 *   out via opacity+translateY rather than display toggling so the transition actually plays.
 *   Deliberately theme-independent (a solid dark pill, not var(--lg-surface)/var(--lg-text-1))
 *   since it needs to read clearly over whatever's behind it in either light or dark mode, same
 *   reasoning most toast/snackbar patterns use. Sits above every modal (`--lg-z-modal` + 10) —
 *   invoice-sent is the first use, but nothing about this ties it to invoices specifically.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-toast
 * @tags        utils
 * @called-by   lgUtils (lgShowToast)
 * @depends-on  --lg-radius-full, --lg-shadow-large, --lg-z-modal
 * @updated     2026-07-14
 */
.lg-toast {
    position: fixed;
    left: 50%;
    bottom: 32px;
    transform: translate(-50%, 12px);
    z-index: calc(var(--lg-z-modal) + 10);
    max-width: calc(100% - 48px);
    padding: 12px 20px;
    border-radius: var(--lg-radius-full);
    background: rgba(17, 24, 39, 0.92);
    color: #f9fafb;
    font-size: 0.95rem;
    font-weight: 600;
    text-align: center;
    box-shadow: var(--lg-shadow-large);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.lg-toast.lg-toast-visible {
    opacity: 1;
    transform: translate(-50%, 0);
}

/* ── Vehicle card text styling — modeled on Project Memory's pm-card-reminder-title/
   pm-card-reminder-due (theme-clean-reminders.css); the type pill is modeled on
   pm-card-note-category (theme-clean-notes.css). Outer box (lg-card-vehicle) removed 13 July
   2026 — Vehicle cards now use the shared lg-card-expense box instead. ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Vehicle name line on the card. Modeled on Project Memory's
 *   pm-card-reminder-title.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-vehicle-title
 * @tags        vehicles, cards
 * @called-by   lgVehicleList
 * @depends-on  --lg-text-1
 * @updated     2026-07-11
 */
.lg-card-vehicle-title {
    font-size: 0.98rem;
    font-weight: 700;
    color: var(--lg-text-1);
    margin-bottom: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Type pill (Car/Motorbike/Other) on the card. Modeled on Project Memory's
 *   pm-card-note-category.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-vehicle-type
 * @tags        vehicles, cards
 * @called-by   lgVehicleList
 * @depends-on  --lg-radius-full, --lg-brand-light, --lg-brand-dark
 * @updated     2026-07-11
 */
.lg-card-vehicle-type {
    display: inline-block;
    padding: 2px 10px;
    border-radius: var(--lg-radius-full);
    background: var(--lg-brand-light);
    color: var(--lg-brand-dark);
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Purchase price/date/depreciation meta line on the card. Modeled on Project
 *   Memory's pm-card-reminder-due.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-vehicle-meta
 * @tags        vehicles, cards
 * @called-by   lgVehicleList
 * @depends-on  --lg-text-3
 * @updated     2026-07-11
 */
.lg-card-vehicle-meta {
    font-size: 0.82rem;
    color: var(--lg-text-3);
    margin-bottom: 8px;
}

/* ── Empty state — direct port of Project Memory's pm-notes-empty
   (theme-clean-notes-modal.css). ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Empty-state block shown when a list has no rows yet. Direct port of Project
 *   Memory's pm-notes-empty.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-empty-state
 * @tags        shared
 * @called-by   lgVehicleList, lgApp (DB init failure)
 * @depends-on  --lg-text-3
 * @updated     2026-07-11
 */
.lg-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    gap: 8px;
    color: var(--lg-text-3);
    text-align: center;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Icon inside lg-empty-state.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-empty-state-icon
 * @tags        shared
 * @called-by   lgVehicleList
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-empty-state-icon {
    font-size: 2rem;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bold headline text inside lg-empty-state.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-empty-state-text
 * @tags        shared
 * @called-by   lgVehicleList
 * @depends-on  --lg-text-2
 * @updated     2026-07-11
 */
.lg-empty-state-text {
    font-size: 1rem;
    font-weight: 700;
    color: var(--lg-text-2);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Muted hint text inside lg-empty-state, below the headline.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-empty-state-hint
 * @tags        shared
 * @called-by   lgVehicleList
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-empty-state-hint {
    font-size: 0.85rem;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Centered readout box for a captured value (currently: GPS coordinates in
 *   lgPlaceForm) — sits under a full-width action button rather than crammed inline beside it.
 *   Introduced 13 July 2026 after Rocky flagged the inline button+text layout as janky.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-readout-box
 * @tags        shared
 * @called-by   lgPlaceForm
 * @depends-on  none
 * @updated     2026-07-13
 */
.lg-readout-box {
    text-align: center;
    font-size: 0.85rem;
    color: var(--lg-text-3);
    background: var(--lg-surface-2);
    border: 1px solid var(--lg-border);
    border-radius: var(--lg-radius-small);
    padding: 10px 14px;
    margin-top: 10px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bold-text modifier on lg-readout-box, used for the Invoice modal's Total line
 *   (14 July 2026, Rocky) — scoped rather than making lg-readout-box bold everywhere, since it's
 *   shared with lgPlaceForm's plain GPS-coordinates readout.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-readout-box-bold
 * @tags        invoices
 * @called-by   invoiceFormComponent.js (.lg-readout-box-bold)
 * @depends-on  none
 * @updated     2026-07-14
 */
.lg-readout-box-bold {
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--lg-text-1);
}

/* ── Job card text styling — lg-card-job-title/-meta, same structure/values as
   lg-card-vehicle-title/-meta. Outer box (lg-card-job) removed 13 July 2026 — Job cards now use
   the shared lg-card-expense box instead. ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Job name line on the card. Same structure/values as lg-card-vehicle-title.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-job-title
 * @tags        jobs, cards
 * @called-by   lgJobList
 * @depends-on  --lg-text-1
 * @updated     2026-07-11
 */
.lg-card-job-title {
    font-size: 0.98rem;
    font-weight: 700;
    color: var(--lg-text-1);
    margin-bottom: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description ⏳/🧾/💰 payment-status icon before the job name (schema v26, 15 July 2026 — see
 *   lgJobList._jobPaymentIcon). Billing info was deliberately removed from the Job card 11 July
 *   2026; this is a much lighter return of it — one glance icon, not a full breakdown.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-job-payment-icon
 * @tags        jobs, cards
 * @called-by   lgJobList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-job-payment-icon {
    margin-right: 6px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Date-range/billing-summary meta line(s) on the card. Same structure/values as
 *   lg-card-vehicle-meta.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-job-meta
 * @tags        jobs, cards
 * @called-by   lgJobList
 * @depends-on  --lg-text-3
 * @updated     2026-07-11
 */
.lg-card-job-meta {
    font-size: 0.82rem;
    color: var(--lg-text-3);
    margin-bottom: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bold/darker modifier for lg-card-job-meta, Jobs list card only (17 July 2026,
 *   Rocky: "text in card is hard to read. make bold") — the muted `--lg-text-3`/regular-weight
 *   look stays the default everywhere else lg-card-job-meta is reused (Bank Accounts, Bank
 *   Transaction detail, Bank Statements, Income/Expense edit forms all rely on it staying
 *   deliberately muted), so this is a second class added alongside it rather than a change to the
 *   shared base class.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-job-meta-bold
 * @tags        jobs, cards
 * @called-by   lgJobList
 * @depends-on  --lg-text-1
 * @updated     2026-07-17
 */
.lg-card-job-meta-bold {
    font-weight: 700;
    color: var(--lg-text-1);
}

/* ── Job form extras — section labels, textarea, and the per-billing-line sub-card. ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Small uppercase section-divider label inside a modal body, grouping related
 *   fields (e.g. "Start date", "Billing") — same visual weight as lg-home-group-label, reused
 *   here for a different purpose (form sections rather than home tile groups). `margin-bottom`
 *   added 14 July 2026 (Rocky, on the Invoice modal's "Line items — tap to edit" label sitting
 *   flush against the first card underneath it) — applies globally since every other use of this
 *   label benefits from the same breathing room, not just Invoices.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-form-section-label
 * @tags        forms
 * @called-by   lgJobForm, lgInvoiceForm
 * @depends-on  --lg-text-2
 * @updated     2026-07-14
 */
.lg-form-section-label {
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: var(--lg-text-2);
    margin-top: 4px;
    margin-bottom: 8px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Multi-line text input. Direct port of Project Memory's pm-textarea, with a
 *   smaller min-height (Logit's job Notes field is a brief aside, not a primary content area
 *   like PM's note-taking feature). Auto-grows to fit its content (14 July 2026, Rocky — the
 *   Timesheet "What did you do?" box was a fixed 3 lines, forcing a scroll for anything longer)
 *   via `lgUtils.lgAutoResizeTextarea`, wired app-wide by `lgApp` (a document-level 'input'
 *   listener for live typing, plus a MutationObserver that sizes any textarea the instant it's
 *   rendered — covers a pre-filled long note on an existing record too, not just fresh typing) —
 *   applies to every `.lg-textarea` in the app, not just Timesheet, since they all had the exact
 *   same fixed-height problem. `resize: none` replaces the old manual drag-handle — pointless
 *   once the box is already auto-sizing to its content, a manual resize would just get overwritten
 *   on the next keystroke. `overflow: hidden` is required for `scrollHeight` to measure only the
 *   content, not a scrollbar.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-textarea
 * @tags        forms
 * @called-by   lgJobForm, lgTimesheetEditForm, lgExpenseEditForm, lgTripForm
 * @depends-on  --lg-radius-small, --lg-border, --lg-brand
 * @updated     2026-07-14
 */
.lg-textarea {
    width: 100%;
    min-height: 70px;
    padding: 10px 14px;
    border-radius: var(--lg-radius-small);
    border: 1.5px solid var(--lg-border);
    background: var(--lg-bg);
    color: var(--lg-text-1);
    font-size: 0.95rem;
    font-family: inherit;
    line-height: 1.5;
    resize: none;
    overflow: hidden;
}

.lg-textarea:focus {
    outline: none;
    border-color: var(--lg-brand);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bordered sub-card for wrapping one billing line's fields — visually separates
 *   lines when there's more than one. Not currently used — billing was pulled out of the job
 *   modal entirely (11 July 2026, "every modal does one thing"); kept for a future standalone
 *   Invoices modal to reuse.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-invoice-line
 * @tags        jobs, forms
 * @called-by   none yet — reserved for a future Invoices modal
 * @depends-on  --lg-radius-medium, --lg-border, --lg-surface-2
 * @updated     2026-07-11
 */
.lg-invoice-line {
    display: flex;
    flex-direction: column;
    gap: 10px;
    border: 1px solid var(--lg-border);
    background: var(--lg-surface-2);
    border-radius: var(--lg-radius-medium);
    padding: 14px;
    margin-bottom: 12px;
}

/* ── Trip card — same structure/values as lg-card-vehicle-*, lg-card-job-*, kept as its own set
   of classes per this project's existing convention (see lg-card-job's own note). Outer box
   (lg-card-trip) removed 13 July 2026 — Trip cards now use the shared lg-card-expense box
   instead; these -title/-meta classes are unaffected. ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Vehicle + date title line on the trip card.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-trip-title
 * @tags        trips, cards
 * @called-by   lgTripList
 * @depends-on  --lg-text-1
 * @updated     2026-07-11
 */
.lg-card-trip-title {
    font-size: 0.98rem;
    font-weight: 700;
    color: var(--lg-text-1);
    margin-bottom: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Job/route/km/business-personal meta line(s) on the trip card.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-trip-meta
 * @tags        trips, cards
 * @called-by   lgTripList
 * @depends-on  --lg-text-3
 * @updated     2026-07-11
 */
.lg-card-trip-meta {
    font-size: 0.82rem;
    color: var(--lg-text-3);
    margin-bottom: 4px;
}

/* ── In-progress trip card — distinct brand-tinted treatment so a live trip stands out from
   the ordinary completed-trip cards below it. ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description The live "trip in progress" card shown in the Trips panel's action area instead
 *   of Start/Add Trip buttons while a trip is running. Brand-tinted to stand out from ordinary
 *   lg-card-trip cards.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-trip-in-progress
 * @tags        trips
 * @called-by   lgTripList
 * @depends-on  --lg-radius-medium, --lg-brand, --lg-brand-light
 * @updated     2026-07-11
 */
.lg-trip-in-progress {
    background: var(--lg-brand-light);
    border: 1.5px solid var(--lg-brand);
    border-radius: var(--lg-radius-medium);
    padding: 16px;
    margin-bottom: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Title line inside lg-trip-in-progress.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-trip-in-progress-title
 * @tags        trips
 * @called-by   lgTripList
 * @depends-on  --lg-brand-dark
 * @updated     2026-07-11
 */
.lg-trip-in-progress-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--lg-brand-dark);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description "Started HH:MM" meta line inside lg-trip-in-progress.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-trip-in-progress-meta
 * @tags        trips
 * @called-by   lgTripList
 * @depends-on  --lg-text-2
 * @updated     2026-07-11
 */
.lg-trip-in-progress-meta {
    font-size: 0.85rem;
    color: var(--lg-text-2);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Wrapper for the Trips panel's action area (Start/Add Trip buttons, or the
 *   in-progress card) — stacks its content in a column with a real gap, since its buttons are
 *   plain sibling elements with no gap of their own otherwise.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-trip-action-area
 * @tags        trips
 * @called-by   index.html (#lg-trip-action-area)
 * @depends-on  none
 * @updated     2026-07-11
 */
.lg-trip-action-area {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Generic hidden-state utility — toggled via classList in JS to show/hide
 *   conditional elements (e.g. lgTripForm's "📍 Save as Place" buttons, hidden until their
 *   corresponding Start point/Destination field has a value).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-hidden
 * @tags        shared
 * @called-by   lgTripForm
 * @depends-on  none
 * @updated     2026-07-13
 */
.lg-hidden {
    display: none;
}

/* ── Route/Place card text styling — lg-card-route-title/-subtitle/-meta, still shared by
   Route/Place/Expense card content. Outer box (lg-card-route) removed 13 July 2026 — Routes and
   Places now use the shared lg-card-expense box instead. ── */

/**
 * @pm-registry
 * @prefix      lg
 * @description Highlights a card as checked during a bulk-select flow (13 July 2026, Places
 *   merge — the only bulk-select feature so far). Stacks with lg-card-route rather than
 *   replacing it, so every other card style stays unchanged.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-selected
 * @tags        shared, cards
 * @called-by   lgPlaceList
 * @depends-on  --lg-brand
 * @updated     2026-07-13
 */
.lg-selected {
    border-color: var(--lg-brand);
    border-width: 2px;
    background: var(--lg-brand-light, var(--lg-surface-2));
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Dimmed look for an archived Worker's card (schema v31, 17 July 2026,
 *   lgWorkerList) — visually distinct from active workers without needing a separate list/panel,
 *   since the "(Archived)" text suffix alone was easy to miss scanning quickly.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-worker-card-archived
 * @tags        workers, cards
 * @called-by   lgWorkerList
 * @depends-on  none
 * @updated     2026-07-17
 */
.lg-worker-card-archived {
    opacity: 0.55;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Route name line on the card.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-route-title
 * @tags        routes, cards
 * @called-by   lgRouteList
 * @depends-on  --lg-text-1
 * @updated     2026-07-11
 */
.lg-card-route-title {
    font-size: 0.98rem;
    font-weight: 700;
    color: var(--lg-text-1);
    margin-bottom: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Secondary, readable line on a card — currently a Place's address (13 July 2026).
 *   Sits between the title and the more-muted lg-card-route-meta line — address is what's easy
 *   to read, raw coordinates stay visible underneath but slightly greyed out.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-route-subtitle
 * @tags        routes, places, cards
 * @called-by   lgPlaceList
 * @depends-on  --lg-text-2
 * @updated     2026-07-13
 */
.lg-card-route-subtitle {
    font-size: 0.88rem;
    color: var(--lg-text-2);
    margin-bottom: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description From → To meta line on the card (Routes), or raw coordinates (Places) —
 *   deliberately the most muted line on the card.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-route-meta
 * @tags        routes, places, cards
 * @called-by   lgRouteList, lgPlaceList
 * @depends-on  --lg-text-3
 * @updated     2026-07-13
 */
.lg-card-route-meta {
    font-size: 0.82rem;
    color: var(--lg-text-3);
    margin-bottom: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bold, larger, full-contrast modifier on lg-card-route-meta, used for a dollar
 *   figure that should stand out (14 July 2026, Rocky, on the Invoice modal's line-item amounts
 *   and its Total readout; font-size/colour bumped the same day after Rocky found bold alone at
 *   the base 0.82rem/muted colour still "too hard to read" on the Invoices list card's own total)
 *   — a scoped modifier rather than changing lg-card-route-meta outright, since that shared class
 *   also renders non-money meta content (Route from/to, Place coordinates) that shouldn't change
 *   weight/size just because Invoices needed its amount to stand out.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-route-meta-bold
 * @tags        invoices, cards
 * @called-by   invoiceFormComponent.js, invoiceListComponent.js (.lg-card-route-meta-bold)
 * @depends-on  --lg-text-1
 * @updated     2026-07-14
 */
.lg-card-route-meta-bold {
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--lg-text-1);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Expense card's top line (13 July 2026) — Date + Paid to on the left, Amount
 *   right-aligned on the same line via flex space-between, rather than the amount sitting on its
 *   own line with wasted space beside it. Combined with lg-card-route-title for the same
 *   font-size/weight/color/margin, just adding the row layout.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-card-title-row
 * @tags        expenses, cards
 * @called-by   lgExpenseList, lgExpenseForm
 * @depends-on  none
 * @updated     2026-07-13
 */
.lg-expense-card-title-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 10px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Amount on the expense card's title row — same weight/color as the rest of the
 *   title (not muted, it's the number people scan for), never wraps.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-card-amount
 * @tags        expenses, cards
 * @called-by   lgExpenseList, lgExpenseForm
 * @depends-on  --lg-text-1
 * @updated     2026-07-13
 */
.lg-expense-card-amount {
    white-space: nowrap;
    color: var(--lg-text-1);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Modifier on lg-expense-card-amount for a positive (money in) amount — green, same
 *   `--lg-success` used app-wide for a good/positive signal, deliberately theme-stable (see
 *   PROJECT-DECISIONS.md's theme entries — success/danger never shift per theme). First use:
 *   Bank Reconciliation transaction cards (15 July 2026, Rocky: "different colour for money
 *   coming in... so user can easily tell"), reusable anywhere a signed amount needs the same
 *   at-a-glance in/out distinction.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-amount-positive
 * @tags        bank-reconciliation, cards
 * @called-by   lgBankStatementsList
 * @depends-on  --lg-success
 * @updated     2026-07-15
 */
.lg-card-amount-positive {
    color: var(--lg-success);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Shared card box (13 July 2026 — Rocky liked it enough on Expense cards to ask
 *   for the same treatment on every list in the app) — now the outer box for every card type:
 *   Expense, Route, Place, Trip, Job, and Vehicle. Named after its first user (Expense) but not
 *   Expense-specific — kept as-is per Rocky's explicit "reuse exactly the same CSS classes"
 *   rather than renamed generic, so a future reader should expect this on any card, not just
 *   literally expenses. Two deliberate differences from the old per-entity box classes it
 *   replaced (lg-card-route/lg-card-trip/lg-card-vehicle/lg-card-job, all removed): background
 *   is --lg-surface-2 (a visibly grey fill, not --lg-surface's near-white), and padding is much
 *   shorter top/bottom (8px vs the usual 14px all around) — enough to read as "each one is a
 *   separate entry" without wasting space on cards that are only 1-2 lines of content.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-expense
 * @tags        expenses, routes, places, trips, cards
 * @called-by   lgExpenseList, lgExpenseForm, lgRouteList, lgPlaceList, lgTripList, lgJobList,
 *              lgVehicleList
 * @depends-on  --lg-surface-2, --lg-radius-medium, --lg-border, --lg-shadow-small
 * @updated     2026-07-13
 */
.lg-card-expense {
    background: var(--lg-surface-2);
    border-radius: var(--lg-radius-medium);
    border: 1px solid var(--lg-border);
    padding: 8px 14px;
    margin-bottom: 10px;
    box-shadow: var(--lg-shadow-small);
    cursor: pointer;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Flex-row modifier on lg-card-expense for a Bank Account card (18 July 2026,
 *   multi-account support) — places the tappable body (lg-bank-account-card-body, flex:1) and the
 *   ✏️ rename icon side by side, same "primary tap area vs. small icon action" split as
 *   lg-etp-row/lg-etp-row-label elsewhere, just applied to this card shape instead of a picker row.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-account-card-row
 * @tags        bank-reconciliation, cards
 * @called-by   lgBankAccountsList
 * @depends-on  lg-card-expense
 * @updated     2026-07-18
 */
.lg-bank-account-card-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Tappable body area of a lg-bank-account-card-row — see that class's own docblock.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-account-card-body
 * @tags        bank-reconciliation, cards
 * @called-by   lgBankAccountsList
 * @depends-on  none
 * @updated     2026-07-18
 */
.lg-bank-account-card-body {
    flex: 1;
    min-width: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Small ✉️ icon row on an Invoice card (schema v19, 14 July 2026; Delete moved into
 *   lgInvoiceForm's edit-mode header same session as the icon lost its own 🗑️, matching every
 *   other record type in this app). Stops propagation so tapping it doesn't also trigger the
 *   card's own tap-to-open-edit-modal handler.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-invoice-card-actions
 * @tags        invoices, cards
 * @called-by   invoiceListComponent.js (.lg-invoice-card-actions)
 * @depends-on  none
 * @updated     2026-07-14
 */
.lg-invoice-card-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 4px;
    margin-top: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Tappable status text on an Invoice card (schema v20, 14 July 2026, Rocky: "there
 *   needs to be some visual indicator that the invoice has been sent"), sitting inside
 *   lg-invoice-card-actions alongside the ✉️ Email icon (moved onto that same row same session —
 *   Rocky found its own separate line underneath wasted too much vertical space). Tap cycles Not
 *   Sent → Sent → Paid → Not Sent (see lgInvoiceList._handleStatusTap). Colour comes from the
 *   three lg-invoice-status-* modifier classes (not-sent/sent/paid) applied alongside this base
 *   class.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-invoice-status
 * @tags        invoices, cards
 * @called-by   invoiceListComponent.js (.lg-invoice-status)
 * @depends-on  none
 * @updated     2026-07-14
 */
.lg-invoice-status {
    font-size: 0.78rem;
    font-weight: 700;
    cursor: pointer;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description 🧾/💰 icon before the status text on an Invoice card (schema v26, 15 July 2026) —
 *   🧾 for not_sent/sent (still awaiting payment), 💰 once paid, same money-bag-means-paid symbol
 *   used on the Jobs list and (via the "linked" badge) on Bank Transactions/Expense/Income cards.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-invoice-status-icon
 * @tags        invoices, cards
 * @called-by   invoiceListComponent.js (.lg-invoice-status-icon)
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-invoice-status-icon {
    margin-right: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description "Not sent" colour for lg-invoice-status — muted, matches the app's standard
 *   secondary-text tone.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-invoice-status-not_sent
 * @tags        invoices, cards
 * @called-by   invoiceListComponent.js (.lg-invoice-status-not_sent)
 * @depends-on  --lg-text-3
 * @updated     2026-07-14
 */
.lg-invoice-status-not_sent {
    color: var(--lg-text-3);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description "Sent" colour for lg-invoice-status — the app's brand blue.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-invoice-status-sent
 * @tags        invoices, cards
 * @called-by   invoiceListComponent.js (.lg-invoice-status-sent)
 * @depends-on  --lg-brand
 * @updated     2026-07-14
 */
.lg-invoice-status-sent {
    color: var(--lg-brand);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description "Paid" colour for lg-invoice-status — green, same success token used elsewhere in
 *   the app.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-invoice-status-paid
 * @tags        invoices, cards
 * @called-by   invoiceListComponent.js (.lg-invoice-status-paid)
 * @depends-on  --lg-success
 * @updated     2026-07-14
 */
.lg-invoice-status-paid {
    color: var(--lg-success);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Groups Date and Paid to on the expense card's title row with a deliberate gap
 *   between them (13 July 2026 — a plain single space "looked bad"/too tight on-device; a flex
 *   gap reads as a clear, intentional separation instead). Only wraps both spans when Paid to is
 *   set — a date-only title has nothing to gap from.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-card-title-left
 * @tags        expenses, cards
 * @called-by   lgExpenseList, lgExpenseForm
 * @depends-on  none
 * @updated     2026-07-13
 */
.lg-expense-card-title-left {
    display: flex;
    gap: 14px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Help modal content styling (lgHelpModal, 14 July 2026) — one section per topic
 *   area, a title, an optional plain-paragraph body, keyword/icon rows, and an example block (a
 *   small shaded group of short example strings). A keyword/icon row stacks its bold label above
 *   its description (Rocky, same session — a side-by-side layout with a fixed-width label pushed
 *   the description text around and looked bad once a label ran long, e.g. "🗑️ (in the edit
 *   screen)"). Same visual structure Project Memory's own help modals use, built fresh in
 *   Logit's own design tokens rather than copied CSS (PM's help styling wasn't in a shared
 *   stylesheet to copy from — see lgHelpModal's own docblock for why the two apps' help systems
 *   otherwise diverge, template-file-loading vs. inline content dictionary).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-help-section
 * @tags        help
 * @called-by   lgHelpModal
 * @depends-on  --lg-border, --lg-text-1, --lg-text-2, --lg-brand, --lg-surface-2, --lg-radius-medium
 * @updated     2026-07-14
 */
.lg-help-section {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--lg-border);
}

.lg-help-section:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bold title line of one lg-help-section. See lg-help-section's own docblock for
 *   the full help-content layout this belongs to.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-help-section-title
 * @tags        help
 * @called-by   lgHelpModal
 * @depends-on  --lg-text-1
 * @updated     2026-07-14
 */
.lg-help-section-title {
    font-weight: 700;
    font-size: 1.05rem;
    color: var(--lg-text-1);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Plain-paragraph body text of one lg-help-section, below its title. See
 *   lg-help-section's own docblock for the full help-content layout this belongs to.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-help-section-body
 * @tags        help
 * @called-by   lgHelpModal
 * @depends-on  --lg-text-2
 * @updated     2026-07-14
 */
.lg-help-section-body {
    color: var(--lg-text-2);
    font-size: 0.9rem;
    line-height: 1.4;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description One keyword-row inside a help section — bold label stacked above its description
 *   (14 July 2026: switched from side-by-side after a long label, e.g. "🗑️ (in the edit screen)",
 *   pushed the description text around). See lg-help-section's own docblock for the full layout
 *   this belongs to. Identical rule to lg-help-icon-row, kept as its own selector/docblock pair
 *   purely so both class names are individually registry-searchable.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-help-row
 * @tags        help
 * @called-by   lgHelpModal
 * @depends-on  none
 * @updated     2026-07-14
 */
.lg-help-row {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 0.9rem;
    line-height: 1.4;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description One icon-row inside a help section (an emoji-icon key rather than a text
 *   keyword) — same layout as lg-help-row, see its docblock for the full context.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-help-icon-row
 * @tags        help
 * @called-by   lgHelpModal
 * @depends-on  none
 * @updated     2026-07-14
 */
.lg-help-icon-row {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 0.9rem;
    line-height: 1.4;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bold, brand-coloured keyword label inside a lg-help-row. See lg-help-section's own
 *   docblock for the full layout this belongs to. Identical rule to lg-help-icon, kept as its own
 *   selector/docblock pair purely so both class names are individually registry-searchable.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-help-keyword
 * @tags        help
 * @called-by   lgHelpModal
 * @depends-on  --lg-brand
 * @updated     2026-07-14
 */
.lg-help-keyword {
    font-weight: 700;
    color: var(--lg-brand);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bold, brand-coloured emoji-icon label inside a lg-help-icon-row — same styling as
 *   lg-help-keyword, see its docblock for the full context.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-help-icon
 * @tags        help
 * @called-by   lgHelpModal
 * @depends-on  --lg-brand
 * @updated     2026-07-14
 */
.lg-help-icon {
    font-weight: 700;
    color: var(--lg-brand);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Shaded container grouping one or more lg-help-example lines. See
 *   lg-help-section's own docblock for the full help-content layout this belongs to.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-help-example-block
 * @tags        help
 * @called-by   lgHelpModal
 * @depends-on  --lg-surface-2, --lg-radius-medium
 * @updated     2026-07-14
 */
.lg-help-example-block {
    background: var(--lg-surface-2);
    border-radius: var(--lg-radius-medium);
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description One italic example line inside a lg-help-example-block. See lg-help-section's own
 *   docblock for the full help-content layout this belongs to.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-help-example
 * @tags        help
 * @called-by   lgHelpModal
 * @depends-on  --lg-text-2
 * @updated     2026-07-14
 */
.lg-help-example {
    font-size: 0.85rem;
    color: var(--lg-text-2);
    font-style: italic;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Horizontally-scrollable wrapper around the import wizard's raw-CSV preview table
 *   (Bank Reconciliation, 15 July 2026) — a real bank export can have more columns than fit a
 *   phone screen, so this scrolls its own content rather than letting the table force the whole
 *   modal wider.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-biw-preview-table
 * @tags        bank-reconciliation
 * @called-by   bankImportWizardComponent
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-biw-preview-table {
    overflow-x: auto;
    border: 1px solid var(--lg-border);
    border-radius: var(--lg-radius-medium);
    margin-bottom: 12px;
}

.lg-biw-preview-table table {
    border-collapse: collapse;
    width: 100%;
    font-size: 0.8rem;
    white-space: nowrap;
}

.lg-biw-preview-table th,
.lg-biw-preview-table td {
    padding: 6px 10px;
    text-align: left;
    border-bottom: 1px solid var(--lg-border);
}

.lg-biw-preview-table th {
    background: var(--lg-surface-2);
    font-weight: 600;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Small explanatory/status line inside the import wizard (Bank Reconciliation, 15
 *   July 2026) — used both for the live "this is how your data will be read" mapping preview and
 *   for a plain informational note (e.g. "this bank's export looks different from last time").
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-biw-note
 * @tags        bank-reconciliation
 * @called-by   bankImportWizardComponent
 * @depends-on  --lg-text-2
 * @updated     2026-07-15
 */
.lg-biw-note {
    font-size: 0.85rem;
    color: var(--lg-text-2);
    background: var(--lg-surface-2);
    border-radius: var(--lg-radius-medium);
    padding: 8px 10px;
    margin-bottom: 12px;
}

.lg-biw-note.lg-biw-note-error {
    color: var(--lg-danger);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bank Statement card title's smaller (still bold) text — kept unconditional
 *   regardless of Card style (see lg-card-style-square below), since this and
 *   lg-expense-card-compact's identical rule are wrap-prevention bug fixes, not a look/feel
 *   choice. Was paired with an unconditional `border-radius: 0` here too (15 July 2026,
 *   originally an experiment scoped to Bank cards only); that part moved into the toggleable
 *   lg-card-style-square rule below once Rocky asked for the square/edge-to-edge look to become
 *   an app-wide try-first setting rather than a permanent Bank-only special case.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-card
 * @tags        bank-reconciliation, cards
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-card .lg-card-route-title {
    font-size: 0.85rem;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Generalized edge-to-edge utility (15 July 2026, renamed from Bank-only
 *   lg-bank-list-edge) — a no-op by default; only when the experimental Square card style is on
 *   (`:root[data-card-style="square"]`, see lg-card-style-square below) does it cancel
 *   lg-panel-content's shared 16px side padding for a list container (negative margin) so the card
 *   boxes inside it reach the true screen edges. Applied to every list container across the app
 *   (Vehicles/Jobs/Trips/Routes/Places/Contacts/Expenses/Invoices/Bank Transactions/Bank Accounts).
 *   See lg-list-edge-modal for the equivalent used inside modal bodies, which have a different
 *   (20px) side padding to cancel.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-list-edge
 * @tags        cards
 * @called-by   index.html (every panel's list container)
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-list-edge {
}

:root[data-card-style="square"] .lg-list-edge {
    margin-left: -16px;
    margin-right: -16px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Modal-body version of lg-list-edge (15 July 2026 follow-up) — cancels
 *   lg-modal-body's 20px side padding instead of lg-panel-content's 16px, so a list nested inside
 *   a modal reaches the modal's own true edges the same way a full panel's list does. Deliberately
 *   a plain, non-feature-specific utility (not e.g. "lg-expense-list-edge-modal") so any modal-
 *   scoped list can reuse it as-is — first the "Expenses for this trip/job/vehicle" sheet
 *   (lgExpenseForm's #lg-ef-list), same day extended to the Timesheet sheet (lgTimesheetForm's
 *   #lg-tsf-list, Rocky: "need to do same with the timesheet modal in jobs... is there one
 *   overriding css for this? they need to be combined" — yes, this one, no new CSS needed) and the
 *   individual Invoice modal (lgInvoiceForm's #lg-invf-lines-area, same follow-up message).
 *   Originally left out of scope entirely (a modal's floating box has no "screen edge"), but asked
 *   for once Square style was the confirmed default. Same no-op-by-default, toggle-gated
 *   mechanism as lg-list-edge.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-list-edge-modal
 * @tags        cards
 * @called-by   lgExpenseForm (#lg-ef-list), lgTimesheetForm (#lg-tsf-list), lgInvoiceForm
 *              (#lg-invf-lines-area)
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-list-edge-modal {
}

:root[data-card-style="square"] .lg-list-edge-modal {
    margin-left: -20px;
    margin-right: -20px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Experimental alternate Card style (15 July 2026) — square corners for every card in
 *   the app instead of the historical rounded ones. Targets lg-card-expense directly (the one
 *   shared box every card type already uses — Vehicles/Jobs/Trips/Routes/Places/Contacts/
 *   Invoices/Bank Transactions/Bank Accounts/Expenses/Timesheet entries), so one rule covers all
 *   of them, gated behind `:root[data-card-style="square"]` (set/cleared by
 *   lgUtils.lgApplyCardStyle, toggled from the new Settings "Card style" picker) so nothing
 *   changes for anyone until they opt in. Rocky: "the look and feel of this app is a bit
 *   different... more about money, about finance... just keep the rounded corner for making the
 *   ico buttons" — lg-home-button (Home/More tile buttons) is a separate class entirely and is
 *   untouched by this selector either way. Paired with lg-list-edge for the edge-to-edge half of
 *   the same look; asked for as a try-first toggle rather than a direct rewrite: "we could also
 *   make this an alternate css theme and try it out first. If it looks and works OK we could then
 *   make it the default."
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-card-style-square
 * @tags        cards
 * @called-by   lgUtils.lgApplyCardStyle (sets data-card-style="square" on <html>)
 * @depends-on  lg-card-expense
 * @updated     2026-07-15
 */
:root[data-card-style="square"] .lg-card-expense {
    border-radius: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description EXPERIMENTAL, Bank Statement cards only (15 July 2026) — lets the title row's left
 *   group (date + merchant) actually shrink below its own content's natural width, within the
 *   outer title row's own flex layout. `min-width: 0` is what makes `lg-bank-card-merchant`'s own
 *   `text-overflow: ellipsis` do anything at all — without it, a flex child never shrinks past its
 *   content's natural width no matter what overflow rules it has.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-card .lg-expense-card-title-left
 * @tags        bank-reconciliation, cards
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-card .lg-expense-card-title-left {
    min-width: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description The compact date on a Bank Statement card's title row (Rocky's real example: "14
 *   Jul 2026 Amazon Prime Membership -79" was wrapping to two lines) — never shrinks or wraps,
 *   since it's already short and fixed-width; the merchant name next to it does the shrinking.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-card-date
 * @tags        bank-reconciliation, cards
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-card-date {
    flex-shrink: 0;
    white-space: nowrap;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Single-line ellipsis truncation for a Bank Statement card's merchant name, instead
 *   of wrapping onto a second line on a narrow phone screen. `flex: 1 1 auto` + `min-width: 0`
 *   (paired with `lg-bank-card .lg-expense-card-title-left`'s own `min-width: 0`) is what actually
 *   lets this shrink below its own text's natural width — without both, `text-overflow: ellipsis`
 *   silently does nothing inside a flex row. Full text stays in the DOM (`title` attribute) for a
 *   long-press/hover hint.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-card-merchant
 * @tags        bank-reconciliation, cards
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-card-merchant {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.lg-bank-card .lg-card-route-subtitle {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.lg-bank-card .lg-card-job-meta {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Bar above the triage list holding the bulk action button — "Mark all N as Personal"
 *   (Business tab) or "Categorize all N as…" (Personal tab, schema v33, 17 July 2026) — only ever
 *   rendered while a search is active (lgBankStatementsList._renderCards), scoped to exactly the
 *   currently search-matched rows. Rocky's own real example (recurring Amazon Prime charges): a
 *   deliberately narrow reversal of the brief's original "no bulk actions" call, not a general
 *   multi-select system. `> * + *` spacing (17 July 2026 follow-up) keeps the stacked action
 *   button/hint text/edit-selection or Cancel link evenly gapped without a fixed child count.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-bulk-bar
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-17
 */
.lg-bank-bulk-bar {
    margin-bottom: 10px;
    padding: 0 16px;
}

.lg-bank-bulk-bar > * + * {
    margin-top: 8px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Dimmed look for a bank transaction card excluded from the current bulk action
 *   (schema v33, 17 July 2026 follow-up, lgBankStatementsList's bulk-edit mode) — same opacity
 *   treatment as lg-worker-card-archived, plus a danger-tinted border so "excluded" reads distinctly
 *   from just "less important."
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-card-excluded
 * @tags        bank-reconciliation, cards
 * @called-by   lgBankStatementsList
 * @depends-on  --lg-danger
 * @updated     2026-07-17
 */
.lg-bank-card-excluded {
    opacity: 0.5;
    border-color: var(--lg-danger);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Small ❌ badge on an excluded card's title row, trailing the merchant name — never
 *   shrinks (same fixed-size treatment as the status badge/date at the start of the row).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-card-excluded-badge
 * @tags        bank-reconciliation, cards
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-17
 */
.lg-bank-card-excluded-badge {
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Small note shown above the list when viewing the "personal" keyword-search view
 *   (lgBankStatementsList._renderCards, viewMode 'personal') — a cheap stand-in for the feature
 *   doc's original "Review Personal Items" screen, so it's clear the list is showing something
 *   other than the normal unassigned/search results.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-view-note
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  --lg-text-2
 * @updated     2026-07-15
 */
.lg-bank-view-note {
    font-size: 0.85rem;
    color: var(--lg-text-2);
    padding: 0 16px 8px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Attractive callout box above a search-filtered triage list (15 July 2026, Rocky's
 *   own request; removed then brought back dismissible, 17 July 2026 follow-up — "taking up way too
 *   much screen space," then "close when user touches it") — a brand-tinted background + icon, not
 *   a plain text line, explaining that tapping each card is the primary way to decide Personal/
 *   Business, and the bulk "Mark all as Personal" button is only a shortcut for when every result
 *   matches. Same visual family as this app's Help modal callouts (lg-help-example-block), just
 *   brand-colored instead of neutral grey to read as an active tip rather than passive reference
 *   text. The whole box is the dismiss tap target (see lg-bank-tip-box-close), not just the small
 *   ✕ — a bigger, more forgiving hit area on a phone.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-tip-box
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  --lg-brand-light, --lg-radius-medium
 * @updated     2026-07-17
 */
.lg-bank-tip-box {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: var(--lg-brand-light);
    border-radius: var(--lg-radius-medium);
    padding: 10px 14px;
    margin: 0 16px 10px;
    font-size: 0.85rem;
    color: var(--lg-text-1);
    line-height: 1.4;
    cursor: pointer;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description The 💡 icon inside lg-bank-tip-box — fixed size, never shrinks/wraps.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-tip-box-icon
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-17
 */
.lg-bank-tip-box-icon {
    font-size: 1.1rem;
    line-height: 1.3;
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Small ✕ at the end of lg-bank-tip-box (17 July 2026) — a visual affordance signaling
 *   the box is dismissible; the click handler is on the whole box, this is just a plain span, not a
 *   second separate tap target.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-tip-box-close
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  --lg-text-2
 * @updated     2026-07-17
 */
.lg-bank-tip-box-close {
    font-size: 0.9rem;
    color: var(--lg-text-2);
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Three-way filter tabs above the Transactions search box (Business/Personal/
 *   All, 15 July 2026) — replaces the earlier "type the word personal into search" hack, which
 *   Rocky found confusing (typing anything past the exact word broke back out to the normal
 *   unassigned search unexpectedly, feeling like "can't type anything else"). A real toggle keeps
 *   scope (which status) and the search box (free text within that scope) fully independent.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-filter-tabs
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-filter-tabs {
    display: flex;
    gap: 8px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description One Business/Personal/All filter tab button, inside lg-bank-filter-tabs.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-filter-tab
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  --lg-surface-2, --lg-radius-medium
 * @updated     2026-07-15
 */
.lg-bank-filter-tab {
    flex: 1;
    padding: 8px 0;
    text-align: center;
    border-radius: var(--lg-radius-medium);
    background: var(--lg-surface-2);
    color: var(--lg-text-2);
    font-weight: 600;
    font-size: 0.9rem;
    border: none;
    cursor: pointer;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Modifier on lg-bank-filter-tab for whichever tab matches the current
 *   `_statusFilter` — brand-colored fill, matching the app's own accent.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-filter-tab-active
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  --lg-brand
 * @updated     2026-07-15
 */
.lg-bank-filter-tab-active {
    background: var(--lg-brand);
    color: #fff;
}

/**
 * @pm-registry
 * @description Business/Personal/All filter tabs on the Expenses panel (schema v46, 28 July 2026)
 *   — same visual pattern as lg-bank-filter-tabs, kept as its own class rather than reused directly
 *   so Bank Transactions' own styling can't be affected by an Expenses-only change.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-filter-tabs
 * @tags        expenses
 * @called-by   lgExpenseList
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-expense-filter-tabs {
    display: flex;
    gap: 8px;
}

/**
 * @pm-registry
 * @description One Business/Personal/All filter tab button, inside lg-expense-filter-tabs.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-filter-tab
 * @tags        expenses
 * @called-by   lgExpenseList
 * @depends-on  --lg-surface-2, --lg-radius-medium
 * @updated     2026-07-28
 */
.lg-expense-filter-tab {
    flex: 1;
    padding: 8px 0;
    text-align: center;
    border-radius: var(--lg-radius-medium);
    background: var(--lg-surface-2);
    color: var(--lg-text-2);
    font-weight: 600;
    font-size: 0.9rem;
    border: none;
    cursor: pointer;
}

/**
 * @pm-registry
 * @description Modifier on lg-expense-filter-tab for whichever tab matches the current
 *   `_statusFilter` — brand-colored fill, matching the app's own accent.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-filter-tab-active
 * @tags        expenses
 * @called-by   lgExpenseList
 * @depends-on  --lg-brand
 * @updated     2026-07-28
 */
.lg-expense-filter-tab-active {
    background: var(--lg-brand);
    color: #fff;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Wraps the Transactions search input so a clear (✕) button can sit inside it on the
 *   right — Rocky: "search box needs an X on RHS so user can clear text box with one click instead
 *   of having to delete each letter." Button only shown while the input has text (toggled in
 *   lgBankStatementsList's search wiring).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-search-wrapper
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-search-wrapper {
    position: relative;
    flex: 1;
    min-width: 0;
}

.lg-bank-search-wrapper .lg-input {
    padding-right: 36px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description The ✕ clear button sitting inside lg-bank-search-wrapper — hidden by default
 *   (`lg-bank-search-clear-btn-visible` toggles it on), positioned absolutely over the input's own
 *   right-side padding reserved for it.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-search-clear-btn
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  --lg-text-2
 * @updated     2026-07-15
 */
.lg-bank-search-clear-btn {
    display: none;
    position: absolute;
    right: 6px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--lg-text-2);
    font-size: 1rem;
    line-height: 1;
    padding: 6px;
    cursor: pointer;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Modifier on lg-bank-search-clear-btn — shown only while the search box has text,
 *   toggled by lgBankStatementsList's search wiring/_setSearchValue.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-search-clear-btn-visible
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-search-clear-btn-visible {
    display: block;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Row holding the search box and the "📅 Date range" icon button side by side (15
 *   July 2026 follow-up — Rocky: the button "needs to go on RHS of Search transactions not
 *   underneath it").
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-search-row
 * @tags        bank-reconciliation
 * @called-by   index.html (.lg-bank-search-row)
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-search-row {
    display: flex;
    align-items: stretch;
    gap: 8px;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description "📅 Date range" button — a real bordered button, not the underlined text-link style
 *   (Rocky, explicit: "dont use text underscored anywhere in app i hate it. make a proper little
 *   button"), icon-only and about 50% larger than normal body text ("even if it just showed the
 *   calendar icon about 50% bigger that would be ok"), matching the search input's own height so
 *   it sits neatly beside it.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-date-range-icon-btn
 * @tags        bank-reconciliation
 * @called-by   index.html (.lg-bank-date-range-icon-btn)
 * @depends-on  --lg-radius-medium, --lg-brand, --lg-surface-2
 * @updated     2026-07-15
 */
.lg-bank-date-range-icon-btn {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 46px;
    border-radius: var(--lg-radius-medium);
    border: 1.5px solid var(--lg-brand);
    background: var(--lg-surface-2);
    font-size: 1.35rem;
    cursor: pointer;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Active date-range summary ("Showing 1 Jul 2025 – 30 Jun 2026") + its ✕ clear button
 *   — hidden by default (`display: none` right here, not the shared `lg-hidden` utility). Bug fix,
 *   15 July 2026 — Rocky: "there is a big X under the search bar. whats this for? it doesnt do
 *   anything." Root cause: this rule used to rely on a separate `lg-hidden` class toggled in JS,
 *   but `lg-hidden { display: none; }` and this class both have equal (single-class) specificity,
 *   and this rule's own unconditional `display: flex` — appearing later in the stylesheet — always
 *   won, so the indicator showed permanently regardless of the `lg-hidden` class being present.
 *   Fixed by making `display: none` the base state here directly, with a dedicated
 *   `lg-bank-date-range-indicator-visible` modifier (same proven pattern as
 *   `lg-bank-search-clear-btn`/`-visible`) turning it on instead.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-date-range-indicator
 * @tags        bank-reconciliation
 * @called-by   index.html (.lg-bank-date-range-indicator)
 * @depends-on  --lg-text-2
 * @updated     2026-07-15
 */
.lg-bank-date-range-indicator {
    display: none;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    color: var(--lg-text-2);
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Shows lg-bank-date-range-indicator — toggled on/off directly by
 *   lgBankStatementsList._updateAdvancedSearchIndicator, not the shared lg-hidden utility (see that
 *   class's own docblock for why).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-date-range-indicator-visible
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-17
 */
.lg-bank-date-range-indicator-visible {
    display: flex;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Small pink "P" badge to the left of a Transaction card's date, for a Personal-status
 *   row — shown on the Business and All tabs (not Personal, redundant there — every row is already
 *   Personal). Used to also have a blue "B" modifier for any non-Personal row, collapsing "still
 *   unassigned" and "genuinely business-assigned" into one look; retired 15 July 2026 once that
 *   turned out to be a real point of confusion (see lgBankStatementsList._renderCard's own
 *   docblock) — non-Personal rows now use the same ⏳/🏦/💰 markers everywhere instead. Deliberately
 *   a fixed color, not theme-tinted — same reasoning as --lg-success/--lg-danger staying put across
 *   every theme, since a status color needs to stay recognizable regardless of the active theme.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-status-badge
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 0.68rem;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Pink modifier on lg-bank-status-badge for a Personal-status row.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-status-badge-personal
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-status-badge-personal {
    background: #ec4899;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Small "B"/"P" badge to the left of a Trip card's date (28 July 2026) — same visual
 *   shape as lg-bank-status-badge, but always shown on both card types (unlike Bank Transactions'
 *   Personal-only badge, which relies on neighboring Business/Personal/All filter tabs for
 *   context Trip cards don't have). Symmetric on purpose: an icon shown on only one card type
 *   would leave the other card's title starting at a different horizontal position — always
 *   reserving the same badge slot on every card keeps titles aligned regardless of type. Own
 *   class rather than reusing lg-bank-status-badge directly, so a future Bank Transactions change
 *   can't accidentally affect Trip cards or vice versa.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-trip-status-badge
 * @tags        trips
 * @called-by   lgTripList
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-trip-status-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    font-size: 0.68rem;
    font-weight: 700;
    color: #fff;
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Pink modifier on lg-trip-status-badge for a Personal trip — same fixed pink as
 *   lg-bank-status-badge-personal, deliberately not theme-tinted, so "Personal" reads as the same
 *   color everywhere in the app regardless of which theme is active.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-trip-status-badge-personal
 * @tags        trips
 * @called-by   lgTripList
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-trip-status-badge-personal {
    background: #ec4899;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Blue modifier on lg-trip-status-badge for a Business trip — its own fixed color
 *   (not theme-tinted, same reasoning as the Personal badge), distinct from any icon/color already
 *   used elsewhere in the app (deliberately not bank/money-bag related, since 🏦/💰 already mean
 *   something different — "matched with a bank statement"/"linked to Income" — on Expense cards).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-trip-status-badge-business
 * @tags        trips
 * @called-by   lgTripList
 * @depends-on  none
 * @updated     2026-07-28
 */
.lg-trip-status-badge-business {
    background: #3b82f6;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Plain ⏳ "still awaiting assignment" marker on a Business or All tab card (Task 6,
 *   15 July 2026; unified across both tabs same day — see lgBankStatementsList._renderCard's own
 *   docblock). Its paired "already assigned" state used to be a plain ✅ here too, but split into
 *   `lg-expense-bank-badge`'s 🏦 (Expense-linked) or `lg-income-bank-badge`'s 💰 (Income-linked,
 *   schema v26 follow-up) so the same icon means "linked to its counterpart" on each side — see
 *   those classes' own docblocks. No colored circle like lg-bank-status-badge — the emoji already
 *   carries its own color, a background would just clash.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bank-status-emoji
 * @tags        bank-reconciliation
 * @called-by   lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-bank-status-emoji {
    font-size: 0.9rem;
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Expense cards only (15 July 2026) — the same smaller-title-text fix already proven
 *   on Bank Statement cards across two real phones, applied here after Rocky noticed the identical
 *   Date/Paid-to wrapping problem on Expense cards (same underlying shared classes, same root
 *   cause). `min-width: 0` is what lets the title-left flex child actually shrink so
 *   `lg-expense-card-paid-to`'s ellipsis truncation can take effect — without it, a flex child
 *   never shrinks past its content's natural width. Reused as-is by lgIncomeList (15 July 2026,
 *   Phase 1) — Income cards share the exact same title-row shape (Date + a left-side text field +
 *   right-aligned Amount).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-card-compact
 * @tags        expenses, cards, income
 * @called-by   lgExpenseList, lgExpenseForm, lgIncomeList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-expense-card-compact .lg-card-route-title {
    font-size: 0.85rem;
}

.lg-expense-card-compact .lg-expense-card-title-left {
    min-width: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description The compact date on an Expense card's title row — never shrinks or wraps, since
 *   Paid to (next to it) does the shrinking instead. See lg-expense-card-compact.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-card-date
 * @tags        expenses, cards, income
 * @called-by   lgExpenseList, lgExpenseForm, lgIncomeList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-expense-card-date {
    flex-shrink: 0;
    white-space: nowrap;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description 🏦 badge marking "linked to its counterpart" (15 July 2026) — same slot and same
 *   plain-emoji-no-background style as lg-bank-status-emoji (left of the date, inside
 *   lg-expense-card-title-left), the simple first tier of Rocky's "matched with a bank statement"
 *   idea: "we could use a little symbol like a bank symbol... to indicate that it's been matched."
 *   Deliberately reused as-is (not a separate icon) on the Bank Transaction card's own "already
 *   assigned" state too (15 July 2026 follow-up, replacing a plain ✅ there) — Rocky, when asked
 *   whether the bank icon felt redundant on an already-bank-typed card: "it doesn't matter that
 *   it is redundant in the transactions. Its just to let the users know that their bank details
 *   have propagated throughout jobs and expenses" — so the exact same symbol appears on both sides
 *   of the same underlying link (an Expense card and its counterpart Bank Transaction card).
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-bank-badge
 * @tags        expenses, cards, bank-reconciliation
 * @called-by   lgExpenseList, lgExpenseForm, lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-expense-bank-badge {
    font-size: 0.9rem;
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description ✍️ badge marking a manually-entered expense (18 July 2026) — the exact inverse of
 *   lg-expense-bank-badge's 🏦, same slot/style, shown when an expense has no matching
 *   bank_transactions row at all (`!isMatched`). Rocky's own request, same session the two-digit-
 *   year bank-import date corruption was found and fixed — wanted an at-a-glance way to tell "I
 *   typed this myself" apart from "came from resolving a bank transaction" on the card itself, not
 *   just inferred from the absence of the other badge.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-manual-badge
 * @tags        expenses, cards
 * @called-by   lgExpenseList
 * @depends-on  none
 * @updated     2026-07-19
 */
.lg-expense-manual-badge {
    font-size: 0.9rem;
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description 💰 badge marking "linked to its counterpart" — income side (schema v26, 15 July
 *   2026, exact analog of lg-expense-bank-badge). Split out as its own icon once Income existed,
 *   distinct from 🏦 (Expense-linked) — Rocky: "when income is marked paid it should have the
 *   money bag symbol appear not the bank symbol." Same slot/style, appears on both the Income
 *   card's own "matched with a bank transaction" badge and the Bank Transaction card's "already
 *   assigned" state when linked via `income_id` rather than `expense_id`.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-income-bank-badge
 * @tags        income, cards, bank-reconciliation
 * @called-by   lgIncomeList, lgBankStatementsList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-income-bank-badge {
    font-size: 0.9rem;
    flex-shrink: 0;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Single-line ellipsis truncation for an Expense card's Paid to field, instead of
 *   wrapping onto a second line on a narrow phone screen. Full text stays in the DOM (`title`
 *   attribute) for a long-press/hover hint. See lg-expense-card-compact. Reused as-is by
 *   lgIncomeList (15 July 2026, Phase 1) for its "Received from" field — same truncation need,
 *   opposite direction of money.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-expense-card-paid-to
 * @tags        expenses, cards, income
 * @called-by   lgExpenseList, lgExpenseForm, lgIncomeList
 * @depends-on  none
 * @updated     2026-07-15
 */
.lg-expense-card-paid-to {
    flex: 1 1 auto;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/**
 * @pm-registry
 * @prefix      lg
 * @description Decorative row of emoji above the Add/View Asset and Add/View Liability button
 *   pairs on the Balance Sheet hub (19 July 2026) — purely visual, not tappable, just "give people
 *   an idea" of what belongs in that section (Rocky's own framing) — house/car/bank/cash/Bitcoin
 *   above Assets, house/car loan/bank loan/credit card/student debt above Liabilities. House and
 *   car deliberately appear in *both* rows (19 July 2026 follow-up, Rocky: "they are only an asset
 *   if they are paid off, until then user has to keep paying") — a mortgaged home or financed car
 *   is genuinely both at once, not one or the other. Larger than body text and centered so it reads
 *   as a header illustration, not real content.
 * @apps        memri-logit
 * @type        css-class
 * @name        lg-bs-icon-row
 * @tags        balance-sheet
 * @called-by   index.html (.lg-bs-icon-row)
 * @depends-on  none
 * @updated     2026-07-19
 */
.lg-bs-icon-row {
    text-align: center;
    font-size: 1.8rem;
    letter-spacing: 6px;
    margin-bottom: 6px;
}


/* --- Web workspace (browser only, 19 Nov 2026): login screen, save status pill --------------- */
.lg-web-login {
    position: fixed;
    inset: 0;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: var(--lg-bg);
    overflow-y: auto;
}
.lg-web-login-card {
    width: 100%;
    max-width: 420px;
    padding: 28px 24px;
    text-align: center;
    background: var(--lg-surface);
    border: 1px solid var(--lg-border);
    border-radius: var(--lg-radius-large);
    box-shadow: var(--lg-shadow-large);
}
.lg-web-login-img {
    width: 100%;
    max-width: 260px;
    border-radius: var(--lg-radius-medium);
}
.lg-web-login-title {
    margin: 16px 0 4px;
    color: var(--lg-text-1);
}
.lg-web-login-tagline,
.lg-web-login-note {
    margin: 0 0 16px;
    color: var(--lg-text-2);
}
.lg-web-login-message {
    margin: 0 0 16px;
    color: var(--lg-text-1);
    line-height: 1.45;
}
.lg-web-login .lg-input {
    width: 100%;
    margin-bottom: 12px;
    box-sizing: border-box;
}
.lg-web-login-btn {
    width: 100%;
    min-height: 56px;
    margin-bottom: 16px;
    border: none;
    border-radius: var(--lg-radius-full);
    background: var(--lg-brand);
    color: #fff;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
}
.lg-web-login-btn:hover { background: var(--lg-brand-dark); }
.lg-web-save-pill {
    position: fixed;
    right: 16px;
    bottom: 16px;
    z-index: 99999;
    padding: 8px 14px;
    border-radius: var(--lg-radius-full);
    background: var(--lg-surface);
    border: 1px solid var(--lg-border);
    box-shadow: var(--lg-shadow-small);
    color: var(--lg-text-2);
    font-size: 0.9rem;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s;
}
.lg-web-save-pill-visible { opacity: 1; }
.lg-web-save-pill[data-state="error"],
.lg-web-save-pill[data-state="conflict"] {
    color: #fff;
    background: var(--lg-danger);
    border-color: var(--lg-danger);
}
.lg-web-login-btn-secondary {
    background: transparent;
    color: var(--lg-brand);
    border: 2px solid var(--lg-brand);
}
.lg-web-login-btn-secondary:hover {
    background: var(--lg-brand-light);
}
.lg-web-login-divider {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 8px 0 16px;
    color: var(--lg-text-2);
    font-weight: 600;
}
.lg-web-login-divider::before,
.lg-web-login-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--lg-border);
}

/* Web top bar — account badge top-right (browser only, 19 Nov 2026) */
.lg-web-bar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 52px;
    z-index: 5000;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    box-sizing: border-box;
    background: var(--lg-surface);
    border-bottom: 1px solid var(--lg-border);
}
.lg-web-bar-brand {
    font-weight: 800;
    font-size: 1.15rem;
    color: var(--lg-text-1);
}
.lg-web-bar-user {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    max-width: 100%;
    min-width: 0;
    padding: 4px 12px 4px 4px;
    border: 1px solid var(--lg-border);
    border-radius: var(--lg-radius-full);
    background: var(--lg-bg);
    color: var(--lg-text-1);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
}
.lg-web-bar-avatar {
    flex: 0 0 auto;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--lg-brand);
    color: #fff;
    font-weight: 700;
}
.lg-web-bar-name {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.lg-web-bar-caret { color: var(--lg-text-2); }
.lg-web-bar-right {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}
.lg-web-bar-settings {
    display: flex;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    min-width: 44px;
    justify-content: center;
    padding: 4px 14px;
    border: 1px solid var(--lg-border);
    border-radius: var(--lg-radius-full);
    background: var(--lg-bg);
    color: var(--lg-text-1);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
}
.lg-web-bar-settings:hover,
.lg-web-bar-user:hover { border-color: var(--lg-brand); }
@media (max-width: 599px) {
    .lg-web-bar-settings { padding: 4px 10px; }
    .lg-web-bar-settings-label { display: none; }
}
.lg-web-bar-menu {
    position: absolute;
    top: 50px;
    right: 16px;
    min-width: 240px;
    max-width: calc(100vw - 32px);
    padding: 8px;
    box-sizing: border-box;
    background: var(--lg-surface);
    border: 1px solid var(--lg-border);
    border-radius: var(--lg-radius-medium);
    box-shadow: var(--lg-shadow-large);
}
.lg-web-bar-menu[hidden] { display: none; }
.lg-web-bar-menu-who {
    padding: 8px 10px 12px;
    border-bottom: 1px solid var(--lg-border);
    margin-bottom: 6px;
    overflow-wrap: anywhere;
}
.lg-web-bar-menu-label { font-size: 0.8rem; color: var(--lg-text-2); }
.lg-web-bar-menu-name { font-weight: 700; color: var(--lg-text-1); }
.lg-web-bar-menu-email { font-size: 0.9rem; color: var(--lg-text-2); }
.lg-web-bar-menu-item {
    display: block;
    width: 100%;
    min-height: 44px;
    padding: 0 10px;
    border: none;
    border-radius: var(--lg-radius-small);
    background: none;
    color: var(--lg-text-1);
    font-size: 1rem;
    text-align: left;
    cursor: pointer;
}
.lg-web-bar-menu-item:hover { background: var(--lg-surface-2); }
.lg-web-bar-menu-danger { color: var(--lg-danger); }
body.lg-web-has-bar .lg-app-column { padding-top: 52px; box-sizing: border-box; }
body.lg-web-has-bar .lg-modal-overlay { top: 52px; }
/* !important: lgBringModalToFront sets an inline z-index (~700) that would put the viewer —
   and its ✕ — underneath the web top bar. */
body.lg-web-has-bar .lg-receipt-viewer { z-index: 6000 !important; }
.lg-invoice-card-icons { display: flex; align-items: center; gap: 4px; }

/* Viewer Print button (web only) — top-right, left of the ✕ */
.lg-receipt-viewer-print {
    position: fixed;
    top: calc(env(safe-area-inset-top) + 16px);
    right: 72px;
    z-index: calc(var(--lg-z-modal) + 1);
    min-height: 44px;
    padding: 0 16px;
    border: none;
    border-radius: var(--lg-radius-full);
    background: rgba(255, 255, 255, 0.92);
    color: #111;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
}
.lg-receipt-viewer-print:hover { background: #fff; }

/* Contact form notice + invoice client email line (19 Nov 2026 — fix "no email" dead end) */
.lg-cf-notice {
    margin-bottom: 16px;
    padding: 12px 14px;
    border-radius: var(--lg-radius-medium);
    background: var(--lg-brand-light);
    color: var(--lg-text-1);
    font-weight: 600;
    line-height: 1.4;
}
.lg-invf-client-email {
    display: block;
    margin-top: 6px;
    color: var(--lg-text-2);
    font-size: 0.95rem;
    overflow-wrap: anywhere;
}
.lg-invf-client-email-missing {
    width: 100%;
    min-height: 44px;
    padding: 8px 12px;
    border: 1px dashed var(--lg-danger);
    border-radius: var(--lg-radius-medium);
    background: var(--lg-danger-light);
    color: var(--lg-danger);
    font-weight: 600;
    text-align: left;
    cursor: pointer;
}

/* =============================================================================================
   Web workspace layout (19 Nov 2026). Everything below is scoped to body.lg-web-has-bar, which
   only the browser version ever sets — the Android app can never match these rules.
   ============================================================================================= */

/* Bug fix (all web sizes): every panel is 100dvh tall, but the web top bar takes 52px — without
   this the bottom 52px of every screen was cut off. */
body.lg-web-has-bar [class*="lg-panel-"].lg-active {
    height: calc(100dvh - 52px);
}

/* Desktop (PC monitor / large tablet landscape) — phones and iPhones (<900px wide) keep the
   big-tile layout untouched. */
@media (min-width: 900px) {
    body.lg-web-has-bar {
        --lg-web-content-max: 1100px;
        --lg-web-gutter: max(24px, calc((100% - var(--lg-web-content-max)) / 2));
    }

    /* Screens use a comfortable centred reading width; headers keep their full-width band but
       line their title/✕ up with the content below. */
    body.lg-web-has-bar .lg-header,
    body.lg-web-has-bar .lg-panel-content,
    body.lg-web-has-bar .lg-home-groups {
        padding-left: var(--lg-web-gutter);
        padding-right: var(--lg-web-gutter);
    }
    body.lg-web-has-bar .lg-home-groups {
        padding-top: 24px;
        padding-bottom: 24px;
        gap: 16px;
    }

    /* Hub tiles (Home, More, Banking): a compact grid of normal-sized buttons instead of two
       giant squares per row. The row wrappers dissolve into the grid. */
    body.lg-web-has-bar .lg-home-group {
        display: grid;
        grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
        gap: 14px;
    }
    body.lg-web-has-bar .lg-home-button-row {
        display: contents;
    }
    body.lg-web-has-bar .lg-home-button {
        aspect-ratio: auto;
        min-height: 128px;
        padding: 18px 12px;
    }
    body.lg-web-has-bar .lg-home-button:hover {
        border-color: var(--lg-brand);
        background: var(--lg-surface-2);
    }
    body.lg-web-has-bar .lg-home-button-icon {
        font-size: 2.6rem;
    }
    body.lg-web-has-bar .lg-home-button-label {
        font-size: 0.95rem;
    }
    body.lg-web-has-bar .lg-home-group > :not(.lg-home-button-row):not(.lg-home-button) {
        grid-column: 1 / -1; /* hero card, headings, notes span the full width */
    }

    /* Main action buttons (+ Add Job, + Create Invoice …): mouse-sized, not full-width bars. */
    body.lg-web-has-bar .lg-panel-content > .lg-button-action {
        width: auto;
        align-self: flex-start;
        min-width: 220px;
        padding: 12px 28px;
    }

    /* Pop-up forms: a little roomier on a big screen. */
    body.lg-web-has-bar .lg-modal {
        max-width: 560px;
    }
    /* Full-screen pop-ups (the invoice) become a large centred dialog. */
    body.lg-web-has-bar .lg-modal.lg-modal-fullscreen {
        max-width: 960px;
        height: calc(100% - 48px);
        border-radius: var(--lg-radius-large);
    }
    body.lg-web-has-bar #lg-invoice-modal-overlay {
        padding: 24px;
    }

    /* Dialog footer buttons (Save, View PDF, Download PDF …) sit side by side, right-aligned,
       at normal button size — not stacked full-width thumb bars. */
    body.lg-web-has-bar .lg-modal-footer {
        display: flex;
        flex-direction: row;
        justify-content: flex-end;
        flex-wrap: wrap;
        gap: 12px;
    }
    body.lg-web-has-bar .lg-modal-footer > button {
        width: auto;
        flex: 0 0 auto;
        min-width: 160px;
        min-height: 44px;
        padding: 10px 24px;
        margin: 0;
    }
}
