.story-mode {
  width: min(1500px, 100%);
  margin: 0 auto;
  padding: clamp(14px, 2vw, 28px);
}

.story-mode__loading {
  min-height: 50vh;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  color: var(--portal-muted, #98a8c8);
  letter-spacing: .16em;
  font-weight: 900;
}

.story-hero {
  position: relative;
  overflow: hidden;
  min-height: 330px;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, .75fr);
  gap: 24px;
  align-items: center;
  padding: clamp(24px, 4vw, 58px);
  border: 1px solid rgba(255, 221, 74, .24);
  border-radius: 28px;
  background:
    radial-gradient(circle at 80% 25%, rgba(255,221,74,.18), transparent 30%),
    linear-gradient(135deg, rgba(18,26,48,.98), rgba(7,12,25,.98));
  box-shadow: 0 30px 90px rgba(0,0,0,.25);
}

.story-hero::after {
  content: "";
  position: absolute;
  width: 440px;
  height: 440px;
  right: -130px;
  top: -170px;
  border: 1px solid rgba(255,255,255,.06);
  border-radius: 50%;
}

.story-hero h1 {
  margin: 12px 0 16px;
  font-size: clamp(54px, 8vw, 112px);
  line-height: .82;
  letter-spacing: -.06em;
}

.story-hero h1 span {
  display: block;
  color: #ffdb3b;
}

.story-hero p {
  max-width: 650px;
  color: #aebbd2;
  font-size: clamp(16px, 1.5vw, 20px);
}

.story-hero__signals,
.story-game__features {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}

.story-hero__signals span,
.story-game__features span {
  padding: 7px 10px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 999px;
  background: rgba(255,255,255,.035);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: .08em;
}

.story-hero__art {
  min-height: 250px;
  display: grid;
  place-items: center;
}

.story-orb {
  position: relative;
  width: min(280px, 70vw);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(255,225,74,.3), rgba(255,225,74,.05) 54%, transparent 55%);
  filter: drop-shadow(0 30px 40px rgba(255,205,45,.12));
}

.story-orb::before,
.story-orb::after {
  content: "";
  position: absolute;
  border: 1px solid rgba(255,235,135,.25);
  border-radius: 50%;
}

.story-orb::before {
  inset: 12%;
}

.story-orb::after {
  inset: -8%;
}

.story-orb img {
  position: relative;
  z-index: 2;
  width: 72%;
  image-rendering: pixelated;
}

.story-unlock {
  margin: 18px 0;
  padding: 20px 24px;
  display: flex;
  gap: 20px;
  justify-content: space-between;
  align-items: center;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 18px;
  background: rgba(8,15,29,.92);
}

.story-unlock h2 {
  margin: 6px 0 4px;
}

.story-unlock p {
  margin: 0;
  color: #93a5c2;
}

.story-unlock strong {
  white-space: nowrap;
  padding: 10px 14px;
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: .08em;
}

.story-unlock .is-ready {
  color: #71f6bc;
  border: 1px solid rgba(113,246,188,.35);
  background: rgba(113,246,188,.08);
}

.story-unlock .is-locked {
  color: #ffce70;
  border: 1px solid rgba(255,206,112,.25);
  background: rgba(255,206,112,.07);
}

.story-games {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 18px;
}

.story-game {
  overflow: hidden;
  display: grid;
  grid-template-columns: minmax(220px,.82fr) minmax(0,1.18fr);
  min-height: 420px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 24px;
  background: #09111f;
}

.story-game__visual {
  position: relative;
  overflow: hidden;
  min-height: 320px;
  padding: 22px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background:
    radial-gradient(circle at 50% 40%, rgba(255,225,64,.35), transparent 40%),
    linear-gradient(155deg, #302b0d, #131407 70%);
}

.story-game--crystal .story-game__visual {
  background:
    radial-gradient(circle at 50% 40%, rgba(65,212,255,.23), transparent 40%),
    linear-gradient(155deg, #082439, #07121d 70%);
}

.story-game__visual::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .18;
  background:
    linear-gradient(90deg, transparent 49%, rgba(255,255,255,.1) 50%, transparent 51%),
    linear-gradient(transparent 49%, rgba(255,255,255,.08) 50%, transparent 51%);
  background-size: 34px 34px;
}

.story-game__gen,
.story-game__visual > strong {
  position: relative;
  z-index: 2;
  font-weight: 950;
  letter-spacing: .14em;
}

.story-game__visual > strong {
  font-size: clamp(30px,4vw,56px);
}

.story-game__pokemon {
  position: relative;
  z-index: 2;
  display: grid;
  place-items: center;
}

.story-game__pokemon img {
  width: min(200px,80%);
  image-rendering: pixelated;
  filter: drop-shadow(0 28px 22px rgba(0,0,0,.4));
}

.story-game__body {
  padding: clamp(22px,3vw,38px);
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.story-game__status {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 11px;
  font-weight: 950;
  letter-spacing: .12em;
  color: #91a3c0;
}

.story-game.is-unlocked .story-game__status b {
  color: #6ff2b3;
}

.story-game.is-locked .story-game__status b {
  color: #ffbf64;
}

.story-game__body h2 {
  margin: 20px 0 12px;
  font-size: clamp(30px,4vw,50px);
  line-height: .92;
}

.story-game__body p {
  color: #9eadc5;
  line-height: 1.6;
}

.story-button {
  min-height: 48px;
  margin-top: 24px;
  padding: 12px 18px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 12px;
  background: rgba(255,255,255,.06);
  color: #eaf3ff;
  font: inherit;
  font-weight: 950;
  letter-spacing: .08em;
  text-decoration: none;
  cursor: pointer;
}

.story-button--play {
  border-color: rgba(255,220,55,.4);
  background:
    linear-gradient(135deg,#ffe14f,#ffba38);
  color: #15150b;
  box-shadow: 0 14px 40px rgba(255,205,48,.16);
}

.story-button:disabled {
  opacity: .48;
  cursor: not-allowed;
}

.story-game__message {
  min-height: 22px;
  margin-top: 10px;
  color: #ffcc74;
  font-size: 12px;
  text-align: center;
}

.story-access-card {
  min-height: 280px;
  padding: 32px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 24px;
  align-items: center;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 22px;
  background: rgba(7,14,28,.94);
}

.story-lock {
  font-size: 42px;
}

@media (max-width: 1100px) {
  .story-games {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 800px) {
  .story-hero {
    grid-template-columns: 1fr;
  }

  .story-hero__art {
    min-height: 180px;
  }

  .story-orb {
    width: 190px;
  }

  .story-game {
    grid-template-columns: 1fr;
  }

  .story-unlock {
    align-items: flex-start;
    flex-direction: column;
  }

  .story-access-card {
    grid-template-columns: 1fr;
  }
}
