@font-face {
  font-family: Barlow Condensed;
  src: url(art/fonts/BarlowCondensed-ExtraBoldItalic.ttf) format('truetype');
  font-weight: 800;
  font-style: italic;
  font-display: swap;
}
:root {
  --paper: #f6f4eb;
  --ink: #172e2c;
  --muted: #576c65;
  --rule: #d7dace;
  --mint: #b5dacf;
  --orange: #f3a044;
  --dark: #183b38;
  --shadow: 0 3px 0 #172e2c12;
  --display: 'Barlow Condensed', 'Avenir Next Condensed', Impact, sans-serif;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--paper);
  color: var(--ink);
}
body {
  font:
    500 15px/1.4 'DM Sans',
    'Avenir Next',
    system-ui,
    sans-serif;
  -webkit-tap-highlight-color: transparent;
}
button {
  font: inherit;
  color: inherit;
  cursor: pointer;
}
button:disabled {
  cursor: default;
}
button:focus-visible {
  outline: 3px solid #0e8e86;
  outline-offset: 4px;
}
button {
  touch-action: manipulation;
}
[hidden] {
  display: none !important;
}
.ico {
  width: 1.22em;
  height: 1.22em;
  flex: none;
  vertical-align: middle;
  pointer-events: none;
}
button,
.money,
.tag {
  align-items: center;
}
button img {
  pointer-events: none;
}
h1,
h2,
h3,
p {
  margin: 0;
}
#lobby {
  min-height: 100dvh;
  background: radial-gradient(ellipse at 75% 20%, #fffcf3, transparent 72%), var(--paper);
}
.topbar {
  border-bottom: 1px solid var(--rule);
  background: #faf9f2;
  padding-top: var(--safe-top);
}
.bar-inner,
.page {
  width: min(1156px, 92%);
  margin: auto;
}
.bar-inner {
  height: 67px;
  display: flex;
  align-items: center;
  gap: 44px;
}
.wordmark,
.navlink,
.back,
.round,
.text-btn,
.plain,
.hero-help,
.cancel-tool {
  border: 0;
  background: transparent;
}
.wordmark {
  display: flex;
  gap: 12px;
  padding: 0;
  font-size: 19px;
  font-weight: 850;
  letter-spacing: -0.9px;
}
.brand-p {
  position: relative;
  display: grid;
  place-items: center;
  background: var(--dark);
  color: #fff8e0;
  width: 35px;
  height: 36px;
  border-radius: 9px 9px 9px 3px;
  font: italic 800 30px/1 var(--display);
  padding-right: 3px;
  transform: skew(-5deg);
}
.brand-p::after {
  content: '';
  position: absolute;
  bottom: 5px;
  left: -4px;
  width: 13px;
  height: 3px;
  background: var(--orange);
  box-shadow: 0 -5px var(--orange);
  transform: skew(-12deg);
}
.bar-inner nav {
  display: flex;
  gap: 18px;
  align-self: stretch;
}
.navlink {
  position: relative;
  color: var(--muted);
  font-weight: 750;
  font-size: 13px;
  padding: 0 2px;
}
.navlink.active {
  color: var(--ink);
}
.navlink.active::after {
  content: '';
  position: absolute;
  bottom: 11px;
  height: 2px;
  background: #36756a;
  left: 2px;
  right: 2px;
}
.bar-end {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-left: auto;
}
.money {
  display: inline-flex;
  gap: 5px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.money.coins .ico {
  color: #a96810;
  background: #f9cd6d;
  border-radius: 100%;
  padding: 1px;
}
.money.gems .ico {
  color: #187d8b;
}
.bar-end > .money {
  height: 33px;
  min-width: 57px;
  padding: 0 12px;
  justify-content: center;
  border: 1px solid #d6d9cc;
  background: #fffdf6;
  border-radius: 20px;
}
.round,
.drive-pause {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  padding: 0;
}
.round {
  border: 1px solid var(--rule);
  margin-left: 4px;
}
.round:hover,
.navlink:hover,
.back:hover,
.text-btn:hover {
  color: #098074;
}
.page {
  padding: 25px 0 max(28px, var(--safe-bottom));
}
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  border-radius: 22px;
  background: #214946 url(art/parking-club.webp) no-repeat center 58% / cover;
  min-height: 339px;
  height: clamp(339px, 45vh, 465px);
  box-shadow: 0 6px 16px #17332c14;
}
.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    linear-gradient(90deg, #102f2fe8 0%, #123b3bd4 19%, #1238358f 35%, #14373722 53%, transparent 72%),
    linear-gradient(0deg, #172d2b3b, transparent 28%);
}
.hero-copy {
  position: absolute;
  inset: 0 auto 0 0;
  padding: clamp(24px, 3.3vw, 45px);
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  justify-content: center;
  color: #fff7df;
}
.overline,
.tiny,
.stock,
.drive-group small,
.speed {
  font:
    800 10px/1.25 'Avenir Next',
    'DM Sans',
    system-ui,
    sans-serif;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}
.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  color: #ffe7bc;
}
.hero-tag i {
  width: 20px;
  height: 9px;
  background: repeating-linear-gradient(120deg, #ffc665 0 3px, transparent 3px 6px);
}
.hero-tag span {
  opacity: 0.6;
}
.hero h1,
.page-heading h1,
.dialog-head h2 {
  font: italic 800 46px/0.85 var(--display);
  letter-spacing: -0.02em;
  text-transform: uppercase;
}
.hero h1 {
  font-size: clamp(76px, 7vw, 110px);
  margin: 13px 0 10px;
  line-height: 0.83;
  text-shadow: 0 3px 1px #132c2c24;
}
.hero h1 em {
  font: inherit;
  color: #ffbe65;
}
.hero-copy p {
  font-weight: 600;
  font-size: 14px;
  color: #fff8e8;
}
.hero-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 22px;
}
.start-btn,
.primary,
.secondary,
.shop-btn,
.text-btn,
.hero-help,
.back,
.plain,
.cancel-tool {
  display: inline-flex;
  justify-content: center;
  gap: 8px;
  font-weight: 800;
}
.start-btn,
.primary {
  border: none;
  border-radius: 10px;
  background: #ffb54f;
  color: #20322c;
  min-height: 45px;
  padding: 10px 22px;
  box-shadow: 0 3px 0 #be7934;
  transition:
    transform 0.15s,
    background 0.15s;
}
.start-btn:hover,
.primary:hover {
  background: #ffca77;
  transform: translateY(-1px);
}
.start-btn:active,
.primary:active {
  transform: translateY(2px);
}
.hero-help {
  color: #fff6e2;
  padding: 9px 1px;
  font-size: 12px;
}
.hero-help .ico {
  opacity: 0.85;
}
.hero-location {
  position: absolute;
  bottom: 18px;
  right: 20px;
  color: #fff6df;
  background: #193532bd;
  border: 1px solid #ffffff55;
  border-radius: 18px;
  padding: 5px 11px;
  font-size: 11px;
  font-weight: 730;
  display: flex;
  gap: 6px;
  align-items: center;
}
.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 27px 0 13px;
}
.section-title h2,
.vehicle h2,
.shop-row h2,
.extra h2 {
  font-size: 22px;
  letter-spacing: -1px;
  line-height: 1.1;
  font-weight: 820;
}
.text-btn,
.back,
.plain {
  font-size: 13px;
  align-items: center;
}
.text-btn {
  padding: 5px 0;
  color: #345f56;
}
.garage-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 15px;
}
.garage-card {
  position: relative;
  isolation: isolate;
  display: flex;
  text-align: left;
  align-items: flex-end;
  padding: 19px 18px;
  min-height: 126px;
  border: 1px solid #adcabf;
  border-radius: 15px;
  background: linear-gradient(115deg, #e0efe4, #c2e1d2);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition:
    transform 0.17s,
    box-shadow 0.17s;
}
.garage-card.tools {
  border-color: #e2c89c;
  background: linear-gradient(115deg, #f7ead1, #f6d6a1);
}
.garage-card.missions {
  border-color: #ddc3ae;
  background: linear-gradient(115deg, #f7e7d9, #efd0bd);
}
.garage-card:hover,
.lot-card:not(:disabled):hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 12px #23392f14;
}
.art-well {
  position: absolute;
  right: 0;
  bottom: 0;
  height: 100%;
  width: 44%;
  display: grid;
  place-items: center;
  z-index: -1;
}
.art-well::before {
  content: '';
  position: absolute;
  right: -25%;
  width: 130%;
  height: 160%;
  border: 1px solid #ffffff77;
  border-radius: 50%;
  transform: rotate(33deg);
}
.art-well img {
  width: 94%;
  height: 89%;
  object-fit: contain;
  transform: rotate(-5deg);
  filter: drop-shadow(0 7px 5px #25403226);
}
.tools .art-well img,
.missions .art-well img {
  height: 75%;
}
.card-copy {
  display: flex;
  flex-direction: column;
  gap: 5px;
  max-width: 64%;
  background: transparent;
}
.card-copy strong {
  line-height: 1.1;
  font-weight: 850;
  letter-spacing: -0.8px;
  font-size: clamp(18px, 1.75vw, 25px);
}
.card-copy small,
.campaign-foot,
.footnote,
.page-heading p,
.shop-row p,
.vehicle-info small,
.extra p {
  color: var(--muted);
  font-size: 12px;
}
.corner-arrow {
  position: absolute;
  left: 17px;
  top: 14px;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #fafbf0a6;
  color: #385649;
  font-size: 10px;
}
.campaign-foot {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-top: 22px;
  padding: 14px 0 0;
  border-top: 1px solid var(--rule);
  font-size: 12px;
}
.campaign-foot span {
  display: flex;
  align-items: center;
  gap: 6px;
}
.campaign-foot b {
  font-variant-numeric: tabular-nums;
}
.segments {
  display: flex;
  gap: 3px;
  max-width: 230px;
  flex: 1;
}
.segments i {
  height: 5px;
  background: #d4d9cc;
  flex: 1;
  transform: skew(-20deg);
}
.segments .filled {
  background: #448e79;
}
.back {
  padding: 4px 0;
}
.page-heading {
  margin: 22px 0 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.page-heading h1 {
  font-size: clamp(46px, 5vw, 66px);
  line-height: 1;
  color: var(--dark);
}
.page-heading p {
  margin-top: 8px;
  font-size: 14px;
}
.tiny {
  color: var(--muted);
}
.lots-grid,
.vehicle-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 13px;
}
.lot-card,
.vehicle,
.extra,
.shop-row {
  border: 1px solid var(--rule);
  border-radius: 14px;
  box-shadow: var(--shadow);
  background: #fffdf7;
}
.lot-card {
  position: relative;
  display: grid;
  text-align: left;
  padding: 16px;
  gap: 3px;
  background: #dbede3;
  transition: transform 0.16s;
}
.lot-debut {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 6px;
  font-size: 10px;
  font-weight: 700;
  color: #406958;
}
.lot-card.locked {
  background: #eeeee5;
  color: #6b756c;
}
.lot-no {
  font: italic 800 33px/1 var(--display);
  color: #337366;
}
.locked .lot-no {
  color: #87968a;
}
.lot-mark {
  position: absolute;
  right: 12px;
  top: 13px;
}
.lot-card strong {
  margin-top: 8px;
}
.lot-card small {
  font-size: 11px;
}
.tabs {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid #d0d7c9;
  border-radius: 11px;
  background: #e8ece1;
  margin-bottom: 22px;
}
.tabs button {
  background: transparent;
  border: 0;
  border-radius: 7px;
  padding: 7px 17px;
  font-size: 13px;
  font-weight: 730;
}
.tabs button[aria-pressed='true'] {
  background: var(--dark);
  color: #fff9e7;
}
.vehicle,
.extra {
  overflow: hidden;
}
.vehicle-art,
.preview-art {
  position: relative;
  height: clamp(130px, 14vw, 170px);
  display: grid;
  place-items: center;
  background: radial-gradient(ellipse at center, #fff2e0 10%, #ecd8c1 90%);
}
.vehicle-art {
  grid-template: minmax(0, 1fr) / minmax(0, 1fr);
  overflow: hidden;
}
.vehicle-art.v1,
.vehicle-art.v4 {
  background: radial-gradient(ellipse, #fff2cb, #ebdab4);
}
.vehicle-art.v2,
.vehicle-art.v6 {
  background: radial-gradient(ellipse, #eef4d2, #d4deb9);
}
.vehicle-art.v3,
.vehicle-art.v5 {
  background: radial-gradient(ellipse, #e7f3eb, #bfd9ce);
}
.vehicle-art.v7 {
  background: radial-gradient(ellipse, #e8eef4, #ccd9e3);
}
.vehicle-art img {
  width: 92%;
  height: 94%;
  min-height: 0;
  min-width: 0;
  object-fit: contain;
  transition: filter 0.25s;
}
.speed {
  position: absolute;
  left: 8px;
  top: 8px;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 3px;
  border-radius: 10px;
  padding: 4px 6px;
  background: #fffbecd9;
  font-size: 9px;
  letter-spacing: 0.15px;
}
.vehicle-info,
.extra {
  padding: 15px;
}
.vehicle-info h2,
.extra h2,
.shop-row h2 {
  font-size: 19px;
  margin: 4px 0;
}
.vehicle-info .tiny {
  font-size: 9px;
  letter-spacing: 1.1px;
}
.paint-info {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: space-between;
  min-height: 43px;
}
.swatches {
  display: flex;
  gap: 5px;
}
.swatches button {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  padding: 0;
  border: 3px solid #fffdf7;
  background: var(--swatch);
  box-shadow: 0 0 0 1px #cccec0;
}
.swatches button[aria-pressed='true'] {
  box-shadow: 0 0 0 2px #345e53;
}
.shop-btn,
.secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  background: #2d6156;
  color: #fff9e7;
  border: 1px solid transparent;
  border-radius: 8px;
  padding: 8px 13px;
  font-size: 13px;
  min-height: 36px;
}
.shop-btn:disabled {
  background: #edeee4;
  color: #68756c;
}
.shop-btn:not(:disabled):hover {
  background: #214e46;
}
.shop-btn .money {
  color: inherit;
}
.vehicle-info > .shop-btn,
.extra > .shop-btn {
  width: 100%;
  margin-top: 7px;
}
.extras-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
.preview-art {
  overflow: hidden;
  background: var(--land);
  border-radius: 9px;
  margin-bottom: 12px;
  height: 105px;
}
.preview-art i,
.preview-art b {
  position: absolute;
  transform: rotate(-25deg);
}
.preview-art i {
  width: 130%;
  height: 38px;
  background: var(--tint);
}
.preview-art b {
  width: 135%;
  height: 2px;
  border-top: 2px dashed #fff8e0;
}
.preview-art .ico {
  position: absolute;
  right: 25%;
  font-size: 24px;
  color: #fffcde;
}
.preview-art.trail i {
  height: 14px;
  box-shadow: 0 23px var(--tint);
}
.tool-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.shop-row {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 17px;
}
.item-icon {
  height: 49px;
  width: 49px;
  flex: none;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: #d4e7da;
  color: #236754;
  font-size: 24px;
}
.item-icon.flip {
  background: #f1dfc0;
  color: #a26923;
}
.item-icon.pace {
  background: #e1e6ef;
  color: #4b648a;
}
.item-icon.scan {
  background: #f2dbcd;
  color: #955138;
}
.row-content {
  flex: 1;
}
.shop-row p {
  margin: 5px 0;
}
.stock {
  font-size: 9px;
  letter-spacing: 0.6px;
  color: #3c7767;
}
.footnote {
  margin: 18px 0;
}
.mission-reward {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  width: 100px;
  font-size: 12px;
}
.mission-reward .shop-btn {
  width: 100%;
  font-size: 11px;
}
.meter {
  height: 5px;
  background: #dce2d6;
  border-radius: 5px;
  overflow: hidden;
  margin: 9px 0 2px;
}
.meter i {
  display: block;
  height: 100%;
  background: #518e78;
}
.row-content > small {
  color: var(--muted);
  font-size: 10px;
}
#game,
#world,
#scene,
#targets {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
#game {
  position: fixed;
  overflow: hidden;
  user-select: none;
  background: #87aa70;
}
#world {
  isolation: isolate;
  touch-action: none;
  cursor: grab;
}
#world:active {
  cursor: grabbing;
}
#targets {
  pointer-events: none;
}
.car {
  position: absolute;
  pointer-events: none;
  padding: 0;
  border: 0;
  outline: 0;
  background: transparent;
  touch-action: none;
}
.car svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}
.car polygon {
  pointer-events: fill;
  fill: transparent;
  stroke-linejoin: round;
}
.car:hover:not(:disabled) polygon,
.car:focus-visible polygon {
  stroke: #fff9d5;
  stroke-width: 2px;
}
.car.safe polygon {
  fill: #c4f68f42;
  stroke: #d6ff95;
  stroke-width: 2px;
}
.car.aiming polygon {
  stroke: #ffdc74;
  stroke-width: 2px;
  stroke-dasharray: 4 3;
}
.car.hint::after {
  content: '☞';
  position: absolute;
  left: 12%;
  top: 48%;
  color: #fff9d9;
  font:
    900 42px/1 Georgia,
    serif;
  -webkit-text-stroke: 1px #584635;
  filter: drop-shadow(0 2px 1px #39372b66);
  transform: rotate(-125deg);
  pointer-events: none;
  animation: point 0.7s ease-in-out infinite alternate;
}
@keyframes point {
  to {
    translate: 3px 5px;
  }
}
.drive-hud {
  position: absolute;
  left: 50%;
  top: max(14px, 3%, var(--safe-top));
  transform: translateX(-50%);
  width: min(500px, 94%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  pointer-events: none;
}
.drive-group,
.drive-metrics,
.toolbelt,
.aim {
  display: flex;
  align-items: center;
  background: #173b36f5;
  border: 1px solid #fffae7aa;
  box-shadow: 0 3px 10px #1b35282b;
  color: #fff9e8;
  border-radius: 13px;
  pointer-events: auto;
}
.drive-group {
  gap: 9px;
  padding: 5px 14px 5px 6px;
}
.drive-group small {
  font-size: 9px;
  color: #b7d2bf;
  letter-spacing: 1px;
}
.drive-group strong {
  display: block;
  font-size: 14px;
}
.drive-pause {
  border: 0;
  color: #25493f;
  background: #ffedcf;
  border-radius: 8px;
  width: 31px;
  height: 31px;
}
.drive-metrics {
  gap: 12px;
  padding: 8px 12px;
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.drive-metrics .money {
  color: #ffdf9c;
}
.guide {
  position: absolute;
  left: 50%;
  bottom: max(11%, var(--safe-bottom));
  transform: translateX(-50%);
  width: min(350px, 90vw);
  min-height: 82px;
  background: #fff9ea;
  color: var(--ink);
  padding: 14px 14px 26px 87px;
  border: 2px solid #244c41;
  border-radius: 11px;
  text-align: left;
  box-shadow: 0 4px 0 #25463740;
}
.guide small {
  position: absolute;
  right: 14px;
  bottom: 8px;
  color: #976525;
  font-size: 11px;
}
.guide:disabled {
  color: var(--ink);
  opacity: 1;
}
#marshal {
  position: absolute;
  width: 87px;
  left: 0;
  bottom: 0;
}
#tools-hud {
  position: absolute;
  left: 50%;
  bottom: max(15px, var(--safe-bottom));
  transform: translateX(-50%);
  width: min(430px, 95%);
}
.toolbelt {
  padding: 5px;
  justify-content: space-around;
  gap: 3px;
}
.toolbelt button {
  display: flex;
  position: relative;
  align-items: center;
  flex-direction: column;
  gap: 3px;
  background: transparent;
  color: #fff3d8;
  border: 1px solid transparent;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 700;
  padding: 6px 11px;
  flex: 1;
  white-space: nowrap;
}
.toolbelt button[aria-pressed='true'] {
  background: #426a5e;
  border-color: #f6d78e;
}
.toolbelt .ico {
  font-size: 20px;
}
.toolbelt b {
  position: absolute;
  top: 0;
  right: 3px;
  font-size: 9px;
  border-radius: 6px;
  background: #fed490;
  color: #274637;
  padding: 1px 4px;
}
.aim {
  justify-content: space-between;
  padding: 6px 10px;
  font-size: 12px;
  margin: 0 0 5px;
}
.cancel-tool {
  color: #ffe4a5;
  font-size: 11px;
}
#drive-msg,
#toast {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  padding: 7px 14px;
  background: #183a36ee;
  color: #fff7dd;
  border: 1px solid #ffffff5c;
  border-radius: 14px;
  font-weight: 700;
  line-height: 1.25;
  white-space: nowrap;
  font-size: 12px;
  pointer-events: none;
}
#drive-msg {
  top: max(76px, calc(var(--safe-top) + 64px));
}
#drive-msg:empty {
  display: none;
}
#toast {
  position: fixed;
  bottom: max(20px, var(--safe-bottom));
  z-index: 5;
}
dialog {
  width: min(360px, 91vw);
  max-height: 88dvh;
  overflow: auto;
  border: 1px solid #38564e;
  border-radius: 18px;
  background: #fffbef;
  padding: 26px;
  color: var(--ink);
  box-shadow: 0 20px 80px #102b2a44;
  text-align: center;
}
dialog::backdrop {
  background: #112d2a85;
  backdrop-filter: blur(3px);
}
.dialog-head h2 {
  font-size: 39px;
  line-height: 0.95;
}
.checker {
  width: 39px;
  height: 12px;
  margin: 0 auto 13px;
  background: repeating-conic-gradient(#528477 0 25%, transparent 0 50%) 0 0/12px 12px;
  transform: skew(-12deg);
}
dialog p {
  font-size: 14px;
  margin: 13px 0;
  color: var(--muted);
}
dialog .primary,
dialog .secondary,
dialog .plain {
  width: 100%;
  margin-top: 10px;
}
.secondary {
  background: #e8eee3;
  color: var(--dark);
  border: 1px solid #ccdacd;
}
.plain {
  padding: 6px;
  color: var(--muted);
}
.instructions {
  text-align: left;
  font-size: 14px;
  padding-left: 22px;
}
.instructions li {
  margin: 9px 0;
}
.stars {
  color: #b77b1d;
  letter-spacing: 4px;
  font-size: 31px;
  margin: 9px 0 0;
}
.stars span {
  color: #d4d7c7;
}
.receipt {
  margin: 14px 0 8px;
  padding: 10px 14px;
  background: #f2eddf;
  border-radius: 10px;
  font-size: 13px;
}
.receipt div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 4px 0;
}
.receipt div:last-child {
  border-top: 1px dashed #aeb7a4;
  padding-top: 7px;
}
.receipt dd {
  font-weight: 780;
  margin: 0;
}
@media (max-width: 880px) {
  .garage-grid {
    gap: 9px;
  }
  .garage-card {
    min-height: 122px;
    padding: 14px;
  }
  .corner-arrow {
    left: 14px;
  }
  .tool-grid {
    grid-template-columns: 1fr;
  }
  .vehicle-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .vehicle-art {
    height: 166px;
  }
  .lots-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 620px) {
  .bar-inner,
  .page {
    width: calc(100% - 28px);
  }
  .bar-inner {
    height: 55px;
    gap: 10px;
  }
  .bar-inner nav {
    display: none;
  }
  .wordmark {
    gap: 7px;
    font-size: 15px;
  }
  .brand-p {
    width: 28px;
    height: 30px;
    font-size: 25px;
  }
  .bar-end {
    gap: 4px;
  }
  .bar-end > .money {
    min-width: 39px;
    padding: 0 7px;
    height: 28px;
    font-size: 12px;
  }
  .round {
    margin-left: 1px;
    width: 30px;
    height: 30px;
  }
  .page {
    padding-top: 15px;
  }
  .hero {
    height: clamp(353px, 50vh, 445px);
    min-height: 0;
    border-radius: 15px;
    background-position: 65% center;
  }
  .hero::before {
    background: linear-gradient(0deg, #102e2ef5 0%, #153733d9 21%, #122b2a65 57%, transparent 86%);
  }
  .hero-copy {
    inset: auto 0 0;
    padding: 20px;
  }
  .hero h1 {
    font-size: 62px;
    margin: 8px 0 7px;
  }
  .hero-tag {
    font-size: 9px;
    letter-spacing: 1.5px;
  }
  .hero-copy p {
    font-size: 12px;
  }
  .hero-actions {
    margin-top: 14px;
    gap: 12px;
  }
  .hero-location {
    top: 12px;
    right: 10px;
    bottom: auto;
    font-size: 10px;
  }
  .start-btn {
    min-height: 40px;
    padding: 8px 15px;
  }
  .hero-help {
    font-size: 11px;
  }
  .section-title {
    margin: 21px 0 10px;
  }
  .section-title h2 {
    font-size: 21px;
  }
  .garage-grid {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .garage-card {
    min-height: 77px;
    align-items: center;
    padding: 12px 43px 12px 87px;
  }
  .art-well {
    right: auto;
    left: 6px;
    width: 72px;
    height: 100%;
  }
  .art-well::before {
    display: none;
  }
  .art-well img {
    width: 94%;
    height: 78%;
  }
  .tools .art-well img,
  .missions .art-well img {
    height: 68%;
  }
  .corner-arrow {
    left: auto;
    right: 13px;
    top: 50%;
    transform: translateY(-50%);
  }
  .card-copy {
    max-width: none;
    gap: 1px;
  }
  .card-copy strong {
    font-size: 19px;
  }
  .card-copy small {
    font-size: 11px;
  }
  .campaign-foot {
    margin-top: 14px;
    gap: 7px;
    font-size: 10px;
  }
  .segments {
    max-width: none;
  }
  .page-heading {
    margin: 12px 0 18px;
  }
  .page-heading h1 {
    font-size: 47px;
  }
  .page-heading p {
    font-size: 13px;
  }
  .lots-grid,
  .vehicle-grid {
    gap: 9px;
  }
  .vehicle-art {
    height: 121px;
  }
  .vehicle-info,
  .extra {
    padding: 10px;
  }
  .vehicle-info h2,
  .extra h2 {
    font-size: 16px;
  }
  .paint-info {
    gap: 4px;
    padding: 9px 0;
    align-items: flex-start;
    flex-direction: column;
  }
  .shop-btn {
    padding: 7px;
    font-size: 11px;
  }
  .speed {
    font-size: 8px;
  }
  .extras-grid {
    grid-template-columns: 1fr;
  }
  .extra {
    display: grid;
    align-items: center;
    grid-template-columns: 75px 1fr auto;
    gap: 10px;
  }
  .preview-art {
    height: 60px;
    margin: 0;
  }
  .extra > .shop-btn {
    margin: 0;
  }
  .shop-row {
    padding: 12px;
    gap: 9px;
  }
  .item-icon {
    width: 38px;
    height: 38px;
    font-size: 20px;
  }
  .mission-reward {
    width: 80px;
  }
  .shop-row h2 {
    font-size: 16px;
  }
  .shop-row p {
    font-size: 11px;
  }
  .drive-metrics {
    gap: 7px;
    padding: 7px;
    font-size: 10px;
  }
  .drive-group {
    padding-right: 8px;
  }
  .drive-group strong {
    font-size: 12px;
  }
  .toolbelt button {
    padding: 6px 4px;
  }
  .tabs button {
    padding: 7px 12px;
  }
}
@media (max-height: 440px) and (orientation: landscape) {
  .drive-hud {
    top: 4px;
  }
  .guide {
    bottom: 3%;
    min-height: 51px;
    padding: 6px 12px 15px 58px;
    width: 285px;
  }
  .guide small {
    bottom: 2px;
  }
  #marshal {
    width: 58px;
  }
  #tools-hud {
    bottom: 4px;
  }
  .toolbelt button {
    flex-direction: row;
    align-items: center;
  }
  .toolbelt .ico {
    font-size: 14px;
  }
  #drive-msg {
    top: 50px;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}

.night-entry,
.pass-counter {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
  margin: 22px 0;
  border-radius: 14px;
  padding: 18px 20px;
  color: #fff5db;
  background: linear-gradient(115deg, #163c3a, #285a52);
}
.night-entry h2 {
  font: italic 800 30px/1 var(--display);
}
.night-entry p {
  margin: 4px 0;
}
.pass-counter strong {
  display: block;
  font: italic 800 34px/1 var(--display);
}
#reward-video {
  display: block;
  width: 100%;
  border-radius: 9px;
  background: #193630;
}
.ad-progress {
  font-variant-numeric: tabular-nums;
}
#express-order {
  position: absolute;
  top: calc(max(14px, 3%, var(--safe-top)) + 54px);
  left: 50%;
  transform: translateX(-50%);
  max-width: 95%;
  width: max-content;
  padding: 5px 12px;
  border-radius: 15px;
  background: #193c36ed;
  color: #ffe59b;
  font-size: 12px;
  font-weight: 700;
  pointer-events: none;
}
.car.priority::before {
  content: '★';
  position: absolute;
  left: 50%;
  top: 25%;
  transform: translate(-50%, -50%);
  font: bold 14px/1 system-ui;
  color: #ffec9e;
  background: #3f311a;
  padding: 2px 3px;
  border: 1px solid #ffdb71;
  border-radius: 6px;
  pointer-events: none;
}
.car.priority polygon {
  stroke: #ffd45a;
  stroke-width: 2px;
}

#express-order:not([hidden]) ~ #drive-msg {
  top: calc(max(14px, 3%, var(--safe-top)) + 84px);
}
.car.express-hint::after {
  content: '↓';
  position: absolute;
  bottom: 78%;
  left: 50%;
  transform: translateX(-50%);
  color: #ffda66;
  text-shadow:
    0 1px 2px #523f19,
    0 -1px 2px #523f19;
  font: bold 22px/1 system-ui;
  pointer-events: none;
}
