:root {
  color-scheme: light;
  --ink: #34234c;
  --accent: #7652d8;
  --pink: #ec6ba5;
}
* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: Inter, ui-rounded, system-ui, sans-serif;
  color: var(--ink);
  background: #17102a;
}
body {
  padding-top: env(safe-area-inset-top);
  padding-bottom: env(safe-area-inset-bottom);
}
#camera,
#game {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
#camera {
  transform: scaleX(-1);
  opacity: 0.5;
}
#game {
  touch-action: none;
}
.overlay {
  position: fixed;
  inset: 0;
  z-index: 5;
  display: grid;
  place-items: center;
  padding: max(18px, env(safe-area-inset-top)) 16px
    max(18px, env(safe-area-inset-bottom));
  background: #17102ade;
  overflow: auto;
}
.hidden {
  display: none !important;
}
.card {
  width: min(760px, 100%);
  padding: 28px;
  border: 1px solid #fff8;
  border-radius: 28px;
  background: #fff9ffed;
  box-shadow: 0 24px 80px #070311aa;
  text-align: center;
}
.card.compact {
  width: min(470px, 100%);
}
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.top a {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #fff;
  color: var(--ink);
  text-decoration: none;
  font-size: 24px;
}
.top select {
  width: auto;
}
.icon {
  font-size: 56px;
  margin-top: 10px;
}
.kicker {
  color: #6840c2;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.12em;
}
h1 {
  font-size: clamp(34px, 7vw, 60px);
  line-height: 1;
  margin: 10px 0;
}
p {
  line-height: 1.55;
}
.settings {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin: 22px 0;
  text-align: left;
}
label span {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 800;
}
select,
button {
  min-height: 48px;
  border: 1px solid #cbb9ef;
  border-radius: 14px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-weight: 750;
  padding: 10px 14px;
}
select {
  width: 100%;
}
button {
  cursor: pointer;
}
.primary {
  border: 0;
  background: linear-gradient(135deg, #7652d8, #ec6ba5);
  color: #fff;
}
.danger {
  border-color: #a91d55;
  background: #fff0f5;
  color: #8e1645;
}
.actions {
  display: flex;
  gap: 12px;
  margin: 18px 0;
}
.actions button {
  flex: 1;
}
.check {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
}
.check span {
  margin: 0;
}
.progress {
  height: 14px;
  overflow: hidden;
  border-radius: 999px;
  background: #ded3f4;
}
.progress i {
  display: block;
  width: 0;
  height: 100%;
  background: #7652d8;
}
.hud {
  position: fixed;
  z-index: 4;
  top: max(10px, env(safe-area-inset-top));
  left: 10px;
  right: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  flex-wrap: wrap;
}
.hud > div,
.hud > label,
.hud > button {
  min-height: 48px;
  padding: 8px 11px;
  border-radius: 14px;
  background: #fff9fff0;
  box-shadow: 0 8px 24px #07031166;
}
.hud span {
  display: block;
  font-size: 10px;
  font-weight: 900;
}
.hud b {
  font-size: 20px;
}
.hud label {
  display: flex;
  align-items: center;
  gap: 7px;
}
.hud label span {
  margin: 0;
}
.hud select {
  width: auto;
  min-height: 32px;
  padding: 4px 8px;
}
.warning {
  padding: 12px;
  border-radius: 14px;
  background: #fff0f5;
  color: #8e1645;
  font-weight: 800;
}
@media (max-width: 600px) {
  .card {
    padding: 20px 16px;
    border-radius: 22px;
  }
  .settings {
    grid-template-columns: 1fr;
  }
  .actions {
    flex-direction: column;
  }
  .hud {
    justify-content: flex-start;
  }
  .hud > div {
    flex: 1;
    text-align: center;
  }
  .hud > label {
    order: 3;
    width: 100%;
    justify-content: center;
  }
  .hud > .danger {
    flex: 1;
  }
  .icon {
    font-size: 44px;
  }
  h1 {
    font-size: 34px;
  }
}
