/* ══════════════════════════════════════════════════════════════
   «ВЫБОР ЗА ТОБОЙ»
   Прокуратура города Темиртау
   Таблица стилей · адаптив: телефон / планшет / компьютер
══════════════════════════════════════════════════════════════ */

:root {
  --bg: #F0F6FF;
  --surface: #FFFFFF;
  --surface2: #E8F0FB;
  --surface3: #D6E4F7;
  --accent: #00AEEF;
  --accent2: #0088CC;
  --gold: #FFD700;
  --gold2: #E6B800;
  --good: #10B981;
  --bad: #EF4444;
  --neutral: #6366F1;
  --warn: #F59E0B;
  --text: #1A2340;
  --text-dim: #5A6A8A;
  --border: rgba(0,174,239,0.15);
  --border2: rgba(0,174,239,0.3);
  --shadow: 0 4px 24px rgba(0,100,180,0.10);
  --shadow-lg: 0 8px 40px rgba(0,100,180,0.16);
  --radius: 18px;
  --radius-sm: 12px;
}
* { margin: 0; padding: 0; box-sizing: border-box; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: 'Nunito', sans-serif;
  min-height: 100vh;
  overflow-x: hidden;
}
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 50% at 0% 0%, rgba(0,174,239,0.08) 0%, transparent 60%),
    radial-gradient(ellipse 50% 60% at 100% 100%, rgba(255,215,0,0.07) 0%, transparent 60%);
  pointer-events: none;
  z-index: 0;
}
#app {
  position: relative;
  z-index: 1;
  min-height: 100vh;
}
/* ══════════════════════════════════════
   SCREENS
══════════════════════════════════════ */
.screen { display: none; }
.screen.active { display: flex; flex-direction: column; }
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
.screen.active { animation: fadeIn 0.35s ease; }
/* ══════════════════════════════════════
   INTRO SCREEN
══════════════════════════════════════ */
#screen-intro {
  min-height: 100vh;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
}
.intro-wrap {
  width: 100%;
  max-width: 760px;
  background: var(--surface);
  border: 2px solid var(--border2);
  border-radius: var(--radius);
  padding: 36px 40px;
  box-shadow: var(--shadow-lg);
}
.intro-header {
  text-align: center;
  margin-bottom: 28px;
  padding-bottom: 24px;
  border-bottom: 2px solid var(--border);
}
.intro-logos {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 22px;
  margin-bottom: 18px;
}
.intro-logo {
  height: 60px;
  width: auto;
  object-fit: contain;
}
.intro-title {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(32px, 5vw, 44px);
  font-weight: 800;
  line-height: 1.1;
  color: var(--text);
  margin-bottom: 8px;
}
.intro-title .accent { color: var(--accent); }
.intro-title .gold { color: var(--gold2); }
.intro-sub {
  font-size: 15px;
  color: var(--text-dim);
  font-weight: 600;
}
.intro-section {
  margin-bottom: 24px;
}
.intro-section-title {
  font-family: 'Unbounded', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}
.intro-text {
  font-size: 15px;
  line-height: 1.65;
  color: var(--text);
  font-weight: 500;
}
.intro-stats {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.intro-stat {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  background: var(--surface2);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
}
.intro-stat-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}
.intro-stat-name {
  font-family: 'Unbounded', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 4px;
}
.intro-stat-desc {
  font-size: 13px;
  line-height: 1.5;
  color: var(--text-dim);
  font-weight: 500;
}
.intro-rules {
  background: var(--surface2);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.intro-rule {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
  font-weight: 600;
}
.intro-rule-icon {
  font-size: 18px;
  flex-shrink: 0;
  margin-top: 1px;
}
.intro-btn {
  width: 100%;
  background: linear-gradient(135deg, var(--accent), #0088CC);
  color: #fff;
  border: none;
  border-radius: var(--radius-sm);
  padding: 18px;
  font-family: 'Nunito', sans-serif;
  font-size: 17px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-top: 8px;
  box-shadow: 0 6px 20px rgba(0,174,239,0.35);
}
.menu-help-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--surface2);
  border: 1.5px solid var(--border2);
  color: var(--accent2);
  font-family: 'Nunito', sans-serif;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s;
  margin-right: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}
/* ══════════════════════════════════════
   MENU SCREEN
══════════════════════════════════════ */
#screen-menu {
  min-height: 100vh;
  flex-direction: column;
}
.menu-header {
  background: var(--surface);
  border-bottom: 2px solid var(--border2);
  padding: 14px 32px;
  display: flex;
  align-items: center;
  gap: 12px;
  box-shadow: var(--shadow);
}
.menu-header-icon { font-size: 26px; }
.menu-header-logos {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 18px;
}
.menu-header-logo {
  height: 50px;
  width: auto;
  object-fit: contain;
  display: block;
}
.menu-header { position: relative; }
.menu-kz-badge {
  margin-left: auto;
  background: var(--surface2);
  border: 1.5px solid var(--border2);
  border-radius: 20px;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-dim);
}
.menu-body {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  max-height: calc(100vh - 73px);
}
.menu-cover-side {
  position: relative;
  overflow: hidden;
}
.menu-cover-side img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}
.menu-cover-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to right, transparent 60%, var(--bg) 100%);
}
.menu-content-side {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 40px 52px;
  gap: 28px;
}
.menu-title {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(30px, 3.8vw, 50px);
  font-weight: 800;
  line-height: 1.1;
  color: var(--text);
  margin-bottom: 0;
}
.menu-title .accent { color: var(--accent); }
.menu-title .gold { color: var(--gold2); }
.menu-facts {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.menu-fact-pill {
  display: flex;
  align-items: center;
  gap: 7px;
  background: var(--surface2);
  border: 1.5px solid var(--border2);
  border-radius: 30px;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-dim);
  white-space: nowrap;
}
.menu-fact-pill .pill-icon { font-size: 16px; }
.menu-fact-pill.highlight {
  background: linear-gradient(135deg, #E8F7FF, #F0F6FF);
  border-color: var(--accent);
  color: var(--accent2);
}
.scenario-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.scenario-card {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  cursor: pointer;
  transition: all 0.22s ease;
  display: flex;
  align-items: center;
  gap: 18px;
  box-shadow: var(--shadow);
}
.scenario-card.disabled {
  opacity: 0.45;
  cursor: not-allowed;
}
.sc-icon {
  width: 56px; height: 56px;
  background: var(--surface2);
  border: 2px solid var(--border2);
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  font-size: 28px;
  flex-shrink: 0;
}
.sc-info h3 {
  font-family: 'Unbounded', sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
}
.sc-info p {
  font-size: 13px;
  color: var(--text-dim);
  margin-top: 4px;
}
.sc-badge {
  margin-left: auto;
  background: var(--surface2);
  border: 1.5px solid var(--border2);
  border-radius: 20px;
  padding: 5px 12px;
  font-size: 12px;
  font-weight: 700;
  color: var(--text-dim);
  white-space: nowrap;
  flex-shrink: 0;
}
.sc-badge.active-badge {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
/* ══════════════════════════════════════
   GAME SCREEN – HORIZONTAL LAYOUT
══════════════════════════════════════ */
#screen-game {
  min-height: 100vh;
  flex-direction: column;
}
.game-topbar {
  background: var(--surface);
  border-bottom: 2px solid var(--border2);
  padding: 12px 32px;
  display: flex;
  align-items: center;
  gap: 20px;
  box-shadow: var(--shadow);
  flex-shrink: 0;
}
.game-back-btn {
  background: var(--surface2);
  border: 1.5px solid var(--border2);
  border-radius: 10px;
  padding: 8px 16px;
  font-family: 'Nunito', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-dim);
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}
.game-back-scene-btn {
  background: var(--surface2);
  border: 1.5px solid var(--border2);
  border-radius: 10px;
  padding: 8px 14px;
  font-family: 'Nunito', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-dim);
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
}
.game-title-block { flex: 1; }
.game-scenario-label {
  font-size: 11px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-weight: 700;
}
.game-scenario-title {
  font-family: 'Unbounded', sans-serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  margin-top: 2px;
}
.game-progress-wrap {
  display: flex;
  gap: 5px;
  align-items: center;
}
.progress-dot {
  width: 32px; height: 5px;
  border-radius: 3px;
  background: var(--surface3);
  transition: background 0.3s;
}
.progress-dot.done { background: var(--good); }
.progress-dot.current { background: var(--accent); }
/* Stats in topbar */
.game-stats {
  display: none; /* moved to subbar */
}
.game-statsbar {
  background: var(--surface);
  border-bottom: 2px solid var(--border);
  padding: 8px 32px;
  display: flex;
  align-items: center;
  gap: 0;
  flex-shrink: 0;
}
.stat-pill {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 20px 6px 12px;
  border-right: 1.5px solid var(--border);
}
.stat-pill:last-child { border-right: none; }
.stat-pill { position: relative; cursor: help; }
.stat-pill-icon { font-size: 18px; flex-shrink: 0; }
.stat-pill-info { display: flex; flex-direction: column; flex: 1; min-width: 0; }
.stat-pill-label { font-size: 10px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.5px; line-height: 1; white-space: nowrap; }
.stat-pill-bar-wrap { width: 100%; height: 5px; background: var(--surface3); border-radius: 3px; overflow: hidden; margin-top: 4px; }
.stat-pill-bar { height: 100%; border-radius: 3px; transition: width 0.5s ease; }
.stat-pill-val { font-size: 13px; font-weight: 800; flex-shrink: 0; width: 28px; text-align: right; }
/* Анимация изменения стата */
.stat-delta {
  position: absolute;
  top: -4px;
  right: 8px;
  font-size: 13px;
  font-weight: 800;
  font-family: 'Nunito', sans-serif;
  pointer-events: none;
  opacity: 0;
  z-index: 10;
  text-shadow: 0 1px 3px rgba(0,0,0,0.15);
  white-space: nowrap;
}
.stat-delta.show {
  animation: deltaFloat 1.6s ease-out forwards;
}
@keyframes deltaFloat {
  0%   { opacity: 0; transform: translateY(8px) scale(0.85); }
  15%  { opacity: 1; transform: translateY(0) scale(1.15); }
  30%  { transform: translateY(-2px) scale(1); }
  85%  { opacity: 1; transform: translateY(-22px); }
  100% { opacity: 0; transform: translateY(-30px); }
}
.stat-pill-val.bump {
  animation: valBump 0.4s ease-out;
}
@keyframes valBump {
  0%   { transform: scale(1); }
  40%  { transform: scale(1.35); }
  100% { transform: scale(1); }
}
/* Tooltip system for stats */
.stat-tooltip {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translateX(-50%) translateY(-6px);
  background: var(--surface);
  border: 1.5px solid var(--border2);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  width: 280px;
  box-shadow: var(--shadow-lg);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease, transform 0.18s ease;
  z-index: 100;
}
.stat-tooltip::before {
  content: '';
  position: absolute;
  top: -7px;
  left: 50%;
  transform: translateX(-50%) rotate(45deg);
  width: 12px;
  height: 12px;
  background: var(--surface);
  border-top: 1.5px solid var(--border2);
  border-left: 1.5px solid var(--border2);
}
.tip-title {
  font-family: 'Unbounded', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 8px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border);
}
.tip-text {
  font-size: 12px;
  line-height: 1.45;
  color: var(--text-dim);
  margin-bottom: 4px;
}
.tip-text:last-child { margin-bottom: 0; }
.tip-text b { color: var(--text); font-weight: 700; }
.tip-q {
  display: inline-block;
  width: 14px; height: 14px;
  background: var(--surface3);
  color: var(--text-dim);
  border-radius: 50%;
  font-size: 10px;
  font-weight: 700;
  text-align: center;
  line-height: 14px;
  margin-left: 4px;
  cursor: help;
}
/* MAIN GAME AREA */
.game-main {
  flex: 1;
  display: grid;
  grid-template-columns: 44% 56%;
  overflow: hidden;
  min-height: 0;
}
.game-image-panel {
  position: relative;
  overflow: hidden;
  background: var(--surface2);
}
.game-image-panel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
}
.game-image-overlay {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 120px;
  background: linear-gradient(to top, rgba(240,246,255,0.95) 0%, transparent 100%);
}
.game-location-tag {
  position: absolute;
  bottom: 16px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 6px 16px;
  border-radius: 20px;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(0,174,239,0.4);
}
.game-content-panel {
  overflow-y: auto;
  padding: 28px 36px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  background: var(--bg);
}
/* Scene description */
.scene-desc-block {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 26px;
  box-shadow: var(--shadow);
}
.scene-chapter-label {
  font-size: 11px;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-weight: 800;
  margin-bottom: 8px;
}
.scene-desc-text {
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  font-weight: 600;
}
/* Dialogue */
.dialogue-block { display: flex; flex-direction: column; gap: 12px; }
.dialogue-msg { display: flex; gap: 12px; }
.dialogue-msg.player { flex-direction: row-reverse; }
.msg-avatar {
  width: 42px; height: 42px;
  border-radius: 50%;
  background: var(--surface2);
  border: 2px solid var(--border2);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}
.msg-bubble {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: 14px;
  padding: 12px 16px;
  max-width: 78%;
  box-shadow: var(--shadow);
}
.dialogue-msg.player .msg-bubble {
  background: var(--accent);
  border-color: var(--accent);
}
.msg-name {
  font-size: 12px;
  font-weight: 800;
  color: var(--accent);
  margin-bottom: 5px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.dialogue-msg.player .msg-name { color: rgba(255,255,255,0.8); }
.msg-text { font-size: 15px; line-height: 1.6; color: var(--text); font-weight: 600; }
.dialogue-msg.player .msg-text { color: #fff; }
/* Consequence */
.consequence-card {
  border-radius: var(--radius);
  padding: 20px 24px;
  border: 2px solid;
  box-shadow: var(--shadow);
}
.consequence-card.good { background: #F0FDF4; border-color: #6EE7B7; }
.consequence-card.bad  { background: #FFF1F2; border-color: #FCA5A5; }
.consequence-card.neutral { background: #F0F0FF; border-color: #A5B4FC; }
.consequence-header { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.consequence-icon { font-size: 28px; }
.consequence-title { font-family: 'Unbounded', sans-serif; font-size: 14px; font-weight: 700; }
.consequence-card.good .consequence-title { color: #059669; }
.consequence-card.bad  .consequence-title { color: #DC2626; }
.consequence-card.neutral .consequence-title { color: #4F46E5; }
.consequence-text { font-size: 15px; line-height: 1.7; color: var(--text); font-weight: 600; }
/* Legal tip */
.legal-tip {
  background: #FFFBEB;
  border: 2px solid #FCD34D;
  border-radius: var(--radius);
  padding: 18px 22px;
}
.legal-tip-header {
  display: flex; align-items: center; gap: 8px;
  font-family: 'Unbounded', sans-serif;
  font-size: 12px; font-weight: 700;
  color: #B45309;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
}
.legal-tip-text { font-size: 14px; line-height: 1.7; color: #78350F; font-weight: 500; }
.legal-tip-text b { font-weight: 800; color: #5A2B06; }
.legal-tip-text i { font-style: italic; font-weight: 400; color: #8B5A2B; display: block; margin-top: 8px; padding-top: 8px; border-top: 1px solid rgba(120, 53, 15, 0.15); font-size: 13px; }
/* Choices */
.choices-section { display: flex; flex-direction: column; gap: 12px; }
.choices-label {
  font-family: 'Unbounded', sans-serif;
  font-size: 13px;
  font-weight: 700;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
}
.choices-list { display: flex; flex-direction: column; gap: 10px; }
.choice-btn {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--text);
  font-family: 'Nunito', sans-serif;
  font-size: 15px;
  line-height: 1.5;
  font-weight: 700;
  box-shadow: var(--shadow);
}
.choice-num {
  width: 32px; height: 32px;
  border-radius: 10px;
  background: var(--surface2);
  border: 2px solid var(--border2);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 800;
  color: var(--accent);
  flex-shrink: 0;
}
.choice-type { margin-left: auto; font-size: 20px; flex-shrink: 0; }
/* ══════════════════════════════════════
   FINAL SCREEN
══════════════════════════════════════ */
#screen-final {
  min-height: 100vh;
  align-items: center;
  justify-content: center;
  padding: 40px;
}
.final-wrap {
  width: 100%;
  max-width: 900px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.final-hero {
  background: var(--surface);
  border: 2px solid var(--border2);
  border-radius: var(--radius);
  padding: 36px 40px;
  display: flex;
  align-items: center;
  gap: 28px;
  box-shadow: var(--shadow-lg);
}
.final-icon-big { font-size: 80px; flex-shrink: 0; }
.final-hero-text {}
.final-result-title {
  font-family: 'Unbounded', sans-serif;
  font-size: 28px;
  font-weight: 800;
  color: var(--text);
  margin-bottom: 10px;
}
.final-result-sub { font-size: 16px; color: var(--text-dim); line-height: 1.7; font-weight: 600; }
.final-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.final-stats, .decisions-review {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 28px;
  box-shadow: var(--shadow);
}
.final-stats h3, .decisions-review h3 {
  font-family: 'Unbounded', sans-serif;
  font-size: 13px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 20px;
}
.final-stat-row {
  display: flex; align-items: center; gap: 12px; margin-bottom: 16px;
  position: relative; cursor: help;
}
.final-stat-row .stat-tooltip { top: calc(100% + 6px); left: 0; transform: translateX(0) translateY(-6px); }
.final-stat-row .stat-tooltip::before { left: 60px; }
.final-stat-row:last-child { margin-bottom: 0; }
.final-stat-label { font-size: 14px; color: var(--text-dim); width: 120px; flex-shrink: 0; font-weight: 700; }
.final-stat-bar-wrap { flex: 1; height: 10px; background: var(--surface2); border-radius: 5px; overflow: hidden; }
.final-stat-bar-fill { height: 100%; border-radius: 5px; transition: width 1s ease; }
.final-stat-num { font-size: 14px; font-weight: 800; width: 36px; text-align: right; flex-shrink: 0; }
.decision-item {
  display: flex; align-items: flex-start; gap: 10px;
  margin-bottom: 14px; font-size: 14px; line-height: 1.5; font-weight: 600;
}
.decision-item:last-child { margin-bottom: 0; }
.decision-dot { font-size: 18px; flex-shrink: 0; margin-top: 1px; }
.decision-scene-label { font-size: 11px; color: var(--text-dim); font-weight: 700; text-transform: uppercase; letter-spacing: 0.5px; display: block; margin-bottom: 2px; }
.final-buttons {
  display: flex;
  gap: 14px;
}
.btn {
  border: none;
  border-radius: var(--radius-sm);
  padding: 16px 28px;
  font-family: 'Nunito', sans-serif;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.btn-primary {
  background: linear-gradient(135deg, var(--accent), #0088CC);
  color: #fff;
  flex: 1;
  box-shadow: 0 6px 20px rgba(0,174,239,0.35);
}
.btn-secondary {
  background: var(--surface);
  border: 2px solid var(--border2);
  color: var(--text-dim);
  flex: 1;
}
/* Кнопка "Поделиться" */
.btn-share {
  background: var(--surface);
  border: 2px solid #FCD34D;
  color: #B45309;
  flex: 1;
}
/* Счётчик открытых концовок */
.endings-tracker-wrap {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 20px 24px;
  box-shadow: var(--shadow);
}
.endings-count {
  font-family: 'Unbounded', sans-serif;
  font-size: 13px;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
}
.endings-count b { color: var(--accent); font-weight: 800; }
.endings-dots {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
}
.ending-dot {
  flex: 1;
  height: 50px;
  border-radius: var(--radius-sm);
  background: var(--surface2);
  border: 2px dashed var(--border2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 800;
  color: var(--text-dim);
  transition: all 0.3s ease;
}
.ending-dot.opened {
  background: linear-gradient(135deg, #E8F7FF, #F0F6FF);
  border: 2px solid var(--accent);
  color: var(--accent2);
  box-shadow: 0 4px 12px rgba(0,174,239,0.15);
}
.endings-hint {
  font-size: 13px;
  color: var(--text-dim);
  font-style: italic;
}
/* Бейдж прогресса в меню */
.sc-progress-badge {
  background: var(--accent);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 12px;
  margin-left: auto;
  margin-right: 8px;
  white-space: nowrap;
  flex-shrink: 0;
  font-family: 'Unbounded', sans-serif;
}
.sc-progress-badge.complete {
  background: linear-gradient(135deg, var(--gold), var(--gold2));
  color: var(--text);
}

/* ══════════════════════════════════════════════════════════════
   ЭФФЕКТЫ НАВЕДЕНИЯ
   Только для мыши. На тач-экранах :hover «залипает» после тапа,
   поэтому вся эта секция для телефонов и планшетов отключена.
══════════════════════════════════════════════════════════════ */
@media (hover: hover) and (pointer: fine) {
  .intro-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(0,174,239,0.45);
  }
  .menu-help-btn:hover {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
    transform: scale(1.05);
  }
  .scenario-card:hover {
    border-color: var(--accent);
    transform: translateX(6px);
    box-shadow: var(--shadow-lg);
  }
  .scenario-card.disabled:hover { transform: none; box-shadow: var(--shadow); border-color: var(--border); }
  .game-back-btn:hover { border-color: var(--accent); color: var(--accent); background: var(--bg); }
  .game-back-scene-btn:hover {
    border-color: var(--accent);
    color: var(--accent);
    background: var(--bg);
  }
  .stat-pill:hover .stat-tooltip,
  .final-stat-row:hover .stat-tooltip {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
  .choice-btn:hover {
    border-color: var(--accent);
    background: #E8F7FF;
    transform: translateX(5px);
    box-shadow: var(--shadow-lg);
  }
  .choice-btn:hover .choice-num { background: var(--accent); color: #fff; border-color: var(--accent); }
  .final-stat-row:hover .stat-tooltip { transform: translateX(0) translateY(0); }
  .btn-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(0,174,239,0.45); }
  .btn-secondary:hover { border-color: var(--accent); color: var(--accent); background: var(--bg); }
  .btn-share:hover {
    background: #FFFBEB;
    border-color: #F59E0B;
    color: #92400E;
  }
}

/* ══════════════════════════════════════════════════════════════
   БАЗОВЫЕ ФИКСЫ ДЛЯ ТАЧ-УСТРОЙСТВ
══════════════════════════════════════════════════════════════ */

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

/* overflow-x:hidden на body ломает position:sticky.
   overflow-x:clip обрезает так же, но скролл-контейнер не создаёт. */
@supports (overflow: clip) {
  body { overflow-x: clip; }
}

/* Отключаем scroll anchoring.
   Браузер по умолчанию пытается удержать контент перед глазами
   пользователя, когда высота меняется. При смене сцены мы заменяем
   всё содержимое разом — и эта «забота» перебивает наш сброс
   прокрутки в начало, из-за чего новая сцена открывалась с середины
   и игрок не видел, как изменились показатели. */
html, body,
.game-main,
.game-content-panel { overflow-anchor: none; }

/* Высота вьюпорта без адресной строки браузера.
   Старые браузеры просто проигнорируют строку с dvh. */
body, #app, #screen-intro, #screen-menu, #screen-game, #screen-final { min-height: 100dvh; }
.menu-body { max-height: calc(100dvh - 73px); }

/* Убираем синюю подсветку при тапе и случайное выделение текста на кнопках */
button, .scenario-card, .stat-pill, .final-stat-row {
  -webkit-tap-highlight-color: transparent;
}
button, .scenario-card {
  -webkit-user-select: none;
  user-select: none;
  touch-action: manipulation;
}

/* Обратная связь на нажатие вместо hover */
@media (hover: none) {
  .choice-btn:active,
  .scenario-card:active { background: #E8F7FF; border-color: var(--accent); }
  .intro-btn:active,
  .btn-primary:active { filter: brightness(0.94); }
  .btn-secondary:active,
  .btn-share:active,
  .game-back-btn:active,
  .game-back-scene-btn:active,
  .menu-help-btn:active { background: var(--surface2); }
}

img { max-width: 100%; }

/* ══════════════════════════════════════════════════════════════
   ПОДСКАЗКИ ПО ПОКАЗАТЕЛЯМ НА ТАЧ-ЭКРАНАХ
   Ховера нет — открываются по тапу, снизу экрана как «шторка»
══════════════════════════════════════════════════════════════ */
@media (hover: none) {
  .stat-tooltip {
    position: fixed;
    left: 12px;
    right: 12px;
    top: auto;
    bottom: calc(12px + env(safe-area-inset-bottom));
    width: auto;
    max-width: 460px;
    margin: 0 auto;
    transform: translateY(14px);
    padding: 16px 18px;
    border-width: 2px;
    z-index: 200;
  }
  .stat-tooltip::before { display: none; }
  .final-stat-row .stat-tooltip {
    top: auto;
    left: 12px;
    transform: translateY(14px);
  }

  .stat-pill.tip-open .stat-tooltip,
  .final-stat-row.tip-open .stat-tooltip {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }

  .tip-title { font-size: 14px; margin-bottom: 10px; padding-bottom: 8px; }
  .tip-text  { font-size: 13px; line-height: 1.55; margin-bottom: 6px; }

  /* индикатор «здесь можно нажать» — в углу иконки, чтобы не закрывать цифру */
  .stat-pill::after {
    content: '?';
    position: absolute;
    top: 1px;
    left: 15px;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: var(--surface3);
    color: var(--text-dim);
    font-size: 8px;
    font-weight: 800;
    line-height: 11px;
    text-align: center;
  }
  .stat-pill.tip-open::after { background: var(--accent); color: #fff; }
  .final-stat-row::after { display: none; }
}

/* затемнение позади открытой подсказки */
.tip-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(26, 35, 64, 0.35);
  z-index: 40;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s ease;
}
.tip-backdrop.show { opacity: 1; pointer-events: auto; }

/* ══════════════════════════════════════════════════════════════
   ПЛАНШЕТ В АЛЬБОМНОЙ ОРИЕНТАЦИИ (901–1180px)
   Двухколоночная раскладка сохраняется, поджимаются отступы
══════════════════════════════════════════════════════════════ */
@media (min-width: 901px) and (max-width: 1180px) {
  .menu-header       { padding: 12px 22px; }
  .menu-header-logo  { height: 40px; }
  .menu-content-side { padding: 30px 34px; gap: 22px; }
  .menu-title        { font-size: clamp(28px, 4.4vw, 40px); }
  .scenario-card     { padding: 16px 18px; gap: 14px; }
  .sc-icon           { width: 50px; height: 50px; font-size: 25px; }

  .game-topbar       { padding: 11px 22px; gap: 14px; }
  .game-statsbar     { padding: 7px 22px; }
  .game-main         { grid-template-columns: 40% 60%; }
  .game-content-panel{ padding: 22px 26px; gap: 18px; }
  .scene-desc-block  { padding: 18px 20px; }
  .choice-btn        { padding: 15px 17px; }

  #screen-final      { padding: 28px 22px; }
  .final-hero        { padding: 28px 30px; gap: 22px; }
  .final-icon-big    { font-size: 64px; }
  .final-result-title{ font-size: 24px; }
  .final-stats,
  .decisions-review  { padding: 20px 22px; }

  .intro-wrap        { padding: 30px 32px; }
}

/* ══════════════════════════════════════════════════════════════
   ВЕРТИКАЛЬНЫЙ СТЕК
   телефоны (любая ориентация) + планшеты в портрете
══════════════════════════════════════════════════════════════ */
@media (max-width: 900px), (orientation: portrait) and (max-width: 1100px) {

  /* ── ЭКРАН «КАК ИГРАТЬ» ── */
  #screen-intro {
    padding: 18px 14px calc(26px + env(safe-area-inset-bottom));
    padding-left: calc(14px + env(safe-area-inset-left));
    padding-right: calc(14px + env(safe-area-inset-right));
  }
  .intro-wrap        { padding: 22px 18px; border-radius: 16px; }
  .intro-header      { margin-bottom: 22px; padding-bottom: 18px; }
  .intro-logos       { gap: 14px; margin-bottom: 14px; }
  .intro-logo        { height: 42px; }
  .intro-title       { font-size: clamp(28px, 9vw, 42px); }
  .intro-sub         { font-size: 13.5px; }
  .intro-section     { margin-bottom: 20px; }
  .intro-text        { font-size: 14.5px; line-height: 1.6; }
  .intro-stat        { padding: 12px 13px; gap: 12px; }
  .intro-stat-icon   { width: 36px; height: 36px; font-size: 18px; }
  .intro-stat-name   { font-size: 13px; }
  .intro-stat-desc   { font-size: 12.5px; }
  .intro-rules       { padding: 14px 16px; }
  .intro-rule        { font-size: 13.5px; }
  .intro-btn         { min-height: 54px; font-size: 16px; padding: 16px; }

  /* ── МЕНЮ ── */
  .menu-header {
    padding: 9px 14px;
    padding-left: calc(14px + env(safe-area-inset-left));
    padding-right: calc(14px + env(safe-area-inset-right));
    gap: 10px;
  }
  .menu-header-icon  { font-size: 22px; }
  .menu-header-logos {
    position: static;
    transform: none;
    margin-left: auto;
    gap: 10px;
    display: flex;
  }
  .menu-header-logo  { height: 30px; }
  .menu-kz-badge     { display: none; }
  .menu-help-btn     { margin-right: 0; margin-left: 4px; width: 34px; height: 34px; order: 5; }

  .menu-body         { grid-template-columns: 1fr; grid-template-rows: auto 1fr; max-height: none; }
  .menu-cover-side   { height: min(26dvh, 210px); }
  .menu-cover-side img { object-position: center 22%; }
  .menu-cover-overlay{ background: linear-gradient(to top, var(--bg) 0%, rgba(240,246,255,0) 55%); }
  .menu-content-side {
    padding: 16px 16px calc(30px + env(safe-area-inset-bottom));
    padding-left: calc(16px + env(safe-area-inset-left));
    padding-right: calc(16px + env(safe-area-inset-right));
    gap: 15px;
    justify-content: flex-start;
  }
  .menu-title        { font-size: clamp(26px, 7.6vw, 38px); }
  .menu-fact-pill    { font-size: 12px; padding: 7px 13px; }
  .scenario-list     { gap: 11px; }
  .scenario-card     { padding: 13px 14px; gap: 12px; border-radius: 15px; min-height: 68px; }
  .sc-icon           { width: 46px; height: 46px; font-size: 23px; border-radius: 12px; }
  .sc-info           { min-width: 0; }
  .sc-info h3        { font-size: 14px; line-height: 1.25; }
  .sc-info p         { font-size: 12px; line-height: 1.35; margin-top: 3px; }
  .sc-badge          { font-size: 11px; padding: 4px 10px; }
  .sc-progress-badge { font-size: 11px; padding: 3px 8px; margin-right: 6px; }

  /* ── ИГРА ── */
  .game-topbar {
    padding: 9px 14px;
    padding-left: calc(14px + env(safe-area-inset-left));
    padding-right: calc(14px + env(safe-area-inset-right));
    gap: 8px;
    flex-wrap: wrap;
    row-gap: 7px;
  }
  .game-back-btn,
  .game-back-scene-btn {
    padding: 8px 12px;
    font-size: 13px;
    min-height: 38px;
    display: inline-flex;
    align-items: center;
  }
  .game-title-block   { order: 5; flex: 1 0 100%; }
  .game-scenario-label{ font-size: 10px; letter-spacing: 1px; }
  .game-scenario-title{ font-size: 14px; }
  .game-progress-wrap { flex: 1 1 auto; min-width: 70px; margin-left: auto; gap: 3px; }
  .progress-dot       { flex: 1 1 0; width: auto; min-width: 3px; max-width: 26px; height: 4px; }

  /* показатели: компактно и залипают сверху */
  .game-statsbar {
    display: flex;
    position: sticky;
    top: 0;
    z-index: 60;
    padding: 5px 6px;
    padding-left: calc(6px + env(safe-area-inset-left));
    padding-right: calc(6px + env(safe-area-inset-right));
    box-shadow: 0 2px 12px rgba(0, 100, 180, 0.10);
  }
  .stat-pill          { padding: 4px 8px; gap: 7px; }
  .stat-pill-icon     { font-size: 15px; }
  .stat-pill-label    { font-size: 9px; letter-spacing: 0.2px; }
  .stat-pill-bar-wrap { height: 4px; margin-top: 3px; }
  .stat-pill-val      { font-size: 12px; width: 21px; }
  .stat-delta         { font-size: 12px; right: 4px; }

  /* главная область — вертикальный стек, скроллится вся страница */
  .game-main {
    display: flex;
    flex-direction: column;
    overflow: visible;
  }
  .game-image-panel {
    flex: none;
    height: clamp(150px, 28dvh, 280px);
  }
  .game-image-panel img { object-position: center 20%; }
  .game-image-overlay   { height: 80px; }
  .game-location-tag    { font-size: 11px; padding: 5px 13px; bottom: 12px; max-width: 88%; overflow: hidden; text-overflow: ellipsis; }

  .game-content-panel {
    overflow: visible;
    gap: 15px;
    padding: 16px 14px calc(30px + env(safe-area-inset-bottom));
    padding-left: calc(14px + env(safe-area-inset-left));
    padding-right: calc(14px + env(safe-area-inset-right));
  }

  .scene-desc-block   { padding: 16px 16px; border-radius: 15px; }
  .scene-chapter-label{ font-size: 10px; }
  .scene-desc-text    { font-size: 15px; line-height: 1.62; }

  .dialogue-block     { gap: 10px; }
  .dialogue-msg       { gap: 9px; }
  .msg-avatar         { width: 34px; height: 34px; font-size: 17px; border-width: 1.5px; }
  .msg-bubble         { padding: 10px 13px; max-width: calc(100% - 46px); border-radius: 13px; }
  .msg-name           { font-size: 11px; margin-bottom: 4px; }
  .msg-text           { font-size: 14px; line-height: 1.55; }

  .consequence-card   { padding: 15px 16px; border-radius: 15px; }
  .consequence-header { gap: 10px; margin-bottom: 8px; }
  .consequence-icon   { font-size: 23px; }
  .consequence-title  { font-size: 13px; }
  .consequence-text   { font-size: 14px; line-height: 1.6; }

  .legal-tip          { padding: 14px 15px; border-radius: 15px; }
  .legal-tip-header   { font-size: 11px; margin-bottom: 7px; }
  .legal-tip-text     { font-size: 13.5px; line-height: 1.62; }
  .legal-tip-text i   { font-size: 12.5px; }

  .choices-label      { font-size: 12px; }
  .choices-list       { gap: 9px; }
  .choice-btn {
    padding: 13px 14px;
    gap: 11px;
    font-size: 14.5px;
    line-height: 1.42;
    min-height: 54px;
    border-radius: 14px;
  }
  .choice-num         { width: 27px; height: 27px; font-size: 13px; border-radius: 9px; }

  /* ── ФИНАЛ ── */
  #screen-final {
    padding: 18px 14px calc(26px + env(safe-area-inset-bottom));
    padding-left: calc(14px + env(safe-area-inset-left));
    padding-right: calc(14px + env(safe-area-inset-right));
  }
  .final-wrap         { gap: 14px; }
  .final-hero         { flex-direction: column; text-align: center; padding: 24px 18px; gap: 12px; border-radius: 16px; }
  .final-icon-big     { font-size: 56px; }
  .final-result-title { font-size: 21px; margin-bottom: 8px; }
  .final-result-sub   { font-size: 14.5px; line-height: 1.6; }

  .final-grid         { grid-template-columns: 1fr; gap: 14px; }
  .final-stats,
  .decisions-review   { padding: 18px 16px; border-radius: 16px; }
  .final-stats h3,
  .decisions-review h3{ font-size: 12px; margin-bottom: 15px; }
  .final-stat-row     { gap: 10px; margin-bottom: 13px; }
  .final-stat-label   { width: 100px; font-size: 13px; }
  .final-stat-num     { font-size: 13px; width: 30px; }
  .decision-item      { font-size: 13px; margin-bottom: 12px; }

  .endings-tracker-wrap { padding: 16px 16px; border-radius: 16px; }
  .endings-count      { font-size: 12px; }
  .endings-dots       { gap: 8px; }
  .ending-dot         { height: 42px; font-size: 19px; }
  .endings-hint       { font-size: 12px; }

  .final-buttons      { flex-direction: column; gap: 10px; }
  .btn                { padding: 15px 20px; font-size: 15px; min-height: 52px; width: 100%; }
}

/* ══════════════════════════════════════════════════════════════
   ПЛАНШЕТ В ПОРТРЕТЕ (601–1100px)
   Раскладка остаётся вертикальной, но текст и элементы
   возвращаются к «взрослым» размерам, а колонка ограничивается
   по ширине — иначе строка растягивается и читать тяжело.
══════════════════════════════════════════════════════════════ */
@media (min-width: 601px) and (max-width: 1100px) and (orientation: portrait) {

  /* ── ЭКРАН «КАК ИГРАТЬ» ── */
  .intro-wrap        { padding: 32px 34px; }
  .intro-logo        { height: 56px; }
  .intro-text        { font-size: 16px; }
  .intro-stat-desc   { font-size: 13.5px; }
  .intro-rule        { font-size: 14.5px; }

  /* ── МЕНЮ ── */
  .menu-header       { padding: 12px 24px; }
  .menu-header-logo  { height: 42px; }
  .menu-kz-badge     { display: inline-block; margin-left: 12px; }
  .menu-cover-side   { height: min(30dvh, 340px); }
  .menu-content-side { max-width: 780px; width: 100%; margin: 0 auto; padding: 28px 30px 44px; gap: 24px; }
  .menu-title        { font-size: 46px; }
  .menu-fact-pill    { font-size: 13px; padding: 8px 16px; }
  .scenario-list     { gap: 14px; }
  .scenario-card     { padding: 18px 20px; gap: 16px; min-height: 84px; }
  .sc-icon           { width: 56px; height: 56px; font-size: 28px; }
  .sc-info h3        { font-size: 16px; }
  .sc-info p         { font-size: 13.5px; }
  .sc-badge          { font-size: 12px; padding: 5px 12px; }

  /* ── ИГРА ── */
  .game-topbar        { padding: 12px 24px; gap: 14px; flex-wrap: nowrap; }
  .game-title-block   { order: 0; flex: 1; }
  .game-scenario-title{ font-size: 16px; }
  .game-progress-wrap { flex: 0 1 300px; }
  .progress-dot       { max-width: 30px; height: 5px; }

  .game-statsbar      { justify-content: center; padding: 8px 20px; }
  .stat-pill          { flex: 0 1 240px; padding: 6px 18px; gap: 10px; }
  .stat-pill-icon     { font-size: 18px; }
  .stat-pill-label    { font-size: 10px; }
  .stat-pill-bar-wrap { height: 5px; margin-top: 4px; }
  .stat-pill-val      { font-size: 14px; width: 26px; }
  .stat-pill::after   { left: 18px; width: 13px; height: 13px; line-height: 13px; font-size: 9px; }

  .game-image-panel   { height: min(30dvh, 340px); }
  .game-content-panel { max-width: 780px; width: 100%; margin: 0 auto; padding: 26px 30px 44px; gap: 20px; }
  .scene-desc-block   { padding: 20px 24px; }
  .scene-desc-text    { font-size: 16.5px; line-height: 1.7; }
  .msg-avatar         { width: 40px; height: 40px; font-size: 19px; }
  .msg-bubble         { padding: 12px 16px; max-width: 80%; }
  .msg-text           { font-size: 15.5px; }
  .consequence-text   { font-size: 15px; }
  .legal-tip-text     { font-size: 14.5px; }
  .choice-btn         { font-size: 16px; padding: 16px 18px; min-height: 58px; gap: 13px; }
  .choice-num         { width: 30px; height: 30px; font-size: 14px; }

  /* ── ФИНАЛ ── */
  #screen-final       { padding: 32px 26px; }
  .final-wrap         { gap: 20px; }
  .final-hero         { flex-direction: row; text-align: left; padding: 30px 32px; gap: 24px; }
  .final-icon-big     { font-size: 68px; }
  .final-result-title { font-size: 25px; }
  .final-result-sub   { font-size: 15.5px; }
  .final-grid         { grid-template-columns: 1fr 1fr; gap: 18px; }
  .final-stats,
  .decisions-review   { padding: 22px 24px; }
  .final-stat-label   { width: 108px; font-size: 13.5px; }
  .decision-item      { font-size: 13.5px; }
  .final-buttons      { flex-direction: row; gap: 12px; }
  .btn                { width: auto; font-size: 15px; padding: 15px 20px; }
  .ending-dot         { height: 50px; font-size: 22px; }
}

/* ══════════════════════════════════════════════════════════════
   ТЕЛЕФОНЫ ≤ 560px — убираем лишнее
══════════════════════════════════════════════════════════════ */
@media (max-width: 560px) {
  .sc-badge          { display: none; }
  .menu-facts        { gap: 8px; }
  .menu-header-logo  { height: 27px; }
  .final-stat-label  { width: 102px; font-size: 12.5px; }
}

/* ══════════════════════════════════════════════════════════════
   УЗКИЕ ТЕЛЕФОНЫ ≤ 380px
══════════════════════════════════════════════════════════════ */
@media (max-width: 380px) {
  .menu-content-side { padding-left: 12px; padding-right: 12px; }
  .game-content-panel{ padding-left: 11px; padding-right: 11px; }
  .scenario-card     { padding: 12px; gap: 10px; }
  .sc-icon           { width: 42px; height: 42px; font-size: 21px; }
  .sc-info p         { font-size: 11.5px; }

  .stat-pill         { padding: 4px 5px; gap: 5px; }
  .stat-pill-icon    { font-size: 13px; }
  .stat-pill-label   { font-size: 8px; }
  .stat-pill-val     { font-size: 11px; width: 18px; }

  .scene-desc-text   { font-size: 14.5px; }
  .choice-btn        { font-size: 14px; padding: 12px 12px; gap: 9px; }
  .msg-text          { font-size: 13.5px; }
  .msg-bubble        { max-width: calc(100% - 42px); }
  .final-stat-label  { width: 92px; font-size: 11.5px; }
}

/* ══════════════════════════════════════════════════════════════
   ТЕЛЕФОН В АЛЬБОМНОЙ ОРИЕНТАЦИИ — экран низкий, режем картинку
══════════════════════════════════════════════════════════════ */
@media (orientation: landscape) and (max-height: 520px) {
  /* шапка в одну строку — по ширине места хватает, по высоте нет */
  .game-topbar        { flex-wrap: nowrap; padding-top: 7px; padding-bottom: 7px; }
  .game-title-block   { order: 0; flex: 1 1 auto; }
  .game-progress-wrap { flex: 0 1 200px; }
  .game-statsbar      { padding-top: 4px; padding-bottom: 4px; }

  .game-image-panel  { height: min(34dvh, 120px); }
  .menu-cover-side   { height: min(34dvh, 130px); }
  .menu-title        { font-size: 30px; }
  .menu-content-side { padding-top: 14px; gap: 12px; }
  #screen-intro      { padding-top: 14px; }
  .intro-logo        { height: 34px; }
  .final-icon-big    { font-size: 44px; }
}

/* ══════════════════════════════════════════════════════════════
   ЩАДЯЩИЙ РЕЖИМ АНИМАЦИЙ
══════════════════════════════════════════════════════════════ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ══════════════════════════════════════════════════════════════
   ПЕЧАТЬ (на случай распечатки методички)
══════════════════════════════════════════════════════════════ */
@media print {
  .game-topbar, .game-statsbar, .choices-section, .final-buttons { display: none !important; }
  body { background: #fff; }
  body::before { display: none; }
}

