/* Extracted from ecosystem.css — Deals workspace chrome + new-deal form. */
/* Keep in sync with index.html stack order (after ecosystem.css, before platform). */

 /* Deals workspace : one compact command line, one navigation line. */
 #deals-command-bar {
        display:flex; gap:6px; align-items:center; margin:0 0 5px; min-width:0;
    }
 /* Deals chrome is view-scoped. This specificity intentionally beats mobile
 layout declarations that use #filters/#deal-bar with !important. */
    body:not([data-view="deals"]) #deals-command-bar,
    body:not([data-view="deals"]) #deal-bar,
 #filters.is-hidden, #new-wrap.is-hidden, #deal-bar.is-hidden {
        display:none !important;
    }
 #new-wrap { flex:0 0 auto; margin:0 !important; }
 #filters { display:flex; gap:5px; align-items:center; flex:1 1 auto; min-width:0; margin:0 !important; }
 #filters #f-period { flex:0 0 auto; min-width:118px; }
 #filters #f-q { flex:1 1 240px; min-width:120px; }
 #deal-bar {
        min-width:0; flex-wrap:nowrap !important; padding:2px 0 4px;
        border-bottom:1px solid rgba(127,127,127,.12);
    }
 #f-seg, #f-view {
        flex-wrap:wrap; overflow-x:visible; scrollbar-width:none; -webkit-overflow-scrolling:touch;
    }
 #f-seg::-webkit-scrollbar, #f-view::-webkit-scrollbar { display:none; }
 #f-seg .rk, #f-view .rk { flex:0 0 auto; min-height:44px; padding:6px 10px; font-size:12px; white-space:nowrap; }
 #f-view .help-q { width:44px; min-width:44px; }
    body.pro #deals-cards.list { grid-template-columns:1fr; gap:4px; }

 /* Deal form: light sectioned workspace, not a wall of form rows. */
 #deal-form-modal #form { max-width:920px; }
 #deal-form-modal #form {
        border:1px solid rgba(127,127,127,.18); border-radius:16px; padding:8px;
        background:linear-gradient(145deg, rgba(255,255,255,.52), rgba(127,127,127,.045));
        box-shadow:0 12px 34px -30px rgba(0,0,0,.7);
    }
    .nf-head {
        display:flex; align-items:center; justify-content:space-between; gap:8px;
        min-height:34px; padding:0 3px 7px;
    }
    .nf-head > div:first-child { display:flex; align-items:baseline; gap:8px; }
    .nf-head b { font-size:15px; }
    .nf-head span { color:var(--tg-theme-hint-color,#777); font-size:11px; }
    .nf-head-actions { display:flex; align-items:center; gap:4px; }
    .nf-section {
        margin-bottom:8px; padding:10px 12px; border-radius:14px;
        border:1px solid color-mix(in srgb, var(--tg-theme-hint-color,#708090) 24%, transparent);
        background:var(--tg-theme-bg-color,#fff);
        box-shadow:0 1px 2px rgba(18,31,53,.04);
    }
    html[data-theme="dark"] .nf-section,
    .overlay[data-theme="dark"] .nf-section {
        background:var(--tg-theme-secondary-bg-color,#2b3949);
        border-color:rgba(255,255,255,.12);
        box-shadow:0 6px 18px rgba(0,0,0,.18);
    }
    .nf-section-title {
        margin:0 0 6px; color:var(--ui-muted-strong, var(--tg-theme-hint-color,#555));
        font-size:12px; font-weight:650; letter-spacing:.01em; text-transform:none;
    }
    .nf-pivot-row { margin-top:4px; }
    .nf-segment { display:grid; grid-auto-flow:column; grid-auto-columns:1fr; gap:3px; }
    .nf-segment .rk { min-height:32px; padding:4px 7px; font-size:12px; }
    .nf-assets-grid {
        grid-template-columns:minmax(0,1fr) minmax(0,1fr) !important;
        min-width:0; max-width:100%; width:100%; box-sizing:border-box;
    }
    .nf-route-help { margin:5px 1px 0; white-space:normal; overflow:visible; }
    .nf-adv-toggle {
        width:100%; display:flex; justify-content:space-between; align-items:center;
        margin:0 0 6px; min-height:34px; padding:5px 9px; text-align:left;
        color:inherit; background:rgba(127,127,127,.055);
    }
    .nf-section-advanced { margin-bottom:6px; }
    .nf-preview-bar {
        border-radius:10px; border:1px solid rgba(51,144,236,.16);
        background:rgba(51,144,236,.06);
    }
 #nf-preview.is-ready { color:inherit; }
    .nf-draft-link {
        background: transparent;
        border: none;
        box-shadow: none;
        text-decoration: underline;
        text-underline-offset: 3px;
        font-weight: 650;
        min-height: 40px;
    }
    .nf-actions-sticky {
        display:flex; align-items:center; justify-content:space-between; gap:12px;
        padding:7px 2px 1px; margin-top:4px; border-top:1px solid rgba(127,127,127,.12);
        background:var(--tg-theme-bg-color,#fff);
    }
    .nf-actions-sticky .ui-actions { flex:0 1 auto; margin:0; }
    .nf-actions-copy { display:flex; flex-direction:column; min-width:150px; }
    .nf-actions-copy b { font-size:12px; color:var(--neg,#d11); }
    .nf-actions-copy b.is-ready { color:var(--pos,#1a8d3e); }
    .nf-actions-copy span { font-size:10px; color:var(--tg-theme-hint-color,#777); }
    html[data-theme="dark"] .nf-actions-copy b,
    .overlay[data-theme="dark"] .nf-actions-copy b { color:var(--neg,#ff5b5b); }
    html[data-theme="dark"] .nf-actions-copy b.is-ready,
    .overlay[data-theme="dark"] .nf-actions-copy b.is-ready { color:var(--pos,#4cd964); }
    html[data-theme="dark"] .nf-actions-sticky,
    .overlay[data-theme="dark"] .nf-actions-sticky {
        background:var(--tg-theme-secondary-bg-color,#2b3949);
        border-top-color:rgba(255,255,255,.12);
    }
 #deal-form-modal #form input:disabled, #deal-form-modal #form select:disabled, #deal-card input:disabled, #deal-card select:disabled {
        opacity:.78; cursor:default; background:rgba(127,127,127,.055);
    }

 /* Explicit view → edit → save model for deal cards. */
 #deal-card .dc-editbar {
        display:flex; justify-content:space-between; align-items:center; gap:8px;
        margin:3px 0 7px; padding:5px 7px; border-radius:9px;
        background:rgba(127,127,127,.055); border:1px solid rgba(127,127,127,.10);
    }
 #deal-card .dc-editbar .fin { margin:0; }
 #deal-card .dc-editbar .fbtns { margin:0; flex:0 0 auto; }
 #deal-card .dc-editbar .fbtns button { min-height:28px; padding:4px 8px; font-size:12px; }
 #deal-card .dc-editbar.is-editing { border-color:rgba(51,144,236,.26); background:rgba(51,144,236,.07); }
 #deal-card .dc-fld.ok { border-color:rgba(26,141,62,.5); }
 #deal-card .dc-fld.err { border-color:var(--neg,#d11); }

 /* Modal containment: no body scroll, safe mobile sheet, sticky controls. */
    body.modal-open { overflow:hidden; }
    .overlay { overflow:hidden; overscroll-behavior:contain; }
    .modal { max-height:calc(100dvh - 24px); overflow:auto; overscroll-behavior:contain; }
    .modal-head {
        position:sticky; top:-14px; z-index:8; margin:-14px -14px 8px; padding:10px 14px 8px;
        background:var(--tg-theme-bg-color,#fff);
        background:color-mix(in srgb, var(--tg-theme-bg-color,#fff) 94%, transparent);
        border-bottom:1px solid rgba(127,127,127,.10); backdrop-filter:blur(14px);
        -webkit-backdrop-filter:blur(14px);
    }

    .pager-range { margin:0 6px !important; display:inline-block; }
    .pager-label { margin-left:8px !important; }
    .pager-size { max-width:6ch; margin-left:4px; }

 /* .nf-section dark surface — see block above (card-like wells). */
    html[data-theme="dark"] #deal-form-modal #form,
    .overlay[data-theme="dark"] #deal-form-modal #form {
        background:var(--tg-theme-secondary-bg-color,#1c2733);
    }
    html[data-theme="dark"] .modal-head,
    .overlay[data-theme="dark"] .modal-head {
        background:var(--tg-theme-bg-color,#1a2330);
        backdrop-filter:none; -webkit-backdrop-filter:none;
    }
    html[data-theme="dark"] .nf-actions-sticky,
    .overlay[data-theme="dark"] .nf-actions-sticky {
        background:var(--tg-theme-secondary-bg-color,#2b3949);
    }


/* Extracted from ecosystem.css — Deals registry table/stack mode. */
 /* Deals registry (▥): dense table mode with quick filters, frozen first 3 columns and zebra rows. */
 #deals-cards.registry-mode { width:100%; display:block; }
 body.pro #deals-cards.registry-mode { display:block; } /* override Pro card-grid layout */
    .reg-top { margin-bottom:8px; }
    .reg-top-row { margin-bottom:4px; }
    .reg-qf, .reg-hist { display:flex; gap:6px; flex-wrap:wrap; margin-bottom:4px; }
    .reg-meta { margin-top:2px; }
    .reg-qf .rk { min-height:34px; padding:6px 10px; font-size:13px; }
 #grid.deals-registry > thead > tr > th,
 #grid.deals-registry > tbody > tr > td {
        padding:4px 7px; font-size:11.5px; line-height:1.28;
    }
 #grid.deals-registry > thead > tr > th {
        font-size:10.5px; letter-spacing:.01em; font-weight:630;
    }
 #grid.deals-registry > tbody > tr > td { color:var(--tg-theme-text-color,#1f2328); }
 #grid.deals-registry .reg-cut { overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
 #grid.deals-registry .reg-num { text-align:right; }
 #grid.deals-registry .reg-center { text-align:center; }
 #grid.deals-registry .reg-tiny { font-size:10.5px; }
 #grid.deals-registry td.reg-col-number { font-weight:600; }
 #grid.deals-registry > tbody > tr:nth-child(even) > td { background: rgba(127,127,127,.08); }
 #grid.deals-registry > tbody > tr:nth-child(even) > td.reg-freeze { background: rgba(127,127,127,.12); }
 #grid.deals-registry > tbody > tr:hover > td { background: rgba(51,144,236,.10); }
 #grid.deals-registry > tbody > tr:hover > td.reg-freeze { background: rgba(51,144,236,.15); }
 #grid.deals-registry mark { background:#ffd54f99; color:inherit; border-radius:3px; padding:0 2px; }
 /* disable generic first-column freeze; registry freezes 3 explicit columns below */
 #grid.deals-registry td:first-child, #grid.deals-registry th:first-child { left:auto; }
 #grid.deals-registry .reg-freeze {
        position:sticky; z-index:2; background:var(--tg-theme-bg-color,#fff);
        overflow:hidden; text-overflow:ellipsis; box-sizing:border-box;
    }
 #grid.deals-registry > thead > tr > th.reg-freeze {
        z-index:4; background:var(--tg-theme-secondary-bg-color,#f2f2f2);
    }
    .reg-colpick-wrap { max-height:52vh; overflow:auto; margin-top:6px;
        border:1px solid var(--tg-theme-hint-color,#ddd); border-radius:8px; padding:2px 10px; }
    .reg-colpick { margin-bottom:2px; }
    .reg-colpick input { width:auto; }
    .reg-colpick .reg-ecol-wrap { flex:0 0 auto; }
    .reg-colpick.reg-colpick-linked .reg-ecol-wrap { display:none; }
    .reg-layout-row { display:flex; gap:4px; margin:4px 0; flex-wrap:wrap; }
    .reg-stack { display:flex; flex-direction:column; gap:8px; margin-top:8px; }
    .reg-stack-card {
        border:1px solid var(--tg-theme-hint-color,#e0e0e0); border-radius:10px;
        padding:10px 12px; cursor:pointer; background:var(--tg-theme-bg-color,#fff);
    }
    .reg-stack-card:active { background:var(--tg-theme-secondary-bg-color,#f3f3f3); }
    .reg-stack-head { font-weight:600; font-size:14px; margin-bottom:4px; line-height:1.35; }
    .reg-stack-sub { font-size:13px; opacity:.85; margin-bottom:4px; line-height:1.35; word-break:break-word; }
    .reg-stack-tags { display:flex; flex-wrap:wrap; gap:4px 8px; font-size:12px; }
    .reg-stack-tag { background:var(--tg-theme-secondary-bg-color,#f2f2f2); border-radius:6px; padding:2px 6px; }
    .reg-top { margin-bottom:6px; }
 #reg-top-host { margin-bottom:4px; }
    .reg-bar { display:flex; gap:6px; align-items:center; flex-wrap:wrap; }
    .reg-preset-sel { flex:1; min-width:110px; max-width:200px; min-height:36px; }
    .reg-seg { display:flex; gap:0; border-radius:9px; overflow:hidden; }
    .reg-seg .rk { border-radius:0; min-height:36px; padding:6px 10px; font-size:13px; }
    .reg-bar-actions { display:flex; gap:4px; flex-wrap:wrap; margin-left:auto; }
    .reg-bar-actions .rk { min-height:36px; padding:6px 10px; font-size:14px; }
    body.pro .reg-seg .rk, body.pro .reg-bar-actions .rk {
        min-height:30px; padding:4px 8px; font-size:12px;
    }
 /* chips stay on ONE line and scroll sideways — no 3-row stack on a phone */
    .reg-chips { display:flex; gap:4px; flex-wrap:nowrap; overflow-x:auto;
        -webkit-overflow-scrolling:touch; margin-top:6px; align-items:center;
        padding-bottom:2px; scrollbar-width:none; }
    .reg-chips::-webkit-scrollbar { display:none; }
    .reg-chip { flex:0 0 auto; min-height:32px; padding:5px 9px; font-size:12px; border-radius:16px; white-space:nowrap; }
    .reg-chip.active { background:var(--tg-theme-button-color,#3390ec); color:var(--tg-theme-button-text-color,#fff); }
    .reg-clear-f { flex:0 0 auto; font-size:12px; opacity:.75; min-height:32px; padding:5px 8px; white-space:nowrap; }
    body.pro .reg-chip, body.pro .reg-clear-f { min-height:28px; padding:4px 8px; font-size:11px; }
    .reg-hist { display:flex; gap:4px; flex-wrap:wrap; margin-top:6px; }
    .reg-empty-note {
        margin-top:6px; padding:7px 10px; border-radius:8px;
        background:var(--tg-theme-secondary-bg-color,#f2f2f2);
        font-size:12px; color:var(--tg-theme-hint-color,#666);
        white-space:normal; line-height:1.35;
    }
 /* filters modal: aligned 3-column grid (name | on | pin) */
    .reg-fpick { display:grid; grid-template-columns:1fr 44px 56px; align-items:center;
        gap:6px; min-height:40px; border-bottom:1px solid var(--tg-theme-hint-color,#eee); }
    .reg-fpick:last-child { border-bottom:none; }
    .reg-fpick-head { min-height:28px; font-size:12px; opacity:.7; border-bottom:none;
        margin-top:6px; padding:0 12px; }
    .reg-fpick-head .reg-fpick-cb { text-align:center; }
    .reg-fpick-name { line-height:1.3; }
    .reg-fpick-kind { display:block; font-size:11px; color:var(--ui-muted, var(--tg-theme-hint-color,#5a6573)); }
    .reg-fpick-cb { display:flex; justify-content:center; }
    .reg-fpick-cb input { width:20px; height:20px; margin:0; }
    .reg-fpick-wrap { padding:2px 12px; }
    body.registry-fullscreen #hdr,
    body.registry-fullscreen #tabs,
    body.registry-fullscreen #dash,
    body.registry-fullscreen #filters,
    body.registry-fullscreen #deal-bar,
    body.registry-fullscreen #new-wrap,
    body.registry-fullscreen #lite-back,
    body.registry-fullscreen #bulk-bar { display:none !important; }
    body.registry-fullscreen #grid-wrap { margin:0; max-width:none; }
    body.registry-fullscreen #deals-cards.registry-mode { padding:8px 10px 16px; }
    body.registry-fullscreen #reg-top-host { position:sticky; top:0; z-index:5;
        background:var(--tg-theme-bg-color,#fff); padding:8px 10px 6px;
        border-bottom:1px solid var(--tg-theme-hint-color,#e8e8e8); }
    .reg-stack-grid {
        display:grid; grid-template-columns:minmax(110px, 38%) 1fr; gap:3px 10px;
        font-size:13px; line-height:1.4;
    }
    .reg-sk { color:var(--tg-theme-hint-color,#777); }
    .reg-sv { word-break:break-word; overflow-wrap:anywhere; }
    body.registry-stack-mode #grid-wrap .wrap,
    body.registry-stack-mode #grid-wrap { overflow-x:visible; }
    .pager-row.pager-bottom { margin-top:10px; }
    .deals-pager-strip {
        display:flex; align-items:center; gap:6px; flex-wrap:nowrap; overflow-x:auto;
        margin:0 0 8px; padding:4px 7px; border-radius:9px;
        background:var(--tg-theme-secondary-bg-color,#f1f4f8);
        border:1px solid var(--tg-theme-hint-color,#dde3ea);
    }
    .deals-pager-strip::-webkit-scrollbar { display:none; }
    .deals-pager-strip .fin { margin:0; white-space:nowrap; }
    .deals-pager-strip .rk { min-height:24px; padding:2px 7px; font-size:11px; }
    .deals-pager-strip .cm { min-height:24px; font-size:11px; }
 #deals-cards .deals-pager-strip { grid-column:1 / -1; }
    .deals-ctx {
        font-size:11px; color:var(--ui-muted-strong, #3f4b5a);
        align-self:center; margin-left:6px;
        white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:260px;
    }



/* Extracted from ecosystem.css — deal form/bar leftovers. */
#deal-form-modal .modal-head { display: none; }
#deal-form-modal .modal {
  max-width: min(1200px, calc(100vw - 16px));
  width: 100%;
  box-sizing: border-box;
  max-height: calc(100dvh - 24px);
  overflow-y: auto;
}
#deal-form-modal #form {
  display: block !important;
  margin: 0;
  max-width: none;
}

.dc-cap-btn { font-weight: 400; }
.dc-reqs-block {
  margin-top: 12px;
  padding-top: 8px;
  border-top: 1px dashed var(--tg-theme-hint-color, #bbb);
}
.dc-reqs-title { margin-bottom: 4px; }
.dc-reqs-hint { margin-bottom: 6px; }
.dc-debt-native { opacity: .75; }

.deal-bar-row {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-bottom: 6px;
  flex-wrap: wrap;
}
.deal-bar-seg {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.deal-bar-view {
  display: flex;
  gap: 4px;
  margin-left: auto;
}

#form.ecosystem-form.nf-deal-form .nf-segment {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 4px;
}
#form.ecosystem-form.nf-deal-form .nf-segment-modes {
  display: flex;
  flex-wrap: nowrap;
  width: 100%;
}

/* registry empty / colpick leftover */
#reg-top-host .workspace-empty,
.registry-mode .workspace-empty {
  margin: 8px 0 4px;
}

.reg-colpick-label { flex: 1; min-width: 0; }

    @media (max-width:760px) {
 #deals-command-bar { align-items:stretch; }
 #new-wrap #new-btn { min-height:40px; padding:7px 10px; }
 #filters { display:grid !important; grid-template-columns:auto minmax(0,1fr); }
 #filters #f-period { min-width:104px; width:104px; }
 #filters #f-q { min-width:0; width:100%; }
 #deal-bar { display:block !important; }
 #f-seg, #f-view {
            flex-wrap:nowrap; overflow-x:auto; max-width:100%;
            margin-bottom:4px; padding-bottom:1px;
        }
 #f-view { margin-left:0 !important; }
        .deals-ctx { display:none; }
        .reg-bar {
            display:grid; grid-template-columns:minmax(0,1fr); max-width:100%;
            overflow:visible;
        }
        .reg-preset-sel { width:100%; min-width:0; }
        .reg-bar-actions {
            display:grid; grid-template-columns:repeat(2,minmax(0,1fr));
            width:100%; margin-left:0;
        }
        .reg-bar-actions .rk {
            min-width:0; white-space:normal; min-height:36px; font-size:12px; padding:5px 7px;
        }
        .reg-top, #reg-top-host, .reg-chips { max-width:100%; min-width:0; }
        .reg-chips { flex-wrap:wrap; overflow:visible; }
        .nf-assets-grid { grid-template-columns:minmax(0,1fr) !important; }
 #deal-form-modal #form { margin-left:-2px; margin-right:-2px; padding:7px; border-radius:14px; }
 #deal-form-modal #form,
 #deal-form-modal #form .nf-section,
 #deal-form-modal #form .nf-assets-grid,
 #deal-form-modal #form .ecosystem-field-row,
 #deal-form-modal #form input,
 #deal-form-modal #form select {
            min-width:0; max-width:100%; box-sizing:border-box;
        }
        .nf-section { padding:7px; }
        .nf-actions-sticky {
            bottom:calc(74px + env(safe-area-inset-bottom)); align-items:stretch;
            margin:4px -7px -7px; padding:7px;
        }
        #deal-form-modal .nf-preview-bar { pointer-events:none; position:relative; z-index:1; }
        #deal-form-modal .nf-actions-sticky {
            position:fixed; left:8px; right:8px;
            bottom:env(safe-area-inset-bottom, 0px);
            margin:0; padding:8px;
            z-index:12;
            pointer-events:auto;
        }
        #deal-form-modal #form {
            padding-bottom:calc(var(--nf-sticky-h, 118px) + 16px);
            scroll-padding-bottom:calc(var(--nf-sticky-h, 118px) + 16px);
        }
        #deal-form-modal #nf-incoming_amount {
            scroll-margin-bottom:calc(var(--nf-sticky-h, 118px) + 16px);
        }
        .nf-actions-copy { display:none; }
        .nf-actions-sticky .ui-actions { width:100%; }
        .overlay { padding:0; align-items:flex-end; }
        .modal {
            width:100%; max-width:100%; min-width:0; max-height:calc(100dvh - 8px);
            margin:0; border-radius:18px 18px 0 0; padding:12px;
            box-sizing:border-box;
        }
        body.pro .overlay .modal { width:100%; max-width:100%; min-width:0; }
        .modal-head { top:-12px; margin:-12px -12px 8px; padding:10px 12px 8px; }
        body.pro #deal-card .modal, body.pro #ref-card .modal { min-width:0; max-width:100%; }
        body.pro #refs-list, body.pro #refs-list.refs-view-edit { grid-template-columns:1fr; }
        .ref-bar2 {
            grid-template-columns:minmax(0,1fr) auto;
            grid-template-areas:"filter filter" "help views" "create create";
            gap:4px;
        }
        .ref-bar2 #ref-filter { grid-area:filter; min-width:0; width:100%; }
        .ref-bar2 .help-q { grid-area:help; }
        .ref-bar2 #ref-view { grid-area:views; justify-self:end; }
        .ref-bar2 .ref-create { grid-area:create; justify-self:end; }
        .ref-view-toggle .rv { padding:4px 7px; }
        #ref-view.ref-view-toggle .rv span { display:none; }
        .ref-create > summary { padding:5px 8px; }
        .ref-create > summary span { display:none; }
        .ref-create-popover {
            position:fixed; left:8px; right:8px; top:auto;
            bottom:calc(70px + env(safe-area-inset-bottom)); width:auto; max-width:none;
            grid-template-columns:minmax(0,1fr) auto;
            box-shadow:0 18px 48px rgba(0,0,0,.28);
        }
        .ref-context { margin-bottom:4px; }
 #ref-card .ref-kpi-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
 #ref-card .ref-card-layout { grid-template-columns:1fr; gap:6px; }
 #ref-card .ref-card-col { gap:6px; }
 #ref-card .ref-primary-actions { position:sticky; top:37px; z-index:6; padding:4px 0; background:var(--tg-theme-bg-color,#fff); }
 #ref-card .ref-wallet-add, #ref-card .ref-payer-add { grid-template-columns:1fr auto; }
 #ref-card .ref-wallet-add #cw-label, #ref-card .ref-payer-add #rc-pc-req { grid-column:1 / -1; grid-row:2; }
 #ref-card .pc-row { align-items:stretch; flex-direction:column; }
 #ref-card .pc-fields { grid-template-columns:1fr; width:100%; }
 #ref-card .pc-actions { width:100%; }
 #ref-card .pc-actions button { flex:1; }
        .notes-add { grid-template-columns:1fr; }
        .notes-roles { grid-column:1; }
        .notes-save { grid-column:1; grid-row:auto; width:100%; }
 #deal-card .dc-editbar { align-items:flex-start; }
 #deal-card .dc-editbar > .fin { display:none; }
 #deal-card .dc-editbar .fbtns { width:100%; }
        .deals-pager-strip { justify-content:space-between; gap:3px; }
        .deals-pager-strip .pager-label { display:none; }
    }

 #litedeal-card .modal { width:min(96%, 560px); }
    .ld-section { margin-bottom:7px; }
    .ld-segment { display:grid; grid-template-columns:1fr 1fr; gap:4px; }
    .ld-segment .rk { min-height:40px; white-space:normal; }
    .ld-grid { display:grid; grid-template-columns:1fr 1fr; gap:7px; }
    .ld-preview { min-height:38px; padding:8px 10px; box-sizing:border-box; font-size:12px; }
    .ld-actions { margin-top:7px; }
    .ld-actions .ui-action { min-height:42px; }

    @media (max-width:520px) {
 #litedeal-card .modal { width:100%; }
        .ld-grid { grid-template-columns:1fr; gap:6px; }
        body.lite .dash-fin-hero { min-height:78px; padding:10px 12px; }
        body.lite .dash-fin-value { font-size:24px; }
        body.lite .dash-fin-caption { font-size:11px; }
        body.lite .dash-fin-row { min-height:36px; padding:6px 5px; font-size:12px; }
    }

    @media (max-width:760px) {
        body.pro #pf-members-modal .modal,
        body.pro #pf-billing-modal .modal,
        body.pro #pf-quotas-modal .modal,
        body.pro #pf-modules-modal .modal {
            width:calc(100vw - 16px); max-width:calc(100vw - 16px); min-width:0;
        }
        body.lite #platform-bar .rk,
        body.lite #platform-bar .collap-h,
        body.lite [id^="pf-"] .rk { min-height:44px; }
 #platform-bar .pf-help-row { align-items:center; }
 #platform-bar .pf-freshness { order:3; flex:1 1 100%; margin-left:0; }
    }

/* Deal cards / #deal-card modal / feed → ecosystem_deals_cards.css. */
