@font-face { font-family: "Poppins"; src: url("assets/Poppins-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }
@font-face { font-family: "Poppins"; src: url("assets/Poppins-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Poppins"; src: url("assets/Poppins-800.woff2") format("woff2"); font-weight: 800; font-display: swap; }

:root {
  --latar: #f3f7f4; --tua: #10291d; --abu: #66756c; --hijau: #17a05d; --hijau-tua: #0e6b3f;
  --hijau-muda: #e3f4ea; --emas: #f5a700; --merah: #d6453d; --putih: #fff;
  --bayang: 0 14px 34px rgba(16, 60, 38, .13);
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; height: 100%; }
body { font-family: "Poppins", system-ui, sans-serif; font-weight: 600; color: var(--tua); background: var(--latar); overflow-x: hidden; }

.latar { position: fixed; inset: 0; z-index: 0; overflow: hidden;
  background-image: linear-gradient(rgba(16, 60, 38, .035) 1px, transparent 1px), linear-gradient(90deg, rgba(16, 60, 38, .035) 1px, transparent 1px);
  background-size: 28px 28px; }
.latar i { position: absolute; border-radius: 50%; filter: blur(60px); }
.latar i:nth-child(1) { width: 300px; height: 300px; left: -110px; top: -60px; background: rgba(23, 160, 93, .30); }
.latar i:nth-child(2) { width: 340px; height: 340px; right: -150px; bottom: 6%; background: rgba(23, 160, 93, .24); }
.latar i:nth-child(3) { width: 240px; height: 240px; right: -90px; top: 16%; background: rgba(120, 130, 125, .20); }

#app { position: relative; z-index: 1; max-width: 480px; min-height: 100%; margin: 0 auto;
  padding: max(18px, env(safe-area-inset-top)) 20px max(22px, env(safe-area-inset-bottom)); }
.layar { display: none; flex-direction: column; align-items: center; text-align: center; gap: 14px; min-height: calc(100dvh - 44px); justify-content: center; }
.layar.aktif { display: flex; animation: masuk .45s cubic-bezier(.2, .9, .3, 1.2); }
@keyframes masuk { from { opacity: 0; transform: translateY(18px) scale(.98); } to { opacity: 1; transform: none; } }

h1 { margin: 0; font-size: 34px; line-height: 1.12; font-weight: 800; letter-spacing: -.02em; }
h2 { margin: 0; font-size: 23px; line-height: 1.3; font-weight: 700; letter-spacing: -.01em; }
.sub { margin: 0; color: var(--abu); font-size: 15px; line-height: 1.5; max-width: 330px; }
.kecil { margin: 0; color: var(--abu); font-size: 12.5px; }

.logo { width: 150px; height: auto; }
.maskot { width: 190px; height: 190px; object-fit: contain; margin: -4px 0 -8px; animation: ayun 3.2s ease-in-out infinite; }
.maskot.kecil-m { width: 130px; height: 130px; }
@keyframes ayun { 50% { transform: translateY(-7px) rotate(-1.5deg); } }

.langkah { list-style: none; margin: 2px 0 4px; padding: 0; width: 100%; display: grid; gap: 8px; }
.langkah li { display: flex; align-items: center; gap: 12px; text-align: left; background: var(--putih); border-radius: 16px; padding: 11px 14px; font-size: 14.5px; box-shadow: 0 4px 14px rgba(16, 60, 38, .07); }
.langkah b { flex: none; width: 28px; height: 28px; border-radius: 50%; background: var(--hijau-muda); color: var(--hijau-tua); display: grid; place-items: center; font-weight: 800; font-size: 14px; }

.tbl { appearance: none; border: 0; width: 100%; min-height: 56px; padding: 14px 18px; border-radius: 18px; font: inherit; font-weight: 700; font-size: 18px;
  color: #fff; background: var(--hijau); box-shadow: 0 5px 0 var(--hijau-tua), var(--bayang); cursor: pointer; text-decoration: none; display: grid; place-items: center;
  transition: transform .08s, box-shadow .08s, opacity .2s; }
.tbl:active { transform: translateY(4px); box-shadow: 0 1px 0 var(--hijau-tua); }
.tbl.emas { background: var(--emas); color: #3a2600; box-shadow: 0 5px 0 #b97c00, var(--bayang); }
.tbl.garis { background: transparent; color: var(--hijau-tua); box-shadow: inset 0 0 0 2px rgba(14, 107, 63, .35); min-height: 48px; font-size: 15px; }
.tbl:disabled { opacity: .5; box-shadow: none; transform: none; cursor: default; }

.pil { margin: 0; display: inline-block; background: var(--hijau-tua); color: #fff; font-size: 12px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; padding: 7px 14px; border-radius: 99px; }
.pil.terang { background: var(--hijau-muda); color: var(--hijau-tua); }
.pil.emas { background: var(--emas); color: #3a2600; }

/* Kuis */
#l-kuis { justify-content: flex-start; padding-top: 10px; gap: 16px; }
.atas { width: 100%; display: flex; justify-content: space-between; align-items: center; }
.waktu { width: 100%; height: 10px; border-radius: 99px; background: rgba(16, 60, 38, .10); overflow: hidden; }
.waktu i { display: block; height: 100%; width: 100%; background: var(--hijau); border-radius: 99px; transform-origin: left; }
.waktu i.genting { background: var(--merah); }
#k-tanya { min-height: 96px; display: grid; place-items: center; width: 100%; background: var(--putih); border-radius: 22px; padding: 20px 18px; box-shadow: var(--bayang); font-size: 20px; }
.pilihan { width: 100%; display: grid; gap: 11px; }
.pilih { appearance: none; border: 0; width: 100%; min-height: 58px; display: flex; align-items: center; gap: 12px; text-align: left; padding: 12px 14px; border-radius: 18px;
  background: var(--putih); color: var(--tua); font: inherit; font-size: 16px; line-height: 1.3; box-shadow: inset 0 0 0 2px rgba(16, 60, 38, .10), 0 4px 0 rgba(16, 60, 38, .10); cursor: pointer; transition: transform .08s; }
.pilih:active { transform: translateY(3px); }
.pilih b { flex: none; width: 32px; height: 32px; border-radius: 10px; background: var(--hijau-muda); color: var(--hijau-tua); display: grid; place-items: center; font-weight: 800; }
.pilih.benar { background: var(--hijau); color: #fff; box-shadow: 0 4px 0 var(--hijau-tua); animation: denyut .4s; }
.pilih.benar b { background: rgba(255, 255, 255, .25); color: #fff; }
.pilih.salah { background: #fde8e6; color: #8f231d; box-shadow: inset 0 0 0 2px var(--merah); animation: geleng .35s; }
.pilih.salah b { background: var(--merah); color: #fff; }
.pilih.redup { opacity: .45; }
.pilih:disabled { cursor: default; }
@keyframes denyut { 40% { transform: scale(1.04); } }
@keyframes geleng { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
.info { margin: 0; min-height: 44px; font-size: 14px; line-height: 1.45; color: var(--hijau-tua); }

/* Hasil + follow */
.kartu { width: 100%; background: var(--putih); border-radius: 22px; padding: 16px; box-shadow: var(--bayang); display: grid; gap: 14px; }
.ig { display: flex; align-items: center; gap: 12px; text-align: left; }
.ig img { width: 58px; height: 58px; border-radius: 50%; object-fit: contain; padding: 7px; box-shadow: inset 0 0 0 3px var(--hijau); background: #fff; }
.ig b { display: block; font-size: 17px; font-weight: 800; }
.ig span { font-size: 12.5px; color: var(--abu); }

/* Roda */
.roda-wadah { position: relative; width: min(86vw, 350px); aspect-ratio: 1; margin: 8px 0 6px; }
.roda { position: absolute; inset: 0; border-radius: 50%; box-shadow: 0 0 0 8px #fff, 0 0 0 11px var(--hijau-tua), 0 20px 40px rgba(16, 60, 38, .25); transition: transform 5.2s cubic-bezier(.12, .7, .1, 1); }
.roda svg { width: 100%; height: 100%; display: block; border-radius: 50%; }
.roda text { font-family: "Poppins", sans-serif; font-weight: 800; fill: #fff; }
.jarum { position: absolute; left: 50%; top: -20px; z-index: 3; width: 0; height: 0; transform: translateX(-50%);
  border-left: 17px solid transparent; border-right: 17px solid transparent; border-top: 34px solid var(--merah); filter: drop-shadow(0 3px 3px rgba(0, 0, 0, .25)); }
.pusat { position: absolute; left: 50%; top: 50%; z-index: 2; width: 23%; aspect-ratio: 1; transform: translate(-50%, -50%); border-radius: 50%; background: #fff; display: grid; place-items: center; box-shadow: 0 4px 12px rgba(0, 0, 0, .22), inset 0 0 0 3px var(--hijau-tua); }
.pusat img { width: 68%; }

/* Hadiah */
.hadiah-ikon { font-size: 104px; line-height: 1; animation: lompat .7s cubic-bezier(.2, .9, .3, 1.5); }
@keyframes lompat { from { transform: scale(.2) rotate(-25deg); opacity: 0; } }
#d-nama { font-size: 40px; color: var(--hijau-tua); }
.tunjuk { gap: 4px; border: 2px dashed rgba(14, 107, 63, .4); }
.tunjuk b { font-size: 16px; }
.tunjuk span { font-size: 13.5px; color: var(--abu); }
.tunjuk em { font-style: normal; color: var(--hijau-tua); }
.jam { font-size: 34px; font-weight: 800; letter-spacing: .02em; font-variant-numeric: tabular-nums; margin-top: 6px; }
.tunjuk small { font-size: 12px; color: var(--abu); }

/* Konfeti */
#konfeti { position: fixed; inset: 0; z-index: 5; pointer-events: none; overflow: hidden; }
#konfeti i { position: absolute; top: -20px; width: 10px; height: 14px; border-radius: 2px; animation: jatuh linear forwards; }
@keyframes jatuh { to { transform: translateY(110vh) rotate(720deg); } }

@media (max-height: 640px) { .maskot { width: 130px; height: 130px; } h1 { font-size: 28px; } .layar { gap: 10px; } }
@media (prefers-reduced-motion: reduce) { .maskot, .layar.aktif { animation: none; } }

/* Follow 3 akun */
.daftar-ig { width: 100%; display: grid; gap: 10px; }
.akun { display: flex; align-items: center; gap: 12px; text-align: left; background: var(--putih); border-radius: 18px; padding: 12px 12px 12px 14px; box-shadow: 0 4px 14px rgba(16, 60, 38, .08); text-decoration: none; color: var(--tua); }
.akun .ikon-ig { flex: none; width: 44px; height: 44px; border-radius: 14px; display: grid; place-items: center; color: #fff; font-size: 24px; background: linear-gradient(45deg, #f9ce34, #ee2a7b 55%, #6228d7); }
.akun div { flex: 1; min-width: 0; }
.akun b { display: block; font-size: 15.5px; font-weight: 800; overflow: hidden; text-overflow: ellipsis; }
.akun div span { font-size: 12.5px; color: var(--abu); }
.akun i { flex: none; font-style: normal; font-size: 13px; font-weight: 700; padding: 8px 14px; border-radius: 99px; background: var(--hijau); color: #fff; }
.akun.sudah { box-shadow: inset 0 0 0 2px var(--hijau); }
.akun.sudah i { background: var(--hijau-muda); color: var(--hijau-tua); }

/* Syarat ambil hadiah */
.syarat { text-align: left; gap: 8px; border: 2px dashed rgba(14, 107, 63, .4); }
.syarat-judul { font-size: 16px; text-align: center; }
.syarat ol { margin: 0; padding: 0; list-style: none; counter-reset: s; display: grid; gap: 10px; }
.syarat li { counter-increment: s; position: relative; padding-left: 36px; font-size: 14px; line-height: 1.4; display: grid; gap: 6px; }
.syarat li::before { content: counter(s); position: absolute; left: 0; top: -2px; width: 26px; height: 26px; border-radius: 50%; background: var(--hijau-muda); color: var(--hijau-tua); display: grid; place-items: center; font-weight: 800; font-size: 13px; }
.syarat em { font-style: normal; color: var(--hijau-tua); font-size: 13px; word-break: break-word; }
.tbl.kecil-t { min-height: 42px; padding: 8px 14px; font-size: 14.5px; border-radius: 14px; box-shadow: 0 3px 0 var(--hijau-tua); }
.tbl.garis.kecil-t { box-shadow: inset 0 0 0 2px rgba(14, 107, 63, .35); }
.syarat .jam { text-align: center; font-size: 30px; }
.syarat small { text-align: center; }
#l-hadiah { gap: 10px; }
#l-hadiah .hadiah-ikon { font-size: 72px; }
#l-hadiah #d-nama { font-size: 32px; }

/* Selamat datang: muat satu layar HP */
#l-mulai { gap: 10px; }
#l-mulai .logo { width: 120px; }
#l-mulai .maskot { width: 140px; height: 140px; }
#l-mulai .langkah { gap: 6px; }
#l-mulai .langkah li { padding: 8px 12px; font-size: 14px; }
.akun b { font-size: 14px; }
.akun i { padding: 8px 12px; }

/* ---------- Kepala dua logo + proporsi layar ---------- */
#app { display: flex; flex-direction: column; min-height: 100dvh; }
.kepala { flex: none; display: flex; align-items: center; justify-content: center; gap: 10px; padding: 4px 0 10px; }
.kepala img { height: 42px; width: auto; display: block; }
.kepala img.lebar { height: 40px; }
.kepala i { width: 1.5px; height: 30px; background: rgba(16, 60, 38, .22); border-radius: 2px; }
.kepala-teks { display: grid; text-align: left; font-size: 10px; line-height: 1.25; color: var(--abu); font-weight: 600; }
.kepala-teks b { font-size: 11.5px; color: var(--tua); font-weight: 800; letter-spacing: .01em; }
.layar { flex: 1; min-height: 0; justify-content: center; gap: clamp(10px, 2dvh, 18px); padding: clamp(4px, 1.5dvh, 16px) 0; }
.layar.aktif { display: flex; }
#l-kuis { justify-content: center; padding-top: 0; }
#l-mulai { gap: clamp(8px, 1.6dvh, 14px); }
#l-mulai .maskot { width: clamp(120px, 22dvh, 190px); height: clamp(120px, 22dvh, 190px); margin: 0; }
h1 { font-size: clamp(28px, 4.4dvh, 36px); }
.maskot.kecil-m { width: clamp(110px, 18dvh, 150px); height: clamp(110px, 18dvh, 150px); }
.roda-wadah { width: min(84vw, 46dvh, 360px); margin: clamp(14px, 3dvh, 26px) 0 clamp(6px, 1.5dvh, 12px); }
.tbl { max-width: 420px; }
@media (max-height: 700px) {
  #l-mulai .maskot { width: 96px; height: 96px; }
  #l-mulai .sub { font-size: 13.5px; line-height: 1.4; }
  #l-mulai .langkah li { padding: 6px 12px; font-size: 13px; }
  #l-mulai .langkah b { width: 24px; height: 24px; font-size: 12px; }
  .akun { padding: 9px 10px 9px 12px; }
  .tbl { min-height: 50px; }
}
