/* ---------- stranica Igre ---------- */
.games-intro { padding-top: clamp(40px, 7vw, 64px); padding-bottom: 8px; }
.games-intro h1 { font-size: clamp(38px, 7vw, 56px); line-height: 1.05; }
.games-intro p { color: var(--siva); margin: 10px 0 0; max-width: 640px; }
.pick { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 24px 0 0; }
.pick button { font: inherit; color: var(--kora); background: #fff; border: 2px solid var(--linija); border-radius: 18px; padding: 10px 8px 14px; cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; }
.pick button img { width: 100px; height: 67px; }
.pick button b { font-size: 15px; line-height: 1.2; }
.pick button span { font-size: 13px; color: var(--siva); line-height: 1.3; }
.pick button[aria-pressed="true"] { border-color: var(--psenica); background: #FFF8EA; box-shadow: 0 0 0 3px rgba(227,167,47,.25); }
@media (max-width: 720px) { .pick { grid-template-columns: repeat(2, minmax(0, 1fr)); } .pick button span { display: none; } }

.stage-wrap { padding-top: 24px; padding-bottom: clamp(56px, 9vw, 88px); }
#game { max-width: 420px; margin: 0 auto; background: var(--brasno); border: 1px solid var(--linija); border-radius: 26px; overflow: hidden; scroll-margin-top: 84px; padding-bottom: 16px; user-select: none; -webkit-user-select: none; }

/* zajednički delovi igara */
.g-head { background: var(--kora); color: var(--brasno); padding: 16px 20px; display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; }
.g-head > div:first-child { display: flex; flex-direction: column; gap: 2px; }
.g-kicker { font-size: 12px; letter-spacing: 1.5px; text-transform: uppercase; color: var(--psenica); font-weight: 700; }
.g-title { font-family: var(--naslov); font-weight: 800; font-size: 24px; }
.g-stats { display: flex; flex-direction: column; align-items: flex-end; font-size: 14px; color: var(--pesak); }
.g-stats b { color: var(--brasno); font-size: 17px; }
.g-stats b.g-lives { color: var(--crveno-tamno); font-size: 15px; }
.g-rel { position: relative; }
.g-row { display: flex; gap: 10px; margin: 12px 16px 0; }
.g-btn { flex: 1 1 0; min-height: 48px; border-radius: 14px; border: 1.5px solid var(--linija-2); background: #fff; color: var(--kora); font: inherit; font-weight: 700; font-size: 20px; cursor: pointer; }
.g-btn-text { font-size: 16px; font-weight: 600; }
.g-note { margin: 10px 16px 0; font-size: 13px; color: var(--siva); text-align: center; }
.g-small { font-size: 13px; color: var(--siva); }
.g-over { position: absolute; inset: 0; z-index: 5; background: rgba(42,26,16,0.92); color: var(--brasno); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 28px; text-align: center; }
.g-big { font-family: var(--naslov); font-weight: 800; font-size: 28px; }
.g-muted { color: var(--pesak); font-size: 15px; line-height: 1.5; }
.g-kick2 { font-size: 14px; color: var(--psenica); font-weight: 700; letter-spacing: 1px; text-transform: uppercase; }
.g-score { font-family: var(--naslov); font-weight: 800; font-size: 54px; line-height: 1; }
.g-tel { color: var(--psenica) !important; font-weight: 700; font-size: 20px; }
.g-cta { margin-top: 8px; background: var(--psenica); color: var(--kora); border: none; padding: 14px 30px; border-radius: 999px; font: inherit; font-weight: 700; font-size: 17px; cursor: pointer; min-height: 48px; }

/* 1. uhvati */
.c-field { position: relative; margin: 14px 16px 0; height: 520px; border-radius: 20px; overflow: hidden; background: #3A281C; touch-action: none; }
.c-top { position: absolute; left: 0; right: 0; top: 0; height: 26px; background: var(--kora); border-bottom: 3px solid var(--psenica); }
.c-item { position: absolute; left: 0; top: 0; width: 70px; height: 47px; pointer-events: none; will-change: transform; }
.c-tray { position: absolute; top: 476px; left: 131px; width: 96px; height: 26px; border-radius: 6px 6px 14px 14px; background: #9A9A9A; border: 3px solid #5E5E5E; box-sizing: border-box; pointer-events: none; }
.c-flash { position: absolute; left: 0; right: 0; top: 40px; text-align: center; font-weight: 700; font-size: 18px; pointer-events: none; }

/* 2. spakuj */
.o-card { margin: 14px 16px 0; background: #fff; border: 1px solid var(--linija); border-radius: 18px; padding: 14px 16px; display: flex; flex-direction: column; gap: 8px; }
.o-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.o-cust { font-weight: 700; font-size: 17px; }
.o-lines { display: flex; flex-direction: column; gap: 6px; }
.o-line { display: flex; justify-content: space-between; gap: 10px; font-size: 16px; }
.o-bar { height: 12px; border-radius: 999px; background: #F1E8DA; overflow: hidden; margin-top: 4px; }
.o-bar-in { height: 100%; border-radius: 999px; transition: width .1s linear; }
.o-msg { font-size: 13px; font-weight: 600; min-height: 18px; }
.o-shelf { margin: 12px 16px 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.o-prod { background: #fff; border: 1.5px solid var(--linija); border-radius: 14px; padding: 6px 4px 8px; display: flex; flex-direction: column; align-items: center; gap: 2px; cursor: pointer; font: inherit; color: var(--kora); min-height: 104px; touch-action: manipulation; }
.o-prod:active { background: #FFF8EA; border-color: var(--psenica); }
.o-prod img { width: 88px; height: 59px; pointer-events: none; }
.o-prod span { font-size: 12px; font-weight: 600; line-height: 1.2; }

/* 3. memorija */
.m-hint { margin: 14px 16px 0; font-size: 15px; color: var(--siva); text-align: center; min-height: 22px; }
.m-grid { margin: 10px 16px 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.m-card { height: 132px; border-radius: 16px; cursor: pointer; font: inherit; padding: 6px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; border: 2px solid var(--kora-3); background: var(--kora); color: var(--kora); touch-action: manipulation; }
.m-card.is-open { background: #fff; border-color: var(--psenica); }
.m-card.is-match { background: var(--zeleno-bg); border-color: var(--zeleno-tamno); }
.m-card img { width: 96px; height: 64px; pointer-events: none; }
.m-card span { font-size: 12px; font-weight: 600; line-height: 1.2; text-align: center; }

/* 4. pečenje */
.b-oven { margin: 16px 16px 0; height: 300px; border-radius: 22px; background: #1E130C; border: 6px solid var(--kora-3); box-sizing: border-box; position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.b-glow { position: absolute; left: 0; right: 0; bottom: 0; height: 120px; }
.b-heat { position: absolute; left: 18px; right: 18px; height: 6px; border-radius: 3px; background: var(--crveno-tacka); }
.b-heat-t { top: 26px; } .b-heat-b { bottom: 26px; }
.b-oven img { position: relative; width: 240px; height: 160px; }
.b-name { position: absolute; left: 0; right: 0; top: 40px; text-align: center; color: var(--pesak); font-size: 15px; font-weight: 600; }
.b-scale { margin: 16px 16px 0; display: flex; flex-direction: column; gap: 6px; }
.b-track { position: relative; height: 22px; border-radius: 999px; overflow: hidden; background: linear-gradient(90deg, #F3E3C3 0%, #E8C27A 45%, #C98A34 70%, #6B3A1A 88%, #1E130C 100%); }
.b-zone { position: absolute; top: 0; bottom: 0; border: 3px solid #2F8A43; box-sizing: border-box; border-radius: 6px; }
.b-mark { position: absolute; top: -2px; bottom: -2px; width: 4px; margin-left: -2px; background: #fff; box-shadow: 0 0 0 2px var(--kora); }
.b-labels { display: flex; justify-content: space-between; font-size: 12px; color: var(--siva); }
.b-labels b { color: var(--zeleno); }
.b-result { margin: 14px 16px 0; min-height: 52px; text-align: center; display: flex; flex-direction: column; gap: 2px; }
.b-res { font-family: var(--naslov); font-weight: 800; font-size: 24px; }
.b-btn { display: block; width: calc(100% - 32px); margin: 8px 16px 0; min-height: 64px; border-radius: 18px; border: none; background: var(--psenica); color: var(--kora); font: inherit; font-weight: 800; font-size: 22px; cursor: pointer; touch-action: manipulation; }
.b-btn-dark { background: var(--kora); color: var(--brasno); font-weight: 700; font-size: 19px; }
.g-stats span { white-space: nowrap; }

/* kraj partije */
.g-quip { margin-top: 8px; max-width: 300px; font-size: 17px; line-height: 1.45; font-style: italic; color: var(--brasno); }
.g-quip2 { margin-top: 12px; max-width: 300px; font-size: 15px; line-height: 1.45; color: var(--zuto-tamno); }
.g-wide { min-width: 190px; }
.g-call { margin-top: 6px; min-height: 48px; box-sizing: border-box; display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 2px solid var(--psenica); color: var(--brasno) !important; text-decoration: none; padding: 10px 22px; border-radius: 999px; font-weight: 700; font-size: 17px; }
.g-call:hover { background: rgba(227,167,47,.15); }

/* dugme i režim celog ekrana */
.g-fs { flex-shrink: 0; width: 44px; height: 44px; border-radius: 12px; border: 1.5px solid #5A4232; background: var(--kora-2); color: var(--brasno); cursor: pointer; display: flex; align-items: center; justify-content: center; padding: 0; align-self: center; }
.g-fs:hover { border-color: var(--psenica); }
.g-box { width: 100%; transform-origin: center center; }
#game.is-full { position: fixed; inset: 0; z-index: 100; max-width: none; margin: 0; border: 0; border-radius: 0; background: var(--kora); display: flex; align-items: center; justify-content: center; padding: 0; overflow: hidden; }
#game.is-full .g-box { width: 400px; flex-shrink: 0; background: var(--brasno); border-radius: 22px; overflow: hidden; padding-bottom: 16px; }
html.g-lock, html.g-lock body { overflow: hidden; }

/* zaglavlje igre na uskim ekranima */
.g-head > div:first-child { min-width: 0; flex: 1 1 auto; }
.g-kicker { white-space: nowrap; }
@media (max-width: 440px) {
  .g-head { padding: 14px 14px 14px 16px; gap: 10px; }
  .g-kicker { font-size: 11px; letter-spacing: 1px; }
  .g-title { font-size: 20px; line-height: 1.15; }
  .g-stats { font-size: 13px; }
}
