* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  min-height: 100%;
  overscroll-behavior: none;
}
body {
  background: #222d37;
  font-family:
    "Avenir Next",
    "PingFang SC",
    "Microsoft YaHei",
    Arial,
    sans-serif;
  color: #18222e;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100dvh;
  -webkit-tap-highlight-color: transparent;
}
button {
  font: inherit;
  cursor: pointer;
  touch-action: manipulation;
}
button:disabled {
  cursor: default;
}
button:focus-visible {
  outline: 3px solid #ed9c18;
  outline-offset: 2px;
}
button[hidden],
[hidden] {
  display: none !important;
}
.game {
  width: min(100%, 440px);
  height: min(100dvh, 940px);
  min-height: 540px;
  position: relative;
  overflow: hidden;
  background: #edf0f1;
  isolation: isolate;
  box-shadow: 0 20px 70px #0004;
  --selection-height:470px;
}
.top-bar {
  height: 48px;
  position: absolute;
  inset: 0 0 auto;
  z-index: 12;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 12px;
  background:
    linear-gradient(
      105deg,
      #182432f5,
      #233448e8);
  color: #fff;
  border-bottom: 1px solid #ffffff22;
}
.brand-icon {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 36px;
  padding: 0 9px 0 4px;
  flex-shrink: 0;
  border: 1px solid #ffffff33;
  border-radius: 999px;
  background: #ffffff17;
  color: #fff;
  text-decoration: none;
}
.brand-icon-back {
  display: block;
  opacity: .85;
}

.brand-icon-back svg {
  display: block;
  width: 15px;
  height: 15px;
}
.brand-icon img {
  display: block;
  width: 28px;
  height: 28px;
  border-radius: 8px;
}
.brand-icon:hover,
.brand-icon:focus-visible {
  background: #ffffff2b;
  border-color: #ffffff5c;
}
.brand-icon:focus-visible {
  outline: 2px solid #8ee5d5;
  outline-offset: 2px;
}
.game-title {
  font-weight: 750;
  font-size: 10px;
  letter-spacing: .8px;
  margin-left: auto;
  white-space: nowrap;
  opacity: .78;
}
.balance {
  display: flex;
  align-items: center;
  gap: 5px;
  padding-left: 8px;
  border-left: 1px solid #ffffff26;
  white-space: nowrap;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
}
.balance strong {
  font-weight: 750;
}
.coin-icon {
  display: inline-block;
  width: 17px;
  height: 17px;
  background:
    radial-gradient(
      circle at 30% 20%,
      #ffe696,
      #ffc82f 65%,
      #c98a0c);
  border: 2px solid #fff3ac;
  border-radius: 50%;
  box-shadow: inset 0 0 0 1px #a86d2055, 0 1px 3px #0004;
}
.scene-view {
  position: absolute;
  top: 48px;
  left: 0;
  right: 0;
  bottom: var(--selection-height);
  overflow: hidden;
  background: #b2d5ed;
  transition: bottom .65s cubic-bezier(.2, .7, .1, 1);
}
/* Showcase grade: a soft photographic vignette while the car is on display. */
.scene-view:after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: 0;
  transition: opacity .5s ease;
  background:
    radial-gradient(122% 92% at 50% 40%, #0000 44%, #06131f5c 100%),
    linear-gradient(#0a1a2a2e, #0a1a2a00 32%);
}
.game[data-stage=selecting] .scene-view:after,
.game[data-stage=loading] .scene-view:after {
  opacity: 1;
}
.scene-view canvas {
  display: block;
  width: 100%;
  height: 100%;
}
.model-caption {
  position: absolute;
  z-index: 2;
  left: 16px;
  right: 16px;
  top: 12px;
  display: flex;
  gap: 9px;
  align-items: center;
  pointer-events: none;
  text-shadow: 0 1px 3px #0004;
  color: #fff;
}
.model-caption:before {
  content: "";
  position: absolute;
  inset: -12px -16px -22px -16px;
  background:
    linear-gradient(
      180deg,
      #15253380,
      transparent);
  z-index: -1;
}
.caption-rule {
  width: 3px;
  height: 25px;
  background: #ffd342;
}
.model-caption > div {
  display: flex;
  flex-direction: column;
}
.caption-kicker {
  display: none;
  font-weight: 700;
  letter-spacing: 2px;
  opacity: .85;
}
.model-caption strong {
  font-size: 16px;
  font-weight: 850;
  line-height: 1.15;
}
.model-caption small {
  display: none;
  opacity: .83;
  margin-top: 4px;
}
.selection-panel {
  position: absolute;
  inset: auto 0 0;
  z-index: 8;
  padding: 11px 12px max(12px, env(safe-area-inset-bottom));
  background:
    linear-gradient(
      135deg,
      #f8f7f4,
      #e8e9e7);
  border-top: 1px solid #fff;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: transform .5s ease, opacity .35s;
}
.amount-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  font-size: 13px;
  line-height: 18px;
  font-weight: 750;
}
.amount-picker {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}
.amount-picker button {
  height: 44px;
  border-radius: 7px;
  border: 1px solid #b7bdc2;
  background: linear-gradient(#fff, #e7e9ea);
  box-shadow: inset 0 1px #fff;
  font-size: 21px;
  font-weight: 850;
  font-style: italic;
  letter-spacing: -.7px;
  color: #202a34;
}
.amount-picker button.selected {
  background: linear-gradient(#ffe484, #ffd23c);
  border-color: #e4b42f;
  box-shadow: inset 0 0 0 1px #fff7ca;
}
.amount-picker button:disabled {
  opacity: .4;
}
.car-picker {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.car-row {
  width: 100%;
  height: clamp(47px, 7.3dvh, 62px);
  display: flex;
  align-items: center;
  padding: 3px 7px 3px 1px;
  border: 1px solid #d1d5d7;
  border-radius: 8px;
  background:
    linear-gradient(
      115deg,
      #ffffffd9,
      #f0f2f2);
  text-align: left;
  color: #202932;
  position: relative;
  overflow: hidden;
  transition:
    border .15s,
    background .15s,
    transform .15s;
}
.car-row.selected {
  background:
    linear-gradient(
      110deg,
      #fff3c9,
      #fff9e6);
  border-color: #e6b12b;
  box-shadow: inset 0 0 0 1px #fffdf5;
}
.car-row:active {
  transform: scale(.987);
}
.car-row img {
  width: 100px;
  height: 57px;
  object-fit: contain;
  flex-shrink: 0;
  margin-right: 0;
  filter: drop-shadow(0 3px 2px #17243222);
}
.car-info {
  min-width: 0;
  flex: 1;
}
.car-name-line {
  display: flex;
  align-items: center;
  gap: 5px;
}
.car-number {
  font-style: italic;
  font-weight: 900;
  font-size: 16px;
  line-height: 23px;
  min-width: 28px;
  text-align: center;
  color: #fff;
  background: var(--car-color);
  border-radius: 2px;
  text-shadow: 0 1px 2px #0004;
}
.car-name {
  font-size: 13px;
  font-weight: 800;
  white-space: nowrap;
  letter-spacing: -.25px;
}
.car-shape {
  font-size: 8px;
  line-height: 1.3;
  color: #839099;
  margin-top: 4px;
  white-space: nowrap;
}
.reward-preview {
  width: 83px;
  margin-left: 5px;
  align-self: center;
  border-left: 1px solid #b9bfc65c;
  padding-left: 8px;
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex-shrink: 0;
}
.reward-preview small {
  font-size: 9px;
  color: #727c84;
}
.reward-preview strong {
  font-size: 20px;
  line-height: 1;
  font-style: italic;
  letter-spacing: -.5px;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
}
.reward-preview strong.is-changing {
  animation: number-pop .23s ease;
}
.reward-hint {
  margin: 0;
  font-size: 9px;
  color: #92979b;
  text-align: center;
  line-height: 1.25;
}
.primary-button {
  width: 100%;
  min-height: 51px;
  border: 1px solid #d8a71e;
  box-shadow: inset 0 0 0 1px #fff0ac, 0 2px 4px #45421a0d;
  border-radius: 8px;
  background:
    linear-gradient(
      115deg,
      #ffe579,
      #ffcb31);
  color: #1c2631;
  font-weight: 850;
  font-size: 17px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  position: relative;
}
.primary-button:hover:not(:disabled) {
  filter: brightness(1.025);
}
.primary-button:active:not(:disabled) {
  transform: translateY(1px);
}
.primary-button:disabled {
  background:
    linear-gradient(
      110deg,
      #e0e3e4,
      #d5dadb);
  border-color: #c1c8cc;
  box-shadow: inset 0 0 0 1px #ffffff8c;
  color: #73818b;
}
.button-arrow {
  position: absolute;
  right: 16px;
  font-size: 25px;
  font-weight: 500;
}
.result-status {
  margin: 0;
  color: #7b660a;
  font-size: 12px;
  line-height: 1.5;
  text-align: center;
}
.result-status:empty {
  display: none;
}
.text-button {
  min-height: 40px;
  border: 0;
  background: transparent;
  color: #7b660a;
  text-decoration: underline;
  font-size: 12px;
  padding: 6px;
}
.profile-button {
  display: grid;
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  padding: 0;
  place-items: center;
  border: 1px solid #ffffff33;
  border-radius: 50%;
  background: #ffffff17;
  color: #fff;
}
.profile-button img {
  display: block;
  width: 20px;
  height: 20px;
  filter: invert(1);
}
.gt-racing-page .zf-game-stage {
  display: flex;
  justify-content: center;
  align-items: center;
}
.gt-racing-page [data-profile-panel].zf-profile-surface {
  left: max(12px, calc(50% - 220px));
}
.game:not([data-stage=selecting]):not([data-stage=loading]) .scene-view {
  bottom: 0;
}
.game:not([data-stage=selecting]):not([data-stage=loading]) .selection-panel {
  transform: translateY(105%);
  opacity: 0;
  pointer-events: none;
}
.game:not([data-stage=selecting]) .model-caption {
  display: none;
}
.race-hud {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 3;
}
.phase-chip {
  position: absolute;
  top: 14px;
  right: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: white;
  background: #182534c9;
  font-weight: 800;
  font-size: 12px;
  letter-spacing: 1px;
  padding: 7px 11px;
  transform: skew(-4deg);
  border-left: 3px solid #ffd445;
}
.rank-board {
  position: absolute;
  top: 14px;
  left: 10px;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.rank-item {
  display: flex;
  align-items: center;
  gap: 6px;
  background: #162332d4;
  color: white;
  height: 24px;
  min-width: 102px;
  padding: 2px 6px 2px 4px;
  border-radius: 2px;
  font-size: 10px;
  border: 1px solid transparent;
  transition: transform .25s;
}
.rank-item.is-yours {
  border-color: #ffda45;
  background: #393527df;
}
.rank-position {
  width: 12px;
  text-align: center;
  font-size: 11px;
  font-style: italic;
  color: #dbe6eb;
}
.rank-number {
  font-size: 12px;
  min-width: 21px;
  line-height: 18px;
  background: var(--car-color);
  color: white;
  text-align: center;
  font-weight: 850;
  font-style: italic;
}
.rank-name {
  font-size: 10px;
}
.race-progress {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  background: #ffffff22;
}
.race-progress div {
  height: 100%;
  width: 0;
  background: #ffce37;
  box-shadow: 0 0 6px #ffdd66;
}
.race-call {
  position: absolute;
  top: 26%;
  left: 0;
  right: 0;
  text-align: center;
  color: #fff;
  z-index: 5;
  pointer-events: none;
  font-size: 21px;
  font-weight: 850;
  font-style: italic;
  text-shadow: 0 2px 8px #10202fcc;
  opacity: 0;
  transform: translateY(5px);
  transition: opacity .18s, transform .18s;
}
.race-call.visible {
  opacity: 1;
  transform: translateY(0);
}
.your-car {
  position: absolute;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) skew(-4deg);
  font-size: 12px;
  white-space: nowrap;
  background: #142433cf;
  border: 1px solid #ffffff50;
  border-radius: 3px;
  padding: 8px 13px;
  color: #fff;
  z-index: 3;
  font-weight: 700;
}
.your-car b {
  margin-left: 7px;
  padding: 3px 6px;
  background: var(--car-color);
  color: white;
  font-style: italic;
}
.champion-banner {
  position: absolute;
  z-index: 4;
  top: 18px;
  left: 0;
  right: 0;
  text-align: center;
  color: #ffe270;
  text-shadow: 0 2px 10px #22374066;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}
.champion-banner small {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 8px;
  display: block;
  margin-bottom: 4px;
}
.champion-banner strong {
  font-size: 32px;
  font-weight: 900;
  font-style: italic;
}
.laurel {
  font-size: 45px;
  font-weight: 400;
  opacity: .8;
}
.result-panel {
  position: absolute;
  z-index: 10;
  bottom: max(16px, env(safe-area-inset-bottom));
  left: 12px;
  right: 12px;
  background:
    linear-gradient(
      135deg,
      #ffffffef,
      #f7f7f3e8);
  backdrop-filter: blur(9px);
  border: 1px solid #ffffffc9;
  border-radius: 10px;
  box-shadow: 0 8px 28px #18273533;
  padding: 15px 14px 13px;
  animation: result-in .45s cubic-bezier(.16, .7, .2, 1);
}
.result-heading {
  text-align: center;
  margin-bottom: 8px;
}
.result-heading > span {
  font-size: 10px;
  color: #727e89;
  letter-spacing: 1px;
}
.result-heading #result-title {
  display: block;
  font-size: 23px;
  line-height: 1.2;
  margin: 5px 0 4px;
  font-weight: 900;
  color: #243641;
}
.result-heading p {
  font-size: 11px;
  color: #687782;
  margin: 0;
}
.result-numbers {
  margin: 6px 0 12px;
}
.result-numbers > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 0;
  border-bottom: 1px solid #b8c1c755;
}
.result-numbers dt {
  font-size: 12px;
  color: #64707c;
}
.result-numbers dd {
  font-size: 17px;
  font-weight: 750;
  margin: 0;
  font-variant-numeric: tabular-nums;
}
.result-numbers .reward-line dd {
  font-size: 24px;
  font-weight: 950;
  color: #192932;
}
.result-numbers dd.positive {
  color: #1c9554;
}
.result-numbers dd.negative {
  color: #697681;
}
.game[data-stage=result] .champion-banner {
  top: 20px;
}
.confetti {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 4;
  overflow: hidden;
}
.confetti i {
  position: absolute;
  top: -20px;
  left: var(--x);
  height: 9px;
  width: 5px;
  background: var(--color);
  animation: confetti-fall var(--duration) linear var(--delay) infinite;
}
.loading {
  position: absolute;
  inset: 0;
  z-index: 20;
  background:
    linear-gradient(
      160deg,
      #182a3b,
      #244b62);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  color: white;
  gap: 20px;
}
.loading-emblem {
  font-size: 70px;
  font-weight: 950;
  font-style: italic;
  color: #ffcf3e;
  letter-spacing: -5px;
}
.loading-meter {
  display: flex;
  flex-direction: column;
  gap: 9px;
  width: 250px;
}
.loading-meter-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
}
.loading-meter-head > span:first-child {
  font-size: 12px;
  letter-spacing: 1px;
}
.loading-percent {
  flex: 0 0 auto;
  font-size: 30px;
  font-weight: 900;
  font-style: italic;
  letter-spacing: -1px;
  font-variant-numeric: tabular-nums;
}
.loading-percent-sign {
  font-size: 16px;
  margin-left: 1px;
}
.loading-bar {
  position: relative;
  height: 14px;
  overflow: hidden;
  border-radius: 3px;
  background: #0d1b26cc;
  box-shadow: inset 0 0 0 1px #ffffff1f;
}
.loading-bar-fill {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  border-right: 2px solid #ffd343;
  background: repeating-conic-gradient(#eef2f4 0% 25%, #16232e 0% 50%) 0 0 / 14px 14px;
  transition: width .3s linear;
}
.loading-ticks {
  display: flex;
  justify-content: space-between;
  color: #7f9bb0;
  font-size: 10px;
  letter-spacing: 1px;
}
.notice {
  position: absolute;
  z-index: 30;
  top: 70px;
  left: 15px;
  right: 15px;
  background: #25384bf2;
  border: 1px solid #ffc93966;
  color: #fff;
  border-radius: 7px;
  padding: 14px;
  font-size: 12px;
  line-height: 1.7;
  box-shadow: 0 7px 28px #15263844;
}
.game[data-stage=loading] .selection-panel {
  opacity: 0;
}
.game[data-stage=result] .your-car,
.game[data-stage=celebrating] .your-car {
  display: none !important;
}
@keyframes number-pop {
  50% {
    transform: translateY(-2px);
    color: #a67a00;
  }
}
@keyframes result-in {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@keyframes confetti-fall {
  to {
    transform: translate(30px, 920px) rotate(720deg);
  }
}
@media (min-width:600px) {
  body {
    padding: 14px;
  }
  .game {
    height: min(calc(100dvh - 28px), 940px);
    border-radius: 12px;
    border: 1px solid #ffffff15;
  }
}
@media (max-width:380px) {
  .top-bar {
    gap: 6px;
    padding: 0 9px;
  }
  .brand-icon {
    height: 30px;
    gap: 2px;
    padding: 0 6px 0 3px;
  }
  .brand-icon-back {
    font-size: 15px;
  }
  .brand-icon img {
    width: 24px;
    height: 24px;
  }
  .game-title {
    font-size: 9px;
    letter-spacing: 0;
  }
  .balance {
    font-size: 15px;
    padding-left: 6px;
  }
  .car-row img {
    width: 85px;
  }
  .reward-preview {
    width: 77px;
  }
  .reward-preview strong {
    font-size: 18px;
  }
  .car-name {
    font-size: 12px;
  }
  .car-shape {
    font-size: 7px;
  }
  .selection-panel {
    padding-left: 9px;
    padding-right: 9px;
  }
  .primary-button {
    font-size: 15px;
  }
  .result-heading #result-title {
    font-size: 21px;
  }
}
@media (max-height:700px) {
  .selection-panel {
    gap: 6px;
    padding-top: 8px;
    padding-bottom: 8px;
  }
  .amount-heading {
    font-size: 11px;
  }
  .amount-picker button {
    height: 44px;
    font-size: 19px;
  }
  .car-picker {
    gap: 4px;
  }
  .car-row {
    height: 47px;
  }
  .car-row img {
    height: 46px;
  }
  .car-shape {
    margin-top: 2px;
  }
  .primary-button {
    min-height: 44px;
  }
  .reward-hint {
    font-size: 8px;
  }
  .model-caption strong {
    font-size: 15px;
  }
  .result-panel {
    padding-top: 10px;
    bottom: 10px;
  }
  .result-numbers > div {
    padding: 5px 0;
  }
  .result-heading #result-title {
    font-size: 20px;
  }
}
@media (prefers-reduced-motion:reduce) {
  *,
  *:before,
  *:after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
  .confetti {
    display: none;
  }
}
.audio-review-link { display: block; padding-top: 7px; color: #47647d; text-align: center; font-size: 10px; }
.audio-review-link[hidden] { display: none; }
