/* Maintenance > Sparepart: what is new on the request card. The card itself (.spr), the sticker (.covtag), the search (.m3s),
   the suggestion list (.tp-sugg) and the buttons (.btn-line, .m3-text) are the app's own; only the additions live here.
   Classes are .spl-* on purpose (.tk-* belongs to Projects). Colours are the app's tokens, so dark mode follows. */
.spr-t .covtag{margin-left:8px;vertical-align:2px}

/* the foot of the card: the button that opens the list, the grey line, and the old "Batalkan permintaan" */
.spr-foot{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.spr-foot .spl-btn + .spl-state,.spr-foot .spl-btn + .spr-cancel{margin-left:0}
.spl-state{font-size:13px;color:var(--ink-soft)}

/* the list opens on the request's own card: what the technician sent on the left, the manager's list on the right */
.spl{margin:14px 0 4px;padding-top:16px;border-top:1px solid var(--rule-soft)}
.spl-grid{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1.15fr);gap:32px;align-items:start}
@media (max-width:1100px){.spl-grid{grid-template-columns:minmax(0,1fr)}}
.spl-rep .spr-lab{margin-top:14px}
.spl-tech{font-size:13px;color:var(--ink-soft)}
.spl-photos{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px 12px}
.spl-img{position:relative;aspect-ratio:4/3;border-radius:8px;background:var(--field);border:1px solid var(--rule-soft);overflow:hidden}
.spl-img .pvth{width:100%;height:100%}
.spl-nt{font-size:13px;color:var(--ink-soft);margin-top:6px;line-height:1.35;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden;overflow-wrap:anywhere}
.spl-none{font-size:15px;color:var(--ink-soft)}
.spl-morebtn{margin:8px 0 0 -10px}
.spl-h{font-size:19px;font-weight:600;letter-spacing:-.01em}

/* the search, inside the list's own column */
.spl-find{position:relative;margin:10px 0 6px}
.spl-find .m3s{background:var(--field)}
.spl-find .m3s:focus-within{background:var(--surface)}
.spl-find .m3s input{font-size:15px}
.spl-sugg{--tp-wash:var(--field);position:static;width:100%;max-width:none;margin:6px 0 4px;box-shadow:none;max-height:min(380px,60vh)}
.spl-sugg[hidden]{display:none}
.spl-sugg button{align-items:baseline}
.spl-sugg .nm{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:15px}
.spl-code{font:13px 'JetBrains Mono',monospace;color:var(--ink-faint);flex-shrink:0}
.spl-nm .spl-code{display:block;margin-top:2px}
.spl-sn{font-size:13px;color:var(--ink-soft);white-space:nowrap;margin-left:10px}
.spl-sn.none{color:var(--ink-faint)}
.spl-more-line{padding:8px 10px 6px;font-size:13px;color:var(--ink-faint)}
.spl-more-line.late{color:var(--warn);display:flex;align-items:center;gap:4px;flex-wrap:wrap}
.spl-more-line .m3-text{margin-left:4px}

/* the lines */
.spl-empty{padding:6px 0 4px;font-size:15px;color:var(--ink-soft)}
.spl-line{padding:14px 0;border-bottom:1px solid var(--rule-soft)}
.spl-line.ok{box-shadow:inset 3px 0 0 var(--good);padding-left:12px;margin-left:-12px}
.spl-top{display:flex;gap:8px;align-items:flex-start}
.spl-nm{flex:1;min-width:0;font-size:15px;font-weight:500;overflow-wrap:anywhere}
.spl-x{border:0;background:none;color:var(--ink-faint);cursor:pointer;width:30px;height:30px;border-radius:15px;display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;padding:0}
.spl-x:hover{background:var(--field);color:var(--ink)}
.spl-x svg{width:16px;height:16px}
.spl-stk{font-size:13px;color:var(--ink-soft);margin-top:4px;line-height:1.45}
.spl-stk b{font-weight:600;color:var(--ink)}
.spl-faint{color:var(--ink-faint)}
.spl-at{color:var(--ink-faint)}
.spl-at.late{color:var(--warn)}
.spl-big{color:var(--ink-faint)}
.spl-row{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:10px;flex-wrap:wrap}
.spl-qty{display:flex;align-items:center;gap:10px}
.spl-qty b{font-size:15px;font-weight:600}
.spl-un{font-size:13px;color:var(--ink-soft)}
.spl-step{display:inline-flex;align-items:center;height:44px;background:var(--field);border-radius:22px}
.spl-step button{width:44px;height:44px;border:0;background:none;border-radius:22px;font:600 20px/1 'Inter',sans-serif;color:var(--ink);cursor:pointer;padding:0}
.spl-step button:hover{background:var(--field-h)}
.spl-qin{width:52px;height:40px;border:0;background:none;outline:none;text-align:center;font:600 15px 'Inter',sans-serif;color:var(--ink);font-variant-numeric:tabular-nums;padding:0}
.spl-step:focus-within{box-shadow:0 0 0 2px var(--ink-faint)}

/* the tick: a real button with role=checkbox, drawn like the app's own .tmbox (nothing the browser draws) */
.spl-tick{display:inline-flex;align-items:center;gap:10px;min-height:44px;border:0;background:none;padding:0 4px 0 0;font:15px 'Inter',sans-serif;color:var(--ink);cursor:pointer;text-align:left}
.spl-box{position:relative;width:19px;height:19px;flex:none;border:1.5px solid var(--ink-faint);border-radius:4px;background:var(--surface)}
.spl-tick[aria-checked="true"] .spl-box{background:var(--ink);border-color:var(--ink)}
.spl-tick[aria-checked="true"] .spl-box::after{content:"";position:absolute;left:5.5px;top:2px;width:5px;height:9.5px;border:solid var(--on-ink);border-width:0 2.2px 2.2px 0;transform:rotate(43deg)}
.spl-tick:focus-visible{outline:none}
.spl-tick:focus-visible .spl-box{outline:2px solid var(--accent);outline-offset:2px}
.spl-tag{font-size:13px;font-weight:600;padding:3px 10px;border-radius:6px}
.spl-tag.g{color:var(--good);background:var(--good-bg)}
.spl-tag.b{color:var(--warn);background:var(--field)}

/* the price (ours, typed once; the standard price comes back by itself) */
.spl-more{display:flex;align-items:flex-end;gap:14px;flex-wrap:wrap;margin-top:6px}
.spl-more label{display:flex;flex-direction:column;gap:4px;font-size:13px;color:var(--ink-soft)}
.spl-rp{display:flex;align-items:center;gap:6px;height:40px;width:150px;padding:0 12px;border-radius:10px;background:var(--field);border:1px solid transparent}
.spl-rp:focus-within{background:var(--surface);border-color:var(--ink-faint)}
.spl-rp span{font-size:13px;color:var(--ink-faint);flex:none;white-space:nowrap}
.spl-rp input{border:0;background:none;outline:none;width:100%;text-align:right;font:15px 'Inter',sans-serif;color:var(--ink);font-variant-numeric:tabular-nums;padding:0}
.spl-std[hidden]{display:none}
.spl-warn{font-size:13px;color:var(--warn);margin-top:8px}
.spl-warn:empty{display:none}
.spl-sum{font-size:13px;color:var(--ink-soft);margin-top:14px}

@media (max-width:600px){
  .spl-photos{grid-template-columns:repeat(2,minmax(0,1fr))}
  .spl-x{width:44px;height:44px;border-radius:22px;margin:-7px -8px 0 0}
  .spl-sugg button{flex-wrap:wrap}
  .spl-sugg .nm{flex:1 1 100%;white-space:normal}
  .spl-sugg .spl-sn{margin-left:auto}
  .spl-find .m3s input{font-size:16px}
  .spl-rp{height:44px}
}

/* a card scrolled into view must not hide under the phone's sticky top bar (#mBar, 52 px) */
.spr{scroll-margin-top:72px}
/* rows from the search before this one stay visible but cannot be pressed until the new answer is in */
.spl-sugg.spl-stale{opacity:.5;pointer-events:none}
/* the list could not be saved: said once, above the lines, with the way to try again */
.spl-note{font-size:13px;color:var(--warn);margin-top:8px}
.spl-note:empty{display:none}

/* "Ambil di <warehouse>": only when the ticked part has stock in two or more warehouses */
.spl-from{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.spl-from:empty{display:none}
.spl-from{margin-top:6px}
.spl-fp{position:relative}
.spl-fp .mp-pick{background:var(--field);border-radius:10px;min-height:40px;padding:0 12px;font-size:15px}
.spl-fp .mp-pick:hover{background:var(--field-h)}
.spl-fp select[hidden]{display:none}

/* ── phase 2: the forms ── */
.spl-tabs{margin-bottom:6px}
.spl-hrow{display:flex;align-items:center;justify-content:space-between;gap:10px}
.spl-hrow .m3-text{margin-right:-10px}
.spl-find[hidden]{display:none}
/* "Untuk keperluan": the app's own dropdown, drawn like the search box beside it */
.spl-pur{margin:12px 0 4px}
.spl-pur .spr-lab{margin-top:0}
.spl-purtxt{font-size:15px}
.mp-fieldpick.spl-fp .mp-pick{background:var(--field);border-radius:10px;min-height:44px;padding:0 14px;font-size:15px}
.mp-fieldpick.spl-fp .mp-pick:hover{background:var(--field-h)}
.spl-other{margin-top:8px}
.spl-bkw{width:110px}
/* the one dark button of the list */
.spl-make{margin-top:16px}
.spl-make .btn-line{width:100%;justify-content:center}
/* the forms a list made, inside the card */
.spl-let{display:grid;grid-template-columns:minmax(0,1.1fr) minmax(0,1.4fr) auto;gap:12px;align-items:baseline;width:100%;text-align:left;border:0;border-bottom:1px solid var(--rule-soft);background:none;padding:12px 0;cursor:pointer;font:15px 'Inter',sans-serif;color:var(--ink)}
.spl-let .no{font:13px 'JetBrains Mono',monospace}
.spl-let .st{font-size:13px;color:var(--ink-soft)}
.spl-let:hover{background:var(--field)}
/* the Surat permintaan tab */
.spl-lt .spl-lrow{cursor:pointer}
.spl-lt .spl-lrow:focus-visible{outline:2px solid var(--ink-faint);outline-offset:-2px}
.spl-lnm{font-size:15px;font-weight:500}
.spl-lsm{font-size:13px;color:var(--ink-faint);margin-top:2px}
.spl-cx{font-size:13px;font-weight:600;color:var(--ink-soft);background:var(--field);border-radius:6px;padding:2px 8px;margin-left:6px}
.spl-pvbar{display:flex;margin:16px 0 10px}
.spl-pvbar .grow{flex:1}
/* the paper is always black on white, in both themes; on a narrow screen it scrolls inside its own box */
.spl-paper{overflow-x:auto;padding-bottom:6px}
.spl-paper .sp-form{min-width:760px}
@media (max-width:600px){
  .spl-let{grid-template-columns:minmax(0,1fr) auto}
  .spl-let .no{grid-column:1 / -1}
}

/* anything scrolled into view (a press, a keyboard move) stops below the phone's fixed top bar and capsule, not under them */
#partsList button,#partsList input,#partsList tr,#partsList .sp-form{scroll-margin-top:72px}

/* "Ubah nomor": the running part is edited in place, on the form's own screen */
.spl-numed{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:6px 0 4px}
.spl-numin{width:92px;height:44px;border:1px solid transparent;border-radius:10px;background:var(--field);color:var(--ink);text-align:center;font:600 15px 'Inter',sans-serif;font-variant-numeric:tabular-nums;outline:none;padding:0}
.spl-numin:focus{background:var(--surface);border-color:var(--ink-faint)}
.spl-numrest{font:15px 'JetBrains Mono',monospace;color:var(--ink-soft)}
.spl-numerr{font-size:13px;color:var(--warn);margin:2px 0 6px}
.spl-numerr:empty{display:none}
.spl-numnote{font-size:13px;color:var(--ink-soft);margin:2px 0 8px}
.spl-pvbar{flex-wrap:wrap;gap:4px 8px;align-items:center}
.spl-pvbar .m3-text,.spl-pvbar .btn-line{white-space:nowrap}

/* more than one parts request on a job: which one this list is, and the forms of the earlier ones */
.spl-rnd{font-size:13px;font-weight:400;color:var(--ink-faint);margin-left:8px;letter-spacing:0}
.spl-earlier-lab{margin-top:18px}

/* ── phase 3: the full list of forms ── */
.spl-ltbar{display:flex;align-items:center;gap:10px;flex-wrap:wrap;margin:18px 0 10px}
.spl-ltbar .grow{flex:1}
.spl-ltq-w{width:340px;flex:0 1 340px}
.spl-ltpick{display:inline-block;width:auto}
.spl-ltpick .mp-pop{display:inline-block;width:auto}
.mp-fieldpick.spl-ltpick .mp-pick{width:auto;min-height:40px;padding:0 14px 0 14px;border-radius:20px;background:var(--field);font-size:15px;justify-content:space-between;gap:8px}
.spl-ltcount{font-size:13px;color:var(--ink-soft);min-height:22px;margin-bottom:4px}
.spl-th{display:inline-flex;align-items:center;gap:4px;border:0;background:none;padding:10px 8px 10px 0;margin:0;font:inherit;color:inherit;cursor:pointer;text-align:left}
.spl-th.on{color:var(--ink)}
.spl-th:focus-visible{outline:2px solid var(--ink-faint);outline-offset:2px;border-radius:4px}
.spl-ar{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:round;stroke-linejoin:round}
.spl-lt thead th{padding:0 !important}
.spl-ltmore{margin:14px 0 4px;display:flex;justify-content:center}
@media (max-width:760px){
  .spl-ltq-w{width:100%;flex:1 1 100%}
  .spl-ltbar .mp-menu{max-width:calc(100vw - 32px)}
  .spl-ltbar .spl-ltpick:nth-of-type(n+3) .mp-menu{left:auto;right:0}
}
/* on a phone the app turns each row into a card and hides the headings; the sort buttons stay, as a row of small buttons above the cards */
@media (max-width:760px){
  table.dt.spl-lt thead{display:block;border-bottom:1px solid var(--rule)}
  table.dt.spl-lt thead tr{display:flex;flex-wrap:wrap;gap:0 14px;border:0;padding:0}
  table.dt.spl-lt thead th{display:block;width:auto;border:0}
  .spl-th{padding:8px 0;font-size:13px}
}

/* ── Mata uang: one switch for the whole list (the app's sliding switch .spr-seg, seg-knob.js), the rate, the total (one dollar rate, 9 Nov 2026) ── */
.spl-curw{margin:10px 0 6px}
.spl-curw .spr-lab{margin-top:0}
.spl-currow{display:flex;align-items:center;gap:14px;flex-wrap:wrap}
.spl-cseg button{min-width:56px;font-size:14px}
.spl-rate{display:flex;align-items:center;gap:10px;flex-wrap:wrap;font-size:14px;min-height:40px}
.spl-rate:empty{display:none}
.spl-rate .spl-un{font-size:14px}
.spl-ratev{font-weight:600;font-variant-numeric:tabular-nums;color:var(--ink)}
.spl-mine{display:inline-flex;align-items:center;height:24px;padding:0 10px;border-radius:999px;font-size:14px;font-weight:500;background:color-mix(in srgb,var(--accent) 12%,transparent);color:var(--accent)}
.spl-rp.spl-ratew{width:120px}
.spl-rate .spl-numerr{flex-basis:100%;font-size:14px}
.spl-eq{font-size:14px;color:var(--ink-soft);font-variant-numeric:tabular-nums}
.spl-eq:empty{display:none}
.spl-tot{font-size:14px;font-weight:600;color:var(--ink);margin-top:12px;font-variant-numeric:tabular-nums}
.spl-tot:empty{display:none}
