/* ===== Layar HP siswa (stik) ===== */
html,
body.pemain {
  overscroll-behavior: none;
  touch-action: manipulation;
}
body.pemain {
  background:
    radial-gradient(900px 500px at 50% -10%, rgba(155, 92, 255, 0.3), transparent 70%),
    radial-gradient(700px 400px at 50% 120%, rgba(255, 74, 31, 0.25), transparent 70%),
    #0b0820;
  min-height: 100%;
  min-height: 100dvh;
  user-select: none;
  -webkit-user-select: none;
}
.layar {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 18px 16px calc(18px + env(safe-area-inset-bottom));
  text-align: center;
}
body.ada-atas .layar {
  padding-top: 70px;
}
.layar h2 {
  margin: 0;
  font-family: 'LG', sans-serif;
  font-weight: 400;
  font-size: 28px;
  letter-spacing: 0.03em;
}
.pemain .logo {
  font-size: clamp(44px, 14vw, 64px);
}
.kartu.form {
  width: min(420px, 100%);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  text-align: left;
}
.form label {
  font-weight: 700;
  color: var(--redup);
  font-size: 15px;
}
#isiPin {
  font-family: 'LG', sans-serif;
  font-size: 34px;
  letter-spacing: 0.25em;
  text-align: center;
  padding: 12px 10px 8px;
}
.form .tombol {
  font-size: 26px;
  padding: 16px;
}
.kecil-redup {
  font-size: 14px;
  color: var(--redup);
  margin: 0;
}

/* ---------- bilah atas ---------- */
.atas {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  padding-top: calc(10px + env(safe-area-inset-top));
  background: rgba(10, 15, 36, 0.9);
  border-bottom: 3px solid #0a0f24;
  font-weight: 700;
}
.atas .titik {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 3px solid #0a0f24;
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.4);
  flex: none;
}
.atas .nama {
  flex: 1;
  min-width: 0;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 17px;
}
.atas .nomor {
  font-family: 'LG', sans-serif;
  font-size: 18px;
  color: var(--kuning);
}
.atas .skor {
  font-family: 'LG', sans-serif;
  font-size: 18px;
  background: #fff;
  color: var(--aspal);
  border-radius: 10px;
  padding: 4px 10px 2px;
}

/* ---------- pahlawan ---------- */
.label-kecil {
  margin: 0;
  font-family: 'LG', sans-serif;
  letter-spacing: 0.12em;
  color: var(--kuning);
  font-size: 16px;
}
.kanvas-hero {
  width: min(260px, 60vw);
  height: auto;
  aspect-ratio: 360 / 400;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.5));
}
.kanvas-hero.kecil {
  width: min(200px, 48vw);
  aspect-ratio: 300 / 320;
}
.nama-hero {
  font-family: 'LG', sans-serif;
  font-size: 40px;
  line-height: 1;
}
.gelar-hero {
  font-weight: 700;
  font-size: 18px;
  color: var(--redup);
}
.daftar-jurus {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  max-width: 420px;
}
.daftar-jurus span {
  background: rgba(255, 255, 255, 0.08);
  border: 2px solid rgba(255, 255, 255, 0.12);
  border-radius: 99px;
  padding: 6px 12px;
  font-weight: 700;
  font-size: 14px;
}
.daftar-jurus span.ult {
  border-color: var(--kuning);
  color: var(--kuning);
}
.jurus-hasil {
  font-family: 'LG', sans-serif;
  font-size: 26px;
  letter-spacing: 0.02em;
  text-shadow: 0 3px 0 rgba(0, 0, 0, 0.35);
}
.atas .ikon-hero {
  font-size: 22px;
}
.nomor-besar {
  font-family: 'LG', sans-serif;
  font-size: 54px;
  line-height: 1;
  color: var(--kuning);
}
.pesan-besar {
  font-family: 'LG', sans-serif;
  font-size: 30px;
  line-height: 1.15;
  letter-spacing: 0.02em;
  margin: 0;
}
.pesan {
  font-size: 18px;
  font-weight: 600;
  color: var(--redup);
  margin: 0;
  max-width: 420px;
}
.mata {
  font-size: 70px;
  animation: lirik 1.6s infinite;
}
@keyframes lirik {
  50% {
    transform: translateY(-8px) scale(1.05);
  }
}
.bar-waktu {
  width: min(420px, 100%);
  height: 14px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
}
.bar-waktu div {
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, var(--kuning), var(--oranye));
  transform-origin: left;
}

/* ---------- jawab ---------- */
#sJawab {
  justify-content: flex-start;
  gap: 10px;
  padding-left: 10px;
  padding-right: 10px;
}
.info-soal {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: 'LG', sans-serif;
  font-size: 20px;
  color: var(--redup);
  padding: 0 4px;
}
.info-soal .detik {
  color: #fff;
  font-size: 26px;
  min-width: 52px;
  text-align: right;
}
.info-soal .detik.genting {
  color: #ff7b7b;
}
#sJawab .bar-waktu {
  width: 100%;
  height: 10px;
}
.tombol-jawab {
  flex: 1;
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-auto-rows: 1fr;
  gap: 10px;
  min-height: 0;
}
.tombol-jawab.dua {
  grid-template-columns: 1fr;
}
.jawab {
  position: relative;
  border: 0;
  border-radius: 20px;
  color: #fff;
  font-family: 'FR', sans-serif;
  font-weight: 700;
  font-size: 22px;
  line-height: 1.15;
  padding: 14px 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  box-shadow: inset 0 -8px 0 rgba(0, 0, 0, 0.25), 0 6px 18px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  touch-action: manipulation;
  transition: transform 0.08s, filter 0.2s;
  word-break: break-word;
  text-shadow: 0 2px 0 rgba(0, 0, 0, 0.3);
}
.jawab:active {
  transform: scale(0.96);
}
.jawab .huruf {
  font-family: 'LG', sans-serif;
  font-size: 30px;
  width: 50px;
  height: 50px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.92);
  color: #10183a;
  display: flex;
  align-items: center;
  justify-content: center;
  text-shadow: none;
}
.jawab.panjang {
  font-size: 17px;
}
.jawab.sangat-panjang {
  font-size: 14px;
}
.jawab.p1 {
  background: var(--opsi1);
}
.jawab.p2 {
  background: var(--opsi2);
}
.jawab.p3 {
  background: var(--opsi3);
}
.jawab.p4 {
  background: var(--opsi4);
}
.tombol-jawab.terkunci .jawab {
  filter: grayscale(0.7) brightness(0.6);
}
.tombol-jawab.terkunci .jawab.dipilih {
  filter: none;
  transform: scale(1.02);
  outline: 5px solid #fff;
}

/* ---------- terkunci ---------- */
.gembok {
  font-size: 76px;
}
.pilihan-saya {
  font-size: 22px;
  font-weight: 700;
  padding: 12px 18px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.1);
  max-width: 420px;
}
.berputar {
  width: 46px;
  height: 46px;
  border: 6px solid rgba(255, 255, 255, 0.2);
  border-top-color: var(--kuning);
  border-radius: 50%;
  animation: putar 0.9s linear infinite;
}
@keyframes putar {
  to {
    transform: rotate(360deg);
  }
}

/* ---------- hasil ---------- */
#sHasil.benar {
  background: radial-gradient(circle at 50% 30%, #3fe274, #17803a 70%);
}
#sHasil.salah {
  background: radial-gradient(circle at 50% 30%, #ff5a5f, #8e1018 70%);
}
#sHasil.kosong {
  background: radial-gradient(circle at 50% 30%, #5a6699, #252f5c 70%);
}
.ikon-hasil {
  font-size: 84px;
  line-height: 1;
  animation: lompat 0.5s cubic-bezier(0.2, 1.6, 0.4, 1) both;
}
@keyframes lompat {
  from {
    transform: scale(0.3);
    opacity: 0;
  }
}
.judul-hasil {
  font-family: 'LG', sans-serif;
  font-size: 46px;
  line-height: 1;
  margin: 0;
  text-shadow: 0 4px 0 rgba(0, 0, 0, 0.3);
}
.poin-hasil {
  font-family: 'LG', sans-serif;
  font-size: 38px;
  background: rgba(0, 0, 0, 0.25);
  border-radius: 16px;
  padding: 8px 18px 4px;
}
.lencana {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}
.lencana span {
  background: rgba(0, 0, 0, 0.28);
  border-radius: 99px;
  padding: 6px 14px;
  font-weight: 700;
  font-size: 16px;
}
.kunci-hasil {
  font-size: 18px;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.92);
  color: #10183a;
  border-radius: 14px;
  padding: 10px 16px;
  max-width: 420px;
}
.posisi {
  font-size: 20px;
  font-weight: 700;
}
.posisi b {
  font-family: 'LG', sans-serif;
  font-size: 30px;
}

/* ---------- akhir ---------- */
.piala {
  font-size: 96px;
  line-height: 1;
}
.peringkat-akhir {
  font-family: 'LG', sans-serif;
  font-size: 48px;
  line-height: 1.05;
  margin: 0;
  color: var(--kuning);
}
.statistik-akhir {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  width: min(380px, 100%);
}
.statistik-akhir div {
  background: rgba(255, 255, 255, 0.08);
  border-radius: 16px;
  padding: 12px;
  font-weight: 700;
  color: var(--redup);
}
.statistik-akhir b {
  display: block;
  font-family: 'LG', sans-serif;
  font-weight: 400;
  font-size: 30px;
  color: #fff;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: calc(20px + env(safe-area-inset-bottom));
  transform: translateX(-50%);
  z-index: 30;
  background: #10183a;
  border: 2px solid var(--kuning);
  color: #fff;
  font-weight: 700;
  padding: 10px 16px;
  border-radius: 14px;
  max-width: 90vw;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}
.sambung {
  position: fixed;
  left: 0;
  right: 0;
  top: 0;
  z-index: 40;
  background: var(--merah);
  color: #fff;
  font-weight: 700;
  padding: 10px;
  padding-top: calc(10px + env(safe-area-inset-top));
  text-align: center;
}
