/* menu-kit.css – gemeinsame Bausteine für HTML-Menü-Overlays (Start/Ende/Preise …).
   Quelle: C:\dev\gastro-games\_menu-kit\ – pro Spiel in den Spielordner kopieren
   (jedes Spiel wird einzeln deployt). Farben kommen aus config.json branding:
   --ov-primary / --ov-secondary werden von applyTheme() (menu-kit.js) gesetzt. */

.ov-screen {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 40;
  flex-direction: column;
  align-items: center;
  overflow-y: auto;
  padding: max(26px, env(safe-area-inset-top)) 22px calc(26px + env(safe-area-inset-bottom, 0px));
  font-family: -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  color: #fff;
  text-align: center;
  touch-action: auto;
}
/* Inhalt mittig, solange er in die Höhe passt; sonst scrollbar */
.ov-screen > :first-child:not(.ov-deco), .ov-screen > .ov-deco + * { margin-top: auto; }
.ov-screen > :last-child  { margin-bottom: auto; }

/* weicher Farb-Glow hinter dem Inhalt */
.ov-screen::before {
  content: '';
  position: fixed;
  left: 50%; top: 30%;
  width: 120vmin; height: 120vmin;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, var(--ov-primary, #e63946) 0%, transparent 60%);
  opacity: var(--ov-glow, 0.18);
  pointer-events: none;
  z-index: -1;
}

.ov-brand {
  width: min(86%, 320px);
  margin-bottom: 14px;
  font-size: 38px;
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: 1px;
  color: var(--ov-primary, #e63946);
  text-shadow: 0 3px 0 rgba(0,0,0,.5), 0 8px 22px rgba(0,0,0,.45);
  overflow-wrap: break-word;
}
.ov-brand img {
  width: auto; max-width: 100%; max-height: 24vh;
  margin: 0 auto; display: block;
  filter: drop-shadow(0 8px 18px rgba(0,0,0,.4));
}
.ov-brand--sm { width: min(90%, 320px); font-size: 24px; }
.ov-brand--sm img { max-height: 13vh; }

.ov-title { font-size: 30px; font-weight: 800; margin-bottom: 8px; text-shadow: 0 2px 6px rgba(0,0,0,.4); }
.ov-sub   { font-size: 17px; line-height: 1.45; color: var(--ov-secondary, #a8dadc); max-width: 340px; margin-bottom: 20px; }
.ov-label { font-size: 12.5px; letter-spacing: 4px; color: rgba(255,255,255,.6); margin-bottom: 8px; }
.ov-muted { font-size: 12px; line-height: 1.45; color: rgba(255,255,255,.5); max-width: 340px; margin-bottom: 12px; }

.ov-card {
  width: 100%; max-width: 360px;
  background: rgba(255,255,255,.07);
  border: 1.5px solid rgba(255,255,255,.16);
  border-radius: 18px;
  padding: 14px 18px;
  margin-bottom: 18px;
  backdrop-filter: blur(6px);
  box-shadow: 0 10px 24px rgba(0,0,0,.25);
}
.ov-card p { font-size: 14.5px; line-height: 1.5; margin: 0 0 6px; color: rgba(255,255,255,.88); }
.ov-card p:last-child { margin-bottom: 0; }
.ov-card[hidden] { display: none; }

.ov-btn {
  border: none; border-radius: 16px;
  font-weight: 800; letter-spacing: .3px;
  cursor: pointer; margin-bottom: 12px;
  transition: transform .08s ease;
}
.ov-btn:active { transform: scale(.96); }
.ov-btn--block { width: 100%; max-width: 320px; padding: 17px; font-size: 21px; box-shadow: 0 10px 22px rgba(0,0,0,.35); }
.ov-btn-primary {
  background: linear-gradient(180deg, var(--ov-primary, #e63946) 0%, var(--ov-primary-dark, #b3202c) 100%);
  color: #fff;
  box-shadow: 0 10px 22px rgba(0,0,0,.35), inset 0 1px 0 rgba(255,255,255,.3);
}
.ov-btn--pulse { animation: ov-pulse 1.6s ease-in-out infinite; }
.ov-btn--pulse:active { animation: none; }
@keyframes ov-pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.035); } }

/* Ein-/Ausblenden (revealOverlay()/fadeOutOverlay() in menu-kit.js) */
.ov-fade-in  { animation: ov-fade-in .35s ease both; }
.ov-fade-out { animation: ov-fade-out .25s ease both; }
@keyframes ov-fade-in  { from { opacity: 0; } to { opacity: 1; } }
@keyframes ov-fade-out { from { opacity: 1; } to { opacity: 0; } }

/* Steuerungs-Zonen (◀ ▶) */
.ov-zones { display: flex; gap: 10px; width: 100%; max-width: 360px; margin-bottom: 8px; }
.ov-zone {
  flex: 1; height: 62px; display: flex; align-items: center; justify-content: center;
  font-size: 26px; border-radius: 14px;
  border: 1.5px solid rgba(255,255,255,.2); background: rgba(255,255,255,.05);
}
.ov-zone span { display: block; animation: ov-nudge 1.3s ease-in-out infinite; }
.ov-zone:first-child span { --d: -8px; }
.ov-zone:last-child  span { --d: 8px; }
@keyframes ov-nudge { 0%,100% { transform: translateX(0); } 50% { transform: translateX(var(--d)); } }
.ov-hint { font-size: 14px; color: rgba(255,255,255,.65); white-space: pre-line; margin-bottom: 16px; }

/* Gutschein-/Preis-Stufen (alle sichtbar, erspielte hervorgehoben) */
.ov-tiers { width: 100%; max-width: 360px; margin-bottom: 12px; }
.ov-tier {
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
  padding: 8px 14px; margin-bottom: 6px; border-radius: 14px;
  background: rgba(0,0,0,.28); opacity: .65;
}
.ov-tier img { width: 32px; height: 32px; image-rendering: pixelated; transform: scale(.85); }
.ov-tier-text { flex: 1; }
.ov-tier-text p { margin: 0; }
.ov-tier-reward { font-size: 16px; font-weight: 600; }
.ov-tier-sub { font-size: 12.5px; margin-top: 2px !important; color: rgba(255,255,255,.6); }
.ov-tier--earned {
  background: linear-gradient(180deg, var(--ov-primary, #e63946), var(--ov-primary-dark, #b3202c));
  opacity: 1; transform: scale(1.03); box-shadow: 0 8px 20px rgba(0,0,0,.35);
}
.ov-tier--earned img { transform: scale(1.25); }
.ov-tier--earned .ov-tier-reward { font-size: 19px; font-weight: 800; }
.ov-tier--earned .ov-tier-sub { color: #ffeeaa; }

/* Ergebnis-Zeilen (Endscreen) */
.ov-stat { display: flex; justify-content: space-between; font-size: 17px; padding: 3px 0; }
.ov-stat strong { color: #ffd700; }
.ov-stat--score { font-size: 22px; font-weight: 800; border-top: 1px solid rgba(255,255,255,.2); margin-top: 6px; padding-top: 8px; }

/* Endscreen kompakt, damit alles ohne Scrollen passt */
.ov-screen--compact { padding-top: max(16px, env(safe-area-inset-top)); padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px)); }
.ov-screen--compact .ov-brand { margin-bottom: 6px; }
.ov-screen--compact .ov-card  { padding: 11px 18px; margin-bottom: 12px; }
.ov-screen--compact .ov-title { font-size: 28px; margin-bottom: 4px; }
.ov-screen--compact .ov-btn--block { padding: 15px; margin-bottom: 8px; }
.ov-screen--flat .ov-brand img { filter: none; }
