.game-page {
  width: min(1050px, calc(100% - 48px));
  margin: 0 auto;
  padding-bottom: 32px;
}
.game-intro {
  display: grid;
  grid-template: "title action" auto "description action" auto / minmax(0, 1fr) auto;
  align-items: center;
  gap: 4px 16px;
  padding: 20px 0 22px;
}
.game-intro > h1 {
  grid-area: title;
  margin: 0;
  color: #253e33;
  font: 500 clamp(2.5rem, 5.2vw, 4rem)/1.08 Georgia, "Times New Roman", serif;
  letter-spacing: -.035em;
}
.game-intro > p {
  grid-area: description;
  margin: 0;
  color: #526456;
  font: 400 clamp(1rem, 1.8vw, 1.125rem)/1.4 "Segoe UI", Arial, sans-serif;
}
.game-intro > .game-intro-action,
.game-dialog .primary,
.game-dialog .secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 45px;
  margin: 0;
  padding: 8px 16px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: var(--game-action-bg, #2f5842);
  color: #fff;
  font: 650 1rem/1.35 "Segoe UI", Arial, sans-serif;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}
.game-intro > .game-intro-action { grid-area: action; justify-self: end; }
.game-intro-action > [aria-hidden="true"] { font-size: 1.18em; line-height: 1; }
.game-intro > .game-intro-action:hover, .game-dialog .primary:hover { background: var(--game-action-hover-bg, #214830); }
.game-intro > .game-intro-action:focus-visible, .game-dialog :focus-visible { outline: 3px solid #377ba2; outline-offset: 3px; }
.game-dialog {
  box-sizing: border-box;
  width: min(450px, calc(100% - 32px));
  max-height: calc(100% - 32px);
  padding: clamp(18px, 4vw, 24px);
  color: #253e33;
  border: 1px solid #d6d8c9;
  border-radius: 17px;
  background: #fffdf6;
  box-shadow: 0 14px 60px #22382838;
}
.game-dialog::backdrop { background: #203227af; }
.game-dialog .dialog-head, .game-dialog .dialog-actions { display: flex; align-items: center; gap: 12px; }
.game-dialog .dialog-head { justify-content: space-between; margin-bottom: 10px; }
.game-dialog .dialog-actions { flex-wrap: wrap; justify-content: flex-end; margin-top: 20px; }
.game-dialog .dialog-head h2 {
  margin: 0;
  font: 500 clamp(1.5rem, 2.5vw, 2rem)/1.1 Georgia, "Times New Roman", serif;
  letter-spacing: -.035em;
}
.game-dialog .cross {
  flex: none;
  display: grid;
  place-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  color: #253e33;
  border: 0;
  border-radius: 50%;
  background: #ecf0e4;
  font: 400 1.625rem/1 "Segoe UI", Arial, sans-serif;
  cursor: pointer;
}
.game-dialog .secondary { color: #253e33; border-color: #bbc5b4; background: #fffdf6; }
.game-dialog .secondary:hover, .game-dialog .cross:hover { background: #e7ecdf; }
.game-dialog label { display: block; margin: 14px 0 5px; font-weight: 650; }
.game-dialog select { width: 100%; min-height: 46px; padding: 8px; border: 1px solid #aebca5; border-radius: 7px; background: #fff; color: #253e33; }
.game-dialog p { margin: 13px 0 0; }
.game-dialog a { color: #2f5842; }
.game-dialog .credits { font-size: .875rem; }
.game-dialog .credits a { display: inline-flex; align-items: center; min-height: 44px; }
@media (min-width: 721px) and (max-height: 830px) {
  .game-intro { padding: 10px 0 14px; }
  .game-intro > h1 { font-size: clamp(2.625rem, 4.4vw, 3.25rem); }
}
@media (max-width: 720px) {
  .game-page { width: min(540px, calc(100% - 24px)); }
  .game-intro {
    grid-template-areas: "title action" "description description";
    gap: 5px 8px;
    padding: 13px 0 14px;
  }
  .game-intro > h1 { font-size: clamp(1.6rem, 8.8vw, 2.8rem); }
  .game-intro > .game-intro-action { min-height: 44px; padding: 7px 11px; gap: 5px; }
}
@media (max-width: 360px) {
  .game-intro > h1 { font-size: clamp(1.5rem, 8vw, 1.8rem); }
}

/* Verzia 2.3 – tablet: nižšia hlavička, aby zostalo viac miesta pre hraciu plochu. */
@media (min-width: 721px) and (max-height: 1000px), (min-width: 721px) and (orientation: portrait) {
  .game-intro {
    grid-template: "title description action" auto / auto minmax(0, 1fr) auto;
    gap: 4px 18px;
    padding: 8px 0 10px;
  }
  .game-intro > h1 { font-size: clamp(1.75rem, 3.4vw, 2.25rem); }
  .game-intro > p { font-size: 1rem; line-height: 1.3; }
}

/* Verzia 2.5 – nízke okno na šírku (tablet v prehliadači s lištou, monitor so zväčšením stránky). */
@media (min-width: 721px) and (max-height: 700px) {
  .game-intro { padding: 2px 0 6px; }
  .game-intro > h1 { font-size: 1.6rem; }
}
