/* Concept Drive: shared mobile visual vocabulary. */
:root {
  --cd-black: #08090b;
  --cd-ink: #14171a;
  --cd-muted: #626970;
  --cd-line: #dde1e5;
  --cd-canvas: #fff;
  --cd-surface: #fff;
  --cd-red: #ec1c24;
  --cd-red-dark: #c8141b;
  --cd-blue: #176ea6;
  --cd-blue-soft: #eaf5fb;
  --cd-green: #087b52;
  --cd-green-soft: #e6f6ef;
  --cd-amber: #8a5a08;
  --cd-amber-soft: #fff3d8;
  --radius: 12px;
  --red: #ec1c24;
  --red-hover: #c8141b;
  --mobile-gutter: 14px;
  --mobile-nav-height: 68px;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --bg:#fff; --surface:#fff; --surface-2:#f6f7f8;
  --ink:var(--cd-ink); --muted:var(--cd-muted); --subtle:#70777e; --line:var(--cd-line);
  --red-soft:#fff0f1; --blue:var(--cd-blue); --blue-soft:var(--cd-blue-soft); --shadow:none;
}

html { background: #dfe2e5; scroll-behavior: auto; scroll-padding-block-start: calc(70px + env(safe-area-inset-top)); }
body {
  min-width: 320px;
  background: #dfe2e5;
  color: var(--cd-ink);
  font: 15px/1.4 system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
.shell { background: var(--cd-canvas); }

.topbar {
  height: calc(58px + env(safe-area-inset-top));
  padding: env(safe-area-inset-top) 10px 0;
  background: var(--cd-black);
  color: #fff;
  border:0; backdrop-filter:none; -webkit-backdrop-filter:none;
}
.topbar-actions { gap:0; }
.brand {
  min-height: 44px;
  position:absolute; left:50%; transform:translateX(-50%);
  gap: 8px;
  color: #fff;
}
.brand-mark {
  width: 4px;
  height: 32px;
  border-radius: 0;
  background: var(--cd-red);
}
.brand-wordmark {
  display: grid;
  color: #fff;
  font-size: 14px;
  font-weight: 850;
  line-height: .84;
  letter-spacing: -.035em;
}
.header-icon,
.topbar .profile-button {
  position: relative;
  width: 44px;
  min-width: 44px;
  height: 44px;
  border-radius: 8px;
  color: #fff;
}
.notification-badge {
  position: absolute;
  top: 3px;
  right: 2px;
  min-width: 17px;
  height: 17px;
  padding: 0 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 2px solid var(--cd-black);
  border-radius: 999px;
  background: var(--red);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  line-height: 1;
  white-space: nowrap;
  pointer-events: none;
}
.notification-badge:empty { display: none; }
.header-icon:hover,
.header-icon:active,
.topbar .profile-button:hover,
.topbar .profile-button:active { background: #202328; }

main {
  padding: 14px var(--mobile-gutter)
    calc(var(--mobile-nav-height) + env(safe-area-inset-bottom) + 18px);
  overflow-x: clip;
}

.view { width: 100%; min-width: 0; }
.view > :first-child { margin-top: 0; }
.page-head,
.home-header,
.wizard-top {
  gap: 5px;
  margin-bottom: 12px;
}
.page-head h1,
.home-header h1,
.wizard-top h1,
.add-intro h1 {
  margin: 0 0 3px;
  color: #0d0f11;
  font-size: 22px;
  line-height: 1.18;
  letter-spacing: -.025em;
}
.page-head p,
.home-header p,
.add-intro p {
  margin-bottom: 0;
  color: var(--cd-muted);
  font-size: 14px;
  line-height: 1.42;
}
.section-heading {
  min-height: 44px;
  margin: 4px 0 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.section-heading h2,
.section-heading h3 {
  margin: 0;
  color: #111418;
  font-size: 17px;
  line-height: 1.2;
}
.section-heading .link-button { margin-right: -8px; }

.card,
.wizard-card,
.choice-card,
.dialog-card,
.home-car,
.weather-card {
  border: 0;
  border-radius: var(--radius);
  background: var(--cd-surface);
  box-shadow: none;
}
.card,
.wizard-card { padding: 14px; }
.card-title { margin-bottom: 9px; }
.card-title h2,
.card-title h3 { font-size: 16px; }

.button,
.filter,
.small-action,
.link-button,
.text-link,
.choice-card,
.action-tile,
.city-option,
.assistant-button,
.home-car__actions button,
.home-car__actions a,
.doc-card__actions button,
.doc-card__actions a {
  min-height: 44px;
}
.button { border-radius: 9px; }
.button.primary { background: var(--red); color: #fff; }
.button.primary:hover { background: var(--cd-red-dark); }
.button.secondary { background: var(--cd-blue-soft); color: var(--cd-blue); }
.button.ghost { color: var(--cd-blue); }
.link-button,
.text-link,
.small-action,
.document-actions a { color: var(--cd-blue); }

:where(a, button, input, select, textarea, summary):focus-visible {
  outline: 3px solid rgba(236, 28, 36, .38);
  outline-offset: 2px;
}
:where(button, input, select, textarea):disabled { cursor: not-allowed; opacity: .55; }
input,
select,
textarea,
.picker-trigger {
  min-width: 0;
  min-height: 48px;
  border: 1px solid #c9ced3;
  border-radius: 9px;
  background: #fff;
  font-size: 16px;
}
input::placeholder,
textarea::placeholder { color: #676e75; opacity: 1; }
.form-grid label,
.stack-form label,
.item-grid label,
.wizard-form label,
.mileage-form label,
.password-form label {
  gap: 6px;
  color: #3f464d;
  font-size: 14px;
  line-height: 1.3;
}
.form-error:not(:empty) {
  min-height: 44px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  border-radius: 9px;
  background: #fff0f1;
  color: #a70e15;
}

/* Continuous home composition. */
.home-dashboard,.home-canvas { display:grid; gap:0; }
.home-car { position:relative; overflow:hidden; padding:0; border-radius:0; }
.home-car__top { display:flex; align-items:flex-start; justify-content:space-between; gap:10px; }
.home-car__identity { min-width:0; }
.home-car__identity > span { display:block; color:var(--cd-blue); font-size:11px; font-weight:600; }
.home-car__identity h1,.home-car__identity h2 { margin:1px 0 0; color:var(--cd-ink); font-size:21px; line-height:1.15; overflow-wrap:anywhere; letter-spacing:-.025em; }
.home-car__identity p { margin:2px 0 0; color:#424950; font-size:12px; }
.home-car__garage { min-height:44px; display:flex; align-items:center; gap:3px; margin:-5px -6px 0 0; padding:0 6px; border:0; border-radius:5px; background:transparent; color:var(--cd-blue); font-size:12px; font-weight:650; }
.home-car__garage svg:first-child { display:none; }
.home-car__garage svg { width:14px; height:14px; }
.home-car__visual { position:relative; height:230px; margin:5px calc(-1 * var(--mobile-gutter)) 0; display:grid; place-items:center; overflow:hidden; background:linear-gradient(#fff 10%,#f2f5f7 76%,#fff); }
.home-car__visual img,.home-car__visual svg { width:100%; height:100%; object-fit:contain; }
.home-car__visual img.vehicle-cutout { object-fit:contain; background:transparent; }
.home-car__visual .vehicle-photo { object-fit:cover; }
.vehicle-photo-caption { display:block; padding:5px 0; color:var(--cd-muted); font-size:11px; text-align:center; }
.home-car__meta { display:grid; grid-template-columns:auto minmax(0,1fr); align-items:center; gap:10px; margin:0; }
.home-car .plate-number { position:static; padding:0; border:0; background:transparent; color:var(--cd-ink); font-size:14px; }
.home-car__meta-empty { color:var(--cd-muted); font-size:11px; }
.home-car__odometer { min-height:44px; margin:0; padding:3px 0; border:0; background:transparent; text-align:right; }
.home-car__odometer strong { display:block; color:var(--cd-ink); font-size:15px; line-height:1.2; }
.home-car__odometer small { color:var(--cd-muted); font-size:10px; }
.home-status-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); border-block:1px solid var(--cd-line); }
.home-status-cell { min-height:48px; padding:7px 9px; display:flex; align-items:center; justify-content:center; gap:7px; border:0; background:#fff; color:var(--cd-ink); }
.home-status-cell + .home-status-cell { border-left:1px solid var(--cd-line); }
.home-status-cell strong { color:var(--cd-blue); font-size:19px; font-weight:750; }
.home-status-cell span { font-size:11px; text-align:left; line-height:1.25; }
.home-focus-list { padding-top:4px; }
.home-focus-list .section-heading { min-height:38px; }
.section-heading > div > span { display:block; margin-top:2px; color:var(--cd-muted); font-size:11px; }
.home-empty-row { width:100%; min-height:56px; padding:8px 0; display:flex; justify-content:space-between; align-items:center; gap:12px; border:0; background:#fff; text-align:left; }
.home-empty-row strong,.home-empty-row small { display:block; }
.home-empty-row strong { font-size:14px; }
.home-empty-row small { color:var(--cd-muted); font-size:12px; }
.home-context-list { display:grid; margin-top:3px; border-top:1px solid var(--cd-line); }
.season-row,.weather-row { min-width:0; min-height:62px; padding:8px 2px; display:grid; grid-template-columns:36px minmax(0,1fr) auto; align-items:center; gap:9px; border:0; border-bottom:1px solid var(--cd-line); border-radius:0; background:#fff; color:var(--cd-ink); text-align:left; text-decoration:none; }
.season-row > span:nth-child(2),.weather-row > span:nth-child(2) { min-width:0; display:grid; gap:2px; }
.season-row strong,.weather-row strong { display:block; overflow-wrap:anywhere; font-size:13px; line-height:1.25; }
.season-row small,.weather-row small { display:block; overflow-wrap:anywhere; color:var(--cd-muted); font-size:11px; line-height:1.35; }
.context-icon { width:34px; height:34px; display:grid; place-items:center; border-radius:5px; background:var(--cd-blue-soft); color:#268dc5; }
.context-icon svg { width:25px; height:25px; }
.season-row > svg,.weather-row > svg { width:17px; height:17px; color:var(--cd-blue); }
.weather-row > b { color:var(--cd-blue); font-size:18px; white-space:nowrap; }
.home-primary-actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:7px; margin-top:9px; }
.camera-action,.assistant-button { min-width:0; width:100%; min-height:49px; padding:7px 8px; display:grid; grid-template-columns:26px minmax(0,1fr); align-items:center; gap:7px; border:0; border-radius:6px; text-align:left; color:#fff; }
.camera-action { background:var(--red); }
.assistant-button { background:var(--cd-black); }
.camera-action > svg,.assistant-button > svg { width:25px; height:25px; }
.camera-action > span,.assistant-button > span { min-width:0; }
.camera-action strong,.assistant-button strong { display:block; overflow-wrap:anywhere; font-size:11px; line-height:1.2; }
.camera-action small,.assistant-button small { display:block; font-size:11px; line-height:1.3; opacity:.85; }
.home-followup-section { margin-top:16px; padding-top:8px; border-top:1px solid var(--cd-line); }
.home-car--empty { display:grid; gap:14px; padding-block:12px 20px; }
.home-car__actions { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:7px; margin-top:10px; }
.vehicle-photo-actions { display:flex; flex-wrap:wrap; gap:7px; margin-top:10px; }
.vehicle-photo-actions .button { flex:1 1 180px; }
.vehicle-photo-actions svg { width:21px; height:21px; }
.today-list,.plan-list,.documents-list,.season-checklist,.city-list { display:grid; gap:0; }
.compact-work { min-height:64px; padding:7px 0; display:grid; grid-template-columns:38px minmax(0,1fr) 44px; align-items:center; gap:8px; border-bottom:1px solid var(--cd-line); background:#fff; }
.today-list .compact-work--link { width:100%; border:0; border-bottom:1px solid var(--cd-line); border-radius:0; color:inherit; font:inherit; text-align:left; appearance:none; }
.today-list .compact-work--link:hover,
.today-list .compact-work--link:active { background:#f6f7f8; }
.compact-work__icon { width:36px; height:36px; display:grid; place-items:center; border-radius:5px; background:#f7f8f9; color:var(--cd-ink); }
.compact-work.is-due .compact-work__icon { color:var(--red); background:#fff4f4; }
.compact-work__icon svg { width:27px; height:27px; }
.compact-work__body { min-width:0; }
.compact-work strong { display:block; overflow-wrap:anywhere; font-size:14px; font-weight:650; line-height:1.3; }
.compact-work small { display:block; margin-top:3px; color:var(--cd-muted); font-size:11px; line-height:1.4; }
.compact-work__open { width:44px; height:44px; padding:0; display:grid; place-items:center; border:0; background:transparent; color:var(--cd-muted); }
.compact-work__open svg { width:17px; height:17px; }
.plan-toolbar { display:flex; align-items:center; justify-content:space-between; gap:8px; margin-bottom:2px; }
.plan-toolbar .button { padding:8px 12px; }
.plan-list .compact-work { grid-template-columns:36px minmax(0,1fr) 24px 44px; gap:7px; }
.plan-list .compact-work > input { width:20px; height:20px; min-height:20px; margin:0; accent-color:var(--red); }
.compact-work__actions { grid-column:3; display:flex; align-items:center; gap:3px; margin-top:-8px; }
.compact-work__actions .small-action { padding:0; font-size:12px; }
.compact-work__actions .delete-button { color:#858c93; margin-left:auto; font-size:20px; }
.compact-work.is-done .compact-work__body { opacity:.65; }
.compact-work.is-done strong { text-decoration:line-through; }
.status-chip { min-height:24px; padding:4px 7px; border-radius:5px; background:var(--cd-blue-soft); color:var(--cd-blue); font-size:11px; }
.status-chip.good { background:var(--cd-green-soft); color:var(--cd-green); }
.status-chip.warn { background:var(--cd-amber-soft); color:var(--cd-amber); }

/* Documents */
.documents-view,
.plan-view,
.garage-overview,
.weather-view,
.season-view { display: grid; gap: 10px; }
.garage-car .home-car__visual { height: 220px; }
.vehicle-details .page-head { margin-bottom: 2px; }
.doc-card { min-height:80px; padding:9px 0; display:grid; grid-template-columns:32px minmax(0,1fr) 88px; align-items:center; column-gap:8px; border-bottom:1px solid var(--cd-line); background:#fff; }
.doc-card__icon { grid-row:1 / 3; width:36px; height:38px; display:grid; place-items:center; color:var(--red); }
.doc-card__icon svg { width:25px; height:25px; }
.doc-card__body { min-width:0; }
.doc-card__body strong { display:block; overflow-wrap:anywhere; font-size:14px; line-height:1.25; }
.doc-card__body small { display:block; margin-top:3px; color:var(--cd-muted); font-size:11px; line-height:1.35; overflow-wrap:anywhere; }
.doc-card__body em { display:block; color:var(--cd-blue); font-size:10px; font-style:normal; line-height:1.35; margin-top:2px; }
.doc-card__amount { grid-column:2; font-size:13px; white-space:nowrap; align-self:start; margin-top:4px; }
.doc-card__actions { grid-column:3; grid-row:1 / 3; display:flex; align-items:center; gap:0; }
.doc-card__actions a,.doc-card__actions button { min-height:44px; min-width:44px; padding:0; border:0; background:transparent; color:var(--cd-blue); font-size:12px; }

/* Garage, weather, and seasonal checklists */
.detail-row {
  min-height: 52px;
  padding: 9px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-top: 1px solid var(--cd-line);
}
.detail-row:first-child { border-top: 0; }
.detail-row span { color: var(--cd-muted); font-size: 13px; }
.detail-row strong { max-width: 62%; text-align: right; overflow-wrap: anywhere; font-size: 14px; }
.detail-row dt { color: var(--cd-muted); font-size: 13px; }
.detail-row dd { max-width: 62%; text-align: right; overflow-wrap: anywhere; font-size: 14px; }
.weather-card { padding: 14px; }
.weather-card__current {
  display: flex;
  align-items: center;
  gap: 14px;
}
.weather-card__current > div {
  min-width: 0;
  display: grid;
  gap: 3px;
}
.weather-card__current > div > span { color: var(--cd-muted); font-size: 13px; }
.weather-card__current strong { display: block; margin-top: 2px; font-size: 32px; line-height: 1; }
.weather-card__current small { color: var(--cd-muted); font-size: 12px; }
.weather-card p { margin: 0; color: var(--cd-muted); font-size: 13px; line-height: 1.35; }
.weather-card > .text-link { margin: 10px -8px -7px; }
.weather-location-form h2 { margin-bottom: 4px; font-size: 17px; }
.city-option {
  width: 100%;
  padding: 8px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 0;
  border-radius: 9px;
  background: #fff;
  box-shadow: none;
  text-align: left;
}
.city-option[aria-pressed="true"],
.city-option.active { background: var(--cd-blue-soft); color: #12577f; }
.season-item {
  min-height: 78px;
  padding: 9px 0;
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
}
.season-item > span {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: var(--cd-blue-soft);
  color: var(--cd-blue);
}
.season-item > span svg { width: 22px; height: 22px; }
.season-item .small-action { padding-inline:0; white-space:nowrap; font-size:12px; }
.season-item input { width: 22px; height: 22px; min-height: 22px; margin: 0; accent-color: var(--cd-red); }
.season-item strong { display: block; font-size:14px; line-height:1.3; }
.season-item small { display:block; color:var(--cd-muted); font-size:11px; line-height:1.35; }
.season-note { margin: 2px 2px 0; font-size: 12px; }
.season-sources {
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
}
.season-sources summary {
  min-height: 48px;
  padding: 10px 12px;
  display: flex;
  align-items: center;
  cursor: pointer;
  font-weight: 700;
}
.season-sources p { margin: 0; padding: 0 12px 10px; font-size: 13px; }
.season-sources a { color: var(--cd-blue); }

/* Existing flows */
.history-filters { gap: 6px; }
.filter-row {
  margin-inline: calc(-1 * var(--mobile-gutter));
  padding: 2px var(--mobile-gutter) 8px;
  scroll-padding-inline: var(--mobile-gutter);
  scrollbar-width: none;
}
.filter-row::-webkit-scrollbar { display: none; }
.filter { flex: 0 0 auto; border-radius: 8px; }
.filter.active { background: var(--red); color: #fff; }
.form-card,
.wizard-card {
  width: 100%;
  margin-inline: 0;
  border-radius: var(--radius);
  box-shadow: none;
}
.form-grid,
.wizard-form,
.item-grid { gap: 14px; }
.form-actions { gap: 8px; }
.stack-form { display:grid; gap:14px; }
.stack-form h2 { margin-bottom: 0; font-size: 17px; }
.stack-form > p { margin-bottom: 0; font-size: 14px; line-height: 1.45; }
.form-grid label:not(.checkline) > :is(input,select,textarea),
.stack-form label:not(.checkline) > :is(input,select,textarea),
.item-grid label:not(.checkline) > :is(input,select,textarea),
.wizard-form label:not(.checkline) > :is(input,select,textarea),
.password-fields label:not(.checkline) > :is(input,select,textarea),
.mileage-form label:not(.checkline) > :is(input,select,textarea) { margin-top:8px; }
.stack-form > :is(.form-actions,.plan-form__actions),
.stack-form > .button[type="submit"],
.password-fields > .button[type="submit"],
.feedback-form > .button[type="submit"] { margin-top:4px; }
.stack-form > .checkline,
.policy-review > .checkline,
.review-form > .checkline { margin-block:2px; padding-block:4px; }
.field-help { font-size: 13px; line-height: 1.35; }
.form-error:empty { display:none; min-height:0; margin:0; }
.upload-box {
  border: 1px dashed #969da4;
  background: #f5f6f7;
}
.list-row,
.document-item,
.reminder { min-height: 56px; }
.list-row.highlighted,
.reminder.highlighted { background: #fff0f1; }
.more-list { box-shadow: none; }
.more-row { min-height: 62px; }
.more-row > span:nth-child(2) {
  min-width: 0;
  display: grid;
  gap: 2px;
}
.more-row strong,
.more-row small {
  display: block;
  line-height: 1.3;
}
.more-row small {
  overflow: visible;
  overflow-wrap: anywhere;
  text-overflow: clip;
  white-space: normal;
}
.more-icon { background: var(--cd-blue-soft); color: var(--cd-blue); }

.notification-list {
  display: grid;
  gap: 7px;
}
.notification-row {
  position: relative;
  min-height: 64px;
  padding: 9px 8px;
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  border-radius: 10px;
  background: #fff;
  box-shadow: none;
}
.notification-icon,
.notification-row__icon,
.notification-row > :first-child {
  position: relative;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: #f0f2f4;
  color: #293038;
}
.notification-icon svg,
.notification-row__icon svg,
.notification-row > :first-child svg { width: 22px; height: 22px; }
.notification-row__body {
  min-width: 0;
  display: grid;
  gap: 3px;
}
.notification-row__body strong,
.notification-row__body small,
.notification-row__body p {
  display: block;
  overflow-wrap: anywhere;
}
.notification-row__body strong { font-size: 15px; line-height: 1.25; }
.notification-row__body small { color: var(--cd-muted); font-size: 13px; line-height: 1.35; }
.notification-row__body p {
  margin: 0;
  color: var(--cd-muted);
  font-size: 13px;
  line-height: 1.35;
}
.notification-row__actions {
  display: flex;
  align-items: center;
  gap: 2px;
}
.notification-row__actions :where(a, button) { min-width: 44px; min-height: 44px; }
.notification-row.is-unread,
.notification-row.unread { background: var(--cd-blue-soft); }
.notification-row.is-unread .notification-row__icon::after,
.notification-row.unread .notification-row__icon::after,
.notification-row.is-unread .notification-icon::after,
.notification-row.unread .notification-icon::after,
.notification-row.is-unread > :first-child::after,
.notification-row.unread > :first-child::after {
  content: "";
  position: absolute;
  top: 2px;
  right: 2px;
  width: 8px;
  height: 8px;
  border: 2px solid var(--cd-blue-soft);
  border-radius: 50%;
  background: var(--red);
}

.tabbar {
  height: calc(var(--mobile-nav-height) + env(safe-area-inset-bottom));
  padding: 4px 4px env(safe-area-inset-bottom);
  background: var(--cd-black);
  border: 0;
  box-shadow: none;
}
.tabbar a {
  min-width: 0;
  min-height: 58px;
  flex: 1 1 20%;
  gap: 2px;
  padding: 3px 1px;
  border-radius: 8px;
  color: #f0f2f3;
  font-size: 10px;
  font-weight: 650;
}
.tabbar a:hover,
.tabbar a:active { background: #202328; }
.tabbar a.active,
.tabbar a[aria-current="page"] { color: var(--cd-red); }
.tabbar svg { width: 21px; height: 21px; stroke-linecap: round; stroke-linejoin: round; }
.add-tab { margin: 0; }
.add-orb {
  width: 29px;
  height: 29px;
  border: 1.5px solid currentColor;
  border-radius: 50%;
  background: transparent;
  box-shadow: none;
}
.add-orb svg { width: 17px; height: 17px; }

@media (max-width: 370px) {
  :root { --mobile-gutter: 12px; }
  .brand-wordmark { font-size: 13px; }
  .tabbar a { font-size: 9px; }
  .home-car__visual { height: 185px; }
  .camera-action strong,.assistant-button strong { font-size:10px; }
  .compact-work { grid-template-columns: 34px minmax(0,1fr) 44px; }
  .compact-work .status-chip { grid-column: 2; justify-self: start; }

  .plan-list .compact-work { grid-template-columns:30px minmax(0,1fr) 22px 40px; gap:5px; }
  .plan-list .compact-work__actions { grid-column: 3; }
  .doc-card { grid-template-columns:28px minmax(0,1fr) 44px; }
  .doc-card__actions { flex-direction:column; }
  .doc-card__amount { grid-column:2; margin-top:4px; }
  .doc-card__actions { grid-column:3; justify-self:end; }
  .detail-row { align-items: flex-start; flex-direction: column; gap: 2px; }
  .detail-row strong { max-width: 100%; text-align: left; }
  .detail-row dd { max-width: 100%; text-align: left; }
  .season-item { grid-template-columns:32px minmax(0,1fr) 46px; gap:7px; }
  .notification-row { grid-template-columns: 40px minmax(0, 1fr); }
  .notification-row__actions { grid-column: 2; justify-self: start; }
}

@media (min-width: 481px) {
  .shell { box-shadow: 0 0 24px rgba(20, 28, 35, .12); }
}

@media (prefers-contrast: more) {
  .card,
  .home-car,
  .compact-work,
  .doc-card,
  .season-row,
  .weather-row,
  .weather-card,
  .season-item,
  .city-option { outline: 1px solid #666; }
  .tabbar a { color: #fff; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* Shared detail and form surfaces. */
.vehicle-profile-card { background:#fff; color:var(--cd-ink); border:0; border-radius:0; }
.vehicle-profile-head { padding:12px 0; border-color:var(--cd-line); }
.vehicle-profile-head h2 { padding:0; margin:3px 0 7px; font-size:21px; }
.vehicle-profile-head .plate-number { position:static; display:inline-block; border:1px solid #c9ced3; }
.vehicle-facts { margin:0; padding:0; }
.vehicle-facts div { border-color:var(--cd-line); min-height:45px; }
.vehicle-facts dt,.mileage-block small { color:var(--cd-muted); }
.vehicle-facts dd { color:var(--cd-ink); font-size:14px; }
.mileage-block { padding:14px 0; }
.mileage-block > div > strong { color:var(--cd-ink); font-size:23px; }
.mileage-form { border-color:var(--cd-line); }
.mileage-form label { color:#424950; }
.mileage-form > div:first-child { gap:12px; }
.mileage-form .form-actions { margin-top:16px; }
.garage-car { padding:0; }
.action-tile { border:0; border-bottom:1px solid var(--cd-line); border-radius:0; background:#fff; color:var(--cd-ink); }
.action-tile small { color:var(--cd-muted); }
.form-card,.wizard-card { padding:14px 0; border-radius:0; }
.choice-card { padding:15px 0; border-bottom:1px solid var(--cd-line); border-radius:0; }
.choice-icon { color:var(--red); background:#fff0f1; border-radius:5px; }
.form-grid input,.stack-form input,.item-grid input,.wizard-form input,.auth-card input,.mileage-form input,.password-form input { background:#fff; }
.plan-form { border-top:1px solid var(--cd-line); }
.more-list { border:0; border-radius:0; box-shadow:none; }
.more-row { padding:9px 0; grid-template-columns:36px minmax(0,1fr) 20px; }
.more-row strong { font-size:14px; }
.more-row small { font-size:11px; }
.more-icon { background:#f6f7f8; color:var(--cd-ink); border-radius:5px; }
.more-row > svg { width:17px; height:17px; color:var(--cd-muted); }
.account-card { padding:14px 0; border-block:1px solid var(--cd-line); border-radius:0; }
.account-details strong { overflow-wrap:anywhere; }
.chat-card { padding:0; border:1px solid var(--cd-line); border-radius:8px; }
.message { font-size:14px; line-height:1.5; border-radius:8px; }
.message.user { background:var(--cd-ink); color:#fff; }
.message.assistant { background:#f6f7f8; color:var(--cd-ink); }
.chat-form { padding:8px; gap:7px; }
.assistant-side { border-top:1px solid var(--cd-line); border-radius:0; padding:14px 0; }
.template-list,.starter-prompts { scrollbar-width:none; }
.template-list::-webkit-scrollbar,.starter-prompts::-webkit-scrollbar { display:none; }
.template-list button,.starter-prompts button { font-size:12px; border-radius:6px; }
.tabbar a.active,.tabbar a[aria-current="page"] { background:transparent; }
.topbar,.tabbar { backdrop-filter:none; -webkit-backdrop-filter:none; }
.site-footer { margin-top:18px; padding-top:12px; font-size:10px; }

.vehicle-gear-overlay { position:absolute; top:8px; right:14px; width:44px; height:44px; display:grid; place-items:center; border:0; border-radius:7px; background:transparent; color:#fff; }
.vehicle-gear-overlay svg { width:30px; height:30px; padding:5px; border-radius:5px; background:#4b535ed9; }
.plan-form__actions { display:grid; gap:8px; }
.plan-list .compact-work__icon .ui-icon--oil,.plan-list .compact-work__icon .ui-icon--windshield { color:var(--red); }
.doc-card__actions .ui-icon { width:20px; height:20px; }
.weather-card { padding:14px 0; border-block:1px solid var(--cd-line); border-radius:0; }
.weather-card__current strong { color:var(--cd-blue); }
.weather-location-form { display:grid; gap:12px; padding:14px 0; }
.weather-location-form label { display:grid; gap:6px; font-size:13px; }
.form-grid :is(input,select,textarea),.stack-form :is(input,select,textarea),.item-grid :is(input,select),.wizard-form :is(input,select),.weather-location-form select { background:#fff; }
.site-footer .install-link { padding:0; align-self:flex-start; font-size:12px; }

/* A single icon family, with the same semantic accents as the client concept. */
.ui-icon { stroke-width:1.7; }
.context-icon .ui-icon--snow { width:27px; height:27px; color:#258fc9; }
.context-icon .ui-icon--cloud { width:29px; height:29px; color:#469bd0; }
.compact-work__icon .ui-icon--oil,
.compact-work__icon .ui-icon--windshield { color:var(--cd-red); }
.compact-work__icon .ui-icon--brakes,
.compact-work__icon .ui-icon--battery,
.compact-work__icon .ui-icon--tire { color:var(--cd-ink); }
.doc-card__icon { background:#fff4f4; border-radius:6px; }
.doc-card__icon .ui-icon { width:25px; height:25px; }
.camera-action .ui-icon { width:24px; height:24px; }
.assistant-button .ui-icon--send { width:22px; height:22px; }
.add-orb { border:0; }
.add-orb svg { width:34px; height:34px; }
.chat-card { min-height:390px; }

/* Shared utility icons: fixed boxes keep controls aligned on every screen. */
.delete-button { display: inline-flex; align-items: center; justify-content: center; }
.delete-button .ui-icon { width: 20px; height: 20px; flex-shrink: 0; }
.picker-trigger > .ui-icon, .picker-results button > .ui-icon { width: 20px; height: 20px; flex-shrink: 0; }
.picker-results button > .ui-icon { color: var(--cd-red); }
.chat-form button .ui-icon { width: 22px; height: 22px; }

/* Consistent inset for catalog checks and closed native dropdown indicators. */
select { appearance:none; -webkit-appearance:none; padding-right:44px !important; background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235c6670' stroke-width='1.7' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m5 9 7 7 7-7'/%3E%3C/svg%3E") !important; background-repeat:no-repeat !important; background-position:right 16px center !important; background-size:18px 18px !important; }
.picker-results button { padding-inline:16px; gap:16px; }
.picker-results button > span { min-width:0; overflow-wrap:anywhere; }
.picker-trigger { padding-inline:16px; gap:12px; }
.home-spending { flex-direction:column; gap:2px; }
.home-spending strong { max-width:100%; overflow-wrap:anywhere; font-size:17px; }
.home-spending span { text-align:center; }
.history-filters { flex-direction:column; align-items:stretch; gap:10px; }
.history-selects { display:grid; gap:8px; }
.history-selects .filter-select { margin:0; }
.history-selects select { max-width:none; }
.spending-summary { padding:14px 0 16px; margin:0 0 16px; border-block:1px solid var(--cd-line); }
.spending-summary__top { display:flex; justify-content:space-between; align-items:flex-end; gap:16px; }
.spending-summary__top > div { min-width:0; }
.spending-summary__label { display:block; color:var(--cd-muted); font-size:12px; margin-bottom:4px; }
.spending-summary__total { display:block; font-size:28px; line-height:1.2; letter-spacing:-.025em; white-space:nowrap; font-variant-numeric:tabular-nums; }
.spending-summary__top > p { flex:1; min-width:0; font-size:11px; line-height:1.5; text-align:right; color:var(--cd-muted); margin:0 0 3px; }
.spending-summary__categories { display:flex; flex-wrap:wrap; gap:10px 22px; margin:12px 0 0; }
.spending-summary__categories > div { display:flex; align-items:baseline; gap:7px; font-size:12px; }
.spending-summary__categories dt { color:var(--cd-muted); }
.spending-summary__categories dd { margin:0; font-weight:650; }
.spending-summary__empty { font-size:12px; color:var(--cd-muted); margin:10px 0 0; }
@media (forced-colors:active) { select { appearance:auto; -webkit-appearance:auto; background-image:none !important; } }

/* V2 detail flows and narrow-screen hardening. */
.connection { display:none; }
.topbar-actions { margin-left:auto; }
.nested-view .tabbar { visibility:hidden; pointer-events:none; }
.nested-view main { padding-bottom:calc(24px + env(safe-area-inset-bottom)); }
.nested-view #openProfile .ui-icon--chevron { transform:rotate(180deg); }
.row-open,.back-button { width:44px; height:44px; padding:0; display:grid; place-items:center; border:0; background:transparent; color:var(--cd-blue); }
.row-open svg,.back-button svg { width:19px; height:19px; }
.back-button svg { transform:rotate(180deg); }
.expense-row,.policy-row,.document-row { grid-template-columns:10px minmax(0,1fr) auto 44px; gap:8px; }
.expense-row .row-main,.policy-row .row-main,.document-row .row-main { min-width:0; }
.expense-row .row-amount { max-width:105px; overflow-wrap:anywhere; text-align:right; font-variant-numeric:tabular-nums; }
.policy-row .row-open,.document-row .row-open { grid-column:4; }
.timeline-list { border-top:1px solid var(--cd-line); }
.detail-view { display:grid; gap:20px; }
.detail-head { display:grid; grid-template-columns:44px minmax(0,1fr); align-items:start; gap:6px; margin-left:-8px; }
.detail-head h1 { margin:3px 0 2px; font-size:24px; overflow-wrap:anywhere; }
.detail-head p { margin:0; color:var(--cd-muted); font-size:13px; }
.detail-total { padding:16px 0; display:flex; align-items:end; justify-content:space-between; gap:12px; border-block:1px solid var(--cd-line); }
.detail-total span,.detail-fact span { color:var(--cd-muted); font-size:13px; }
.detail-total strong { font-size:28px; line-height:1.1; font-variant-numeric:tabular-nums; overflow-wrap:anywhere; text-align:right; }
.detail-fact { display:flex; justify-content:space-between; gap:12px; }
.detail-view h2,.feedback-form h2 { margin:0 0 8px; font-size:18px; }
.detail-list { margin:0; }
.detail-list>div { min-height:46px; padding:9px 0; display:flex; justify-content:space-between; gap:16px; border-bottom:1px solid var(--cd-line); }
.detail-list dt { color:var(--cd-muted); }
.detail-list dd { margin:0; max-width:62%; text-align:right; overflow-wrap:anywhere; }
.line-items { border-top:1px solid var(--cd-line); }
.line-item { min-height:62px; padding:10px 0; display:flex; justify-content:space-between; gap:12px; border-bottom:1px solid var(--cd-line); }
.line-item>div:first-child { min-width:0; }
.line-item strong,.line-item small { display:block; overflow-wrap:anywhere; }
.line-item small { margin-top:3px; color:var(--cd-muted); font-size:12px; }
.line-item__aside { flex:0 0 auto; max-width:44%; display:grid; justify-items:end; gap:5px; text-align:right; }
.detail-actions { display:flex; flex-wrap:wrap; gap:8px; }
.document-hero { position:relative; height:220px; display:grid; place-items:center; overflow:hidden; background:#f3f5f6; color:var(--cd-blue); text-decoration:none; }
.document-hero img { width:100%; height:100%; object-fit:contain; }
.document-hero span { position:absolute; right:8px; bottom:8px; min-height:36px; padding:7px 9px; display:flex; align-items:center; gap:5px; border-radius:6px; background:#fff; }
.assistant-identity { margin-bottom:12px; display:flex; align-items:center; gap:12px; }
.assistant-identity img { width:64px; height:64px; object-fit:cover; border-radius:50%; }
.assistant-identity h1 { margin:0; font-size:24px; }
.assistant-identity p { margin:2px 0 0; color:var(--cd-muted); font-size:13px; }
.account-avatar--photo { object-fit:cover; }
.feedback-form { margin-top:24px; padding-top:18px; display:grid; gap:14px; border-top:1px solid var(--cd-line); }
.feedback-form p { margin:0; color:var(--cd-muted); font-size:13px; }
.feedback-form textarea { width:100%; min-height:110px; padding:12px; resize:vertical; }
.page-head h1,.home-header h1,.wizard-top h1,.add-intro h1 { font-size:24px; line-height:1.21; }
.filter-row--compact { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); margin-inline:0; padding-inline:0; }
.filter-row--compact .filter { min-width:0; padding-inline:8px; }
.assistant-view {
  --assistant-nav-reserve:calc(var(--mobile-nav-height) + env(safe-area-inset-bottom));
  height:calc(var(--visual-viewport-height, 100dvh) + var(--visual-viewport-offset-top, 0px) - 58px - env(safe-area-inset-top) - var(--assistant-nav-reserve) - 14px);
  min-height:0;
  display:grid;
  grid-template-rows:auto auto auto minmax(0,1fr);
  gap:12px;
  overflow:hidden;
}
main:has(> #app > .assistant-view) {
  padding-bottom:0;
  overflow:hidden;
}
.assistant-view .assistant-identity { margin:0; }
.assistant-view .assistant-identity img { width:54px; height:54px; }
.assistant-view .assistant-identity p { max-width:34ch; line-height:1.35; }
.assistant-intro { margin:0; color:var(--cd-muted); font-size:13px; line-height:1.45; }
.assistant-prompts { margin:0; padding:0; display:grid; grid-template-columns:minmax(0,1fr); gap:6px; overflow:visible; }
.assistant-prompts button { width:100%; min-width:0; min-height:52px; padding:7px 10px; display:grid; grid-template-columns:32px minmax(0,1fr); align-items:center; gap:9px; overflow:hidden; white-space:normal; text-align:left; font-size:12px; line-height:1.25; }
.assistant-prompt__icon { width:32px; height:32px; display:grid; place-items:center; border-radius:5px; background:var(--cd-black); color:#fff; }
.assistant-prompt__icon .ui-icon { width:19px; height:19px; }
.assistant-prompts button:last-child .assistant-prompt__icon { background:var(--cd-red); }
.assistant-prompt__text { min-width:0; display:grid; gap:1px; }
.assistant-prompt__text strong,.assistant-prompt__text small { display:block; overflow-wrap:anywhere; }
.assistant-prompt__text strong { color:var(--cd-ink); font-size:12px; line-height:1.2; }
.assistant-prompt__text small { color:var(--cd-muted); font-size:11px; line-height:1.25; }
.assistant-view .chat-card { min-height:0; height:100%; display:flex; flex-direction:column; overflow:hidden; }
.assistant-view .chat-log { min-height:0; max-height:none; overflow-y:auto; overscroll-behavior:contain; }
.assistant-view .chat-form { flex:none; display:grid; grid-template-columns:minmax(0,1fr); gap:7px; padding:8px; }
.assistant-composer { min-width:0; display:grid; grid-template-columns:minmax(0,1fr) 46px; gap:7px; }
.assistant-composer input { min-width:0; margin:0; }
.assistant-composer .button { width:46px; min-width:46px; min-height:48px; padding:0; }
.assistant-image-actions { min-width:0; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:7px; }
.assistant-image-actions button { width:100%; min-width:0; min-height:44px; padding:6px 9px; display:flex; align-items:center; justify-content:center; gap:7px; border:1px solid var(--cd-line); border-radius:7px; background:#fff; color:var(--cd-ink); font-size:12px; font-weight:700; }
.assistant-image-actions button:hover,.assistant-image-actions button:active { background:#f6f7f8; }
.assistant-image-actions .ui-icon { width:20px; height:20px; flex:none; color:var(--cd-red); }
.assistant-attachment { min-width:0; min-height:58px; display:grid; grid-template-columns:48px minmax(0,1fr) 44px; align-items:center; gap:9px; }
.assistant-attachment > a { width:48px; height:48px; display:block; overflow:hidden; border-radius:6px; background:#eef0f2; }
.assistant-attachment img { width:100%; height:100%; display:block; object-fit:cover; }
.assistant-attachment > span { min-width:0; }
.assistant-attachment strong,.assistant-attachment small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.assistant-attachment strong { font-size:12px; }
.assistant-attachment small { margin-top:2px; color:var(--cd-muted); font-size:11px; }
.assistant-attachment > button { width:44px; height:44px; padding:0; display:grid; place-items:center; border:0; border-radius:7px; background:transparent; color:var(--cd-muted); }
.assistant-attachment > button:hover,.assistant-attachment > button:active { background:#f6f7f8; color:var(--cd-ink); }
.assistant-attachment > button .ui-icon { width:20px; height:20px; }
.assistant-image-status,.assistant-image-error,.assistant-image-note { margin:0; font-size:12px; line-height:1.35; }
.assistant-image-status,.assistant-image-note { color:var(--cd-muted); }
.assistant-image-error { color:var(--cd-red-dark); }
.assistant-message-photo { width:min(180px,100%); margin-bottom:7px; display:block; overflow:hidden; border-radius:6px; background:#eef0f2; }
.assistant-message-photo img { width:100%; height:auto; max-height:160px; display:block; object-fit:contain; }
.assistant-message-text { display:block; white-space:pre-wrap; overflow-wrap:anywhere; }
.assistant-view:has(.message) { grid-template-rows:auto minmax(0,1fr); }
.assistant-view:has(.message) .assistant-intro,
.assistant-view:has(.message) .assistant-prompts { display:none; }
.assistant-view .sources a { color:var(--cd-blue); overflow-wrap:anywhere; }
.assistant-view .sources .assistant-source-current { color:var(--cd-muted); overflow-wrap:anywhere; }
body.keyboard-open .assistant-view { --assistant-nav-reserve:0px; grid-template-rows:auto minmax(0,1fr); }
body.keyboard-open .assistant-view .assistant-intro,
body.keyboard-open .assistant-view .assistant-prompts { display:none; }
body.keyboard-open .assistant-view .assistant-identity img { width:44px; height:44px; }
@media(max-height:650px) {
  .assistant-view:focus-within { grid-template-rows:auto minmax(0,1fr); }
  .assistant-view:focus-within .assistant-intro,
  .assistant-view:focus-within .assistant-prompts { display:none; }
  .assistant-view:focus-within .assistant-identity img { width:44px; height:44px; }
}
.home-spending-breakdown { margin-top:14px; padding-top:10px; border-top:1px solid var(--cd-line); }
.spending-bar { width:100%; height:8px; display:block; overflow:hidden; border-radius:4px; background:#eef0f2; }
.spending-bar__segment { stroke:none; fill:#717981; }
.spending-bar__segment.fuel { fill:#287fb2; }
.spending-bar__segment.maintenance { fill:#ec1c24; }
.spending-bar__segment.repair { fill:#9a3f42; }
.spending-bar__segment.parts { fill:#5d6670; }
.spending-bar__segment.insurance { fill:#087b52; }
.spending-bar__segment.wash { fill:#46a9c9; }
.spending-bar__segment.other { fill:#858b91; }
.category-dot.fuel { background:#287fb2; }
.category-dot.maintenance { background:#ec1c24; }
.category-dot.repair { background:#9a3f42; }
.category-dot.parts { background:#5d6670; }
.category-dot.insurance { background:#087b52; }
.category-dot.wash { background:#46a9c9; }
.category-dot.other { background:#858b91; }
.home-spending-breakdown dl { margin:8px 0 0; display:grid; gap:4px; }
.home-spending-breakdown dl>div { display:flex; justify-content:space-between; gap:12px; font-size:12px; }
.home-spending-breakdown dt { min-width:0; display:flex; align-items:center; gap:6px; color:var(--cd-muted); }
.home-spending-breakdown dd { margin:0; font-weight:650; font-variant-numeric:tabular-nums; }
.category-dot { width:7px; height:7px; flex:none; border-radius:50%; background:#717981; }
.legal-details { margin-top:18px; color:var(--cd-muted); font-size:12px; }
.legal-details summary { min-height:44px; display:flex; align-items:center; cursor:pointer; color:var(--cd-blue); font-weight:650; }
.legal-details a { color:var(--cd-blue); }
@media(max-width:370px){.expense-row,.policy-row,.document-row{grid-template-columns:8px minmax(0,1fr) 44px}.expense-row .row-amount{grid-column:2;text-align:left}.expense-row .row-open,.policy-row .row-open,.document-row .row-open{grid-column:3;grid-row:1/3}.detail-total{align-items:flex-start;flex-direction:column}.detail-total strong{text-align:left}.line-item{align-items:flex-start;flex-direction:column}.line-item__aside{max-width:100%;justify-items:start;text-align:left}.detail-actions .button{width:100%}}

/* Client concept composition: calm service-book rows and explicit local context. */
.page-context-back {
  width:max-content;
  min-height:44px;
  margin:-8px 0 2px -10px;
  padding:0 10px;
  display:flex;
  align-items:center;
  gap:4px;
  border:0;
  background:transparent;
  color:var(--cd-blue);
  font-size:13px;
  font-weight:650;
}
.page-context-back .ui-icon { width:17px; height:17px; transform:rotate(180deg); }
.page-head--compact { min-height:44px; display:flex; flex-direction:row; align-items:center; justify-content:space-between; gap:12px; }
.page-head--compact > div { min-width:0; }
.page-head--compact h1 { margin:0; font-size:21px; line-height:1.18; }
.page-head--compact small { display:block; margin-top:3px; color:var(--cd-muted); font-size:12px; }
.page-add-action { flex:none; padding-inline:8px; display:inline-flex; align-items:center; justify-content:center; gap:7px; color:var(--cd-blue); font-weight:700; white-space:nowrap; }
.page-add-action .ui-icon { width:18px; height:18px; flex:none; }
.page-head--with-back {
  display:grid;
  grid-template-columns:36px minmax(0,1fr) auto;
  align-items:center;
  gap:8px;
  min-height:44px;
  margin:0 0 12px;
}
.page-head--with-back > div { min-width:0; }
.page-head--with-back h1 { font-size:20px; margin-bottom:0; }
.page-head--with-back p { margin-top:4px; font-size:12px; }
.page-head--with-back .page-context-back {
  width:44px;
  min-height:44px;
  margin:0;
  padding:0;
  display:grid;
  place-items:center;
}
.assistant-identity .page-context-back { flex:0 0 44px; width:44px; min-height:44px; margin:0; padding:0; display:grid; place-items:center; }
.assistant-identity > div { min-width:0; }
.assistant-identity img { flex:none; }

.history-view { display:grid; gap:10px; }
.history-view .spending-summary {
  margin:0;
  padding:10px 0;
  border-block:1px solid var(--cd-line);
}
.history-view .spending-summary__top { align-items:center; }
.history-view .spending-summary__label { margin:0 0 1px; }
.history-view .spending-summary__total { font-size:22px; line-height:1.15; }
.history-view .spending-summary__top > p { margin:0; white-space:nowrap; }
.history-view .spending-summary__categories { margin-top:7px; gap:5px 14px; max-height:40px; overflow:hidden; }
.history-filters { display:grid; gap:8px; }
.filter-row--compact { grid-template-columns:repeat(3,minmax(0,1fr)); gap:4px; padding:0; }
.filter-row--compact .filter { min-height:44px; padding:7px 6px; font-size:13px; }
.history-selects { grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
.history-selects .filter-select { min-width:0; display:flex; flex-direction:column; align-items:stretch; gap:0; font-size:11px; }
.history-selects select { width:100%; min-height:44px; margin-top:4px; padding:8px 34px 8px 10px !important; background-position:right 10px center !important; font-size:14px; }

.timeline-list { border-top:0; }
.list-row { cursor:pointer; }
.expense-row,.policy-row,.document-row {
  min-height:64px;
  padding:7px 0;
  grid-template-columns:40px minmax(0,1fr) auto 20px;
  align-items:center;
  gap:8px;
  border-bottom:1px solid var(--cd-line);
  border-radius:0;
}
.row-symbol {
  width:38px;
  height:38px;
  display:grid;
  place-items:center;
  border:1px solid #f0b7ba;
  border-radius:7px;
  background:#fff;
  color:var(--cd-red);
}
.row-symbol .ui-icon { width:23px; height:23px; }
.row-symbol.fuel { color:#267daa; border-color:#b8d8e9; }
.row-symbol.insurance { color:var(--cd-green); border-color:#b7dfcf; }
.row-main { min-width:0; }
.row-main strong { display:block; font-size:14px; line-height:1.3; overflow-wrap:break-word; }
.row-main small,.row-main em { display:block; margin-top:2px; color:var(--cd-muted); font-size:11px; line-height:1.3; font-style:normal; }
.row-main em { color:var(--cd-blue); }
.row-merchant { display:block; max-width:100%; margin-top:2px; overflow:hidden; color:var(--cd-muted); font-size:11px; line-height:1.3; text-overflow:ellipsis; white-space:nowrap; }
.row-amount { align-self:center; max-width:98px; font-size:14px; font-weight:750; white-space:nowrap; }
.row-open { width:20px; height:44px; color:#7b838a; }
.row-open svg { width:16px; height:16px; }
.policy-row .row-main,.document-row .row-main { grid-column:2; grid-row:1; }
.policy-row .row-open,.document-row .row-open { grid-column:4; grid-row:1; }

.documents-view,.plan-view { gap:8px; }
.doc-card {
  min-height:70px;
  padding:8px 0;
  grid-template-columns:40px minmax(0,1fr) auto;
  gap:9px;
  cursor:pointer;
}
.doc-card__icon { grid-row:auto; width:38px; height:38px; border:1px solid #f0b7ba; background:#fff; }
.doc-card__body strong { font-size:14px; }
.doc-card__body small { font-size:11px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.doc-card__body em { font-size:11px; }
.doc-card__aside { display:flex; align-items:center; gap:6px; color:#7b838a; }
.doc-card__aside .ui-icon { width:16px; height:16px; }
.doc-card__amount { grid-column:auto; margin:0; font-size:13px; color:var(--cd-ink); }
.plan-list .compact-work { min-height:66px; }
.plan-list .compact-work__icon { border:1px solid #edf0f2; background:#fff; }

.nested-view .tabbar { visibility:visible; pointer-events:auto; }
.nested-view main { padding-bottom:calc(var(--mobile-nav-height) + env(safe-area-inset-bottom) + 18px); }
.detail-head { align-items:center; margin-left:-10px; }
.detail-head h1 { font-size:21px; line-height:1.2; }
.detail-view { gap:16px; }
.detail-actions { padding-top:2px; }

.home-car__visual { height:auto; aspect-ratio:1.9; max-height:220px; }
.home-context-list { margin-top:8px; }
.home-focus-list,.home-spending-breakdown { margin-top:10px; }
.home-spending-breakdown { padding-top:8px; }

.license-plate {
  position:static;
  width:max-content;
  min-height:27px;
  display:inline-grid;
  grid-template-columns:auto 31px;
  align-items:stretch;
  overflow:hidden;
  border:1px solid #25282b;
  border-radius:5px;
  background:#fff;
  color:#151719;
  font-variant-numeric:tabular-nums;
  line-height:1;
  vertical-align:middle;
}
.license-plate > strong { padding:5px 7px 4px; font-size:13px; font-weight:800; letter-spacing:.045em; white-space:nowrap; }
.license-plate__region { min-width:31px; padding:2px 3px; display:grid; place-items:center; border-left:1px solid #25282b; line-height:1; }
.license-plate__region b { font-size:10px; font-weight:800; }
.license-plate__region small { font-size:6px; font-weight:750; letter-spacing:.04em; }
.vehicle-profile-head .license-plate { margin-top:10px; }
.vehicle-facts .license-plate { margin-left:auto; }

.home-plan-section { margin-top:8px; }
.home-plan-section .section-heading,.home-spending-breakdown .section-heading { min-height:40px; margin:0; }
.home-plan-section .section-heading > div,.home-spending-breakdown .section-heading > div { min-width:0; }
.home-spending-breakdown .section-heading strong { display:block; margin-top:1px; font-size:18px; line-height:1.2; }
.home-document-link {
  width:100%;
  min-height:58px;
  margin-top:8px;
  padding:8px 2px;
  display:grid;
  grid-template-columns:36px minmax(0,1fr) 18px;
  align-items:center;
  gap:9px;
  border:0;
  border-top:1px solid var(--cd-line);
  background:#fff;
  color:var(--cd-ink);
  text-align:left;
}
.home-document-link > span:nth-child(2) { min-width:0; }
.home-document-link strong,.home-document-link small { display:block; }
.home-document-link strong { font-size:13px; }
.home-document-link small { margin-top:2px; color:var(--cd-muted); font-size:11px; }
.home-document-link > .ui-icon { width:17px; height:17px; color:var(--cd-blue); }

@media(max-width:370px) {
  .spending-summary__top { flex-direction:column; align-items:flex-start; gap:5px; }
  .spending-summary__top > p { text-align:left; }
  .page-head--compact { align-items:flex-start; }
  .page-head--compact h1 { font-size:20px; }
  .expense-row,.policy-row,.document-row { grid-template-columns:36px minmax(0,1fr) 18px; }
  .expense-row .row-amount { grid-column:2; margin-top:2px; text-align:left; }
  .expense-row .row-open,.policy-row .row-open,.document-row .row-open { grid-column:3; grid-row:1/3; }
  .policy-row .row-main,.document-row .row-main { grid-column:2; grid-row:1; }
  .policy-row .row-open,.document-row .row-open { grid-column:3; grid-row:1; }
  .row-symbol { width:34px; height:34px; }
  .history-selects { grid-template-columns:1fr 1fr; }
  .doc-card { grid-template-columns:36px minmax(0,1fr) auto; }
  .doc-card__icon { width:34px; height:36px; }
  .doc-card__aside { flex-direction:column; align-items:flex-end; gap:2px; }
}

/* History search and date range keep the existing dense instrument layout. */
.history-search {
  position:relative;
  display:grid;
  grid-template-columns:minmax(0,1fr) auto;
  gap:8px;
}
.history-search input { min-width:0; min-height:44px; padding-right:38px; }
.history-search .button { min-height:44px; padding:8px 13px; }
.history-search__clear {
  position:absolute;
  top:0;
  right:72px;
  width:44px;
  height:44px;
  border:0;
  background:transparent;
  color:var(--cd-muted);
  font-size:22px;
}
.history-range { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
.history-range label { color:var(--cd-muted); font-size:11px; font-weight:650; }
.history-range input { width:100%; min-height:44px; margin-top:4px; padding:8px 10px; background:#fff; }
.spending-summary__unknown { margin:7px 0 0; color:var(--cd-muted); font-size:12px; line-height:1.35; }
.spending-summary__total.is-unknown { max-width:210px; font-size:16px; line-height:1.2; }
.line-item__amount { display:grid; justify-items:end; gap:1px; }
.line-item__amount small { margin:0; color:var(--cd-muted); font-size:10px; font-weight:600; line-height:1.2; }
.line-item__amount b { white-space:nowrap; }
.line-item__unknown { max-width:145px; color:var(--cd-muted); font-size:11px; line-height:1.3; text-align:right; }

/* Explicit onboarding choices and completion summary. */
.vehicle-entry__choices { display:grid; gap:10px; }
.vehicle-entry__choice {
  width:100%; min-width:0; min-height:72px; padding:11px 12px;
  display:grid; grid-template-columns:44px minmax(0,1fr) 22px; align-items:center; gap:10px;
  border:1px solid var(--cd-line); border-radius:9px; background:#fff; color:var(--cd-ink); text-align:left;
}
.vehicle-entry__choice:not(:disabled):hover,.vehicle-entry__choice:not(:disabled):active { border-color:var(--red); background:#fff7f7; }
.vehicle-entry__choice:disabled { opacity:.58; cursor:not-allowed; }
.vehicle-entry__choice > span:nth-child(2) { min-width:0; }
.vehicle-entry__choice strong,.vehicle-entry__choice small { display:block; overflow-wrap:anywhere; }
.vehicle-entry__choice strong { font-size:15px; line-height:1.25; }
.vehicle-entry__choice small { margin-top:3px; color:var(--cd-muted); font-size:12px; line-height:1.35; }
.vehicle-entry__choice > .ui-icon { width:18px; height:18px; color:var(--cd-muted); }
.vehicle-entry__icon { width:44px; height:44px; display:grid; place-items:center; border-radius:8px; background:var(--cd-black); color:#fff; }
.vehicle-entry__choice:first-child .vehicle-entry__icon { background:var(--red); }
.vehicle-entry__icon .ui-icon { width:23px; height:23px; }
.vehicle-document__card { display:grid; gap:13px; }
.vehicle-document__error { margin:0; padding:10px 12px; border-radius:7px; background:#fff0f1; }
.vehicle-document__preview { min-width:0; display:grid; grid-template-columns:72px minmax(0,1fr); align-items:center; gap:11px; }
.vehicle-document__preview > a { width:72px; height:72px; display:block; overflow:hidden; border-radius:7px; background:#eef0f2; }
.vehicle-document__preview img { width:100%; height:100%; display:block; object-fit:cover; }
.vehicle-document__preview > span { min-width:0; }
.vehicle-document__preview strong,.vehicle-document__preview small { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.vehicle-document__preview strong { font-size:13px; }
.vehicle-document__preview small,.vehicle-document__status,.vehicle-document__privacy { color:var(--cd-muted); font-size:12px; line-height:1.4; }
.vehicle-document__status,.vehicle-document__privacy { margin:0; }
.vehicle-document__actions { min-width:0; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
.vehicle-document__actions .button { width:100%; min-width:0; min-height:44px; padding-inline:8px; gap:6px; }
.vehicle-document__actions .ui-icon { width:20px; height:20px; flex:none; }
.vehicle-document__retry { grid-column:1/-1; }
.vehicle-document__manual { width:max-content; max-width:100%; min-height:44px; padding:8px 0; text-align:left; }
.vehicle-document__start { width:100%; min-height:44px; margin-bottom:14px; }
.vehicle-document__start .ui-icon { width:20px; height:20px; }
.vehicle-document__review { margin-bottom:14px; padding:12px; display:grid; gap:5px; border-left:3px solid var(--red); background:#fff5f5; }
.vehicle-document__review strong,.vehicle-document__review span { display:block; }
.vehicle-document__review span,.vehicle-document__review li { color:var(--cd-muted); font-size:12px; line-height:1.4; }
.vehicle-document__review ul { margin:3px 0 0; padding-left:19px; }
.vehicle-document__review .link-button { width:max-content; max-width:100%; min-height:44px; padding:8px 0; text-align:left; }
.wizard-progress--5 { display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); }
.wizard-progress--5 .wizard-progress-step small { font-size:10px; }
@media(max-width:560px) {
  .wizard-shell .wizard-top {
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:start;
    gap:8px;
    margin-bottom:2px;
  }
  .wizard-shell .wizard-top > div { min-width:0; }
  .wizard-shell .wizard-top p { margin:0; font-size:13px; line-height:1.35; }
  .wizard-shell .wizard-top .link-button {
    align-self:start;
    margin:-8px -8px 0 0;
    padding:8px;
    min-height:44px;
  }
  .wizard-shell .wizard-progress { margin:4px 0 10px; gap:6px; }
  .wizard-shell .wizard-card { padding-top:8px; }
}
@media(max-width:430px) {
  .wizard-progress--5 .wizard-progress-step small { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); }
}
.reminder-choice { display:grid; gap:8px; margin:0; padding:0; border:0; }
.reminder-choice label {
  min-height:48px;
  padding:8px 12px;
  display:flex;
  align-items:center;
  gap:10px;
  border:1px solid var(--cd-line);
  border-radius:9px;
  background:#fff;
  color:var(--cd-ink);
  font-size:14px;
  font-weight:650;
}
.reminder-choice input { width:20px; height:20px; min-height:20px; margin:0; accent-color:var(--red); }
.wizard-complete { display:grid; justify-items:start; gap:12px; }
.wizard-complete__mark { width:44px; height:44px; display:grid; place-items:center; border-radius:50%; background:var(--cd-green-soft); color:var(--cd-green); font-size:24px; font-weight:800; }
.wizard-complete h2,.wizard-complete p { margin:0; }
.wizard-summary { width:100%; margin:4px 0; border-top:1px solid var(--cd-line); }
.wizard-summary > div { min-height:44px; padding:9px 0; display:flex; justify-content:space-between; gap:12px; border-bottom:1px solid var(--cd-line); }
.wizard-summary dt { color:var(--cd-muted); }
.wizard-summary dd { margin:0; font-weight:700; text-align:right; }

/* Plan actions remain compact, but every interactive control has a 44 px target. */
.plan-item { border-bottom:1px solid var(--cd-line); }
.plan-item > .compact-work { border-bottom:0; }
.plan-list .compact-work { grid-template-columns:minmax(0,1fr) 44px; gap:0 4px; }
.plan-list .compact-work__primary {
  width:100%; min-width:0; min-height:52px; padding:0;
  display:grid; grid-template-columns:36px minmax(0,1fr) 24px; align-items:center; gap:8px;
  border:0; background:transparent; color:inherit; font:inherit; text-align:left;
}
.plan-list .compact-work__primary:hover,.plan-list .compact-work__primary:active { background:#f6f7f8; }
.plan-list .compact-work__primary .compact-work__open { width:24px; pointer-events:none; }
.plan-list .compact-work__toggle-target { width:44px; height:44px; display:grid; place-items:center; cursor:pointer; }
.plan-list .compact-work__toggle { width:20px; height:20px; min-height:20px; padding:0; margin:0; accent-color:var(--red); cursor:pointer; }
.compact-work__snooze { grid-column:1; min-height:44px; width:max-content; max-width:calc(100% - 44px); margin:-7px 0 0 44px; padding:8px 0; border:0; background:transparent; color:var(--cd-blue); font:inherit; font-size:12px; font-weight:650; text-align:left; }
.task-inline-panel { margin:0 0 10px 44px; padding:12px; display:grid; gap:10px; border:1px solid var(--cd-line); border-radius:9px; background:var(--surface-2); }
.task-inline-panel > :is(strong,p) { margin:0; }
.task-inline-panel > p { color:var(--cd-muted); font-size:12px; line-height:1.4; }
.task-inline-actions { display:flex; flex-wrap:wrap; gap:8px; }
.task-inline-actions .button,.task-inline-actions .text-link { min-height:44px; }
.task-panel-title { display:flex; align-items:center; justify-content:space-between; gap:12px; }
.completion-fields { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
.completion-fields label:last-child { grid-column:1/-1; }
.completion-fields label,.snooze-form label { color:var(--cd-muted); font-size:12px; font-weight:650; }
.completion-fields input,.snooze-form input { width:100%; min-height:44px; margin-top:4px; background:#fff; }
.completion-form > .button { width:100%; }
.snooze-form { grid-template-columns:minmax(0,1fr); }

@media(max-width:370px) {
  .vehicle-document__actions { grid-template-columns:minmax(0,1fr); }
  .vehicle-document__retry { grid-column:auto; }
  .wizard-shell--step-4 .wizard-top {
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    align-items:start;
    gap:8px;
    margin-bottom:4px;
  }
  .wizard-shell--step-4 .wizard-top h1 { margin-bottom:2px; font-size:22px; }
  .wizard-shell--step-4 .wizard-top .link-button { margin:-5px -8px 0 0; }
  .wizard-shell--step-4 .wizard-progress { margin:6px 0 9px; }
  .wizard-shell--step-4 .wizard-card { padding-top:7px; }
  .wizard-shell--step-4 .wizard-card h2 { margin-bottom:4px; font-size:20px; }
  .wizard-shell--step-4 .wizard-card > p { margin-bottom:0; font-size:13px; line-height:1.35; }
  .wizard-shell--step-4 .wizard-form { margin-top:9px; gap:8px; }
  .wizard-shell--step-4 .reminder-choice { gap:6px; }
  .wizard-shell--step-4 .reminder-choice label { min-height:44px; padding:6px 10px; }
  .wizard-shell--step-4 .form-actions { margin-top:0; }
  .history-search { grid-template-columns:1fr; }
  .history-search .button { width:100%; }
  .history-search__clear { right:0; }
  .history-range,.completion-fields { grid-template-columns:1fr; }
  .completion-fields label:last-child { grid-column:auto; }
  .wizard-progress--5 .wizard-progress-step small { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); }
  .task-inline-panel { margin-left:0; }
  .task-inline-actions { display:grid; }
  .task-inline-actions .button { width:100%; }
  .line-item__amount { justify-items:start; }
}

/* Launch account, export, and retry states. */
.account-token-view .topbar,
.account-token-view .tabbar,
.account-token-view .site-footer { display:none; }
.account-token-view main {
  min-height:100dvh;
  padding:max(28px, env(safe-area-inset-top)) var(--mobile-gutter) max(28px, env(safe-area-inset-bottom));
  display:grid;
  align-items:center;
}
.history-export,
.account-export {
  border-block:1px solid var(--cd-line);
  background:#fff;
}
.history-export { margin:0 0 2px; }
.history-export summary {
  min-height:44px;
  display:flex;
  align-items:center;
  gap:9px;
  cursor:pointer;
  color:var(--cd-blue);
  font-size:13px;
  font-weight:700;
}
.history-export summary .ui-icon { width:20px; height:20px; }
.history-export p,
.account-export p,
.capability-note { margin:0; color:var(--cd-muted); font-size:12px; line-height:1.45; }
.history-export p { padding:0 0 10px; max-width:68ch; }
.history-export .button { width:100%; margin:0 0 12px; }
.account-export { padding:14px 0; display:grid; gap:12px; }
.account-export h2 { margin:0 0 4px; font-size:16px; }
.account-export .button { width:100%; }
.verification-row { margin-top:9px; display:flex; flex-wrap:wrap; align-items:center; gap:8px; }
.verification-row .button { width:100%; }
.verification-state {
  min-height:28px;
  padding:5px 9px;
  display:inline-flex;
  align-items:center;
  border-radius:999px;
  background:var(--cd-amber-soft);
  color:var(--cd-amber);
  font-size:12px;
  font-weight:700;
}
.verification-state.is-verified { background:var(--cd-green-soft); color:var(--cd-green); }
.auth-notice {
  min-height:44px;
  margin:0;
  padding:10px 12px;
  display:flex;
  align-items:center;
  border-radius:9px;
  background:var(--cd-green-soft);
  color:#075f41;
  font-size:13px;
}
.token-card > form { display:grid; gap:12px; }
.token-card > .link-button { width:100%; margin-top:4px; }
.chat-retry {
  min-height:44px;
  margin:8px -8px -6px;
  padding:8px;
  display:block;
  border:0;
  background:transparent;
  color:var(--cd-blue);
  font:inherit;
  font-size:13px;
  font-weight:750;
  text-align:left;
}
.chat-retry:disabled { opacity:.55; }

@media(min-width:560px) {
  .account-export { grid-template-columns:minmax(0,1fr) auto; align-items:center; }
  .account-export .button { width:auto; }
  .verification-row .button { width:auto; }
  .history-export .button { width:auto; }
}
