/* Soft sticky bar + game-over store CTA */

.games-soft-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  gap: 0.65rem 0.85rem;
  padding: 0.7rem 0.9rem calc(0.7rem + env(safe-area-inset-bottom, 0px));
  border-top: 1px solid var(--line, rgba(0, 0, 0, 0.12));
  background: color-mix(in srgb, var(--surface-strong, #fff) 92%, transparent);
  backdrop-filter: blur(10px);
  box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.08);
}

.games-soft-bar[hidden] {
  display: none !important;
}

body.has-games-soft-bar {
  padding-bottom: calc(4.5rem + env(safe-area-inset-bottom, 0px));
}

.games-soft-bar__text {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
  font-size: 0.92rem;
  line-height: 1.35;
  color: var(--text, inherit);
}

.games-soft-bar__cta {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.45rem 0.85rem;
  border-radius: 999px;
  background: var(--accent, #e40c0c);
  color: #fff;
  font-weight: 650;
  font-size: 0.88rem;
  text-decoration: none;
  white-space: nowrap;
}

.games-soft-bar__cta:hover {
  filter: brightness(1.05);
}

.games-soft-bar__cta:focus-visible {
  outline: 2px solid var(--accent, #e40c0c);
  outline-offset: 2px;
}

.games-soft-bar__close {
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--muted, #667);
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
}

.games-soft-bar__close:hover {
  background: color-mix(in srgb, var(--muted, #667) 12%, transparent);
}

.games-soft-bar__close:focus-visible {
  outline: 2px solid var(--accent, #e40c0c);
  outline-offset: 2px;
}

@media (max-width: 520px) {
  .games-soft-bar {
    flex-wrap: wrap;
  }

  .games-soft-bar__text {
    flex: 1 1 calc(100% - 2.5rem);
  }

  .games-soft-bar__close {
    order: 1;
  }

  .games-soft-bar__cta {
    width: 100%;
  }
}

/* Game-over secondary CTA (under Start / controls) */
.spn-g2a-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0.55rem 0 0;
  padding: 0.45rem 0.9rem;
  border: 1px solid var(--line, rgba(0, 0, 0, 0.14));
  border-radius: 999px;
  background: var(--surface-strong, #fff);
  color: var(--text, inherit);
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  line-height: 1.25;
}

.spn-g2a-cta[hidden] {
  display: none !important;
}

.spn-g2a-cta:hover {
  border-color: var(--accent, #e40c0c);
  color: var(--accent, #e40c0c);
}

.spn-g2a-cta:focus-visible {
  outline: 2px solid var(--accent, #e40c0c);
  outline-offset: 2px;
}

html[data-theme='dark'] .games-soft-bar {
  background: color-mix(in srgb, var(--surface-strong, #161a22) 94%, transparent);
  box-shadow: 0 -6px 24px rgba(0, 0, 0, 0.35);
}

html[data-theme='dark'] .spn-g2a-cta {
  background: #161a22;
}
