/* =====================================================================
   Vinzz Piano Tiles v2 - Halaman publik (tema pastel kartun)
   Landing, Daftar Lagu, Detail Lagu, Buat Lagu, Papan Skor, Hasil.
   Hanya memakai token & komponen dari app.css. Mobile first.
   ===================================================================== */

/* ---------------------------------------------------------------------
   Utilitas bersama
   ------------------------------------------------------------------- */

/* Atribut hidden harus menang atas display dari komponen (.btn, .notice, dsb.) */
:where(.page-landing, .page-songs, .page-song, .page-upload, .page-leaderboard, .page-result, .page-profile) [hidden] { display: none !important; }

.list-reset { list-style: none; margin: 0; padding: 0; }

.kbd-xs { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 7px; font-size: 11.5px; box-shadow: 0 2px 0 var(--line-strong); }

.dot-sep { display: inline-block; width: 5px; height: 5px; margin: 0 2px; border-radius: 50%; background: var(--line-strong); vertical-align: middle; flex: none; }

.field-optional { margin-left: 6px; font-size: 12.5px; font-weight: 700; color: var(--text-sub); }
.field-label-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }

.diff-dot { display: inline-block; flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--diff, var(--muted)); box-shadow: 0 2px 0 rgba(43, 35, 86, 0.14); }
.diff-dot-easy { --diff: var(--easy); }
.diff-dot-normal { --diff: var(--normal); }
.diff-dot-hard { --diff: var(--hard); }
.diff-dot-expert { --diff: var(--expert); }

.badge-light { color: var(--ink-2); background: rgba(255, 255, 255, 0.94); }

/* Badge jenis lagu */
.kind-badge { gap: 5px; }
.kind-badge.kind-tiles { color: var(--grape-ink); background: var(--grape-soft); }
.kind-badge.kind-audio { color: var(--sky-ink); background: var(--sky-soft); }

/* Pil mode kecil */
.mode-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  height: 26px;
  padding: 0 10px 0 8px;
  border-radius: 999px;
  background: var(--mode-soft, var(--grape-soft));
  color: var(--mode-ink, var(--grape-ink));
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
}
.mode-pill .icon { color: var(--mode-deep, var(--grape-deep)); }

.medals { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }

/* Placeholder cover dengan ikon jenis lagu */
.cover-placeholder .icon { width: 38%; height: 38%; color: #fff; filter: drop-shadow(0 3px 0 hsl(var(--hue) 60% 60% / 0.7)); }

/* Empty state dengan maskot */
.empty-state.has-mascot { gap: 8px; }
.empty-mascot { width: 108px; margin-bottom: 4px; }

/* Panel putih tebal (senada kartu di halaman permainan) */
.panel {
  position: relative;
  background: #fff;
  border: 3px solid #fff;
  border-radius: 28px;
  box-shadow: 0 6px 0 rgba(98, 76, 196, 0.12), var(--shadow);
}
.panel-body { padding: clamp(18px, 3vw, 26px); }
.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px 14px;
  padding: clamp(16px, 2.6vw, 22px) clamp(18px, 3vw, 26px) 0;
}
.panel-title { display: flex; align-items: center; gap: 10px; min-width: 0; font-family: var(--font-display); font-size: 20px; font-weight: 650; line-height: 1.2; color: var(--ink); }
.panel-title-icon {
  --tint: var(--grape);
  --tint-soft: var(--grape-soft);
  flex: none;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 13px;
  background: var(--tint-soft);
  color: var(--tint);
}
.tint-pink { --tint: var(--pink-deep); --tint-soft: var(--pink-soft); }
.tint-sky { --tint: var(--sky-deep); --tint-soft: var(--sky-soft); }
.tint-mint { --tint: var(--mint-deep); --tint-soft: var(--mint-soft); }
.tint-orange { --tint: var(--orange-deep); --tint-soft: var(--orange-soft); }
.tint-yellow { --tint: #9a6c00; --tint-soft: var(--yellow-soft); }

/* Judul halaman */
.page-top {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 24px;
  margin-bottom: 24px;
}
.page-top-text { min-width: 0; max-width: 640px; }
.page-top .eyebrow { margin-bottom: 6px; }
.page-top h1 { font-size: clamp(32px, 5vw, 48px); font-weight: 700; }
.page-top-sub { margin-top: 8px; font-size: 16.5px; color: var(--ink-2); }
.page-top-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 40px;
  padding: 0 14px 0 10px;
  margin-bottom: 18px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.8);
  color: var(--ink-2);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  box-shadow: 0 3px 0 rgba(98, 76, 196, 0.12);
  max-width: 100%;
}
.back-link span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.back-link:hover { background: #fff; color: var(--ink); }

/* Grid sedang dimuat ulang */
.is-refreshing { opacity: 0.55; pointer-events: none; transition: opacity 0.2s var(--ease); }

/* Baris chip yang bisa di-scroll horizontal di mobile */
.chip-scroll {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 2px 6px;
  margin: -2px -2px -6px;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.chip-scroll::-webkit-scrollbar { display: none; }
.chip-scroll .chip { flex: none; }
.chip-scroll { min-width: 0; flex: 1 1 auto; }

/* ---------------------------------------------------------------------
   Kartu lagu v2 (dirender songCardHtml / landing_song_card)
   ------------------------------------------------------------------- */

.song-card-head { min-width: 0; }
.song-card-title { display: block; }
.song-card-meta { margin-top: 0; }
.song-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-height: 24px;
  margin-top: auto;
  padding-top: 8px;
  border-top: 2px dashed var(--surface-3);
}
.song-card-level { font-family: var(--font-display); font-size: 13.5px; font-weight: 600; color: var(--text-sub); white-space: nowrap; }
.song-card-best { display: inline-flex; align-items: center; gap: 4px; }
.song-card-best .medals { gap: 3px; flex-wrap: nowrap; }
.song-card-best .stars, .song-card-best .crowns { gap: 0; }
.song-card-score { font-family: var(--font-display); font-size: 14px; color: var(--grape-deep); }
.song-card-diffs span { width: 10px; height: 10px; border-radius: 50%; }
.song-card .kind-badge { height: 24px; padding: 0 9px 0 7px; font-size: 12px; }
.song-card-flags .badge { box-shadow: 0 2px 0 rgba(43, 35, 86, 0.12); }

@media (max-width: 520px) {
  .song-card-body { gap: 6px; padding: 10px 4px 4px; }
  .song-card-artist { font-size: 13px; }
  .song-card-foot { padding-top: 6px; }
  .song-card-level { font-size: 12.5px; }
  .song-card-best .icon { width: 14px; height: 14px; }
  .song-card .kind-badge { height: 22px; font-size: 11px; padding: 0 7px 0 6px; }
  .song-card .kind-badge .icon { width: 12px; height: 12px; }
  .song-card-flags { left: 6px; top: 6px; gap: 4px; }
  .song-card-flags .badge { height: 22px; padding: 0 7px; font-size: 11px; }
}

/* ---------------------------------------------------------------------
   Landing
   ------------------------------------------------------------------- */

.landing { overflow-x: clip; }

.hero-kids { padding: clamp(22px, 5vw, 56px) 0 clamp(20px, 4vw, 40px); }
.hero-kids-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  align-items: center;
  gap: clamp(24px, 4vw, 56px);
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 38px;
  padding: 0 16px 0 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 4px 0 rgba(98, 76, 196, 0.12);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  color: var(--ink-2);
}
.hero-badge-icon { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--yellow); color: var(--ink); }

.hero-kids-title {
  margin-top: 18px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(50px, 7.4vw, 94px);
  line-height: 0.95;
  letter-spacing: -0.02em;
}
.hero-kids-title span { display: block; }
.hero-kids-title .t-a { color: var(--grape-deep); text-shadow: 0 5px 0 rgba(255, 255, 255, 0.7); }
.hero-kids-title .t-b {
  color: var(--pink-deep);
  text-shadow:
    3px 0 0 #fff, -3px 0 0 #fff, 0 3px 0 #fff, 0 -3px 0 #fff,
    2px 2px 0 #fff, -2px 2px 0 #fff, 2px -2px 0 #fff, -2px -2px 0 #fff,
    0 8px 0 rgba(220, 74, 139, 0.22);
}
.hero-kids-tagline {
  margin-top: 18px;
  max-width: 460px;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(20px, 2.3vw, 26px);
  line-height: 1.3;
  color: var(--ink-2);
}
.hero-kids-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; margin-top: 28px; }
.hero-play .icon { margin-left: -4px; }

.hero-facts { list-style: none; margin: 28px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.hero-facts li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 40px;
  padding: 0 14px 0 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  font-weight: 700;
  font-size: 14.5px;
  color: var(--ink-2);
}
.hero-facts b { font-family: var(--font-display); color: var(--ink); }
.hero-fact-icon { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; color: #fff; }
.fact-pink { background: var(--pink); }
.fact-sky { background: var(--sky); }
.fact-mint { background: var(--mint); }

/* Panggung demo */
.hero-stage {
  --board-w: clamp(210px, 23vw, 300px);
  position: relative;
  display: grid;
  place-items: center;
  min-height: calc(var(--board-w) * 1.62);
  padding: 10px 0 10px calc(var(--board-w) * 0.18);
}
.stage-blob {
  position: absolute;
  z-index: -1;
  width: calc(var(--board-w) * 2);
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0.35) 60%, transparent 70%);
}

.stage-board {
  position: relative;
  width: var(--board-w);
  aspect-ratio: 3 / 4.6;
  overflow: hidden;
  border-radius: 28px;
  background: #fff;
  border: 6px solid #fff;
  box-shadow: 0 10px 0 rgba(98, 76, 196, 0.16), 0 28px 60px rgba(98, 76, 196, 0.28);
  transform: rotate(3deg);
  isolation: isolate;
}
.stage-lanes { position: absolute; inset: 0; display: grid; grid-template-columns: repeat(4, 1fr); pointer-events: none; }
.stage-lanes i { border-right: 2px solid #efeaff; }

.stage-track {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 400%;
  animation: stage-scroll 8s linear infinite;
  will-change: transform;
}
@keyframes stage-scroll {
  from { transform: translateY(-50%); }
  to { transform: translateY(0); }
}
.stage-tile {
  position: absolute;
  left: calc(var(--lane) * 25%);
  top: calc(var(--row) * 6.25%);
  width: 25%;
  height: calc(var(--len) * 6.25%);
  padding: 3px;
}
.stage-tile::before {
  content: "";
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 10px;
  background: linear-gradient(180deg, #3a3170 0%, #2b2356 30%);
  box-shadow: inset 0 3px 0 rgba(255, 255, 255, 0.12);
}
.stage-tile.is-long::before {
  background: linear-gradient(180deg, #3a3170 0%, #2b2356 16%, #2b2356 52%, var(--mint) 52%, #5fe3b7 100%);
}

.stage-hud { position: absolute; z-index: 2; left: 0; right: 0; top: 0; padding: 10px 14px 0; text-align: center; pointer-events: none; }
.stage-score {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: calc(var(--board-w) * 0.17);
  line-height: 1;
  color: #ff4f86;
  text-shadow: 3px 0 0 #fff, -3px 0 0 #fff, 0 3px 0 #fff, 0 -3px 0 #fff, 2px 2px 0 #fff, -2px 2px 0 #fff, 2px -2px 0 #fff, -2px -2px 0 #fff;
}
.stage-score.is-pop { animation: score-pop 0.3s var(--bounce); }
@keyframes score-pop { 0% { transform: scale(1.25); } 100% { transform: scale(1); } }
.stage-progress {
  position: relative;
  display: block;
  height: 8px;
  margin: 8px 12px 0;
  border-radius: 99px;
  background: rgba(43, 35, 86, 0.1);
  box-shadow: inset 0 0 0 2px #fff;
}
.stage-progress i {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--yellow), var(--orange));
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform 0.25s linear;
}
.stage-mark {
  position: absolute;
  top: 50%;
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  margin: -11px 0 0 -11px;
  border-radius: 50%;
  background: #fff;
  color: #ddd6f1;
  box-shadow: 0 2px 0 var(--line-strong);
}
.stage-mark:last-child { margin-left: -20px; }
.stage-mark.is-on { color: var(--yellow); animation: score-pop 0.45s var(--bounce); }
.stage-mark.is-on .icon { filter: drop-shadow(0 1.5px 0 var(--yellow-deep)); }

.stage-tap {
  position: absolute;
  z-index: 3;
  left: 58%;
  bottom: 9%;
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--yellow);
  color: var(--ink);
  border: 4px solid #fff;
  box-shadow: 0 4px 0 var(--yellow-deep), 0 10px 20px rgba(43, 35, 86, 0.2);
  animation: tap-bob 1s var(--ease) infinite;
}
@keyframes tap-bob {
  0%, 100% { transform: translateY(0) scale(1); }
  45% { transform: translateY(6px) scale(0.92); }
}

.stage-mascot {
  position: absolute;
  z-index: 4;
  left: 0;
  bottom: 0;
  width: calc(var(--board-w) * 0.62);
}
.stage-mascot .mascot { width: 100%; filter: drop-shadow(0 12px 14px rgba(43, 35, 86, 0.2)); }
.stage-bubble {
  position: absolute;
  left: 38%;
  top: -34px;
  z-index: 1;
  padding: 8px 14px;
  border-radius: 18px;
  background: var(--ink);
  color: #fff;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  white-space: nowrap;
  box-shadow: 0 8px 18px rgba(43, 35, 86, 0.25);
  animation: bubble-bob 2.4s var(--ease) infinite;
}
.stage-bubble::after { content: ""; position: absolute; left: 22px; bottom: -6px; width: 14px; height: 14px; border-radius: 3px; background: var(--ink); transform: rotate(45deg); }
@keyframes bubble-bob { 0%, 100% { transform: translateY(0) rotate(-2deg); } 50% { transform: translateY(-6px) rotate(1deg); } }

.stage-float { position: absolute; z-index: 1; display: grid; place-items: center; animation: float-y 3.2s var(--ease) infinite; }
.float-1 { right: 4%; top: 6%; color: var(--yellow); filter: drop-shadow(0 3px 0 var(--yellow-deep)); }
.float-2 { right: 0; top: 52%; color: var(--pink); animation-delay: -1.1s; }
.float-3 { left: 16%; top: 12%; color: var(--sky); filter: drop-shadow(0 2px 0 var(--sky-deep)); animation-delay: -2s; }
.float-4 { left: 8%; top: 44%; color: var(--grape); animation-delay: -0.6s; }
@keyframes float-y { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-12px) rotate(8deg); } }

/* Blok section */
.landing-block { padding-top: clamp(28px, 5vw, 56px); padding-bottom: clamp(16px, 3vw, 28px); }
.block-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 14px 24px; margin-bottom: 24px; }
.block-head h2 { font-size: clamp(28px, 3.6vw, 40px); font-weight: 700; }
.block-head .eyebrow { margin-bottom: 6px; }
.block-head p:not(.eyebrow) { margin-top: 8px; font-size: 16.5px; color: var(--ink-2); }
.block-head.is-center { flex-direction: column; align-items: center; text-align: center; }

.mode-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; }
.mode-grid .mode-card { padding: 22px 20px 20px; }
.mode-grid .mode-card p { font-size: 15px; line-height: 1.45; color: var(--ink-2); flex: 1; }
.mode-card-tag {
  align-self: flex-start;
  margin-top: 6px;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--mode-soft);
  color: var(--mode-ink);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 12.5px;
}

.howto { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; counter-reset: none; }
.howto-step {
  --tint: var(--pink);
  --tint-deep: var(--pink-deep);
  --tint-soft: var(--pink-soft);
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
  padding: 30px 22px 24px;
  border-radius: 28px;
  background: #fff;
  border: 3px solid #fff;
  box-shadow: 0 6px 0 rgba(98, 76, 196, 0.12), var(--shadow);
}
.howto-step.step-2 { --tint: var(--sky); --tint-deep: var(--sky-deep); --tint-soft: var(--sky-soft); }
.howto-step.step-3 { --tint: var(--mint); --tint-deep: var(--mint-deep); --tint-soft: var(--mint-soft); }
.howto-num {
  position: absolute;
  top: -16px;
  left: 50%;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  margin-left: -19px;
  border-radius: 50%;
  background: var(--tint);
  color: var(--ink);
  border: 3px solid #fff;
  box-shadow: 0 3px 0 var(--tint-deep);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
}
.howto-icon { display: grid; place-items: center; width: 70px; height: 70px; margin: 6px 0 4px; border-radius: 24px; background: var(--tint-soft); color: var(--tint-deep); }
.howto-step h3 { font-size: 21px; }
.howto-step p { font-size: 15px; color: var(--ink-2); max-width: 260px; }

.howto-rules { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px 18px; margin-top: 22px; }
.howto-rule { display: inline-flex; align-items: center; gap: 10px; padding: 8px 16px 8px 10px; border-radius: 999px; background: rgba(255, 255, 255, 0.75); font-weight: 700; font-size: 14.5px; color: var(--ink-2); }
.howto-rule i { display: block; width: 16px; height: 22px; border-radius: 5px; background: var(--ink); }
.howto-rule .rule-long { background: linear-gradient(0deg, var(--mint) 55%, var(--ink) 55%); }
.howto-rule .rule-miss { background: #fff; box-shadow: inset 0 0 0 2px var(--red); position: relative; }
.howto-rule .rule-miss::after { content: ""; position: absolute; inset: 4px 3px; background: linear-gradient(45deg, transparent 42%, var(--red) 42% 58%, transparent 58%); }

.landing-create { padding-bottom: clamp(36px, 6vw, 72px); }
.create-band {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(18px, 3vw, 36px);
  padding: clamp(24px, 4vw, 40px);
  border-radius: 34px;
  background:
    radial-gradient(circle at 12% 20%, rgba(255, 255, 255, 0.55) 0 60px, transparent 61px),
    radial-gradient(circle at 92% 90%, rgba(255, 255, 255, 0.35) 0 90px, transparent 91px),
    linear-gradient(135deg, var(--grape-soft), #ffe7f3);
  border: 4px solid #fff;
  box-shadow: 0 8px 0 rgba(98, 76, 196, 0.14), var(--shadow);
}
.create-mascot { width: clamp(110px, 12vw, 150px); animation: mascot-bounce 2.6s var(--ease) infinite; }
.create-copy h2 { font-size: clamp(28px, 3.4vw, 38px); font-weight: 700; }
.create-copy .eyebrow { margin-bottom: 6px; }
.create-copy p:not(.eyebrow) { margin: 10px 0 18px; font-size: 16px; color: var(--ink-2); max-width: 420px; }
.create-options { display: grid; gap: 12px; }
.create-option {
  --tint: var(--grape);
  --tint-deep: var(--grape-deep);
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 84px;
  padding: 14px 16px;
  border-radius: 22px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 5px 0 rgba(98, 76, 196, 0.14);
  transition: transform 0.25s var(--bounce);
}
.create-option:hover { color: var(--ink); transform: translateY(-3px) rotate(-0.6deg); }
.option-mp3 { --tint: var(--sky); --tint-deep: var(--sky-deep); }
.create-option-icon { flex: none; display: grid; place-items: center; width: 54px; height: 54px; border-radius: 18px; background: var(--tint); color: #fff; box-shadow: 0 4px 0 var(--tint-deep); }
.create-option-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.create-option-text b { font-family: var(--font-display); font-size: 19px; font-weight: 650; }
.create-option-text span { font-size: 14.5px; color: var(--ink-2); }
.create-option-go { color: var(--text-sub); }
.create-note { display: flex; gap: 8px; align-items: flex-start; font-size: 13.5px; color: var(--ink-2); }
.create-note .icon { flex: none; margin-top: 2px; color: var(--grape-deep); }

@media (max-width: 1080px) {
  .create-band { grid-template-columns: auto minmax(0, 1fr); }
  .create-options { grid-column: 1 / -1; grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .create-note { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  .hero-kids-inner { grid-template-columns: minmax(0, 1fr); text-align: center; }
  .hero-kids-copy { display: flex; flex-direction: column; align-items: center; }
  .hero-kids-tagline { margin-left: auto; margin-right: auto; }
  .hero-kids-cta, .hero-facts { justify-content: center; }
  .hero-stage { --board-w: 230px; margin-top: 12px; }
  .mode-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .howto { grid-template-columns: minmax(0, 1fr); gap: 26px; max-width: 520px; margin: 0 auto; }
  .howto-step { flex-direction: row; text-align: left; align-items: center; flex-wrap: wrap; column-gap: 16px; padding: 20px 20px 20px 22px; }
  .howto-step .howto-num { left: 18px; margin-left: 0; }
  .howto-icon { grid-row: span 2; margin: 0; width: 64px; height: 64px; }
  .howto-step h3, .howto-step p { flex: 1 1 calc(100% - 90px); }
  .howto-step { display: grid; grid-template-columns: auto minmax(0, 1fr); row-gap: 2px; }
  .howto-step .howto-icon { grid-row: 1 / span 2; }
}

@media (max-width: 560px) {
  .hero-kids-title { font-size: clamp(46px, 14vw, 60px); }
  .hero-kids-cta { flex-direction: column; align-items: stretch; width: 100%; max-width: 340px; }
  .hero-kids-cta .btn { width: 100%; }
  .hero-kids-cta .btn-xl { height: 62px; font-size: 21px; }
  .hero-facts { gap: 8px; }
  .hero-facts li { height: 36px; font-size: 13.5px; }
  .hero-fact-icon { width: 26px; height: 26px; }
  .hero-fact-icon .icon { width: 15px; height: 15px; }
  .hero-stage { --board-w: 200px; padding-left: 44px; }
  .stage-bubble { font-size: 13.5px; top: -30px; }
  .mode-grid { gap: 12px; }
  .mode-grid .mode-card { padding: 16px 14px; gap: 6px; border-radius: 22px; }
  .mode-grid .mode-card-icon { width: 44px; height: 44px; border-radius: 15px; }
  .mode-grid .mode-card-icon .icon { width: 22px; height: 22px; }
  .mode-grid .mode-card h3 { font-size: 18px; }
  .mode-grid .mode-card p { font-size: 13.5px; }
  .mode-card-tag { font-size: 11.5px; padding: 2px 8px; }
  .block-head .btn { width: 100%; }
  .create-band { grid-template-columns: minmax(0, 1fr); text-align: center; border-radius: 28px; }
  .create-mascot { margin: 0 auto; width: 104px; }
  .create-copy p:not(.eyebrow) { margin-left: auto; margin-right: auto; }
  .create-copy .btn { width: 100%; }
  .create-options { grid-template-columns: minmax(0, 1fr); text-align: left; }
}

/* ---------------------------------------------------------------------
   Daftar Lagu
   ------------------------------------------------------------------- */

.library-top { padding-right: 150px; min-height: 120px; }
.library-top .page-top-actions { position: relative; z-index: 1; }
.library-mascot {
  position: absolute;
  right: 0;
  bottom: -30px;
  z-index: 0;
  width: 128px;
  transform: rotate(6deg);
  filter: drop-shadow(0 10px 12px rgba(43, 35, 86, 0.16));
  pointer-events: none;
}
.library-top .page-top-actions { margin-left: auto; }

.library-filters { position: relative; z-index: 1; padding: 16px; margin-bottom: 18px; }
.library-filters-top { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.library-search { flex: 1 1 300px; }
.library-search .input { padding-right: 52px; background: var(--surface-2); }
.library-search .input:focus { background: #fff; }
.library-search input[type="search"]::-webkit-search-cancel-button { display: none; }
.library-search .input-action { width: 38px; }
.library-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.library-scope button { height: 40px; }
.library-sort { position: relative; display: flex; align-items: center; }
.library-sort > .icon { position: absolute; left: 14px; color: var(--grape); pointer-events: none; }
.library-sort .select { width: auto; min-width: 170px; height: 50px; padding-left: 40px; }

.library-filter-rows { display: flex; flex-wrap: wrap; gap: 12px 28px; margin-top: 14px; padding-top: 14px; border-top: 2px dashed var(--line); }
.filter-row { display: flex; align-items: center; gap: 12px; min-width: 0; }
.filter-label { flex: none; font-family: var(--font-display); font-weight: 600; font-size: 14px; color: var(--text-sub); letter-spacing: 0.02em; }
.filter-row .chip { height: 44px; }
.filter-row .chip .icon { color: var(--grape); }
.filter-row .chip.is-active .icon { color: #fff; }
.filter-row .chip .diff-dot { box-shadow: 0 0 0 2px #fff; }

.results-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; min-height: 40px; margin-bottom: 14px; }
.results-status { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; font-weight: 700; font-size: 15px; color: var(--ink-2); }
.results-status .spinner { width: 18px; height: 18px; border-width: 3px; }
.results-status b { font-family: var(--font-display); color: var(--ink); }
.results-filters { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.results-filter { padding: 2px 10px; border-radius: 999px; background: rgba(255, 255, 255, 0.8); font-size: 13px; color: var(--grape-deep); }

.song-grid.is-empty { display: block; }

@media (max-width: 720px) {
  .library-top { padding-right: 96px; min-height: 0; }
  .library-mascot { width: 84px; bottom: auto; top: 0; }
  .library-top .page-top-actions { margin-left: 0; }
  .library-filters { padding: 12px; border-radius: 24px; }
  .library-controls { width: 100%; }
  .library-scope { flex: 1 1 auto; }
  .library-scope button { flex: 1; justify-content: center; padding: 0 8px; }
  .library-sort { flex: 1 1 150px; }
  .library-sort .select { width: 100%; min-width: 0; height: 48px; }
  .library-filter-rows { flex-direction: column; gap: 10px; }
  .filter-row { width: 100%; }
  .filter-row { gap: 10px; }
  .filter-label { width: 42px; font-size: 13px; }
  .filter-row .chip { height: 42px; padding: 0 14px; font-size: 14.5px; }
}

/* ---------------------------------------------------------------------
   Detail Lagu
   ------------------------------------------------------------------- */

.song-head {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  align-items: center;
  gap: clamp(18px, 3vw, 30px);
  padding: 16px;
  margin-bottom: 22px;
}
.song-head-cover { position: relative; aspect-ratio: 1; overflow: hidden; border-radius: 22px; background: var(--surface-3); box-shadow: 0 5px 0 rgba(98, 76, 196, 0.12); }
.song-head-cover img { width: 100%; height: 100%; object-fit: cover; }
.song-head-info { min-width: 0; padding-right: 8px; }
.song-head-badges { display: flex; flex-wrap: wrap; gap: 6px; }
.song-head-badges .status-flag { display: contents; }
.song-head-title { margin-top: 10px; font-size: clamp(30px, 4.4vw, 46px); font-weight: 700; line-height: 1.05; overflow-wrap: anywhere; }
.song-head-artist { margin-top: 6px; font-size: 17px; color: var(--ink-2); }
.song-facts { list-style: none; margin: 18px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.song-facts li { display: flex; align-items: center; gap: 10px; min-width: 0; padding: 7px 14px 7px 7px; border-radius: 18px; background: var(--surface-2); }
.song-facts li > span:last-child { display: flex; flex-direction: column; min-width: 0; line-height: 1.15; }
.song-facts small { font-size: 12px; font-weight: 700; color: var(--text-sub); }
.song-facts b { font-family: var(--font-display); font-weight: 600; font-size: 16px; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.song-facts b a { color: var(--grape-deep); }
.song-fact-icon { flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 12px; background: var(--tint-soft); color: var(--tint); }

.song-layout { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(300px, 1fr); align-items: start; gap: 22px; }
.song-main, .song-side { display: flex; flex-direction: column; gap: 22px; min-width: 0; }

.step-dot {
  flex: none;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--grape-deep);
  color: #fff;
  font-size: 17px;
  font-weight: 700;
  box-shadow: 0 3px 0 #4f33c4;
}
.pick-sub { font-family: var(--font-display); font-weight: 600; font-size: 14px; color: var(--text-sub); }
.pick-note { display: flex; gap: 8px; align-items: flex-start; margin-top: 14px; font-size: 14px; color: var(--ink-2); }
.pick-note .icon { flex: none; margin-top: 2px; color: var(--sky-deep); }

/* Kartu level */
.level-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.level-card {
  --diff: var(--sky);
  --diff-deep: var(--sky-deep);
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 78px;
  padding: 10px 40px 10px 10px;
  border-radius: 22px;
  background: #fff;
  border: 3px solid var(--line);
  box-shadow: 0 4px 0 var(--line);
  cursor: pointer;
  transition: transform 0.22s var(--bounce), border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
.level-card.diff-easy { --diff: var(--mint); --diff-deep: var(--mint-deep); }
.level-card.diff-hard { --diff: var(--orange); --diff-deep: var(--orange-deep); }
.level-card.diff-expert { --diff: var(--pink); --diff-deep: var(--pink-deep); }
.level-card:hover { transform: translateY(-2px); border-color: var(--line-strong); }
.level-card.is-active { border-color: var(--diff); box-shadow: 0 4px 0 var(--diff-deep); background: color-mix(in srgb, var(--diff) 7%, #fff); }
.level-card:has(input:focus-visible) { outline: 3px solid var(--grape); outline-offset: 3px; }
.level-card-lv {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 18px;
  background: var(--diff);
  color: var(--ink);
  box-shadow: 0 3px 0 var(--diff-deep);
  font-family: var(--font-display);
  line-height: 1;
}
.level-card-lv small { font-size: 11px; font-weight: 600; opacity: 0.9; }
.level-card-lv b { font-size: 24px; font-weight: 700; }
.level-card-text { display: flex; flex-direction: column; gap: 4px; min-width: 0; flex: 1; }
.level-card-name { display: flex; flex-direction: column; font-family: var(--font-display); font-weight: 650; font-size: 18px; line-height: 1.15; color: var(--ink); }
.level-card-sub { font-family: var(--font-sans); font-weight: 700; font-size: 13px; color: var(--text-sub); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.level-card-best .medals { gap: 4px; }
.level-card-best .stars, .level-card-best .crowns { gap: 0; }
.level-card-empty { display: inline-flex; align-items: center; gap: 5px; font-size: 13px; font-weight: 700; color: var(--text-sub); }
.level-card-row { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.level-card-status { display: inline-flex; }
.level-card-status .badge { height: 22px; font-size: 11px; padding: 0 8px; }
.level-card-check,
.mode-card-check {
  position: absolute;
  right: 10px;
  top: 10px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--surface-3);
  color: transparent;
  transition: transform 0.25s var(--bounce), background-color 0.15s var(--ease);
}
.level-card.is-active .level-card-check { background: var(--diff); color: #fff; transform: scale(1.08); }

/* Kartu mode (pilih) */
.mode-picker { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.mode-picker.is-single { grid-template-columns: minmax(0, 1fr); }
.mode-picker .mode-card { cursor: pointer; padding: 16px 16px 14px; min-height: 100%; }
.mode-picker .mode-card:has(input:focus-visible) { outline: 3px solid var(--grape); outline-offset: 3px; }
.mode-picker .mode-card p { flex: 1; font-size: 14px; line-height: 1.4; color: var(--ink-2); }
.mode-picker .mode-card.is-active { background: color-mix(in srgb, var(--mode) 6%, #fff); }
.mode-picker .mode-card.is-active .mode-card-check { background: var(--mode); color: #fff; transform: scale(1.08); }
.mode-card-check { right: 12px; top: 12px; }
.mode-card-best {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  min-height: 30px;
  margin-top: 4px;
  padding: 4px 10px;
  border-radius: 12px;
  background: var(--mode-soft);
  font-size: 13px;
  color: var(--mode-ink);
}
.mode-card-best b { font-family: var(--font-display); font-size: 15px; color: var(--ink); }
.mode-card-best .medals { gap: 3px; }
.mode-card-best .stars, .mode-card-best .crowns { gap: 0; }
.mode-best-empty { font-weight: 700; color: var(--ink-2); }

/* Panel main */
.play-panel { padding: 18px; }
.play-head { display: flex; align-items: center; gap: 12px; }
.play-mascot { flex: none; width: 70px; margin: -34px 0 0 -4px; filter: drop-shadow(0 8px 10px rgba(43, 35, 86, 0.16)); }
.play-head-text { min-width: 0; }
.play-title { font-size: 24px; font-weight: 700; }
.play-picks { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.play-picks .mode-pill { height: 28px; }
.play-best {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 2px 10px;
  margin: 16px 0;
  padding: 12px 14px;
  border-radius: 18px;
  background: var(--surface-2);
  border: 2px solid var(--line);
}
.play-best-label { grid-column: 1 / -1; display: flex; align-items: center; gap: 6px; font-family: var(--font-display); font-weight: 600; font-size: 14px; color: var(--text-sub); }
.play-best-label .icon { color: var(--orange); }
.play-best-value { font-family: var(--font-display); font-weight: 700; font-size: 30px; line-height: 1.1; color: var(--ink); }
.play-best-value.is-empty { font-size: 20px; color: var(--ink-2); }
.play-best-extra { justify-self: end; text-align: right; font-size: 13.5px; font-weight: 700; color: var(--ink-2); }
.play-best-extra .medals { gap: 4px; justify-content: flex-end; }
.play-best-value.is-empty + .play-best-extra { grid-column: 1 / -1; justify-self: start; text-align: left; font-weight: 600; }
.play-button { font-size: 26px; }
.play-button.is-disabled, .play-dock-button.is-disabled { opacity: 0.45; pointer-events: none; }
.play-hint { display: flex; align-items: flex-start; justify-content: center; gap: 7px; min-height: 22px; margin-top: 14px; font-size: 14px; text-align: center; color: var(--ink-2); }
.play-hint:empty { display: none; }
.play-hint .icon { flex: none; margin-top: 2px; color: var(--grape); }
.play-hint a { font-weight: 800; }
.play-settings { margin-top: 8px; color: var(--ink-2); }

/* Papan skor ringkas */
.board-body { padding-top: 14px; }
.board-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.board-row { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 7px 10px 7px 7px; border-radius: 16px; background: var(--surface-2); }
.board-row.is-me { background: var(--yellow-soft); box-shadow: inset 0 0 0 2px var(--yellow); }
.board-row-self { margin-top: 6px; }
.board-row .rank { min-width: 34px; height: 34px; font-size: 15px; }
.board-user { display: flex; align-items: center; gap: 8px; min-width: 0; font-family: var(--font-display); font-weight: 600; }
.board-user a { color: var(--ink); }
.board-value { display: flex; flex-direction: column; align-items: flex-end; gap: 1px; }
.board-value b { font-family: var(--font-display); font-weight: 650; font-size: 16px; color: var(--ink); white-space: nowrap; }
.board-value .medals { gap: 2px; }
.board-value .stars, .board-value .crowns { gap: 0; }
.board-empty .empty-state { padding: 22px 12px; border-radius: 22px; background: var(--surface-2); border-color: var(--surface-3); }
.board-empty .empty-state h3 { font-size: 18px; }
.board-empty .empty-icon { width: 54px; height: 54px; border-radius: 18px; }
.board-body .loading-state { padding: 28px 10px; }

/* Panel kelola */
.manage-panel { margin-top: 22px; }
.manage-song { display: flex; flex-direction: column; gap: 14px; padding-bottom: 20px; border-bottom: 2px dashed var(--line); }
.manage-status-text { font-size: 15px; color: var(--ink-2); }
.manage-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.manage-danger { color: var(--red-deep); }
.manage-danger:hover { color: var(--red-deep); background: var(--red-soft); }
.manage-charts { padding-top: 18px; }
.manage-charts-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; margin-bottom: 14px; }
.manage-charts-head h3 { font-size: 19px; }
.manage-charts-head p { font-size: 14px; color: var(--text-sub); }
.manage-chart-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.manage-chart { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; padding: 12px 14px; border-radius: 18px; background: var(--surface-2); }
.manage-chart-main { display: flex; align-items: center; gap: 12px; min-width: 0; flex: 1 1 280px; }
.manage-chart-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.manage-chart-name { font-family: var(--font-display); font-weight: 600; font-size: 16px; }
.manage-chart-meta { font-size: 13px; color: var(--text-sub); }
.manage-chart-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.manage-delete { color: var(--red-deep); }
.manage-delete:hover { background: var(--red-soft); color: var(--red-deep); }
.manage-empty { display: flex; align-items: center; gap: 8px; padding: 14px; border-radius: 16px; background: var(--surface-2); color: var(--ink-2); }

.song-footnote { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 20px; margin-top: 26px; padding: 14px 18px; border-radius: 20px; background: rgba(255, 255, 255, 0.6); }
.song-footnote p { display: flex; gap: 8px; align-items: flex-start; max-width: 760px; font-size: 13.5px; color: var(--ink-2); }
.song-footnote p .icon { flex: none; margin-top: 2px; color: var(--grape-deep); }

/* Dock "Main!" mobile */
.play-dock { display: none; }

/* Modal tambah level & laporan */
.level-form { display: flex; flex-direction: column; gap: 18px; }
.level-form-diffs { margin: 0; padding: 0; border: 0; }
.level-form-diffs legend { margin-bottom: 8px; }
.diff-pick { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.diff-pick-card {
  --diff: var(--sky);
  --diff-deep: var(--sky-deep);
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px;
  border-radius: 18px;
  border: 3px solid var(--line);
  background: #fff;
  cursor: pointer;
  transition: transform 0.2s var(--bounce), border-color 0.15s var(--ease);
}
.diff-pick-card.diff-easy { --diff: var(--mint); --diff-deep: var(--mint-deep); }
.diff-pick-card.diff-hard { --diff: var(--orange); --diff-deep: var(--orange-deep); }
.diff-pick-card.diff-expert { --diff: var(--pink); --diff-deep: var(--pink-deep); }
.diff-pick-card:hover { transform: translateY(-2px); }
.diff-pick-card.is-active { border-color: var(--diff); background: color-mix(in srgb, var(--diff) 16%, #fff); box-shadow: 0 4px 0 var(--diff-deep); }
.diff-pick-card:has(input:focus-visible) { outline: 3px solid var(--grape); outline-offset: 2px; }
.diff-pick-name { font-family: var(--font-display); font-weight: 650; font-size: 17px; color: var(--ink); }
.diff-pick-desc { font-size: 12.5px; line-height: 1.35; color: var(--ink-2); }
.diff-pick-count { font-size: 11.5px; font-weight: 800; color: var(--text-sub); }
.stepper { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.stepper-value { display: grid; place-items: center; min-width: 70px; height: 50px; border-radius: 16px; background: var(--surface-2); border: 2px solid var(--line-strong); font-family: var(--font-display); font-weight: 700; font-size: 26px; color: var(--ink); }
.stepper-hint { font-size: 13.5px; font-weight: 700; color: var(--text-sub); }

.report-form { display: flex; flex-direction: column; gap: 16px; }
.report-reasons { margin: 0; padding: 0; border: 0; display: grid; gap: 8px; }
.report-reasons legend { margin-bottom: 8px; }
.report-reason { display: flex; align-items: flex-start; gap: 10px; padding: 10px 12px; border-radius: 16px; border: 2px solid var(--line); cursor: pointer; }
.report-reason:has(input:checked) { border-color: var(--grape); background: var(--grape-soft); }
.report-reason input { margin-top: 3px; width: 18px; height: 18px; accent-color: var(--grape); }
.report-reason-body { display: flex; flex-direction: column; }
.report-reason-body b { font-family: var(--font-display); font-weight: 600; color: var(--ink); }
.report-reason-body small { font-size: 13px; color: var(--ink-2); }

@media (max-width: 980px) {
  .song-layout { display: flex; flex-direction: column; align-items: stretch; gap: 16px; }
  .song-main, .song-side { display: contents; }
}

@media (max-width: 900px) {
  .play-dock {
    position: fixed;
    z-index: 40;
    left: 12px;
    right: 12px;
    bottom: max(12px, env(safe-area-inset-bottom));
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 10px 10px 14px;
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 6px 0 rgba(98, 76, 196, 0.14), var(--shadow-lg);
    transform: translateY(140%);
    transition: transform 0.35s var(--bounce);
  }
  .play-dock.is-shown { transform: none; }
  .play-dock-picks { display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; flex: 1; }
  .play-dock-button { flex: none; padding: 0 22px; }
  .song-page { padding-bottom: 110px; }
}

@media (max-width: 640px) {
  .back-link { margin-bottom: 12px; }
  .song-head { grid-template-columns: 104px minmax(0, 1fr); gap: 4px 14px; padding: 12px; border-radius: 24px; margin-bottom: 16px; }
  .song-head-cover { border-radius: 16px; align-self: start; }
  .song-head-info { padding-right: 0; }
  .song-head-title { margin-top: 6px; font-size: 25px; }
  .song-head-artist { font-size: 14.5px; }
  .song-facts { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-top: 10px; }
  .song-head-info { display: contents; }
  .song-head-info > :not(.song-facts) { grid-column: 2; }
  .song-head-badges { grid-row: 1; align-self: end; }
  .song-head-title { grid-row: 2; }
  .song-head-artist { grid-row: 3; align-self: start; }
  .song-head-cover { grid-row: 1 / span 3; }
  .song-facts li { padding: 6px 10px 6px 6px; border-radius: 14px; }
  .song-fact-icon { width: 30px; height: 30px; border-radius: 10px; }
  .song-fact-icon .icon { width: 16px; height: 16px; }
  .song-facts b { font-size: 15px; }
  .level-list { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .level-card { min-height: 70px; border-radius: 20px; }
  .level-card-lv { width: 50px; height: 50px; border-radius: 16px; }
  .level-card-lv b { font-size: 21px; }
  .mode-picker { gap: 10px; }
  .mode-picker .mode-card { padding: 12px 12px 10px; gap: 5px; border-radius: 20px; }
  .mode-picker .mode-card-icon { width: 42px; height: 42px; border-radius: 14px; }
  .mode-picker .mode-card-icon .icon { width: 21px; height: 21px; }
  .mode-picker .mode-card h3 { font-size: 18px; }
  .mode-picker .mode-card p { font-size: 12.5px; }
  .mode-card-check { width: 22px; height: 22px; right: 8px; top: 8px; }
  .mode-card-best { padding: 3px 8px; font-size: 12px; min-height: 26px; }
  .mode-card-best b { font-size: 13.5px; }
  .mode-card-best .icon { width: 13px; height: 13px; }
  .play-panel { padding: 16px 14px; }
  .play-mascot { width: 60px; margin-top: -26px; }
  .play-title { font-size: 21px; }
  .manage-actions .btn { flex: 1 1 auto; }
  .manage-chart-actions { width: 100%; }
  .manage-chart-actions .btn-sky { flex: 1; }
  .diff-pick { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .song-footnote { padding: 12px 14px; }
}

.mode-picker.is-single .mode-card { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; column-gap: 16px; row-gap: 2px; padding-right: 50px; }
.mode-picker.is-single .mode-card-icon { grid-row: 1 / span 3; align-self: start; }
.mode-picker.is-single .mode-card-best { justify-self: start; }

/* ---------------------------------------------------------------------
   Buat Lagu / Ubah Info
   ------------------------------------------------------------------- */

.upload-top { align-items: center; }
.upload-steps { list-style: none; margin: 0; padding: 6px; display: flex; align-items: center; gap: 4px; border-radius: 999px; background: rgba(255, 255, 255, 0.75); }
.upload-step { display: inline-flex; align-items: center; gap: 8px; height: 40px; padding: 0 14px 0 5px; border-radius: 999px; font-family: var(--font-display); font-weight: 600; font-size: 14.5px; color: var(--text-sub); }
.upload-step-num { display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--surface-3); color: var(--ink-2); font-size: 15px; }
.upload-step-num .step-check { display: none; }
.upload-step.is-active { background: #fff; color: var(--ink); box-shadow: 0 3px 0 var(--line-strong); }
.upload-step.is-active .upload-step-num { background: var(--grape-deep); color: #fff; }
.upload-step.is-done .upload-step-num { background: var(--mint); color: var(--ink); }
.upload-step.is-done .upload-step-num span { display: none; }
.upload-step.is-done .upload-step-num .step-check { display: block; }
.upload-step.is-next .upload-step-num { background: var(--yellow-soft); color: #9a6c00; }

/* Langkah 1: kartu jenis */
.kind-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.kind-card {
  --tint: var(--grape);
  --tint-deep: var(--grape-deep);
  --tint-soft: var(--grape-soft);
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 18px 20px 20px;
  border-radius: 30px;
  background: #fff;
  border: 3px solid #fff;
  color: var(--ink);
  box-shadow: 0 8px 0 var(--tint-soft), var(--shadow);
  transition: transform 0.28s var(--bounce), box-shadow 0.2s var(--ease);
}
.kind-card:hover { color: var(--ink); transform: translateY(-5px) rotate(-0.5deg); box-shadow: 0 10px 0 var(--tint-soft), var(--shadow-lg); }
.kind-card-audio { --tint: var(--sky); --tint-deep: var(--sky-deep); --tint-soft: var(--sky-soft); }
.kind-card-audio .kind-card-tag { color: var(--sky-ink); }
.kind-card-art {
  position: relative;
  display: block;
  height: 150px;
  margin-bottom: 8px;
  overflow: hidden;
  border-radius: 22px;
  background: linear-gradient(160deg, var(--tint-soft), #fff);
}
.kind-card-icon { position: absolute; left: 50%; top: 18px; z-index: 1; display: grid; place-items: center; width: 70px; height: 70px; margin-left: -35px; border-radius: 22px; background: var(--tint); color: #fff; border: 4px solid #fff; box-shadow: 0 5px 0 var(--tint-deep); }
.kind-keys { position: absolute; left: 50%; bottom: -18px; display: flex; gap: 4px; transform: translateX(-50%); }
.kind-keys i { position: relative; display: block; width: 38px; height: 70px; border-radius: 0 0 10px 10px; background: #fff; box-shadow: inset 0 -5px 0 var(--line), 0 0 0 2px var(--line-strong); }
.kind-keys i:nth-child(1)::after, .kind-keys i:nth-child(2)::after, .kind-keys i:nth-child(4)::after, .kind-keys i:nth-child(5)::after, .kind-keys i:nth-child(6)::after {
  content: "";
  position: absolute;
  right: -13px;
  top: 0;
  z-index: 1;
  width: 22px;
  height: 40px;
  border-radius: 0 0 7px 7px;
  background: var(--ink);
}
.kind-wave { position: absolute; inset: auto 14px 12px; display: flex; align-items: flex-end; justify-content: space-between; height: 56px; }
.kind-wave i { display: block; width: 8%; border-radius: 8px; background: color-mix(in srgb, var(--sky) 45%, #fff); animation: wave-bounce 1.4s var(--ease) infinite; }
.kind-wave i:nth-child(1) { height: 30%; animation-delay: -0.2s; }
.kind-wave i:nth-child(2) { height: 60%; animation-delay: -0.5s; }
.kind-wave i:nth-child(3) { height: 42%; animation-delay: -0.9s; }
.kind-wave i:nth-child(4) { height: 80%; animation-delay: -0.3s; }
.kind-wave i:nth-child(5) { height: 55%; animation-delay: -1.1s; }
.kind-wave i:nth-child(6) { height: 90%; animation-delay: -0.7s; }
.kind-wave i:nth-child(7) { height: 45%; animation-delay: -0.1s; }
.kind-wave i:nth-child(8) { height: 70%; animation-delay: -0.6s; }
.kind-wave i:nth-child(9) { height: 35%; animation-delay: -1s; }
@keyframes wave-bounce { 0%, 100% { transform: scaleY(1); } 50% { transform: scaleY(0.6); } }
.kind-card-tag { align-self: flex-start; padding: 3px 12px; border-radius: 999px; background: var(--tint-soft); color: var(--grape-ink); font-family: var(--font-display); font-weight: 600; font-size: 13px; }
.kind-card-title { font-family: var(--font-display); font-weight: 700; font-size: 28px; line-height: 1.1; }
.kind-card-desc { font-size: 15.5px; color: var(--ink-2); }
.kind-card-points { display: flex; flex-direction: column; gap: 6px; margin: 6px 0 10px; }
.kind-card-points span { display: flex; align-items: flex-start; gap: 8px; font-size: 14.5px; font-weight: 700; color: var(--ink-2); }
.kind-card-points .icon { flex: none; margin-top: 2px; color: var(--mint-deep); }
.kind-card-cta { margin-top: auto; }
.kind-note { display: flex; gap: 8px; align-items: flex-start; justify-content: center; margin-top: 22px; font-size: 14px; color: var(--ink-2); text-align: center; }
.kind-note .icon { flex: none; margin-top: 2px; color: var(--grape-deep); }

/* Langkah 2: form */
.upload-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; align-items: start; gap: 22px; }
.upload-form-head { display: flex; align-items: center; gap: 14px; padding: 18px clamp(18px, 3vw, 26px) 0; }
.upload-kind-icon { flex: none; display: grid; place-items: center; width: 54px; height: 54px; border-radius: 18px; background: var(--grape); color: #fff; box-shadow: 0 4px 0 var(--grape-deep); }
.upload-form.is-audio .upload-kind-icon, .page-upload[data-kind="audio"] .upload-kind-icon { background: var(--sky); box-shadow: 0 4px 0 var(--sky-deep); }
.upload-form-titles { min-width: 0; flex: 1; }
.upload-form-titles .eyebrow { font-size: 12px; }
.upload-form-titles h2 { font-size: 25px; font-weight: 700; }
.upload-form-body { display: flex; flex-direction: column; gap: 20px; }
.upload-form-body > .notice { margin: 0; }

.bpm-presets { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-bottom: 4px; }
.bpm-preset {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 58px;
  padding: 8px 12px;
  border-radius: 18px;
  border: 3px solid var(--line);
  background: #fff;
  color: var(--ink-2);
  text-align: left;
  box-shadow: 0 3px 0 var(--line);
  transition: transform 0.2s var(--bounce), border-color 0.15s var(--ease);
}
.bpm-preset:hover { transform: translateY(-2px); color: var(--ink); }
.bpm-preset .icon { flex: none; color: var(--grape); }
.bpm-preset span { display: flex; flex-direction: column; line-height: 1.15; }
.bpm-preset b { font-family: var(--font-display); font-weight: 650; font-size: 16px; color: var(--ink); }
.bpm-preset small { font-size: 12.5px; font-weight: 700; color: var(--text-sub); }
.bpm-preset.is-active { border-color: var(--grape); background: var(--grape-soft); box-shadow: 0 3px 0 var(--grape-deep); }
.bpm-row { display: flex; flex-wrap: wrap; gap: 10px; }
.bpm-input-wrap { position: relative; flex: 0 1 200px; min-width: 150px; }
.bpm-input { padding-right: 58px; font-family: var(--font-display); font-size: 19px; }
.bpm-unit { position: absolute; right: 16px; top: 50%; transform: translateY(-50%); font-family: var(--font-display); font-weight: 600; font-size: 13px; color: var(--text-sub); pointer-events: none; }
.tap-button { height: 50px; }
.tap-button.is-tapped { animation: tap-pop 0.25s var(--bounce); }
@keyframes tap-pop { 0% { transform: scale(0.94); } 100% { transform: scale(1); } }
.tap-count { display: grid; place-items: center; min-width: 26px; height: 26px; padding: 0 6px; border-radius: 999px; background: var(--grape-deep); color: #fff; font-size: 13px; }
.upload-bpm-note { margin: 0; }

.visibility-field { margin: 0; padding: 0; border: 0; min-width: 0; }
.visibility-field legend { margin-bottom: 7px; }
.visibility-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.visibility-option { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 18px; border: 3px solid var(--line); background: #fff; cursor: pointer; transition: border-color 0.15s var(--ease), transform 0.2s var(--bounce); }
.visibility-option:hover { transform: translateY(-2px); }
.visibility-option.is-active { border-color: var(--grape); background: var(--grape-soft); }
.visibility-option:has(input:focus-visible) { outline: 3px solid var(--grape); outline-offset: 2px; }
.visibility-option.is-disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.visibility-icon { flex: none; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; background: var(--tint-soft); color: var(--tint); }
.visibility-text { display: flex; flex-direction: column; min-width: 0; }
.visibility-text b { font-family: var(--font-display); font-weight: 650; font-size: 16.5px; color: var(--ink); }
.visibility-text small { font-size: 13px; line-height: 1.35; color: var(--ink-2); }

.media-drop { min-height: 84px; }
.media-drop-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.media-drop-text .dropzone-title { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.media-drop .btn, .media-drop .media-remove { position: relative; z-index: 2; }
.media-drop.is-invalid { border-color: var(--red); background: var(--red-soft); }
.media-drop.is-static { cursor: default; }
.media-drop.is-static:hover { transform: none; }
.cover-preview { flex: none; display: grid; place-items: center; width: 64px; height: 64px; overflow: hidden; border-radius: 16px; background: #fff; box-shadow: 0 3px 0 var(--line-strong); }
.cover-preview img { width: 100%; height: 100%; object-fit: cover; }
.cover-preview-empty { color: var(--grape); }
.audio-progress { height: 8px; margin-top: 8px; overflow: hidden; border-radius: 999px; background: var(--surface-3); }
.audio-progress span { display: block; width: 0; height: 100%; border-radius: inherit; background: var(--sky); transition: width 0.2s linear; }

.copyright-notice { margin: 0; }
.copyright-notice .check { font-weight: 700; }

.upload-progress { padding: 14px; border-radius: 18px; background: var(--mint-soft); }
.upload-progress-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.upload-progress-label { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-display); font-weight: 600; color: var(--ink); }
.upload-progress-label .spinner { width: 18px; height: 18px; border-width: 3px; }
.upload-progress-pct { font-family: var(--font-display); font-weight: 700; color: var(--mint-deep); }
.upload-form.is-uploading .upload-form-body { opacity: 0.85; }

.upload-form-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 16px;
  padding: 16px clamp(18px, 3vw, 26px) 20px;
  border-top: 2px dashed var(--line);
}
.upload-foot-note { font-size: 14px; color: var(--ink-2); }
.upload-foot-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-left: auto; }

.tips-card { position: sticky; top: 90px; padding: 20px 18px 18px; margin-top: 30px; }
.tips-mascot { width: 84px; margin: -58px auto 4px; filter: drop-shadow(0 8px 10px rgba(43, 35, 86, 0.16)); }
.tips-title { text-align: center; font-size: 21px; font-weight: 700; margin-bottom: 14px; }
.tips-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.tips-list li { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; line-height: 1.45; color: var(--ink-2); }
.tips-list b { color: var(--ink); }
.tips-icon { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 12px; background: var(--tint-soft); color: var(--tint); }

@media (max-width: 980px) {
  .upload-layout { grid-template-columns: minmax(0, 1fr); }
  .tips-card { position: static; margin-top: 40px; }
}

@media (max-width: 720px) {
  .upload-steps { width: 100%; justify-content: space-between; }
  .upload-step { padding: 0 10px 0 5px; font-size: 13.5px; gap: 6px; }
  .kind-grid { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .kind-card { padding: 14px 16px 16px; border-radius: 26px; }
  .kind-card-art { height: 116px; }
  .kind-card-icon { width: 60px; height: 60px; margin-left: -30px; top: 12px; border-radius: 20px; }
  .kind-keys i { width: 32px; height: 56px; }
  .kind-keys i::after { height: 32px !important; width: 18px !important; right: -11px !important; }
  .kind-card-title { font-size: 24px; }
  .upload-form-head { padding-top: 16px; flex-wrap: wrap; }
  .upload-kind-icon { width: 46px; height: 46px; border-radius: 15px; }
  .upload-form-titles h2 { font-size: 21px; }
  .bpm-presets { gap: 8px; }
  .bpm-preset { flex-direction: column; align-items: center; gap: 2px; padding: 8px 4px; text-align: center; }
  .bpm-preset span { align-items: center; }
  .visibility-options { grid-template-columns: minmax(0, 1fr); }
  .upload-foot-actions { width: 100%; }
  .upload-foot-actions .btn-lg { flex: 1; }
  .media-drop { gap: 12px; padding: 12px; }
}

/* ---------------------------------------------------------------------
   Papan Skor
   ------------------------------------------------------------------- */

.lb-top { padding-right: 150px; min-height: 120px; }
.lb-mascot { position: absolute; right: 6px; bottom: -26px; width: 124px; transform: rotate(-5deg); filter: drop-shadow(0 10px 12px rgba(43, 35, 86, 0.16)); pointer-events: none; }

.lb-controls { position: relative; z-index: 3; display: flex; flex-direction: column; gap: 16px; padding: 16px; margin-bottom: 18px; }
.lb-scope { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; padding: 5px; border-radius: 20px; background: var(--surface-3); }
.lb-scope-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 12px;
  border: 0;
  border-radius: 15px;
  background: transparent;
  color: var(--ink-2);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 16px;
  transition: background-color 0.15s var(--ease), color 0.15s var(--ease);
}
.lb-scope-btn:hover { color: var(--ink); background: rgba(255, 255, 255, 0.5); }
.lb-scope-btn .icon { color: var(--grape); }
.lb-scope-btn.is-active { background: #fff; color: var(--grape-deep); box-shadow: 0 3px 0 var(--line-strong); }
.lb-scope-hint { display: flex; align-items: center; gap: 8px; font-size: 14.5px; font-weight: 700; color: var(--ink-2); }
.lb-scope-hint .icon { color: var(--yellow); filter: drop-shadow(0 1.5px 0 var(--yellow-deep)); }

.lb-pickers { display: grid; grid-template-columns: minmax(260px, 380px) minmax(0, 1fr); align-items: end; gap: 14px 18px; }
.lb-picker { position: relative; display: flex; flex-direction: column; gap: 6px; }
.lb-picker .input { padding-right: 50px; }
.lb-picker.has-value .input { background: var(--grape-soft); border-color: var(--grape); }
.picker-list {
  position: absolute;
  z-index: 20;
  left: 0;
  right: 0;
  top: calc(100% + 8px);
  max-height: 340px;
  overflow-y: auto;
  margin: 0;
  padding: 6px;
  list-style: none;
  border-radius: 20px;
  background: #fff;
  border: 2px solid var(--line);
  box-shadow: var(--shadow-lg);
}
.picker-option { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 14px; cursor: pointer; }
.picker-option:hover, .picker-option.is-active { background: var(--surface-3); }
.picker-option[aria-selected="true"] { background: var(--grape-soft); }
.picker-cover { position: relative; flex: none; width: 44px; height: 44px; overflow: hidden; border-radius: 12px; background: var(--surface-3); }
.picker-cover img { width: 100%; height: 100%; object-fit: cover; }
.picker-cover .cover-placeholder .icon { width: 55%; height: 55%; }
.picker-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.picker-title { font-family: var(--font-display); font-weight: 600; color: var(--ink); }
.picker-sub { font-size: 13px; color: var(--text-sub); }
.picker-status { display: flex; align-items: center; gap: 8px; padding: 12px; font-weight: 700; color: var(--ink-2); }
.picker-status .spinner { width: 18px; height: 18px; border-width: 3px; }

.lb-levels { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.lb-level-chip { --diff: var(--sky); height: 46px; }
.lb-level-chip.diff-easy { --diff: var(--mint); }
.lb-level-chip.diff-hard { --diff: var(--orange); }
.lb-level-chip.diff-expert { --diff: var(--pink); }
.lb-level-chip .diff-dot { box-shadow: 0 0 0 2px #fff; }
.lb-level-lv { font-size: 13px; opacity: 0.85; }
.lb-level-name { max-width: 120px; font-size: 13px; opacity: 0.85; }

.lb-modes { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding-top: 14px; border-top: 2px dashed var(--line); }
.lb-mode-list { display: flex; flex-wrap: wrap; gap: 8px; }
.lb-mode {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 44px;
  padding: 0 16px 0 12px;
  border-radius: 999px;
  border: 2px solid var(--mode-soft);
  background: #fff;
  color: var(--ink-2);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 15px;
  box-shadow: 0 3px 0 var(--mode-soft);
  transition: transform 0.2s var(--bounce), background-color 0.15s var(--ease);
}
.lb-mode .icon { color: var(--mode-deep); }
.lb-mode:hover { transform: translateY(-2px); color: var(--ink); }
.lb-mode.is-active { background: var(--mode); border-color: var(--mode); color: var(--ink); box-shadow: 0 3px 0 var(--mode-deep); }
.lb-mode.is-active .icon { color: var(--ink); }
.lb-mode:disabled { opacity: 0.4; transform: none; cursor: not-allowed; }
.lb-mode-note { display: flex; align-items: center; gap: 6px; font-size: 13.5px; font-weight: 700; color: var(--ink-2); }
.lb-mode-note .icon { color: var(--sky-deep); }

.lb-context { display: flex; align-items: center; gap: 14px; padding: 12px; margin-bottom: 16px; }
.lb-context-cover { position: relative; flex: none; width: 76px; height: 76px; overflow: hidden; border-radius: 18px; background: var(--surface-3); }
.lb-context-cover img { width: 100%; height: 100%; object-fit: cover; }
.lb-context-cover .cover-placeholder .icon { width: 50%; height: 50%; }
.lb-context-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; flex: 1; }
.lb-context-badges { display: flex; flex-wrap: wrap; gap: 6px; }
.lb-context-title { font-family: var(--font-display); font-weight: 650; font-size: 21px; color: var(--ink); }
.lb-context-sub { font-size: 14px; color: var(--text-sub); }
.lb-context-actions { display: flex; flex-wrap: wrap; gap: 8px; }

.lb-me { margin-bottom: 18px; }
.lb-me-card { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding: 10px 16px 10px 10px; border-radius: 22px; background: var(--yellow-soft); border: 3px solid var(--yellow); box-shadow: 0 4px 0 var(--yellow-deep); }
.lb-me-card.is-guest, .lb-me-card.is-empty { padding: 12px 16px; background: rgba(255, 255, 255, 0.8); border-color: #fff; box-shadow: 0 4px 0 rgba(98, 76, 196, 0.12); font-weight: 700; color: var(--ink-2); }
.lb-me-card.is-guest .icon, .lb-me-card.is-empty > .icon { color: var(--grape); }
.lb-me-card.is-empty .btn { margin-left: auto; }
.lb-me-rank { display: flex; flex-direction: column; line-height: 1.1; }
.lb-me-rank small { font-size: 12.5px; font-weight: 800; color: #8a6200; }
.lb-me-rank b { font-family: var(--font-display); font-weight: 700; font-size: 26px; color: var(--ink); }
.lb-me-value { display: flex; flex-direction: column; align-items: flex-end; margin-left: auto; }
.lb-me-main { display: flex; align-items: center; gap: 10px; font-family: var(--font-display); font-size: 22px; color: var(--ink); }
.lb-me-sub { font-size: 13px; font-weight: 700; color: var(--ink-2); }

.lb-medal-count { display: inline-flex; align-items: center; gap: 4px; }
.lb-medal-count b { font-family: var(--font-display); font-weight: 650; }
.lb-star { color: var(--yellow); filter: drop-shadow(0 1.5px 0 var(--yellow-deep)); }
.lb-crown { color: var(--orange); filter: drop-shadow(0 1.5px 0 var(--orange-deep)); }

/* Podium */
.podium { list-style: none; margin: 34px 0 22px; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 14px; max-width: 700px; margin-left: auto; margin-right: auto; }
.podium-spot {
  --place: #dfe6f3;
  --place-deep: #b8c3d8;
  --block: 120px;
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 0;
  text-align: center;
}
.podium-spot { grid-row: 1; }
.podium-spot.place-1 { grid-column: 2; --place: var(--yellow); --place-deep: var(--yellow-deep); --block: 160px; }
.podium-spot.place-2 { grid-column: 1; }
.podium-spot.place-3 { grid-column: 3; --place: #ffc79a; --place-deep: #e59a5f; --block: 96px; }
.podium-spot.is-empty .podium-avatar .avatar-empty { display: grid; place-items: center; width: 68px; height: 68px; border-radius: 50%; background: rgba(255, 255, 255, 0.6); border: 3px dashed var(--line-strong); color: var(--text-sub); font-family: var(--font-display); font-weight: 700; font-size: 26px; }
.podium-spot.is-empty .podium-name { color: var(--text-sub); }
.podium-spot.is-empty .podium-block { opacity: 0.45; }
.podium-avatar { position: relative; display: grid; place-items: center; margin-bottom: 4px; }
.podium-avatar .avatar { border: 5px solid #fff; box-shadow: 0 5px 0 var(--place-deep), 0 10px 24px rgba(43, 35, 86, 0.16); }
.podium-crown { position: absolute; top: -28px; left: 50%; z-index: 1; margin-left: -15px; color: var(--yellow); filter: drop-shadow(0 3px 0 var(--yellow-deep)); animation: crown-bob 2.2s var(--ease) infinite; }
@keyframes crown-bob { 0%, 100% { transform: translateY(0) rotate(-6deg); } 50% { transform: translateY(-5px) rotate(6deg); } }
.podium-rank { position: absolute; right: -6px; bottom: -4px; display: grid; place-items: center; width: 30px; height: 30px; border-radius: 50%; background: var(--place); color: var(--ink); border: 3px solid #fff; font-family: var(--font-display); font-weight: 700; font-size: 15px; }
.podium-name { max-width: 100%; font-family: var(--font-display); font-weight: 650; font-size: 18px; color: var(--ink); }
.podium-value { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 10px; font-family: var(--font-display); font-size: 24px; color: var(--ink); }
.podium-value b { font-weight: 700; }
.podium-sub { font-size: 13px; font-weight: 700; color: var(--ink-2); min-height: 20px; }
.podium-sub .medals { justify-content: center; gap: 3px; }
.podium-sub .stars, .podium-sub .crowns { gap: 0; }
.podium-chart .diff-badge { height: 24px; font-size: 12px; }
.podium-block {
  width: 100%;
  height: var(--block);
  margin-top: 10px;
  border-radius: 22px 22px 10px 10px;
  background:
    radial-gradient(circle at 50% 30%, rgba(255, 255, 255, 0.55) 0 22px, transparent 23px),
    var(--place);
  box-shadow: inset 0 -8px 0 rgba(43, 35, 86, 0.08), 0 6px 0 var(--place-deep);
}
.podium-spot.is-me .podium-name { color: var(--grape-deep); }

/* Tabel & kartu */
.lb-table { margin-top: 8px; }
.lb-table .table td { padding-top: 10px; padding-bottom: 10px; }
.lb-table .col-rank { width: 64px; }
.lb-table .lb-score { font-family: var(--font-display); font-weight: 650; font-size: 17px; color: var(--ink); }
.lb-table .lb-score small { font-family: var(--font-sans); font-size: 12px; color: var(--text-sub); }
.lb-table .medals { gap: 4px; }
.lb-table .stars, .lb-table .crowns { gap: 0; }
.lb-table tr.is-me { background: var(--yellow-soft); }
.lb-table tr.is-me:hover { background: var(--yellow-soft); }
.lb-you { height: 22px; font-size: 11px; }
.lb-cards { display: none; list-style: none; margin: 8px 0 0; padding: 0; }

/* Tablet portrait: tabel masih tampil, kolom waktu disembunyikan agar tidak terpotong */
@media (max-width: 900px) and (min-width: 761px) {
  .lb-table th:last-child, .lb-table td:last-child { display: none; }
}

@media (max-width: 760px) {
  .lb-top { padding-right: 90px; min-height: 0; }
  .lb-mascot { width: 82px; bottom: auto; top: 6px; }
  .lb-controls { padding: 12px; gap: 14px; border-radius: 24px; }
  .lb-scope { gap: 4px; padding: 4px; border-radius: 18px; }
  .lb-scope-btn { flex-direction: column; gap: 2px; min-height: 58px; padding: 6px 4px; font-size: 13.5px; border-radius: 14px; }
  .lb-pickers { grid-template-columns: minmax(0, 1fr); }
  .lb-modes { flex-direction: column; align-items: stretch; }
  .lb-mode-list { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
  .lb-mode { flex-direction: column; justify-content: center; gap: 2px; height: 58px; padding: 4px; border-radius: 16px; font-size: 13.5px; }
  .lb-context { flex-wrap: wrap; }
  .lb-context-cover { width: 60px; height: 60px; border-radius: 15px; }
  .lb-context-title { font-size: 18px; }
  .lb-context-actions { width: 100%; }
  .lb-context-actions .btn { flex: 1; }
  .lb-me-card { gap: 8px 10px; }
  .lb-me-rank b { font-size: 22px; }
  .lb-me-main { font-size: 18px; gap: 8px; }
  .lb-me-main .icon { width: 17px; height: 17px; }
  .podium { gap: 8px; margin-top: 30px; }
  .podium-spot { --block: 84px; }
  .podium-spot.place-1 { --block: 116px; }
  .podium-spot.place-3 { --block: 64px; }
  .podium-avatar .avatar { width: 56px !important; height: 56px !important; border-width: 4px; }
  .podium-spot.place-1 .podium-avatar .avatar { width: 70px !important; height: 70px !important; }
  .podium-crown { top: -24px; }
  .podium-crown .icon { width: 24px; height: 24px; }
  .podium-crown { margin-left: -12px; }
  .podium-rank { width: 26px; height: 26px; font-size: 13px; }
  .podium-spot.is-empty .podium-avatar .avatar-empty { width: 56px; height: 56px; font-size: 22px; }
  .podium-name { font-size: 15px; }
  .podium-value { font-size: 18px; gap: 6px; }
  .podium-value .icon { width: 15px; height: 15px; }
  .podium-sub { font-size: 11.5px; }
  .podium-sub .icon { width: 12px; height: 12px; }
  .podium-block { border-radius: 16px 16px 8px 8px; }
  .lb-table { display: none; }
  .lb-cards { display: grid; gap: 8px; }
  .lb-card { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 10px 12px 10px 10px; border-radius: 20px; background: #fff; box-shadow: 0 4px 0 rgba(98, 76, 196, 0.1); }
  .lb-card.is-me { background: var(--yellow-soft); box-shadow: 0 4px 0 var(--yellow-deep); }
  .lb-card-player { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
  .lb-card-player .cell-user { display: flex; align-items: center; gap: 8px; min-width: 0; }
  .lb-card-player .cell-user a { color: var(--ink); font-family: var(--font-display); font-weight: 600; }
  .lb-card-chart .diff-badge { height: 22px; font-size: 11px; padding: 0 9px; }
  .lb-card-value { display: flex; flex-direction: column; align-items: flex-end; text-align: right; }
  .lb-card-main { display: flex; align-items: center; gap: 8px; font-family: var(--font-display); font-size: 18px; color: var(--ink); }
  .lb-card-main .icon { width: 16px; height: 16px; }
  .lb-card-sub { font-size: 12px; font-weight: 700; color: var(--text-sub); }
  .lb-card-sub .medals { gap: 2px; }
  .lb-card-sub .stars, .lb-card-sub .crowns { gap: 0; }
  .lb-card-sub .icon { width: 13px; height: 13px; }
}

/* ---------------------------------------------------------------------
   Hasil permainan
   ------------------------------------------------------------------- */

.result-page { position: relative; }
.result-confetti { position: fixed; z-index: 70; }
.result-shell { max-width: 600px; margin: 0 auto; }
.result-topbar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 70px; }
.result-topbar .back-link { margin-bottom: 0; }
.result-topbar .btn.is-copied { --btn-bg: var(--mint-soft); }

.result-card {
  --mode: var(--pink);
  --mode-deep: var(--pink-deep);
  position: relative;
  padding: 70px clamp(18px, 4vw, 34px) clamp(20px, 4vw, 30px);
  border-radius: 36px;
  background: #fff;
  border: 4px solid #fff;
  text-align: center;
  box-shadow: 0 10px 0 rgba(98, 76, 196, 0.18), var(--shadow-lg);
  animation: result-pop 0.55s var(--bounce);
}
@keyframes result-pop { from { opacity: 0; transform: translateY(24px) scale(0.92); } }
.result-mascot { position: absolute; left: 50%; top: -78px; transform: translateX(-50%); }
.result-mascot .mascot { width: 124px; filter: drop-shadow(0 10px 12px rgba(43, 35, 86, 0.18)); animation: mascot-bounce 2.4s var(--ease) infinite; }
.result-eyebrow { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.result-eyebrow .mode-pill { height: 28px; font-size: 14px; }
.result-title { margin-top: 10px; font-size: clamp(32px, 7vw, 44px); font-weight: 700; line-height: 1.08; }

.result-medals { display: grid; gap: 6px; margin: 16px 0 4px; }
.result-medal-row { display: flex; justify-content: center; align-items: flex-end; gap: 8px; }
.result-medal { display: inline-grid; place-items: center; color: #e8e3f6; }
.result-stars .result-medal:nth-child(2) { transform: translateY(-14px); }
.result-medal .icon { width: 70px; height: 70px; }
.result-medal-crown .icon { width: 42px; height: 42px; }
.result-medal.is-on { color: var(--yellow); animation: result-medal-in 0.6s var(--bounce) both; animation-delay: calc(var(--i) * 0.2s + 0.25s); }
.result-medal.is-on .icon { filter: drop-shadow(0 4px 0 var(--yellow-deep)); }
.result-medal-crown.is-on { color: var(--orange); }
.result-medal-crown.is-on .icon { filter: drop-shadow(0 3px 0 var(--orange-deep)); }
.result-stars .result-medal:nth-child(2).is-on { animation-name: result-medal-in-mid; }
@keyframes result-medal-in { 0% { opacity: 0; transform: scale(0.2) rotate(-30deg); } 70% { opacity: 1; transform: scale(1.22) rotate(8deg); } 100% { opacity: 1; transform: none; } }
@keyframes result-medal-in-mid { 0% { opacity: 0; transform: translateY(-14px) scale(0.2) rotate(-30deg); } 70% { opacity: 1; transform: translateY(-14px) scale(1.22) rotate(8deg); } 100% { opacity: 1; transform: translateY(-14px); } }

.result-main { margin-top: 10px; }
.result-main small { display: block; font-family: var(--font-display); font-weight: 600; font-size: 15px; color: var(--text-sub); }
.result-main b { display: block; font-family: var(--font-display); font-weight: 700; font-size: clamp(54px, 13vw, 76px); line-height: 1.02; color: var(--pink-deep); }
.mode-arcade .result-main b { color: var(--sky-deep); }
.mode-zen .result-main b { color: var(--mint-deep); }
.mode-rush .result-main b { color: var(--orange-deep); }

.result-badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 10px; }
.result-best, .result-rank {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15px;
}
.result-best { background: var(--yellow); color: var(--ink); box-shadow: 0 3px 0 var(--yellow-deep); animation: best-wiggle 1.4s var(--ease) infinite; }
.result-rank { background: var(--grape-soft); color: var(--grape-deep); }
@keyframes best-wiggle { 0%, 100% { transform: rotate(-3deg); } 50% { transform: rotate(3deg) scale(1.04); } }

.result-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(96px, 1fr)); gap: 10px; margin-top: 20px; }
.result-stat { display: grid; justify-items: center; gap: 1px; padding: 10px 6px; border-radius: 18px; background: var(--surface-2); border: 2px solid var(--line); }
.result-stat .icon { color: var(--grape); }
.result-stat span { font-size: 12.5px; font-weight: 700; color: var(--text-sub); }
.result-stat b { font-family: var(--font-display); font-weight: 650; font-size: 19px; color: var(--ink); }

.result-song { display: flex; align-items: center; gap: 12px; margin-top: 18px; padding: 10px 14px 10px 10px; border-radius: 20px; background: var(--surface-2); color: var(--ink); text-align: left; transition: transform 0.2s var(--bounce); }
.result-song:hover { color: var(--ink); transform: translateY(-2px); }
.result-song-cover { position: relative; flex: none; width: 58px; height: 58px; overflow: hidden; border-radius: 15px; background: var(--surface-3); }
.result-song-cover img { width: 100%; height: 100%; object-fit: cover; }
.result-song-cover .cover-placeholder .icon { width: 50%; height: 50%; }
.result-song-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.result-song-title { font-family: var(--font-display); font-weight: 650; font-size: 17px; }
.result-song-sub { font-size: 13.5px; color: var(--text-sub); }

.result-player { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; padding: 0 4px; text-align: left; }
.result-player-link { display: flex; align-items: center; gap: 10px; color: var(--ink); }
.result-player-link span, .result-date { display: flex; flex-direction: column; line-height: 1.2; }
.result-player small, .result-date small { font-size: 12px; font-weight: 700; color: var(--text-sub); }
.result-player b { font-family: var(--font-display); font-weight: 650; font-size: 16px; }
.result-date { text-align: right; font-size: 14px; font-weight: 700; color: var(--ink-2); }

.result-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 20px; padding-top: 18px; border-top: 2px dashed var(--line); }
.result-actions .result-retry { flex: 1 1 100%; }
.result-actions .btn-secondary { flex: 1 1 180px; }

@media (max-width: 480px) {
  .result-topbar { margin-bottom: 64px; }
  .result-card { padding-top: 62px; border-radius: 30px; }
  .result-mascot { top: -68px; }
  .result-mascot .mascot { width: 104px; }
  .result-medal .icon { width: 58px; height: 58px; }
  .result-medal-crown .icon { width: 36px; height: 36px; }
  .result-stats { gap: 8px; }
  .result-stats.stats-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .result-stats.stats-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .result-stat b { font-size: 17px; }
  .result-player { flex-direction: column; align-items: flex-start; }
  .result-date { text-align: left; }
  .result-actions .btn-lg { height: 52px; font-size: 17px; }
}

@media (prefers-reduced-motion: reduce) {
  .stage-track, .stage-tap, .stage-bubble, .stage-float, .kind-wave i, .podium-crown, .result-best, .result-mascot .mascot, .create-mascot { animation: none !important; }
}
