/* ==========================================================================================
   Dandelion CRM on the phone - sales (the 2026-10-21 round, the owner's page-by-page review).
   Leads + the lead / deal record, Cold calling, Contacts. Rules only inside @media (max-width:
   900px), scoped html.ui-2026 body:not(#dn26) (see core.css); the desktop never matches.
   Items: 17 the record fills the screen · 18 Cold calling's filters behind the round filter
   button, Statistics a round button, the management buttons and the overview bar gone · 23
   Contacts' four filters behind the filter button · 35 Call / WhatsApp as round icon buttons
   in the list cards, "Open" buttons gone (the card opens the record). The JS half is
   assets/js/mobile/sales.js.
   ========================================================================================== */
@media (max-width: 900px){
  /* ======================================================================== 17. the record (lead / deal) fills the screen
     ui-2026.css line ~4891 sizes the desktop record drawer calc(100vw - 60px) with a `:not(#dn27)` selector and no media
     query, so on the phone the record was a 330px panel with a 60px strip of the page showing (owner: «تمام صفحه»). The
     third :not(#id) outranks it, the house trick of ui-2026.css itself. */
  html.ui-2026 body:not(#dn26):not(#dn27):not(#dn28) #lead-modal-overlay > #lead-modal{
    width: 100vw !important; max-width: none !important;
    height: var(--app-vh, 100dvh) !important; max-height: none !important;   /* --app-vh: the keyboard-aware height of app.js */
    margin: 0 !important; border: 0 !important; border-radius: 0 !important; box-shadow: none !important;
    transform-origin: center !important; backface-visibility: visible;
    animation: dnmRecordIn .22s ease both !important;                        /* ui.css: the 3D "door" (enterprisePageOpen) */
  }
  html.ui-2026 body:not(#dn26):not(#dn27):not(#dn28) #lead-modal-overlay > #lead-modal.closing{ animation: none !important; }
  html.ui-2026 body:not(#dn26) #lead-modal-overlay{
    padding: 0 !important; inset: 0 !important; perspective: none !important; animation: none !important;
    -webkit-backdrop-filter: none !important; backdrop-filter: none !important;                 /* no glass (item 4) */
    background: var(--surface) !important;                                                        /* nothing of the page shows beside a full-screen record */
  }
  @keyframes dnmRecordIn{ from{ opacity: 0; transform: translateY(10px); } to{ opacity: 1; transform: none; } }
  @media (prefers-reduced-motion: reduce){ html.ui-2026 body:not(#dn26):not(#dn27):not(#dn28) #lead-modal-overlay > #lead-modal{ animation: none !important; } }

  /* ======================================================================== 18. Cold calling */
  /* the overview bar + legend under the title, and the management buttons (Import numbers, Imported files, Assign numbers,
     Do-not-call list) leave the phone; Statistics is a round button beside the filter button in the tools row (sales.js) */
  html.ui-2026 body:not(#dn26) #page-cold-calling #cc-ov,
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-head .cc-head-actions{ display: none !important; }
  /* the head is then empty (the title left in header.css) unless the Personal view's "My Cold Calling points" card shows */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-head:not(:has(.cc-myscore:not([hidden]))){ display: none !important; }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-head{ gap: 0; }
  /* the page keeps empty blocks between the head and the tab strip (#cc-hours, #cc-undo, #cc-filebar) and around the list
     (#cc-pickall-row, #cc-more); each one costs a 14px flex gap of .cc-root while empty - 42px of nothing under the top bar
     once the head is gone (reviewer 2026-10-21). They show again the moment cold-calling.js fills them. */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-root > :is(#cc-hours, #cc-undo, #cc-filebar, #cc-pickall-row, #cc-more):empty{ display: none; }
  /* the Owners / Buyers / To sort strip (kept, item 18): one line that scrolls sideways instead of wrapping "To / sort" (EN)
     or spilling past the edge (fa) - the only piece left in the page head (reviewer 2026-10-21) */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-split{
    flex-wrap: nowrap; overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; scrollbar-width: none;
  }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-split::-webkit-scrollbar{ display: none; }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-split > .cc-kindbtn{ flex: 1 0 auto; white-space: nowrap; padding-inline: 8px; }   /* 8px: three fa tabs fit 390 */
  /* the tools row: the search field + the two round buttons on one line */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-tools{ display: flex; flex-wrap: nowrap; align-items: center; gap: 8px; }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-tools > .cc-search-wrap{ flex: 1 1 auto; min-width: 0; min-height: var(--dnm-ctrl); }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-tools > .dnm-ib{ flex: 0 0 auto; }
  /* the status chips (Open · Interested · …) scroll sideways instead of wrapping into three rows */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-chips{
    flex-wrap: nowrap; overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch; scrollbar-width: none;
    padding: 2px var(--dnm-gutter) 6px; margin-inline: calc(-1 * var(--dnm-gutter));
  }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-chips::-webkit-scrollbar{ display: none; }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-chips > .cc-chip{ flex: 0 0 auto; white-space: nowrap; }
  /* the moved filters inside the drawer: full width, 44px, and the multi-select's pop opens IN the panel (its phone style is a
     fixed bottom sheet at z 1200 - under the drawer at 1201) */
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .cc-select{ width: 100%; min-height: var(--dnm-ctrl); font-size: 15px; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .cc-ms{ display: flex; flex-direction: column; flex: 0 0 auto; }   /* cold-calling.css (≤900): flex:1 1 100% - in the drawer's column that basis is the panel's height */
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .cc-ms-btn{ width: 100%; max-width: none; height: auto; min-height: var(--dnm-ctrl); }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .cc-ms-pop{
    position: static; inset: auto; width: auto; max-width: none; max-height: none; margin-top: 6px; z-index: auto; box-shadow: none;
  }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .cc-ms-list{ max-height: 40vh; overflow: auto; flex: none; }
  /* a filter the page keeps hidden until its facets arrive (Category, Year, Bedrooms…) shows no orphan caption */
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-drawer-label:has(+ [hidden]){ display: none; }
  /* 35: in the number's card Call and WhatsApp are round icon buttons; Result (the primary) keeps its word */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-card .cc-actions{ flex-wrap: nowrap; gap: 8px; }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-card .cc-actions .cc-btn{ flex: 1 1 auto; min-width: 0; padding: 0 12px; min-height: var(--dnm-ctrl); }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-card .cc-actions :is(.cc-btn-call, .cc-btn-wa){
    flex: 0 0 var(--dnm-ctrl); width: var(--dnm-ctrl); height: var(--dnm-ctrl); padding: 0; border-radius: 50%;
  }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-card .cc-actions :is(.cc-btn-call, .cc-btn-wa) > span{ display: none; }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-card .cc-actions :is(.cc-btn-call, .cc-btn-wa) svg{ width: 20px; height: 20px; }
  /* 35: the worded "Details" (an Open-type button) leaves the card; tapping the card opens the number's Details sheet (sales.js) */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-card .cc-actions > [data-act="detail"]{ display: none !important; }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-card:has([data-act="detail"]){ cursor: pointer; }

  /* ======================================================================== 23. Contacts: the search + the round filter button */
  html.ui-2026 body:not(#dn26) #page-owners .own-toolbar{
    display: flex !important; flex-direction: row !important; flex-wrap: nowrap !important; align-items: center !important;
    gap: 8px !important; grid-template-columns: none !important;                 /* ui.css (≤900): display:grid !important, 1fr 1fr */
  }
  html.ui-2026 body:not(#dn26) #page-owners .own-toolbar > .own-search-wrap{ flex: 1 1 0% !important; width: auto !important; min-width: 0; }
  html.ui-2026 body:not(#dn26) #page-owners .own-toolbar > .dnm-ib{ flex: 0 0 auto; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .own-filter{ width: 100%; height: var(--dnm-ctrl) !important; min-height: var(--dnm-ctrl) !important; max-height: none !important; }
  /* 35: the contact card opens on tap (its own onclick), so "Open" goes; Call / WhatsApp / Email are round icon buttons (sales.js adds the icons) */
  html.ui-2026 body:not(#dn26) #page-owners .own-card-actions > .own-act-open{ display: none !important; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card-actions{ gap: 10px; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card-actions > .own-act[data-dnm-ic]{
    flex: 0 0 var(--dnm-ctrl); width: var(--dnm-ctrl); min-width: 0; height: var(--dnm-ctrl); min-height: var(--dnm-ctrl); padding: 0; border-radius: 50%;
  }
  html.ui-2026 body:not(#dn26) #page-owners .own-card-actions > .own-act[data-dnm-ic] > span{ display: none; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card-actions > .own-act[data-dnm-ic] svg{ width: 20px; height: 20px; }
  /* TestFlight 28 (owner 2026-10-27: «مخاطبین رو مینیمال‌تر کن تا مرتب‌تر بشه»): ONE compact row per contact - the initials, the name with the
     number under it, and small call / WhatsApp / mail icons at the end. The dash pill, the agent line with its photo, the e-mail row
     (the mail icon is the e-mail), the budget dash and the "Not specified" line are gone; a preference line shows only when the contact
     has one (sales.js marks the card .dnm-own-pref). The card opens the contact on tap, as before. */
  html.ui-2026 body:not(#dn26) #page-owners #own-grid > .own-card{
    display: grid; grid-template-columns: auto minmax(0, 1fr) auto; grid-template-areas: "av info acts" "pref pref pref";
    align-items: center; column-gap: 10px; row-gap: 4px; min-height: 0; padding: 10px 12px;
  }
  html.ui-2026 body:not(#dn26) #page-owners .own-card > .own-card-top{ display: contents; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card .own-card-top > .own-avatar{ grid-area: av; width: 40px; height: 40px; min-width: 40px; font-size: 14px; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card .own-card-top > .own-card-info{ grid-area: info; min-width: 0; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card .own-card-info > b.own-card-name{ font-size: 15px; line-height: 1.25; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: block; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card .own-card-info .own-card-phone{ font-size: 13px; line-height: 1.3; color: var(--text-muted); }
  html.ui-2026 body:not(#dn26) #page-owners .own-card .own-card-info .own-card-phone.is-empty{ display: none; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card :is(.own-card-top > .own-pill, .own-card-sub, .own-card-rows, .own-card-pref){ display: none !important; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card.dnm-own-pref > .own-card-pref{
    display: block !important; grid-area: pref; margin: 0; font-size: 12px; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
  }
  html.ui-2026 body:not(#dn26) #page-owners .own-card > .own-card-actions{ grid-area: acts; margin: 0; padding: 0; border: 0; gap: 6px; flex-wrap: nowrap; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card > .own-card-actions > .own-act[data-dnm-ic]{ flex: 0 0 36px; width: 36px; height: 36px; min-height: 36px; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card > .own-card-actions > .own-act[data-dnm-ic] svg{ width: 18px; height: 18px; }

  /* ======================================================================== 35. Leads: the card's WhatsApp / Call / ⋯ as round icon buttons
     (the card opens the record on tap already; the words stay as aria-label / title, sales.js) */
  html.ui-2026 body:not(#dn26) #page-customers .crm-lc .crm-lc-actions{ gap: 10px; justify-content: flex-start; }
  html.ui-2026 body:not(#dn26) #page-customers .crm-lc .crm-lc-btn{
    flex: 0 0 var(--dnm-ctrl); width: var(--dnm-ctrl); height: var(--dnm-ctrl); min-height: var(--dnm-ctrl); padding: 0; border-radius: 50%;
  }
  html.ui-2026 body:not(#dn26) #page-customers .crm-lc .crm-lc-btn > span{ display: none; }
  html.ui-2026 body:not(#dn26) #page-customers .crm-lc .crm-lc-btn svg{ width: 20px; height: 20px; }
  html.ui-2026 body:not(#dn26) #page-customers .crm-lc .crm-lc-btn.crm-lc-more{ margin-inline-start: auto; }
}

/* Owner 2026-10-22: buttons on the lead record's property cards (Quote price / View / Remove / Reschedule …) are icon-only on the
   phone - _actIconize already gave them their icon and the word as aria-label / title; the word itself is hidden here. */
@media (max-width: 900px){
  html.ui-2026 body:not(#dn26) #lead-modal .lm-body .btn.act-ic .act-ic-lab{ position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  html.ui-2026 body:not(#dn26) #lead-modal .lm-body .btn.act-ic{ position: relative; min-width: 40px; height: 40px; padding: 0 12px; border-radius: 999px; display: inline-flex; align-items: center; justify-content: center; gap: 0; }
  html.ui-2026 body:not(#dn26) #lead-modal .lm-body .btn.act-ic svg{ width: 18px; height: 18px; }
  /* Leads page: the Deleted (bin) button is a round icon button; sales.js strips the word and names it */
  html.ui-2026 body:not(#dn26) #page-customers .crm-del-bin.dnm-ib{ width: var(--dnm-ctrl); height: var(--dnm-ctrl); padding: 0; justify-content: center; }
  html.ui-2026 body:not(#dn26) #page-customers .crm-del-bin.dnm-ib svg{ width: 18px; height: 18px; }
}

/* ==========================================================================================================================
   Phone review 2026-10-22 (owner-style, 390px) - sales: Leads, the lead / deal record, Contacts, Cold calling.
   The JS half is the last block of assets/js/mobile/sales.js. Everything here is inside (max-width: 900px).
   ========================================================================================================================== */
@media (max-width: 900px){
  /* ---------------------------------------------------------------- Leads: one tools row (search · quick add · filter · sort) */
  /* the title row (Leads, the count, the Deleted bin) leaves: the count is a caption, the bin sits in the filter drawer (sales.js) */
  html.ui-2026 body:not(#dn26) #page-customers .crm-dl-head > .crm-dl-title{ display: none !important; }
  html.ui-2026 body:not(#dn26) #page-customers .crm-dl-head{ flex-wrap: nowrap !important; align-items: center; gap: 8px !important; }
  html.ui-2026 body:not(#dn26) #page-customers .crm-dl-head > .crm-dl-search{ flex: 1 1 auto !important; min-width: 0; order: 0 !important; }
  html.ui-2026 body:not(#dn26) #page-customers .crm-dl-head > :is(.crm-quick-add-btn, .dnm-ib){ order: 1 !important; }
  html.ui-2026 body:not(#dn26) #page-customers .crm-quick-add-btn{
    flex: 0 0 var(--dnm-ctrl); width: var(--dnm-ctrl) !important; height: var(--dnm-ctrl) !important; min-width: 0; padding: 0 !important;
    border: 0 !important; border-radius: 50% !important; background: var(--dnm-soft) !important; color: var(--text) !important; box-shadow: none !important;
    display: inline-flex; align-items: center; justify-content: center;
  }
  html.ui-2026 body:not(#dn26) #page-customers .crm-quick-add-btn svg{ width: 20px; height: 20px; }
  /* the desktop filters (agent combobox, dataset, sort, "Show lost deals", Clear) live behind the round filter / sort buttons */
  html.ui-2026 body:not(#dn26) #page-customers .crm-dl-controls{ display: none !important; }
  html.ui-2026 body:not(#dn26) #page-customers .crm-dl-bar:not(:has(.crm-dl-chips > *)){ display: none !important; }
  /* the card opens the record on tap: the round "›" (Continue Workflow) is a second Open */
  html.ui-2026 body:not(#dn26) #page-customers .crm-lc .crm-lc-btn.crm-lc-more{ display: none !important; }
  /* Call and WhatsApp: one look on Leads and on Cold calling (the round tool button's soft fill) */
  html.ui-2026 body:not(#dn26) #page-customers .crm-lc .crm-lc-btn:is(.wa, .call),
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-card .cc-actions :is(.cc-btn-call, .cc-btn-wa){
    background: var(--dnm-soft) !important; border-color: transparent !important; color: var(--text) !important; box-shadow: none !important;
  }
  /* the sort / filter drawer rows (sales.js): one option per row, the chosen one marked */
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-opt-list{ display: flex; flex-direction: column; margin: 0 0 6px; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-opt-row{
    display: flex; align-items: center; gap: 12px; width: 100%; min-height: 48px; padding: 6px 12px; border: 0; border-radius: 12px;
    background: transparent; color: var(--text); font: inherit; font-size: 15px; text-align: start; cursor: pointer;
  }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-opt-row.is-on{ background: var(--dnm-soft); font-weight: 700; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-opt-row > span{ flex: 1 1 auto; min-width: 0; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-opt-row > svg{ flex: 0 0 auto; width: 20px; height: 20px; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-opt-row input[type="checkbox"]{ margin: 0 !important; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-team-list{ display: flex; flex-direction: column; margin: 0 0 6px; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-team-row{
    display: flex; align-items: center; gap: 12px; width: 100%; min-height: 56px; padding: 6px 8px; border: 0; border-radius: 12px;
    background: transparent; color: var(--text); font: inherit; font-size: 15px; text-align: start;
  }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-team-row.is-on{ background: var(--dnm-soft); font-weight: 700; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-team-row > span:last-child{ min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; unicode-bidi: plaintext; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-team-row .dc-admin-option-avatar{
    flex: 0 0 auto; width: 40px; height: 40px; border-radius: 50%; overflow: hidden; display: grid; place-items: center;
    background: var(--dnm-soft); color: var(--text); font-size: 13px; font-weight: 700;
  }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-team-row .dc-admin-option-avatar :is(img, span){ width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: grid; place-items: center; }
  html.ui-2026 body:not(#dn26) .dnm-drawer-body .dnm-team-row .dc-admin-option-avatar svg{ width: 18px; height: 18px; }
  /* Quick Add Lead (full screen by core.css): no helper lines */
  html.ui-2026 body:not(#dn26) #small-modal .form-group:has(> .ql-searchbox) > .form-label,
  html.ui-2026 body:not(#dn26) #small-modal .ql-divider{ display: none !important; }
  html.ui-2026 body:not(#dn26) #small-modal .form-group:has(> .ql-searchbox){ margin-bottom: 16px; }

  /* ---------------------------------------------------------------- the lead / deal record */
  /* head: prev / next and close are the round tool buttons; a disabled arrow is not shown; close on the 16px gutter, level with the head */
  html.ui-2026 body:not(#dn26):not(#dn27) #lead-modal :is(.lm-iconbtn, .lm-close){
    width: var(--dnm-ctrl) !important; height: var(--dnm-ctrl) !important; min-width: 0 !important; padding: 0 !important;
    border: 0 !important; border-radius: 50% !important; background: var(--dnm-soft) !important; color: var(--text) !important; box-shadow: none !important;
    display: inline-flex !important; align-items: center; justify-content: center;
  }
  html.ui-2026 body:not(#dn26):not(#dn27) #lead-modal .lm-nav .lm-iconbtn:disabled{ display: none !important; }
  html.ui-2026 body:not(#dn26):not(#dn27) #lead-modal .lm-nav:not(:has(.lm-iconbtn:not(:disabled))){ display: none !important; }
  html.ui-2026 body:not(#dn26):not(#dn27) #lead-modal .lm-close{
    top: calc(var(--dn-safe-top, env(safe-area-inset-top, 0px)) + 30px) !important; right: max(16px, var(--dn-safe-right, 0px)) !important; left: auto !important;
  }
  html.ui-2026[dir="rtl"] body:not(#dn26):not(#dn27) #lead-modal .lm-close{ left: max(16px, var(--dn-safe-left, 0px)) !important; right: auto !important; }
  html.ui-2026 body:not(#dn26):not(#dn27) #lead-modal .lm-title h2{ overflow-wrap: break-word !important; word-break: normal !important; }
  /* the stage strip keeps the current stage in view (sales.js scrolls to it) and its last chip off the screen edge */
  html.ui-2026 body:not(#dn26) #lead-modal .lm-stepper{ scroll-padding-inline: var(--dnm-gutter); }
  html.ui-2026 body:not(#dn26) #lead-modal .lm-stepper::after{ content: ''; flex: 0 0 4px; }
  /* the action bar: four equal, unfilled buttons on the 16px gutter */
  html.ui-2026 body:not(#dn26) #lead-modal .lm-mbar{ padding-inline: var(--dnm-gutter) !important; }
  html.ui-2026 body:not(#dn26) #lead-modal .lm-mbar-btn{ background: transparent !important; }
  /* the Closing / Documents cards: the Lead card's inner padding, apart from the card above */
  html.ui-2026 body:not(#dn26) #lead-modal .lm-block.rec-stage-panel{ padding-inline: 14px !important; margin-top: 12px !important; }
  html.ui-2026 body:not(#dn26) #lead-modal .dwf-body{ min-height: 0 !important; height: auto !important; }
  /* one section style: no grey side column, section titles do not stick over the content */
  html.ui-2026 body:not(#dn26) #lead-modal .lm-col.lm-side{ background: transparent !important; }
  html.ui-2026 body:not(#dn26) #lead-modal .lm-section-title{ position: static !important; }
  /* the + New Lead inside a record (the page's + New lead button has it) */
  html.ui-2026 body:not(#dn26) #lead-modal .rec-info-new{ display: none !important; }
  /* disclosure: a chevron in place of the native triangle */
  html.ui-2026 body:not(#dn26) :is(#lead-modal details, #small-modal details.pty-add) > summary{ list-style: none; display: flex; align-items: center; gap: 8px; cursor: pointer; }
  html.ui-2026 body:not(#dn26) :is(#lead-modal details, #small-modal details.pty-add) > summary::-webkit-details-marker{ display: none; }
  html.ui-2026 body:not(#dn26) :is(#lead-modal details, #small-modal details.pty-add) > summary::before{
    content: ''; flex: 0 0 16px; width: 16px; height: 16px; background: currentColor; transition: transform .15s ease;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 6 6 6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
            mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m9 6 6 6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
  }
  html.ui-2026[dir="rtl"] body:not(#dn26) :is(#lead-modal details, #small-modal details.pty-add) > summary::before{ transform: scaleX(-1); }
  html.ui-2026 body:not(#dn26) :is(#lead-modal details, #small-modal details.pty-add)[open] > summary::before{ transform: rotate(90deg) !important; }
  /* the tool buttons of the record (sales.js marks them .dnm-rec-ic): round 44px icons, the word kept as the name */
  html.ui-2026 body:not(#dn26):not(#dn27) #lead-modal .dnm-rec-ic{
    position: relative; flex: 0 0 auto; width: var(--dnm-ctrl) !important; height: var(--dnm-ctrl) !important; min-width: 0 !important; min-height: 0 !important;
    padding: 0 !important; gap: 0 !important; border: 0 !important; border-radius: 50% !important; background: var(--dnm-soft) !important; color: var(--text) !important;
    box-shadow: none !important; display: inline-flex !important; align-items: center; justify-content: center; font-size: 0 !important;
  }
  html.ui-2026 body:not(#dn26):not(#dn27) #lead-modal .dnm-rec-ic svg{ width: 20px !important; height: 20px !important; }
  html.ui-2026 body:not(#dn26) #lead-modal .dnm-rec-ic :is(.dnm-ic-lab, span:not(:has(svg))){
    position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap;
  }
  html.ui-2026 body:not(#dn26):not(#dn27) #lead-modal .lm-body .btn.act-ic{ width: var(--dnm-ctrl); height: var(--dnm-ctrl); min-width: 0; padding: 0; border-radius: 50%; }
  /* Open work: the four tools in one row of round buttons */
  html.ui-2026 body:not(#dn26) #lead-modal #rec-open-work .lm-btnrow{ display: flex !important; flex-wrap: nowrap; gap: 10px; grid-template-columns: none !important; }
  html.ui-2026 body:not(#dn26) #lead-modal :is(.need-act, .rec-info-needs > .lm-btnrow, .shown-marks, .wa-actions){ gap: 10px; }
  /* WhatsApp: the reason is not printed twice (sales.js marks the copy) */
  html.ui-2026 body:not(#dn26) #lead-modal .wa-reason.dnm-dup{ display: none !important; }
  /* Closing details: values in the text colour (the commission read like a placeholder) */
  html.ui-2026 body:not(#dn26) #lead-modal #close-form :is(input, select, textarea){ color: var(--text) !important; -webkit-text-fill-color: var(--text); }
  /* Lead details › Change: a round button, not a grey word */
  html.ui-2026 body:not(#dn26) #lead-modal .lm-reassign-btn.dnm-rec-ic{ opacity: 1 !important; }

  /* Change Agent: the people as photos + names, always open; no help line, no ▾ */
  html.ui-2026 body:not(#dn26) #small-modal .reassign-hint,
  html.ui-2026 body:not(#dn26) #small-modal .reassign-body .dc-admin-combo-toggle{ display: none !important; }
  html.ui-2026 body:not(#dn26) #small-modal .reassign-body #reassign-agent-options{
    display: flex !important; flex-direction: column; position: static !important; inset: auto !important; max-height: none !important; margin-top: 8px;
    border: 0 !important; box-shadow: none !important; background: transparent !important; padding: 0 !important; transform: none !important; opacity: 1 !important; visibility: visible !important;
  }
  html.ui-2026 body:not(#dn26) #small-modal .reassign-body #reassign-agent-options > [role="option"]{
    display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 6px 8px; border: 0; border-radius: 12px; background: transparent; text-align: start;
  }
  html.ui-2026 body:not(#dn26) #small-modal .reassign-body #reassign-agent-options > [role="option"][hidden]{ display: none; }
  html.ui-2026 body:not(#dn26) #small-modal .reassign-body #reassign-agent-options > [role="option"][aria-selected="true"]{ background: var(--dnm-soft); font-weight: 700; }
  html.ui-2026 body:not(#dn26) #small-modal .reassign-body #reassign-agent-options .dc-admin-option-avatar{
    flex: 0 0 auto; width: 40px; height: 40px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; background: var(--dnm-soft); font-size: 13px; font-weight: 700;
  }
  html.ui-2026 body:not(#dn26) #small-modal .reassign-body #reassign-agent-options .dc-admin-option-avatar :is(img, span){ width: 100%; height: 100%; object-fit: cover; border-radius: 50%; display: grid; place-items: center; }
  html.ui-2026 body:not(#dn26) #small-modal .reassign-body #reassign-agent-options .dc-admin-option-copy{ display: flex; flex-direction: column; min-width: 0; flex: 1 1 auto; }
  html.ui-2026 body:not(#dn26) #small-modal .reassign-body #reassign-agent-options .dc-admin-option-copy small{ display: none; }

  /* Add need: Buy / Rent / Owner on one row; no "needed for Matching" hints */
  html.ui-2026 body:not(#dn26) #small-modal .need-kind-pick{ display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)) !important; gap: 8px !important; }
  html.ui-2026 body:not(#dn26) #small-modal .need-kind-pick > .need-kind-opt{ min-height: var(--dnm-ctrl); min-width: 0; padding: 0 8px !important; flex-direction: row !important; gap: 6px; justify-content: center; white-space: nowrap; }
  html.ui-2026 body:not(#dn26) #small-modal .need-fornext{ display: none !important; }

  /* ---------------------------------------------------------------- Contacts */
  /* the head row only held "+ New Contact": it floats above the tab bar like Developers' "+ Add" */
  html.ui-2026 body:not(#dn26):not(#dn27) #page-owners header.own-header{ display: contents !important; }
  html.ui-2026 body:not(#dn26) #page-owners .own-root{ padding-top: 4px !important; }
  html.ui-2026 body:not(#dn26) #page-owners .own-header > div:first-child{ display: none !important; }
  html.ui-2026 body:not(#dn26) #page-owners .own-btn-add{
    position: fixed; z-index: 112; inset-inline-end: max(16px, var(--dn-safe-right, 0px)); bottom: calc(var(--dn-tabbar-h, 64px) + 12px + var(--dn-safe-bottom, 0px));
    display: inline-flex; align-items: center; gap: 8px; min-height: 52px; height: auto !important; padding-block: 0; padding-inline: 16px 20px; margin: 0;
    border-radius: var(--dnm-pill, 999px); font-size: 15px; font-weight: 600; box-shadow: 0 8px 22px rgba(0,0,0,.18); transform: none !important;
  }
  html.ui-2026 body:not(#dn26) #page-owners .own-btn-add svg{ width: 18px; height: 18px; }
  html.ui-2026.dnm-menu-open body:not(#dn26) #page-owners .own-btn-add,
  html.ui-2026 body:not(#dn26):has(.modal-overlay:not(.hidden)) #page-owners .own-btn-add,
  html.ui-2026 body:not(#dn26):has(#own-panel-overlay.visible) #page-owners .own-btn-add,
  html.ui-2026 body:not(#dn26):has(.dnm-drawer.is-on) #page-owners .own-btn-add{ display: none !important; }
  /* 20 cards a page (sales.js); the desktop's "Show more contacts" is replaced by the pager */
  html.ui-2026 body:not(#dn26) #page-owners #own-grid > .own-card.dnm-off{ display: none !important; }
  html.ui-2026 body:not(#dn26) #page-owners #own-load-more-wrap{ display: none !important; }
  /* a Latin name in a Persian page is cut at its own end, not its start */
  html.ui-2026 body:not(#dn26) :is(#page-owners .own-card-name, #own-panel-name, #page-cold-calling .cc-group-name, #page-cold-calling .cc-name){ unicode-bidi: plaintext; }
  html.ui-2026[dir="rtl"] body:not(#dn26) :is(#page-owners .own-card-name, #own-panel-name){ text-align: right; }
  /* the agent's photo in the card's meta line (sales.js) */
  html.ui-2026 body:not(#dn26) #page-owners .own-card-sub .dnm-own-agent{ display: inline-flex; align-items: center; vertical-align: middle; margin-inline-end: 6px; }
  html.ui-2026 body:not(#dn26) #page-owners .own-card-sub .dnm-own-agent .agent-inline-avatar{
    width: 22px; height: 22px; flex: 0 0 22px; border-radius: 50%; overflow: hidden; display: inline-grid; place-items: center;
    background: var(--dnm-soft); color: var(--text); font-size: 9px !important; font-weight: 700; line-height: 1; letter-spacing: 0;
  }
  html.ui-2026 body:not(#dn26) #page-owners .own-card-sub .dnm-own-agent .agent-inline-avatar > *{ width: 100%; height: 100%; border-radius: 50%; object-fit: cover; display: grid; place-items: center; font-size: 9px !important; line-height: 1; }
  /* the Filters drawer: the agent is chosen from photos + names (sales.js); the moved select stays for the page's own code */
  html.ui-2026 body:not(#dn26) .dnm-drawer-body #own-filter-owner{ display: none !important; }
  /* the contact record: full screen and square, no glass; Call / WhatsApp / Log visit / Merge round; Edit and Delete in ⋯ */
  html.ui-2026 body:not(#dn26):not(#dn27) #own-panel{ border-radius: 0 !important; border: 0 !important; box-shadow: none !important; }
  html.ui-2026 body:not(#dn26) #own-panel-overlay{ -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
  html.ui-2026 body:not(#dn26):not(#dn27) #own-panel .own-panel-close{
    width: var(--dnm-ctrl) !important; height: var(--dnm-ctrl) !important; border: 0 !important; border-radius: 50% !important; background: var(--dnm-soft) !important;
    color: var(--text) !important; box-shadow: none !important; font-size: 22px; line-height: 1;
  }
  html.ui-2026 body:not(#dn26) #own-panel .own-panel-edit-btn,
  html.ui-2026 body:not(#dn26) #own-panel #own-panel-actions > .own-act-danger,
  html.ui-2026 body:not(#dn26) #own-panel #own-panel-source.dnm-empty{ display: none !important; }
  html.ui-2026 body:not(#dn26):not(#dn27) #own-panel #own-panel-actions{ display: flex !important; flex-wrap: nowrap !important; gap: 10px !important; grid-template-columns: none !important; }
  html.ui-2026 body:not(#dn26):not(#dn27) #own-panel #own-panel-actions > :is([data-dnm-ic], .dnm-ib){
    flex: 0 0 var(--dnm-ctrl) !important; width: var(--dnm-ctrl) !important; height: var(--dnm-ctrl) !important; min-width: 0 !important; min-height: 0 !important;
    padding: 0 !important; gap: 0 !important; border: 0 !important; border-radius: 50% !important; background: var(--dnm-soft) !important; color: var(--text) !important;
    display: inline-flex !important; align-items: center; justify-content: center; font-size: 0 !important; box-shadow: none !important;
  }
  html.ui-2026 body:not(#dn26) #own-panel #own-panel-actions > [data-dnm-ic] svg{ width: 20px !important; height: 20px !important; }
  html.ui-2026 body:not(#dn26) #own-panel #own-panel-actions > [data-dnm-ic] > span{ position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
  html.ui-2026 body:not(#dn26) #own-panel #own-panel-actions > .dnm-ib{ margin-inline-start: auto; }

  /* ---------------------------------------------------------------- the round pager (Contacts, Cold calling) */
  html.ui-2026 body:not(#dn26) .dnm-pager{ display: flex; align-items: center; justify-content: center; gap: 12px; margin: 14px 0 6px; }
  html.ui-2026 body:not(#dn26) .dnm-pager > b{ min-width: 0; font-size: 14px; font-weight: 600; color: var(--text-muted, var(--text)); text-align: center; font-variant-numeric: tabular-nums; }
  html.ui-2026 body:not(#dn26) .dnm-pager > .dnm-ib:disabled{ opacity: .35; }
  html.ui-2026 body:not(#dn26) .dnm-pager > .dnm-ib:first-child svg{ transform: scaleX(-1); }
  html.ui-2026[dir="rtl"] body:not(#dn26) .dnm-pager > .dnm-ib:first-child svg{ transform: none; }
  html.ui-2026[dir="rtl"] body:not(#dn26) .dnm-pager > .dnm-ib:last-child svg{ transform: scaleX(-1); }

  /* ---------------------------------------------------------------- Cold calling */
  /* area tiles: the whole name on up to two lines, the count under it; the bar inside the tile, not on its border */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-groups > .cc-group{ flex-direction: column !important; align-items: flex-start !important; justify-content: flex-start; gap: 2px; padding: 10px 12px 16px !important; text-align: start; }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-groups > .cc-group > .cc-group-name{
    white-space: normal !important; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
    line-height: 1.3; max-width: 100%; overflow-wrap: break-word;
  }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-groups > .cc-group > b{ font-size: 13px; font-weight: 600; color: var(--text-muted, var(--text)); }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-groups > .cc-group > i{ left: 12px !important; right: auto !important; bottom: 8px !important; max-width: calc(100% - 24px); height: 3px; border-radius: 2px; }
  html.ui-2026[dir="rtl"] body:not(#dn26) #page-cold-calling .cc-groups > .cc-group > i{ right: 12px !important; left: auto !important; }
  /* the "Choose an area · 298,682 numbers" caption leaves; "Show all as a list" stays */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-groups-head > :is(b, span){ display: none !important; }
  /* the search field at 44px */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-tools > .cc-search-wrap{ height: var(--dnm-ctrl) !important; min-height: 0 !important; box-sizing: border-box; }
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-tools > .cc-search-wrap > input{ height: 100% !important; min-height: 0 !important; }
  /* 20 numbers a page: the round pager of sales.js replaces the numbered pages and the 50 / 100 / 200 switch */
  html.ui-2026 body:not(#dn26) #page-cold-calling #cc-more > .cc-pager{ display: none !important; }
  /* the sheets of the page (Statistics, a number's details, …) are full screen; the X closes them (no worded Close) */
  html.ui-2026.crm-mobile-lock body:not(#dn26) #small-modal:has(.cc-sheet) .modal{
    position: fixed !important; inset: 0 !important; width: 100% !important; max-width: none !important; height: var(--app-vh, 100dvh) !important; max-height: none !important;
    margin: 0 !important; border: 0 !important; border-radius: 0 !important; transform: none !important;
  }
  html.ui-2026.crm-mobile-lock body:not(#dn26) #small-modal:has(.cc-sheet) .modal-header{ padding-top: max(8px, var(--dn-safe-top, 0px)) !important; }
  html.ui-2026 body:not(#dn26) #small-modal:has(.cc-sheet) #small-modal-footer:has(> .cc-btn:only-child[onclick*="closeModal"]){ display: none !important; }
  /* Statistics: the period is one row of chips that scrolls, never "Last 7 / days" */
  html.ui-2026 body:not(#dn26) #small-modal .cc-sheet > .cc-seg{
    display: flex !important; flex-wrap: nowrap !important; overflow: hidden; gap: 2px !important; width: 100% !important; max-width: 100%; box-sizing: border-box;
  }
  html.ui-2026 body:not(#dn26) #small-modal .cc-sheet > .cc-seg > button{
    flex: 1 1 auto !important; min-width: 0 !important; white-space: nowrap !important; min-height: 40px; padding-inline: 6px !important; font-size: 12.5px !important;
  }
  /* "Called by X · when": one pill of running text (its flex items stood as three columns in Persian) */
  html.ui-2026 body:not(#dn26) #page-cold-calling .cc-card .cc-who{ display: inline-block !important; max-width: 100%; border-radius: 12px; line-height: 1.5; }
  /* a number's details: its Call / WhatsApp as round buttons under the phone line (sales.js) */
  html.ui-2026 body:not(#dn26) #small-modal .cc-sheet .dnm-cc-acts{ display: flex; gap: 10px; margin: 10px 0 14px; }
}

/* App TestFlight feedback 2026-10-23 (item 9): the lead card's sub-status ("Visit scheduled", "Properties proposed") is a
   compact pill that hugs its text - it was stretched by the card's column to almost the full card width */
@media (max-width: 900px){
  html.ui-2026 body:not(#dn26) .crm-lc .crm-lc-resp{
    align-self:flex-start; justify-self:start; width:fit-content; max-width:100%; flex:0 0 auto;
    white-space:nowrap; overflow:hidden; text-overflow:ellipsis; margin-inline-start:0;
  }
}
