/* Loaded only on the two explicitly owned CTN Games pages. */
body.ctn-yootheme.ctn-games-catalogue .ctn-games-catalogue { margin-top: 28px; }
body.ctn-yootheme .ctn-game-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  overflow: hidden;
  border: 1px solid var(--ctn-line);
  border-radius: var(--ctn-radius);
  background: var(--ctn-paper);
  color: #252521;
}
body.ctn-yootheme .ctn-game-card-art { padding: clamp(20px, 4vw, 44px); background: #ded8cd; }
body.ctn-yootheme .ctn-game-preview { width: 100%; max-width: 480px; margin: 0 auto; }
body.ctn-yootheme .ctn-game-preview img { width: 100%; height: auto; }
body.ctn-yootheme .ctn-game-preview figcaption {
  margin-top: 12px;
  color: #59574f;
  font-size: 13px;
  line-height: 1.5;
  text-align: center;
}
body.ctn-yootheme .ctn-game-card-copy {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  flex-direction: column;
  padding: clamp(24px, 5vw, 56px);
}
body.ctn-yootheme .ctn-game-status {
  margin: 0 0 14px;
  color: #a63c0b;
  font-size: 13px;
  font-weight: 750;
}
body.ctn-yootheme .ctn-game-card h2 {
  margin: 0;
  color: #252521;
  font-size: clamp(34px, 5vw, 56px);
  font-weight: 650;
  letter-spacing: -.045em;
  line-height: 1.1;
}
body.ctn-yootheme .ctn-game-card-copy > p:not(.ctn-game-status) { margin: 20px 0 26px; }
body.ctn-yootheme a.ctn-game-button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 22px;
  border: 1px solid #252521;
  border-radius: 8px;
  background: #252521;
  color: #f3efe7;
  font-size: 15px;
  font-weight: 750;
  text-decoration: none;
}
body.ctn-yootheme a.ctn-game-button:hover { background: #3b3b35; color: #fff; }
body.ctn-yootheme .ctn-game-card :focus-visible { outline-color: #a63c0b; }
body.ctn-yootheme.ctn-games-game { min-width: 0; }
body.ctn-yootheme.ctn-games-game .ctn-game-shell {
  width: calc(100% - 48px);
  max-width: 1180px;
  margin-inline: auto;
}
body.ctn-yootheme.ctn-games-game .ctn-game-header { border-bottom: 1px solid var(--ctn-line); }
body.ctn-yootheme.ctn-games-game .ctn-game-header nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 76px;
}
body.ctn-yootheme .ctn-game-brand { display: inline-flex; align-items: center; min-height: 44px; min-width: 44px; color: var(--ctn-text); font-size: 21px; font-weight: 800; letter-spacing: .18em; text-decoration: none; }
body.ctn-yootheme .ctn-game-back { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; color: var(--ctn-text-soft); font-size: 15px; text-decoration: none; }
body.ctn-yootheme .ctn-game-main { padding-block: clamp(24px, 4vw, 48px); }
body.ctn-yootheme .ctn-game-content > p:empty { display: none; }
body.ctn-yootheme .ctn-game-title { margin: 0 0 26px; font-size: clamp(30px, 4vw, 46px); font-weight: 650; letter-spacing: -.04em; line-height: 1.15; }
body.ctn-yootheme .ctn-game-unavailable {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: center;
  gap: clamp(24px, 5vw, 64px);
  padding: clamp(24px, 5vw, 56px);
  border: 1px solid var(--ctn-line);
  border-radius: var(--ctn-radius);
  background: var(--ctn-paper);
  color: #252521;
}
body.ctn-yootheme .ctn-game-unavailable h2 { margin: 0 0 18px; color: #252521; font-size: clamp(24px, 3vw, 34px); line-height: 1.2; letter-spacing: -.025em; }
body.ctn-yootheme .ctn-game-unavailable-copy p { margin: 0; }
body.ctn-yootheme .ctn-game-frame { display: block; width: 100%; height: min(850px, 80dvh); min-height: 480px; border: 1px solid var(--ctn-line); border-radius: 10px; background: var(--ctn-surface); }
body.ctn-yootheme .ctn-game-direct { margin: 16px 0 0; font-size: 15px; }
body.ctn-yootheme .ctn-game-direct a { display: inline-block; padding-block: 8px; color: var(--ctn-text-soft); }
body.ctn-yootheme .ctn-game-skip { position: fixed; z-index: 10000; top: 12px; left: 12px; padding: 10px 16px; transform: translateY(-200%); border-radius: 6px; background: var(--ctn-paper); color: #252521; }
body.ctn-yootheme .ctn-game-skip:focus { transform: none; }
body.ctn-yootheme .ctn-game-sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
/* A live iframe fills the space left by real navigation, title and fallback. */
body.ctn-yootheme.ctn-game-live { display: flex; flex-direction: column; height: 100dvh; min-height: 0; overflow: hidden; }
body.ctn-yootheme.ctn-game-live.admin-bar { height: calc(100dvh - var(--wp-admin--admin-bar--height, 32px)); }
body.ctn-yootheme.ctn-game-live .ctn-game-header { flex: 0 0 auto; }
body.ctn-yootheme.ctn-game-live .ctn-game-header nav { min-height: 64px; }
body.ctn-yootheme.ctn-game-live .ctn-game-main { display: flex; flex: 1 1 0; flex-direction: column; min-height: 0; padding-block: 18px 8px; }
body.ctn-yootheme.ctn-game-live .ctn-game-title { flex: 0 0 auto; margin-bottom: 16px; font-size: 28px; }
body.ctn-yootheme.ctn-game-live .ctn-game-content,
body.ctn-yootheme.ctn-game-live .ctn-game-workspace { display: flex; flex: 1 1 0; flex-direction: column; min-height: 0; }
body.ctn-yootheme.ctn-game-live .ctn-game-frame { flex: 1 1 0; height: 0; min-height: 0; }
body.ctn-yootheme.ctn-game-live .ctn-game-direct { flex: 0 0 auto; margin-top: 6px; }
@media (max-width: 782px) {
  body.ctn-yootheme.ctn-game-live.admin-bar { height: calc(100dvh - var(--wp-admin--admin-bar--height, 46px)); }
}
@media (max-width: 700px) {
  body.ctn-yootheme .ctn-game-card,
  body.ctn-yootheme .ctn-game-unavailable { grid-template-columns: minmax(0, 1fr); }
  body.ctn-yootheme .ctn-game-card-art { padding: 22px; }
  body.ctn-yootheme .ctn-game-preview { max-width: 340px; }
  body.ctn-yootheme .ctn-game-card-copy { padding: 28px 24px 32px; }
  body.ctn-yootheme.ctn-games-game .ctn-game-shell { width: calc(100% - 32px); }
  body.ctn-yootheme .ctn-game-header nav { min-height: 64px; }
  body.ctn-yootheme .ctn-game-frame { height: 80dvh; min-height: 440px; }
}
