.ls-page {
  --ls-bg: #050505;
  --ls-text: #ffffff;
  --ls-muted: #888888;
  --ls-gk: #39ff14;
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0;
  font-family: "Outfit", system-ui, sans-serif;
  background: var(--ls-bg);
  color: var(--ls-text);
  /* Spine spacer handles header + safe-area — don't double-count here. */
  /* Extra room for Safari/Chrome bottom bar on iPhones. */
  padding: 0.35rem max(0.65rem, env(safe-area-inset-left))
    calc(6.25rem + env(safe-area-inset-bottom, 0px)) max(0.65rem, env(safe-area-inset-right));
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
  box-sizing: border-box;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.ls-wrap {
  max-width: 620px;
  margin: 0 auto;
  text-align: center;
  background: #0a0a0a;
  border-radius: 16px;
  padding: 16px 10px 18px;
  font-family: "Barlow Condensed", system-ui, sans-serif;
  overflow: visible;
  box-sizing: border-box;
}

.ls-steps-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 5px;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

.ls-steps-bar__item {
  padding: 4px 11px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--ls-gk);
  border: 1px solid rgba(57, 255, 20, 0.4);
  border-radius: 50px;
}

.ls-steps-bar__item--active {
  color: #0a0a0a;
  background: var(--ls-gk);
  border-color: var(--ls-gk);
}

.ls-steps-bar__sep {
  color: #444;
  font-weight: 700;
  font-size: 16px;
}

.ls-headline {
  margin: 0 0 18px;
  line-height: 1;
}

.ls-headline__top {
  display: block;
  font-size: clamp(1.6rem, 4vw, 2.2rem);
  font-weight: 900;
  color: white;
  letter-spacing: 3px;
}

.ls-headline__accent {
  display: block;
  font-size: clamp(2rem, 5vw, 2.8rem);
  font-weight: 900;
  color: var(--ls-gk);
  letter-spacing: 3px;
  line-height: 1.15;
  margin-top: 0.1rem;
}

.ls-token-panel {
  margin: 16px 0 12px;
  padding: 12px 16px;
  border: 1px solid rgba(57, 255, 20, 0.45);
  border-radius: 12px;
  background: rgba(57, 255, 20, 0.08);
  text-align: center;
}

.ls-token-panel.is-locked {
  border-color: rgba(57, 255, 20, 0.25);
  background: rgba(255, 255, 255, 0.04);
}

.ls-token-panel__row {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 8px;
}

.ls-token-panel__count {
  font-family: "Barlow Condensed", system-ui, sans-serif;
  font-size: 2.4rem;
  font-weight: 900;
  color: var(--ls-gk);
  line-height: 1;
  letter-spacing: 2px;
}

.ls-token-panel__label {
  font-family: "Barlow Condensed", system-ui, sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  color: #ccc;
  letter-spacing: 2px;
}

.ls-token-panel__best {
  margin: 6px 0 0;
  font-family: "Outfit", system-ui, sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: #aaa;
}

.ls-roll-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-top: 14px;
}

.ls-roll-actions.is-hidden {
  display: none;
}

.ls-referral {
  margin-top: 18px;
  padding: 14px;
  border: 1px solid rgba(57, 255, 20, 0.25);
  border-radius: 10px;
  background: rgba(57, 255, 20, 0.04);
  text-align: left;
}

.ls-referral.is-hidden {
  display: none;
}

.ls-referral__title {
  margin: 0 0 8px;
  font-family: "Outfit", system-ui, sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: #ccc;
}

.ls-referral__row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.ls-referral__input {
  flex: 1 1 180px;
  min-width: 0;
  background: #111;
  border: 1px solid #333;
  border-radius: 8px;
  color: #aaa;
  font-size: 11px;
  padding: 8px 10px;
  font-family: monospace;
}

.ls-bank__frame {
  background: #161616;
  border: 2px solid #2a2a2a;
  border-radius: 10px;
  padding: 12px 8px;
  overflow: hidden;
}

.ls-bank__row {
  display: flex;
  gap: 6px;
  justify-content: center;
  overflow: hidden;
}

.ls-bank__vent--top {
  height: 10px;
  background: #222;
  border-radius: 5px 5px 0 0;
  margin: -12px -8px 12px;
  border-bottom: 2px solid #111;
}

.ls-bank__vent--bottom {
  height: 10px;
  background: #222;
  border-radius: 0 0 5px 5px;
  margin: 12px -8px -12px;
  border-top: 2px solid #111;
}

.ls-locker {
  position: relative;
  width: 108px;
  height: 194px;
  border-radius: 6px;
  overflow: hidden;
  flex-shrink: 0;
}

.ls-locker__inside {
  position: absolute;
  inset: 0;
  background: #0d0d0d;
  border: 2px solid #333;
  border-radius: 6px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.ls-locker__prize-icon {
  font-size: 2rem;
  line-height: 1;
}

.ls-locker__prize-label {
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--ls-gk);
  text-align: center;
  padding: 0 4px;
  line-height: 1.3;
}

.ls-locker__door {
  position: absolute;
  inset: 0;
  background: #333;
  border: 2px solid #555;
  border-radius: 6px;
  transition: transform 0.9s cubic-bezier(0.77, 0, 0.175, 1);
  transform-origin: left center;
  overflow: hidden;
}

.ls-locker__door.is-open {
  transform: rotateY(-82deg);
}

.ls-locker__door-head {
  background: var(--ls-gk);
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 9px;
}

.ls-locker__num {
  font-weight: 900;
  font-size: 16px;
  color: #000;
}

.ls-locker__knob {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #000;
}

.ls-locker__vents {
  padding: 12px 9px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ls-locker__vent-line {
  height: 5px;
  background: #222;
  border-top: 1px solid #4a4a4a;
  border-radius: 2px;
}

.ls-locker__handle {
  position: absolute;
  bottom: 12px;
  right: 9px;
  width: 13px;
  height: 30px;
  background: #444;
  border: 1px solid #666;
  border-radius: 3px;
}

.ls-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 18px;
}

.ls-action-bar {
  margin-top: 12px;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  gap: 8px;
  width: 100%;
}

.ls-action-bar .ls-mute-btn {
  flex: 0 0 auto;
}

.ls-action-bar .ls-controls {
  flex: 1 1 auto;
  margin-top: 0;
  min-width: 0;
}

.ls-action-bar .ls-controls:has(#lsSpinBtn[hidden]) {
  display: none;
}

.ls-action-bar .ls-roll-actions:not(.is-hidden) {
  display: flex;
  flex: 1 1 auto;
  margin-top: 0;
  gap: 6px;
  min-width: 0;
}

.ls-action-bar .ls-roll-actions:not(.is-hidden) .ls-btn {
  flex: 1 1 0;
  min-width: 0;
}

.ls-action-bar .ls-spin-btn {
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.ls-spin-btn {
  appearance: none;
  border: none;
  border-radius: 50px;
  padding: 14px 44px;
  font-family: "Barlow Condensed", system-ui, sans-serif;
  font-weight: 900;
  font-size: 1.2rem;
  letter-spacing: 3px;
  cursor: pointer;
  background: var(--ls-gk);
  color: #0a0a0a;
  transition: opacity 0.2s;
}

.ls-spin-btn:disabled {
  opacity: 0.4;
  cursor: default;
}

.ls-mute-btn {
  background: #1a1a1a;
  color: var(--ls-gk);
  border: 1px solid #333;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ls-result {
  margin-top: 16px;
  padding: 20px;
  background: #111;
  border: 1px solid rgba(57, 255, 20, 0.5);
  border-radius: 12px;
  overflow: hidden;
}

.ls-result.is-hidden {
  display: none;
}

.ls-result__grand-banner {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 3px;
  color: #0a0a0a;
  background: var(--ls-gk);
  padding: 8px;
  margin: -20px -20px 16px;
}

.ls-result__grand-banner.is-hidden {
  display: none;
}

.ls-result__eyebrow {
  margin: 0 0 8px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 3px;
  color: var(--ls-gk);
  text-transform: uppercase;
}

.ls-result__icon {
  font-size: 2.5rem;
  line-height: 1;
  margin-bottom: 6px;
}

.ls-result__title {
  font-family: "Barlow Condensed", system-ui, sans-serif;
  margin: 0 0 6px;
  font-size: 1.5rem;
  font-weight: 900;
  color: white;
  letter-spacing: 1px;
}

.ls-result__desc,
.ls-result__locker-note {
  margin: 0 0 0.75rem;
  color: var(--ls-muted);
  font-size: 13px;
  line-height: 1.5;
  font-family: Arial, sans-serif;
  font-weight: 400;
}

.ls-result__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-top: 14px;
}

.ls-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 20px;
  border-radius: 50px;
  font-family: "Barlow Condensed", system-ui, sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 2px;
  text-decoration: none;
  cursor: pointer;
}

.ls-btn--primary {
  background: var(--ls-gk);
  color: #0a0a0a;
  border: none;
}

.ls-btn--ghost {
  background: transparent;
  color: var(--ls-gk);
  border: 1px solid rgba(57, 255, 20, 0.5);
}

.ls-open-access {
  margin-top: 1rem;
  padding: 0.65rem 0.85rem;
  border: 1px solid rgba(57, 255, 20, 0.45);
  border-radius: 6px;
  background: rgba(57, 255, 20, 0.08);
  color: var(--ls-gk);
  font-size: 0.88rem;
  font-family: "Outfit", system-ui, sans-serif;
  text-align: center;
}

.ls-status {
  margin-top: 1rem;
  font-size: 0.9rem;
  font-family: "Outfit", system-ui, sans-serif;
}

.ls-status--err {
  color: #ff6b6b;
}

.ls-status:not(.is-hidden) {
  color: var(--ls-muted);
}

.is-hidden {
  display: none !important;
}

@media (max-width: 580px) {
  .ls-locker {
    width: 88px;
    height: 158px;
  }

  .ls-locker__prize-icon {
    font-size: 1.65rem;
  }

  .ls-spin-btn {
    padding: 12px 28px;
    font-size: 1rem;
  }
}

/* Phones — iPhone 11/SE through Pro Max: fit lockers + actions above browser chrome */
@media (max-width: 520px) {
  .ls-wrap {
    padding: 12px 8px 14px;
    border-radius: 12px;
  }

  .ls-steps-bar {
    margin-bottom: 8px;
    gap: 4px;
  }

  .ls-steps-bar__item:not(.ls-steps-bar__item--active),
  .ls-steps-bar__sep {
    display: none;
  }

  .ls-steps-bar__item--active {
    font-size: 9px;
    letter-spacing: 1.5px;
    padding: 3px 10px;
  }

  .ls-headline {
    margin-bottom: 10px;
  }

  .ls-headline__top {
    font-size: 1.35rem;
    letter-spacing: 2px;
  }

  .ls-headline__accent {
    font-size: 1.75rem;
    letter-spacing: 2px;
  }

  .ls-bank__frame {
    padding: 6px 4px;
  }

  .ls-bank__row {
    gap: 3px;
    justify-content: stretch;
  }

  .ls-locker {
    flex: 1 1 0;
    flex-shrink: 1;
    width: auto;
    min-width: 0;
    height: auto;
    aspect-ratio: 76 / 136;
    max-height: 132px;
  }

  .ls-locker__door-head {
    height: 22px;
    padding: 0 7px;
  }

  .ls-locker__num {
    font-size: 13px;
  }

  .ls-locker__vents {
    padding: 8px 7px;
    gap: 8px;
  }

  .ls-locker__vent-line {
    height: 4px;
  }

  .ls-locker__handle {
    bottom: 8px;
    right: 7px;
    width: 11px;
    height: 24px;
  }

  .ls-token-panel {
    margin: 8px 0 6px;
    padding: 7px 10px;
  }

  .ls-token-panel__count {
    font-size: 1.85rem;
  }

  .ls-token-panel__label {
    font-size: 0.72rem;
    letter-spacing: 1.5px;
  }

  .ls-token-panel__best {
    font-size: 11px;
    margin-top: 4px;
  }

  .ls-controls {
    margin-top: 0;
    gap: 8px;
  }

  .ls-action-bar {
    margin-top: 8px;
    gap: 6px;
  }

  .ls-spin-btn {
    padding: 10px 16px;
    font-size: 0.88rem;
    letter-spacing: 1.5px;
  }

  .ls-mute-btn {
    width: 36px;
    height: 36px;
    font-size: 13px;
  }

  .ls-roll-actions {
    margin-top: 0;
    gap: 5px;
  }

  .ls-btn {
    padding: 9px 8px;
    font-size: 10px;
    letter-spacing: 1px;
  }

  .ls-referral {
    margin-top: 10px;
    padding: 8px;
  }

  .ls-referral__title {
    font-size: 10px;
    margin-bottom: 5px;
    line-height: 1.3;
  }

  .ls-referral__input {
    font-size: 10px;
    padding: 6px 8px;
  }

  .ls-open-access {
    margin-top: 0.5rem;
    margin-bottom: 0.25rem;
    padding: 0.4rem 0.55rem;
    font-size: 0.68rem;
    line-height: 1.35;
  }
}

@media (max-height: 740px) {
  .ls-headline {
    margin-bottom: 6px;
  }

  .ls-headline__top {
    font-size: 1.15rem;
  }

  .ls-headline__accent {
    font-size: 1.45rem;
  }

  .ls-locker {
    max-height: 118px;
  }

  .ls-token-panel {
    margin: 6px 0 4px;
    padding: 6px 10px;
  }

  .ls-token-panel__count {
    font-size: 1.55rem;
  }

  .ls-action-bar {
    margin-top: 6px;
  }
}
