/* Branches (branches.js): the badge on orders, filter chips and the settings tab. */
.br-badge { display: inline-flex; align-items: center; gap: 3px; width: fit-content; margin-top: 3px; padding: 1px 9px; border-radius: 999px; background: var(--br-bg, #eaf1fe); color: var(--br-fg, #2563eb); font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.br-badge.br-none { background: #fdecea; color: #b42318; }
.br-badge.br-sm { margin-top: 0; font-size: 11px; }
.zid-col-place .br-badge { display: flex; }
.br-chips { margin-top: -4px; }
.br-chips-label { align-self: center; color: #55677f; font-size: 12.5px; font-weight: 700; }
.br-chip-none:not(.is-active) b { color: #b42318; }
.br-select { max-width: 100%; padding: 6px 10px; border: 1px solid #dfe6f1; border-radius: 10px; background: #fff; font: inherit; font-size: 13px; color: #0b1b3d; }
.order-facts .br-select { margin-inline-start: 6px; }
#mShell .m-rows > div:has(.m-branch-select) { flex-wrap: wrap; }
#mShell .m-rows .m-branch-select { flex: 1 0 100%; width: 100%; margin-top: 6px; }

.br-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.br-card { display: grid; gap: 10px; padding: 14px; border: 1px solid #e3e9f4; border-top: 4px solid var(--br-fg); border-radius: 14px; background: #fff; }
.br-card-head { display: flex; align-items: center; gap: 8px; }
.br-card-head b { flex: 1; color: #0b1b3d; font-size: 15px; }
.br-card-head small { color: #6b7489; font-weight: 700; }
.br-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--br-fg); }
.br-cities { display: flex; flex-wrap: wrap; gap: 5px; }
.br-cities span { padding: 2px 10px; border-radius: 999px; background: #f3f5f9; color: #33415c; font-size: 12px; font-weight: 600; }
.br-cities span small { color: #98a2b3; }
.br-card .row-actions { justify-content: flex-start; }
.br-loose { display: grid; gap: 6px; margin-top: 14px; padding: 12px 14px; border-radius: 12px; background: #fff7ed; }
.br-loose > b { color: #a35a00; }

.br-modal .inv-modal-body > * { flex-shrink: 0; }
.br-picks { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 6px; max-height: 280px; overflow: auto; padding: 2px; }
.br-picks label { display: flex; align-items: flex-start; gap: 8px; padding: 7px 10px; border: 1px solid #e3e9f4; border-radius: 10px; cursor: pointer; }
.br-picks label:has(input:checked) { border-color: #2563eb; background: #f5f8ff; }
.br-picks span { display: grid; font-size: 13px; font-weight: 600; color: #0b1b3d; }
.br-picks small { color: #6b7489; font-size: 11.5px; font-weight: 500; }
.br-modal [hidden] { display: none !important; }


/* channel badge icon, new branch order form */
.br-badge svg { width: 11px; height: 11px; flex: none; }
.br-modal .task-form-grid > .br-span { grid-column: 1 / -1; }
.br-check { display: flex; align-items: center; gap: 8px; padding: 8px 2px; font-weight: 700; color: #0b1b3d; cursor: pointer; }
.br-check input { width: 18px; height: 18px; }
.br-found { margin: 0; padding: 8px 12px; border-radius: 10px; background: #e8f5ee; color: #15803d; font-size: 13px; font-weight: 700; }
.br-hint { margin-top: 10px; }
#mShell .m-new-order { width: 100%; justify-content: center; }
@media (max-width: 760px) {
  .br-modal .inv-modal-body .form-grid.task-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; gap: 10px; }
  .br-modal .task-form-grid input, .br-modal .task-form-grid select { min-width: 0; width: 100%; }
}
.br-badges { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 3px; }

/* the source switcher (top bar and phone home) */
.br-switch { display: inline-flex; align-items: center; gap: 6px; height: 38px; padding: 0 10px; border: 1px solid #dfe6f1; border-radius: 12px; background: #fff; color: #33415c; cursor: pointer; }
.br-switch select { border: 0; background: transparent; font: inherit; font-size: 13.5px; font-weight: 700; color: #0b1b3d; cursor: pointer; max-width: 190px; outline: none; }
.br-switch.is-on { border-color: #2563eb; background: #eaf1fe; color: #2563eb; }
.br-switch.is-on select { color: #1d4ed8; }
.br-switch.is-fixed b { font-size: 13.5px; color: #0b1b3d; }
[data-br-switch-holder] { display: flex; align-items: center; margin-inline-end: 8px; }
.m-home-head .br-switch.m-switch { margin-top: 12px; width: 100%; height: 40px; border-color: rgba(255, 255, 255, 0.25); background: rgba(255, 255, 255, 0.12); color: #fff; }
.m-home-head .br-switch.m-switch select { flex: 1; max-width: none; color: #fff; }
.m-home-head .br-switch.m-switch select option { color: #0b1b3d; }
.m-home-head .br-switch.m-switch.is-on { background: rgba(255, 255, 255, 0.22); }
.zo-branch-orders { display: grid; gap: 6px; padding: 10px 12px; border-radius: 12px; background: #f5f7fb; font-size: 13px; }
.m-row-text .br-badges { margin: 2px 0; }
.br-danger { color: #b42318 !important; border-color: #f3d3d0 !important; }
.br-danger:hover { background: #fdecea !important; }
/* on the dark header of the order page the delete button keeps a light face */
.order-hero .br-danger { background: #fff !important; color: #b42318 !important; border-color: #fff !important; }
.order-hero .br-danger:hover { background: #fdecea !important; }
/* «طلب جديد»: branch or online store */
.br-choose { width: min(560px, 100%); }
.br-choose-lead { color: #5b6b82; font-size: 13.5px; margin: 0 0 12px; }
.br-choose-grid { display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.br-choose-card { align-items: flex-start; background: #fff; border: 1px solid #e3eaf4; border-radius: 16px; cursor: pointer; display: flex; flex-direction: column; font: inherit; gap: 6px; padding: 14px; text-align: start; transition: border-color 0.15s, box-shadow 0.15s, transform 0.15s; }
.br-choose-card:hover, .br-choose-card:focus-visible { border-color: #2f6fe4; box-shadow: 0 8px 20px rgba(47, 111, 228, 0.12); outline: none; transform: translateY(-1px); }
.br-choose-icon { align-items: center; background: #eef4ff; border-radius: 12px; color: #2f6fe4; display: flex; height: 42px; justify-content: center; width: 42px; }
.br-choose-card b { color: #0b1f3a; font-size: 15px; }
.br-choose-card small { color: #5b6b82; font-size: 12px; line-height: 1.6; }
.br-choose-card em { background: #f1f4f9; border-radius: 999px; color: #55607a; font-size: 11px; font-style: normal; padding: 2px 8px; }
.br-choose-card.is-online { background: linear-gradient(160deg, #f7f3ff, #fff 70%); border-color: #dccff7; }
.br-choose-card.is-online .br-choose-icon { background: #6c3cd6; color: #fff; }
.br-choose-card.is-online:hover { border-color: #6c3cd6; box-shadow: 0 8px 20px rgba(108, 60, 214, 0.15); }
