/*
    Transaction popups: the shared design tokens and building blocks of the transaction popup, its Recurring tab
    (recurring-stream-editor.css) and the Manual Transaction popup (manual-transaction.css). They port the mobile v4
    theme keys (ChipIn.Mobile Themes/LightTheme.xaml and DarkTheme.xaml) one for one, so web and mobile read the same in
    light and dark. MAUI writes colors as #AARRGGBB; they are converted to rgba() here.

    Prefixes: --tx-* tokens, tx- shared primitives, txp- transaction popup, rse- recurring editor, mtx- manual
    transaction. Dark mode follows the site's data-bs-theme="dark" on <html>.
*/

:root {
    --tx-font: "Poppins", var(--si-font-sans-serif, "Manrope"), system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
    --tx-font-text: "Segoe UI", system-ui, -apple-system, Roboto, "Helvetica Neue", Arial, sans-serif;
    --tx-primary: hsl(calc(247.83deg + var(--ci-accent-shift, 0deg)) 76.3% 58.63%);
    --tx-page: #FCFDFD;
    --tx-text: #0B0F19;
    --tx-muted: #565973;
    --tx-light-text: #9397AD;
    --tx-surface: #F3F5FA;
    --tx-hero-tile: #FFFFFF;
    --tx-input-bg: rgba(255, 255, 255, .85);
    --tx-tile-border: #E3E7EF;
    --tx-tile-bg: rgba(255, 255, 255, .70);
    --tx-owner-partner-tint: rgba(217, 119, 6, .10);
    --tx-card-border: hsl(calc(249.6deg + var(--ci-accent-shift, 0deg)) 75.76% 93.53%);
    --tx-hero-border: hsl(calc(252.97deg + var(--ci-accent-shift, 0deg)) 78.72% 90.78%);
    --tx-entry-border: #EAEEF2;
    --tx-border: #E2E5F1;
    --tx-wrapper: #F3F6FF;
    --tx-seg-track: #F3F5FA;
    --tx-seg-pill: linear-gradient(135deg, #D9E2F3 0%, #EEF2F9 100%);
    --tx-seg-pill-border: #FFFFFF;
    --tx-seg-pill-shadow: rgba(31, 42, 68, .16);
    --tx-seg-selected-glyph: hsl(calc(247.83deg + var(--ci-accent-shift, 0deg)) 76.3% 58.63%);
    --tx-seg-selected-text: #0B0F19;
    --tx-seg-text: #565973;
    --tx-positive: #16A34A;
    --tx-negative: #EF4444;
    --tx-caution: #B45309;
    --tx-caution-soft: #FEF3C7;
    --tx-critical: #DC2626;
    --tx-critical-soft: #FEE2E2;
    --tx-positive-soft: #DCFCE7;
    --tx-home-icon: #2563EB;
    --tx-reports-icon: hsl(calc(243.4deg + var(--ci-accent-shift, 0deg)) 75.36% 58.63%);
    --tx-partner: #D97706;
    --tx-user: #2563EB;
    --tx-green: #00BD46;
    --tx-amount-expense: #FF392B;
    --tx-amount-income: #096F74;
    --tx-amount-zero: #6B7280;
    --tx-inflow: #10B981;
    --tx-neutral: #6B7280;
    /* The flow strip's hues: the mobile TxFlow* keys (text / background), one per kind family. */
    --tx-flow-income-text: #16A34A;
    --tx-flow-income-bg: #DCFCE7;
    --tx-flow-transfer-text: #2563EB;
    --tx-flow-transfer-bg: #DBEAFE;
    --tx-flow-credit-text: #0D9488;
    --tx-flow-credit-bg: #CCFBF1;
    --tx-flow-loan-text: #B45309;
    --tx-flow-loan-bg: #F6DDB2;
    --tx-pill-bg: hsl(calc(246.92deg + var(--ci-accent-shift, 0deg)) 100% 94.9%);
    --tx-pill-text: hsl(calc(248.51deg + var(--ci-accent-shift, 0deg)) 62.11% 44.51%);
    --tx-thumb: hsl(calc(247.83deg + var(--ci-accent-shift, 0deg)) 76.3% 58.63%);
    --tx-thumb-on: hsl(calc(247.94deg + var(--ci-accent-shift, 0deg)) 83.95% 68.24%);
    --tx-thumb-off: hsl(calc(247.66deg + var(--ci-accent-shift, 0deg)) 100% 90.78%);
    --tx-glass: rgba(255, 255, 255, .7);
    --tx-skeleton-bone: #D2D8E6;
    --tx-skeleton-wave: #F0F3F9;
    --tx-calendar-selection: #D9E2F3;
    --tx-calendar-selection-text: #0B0F19;
    --tx-calendar-header: #E8EFF2;
    --tx-action-secondary: hsl(calc(248.57deg + var(--ci-accent-shift, 0deg)) 53.85% 97.45%);
    --tx-confirm-accept: #4F5263;
    --tx-nr-critical: #DC2626;
    --tx-nr-warning: #B45309;
    --tx-nr-warning-soft: #FEF3C7;
    --tx-nr-info: hsl(calc(247.83deg + var(--ci-accent-shift, 0deg)) 76.3% 58.63%);
    --tx-nr-info-soft: hsl(calc(249deg + var(--ci-accent-shift, 0deg)) 100% 96.08%);
    --tx-nr-tile: hsl(calc(248.57deg + var(--ci-accent-shift, 0deg)) 53.85% 97.45%);
    --tx-nr-active: #15803D;
    --tx-nr-paused: #B45309;
    --tx-nr-cancelled: #DC2626;
    --tx-nr-archived: #64748B;
    --tx-nr-on-accent: #FFFFFF;
    --tx-nr-chart-bar: #C9C2F5;
    --tx-nr-chart-flagged: #5A45E6;
    --tx-nr-reviewed: #16A34A;
    --tx-nr-header-icon-bg: hsl(calc(249deg + var(--ci-accent-shift, 0deg)) 100% 96.08%);
    --tx-nr-header-icon: hsl(calc(247.83deg + var(--ci-accent-shift, 0deg)) 76.3% 58.63%);
    --tx-glow-user: radial-gradient(ellipse 65% 65% at 0% 0%, rgba(37, 99, 235, .15) 0%, rgba(37, 99, 235, .075) 50%, rgba(37, 99, 235, 0) 100%);
    --tx-glow-partner: radial-gradient(ellipse 65% 65% at 100% 0%, rgba(217, 119, 6, .12) 0%, rgba(217, 119, 6, .06) 50%, rgba(217, 119, 6, 0) 100%);
    --tx-detail-card: linear-gradient(158deg, rgba(232, 233, 237, .9) 0%, rgba(243, 244, 246, .92) 45%, rgba(255, 255, 255, .95) 100%);
    --tx-card-stroke: linear-gradient(135deg, #FFFFFF 0%, rgba(221, 227, 238, .9) 50%, rgba(216, 221, 231, .8) 100%);
    --tx-recurring-card: linear-gradient(158deg, rgba(234, 229, 246, .9) 0%, rgba(244, 242, 250, .92) 45%, rgba(255, 255, 255, .95) 100%);
    --tx-overlay: rgba(0, 0, 0, .6);
    --tx-dialog-shadow: 0 24px 64px rgba(15, 23, 42, .28);
    /* Lit tiles (mobile TxPopupTileBrush / TxPopupTileStrokeBrush): the tile color at the top-left fading toward the
       surface under it, with a hairline that fades the same way. */
    --tx-tile-fill: linear-gradient(to bottom right, #FFFFFF 0%, rgba(255, 255, 255, .6) 55%, rgba(255, 255, 255, .2) 100%);
    --tx-tile-stroke: linear-gradient(to bottom right, #E3E7EF 0%, rgba(227, 231, 239, .4) 60%, rgba(227, 231, 239, 0) 100%);
    /* Switch tracks (mobile TxFlowSwitch*): Expense / Income / Other, its type menu, Insights / Details / Charges and the
       Notifications menu. Light: a white track lifted by a soft shadow; the accent hairline is lit from the top-left. */
    --tx-switch-track: linear-gradient(to bottom right, #FFFFFF 0%, #F6F7FB 100%);
    --tx-switch-stroke: linear-gradient(to bottom right, hsl(calc(247.83deg + var(--ci-accent-shift, 0deg)) 76.3% 58.63% / .45) 0%, #E3E7EF 45%, #E3E7EF 100%);
    --tx-switch-shadow: 0 3px 10px rgba(31, 42, 68, .1);
    /* The popup's tab dock (mobile TxTabDock* / TxTabPillGlowColor / TxTabBarGlow*): an accent-washed band edge to edge,
       an accent hairline on top, an inset track, an accent glow under the pill and a blurred bar under the selected tab. */
    --tx-dock-bg: linear-gradient(180deg, hsl(calc(249.47deg + var(--ci-accent-shift, 0deg)) 90.48% 95.88%) 0%, #F9FAFD 100%);
    --tx-dock-top-edge: hsl(calc(247.83deg + var(--ci-accent-shift, 0deg)) 76.3% 58.63% / .28);
    --tx-dock-bottom-edge: #E3E7EF;
    --tx-dock-track: #FFFFFF;
    --tx-dock-track-border: #E3E7EF;
    --tx-pill-glow: hsl(calc(247.83deg + var(--ci-accent-shift, 0deg)) 76.3% 58.63% / .27);
    --tx-bar-glow-core: hsl(calc(247.83deg + var(--ci-accent-shift, 0deg)) 76.3% 58.63% / .4);
    --tx-bar-glow-lead: hsl(calc(247.27deg + var(--ci-accent-shift, 0deg)) 100% 74.12% / .5);
    --tx-bar-glow-trail: hsl(calc(247.13deg + var(--ci-accent-shift, 0deg)) 62.99% 50.2% / .5);
    --tx-bar-glow-sheen: rgba(255, 255, 255, .5);
}

[data-bs-theme="dark"] {
    --tx-primary: hsl(calc(247.94deg + var(--ci-accent-shift, 0deg)) 83.95% 68.24%);
    --tx-page: #0B0F19;
    --tx-text: #D9DBE8;
    --tx-muted: #EEEEEE;
    --tx-light-text: #B4B7C9;
    --tx-surface: #151B28;
    --tx-hero-tile: rgba(255, 255, 255, .08);
    --tx-input-bg: rgba(11, 15, 25, .5);
    --tx-tile-border: rgba(255, 255, 255, .10);
    --tx-tile-bg: rgba(255, 255, 255, .08);
    --tx-owner-partner-tint: rgba(251, 191, 36, .12);
    --tx-card-border: #2B3045;
    --tx-hero-border: hsl(calc(245.45deg + var(--ci-accent-shift, 0deg)) 31.43% 27.45%);
    --tx-entry-border: #2B3045;
    --tx-border: #2B3045;
    --tx-wrapper: #1F2233;
    --tx-seg-track: #151B28;
    --tx-seg-pill: linear-gradient(135deg, #2F3B5D 0%, #1F2741 100%);
    --tx-seg-pill-border: rgba(255, 255, 255, .15);
    --tx-seg-pill-shadow: rgba(0, 0, 0, .16);
    --tx-seg-selected-glyph: hsl(calc(246.79deg + var(--ci-accent-shift, 0deg)) 100% 79.22%);
    --tx-seg-selected-text: #F5F6FB;
    --tx-seg-text: #A9AEC4;
    --tx-positive: #22C55E;
    --tx-negative: #EF4444;
    --tx-caution: #FBBF24;
    --tx-caution-soft: rgba(251, 191, 36, .18);
    --tx-critical: #F87171;
    --tx-critical-soft: rgba(248, 113, 113, .18);
    --tx-positive-soft: rgba(34, 197, 94, .15);
    --tx-home-icon: #60A5FA;
    --tx-reports-icon: #A5B4FC;
    --tx-partner: #FBBF24;
    --tx-user: #60A5FA;
    --tx-neutral: #9CA3AF;
    --tx-flow-income-text: #22C55E;
    --tx-flow-income-bg: rgba(34, 197, 94, .15);
    --tx-flow-transfer-text: #60A5FA;
    --tx-flow-transfer-bg: rgba(96, 165, 250, .16);
    --tx-flow-credit-text: #2DD4BF;
    --tx-flow-credit-bg: rgba(45, 212, 191, .15);
    --tx-flow-loan-text: #F2B557;
    --tx-flow-loan-bg: rgba(242, 181, 87, .16);
    --tx-pill-bg: hsl(calc(247.2deg + var(--ci-accent-shift, 0deg)) 24.27% 20.2%);
    --tx-pill-text: hsl(calc(246.89deg + var(--ci-accent-shift, 0deg)) 100% 88.04%);
    --tx-thumb: hsl(calc(247.94deg + var(--ci-accent-shift, 0deg)) 83.95% 68.24%);
    --tx-thumb-on: hsl(calc(246.89deg + var(--ci-accent-shift, 0deg)) 100% 88.04%);
    --tx-thumb-off: hsl(calc(250.34deg + var(--ci-accent-shift, 0deg)) 21.48% 26.47%);
    --tx-glass: rgba(255, 255, 255, .08);
    --tx-skeleton-bone: rgba(154, 168, 214, .13);
    --tx-skeleton-wave: rgba(180, 190, 230, .24);
    --tx-calendar-selection: #2F3B5D;
    --tx-calendar-selection-text: #F5F6FB;
    --tx-calendar-header: #333942;
    --tx-action-secondary: #1F2433;
    --tx-nr-critical: #F87171;
    --tx-nr-warning: #F2B557;
    --tx-nr-warning-soft: rgba(242, 181, 87, .18);
    --tx-nr-info: hsl(calc(248.4deg + var(--ci-accent-shift, 0deg)) 100% 80.39%);
    --tx-nr-info-soft: hsl(calc(247.38deg + var(--ci-accent-shift, 0deg)) 87.14% 72.55% / .18);
    --tx-nr-tile: #1F2433;
    --tx-nr-active: #34D399;
    --tx-nr-paused: #FBBF24;
    --tx-nr-cancelled: #F87171;
    --tx-nr-archived: #94A3B8;
    --tx-nr-on-accent: #0B0F19;
    --tx-nr-chart-bar: #3F3A6B;
    --tx-nr-chart-flagged: #A99BFF;
    --tx-nr-reviewed: #34D399;
    --tx-nr-header-icon-bg: hsl(calc(247.94deg + var(--ci-accent-shift, 0deg)) 83.95% 68.24% / .18);
    --tx-nr-header-icon: hsl(calc(248.4deg + var(--ci-accent-shift, 0deg)) 100% 80.39%);
    --tx-glow-user: radial-gradient(ellipse 65% 65% at 0% 0%, rgba(37, 99, 235, .22) 0%, rgba(37, 99, 235, .11) 50%, rgba(37, 99, 235, 0) 100%);
    --tx-glow-partner: radial-gradient(ellipse 65% 65% at 100% 0%, rgba(217, 119, 6, .18) 0%, rgba(217, 119, 6, .09) 50%, rgba(217, 119, 6, 0) 100%);
    --tx-detail-card: linear-gradient(158deg, rgba(42, 44, 51, .85) 0%, rgba(29, 31, 37, .8) 45%, rgba(19, 20, 24, .75) 100%);
    --tx-card-stroke: linear-gradient(135deg, rgba(255, 255, 255, .25) 0%, rgba(255, 255, 255, .08) 50%, rgba(255, 255, 255, .04) 100%);
    --tx-recurring-card: linear-gradient(158deg, rgba(46, 40, 80, .85) 0%, rgba(31, 28, 54, .8) 45%, rgba(20, 19, 32, .75) 100%);
    --tx-dialog-shadow: 0 24px 64px rgba(0, 0, 0, .55);
    --tx-tile-fill: linear-gradient(to bottom right, rgba(255, 255, 255, .12) 0%, rgba(255, 255, 255, .05) 55%, rgba(255, 255, 255, .012) 100%);
    --tx-tile-stroke: linear-gradient(to bottom right, rgba(255, 255, 255, .14) 0%, rgba(255, 255, 255, .03) 60%, rgba(255, 255, 255, 0) 100%);
    /* Dark: a recessed well, deeper at the top, that the raised pill pops out of; no lift. */
    --tx-switch-track: linear-gradient(180deg, rgba(10, 13, 23, .9) 0%, rgba(17, 22, 38, .7) 100%);
    --tx-switch-stroke: linear-gradient(to bottom right, hsl(calc(247.27deg + var(--ci-accent-shift, 0deg)) 100% 74.12% / .45) 0%, rgba(255, 255, 255, .12) 45%, rgba(255, 255, 255, .06) 100%);
    --tx-switch-shadow: none;
    --tx-dock-bg: linear-gradient(180deg, hsl(calc(245.62deg + var(--ci-accent-shift, 0deg)) 34.04% 18.43%) 0%, #121726 100%);
    --tx-dock-top-edge: hsl(calc(247.27deg + var(--ci-accent-shift, 0deg)) 100% 74.12% / .35);
    --tx-dock-bottom-edge: rgba(255, 255, 255, .06);
    --tx-dock-track: rgba(11, 15, 25, .9);
    --tx-dock-track-border: rgba(255, 255, 255, .08);
    --tx-pill-glow: hsl(calc(247.94deg + var(--ci-accent-shift, 0deg)) 83.95% 68.24% / .45);
    --tx-bar-glow-core: hsl(calc(247.27deg + var(--ci-accent-shift, 0deg)) 100% 74.12% / .6);
    --tx-bar-glow-lead: hsl(calc(247.88deg + var(--ci-accent-shift, 0deg)) 100% 80.59% / .7);
    --tx-bar-glow-trail: hsl(calc(247.79deg + var(--ci-accent-shift, 0deg)) 83.7% 63.92% / .65);
    --tx-bar-glow-sheen: rgba(255, 255, 255, .2);
}

/* ------------------------------------------------------------------ Dialog chrome (SfDialog CssClass="tx-dialog") */

.e-dialog.tx-dialog {
    border: 0;
    border-radius: 24px;
    overflow: hidden;
    background: var(--tx-page);
    box-shadow: var(--tx-dialog-shadow);
    max-height: calc(100dvh - 2rem);
}

.e-dialog.tx-dialog .e-dlg-header-content {
    display: none;
}

.e-dialog.tx-dialog .e-dlg-content {
    padding: 0;
    background: var(--tx-page);
    color: var(--tx-text);
    overflow: hidden;
    height: 100%;
}

/* Only the popups' own overlays (every other Syncfusion dialog on the site keeps its look). The :has() forms sit in rules
   of their own: a browser without :has() drops only those. */
.e-dlg-container .e-dlg-overlay.tx-overlay,
.tx-dialog + .e-dlg-overlay {
    background-color: var(--tx-overlay);
    transition: opacity .2s ease;
}

.e-dlg-container:has(> .tx-dialog) > .e-dlg-overlay {
    background-color: var(--tx-overlay);
    transition: opacity .2s ease;
}

@media (max-width: 640px) {
    .e-dialog.tx-dialog.tx-dialog-full {
        width: 100vw !important;
        max-width: 100vw !important;
        height: 100dvh !important;
        max-height: 100dvh !important;
        border-radius: 0;
        top: 0 !important;
        left: 0 !important;
    }
}

.tx-root {
    font-family: var(--tx-font);
    color: var(--tx-text);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.tx-root *,
.tx-root *::before,
.tx-root *::after {
    box-sizing: border-box;
}

.tx-root button {
    font-family: inherit;
}

.tx-root :focus-visible {
    outline: 2px solid var(--tx-primary);
    outline-offset: 2px;
}

.tx-sr-only {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* ------------------------------------------------------------------ Sections, tiles and text (the mobile Tx* styles) */

.tx-section {
    padding: 14px;
    background: var(--tx-surface);
    border-radius: 18px;
}

.tx-section-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tx-section-title {
    margin: 0;
    font-weight: 600;
    font-size: 11px;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--tx-muted);
}

.tx-field-label {
    margin: 0;
    font-weight: 600;
    font-size: 13px;
    color: var(--tx-text);
}

.tx-hint,
.tx-hint-wrap {
    margin: 0;
    font-family: var(--tx-font-text);
    font-size: 11.5px;
    color: var(--tx-muted);
}

.tx-hint {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.tx-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.tx-field-box {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 2px 12px;
    background: var(--tx-input-bg);
    border: 1px solid var(--tx-tile-border);
    border-radius: 12px;
    transition: border-color .15s ease, box-shadow .15s ease;
}

.tx-field-box:focus-within {
    border-color: var(--tx-primary);
}

/* The box's border is the field's focus ring: the input inside doesn't add a second one. */
.tx-field-box :focus-visible {
    outline: none;
}

.tx-field-box.tx-field-box-multiline {
    align-items: flex-start;
    padding: 4px 10px;
}

.tx-field-input,
.tx-field-textarea {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: var(--tx-text);
}

.tx-field-input {
    min-height: 42px;
    font-family: var(--tx-font);
    font-weight: 600;
    font-size: 15px;
}

.tx-field-textarea {
    min-height: 60px;
    padding: 8px 2px;
    resize: vertical;
    font-family: var(--tx-font-text);
    font-size: 14px;
    line-height: 1.4;
    field-sizing: content;
}

.tx-field-input::placeholder,
.tx-field-textarea::placeholder {
    color: var(--tx-muted);
    opacity: .75;
}

.tx-field-input:disabled,
.tx-field-textarea:disabled {
    cursor: default;
    opacity: .8;
}

.tx-glance-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

.tx-glance-tile {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    padding: 9px 10px;
    background: var(--tx-hero-tile);
    border: 0;
    border-radius: 14px;
    text-align: left;
    color: inherit;
}

/* Lit from the top-left (the mobile TxGlanceTile / RsGlanceTile): the Transaction tab's At a glance and the recurring
   editor's At a glance and Charge history tiles. The hairline is the shared .tx-lit-ring below. */
.tx-glance-tile:not(.rts-tile) {
    position: relative;
    background: var(--tx-tile-fill);
}

button.tx-glance-tile {
    cursor: pointer;
    transition: transform .12s ease, box-shadow .12s ease;
}

button.tx-glance-tile:hover {
    box-shadow: 0 2px 10px rgba(15, 23, 42, .06);
}

button.tx-glance-tile:active {
    transform: scale(.985);
}

.tx-glance-caption {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
    font-size: 10px;
    letter-spacing: .05em;
    text-transform: uppercase;
    color: var(--tx-muted);
}

.tx-glance-value {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
    font-size: 15.5px;
    color: var(--tx-text);
}

.tx-glance-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    min-width: 0;
}

.tx-glyph {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    line-height: 1;
}

.tx-glyph-muted {
    color: var(--tx-muted);
}

.tx-pencil {
    font-size: 11px;
    color: var(--tx-muted);
}

.tx-about-row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    column-gap: 16px;
}

.tx-about-value {
    font-weight: 600;
    font-size: 13px;
    text-align: right;
    color: var(--tx-text);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    white-space: pre-line;
    overflow-wrap: anywhere;
}

.tx-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 9px;
    background: var(--tx-tile-bg);
    border-radius: 12px;
    font-weight: 600;
    font-size: 10px;
    color: var(--tx-primary);
    white-space: nowrap;
}

/* ------------------------------------------------------------------ Action rows (share, delete, help links) */

.tx-action-row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    column-gap: 12px;
    width: 100%;
    min-height: 56px;
    padding: 11px 14px;
    background: var(--tx-surface);
    border: 0;
    border-radius: 14px;
    text-align: left;
    color: inherit;
    cursor: pointer;
    transition: transform .12s ease, box-shadow .12s ease;
}

.tx-action-row:hover {
    box-shadow: 0 2px 12px rgba(15, 23, 42, .06);
}

.tx-action-row:active {
    transform: scale(.99);
}

.tx-action-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 17px;
    background: var(--tx-tile-bg);
    color: var(--tx-primary);
    font-size: 13px;
}

.tx-action-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-weight: 600;
    font-size: 14px;
    color: var(--tx-text);
}

.tx-action-detail {
    margin-top: 1px;
    font-size: 11px;
    line-height: 1.35;
    color: var(--tx-muted);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.tx-action-chevron {
    font-size: 11px;
    color: var(--tx-muted);
}

.tx-action-row.tx-action-critical {
    border: 1px solid var(--tx-critical-soft);
}

.tx-action-row.tx-action-critical .tx-action-badge {
    background: var(--tx-critical-soft);
    color: var(--tx-critical);
}

.tx-action-row.tx-action-critical .tx-action-title,
.tx-action-row.tx-action-critical .tx-action-chevron {
    color: var(--tx-critical);
}

.tx-action-row.tx-action-critical .tx-action-chevron {
    opacity: .75;
}

.tx-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px;
    border: 0;
    background: transparent;
    font-weight: 600;
    font-size: 12px;
    color: var(--tx-primary);
    cursor: pointer;
}

.tx-link:hover {
    text-decoration: underline;
}

/* ------------------------------------------------------------------ Buttons (ActionPrimaryButtonStyle and friends) */

.tx-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 8px 16px;
    border: 0;
    border-radius: 14px;
    font-family: var(--tx-font);
    font-weight: 600;
    font-size: 14px;
    line-height: 1.2;
    white-space: nowrap;
    cursor: pointer;
    transition: filter .15s ease, transform .12s ease, opacity .15s ease;
}

.tx-btn:active:not(:disabled) {
    transform: scale(.98);
}

.tx-btn:disabled {
    cursor: default;
    opacity: .55;
}

.tx-btn-primary {
    background: var(--tx-primary);
    color: #FFFFFF;
}

.tx-btn-primary:hover:not(:disabled) {
    filter: brightness(1.06);
}

.tx-btn-secondary {
    background: var(--tx-action-secondary);
    color: var(--tx-primary);
}

.tx-btn-text {
    background: transparent;
    color: var(--tx-text);
}

.tx-btn-text:hover:not(:disabled) {
    background: var(--tx-tile-bg);
}

.tx-btn-critical {
    background: var(--tx-critical);
    color: #FFFFFF;
}

.tx-btn-compact {
    min-height: 36px;
    padding: 8px 16px;
    border-radius: 12px;
    font-size: 12.5px;
}

/* ------------------------------------------------------------------ Segmented menu (Controls/SharedViews/SegmentedMenu) */

.tx-seg {
    position: relative;
    display: grid;
    grid-auto-columns: minmax(0, 1fr);
    grid-auto-flow: column;
    padding: 4px;
    background: var(--tx-seg-track);
    border-radius: 16px;
}

.tx-seg-pill {
    position: absolute;
    top: 4px;
    bottom: 4px;
    left: 4px;
    width: calc((100% - 8px) / var(--tx-seg-count, 3));
    transform: translateX(calc(100% * var(--tx-seg-index, 0)));
    background: var(--tx-seg-pill);
    border: 1px solid var(--tx-seg-pill-border);
    border-radius: 12px;
    box-shadow: 0 2px 8px var(--tx-seg-pill-shadow);
    pointer-events: none;
    transition: transform .38s cubic-bezier(.34, 1.36, .64, 1), width .25s ease;
}

.tx-seg-pill.tx-seg-pill-instant {
    transition: none;
}

.tx-seg-item {
    position: relative;
    z-index: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    min-width: 0;
    height: 40px;
    padding: 0 4px;
    border: 0;
    background: transparent;
    color: var(--tx-seg-text);
    font-family: var(--tx-font-text);
    font-size: 13px;
    white-space: nowrap;
    cursor: pointer;
}

.tx-seg-item .tx-glyph {
    font-size: 13px;
}

.tx-seg-item .tx-icon-split {
    width: 16px;
    height: 16px;
}

.tx-seg-item.tx-seg-selected {
    color: var(--tx-seg-selected-text);
    font-family: var(--tx-font);
    font-weight: 600;
}

.tx-seg-item.tx-seg-selected .tx-glyph,
.tx-seg-item.tx-seg-selected .tx-icon-split {
    color: var(--tx-seg-selected-glyph);
}

.tx-seg-item-label {
    overflow: hidden;
    text-overflow: ellipsis;
}

/* The muted detail after a label (the mobile SegmentedMenuItem.Detail): a count, or the clear mark of a filter. */
.tx-seg-item-detail {
    flex: 0 0 auto;
    font-family: var(--tx-font-text);
    font-size: 11.5px;
    font-weight: 500;
    font-variant-numeric: tabular-nums;
    color: var(--tx-seg-text);
    opacity: .85;
}

.tx-seg-item.tx-seg-selected .tx-seg-item-detail {
    color: var(--tx-seg-selected-glyph);
    opacity: 1;
}

a.tx-seg-item,
a.tx-seg-item:hover,
a.tx-seg-item:focus {
    text-decoration: none;
}

.tx-seg-item:not(.tx-seg-selected):not(:disabled):hover {
    color: var(--tx-seg-selected-text);
}

.tx-seg-item:focus-visible {
    outline: 2px solid var(--tx-seg-selected-glyph);
    outline-offset: -2px;
    border-radius: 12px;
}

.tx-seg:not(.rse-status) > .tx-seg-item:disabled,
.tx-seg-item.tx-seg-disabled {
    cursor: default;
    opacity: .45;
}

/* The whole menu while its choice loads: the pill stays, the other segments dim. */
.tx-seg.tx-seg-is-disabled .tx-seg-item {
    cursor: progress;
}

.tx-seg.tx-seg-is-disabled .tx-seg-item:not(.tx-seg-selected) {
    opacity: .55;
}

.tx-seg.tx-seg-is-disabled .tx-seg-item.tx-seg-selected {
    opacity: 1;
}

.tx-seg-item.tx-seg-icon-only {
    padding: 0 10px;
}

.tx-seg-item.tx-seg-icon-only .tx-glyph {
    font-size: 14px;
}

/* Compact (the mobile IsCompact menus): card headers, filter panels, the owner filter. */
.tx-seg.tx-seg-compact {
    padding: 3px;
    border-radius: 13px;
}

.tx-seg.tx-seg-compact .tx-seg-pill {
    top: 3px;
    bottom: 3px;
    left: 3px;
    width: calc((100% - 6px) / var(--tx-seg-count, 3));
    border-radius: 10px;
}

.tx-seg.tx-seg-compact .tx-seg-item {
    height: 32px;
    gap: 6px;
    padding: 0 8px;
    font-size: 12.5px;
}

.tx-seg.tx-seg-compact .tx-seg-item .tx-glyph {
    font-size: 12px;
}

/* Inline: as wide as its labels (every segment as wide as the widest, so the pill keeps one width). */
.tx-seg.tx-seg-inline {
    display: inline-grid;
    grid-auto-columns: minmax(0, 1fr);
    max-width: 100%;
    vertical-align: middle;
}

.tx-seg.tx-seg-inline .tx-seg-item {
    padding: 0 14px;
}

.tx-seg.tx-seg-compact.tx-seg-inline .tx-seg-item {
    padding: 0 12px;
}

/* The selected label is semibold: an invisible semibold copy reserves its width so the segments never shift. */
.tx-seg.tx-seg-inline .tx-seg-item-label {
    display: inline-grid;
    overflow: visible;
}

.tx-seg.tx-seg-inline .tx-seg-item-label::after {
    content: attr(data-text);
    grid-area: 1 / 1;
    height: 0;
    overflow: hidden;
    visibility: hidden;
    font-family: var(--tx-font);
    font-weight: 600;
}

/* Scroll (the mobile Mode="Scroll" chips): every segment keeps --tx-seg-min and the track scrolls sideways. */
.tx-seg.tx-seg-scroll {
    --tx-seg-min: 88px;
    grid-auto-columns: minmax(var(--tx-seg-min), 1fr);
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
}

.tx-seg.tx-seg-scroll::-webkit-scrollbar {
    display: none;
}

/* SegmentedScroller: a section menu that scrolls when it can't fit (Reports, Investments). The arrows appear only
   while there's more that way (js/chipin-layout.js sets can-prev / can-next) and the track fades under them; a mouse
   can drag it. */
.seg-scroller {
    position: relative;
    min-width: 0;
    margin: 0 0 1.25rem;
}

/* Beats the area menus' own margin and min-width (.tx-seg.rc-menu-seg), so the arrows center on the track. */
.seg-scroller > .tx-seg.tx-seg {
    width: 100%;
    min-width: 0;
    margin: 0;
}

.seg-scroller.is-overflowing > .tx-seg {
    cursor: grab;
}

.seg-scroller.is-dragging > .tx-seg {
    cursor: grabbing;
    user-select: none;
    scroll-behavior: auto;
}

.seg-scroller.is-overflowing > .tx-seg .tx-seg-item {
    -webkit-user-drag: none;
}

.seg-scroller.can-next > .tx-seg {
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 72px), transparent calc(100% - 6px));
    mask-image: linear-gradient(to right, #000 calc(100% - 72px), transparent calc(100% - 6px));
}

.seg-scroller.can-prev > .tx-seg {
    -webkit-mask-image: linear-gradient(to right, transparent 6px, #000 72px);
    mask-image: linear-gradient(to right, transparent 6px, #000 72px);
}

.seg-scroller.can-prev.can-next > .tx-seg {
    -webkit-mask-image: linear-gradient(to right, transparent 6px, #000 72px, #000 calc(100% - 72px), transparent calc(100% - 6px));
    mask-image: linear-gradient(to right, transparent 6px, #000 72px, #000 calc(100% - 72px), transparent calc(100% - 6px));
}

.seg-scroll-btn {
    position: absolute;
    top: 50%;
    z-index: 3;
    display: none;
    place-items: center;
    width: 32px;
    height: 32px;
    padding: 0;
    border: 1px solid var(--tx-seg-pill-border);
    border-radius: 50%;
    background: var(--tx-seg-pill);
    color: var(--tx-seg-selected-text);
    box-shadow: 0 3px 12px var(--tx-seg-pill-shadow);
    transform: translateY(-50%);
    cursor: pointer;
    transition: transform .12s ease, filter .15s ease;
}

.seg-scroll-btn .tx-glyph {
    font-size: 12px;
}

.seg-scroll-btn:hover {
    filter: brightness(1.08);
}

.seg-scroll-btn:active {
    transform: translateY(-50%) scale(.94);
}

.seg-scroll-prev {
    left: 4px;
}

.seg-scroll-next {
    right: 4px;
}

.seg-scroller.can-prev > .seg-scroll-prev,
.seg-scroller.can-next > .seg-scroll-next {
    display: inline-grid;
}

.tx-seg.tx-seg-scroll .tx-seg-pill {
    width: max(var(--tx-seg-min), calc((100% - 8px) / var(--tx-seg-count, 3)));
}

.tx-seg.tx-seg-compact.tx-seg-scroll .tx-seg-pill {
    width: max(var(--tx-seg-min), calc((100% - 6px) / var(--tx-seg-count, 3)));
}

/* A glyph after the label (SegmentedMenuItem.TrailingGlyph): a chevron on a segment that opens a menu. It takes the
   label's color and turns up while the menu is open. */
.tx-seg .tx-seg-item .tx-glyph.tx-seg-item-trailing {
    font-size: 9px;
    color: inherit;
    opacity: .75;
    transition: transform .2s ease;
}

.tx-seg .tx-seg-item.tx-seg-expanded .tx-glyph.tx-seg-item-trailing {
    transform: rotate(180deg);
}

@media (prefers-reduced-motion: reduce) {
    .tx-seg-pill,
    .tx-seg .tx-seg-item .tx-glyph.tx-seg-item-trailing {
        transition: none;
    }
}

/*
    Where the segmented menu sits around the site (every segmented choice draws through the shared menu): the
    Investments and Enriched Investments detail tabs, the Enriched view and chart-type switchers, the Reports views.
    On a phone the wide inline menus become scrolling tracks so no label is cut.
*/
.tx-seg.admin-detail-seg {
    margin-bottom: 1rem;
}

.admin-detail-pane {
    min-width: 0;
}

.tx-seg.enriched-series-seg {
    width: min(100%, 540px);
}

@media (max-width: 575.98px) {
    .tx-seg.tx-seg-inline.enriched-view-seg,
    .tx-seg.tx-seg-inline.admin-reports-seg {
        display: grid;
        width: 100%;
        grid-auto-columns: minmax(120px, 1fr);
        overflow-x: auto;
        scrollbar-width: none;
    }

    .tx-seg.tx-seg-inline.enriched-view-seg::-webkit-scrollbar,
    .tx-seg.tx-seg-inline.admin-reports-seg::-webkit-scrollbar {
        display: none;
    }

    .tx-seg.tx-seg-inline.enriched-view-seg .tx-seg-pill,
    .tx-seg.tx-seg-inline.admin-reports-seg .tx-seg-pill {
        width: max(120px, calc((100% - 8px) / var(--tx-seg-count, 3)));
    }
}

/* ------------------------------------------------------------------ Icons */

.tx-icon-split {
    display: inline-block;
    width: 14px;
    height: 14px;
    fill: currentColor;
    flex: 0 0 auto;
}

/* The close "X" (PopupGlyphs.Close) is an inline SVG too: paint it in the button's text color, or it falls back to
   black and disappears on dark surfaces. */
.tx-icon-close {
    fill: currentColor;
    flex: 0 0 auto;
}

/* ------------------------------------------------------------------ Snackbar (in-popup toast) */

.tx-snackbar {
    position: absolute;
    left: 50%;
    bottom: 18px;
    z-index: 30;
    max-width: calc(100% - 32px);
    padding: 11px 18px;
    border-radius: 14px;
    background: #1F2233;
    color: #FFFFFF;
    font-family: var(--tx-font);
    font-size: 13.5px;
    line-height: 1.35;
    text-align: center;
    box-shadow: 0 10px 30px rgba(15, 23, 42, .28);
    transform: translate(-50%, 16px);
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s ease, transform .2s ease;
}

.tx-snackbar.tx-snackbar-visible {
    transform: translate(-50%, 0);
    opacity: 1;
}

[data-bs-theme="dark"] .tx-snackbar {
    background: #D9DBE8;
    color: #0B0F19;
}

/* The popup host's notice (a popup that can't open): the snackbar at the bottom of the window, over the page. */
.tx-host-notice {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 12px;
    height: 0;
    z-index: 1100;
    pointer-events: none;
}

/* ------------------------------------------------------------------ Confirmation (mobile ConfirmationPopup) */

.e-dialog.tx-confirm-dialog {
    border: 1px solid var(--tx-entry-border);
    border-radius: 20px;
    background: var(--tx-wrapper);
    box-shadow: var(--tx-dialog-shadow);
}

.e-dialog.tx-confirm-dialog .e-dlg-header-content {
    display: none;
}

.e-dialog.tx-confirm-dialog .e-dlg-content {
    padding: 20px;
    background: var(--tx-wrapper);
    color: var(--tx-text);
}

.tx-confirm {
    display: flex;
    flex-direction: column;
    gap: 16px;
    font-family: var(--tx-font);
}

.tx-confirm-title {
    margin: 0;
    font-weight: 700;
    font-size: 18px;
    text-align: center;
    color: var(--tx-text);
}

.tx-confirm-message {
    margin: 0;
    font-size: 14px;
    line-height: 1.45;
    text-align: center;
    color: var(--tx-text);
}

.tx-confirm-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.tx-confirm-actions .tx-btn {
    min-height: 38px;
    padding: 0 10px;
    font-family: var(--tx-font-text);
    font-weight: 400;
    text-transform: uppercase;
}

.tx-confirm-accept {
    background: var(--tx-confirm-accept);
    color: #FFFFFF;
}

.tx-confirm-accept.tx-confirm-critical {
    background: var(--tx-critical);
}

/* ------------------------------------------------------------------ Calendar overlay (the transaction date pickers) */

.e-dialog.tx-calendar-dialog {
    border: 1px solid var(--tx-entry-border);
    border-radius: 12px;
    background: var(--tx-page);
    box-shadow: var(--tx-dialog-shadow);
}

.e-dialog.tx-calendar-dialog .e-dlg-header-content {
    display: none;
}

.e-dialog.tx-calendar-dialog .e-dlg-content {
    padding: 10px;
    background: var(--tx-page);
}

.tx-calendar {
    display: flex;
    flex-direction: column;
    gap: 10px;
    font-family: var(--tx-font);
}

.tx-calendar-title {
    margin: 0;
    font-weight: 600;
    font-size: 14px;
    letter-spacing: .02em;
    text-transform: uppercase;
    color: var(--tx-text);
}

.tx-calendar .e-calendar {
    width: 100%;
    max-width: none;
    min-width: 0;
    border: 0;
    background: var(--tx-page);
}

.tx-calendar .e-calendar .e-content td.e-selected span.e-day {
    background: var(--tx-calendar-selection);
    color: var(--tx-calendar-selection-text);
}

.tx-calendar .e-calendar .e-content td.e-today span.e-day {
    border-color: var(--tx-primary);
    color: var(--tx-primary);
    font-weight: 700;
}

.tx-calendar .e-calendar .e-content td.e-today.e-selected span.e-day {
    color: var(--tx-calendar-selection-text);
}

.tx-calendar-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

/* ------------------------------------------------------------------ Date field (PopupDatePicker: the mobile DatePicker) */

.e-input-group.e-control-wrapper.e-date-wrapper.tx-date-picker {
    display: inline-flex;
    align-items: center;
    min-height: 36px;
    margin: 0;
    padding: 0 2px 0 12px;
    border: 1px solid var(--tx-tile-border);
    border-radius: 12px;
    background: var(--tx-input-bg);
    box-shadow: none;
    cursor: pointer;
}

.e-input-group.e-control-wrapper.e-date-wrapper.tx-date-picker.e-input-focus {
    border-color: var(--tx-primary);
    box-shadow: none;
}

.e-input-group.e-control-wrapper.e-date-wrapper.tx-date-picker input.e-input {
    min-height: 34px;
    padding: 0;
    border: 0;
    background: transparent;
    font-family: var(--tx-font-text);
    font-size: 14px;
    color: var(--tx-text);
    cursor: pointer;
}

.e-input-group.e-control-wrapper.e-date-wrapper.tx-date-picker .e-input-group-icon.e-date-icon {
    min-width: 0;
    min-height: 0;
    margin: 0;
    padding: 0 8px;
    border: 0;
    background: transparent;
    font-size: 14px;
    color: var(--tx-muted);
}

.e-input-group.e-control-wrapper.e-date-wrapper.tx-date-picker.e-disabled {
    opacity: .55;
    cursor: default;
}

.e-input-group.e-control-wrapper.e-date-wrapper.tx-date-picker.e-disabled input.e-input {
    cursor: default;
}

/* Its calendar, which the DatePicker renders on the page body: the popup surface and the calendar overlay's day colors. */
.e-datepicker.e-popup-wrapper.tx-date-picker {
    border: 1px solid var(--tx-entry-border);
    border-radius: 12px;
    background: var(--tx-page);
    box-shadow: var(--tx-dialog-shadow);
    overflow: hidden;
}

.e-datepicker.e-popup-wrapper.tx-date-picker .e-calendar {
    border: 0;
    background: var(--tx-page);
    font-family: var(--tx-font);
}

.e-datepicker.e-popup-wrapper.tx-date-picker .e-calendar .e-content td.e-selected span.e-day {
    background: var(--tx-calendar-selection);
    color: var(--tx-calendar-selection-text);
}

.e-datepicker.e-popup-wrapper.tx-date-picker .e-calendar .e-content td.e-today span.e-day {
    border-color: var(--tx-primary);
    color: var(--tx-primary);
    font-weight: 700;
}

.e-datepicker.e-popup-wrapper.tx-date-picker .e-calendar .e-content td.e-today.e-selected span.e-day {
    color: var(--tx-calendar-selection-text);
}

/* ------------------------------------------------------------------ Help sheet */

.e-dialog.tx-help-dialog {
    border: 0;
    border-radius: 20px;
    background: var(--tx-page);
    box-shadow: var(--tx-dialog-shadow);
    max-height: calc(100dvh - 2rem);
}

.e-dialog.tx-help-dialog .e-dlg-header-content {
    display: none;
}

.e-dialog.tx-help-dialog .e-dlg-content {
    padding: 0;
    background: var(--tx-page);
    color: var(--tx-text);
}

.tx-help {
    display: flex;
    flex-direction: column;
    max-height: calc(100dvh - 2rem);
    font-family: var(--tx-font);
}

.tx-help-head {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 18px 18px 12px;
    border-bottom: 1px solid var(--tx-border);
}

.tx-help-head-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 11px;
    background: var(--tx-nr-header-icon-bg);
    color: var(--tx-nr-header-icon);
    font-size: 15px;
}

.tx-help-title {
    margin: 0;
    font-weight: 600;
    font-size: 16px;
    color: var(--tx-text);
}

.tx-help-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 17px;
    background: var(--tx-surface);
    color: var(--tx-text);
    cursor: pointer;
}

.tx-help-body {
    display: flex;
    flex-direction: column;
    gap: 14px;
    padding: 14px 18px 20px;
    overflow-y: auto;
}

.tx-help-summary {
    margin: 0;
    font-size: 13.5px;
    line-height: 1.5;
    color: var(--tx-muted);
}

.tx-help-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px;
    background: var(--tx-surface);
    border-radius: 18px;
}

.tx-help-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    font-weight: 600;
    font-size: 14px;
    color: var(--tx-text);
}

.tx-help-section-title .tx-glyph {
    color: var(--tx-primary);
    font-size: 13px;
}

.tx-help-text {
    margin: 0;
    font-size: 13px;
    line-height: 1.5;
    color: var(--tx-text);
}

.tx-help-points {
    display: flex;
    flex-direction: column;
    gap: 9px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.tx-help-point {
    display: grid;
    grid-template-columns: 22px minmax(0, 1fr);
    gap: 8px;
    font-size: 13px;
    line-height: 1.45;
}

.tx-help-point .tx-glyph {
    margin-top: 3px;
    color: var(--tx-primary);
    font-size: 12px;
}

.tx-help-point-lead {
    font-weight: 600;
    color: var(--tx-text);
}

.tx-help-point-text {
    color: var(--tx-muted);
}

.tx-help-point-link {
    padding: 0;
    border: 0;
    background: transparent;
    font: inherit;
    font-weight: 600;
    color: var(--tx-primary);
    cursor: pointer;
    text-align: left;
}

.tx-help-steps {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin: 0;
    padding-left: 20px;
    font-size: 13px;
    line-height: 1.45;
    color: var(--tx-text);
}

.tx-help-callout {
    margin: 0;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 12.5px;
    line-height: 1.45;
    background: var(--tx-nr-info-soft);
    color: var(--tx-text);
}

.tx-help-callout-important {
    background: var(--tx-caution-soft);
}

.tx-help-callout-privacy {
    background: var(--tx-owner-partner-tint);
}

.tx-help-callout-label {
    font-weight: 600;
    margin-right: 4px;
}

.tx-help-learn-more {
    align-self: flex-start;
}

/* ------------------------------------------------------------------ Switch (ThumbOn / ThumbOff) */

.tx-switch.e-switch-wrapper .e-switch-inner.e-switch-active,
.tx-switch.e-switch-wrapper:hover .e-switch-inner.e-switch-active {
    border-color: var(--tx-thumb-on);
    background-color: var(--tx-thumb-on);
}

.tx-switch.e-switch-wrapper .e-switch-inner:not(.e-switch-active) {
    border-color: var(--tx-thumb-off);
    background-color: var(--tx-thumb-off);
}

.tx-switch.e-switch-wrapper .e-switch-handle {
    background-color: #FFFFFF;
}

.tx-switch.e-switch-wrapper .e-switch-handle.e-switch-active {
    background-color: var(--tx-thumb);
}

[data-bs-theme="dark"] .tx-switch.e-switch-wrapper .e-switch-handle.e-switch-active {
    background-color: #0B0F19;
}

/* ------------------------------------------------------------------ Check box (the recurring name option) */

.tx-check {
    display: grid;
    grid-template-columns: auto auto minmax(0, 1fr);
    align-items: start;
    column-gap: 8px;
    padding: 4px 0 0 2px;
    border: 0;
    background: transparent;
    text-align: left;
    color: inherit;
    cursor: pointer;
}

.tx-check-box {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border: 1.5px solid var(--tx-tile-border);
    border-radius: 6px;
    background: transparent;
    color: #FFFFFF;
    font-size: 10px;
}

.tx-check.tx-check-on .tx-check-box {
    border-color: var(--tx-primary);
    background: var(--tx-primary);
}

.tx-check-glyph {
    margin-top: 3px;
    font-size: 12px;
    color: var(--tx-primary);
}

.tx-check-text {
    font-family: var(--tx-font-text);
    font-size: 12.5px;
    line-height: 1.4;
    color: var(--tx-text);
}

/* ------------------------------------------------------------------ Skeleton (SfShimmer: SkeletonBone + SkeletonWave) */

.tx-root .e-skeleton,
.tx-skeleton.e-skeleton {
    background-color: var(--tx-skeleton-bone);
}

.tx-root .e-skeleton.e-shimmer-wave::after,
.tx-skeleton.e-skeleton.e-shimmer-wave::after {
    background-image: linear-gradient(90deg, transparent calc(50% - 75px), var(--tx-skeleton-wave) 50%, transparent calc(50% + 75px));
}

.tx-skeleton-block {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* ------------------------------------------------------------------ Busy bar (the header's linear indicator) */

.tx-busy-bar {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    z-index: 40;
    height: 2px;
    overflow: hidden;
    pointer-events: none;
}

.tx-busy-bar::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: -40%;
    width: 40%;
    background: var(--tx-primary);
    animation: tx-busy 1.1s ease-in-out infinite;
}

@keyframes tx-busy {
    0% { left: -40%; }
    100% { left: 100%; }
}

@media (prefers-reduced-motion: reduce) {
    .tx-busy-bar::before {
        animation-duration: 2.4s;
    }
}

/* ------------------------------------------------------------------ Lit rings (gradient hairlines)

   A 1px hairline drawn with a gradient that fades round the edge (mobile Border.Stroke brushes). CSS borders can't take a
   gradient over a translucent fill, so the ring is a masked ::before: the gradient fills the box and the mask cuts the
   inside out, leaving 1px. Each owner sets --tx-ring to its stroke and is a positioned box. */

.tx-glance-tile:not(.rts-tile)::before,
.txp-tile::before,
.txp-summary .tx-seg.txp-direction::before,
.txp-summary .txp-type-menu::before,
.rse-menu > .tx-seg::before,
.ntf-menu > .tx-seg::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
    padding: 1px;
    border-radius: inherit;
    background: var(--tx-ring, var(--tx-tile-stroke));
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
    pointer-events: none;
}

/* ------------------------------------------------------------------ Switch tracks (mobile TxFlowSwitch*)

   The transaction popup's Expense / Income / Other switch and its type menu, the recurring editor's Insights / Details /
   Charges menu and the Notifications menu share one track: dark = a recessed well the raised pill pops out of, light =
   a white track lifted by a soft shadow; both carry the accent hairline lit from the top-left. The pill is unchanged. */

.txp-summary .tx-seg.txp-direction,
.rse-menu > .tx-seg,
.ntf-menu > .tx-seg {
    --tx-ring: var(--tx-switch-stroke);
    background: var(--tx-switch-track);
    box-shadow: var(--tx-switch-shadow);
}

.txp-summary .txp-type-menu {
    --tx-ring: var(--tx-switch-stroke);
    border-color: transparent;
    background: var(--tx-switch-track);
}

/* The menu keeps its 1px (now clear) border for layout: its ring sits on that border. */
.txp-summary .txp-type-menu::before {
    inset: -1px;
}

[data-bs-theme="dark"] .txp-summary .txp-type-menu {
    /* The dark well is translucent: paint it over the page so the summary card doesn't show through the dropdown. */
    background: var(--tx-switch-track), var(--tx-page);
}
