.game-mode-page {
  width: min(1180px, calc(100% - 2rem));
  margin: 8.5rem auto 3rem;
  overflow-x: clip;
}

.game-mode-transition-card {
  transition: transform 0.32s ease-in-out;
}

html.game-mode-entry-left .game-mode-page:not(.is-entering) .is-transition-forward,
html.game-mode-entry-right .game-mode-page:not(.is-entering) .is-transition-reverse,
.game-mode-page.is-leaving[data-transition-direction="next"] .is-transition-forward,
.game-mode-page.is-leaving[data-transition-direction="previous"] .is-transition-reverse {
  transform: translateX(calc(-100% - 2rem));
}

html.game-mode-entry-right .game-mode-page:not(.is-entering) .is-transition-forward,
html.game-mode-entry-left .game-mode-page:not(.is-entering) .is-transition-reverse,
.game-mode-page.is-leaving[data-transition-direction="previous"] .is-transition-forward,
.game-mode-page.is-leaving[data-transition-direction="next"] .is-transition-reverse {
  transform: translateX(calc(100% + 2rem));
}

@media (prefers-reduced-motion: reduce) {
  .game-mode-transition-card {
    transition: none;
  }
}

.game-mode-hero {
  touch-action: pan-y;
  position: relative;
  display: grid;
  min-height: 26rem;
  grid-template-columns: minmax(0, 1fr) 16rem;
  align-items: center;
  gap: 3rem;
  overflow: hidden;
  padding: clamp(2rem, 6vw, 5rem);
  border: 1px solid rgb(from var(--line) r g b / 22%);
  background:
    radial-gradient(circle at 82% 45%, rgb(from var(--mode-accent) r g b / 22%), transparent 27%),
    linear-gradient(135deg, #142923, #081315 68%);
}

.game-mode-copy {
  position: relative;
  z-index: 1;
}

.game-mode-copy h1 {
  margin: 0.5rem 0 1rem;
  color: var(--bone);
  font: 700 clamp(3.8rem, 9vw, 7.5rem) / 0.95 Cinzel, serif;
}

.game-mode-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem;
}

.game-mode-title-row h1 {
  margin-right: 0.25rem;
}

.game-mode-availability {
  padding: 0.4rem 0.75rem;
  border: 1px solid rgb(from var(--mode-accent) r g b / 70%);
  border-radius: 999px;
  color: var(--mode-accent);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.game-mode-lead {
  max-width: 46rem;
  margin: 0;
  color: #c4ceca;
  font-size: clamp(1rem, 2vw, 1.2rem);
  line-height: 1.8;
}

.game-mode-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 2rem;
}

.game-mode-actions .btn-disabled {
  border-color: rgb(from var(--mist) r g b / 28%);
  background: rgb(from var(--mist) r g b / 10%);
  color: var(--mist);
  cursor: not-allowed;
  opacity: 0.75;
}

.game-mode-emblem {
  display: grid;
  width: 15rem;
  height: 15rem;
  place-items: center;
  border: 1px solid rgb(from var(--mode-accent) r g b / 38%);
  border-radius: 50%;
  background: rgb(from var(--mode-accent) r g b / 9%);
  box-shadow: 0 0 5rem rgb(from var(--mode-accent) r g b / 15%);
}

.game-mode-emblem img {
  width: 8rem;
  height: 8rem;
  object-fit: contain;
  filter: brightness(1.08);
}

.game-mode-carousel-navigation {
  position: absolute;
  inset: 50% 2rem auto;
  z-index: 2;
  display: flex;
  justify-content: space-between;
  pointer-events: none;
  transform: translateY(-50%);
}

.game-mode-carousel-arrow {
  display: grid;
  width: 3.5rem;
  height: 3.5rem;
  place-items: center;
  border: 1px solid rgb(from var(--mode-accent) r g b / 55%);
  border-radius: 50%;
  background: rgb(from #081315 r g b / 82%);
  box-shadow: 0 0 1.2rem rgb(from var(--mode-accent) r g b / 12%);
  color: var(--bone);
  font: 400 2.35rem/1 Cinzel, serif;
  text-decoration: none;
  pointer-events: auto;
  transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.game-mode-carousel-arrow:hover,
.game-mode-carousel-arrow:focus-visible {
  border-color: var(--mode-accent);
  background: rgb(from var(--mode-accent) r g b / 22%);
  color: var(--bone);
  transform: scale(1.08);
}

.game-mode-rules {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
}

.game-mode-rule {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  min-height: 22rem;
  overflow: hidden;
  border: 1px solid rgb(from var(--line) r g b / 16%);
  background: linear-gradient(145deg, #10211e, #091314);
}

.game-mode-rule-copy {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(2rem, 4vw, 3.5rem);
}

.game-mode-rule:nth-child(even) .game-mode-rule-copy {
  order: 2;
}

.game-mode-rule:nth-child(even) figure {
  order: 1;
}

.game-mode-number {
  position: absolute;
  top: 0.75rem;
  right: 1rem;
  color: rgb(from var(--mode-accent) r g b / 24%);
  font: 700 3.5rem Cinzel, serif;
}

.game-mode-rule-copy h2,
.game-mode-summary h2 {
  position: relative;
  margin: 2.5rem 0 1rem;
  color: var(--bone);
  font: 700 1.35rem Cinzel, serif;
}

.game-mode-rule-copy p,
.game-mode-rule-copy li,
.game-mode-summary p {
  position: relative;
  margin: 0;
  color: var(--mist);
  line-height: 1.75;
}

.game-mode-rule-copy ul {
  display: grid;
  gap: 0.55rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.game-mode-rule-copy li,
.game-mode-technical-details li {
  position: relative;
  padding-left: 1.5rem;
}

.game-mode-rule-copy li::before,
.game-mode-technical-details li::before {
  position: absolute;
  top: 0.55em;
  left: 0.1rem;
  width: 0.55rem;
  height: 0.55rem;
  border: 1px solid rgb(from var(--mode-accent) r g b / 85%);
  background: rgb(from var(--mode-accent) r g b / 28%);
  box-shadow: 0 0 0.55rem rgb(from var(--mode-accent) r g b / 18%);
  content: "";
  transform: rotate(45deg);
}

.game-mode-summary {
  display: grid;
  grid-template-columns: minmax(16rem, 0.8fr) minmax(0, 1.2fr);
  align-items: center;
  gap: 3rem;
  margin-top: 1rem;
  padding: 2rem;
  border-left: 3px solid var(--mode-accent);
  background: #0d1b1b;
}

.game-mode-rule figure {
  display: grid;
  grid-template-rows: minmax(0, 1fr) auto;
  margin: 0;
  background: #081315;
}

.game-mode-rule img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 20rem;
  object-fit: cover;
}

.game-mode-rule figcaption {
  padding: 0.9rem 1rem;
  border-top: 1px solid rgb(from var(--mode-accent) r g b / 22%);
  color: #c4ceca;
  font-size: 0.86rem;
}

.game-mode-summary h2 {
  margin: 0.5rem 0 0;
}

.game-mode-hammer {
  --mode-accent: #fad352;
}

.game-mode-normal {
  --mode-accent: #fa8952;
}

.game-mode-hard {
  --mode-accent: #ff7e6a;
}

.game-mode-landoria-features {
  margin-top: 1rem;
  padding: clamp(1.5rem, 4vw, 2.5rem);
  border: 1px solid rgb(from var(--mode-accent) r g b / 38%);
  background:
    radial-gradient(circle at 100% 0, rgb(from var(--mode-accent) r g b / 12%), transparent 38%),
    #0d1b1b;
}

.game-mode-landoria-features > header {
  max-width: 50rem;
}

.game-mode-landoria-features h2 {
  margin: 0.5rem 0 0.75rem;
  color: var(--bone);
  font: 700 clamp(1.65rem, 3vw, 2.25rem)/1.2 Cinzel, serif;
}

.game-mode-landoria-features > header p,
.game-mode-landoria-grid p,
.game-mode-technical-details p {
  color: var(--mist);
  line-height: 1.7;
}

.game-mode-landoria-features > header p {
  margin: 0;
}

.game-mode-landoria-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  margin-top: 2rem;
}

.game-mode-landoria-grid article {
  padding: 1.5rem;
  border: 1px solid rgb(from var(--line) r g b / 18%);
  background: #091516;
}

.game-mode-landoria-grid h3 {
  margin: 0 0 0.65rem;
  color: var(--bone);
  font: 700 1.1rem/1.3 Cinzel, serif;
}

.game-mode-landoria-grid p {
  margin: 0;
}

.game-mode-landoria-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem 2rem;
  margin: 2rem 0 0;
  padding: 0;
  color: var(--mist);
  line-height: 1.65;
  list-style: none;
}

.game-mode-landoria-list li {
  position: relative;
  padding: 0.9rem 0 0.9rem 1.5rem;
  border-bottom: 1px solid rgb(from var(--line) r g b / 15%);
}

.game-mode-landoria-list li::before {
  position: absolute;
  top: 1.45rem;
  left: 0.1rem;
  width: 0.55rem;
  height: 0.55rem;
  border: 1px solid rgb(from var(--mode-accent) r g b / 85%);
  background: rgb(from var(--mode-accent) r g b / 28%);
  box-shadow: 0 0 0.55rem rgb(from var(--mode-accent) r g b / 18%);
  content: "";
  transform: rotate(45deg);
}

.game-mode-landoria-list strong {
  color: var(--bone);
}

.game-mode-technical-details {
  margin-top: 1rem;
  border: 1px solid rgb(from var(--line) r g b / 18%);
  background: #091516;
}

.game-mode-technical-details summary {
  padding: 1rem 1.25rem;
  color: var(--bone);
  font-weight: 700;
  cursor: pointer;
  user-select: none;
}

.game-mode-technical-details[open] summary {
  border-bottom: 1px solid rgb(from var(--line) r g b / 18%);
}

.game-mode-technical-details > div {
  padding: 0.25rem 1.25rem 1.25rem;
}

.game-mode-technical-details p {
  margin: 1rem 0 0;
}

.game-mode-technical-details ul {
  display: grid;
  gap: 0.8rem;
  margin: 1rem 0 0;
  padding: 0;
  color: var(--mist);
  line-height: 1.65;
  list-style: none;
}

.game-mode-technical-details strong {
  color: var(--bone);
}

.other-game-modes {
  display: grid;
  grid-template-columns: minmax(13rem, 0.55fr) minmax(0, 1.45fr);
  gap: 2rem;
  margin-top: 1rem;
  padding: 2rem;
  border: 1px solid rgb(from var(--line) r g b / 18%);
  background: #0d1b1b;
}

.other-game-modes-heading h2 {
  margin: 0.45rem 0 0;
  color: var(--bone);
  font: 700 1.45rem/1.2 Cinzel, serif;
}

.other-game-modes-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.other-game-mode-link {
  position: relative;
  display: grid;
  grid-template-columns: 4rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 1.1rem;
  min-height: 8rem;
  padding: 1.25rem 1.2rem;
  border: 1px solid rgb(from var(--other-mode-accent) r g b / 58%);
  background:
    radial-gradient(circle at 0 50%, rgb(from var(--other-mode-accent) r g b / 22%), transparent 48%),
    #122321;
  color: var(--mist);
  text-decoration: none;
  transition: border-color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.other-game-mode-link:hover,
.other-game-mode-link:focus-visible {
  border-color: var(--other-mode-accent);
  background-color: #19302c;
  color: var(--bone);
  transform: translateY(-0.2rem);
}

.other-game-mode-link > img {
  width: 4rem;
  height: 4rem;
  object-fit: contain;
}

.other-game-mode-copy {
  display: grid;
  gap: 0.55rem;
}

.other-game-mode-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem;
}

.other-game-mode-link strong {
  color: var(--bone);
  font: 700 1.3rem Cinzel, serif;
}

.other-game-mode-link small {
  padding: 0.22rem 0.45rem;
  border: 1px solid #ff7e6a88;
  border-radius: 999px;
  color: #ff7e6a;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.other-game-mode-copy > span:last-child {
  font-size: 0.82rem;
  line-height: 1.5;
}

.other-game-mode-link b {
  color: var(--other-mode-accent);
  font-size: 1.55rem;
}

.game-mode-join-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  margin-top: 1rem;
  padding: 2rem;
  border: 1px solid rgb(from var(--mode-accent) r g b / 28%);
  background:
    radial-gradient(circle at 15% 50%, rgb(from var(--mode-accent) r g b / 12%), transparent 35%),
    #0d1b1b;
}

.game-mode-join-cta h2 {
  margin: 0.45rem 0 0;
  color: var(--bone);
  font: 700 1.45rem/1.2 Cinzel, serif;
}

.game-mode-join-cta .btn {
  flex: none;
}

.game-mode-register-page {
  width: min(1180px, calc(100% - 2rem));
  margin: 8.5rem auto 3rem;
}

.game-mode-register-header {
  max-width: 46rem;
  margin-bottom: 2rem;
}

.game-mode-register-header h1 {
  margin: 0.5rem 0 0.75rem;
  color: var(--bone);
  font: 700 clamp(2.5rem, 6vw, 4.8rem)/1.05 Cinzel, serif;
}

.game-mode-register-header p {
  margin: 0;
  color: var(--mist);
}

.game-mode-choice-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.game-mode-overview-page .game-mode-choice-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.game-mode-register-actions {
  display: flex;
  justify-content: center;
  margin-top: 2rem;
}

.game-mode-choice {
  position: relative;
  display: grid;
  min-height: 27rem;
  grid-template-rows: auto 1fr auto;
  justify-items: start;
  gap: 1.5rem;
  padding: 2rem;
  overflow: hidden;
  border: 1px solid rgb(from var(--line) r g b / 20%);
  background: linear-gradient(145deg, #10211e, #091314);
}

.game-mode-choice > img {
  width: 6rem;
  height: 6rem;
  object-fit: contain;
}

.game-mode-choice h2 {
  margin: 0.4rem 0 0.75rem;
  color: var(--bone);
  font: 700 2rem/1 Cinzel, serif;
}

.game-mode-choice p {
  margin: 0;
  color: var(--mist);
  line-height: 1.65;
}

.game-mode-choice-details {
  display: inline-block;
  margin-top: 1rem;
  color: var(--ember);
  font-size: 0.86rem;
  font-weight: 700;
  text-decoration: none;
}

.game-mode-choice-details:hover,
.game-mode-choice-details:focus-visible {
  color: var(--bone);
  text-decoration: underline;
  text-underline-offset: 0.25rem;
}

.game-mode-choice-status,
.game-mode-choice-lock {
  position: absolute;
  top: 1rem;
  right: 1rem;
}

.game-mode-choice-status {
  padding: 0.35rem 0.65rem;
  border: 1px solid rgb(from var(--ember) r g b / 60%);
  border-radius: 999px;
  color: var(--ember);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.game-mode-choice-lock {
  display: grid;
  width: 2.5rem;
  height: 2.5rem;
  place-items: center;
  border-radius: 50%;
  background: #1d2928;
  color: var(--mist);
}

.game-mode-choice-lock svg {
  width: 1.2rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.7;
}

.game-mode-choice.is-locked,
.game-mode-choice.is-coming-soon {
  opacity: 0.72;
}

.game-mode-choice .btn {
  width: 100%;
  text-align: center;
}

.game-mode-choice .btn-disabled {
  border-color: rgb(from var(--mist) r g b / 25%);
  background: rgb(from var(--mist) r g b / 8%);
  color: var(--mist);
  cursor: not-allowed;
}

.game-mode-choice-requirement {
  align-self: end;
  color: var(--mist);
  font-size: 0.78rem;
}

@media (max-width: 850px) {
  .game-mode-hero {
    grid-template-columns: minmax(0, 1fr) 9rem;
    gap: 1.5rem;
  }

  .game-mode-emblem {
    width: 9rem;
    height: 9rem;
  }

  .game-mode-emblem img {
    width: 5.5rem;
    height: 5.5rem;
  }

  .game-mode-rule {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .game-mode-rule:nth-child(even) .game-mode-rule-copy,
  .game-mode-rule:nth-child(even) figure {
    order: initial;
  }

  .game-mode-rule img {
    min-height: 16rem;
  }

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

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

  .game-mode-landoria-list {
    grid-template-columns: 1fr;
  }

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

  .game-mode-choice {
    min-height: 0;
  }
}

@media (max-width: 600px) {
  .game-mode-page {
    margin-top: 6.5rem;
  }

  .game-mode-register-page {
    margin-top: 6.5rem;
  }

  .game-mode-hero {
    grid-template-columns: 1fr;
    padding: 2rem 3.75rem;
  }

  .game-mode-carousel-navigation {
    inset-inline: 1rem;
  }

  .game-mode-carousel-arrow {
    width: 3rem;
    height: 3rem;
  }

  .game-mode-emblem {
    grid-row: 1;
  }

  .game-mode-actions .btn {
    width: 100%;
  }

  .game-mode-summary {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .other-game-modes-list {
    grid-template-columns: 1fr;
  }

  .game-mode-join-cta {
    align-items: stretch;
    flex-direction: column;
  }

  .game-mode-join-cta .btn {
    width: 100%;
  }
}
