:root { color-scheme: light; --ink: #17212b; --muted: #626f7d; --line: #dce2e8; --blue: #1479f6; --green: #187454; --red: #ad3b3b; }
* { box-sizing: border-box; }
html { height: 100%; }
body { margin: 0; height: 100dvh; display: flex; flex-direction: column; background: #f5f7fb; color: var(--ink); font: 15px/1.5 system-ui, sans-serif; letter-spacing: 0; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
button, .button { cursor: pointer; }
.app-header { flex: 0 0 64px; display: flex; align-items: center; justify-content: space-between; padding: 0 max(18px, calc((100% - 920px)/2)); background: #fff; border-bottom: 1px solid var(--line); gap: 16px; z-index: 2; }
.brand { display: flex; align-items: center; gap: 9px; font-size: 21px; font-weight: 750; }
.brand svg { color: var(--blue); width: 28px; height: 28px; }
.header-tools { display: flex; align-items: center; gap: 10px; }
.notification-bell { position: relative; border: 0; background: transparent; }
.notification-badge { position: absolute; right: 0; top: 0; min-width: 20px; height: 20px; border-radius: 10px; background: var(--red); color: white; font-size: 10px; text-align: center; padding: 2px; }
.notification-filters { display: flex; gap: 22px; border-bottom: 1px solid var(--line); }
.notification-filters a { padding: 12px 0; }
.notification-filters [aria-current] { border-bottom: 2px solid var(--blue); font-weight: 700; }
.notification-row { padding: 18px 0; border-bottom: 1px solid var(--line); }
.notification-row.is-unread h2::before { content: ''; display: inline-block; width: 7px; height: 7px; background: var(--blue); border-radius: 50%; margin-right: 8px; }
.environment { background: #fcf0cc; color: #75520d; font-size: 11px; font-weight: 650; padding: 3px 8px; border-radius: 4px; }
.section-heading { flex: 0 0 43px; background: #fff; border-bottom: 1px solid var(--line); padding: 10px max(18px, calc((100% - 920px)/2)); font-size: 13px; font-weight: 650; }
main { flex: 1 1 auto; min-height: 0; width: 100%; overflow-y: auto; overflow-x: hidden; padding: 25px max(18px, calc((100% - 920px)/2)) 35px; outline: none; }
main > * { min-width: 0; }
h1, h2, p { margin: 0; overflow-wrap: anywhere; }
h1 { font-size: 26px; line-height: 1.3; font-weight: 720; }
h2 { font-size: 17px; line-height: 1.4; font-weight: 680; }
.eyebrow { font-size: 10px; font-weight: 700; color: var(--muted); margin-bottom: 6px; }
.page-title { display: flex; align-items: center; justify-content: space-between; margin: 0 0 24px; gap: 16px; }
.page-title > svg { width: 26px; height: 26px; color: var(--muted); }
svg { flex-shrink: 0; width: 20px; height: 20px; vertical-align: middle; }
.bottom-nav { flex: 0 0 auto; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); padding: 10px max(6px, calc((100% - 920px)/2)) max(9px, env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--line); min-height: 72px; z-index: 2; }
.bottom-nav a { display: flex; flex-direction: column; align-items: center; gap: 4px; color: var(--muted); font-size: 11px; min-height: 45px; justify-content: center; }
.bottom-nav svg { width: 22px; height: 22px; }
.bottom-nav a[aria-current] { color: #1168d4; font-weight: 700; }
.link-list { background: #fff; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.link-list a { display: flex; gap: 14px; align-items: center; padding: 20px 4px; min-height: 64px; }
.link-list a + a { border-top: 1px solid var(--line); }
.link-list span { flex: 1; font-weight: 600; }
.link-list svg:first-child { color: var(--green); }
.link-list svg:last-child { color: var(--muted); width: 16px; }
.login-panel { max-width: 370px; margin: 45px auto; }
.login-panel h1 { margin-bottom: 26px; }
label { display: block; font-size: 13px; font-weight: 600; margin: 17px 0 7px; }
input, select { display: block; width: 100%; min-width: 0; min-height: 46px; padding: 10px 12px; border: 1px solid #bac5d0; border-radius: 5px; background: #fff; color: var(--ink); font-size: 16px; }
button, .button { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 45px; border: 1px solid transparent; border-radius: 5px; padding: 10px 17px; font-weight: 650; max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
.primary { background: var(--blue); color: #fff; width: 100%; margin-top: 25px; }
.secondary { background: #fff; color: var(--ink); border-color: var(--line); }
.search-row { display: flex; gap: 8px; }
.icon-button { background: #fff; border-color: #bac5d0; flex: 0 0 46px; padding: 10px; }
.filters { margin-bottom: 22px; display: grid; grid-template-columns: 1fr 135px auto; gap: 7px 10px; align-items: end; }
.filters label { margin: 0; }
.filters label:first-child { grid-column: 1; grid-row: 1; }
.filters .search-row { grid-column: 1; grid-row: 2; }
.filters label[for=status] { grid-column: 2; grid-row: 1; }
.filters select { grid-column: 2; grid-row: 2; }
.filter-button { grid-column: 3; grid-row: 2; background: #e9eef4; color: #34465a; }
.bus-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.bus-card { background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 18px; min-width: 0; }
.bus-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.status { font-size: 10px; font-weight: 650; border-radius: 4px; padding: 4px 7px; white-space: nowrap; }
.active { color: var(--green); background: #e6f3eb; }
.inactive { color: var(--red); background: #fbeceb; }
.route { display: flex; align-items: center; gap: 8px; font-size: 13px; }
.route svg { width: 15px; height: 15px; color: var(--muted); }
.bus-meta { color: var(--muted); font-size: 12px; margin-top: 8px; }
.pagination { display: flex; justify-content: center; align-items: center; gap: 18px; margin-top: 24px; font-size: 13px; }
.pagination a { display: inline-flex; align-items: center; min-height: 44px; gap: 4px; color: #1168d4; }
.pagination svg { width: 16px; }
.empty-state { text-align: center; padding: 55px 15px; color: var(--muted); grid-column: 1/-1; }
.empty-state > svg { width: 32px; height: 32px; margin-bottom: 14px; color: #8896a5; }
.empty-state h1, .empty-state h2 { color: var(--ink); font-size: 20px; margin-bottom: 10px; }
.empty-state .button { margin-top: 16px; }
.account-details { padding: 20px 0; border-top: 1px solid var(--line); margin-bottom: 20px; }
.account-details p { color: var(--muted); margin-top: 5px; }
.alert { padding: 12px; border-left: 3px solid var(--red); background: #fbeceb; border-radius: 3px; margin: 18px 0; font-size: 13px; color: #872c2c; }
.notice { padding: 12px; border-left: 3px solid var(--green); background: #e6f3eb; margin-bottom: 18px; }
.section-tabs { display: flex; gap: 26px; }
.section-tabs a { min-height: 24px; }
.edit-form { max-width: 600px; }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 20px 0; }
.form-actions .primary { width: auto; margin-top: 0; }
.register-row, .history { padding: 20px 0; border-bottom: 1px solid var(--line); }
.register-row p, .history p { margin-top: 8px; }
.history h2 { margin-bottom: 12px; }
.record-link { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; margin-top: 8px; color: #1168d4; font-size: 13px; }
.amounts { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 8px; font-size: 14px; }
.amounts dd { margin: 0; font-variant-numeric: tabular-nums; }
.check-label { display: flex; align-items: center; gap: 10px; min-height: 44px; margin: 5px 0; font-weight: 500; }
.check-label input { width: 21px; min-height: 21px; height: 21px; margin: 0; flex: 0 0 21px; }
.schedule-day { border-bottom: 1px solid var(--line); padding: 12px 0; }
.schedule-day summary { cursor: pointer; min-height: 40px; padding: 8px 0; font-weight: 650; }
.schedule-day fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
.schedule-day legend { font-size: 13px; font-weight: 650; padding: 12px 0; }
.weekday-options { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 2px 12px; }
.field-label { font-size: 13px; font-weight: 650; margin-top: 12px; }
[hidden] { display: none !important; }
.mode-picker { border: 0; padding: 0; margin: 20px 0; display: flex; flex-wrap: wrap; gap: 20px; }
.mode-picker legend { font-size: 13px; font-weight: 650; }
.cashing-bus { border: 1px solid var(--line); border-radius: 6px; background: #fff; padding: 18px; margin: 20px 0; min-width: 0; }
.segmented { display: flex; padding: 0; border: 1px solid var(--line); border-radius: 6px; margin: 0 0 20px; overflow: hidden; }
.segmented label { flex: 1; text-align: center; padding: 12px 8px; margin: 0; cursor: pointer; }
.segmented label:has(input:checked) { background: #e5f0ff; color: #1168d4; font-weight: 650; }
.segmented input { width: auto; margin-right: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.menu-pending { display: flex; align-items: center; gap: 12px; padding: 18px 0; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; color: var(--muted); width: 100%; text-align: left; }
.menu-pending span { flex: 1; }
.menu-pending svg { width: 20px; height: 20px; }
.salary-preview { margin: 20px 0; border-bottom: 1px solid var(--line); padding-bottom: 16px; }
.salary-preview dl { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 10px; }
.salary-preview dd { margin: 0; font-variant-numeric: tabular-nums; }
.cashing-bus legend { font-weight: 700; }
.metrics { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 10px; margin-bottom: 10px; }
.metrics.two { grid-template-columns: repeat(2,minmax(0,1fr)); }
.metric { border: 1px solid var(--line); border-radius: 6px; background: #fff; padding: 14px 12px; min-width: 0; }
.metric-label { font-size: 12px; color: var(--muted); min-height: 36px; line-height: 1.35; }
.metric-value { font-size: 22px; font-weight: 720; font-variant-numeric: tabular-nums; white-space: nowrap; }
.quick-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 20px 0; }
.fleet-counts { padding: 12px 0; font-size: 13px; }
.fleet-counts span { margin: 0 9px; color: var(--muted); }
.period-picker { padding: 15px 0 20px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.period-picker .mode-picker { margin: 0 0 14px; gap: 16px; }
.period-picker .secondary { margin-top: 14px; }
.date-pair { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.chart-band { padding: 24px 0; border-bottom: 1px solid var(--line); }
.chart-band h2 { margin-bottom: 20px; }
.chart-frame { position: relative; height: 310px; width: 100%; }
.table-scroll { overflow-x: auto; margin: 20px 0; }
table { border-collapse: collapse; width: 100%; font-size: 13px; }
caption { text-align: left; font-weight: 650; margin-bottom: 12px; }
th,td { padding: 12px 10px; text-align: right; border-bottom: 1px solid var(--line); white-space: nowrap; }
th:first-child { text-align: left; padding-left: 0; }
td a,th a { color: #1168d4; }
.finance-tabs { justify-content: space-between; gap: 10px; }
.finance-tabs a[aria-current] { color: #1168d4; }
.balance-now { margin-bottom: 24px; max-width: 330px; }
.balance-now .metric-label { min-height: 20px; }
.report-section { padding: 16px 0; border-bottom: 1px solid var(--line); }
.report-section summary { cursor: pointer; font-weight: 650; padding: 8px 0; }
.report-section li { margin: 10px 0; line-height: 1.55; }
.reminder-row { padding: 12px 0; border-bottom: 1px solid var(--line); }
.home-reminders { padding: 12px 0; border-bottom: 1px solid var(--line); }
.home-reminders-heading { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 16px; margin-bottom: 10px; }
.home-reminders-heading a { color: #1168d4; font-size: 13px; }
.home-reminder { display: grid; grid-template-columns: minmax(70px,110px) minmax(0,1fr) max-content max-content; align-items: center; gap: 4px 12px; padding: 6px 10px; margin-top: 6px; border: 1px solid var(--line); border-radius: 4px; background: #fff; font-size: 12px; }
.home-reminder > * { min-width: 0; overflow-wrap: anywhere; }
.home-reminder-registration { font-weight: 650; }
.home-reminder-date { color: var(--muted); font-size: 11px; white-space: nowrap; }
.reminder-warning { color: #75520d; background: #fcf0cc; }
.reminder-info { color: var(--muted); background: #e9eef4; }
.driver-info { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 10px; width: fit-content; max-width: 100%; margin-top: 8px; }
.driver-info p { margin: 0; min-width: 0; }
.driver-info .status { max-width: 100%; white-space: normal; }
.driver-actions { margin-top: 12px; }
.reconciliation-equation { overflow-wrap: anywhere; font-variant-numeric: tabular-nums; }
#servicing-total { display: block; margin: 16px 0; font-weight: 700; }
.cashing-invoice { margin: 18px 0; }
.invoice-heading, .invoice-row { display: grid; grid-template-columns: minmax(0,1fr) minmax(0,1fr) minmax(0,1fr); gap: 8px; align-items: start; }
.invoice-heading { color: var(--muted); font-size: 12px; padding: 10px 8px; }
.invoice-row { padding: 12px 8px; font-size: 13px; }
.invoice-row>* { overflow-wrap: anywhere; min-width: 0; }
.invoice-heading>*:not(:first-child), .invoice-row>*:not(:first-child) { text-align: right; font-variant-numeric: tabular-nums; }
.cashing-choice { border-bottom: 1px solid var(--line); padding: 4px 0; }
.cashing-choice:has(.adjust-trigger:not([hidden])) { border: 1px solid var(--line); border-radius: 6px; margin: 12px 0; padding: 8px; }
.cashing-choice.is-adjusted { border-color: #1479f6; background: #f6faff; }
.adjust-trigger { min-height: 44px; cursor: pointer; }
.adjust-trigger svg { width: 16px; height: 16px; }
.invoice-total { display: flex; justify-content: space-between; gap: 12px; border-top: 2px solid var(--line); padding: 16px 8px; font-variant-numeric: tabular-nums; }
.invoice-total>* { min-width: 0; overflow-wrap: anywhere; }
.cashing-submit { width: 100%; margin-top: 20px; min-height: 48px; }
:focus-visible { outline: 3px solid #7bb5ff; outline-offset: 3px; }
.skip-link { position: fixed; top: -70px; left: 8px; background: #fff; padding: 12px; z-index: 9; }
.skip-link:focus { top: 8px; }
@media (max-width: 600px) {
  .home-reminder { grid-template-columns: minmax(0,1fr) auto; gap: 4px 10px; }
  .home-reminder-registration { grid-column: 1; grid-row: 1; }
  .home-reminder-title { grid-column: 1; grid-row: 2; }
  .home-reminder-date { grid-column: 2; grid-row: 2; }
  .home-reminder .status { grid-column: 2; grid-row: 1; justify-self: end; }
  .bus-list { grid-template-columns: minmax(0, 1fr); }
  .filters { grid-template-columns: minmax(0, 1fr) auto; }
  .filters label:first-child, .filters .search-row { grid-column: 1/-1; }
  .filters label[for=status] { grid-column: 1; grid-row: 3; margin-top: 8px; }
  .filters select { grid-column: 1; grid-row: 4; }
  .filter-button { grid-column: 2; grid-row: 4; }
  .login-panel { margin-top: 25px; }
  main { padding-top: 22px; }
}
@media (prefers-reduced-motion: reduce) { * { scroll-behavior: auto; } }
