/* ---------- Tokens ---------- */
:root {
  color-scheme: light;
  --bg: #f4f4f1; --surface: #fcfcfb; --surface-2: #f0efec; --border: #e2e1dc;
  --text: #0b0b0b; --text-2: #52514e; --text-3: #8a8985;
  --accent: #2a78d6; --accent-soft: #e3eefb;
  --good: #008300; --good-soft: #e3f3e3; --warn: #c98500; --warn-soft: #fff3d6; --bad: #e34948; --bad-soft: #fde5e5;
  --series-1: #2a78d6; --series-2: #eb6834; --series-3: #1baf7a; --series-4: #eda100; --series-5: #e87ba4;
  --radius: 10px; --shadow: 0 1px 2px rgba(0,0,0,.05), 0 4px 16px rgba(0,0,0,.04);
  --font: "IBM Plex Sans Arabic", -apple-system, "Segoe UI", Tahoma, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, monospace;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { font-family: var(--font); font-size: 14px; color: var(--text); background: var(--bg); line-height: 1.6; }
a { color: var(--accent); text-decoration: none; } a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0; font-weight: 600; } h1 { font-size: 22px; } h2 { font-size: 17px; } h3 { font-size: 14px; }
p { margin: 0; } small { font-size: 12px; color: var(--text-2); }
[hidden] { display: none !important; }
.num, .mono, .ltr { direction: ltr; unicode-bidi: isolate; font-variant-numeric: tabular-nums; }

/* ---------- Login ---------- */
.login { min-height: 100vh; display: grid; place-items: center; background: var(--bg); padding: 24px; }
.login-card { width: min(420px, 100%); background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 32px; box-shadow: var(--shadow); }
.login-card .brand { justify-content: center; margin-bottom: 20px; font-size: 20px; }
.login-card .brand-mark { width: 40px; height: 40px; font-size: 20px; }
.login-demo { margin-top: 18px; padding-top: 16px; border-top: 1px dashed var(--border); }
.login-demo .row { justify-content: center; }

/* ---------- Layout ---------- */
.topbar { display: flex; align-items: center; gap: 20px; height: 56px; padding: 0 20px; background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 20; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 16px; }
.brand-mark { width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; background: var(--text); color: #fff; font-size: 15px; }
.topbar-search { flex: 1; max-width: 460px; } .topbar-search input { background: var(--surface-2); border-color: transparent; }
.topbar-right { margin-inline-start: auto; display: flex; gap: 10px; align-items: center; }
.user-chip { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.user-chip .avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-weight: 600; }
.user-chip small { display: block; line-height: 1.1; }
.dot { display: inline-grid; place-items: center; min-width: 16px; height: 16px; border-radius: 8px; background: var(--bad); color: #fff; font-size: 10px; padding: 0 4px; }
.dot:empty { display: none; }

.shell { display: flex; min-height: calc(100vh - 56px); }
.sidebar { width: 230px; flex: none; padding: 14px 12px; border-inline-end: 1px solid var(--border); background: var(--surface); }
.sidebar .nav-title { font-size: 11px; color: var(--text-3); padding: 12px 10px 4px; }
.sidebar a { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 8px 10px; border-radius: 8px; color: var(--text-2); font-weight: 500; }
.sidebar a:hover { background: var(--surface-2); text-decoration: none; }
.sidebar a.active { background: var(--accent-soft); color: var(--accent); }
.sidebar .count { font-size: 11px; background: var(--surface-2); padding: 1px 7px; border-radius: 10px; color: var(--text-2); }
.sidebar a.active .count { background: #fff; }
.sidebar .role-note { margin: 16px 10px 0; font-size: 11px; color: var(--text-3); border-top: 1px solid var(--border); padding-top: 12px; }

.content { flex: 1; padding: 24px 28px; max-width: 1320px; min-width: 0; }
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 20px; }
.page-head p { color: var(--text-2); margin-top: 4px; }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- Cards & grid ---------- */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 18px; }
.card + .card { margin-top: 16px; }
.card-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; gap: 12px; }
.card-head h2, .card-head h3 { display: flex; align-items: center; gap: 8px; }
.grid { display: grid; gap: 16px; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.grid > .card { margin: 0; } .span-2 { grid-column: span 2; }
@media (max-width: 1250px) { .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 1100px) { .grid-4, .grid-5 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.stat { padding: 16px 18px; }
.stat .label { font-size: 12px; color: var(--text-2); }
.stat .value { font-size: 24px; font-weight: 600; margin-top: 2px; }
.stat .value.hero { font-size: 36px; }
.stat .delta { font-size: 12px; margin-top: 4px; color: var(--text-2); }
.stat .delta.up { color: var(--good); } .stat .delta.down { color: var(--bad); }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { text-align: start; padding: 10px; border-bottom: 1px solid var(--border); vertical-align: middle; white-space: nowrap; }
th { font-size: 11px; color: var(--text-3); font-weight: 600; }
td.num, th.num { text-align: start; }
tr.clickable { cursor: pointer; } tr.clickable:hover td { background: var(--surface-2); }
tbody tr:last-child td { border-bottom: 0; }
td.wrap { white-space: normal; min-width: 120px; }
td .sub { display: block; font-size: 12px; color: var(--text-3); }
.empty { padding: 28px; text-align: center; color: var(--text-3); }
tr.total td { font-weight: 600; background: var(--surface-2); }
tr.selected td { background: var(--accent-soft); }
tr.profile td { background: var(--bg); padding: 12px; white-space: normal; }
.profile-box table { font-size: 12px; }
.profile-box { border: 1px solid var(--border); border-radius: 10px; padding: 16px; background: var(--surface); }
.profile-box .card { margin: 0; }

/* ---------- Badges ---------- */
.badge { display: inline-flex; align-items: center; gap: 5px; padding: 2px 9px; border-radius: 999px; font-size: 12px; font-weight: 500; white-space: nowrap; background: var(--surface-2); color: var(--text-2); }
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge.blue { background: var(--accent-soft); color: #1c5cab; } .badge.green { background: var(--good-soft); color: var(--good); }
.badge.amber { background: var(--warn-soft); color: #8a5b00; } .badge.red { background: var(--bad-soft); color: #b32d2c; }
.badge.gray { background: var(--surface-2); color: var(--text-2); } .badge.plain::before { display: none; }
.tag { font-size: 11px; padding: 1px 7px; border-radius: 4px; background: var(--surface-2); color: var(--text-2); }
.lock { color: var(--text-3); font-size: 12px; }

/* ---------- Buttons & forms ---------- */
.btn { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--border); background: var(--surface); color: var(--text); padding: 7px 13px; border-radius: 8px; font: inherit; font-weight: 500; cursor: pointer; transition: background .1s; }
.btn:hover { background: var(--surface-2); }
.btn-primary { background: var(--text); color: #fff; border-color: var(--text); } .btn-primary:hover { background: #333; }
.btn-accent { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn-good { background: var(--good); color: #fff; border-color: var(--good); }
.btn-danger { background: var(--surface); color: var(--bad); border-color: var(--bad); } .btn-danger:hover { background: var(--bad-soft); }
.btn-ghost { border-color: transparent; background: transparent; color: var(--text-2); }
.btn-sm { padding: 4px 10px; font-size: 12px; } .btn:disabled { opacity: .5; cursor: not-allowed; }

.form { display: grid; gap: 14px; }
.form-row { display: grid; gap: 14px; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
.form-row.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.form-flow { display: flex; flex-wrap: wrap; gap: 14px; align-items: flex-start; }
.form-flow > .field { flex: 1 1 180px; min-width: 0; }
.field-inline { display: grid; gap: 5px; justify-items: start; }
.field { display: grid; gap: 5px; align-content: start; }
.field label { font-size: 12px; font-weight: 500; color: var(--text-2); min-height: 18px; display: flex; align-items: flex-end; }
.field .hint { min-height: 16px; }
.field .hint { font-size: 11px; color: var(--text-3); line-height: 1.4; }
input, select, textarea { font: inherit; padding: 8px 10px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); color: var(--text); width: 100%; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent-soft); border-color: var(--accent); }
input[type=number] { direction: ltr; text-align: end; }
input[type=number]::-webkit-outer-spin-button, input[type=number]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
input[type=number] { -moz-appearance: textfield; }
input[data-money] { direction: ltr; text-align: end; font-variant-numeric: tabular-nums; }
textarea { resize: vertical; min-height: 70px; }
.input-group { display: flex; align-items: center; }
.input-group input { border-radius: 0 8px 8px 0; }
.input-group span { padding: 8px 10px; border: 1px solid var(--border); border-inline-start: 0; border-radius: 8px 0 0 8px; background: var(--surface-2); color: var(--text-2); font-size: 12px; white-space: nowrap; }
.segmented { display: inline-flex; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.segmented button { border: 0; background: transparent; padding: 7px 12px; font: inherit; cursor: pointer; color: var(--text-2); }
.segmented button + button { border-inline-start: 1px solid var(--border); }
.segmented button.active { background: var(--text); color: #fff; }
.filters { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 14px; }
.filters input[type=search] { max-width: 260px; } .filters select { width: auto; }
.items-editor .item-row { display: grid; grid-template-columns: minmax(0, 1.6fr) 76px minmax(0, 1fr) minmax(0, 1fr) 34px; gap: 8px; margin-bottom: 8px; align-items: center; }
.items-editor .item-row .btn { padding: 0; justify-content: center; }
/* the catalogue picker on the add-line page — a search, not a two-thousand-row select */
.picker { list-style: none; margin: 0 0 10px; padding: 0; display: grid; gap: 6px; max-height: 340px; overflow-y: auto; }
.picker button { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 10px; align-items: center;
  width: 100%; text-align: start; font: inherit; color: inherit; cursor: pointer;
  background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 7px 10px; }
.picker button:hover { background: var(--surface-2); border-color: var(--text-3); }
.picker img, .picked img { width: 44px; height: 44px; border-radius: 6px; object-fit: cover; display: block; background: var(--surface-2); }
.picker .who, .picked .who { min-width: 0; }
.picker .who b, .picked .who b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.picker .who small, .picked .who small { color: var(--text-3); }
.picked { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 10px; align-items: center;
  border: 1px solid var(--border); border-radius: 8px; padding: 7px 10px; background: var(--surface-2); }

.upload { border: 1px dashed var(--border); border-radius: 8px; padding: 10px; text-align: center; color: var(--text-3); font-size: 12px; background: var(--surface-2); }
.checkbox { display: flex; align-items: center; gap: 8px; } .checkbox input { width: auto; }
.perm-grid td:not(:first-child) { text-align: center; } .perm-grid input { width: auto; }

/* ---------- Order detail ---------- */
.order-layout { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 16px; align-items: start; }
.kv { display: grid; grid-template-columns: 130px 1fr; row-gap: 8px; column-gap: 12px; font-size: 13px; }
.kv dt { color: var(--text-3); } .kv dd { margin: 0; }
.stepper { display: flex; overflow-x: auto; padding-bottom: 4px; }
.step { flex: 1; min-width: 92px; padding: 8px 6px 0; text-align: center; font-size: 11px; color: var(--text-3); }
.step::before { content: ""; display: block; height: 4px; border-radius: 2px; background: var(--border); margin-bottom: 8px; }
.step.done::before { background: var(--good); } .step.done { color: var(--text-2); }
.step.current::before { background: var(--accent); } .step.current { color: var(--accent); font-weight: 600; }
.step.dead::before { background: var(--bad); } .step.dead { color: var(--bad); }
#pricingForm table { table-layout: fixed; }
#pricingForm th:nth-child(1), #pricingForm td:nth-child(1) { width: 27%; }
#pricingForm th:nth-child(2), #pricingForm td:nth-child(2) { width: 21%; }
#pricingForm th:nth-child(3), #pricingForm td:nth-child(3) { width: 10%; }
#pricingForm th:nth-child(4), #pricingForm td:nth-child(4) { width: 27%; }
#pricingForm th:nth-child(5), #pricingForm td:nth-child(5) { width: 10%; }
#pricingForm th:nth-child(6), #pricingForm td:nth-child(6) { width: 5%; }
#pricingForm td, #pricingForm th { padding-inline: 6px; }
#pricingForm td { vertical-align: middle; }
#pricingForm .input-group input, #pricingForm .pi-qty, #pricingForm .pi-name, #pricingForm .pi-sup { height: 38px; }
#pricingForm tfoot td { vertical-align: middle; }
.price-calc { display: grid; grid-template-columns: 1fr auto; row-gap: 6px; font-size: 13px; }
.price-calc .total { font-weight: 600; font-size: 15px; border-top: 1px solid var(--border); padding-top: 8px; margin-top: 4px; }
.price-calc .muted { color: var(--text-3); }
.hidden-field { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-radius: 8px; background: var(--surface-2); color: var(--text-3); font-size: 12px; }
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { display: grid; grid-template-columns: 14px minmax(0, 1fr); gap: 10px; padding: 6px 0; }
.timeline li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--border); margin-top: 8px; margin-inline-start: 3px; }
.timeline li.active::before { background: var(--accent); }
.timeline li .when { font-size: 11px; color: var(--text-3); }
.chat { display: flex; flex-direction: column; gap: 10px; max-height: 360px; overflow-y: auto; padding: 4px 2px; }
.msg { max-width: 85%; padding: 8px 12px; border-radius: 12px; background: var(--surface-2); font-size: 13px; }
.msg .who { font-size: 11px; color: var(--text-3); margin-bottom: 2px; }
.msg.mine { align-self: flex-end; background: var(--accent-soft); }
.msg .img { margin-top: 6px; width: 160px; height: 110px; border-radius: 8px; background: repeating-linear-gradient(45deg, #dcdcd8 0 8px, #ececea 8px 16px); display: grid; place-items: center; color: var(--text-3); font-size: 11px; }
.chat-input { display: flex; gap: 8px; margin-top: 10px; } .chat-input input { flex: 1; }
.gallery { display: flex; gap: 12px; flex-wrap: wrap; }
.shot { width: 124px; }
.shot .frame { width: 124px; height: 92px; border-radius: 8px; border: 1px solid var(--border); overflow: hidden; background: repeating-linear-gradient(45deg, #dcdcd8 0 8px, #ececea 8px 16px); display: grid; place-items: center; cursor: pointer; position: relative; }
.shot .frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
.shot .frame .doc { font-size: 22px; }
.shot .cap { font-size: 11px; color: var(--text-2); margin-top: 4px; line-height: 1.35; word-break: break-word; }
.shot .cap small { display: block; color: var(--text-3); font-size: 10px; }
.shot .rm { position: absolute; inset-inline-end: 4px; top: 4px; background: rgba(0,0,0,.55); color: #fff; border: 0; border-radius: 6px; width: 22px; height: 22px; cursor: pointer; line-height: 1; opacity: 0; transition: opacity .12s; }
.shot:hover .rm, .shot .rm:focus { opacity: 1; }
.sec { border: 1px solid var(--border); border-radius: 10px; padding: 12px; margin-bottom: 12px; }
.sec-head { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.sec-head b { font-size: 13px; }
.lightbox img { width: 100%; border-radius: 10px; display: block; }
.thumb { width: 44px; height: 44px; border-radius: 6px; background: repeating-linear-gradient(45deg, #dcdcd8 0 6px, #ececea 6px 12px); display: inline-grid; place-items: center; font-size: 14px; color: var(--text-3); }
.file-chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 6px; background: var(--surface-2); font-size: 11px; color: var(--text-2); }

.alert { padding: 10px 14px; border-radius: 8px; font-size: 13px; display: flex; gap: 10px; align-items: flex-start; }
.alert.warn { background: var(--warn-soft); color: #6f4a00; } .alert.info { background: var(--accent-soft); color: #1c5cab; }
.alert.bad { background: var(--bad-soft); color: #b32d2c; } .alert.good { background: var(--good-soft); color: var(--good); }
.alert + .alert, .alert + .card { margin-top: 12px; }
.actions-list { display: grid; gap: 8px; } .actions-list .btn { justify-content: flex-start; width: 100%; }

/* ---------- Charts ---------- */
.chart { width: 100%; } .chart svg { width: 100%; height: auto; display: block; overflow: visible; direction: ltr; }
.chart text { font-family: var(--font); fill: var(--text-2); font-size: 11px; }
.chart .grid line { stroke: var(--border); stroke-width: 1; } .chart .axis text { fill: var(--text-3); }
.chart .bar:hover, .chart .dot:hover { opacity: .8; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--text-2); margin-top: 10px; }
.legend span { display: inline-flex; align-items: center; gap: 6px; } .legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.funnel { display: grid; gap: 8px; }
.funnel .row { display: grid; grid-template-columns: 130px 1fr 90px; align-items: center; gap: 10px; font-size: 13px; }
.funnel .bar-track { height: 18px; background: var(--surface-2); border-radius: 4px; overflow: hidden; }
.funnel .bar-fill { height: 100%; background: var(--series-1); border-radius: 4px 0 0 4px; }
.meter { height: 8px; background: var(--surface-2); border-radius: 4px; overflow: hidden; } .meter i { display: block; height: 100%; background: var(--accent); }
.list-plain { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.list-plain li { display: flex; justify-content: space-between; gap: 12px; font-size: 13px; padding-bottom: 8px; border-bottom: 1px solid var(--border); }
.list-plain li:last-child { border-bottom: 0; padding-bottom: 0; }
.insight { display: grid; grid-template-columns: 28px 1fr; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 13px; }
.insight:last-child { border-bottom: 0; } .insight .icon { width: 28px; height: 28px; border-radius: 8px; display: grid; place-items: center; background: var(--surface-2); font-size: 14px; }
.insight b { display: block; }
.cash-box { display: grid; grid-template-columns: 40px 1fr auto; gap: 12px; align-items: center; padding: 12px; border: 1px solid var(--border); border-radius: 10px; }
.cash-box .avatar { width: 40px; height: 40px; border-radius: 50%; background: var(--surface-2); display: grid; place-items: center; font-weight: 600; }
.cash-box .amt { font-size: 18px; font-weight: 600; }
.task { display: grid; grid-template-columns: 24px 1fr auto; gap: 10px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 13px; }
.task:last-child { border-bottom: 0; } .task input { width: 18px; height: 18px; } .task.done span { text-decoration: line-through; color: var(--text-3); }
.task .meta { font-size: 11px; color: var(--text-3); display: block; }

/* ---------- Modal & toast ---------- */
.modal-root { position: fixed; inset: 0; background: rgba(10,10,10,.35); display: grid; place-items: center; z-index: 50; padding: 20px; }
.modal { background: var(--surface); border-radius: 14px; width: min(600px, 100%); max-height: 90vh; overflow-y: auto; box-shadow: 0 20px 60px rgba(0,0,0,.2); }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; border-bottom: 1px solid var(--border); }
.modal-body { padding: 20px; } .modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 20px; border-top: 1px solid var(--border); }
.toast-root { position: fixed; bottom: 20px; inset-inline-start: 20px; display: grid; gap: 8px; z-index: 60; }
.toast { background: var(--text); color: #fff; padding: 10px 14px; border-radius: 8px; font-size: 13px; box-shadow: var(--shadow); animation: fade .2s; }
@keyframes fade { from { opacity: 0; transform: translateY(6px); } }

.muted { color: var(--text-3); } .mt-2 { margin-top: 8px; } .mt-3 { margin-top: 12px; } .mt-4 { margin-top: 16px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; } .right { margin-inline-start: auto; }
.good { color: var(--good); } .bad { color: var(--bad); } .warn { color: var(--warn); }

/* ---------- additions for the Laravel build ---------- */
.wire-saving { opacity: .55; transition: opacity .15s; }
[wire\:loading] { display: none; }
.field input:disabled, .field select:disabled { background: var(--surface-2, #f4f4f2); color: var(--muted, #6b6b66); }
.alert { padding: 10px 12px; border-radius: 8px; margin-bottom: 12px; font-size: 13px; }
.alert-error { background: #fdecec; color: #a11; border: 1px solid #f5c6c6; }
.alert-ok { background: #eaf7ef; color: #17643a; border: 1px solid #bfe5cf; }

/* utilities the Blade views rely on */
.modal-backdrop { position: absolute; inset: 0; }
.modal { position: relative; z-index: 1; }
.p-3 { padding: 14px 18px; }
.col { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.pagination { display: flex; gap: 6px; list-style: none; padding: 0; margin: 0; }
.pagination a, .pagination span { padding: 4px 9px; border: 1px solid var(--border); border-radius: 7px; font-size: 13px; text-decoration: none; color: var(--text); }
.pagination .active span { background: var(--text); color: #fff; border-color: var(--text); }

/* horizontal bars — HTML, so Arabic labels never clip the way SVG text does */
.bar-row { display: grid; grid-template-columns: 130px 1fr 34px; align-items: center; gap: 10px; padding: 4px 0; }
.bar-label { font-size: 13px; color: var(--text-2); }
.bar-track { background: var(--surface-2); border-radius: 4px; height: 16px; overflow: hidden; }
.bar-fill { display: block; height: 100%; background: var(--series-1); border-radius: 4px; }
.bar-value { font-size: 12px; color: var(--text-3); text-align: start; }

/* attachments and the chat thread */
.sec { padding: 10px 0; border-block-end: 1px solid var(--border); }
.sec:last-child { border-block-end: 0; }
.sec-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; }
.file-chip { margin: 0; display: flex; flex-direction: column; gap: 4px; width: 108px; position: relative; }
.file-chip figcaption { font-size: 11px; line-height: 1.4; }
.file-chip figcaption small { display: block; color: var(--text-3); }
.file-chip .btn { position: absolute; inset-block-start: 2px; inset-inline-end: 2px; background: rgba(255,255,255,.9); }
.thumb-file { display: grid; place-items: center; font-size: 28px; background: var(--surface-2); border-radius: 8px; height: 80px; text-decoration: none; }
.upload { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; margin-top: 6px; }

/* the currency picker beside the foreign-cost amount */
.input-group .currency-pick { width: auto; min-width: 84px; flex: 0 0 auto; text-align: center; }

/* ------------------------------------------------- mentions in the order thread */
.msg .tag {
    background: var(--accent-soft, #e6f0fb);
    color: var(--accent, #1c3c6e);
    border-radius: 5px;
    padding: 0 4px;
    font-weight: 600;
    direction: ltr;
    unicode-bidi: isolate;
    display: inline-block;
}
.mention-strip {
    display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
    padding: 8px 12px 0; font-size: 12px;
}
.mention-strip .btn { direction: ltr; unicode-bidi: isolate; }

/* the bell in the top bar */
.bell { position: relative; }
.bell .count {
    position: absolute; top: -4px; inset-inline-end: -4px;
    min-width: 17px; height: 17px; padding: 0 4px;
    border-radius: 9px; background: #d64545; color: #fff;
    font-size: 11px; line-height: 17px; text-align: center; font-weight: 700;
}
.bell-list { max-height: 340px; overflow: auto; }
.bell-list .row-item {
    display: block; padding: 10px 12px; border-bottom: 1px solid var(--line, #e3e6ea);
    text-decoration: none; color: inherit;
}
.bell-list .row-item:hover { background: var(--surface-2, #f5f6f8); }
.bell-list .row-item.unseen { background: #f2f7fd; }
.bell-list .row-item small { color: var(--text-3, #7b8494); }

/* the dropdown the mentions list sits in */
.menu {
    position: absolute; top: calc(100% + 6px); z-index: 60;
    min-width: 320px; background: var(--surface, #fff);
    border: 1px solid var(--line, #e3e6ea); border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,.12); overflow: hidden;
}
.menu-end { inset-inline-end: 0; }
.menu-head {
    display: flex; justify-content: space-between; align-items: center;
    padding: 9px 12px; border-bottom: 1px solid var(--line, #e3e6ea);
    font-size: 13px;
}

/* ------------------------------- the website's own price list, shown as a label */
.web-price { margin-top: 4px; font-size: 12px; }
.web-price > summary {
    cursor: pointer; color: var(--accent, #1c3c6e); font-weight: 600;
    list-style: none; display: inline-block;
}
.web-price > summary::before { content: "▸ "; }
.web-price[open] > summary::before { content: "▾ "; }
.web-price-table { width: auto; margin: 6px 0 2px; border-collapse: collapse; }
.web-price-table td { padding: 2px 8px 2px 0; border: 0; font-size: 12px; white-space: nowrap; }
.web-price-table td.num { direction: ltr; unicode-bidi: isolate; font-weight: 600; }
.web-price .hint { margin: 2px 0 0; font-size: 11px; }

/* ------------------- the pricing table now carries a carriage box per line too */
#pricingTable { min-width: 780px; }
#pricingTable .input-group { min-width: 130px; }
#pricingTable .input-group input { min-width: 88px; }
