/* Final visual refinements: compact headlines, icon-led navigation, and vertical reading flow. */
h1 {
  font-size: clamp(37px, 4.45vw, 58px);
  line-height: .98;
}

/* The updated lead image is a 16:9 scene. */
.hero-image-frame img { aspect-ratio: 16 / 9; }

.section-heading h2,
.guide-sidebar h2,
.visual-break-copy h2,
.updates-heading h2,
.faq-heading h2,
.gallery-heading h2,
.closing-cta h2 {
  font-size: clamp(27px, 2.9vw, 40px);
  line-height: 1.03;
}

.site-nav > a,
.button,
.text-link,
.footer-inner > a {
  position: relative;
}

.site-nav > a:not(.nav-cta)::before,
.nav-cta::before,
.button::before,
.text-link::before,
.footer-inner > a::before {
  display: inline-grid;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  place-items: center;
  font-size: 12px;
  line-height: 1;
  font-weight: 900;
}

.site-nav > a:nth-child(1)::before { content: '◉'; }
.site-nav > a:nth-child(2)::before { content: '▦'; }
.site-nav > a:nth-child(3)::before { content: '✦'; }
.site-nav > a:nth-child(4)::before { content: '◇'; }
.site-nav > a:nth-child(5)::before { content: '↻'; }
.site-nav > a:nth-child(6)::before { content: '?'; border: 1px solid currentColor; border-radius: 50%; font-size: 10px; }
.nav-cta::before, .button::before { content: '▣'; }
.text-link::before { content: '✦'; color: var(--lime); }
.footer-inner > a::before { content: '↑'; color: var(--lime); }

.site-nav > a,
.nav-cta,
.button,
.text-link,
.footer-inner > a {
  display: inline-flex;
  align-items: center;
}

.site-nav > a:not(.nav-cta) { gap: 5px; }
.nav-cta, .button, .text-link, .footer-inner > a { gap: 8px; }

/* Unified capsule controls. */
.site-nav > a,
.nav-cta,
.button,
.text-link,
.footer-inner > a,
.menu-toggle {
  border-radius: 999px;
}

.site-nav > a:not(.nav-cta) {
  min-height: 34px;
  padding: 5px 10px;
  border: 1px solid rgba(240, 244, 248, .11);
  background: rgba(240, 244, 248, .045);
  transition: color .2s, border-color .2s, background .2s, transform .2s;
}

.site-nav > a:not(.nav-cta):hover,
.site-nav > a:not(.nav-cta):focus-visible {
  border-color: rgba(57, 255, 20, .5);
  background: rgba(57, 255, 20, .1);
  transform: translateY(-1px);
}

.nav-cta,
.button-primary {
  border-radius: 999px;
  background: var(--lime);
  color: #082019;
  box-shadow: 0 7px 21px rgba(57, 255, 20, .15);
}

.button-outline {
  border-radius: 999px;
  background: rgba(57, 255, 20, .06);
}

/* Persistent detail access replaces the former bottom call-to-action section. */
.floating-detail-cta {
  position: fixed;
  z-index: 90;
  right: clamp(18px, 4vw, 42px);
  bottom: clamp(18px, 4vw, 34px);
  min-width: 148px;
  min-height: 46px;
  padding: 0 20px;
  white-space: nowrap;
  box-shadow: 0 10px 28px rgba(0, 0, 0, .34), 0 7px 21px rgba(57, 255, 20, .18);
}

.floating-detail-cta:hover,
.floating-detail-cta:focus-visible {
  transform: translateY(-3px);
  box-shadow: 0 14px 32px rgba(0, 0, 0, .38), 0 9px 26px rgba(57, 255, 20, .28);
}

.text-link,
.footer-inner > a {
  min-height: 38px;
  padding: 5px 14px;
  border: 1px solid rgba(57, 255, 20, .32);
  background: rgba(57, 255, 20, .055);
}

.text-link {
  border-bottom-width: 1px;
}

.menu-toggle {
  border-color: rgba(57, 255, 20, .32);
  background: rgba(57, 255, 20, .06);
}

/* Modern interaction layer: tactile feedback without shifting the page layout. */
:where(a, button, summary):focus-visible {
  outline: 2px solid var(--lime);
  outline-offset: 4px;
}

.brand {
  transition: color .25s ease, transform .25s ease;
}

.brand:hover,
.brand:focus-visible {
  color: var(--lime);
  transform: translateY(-1px);
}

.brand img {
  transition: transform .35s ease, box-shadow .35s ease, border-color .25s ease;
}

.brand:hover img,
.brand:focus-visible img {
  transform: rotate(-5deg) scale(1.06);
  border-color: var(--lime);
  box-shadow: 0 0 0 4px rgba(57, 255, 20, .1), 0 7px 18px rgba(0, 0, 0, .25);
}

.button,
.nav-cta {
  overflow: hidden;
  isolation: isolate;
}

.button::after,
.nav-cta::after {
  position: absolute;
  top: 0;
  bottom: 0;
  left: -75%;
  width: 45%;
  content: "";
  pointer-events: none;
  background: linear-gradient(105deg, transparent, rgba(255, 255, 255, .3), transparent);
  transform: skewX(-18deg);
  transition: left .55s ease;
}

.button:hover::after,
.button:focus-visible::after,
.nav-cta:hover::after,
.nav-cta:focus-visible::after {
  left: 135%;
}

.hero-image-frame {
  transition: border-color .3s ease, box-shadow .3s ease, transform .35s ease;
}

.hero-image-frame:hover,
.hero-image-frame:focus-within {
  border-color: var(--lime);
  box-shadow: 0 0 0 4px rgba(57, 255, 20, .08), 0 18px 40px rgba(0, 0, 0, .28);
  transform: translateY(-3px);
}

.hero-image-frame img {
  transition: transform .6s cubic-bezier(.2, .7, .2, 1), filter .35s ease;
}

.hero-image-frame:hover img,
.hero-image-frame:focus-within img {
  transform: scale(1.025);
  filter: saturate(1.08) contrast(1.03);
}

.match-card {
  transition: transform .3s ease, box-shadow .3s ease, border-color .3s ease;
}

.match-card:hover {
  transform: translate(-3px, -4px);
  border-left-color: var(--lime-soft);
  box-shadow: 0 20px 35px rgba(0, 0, 0, .34), 0 0 0 1px rgba(57, 255, 20, .12);
}

.quick-strip a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color .2s ease, transform .2s ease;
}

.quick-strip a:hover,
.quick-strip a:focus-visible {
  transform: translateX(4px);
}

.system-card,
.feature-grid article {
  transition: background .3s ease, border-color .3s ease, box-shadow .3s ease, transform .3s ease;
}

.system-card:hover,
.system-card:focus-within,
.feature-grid article:hover,
.feature-grid article:focus-within {
  position: relative;
  z-index: 1;
  border-color: rgba(57, 255, 20, .28);
  box-shadow: 0 12px 28px rgba(0, 0, 0, .2), inset 0 0 0 1px rgba(57, 255, 20, .1);
  transform: translateY(-4px);
}

.system-card h3,
.feature-grid h3,
.guide-list h3,
.timeline h3 {
  transition: color .25s ease;
}

.system-card:hover h3,
.system-card:focus-within h3,
.feature-grid article:hover h3,
.feature-grid article:focus-within h3,
.guide-list article:hover h3,
.timeline li:hover h3 {
  color: var(--lime-soft);
}

.feature-icon {
  display: inline-block;
  transition: transform .3s ease, text-shadow .3s ease;
}

.feature-grid article:hover .feature-icon,
.feature-grid article:focus-within .feature-icon {
  transform: translateY(-3px) scale(1.12) rotate(-6deg);
  text-shadow: 0 0 16px rgba(57, 255, 20, .55);
}

.image-card img {
  transition: transform .65s cubic-bezier(.2, .7, .2, 1), filter .35s ease;
}

.image-card:hover img,
.image-card:focus-within img {
  transform: scale(1.055);
  filter: saturate(1.1) contrast(1.04);
}

.guide-list article {
  transition: background .25s ease, padding-left .25s ease, border-color .25s ease;
}

.guide-list article:hover,
.guide-list article:focus-within {
  padding-left: 10px;
  background: rgba(57, 255, 20, .045);
  border-color: rgba(57, 255, 20, .34);
}

.guide-list article > span,
.timeline time {
  transition: color .25s ease, transform .25s ease;
}

.guide-list article:hover > span,
.guide-list article:focus-within > span,
.timeline li:hover time {
  color: var(--lime);
  transform: translateX(3px);
}

.timeline li {
  transition: transform .25s ease;
}

.timeline li:hover {
  transform: translateX(5px);
}

.timeline li::before {
  transition: transform .25s ease, background .25s ease, box-shadow .25s ease;
}

.timeline li:hover::before {
  background: var(--lime);
  box-shadow: 0 0 0 5px rgba(57, 255, 20, .12), 0 0 15px rgba(57, 255, 20, .5);
  transform: translateX(-50%) scale(1.15);
}

.faq-list details {
  transition: background .25s ease, padding-left .25s ease;
}

.faq-list details:hover,
.faq-list details:focus-within {
  padding-left: 10px;
  background: rgba(57, 255, 20, .035);
}

.faq-list summary {
  transition: color .2s ease;
}

.faq-list summary:hover {
  color: var(--lime-soft);
}

.gallery-main {
  transition: border-color .3s ease, box-shadow .3s ease;
}

.gallery-main:hover {
  border-color: var(--lime);
  box-shadow: 0 20px 48px rgba(0, 0, 0, .3), 0 0 0 3px rgba(57, 255, 20, .07);
}

.gallery-main img {
  transition: transform .55s cubic-bezier(.2, .7, .2, 1), filter .35s ease;
}

.gallery-main:hover img {
  transform: scale(1.018);
  filter: saturate(1.06) contrast(1.03);
}

.gallery-caption strong {
  transition: color .25s ease;
}

.gallery-main:hover .gallery-caption strong {
  color: var(--lime-soft);
}

@keyframes detailCtaGlow {
  0%, 100% { box-shadow: 0 10px 28px rgba(0, 0, 0, .34), 0 7px 21px rgba(57, 255, 20, .16); }
  50% { box-shadow: 0 12px 31px rgba(0, 0, 0, .34), 0 7px 28px rgba(57, 255, 20, .3); }
}

.floating-detail-cta {
  animation: detailCtaGlow 3.2s ease-in-out infinite;
}

.floating-detail-cta:hover,
.floating-detail-cta:focus-visible {
  animation-play-state: paused;
}

/* Close the empty grid gap: mini game and final match share one balanced row. */
.gameplay-grid > .image-card:nth-of-type(4) {
  grid-column: span 1;
  min-height: 282px;
}

.gameplay-grid > .system-card-wide {
  grid-column: span 3;
  min-height: 282px;
  padding-left: clamp(28px, 4vw, 54px);
  padding-right: clamp(28px, 5vw, 72px);
}

.gameplay-grid > .system-card-wide .wide-copy {
  max-width: 610px;
}

/* Page titles now form a clear preface directly above their content. */
.updates-layout,
.faq-layout {
  display: block;
}

.updates-heading,
.faq-heading {
  position: static;
  max-width: 760px;
  margin-bottom: 43px;
}

.updates-heading h2,
.faq-heading h2 {
  margin-bottom: 14px;
}

.timeline,
.faq-list {
  max-width: 900px;
}

.timeline {
  margin-left: auto;
  margin-right: auto;
}

.faq-list {
  margin: 0 auto;
}

/* Interactive game gallery: one large scene beside six selectable thumbnails. */
.game-gallery {
  width: min(calc(100% - 48px), var(--max));
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(260px, .85fr);
  gap: 22px;
  align-items: start;
}

.gallery-main {
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(57, 255, 20, .45);
  background: #0a1b16;
  box-shadow: 0 18px 45px rgba(0, 0, 0, .22);
}

.gallery-main img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: #101d1c;
}

.gallery-caption {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  min-height: 52px;
  padding: 13px 16px 14px;
  color: var(--lime-soft);
  font-size: 12px;
  letter-spacing: .55px;
}

.gallery-caption span {
  flex: 0 0 auto;
  color: var(--lime);
  font: 12px/1 var(--display);
  letter-spacing: 1px;
}

.gallery-caption strong {
  color: var(--ice);
  font-size: 14px;
  text-align: right;
}

.gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  min-width: 0;
}

.gallery-thumb {
  display: block;
  min-width: 0;
  margin: 0;
  padding: 0;
  overflow: hidden;
  border: 1px solid rgba(240, 244, 248, .18);
  border-radius: 7px;
  background: #101d1c;
  cursor: pointer;
  transition: border-color .2s, box-shadow .2s, transform .2s, opacity .2s;
}

.gallery-thumb img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  opacity: .72;
  transition: opacity .2s, transform .35s;
}

.gallery-thumb:hover,
.gallery-thumb:focus-visible {
  border-color: rgba(57, 255, 20, .7);
  box-shadow: 0 0 0 2px rgba(57, 255, 20, .12);
  transform: translateY(-2px);
}

.gallery-thumb:hover img,
.gallery-thumb:focus-visible img,
.gallery-thumb.is-active img {
  opacity: 1;
}

.gallery-thumb:hover img,
.gallery-thumb:focus-visible img {
  transform: scale(1.035);
}

.gallery-thumb.is-active {
  border-color: var(--lime);
  box-shadow: 0 0 0 2px rgba(57, 255, 20, .18), 0 8px 20px rgba(0, 0, 0, .2);
}

@media (max-width: 950px) {
  h1 { font-size: clamp(36px, 6.1vw, 50px); }
  .section-heading h2,
  .guide-sidebar h2,
  .visual-break-copy h2,
  .updates-heading h2,
  .faq-heading h2,
  .gallery-heading h2,
  .closing-cta h2 { font-size: clamp(26px, 4.35vw, 36px); }
  .gameplay-grid > .system-card-wide {
    grid-column: span 1;
    padding: 28px;
  }
  .gameplay-grid > .system-card-wide .pitch-diagram {
    width: 180px;
    flex: 0 0 180px;
  }
  .game-gallery {
    grid-template-columns: minmax(0, 1.45fr) minmax(230px, .9fr);
    gap: 16px;
  }
  .gallery-thumbs { gap: 9px; }
}

@media (max-width: 760px) {
  h1 { font-size: clamp(35px, 9.5vw, 43px); }
  .section-heading h2,
  .guide-sidebar h2,
  .visual-break-copy h2,
  .updates-heading h2,
  .faq-heading h2,
  .gallery-heading h2,
  .closing-cta h2 { font-size: clamp(25px, 7.2vw, 32px); }
  .site-nav > a:not(.nav-cta) {
    gap: 8px;
    width: 100%;
    min-height: 42px;
    margin: 3px 0;
    padding: 8px 14px;
    border-bottom: 1px solid rgba(240, 244, 248, .11);
  }
  .site-nav .nav-cta {
    width: 100%;
    min-height: 42px;
    margin-top: 10px;
    padding: 0 18px;
  }
  .gameplay-grid > .image-card:nth-of-type(4),
  .gameplay-grid > .system-card-wide {
    grid-column: auto;
  }
  .gameplay-grid > .system-card-wide .pitch-diagram {
    width: 100%;
    flex-basis: 126px;
  }
  .updates-heading,
  .faq-heading { margin-bottom: 31px; }
  .game-gallery {
    width: min(calc(100% - 34px), var(--max));
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .gallery-thumbs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 8px;
  }
  .gallery-caption {
    min-height: 48px;
    padding: 11px 13px 12px;
  }
  .gallery-caption strong { font-size: 13px; }
  .floating-detail-cta {
    right: 17px;
    bottom: calc(14px + env(safe-area-inset-bottom));
    min-height: 42px;
    min-width: 132px;
    padding: 0 15px;
    font-size: 14px;
  }
}

/* Keep the character copy first and show the artwork at its full aspect ratio. */
.visual-break-copy {
  order: 1;
}

.portrait-figure {
  order: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: center;
  min-height: 0;
  background: transparent;
}

.portrait-figure img {
  width: 100%;
  height: auto;
  object-fit: contain;
  object-position: center;
}

/* Image feedback without zooming or cropping either source image. */
.guide-sidebar > img {
  border-color: rgba(240, 244, 248, .2);
  box-shadow: 0 10px 24px rgba(0, 0, 0, .18);
  transition: border-color .28s ease, box-shadow .28s ease, filter .28s ease, transform .28s ease;
}

.portrait-figure {
  border: 1px solid transparent;
  transition: border-color .3s ease, box-shadow .3s ease, transform .3s ease, background .3s ease;
}

.portrait-figure img {
  transition: filter .3s ease;
}

@media (hover: hover) and (pointer: fine) {
  .guide-sidebar > img:hover {
    border-color: rgba(57, 255, 20, .7);
    box-shadow: 0 17px 34px rgba(0, 0, 0, .3), 0 0 0 3px rgba(57, 255, 20, .08);
    filter: saturate(1.1) contrast(1.04) brightness(1.04);
    transform: translateY(-4px);
  }

  .portrait-figure:hover {
    border-color: rgba(57, 255, 20, .65);
    background: transparent;
    box-shadow: 0 18px 40px rgba(0, 0, 0, .28), 0 0 0 3px rgba(57, 255, 20, .07);
    transform: translateY(-4px);
  }

  .portrait-figure:hover img {
    filter: saturate(1.08) contrast(1.035) brightness(1.035);
  }
}

/* A compact themed link band keeps partner navigation separate from the site footer. */
.friend-links {
  padding: 42px 0 46px;
  background: #102820;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.friend-links-heading {
  margin-bottom: 20px;
  text-align: center;
}

.friend-links-heading .section-kicker {
  margin-bottom: 7px;
}

.friend-links-heading h2 {
  margin: 0;
  color: var(--ice);
  font: clamp(24px, 3vw, 34px) / 1.1 var(--display);
  letter-spacing: .3px;
}

.friend-links-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.friend-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 8px 19px;
  border: 1px solid rgba(240, 244, 248, .18);
  border-radius: 999px;
  background: rgba(240, 244, 248, .06);
  color: var(--ice);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
  transition: color .2s ease, border-color .2s ease, background .2s ease, transform .2s ease, box-shadow .2s ease;
}

.friend-link::before {
  display: none !important;
  content: none !important;
}

.friend-link:hover,
.friend-link:focus-visible {
  border-color: rgba(57, 255, 20, .62);
  background: rgba(57, 255, 20, .13);
  color: var(--lime);
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(57, 255, 20, .12);
}

@media (max-width: 760px) {
  .friend-links {
    padding: 35px 0 39px;
  }

  .friend-links-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 9px;
  }

  .friend-link {
    width: 100%;
    min-height: 44px;
  }
}
