/* ==========================================================================
   IC7 — game-details.css
   Page-specific layout for game-details.html: the split hero with glowing
   square art, badge row, 5-up steps, facts footnote, not-found state.
   Depends on: tokens.css, main.css. Tokens only — no hard-coded colours.
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. Hero
   -------------------------------------------------------------------------- */
.gd-hero {
  padding-bottom: var(--space-9);
}

.gd-hero__orb {
  top: -35%;
  left: -12%;
}

.gd-hero__grid {
  position: relative;
  z-index: var(--z-content);
  display: grid;
  gap: var(--space-7);
  align-items: center;
}

@media (min-width: 900px) {
  .gd-hero__grid {
    grid-template-columns: minmax(240px, 360px) 1fr;
    gap: var(--space-8);
  }
}

/* Square art with a glowing frame */
.gd-hero__art {
  position: relative;
  width: 100%;
  max-width: 360px;
  aspect-ratio: 1 / 1;
  margin-inline: auto;
  padding: 6px;
  background: var(--gradient-primary);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-red-glow-strong), var(--shadow-card);
}

.gd-hero__art::after {
  content: '';
  position: absolute;
  inset: -18%;
  z-index: var(--z-bg);
  background: var(--gradient-glow);
  border-radius: 50%;
  pointer-events: none;
}

.gd-hero__img {
  position: relative;
  z-index: var(--z-content);
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: calc(var(--radius-xl) - 6px);
  background: var(--color-surface-2);
}

/* Graceful degradation if the artwork 404s (main.js adds .is-img-missing) */
.gd-hero__art.is-img-missing {
  display: grid;
  place-items: center;
}

.gd-hero__art.is-img-missing::before {
  content: '7';
  font-family: var(--font-display);
  font-size: clamp(4rem, 12vw, 7rem);
  font-weight: 700;
  color: var(--color-white);
  opacity: 0.35;
}

.gd-hero__info {
  position: relative;
  z-index: var(--z-content);
  max-width: 60ch;
}

.gd-tagline {
  max-width: 52ch;
}

.gd-badges {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-5);
}

.gd-hero__actions {
  margin-top: var(--space-6);
}

/* --------------------------------------------------------------------------
   2. Steps — five across on wide screens (the global default is four)
   -------------------------------------------------------------------------- */
@media (min-width: 1200px) {
  .gd-steps { grid-template-columns: repeat(5, 1fr); }
}

/* --------------------------------------------------------------------------
   3. Facts table
   -------------------------------------------------------------------------- */
.table th[scope='row'] {
  width: 40%;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--color-text-primary);
  white-space: nowrap;
}

.gd-facts__link {
  color: var(--color-red-bright);
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color var(--dur-fast) var(--ease-out);
}
.gd-facts__link:hover { color: var(--color-white); }

.gd-footnote {
  margin-top: var(--space-4);
  font-size: var(--fs-xs);
  line-height: var(--lh-body);
  color: var(--color-text-muted);
}

/* --------------------------------------------------------------------------
   4. Not-found state
   -------------------------------------------------------------------------- */
.gd-notfound {
  padding-top: calc(var(--header-h) + var(--space-9));
}

.gd-notfound__inner {
  display: grid;
  justify-items: center;
  gap: var(--space-4);
  text-align: center;
}

.gd-notfound__mark {
  display: grid;
  place-items: center;
  width: 92px;
  height: 92px;
  margin-bottom: var(--space-3);
  font-family: var(--font-display);
  font-size: 2.6rem;
  font-weight: 700;
  color: var(--color-red-bright);
  border: 2px solid var(--color-red);
  border-radius: 50%;
  box-shadow: var(--shadow-red-glow);
}

.gd-notfound .btn-row {
  justify-content: center;
  margin-top: var(--space-4);
}

