/* ===== Games page navbar ===== */
.games-nav {
  display: flex;
  gap: 12px;
  align-items: center;
  margin: 16px 0 8px;
  border-bottom: 1px solid #e6e6e6;
  padding-bottom: 8px;
  flex-wrap: wrap;
}
.games-nav .tab-btn {
  background: transparent;
  border: none;
  padding: 8px 12px;
  cursor: pointer;
  font-weight: 500;
}
.games-nav .tab-btn[aria-selected="true"] { border-bottom: 2px solid #6c5ce7; }
.games-nav .nav-spacer { margin-left: auto; }

/* ===== Scope fixes to the /games page only ===== */
#games-tabs { /* just a scope hook */ }

/* Reset the home-page hero layout so games can breathe */
#games-tabs ~ .whatever {} /* no-op, keeps specificity low */

.container {
  /* These override the home page's full-screen hero for the games page as well.
     Because games.css is loaded after style.css, these will win. */
  min-height: 100svh;     /* better than 100vh on mobile browsers */
  height: auto;
  justify-content: flex-start;   /* don't pin content to bottom */
  align-items: center;
  overflow-y: auto;
  padding-top: 16px;      /* less padding than the home hero */
}

/* ===== Responsive iframe wrapper ===== */
.frame-wrap {
  width: 100%;
  max-width: 960px;                     /* << wider on desktop */
  height: clamp(520px, 86svh, 1000px);  /* tall enough but not silly */
  margin: 0 auto;
  border: 1px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.frame-wrap iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* ===== Country game text block shouldn’t overlay iframes ===== */
.game-tab .text-container {
  position: static;
  padding: 0;
  background: transparent;
  color: inherit;
}
.game-tab .text-container h3 { margin: 8px 0 12px; }

/* Make sure any legacy carousel rules don’t shrink this page */
#games-tabs .carousel,
#games-tabs .carousel-item {
  position: static !important;
  height: auto !important;
  width: 100% !important;
  max-width: none !important;
  overflow: visible !important;
  display: block !important;
}

/* Mobile tweaks */
@media (max-width: 600px) {
  .games-nav { gap: 8px; }
  .games-nav .tab-btn { padding: 6px 8px; }
  .frame-wrap { height: clamp(540px, 90svh, 1000px); }
}

/* Let the games page breathe (overrides home hero layout) */
.container {
  min-height: 100svh;   /* better than 100vh on mobile */
  height: auto;
  justify-content: flex-start !important;  /* override home */
  align-items: center !important;
  overflow-y: auto;
  padding-top: 16px;
}

/* Wider, taller iframe wrapper so it doesn’t look mobile on desktop */
.frame-wrap {
  width: 100%;
  max-width: 960px;                     /* was 560px — this was making it narrow */
  height: clamp(520px, 86svh, 1000px);
  margin: 0 auto;
  border: 1px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}
.frame-wrap iframe {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
}

/* Text block shouldn’t overlay iframes */
.game-tab .text-container {
  position: static;
  padding: 0;
  background: transparent;
  color: inherit;
}
.game-tab .text-container h3 { margin: 8px 0 12px; }

/* Make sure any legacy carousel rules don’t shrink this page */
#games-tabs .carousel,
#games-tabs .carousel-item {
  position: static !important;
  height: auto !important;
  width: 100% !important;
  max-width: none !important;
  overflow: visible !important;
  display: block !important;
}

/* Mobile tweaks */
@media (max-width: 600px) {
  .frame-wrap { height: clamp(540px, 90svh, 1000px); }
}
