/* Native iOS skin — visual only. Same controls, same JS, same flow. */
@media (max-width: 860px) {
  :root {
    --ios-bg: #f2f2f7;
    --ios-grouped: #f2f2f7;
    --ios-card: #ffffff;
    --ios-label: rgba(60, 60, 67, 0.6);
    --ios-tertiary: rgba(60, 60, 67, 0.3);
    --ios-sep: rgba(60, 60, 67, 0.29);
    --ios-sep-opaque: #c6c6c8;
    --ios-fill: rgba(120, 120, 128, 0.16);
    --ios-fill-2: rgba(120, 120, 128, 0.12);
    --ios-blue: #007aff;
    --ios-red: #ff3b30;
    --ios-green: #34c759;
    --ios-tint: #e10600;
    --tabbar-h: 56px;
    --nav-h: 44px;
    --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", system-ui, sans-serif;
    --display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", system-ui, sans-serif;
    --mono: -apple-system, ui-monospace, "SF Mono", monospace;
  }

  html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    color-scheme: light;
  }

  body.shell {
    font-family: var(--font) !important;
    background: var(--ios-bg) !important;
    color: #000 !important;
    font-size: 17px;
    line-height: 1.294;
    letter-spacing: -0.022em;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px));
  }
  body.shell .noise,
  body.shell code,
  body.shell .mono {
    font-family: var(--font) !important;
  }
  body.shell .mono {
    font-variant-numeric: tabular-nums;
  }

  /* —— Navigation bar —— */
  body.shell .mobile-bar {
    display: flex !important;
    align-items: center;
    min-height: calc(var(--nav-h) + env(safe-area-inset-top, 0px));
    padding: env(safe-area-inset-top, 0px) 8px 0 !important;
    background: rgba(242, 242, 247, 0.82) !important;
    backdrop-filter: saturate(1.8) blur(20px) !important;
    -webkit-backdrop-filter: saturate(1.8) blur(20px) !important;
    border-bottom: 0 !important;
    gap: 4px;
  }
  body.shell:not(.is-locked) .mobile-brand {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    pointer-events: none;
    opacity: 0;
    width: 1px;
    overflow: hidden;
  }
  body.shell .mobile-vendor {
    margin-left: auto;
    max-width: 46vw;
    min-height: 32px;
    padding: 0 12px !important;
    border: 0 !important;
    border-radius: 999px;
    background: var(--ios-fill) !important;
    color: #000 !important;
    font-size: 13px !important;
    font-weight: 600;
    letter-spacing: -0.01em;
  }
  body.shell .wa-retornos-btn,
  body.shell .mobile-bar .wa-retornos-btn {
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 999px;
    background: var(--ios-fill);
    color: #128c7e;
    animation: none;
    box-shadow: none;
  }
  body.shell .wa-retornos-count {
    top: -4px;
    right: -4px;
    min-width: 16px;
    height: 16px;
    font-size: 11px;
    font-weight: 700;
    box-shadow: none;
  }

  /* —— Content / large titles —— */
  body.shell .content {
    padding: 2px 0 32px;
    width: 100%;
    overflow-x: hidden;
  }
  body.shell .page-head {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 4px;
    margin: 0;
    padding: 4px 16px 10px;
  }
  body.shell .page-head h1 {
    font-family: var(--display) !important;
    font-size: 34px !important;
    font-weight: 700;
    line-height: 1.12;
    letter-spacing: -0.043em;
    color: #000;
    margin: 0;
  }
  body.shell .page-head .eyebrow,
  body.shell .page-head .lede {
    display: none !important;
  }
  body.shell .page-head .mono,
  body.shell .page-meta .mono,
  body.shell #agCount,
  body.shell #prospeccaoCount,
  body.shell #lastSync {
    font-size: 15px !important;
    font-weight: 400;
    color: var(--ios-label) !important;
    letter-spacing: -0.016em;
  }
  body.shell .page-meta,
  body.shell .page-meta-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 4px 18px;
    width: 100%;
    text-align: left;
    justify-content: flex-start;
  }
  body.shell .page-meta-actions .btn,
  body.shell .page-meta-actions .btn.ghost,
  body.shell .page-meta-actions .btn.primary {
    flex: 0 0 auto;
    min-height: 44px;
    padding: 0;
    border: 0 !important;
    border-radius: 0;
    background: transparent !important;
    color: var(--ios-tint) !important;
    font-size: 17px !important;
    font-weight: 400;
    box-shadow: none !important;
  }
  body.shell .page-meta-actions .btn.primary {
    font-weight: 600;
  }
  body.shell .vendas-download-actions {
    width: 100%;
    justify-content: space-between !important;
    align-items: center;
    flex-wrap: nowrap;
    gap: 12px;
  }
  body.shell .vendas-download-actions .btn {
    flex: 0 0 auto !important;
  }
  body.shell .vendas-list-total {
    margin-left: auto;
    text-align: right;
    min-width: 0;
    max-width: 64%;
  }
  body.shell .vendas-list-total-label {
    display: block;
    font-size: 12px;
    font-weight: 400;
    color: var(--ios-label);
    line-height: 1.2;
  }
  body.shell .vendas-list-total-value {
    display: block;
    font-size: 17px;
    font-weight: 600;
    color: #000;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.022em;
  }
  body.shell .carteira-page-head {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    padding: 6px 16px 4px !important;
  }
  body.shell .carteira-title-row {
    min-height: 44px;
  }
  body.shell .carteira-title-row h1 {
    font-size: 34px !important;
    line-height: 1.1;
  }
  body.shell .carteira-title-actions {
    gap: 0;
    margin-right: -6px;
  }
  body.shell .ios-bar-text {
    color: var(--ios-tint) !important;
    font-size: 17px;
    font-weight: 400;
    padding: 0 6px;
  }
  body.shell .carteira-page-head.is-selecting .ios-bar-text,
  body.shell #agendamentoRoot.is-selecting #btnCarteiraSelect {
    font-weight: 600;
  }
  body.shell .carteira-head-btns {
    display: none !important;
  }
  body.shell .carteira-head-actions {
    display: block !important;
    width: 100%;
    margin: 0;
    padding: 0 0 8px;
  }
  body.shell .carteira-page-head #agCount {
    display: block;
    margin: 0;
    padding: 0;
    font-size: 15px !important;
    color: var(--ios-label) !important;
  }
  body.shell .ag-seg-scroll {
    margin: 8px 16px 12px !important;
  }
  body.shell .carteira-head-btns .btn,
  body.shell .carteira-head-btns .btn.ghost,
  body.shell .carteira-head-btns .btn.primary {
    flex: 0 0 auto;
    width: auto !important;
    min-height: 44px !important;
    padding: 0 10px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: var(--ios-tint) !important;
    font-size: 17px !important;
    font-weight: 400 !important;
    box-shadow: none !important;
  }
  body.shell .carteira-head-btns .btn.primary {
    font-weight: 600 !important;
  }
  body.shell #btnClientAdd[hidden] {
    display: none !important;
  }
  body.shell #vendasListView > .page-head h1,
  body.shell #vendasListView > .page-head .eyebrow,
  body.shell #vendasListView > .page-head .lede,
  body.shell #resPanelVisao .page-head h1,
  body.shell #resPanelVisao .page-head .eyebrow,
  body.shell #resPanelVisao .page-head .lede,
  body.shell #resPanelComissoes .page-head h1,
  body.shell #resPanelComissoes .page-head .eyebrow,
  body.shell #resPanelComissoes .page-head .lede {
    display: none !important;
  }
  body.shell #vendasListView > .page-head,
  body.shell #resPanelVisao .page-head,
  body.shell #resPanelComissoes .page-head {
    padding: 0 16px 8px;
    margin: 0;
  }

  /* —— Buttons —— */
  body.shell .btn {
    min-height: 50px;
    border-radius: 14px;
    border: 0;
    font-size: 17px;
    font-weight: 600;
    letter-spacing: -0.022em;
    padding: 0 16px;
    -webkit-tap-highlight-color: transparent;
    box-shadow: none !important;
  }
  body.shell .btn.primary {
    background: var(--ios-tint) !important;
    color: #fff !important;
  }
  body.shell .btn.ghost {
    background: var(--ios-fill) !important;
    color: #000 !important;
    border: 0 !important;
  }
  body.shell .btn.tiny {
    min-height: 32px;
    min-width: 32px;
    padding: 0 10px;
    font-size: 15px;
    font-weight: 400;
    border-radius: 8px;
    background: transparent !important;
    color: var(--ios-tint) !important;
  }
  body.shell .btn.tiny.danger {
    color: var(--ios-red) !important;
  }
  body.shell .btn:active {
    opacity: 0.55;
  }

  /* —— Fields —— */
  body.shell input[type="text"],
  body.shell input[type="tel"],
  body.shell input[type="email"],
  body.shell input[type="password"],
  body.shell input[type="datetime-local"],
  body.shell input[type="date"],
  body.shell input[type="number"],
  body.shell select,
  body.shell textarea,
  body.shell .entry-input,
  body.shell .clients-search-input,
  body.shell .campanha-city-search,
  body.shell input[type="search"]:not(.ios-search-input) {
    font-family: var(--font) !important;
    font-size: 17px !important;
    min-height: 44px;
    border: 0 !important;
    border-radius: 10px;
    background: var(--ios-fill) !important;
    color: #000 !important;
    padding: 10px 12px;
    box-shadow: none !important;
    outline: none;
  }
  body.shell input[type="search"]:not(.ios-search-input),
  body.shell .clients-search-input,
  body.shell .campanha-city-search,
  body.shell #vendasSearch,
  body.shell #agCidadeBusca {
    min-height: 36px;
    border-radius: 10px;
    background: var(--ios-fill) !important;
    padding-left: 34px;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none'><circle cx='6.5' cy='6.5' r='5' stroke='%238e8e93' stroke-width='1.6'/><path d='M10.2 10.2 14 14' stroke='%238e8e93' stroke-width='1.6' stroke-linecap='round'/></svg>") !important;
    background-repeat: no-repeat !important;
    background-position: 10px 50% !important;
    background-size: 16px 16px !important;
    background-color: var(--ios-fill) !important;
  }
  body.shell .ios-search-field {
    height: 36px !important;
    min-height: 36px !important;
    overflow: hidden;
    background: var(--ios-fill-2) !important;
    box-shadow: none !important;
  }
  body.shell .ios-search-field input,
  body.shell .ios-search-field input[type="search"],
  body.shell .ios-search-field .ag-search,
  body.shell .ios-search-field #q,
  body.shell .ios-search-field #agBusca {
    flex: 1 1 auto;
    width: auto !important;
    max-width: none !important;
    min-width: 0 !important;
    height: 36px !important;
    min-height: 36px !important;
    margin: 0 !important;
    padding: 0 8px 0 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    background-image: none !important;
    box-shadow: none !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    font-size: 17px !important;
    font-weight: 400 !important;
  }
  body.shell textarea {
    min-height: 120px;
    line-height: 1.35;
    border-radius: 0;
    background: transparent !important;
    padding: 12px 16px;
  }
  body.shell .prospeccao-paste textarea {
    font-family: var(--font) !important;
    font-size: 17px !important;
  }

  body.shell input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 22px;
    height: 22px;
    margin: 0;
    border: 1.5px solid #c7c7cc;
    border-radius: 50%;
    background: #fff;
    position: relative;
    flex: 0 0 22px;
    cursor: pointer;
  }
  body.shell input[type="checkbox"]:checked {
    background: var(--ios-tint);
    border-color: var(--ios-tint);
  }
  body.shell input[type="checkbox"]:checked::after {
    content: "";
    position: absolute;
    left: 6.5px;
    top: 3px;
    width: 5px;
    height: 10px;
    border: 2px solid #fff;
    border-top: 0;
    border-left: 0;
    transform: rotate(45deg);
  }

  /* —— Segmented control —— */
  body.shell .ag-seg,
  body.shell .hub-seg,
  body.shell .prospeccao-main-seg,
  body.shell .prospeccao-tipo-seg,
  body.shell .prospeccao-envio-seg,
  body.shell .prospeccao-busca-view-seg,
  body.shell .comissao-tabs,
  body.shell .campo-pills,
  body.shell .entry-modes {
    display: flex;
    flex-wrap: nowrap;
    width: calc(100% - 32px);
    max-width: none;
    margin: 0 16px 14px;
    padding: 2px;
    gap: 0;
    background: var(--ios-fill) !important;
    border: 0 !important;
    border-radius: 9px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  body.shell .ag-seg::-webkit-scrollbar,
  body.shell .hub-seg::-webkit-scrollbar {
    display: none;
  }
  body.shell .ag-seg-btn,
  body.shell .comissao-tab,
  body.shell .campo-pill,
  body.shell .entry-mode {
    flex: 1 1 0;
    min-width: 0;
    min-height: 28px;
    margin: 0;
    padding: 5px 8px;
    border: 0 !important;
    border-radius: 7px;
    background: transparent !important;
    color: #000 !important;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: -0.01em;
    white-space: nowrap;
    box-shadow: none !important;
  }
  body.shell .ag-seg-btn.is-on,
  body.shell .comissao-tab.is-on,
  body.shell .campo-pill.on,
  body.shell .entry-mode.is-on {
    background: #fff !important;
    color: #000 !important;
    box-shadow: 0 0.5px 1px rgba(0, 0, 0, 0.12), 0 3px 8px rgba(0, 0, 0, 0.04) !important;
  }

  /* —— Inset grouped chrome —— */
  body.shell .panel,
  body.shell .table-panel,
  body.shell .campanha-compose,
  body.shell .clients-page-panel,
  body.shell .ag-list-panel,
  body.shell .ag-rotas-panel,
  body.shell .venda-form-panel,
  body.shell .venda-itens-panel,
  body.shell .comissao-table-panel,
  body.shell .empty-card {
    background: #fff !important;
    border: 0 !important;
    box-shadow: none !important;
    border-radius: 10px;
    margin: 0 16px 16px;
    padding: 0;
    overflow: hidden;
  }
  body.shell .ag-list-panel,
  body.shell .clients-page-panel,
  body.shell .campanha-list-panel,
  body.shell .table-panel {
    background: transparent !important;
    overflow: visible;
    padding: 0;
    margin-left: 0;
    margin-right: 0;
  }
  body.shell .campanha-compose {
    padding: 0 0 8px;
  }
  body.shell .f-label,
  body.shell .prospeccao-cidade-select span,
  body.shell .prospeccao-cidade-field span,
  body.shell .campanha-msg-label .f-label,
  body.shell .entry-field > span,
  body.shell .client-form-grid label > span,
  body.shell .venda-form-grid label > span {
    display: block;
    font-size: 13px !important;
    font-weight: 400 !important;
    letter-spacing: -0.08px;
    text-transform: none !important;
    color: var(--ios-label) !important;
    padding: 8px 16px 0;
  }
  body.shell .campanha-hint {
    font-size: 13px !important;
    color: var(--ios-label) !important;
    font-family: var(--font) !important;
    padding: 0 16px 8px;
    margin: 0;
  }
  body.shell .campanha-compose .entry-input,
  body.shell .campanha-compose select,
  body.shell .ag-rota-create input {
    border-radius: 0;
    background: transparent !important;
    padding: 11px 16px;
    min-height: 44px;
  }
  body.shell .campanha-actions,
  body.shell .prospeccao-paste-head {
    display: grid;
    gap: 8px;
    padding: 8px 16px 12px;
  }
  body.shell .campanha-actions .btn,
  body.shell .prospeccao-paste-head .btn {
    width: 100%;
  }
  body.shell .prospeccao-regras {
    list-style: none;
    margin: 0;
    padding: 8px 16px 14px;
    background: transparent !important;
    color: var(--ios-label);
    font-size: 13px;
    line-height: 1.35;
  }
  body.shell .prospeccao-regras li + li {
    margin-top: 6px;
  }
  body.shell .prospeccao-regras strong {
    color: #000;
    font-weight: 600;
  }
  body.shell .prospeccao-wa-btn {
    background: #25d366 !important;
    color: #fff !important;
    border: 0 !important;
  }

  /* —— Sticky search —— */
  body.shell .campanha-toolbar,
  body.shell .ag-toolbar,
  body.shell .clients-toolbar,
  body.shell .vendas-toolbar {
    display: grid;
    gap: 8px;
    position: sticky;
    top: calc(var(--nav-h) + env(safe-area-inset-top, 0px) - 1px);
    z-index: 16;
    margin: 0;
    padding: 0 16px 10px;
    background: rgba(242, 242, 247, 0.92);
    backdrop-filter: saturate(1.8) blur(20px);
    -webkit-backdrop-filter: saturate(1.8) blur(20px);
    overflow: visible;
  }
  body.shell .campanha-city-clear[hidden] {
    display: none !important;
  }
  body.shell .campanha-city-clear {
    min-height: 36px !important;
    width: 100%;
    font-size: 15px !important;
    font-weight: 400 !important;
  }
  body.shell .campanha-cel-filter {
    display: flex !important;
    align-items: center;
    gap: 8px;
    min-height: 36px;
    margin: 0 !important;
    padding: 0 10px 0 12px !important;
    border-radius: 10px;
    background: var(--ios-fill);
    font-size: 13px !important;
    font-weight: 600;
    color: #000 !important;
  }
  body.shell .campanha-cel-filter input {
    appearance: none !important;
    -webkit-appearance: none !important;
    width: 42px !important;
    height: 26px !important;
    min-width: 42px !important;
    border: 0 !important;
    border-radius: 13px !important;
    background: #e9e9eb !important;
    box-shadow: none !important;
    position: relative;
    flex: 0 0 42px;
  }
  body.shell .campanha-cel-filter input:checked {
    background: #34c759 !important;
    border: 0 !important;
  }
  body.shell .campanha-cel-filter input::after {
    content: "" !important;
    position: absolute;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #fff !important;
    border: 0 !important;
    top: 2px;
    left: 2px;
    transform: none !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  }
  body.shell .campanha-cel-filter input:checked::after {
    left: 18px;
    border: 0 !important;
    background: #fff !important;
    transform: none !important;
  }
  body.shell .campanha-city-search-wrap,
  body.shell .clients-search-row,
  body.shell .ag-search,
  body.shell .pedidos-search {
    max-width: none !important;
    width: 100%;
  }
  body.shell .ag-search {
    margin: 0;
    max-width: none;
  }
  body.shell .campanha-city-search-icon {
    display: none;
  }

  /* Carteira search: field + circular tools */
  body.shell .ag-toolbar.carteira-searchbar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    border-bottom: 0;
    padding-bottom: 12px;
  }
  body.shell .carteira-searchbar .ios-search-field {
    display: flex;
    align-items: center;
    grid-column: 1;
    width: auto;
    min-width: 0;
    min-height: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--ios-fill-2);
  }
  body.shell .carteira-searchbar .ios-search-ico {
    width: 32px;
    height: 36px;
    color: #8e8e93;
  }
  body.shell .carteira-searchbar .ios-search-field .ag-search,
  body.shell .carteira-searchbar .ios-search-field #agBusca {
    flex: 1 1 auto;
    width: auto;
    min-width: 0;
    margin: 0 !important;
    min-height: 36px !important;
    height: 36px;
    padding: 0 8px 0 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    background-image: none !important;
    font-size: 17px !important;
    font-weight: 400 !important;
    letter-spacing: -0.022em;
  }
  body.shell .carteira-searchbar .ios-search-tools {
    display: flex;
    align-items: center;
    grid-column: 2;
    height: 36px;
    gap: 8px;
    padding: 0;
  }
  body.shell .carteira-searchbar .ios-search-tool {
    flex: 0 0 36px;
    width: 36px !important;
    height: 36px !important;
    border-radius: 18px;
    background: var(--ios-fill-2);
    color: #8e8e93;
  }
  body.shell .carteira-searchbar .ios-search-tool.is-on,
  body.shell .carteira-searchbar .ios-search-tool:has(input:checked),
  body.shell .carteira-searchbar .ios-search-tool[aria-expanded="true"] {
    color: var(--ios-tint);
    background: rgba(225, 6, 0, 0.1);
  }
  body.shell .carteira-searchbar .ios-search-tool.ios-chip-check input,
  body.shell .carteira-searchbar .ios-search-tool #agFiltroCelular {
    position: absolute !important;
    inset: 0 !important;
    opacity: 0 !important;
    width: 100% !important;
    height: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    background: none !important;
    cursor: pointer;
  }
  body.shell .carteira-searchbar .ios-search-tool.ios-chip-check input::after,
  body.shell .carteira-searchbar .ios-search-tool #agFiltroCelular::after,
  body.shell .carteira-searchbar .ios-search-tool.ios-chip-check input:checked::after,
  body.shell .carteira-searchbar .ios-search-tool #agFiltroCelular:checked::after {
    content: none !important;
    display: none !important;
  }
  body.shell .carteira-searchbar #agCityPicker {
    flex: none;
    grid-column: 1 / -1;
    width: 100%;
    min-width: 0;
    max-width: none;
    gap: 8px;
  }
  body.shell .carteira-searchbar #agCityPicker:not(.is-open) .campanha-city-search-wrap {
    display: none !important;
  }
  body.shell .carteira-searchbar #agCidadeBusca {
    min-height: 36px !important;
    height: 36px;
    font-size: 17px !important;
    background: var(--ios-fill-2) !important;
  }
  body.shell .carteira-searchbar .ios-city-active {
    gap: 6px 8px;
  }
  body.shell .carteira-searchbar .ios-city-clear {
    min-height: 28px;
    padding: 0 2px;
    background: transparent !important;
    border: 0 !important;
    color: var(--ios-tint) !important;
    font-size: 15px !important;
    font-weight: 400 !important;
    box-shadow: none !important;
  }
  body.shell .carteira-searchbar .campanha-city-tag {
    height: 28px;
    background: rgba(120, 120, 128, 0.12);
    font-size: 13px;
    font-weight: 500;
  }
  body.shell .carteira-searchbar .campanha-city-menu {
    border: 0;
    border-radius: 12px;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.18);
  }

  /* —— Lists —— */
  body.shell .clients-table-wrap,
  body.shell .table-wrap {
    margin: 0 16px 16px;
    border: 0 !important;
    border-radius: 10px;
    overflow: hidden;
    background: #fff;
  }
  body.shell .clients-table thead,
  body.shell .ag-table thead,
  body.shell .prospeccao-table thead,
  body.shell .vendas-table thead,
  body.shell .comissao-table thead,
  body.shell .visao-pedidos-table thead,
  body.shell .table-wrap > table thead {
    display: none !important;
  }
  body.shell .ag-pill {
    text-transform: none;
    letter-spacing: -0.01em;
    font-size: 12px;
    font-weight: 600;
    padding: 3px 8px;
  }
  body.shell .carteira-table tbody tr:active,
  body.shell .vendas-table tbody tr:active {
    background: #d1d1d6 !important;
  }
  body.shell .prospeccao-table .campanha-inline {
    background: transparent !important;
    border-radius: 0;
    border: 0 !important;
    border-bottom: 0.33px solid var(--ios-sep-opaque) !important;
    min-height: 36px;
    padding: 6px 0;
    font-size: 17px !important;
  }
  body.shell .prospeccao-table .prosp-nome .campanha-inline {
    border-bottom: 0 !important;
    font-weight: 600;
    min-height: 24px;
    padding: 0;
  }
  body.shell .vendas-row-actions [data-open-pedido] {
    display: none;
  }

  /* —— Selection toolbar —— */
  body.shell .carteira-selbar[hidden] {
    display: none !important;
  }
  body.shell .carteira-selbar:not([hidden]) {
    position: fixed;
    left: 0;
    right: 0;
    bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px));
    z-index: 40;
    display: flex !important;
    flex-wrap: nowrap;
    align-items: center;
    justify-content: space-between;
    gap: 4px 8px;
    margin: 0;
    padding: 0 4px;
    border: 0;
    border-radius: 0;
    border-top: 0.33px solid var(--ios-sep-opaque);
    background: rgba(249, 249, 249, 0.94) !important;
    backdrop-filter: saturate(1.8) blur(20px);
    -webkit-backdrop-filter: saturate(1.8) blur(20px);
    box-shadow: none;
  }
  body.shell #agendamentoRoot.is-selecting .ag-list-panel,
  body.shell #agendamentoRoot.is-selecting .ag-rotas-panel {
    padding-bottom: 52px;
  }
  body.shell .carteira-selbar-meta {
    display: none;
  }
  body.shell .carteira-selbar-btns {
    display: flex;
    flex: 1 1 auto;
    justify-content: space-around;
    gap: 0;
  }
  body.shell .carteira-selbar .btn,
  body.shell .carteira-selbar .btn.ghost,
  body.shell .carteira-selbar .btn.primary {
    width: auto !important;
    min-height: 44px !important;
    margin: 0;
    padding: 0 8px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: var(--ios-blue) !important;
    font-size: 17px !important;
    font-weight: 400;
    box-shadow: none !important;
  }
  body.shell .carteira-selbar .btn.primary {
    color: var(--ios-tint) !important;
    font-weight: 600;
  }
  body.shell .carteira-selbar strong {
    font-size: 13px;
    font-weight: 600;
  }

  /* —— KPIs / rank / filters —— */
  body.shell .kpis {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.33px;
    margin: 0 16px 16px;
    background: var(--ios-sep-opaque);
    border-radius: 10px;
    overflow: hidden;
  }
  body.shell .kpi {
    appearance: none;
    width: 100%;
    text-align: left;
    font: inherit;
    cursor: pointer;
    min-height: 0;
    margin: 0;
    padding: 12px 14px 14px;
    border: 0 !important;
    border-radius: 0;
    background: #fff !important;
    box-shadow: none !important;
    animation: none;
  }
  body.shell .kpi.clickable::after {
    display: none;
  }
  body.shell .kpi.clickable:hover {
    transform: none;
  }
  body.shell .kpi.clickable.on {
    background: #fff5f5 !important;
  }
  body.shell .kpi span {
    font-size: 13px;
    font-weight: 400;
    letter-spacing: -0.08px;
    text-transform: none;
    color: var(--ios-label);
    padding: 0;
  }
  body.shell .kpi strong {
    display: block;
    margin-top: 2px;
    font-family: var(--display) !important;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.03em;
    color: #000 !important;
    background: none !important;
    -webkit-text-fill-color: #000;
    filter: none;
  }
  body.shell .kpi em {
    font-size: 12px;
    font-style: normal;
    color: var(--ios-label);
  }
  body.shell .rank {
    display: block;
    margin: 0;
    background: #fff;
    border-radius: 0;
    overflow: hidden;
  }
  body.shell .rank-item {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) auto;
    gap: 10px;
    align-items: center;
    min-height: 44px;
    padding: 10px 16px;
    border: 0;
    border-radius: 0;
    background: #fff !important;
    border-bottom: 0.33px solid var(--ios-sep-opaque);
  }
  body.shell .rank-item:last-child {
    border-bottom: 0;
  }
  body.shell .rank-item .n {
    font-family: var(--font);
    font-variant-numeric: tabular-nums;
    font-size: 15px;
    color: var(--ios-label);
  }
  body.shell .rank-item .name {
    font-size: 17px;
    font-weight: 400;
    color: #000;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  body.shell .rank-item .val {
    font-size: 15px;
    color: var(--ios-label);
    font-variant-numeric: tabular-nums;
  }
  body.shell .panel > header,
  body.shell .table-head,
  body.shell .table-title h2,
  body.shell .venda-itens-head h2,
  body.shell .ag-rotas-title {
    font-family: var(--font) !important;
    font-size: 13px !important;
    font-weight: 400 !important;
    color: var(--ios-label) !important;
    letter-spacing: -0.08px;
    text-transform: uppercase;
    margin: 0;
    padding: 16px 16px 8px;
    background: transparent;
  }
  body.shell .panel > header p,
  body.shell .ag-rotas-lede {
    display: none;
  }
  body.shell .pedidos-controls,
  body.shell .filters,
  body.shell .month-bar,
  body.shell .month-meta {
    display: grid;
    gap: 8px;
    margin: 0 16px 16px;
    padding: 0;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }
  body.shell .month-year {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #fff;
    border-radius: 10px;
    min-height: 44px;
    padding: 0 4px;
  }
  body.shell .month-year button {
    width: 44px;
    height: 44px;
    border: 0;
    background: transparent;
    color: var(--ios-tint);
    font-size: 22px;
    border-radius: 0;
  }
  body.shell .month-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.33px;
    background: var(--ios-sep-opaque);
    border-radius: 10px;
    overflow: hidden;
  }
  body.shell .month-chip {
    border: 0 !important;
    border-radius: 0;
    background: #fff !important;
    color: #000 !important;
    min-height: 44px;
    font-size: 15px;
    font-weight: 400;
    box-shadow: none !important;
    transform: none !important;
  }
  body.shell .month-chip.on {
    background: var(--ios-tint) !important;
    color: #fff !important;
    font-weight: 600;
  }
  body.shell .status-trigger,
  body.shell .table-tools label,
  body.shell .comissao-year-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    min-height: 44px;
    padding: 0 16px;
    background: #fff;
    border: 0 !important;
    border-radius: 10px;
    box-shadow: none !important;
  }
  body.shell .status-trigger-label {
    text-transform: none;
    letter-spacing: 0;
    font-size: 17px;
    font-weight: 400;
    color: #000;
  }
  body.shell .status-pop {
    left: 16px;
    right: 16px;
    min-width: 0;
    border: 0;
    border-radius: 14px;
    background: rgba(242, 242, 247, 0.96);
    backdrop-filter: blur(20px);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.18);
  }
  body.shell .status-opt {
    background: #fff;
    border: 0;
    border-radius: 0;
    min-height: 44px;
    font-weight: 400;
  }
  body.shell .status-pop .status-actions {
    justify-content: space-between;
    margin-top: 8px;
  }
  body.shell .status-pop .status-actions .btn {
    min-height: 44px;
  }
  body.shell .cnpj-import {
    background: #fff;
    border-radius: 10px;
    padding: 8px 16px 12px;
  }
  body.shell .cnpj-upload {
    width: 100%;
    min-height: 44px;
  }
  body.shell .pager {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 16px 8px;
    padding: 0;
  }
  body.shell .pager .btn {
    flex: 1;
    min-height: 44px;
    font-weight: 400;
  }

  /* —— Comissões / rotas —— */
  body.shell .comissao-months {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
    margin: 0 16px 16px;
  }
  body.shell .comissao-month {
    min-height: 76px;
    padding: 12px;
    border: 0 !important;
    border-radius: 10px;
    background: #fff !important;
    box-shadow: none !important;
  }
  body.shell .comissao-month.is-selected {
    outline: 2px solid var(--ios-tint);
    outline-offset: -2px;
  }
  body.shell .comissao-month small,
  body.shell .comissao-month .mono {
    font-family: var(--font) !important;
    color: var(--ios-label);
  }
  body.shell .ag-rotas-panel {
    margin: 0 16px 16px;
    padding: 0 0 12px;
    overflow: visible;
  }
  body.shell .ag-rotas-head,
  body.shell .ag-rota-create {
    display: grid;
    gap: 8px;
    padding: 0 0 8px;
  }
  body.shell .ag-rota-card {
    border: 0;
    border-radius: 10px;
    background: #fff;
    box-shadow: none;
  }

  /* —— Sheets / modals —— */
  body.shell .track-modal {
    align-items: flex-end;
    padding: 0;
    background: rgba(0, 0, 0, 0.4);
  }
  body.shell .track-modal[hidden] {
    display: none !important;
  }
  body.shell .track-modal-panel,
  body.shell .ag-wa-panel,
  body.shell .client-form-panel,
  body.shell .ag-sheet-panel {
    width: 100% !important;
    max-width: none !important;
    max-height: min(92dvh, 920px);
    margin: 0;
    border: 0 !important;
    border-radius: 14px 14px 0 0 !important;
    background: var(--ios-bg) !important;
    color: #000 !important;
    box-shadow: none !important;
    padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  }
  body.shell .venda-share-panel {
    width: 100% !important;
    max-width: none !important;
    margin: 0;
    border: 0 !important;
    border-radius: 14px 14px 0 0 !important;
    background: var(--ios-bg) !important;
    color: #000 !important;
    box-shadow: none !important;
    padding-bottom: 12px !important;
  }
  body.shell .venda-share-sheet:not([hidden]) {
    z-index: 2100 !important;
    padding: 0 0 calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px) + 8px) !important;
    align-items: end;
    box-sizing: border-box;
  }
  body.shell.venda-share-open .app-tabbar,
  body.shell.venda-share-open .app-tabbar:not([hidden]) {
    z-index: 400 !important;
  }
  body.shell .track-modal-panel::before,
  body.shell .ag-sheet-panel::before,
  body.shell .venda-share-panel::before,
  body.shell .ag-wa-panel::before {
    content: "";
    display: block;
    width: 36px;
    height: 5px;
    margin: 6px auto 2px;
    border-radius: 3px;
    background: rgba(60, 60, 67, 0.3);
  }
  body.shell .track-modal-head,
  body.shell .venda-share-head {
    background: transparent !important;
    border-bottom: 0.33px solid var(--ios-sep-opaque);
    padding: 8px 16px 12px;
  }
  body.shell .track-modal-head h2,
  body.shell .venda-share-head h2,
  body.shell .track-modal-head #agSheetTitle {
    font-family: var(--display) !important;
    font-size: 17px !important;
    font-weight: 600;
    letter-spacing: -0.022em;
    color: #000 !important;
    text-align: left;
  }
  body.shell .track-eyebrow {
    font-size: 13px;
    color: var(--ios-label);
    text-transform: none;
    letter-spacing: 0;
  }
  body.shell .track-close,
  body.shell .icon-btn {
    width: 30px;
    height: 30px;
    border: 0;
    border-radius: 999px;
    background: var(--ios-fill);
    color: #000;
    font-size: 18px;
  }
  body.shell .ag-actions {
    display: grid;
    gap: 0;
    margin: 8px 16px 16px;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
  }
  body.shell .ag-action {
    min-height: 56px;
    padding: 10px 16px;
    border: 0;
    border-bottom: 0.33px solid var(--ios-sep-opaque);
    border-radius: 0;
    background: #fff;
  }
  body.shell .ag-action:last-child {
    border-bottom: 0;
  }
  body.shell .ag-action:active {
    background: #d1d1d6;
  }
  body.shell .ag-schedule-box,
  body.shell .ag-nota-label,
  body.shell .client-form,
  body.shell .venda-form-grid,
  body.shell .ag-wa-body {
    margin: 0 16px 12px;
    padding: 0;
    background: #fff;
    border: 0;
    border-radius: 10px;
    overflow: hidden;
  }
  body.shell .ag-schedule-box input,
  body.shell .ag-nota-label textarea,
  body.shell .client-form input,
  body.shell .client-form select,
  body.shell .venda-form-grid input,
  body.shell .venda-form-grid select,
  body.shell .venda-form-grid textarea,
  body.shell .ag-wa-body textarea {
    background: transparent !important;
    border-radius: 0;
  }
  body.shell .ag-clear-btn,
  body.shell .client-form-actions,
  body.shell .ag-schedule-actions,
  body.shell .track-modal-foot {
    display: flex;
    gap: 8px;
    padding: 8px 16px 0;
    background: transparent;
    border: 0;
  }
  body.shell .ag-clear-btn,
  body.shell .client-form-actions .btn,
  body.shell .ag-schedule-actions .btn,
  body.shell .track-modal-foot .btn {
    flex: 1;
  }
  body.shell .venda-share-actions {
    margin: 8px 8px 0;
    display: grid;
    gap: 0;
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
  }
  body.shell .venda-share-opt,
  body.shell .btn.venda-share-opt {
    width: 100%;
    min-height: 56px;
    border: 0 !important;
    border-radius: 0 !important;
    border-bottom: 0.33px solid var(--ios-sep-opaque) !important;
    background: #fff !important;
    color: var(--ios-tint) !important;
    font-size: 20px !important;
    font-weight: 400 !important;
  }
  body.shell .venda-share-opt:last-child {
    border-bottom: 0 !important;
  }
  body.shell .ios-sheet-row,
  body.shell .ios-sheet-cancel {
    font-size: 20px;
  }

  /* —— Login —— */
  body.shell .entry {
    padding: 24px 16px 40px;
  }
  body.shell .entry-inner {
    max-width: 100%;
  }
  body.shell .entry-brand {
    font-family: var(--display) !important;
    font-size: 34px;
    font-weight: 700;
    letter-spacing: -0.043em;
  }
  body.shell .entry-auth {
    width: 100%;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    padding: 0 0 12px;
  }
  body.shell .entry-field {
    display: block;
    border-bottom: 0.33px solid var(--ios-sep-opaque);
  }
  body.shell .entry-submit {
    width: calc(100% - 32px);
    margin: 12px 16px 0;
  }

  /* —— Busca / auditoria groups —— */
  body.shell .prospeccao-busca-grupos,
  body.shell .prospeccao-busca-group {
    margin: 0 16px 16px;
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
  }
  body.shell .prospeccao-busca-group h3 {
    margin: 0;
    padding: 16px 16px 6px;
    font-size: 13px;
    font-weight: 400;
    color: var(--ios-label);
    text-transform: uppercase;
    letter-spacing: -0.08px;
    background: var(--ios-bg);
  }
  body.shell .prospeccao-busca-line {
    min-height: 44px;
    padding: 10px 16px;
    border-bottom: 0.33px solid var(--ios-sep-opaque);
    background: #fff;
    font-size: 17px;
  }
  body.shell .prospeccao-busca-line:last-child {
    border-bottom: 0;
  }

  /* —— Tab bar —— */
  body.shell .app-tabbar:not([hidden]) {
    height: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px));
    padding: 4px 0 env(safe-area-inset-bottom, 0px);
    background: rgba(249, 249, 249, 0.94);
    border-top: 0.33px solid var(--ios-sep-opaque);
    backdrop-filter: saturate(1.8) blur(20px);
    -webkit-backdrop-filter: saturate(1.8) blur(20px);
  }
  body.shell .app-tab {
    color: #8e8e93;
    font-size: 10px;
    font-weight: 500;
    letter-spacing: -0.24px;
  }
  body.shell .app-tab.is-on {
    color: var(--ios-tint);
  }
  body.shell .app-tab.is-copied {
    color: #34c759 !important;
  }
  body.shell .app-tab.is-copied .app-tab-ico svg {
    stroke: #34c759;
  }
  body.shell .app-tab-ico svg {
    width: 25px;
    height: 25px;
  }
  body.shell .ios-toast:not([hidden]) {
    bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px) + 16px);
    background: rgba(28, 28, 30, 0.92);
    border-radius: 14px;
    font-size: 15px;
    font-weight: 400;
  }

  body.shell .status-pill {
    border: 0;
    font-size: 12px;
    font-weight: 600;
  }
  body.shell .status-pill.pendente {
    background: rgba(255, 59, 48, 0.12);
    color: #d70015;
  }
  body.shell .status-pill.finalizado {
    background: rgba(52, 199, 89, 0.14);
    color: #248a3d;
  }
  body.shell .status-pill.rascunho {
    background: var(--ios-fill);
    color: #636366;
  }

  body.shell .client-form-grid,
  body.shell .venda-form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0;
  }
  body.shell .client-form-grid label,
  body.shell .venda-form-grid label {
    border-bottom: 0.33px solid var(--ios-sep-opaque);
  }
}

/* —— Mobile layout lock: page scrolls, tab bar fixed, no sideways pan —— */
@media (max-width: 860px) {
  html,
  body.shell {
    display: block !important;
    height: auto !important;
    min-height: 100% !important;
    max-width: 100vw !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch;
  }
  body.shell .content,
  body.shell #appRoot,
  body.shell #agendamentoRoot,
  body.shell #prospeccaoRoot,
  body.shell #resultadosHub,
  body.shell #reportRoot,
  body.shell #vendasRoot,
  body.shell #comissoesRoot {
    overflow: visible !important;
    max-width: 100% !important;
    min-width: 0 !important;
    min-height: 0 !important;
    width: 100% !important;
  }
  body.shell .clients-table-wrap,
  body.shell .table-wrap,
  body.shell .ag-rota-card,
  body.shell .ag-rotas-panel {
    max-width: 100% !important;
    min-width: 0 !important;
  }
  body.shell .clients-table-wrap,
  body.shell .table-wrap {
    overflow: visible !important;
  }

  body.shell .app-tabbar,
  body.shell .app-tabbar:not([hidden]) {
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    position: fixed !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    z-index: 400 !important;
    width: 100% !important;
    max-width: 100vw !important;
    transform: none !important;
    margin: 0 !important;
  }
  body.shell.is-locked .app-tabbar,
  body.shell.is-locked .app-tabbar:not([hidden]) {
    display: none !important;
  }

  /* Carteira: compact segmented control */
  body.shell .ag-seg.ag-seg-scroll {
    display: flex !important;
    flex-wrap: nowrap !important;
    gap: 0 !important;
    width: calc(100% - 32px) !important;
    max-width: calc(100vw - 32px) !important;
    margin: 4px 16px 12px !important;
    padding: 2px !important;
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    background: var(--ios-fill) !important;
    border-radius: 9px !important;
  }
  body.shell .ag-seg-scroll::-webkit-scrollbar {
    display: none;
  }
  body.shell .ag-seg-scroll .ag-seg-btn {
    flex: 0 0 auto !important;
    min-width: auto !important;
    max-width: none;
    min-height: 32px !important;
    margin: 0;
    padding: 6px 12px !important;
    border-radius: 7px !important;
    background: transparent !important;
    color: #000 !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    line-height: 1.2;
    box-shadow: none !important;
    display: inline-flex !important;
    flex-direction: row;
    align-items: baseline;
    justify-content: center;
    gap: 4px;
    white-space: nowrap;
  }
  body.shell .ag-seg-scroll .ag-seg-name {
    display: inline;
    font-size: 13px;
    font-weight: 600;
  }
  body.shell .ag-seg-scroll .ag-seg-count {
    display: inline;
    font-size: 11px;
    font-weight: 600;
    color: var(--ios-label);
    font-variant-numeric: tabular-nums;
  }
  body.shell .ag-seg-scroll .ag-seg-btn.is-on {
    background: #fff !important;
    color: #000 !important;
    box-shadow: 0 0.5px 1px rgba(0, 0, 0, 0.12), 0 3px 8px rgba(0, 0, 0, 0.04) !important;
  }
  body.shell .ag-seg-scroll .ag-seg-btn.is-on .ag-seg-count {
    color: var(--ios-tint);
  }
  body.shell .ag-seg-scroll .ag-seg-count[hidden] {
    display: none !important;
  }
  body.shell .ios-sheet-row[hidden] {
    display: none !important;
  }

  /* Selection: clear check, not a red ball */
  body.shell .carteira-table tbody tr.is-selected,
  body.shell .prospeccao-table tbody tr.is-selected {
    background: rgba(225, 6, 0, 0.06) !important;
  }
  body.shell input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 24px !important;
    height: 24px !important;
    border: 2px solid #c7c7cc !important;
    border-radius: 50%;
    background: #fff !important;
    box-shadow: none !important;
  }
  body.shell input[type="checkbox"]:checked {
    background: #fff !important;
    border-color: var(--ios-tint) !important;
  }
  body.shell input[type="checkbox"]:checked::after {
    content: "";
    position: absolute;
    left: 6px;
    top: 3px;
    width: 7px;
    height: 12px;
    border: 2.5px solid var(--ios-tint);
    border-top: 0;
    border-left: 0;
    transform: rotate(45deg);
    background: none;
  }
  body.shell .campanha-cel-filter #agFiltroCelular,
  body.shell .campanha-cel-filter input[type="checkbox"] {
    width: 42px !important;
    height: 26px !important;
    min-width: 42px !important;
    border: 0 !important;
    border-radius: 13px !important;
    background: #e9e9eb !important;
  }
  body.shell .campanha-cel-filter #agFiltroCelular:checked,
  body.shell .campanha-cel-filter input[type="checkbox"]:checked {
    background: #34c759 !important;
    border: 0 !important;
  }
  body.shell .campanha-cel-filter #agFiltroCelular::after,
  body.shell .campanha-cel-filter input[type="checkbox"]::after,
  body.shell .campanha-cel-filter #agFiltroCelular:checked::after,
  body.shell .campanha-cel-filter input[type="checkbox"]:checked::after {
    content: "" !important;
    width: 22px !important;
    height: 22px !important;
    left: 2px !important;
    top: 2px !important;
    border: 0 !important;
    border-radius: 50% !important;
    background: #fff !important;
    transform: none !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
  }
  body.shell .campanha-cel-filter #agFiltroCelular:checked::after,
  body.shell .campanha-cel-filter input[type="checkbox"]:checked::after {
    left: 18px !important;
  }
  body.shell .ios-chip-check input,
  body.shell .ios-chip-check #agFiltroCelular {
    position: absolute !important;
    opacity: 0 !important;
    width: 0 !important;
    height: 0 !important;
    min-width: 0 !important;
    min-height: 0 !important;
    border: 0 !important;
    pointer-events: none !important;
    background: none !important;
  }
  body.shell .ios-chip-check input::after,
  body.shell .ios-chip-check #agFiltroCelular::after,
  body.shell .ios-chip-check input:checked::after,
  body.shell .ios-chip-check #agFiltroCelular:checked::after {
    content: none !important;
    display: none !important;
  }
  body.shell .campanha-check-col {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding-top: 2px !important;
    min-width: 36px;
  }

  /* Resultados: compact pedido cards */
  body.shell .visao-pedidos-table,
  body.shell .visao-pedidos-table tbody {
    display: block !important;
    width: 100%;
  }
  body.shell .visao-pedidos-table tbody tr.pedido-card {
    display: block !important;
    padding: 0 !important;
    min-height: 0 !important;
    max-height: none !important;
    background: #fff !important;
  }
  body.shell .visao-pedidos-table tbody tr.pedido-card td {
    display: block !important;
    padding: 8px 16px !important;
    font-size: 13px;
  }
  body.shell .visao-pedidos-table tbody td::before,
  body.shell .visao-pedidos-table tbody td::after {
    content: none !important;
    display: none !important;
  }
  body.shell .visao-pedidos-table tbody tr:has(td[colspan]):not(.pedido-card) {
    display: block !important;
    padding: 28px 16px !important;
    text-align: center;
    color: var(--ios-label);
  }
  body.shell .visao-pedidos-table tbody tr:has(td[colspan]):not(.pedido-card) td {
    display: block !important;
  }

  body.shell .comissao-table tbody tr {
    padding: 10px 14px;
  }
  body.shell .vendas-table tbody tr {
    padding: 10px 14px;
  }

  /* Rotas: wrap, compact buttons, no sideways */
  body.shell .ag-rota-card-head,
  body.shell .ag-rota-tools,
  body.shell .ag-rota-add-row,
  body.shell .ag-rota-add,
  body.shell .ag-rota-client,
  body.shell .ag-rota-client-fields {
    flex-wrap: wrap !important;
    min-width: 0 !important;
    max-width: 100% !important;
  }
  body.shell .ag-rota-card-head {
    display: grid !important;
    grid-template-columns: 1fr;
    gap: 10px;
  }
  body.shell .ag-rota-tools {
    display: grid !important;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    width: 100%;
  }
  body.shell .ag-rota-tools .btn,
  body.shell .ag-rota-add .btn,
  body.shell .ag-rota-wa-btn,
  body.shell .ag-rota-create .btn {
    min-height: 36px !important;
    width: 100%;
    font-size: 14px !important;
    padding: 0 10px !important;
    white-space: nowrap;
  }
  body.shell .ag-rota-tools .btn:last-child {
    grid-column: 1 / -1;
  }
  body.shell .ag-rota-add-row {
    display: grid !important;
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 0 12px 12px !important;
  }
  body.shell .ag-rota-add {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    padding: 0 !important;
    width: 100%;
  }
  body.shell .ag-rota-city-select,
  body.shell .ag-rota-create input {
    min-width: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  body.shell .ag-rota-wa-btn {
    width: 100% !important;
  }
  body.shell .ag-rota-client {
    display: grid !important;
    grid-template-columns: 28px minmax(0, 1fr) !important;
    gap: 8px !important;
  }
  body.shell .ag-rota-clients {
    max-height: none !important;
    overflow: visible !important;
  }
  body.shell .ag-rota-client-side {
    grid-column: 2;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: wrap;
  }
  body.shell .ag-rota-client-fields {
    grid-template-columns: 1fr !important;
  }
  body.shell .ag-rota-create {
    display: grid !important;
    grid-template-columns: 1fr;
    width: 100%;
    min-width: 0;
  }

  /* Busca etapas colors */
  body.shell #prospeccaoBuscaEtapas {
    list-style: none;
    padding: 8px 16px 14px;
    margin: 0;
    background: transparent !important;
  }
  body.shell .prospeccao-etapa {
    font-size: 15px;
    font-weight: 600;
    line-height: 1.35;
    padding: 6px 0;
    letter-spacing: -0.016em;
  }
  body.shell .prospeccao-etapa.is-done {
    color: #1c7c3a;
  }
  body.shell .prospeccao-etapa.is-skip {
    color: #007aff;
  }
  body.shell .prospeccao-etapa.is-pending {
    color: #d70015;
  }
  body.shell .prospeccao-etapa.is-err {
    color: #d70015;
  }

  body.shell .prospeccao-cidade-field,
  body.shell .prospeccao-cidade-select {
    max-width: none !important;
    min-width: 0 !important;
    width: 100%;
  }
  body.shell .prospeccao-cidade-field select,
  body.shell .prospeccao-cidade-select select {
    width: 100%;
  }

  /* Login: never show gate and app at the same time */
  body.shell.is-locked {
    padding-bottom: 0 !important;
  }
  body.shell.is-locked .mobile-bar {
    background: transparent !important;
    border: 0 !important;
  }
  body.shell.is-locked .mobile-brand {
    position: static;
    opacity: 1;
    width: auto;
    pointer-events: auto;
    transform: none;
  }
  body.shell #vendorGate[hidden],
  body.shell:not(.is-locked) #vendorGate,
  body.shell #appRoot[hidden] {
    display: none !important;
  }
  html:not(.boot-session) body.shell.is-locked #appRoot {
    display: none !important;
  }
  html:not(.boot-session) body.shell.is-locked #vendorGate:not([hidden]) {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }
  html.boot-session body.shell.is-locked #vendorGate {
    display: none !important;
  }
  html.boot-session body.shell.is-locked #appRoot {
    display: block !important;
  }
  body.shell.is-locked #vendorGate:not([hidden]) {
    min-height: 100dvh;
    padding: 24px 20px 40px;
    overflow: auto;
  }
  body.shell .entry-inner {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
  }
  body.shell .entry-logo .mark,
  body.shell .entry-logo {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    margin: 0 auto 12px;
  }
  body.shell .entry-brand {
    text-align: center;
    font-family: var(--display) !important;
    font-size: 34px !important;
    font-weight: 700;
    letter-spacing: -0.043em;
    margin: 0 0 4px;
  }
  body.shell .entry-line,
  body.shell .entry .eyebrow {
    text-align: center;
    color: var(--ios-label);
    font-size: 15px;
  }
  body.shell .entry-modes {
    width: 100% !important;
    margin: 18px 0 14px !important;
  }
  body.shell .entry-auth {
    width: 100%;
  }
  body.shell .entry-input {
    background: transparent !important;
    border-radius: 0;
    min-height: 44px;
  }
  body.shell .entry-submit {
    min-height: 50px !important;
  }

  body.shell .ag-search,
  body.shell .clients-search-input,
  body.shell input,
  body.shell select,
  body.shell textarea,
  body.shell .btn {
    max-width: 100%;
  }

  /* Sheet above the tab bar so Cancelar is tappable */
  html.pedido-sheet-open,
  html.pedido-sheet-open body.shell {
    overflow: hidden !important;
  }
  body.shell .ios-sheet:not([hidden]) {
    display: block !important;
    position: fixed !important;
    top: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: 2000 !important;
    pointer-events: auto !important;
    background: rgba(0, 0, 0, 0.4) !important;
    transform: none !important;
    -webkit-transform: none !important;
  }
  body.shell .ios-sheet[hidden] {
    display: none !important;
    pointer-events: none !important;
  }
  body.shell .ios-sheet-backdrop {
    position: absolute !important;
    inset: 0 !important;
    z-index: 1 !important;
    pointer-events: auto !important;
    background: transparent !important;
  }
  body.shell .ios-sheet-panel {
    position: absolute !important;
    z-index: 2 !important;
    left: 10px !important;
    right: 10px !important;
    bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px) + 8px) !important;
    pointer-events: auto !important;
    transform: none !important;
  }
  body.shell.is-locked .ios-sheet-panel {
    bottom: calc(10px + env(safe-area-inset-bottom, 0px)) !important;
  }
  body.shell .ios-sheet-cancel,
  body.shell .ios-sheet-row,
  body.shell .ios-sheet-kicker {
    pointer-events: auto !important;
    position: relative;
    z-index: 3;
    touch-action: manipulation;
    -webkit-user-select: none;
    user-select: none;
  }
  body.shell #pedidoActionSheet .ios-sheet-kicker + .pedido-sheet-cliente {
    margin-top: -8px;
  }
  body.shell #pedidoActionSheet .pedido-sheet-cliente + .ios-sheet-row {
    margin-top: -8px;
  }
  body.shell #pedidoSheetBoletos {
    border-radius: 0 0 14px 14px;
  }
  body.ios-more-open .app-tabbar,
  body.pedido-sheet-open .app-tabbar,
  html.pedido-sheet-open body.shell .app-tabbar,
  body.wa-sheet-open .app-tabbar {
    pointer-events: none !important;
    visibility: hidden !important;
  }

  /* Periods: separate cards, not a melted white block */
  body.shell .pedidos-controls {
    display: flex !important;
    flex-direction: column;
    gap: 16px !important;
    margin: 0 16px 20px !important;
    padding: 0 !important;
    background: transparent !important;
  }
  body.shell .month-bar,
  body.shell .month-meta {
    display: flex !important;
    flex-direction: column;
    gap: 12px !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    max-width: 100%;
    min-width: 0;
  }
  body.shell .month-year {
    background: #fff;
    border-radius: 12px;
    min-height: 48px;
    padding: 0 8px;
  }
  body.shell .month-grid {
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 8px !important;
    background: transparent !important;
    border-radius: 0 !important;
    overflow: visible !important;
  }
  body.shell .month-chip {
    min-height: 48px !important;
    border-radius: 12px !important;
    background: #fff !important;
    box-shadow: none !important;
  }
  body.shell .month-chip.on {
    background: var(--ios-tint) !important;
    color: #fff !important;
  }
  body.shell .month-bar .btn,
  body.shell .month-clear {
    min-height: 44px !important;
    width: 100%;
    margin: 0;
  }
  body.shell .campo-pills {
    width: 100% !important;
    margin: 0 !important;
    padding: 3px !important;
    background: var(--ios-fill) !important;
    border-radius: 10px;
    overflow: hidden;
  }
  body.shell .pedidos-search,
  body.shell .cnpj-import {
    display: grid;
    gap: 4px;
    background: #fff;
    border-radius: 12px;
    padding: 4px 12px 12px;
    margin: 0;
  }
  body.shell .table-tools {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin: 0 16px 12px;
    max-width: 100%;
    min-width: 0;
  }
  body.shell .table-tools label {
    margin: 0;
    background: #fff;
    border-radius: 12px;
  }
  body.shell .table-meta-row {
    gap: 10px;
    max-width: 100%;
    min-width: 0;
  }
  body.shell .comissao-months {
    gap: 10px !important;
    margin: 0 16px 20px !important;
  }
  body.shell .comissao-month {
    border-radius: 12px !important;
    background: #fff !important;
  }
  body.shell .vendas-month-grid {
    gap: 8px;
  }
  body.shell .vendas-month-grid button {
    border-radius: 10px;
    min-height: 44px;
  }
}

/* —— Mobile layout v2: one rhythm, opaque tab bar, visible actions —— */
@media (max-width: 860px) {
  :root {
    --tabbar-h: 56px;
    --ios-gutter: 16px;
    --ios-stack: 12px;
  }

  html,
  body.shell {
    overflow-x: hidden !important;
    overflow-y: auto !important;
    height: auto !important;
    min-height: 100% !important;
  }

  body.shell {
    padding-bottom: 0 !important;
  }
  body.shell .content {
    padding: 8px 0 calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px) + 28px) !important;
    overflow: visible !important;
  }
  body.shell .panel,
  body.shell .table-panel,
  body.shell .panel.table-panel {
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }
  body.shell table {
    min-width: 0 !important;
    width: 100% !important;
  }

  /* Filters / months: same width, stacked, breathing room */
  body.shell .table-head {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    justify-content: flex-start !important;
    gap: 12px !important;
    margin: 0 var(--ios-gutter) 16px !important;
    padding: 0 !important;
    width: calc(100% - 32px) !important;
    max-width: calc(100vw - 32px) !important;
  }
  body.shell .table-title {
    min-width: 0 !important;
    width: 100%;
  }
  body.shell .table-title h2 {
    margin: 0 0 10px !important;
  }
  body.shell .table-meta-row {
    display: flex !important;
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 10px !important;
    margin: 0 !important;
    width: 100%;
  }
  body.shell .status-shell,
  body.shell .status-trigger,
  body.shell .table-faturado,
  body.shell #tableMeta,
  body.shell #tableIngestMeta {
    width: 100% !important;
    min-width: 0 !important;
    max-width: 100% !important;
    flex: none !important;
  }
  body.shell .status-trigger {
    display: flex !important;
    justify-content: space-between;
    min-height: 48px;
    padding: 0 14px !important;
    border-radius: 12px !important;
  }
  body.shell .table-faturado {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 48px;
    margin: 0 !important;
    padding: 0 14px !important;
    background: #fff !important;
    border: 0 !important;
    border-radius: 12px !important;
    box-shadow: none !important;
  }
  body.shell .table-tools {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
    width: 100% !important;
    margin: 0 !important;
  }
  body.shell .table-tools label {
    display: grid !important;
    gap: 4px !important;
    width: 100% !important;
    min-height: 48px;
    margin: 0 !important;
    padding: 8px 12px 10px !important;
    background: #fff !important;
    border-radius: 12px !important;
  }
  body.shell .table-tools select {
    width: 100%;
    min-width: 0;
    border: 0;
    background: transparent;
    font-size: 16px;
  }

  body.shell .pedidos-controls,
  body.shell .month-bar,
  body.shell .month-meta {
    display: flex !important;
    flex-direction: column !important;
    grid-template-columns: none !important;
    align-items: stretch !important;
    gap: 12px !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
  }
  body.shell .pedidos-controls {
    width: calc(100% - 32px) !important;
    max-width: calc(100vw - 32px) !important;
    margin: 0 var(--ios-gutter) 20px !important;
  }
  body.shell .month-year {
    display: flex !important;
    width: 100%;
    justify-content: space-between;
    min-height: 48px;
    border-radius: 12px;
  }
  body.shell .month-grid {
    display: grid !important;
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 0 !important;
    width: 100% !important;
    background: #fff !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    box-shadow: none !important;
  }
  body.shell .month-chip {
    min-height: 46px !important;
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    border-right: 0.33px solid var(--ios-sep-opaque) !important;
    border-bottom: 0.33px solid var(--ios-sep-opaque) !important;
    background: #fff !important;
    color: #000 !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    box-shadow: none !important;
    transform: none !important;
  }
  body.shell .month-chip:nth-child(4n) {
    border-right: 0 !important;
  }
  body.shell .month-chip:nth-child(n + 9) {
    border-bottom: 0 !important;
  }
  body.shell .month-chip.on {
    background: var(--ios-tint) !important;
    color: #fff !important;
    border-color: var(--ios-tint) !important;
  }
  body.shell .month-bar .btn,
  body.shell .month-clear {
    width: 100%;
    min-height: 44px !important;
    margin: 0 !important;
    border-radius: 12px !important;
  }
  body.shell .month-bar {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 10px !important;
  }
  body.shell .month-year,
  body.shell .month-grid {
    grid-column: 1 / -1;
  }
  body.shell .month-meta > div,
  body.shell .pedidos-search,
  body.shell .month-meta .status-shell {
    display: grid !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
    margin: 0 !important;
  }
  body.shell .pedidos-search {
    padding: 10px 12px 12px !important;
    background: #fff !important;
    border-radius: 12px !important;
  }
  body.shell .pedidos-search input {
    width: 100%;
    min-height: 40px;
  }
  body.shell .table-tools,
  body.shell .campo-pills,
  body.shell .cnpj-import,
  body.shell .month-clear {
    display: none !important;
  }

  /* Pedidos list: compact card; Rastreio / Boletos via action sheet */
  body.shell .table-wrap,
  body.shell .clients-table-wrap {
    overflow: visible !important;
    margin: 0 0 8px !important;
    border-radius: 0 !important;
  }
  body.shell .ag-list-panel .clients-table-wrap {
    margin: 0 !important;
    border-radius: 0 !important;
    overflow: visible !important;
    background: #fff;
    border-top: 0.33px solid rgba(60, 60, 67, 0.12);
    border-bottom: 0.33px solid rgba(60, 60, 67, 0.12);
  }
  body.shell .carteira-table,
  body.shell .carteira-table tbody {
    display: block !important;
    width: 100% !important;
    min-width: 0 !important;
  }
  body.shell .carteira-table thead {
    display: none !important;
  }
  body.shell .carteira-table .campanha-inline,
  body.shell .carteira-table .campanha-inline[data-ag-field="whatsapp"],
  body.shell .carteira-table .campanha-inline[data-ag-field="comprador"] {
    display: none !important;
  }
  body.shell .carteira-table tbody tr {
    overflow: visible !important;
    background: #fff !important;
  }
  body.shell .carteira-table tbody tr.is-selected {
    background: rgba(225, 6, 0, 0.05) !important;
  }
  body.shell .carteira-table tbody td.clients-actions {
    display: flex !important;
    align-items: flex-start;
    justify-content: flex-end;
    width: auto !important;
    overflow: visible !important;
    background: transparent !important;
  }
  body.shell #agendamentoRoot.is-selecting .carteira-table tbody td.clients-actions {
    display: none !important;
  }
  body.shell .carteira-table .ag-row-desk-actions,
  body.shell .carteira-table .clients-actions .btn.tiny,
  body.shell .carteira-table .clients-actions .btn.tiny.danger,
  body.shell .carteira-table .clients-actions .btn {
    display: none !important;
  }
  body.shell .carteira-table .ag-row-more {
    display: grid !important;
    place-items: center;
    width: 44px;
    height: 44px;
    margin: -8px -12px 0 0;
    color: #c7c7cc;
    background: transparent !important;
    border: 0 !important;
    border-radius: 22px;
  }
  body.shell .carteira-table .ag-card-top {
    align-items: center;
    gap: 8px;
  }
  body.shell .carteira-table .ag-card-top strong {
    flex: 1 1 auto;
    font-size: 17px !important;
    font-weight: 600;
    letter-spacing: -0.022em;
    color: #000;
  }
  body.shell .carteira-table .ag-card-top .ag-pill {
    display: inline !important;
    padding: 0 !important;
    background: transparent !important;
    border-radius: 0 !important;
    font-size: 13px !important;
    font-weight: 600;
    letter-spacing: -0.016em;
    text-transform: none !important;
  }
  body.shell .carteira-table .ag-card-top .ag-pill-agendado { color: #007aff !important; }
  body.shell .carteira-table .ag-card-top .ag-pill-atendido { color: #34c759 !important; }
  body.shell .carteira-table .ag-card-top .ag-pill-nao_quer { color: #ff3b30 !important; }
  body.shell .carteira-table .ag-card-addr {
    margin: 2px 0 0;
    font-size: 13px !important;
    font-weight: 400;
    line-height: 1.35;
    color: var(--ios-label) !important;
  }
  body.shell .carteira-table .ag-card-meta {
    display: flex !important;
    justify-content: space-between;
    gap: 12px;
    margin: 4px 0 0;
    font-size: 15px !important;
    font-weight: 400;
    color: #000;
  }
  body.shell .carteira-table .ag-card-meta span:last-child,
  body.shell .carteira-table .ag-card-phone {
    color: var(--ios-label);
    font-variant-numeric: tabular-nums;
  }
  body.shell .carteira-table .ag-card-person {
    color: #000;
  }
  body.shell .carteira-table tbody td:nth-child(1) input {
    width: 22px !important;
    height: 22px !important;
  }
  body.shell .visao-pedidos-table,
  body.shell .visao-pedidos-table tbody {
    display: block !important;
    width: 100% !important;
  }
  body.shell .visao-pedidos-table tbody tr.pedido-card {
    display: block !important;
    flex-wrap: nowrap;
    padding: 0 !important;
    min-height: 0 !important;
    max-height: none !important;
    background: #fff !important;
  }
  body.shell .visao-pedidos-table tbody tr.pedido-card td {
    display: block !important;
    padding: 8px 16px !important;
    margin: 0 !important;
    max-width: none !important;
    white-space: normal !important;
  }
  body.shell .visao-pedidos-table tbody td::before,
  body.shell .visao-pedidos-table tbody td::after {
    content: none !important;
    display: none !important;
  }
  body.shell .pedido-ov {
    font-size: 12px !important;
    font-weight: 600;
    color: var(--ios-label) !important;
  }
  body.shell .pedido-ov .pedido-date {
    font-size: inherit !important;
    font-weight: inherit !important;
    color: inherit !important;
  }
  body.shell .pedido-ov-row {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
  }
  body.shell .pedido-ov-row .badge {
    margin-left: auto;
    flex: 0 0 auto;
  }
  body.shell .pedido-razao {
    font-size: 15px !important;
    font-weight: 600;
  }
  body.shell .pedido-ov-val {
    font-size: 15px !important;
    font-weight: 600 !important;
    color: #007aff !important;
  }
  body.shell .pedido-fat {
    font-size: 15px !important;
    font-weight: 600 !important;
    color: #1c7c3a !important;
  }
  body.shell .pedido-vals {
    font-size: 15px !important;
  }
  body.shell .pedido-card.is-faturado:active td {
    background: #f2f2f7 !important;
  }
  body.shell .pedido-sheet-row {
    display: flex !important;
    align-items: center;
    justify-content: flex-start !important;
    gap: 14px;
    padding: 0 20px !important;
    line-height: 1.2 !important;
    text-align: left !important;
  }
  body.shell .pedido-sheet-ico {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    color: #007aff;
    flex: 0 0 auto;
  }
  body.shell .pedido-sheet-ico svg {
    width: 24px;
    height: 24px;
  }
  body.shell .pedido-sheet-cliente {
    margin: 0;
    padding: 0 16px 10px;
    text-align: center;
    font-size: 13px;
    color: var(--ios-label);
    background: rgba(245, 245, 247, 0.96);
  }

  /* Opaque footer — page never bleeds through */
  body.shell .app-tabbar,
  body.shell .app-tabbar:not([hidden]) {
    display: grid !important;
    grid-template-columns: repeat(5, minmax(0, 1fr)) !important;
    align-items: start;
    position: fixed !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    z-index: 500 !important;
    height: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px)) !important;
    padding: 6px 4px env(safe-area-inset-bottom, 0px) !important;
    background: #f9f9f9 !important;
    background-image: none !important;
    border-top: 0.5px solid #c6c6c8 !important;
    box-shadow: 0 -12px 28px rgba(0, 0, 0, 0.08) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
  body.shell .app-tab {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 3px;
    min-width: 0 !important;
    max-width: 100%;
    overflow: hidden;
    padding: 2px 4px 0 !important;
    isolation: isolate;
  }
  body.shell .app-tab span:not(.app-tab-ico) {
    display: block;
    width: 100%;
    max-width: 100%;
    font-size: 10px;
    line-height: 1.15;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }
  body.shell .track-modal:not([hidden]),
  body.shell .ios-sheet:not([hidden]) {
    z-index: 2000 !important;
  }
  body.shell .venda-share-sheet:not([hidden]) {
    z-index: 2100 !important;
  }
  body.shell .track-modal[hidden] {
    display: none !important;
  }
  body.shell .pager {
    margin: 8px var(--ios-gutter) 0 !important;
  }
  body.shell .kpis .kpi:last-child {
    grid-column: auto;
  }
  body.shell .pedidos-filtro-hint,
  body.shell .campo-filtro-hint {
    margin: 0;
    font-size: 13px;
    line-height: 1.4;
    color: var(--ios-label);
    font-weight: 400;
    text-transform: none;
    letter-spacing: -0.016em;
  }
  body.shell .table-faturado {
    white-space: normal;
    align-items: flex-start;
    flex-direction: column;
    gap: 2px;
    min-height: 48px;
    padding: 8px 14px !important;
  }
  body.shell .table-faturado strong {
    font-size: 14px;
    font-weight: 600;
    white-space: normal;
  }
  body.shell .client-name {
    display: block;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  body.shell .ios-fold {
    margin: 0 16px 16px;
    border: 0;
    border-radius: 12px;
    background: #fff;
    overflow: visible;
  }
  body.shell .ios-fold-head {
    min-height: 44px;
    padding: 12px 16px;
    font-size: 17px;
    font-weight: 600;
    letter-spacing: -0.022em;
  }
  body.shell .ios-fold-sub {
    margin: 0 16px 12px;
    font-size: 13px;
    color: var(--ios-label);
  }
  body.shell .ios-fold-body {
    padding: 0 0 8px;
  }
  body.shell #foldPedidos .ios-fold-body {
    padding: 0;
  }
  body.shell #foldPedidos .table-title h2 {
    display: none !important;
  }
  body.shell #foldTopClientes .rank {
    margin: 0;
    padding: 0 16px 12px;
  }

  /* —— Carteira composition (Contacts / Reminders) —— */
  body.shell.page-carteira {
    --c-space: 16px;
    --c-title: 34px;
    --c-body: 17px;
    --c-sub: 15px;
    --c-meta: 13px;
    --c-hair: 0.33px solid rgba(60, 60, 67, 0.12);
  }
  body.shell.page-carteira .content {
    padding: 0 0 24px;
  }
  body.shell.page-carteira .carteira-page-head {
    padding: 8px var(--c-space) 0 !important;
    gap: 0;
  }
  body.shell.page-carteira .carteira-title-row {
    min-height: 44px;
    align-items: center;
  }
  body.shell.page-carteira .carteira-title-row h1 {
    font-size: var(--c-title) !important;
    font-weight: 700;
    letter-spacing: -0.043em;
    line-height: 1.12;
  }
  body.shell.page-carteira .carteira-title-actions {
    gap: 0;
    margin-right: -8px;
  }
  body.shell.page-carteira .ios-bar-btn {
    width: 44px;
    height: 44px;
    color: var(--ios-tint) !important;
  }
  body.shell.page-carteira .carteira-sub-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 32px;
    padding: 0 0 12px;
  }
  body.shell.page-carteira .carteira-sub-row #agCount,
  body.shell.page-carteira #agCount {
    font-size: var(--c-sub) !important;
    font-weight: 400;
    color: var(--ios-label) !important;
  }
  body.shell.page-carteira .carteira-sub-row .ios-bar-text {
    margin-left: auto;
    min-height: 32px;
    padding: 0;
    font-size: var(--c-body);
    font-weight: 400;
    color: var(--ios-tint) !important;
  }
  body.shell.page-carteira #agendamentoRoot.is-selecting #btnCarteiraSelect {
    font-weight: 600;
  }
  body.shell.page-carteira .carteira-head-actions {
    display: none !important;
  }

  body.shell.page-carteira #carteiraChrome,
  body.shell.page-carteira .ag-toolbar.carteira-searchbar {
    display: flex !important;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
    position: sticky;
    top: calc(var(--nav-h) + env(safe-area-inset-top, 0px) - 1px);
    z-index: 16;
    margin: 0;
    padding: 0 var(--c-space) 12px;
    background: rgba(242, 242, 247, 0.92);
    backdrop-filter: saturate(1.8) blur(20px);
    -webkit-backdrop-filter: saturate(1.8) blur(20px);
    border: 0;
  }
  body.shell.page-carteira .carteira-searchbar .ios-search-field {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 36px;
    height: 36px;
    grid-column: auto;
    border-radius: 10px;
    background: var(--ios-fill-2);
  }
  body.shell.page-carteira .carteira-searchbar .ios-search-ico {
    width: 32px;
    height: 36px;
    color: #8e8e93;
  }
  body.shell.page-carteira .carteira-searchbar .ios-search-field .ag-search,
  body.shell.page-carteira .carteira-searchbar .ios-search-field #agBusca {
    flex: 1 1 auto;
    min-width: 0;
    height: 36px !important;
    min-height: 36px !important;
    padding: 0 4px 0 0 !important;
    font-size: var(--c-body) !important;
    font-weight: 400 !important;
    background: transparent !important;
  }
  body.shell.page-carteira .carteira-searchbar .ios-search-tools {
    display: flex;
    align-items: center;
    grid-column: auto;
    height: 36px;
    gap: 0;
    padding: 0 4px 0 0;
  }
  body.shell.page-carteira .carteira-searchbar .ios-search-tool {
    flex: 0 0 32px;
    width: 32px !important;
    height: 36px !important;
    border-radius: 0;
    background: transparent !important;
    color: #8e8e93;
  }
  body.shell.page-carteira .carteira-searchbar .ios-search-tool.is-on,
  body.shell.page-carteira .carteira-searchbar .ios-search-tool:has(input:checked),
  body.shell.page-carteira .carteira-searchbar .ios-search-tool[aria-expanded="true"] {
    color: var(--ios-tint) !important;
    background: transparent !important;
  }
  body.shell.page-carteira .carteira-searchbar #agCityPicker {
    grid-column: auto;
    width: 100%;
  }
  body.shell.page-carteira #carteiraChrome.is-rotas .ios-search-field,
  body.shell.page-carteira #carteiraChrome.is-rotas #agCityPicker {
    display: none !important;
  }

  body.shell.page-carteira #agendamentoRoot .ag-seg,
  body.shell.page-carteira #agendamentoRoot .ag-seg.ag-seg-scroll {
    display: flex !important;
    flex-wrap: nowrap !important;
    width: auto !important;
    max-width: none !important;
    margin: 0 -8px !important;
    padding: 0 4px !important;
    gap: 0 !important;
    overflow-x: auto !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }
  body.shell.page-carteira #agendamentoRoot .ag-seg-btn,
  body.shell.page-carteira #agendamentoRoot .ag-seg-scroll .ag-seg-btn {
    flex: 0 0 auto !important;
    min-width: auto !important;
    max-width: none !important;
    min-height: 32px !important;
    margin: 0;
    padding: 4px 12px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--ios-label) !important;
    font-size: var(--c-sub) !important;
    font-weight: 400 !important;
    letter-spacing: -0.016em;
    display: inline-flex !important;
    flex-direction: row !important;
    align-items: baseline;
    gap: 4px;
  }
  body.shell.page-carteira #agendamentoRoot .ag-seg-btn.is-on,
  body.shell.page-carteira #agendamentoRoot .ag-seg-scroll .ag-seg-btn.is-on {
    background: transparent !important;
    box-shadow: none !important;
    color: var(--ios-tint) !important;
    font-weight: 600 !important;
  }
  body.shell.page-carteira #agendamentoRoot .ag-seg-name {
    font-size: inherit;
    font-weight: inherit;
  }
  body.shell.page-carteira #agendamentoRoot .ag-seg-count {
    font-size: var(--c-meta);
    font-weight: 600;
    color: inherit;
    opacity: 0.7;
  }

  body.shell.page-carteira #agListPanel,
  body.shell.page-carteira .ag-list-panel {
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    overflow: visible !important;
  }
  body.shell.page-carteira #agListPanel .clients-table-wrap,
  body.shell.page-carteira .ag-list-panel .clients-table-wrap {
    margin: 0 !important;
    border-radius: 0 !important;
    border-top: var(--c-hair);
    border-bottom: var(--c-hair);
    background: #fff;
    overflow: visible !important;
  }
  body.shell.page-carteira .carteira-table tbody tr {
    padding: 12px var(--c-space) !important;
    background: #fff !important;
    border-bottom: var(--c-hair);
  }
  body.shell.page-carteira .carteira-table tbody tr:last-child {
    border-bottom: 0;
  }
  body.shell.page-carteira .carteira-table tbody tr:active {
    background: #f2f2f7 !important;
  }
  body.shell.page-carteira .carteira-table .ag-card-top strong {
    font-size: var(--c-body) !important;
    font-weight: 600;
    letter-spacing: -0.022em;
  }
  body.shell.page-carteira .carteira-table .ag-card-addr {
    margin: 2px 0 0;
    font-size: var(--c-meta) !important;
    font-weight: 400;
    color: var(--ios-label) !important;
  }
  body.shell.page-carteira .carteira-table .ag-card-meta {
    margin: 4px 0 0;
    font-size: var(--c-sub) !important;
    font-weight: 400;
  }
  body.shell.page-carteira .carteira-table .ag-card-top .ag-pill {
    font-size: var(--c-meta) !important;
    font-weight: 600;
    padding: 0 !important;
    background: transparent !important;
    text-transform: none !important;
  }
  body.shell.page-carteira .carteira-table .ag-row-more {
    color: #c7c7cc;
  }

  body.shell.page-carteira .app-tabbar,
  body.shell.page-carteira .app-tabbar:not([hidden]) {
    box-shadow: none !important;
    background: #f9f9f9 !important;
    border-top: 0.33px solid #c6c6c8 !important;
  }

  /* —— Prospecção: fluxo único —— */
  body.shell.page-prospeccao .prospeccao-main-seg[hidden] {
    display: none !important;
  }
  body.shell.page-prospeccao .prosp-page-head {
    padding: 8px 16px 0 !important;
    gap: 0;
  }
  body.shell.page-prospeccao .prosp-sub-row {
    padding: 0 0 12px;
  }
  body.shell.page-prospeccao .prosp-sub-row #prospeccaoCount,
  body.shell.page-prospeccao #prospeccaoCount {
    font-size: 15px !important;
    font-weight: 400;
    color: var(--ios-label) !important;
  }
  body.shell.page-prospeccao .prosp-page-head .ios-bar-text {
    color: var(--ios-tint) !important;
    font-size: 17px;
  }
  body.shell.page-prospeccao #prospeccaoRoot.is-selecting #btnProspSelect {
    font-weight: 600;
  }
  body.shell.page-prospeccao #btnProspSelect[hidden] {
    display: none !important;
  }

  body.shell.page-prospeccao .prosp-chrome {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 0 16px 12px;
  }
  body.shell.page-prospeccao .prosp-chrome[hidden] {
    display: none !important;
  }
  body.shell.page-prospeccao .prosp-city-field span,
  body.shell.page-prospeccao .prosp-city-field .f-label {
    display: none !important;
  }
  body.shell.page-prospeccao .prosp-city-field,
  body.shell.page-prospeccao .prospeccao-cidade-select {
    margin: 0;
    padding: 0;
  }
  body.shell.page-prospeccao .prospeccao-cidade-select select,
  body.shell.page-prospeccao #prospeccaoCidadeFiltro {
    width: 100%;
    min-height: 36px !important;
    margin: 0;
    padding: 0 12px !important;
    border-radius: 10px;
    background: var(--ios-fill-2) !important;
    font-size: 15px !important;
    font-weight: 600;
  }
  body.shell.page-prospeccao .prospeccao-tipo-seg,
  body.shell.page-prospeccao .prospeccao-envio-seg,
  body.shell.page-prospeccao .prospeccao-busca-view-seg {
    width: auto !important;
    max-width: none !important;
    margin: 0 -8px !important;
    padding: 0 4px !important;
    background: transparent !important;
    border-radius: 0 !important;
    gap: 0;
    overflow-x: auto;
  }
  body.shell.page-prospeccao .prospeccao-tipo-seg .ag-seg-btn,
  body.shell.page-prospeccao .prospeccao-envio-seg .ag-seg-btn,
  body.shell.page-prospeccao .prospeccao-busca-view-seg .ag-seg-btn {
    flex: 0 0 auto !important;
    min-width: auto !important;
    min-height: 32px !important;
    padding: 4px 12px !important;
    background: transparent !important;
    box-shadow: none !important;
    color: var(--ios-label) !important;
    font-size: 15px !important;
    font-weight: 400 !important;
    border-radius: 0 !important;
  }
  body.shell.page-prospeccao .ag-seg-btn.is-on {
    background: transparent !important;
    box-shadow: none !important;
    color: var(--ios-tint) !important;
    font-weight: 600 !important;
  }

  body.shell.page-prospeccao .prosp-empty {
    padding: 32px 32px 24px;
    text-align: center;
  }
  body.shell.page-prospeccao .prosp-empty[hidden] {
    display: none !important;
  }
  body.shell.page-prospeccao .prosp-empty-title {
    margin: 0 0 8px;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.03em;
  }
  body.shell.page-prospeccao .prosp-empty-copy {
    margin: 0 0 20px;
    font-size: 15px;
    color: var(--ios-label);
  }
  body.shell.page-prospeccao .prosp-empty .btn.primary {
    width: auto;
    min-width: 180px;
    min-height: 44px !important;
    margin: 0 auto;
    padding: 0 20px;
    border-radius: 12px;
  }

  body.shell.page-prospeccao .prosp-list-panel,
  body.shell.page-prospeccao .prosp-list-panel .clients-table-wrap {
    margin: 0 !important;
    padding: 0 !important;
    background: #fff !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
  }
  body.shell.page-prospeccao .prosp-list-panel .clients-table-wrap {
    border-top: 0.33px solid rgba(60, 60, 67, 0.12);
    border-bottom: 0.33px solid rgba(60, 60, 67, 0.12);
  }
  body.shell.page-prospeccao .prosp-list-panel[hidden] {
    display: none !important;
  }
  body.shell.page-prospeccao .prospeccao-table tbody tr {
    grid-template-columns: minmax(0, 1fr) !important;
    padding: 12px 16px !important;
    border-bottom: 0.33px solid rgba(60, 60, 67, 0.12);
    background: #fff !important;
  }
  body.shell.page-prospeccao #prospeccaoRoot.is-selecting .prospeccao-table tbody tr {
    grid-template-columns: 28px minmax(0, 1fr) !important;
  }
  body.shell.page-prospeccao .prospeccao-table tbody td:nth-child(1) {
    display: none !important;
  }
  body.shell.page-prospeccao #prospeccaoRoot.is-selecting .prospeccao-table tbody td:nth-child(1) {
    display: flex !important;
    grid-column: 1;
    grid-row: 1;
    align-items: flex-start;
    padding-top: 2px;
  }
  body.shell.page-prospeccao .prospeccao-table tbody td:nth-child(2) {
    grid-column: 1;
    grid-row: 1;
  }
  body.shell.page-prospeccao #prospeccaoRoot.is-selecting .prospeccao-table tbody td:nth-child(2) {
    grid-column: 2;
  }
  body.shell.page-prospeccao .prospeccao-table tbody td:nth-child(3),
  body.shell.page-prospeccao .prospeccao-table tbody td:nth-child(4) {
    display: none !important;
  }
  body.shell.page-prospeccao .prosp-card {
    display: block;
    min-width: 0;
  }
  body.shell.page-prospeccao .prosp-desk-input {
    display: none !important;
  }
  body.shell.page-prospeccao .prosp-card strong {
    display: block;
    font-size: 17px;
    font-weight: 600;
    letter-spacing: -0.022em;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
  body.shell.page-prospeccao .prosp-card-meta {
    margin: 2px 0 0;
    font-size: 13px;
    font-weight: 400;
    color: var(--ios-label);
  }
  body.shell.page-prospeccao .prosp-card-tipo {
    display: inline;
    font-size: 13px;
    font-weight: 600;
    color: var(--ios-label);
  }
  body.shell.page-prospeccao .prospeccao-table tbody tr.is-enviado .prosp-card-tipo {
    color: #34c759;
  }
  body.shell.page-prospeccao .prospeccao-table tbody tr.is-selected {
    background: rgba(225, 6, 0, 0.05) !important;
  }

  body.shell.page-prospeccao .prosp-msg-block {
    padding: 20px 16px 24px;
  }
  body.shell.page-prospeccao .prosp-msg-block[hidden] {
    display: none !important;
  }
  body.shell.page-prospeccao .prosp-sec-label {
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 400;
    color: var(--ios-label);
  }
  body.shell.page-prospeccao .prosp-msg-preview {
    margin: 0 0 8px;
    font-size: 17px;
    line-height: 1.35;
    color: #000;
  }
  body.shell.page-prospeccao .prosp-msg-preview.is-empty {
    color: var(--ios-label);
  }
  body.shell.page-prospeccao .prosp-msg-actions {
    display: flex;
    gap: 16px;
  }
  body.shell.page-prospeccao .prosp-msg-actions .ios-bar-text {
    min-height: 32px;
    padding: 0;
    font-size: 15px;
    color: var(--ios-tint) !important;
  }
  body.shell.page-prospeccao .prosp-job-msg:empty {
    display: none;
  }
  body.shell.page-prospeccao .prosp-job-msg {
    display: block;
    margin-top: 8px;
    font-size: 13px;
    color: var(--ios-label);
  }

  body.shell.page-prospeccao .prosp-selbar[hidden] {
    display: none !important;
  }
  body.shell.page-prospeccao .prosp-selbar:not([hidden]) {
    position: fixed;
    left: 0;
    right: 0;
    bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px));
    z-index: 40;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 0 8px;
    border-top: 0.33px solid #c6c6c8;
    background: rgba(249, 249, 249, 0.94);
    backdrop-filter: saturate(1.8) blur(20px);
  }
  body.shell.page-prospeccao .prosp-selbar-meta {
    margin: 0;
    padding: 0 8px;
    font-size: 13px;
    color: var(--ios-label);
    white-space: nowrap;
  }
  body.shell.page-prospeccao .prosp-selbar-btns {
    display: flex;
    flex: 1;
    justify-content: flex-end;
    gap: 0;
  }
  body.shell.page-prospeccao .prosp-selbar .btn,
  body.shell.page-prospeccao .prosp-selbar .btn.ghost,
  body.shell.page-prospeccao .prosp-selbar .btn.primary,
  body.shell.page-prospeccao .prosp-selbar .prospeccao-wa-btn {
    width: auto !important;
    min-height: 44px !important;
    padding: 0 10px !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    color: var(--ios-blue) !important;
    font-size: 17px !important;
    font-weight: 400 !important;
    box-shadow: none !important;
  }
  body.shell.page-prospeccao .prosp-selbar .btn.primary {
    color: var(--ios-tint) !important;
    font-weight: 600 !important;
  }

  body.shell.page-prospeccao #prospeccaoRoot.is-busca .prosp-page-head .carteira-title-actions {
    visibility: hidden;
  }
  body.shell.page-prospeccao .prosp-busca-pane {
    padding: 0 0 80px;
  }
  body.shell.page-prospeccao .prosp-busca-head {
    display: flex;
    align-items: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 16px 8px;
  }
  body.shell.page-prospeccao .prosp-busca-head h2 {
    flex: 1;
    margin: 0;
    text-align: center;
    font-size: 17px;
    font-weight: 600;
  }
  body.shell.page-prospeccao .prosp-busca-head .ios-bar-text {
    color: var(--ios-tint) !important;
    min-width: 64px;
    justify-content: flex-start;
    padding: 0;
  }
  body.shell.page-prospeccao .prosp-busca-head-gap {
    min-width: 64px;
  }
  body.shell.page-prospeccao .prosp-busca-setup {
    padding: 8px 16px 16px;
  }
  body.shell.page-prospeccao .prosp-busca-setup .btn.primary {
    width: 100%;
    min-height: 44px !important;
    margin-top: 12px;
    border-radius: 12px;
  }
  body.shell.page-prospeccao #prospeccaoBuscaCidade {
    width: 100%;
    min-height: 44px !important;
  }
  body.shell.page-prospeccao .prosp-busca-etapas {
    margin: 12px 0 0;
    padding: 0;
    list-style: none;
    background: transparent !important;
  }
  body.shell.page-prospeccao .prosp-busca-etapas li {
    font-size: 13px;
    color: var(--ios-label);
    padding: 4px 0;
  }
  body.shell.page-prospeccao .prosp-busca-view-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: 0 16px 8px;
  }
  body.shell.page-prospeccao .prosp-busca-found {
    margin: 0;
    font-size: 15px;
    font-weight: 600;
  }
  body.shell.page-prospeccao .prosp-busca-found[hidden] {
    display: none !important;
  }
  body.shell.page-prospeccao #prospeccaoBuscaResultado,
  body.shell.page-prospeccao #prospeccaoBuscaAuditoria {
    margin: 0 !important;
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
  }
  body.shell.page-prospeccao .prospeccao-busca-grupos,
  body.shell.page-prospeccao .prospeccao-busca-group {
    margin: 0 !important;
    border-radius: 0 !important;
    background: #fff;
  }
  body.shell.page-prospeccao .prospeccao-busca-group h3 {
    padding: 16px 16px 6px !important;
    font-size: 13px !important;
    font-weight: 400 !important;
    text-transform: none !important;
    letter-spacing: -0.016em;
    color: var(--ios-label) !important;
    background: var(--ios-bg) !important;
  }
  body.shell.page-prospeccao .prospeccao-busca-line {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    min-height: 0;
    padding: 12px 16px !important;
    font-size: 17px;
  }
  body.shell.page-prospeccao .prosp-busca-card {
    display: grid;
    gap: 2px;
    min-width: 0;
  }
  body.shell.page-prospeccao .prosp-busca-card strong {
    font-size: 17px;
    font-weight: 600;
  }
  body.shell.page-prospeccao .prosp-busca-card small {
    font-size: 13px;
    color: var(--ios-label);
  }
  body.shell.page-prospeccao .prosp-busca-blank {
    margin: 0;
    padding: 32px 24px;
    text-align: center;
    font-size: 15px;
    color: var(--ios-label);
  }
  body.shell.page-prospeccao .prosp-busca-done {
    margin: 0 16px 12px;
    padding: 12px 0 0;
  }
  body.shell.page-prospeccao .prosp-busca-done[hidden] {
    display: none !important;
  }
  body.shell.page-prospeccao .prosp-busca-done p {
    margin: 0 0 4px;
    font-size: 15px;
    font-weight: 600;
  }
  body.shell.page-prospeccao .prosp-busca-done-btns {
    display: flex;
    gap: 16px;
  }
  body.shell.page-prospeccao .prosp-paste-fold {
    margin: 16px 16px 24px;
    background: #fff;
    border-radius: 12px;
  }
  body.shell.page-prospeccao .prosp-paste-fold .panel {
    margin: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
  }
  body.shell.page-prospeccao .prosp-msg-editor {
    width: calc(100% - 24px);
    margin: 0 12px 8px;
    min-height: 140px !important;
    border-radius: 12px !important;
    background: #fff !important;
    padding: 12px !important;
    font-size: 17px !important;
  }
  body.shell.page-prospeccao #prospRegrasSheet .prospeccao-regras {
    margin: 0;
    padding: 8px 20px 16px;
    background: rgba(245, 245, 247, 0.96);
    font-size: 15px;
    color: #000;
  }
  body.shell.page-prospeccao .prosp-send-preview {
    margin: 0;
    padding: 0 20px 16px;
    font-size: 15px;
    line-height: 1.35;
    color: var(--ios-label);
    background: rgba(245, 245, 247, 0.96);
  }
  body.shell.page-prospeccao .app-tabbar,
  body.shell.page-prospeccao .app-tabbar:not([hidden]) {
    box-shadow: none !important;
  }

  /* —— Resultados composition —— */
  body.shell.page-resultados {
    --r-gutter: 16px;
    --r-hair: 0.33px solid rgba(60, 60, 67, 0.12);
    --r-label: var(--ios-label);
    --r-fill: var(--ios-fill);
  }
  body.shell.page-resultados .content {
    padding: 2px 0 24px;
  }
  body.shell.page-resultados .res-hub-head {
    padding: 8px 16px 0 !important;
    margin: 0;
  }
  body.shell.page-resultados .res-hub-head h1 {
    font-size: 34px !important;
    letter-spacing: -0.043em;
  }
  body.shell.page-resultados .hub-seg {
    width: calc(100% - 32px) !important;
    max-width: none;
    margin: 8px 16px 12px !important;
    padding: 2px !important;
    min-height: 32px;
    background: var(--ios-fill) !important;
    border-radius: 9px;
  }
  body.shell.page-resultados .hub-seg .ag-seg-btn {
    min-height: 28px;
    font-size: 13px;
    font-weight: 600;
    color: #000 !important;
  }
  body.shell.page-resultados .hub-seg .ag-seg-btn.is-on {
    background: #fff !important;
    color: var(--ios-tint) !important;
    box-shadow: 0 0.5px 1px rgba(0, 0, 0, 0.12), 0 3px 8px rgba(0, 0, 0, 0.04) !important;
  }
  body.shell.page-resultados #reportRoot {
    padding: 0 16px 8px !important;
    max-width: none;
  }
  body.shell.page-resultados .res-context {
    margin: 4px 0 24px;
  }
  body.shell.page-resultados .res-period-label {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.03em;
    min-height: 44px;
    display: flex;
    align-items: center;
  }
  body.shell.page-resultados .res-updated,
  body.shell.page-resultados #lastSync {
    font-size: 13px !important;
    color: var(--ios-label) !important;
  }
  body.shell.page-resultados .res-sync-btn {
    color: var(--ios-tint);
  }
  body.shell.page-resultados #kpis,
  body.shell.page-resultados #kpis.res-kpis {
    display: flex !important;
    flex-direction: column;
    grid-template-columns: none;
    gap: 32px;
    margin: 0 0 32px;
    background: transparent !important;
    border-radius: 0;
    overflow: visible;
  }
  body.shell.page-resultados .res-group-body {
    background: #fff;
  }
  body.shell.page-resultados .res-fat-value {
    font-family: var(--display);
    font-size: 36px;
    font-weight: 700;
    letter-spacing: -0.045em;
    color: #000;
  }
  body.shell.page-resultados .res-pend-value {
    font-size: 22px;
    font-weight: 650;
  }
  body.shell.page-resultados .res-col strong {
    font-size: 22px;
  }
  body.shell.page-resultados .res-col-year strong {
    font-size: 17px;
    font-weight: 600;
  }
  body.shell.page-resultados .res-detail {
    background: #fff;
  }
  body.shell.page-resultados .res-detail-pedidos {
    margin-top: 20px !important;
  }
  body.shell.page-resultados .ios-fold.res-fold {
    margin: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
  }
  body.shell.page-resultados .ios-fold-head {
    padding: 12px 16px;
    min-height: 56px;
  }
  body.shell.page-resultados .ios-fold-head .ios-fold-sub {
    margin: 0;
    padding: 0;
    font-size: 13px;
    color: var(--ios-label);
  }
  body.shell.page-resultados .ios-fold-body {
    padding: 0 16px 16px;
  }
  body.shell.page-resultados #foldTopClientes .rank,
  body.shell.page-resultados .rank {
    margin: 0;
    padding: 0;
    background: transparent;
  }
  body.shell.page-resultados .rank-item {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr) auto;
    gap: 8px 12px;
    min-height: 0;
    padding: 10px 0;
    border: 0;
    background: transparent !important;
  }
  body.shell.page-resultados .rank-item .n {
    font-size: 13px;
    color: var(--ios-label);
  }
  body.shell.page-resultados .rank-item .name {
    font-size: 15px;
    font-weight: 600;
    white-space: normal;
  }
  body.shell.page-resultados .rank-item .val {
    font-size: 15px;
    font-weight: 600;
    color: #000;
  }
  body.shell.page-resultados .res-pedidos-meta,
  body.shell.page-resultados .table-faturado {
    display: none !important;
  }
  body.shell.page-resultados .pedidos-controls,
  body.shell.page-resultados .month-bar,
  body.shell.page-resultados .month-meta {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0 !important;
    padding: 0 !important;
    background: transparent !important;
  }
  body.shell.page-resultados .status-trigger {
    min-height: 44px;
    padding: 0 !important;
    background: transparent !important;
    border-radius: 0;
  }
  body.shell.page-resultados .status-trigger-label {
    font-size: 15px;
    font-weight: 400;
  }
  body.shell.page-resultados .res-search {
    min-height: 36px;
    height: 36px;
    background: var(--ios-fill-2);
  }
  body.shell.page-resultados .res-search .ios-search-ico {
    width: 32px;
    height: 36px;
    color: var(--ios-label);
  }
  body.shell.page-resultados .res-search .ag-search,
  body.shell.page-resultados .res-search #q,
  body.shell.page-resultados #q {
    width: 100%;
    min-height: 36px !important;
    height: 36px !important;
    margin: 0;
    padding: 0 10px 0 0 !important;
    font-size: 16px !important;
    border: 0 !important;
    border-radius: 0;
    background: transparent !important;
    background-image: none !important;
    box-shadow: none !important;
  }
  body.shell.page-resultados .pager .btn,
  body.shell.page-resultados .pager .btn.ghost {
    min-height: 44px;
    font-size: 15px;
    font-weight: 500;
    background: transparent !important;
    color: var(--ios-tint) !important;
    box-shadow: none !important;
  }
  body.shell.page-resultados .visao-pedidos-table tbody tr.pedido-card td {
    padding: 12px 0 !important;
  }
  body.shell.page-resultados .pedido-ov,
  body.shell.page-resultados .pedido-date,
  body.shell.page-resultados .pedido-date-fat {
    font-size: 12px !important;
    font-weight: 400;
    color: var(--ios-label) !important;
  }
  body.shell.page-resultados .pedido-razao {
    font-size: 16px !important;
    font-weight: 600;
    white-space: normal;
  }
  body.shell.page-resultados .pedido-ov-val {
    font-size: 16px !important;
    font-weight: 650 !important;
    color: #000 !important;
  }
  body.shell.page-resultados .pedido-fat {
    font-size: 13px !important;
    font-weight: 500 !important;
    color: var(--ios-label) !important;
  }
  body.shell.page-resultados .pedido-vals .badge,
  body.shell.page-resultados .pedido-side .badge {
    padding: 2px 8px;
    font-size: 11px;
    font-weight: 600;
    border: 0;
  }
  body.shell.page-resultados .pager {
    margin: 8px 0 0 !important;
  }
  body.shell.page-resultados .res-period-bar .month-year,
  body.shell.page-resultados .visao-month-bar .month-year {
    background: transparent;
    min-height: 44px;
    padding: 0;
  }
  body.shell.page-resultados .res-period-bar .month-grid,
  body.shell.page-resultados .visao-month-bar .month-grid {
    gap: 6px;
    background: transparent;
    border-radius: 0;
  }
  body.shell.page-resultados .res-period-bar .month-chip,
  body.shell.page-resultados .visao-month-bar .month-chip {
    border-radius: 10px;
    background: var(--ios-fill-2) !important;
    color: #000 !important;
  }
  body.shell.page-resultados .res-period-bar .month-chip.on,
  body.shell.page-resultados .visao-month-bar .month-chip.on {
    background: var(--ios-tint) !important;
    color: #fff !important;
  }

  body.shell .ios-search-field,
  body.shell label.ios-search-field,
  body.shell .res-search {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    height: 36px !important;
    min-height: 36px !important;
    max-height: 36px !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    border: 0 !important;
    border-radius: 10px !important;
    background: var(--ios-fill-2) !important;
    box-shadow: none !important;
  }
  body.shell .ios-search-input,
  body.shell .ios-search-field .ios-search-input,
  body.shell #agBusca,
  body.shell #q {
    flex: 1 1 auto !important;
    width: auto !important;
    max-width: none !important;
    min-width: 0 !important;
    height: 36px !important;
    min-height: 0 !important;
    max-height: 36px !important;
    margin: 0 !important;
    padding: 0 8px 0 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: none !important;
    background-image: none !important;
    box-shadow: none !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    font-size: 16px !important;
    font-weight: 400 !important;
    line-height: 20px !important;
    color: #000 !important;
  }
  body.shell .ios-search-input::-webkit-search-decoration,
  body.shell .ios-search-input::-webkit-search-cancel-button,
  body.shell #agBusca::-webkit-search-decoration,
  body.shell #agBusca::-webkit-search-cancel-button,
  body.shell #q::-webkit-search-decoration,
  body.shell #q::-webkit-search-cancel-button {
    -webkit-appearance: none;
    appearance: none;
  }
}
