@font-face {
  font-family: SG;
  src: url(../../fonts/SpaceGrotesk.ttf);
  font-display: swap;
}
* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}
html,
body {
  margin: 0;
  height: 100%;
  overflow: hidden;
  background: #07060d;
  color: #fff;
  font-family:
    SG,
    system-ui,
    sans-serif;
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
  overscroll-behavior: none;
}
#c {
  position: fixed;
  inset: 0;
  display: block;
  touch-action: none;
}
#pause {
  position: fixed;
  top: calc(env(safe-area-inset-top) + 10px);
  right: 10px;
  z-index: 4;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, .22);
  background: rgba(10, 8, 20, .5);
  backdrop-filter: blur(6px);
  color: #fff;
  font: 700 15px SG, system-ui;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
}
#pause i {
  display: block;
  width: 4px;
  height: 14px;
  border-radius: 2px;
  background: #fff;
}
#ui {
  position: fixed;
  inset: 0;
  z-index: 6;
  display: none;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(
      ellipse at center,
      rgba(20, 10, 40, .55),
      rgba(5, 4, 12, .85));
  backdrop-filter: blur(3px);
}
#ui.on {
  display: flex;
  animation: uin .25s ease-out;
}
@keyframes uin {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}
.card {
  width: min(330px, 88vw);
  padding: 26px 22px 20px;
  border-radius: 26px;
  text-align: center;
  background:
    linear-gradient(
      160deg,
      rgba(40, 24, 80, .92),
      rgba(14, 10, 30, .95));
  border: 1px solid rgba(255, 255, 255, .14);
  box-shadow:
    0 0 0 1px var(--ac,#ff3df0) inset,
    0 0 40px -6px var(--ac,#ff3df0),
    0 20px 60px rgba(0, 0, 0, .6);
  animation: pop .35s cubic-bezier(.2, 1.4, .4, 1);
}
@keyframes pop {
  from {
    transform: scale(.85);
    opacity: 0;
  }
  to {
    transform: none;
    opacity: 1;
  }
}
.card h1 {
  margin: 4px 0 6px;
  font-size: 40px;
  line-height: 1;
  letter-spacing: -1px;
  background:
    linear-gradient(
      90deg,
      var(--ac,#ff3df0),
      var(--ac2,#3df5ff));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 12px var(--ac,#ff3df0));
}
.card h2 {
  margin: 2px 0 10px;
  font-size: 28px;
}
.card p {
  margin: 6px 0 14px;
  color: #cfc8ea;
  font-size: 15px;
  line-height: 1.4;
}
.card .big {
  font-size: 54px;
  font-weight: 800;
  margin: 4px 0;
  text-shadow: 0 0 18px var(--ac,#ff3df0);
}
.card .sub {
  font-size: 13px;
  color: #a79fcb;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.btn {
  display: block;
  width: 100%;
  margin: 10px 0 0;
  padding: 15px 18px;
  border: 0;
  border-radius: 16px;
  font: 800 18px SG, system-ui;
  color: #12061f;
  cursor: pointer;
  background:
    linear-gradient(
      90deg,
      var(--ac,#ff3df0),
      var(--ac2,#3df5ff));
  box-shadow: 0 6px 24px -6px var(--ac,#ff3df0);
  transition: transform .1s;
}
.btn:active {
  transform: scale(.96);
}
.btn.alt {
  background: #fff;
  color: #1a0f33;
  box-shadow: none;
}
.btn.ghost {
  background: rgba(255, 255, 255, .08);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, .18);
  box-shadow: none;
  font-size: 15px;
  padding: 12px;
}
.btn.gold {
  background:
    linear-gradient(
      90deg,
      #ffd23d,
      #ff8a3d);
  box-shadow: 0 6px 24px -6px #ffb03d;
}
.row {
  display: flex;
  gap: 8px;
}
.row .btn {
  flex: 1;
}
.seg {
  display: flex;
  gap: 6px;
  margin: 8px 0 4px;
}
.seg button {
  flex: 1;
  padding: 11px 0;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, .2);
  background: rgba(255, 255, 255, .06);
  color: #fff;
  font: 700 14px SG, system-ui;
  cursor: pointer;
}
.seg button.on {
  background: var(--ac,#ff3df0);
  color: #12061f;
  border-color: transparent;
  box-shadow: 0 0 18px -2px var(--ac,#ff3df0);
}
.hint {
  font-size: 12px;
  color: #8f86b5;
  margin-top: 12px;
}
#ui {
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
  padding: 10px 0;
}
#ui .card {
  margin: auto;
  flex-shrink: 0;
}
@media (orientation:landscape) and (max-height:520px) {
  .card {
    padding: 14px 18px 12px;
    border-radius: 20px;
  }
  .card h1 {
    font-size: 30px;
    margin: 0 0 4px;
  }
  .card h2 {
    font-size: 24px;
    margin: 0 0 6px;
  }
  .card p {
    margin: 4px 0 8px;
    font-size: 14px;
  }
  .card .big {
    font-size: 42px;
  }
  .btn {
    padding: 11px 16px;
    font-size: 16px;
    margin-top: 8px;
  }
  .btn.ghost {
    padding: 9px;
  }
  .hint {
    margin-top: 6px;
  }
}
