/* mod-after: Aftersales tracker (staff) + customer tracker page */
.af-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.af-bar .chips { flex: 1; }
.af-bar .chip b { margin-left: 4px; }
.af-client { margin-bottom: 18px; }
.af-ch { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 4px 2px 10px; }
.af-ch > div { flex: 1; min-width: 180px; }
.af-ch b { display: block; color: var(--ink); font-size: 15px; }
.af-ch span { font-size: 12.5px; color: var(--muted); }
.af-av { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: #0b1533; color: #fff; font-weight: 800; font-size: 13px; flex: none; }
.af-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(380px, 1fr)); gap: 12px; }
.af-card { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; border-radius: 18px; border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow); }
.af-card::before { content: ""; position: absolute; left: 0; top: 14px; bottom: 14px; width: 4px; border-radius: 0 4px 4px 0; background: var(--line); }
.af-card.st-reported::before { background: #6a3fd1; } .af-card.st-checked::before { background: #0e7490; } .af-card.st-parts::before { background: #d98a00; }
.af-card.st-scheduled::before { background: #0b5cff; } .af-card.st-fixed::before { background: #0e9f6e; } .af-card.st-closed { opacity: .75; }
.af-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.af-type { font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 99px; background: var(--neutral-bg); color: var(--ink); }
.af-type.t-warranty { background: #f3f0ff; color: #6a3fd1; } .af-type.t-repair { background: #fdecec; color: #c22b2b; } .af-type.t-cleaning { background: #e3f6ee; color: #0e7a55; }
.af-stage { font-size: 11px; font-weight: 800; padding: 2px 8px; border-radius: 99px; background: #0b1533; color: #fff; }
.af-stage.st-parts, .af-card.st-parts .af-stage { background: #d98a00; } .af-stage.st-fixed, .af-card.st-fixed .af-stage { background: #0e9f6e; }
.af-stage.st-closed, .af-card.st-closed .af-stage { background: var(--dim); } .af-stage.st-scheduled, .af-card.st-scheduled .af-stage { background: #0b5cff; }
.af-when { margin-left: auto; font-size: 12px; color: var(--muted); }
.af-issue { font-size: 14px; font-weight: 650; color: var(--ink); }
.af-unit, .af-jo { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 12.5px; color: var(--text); }
.af-unit svg.i, .af-jo svg.i { width: 15px; height: 15px; color: var(--muted); }
.af-jo { padding: 8px 10px; border-radius: 10px; background: #eef3ff; }
.af-jo .badge { margin-left: auto; }
.af-steps { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 4px; }
.af-steps span { display: flex; flex-direction: column; align-items: center; gap: 3px; text-align: center; position: relative; }
.af-steps span::after { content: ""; position: absolute; top: 12px; left: calc(50% + 14px); right: calc(-50% + 14px); height: 2px; background: var(--line); }
.af-steps span:last-child::after { display: none; }
.af-steps span.done::after { background: var(--ok); }
.af-steps i { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); border: 1.5px solid var(--line); color: var(--dim); }
.af-steps i svg.i { width: 12px; height: 12px; }
.af-steps em { font-style: normal; font-size: 10px; font-weight: 700; color: var(--dim); line-height: 1.2; }
.af-steps .done i { background: var(--ok); border-color: var(--ok); color: #fff; }
.af-steps .on i { background: #0b1533; border-color: #0b1533; color: #fff; box-shadow: 0 0 0 4px rgba(11,21,51,.12); }
.af-steps .on em { color: var(--ink); }
.af-parts { border-radius: 12px; background: var(--surface-2); padding: 6px 10px; }
.af-sub { font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--dim); padding: 4px 0; }
.af-sub b { color: #9a5b00; }
.af-part { display: flex; align-items: center; gap: 10px; padding: 7px 0; border-top: 1px dashed var(--line); }
.af-part > div { flex: 1; min-width: 0; }
.af-part b { display: block; font-size: 13px; color: var(--ink); }
.af-part span { font-size: 11.5px; color: var(--muted); }
.af-pst { font-size: 10.5px; font-weight: 800; padding: 2px 8px; border-radius: 99px; background: #fff3dc; color: #9a5b00; white-space: nowrap; }
.af-part.st-ordered .af-pst { background: #eef3ff; color: #0b5cff; } .af-part.st-arrived .af-pst { background: #e3f6ee; color: #0e7a55; } .af-part.st-replaced .af-pst { background: var(--neutral-bg); color: var(--muted); }
.af-acts { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 2px; }
.jo-af { display: flex; flex-direction: column; gap: 2px; padding: 9px 0; border-bottom: 1px solid var(--line-2); color: inherit; text-decoration: none; font-size: 13px; }
.jo-af:last-child { border-bottom: 0; }
.jo-af span { color: var(--muted); font-size: 12.5px; }
.jo-af .af-stage { align-self: flex-start; font-style: normal; }
@media screen and (max-width: 900px) {
  .af-cards { grid-template-columns: minmax(0, 1fr); }
  .af-steps em { font-size: 9px; }
  .af-bar .chips { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin: 0 -14px; padding: 2px 14px; }
  .af-bar .chips > * { flex: none; }
  .af-bar .inp-search { width: 100%; }
}

/* ---------- customer tracker page (track.html) ---------- */
.trk { max-width: 560px; margin: 0 auto; padding: 14px 14px 30px; font-family: var(--font); }
.trk-hero { position: relative; overflow: hidden; padding: 20px 18px; border-radius: 24px; background: #0b1533; color: #fff; margin-bottom: 12px; }
.trk-hero::before { content: ""; position: absolute; width: 260px; height: 260px; right: -110px; top: -130px; border-radius: 50%; background: radial-gradient(circle, rgba(0,184,240,.35), transparent 65%); }
.trk-hero > * { position: relative; }
.trk-hero img { height: 40px; width: auto; border-radius: 10px; background: #fff; padding: 4px; }
.trk-co { display: flex; align-items: center; gap: 10px; }
.trk-co b { display: block; font-size: 14px; } .trk-co span { font-size: 12px; opacity: .7; }
.trk-hero h1 { font-size: 26px; margin: 16px 0 4px; color: #fff; }
.trk-hero p { margin: 0; opacity: .8; font-size: 14px; }
.trk-now { display: inline-flex; flex-direction: column; margin-top: 14px; padding: 8px 14px; border-radius: 14px; background: rgba(255,255,255,.1); }
.trk-now em { font-style: normal; font-size: 11px; opacity: .7; text-transform: uppercase; letter-spacing: .06em; }
.trk-now b { font-size: 18px; color: #3fcf98; }
.trk-card { background: var(--surface); border-radius: 20px; padding: 16px; margin-bottom: 12px; box-shadow: 0 1px 2px rgba(11,21,51,.05), 0 10px 30px rgba(11,21,51,.07); }
.trk-card h3 { font-size: 15px; margin: 0 0 8px; }
.trk-steps { display: flex; flex-direction: column; gap: 0; }
.trk-steps > div { display: flex; align-items: center; gap: 12px; padding: 7px 0; position: relative; color: var(--dim); font-weight: 650; font-size: 14px; }
.trk-steps > div:not(:last-child)::after { content: ""; position: absolute; left: 13px; top: 34px; height: 14px; width: 2px; background: var(--line); }
.trk-steps i { width: 28px; height: 28px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-2); border: 1.5px solid var(--line); flex: none; }
.trk-steps i svg.i { width: 14px; height: 14px; }
.trk-steps .done { color: var(--text); } .trk-steps .done i { background: var(--ok); border-color: var(--ok); color: #fff; } .trk-steps .done::after { background: var(--ok) !important; }
.trk-steps .on { color: var(--ink); font-weight: 800; } .trk-steps .on i { background: #0b1533; border-color: #0b1533; color: #fff; box-shadow: 0 0 0 5px rgba(11,21,51,.12); }
.trk-row { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-top: 1px dashed var(--line-2); font-size: 13.5px; }
.trk-row:first-of-type { border-top: 0; }
.trk-row span { color: var(--muted); } .trk-row b { text-align: right; color: var(--ink); }
.trk-visit { display: flex; align-items: center; gap: 12px; background: #eef3ff; }
.trk-visit > svg.i { width: 26px; height: 26px; color: #0b5cff; }
.trk-visit em { display: block; font-style: normal; font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: #0b5cff; }
.trk-visit b { display: block; font-size: 16px; color: var(--ink); } .trk-visit span { font-size: 12.5px; color: var(--muted); }
.trk-part { display: flex; align-items: center; gap: 10px; padding: 9px 0; border-top: 1px dashed var(--line-2); }
.trk-part > div { flex: 1; } .trk-part b { display: block; font-size: 13.5px; } .trk-part span { font-size: 12px; color: var(--muted); }
.trk-part em { font-style: normal; font-size: 11px; font-weight: 800; padding: 3px 9px; border-radius: 99px; background: #fff3dc; color: #9a5b00; }
.trk-part.st-ordered em { background: #eef3ff; color: #0b5cff; } .trk-part.st-arrived em { background: #e3f6ee; color: #0e7a55; } .trk-part.st-replaced em { background: var(--neutral-bg); color: var(--muted); }
.trk-tl { list-style: none; margin: 0; padding: 0; }
.trk-tl li { position: relative; padding: 0 0 14px 20px; }
.trk-tl li::before { content: ""; position: absolute; left: 3px; top: 6px; width: 9px; height: 9px; border-radius: 50%; background: var(--ink); }
.trk-tl li:not(:last-child)::after { content: ""; position: absolute; left: 7px; top: 17px; bottom: 0; width: 1px; background: var(--line); }
.trk-tl b { display: block; font-size: 13.5px; font-weight: 650; color: var(--ink); } .trk-tl span { font-size: 11.5px; color: var(--muted); }
.trk-tl li.st-fixed::before, .trk-tl li.st-closed::before { background: var(--ok); } .trk-tl li.st-parts::before { background: #d98a00; }
.trk-acts { display: flex; gap: 8px; margin: 6px 0 10px; } .trk-acts .btn { flex: 1; height: 48px; border-radius: 14px; justify-content: center; }
.trk-foot { text-align: center; font-size: 11.5px; color: var(--dim); }

/* Daily Schedule › Crew: one card per team (crew tagged together) */
.ops-team { padding: 14px 16px; display: flex; flex-direction: column; gap: 10px; }
.ops-team-h { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ops-team-n { font-size: 15px; font-weight: 800; color: var(--ink); margin-right: 4px; }
.ops-team-m { display: flex; flex-wrap: wrap; gap: 8px; }
.ops-team-p { display: flex; align-items: center; gap: 8px; padding: 6px 10px 6px 6px; border-radius: 12px; background: var(--surface-2); }
.ops-team-p b { display: block; font-size: 13px; color: var(--ink); line-height: 1.2; }
.ops-team-p em { font-style: normal; font-size: 11px; color: var(--muted); }
.ops-team .ops-crew-jobs a em { display: block; font-style: normal; font-size: 11px; color: var(--dim); }
.ops-team-f { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; color: var(--muted); padding-top: 8px; border-top: 1px dashed var(--line-2); }
.ops-team.none { border-color: #f0c98a; background: #fffaf0; }
.ops-team.free { background: var(--surface-2); }
.ops-team.free .ops-team-p { background: var(--surface); }

/* Aftersales › Warranty: installed units with coverage bars */
.wu { display: flex; flex-direction: column; gap: 10px; padding: 14px 16px; border-radius: 18px; border: 1px solid var(--line); background: var(--surface); box-shadow: var(--shadow); }
.wu-h { display: flex; align-items: center; gap: 10px; }
.wu-h > div { flex: 1; min-width: 0; }
.wu-h b { display: block; color: var(--ink); font-size: 14px; }
.wu-h .mono { font-size: 11.5px; color: var(--muted); }
.wu-st { font-size: 11px; font-weight: 800; padding: 3px 9px; border-radius: 99px; background: #e3f6ee; color: #0e7a55; white-space: nowrap; }
.wu.st-soon .wu-st { background: #fff3dc; color: #9a5b00; } .wu.st-comp .wu-st { background: #eef3ff; color: #0b5cff; } .wu.st-expired .wu-st { background: #fdecec; color: var(--bad); }
.wu.st-expired { opacity: .8; }
.wu-meta { font-size: 12.5px; color: var(--muted); }
.wu-cov { display: flex; flex-direction: column; gap: 7px; }
.wu-cov > div { display: grid; grid-template-columns: 120px 1fr; align-items: center; column-gap: 10px; }
.wu-cov span { font-size: 12px; font-weight: 700; color: var(--ink); }
.wu-cov > div > i { display: block; height: 8px; border-radius: 99px; background: var(--line-2); overflow: hidden; }
.wu-cov > div > i > i { display: block; height: 100%; border-radius: inherit; background: var(--ok); }
.wu-cov .soon > i > i { background: #d98a00; }
.wu-cov em { grid-column: 2; font-style: normal; font-size: 11px; color: var(--muted); }
.wu-cov .off span, .wu-cov .off em { color: var(--dim); }
@media screen and (max-width: 900px) { .wu-cov > div { grid-template-columns: 96px 1fr; } }
