/*
 * Pilot Season (Mega Season 1) styles.
 *
 * One stylesheet, loaded twice on purpose: once in the document head for the
 * hub card and the reward dialog (light DOM), and once inside the lobby's
 * shadow root for the lobby itself. Rules under ":host" only apply in the
 * shadow tree; ".dg-pilot-*" light rules never match inside it.
 *
 * Palette, display face, title shadow, plate, and destination art come from
 * the season skin (SEASON_THEME → --mega-* custom properties). Rules below
 * must keep using those tokens so the next season does not fork this file.
 * Pilot art never inherits an App Skin.
 */

@font-face {
  font-family: "Pilot Display";
  src: url("/games/common/fonts/pilot-display.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

/* ---------------------------------------------------------------------- */
/* Hub card (light DOM) — mirrors the daily game rows exactly.             */
/* ---------------------------------------------------------------------- */

.dg-pilot-season-block { margin: 0 0 1.25rem; }

.app-card.dg-pilot-season-card {
  position: relative;
  overflow: visible;
  width: 100%;
  font: inherit;
  text-align: left;
  cursor: pointer;
  color: #f3e6cf;
  border: 0;
  background-color: #1a1020;
  background-image:
    linear-gradient(90deg, rgba(12, 8, 16, 0.88) 0%, rgba(12, 8, 16, 0.55) 46%, rgba(12, 8, 16, 0.28) 100%),
    var(--mega-plate, url("/games/assets/seasons/last-swing/plate.webp"));
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center 42%;
}

.app-card.dg-pilot-season-card:hover {
  border: 0;
  background-color: #1a1020;
  transform: none;
}

.dg-pilot-season-markwrap {
  position: relative;
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
}
.dg-pilot-season-mark {
  display: block;
  width: 48px;
  height: 48px;
  object-fit: contain;
  background: transparent;
}

.dg-pilot-season-card.is-ready {
  animation: dgPilotReady 1.6s ease-in-out infinite;
}

@keyframes dgPilotReady {
  0%, 100% { box-shadow: 0 0 10px rgba(246, 210, 127, 0.34); }
  50% { box-shadow: 0 0 18px rgba(246, 210, 127, 0.62); }
}

.dg-pilot-season-card.is-upcoming {
  cursor: default;
  animation: none;
  box-shadow: none;
}
.dg-pilot-season-card.is-upcoming [data-season-detail] { display: none !important; }
.dg-pilot-season-card.is-upcoming [data-season-title] {
  font-family: "Pilot Display", "Space Grotesk", system-ui, sans-serif !important;
  font-weight: 400 !important;
  font-style: normal;
  color: var(--mega-gold, #f6d27f) !important;
  -webkit-text-fill-color: var(--mega-gold, #f6d27f);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
  font-size: 1.35rem;
  line-height: 1.05;
  text-shadow: var(--mega-title-shadow, 0 3px 0 #3a2414);
  text-align: center;
  padding-right: 3.75rem;
  white-space: nowrap;
}
.dg-pilot-season-card.is-upcoming:hover { transform: none; }

.dg-pilot-season-card.is-done {
  opacity: 0.78;
  filter: grayscale(0.22);
  animation: none;
  box-shadow: none;
}
.dg-pilot-season-check {
  display: none;
  position: absolute;
  right: -4px;
  bottom: -4px;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #22c55e;
  color: #052e16;
  align-items: center;
  justify-content: center;
  border: 2px solid rgba(15, 23, 42, 0.9);
  box-shadow: 0 4px 8px rgba(15, 23, 42, 0.4);
  filter: none;
}
.dg-pilot-season-card.is-done .dg-pilot-season-check { display: inline-flex; }
.dg-pilot-season-check svg { width: 14px; height: 14px; }

/* ---------------------------------------------------------------------- */
/* App Skin Isolation: BIG GRID hub card, dialogs, and event lobby never  */
/* inherit App Skin borders, layovers (::before/::after), duotone filters,*/
/* or display fonts.                                                      */
/* ---------------------------------------------------------------------- */
[data-shell-theme] .app-card.dg-pilot-season-card {
  border: 0 !important;
  border-width: 0 !important;
  border-style: none !important;
  border-color: transparent !important;
  border-image: none !important;
  border-radius: 1rem !important;
  background-color: #1a1020 !important;
  background-image:
    linear-gradient(90deg, rgba(12, 8, 16, 0.88) 0%, rgba(12, 8, 16, 0.55) 46%, rgba(12, 8, 16, 0.28) 100%),
    var(--mega-plate, url("/games/assets/seasons/last-swing/plate.webp")) !important;
  background-repeat: no-repeat !important;
  background-size: cover !important;
  background-position: center 42% !important;
}
[data-shell-theme] .app-card.dg-pilot-season-card:not(.is-ready) {
  box-shadow: none !important;
}
[data-shell-theme] .app-card.dg-pilot-season-card::before,
[data-shell-theme] .app-card.dg-pilot-season-card::after {
  content: none !important;
  display: none !important;
  background: none !important;
  border: 0 !important;
  filter: none !important;
  animation: none !important;
}
[data-shell-theme] #dg-season-screen img {
  filter: none !important;
}
[data-shell-theme] .dg-pilot-season-block .app-section-title {
  font-family: 'Space Grotesk', system-ui, -apple-system, sans-serif !important;
  font-size: 0.75rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.14em !important;
  text-transform: uppercase !important;
  text-shadow: none !important;
  color: #94a3b8 !important;
}
[data-shell-theme] .app-card.dg-pilot-season-card:not(.is-upcoming) [data-season-title] {
  font-family: 'Space Grotesk', system-ui, -apple-system, sans-serif !important;
  text-shadow: none !important;
  color: #f3e6cf !important;
  -webkit-text-fill-color: #f3e6cf !important;
}
[data-shell-theme] .app-card.dg-pilot-season-card .play-text {
  font-family: 'Space Grotesk', system-ui, -apple-system, sans-serif !important;
  font-size: 0.875rem !important;
  font-weight: 600 !important;
  letter-spacing: normal !important;
  text-transform: none !important;
  text-shadow: none !important;
  color: #fbbf24 !important;
}
[data-shell-theme] .dg-pilot-dialog,
[data-shell-theme] .dg-pilot-dialog h1,
[data-shell-theme] .dg-pilot-dialog h2:not(.shop-tagline):not(.mega-tag),
[data-shell-theme] .dg-pilot-dialog h3 {
  font-family: 'Space Grotesk', system-ui, -apple-system, sans-serif !important;
  text-shadow: none !important;
}
html.dg-pilot-lobby-open[data-shell-theme]::before,
html.dg-pilot-lobby-open[data-shell-theme]::after {
  content: none !important;
  display: none !important;
}

.canary-stepper {
  position: absolute;
  z-index: 6;
  left: 12px;
  right: 12px;
  bottom: calc(188px + var(--safe-bottom));
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: center;
  padding: 8px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.88);
  color: #f8fafc;
  font-size: 12px;
  pointer-events: auto;
}
.canary-stepper button {
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.08);
  color: inherit;
  border-radius: 999px;
  min-height: 40px;
  padding: 8px 12px;
  font: inherit;
}
.canary-stepper [data-canary-label] {
  min-width: 12rem;
  text-align: center;
  font-weight: 600;
}

#dg-season-screen {
  position: fixed;
  left: 0;
  top: 0;
  width: 100%;
  height: 100dvh;
  z-index: 240;
}

#dg-season-screen[data-loading] { visibility: hidden; }

#dg-mega-climb {
  position: fixed;
  inset: 0;
  z-index: 260;
  background: #120c16;
}
.climb {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  background: #120c16;
  color: #f3e6cf;
}
.sheet-hold { min-height: 70dvh; }
.sheet-busy {
  min-height: 46dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: rgba(243, 230, 207, .86);
}
.sheet-busy p { margin: 0; font-size: 14px; font-weight: 650; }
.sheet-busy__spinner {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 2px solid rgba(229, 195, 126, .22);
  border-top-color: #e5c37e;
  animation: sheet-busy-spin .7s linear infinite;
}
@keyframes sheet-busy-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  .sheet-busy__spinner { animation: none; }
}
.reward-btn.is-unlock {
  animation: dg-rung-open 700ms ease;
}
@keyframes dg-rung-open {
  0% { transform: scale(0.86); filter: grayscale(1) brightness(0.7); }
  55% { transform: scale(1.08); filter: none; }
  100% { transform: scale(1); filter: none; }
}

/* ---------------------------------------------------------------------- */
/* Reward detail dialog (light DOM) — the shop's product dialog, Pilot wash. */
/* ---------------------------------------------------------------------- */

.dg-pilot-dialog {
  z-index: 600;
  --shop-common: #aab4c4;
  --shop-rare: #67b8e8;
  --shop-epic: #aa8cf2;
  --shop-legendary: #f2c768;
  --shop-mythic: #ff7a45;
  --shop-action-bg: #1a1420;
  --shop-action-text: #f3e6cf;
  --dg-gold: #e0b15a;
  --dg-gold-light: #ffe7a8;
  color: #f3e6cf;
  background: #120c16;
  border-color: rgba(246, 210, 127, .22);
}

.dg-pilot-dialog .dg-shop-dialog__inner { padding-top: 0; }

.dg-pilot-dialog .dg-shop-dialog__stage {
  background:
    radial-gradient(circle at 50% 36%, color-mix(in srgb, var(--dlg-rarity) 28%, transparent), transparent 64%),
    linear-gradient(160deg, #2a1830, #0d0912);
}

.dg-pilot-dialog .dg-shop-dialog__content h2:not(.shop-tagline) {
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-weight: 400;
  font-size: 26px;
  color: #f6d27f;
}

.dg-pilot-dialog .dg-shop-dialog__eyebrow { color: rgba(243, 230, 207, .62); }
.dg-pilot-dialog .dg-shop-dialog__content p { color: rgba(243, 230, 207, .72); }

.dg-pilot-dialog .dg-shop-dialog__ledger-cell {
  border-color: rgba(246, 210, 127, .14);
  background: rgba(255, 255, 255, .035);
}

.dg-pilot-dialog .dg-shop-dialog__ledger-label { color: rgba(243, 230, 207, .58); }
.dg-pilot-dialog .dg-shop-dialog__ledger-value { color: #f3e6cf; }

/* Enlarged art stage: coins, badges, frames and scenes at product size. */
.dg-pilot-dialog__art {
  display: grid;
  place-items: center;
  width: 100%;
  aspect-ratio: 16 / 11;
  padding: 18px;
}

.dg-pilot-dialog__art > img {
  max-width: 72%;
  max-height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 16px 28px rgba(0, 0, 0, .45));
}

.dg-pilot-dialog__art.is-scene > img {
  max-width: 100%;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 14px;
}

.dg-pilot-dialog__art.is-scene { padding: 14px 14px 16px; }

.dg-pilot-dialog__coin {
  position: relative;
  width: min(52%, 180px);
  aspect-ratio: 1;
}

.dg-pilot-dialog__coin img { width: 100%; height: 100%; object-fit: contain; }

.dg-pilot-dialog__coin b {
  position: absolute;
  right: -4px;
  bottom: 4px;
  min-width: 34px;
  padding: 3px 9px;
  border-radius: 12px;
  background: #1d1508;
  color: #f6d27f;
  font-size: 17px;
  text-align: center;
  box-shadow: 0 6px 14px rgba(0, 0, 0, .4);
}

.dg-pilot-dialog__word {
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: clamp(26px, 7vw, 40px);
  line-height: 1.1;
  text-align: center;
  color: #f6d27f;
  text-shadow: var(--mega-title-shadow, none);
}

/* Circus taglines: one family, three treatments.
   Premium pair, plus the highest free tagline. */
.mega-tag,
.identity-card__tagline.mega-tag,
.friend-profile-card .fp-tagline.mega-tag,
.dg-shop__tagline-sample.mega-tag,
.collect-card .word.mega-tag,
.ach-visual__tag.mega-tag {
  font-family: "Pilot Display", "Space Grotesk", system-ui, sans-serif;
  font-weight: 400;
  font-style: normal;
  letter-spacing: 0.02em;
  color: #f6d27f;
}

.reward-btn .word.mega-tag--first-light,
.dg-pilot-dialog__word.mega-tag--first-light,
.dg-pilot-dialog .dg-shop-dialog__content h2.mega-tag--first-light,
.identity-card__tagline.mega-tag--first-light,
.friend-profile-card .fp-tagline.mega-tag--first-light {
  color: #ffe7a8;
  text-shadow: 0 0 8px rgba(246, 210, 127, .85), 0 0 1px #fff4c8;
  animation: mega-tag-bulb 3.6s ease-in-out infinite;
}

.reward-btn .word.mega-tag--keep-glass,
.dg-pilot-dialog__word.mega-tag--keep-glass,
.dg-pilot-dialog .dg-shop-dialog__content h2.mega-tag--keep-glass,
.identity-card__tagline.mega-tag--keep-glass,
.friend-profile-card .fp-tagline.mega-tag--keep-glass {
  color: #e4d4ff;
  text-decoration: underline;
  text-decoration-color: #f6d27f;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.16em;
  text-shadow: 0 0 8px rgba(170, 140, 242, .7);
}

.reward-btn .word.mega-tag--quiet-gate,
.dg-pilot-dialog__word.mega-tag--quiet-gate,
.dg-pilot-dialog .dg-shop-dialog__content h2.mega-tag--quiet-gate,
.identity-card__tagline.mega-tag--quiet-gate,
.friend-profile-card .fp-tagline.mega-tag--quiet-gate {
  color: #fff6df;
  letter-spacing: 0.08em;
  text-shadow:
    0 0 1px #f6d27f,
    0 0 8px rgba(246, 210, 127, .75),
    0 1px 0 #3a2414;
}

@keyframes mega-tag-bulb {
  0%, 100% { text-shadow: 0 0 4px rgba(246, 210, 127, .45); }
  50% { text-shadow: 0 0 12px rgba(246, 210, 127, .95), 0 0 2px #fff4c8; }
}

@media (prefers-reduced-motion: reduce) {
  .mega-tag--first-light { animation: none; }
}

.dg-pilot-dialog {
  scrollbar-width: none;
}

.dg-pilot-dialog .dg-shop-dialog__rarity-tag.is-premium {
  color: #1d1508;
  background: #f6d27f;
  border-color: #f6d27f;
}

.dg-pilot-dialog .dg-shop-dialog__rarity-tag.is-free {
  color: #f3e6cf;
  background: #3f6b58;
  border-color: #3f6b58;
}

.dg-pilot-dialog__art--theme {
  overflow: visible;
}

.dg-pilot-dialog__art--theme .dg-pilot-theme--stage {
  position: relative;
  display: inline-grid;
  place-items: center;
  overflow: visible;
  min-width: 2.4em;
  min-height: 1.4em;
}

.dg-pilot-dialog__fx {
  position: relative;
}

.dg-pilot-dialog__fx .dg-identity-effect {
  position: absolute;
  inset: 10px 8%;
  font-size: 48px;
}

.dg-pilot-effect-letters {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  place-items: center;
  font-weight: 800;
  color: #f3e6cf;
  pointer-events: none;
}

/* View toggle (Enlarged / On profile) sits where the shop puts its eyebrow. */
.dg-pilot-dialog__tabs {
  position: sticky;
  top: 0;
  z-index: 5;
  display: inline-grid;
  grid-auto-flow: column;
  gap: 3px;
  margin: 0 0 12px;
  padding: 3px;
  border-radius: 999px;
  border: 1px solid rgba(246, 210, 127, .18);
  background: rgba(18, 12, 22, .92);
  pointer-events: auto;
}

.dg-pilot-dialog__tab {
  min-height: 30px;
  padding: 0 13px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: rgba(243, 230, 207, .72);
  font: inherit;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  cursor: pointer;
}

.dg-pilot-dialog__tab[aria-selected="true"] {
  background: #f6d27f;
  color: #1d1508;
}

.dg-pilot-dialog .dg-shop-dialog__rarity-tag {
  z-index: 25;
}
.dg-pilot-dialog .dg-pilot-modal-preview {
  display: flex;
  justify-content: center;
  width: 100%;
  padding: 8px 8px 4px;
}
.dg-pilot-dialog .dg-pilot-modal-preview .friend-profile-card {
  width: min(100%, 360px);
  max-width: 360px;
  margin: 0;
  transform: none;
}
.dg-pilot-dialog .dg-pilot-modal-preview .fp-close { display: none; }
.dg-pilot-dialog .dg-shop-dialog__try-on {
  display: grid;
  place-items: center;
  width: 100%;
  padding: 40px 14px 24px;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .dg-identity-card {
  width: min(100%, 420px);
  max-width: 420px;
  margin: 0 !important;
  border-radius: 16px;
  background-color: #161018;
  box-shadow: 0 14px 30px rgba(0, 0, 0, .35);
  overflow: hidden;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .dg-identity-card:not(.dg-identity-card--framed) {
  border: 1px solid rgba(246, 210, 127, .32);
}
.dg-pilot-dialog .dg-shop-dialog__try-on .dg-identity-card .identity-card__safe {
  position: relative;
  z-index: 21;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: calc(var(--dg-frame-safe-top, 8px) + 10px) !important;
  padding-right: var(--dg-frame-safe-right, 0.75rem) !important;
  padding-bottom: calc(var(--dg-frame-safe-bottom, 8px) + 1.35rem) !important;
  padding-left: var(--dg-frame-safe-left, 0.75rem) !important;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__body {
  position: relative;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center !important;
  column-gap: 0.45rem;
  row-gap: 0;
  width: 100%;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__hero,
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__meta,
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__aside {
  order: 0 !important;
  max-width: none;
  flex: initial;
  justify-self: center !important;
  align-self: center !important;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__hero {
  grid-column: 1 !important;
  flex-direction: column;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__meta {
  grid-column: 2 !important;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__aside {
  grid-column: 3 !important;
  margin-left: 0 !important;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__initials {
  font-family: var(--dg-identity-face, 'Space Grotesk', sans-serif);
  font-size: 2.35rem;
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: 0.02em;
  padding: 0.82em 0.06em;
  box-sizing: border-box;
  transform: translateY(6px);
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__badges {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 0;
  line-height: 0;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__badges .pi-badge-wrap,
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__badges .identity-card__badge-btn,
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__badges > img,
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__badges img {
  width: var(--identity-badge-size, 44px) !important;
  height: var(--identity-badge-size, 44px) !important;
  object-fit: contain;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__stat {
  position: relative !important;
  flex-shrink: 0;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  text-align: center;
  padding: 0;
  overflow: visible;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__stat > p:first-child,
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__stat [data-identity-solved],
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__solved-value {
  font-size: 1.55rem;
  font-weight: 700;
  line-height: 1.1;
  margin: 0 !important;
  color: var(--dg-shell-text, #f8fafc);
  text-align: center;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__stat > p:last-child {
  position: absolute !important;
  left: 50% !important;
  top: 100% !important;
  transform: translateX(-50%) !important;
  margin: 0.12rem 0 0 !important;
  font-size: 0.75rem !important;
  color: #94a3b8 !important;
  text-align: center;
  width: max-content;
  line-height: 1.1;
}
.dg-pilot-dialog .dg-shop-dialog__try-on .identity-card__tagline {
  position: absolute;
  left: 50%;
  top: calc(100% + 0.25rem);
  transform: translateX(-50%);
  width: max-content;
  max-width: min(92%, 16rem);
  margin: 0;
  text-align: center;
  white-space: normal;
  z-index: 2;
}

/* Badge replacement picker: a short list of the three worn badges. */
.dg-pilot-dialog__slots {
  display: grid;
  gap: 8px;
  margin: 14px 0 0;
}

.dg-pilot-dialog__slot {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 56px;
  padding: 8px 12px;
  border: 1px solid rgba(246, 210, 127, .18);
  border-radius: 14px;
  background: rgba(255, 255, 255, .035);
  color: #f3e6cf;
  font: inherit;
  text-align: left;
  cursor: pointer;
}

.dg-pilot-dialog__slot img { width: 36px; height: 36px; object-fit: contain; }
.dg-pilot-dialog__slot span { font-size: 13px; }
.dg-pilot-dialog__slot small { display: block; color: rgba(243, 230, 207, .58); font-size: 11px; }

@media (prefers-reduced-motion: reduce) {
  .dg-pilot-season-card.is-ready { animation: none; box-shadow: 0 0 18px rgba(246, 210, 127, 0.35); }
}

/* ---------------------------------------------------------------------- */
/* Lobby (shadow DOM)                                                      */
/* ---------------------------------------------------------------------- */

:host { all: initial; color-scheme: dark; display: block; }

:host * { box-sizing: border-box; }
:host button { font: inherit; }

.screen {
  --cream: var(--mega-cream, #f3e6cf);
  --gold: var(--mega-gold, #f6d27f);
  --walnut: var(--mega-walnut, #3a2414);
  --glass: rgba(14, 9, 18, .68);
  --glass-edge: rgba(243, 230, 207, .24);
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  position: absolute;
  inset: 0;
  overflow: hidden;
  color: var(--cream);
  font-family: var(--mega-ui, "Space Grotesk", system-ui, sans-serif);
  background: #090912;
}

.world {
  position: absolute;
  inset: 0;
  background: var(--mega-night, #2a1830) var(--mega-plate, none) center 44% / cover no-repeat;
}

.world::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(5, 7, 13, .8) 0%, rgba(8, 6, 12, .38) 26%, rgba(8, 6, 12, .42) 58%, rgba(7, 8, 14, .94) 91%, #07080e 100%),
    linear-gradient(90deg, rgba(7, 8, 14, .42), transparent 35%, transparent 65%, rgba(7, 8, 14, .42));
}

.lobby {
  position: relative;
  z-index: 1;
  width: min(100%, 1180px);
  height: 100%;
  margin: auto;
}

.topbar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: max(14px, var(--safe-top)) 14px 0;
}

.top-actions { display: flex; align-items: flex-start; gap: 8px; }

.rules-btn {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(246, 210, 127, .42);
  border-radius: 14px;
  color: var(--gold);
  background: var(--glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 6px 22px rgba(0, 0, 0, .22);
  cursor: pointer;
}

.rules-btn svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; }

.back {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 42px;
  padding: 0 13px 0 9px;
  border: 1px solid rgba(243, 230, 207, .28);
  border-radius: 14px;
  color: var(--cream);
  background: var(--glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 6px 22px rgba(0, 0, 0, .22);
  cursor: pointer;
}

.back svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; }

.hud { display: flex; gap: 7px; }

.hud-item {
  min-width: 78px;
  padding: 7px 10px;
  border: 1px solid var(--glass-edge);
  border-radius: 13px;
  background: var(--glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 6px 22px rgba(0, 0, 0, .22);
  text-align: center;
}

.hud-item strong { display: block; font-size: 14px; line-height: 1.05; }

.hud-item span {
  display: block;
  margin-top: 3px;
  color: rgba(243, 230, 207, .64);
  font-size: 9px;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.identity {
  position: absolute;
  top: calc(clamp(64px, 10vh, 110px) + var(--safe-top));
  left: 50%;
  transform: translateX(-50%);
  width: min(78vw, 340px);
  text-align: center;
  filter: drop-shadow(0 8px 18px rgba(0, 0, 0, .4));
}

.identity::before,
.destinations::before {
  content: "";
  position: absolute;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(ellipse at center, rgba(8, 6, 12, .5), transparent 72%);
}

.identity::before { inset: -28% -18%; }

.destinations::before { inset: -6% 4%; }

.mark-btn {
  position: relative;
  display: inline-grid;
  place-items: center;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.identity img,
.mark-btn img {
  width: 128px;
  height: 128px;
  object-fit: contain;
}

.mark-btn img.is-jiggle-a { animation: mark-jiggle-a 340ms ease; }
.mark-btn img.is-jiggle-b { animation: mark-jiggle-b 360ms ease; }
.mark-btn img.is-jiggle-c { animation: mark-jiggle-c 320ms ease; }

@keyframes mark-jiggle-a {
  0% { transform: none; }
  40% { transform: rotate(-2deg); }
  100% { transform: none; }
}
@keyframes mark-jiggle-b {
  0% { transform: none; }
  35% { transform: translateY(-1px) rotate(1.5deg); }
  100% { transform: none; }
}
@keyframes mark-jiggle-c {
  0% { transform: none; }
  30% { transform: rotate(2.2deg); }
  65% { transform: rotate(-1.4deg); }
  100% { transform: none; }
}

.mark-sparks {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: visible;
}

.mark-spark {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 1.5px;
  height: var(--sh, 4px);
  margin: calc(var(--sh, 4px) / -2) 0 0 -0.75px;
  border-radius: 1px;
  background: linear-gradient(#fff6d0, #f6d27f);
  opacity: 0.72;
  animation: mark-spark var(--dur, 320ms) linear forwards;
}

@keyframes mark-spark {
  from { transform: translate(0, 0) rotate(var(--rot)) scale(1); opacity: 0.78; }
  to { transform: translate(var(--sx), var(--sy)) rotate(var(--rot)) scale(0.45); opacity: 0; }
}

#dg-season-coin-chip {
  position: fixed;
  top: calc(12px + env(safe-area-inset-top, 0px));
  right: calc(12px + env(safe-area-inset-right, 0px));
  z-index: 400;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 42px;
  padding: 6px 13px 6px 8px;
  border-radius: 999px;
  border: 1px solid rgba(212, 166, 80, 0.42);
  background: rgba(17, 24, 39, 0.82);
  color: #e5c37e;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
  font-family: "Space Grotesk", system-ui, sans-serif;
  font-size: 15px;
  font-weight: 780;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
  pointer-events: none;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.18s ease, transform 0.18s ease;
}

#dg-season-coin-chip.is-on {
  opacity: 1;
  transform: none;
}

#dg-season-coin-chip img {
  width: 27px;
  height: 27px;
  object-fit: contain;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.35));
}

.dg-season-coin-flight {
  position: fixed;
  width: 22px;
  height: 22px;
  margin: 0;
  padding: 0;
  pointer-events: none;
  z-index: 401;
  object-fit: contain;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.35));
  will-change: left, top, opacity, transform;
}

@media (prefers-reduced-motion: reduce) {
  .mark-btn img.is-jiggle-a,
  .mark-btn img.is-jiggle-b,
  .mark-btn img.is-jiggle-c,
  .mark-spark { animation: none; }
  .dg-season-coin-flight { display: none !important; }
  #dg-season-coin-chip { transition: none; }
}

.season-title {
  margin: 0;
  color: var(--gold);
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: .01em;
  text-shadow: var(--mega-title-shadow, none);
}

.identity .season-title {
  margin-top: 6px;
  padding: 0 10px;
  font-size: clamp(20px, 5.4vw, 34px);
}

.destinations {
  position: absolute;
  left: 12px;
  right: 12px;
  top: calc(clamp(64px, 10vh, 110px) + var(--safe-top) + 222px);
  bottom: calc(max(96px, var(--safe-bottom) + 56px) + 108px);
  display: flex;
  justify-content: center;
  gap: clamp(56px, 18vw, 120px);
  align-items: stretch;
  pointer-events: none;
}

.dest-side {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 28px;
  min-height: 0;
  pointer-events: none;
}

.dest-side--end { align-items: flex-end; }

.destination {
  position: relative;
  overflow: visible;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  width: 108px;
  padding: 0;
  border: 0;
  border-radius: 0;
  color: var(--cream);
  background: transparent;
  box-shadow: none;
  cursor: pointer;
  pointer-events: auto;
}

.destination.is-on .destination-art,
.rules-btn.is-on {
  transform: scale(1.08);
  filter:
    drop-shadow(0 0 10px rgba(246, 210, 127, .85))
    drop-shadow(1px 0 0 #ffe7a8)
    drop-shadow(-1px 0 0 #ffe7a8);
}

.destination:active .destination-art { transform: scale(0.94); }

.destination-art {
  width: 96px;
  height: 96px;
  object-fit: contain;
  background: none;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  filter:
    drop-shadow(1px 0 0 #e0b15a)
    drop-shadow(-1px 0 0 #e0b15a)
    drop-shadow(0 1px 0 #e0b15a)
    drop-shadow(0 -1px 0 #e0b15a);
  transition: transform 120ms ease, filter 120ms ease;
}

.destination strong {
  display: block;
  max-width: 108px;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: .01em;
  text-align: center;
  color: var(--cream);
  text-shadow: var(--mega-title-shadow, none);
}


.play-zone {
  position: absolute;
  left: 50%;
  bottom: max(96px, calc(var(--safe-bottom) + 56px));
  transform: translateX(-50%);
  width: min(88vw, 430px);
  text-align: center;
}

.today-name {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  margin: 0 0 9px;
  color: rgba(243, 230, 207, .82);
  font-size: 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  text-shadow: 0 2px 8px #000;
}

.today-logo {
  width: 18px;
  height: 18px;
  object-fit: contain;
  border-radius: 4px;
}

.play {
  width: 100%;
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid #fff0b2;
  border-radius: 19px;
  color: #1d1508;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 28px;
  letter-spacing: .02em;
  background: linear-gradient(180deg, #ffe6a0, #dcae55);
  box-shadow: 0 8px 0 #805c29, 0 14px 34px rgba(0, 0, 0, .42), inset 0 1px rgba(255, 255, 255, .75);
  cursor: pointer;
}

.play:not(:disabled):active {
  transform: translateY(4px);
  box-shadow: 0 4px 0 #805c29, 0 10px 24px rgba(0, 0, 0, .4);
}

.play.is-loading {
  color: #1d1508;
  background: linear-gradient(180deg, #e7c56a, #a8843a);
  transform: translateY(4px);
  box-shadow: 0 4px 0 #805c29, 0 10px 24px rgba(0, 0, 0, .4);
  cursor: progress;
}

.play:disabled,
.play.is-done {
  color: rgba(243, 230, 207, .72);
  border-color: rgba(243, 230, 207, .18);
  background: linear-gradient(#34313a, #211f27);
  box-shadow: 0 6px 0 #111117, 0 12px 28px rgba(0, 0, 0, .35);
  cursor: default;
}

.play.is-done svg { width: 22px; height: 22px; }

.play.is-gate {
  font-size: 18px;
  letter-spacing: 0;
  line-height: 1.15;
  padding: 0 16px;
}

.play.is-signin {
  color: #1d1508;
  border-color: #fff0b2;
  background: linear-gradient(180deg, #ffe6a0, #dcae55);
  box-shadow: 0 8px 0 #805c29, 0 14px 34px rgba(0, 0, 0, .42), inset 0 1px rgba(255, 255, 255, .75);
  cursor: pointer;
  font-size: clamp(17px, 4.6vw, 24px);
  letter-spacing: 0;
  padding: 0 16px;
  white-space: nowrap;
}

.play.is-signin svg {
  width: 20px;
  height: 20px;
  fill: none;
  flex: none;
}

.play.is-signin:active {
  transform: translateY(4px);
  box-shadow: 0 4px 0 #805c29, 0 10px 24px rgba(0, 0, 0, .4);
}

.play svg { width: 23px; height: 23px; stroke: currentColor; stroke-width: 1.8; }

.fair-guide { display: grid; gap: 16px; padding-bottom: 28px; }

.fair-guide__hero {
  display: grid;
  grid-template-columns: 84px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 16px;
  border-radius: 24px;
  border: 1px solid rgba(246, 210, 127, .5);
  background:
    linear-gradient(115deg, rgba(18, 10, 16, .28), rgba(8, 6, 12, .82)),
    var(--mega-plate, none) center 36% / cover no-repeat;
  box-shadow: inset 0 0 0 1px rgba(243, 230, 207, .08), 0 18px 40px rgba(0, 0, 0, .38);
}

.fair-guide__mark {
  width: 84px;
  height: 84px;
  object-fit: contain;
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .45));
}

.fair-guide__kicker {
  margin: 0;
  color: #f6d27f;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.fair-guide__title {
  margin: 4px 0 8px;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-weight: 400;
  font-size: clamp(28px, 7vw, 40px);
  line-height: 1.05;
  color: #f3e6cf;
  text-shadow: var(--mega-title-shadow, none);
}

.fair-guide__hero p:last-child {
  margin: 0;
  color: rgba(243, 230, 207, .86);
  font-size: 14px;
  line-height: 1.45;
}

.fair-guide__bill { display: grid; gap: 14px; }

.fair-card {
  margin: 0;
  padding: 14px;
  border-radius: 22px;
  border: 1px solid rgba(246, 210, 127, .32);
  background:
    radial-gradient(180px 120px at 0 0, rgba(246, 210, 127, .16), transparent 70%),
    linear-gradient(180deg, rgba(42, 24, 48, .55), rgba(12, 8, 16, .92));
  box-shadow: 0 14px 32px rgba(0, 0, 0, .32);
}

.fair-card h3 {
  margin: 14px 0 0;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-weight: 400;
  font-size: 26px;
  line-height: 1;
  color: #f6d27f;
}

.fair-card > p {
  margin: 8px 0 0;
  color: rgba(243, 230, 207, .86);
  font-size: 15px;
  line-height: 1.4;
}

.fair-hud {
  display: inline-grid;
  justify-items: center;
  min-width: 108px;
  margin-bottom: 12px;
  padding: 8px 12px;
  border: 1px solid rgba(246, 210, 127, .35);
  border-radius: 14px;
  background: rgba(8, 6, 12, .45);
  text-align: center;
}

.fair-hud strong {
  font-size: 18px;
  line-height: 1;
  color: #f3e6cf;
}

.fair-hud span {
  margin-top: 4px;
  color: rgba(243, 230, 207, .64);
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.fair-lanes {
  display: grid;
  grid-template-columns: 80px minmax(0, 1fr);
  gap: 8px;
  margin-bottom: 8px;
}

.fair-lanes__names {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px minmax(0, 1fr);
  color: rgba(243, 230, 207, .7);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  text-align: center;
}

.fair-pair {
  display: grid;
  grid-template-columns: 80px minmax(0, 1fr);
  gap: 8px;
  align-items: stretch;
  margin-top: 8px;
}

.fair-day {
  display: grid;
  place-items: center;
  align-content: center;
  border-radius: 16px;
  background: #f6d27f;
  color: #1d1508;
  text-align: center;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .35);
}

.fair-day b {
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-weight: 400;
  font-size: 18px;
  line-height: .95;
}

.fair-day small {
  display: block;
  margin-top: 4px;
  font-size: 11px;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.fair-day.is-one { background: rgba(243, 230, 207, .16); color: #f3e6cf; }

.fair-rungs { display: grid; gap: 8px; min-width: 0; }

.fair-slice .rung { grid-template-columns: minmax(0, 1fr) 42px minmax(0, 1fr); }
.fair-slice .reward-btn { width: 64px; height: 64px; cursor: default; }
.fair-slice .reward-btn img,
.fair-slice .coin-art { width: 46px; height: 46px; }
.fair-slice .bulb,
.fair-slice .rung.is-reached .bulb { width: 36px; height: 36px; font-size: 15px; }

.fair-puzzle {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  min-height: 112px;
  padding: 12px;
  border-radius: 18px;
  background:
    linear-gradient(115deg, rgba(18, 10, 16, .2), rgba(8, 6, 12, .78)),
    var(--mega-plate, none) center 40% / cover no-repeat;
}

.fair-puzzle img {
  width: 92px;
  height: 92px;
  object-fit: contain;
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, .45));
}

.fair-puzzle strong {
  display: block;
  margin: 2px 0;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-weight: 400;
  font-size: 32px;
  line-height: .95;
  color: #f3e6cf;
}

.fair-enter {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 54px;
  margin-top: 18px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(180deg, #ffe6a0, #dcae55);
  color: #3a2414;
  font: inherit;
  font-weight: 750;
  letter-spacing: .03em;
  cursor: pointer;
  box-shadow: 0 6px 0 #805c29;
}

.fair-enter:disabled { opacity: .72; cursor: default; }

.drawer.is-intro .sheet-x { display: none; }

.drawer.is-intro .drawer-body {
  padding-bottom: calc(28px + var(--safe-bottom));
}

.fair-board { display: grid; gap: 6px; }

.fair-board__cols,
.fair-board__row {
  display: grid;
  grid-template-columns: 28px 52px 52px 64px minmax(0, 1fr);
  gap: 6px;
  align-items: center;
}

.fair-board__cols {
  padding: 0 10px;
  color: rgba(243, 230, 207, .55);
  font-size: 10px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.fair-board__row {
  min-height: 42px;
  padding: 0 10px;
  border-radius: 12px;
  background: rgba(243, 230, 207, .08);
  color: #f3e6cf;
  font-variant-numeric: tabular-nums;
}

.fair-board__row b {
  color: #f6d27f;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 22px;
  font-weight: 400;
}

.fair-board__row strong { font-size: 20px; }

.fair-board__row em {
  font-style: normal;
  font-size: 12px;
  line-height: 1.15;
  color: rgba(243, 230, 207, .78);
}

@media (max-width: 520px) {
  .fair-pair,
  .fair-lanes { grid-template-columns: 64px minmax(0, 1fr); gap: 6px; }
  .fair-lanes__names {
    grid-template-columns: minmax(0, 1fr) 32px minmax(0, 1fr);
    letter-spacing: .04em;
    font-size: 10px;
  }
  .fair-slice .rung { grid-template-columns: minmax(0, 1fr) 32px minmax(0, 1fr); }
  .fair-slice .reward-btn { width: 52px; height: 52px; }
  .fair-slice .reward-btn .pi-badge-wrap,
  .fair-slice .reward-btn img,
  .fair-slice .coin-art { width: 36px; height: 36px; }
  .fair-slice .bulb,
  .fair-slice .rung.is-reached .bulb { width: 30px; height: 30px; font-size: 13px; }
  .fair-day b { font-size: 15px; }
  .fair-board__cols,
  .fair-board__row {
    grid-template-columns: 22px 34px 40px 42px minmax(0, 1fr);
    gap: 4px;
    padding-left: 8px;
    padding-right: 8px;
  }
}

.fair-board__row .is-better { color: #8dcea0; font-weight: 750; }
.fair-board__row .is-worse { color: #f0a8a0; font-weight: 750; }

/* Drawers: bottom sheets for Marks and Board, a full-height sheet for the
   ladder. All share one centered season-font title. */
.drawer-wrap {
  position: absolute;
  inset: 0;
  z-index: 5;
  display: grid;
  align-items: end;
  background: rgba(3, 4, 8, .58);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
}

.drawer-wrap[hidden] { display: none; }
.drawer-wrap.is-full { align-items: stretch; }

.drawer {
  position: relative;
  width: min(100%, 760px);
  max-height: min(82dvh, 760px);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(246, 210, 127, .27);
  border-radius: 24px 24px 0 0;
  color: var(--cream);
  background: linear-gradient(180deg, #17101d, #090b11 32%);
  box-shadow: 0 -18px 60px rgba(0, 0, 0, .48);
}

.drawer.is-full {
  width: 100%;
  height: 100%;
  min-height: 100%;
  max-height: none;
  border: 0;
  border-radius: 0;
  background:
    linear-gradient(180deg, rgba(8, 6, 12, 0.78), rgba(8, 6, 12, 0.9)),
    var(--mega-plate, none) center 42% / cover no-repeat;
}

.drawer-head {
  position: relative;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 16px 18px 12px;
  background: rgba(12, 8, 16, .62);
  border-bottom: 1px solid rgba(243, 230, 207, .08);
  text-align: center;
}

.drawer.is-full .drawer-head { padding-top: calc(14px + var(--safe-top)); }

.drawer-head .season-title { font-size: clamp(22px, 6vw, 30px); }

.drawer-head .drawer-sub {
  margin: 2px 0 0;
  color: rgba(243, 230, 207, .62);
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.sheet-x {
  position: absolute;
  left: 50%;
  bottom: calc(14px + var(--safe-bottom));
  z-index: 6;
  touch-action: manipulation;
  transform: translateX(-50%);
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid #fff0b2;
  border-radius: 50%;
  color: var(--walnut);
  background: linear-gradient(180deg, #ffe6a0, #dcae55);
  box-shadow: 0 6px 0 #805c29, 0 12px 24px rgba(0, 0, 0, .4);
  cursor: pointer;
}

.sheet-x svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; }

.drawer-body {
  flex: 1 1 auto;
  min-height: 0;
  padding: 14px 14px calc(84px + var(--safe-bottom));
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.drawer-body::-webkit-scrollbar,
.ladder-scroll::-webkit-scrollbar,
.dg-pilot-dialog::-webkit-scrollbar { display: none; }

.drawer.is-full .drawer-body:has([data-ladder]) {
  display: flex;
  flex-direction: column;
  /* Keep the scroller above the close button. A scrollport that ran under
     the X ate the first tap (it was treated as a pan). */
  margin-bottom: calc(76px + var(--safe-bottom));
  padding: 0;
  overflow: hidden;
}

.drawer-copy {
  margin: 0 0 13px;
  color: rgba(243, 230, 207, .72);
  font-size: 12px;
  line-height: 1.45;
}

/* Ladder: a thermometer. One scroller, rung 25 on top, resume at the
   current rung. The lane captions live in a thin sticky strip so the
   scroller can run edge to edge without a footer. */
.ladder {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.lanes {
  flex: 0 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 52px minmax(0, 1fr);
  gap: 8px;
  padding: 8px 14px 6px;
  color: rgba(243, 230, 207, .58);
  font-size: 10px;
  letter-spacing: .14em;
  text-transform: uppercase;
  text-align: center;
}

.lanes .is-premium { color: var(--gold); }

.lanes .lane-pass {
  justify-self: center;
  min-height: 34px;
  padding: 0 14px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(180deg, #ffe6a0, #dcae55);
  color: #1d1508;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 13px;
  font-weight: 650;
  letter-spacing: .01em;
  text-transform: none;
  box-shadow: 0 3px 0 #805c29, 0 8px 16px rgba(0, 0, 0, .28);
  cursor: pointer;
}
.lanes .lane-pass:active {
  transform: translateY(2px);
  box-shadow: 0 1px 0 #805c29;
}

.pass-sheet {
  position: absolute;
  inset: 0;
  z-index: 30;
  display: grid;
  place-items: safe center;
  overflow: auto;
  padding: 24px 16px;
}

.pass-sheet[hidden] { display: none; }

.pass-sheet__veil {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(8, 6, 12, .72);
  cursor: pointer;
}

.pass-sheet__card {
  position: relative;
  z-index: 1;
  width: min(100%, 420px);
  padding: 22px 18px 16px;
  border-radius: 22px;
  border: 1px solid rgba(246, 210, 127, .55);
  background:
    linear-gradient(180deg, rgba(42, 24, 48, .55), rgba(18, 12, 22, .88)),
    var(--mega-plate, none) center 30% / cover no-repeat;
  box-shadow: 0 18px 50px rgba(0, 0, 0, .55), inset 0 0 0 1px rgba(243, 230, 207, .08);
  text-align: center;
  color: var(--cream, #f3e6cf);
}

.pass-sheet__x {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(246, 210, 127, .4);
  border-radius: 50%;
  background: rgba(18, 10, 16, .55);
  color: #f6d27f;
  cursor: pointer;
}

.pass-sheet__x svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.2; }

.pass-sheet__mark { width: 72px; height: 72px; object-fit: contain; }

.pass-sheet__kicker {
  margin: 8px 0 0;
  color: #f6d27f;
  font-size: 11px;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.pass-sheet__card h2 {
  margin: 4px 0 8px;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-weight: 400;
  font-size: 36px;
  line-height: 1;
  color: #f3e6cf;
  text-shadow: var(--mega-title-shadow, none);
}

.pass-sheet__lead {
  margin: 0 auto 14px;
  max-width: 32ch;
  color: rgba(243, 230, 207, .82);
  font-size: 14px;
  line-height: 1.4;
}

.pass-sheet__stage {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 14px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(8, 6, 12, .45);
  border: 1px solid rgba(246, 210, 127, .22);
}

.pass-shot {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 0;
  margin: 0;
}

.pass-shot__art {
  position: relative;
  width: min(108px, 100%);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  overflow: visible;
}

.pass-stack {
  position: relative;
  width: 100%;
  height: 100%;
}

.pass-stack__item {
  position: absolute;
  object-fit: contain;
  filter: drop-shadow(0 6px 8px rgba(0, 0, 0, .4));
  pointer-events: none;
}

.pass-stack--badges .pass-stack__item {
  width: 70%;
  height: 70%;
  top: 16%;
}

.pass-stack--badges .is-left {
  left: -10%;
  transform: rotate(-16deg);
  z-index: 1;
}

.pass-stack--badges .is-right {
  left: auto;
  right: -10%;
  transform: rotate(16deg);
  z-index: 1;
}

.pass-stack--badges .is-center {
  left: 15%;
  top: 8%;
  width: 74%;
  height: 74%;
  z-index: 2;
}

.pass-stack--borders .pass-stack__item,
.pass-stack--scenes .pass-stack__item {
  width: 78%;
  height: 78%;
}

.pass-stack--borders .is-back,
.pass-stack--scenes .is-back {
  left: -8%;
  top: 2%;
  transform: rotate(-9deg);
  z-index: 1;
}

.pass-stack--borders .is-front,
.pass-stack--scenes .is-front {
  left: auto;
  right: -8%;
  top: 12%;
  transform: rotate(8deg);
  z-index: 2;
}

.pass-stack--scenes .pass-stack__item {
  object-fit: cover;
  border-radius: 12px;
}

.pass-shot .pi-badge-wrap,
.pass-shot .coin-art,
.pass-shot.is-item .pass-shot__art > img {
  width: 88%;
  height: 88%;
}

.pass-shot.is-scene .pass-shot__art > img {
  width: 100%;
  height: 72%;
  object-fit: cover;
  border-radius: 12px;
  filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .45));
}

.pass-shot.is-item .pass-shot__art > img,
.pass-shot .coin-art img,
.pass-shot .pi-badge-wrap > img.pi-badge {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .45));
}

.pass-shot .pi-badge-wrap {
  container-type: size;
}

.pass-shot .coin-art b {
  left: 0;
  bottom: 0;
  font-size: 12px;
  line-height: 18px;
}

.pass-sheet__stage figcaption {
  margin-top: 4px;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 13px;
  line-height: 1.15;
  color: #f3e6cf;
}

.pass-sheet__offer {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
}

.pass-sheet__amount {
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 40px;
  line-height: 1;
  color: #f6d27f;
}

.pass-sheet__offer span:last-child {
  color: rgba(243, 230, 207, .7);
  font-size: 13px;
}

.pass-sheet__buy {
  width: 100%;
  min-height: 52px;
  border: 1px solid #fff0b2;
  border-radius: 16px;
  color: #1d1508;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 22px;
  background: linear-gradient(180deg, #ffe6a0, #dcae55);
  box-shadow: 0 6px 0 #805c29, 0 12px 24px rgba(0, 0, 0, .4);
  cursor: pointer;
}

.pass-sheet__fine {
  margin: 10px 0 0;
  color: rgba(243, 230, 207, .58);
  font-size: 12px;
}

.reward-btn .pi-badge-wrap,
.dg-pilot-mini-fx {
  width: 58px;
  height: 58px;
  container-type: size;
}

.reward-btn .pi-badge-wrap > img.pi-badge {
  width: 100%;
  height: 100%;
}

.dg-pilot-dialog__badge .pi-badge-wrap {
  width: 196px;
  height: 196px;
  container-type: size;
}

.dg-pilot-dialog__badge .pi-badge-wrap > img.pi-badge {
  width: 100%;
  height: 100%;
}

.dg-pilot-mini-fx {
  position: relative;
  display: block;
}

.dg-pilot-mini-fx .pi-fx--card { inset: 8%; }

.ladder-scroll {
  flex: 1 1 auto;
  min-height: 0;
  padding: 0 14px 12px;
  overflow-y: auto;
  overscroll-behavior: contain;
  touch-action: pan-y;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.ladder-scroll::-webkit-scrollbar { display: none; }

.tube {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 30px 0 18px;
}

.stem {
  position: absolute;
  left: 50%;
  top: 8px;
  bottom: 8px;
  width: 10px;
  transform: translateX(-50%);
  border-radius: 999px 999px 8px 8px;
  background: rgba(243, 230, 207, .14);
  overflow: hidden;
}

.stem-fill {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 0;
  border-radius: inherit;
  background: linear-gradient(#ffe7a8, #e0b15a);
  transition: height 420ms ease;
}

.rung {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 52px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}

.bulb {
  width: 34px;
  height: 34px;
  margin: 0 auto;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: #241820;
  color: var(--cream);
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 16px;
  transition: width 220ms ease, height 220ms ease, background-color 220ms ease;
}

.rung.is-reached .bulb {
  width: 46px;
  height: 46px;
  background: var(--gold);
  color: var(--walnut);
  box-shadow: 0 0 0 4px rgba(246, 210, 127, .18), 0 6px 18px rgba(0, 0, 0, .35);
}

.rung.is-current .bulb { box-shadow: 0 0 0 5px rgba(246, 210, 127, .28), 0 0 26px rgba(246, 210, 127, .55); }

.reward-btn {
  --rung-glow: #aab4c4;
  position: relative;
  display: grid;
  place-items: center;
  overflow: visible;
  width: 74px;
  height: 74px;
  margin: 0 auto;
  padding: 0;
  border: 1px solid color-mix(in srgb, var(--rung-glow) 62%, #2a1830);
  border-radius: 18px;
  background:
    radial-gradient(circle at 50% 46%, color-mix(in srgb, var(--rung-glow) 34%, #120c16), transparent 72%),
    rgba(18, 10, 16, .72);
  box-shadow: 0 0 12px color-mix(in srgb, var(--rung-glow) 26%, transparent);
  color: var(--cream);
  cursor: pointer;
}

.reward-btn[data-rarity="rare"] { --rung-glow: #67b8e8; }
.reward-btn[data-rarity="epic"] { --rung-glow: #aa8cf2; }
.reward-btn[data-rarity="legendary"] { --rung-glow: #f2c768; }
.reward-btn[data-rarity="mythic"] { --rung-glow: #ff7a45; }

.reward-btn:active { transform: scale(.96); }

.reward-btn img { width: 78%; height: 78%; object-fit: contain; }
.reward-btn .dg-pilot-theme { font-size: 18px; }
.dg-pilot-theme--stage { font-size: 72px; }

.reward-btn .word {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 66px;
  max-width: 100%;
  min-width: 0;
  margin: 0;
  padding: 0 2px;
  box-sizing: border-box;
  color: var(--cream);
  font-size: 11px;
  line-height: 1.05;
  text-align: center;
  text-wrap: balance;
}
.reward-btn .word--tight {
  width: 74px;
  max-width: 74px;
  font-size: 10px;
  letter-spacing: 0;
  line-height: 1.02;
  transform: scale(0.72);
  transform-origin: center center;
}

.reward-btn.is-claimed .coin-art { opacity: 0.42; filter: grayscale(0.25); }
.reward-btn .coin-check {
  position: absolute;
  inset: 0;
  display: none;
  place-items: center;
  color: #f6d27f;
  z-index: 2;
}
.reward-btn.is-claimed .coin-check { display: grid; }
.reward-btn .coin-check svg { width: 46%; height: 46%; filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .65)); }

.reward-btn.is-locked > :not(.lock):not(.reward-new) {
  filter: grayscale(0.72) brightness(0.9);
  opacity: 0.94;
}

.reward-btn .lock {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: none;
  place-items: center;
  border-radius: inherit;
  background: rgba(8, 6, 12, 0.4);
  color: rgba(248, 250, 252, 0.92);
}

.reward-btn.is-locked .lock { display: grid; }

.reward-btn .lock svg {
  width: 42%;
  height: 42%;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.55));
}

.coin-art { position: relative; width: 58px; height: 58px; }
.coin-art img { width: 100%; height: 100%; object-fit: contain; }

.coin-art b {
  position: absolute;
  left: -2px;
  bottom: -2px;
  min-width: 18px;
  padding: 0 4px;
  border-radius: 8px;
  background: #1d1508;
  color: var(--gold);
  font-size: 11px;
  line-height: 16px;
  text-align: center;
}

.ach-list, .collect-grid { display: grid; gap: 8px; }
.ach-card {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 10px;
  border: 1px solid rgba(255, 255, 255, .07);
  border-radius: 13px;
  background: rgba(255, 255, 255, .03);
  color: inherit;
  font: inherit;
  text-align: left;
  overflow: visible;
  cursor: pointer;
}
.ach-card:active { background: rgba(255, 255, 255, .06); }
.ach-visuals {
  display: flex;
  align-items: center;
  gap: 6px;
  flex: 0 0 auto;
}
.ach-card__body { min-width: 0; }
.ach-card__name { display: block; font-size: 14px; font-weight: 650; color: rgba(255, 255, 255, .92); }
.ach-card__desc { display: block; margin-top: 2px; color: rgba(243, 230, 207, .62); font-size: 12px; }
.ach-card__reward { display: block; margin-top: 3px; color: var(--gold); font-size: 11px; }
.ach-finale { display: grid; gap: 8px; margin-top: 22px; }
.ach-finale__title { margin: 0; font-size: 18px; color: #f6d27f; }
.ach-finale__lead { margin: 0 0 6px; color: rgba(243, 230, 207, .72); font-size: 13px; line-height: 1.45; }
.ach-finale .ach-list { grid-template-columns: 1fr; }
.finale-card { align-items: flex-start; }
.finale-place {
  min-width: 2.4em;
  padding-top: 4px;
  font-size: 20px;
  font-weight: 750;
  line-height: 1;
  color: #f6d27f;
}
.finale-card { cursor: default; }
.finale-card [data-ach-reward] { cursor: pointer; }
.fair-podium {
  display: grid;
  grid-template-columns: 1fr 1.08fr 1fr;
  align-items: end;
  gap: 8px;
  min-height: 168px;
}
.fair-podium__col {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
}
.fair-podium__prizes {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: flex-end;
  gap: 4px;
  margin-bottom: 6px;
}
.fair-podium__stand {
  width: 100%;
  display: grid;
  place-items: center;
  border-radius: 10px 10px 0 0;
  background: linear-gradient(180deg, #ffe7a8, #c4923e);
  color: #3a2414;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45);
}
.fair-podium__col.is-second .fair-podium__stand { height: 58px; }
.fair-podium__col.is-first .fair-podium__stand { height: 92px; }
.fair-podium__col.is-third .fair-podium__stand { height: 42px; }
.fair-podium__stand b { font-size: 16px; font-weight: 800; letter-spacing: .02em; }
.fair-podium .ach-visual,
.fair-podium .ach-visual--badge img,
.fair-podium .ach-visual--badge .pi-badge-wrap,
.fair-podium .ach-visual--frame img,
.fair-podium .ach-visual--scene img {
  width: 40px;
  height: 40px;
}
.fair-podium .ach-visual--coin,
.fair-podium .fair-podium__coin { width: 28px; height: 28px; background: transparent; }
.fair-podium .ach-visual--coin img { width: 28px; height: 28px; }
.fair-podium .ach-visual--coin b { display: none; }
.finale-card.is-yours { border-color: rgba(246, 210, 127, .75); }
.finale-card .ach-visuals { flex-wrap: wrap; }
.ach-visual--coin {
  flex-direction: column;
  gap: 1px;
  background: rgba(246, 210, 127, .08);
}
.ach-visual--coin img { width: 32px; height: 32px; }
.ach-visual--coin b { font-size: 11px; font-weight: 750; line-height: 1; color: #f6d27f; }
.finale-wrap {
  position: absolute;
  inset: 0;
  z-index: 8;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(3, 4, 8, .62);
}
.finale-wrap[hidden] { display: none; }
.finale {
  width: min(100%, 420px);
  max-height: min(86dvh, 640px);
  overflow: auto;
  padding: 22px 18px 18px;
  border-radius: 22px;
  border: 1px solid rgba(246, 210, 127, .35);
  background: #1a120c;
}
.finale__kicker {
  margin: 0;
  color: #f6d27f;
  font-size: 11px;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.finale__title { margin: 6px 0 0; font-size: 28px; line-height: 1.05; color: #fff8e8; }
.finale__copy { margin: 8px 0 0; color: rgba(243, 230, 207, .78); font-size: 14px; line-height: 1.4; }
.finale__rewards { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.finale__names { margin: 10px 0 0; color: #f6d27f; font-size: 13px; line-height: 1.35; }
.finale .fair-enter { margin-top: 16px; }
.ach-visual {
  position: relative;
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 14px;
  overflow: visible;
}
.ach-visual--badge { background: transparent; }
.ach-visual--badge img, .ach-visual--badge .pi-badge-wrap { width: 54px; height: 54px; object-fit: contain; }
.ach-visual--frame, .ach-visual--scene { overflow: hidden; background: rgba(0, 0, 0, .25); }
.ach-visual--frame img, .ach-visual--scene img { width: 54px; height: 54px; display: block; }
.ach-visual--frame img { object-fit: contain; }
.ach-visual--scene img { object-fit: cover; }
.ach-visual--tagline {
  width: 92px;
  height: 54px;
  padding: 4px 6px;
  text-align: center;
  background: linear-gradient(160deg, rgba(212, 166, 80, .16), rgba(255, 255, 255, .03));
  border: 1px solid rgba(212, 166, 80, .28);
}
.ach-visual__tag {
  font-size: 9px;
  font-weight: 650;
  font-style: italic;
  line-height: 1.2;
  color: #e2c17c;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.ach-visual__tag::before { content: "\201C"; }
.ach-visual__tag::after { content: "\201D"; }
.ach-visual__lock {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: inherit;
  background: rgba(2, 6, 23, .28);
  color: rgba(248, 250, 252, .92);
  z-index: 2;
  pointer-events: none;
}
.ach-visual__lock svg { width: 42%; height: 42%; filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .55)); }
.ach-visual--effect { overflow: hidden; background: rgba(0, 0, 0, .25); }
.ach-visual__fx { width: 54px; height: 54px; display: grid; place-items: center; transform: scale(0.7); }
.ach-visual--locked img,
.ach-visual--locked .ach-visual__tag,
.ach-visual--locked .pi-badge-wrap,
.ach-visual--locked .ach-visual__fx { filter: grayscale(0.35) brightness(0.92); }
.collect-card {
  position: relative;
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 6px;
  min-height: 0;
  padding: 8px 6px 10px;
  border: 1px solid rgba(246, 210, 127, .14);
  border-radius: 16px;
  background: rgba(255, 255, 255, .035);
  color: var(--cream);
  cursor: pointer;
}
.collect-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.collect-card .word {
  display: grid;
  place-items: center;
  width: 100%;
  min-height: 64px;
  padding: 6px 4px;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 13px;
  font-style: italic;
  line-height: 1.15;
  text-align: center;
  color: #f6d27f;
}
.collect-card .word.mega-tag { letter-spacing: 0.02em; animation: none; text-shadow: none; }
.collect-card .word.mega-tag--first-light { color: #ffe7a8; }
.collect-card .word.mega-tag--keep-glass { color: #e4d4ff; text-decoration-color: #f6d27f; }
.collect-card .word.mega-tag--quiet-gate { color: #fff6df; }
.collect-card img { width: 100%; height: 64px; object-fit: contain; }
.collect-card[data-cat="Scenes"] img { height: 58px; object-fit: cover; border-radius: 10px; }
.collect-card__from {
  display: block;
  font-size: 10px;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(243, 230, 207, .55);
}
.pass-card {
  margin: 0 0 14px;
  padding: 14px 14px 12px;
  border: 1px solid rgba(246, 210, 127, .4);
  border-radius: 16px;
  background: rgba(18, 10, 16, .72);
}
.pass-card__kicker {
  margin: 0 0 4px;
  color: #f6d27f;
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.pass-card h3 {
  margin: 0 0 6px;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-weight: 400;
  font-size: 28px;
  color: #f3e6cf;
}
.pass-card p { margin: 0 0 10px; color: rgba(243, 230, 207, .78); font-size: 13px; }
.pass-card__row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-bottom: 10px; }
.pass-card__row figure { margin: 0; text-align: center; }
.pass-card__row img { width: 100%; aspect-ratio: 1; object-fit: contain; border-radius: 12px; background: rgba(255,255,255,.04); }
.pass-card__row figcaption { margin-top: 4px; font-size: 10px; color: #f3e6cf; }
.pass-card__price { font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif); font-size: 22px; color: #f6d27f; }
.pass-card__buy {
  width: 100%;
  min-height: 44px;
  border: 0;
  border-radius: 12px;
  background: #f6d27f;
  color: #1d1508;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.pass-card__note { margin-top: 8px; font-size: 11px; color: rgba(243, 230, 207, .55); }
.dg-badge-slot-dialog { width: min(24rem, calc(100% - 32px)); }
.dg-badge-slot-dialog__row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 12px 0; }
.dg-badge-slot-dialog__slot {
  display: grid;
  justify-items: center;
  gap: 6px;
  padding: 8px;
  border-radius: 12px;
  border: 1px solid rgba(246, 210, 127, .28);
  background: transparent;
  color: inherit;
  cursor: pointer;
}
.collect-card__name {
  display: block;
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 13px;
  line-height: 1.15;
  text-align: center;
  color: var(--cream);
}
.collect-card[hidden],
.collect-card.is-off { display: none !important; }
.collect-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}
.collect-shop {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex: 0 0 auto;
  color: var(--gold);
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 14px;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
}
.collect-shop svg { width: 14px; height: 14px; }
.collect-menu { position: relative; }
.collect-menu__btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 12px 0 14px;
  border-radius: 12px;
  border: 1px solid rgba(246, 210, 127, .4);
  background: rgba(18, 10, 22, .78);
  color: var(--gold);
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 15px;
  cursor: pointer;
}
.collect-menu__btn svg { width: 14px; height: 14px; }
.collect-menu__list {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  z-index: 6;
  display: grid;
  min-width: 168px;
  padding: 6px;
  border-radius: 14px;
  border: 1px solid rgba(246, 210, 127, .32);
  background: rgba(18, 10, 22, .96);
  box-shadow: 0 16px 36px rgba(0, 0, 0, .45);
}
.collect-menu__list[hidden] { display: none; }
.collect-menu__opt {
  min-height: 36px;
  padding: 0 10px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--cream);
  font-family: var(--mega-display, "Space Grotesk", system-ui, sans-serif);
  font-size: 14px;
  text-align: left;
  cursor: pointer;
}
.collect-menu__opt.is-on,
.collect-menu__opt:hover {
  background: rgba(246, 210, 127, .16);
  color: var(--gold);
}
.reward-btn.is-unseen {
  z-index: 2;
  animation: dg-reward-new-pulse 1.35s ease-in-out infinite;
}
.collect-card.is-unseen {
  animation: dg-reward-new-pulse 1.35s ease-in-out infinite;
}
.ach-card.is-unseen {
  border-color: rgba(246, 210, 127, 0.48);
  animation: dg-reward-new-pulse 1.35s ease-in-out infinite;
}
@keyframes dg-reward-new-pulse {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(246, 210, 127, 0.2);
  }
  50% {
    transform: scale(1.07);
    box-shadow: 0 0 18px 3px rgba(246, 210, 127, 0.72);
  }
}
.reward-new {
  position: absolute;
  top: 4px;
  left: 4px;
  z-index: 4;
  padding: 2px 6px;
  border-radius: 999px;
  background: var(--gold, var(--mega-gold, #f6d27f));
  color: var(--mega-ink, #1d1508);
  font-family: var(--mega-ui, system-ui, sans-serif);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .06em;
  text-transform: uppercase;
  line-height: 1.3;
  pointer-events: none;
}
.reward-new[hidden] { display: none !important; }
.reward-btn > .reward-new,
.destination > .dest-new,
.dg-pilot-season-card > .reward-new,
.ach-card > .reward-new {
  top: -7px;
  right: -8px;
  left: auto;
}
#mega-s1-preview,
#mega-s1-preview-desktop,
.dg-pilot-season-block { overflow: visible; }

/* Marks drawer */
.marks { display: grid; gap: 8px; }

.mark {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 11px;
  align-items: center;
  padding: 10px 11px;
  border: 1px solid rgba(243, 230, 207, .1);
  border-radius: 14px;
  background: rgba(255, 255, 255, .03);
}

.mark img { width: 46px; height: 46px; border-radius: 10px; object-fit: contain; background: rgba(0, 0, 0, .25); }
.mark strong { display: block; font-size: 13px; }
.mark span { display: block; margin-top: 2px; color: rgba(243, 230, 207, .58); font-size: 10px; }
.mark em { display: block; margin-top: 3px; color: var(--gold); font-size: 10px; font-style: normal; }

/* Board drawer. Rows are the same flair rows as the daily leaderboard. */
.board-prizes {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 38px;
  margin: 0 0 12px;
  padding: 6px 14px 6px 10px;
  border: 1px solid rgba(246, 210, 127, .38);
  border-radius: 999px;
  background: linear-gradient(180deg, rgba(246, 210, 127, .12), rgba(246, 210, 127, .04));
  box-shadow: inset 0 1px 0 rgba(255, 240, 178, .18), 0 4px 12px rgba(0, 0, 0, .28);
  color: var(--cream);
  text-align: left;
  cursor: pointer;
  transition: transform 120ms ease, border-color 120ms ease, background 120ms ease;
}
.board-prizes:hover { border-color: rgba(246, 210, 127, .58); }
.board-prizes:active { transform: translateY(1px); background: rgba(246, 210, 127, .16); }
.board-prizes__mark {
  width: 26px;
  height: 26px;
  object-fit: contain;
  flex: 0 0 auto;
}
.board-prizes__copy { flex: 1 1 auto; min-width: 0; }
.board-prizes__copy strong {
  display: block;
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: .01em;
  line-height: 1.2;
}
.board-prizes__copy span {
  display: block;
  margin-top: 2px;
  color: rgba(243, 230, 207, .62);
  font-size: 12px;
}
.board-prizes__view {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  flex: 0 0 auto;
  color: var(--gold);
  font-size: 13px;
  font-weight: 700;
}
.board-prizes__view svg { width: 16px; height: 16px; }
.prizes-back {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 40px;
  margin: 0 0 14px;
  padding: 0 13px 0 9px;
  border: 1px solid rgba(243, 230, 207, .28);
  border-radius: 14px;
  color: var(--cream);
  background: rgba(14, 9, 18, .68);
  cursor: pointer;
}
.prizes-back svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; }
.mega-board { display: grid; gap: 8px; }
.mega-board .leaderboard-time { flex: 0 0 4.8rem; width: 4.8rem; color: #f3e6cf; text-align: right; font-variant-numeric: tabular-nums; }
.board-row {
  display: grid;
  grid-template-columns: 32px 1fr auto;
  gap: 9px;
  align-items: center;
  padding: 10px 3px;
  border-bottom: 1px solid rgba(243, 230, 207, .08);
  font-size: 12px;
}

.board-row span:last-child { color: var(--gold); }

@media (min-width: 780px) {
  .topbar { padding-left: 24px; padding-right: 24px; }
  .identity { width: max-content; max-width: calc(100vw - 48px); top: calc(48px + var(--safe-top)); }
  .identity img,
  .mark-btn img { width: 176px; height: 176px; }
  .identity .season-title {
    font-size: clamp(36px, 3.4vw, 52px);
    white-space: nowrap;
  }
  .destinations { top: calc(310px + var(--safe-top)); bottom: 160px; gap: clamp(120px, 14vw, 220px); }
  .dest-side { gap: 40px; }
  .destination { width: 160px; }
  .destination-art { width: 144px; height: 144px; }
  .destination strong { max-width: 160px; font-size: 22px; }
  .play-zone { bottom: 72px; width: min(520px, 46vw); }
  .canary-stepper {
    bottom: 156px;
    left: 50%;
    right: auto;
    width: min(720px, 72vw);
    transform: translateX(-50%);
  }
  .hud-item { min-width: 108px; padding: 10px 14px; }
  .hud-item strong { font-size: 20px; }
  .hud-item span { font-size: 11px; }
  .drawer-wrap.is-full { align-items: stretch; padding: 0; }
  .drawer.is-full {
    width: 100%;
    height: 100%;
    max-height: none;
    border: 0;
    border-radius: 0;
  }
  .drawer.is-full .drawer-head { padding-top: calc(18px + var(--safe-top)); }
  .drawer.is-full .season-title { font-size: 40px; }
  .drawer.is-full .drawer-body {
    padding-left: max(32px, calc((100% - 1080px) / 2));
    padding-right: max(32px, calc((100% - 1080px) / 2));
  }
  .ach-list { grid-template-columns: 1fr 1fr; gap: 12px; }
  .fair-guide { width: min(100%, 920px); margin-inline: auto; }
  .fair-guide__bill { grid-template-columns: 1fr 1fr; align-items: start; }
  .fair-card--board { grid-column: 1 / -1; }
  .collect-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .ladder { width: min(100%, 720px); margin-inline: auto; }
  .mega-board { width: min(100%, 760px); margin-inline: auto; }
  .ladder-scroll { padding-bottom: 96px; }
}

@media (max-width: 410px) {
  .hud-item { min-width: 67px; padding-left: 7px; padding-right: 7px; }
  .destinations { left: 8px; right: 8px; gap: clamp(40px, 14vw, 72px); }
  .dest-side { gap: 16px; }
  .destination { width: 96px; }
  .destination-art { width: 84px; height: 84px; }
  .destination strong { font-size: 13px; }
  .play-zone { bottom: max(72px, calc(var(--safe-bottom) + 36px)); }
}

.drawer.is-full.is-climb,
.drawer-wrap:has(.drawer.is-climb) {
  width: 100%;
  height: 100%;
  max-height: none;
  border: 0;
  border-radius: 0;
  background:
    linear-gradient(180deg, rgba(8, 6, 12, 0.82), rgba(8, 6, 12, 0.92)),
    var(--mega-plate, none) center 42% / cover no-repeat;
}

@media (prefers-reduced-motion: reduce) {
  :host * { scroll-behavior: auto !important; transition: none !important; }
  .rung.is-current .bulb { box-shadow: 0 0 0 5px rgba(246, 210, 127, .28); }
  .reward-btn.is-unseen,
  .collect-card.is-unseen { animation: none; }
}
