html,
body {
  height: 100%;
  overflow: hidden;
}

:root {
  --brand: #d6092f;
  --brand-dark: #a30016;
  --spectrum: linear-gradient(90deg, #6b2f93 0%, #f0118f 100%);
  --ink: #172033;
  --muted: #667085;
  --line: #dfe3ea;
  --panel: #ffffff;
  --page: #f5f7fb;
  --soft-red: #fff1f3;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--page);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.5;
}

.bg {
  height: 100vh;
  padding: 10px 0 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.top {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px 8px;
  text-align: center;
  flex: 0 0 auto;
}

.top img {
  display: block;
  width: min(100%, 760px);
  height: auto;
  max-height: 92px;
  margin: 0 auto;
  object-fit: contain;
}

.wrap {
  width: min(1120px, calc(100vw - 24px));
  height: calc(100vh - 132px);
  margin: 0 auto;
  padding: 14px 20px 18px;
  background:
    linear-gradient(#fff, #fff) padding-box,
    linear-gradient(90deg, #6b2f93 0%, #f0118f 35%, #ff1e1e 68%, #111 100%) border-box;
  border: 3px solid transparent;
  border-radius: 28px;
  box-shadow: 0 18px 44px rgba(23, 32, 51, 0.09);
  overflow: hidden;
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
}

#fnolForm {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
  width: 100%;
}

.sessionNote {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: nowrap;
  gap: 12px;
  align-self: stretch;
  margin: 0 0 8px;
  padding: 6px 10px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(223, 227, 234, 0.9);
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.sessionLabel {
  flex: 1;
  min-width: 0;
}

.sessionActions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  flex-shrink: 0;
  white-space: nowrap;
}

.logoutLink {
  padding: 4px 10px;
  color: var(--brand-dark);
  background: rgba(240, 17, 143, 0.08);
  border: 1px solid rgba(240, 17, 143, 0.18);
  border-radius: 999px;
  text-decoration: none;
  white-space: nowrap;
}

.logoutLink:hover {
  color: #fff;
  background: var(--spectrum);
  border-color: transparent;
}

.progress {
  flex: 0 0 auto;
  height: 7px;
  margin: 0 0 12px;
  overflow: hidden;
  background: #e8ecf3;
  border-radius: 999px;
}

.stepNav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 12px;
  padding: 8px 0 2px;
  position: sticky;
  top: 0;
  z-index: 3;
  background: linear-gradient(#fff, #fff);
}

.stepMarker {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  min-height: 40px;
  padding: 0 12px;
  color: var(--brand-dark);
  background: linear-gradient(#fff, #fff) padding-box, var(--spectrum) border-box;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.stepMarker span {
  display: inline-grid;
  place-items: center;
  width: 20px;
  height: 20px;
  color: #fff;
  background: var(--spectrum);
  border-radius: 999px;
  font-size: 11px;
  line-height: 1;
}

.stepMarker.current {
  color: #fff;
  background: var(--spectrum);
}

.stepMarker.current span {
  color: var(--brand-dark);
  background: #fff;
}

.stepMarker.complete {
  opacity: 0.95;
}

.stepMarker.locked {
  opacity: 0.45;
}

.progress b {
  display: block;
  width: 0;
  height: 100%;
  background: var(--brand);
  transition: width 0.2s ease;
}

.card {
  padding: 18px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 12px 32px rgba(23, 32, 51, 0.08);
}

.welcomeCard {
  max-width: 700px;
  margin: 0 auto;
}

.welcomeLead {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 700;
}

.welcomeCopy {
  margin: 0 0 18px;
  color: var(--muted);
}

.startFnolBtn {
  min-width: 180px;
  color: #fff !important;
  background: var(--spectrum) !important;
  border-color: transparent !important;
}

.startFnolBtn:hover {
  filter: brightness(1.05);
}

body.authPage {
  font-family: Inter, "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
  overflow: auto;
  background:
    radial-gradient(circle at top, rgba(240, 17, 143, 0.12), transparent 36%),
    radial-gradient(circle at 20% 20%, rgba(107, 47, 147, 0.08), transparent 24%),
    var(--page);
}

body.authPage .bg {
  justify-content: center;
  min-height: 100vh;
  padding: 18px 0 22px;
}

body.authPage .top img {
  width: min(100%, 1100px);
  max-height: 170px;
}

body.authPage .wrap {
  width: min(1260px, calc(100vw - 24px));
  height: auto;
  min-height: 0;
  flex: 0 0 auto;
  padding: 0;
  background: transparent;
  border: 0;
  box-shadow: none;
}

body.authPage .authCard {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
  padding: 0;
  overflow: hidden;
  border-radius: 28px;
  border: 3px solid transparent;
  background:
    linear-gradient(#fff, #fff) padding-box,
    linear-gradient(90deg, #6b2f93 0%, #f0118f 100%) border-box;
  box-shadow: 0 18px 44px rgba(23, 32, 51, 0.12);
}

body.authPage .authBrand,
body.authPage .authAction {
  padding: 28px 34px;
}

body.authPage .authBrand {
  border-right: 0;
  background: #fff;
  text-align: center;
}

body.authPage .authBrand h1 {
  margin: 0 auto 8px;
  max-width: none;
  white-space: nowrap;
  font-size: clamp(18px, 1.9vw, 30px);
  line-height: 1.02;
  letter-spacing: -0.01em;
}

body.authPage .authAction {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding-top: 0;
}

body.authPage .authAction .startFnolBtn {
  min-width: 220px;
  min-height: 52px;
  align-self: center;
}

body.authPage .authIntro {
  margin: 0;
  color: var(--muted);
  font-size: 16px;
  font-weight: 600;
}

.step {
  display: none;
}

.step.active {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-gutter: stable;
  padding-right: 4px;
}

.stepVehicle.active {
  overflow: hidden;
  padding-right: 0;
}

.stepHeader {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 8px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.accountNotice {
  align-self: flex-end;
  margin: 0 0 14px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

.accountNotice.cash {
  border-color: rgba(148, 163, 184, 0.45);
}

.accountNotice.fleet {
  border-color: rgba(16, 185, 129, 0.35);
}

.accountNotice.assist {
  border-color: rgba(217, 70, 239, 0.35);
}

.adminPage .wrap {
  max-width: 1400px;
  min-height: 0;
  height: auto;
  padding-bottom: 12px;
}

.adminShell {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
  height: auto;
  overflow: visible;
}

.adminHead {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.adminForm {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.adminTabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  padding: 6px;
  border: 1px solid rgba(223, 227, 234, 0.9);
  background: rgba(255, 255, 255, 0.7);
  border-radius: 18px;
}

.adminTab {
  border: 1px solid transparent;
  background: transparent;
  color: var(--ink);
  padding: 10px 14px;
  border-radius: 12px;
  font-weight: 700;
  transition: all 0.18s ease;
}

.adminTab.active {
  background: var(--spectrum);
  color: #fff;
  border-color: transparent;
  box-shadow: 0 8px 16px rgba(128, 45, 169, 0.18);
}

.adminTab:not(.active):hover {
  background: rgba(217, 70, 239, 0.08);
}

.adminPanels {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  overflow: hidden;
}

.adminPanel {
  display: none;
  flex-direction: column;
  gap: 12px;
  min-height: 0;
  overflow: hidden;
  padding-top: 4px;
}

.adminPanel.active {
  display: flex;
  flex: 1;
  overflow: auto;
  padding-right: 4px;
}

.adminMiniForm {
  padding-top: 6px;
}

.adminActions {
  display: flex;
  justify-content: flex-end;
}

.adminModal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.45);
  z-index: 50;
  padding: 24px;
}

.adminModal.open {
  display: flex;
  align-items: center;
  justify-content: center;
}

.adminModalCard {
  width: min(640px, 100%);
  max-height: 100%;
  overflow: auto;
  background: #fff;
  border-radius: 20px;
  border: 1px solid rgba(223, 227, 234, 0.95);
  box-shadow: 0 24px 80px rgba(15, 23, 42, 0.25);
  padding: 16px;
}

.adminModalNarrow {
  width: min(560px, 100%);
  padding: 12px;
}

.adminModalHead {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.adminModalClose {
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: 0;
  background: rgba(15, 23, 42, 0.08);
  color: var(--ink);
  font-size: 22px;
  line-height: 1;
}

.adminTable {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 9px;
  border: 1px solid rgba(223, 227, 234, 0.95);
  border-radius: 14px;
  overflow: hidden;
  background: #fff;
}

.adminTable th,
.adminTable td {
  padding: 3px 5px;
  border-bottom: 1px solid rgba(223, 227, 234, 0.85);
  border-right: 1px solid rgba(223, 227, 234, 0.55);
  vertical-align: top;
}

.adminTable th:last-child,
.adminTable td:last-child {
  border-right: 0;
}

.adminTable th:nth-child(5),
.adminTable td:nth-child(5) {
  width: 180px;
}

.adminTable th:nth-child(6),
.adminTable td:nth-child(6) {
  width: 84px;
}

.adminTable th:nth-child(7),
.adminTable td:nth-child(7) {
  width: 160px;
}

.adminTable th:nth-child(8),
.adminTable td:nth-child(8) {
  width: 78px;
}

.adminTable td:nth-child(5) .adminInlineBadges {
  overflow: hidden;
}

.adminTable td:nth-child(7) .tableValue {
  max-width: 100%;
}

.adminTable th {
  text-align: left;
  font-size: 10px;
  text-transform: uppercase;
  color: var(--muted);
  position: sticky;
  top: 0;
  background: #fff;
  z-index: 1;
}

.adminTable input[type="text"],
.adminTable input[type="number"],
.adminTable textarea {
  width: 100%;
}

.adminTable textarea {
  min-height: 28px;
  resize: none;
}

.adminInlineChecks {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: nowrap;
  white-space: nowrap;
}

.adminInlineChecks .adminCheck {
  gap: 3px;
  font-size: 9px;
  white-space: nowrap;
}

.adminTable input[type="checkbox"] {
  width: 12px;
  height: 12px;
  transform: none;
  accent-color: var(--brand-dark);
  margin: 0;
}

.warrantyTable {
  table-layout: fixed;
  font-size: 10px;
  border: 1px solid rgba(148, 163, 184, 0.75);
  border-radius: 8px;
}

.warrantyTable th,
.warrantyTable td {
  padding: 2px 4px;
  white-space: nowrap;
  vertical-align: middle;
  border: 1px solid rgba(223, 227, 234, 0.95);
}

.warrantyTable input {
  width: 100%;
  height: 24px;
  padding: 2px 6px;
  font-size: 11px;
}

.warrantyTable .rowEditBtn {
  min-height: 24px;
  padding: 2px 6px;
  font-size: 10px;
}

.warrantyTable th:nth-child(2),
.warrantyTable td:nth-child(2) {
  width: 105px;
}

.warrantyTable th:nth-child(3),
.warrantyTable td:nth-child(3) {
  width: 62px;
}

.warrantyActions {
  gap: 8px;
  margin-top: 10px;
}

.faultSearchResults {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 8px;
  margin: 10px 0;
}

.faultResult {
  min-height: 0;
  padding: 10px;
  display: block;
  text-align: left;
  color: var(--ink);
  background: #fff;
  border: 1px solid #d8dee9;
  border-radius: 10px;
}

.faultResult b,
.faultResult span {
  display: block;
}

.faultResult span {
  margin-top: 3px;
  color: var(--muted);
  font-size: 12px;
}

.adminCheck input[type="checkbox"],
.adminModal input[type="checkbox"] {
  width: 12px;
  height: 12px;
  transform: none;
  accent-color: var(--brand-dark);
  margin: 0;
}

.adminTable td {
  vertical-align: middle;
}

.adminTableScroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  max-height: calc(100vh - 320px);
}

.adminTable td:nth-child(2),
.adminTable td:nth-child(3),
.adminTable td:nth-child(4),
.adminTable td:nth-child(7),
.adminTable td:nth-child(8),
.adminTable td:nth-child(9) {
  white-space: nowrap;
}

.tableValue {
  display: inline-block;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tableNote {
  max-width: 180px;
}

.statusBadge,
.flagBadge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 18px;
  padding: 0 7px;
  border-radius: 999px;
  font-size: 9px;
  font-weight: 700;
  border: 1px solid transparent;
}

.statusBadge.on,
.flagBadge.on {
  background: rgba(16, 185, 129, 0.12);
  color: #0f7a55;
  border-color: rgba(16, 185, 129, 0.18);
}

.statusBadge.off,
.flagBadge.off {
  background: rgba(148, 163, 184, 0.10);
  color: #64748b;
  border-color: rgba(148, 163, 184, 0.18);
}

.adminInlineBadges {
  display: flex;
  align-items: center;
  gap: 4px;
  flex-wrap: nowrap;
  white-space: nowrap;
}

.rowEditBtn {
  min-width: 56px;
  height: 24px;
  padding: 0 12px;
  border-radius: 999px;
  border: 1px solid rgba(217, 70, 239, 0.22);
  background: rgba(255,255,255,0.95);
  color: var(--ink);
  font-size: 10px;
  font-weight: 700;
}

.adminCenter {
  text-align: center;
}

.adminCheck {
  display: flex;
  align-items: center;
  gap: 4px;
  font-weight: 600;
}

.adminCheck input[type="checkbox"] {
  width: 12px;
  height: 12px;
  accent-color: var(--brand-dark);
  margin: 0;
}

body.adminPage {
  overflow: hidden;
}

body.adminPage .bg {
  height: 100vh;
  overflow: hidden;
}

body.adminPage .wrap {
  height: calc(100vh - 148px);
  overflow: hidden;
}

body.adminPage .adminShell {
  height: 100%;
  overflow: hidden;
}

body.adminPage .adminTableScroll {
  max-height: none;
  overflow: auto;
}

.stepHeader span {
  display: none;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2 {
  margin-bottom: 0;
  color: var(--ink);
}

label {
  display: block;
  margin: 12px 0 6px;
  color: #2d3748;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  min-height: 46px;
  padding: 11px 12px;
  color: var(--ink);
  background: #fff;
  border: 1px solid #cfd6e1;
  border-radius: 8px;
  font: inherit;
}

textarea {
  min-height: 108px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  outline: 3px solid rgba(214, 9, 47, 0.16);
  border-color: var(--brand);
}

button,
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  color: #fff;
  background: var(--spectrum);
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  font: inherit;
  font-weight: 700;
  text-decoration: none;
  transition: transform 0.16s ease, filter 0.16s ease;
}

button:hover,
.btn:hover {
  transform: translateY(-1px);
  filter: saturate(1.05) brightness(1.04);
}

button:disabled,
.btn:disabled {
  cursor: not-allowed;
  opacity: 0.55;
  transform: none;
}

.btn.secondary,
button.secondary {
  color: var(--ink);
  background:
    linear-gradient(#fff, #fff) padding-box,
    var(--spectrum) border-box;
  border: 1px solid transparent;
}

.btn.secondary:hover,
button.secondary:hover {
  color: var(--ink);
  background:
    linear-gradient(#fff, #fff) padding-box,
    var(--spectrum) border-box;
}

.actionRow button.secondary[onclick="goBack()"],
.actionRow button.historyBack {
  color: var(--ink);
  background:
    linear-gradient(#fff, #fff) padding-box,
    var(--spectrum) border-box;
  border: 1px solid transparent;
  box-shadow: none;
  font-weight: 700;
}

.actionRow button.secondary[onclick="goBack()"]:hover,
.actionRow button.historyBack:hover {
  color: var(--ink);
  background:
    linear-gradient(#fff, #fff) padding-box,
    var(--spectrum) border-box;
}

.actionRow button.secondary[onclick="restartFnol()"] {
  color: var(--muted);
  background:
    linear-gradient(#fff, #fff) padding-box,
    var(--spectrum) border-box;
  border: 1px solid transparent;
  box-shadow: none;
  font-weight: 600;
}

.actionRow button.secondary[onclick="restartFnol()"]:hover {
  color: var(--brand-dark);
  background:
    linear-gradient(#fff, #fff) padding-box,
    var(--spectrum) border-box;
  transform: none;
}

.muted {
  color: var(--muted);
}

.hide {
  display: none !important;
}

.grid {
  display: grid;
  gap: 12px;
}

.grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.choiceGrid {
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  margin-top: 12px;
}

.choiceGrid .tile {
  white-space: nowrap;
}

.tile {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 64px;
  padding: 16px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  transition: border-color 0.16s ease, box-shadow 0.16s ease;
}

.tile input {
  width: auto;
  min-height: 0;
}

.tile:hover {
  border-color: var(--brand);
  box-shadow: 0 8px 20px rgba(23, 32, 51, 0.08);
}

.tile.disabled {
  position: relative;
  cursor: not-allowed;
  opacity: 0.52;
}

.tile.disabled:hover {
  border-color: var(--line);
  box-shadow: none;
}

.tile.disabled[data-tooltip]:hover::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  top: -10px;
  transform: translate(-50%, -100%);
  z-index: 20;
  width: min(460px, calc(100vw - 48px));
  padding: 10px 14px;
  color: #fff;
  background: rgba(23, 32, 51, 0.96);
  border-radius: 14px;
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.24);
  font-size: 12px;
  line-height: 1.35;
  text-align: center;
  white-space: normal;
  pointer-events: none;
}

.dangerTile {
  background: var(--soft-red);
}

.scriptBox,
.banner,
.lookupBox,
.selectedLocationBox,
.summaryBox {
  padding: 12px 14px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.lookupCard {
  margin-top: 14px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(223, 227, 234, 0.9);
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.08);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
}

.lookupCard.ok {
  border-color: rgba(34, 197, 94, 0.32);
}

.lookupCard.warn {
  border-color: rgba(245, 158, 11, 0.32);
}

.lookupCard.confirmed {
  border-color: rgba(34, 197, 94, 0.6);
  box-shadow: 0 18px 46px rgba(34, 197, 94, 0.12);
}

.lookupCard.needs-review {
  border-color: rgba(225, 29, 72, 0.55);
  box-shadow: 0 18px 46px rgba(225, 29, 72, 0.12);
}

.lookupCard .lookupTitle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.lookupCard .lookupTitle h3 {
  margin: 0;
  font-size: 18px;
}

.lookupCard .lookupStatus {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: 999px;
  font-weight: 700;
  white-space: nowrap;
}

.lookupCard .lookupStatus.ok {
  color: #166534;
  background: #ecfdf3;
}

.lookupCard .lookupStatus.bad {
  color: #b42318;
  background: #fef3f2;
}

.lookupCardGrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 6px;
}

.customerAddressBox {
  margin-top: 12px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(223, 227, 234, 0.9);
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(15, 23, 42, 0.08);
}

.addressSuggestions {
  margin-top: 8px;
  display: grid;
  gap: 8px;
}

.addressSuggestions.hide {
  display: none;
}

.addressSuggestion {
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(223, 227, 234, 0.9);
  background: #fff;
  color: var(--ink);
  box-shadow: none;
}

.addressSuggestion:hover {
  background: rgba(246, 239, 253, 0.95);
}

.customerAddressHeader {
  margin-bottom: 10px;
}

.customerAddressHeader span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.customerAddressHeader strong {
  display: block;
  margin-top: 4px;
  color: var(--ink);
  font-size: 15px;
}

.customerAddressBox iframe {
  width: 100%;
  height: 180px;
  border: 0;
  border-radius: 12px;
}

.lookupField {
  padding: 8px 10px;
  background: rgba(248, 250, 252, 0.9);
  border: 1px solid rgba(223, 227, 234, 0.85);
  border-radius: 12px;
}

.lookupField span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.lookupField b {
  display: block;
  margin-top: 4px;
  color: var(--ink);
  font-size: 15px;
}

.lookupHint {
  margin: 8px 0 0;
  color: var(--muted);
  font-weight: 600;
}

.lookupActions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 8px;
}

.lookupActions button {
  min-width: 0;
}

.lookupDecision {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: 100%;
  min-height: 46px;
  padding: 4px 8px;
  color: #fff;
  border: 0;
  border-radius: 16px;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.10);
  transition: transform 0.16s ease, box-shadow 0.16s ease;
}

.lookupDecision span {
  display: block;
  line-height: 1;
  font-size: clamp(16px, 1.8vw, 22px);
  font-weight: 900;
}

.lookupDecision small {
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.lookupDecision.yes {
  background: #19c963;
}

.lookupDecision.no {
  background: #f43b46;
}

.lookupDecision:hover {
  transform: translateY(-2px);
}

.lookupDecision:active {
  transform: translateY(0);
}

.lookupActions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
  margin-top: 18px;
}

.lookupActions button {
  max-width: 100%;
}

.vehicleContinue {
  display: block;
  margin: 12px 0 0 auto;
  min-width: 150px;
}

.scriptBox {
  font-size: 17px;
}

.banner {
  margin: 16px 0;
}

.banner.info {
  background: #eef6ff;
  border-color: #bdd7f5;
}

.banner.warn {
  background: #fff7e6;
  border-color: #f3d19c;
}

.banner.ok {
  background: #edf9f1;
  border-color: #b7e2c2;
}

.banner.danger,
.modal.critical .box {
  background: var(--soft-red);
  border-color: rgba(214, 9, 47, 0.25);
}

.segmented {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 4px;
  background:
    linear-gradient(#fff, #fff) padding-box,
    var(--spectrum) border-box;
  border: 1px solid transparent;
  border-radius: 8px;
}

.segmented button {
  min-height: 38px;
  color: var(--brand-dark);
  background: transparent;
  border-color: transparent;
}

.segmented button.active {
  color: #fff;
  background: var(--spectrum);
  border-color: transparent;
}

.warrantyGuide {
  margin: 16px 0;
  padding: 14px 16px;
  color: #2d3748;
  background: #fbfcfe;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.warrantyGuide p {
  margin: 8px 0 12px;
  color: var(--muted);
}

.warrantyGuideGrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.warrantyGuide ul {
  margin: 8px 0 0;
  padding-left: 20px;
}

.warrantyGuide li {
  margin: 4px 0;
}

.counter {
  display: grid;
  grid-template-columns: 46px 1fr 46px;
  gap: 8px;
}

.counter input {
  text-align: center;
}

.counter button {
  padding: 0;
}

.vrn,
.miniVrn {
  font-weight: 800;
  font-family: "Arial Black", "Impact", system-ui, sans-serif;
  letter-spacing: 0;
  text-transform: uppercase;
}

.vrn {
  padding: 18px 20px;
  color: #111;
  text-align: center;
  font-size: 34px;
  font-weight: 900;
  letter-spacing: 0.14em;
  background: linear-gradient(180deg, #ffe64d 0%, #ffd500 100%);
  border: 2px solid #222;
  border-radius: 10px;
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.28), 0 10px 24px rgba(15, 23, 42, 0.08);
}

.vrn::placeholder {
  color: rgba(17, 17, 17, 0.45);
}

.vrn.invalid {
  border-color: #e11d48;
  outline: 3px solid rgba(225, 29, 72, 0.15);
  background: #fff7f8;
}

.vrn.valid {
  border-color: #16a34a;
  outline: 3px solid rgba(22, 163, 74, 0.12);
}

.locationSearchRow {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: end;
}

#step8.card {
  padding: 12px;
}

#step8 .banner,
#step8 .selectedLocationBox,
#step8 .livePanel {
  margin-top: 8px;
  margin-bottom: 8px;
}

.locationMapRow {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 16px;
  align-items: stretch;
}

.locationMap {
  display: grid;
  min-height: 210px;
  margin: 8px 0;
  place-items: center;
  background: #eef1f6;
  border: 1px dashed #b8c0cc;
  border-radius: 8px;
}

.locationSmsPanel {
  margin: 8px 0;
  align-items: flex-start;
  flex-direction: column;
  justify-content: center;
}

.locationMap iframe {
  width: 100%;
  min-height: 210px;
  border: 0;
  border-radius: 8px;
}

.locationMap > div:not(.mapPlaceholder) {
  width: 100%;
  min-height: 210px;
  border-radius: 8px;
}

.mapPlaceholder {
  color: var(--muted);
  text-align: center;
}

.livePanel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin: 16px 0;
  padding: 16px;
  background: #fbfcfe;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.smsModal {
  backdrop-filter: blur(8px);
  background: rgba(15, 23, 42, 0.42);
}

.smsModal.hide {
  display: none;
}

.smsModalBox {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  width: min(980px, calc(100vw - 32px));
  max-width: none;
}

.modal .box.smsModalBox {
  width: min(980px, calc(100vw - 32px));
  max-width: none;
}

.smsStatusGrid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.smsStatusGrid div {
  padding: 14px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.smsStatusGrid span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.smsStatusGrid b {
  display: block;
  margin-top: 6px;
  color: var(--ink);
}

.damageStencil {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 10px;
  min-height: 180px;
  margin: 12px 0;
  padding: 12px;
  background: #f8fafc;
  border: 1px dashed #b8c0cc;
  border-radius: 8px;
}

.damageZone {
  min-height: 44px;
  padding: 10px 12px;
  color: var(--text);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.damageZone.active {
  color: #fff;
  background: var(--brand);
  border-color: var(--brand);
}

.smallCard {
  margin-top: 16px;
  box-shadow: none;
}

.emailBig {
  color: var(--brand-dark);
  font-size: 20px;
  font-weight: 800;
}

.actionRow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 12px;
  margin-top: 8px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  flex: 0 0 auto;
}

.actionRow button {
  min-width: 126px;
}

.actionRow button:not(.secondary) {
  margin-left: auto;
  min-width: 150px;
}

.actionRow button:only-child {
  margin-left: auto;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(15, 23, 42, 0.58);
}

.modal .box {
  width: min(620px, 100%);
  padding: 28px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 18px 60px rgba(15, 23, 42, 0.24);
}

.pac-container {
  z-index: 99999 !important;
}

.modalActions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 20px;
}

.modalActions button {
  min-width: 150px;
}

.modal.critical .box {
  background: var(--soft-red);
  border-color: rgba(214, 9, 47, 0.25);
}

@media (max-width: 760px) {
  .bg {
    height: auto;
    min-height: 100vh;
  }

  body.authPage .bg {
    padding: 12px 0 16px;
  }

  .top,
  .wrap {
    padding-left: 16px;
    padding-right: 16px;
  }

  .wrap {
    width: calc(100vw - 16px);
    height: auto;
    min-height: calc(100vh - 122px);
  }

  body.authPage .wrap {
    width: calc(100vw - 16px);
    min-height: 0;
  }

  body.authPage .authCard {
    grid-template-columns: 1fr;
  }

  body.authPage .authBrand {
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
    padding: 22px 20px 16px;
  }

  body.authPage .authAction {
    padding: 22px 20px 24px;
  }

  body.authPage .authAction .startFnolBtn {
    width: 100%;
    align-self: stretch;
  }

  .card {
    padding: 14px;
  }

  .top img {
    width: min(100%, 520px);
    max-height: 64px;
  }

  .stepHeader,
  .livePanel {
    align-items: flex-start;
    flex-direction: column;
  }

  .stepNav {
    gap: 6px;
  }

  .grid.two {
    grid-template-columns: 1fr;
  }

  .warrantyGuideGrid {
    grid-template-columns: 1fr;
  }

  .lookupCardGrid,
  .lookupActions {
    grid-template-columns: 1fr;
  }

  .lookupDecision {
    min-height: 52px;
  }

  .actionRow {
    display: grid;
    grid-template-columns: 1fr;
  }

  .actionRow button,
  .actionRow button:not(.secondary),
  .actionRow button:only-child {
    width: 100%;
    margin-left: 0;
  }
}


.rtcOperatorGrid {
  display: grid;
  grid-template-columns: minmax(360px, 1fr) minmax(360px, 0.95fr);
  gap: 18px;
  align-items: start;
}

.rtcQuestions,
.rtcDamagePanel {
  padding: 16px;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 18px;
}

.rtcQuestions h3,
.rtcDamagePanel h3 {
  margin: 0 0 4px;
}

.damageCanvasWrap {
  width: 100%;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 16px;
}

#damageCanvas {
  display: block;
  width: 100%;
  height: auto;
  min-height: 260px;
  touch-action: none;
  cursor: crosshair;
}

.damageToolbar {
  display: flex;
  justify-content: flex-end;
  margin: 10px 0;
}

@media (max-width: 980px) {
  .rtcOperatorGrid {
    grid-template-columns: 1fr;
  }
}


#step10.step.active {
  overflow: hidden;
}

#step10 .rtcOperatorGrid {
  flex: 1 1 auto;
  min-height: 0;
}

#step10 .rtcQuestions {
  max-height: calc(100vh - 250px);
  overflow-y: auto;
  padding-right: 12px;
}

#step10 .rtcDamagePanel {
  position: sticky;
  top: 0;
}

#step10 textarea {
  min-height: 76px;
}

#step10 .actionRow {
  flex: 0 0 auto;
}

@media (max-width: 980px) {
  #step10.step.active {
    overflow-y: auto;
  }

  #step10 .rtcQuestions {
    max-height: none;
    overflow: visible;
  }

  #step10 .rtcDamagePanel {
    position: static;
  }
}


#step10 {
  gap: 12px;
}

#step10 .rtcOperatorGrid {
  max-height: calc(100vh - 330px);
  overflow: hidden;
}

#step10 .rtcQuestions {
  max-height: 100%;
  padding-bottom: 18px;
}

#step10 .actionRow {
  position: relative;
  z-index: 3;
  margin-top: 0;
  padding-top: 14px;
  background: #fff;
  border-top: 1px solid var(--line);
}


.grid.three {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 980px) {
  .grid.three {
    grid-template-columns: 1fr;
  }
}


.detailModal .box {
  max-height: calc(100vh - 80px);
  overflow-y: auto;
}


#step10 .compactQuestionRow {
  align-items: end;
  margin-top: 8px;
}

#step10 .compactQuestionRow label {
  margin-top: 0;
}


#rtcDetailsModal .box {
  width: min(900px, calc(100vw - 32px));
}


#step10 .rtcOperatorGrid {
  grid-template-columns: 1fr;
}

#step10 .rtcQuestions {
  max-height: none;
  overflow: visible;
}

.damageModalBox {
  width: min(1120px, calc(100vw - 32px)) !important;
  max-width: none !important;
}

.damageModalGrid {
  display: grid;
  grid-template-columns: minmax(320px, 0.8fr) minmax(420px, 1.2fr);
  gap: 18px;
  align-items: start;
}

.modalDamagePanel {
  position: static !important;
}

@media (max-width: 900px) {
  .damageModalGrid {
    grid-template-columns: 1fr;
  }
}

.adminModalCard.adminModalNarrow {
  width: min(760px, 96vw);
  padding: 10px;
}

.adminModalNarrow .adminModalHead {
  margin-bottom: 6px;
}

.adminModalNarrow .adminModalHead h2 {
  font-size: 18px;
}

.adminModalNarrow .warrantyTable {
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 10px;
}

.adminModalNarrow .warrantyTable th,
.adminModalNarrow .warrantyTable td {
  height: 22px;
  padding: 1px 3px;
  border: 1px solid #cfd6e1;
  white-space: nowrap;
}

.adminModalNarrow .warrantyTable input {
  min-height: 0;
  height: 20px;
  padding: 1px 4px;
  border-radius: 0;
  font-size: 10px;
}

.adminModalNarrow .warrantyTable .rowEditBtn {
  min-height: 0;
  height: 20px;
  padding: 0 6px;
  border-radius: 0;
  font-size: 9px;
}

.adminModalNarrow .warrantyActions button {
  min-height: 28px;
  padding: 0 10px;
  font-size: 11px;
}

.emailBuilderGrid {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 18px;
}

.emailBuilder aside {
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  padding: 16px;
}

.emailBlockPalette button {
  width: 100%;
  margin: 0 0 8px 0;
}

.emailCanvas {
  min-height: 220px;
  border: 2px dashed #d1d5db;
  border-radius: 16px;
  padding: 12px;
  margin-top: 14px;
  background: #f9fafb;
}

.emailBlock {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 14px;
  margin-bottom: 12px;
  cursor: grab;
}

.emailBlockHead,
.emailRow {
  display: flex;
  align-items: center;
  gap: 10px;
}

.emailBlockHead {
  justify-content: space-between;
  margin-bottom: 10px;
}

.emailRow {
  margin-bottom: 8px;
}

.emailRow input {
  flex: 1;
}

.emailRow select {
  flex: 1;
}

.emailRemoveRow {
  width: auto;
  min-height: 40px;
}

.emailPreviewFrame {
  width: 100%;
  min-height: 520px;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  background: #fff;
  margin-top: 14px;
}

.small {
  font-size: 12px;
}

@media (max-width: 900px) {
  .emailBuilderGrid {
    grid-template-columns: 1fr;
  }
}
