/* Blue brand accents with neutral, low-saturation dark surfaces. */
:root {
    color-scheme: light;
    --ink: #182334;
    --muted: #5c6678;
    --primary: #2859dc;
    --bg: #f7f8fa;
    --line: #e1e5ec;
    --glass: #ffffff;
    --glass-edge: #e1e5ec;
    --surface: #ffffff;
    --card: #ffffff;
    --field: #fafbfe;
    --tint: #f1f4fa;
    --blue-soft: #edf3ff;
    --blue-ink: #2454c6;
    --royal-soft: #edf1f7;
    --royal-ink: #3e5774;
    --mint-soft: #e6efe5;
    --mint-ink: #3c6646;
    --rose-soft: #f8eae6;
    --rose-ink: #a04c40;
    --amber-soft: #f7efda;
    --amber-ink: #7e652d;
    --shadow: 0 3px 18px rgba(36, 37, 29, .025);
    --shine: 0 0 0 transparent;
    --yangon-blue: #2859dc;
    --yangon-polo: #668da5;
    --changi-plum: #3e5774;
    --changi-teal: #2859dc;
    --action-bg: #2859dc;
    --action-ink: #ffffff;
    --action-hover: #1f4bc7;
    --header-bg: #2d5cff;
    --header-ink: #ffffff;
    --header-control: #2450df;
    --header-line: #ffffff40;
}
html[data-theme="dark"] {
    color-scheme: dark;
    --ink: #edf0f4;
    --muted: #a8adb6;
    --primary: #acc2e0;
    --bg: #17191c;
    --line: #34383e;
    --glass: #212429;
    --glass-edge: #34383e;
    --surface: #2a2e34;
    --card: #212429;
    --field: #25292f;
    --tint: #2b3037;
    --blue-soft: #2b3748;
    --blue-ink: #c3d5ee;
    --royal-soft: #303844;
    --royal-ink: #c4cfdf;
    --mint-soft: #2a392e;
    --mint-ink: #b0d2b5;
    --rose-soft: #3d2b26;
    --rose-ink: #e7a392;
    --amber-soft: #3c3524;
    --amber-ink: #e0cb91;
    --shadow: 0 3px 18px rgba(0, 0, 0, .08);
    --shine: 0 0 0 transparent;
    --action-bg: #acc2e0;
    --action-ink: #1b293c;
    --action-hover: #c0d2eb;
    --header-bg: #222c3a;
    --header-ink: #edf0f4;
    --header-control: #2b3748;
    --header-line: #455063;
}
body {
    background: var(--bg);
    color: var(--ink);
    isolation: isolate;
    font-size: 16px;
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}
body::before, body::after { display: none; }
html[data-theme="dark"] :is(.sidebar, .login-story) .brand-logo { background: #ffffff; border-radius: 12px; padding: 5px; }
a { color: var(--primary); }
a:hover { color: var(--blue-ink); }
h1, h2, h3 { color: var(--ink); font-weight: 700; }
h1 { font-size: clamp(28px, 2.5vw, 38px); letter-spacing: -1px; }
h2 { font-size: 20px; }
h3 { font-size: 17px; }
.subtle, label, .help, .metric-label, .metric-foot, td small, .timeline small,
.summary-list dt, .breadcrumbs, .user small, .text-button { color: var(--muted); }
.subtle, label, .metric-label { font-size: 15px; }
.help, .metric-foot, td small, .timeline small { font-size: 14px; }
.eyebrow { color: var(--primary); font-size: 12px; letter-spacing: 1.8px; font-weight: 700; }

/* Solid surfaces keep each section clear and easy to scan. */
.sidebar, header, .card, .metric, .intro-banner, .login-shell, .photo-viewer {
    background: var(--card);
    border: 1px solid var(--glass-edge);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
    box-shadow: var(--shadow);
}
.sidebar {
    inset: 0 auto 0 0;
    width: 240px;
    padding: 23px 16px;
    border-radius: 0;
    border: 0;
    border-right: 1px solid var(--line);
    box-shadow: none;
    color: var(--ink);
    overflow-y: auto;
    scrollbar-width: thin;
}
.sidebar .brand {
    flex-direction: row;
    align-items: center;
    gap: 11px;
    padding: 10px 8px 24px;
    margin: 0 0 12px;
    color: var(--ink);
    border-bottom: 1px solid var(--line);
}
.sidebar .brand-logo { width: 53px; height: 53px; aspect-ratio: auto; max-width: none; }
.sidebar .brand-copy { font-size: 23px; }
.sidebar .brand small { color: var(--muted); font-size: 7px; letter-spacing: 1.2px; line-height: 1.8; }
.sidebar .nav-caption { color: var(--muted); font-size: 12px; font-weight: 600; margin: 16px 14px 14px; }
.sidebar nav a {
    min-height: 48px;
    padding: 10px 12px;
    border: 1px solid transparent;
    border-radius: 12px;
    color: var(--muted);
    font-size: 15px;
    font-weight: 600;
    gap: 12px;
    transition: background .18s, box-shadow .18s, color .18s;
}
.sidebar nav a span {
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 6px;
    background: transparent;
    color: var(--primary);
    font-size: 17px;
    flex-shrink: 0;
}
.sidebar nav a:hover { background: var(--tint); color: var(--ink); }
.sidebar nav a.active {
    color: var(--blue-ink);
    border-color: var(--glass-edge);
    background: var(--blue-soft);
    box-shadow: none;
}
.sidebar nav a.active span { background: transparent; border-color: transparent; color: var(--blue-ink); }
.nav-more { padding: 0; margin-top: 18px; border: 0; }
.nav-more > summary { padding: 12px 14px; font-size: 14px; color: var(--muted); }
.sidebar-bottom { color: var(--muted); border-color: var(--line); font-size: 13px; line-height: 1.8; padding: 20px 8px 0; }
.sidebar-bottom small { color: var(--ink); font-weight: 700; font-size: 14px; }
.live-dot { background: #6b9e9c; box-shadow: none; }
.workspace { margin-left: 240px; min-width: 0; }
header { display: grid; grid-template-columns: minmax(0, 1fr) auto; height: auto; min-height: 80px; margin: 0; padding: 18px 36px; border: 0; border-radius: 0; gap: 18px; background: var(--header-bg); box-shadow: none; color: var(--header-ink); border-bottom: 1px solid var(--header-line); }
header :is(.breadcrumbs, .breadcrumbs strong, .breadcrumbs span, .user, .user small, .text-button) { color: var(--header-ink); }
header :is(.theme-switch, .language-switch) { background: var(--header-control); border-color: var(--header-line); }
header :is(.theme-switch, .language-switch) button { color: var(--header-ink); }
header :is(.theme-switch, .language-switch) button[aria-pressed="true"] { background: var(--surface); color: var(--ink); }
header .avatar { background: var(--blue-soft); color: var(--blue-ink); border-color: var(--line); }
.breadcrumbs { min-width: 0; overflow-wrap: anywhere; font-size: 14px; }
.breadcrumbs strong { color: var(--ink); font-weight: 650; }
.breadcrumbs span { color: var(--muted); margin: 0 10px; }
.user { grid-column: 2; grid-row: 1; min-width: 0; max-width: 100%; flex-wrap: wrap; justify-content: flex-end; font-size: 14px; gap: 12px; }
.user > .avatar, .user > form { flex-shrink: 0; }
.user small { font-size: 13px; }
.avatar { background: var(--blue-soft); color: var(--blue-ink); border: 1px solid var(--glass-edge); width: 38px; height: 38px; box-shadow: none; }
.text-button { font-size: 14px; }
.text-button:hover { color: var(--primary); }
main { max-width: 1520px; padding: 40px 36px 48px; min-width: 0; }
.page-heading { margin-bottom: 26px; gap: 20px; }
.page-heading > div { min-width: 0; max-width: 100%; }
.page-heading h1 { overflow-wrap: anywhere; }
.page-heading > div:first-child { flex: 1; }
.page-heading > .actions { flex-shrink: 0; }
.page-heading .subtle { margin-top: 8px; line-height: 1.8; }
footer { color: var(--muted); border-color: var(--line); font-size: 13px; margin: 0 28px; padding: 18px 0 24px; }

/* Consistent controls with one primary action color. */
.button {
    min-height: 42px;
    padding: 10px 18px;
    border-radius: 6px;
    border: 1px solid var(--action-bg);
    background: var(--action-bg);
    color: var(--action-ink);
    font-size: 14px;
    font-weight: 650;
    box-shadow: none;
    transition: box-shadow .18s, background .18s, transform .18s;
}
.button:hover { color: var(--action-ink); filter: none; box-shadow: none; transform: none; background: var(--action-hover); }
.button.secondary { background: var(--surface); border-color: var(--line); color: var(--ink); box-shadow: none; }
.button.secondary:hover { background: var(--tint); color: var(--blue-ink); }
.button.danger { background: var(--rose-soft); color: var(--rose-ink); border-color: var(--line); box-shadow: none; }
.button.danger:hover { color: var(--rose-ink); background: var(--rose-soft); }
.button.small { min-height: 32px; padding: 5px 11px; font-size: 13px; border-radius: 10px; }
.button:disabled, button:disabled { opacity: .55; cursor: not-allowed; transform: none; }
:where(a, button, summary):focus-visible { outline: 3px solid var(--primary); outline-offset: 4px; }
input, select, textarea {
    min-height: 46px;
    border-radius: 6px;
    border: 1px solid var(--line);
    background: var(--field);
    color: var(--ink);
    font-size: 16px;
    padding: 12px 14px;
    box-shadow: none;
}
input::placeholder, textarea::placeholder { color: var(--muted); opacity: .9; }
input:focus, select:focus, textarea:focus { outline: 3px solid color-mix(in srgb, var(--primary) 24%, transparent); border-color: var(--primary); background: var(--surface); }
input[type="checkbox"], input[type="radio"] { accent-color: var(--primary); }
input[type="file"]::file-selector-button { padding: 6px 10px; margin-right: 10px; border: 0; border-radius: 7px; background: var(--blue-soft); color: var(--blue-ink); font: inherit; cursor: pointer; }
select option { background: var(--card); color: var(--ink); }
.filters { padding: 17px 20px; gap: 14px; border: 1px solid var(--glass-edge); border-radius: 12px; background: var(--glass); box-shadow: none; }
.filters label { flex: 1 1 160px; min-width: min(160px, 100%); max-width: 100%; }
.filters .search { flex: 2 1 260px; min-width: min(260px, 100%); }
.filters > .button, .record-search > .button { flex: 0 0 auto; min-height: 52px; height: 52px; white-space: nowrap; }
html[lang="my"] :is(.filters, .record-search, .workspace-search) > .button { white-space: nowrap; }
.filters input, .filters select { min-width: 0; max-width: 100%; height: 52px; padding-block: 8px; }
.field-grid { gap: 20px; }
.form-actions { border-color: var(--line); flex-wrap: wrap; }
.language-switch, .theme-switch { display: inline-flex; flex-shrink: 0; gap: 3px; padding: 4px; background: var(--tint); border: 1px solid var(--line); border-radius: 12px; }
.language-switch button, .theme-switch button { display: inline-flex; align-items: center; justify-content: center; gap: 5px; width: auto; margin: 0; padding: 5px 9px; min-height: 30px; border: 0; border-radius: 8px; background: transparent; color: var(--muted); font-size: 13px; line-height: 1.6; }
.language-switch button[aria-pressed="true"], .theme-switch button[aria-pressed="true"] { color: var(--blue-ink); background: var(--surface); box-shadow: none; }

/* Responsive operational summary cards. */
.metrics { gap: 18px; margin: 24px 0; }
.metric { position: relative; border-radius: 12px; padding: 23px; overflow: hidden; min-width: 0; }
.metric::before, .metric::after { display: none; }
.metric-label { padding-right: 0; font-size: 14px; font-weight: 600; margin-bottom: 20px; }
.metric-value { color: var(--ink); font-size: clamp(27px, 2.5vw, 38px); font-weight: 700; letter-spacing: -1.2px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.metric-value small { display: inline-block; white-space: nowrap; color: var(--muted); font-size: 14px; font-weight: 500; letter-spacing: 0; }
.metric.accent { background: var(--card); border-color: var(--glass-edge); }
.metric.accent .metric-value { color: var(--primary); }
a.metric { transition: transform .2s, box-shadow .2s; }
a.metric:hover { transform: none; border-color: var(--primary); box-shadow: none; }
.branch-operational-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.card { border-radius: 12px; margin-bottom: 24px; min-width: 0; }
.card-head { padding: 21px 24px; border-color: var(--line); flex-wrap: wrap; }
.card-head h2 { margin: 0; }
.card-head a { font-size: 15px; font-weight: 600; }
.card-body { padding: 24px; }
.intro-banner { border-radius: 12px; padding: 25px; background: var(--blue-soft); border-color: var(--glass-edge); }
.intro-banner p { color: var(--muted); font-size: 15px; }
.split, .two-columns { gap: 24px; min-width: 0; }
.split > *, .two-columns > * { min-width: 0; }
.home-branch-picker { display: inline-flex; gap: 5px; flex-wrap: wrap; padding: 5px; margin: 0 0 22px; border: 1px solid var(--glass-edge); border-radius: 12px; background: var(--glass); box-shadow: none; }
.home-branch-picker a { margin: 0; padding: 10px 18px; border-radius: 12px; border: 1px solid transparent; color: var(--muted); gap: 9px; background: transparent; }
.home-branch-picker strong { font-size: 14px; letter-spacing: .5px; }
.home-branch-picker a span { width: auto; white-space: normal; font-size: 14px; color: inherit; }
.home-branch-picker a:hover { background: var(--tint); color: var(--ink); }
.home-branch-picker a[aria-current="page"] { color: var(--blue-ink); background: var(--blue-soft); border-color: var(--glass-edge); box-shadow: none; }


/* Roomy outlined rows, inspired by the supplied flight-status interface. */
table { border-collapse: separate; border-spacing: 0 8px; }
.table-wrap { padding: 0 16px 8px; }
tbody td { background: var(--card); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
tbody tr:last-child td { border-bottom: 1px solid var(--line); }
tbody td:first-child { border-left: 1px solid var(--line); border-radius: 8px 0 0 8px; }
tbody td:last-child { border-right: 1px solid var(--line); border-radius: 0 8px 8px 0; }
tbody tr:hover td { background: var(--tint); }

.table-wrap { scrollbar-width: thin; scrollbar-color: #8f9dc066 transparent; }
th { padding: 14px 22px; background: transparent; color: var(--muted); font-size: 14px; font-weight: 600; letter-spacing: .3px; border-color: var(--line); }
td { padding: 22px; font-size: 16px; color: var(--ink); border-color: var(--line); }
td strong { font-weight: 650; }
td .mono, .mono { font-size: 15px; }
tbody tr { transition: background .15s; }
tbody tr:hover { background: var(--tint); }
.badge { background: var(--blue-soft); color: var(--blue-ink); padding: 5px 10px; border-radius: 9px; border: 1px solid var(--line); font-size: 13px; font-weight: 650; }
.badge[data-status="Processing"], .badge[data-status="Dispatched"], .badge[data-status="In Transit"], .badge[data-status="Arrived at Branch"] { color: var(--royal-ink); background: var(--royal-soft); }
.badge[data-status="Ready for Dispatch"], .badge[data-status="Ready for Collection"], .badge[data-status="Collected"], .badge[data-status="Delivered"] { color: var(--mint-ink); background: var(--mint-soft); }
.badge[data-status="Exception"], .badge[data-status="Cancelled"] { color: var(--rose-ink); background: var(--rose-soft); }
.branch-route-tag { display: inline-flex; align-items: center; gap: 9px; font-size: 13px; font-weight: 650; white-space: nowrap; }
.branch-route-tag > span:first-child, .branch-route-tag > span:last-child { padding: 4px 8px; border-radius: 7px; color: var(--blue-ink); background: var(--blue-soft); }
.branch-route-tag > span:last-child { background: var(--royal-soft); color: var(--royal-ink); }
.branch-route-tag > span:nth-child(2) { color: var(--muted); }
.pagination { padding: 18px 24px; font-size: 14px; align-items: center; gap: 12px; flex-wrap: wrap; }
.pagination a { background: var(--surface); border-color: var(--line); border-radius: 10px; }
.empty { font-size: 15px; color: var(--muted); }

/* Details, workflows and form feedback share the same material vocabulary. */
details { border-color: var(--line); }
summary { color: var(--ink); font-size: 15px; }
.workflow-details { border: 0; padding: 0; margin: 24px 0; }
.workflow-details > summary { padding: 12px 3px 18px; font-size: 15px; }
.workflow-details > .card { margin-top: 0; }
.queue-section { padding: 0; }
.queue-section > summary { padding: 22px 24px; font-size: 15px; }
.branch-flow { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 24px; color: var(--muted); font-size: 14px; }
.branch-flow span, .simple-flow span { padding: 8px 13px; border: 1px solid var(--glass-edge); border-radius: 12px; background: var(--glass); box-shadow: none; }
.simple-flow .current { background: var(--blue-soft); border-color: var(--line); color: var(--blue-ink); }
.notice { border-radius: 12px; font-size: 15px; }
.notice.success { background: var(--mint-soft); color: var(--mint-ink); border-color: var(--line); }
.notice.error { background: var(--rose-soft); color: var(--rose-ink); border-color: var(--line); }
.summary-list > div { border-color: var(--line); font-size: 15px; }
.summary-list .total { color: var(--primary); }
.timeline li { border-color: var(--line); }
.timeline li::before { background: var(--primary); border-color: var(--card); box-shadow: none; }
.timeline strong { font-size: 15px; }
.timeline p { color: var(--muted); font-size: 14px; }
.quote { border-radius: 12px; border-color: var(--glass-edge); background: var(--blue-soft); box-shadow: none; }
.quote strong { color: var(--blue-ink); }
pre { background: var(--tint); color: var(--ink); border: 1px solid var(--line); border-radius: 12px; font-size: 14px; }
.danger-text { color: var(--rose-ink); }
.checklist label { border-color: var(--line); }
.parcel-photo-grid img { background: var(--tint); border: 1px solid var(--glass-edge); border-radius: 12px; }
.photo-viewer { border-radius: 12px; padding: 20px; color: var(--ink); }
.photo-viewer::backdrop { background: #18233480; -webkit-backdrop-filter: none; backdrop-filter: none; }
.parcel-progress { margin: 16px 0 26px; }
.parcel-progress-label { font-size: 14px; padding: 0 5px; overflow-wrap: anywhere; color: var(--muted); }
.parcel-progress-dot { border-color: #8ba6b9; }
.parcel-progress li:not(:first-child)::before { background: var(--line); }
.parcel-progress li.is-complete::before, .parcel-progress li.is-current::before { background: var(--primary); }
.parcel-progress .is-complete .parcel-progress-dot, .parcel-progress .is-current .parcel-progress-dot { background: var(--action-bg); color: var(--action-ink); border-color: var(--action-bg); box-shadow: none; }
.parcel-progress .is-current .parcel-progress-dot { box-shadow: none; }

/* Simple two-panel sign-in. */
.login-body { padding: 36px 20px; min-height: 100svh; background: var(--bg); }
.login-shell { width: min(1040px, 96vw); padding: 10px; gap: 0; border-radius: 12px; overflow: hidden; }
.login-story { position: relative; isolation: isolate; overflow: hidden; border: 1px solid var(--glass-edge); border-radius: 12px; min-height: 620px; padding: 38px; color: var(--ink); background: var(--blue-soft); box-shadow: none; }
.login-story::after { display: none; }
.login-story .brand { align-items: center; gap: 14px; padding: 0; margin: 0 0 85px; color: var(--ink); }
.login-story .brand-logo { width: 68px; height: 68px; background: #fff; border-radius: 12px; padding: 5px; }
.login-story .brand-copy { font-size: 28px; }
.login-story .brand small { color: var(--muted); font-size: 8px; }
.login-story .eyebrow { color: var(--blue-ink); font-size: 12px; letter-spacing: 1.4px; }
.login-story h1 { color: var(--ink); font-size: 42px; line-height: 1.2; letter-spacing: -1.6px; }
.login-story p { color: var(--muted); font-size: 14px; max-width: 300px; line-height: 1.8; }
.login-story > small { color: var(--muted); font-size: 13px; margin-top: 40px; }
.login-form { padding: 35px 38px; align-self: center; color: var(--ink); }
.login-form h1 { font-size: 26px; }
.login-form label { font-size: 15px; margin: 22px 0; }
.login-form .subtle { line-height: 1.8; }
.login-form > .theme-switch, .login-form > .language-switch { display: flex; width: max-content; margin: 0 0 12px auto; }
.login-form > .language-switch { margin-bottom: 28px; }

/* Keep document surfaces suitable for receipts and manifests. */
.print-page { color-scheme: light; --ink: #24334e; --muted: #52617b; --line: #d9dfeb; --primary: #2859dc; --tint: #f1f3fa; --surface: #fff; --blue-soft: #e3ebff; --blue-ink: #344d9b; --royal-soft: #e1ebff; --royal-ink: #103fa5; color: var(--ink); border: 1px solid #fff; border-radius: 12px; background: #ffffffed; box-shadow: none; }
.print-page h1, .print-page h2, .print-page h3, .print-page td { color: var(--ink); }
.print-page .print-head { border-color: #2859dc; }
.print-page th { color: var(--muted); background: #f1f3fa; }
.print-toolbar { flex-wrap: wrap; }

@media (min-width: 1600px) {
    .sidebar { width: 240px; inset: 0 auto 0 0; padding: 26px 20px; }
    .workspace { margin-left: 240px; }
    header { margin-top: 0; }
    main { padding-top: 38px; }
    .metric { padding: 27px; }
}
@media (max-width: 1150px) and (min-width: 781px) {
    .sidebar { width: 208px; inset: 0 auto 0 0; padding: 20px 12px; }
    .sidebar .brand { gap: 8px; padding-left: 4px; padding-right: 4px; }
    .sidebar .brand-logo { width: 43px; height: 43px; }
    .sidebar .brand-copy { font-size: 21px; }
    .sidebar .brand small { font-size: 6px; }
    .sidebar nav a { padding: 10px 8px; gap: 9px; }
    .workspace { margin-left: 208px; }
    header { margin: 0; padding: 14px 18px; flex-wrap: wrap; }
    .user { flex-wrap: wrap; }
    main { padding: 28px 20px 40px; }
    .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .branch-operational-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .metric { padding: 20px 18px; }
    .metric-label { font-size: 13px; }
    .split { grid-template-columns: 1fr; }
}
@media (max-width: 780px) {
    .sidebar { position: relative; inset: auto; width: auto; margin: 0; padding: 18px; border-radius: 0; border-right: 0; border-bottom: 1px solid var(--line); overflow: visible; }
    .sidebar .brand { width: max-content; max-width: 100%; padding: 0; border: 0; margin: 0 0 14px; gap: 12px; }
    .sidebar .brand-logo { width: 44px; height: 44px; }
    .sidebar .brand-copy { font-size: 22px; }
    .sidebar .brand small { display: block; font-size: 7px; }
    .sidebar nav { display: flex; gap: 6px; }
    .sidebar nav a { min-height: 40px; margin: 0; padding: 7px 9px; font-size: 14px; gap: 7px; border-radius: 12px; }
    .sidebar nav a span { width: 24px; height: 24px; font-size: 15px; border-radius: 7px; }
    .nav-more { margin: 0; flex-basis: 100%; }
    .nav-more > summary { padding: 10px 4px 4px; }
    .nav-more[open] { display: block; }
    .nav-more a { display: inline-flex; margin: 4px 0 0 !important; }
    .workspace { margin-left: 0; }
    header { margin: 0; padding: 14px 16px; min-height: 68px; flex-wrap: wrap; border-radius: 0; gap: 12px; }
    .user { flex-wrap: wrap; gap: 8px; width: 100%; justify-content: flex-start; }
    .user > div:not(.theme-switch):not(.language-switch) { margin-left: auto; }
    main { padding: 25px 14px 36px; }
    .page-heading { flex-wrap: wrap; gap: 14px; }
    h1 { font-size: 27px; }
    .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .branch-operational-metrics { grid-template-columns: 1fr; }
    .metric { padding: 20px; border-radius: 12px; }
    .metric-value { font-size: 29px; }
    .branch-operational-metrics .metric { display: flex; align-items: center; justify-content: space-between; gap: 18px; }
    .branch-operational-metrics .metric-label { margin: 0; padding-right: 0; }
    .branch-operational-metrics .metric-value { padding-right: 22px; }
    .branch-operational-metrics .metric::before { top: 30px; right: 18px; }
    .two-columns, .field-grid, .split { grid-template-columns: 1fr; }
    .card { border-radius: 12px; }
    .card-body { padding: 20px; }
    .card-head { padding: 18px 20px; }
    .filters { padding: 16px; gap: 12px; }
    .filters label { flex: 1; min-width: 120px; }
    .filters input, .filters select { min-width: 0; }
    .filters .search { min-width: 100%; }
    .intro-banner { flex-wrap: wrap; padding: 22px; }
    .home-branch-picker { display: flex; }
    .home-branch-picker a { flex: 1; justify-content: center; padding: 10px; gap: 6px; }
    .home-branch-picker a span { font-size: 13px; }
    td { padding: 16px 18px; }
    th { padding: 13px 18px; }
    footer { margin: 0 16px; }
    .login-body { padding: 16px 10px; }
    .login-shell { width: min(480px, 100%); grid-template-columns: 1fr; padding: 8px; border-radius: 12px; }
    .login-story { min-height: auto; padding: 26px; border-radius: 12px; }
    .login-story .brand { margin-bottom: 28px; }
    .login-story .brand-logo { width: 52px; height: 52px; }
    .login-story .brand-copy { font-size: 24px; }
    .login-story h1 { font-size: 30px; }
    .login-form { padding: 28px 22px; }
    .login-form > .theme-switch, .login-form > .language-switch { display: inline-flex; margin: 0 8px 22px 0; }
    .print-page { margin: 12px; padding: 20px; }
    .photo-viewer-toolbar { gap: 7px; }
}
@media (max-width: 400px) {
    .user .theme-switch button, .user .language-switch button { font-size: 12px; padding: 5px 7px; }
    .user > div:not(.theme-switch):not(.language-switch) { margin-left: 0; }
    .metrics { grid-template-columns: 1fr; }
    .home-branch-picker a span { display: none; }
    .page-heading .actions { width: 100%; }
    .page-heading .actions .button { white-space: normal; }
}
@media screen {
    html[lang="my"] h1 { font-size: 30px; line-height: 1.65; }
    html[lang="my"] .sidebar nav a { font-size: 15px; align-items: center; }
    html[lang="my"] .sidebar .brand small { font-size: 9px; }
    html[lang="my"] :is(label, td, .subtle, .metric-label) { font-size: 15px; }
    html[lang="my"] :is(.help, th, .metric-foot) { font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
    .button:hover, a.metric:hover { transform: none; }
}
@media (prefers-reduced-transparency: reduce) {
    .sidebar, header, .card, .metric, .intro-banner, .login-shell, .photo-viewer, .filters { background: var(--card); -webkit-backdrop-filter: none; backdrop-filter: none; }
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
    .sidebar, header, .card, .metric, .intro-banner, .login-shell, .photo-viewer { background: var(--card); }
}
/* Searches stay outside business forms and preserve the current filters. */
.workspace-search { grid-column: 1 / -1; grid-row: 2; display: flex; align-items: stretch; gap: 8px; min-width: 0; width: 100%; margin: 0; }
.workspace-search input { flex: 1 1 0; width: 0; min-width: 0; min-height: 52px; height: 52px; padding-block: 8px; margin: 0; font-size: 16px; color: var(--ink); background: var(--field); }
.workspace-search .button { flex: 0 0 auto; min-width: 76px; min-height: 52px; padding: 8px 16px; white-space: nowrap; }
.record-search { display:flex; flex-wrap:wrap; align-items:end; gap:12px; padding:18px 24px; border-bottom:1px solid var(--line); }
.record-search label { flex: 1 1 220px; min-width: min(180px, 100%); max-width: 100%; }
.record-search input { min-width: 0; height: 52px; padding-block: 8px; }
.record-search output { flex-basis:100%; color:var(--muted); font-size:14px; }
.record-search output:empty { display:none; }
[data-table-search] tr[hidden] { display:none; }
@media (min-width: 1600px) {
    header { grid-template-columns: minmax(140px, 1fr) minmax(240px, 330px) auto; }
    .workspace-search { grid-column: 2; grid-row: 1; }
    header .user { grid-column: 3; }
}
@media (max-width: 1000px) {
    header { grid-template-columns: minmax(0, 1fr); }
    header .user { grid-column: 1; grid-row: 2; justify-content: flex-start; }
    .workspace-search { grid-row: 3; }
}
@media (max-width: 780px) {
    .record-search { padding: 16px; }
}
/* Install controls use the same clear surfaces as the workspace. */
.pwa-actions { margin:0 0 16px; }
.pwa-actions [hidden], [data-pwa-offline][hidden] { display:none !important; }
.pwa-help { width:min(500px,calc(100vw - 32px)); max-height:85vh; overflow:auto; padding:28px; border:1px solid var(--line); border-radius:12px; background:var(--card); color:var(--ink); }
.pwa-help::backdrop { background:#18233480; }
.pwa-help p { font-size:16px; }
.pwa-offline { position:fixed; bottom:16px; left:50%; transform:translateX(-50%); width:min(600px,calc(100vw - 32px)); z-index:20; margin:0; box-shadow:0 4px 18px #18233420; }
@media(max-width:780px) { .sidebar-bottom:has(.pwa-actions) { display:block; margin-top:16px; border-top:0; padding:0; } .sidebar-bottom:has(.pwa-actions) > .live-dot, .sidebar-bottom:has(.pwa-actions) > small { display:none; } .sidebar-bottom:has(.pwa-actions) { font-size:0; } .sidebar-bottom .pwa-actions { margin:0; } .login-form .pwa-actions button { width:auto; } }
@media print { .pwa-actions, .pwa-offline, .pwa-help { display:none !important; } }
@media print { header, .workspace-search, .record-search { display:none !important; } }
@media print {
    :root, html[data-theme="dark"] { color-scheme: light; --ink: #000; --muted: #444; --line: #ccc; }
    body { background: #fff !important; color: #000 !important; }
    body::before, body::after { display: none; }
    .workspace { margin: 0; }
    main { padding: 0; }
    .print-page { margin: 0; max-width: none; padding: 0; border: 0; border-radius: 0; box-shadow: none; background: #fff; }
    .card, .metric { background: #fff; box-shadow: none; -webkit-backdrop-filter: none; backdrop-filter: none; border: 1px solid #ccc; }
    .print-page h1, .print-page h2, .print-page h3, .print-page td { color: #000; }
    .print-page table { border-collapse: collapse; border-spacing: 0; }
    .print-page td, .print-page th { font-size: 11px; }
    .print-page .table-wrap { padding: 0; }
    .print-page th { background: #f3f3f3; color: #333; }
}

/* A compact mobile workspace, shared by browser and installed PWA. */
.mobile-bar, .mobile-nav { display: none; }
.mobile-menu { color: var(--ink); background: var(--card); border: 1px solid var(--line); }
.mobile-menu:not([open]) { display: none; }
@media screen and (max-width: 780px) {
    html { scroll-padding-top: 90px; -webkit-text-size-adjust: 100%; }
    body { min-height: 100vh; min-height: 100dvh; }
    body:has(.mobile-menu[open]) { overflow: hidden; }
    .sidebar { display: none; }
    .workspace { margin-left: 0; padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
    .workspace > header { position: sticky; top: 0; z-index: 25; display: block; min-height: 0; padding: env(safe-area-inset-top, 0px) max(16px, env(safe-area-inset-right, 0px)) 0 max(16px, env(safe-area-inset-left, 0px)); background: var(--card); color: var(--ink); border-bottom: 1px solid var(--line); }
    header > .breadcrumbs, header > .user { display: none; }
    .mobile-bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 68px; }
    .mobile-brand { display: inline-flex; align-items: center; gap: 9px; color: var(--ink); font-size: 21px; font-weight: 750; line-height: 1.2; }
    .mobile-brand img { object-fit: contain; background: #fff; border-radius: 8px; }
    .mobile-brand small { display: block; font-size: 9px; font-weight: 600; letter-spacing: 1.5px; color: var(--muted); margin-top: 4px; }
    .mobile-search-toggle { display: grid; place-items: center; min-width: 44px; min-height: 44px; padding: 8px; border: 1px solid var(--line); border-radius: 12px; background: var(--field); color: var(--ink); }
    header .workspace-search { display: none; }
    header[data-search-open] .workspace-search { display: flex; padding: 0 0 12px; }
    header .workspace-search :is(input, .button) { min-height: 46px; height: 46px; }
    .mobile-nav { position: fixed; z-index: 30; bottom: 0; left: 0; right: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 2px; padding: 7px max(8px, env(safe-area-inset-right, 0px)) calc(7px + env(safe-area-inset-bottom, 0px)) max(8px, env(safe-area-inset-left, 0px)); border-top: 1px solid var(--line); background: var(--card); box-shadow: 0 -3px 16px #18233408; }
    .mobile-nav > :is(a, button) { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-width: 0; min-height: 50px; padding: 4px 1px; margin: 0; border: 0; border-radius: 10px; background: transparent; color: var(--muted); font-size: 11px; font-weight: 650; line-height: 1.5; text-align: center; overflow-wrap: anywhere; }
    .mobile-nav > :is(a, button) > span { width: auto; }
    .mobile-nav > :is(a, button) > span:first-child { font-size: 23px; line-height: 1; height: 25px; }
    .mobile-nav > a[aria-current="page"], .mobile-nav > button:focus-visible { color: var(--blue-ink); background: var(--blue-soft); }
    .mobile-menu[open] { position: fixed; inset: auto 0 0; margin: 0 auto; width: 100%; max-width: 520px; max-height: calc(100vh - 24px); max-height: calc(100dvh - env(safe-area-inset-top, 0px) - 16px); padding: 18px 20px calc(20px + env(safe-area-inset-bottom, 0px)); border-radius: 22px 22px 0 0; overflow-y: auto; overscroll-behavior: contain; }
    .mobile-menu::backdrop { background: #151610b3; }
    .mobile-menu-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; }
    .mobile-menu-heading h2 { margin: 0; font-size: 22px; }
    .mobile-menu-heading .button { min-width: 44px; min-height: 44px; padding: 0; font-size: 28px; }
    .mobile-account { padding: 0 0 16px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
    .mobile-account small { display: block; color: var(--muted); margin-top: 3px; }
    .mobile-menu-links { display: grid; padding: 10px 0; }
    .mobile-menu-links a { display: flex; align-items: center; gap: 12px; min-height: 50px; padding: 10px 8px; border-radius: 10px; color: var(--ink); font-weight: 600; }
    .mobile-menu-links a span:first-child { color: var(--primary); font-size: 21px; width: 25px; text-align: center; }
    .mobile-menu-links a span:last-child { margin-left: auto; }
    .mobile-menu-links a[aria-current="page"] { background: var(--blue-soft); color: var(--blue-ink); }
    .mobile-preferences { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding: 16px 0; border-top: 1px solid var(--line); }
    .mobile-preferences :is(.theme-switch, .language-switch) { margin: 0; max-width: 100%; }
    .mobile-preferences button { min-height: 44px; padding: 8px 12px; }
    .mobile-menu .pwa-actions { margin: 0; }
    .mobile-menu .pwa-actions:has(button:not([hidden])) { margin-bottom: 12px; }
    .mobile-menu .pwa-actions button, .mobile-logout { width: 100%; min-height: 46px; }
    main { padding: 22px max(16px, env(safe-area-inset-right, 0px)) 24px max(16px, env(safe-area-inset-left, 0px)); }
    .page-heading { display: flex; flex-direction: column; align-items: stretch; gap: 12px; margin-bottom: 18px; }
    .page-heading h1 { font-size: 26px; line-height: 1.3; margin-bottom: 0; }
    .page-heading .subtle { font-size: 14px; line-height: 1.65; margin-top: 6px; }
    .branch-timezone { display: none; }
    .page-heading > :is(a, .actions) { align-self: stretch; width: 100%; }
    .page-heading > a { text-align: center; justify-content: center; }
    .page-heading .actions { display: flex; flex-wrap: wrap; gap: 8px; }
    .page-heading .actions > * { flex: 1 1 auto; }
    .home-branch-picker { margin-bottom: 16px; }
    .home-branch-picker a { min-height: 48px; }
    .home-branch-picker a span { display: none; }
    .home-branch-picker a strong { font-size: 16px; }
    :is(input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]), select, textarea) { font-size: 16px; min-width: 0; max-width: 100%; min-height: 48px; }
    :is(.field-grid, .split, .two-columns) > *, label { min-width: 0; }
    .field-grid { gap: 16px; }
    .field-grid .full { grid-column: 1 / -1; }
    .button, .text-button { min-height: 44px; }
    .form-actions { display: flex; flex-wrap: wrap; gap: 10px; }
    .form-actions > .button { flex: 1 1 140px; min-height: 48px; text-align: center; justify-content: center; }
    .card-head { gap: 10px; padding: 16px; flex-wrap: wrap; }
    .card-body { padding: 16px; }
    .card-head h2 { font-size: 17px; }
    .filters { gap: 10px; padding: 14px; }
    .filters label { min-width: 0; flex: 1 1 160px; }
    .filters .search { flex-basis: 100%; }
    .filters .button { flex: 1 1 100%; }
    .table-wrap { max-width: 100%; overflow-x: auto; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; }
    .branch-operational-metrics .metric { padding: 16px; min-height: 74px; }
    .branch-operational-metrics .metric-value { font-size: 26px; }
    .branch-operational-metrics .metric::before { top: 25px; }
    .pwa-offline { bottom: calc(78px + env(safe-area-inset-bottom, 0px)); z-index: 35; }
    .pwa-help { max-height: calc(100dvh - 40px); padding: 22px; }
    .login-body { padding-top: max(12px, env(safe-area-inset-top, 0px)); padding-bottom: max(12px, env(safe-area-inset-bottom, 0px)); }
    .login-story { padding: 20px; }
    .login-story .brand { margin-bottom: 0; }
    .login-story :is(h1, .eyebrow, p), .login-story > div:last-child:not(:first-child) { display: none; }
    .login-form { padding: 22px 18px; }
    .login-form h1 { font-size: 25px; }
    html[lang="my"] .page-heading h1 { font-size: 24px; line-height: 1.6; }
    html[lang="my"] .mobile-nav > :is(a, button) { font-size: 10px; align-items: center; }
}
@media print { .mobile-bar, .mobile-nav, .mobile-menu { display: none !important; } }

/* Immediate touch feedback without the browser's persistent tap overlay. */
:is(a, button, summary, input[type="submit"], input[type="button"]) { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
html[data-navigation-pending] { cursor: progress; }
html[data-navigation-pending]::after { content: ""; position: fixed; z-index: 9999; inset: 0 0 auto; height: 3px; background: var(--primary); pointer-events: none; }
[data-navigation-busy] { opacity: .7; cursor: progress; }
@media (hover: none) {
    .button, .sidebar nav a, a.metric, tbody tr { transition: none; }
    .mobile-nav > :is(a, button):active, .mobile-menu-links a:active { background: var(--blue-soft); color: var(--blue-ink); }
    .button:active { opacity: .8; }
}

/* Reference-inspired courier layout with the blue brand palette. */
@media screen {
    body { font-size: 14px; }
    h1 { letter-spacing: -1.1px; }
    h2 { font-size: 17px; letter-spacing: -.35px; }
    .sidebar { background: var(--bg); padding-top: 18px; }
    .sidebar .brand { border-bottom: 0; margin-bottom: 18px; }
    .sidebar .brand-copy { font-size: 21px; }
    .sidebar nav a { font-size: 13px; min-height: 44px; border-radius: 9px; font-weight: 500; }
    .sidebar nav a span { color: var(--muted); }
    .sidebar nav a.active { background: var(--blue-soft); color: var(--blue-ink); border-color: var(--line); }
    .sidebar nav a.active span { color: var(--blue-ink); }
    .sidebar .nav-caption { font-size: 10px; letter-spacing: 1.8px; }
    .sidebar-bottom { font-size: 11px; }
    header { padding-block: 14px; gap: 14px; }
    .user { font-size: 12px; }
    .user small { font-size: 11px; }
    .breadcrumbs { font-size: 12px; }
    .workspace-search input { background: var(--card); }
    .workspace-search :is(input, .button) { min-height: 42px; height: 42px; font-size: 13px; }
    .workspace-search .button { min-width: 64px; }
    main { padding-top: 28px; }
    .card, .metric { border-radius: 12px; }
    .card-head { padding: 18px 20px; }
    .card-body { padding: 20px; }
    .card-head a { font-size: 12px; }
    .button { border-radius: 8px; font-size: 13px; }
    .button.small { border-radius: 7px; }
    .subtle, label, .metric-label { font-size: 14px; }
    .help, .metric-foot, td small, .timeline small { font-size: 12px; }
    table { border-spacing: 0; }
    .table-wrap { padding: 0 18px 12px; }
    th { font-size: 11px; letter-spacing: .5px; text-transform: uppercase; padding: 12px 10px; }
    td { padding: 15px 10px; font-size: 13px; }
    td .mono, .mono { font-size: 12px; }
    tbody td { border-top: 0; border-bottom: 1px solid var(--line); }
    tbody td:first-child, tbody td:last-child { border-left: 0; border-right: 0; border-radius: 0; }
    .badge { padding: 4px 7px; border-radius: 5px; font-size: 11px; line-height: 1.5; }
    .branch-route-tag { gap: 5px; font-size: 11px; }
    .dashboard-heading { align-items: center; margin-bottom: 20px; }
    .dashboard-heading h1 { font-size: 29px; margin-top: 3px; }
    .dashboard-heading .eyebrow { font-size: 9px; letter-spacing: 2px; color: var(--muted); }
    .dashboard-heading .subtle { font-size: 12px; margin-top: 3px; }
    .dashboard-heading .home-branch-picker { margin: 0; flex-shrink: 0; background: var(--card); }
    .dashboard-heading .home-branch-picker a { padding: 8px 12px; border-radius: 7px; }
    .dashboard-heading .home-branch-picker a span { font-size: 12px; }
    .courier-hero { position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: center; justify-content: space-between; gap: 24px; min-height: 330px; padding: 36px; border-radius: 14px; background: #544b3d url('../images/courier-conveyor.webp') center 55% / cover; color: #fff; }
    .courier-hero::before { content: ''; position: absolute; z-index: -1; inset: 0; background: linear-gradient(90deg, rgba(28,28,23,.8), rgba(28,28,23,.25) 60%, rgba(28,28,23,.18)); }
    .courier-hero-copy { max-width: 480px; }
    .hero-kicker { display: block; font-size: 10px; text-transform: uppercase; letter-spacing: 1.6px; color: #e0dbcb; margin-bottom: 18px; }
    .hero-kicker > span { padding: 0 6px; }
    .courier-hero h2 { color: #fff; font-weight: 600; font-size: clamp(34px, 4vw, 56px); letter-spacing: -2px; line-height: 1.08; margin: 0 0 14px; }
    .courier-hero p { font-size: 13px; color: #e6e1d5; margin: 0 0 24px; }
    .hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }
    .hero-actions .button { background: var(--action-bg); border-color: var(--action-bg); color: var(--action-ink); font-size: 12px; min-height: 42px; }
    .hero-actions .button:hover { background: var(--action-hover); border-color: var(--action-hover); color: var(--action-ink); }
    .hero-actions .button.secondary { color: #fff; background: #24251fa8; border-color: #ffffff55; backdrop-filter: blur(10px); }
    .hero-actions .button.secondary:hover { background: #24251f; }
    .hero-summary { width: 225px; align-self: flex-end; flex-shrink: 0; padding: 20px; border: 1px solid #ffffff26; border-radius: 12px; color: #f4f2e9; background: #24251de0; backdrop-filter: blur(12px); box-shadow: 0 8px 24px #00000020; }
    .hero-summary-heading { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 12px; }
    .hero-box-icon { width: 32px; height: 32px; display: grid; place-items: center; background: #ffffff0e; border: 1px solid #ffffff20; border-radius: 8px; font-size: 20px; }
    .hero-summary > strong { display: block; font-size: 40px; font-weight: 550; letter-spacing: -1.5px; margin: 6px 0; font-variant-numeric: tabular-nums; }
    .hero-summary > strong small { font-size: 12px; letter-spacing: 0; font-weight: 400; color: #c8c8b8; }
    .hero-summary-footer { font-size: 10px; color: #c8c8b8; display: flex; align-items: center; gap: 7px; }
    .hero-summary .live-dot { background: #b2d19e; }
    .dashboard-queues { margin: 18px 0 24px; gap: 14px; }
    .dashboard-queues .metric { display: flex; align-items: center; gap: 14px; padding: 20px; }
    .dashboard-queues .metric-label { margin: 0 0 2px; font-size: 12px; }
    .dashboard-queues .metric-value { font-size: 28px; line-height: 1.2; letter-spacing: -.7px; }
    .queue-icon { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 10px; flex-shrink: 0; background: var(--blue-soft); color: var(--blue-ink); font-size: 24px; }
    .queue-incoming .queue-icon { background: var(--amber-soft); color: var(--amber-ink); }
    .queue-stored .queue-icon { background: var(--royal-soft); color: var(--royal-ink); }
    .queue-arrow { margin-left: auto; font-size: 17px; color: var(--muted); }
    .dashboard-grid { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 20px; align-items: start; }
    .dashboard-grid > * { min-width: 0; }
    .dashboard-recent .card-head { align-items: center; gap: 12px; }
    .dashboard-recent .card-head > div { flex: 1; }
    .dashboard-recent .card-head .help { margin: 5px 0 0; font-size: 11px; }
    .dashboard-recent .table-wrap { overflow-x: auto; }
    .dashboard-recent table { width: 100%; table-layout: fixed; }
    .dashboard-recent th:first-child { width: 29%; }
    .dashboard-recent th:nth-child(2) { width: 25%; }
    .dashboard-recent th:nth-child(3) { width: 22%; }
    .dashboard-recent th:nth-child(4) { width: 20%; }
    .dashboard-recent th:last-child { width: 4%; }
    .dashboard-recent :is(td, th) { white-space: normal; overflow-wrap: anywhere; }
    .dashboard-recent td:last-child { padding-inline: 0; }
    .dashboard-recent th { font-size: 9px; }
    .dashboard-recent td { font-size: 12px; padding-block: 18px; }
    .dashboard-recent td .mono { font-size: 11px; }
    .dashboard-recent td small { font-size: 10px; }
    .dashboard-recent .badge { max-width: 120px; white-space: normal; }
    .dashboard-aside .card { margin-bottom: 20px; }
    .dashboard-aside .card-head h2 { font-size: 15px; }
    .branch-chip { font-size: 10px; color: var(--muted); border: 1px solid var(--line); background: var(--tint); padding: 3px 7px; border-radius: 5px; }
    .workload-row { display: grid; grid-template-columns: 1fr auto; gap: 9px; padding-bottom: 20px; font-size: 12px; color: var(--muted); }
    .workload-row:last-of-type { padding-bottom: 0; }
    .workload-row strong { color: var(--ink); font-size: 13px; font-weight: 550; }
    .workload-track { grid-column: 1 / -1; height: 5px; overflow: hidden; border-radius: 4px; background: var(--tint); }
    .workload-track > span { display: block; height: 100%; background: #7c9dc5; border-radius: inherit; }
    .queue-incoming .workload-track > span { background: #c8b57c; }
    .queue-stored .workload-track > span { background: #a79c85; }
    .money-label { color: var(--muted); font-size: 12px; }
    .money-total { font-size: 29px; font-weight: 550; letter-spacing: -1px; color: var(--ink); margin: 4px 0 18px; overflow-wrap: anywhere; }
    .money-total small { font-size: 11px; color: var(--muted); letter-spacing: 0; padding-left: 6px; }
    .money-outstanding { padding: 14px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: 11px; color: var(--muted); }
    .money-outstanding strong { display: block; color: var(--ink); margin-top: 3px; font-size: 14px; font-weight: 550; }
    .money-filters { display: flex; align-items: end; gap: 10px; margin-top: 16px; }
    .money-filters label { min-width: 0; flex: 1; font-size: 11px; }
    .money-filters select { height: 36px; min-height: 36px; padding: 5px 9px; margin-top: 4px; font-size: 12px; }
    .money-filters .button { min-height: 36px; font-size: 10px; }
    .money-link { display: flex; align-items: center; justify-content: space-between; font-size: 11px; margin-top: 16px; }
    html[lang="my"] .courier-hero h2 { font-size: clamp(26px, 3vw, 40px); line-height: 1.6; letter-spacing: -.5px; }
    html[lang="my"] .hero-kicker { line-height: 1.8; }
    .login-story { background: var(--tint); }
}
@media screen and (min-width: 1250px) {
    header { grid-template-columns: minmax(200px, 1fr) auto; }
    header .breadcrumbs { display: none; }
    header .workspace-search { grid-row: 1; grid-column: 1; max-width: 420px; }
    header .user { grid-row: 1; grid-column: 2; }
}
@media screen and (min-width: 781px) and (max-width: 1249px) {
    .dashboard-grid { grid-template-columns: minmax(0, 1fr); }
    .dashboard-aside { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
    .courier-hero { padding: 28px; }
    .hero-summary { width: 180px; }
    .dashboard-queues .metric { padding: 16px 12px; gap: 10px; }
    .dashboard-queues .queue-icon { width: 36px; height: 36px; }
    .dashboard-queues .queue-arrow { display: none; }
}
@media screen and (max-width: 780px) {
    .dashboard-heading { align-items: stretch; gap: 10px; margin-bottom: 16px; }
    .dashboard-heading > div:first-child { flex: none; width: 100%; }
    .dashboard-heading h1 { font-size: 26px; margin: 3px 0 0; }
    .dashboard-heading .subtle { margin: 4px 0 0; }
    .dashboard-heading .home-branch-picker { align-self: flex-start; }
    .courier-hero { min-height: 360px; padding: 24px; flex-direction: column; align-items: flex-start; justify-content: flex-start; background-position: 60% center; gap: 24px; }
    .courier-hero::before { background: linear-gradient(90deg, #1c1c17d9, #1c1c1755); }
    .courier-hero h2 { font-size: 38px; }
    .hero-kicker { font-size: 9px; margin-bottom: 14px; }
    .courier-hero p { max-width: 230px; font-size: 12px; }
    .hero-actions .button { font-size: 11px; padding: 9px 12px; }
    .hero-summary { align-self: stretch; width: auto; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 16px; }
    .hero-summary-heading { font-size: 11px; }
    .hero-box-icon { display: none; }
    .hero-summary > strong { font-size: 28px; margin: 0; }
    .hero-summary-footer { flex-basis: 100%; font-size: 9px; }
    .dashboard-queues { grid-template-columns: 1fr; gap: 9px; margin: 14px 0 20px; }
    .dashboard-queues .metric { min-height: 72px; padding: 14px; }
    .dashboard-queues .metric > div { display: flex; flex: 1; align-items: center; justify-content: space-between; gap: 12px; }
    .dashboard-queues .metric-label { font-size: 12px; margin: 0; }
    .dashboard-queues .metric-value { font-size: 24px; padding: 0; }
    .dashboard-queues .queue-icon { width: 34px; height: 34px; font-size: 20px; }
    .dashboard-grid { display: flex; flex-direction: column; gap: 0; }
    .dashboard-grid > * { width: 100%; }
    .dashboard-recent .card-head { padding: 16px; }
    .dashboard-recent .card-head .help { display: none; }
    .dashboard-recent .card-head .button { font-size: 10px; }
    .dashboard-recent .table-wrap { padding-inline: 10px; }
    .dashboard-recent table { min-width: 540px; }
    .money-filters .button { min-height: 48px; }
    .dashboard-heading .home-branch-picker a { min-height: 44px; }
    html[lang="my"] .courier-hero h2 { font-size: 29px; }
}
