/* ============================================================
   Štiri v vrsto — game specific styles.
   Shared panels / chips / game bar live in assets/kids.css
   ============================================================ */

:root {
  --chrome:    210px;   /* zgornja vrstica + vrstica "na vrsti" + robovi */
  --board-cap: 640px;
}

#modes .chip.on  { background: var(--sky);   box-shadow: 0 5px 0 var(--sky-d); }

.panel.off { opacity: .45; pointer-events: none; }

/* ---------- game bar ---------- */

.score-chip.player.active { transform: translateY(-3px) scale(1.08); color: #fff; }

.turn-line { text-align: center; margin-top: 12px; min-height: 2.2em; }

/* ---------- board ---------- */

.board-holder {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
}

/* The board's height comes from its round holes (aspect-ratio: 1), so only the
   width needs capping — a 7:6 board that is H tall is H * 7/6 wide. */
.board {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: clamp(3px, .8vmin, 8px);
  width: 100%;
  max-width: min(100%, calc((100vh  - var(--chrome)) * 7 / 6), var(--board-cap));
  max-width: min(100%, calc((100dvh - var(--chrome)) * 7 / 6), var(--board-cap));
  padding: clamp(6px, 1.2vmin, 14px);
  background: linear-gradient(160deg, #6FB3FF 0%, #4D96FF 100%);
  border-radius: clamp(16px, 3vmin, 30px);
  box-shadow: 0 10px 0 var(--sky-d), 0 18px 34px rgba(35,48,74,.18);
}

.col {
  display: flex;
  flex-direction: column;
  gap: clamp(3px, .8vmin, 8px);
  border: none;
  padding: 0;
  background: none;
  cursor: pointer;
  min-width: 0;
  border-radius: 12px;
  transition: background .15s ease;
}
.col:hover:not(.full) { background: rgba(255,255,255,.16); }
.col.full { cursor: default; }
.board.locked .col { pointer-events: none; }

.hole {
  aspect-ratio: 1;      /* daje višino celotni plošči */
  width: 100%;
  border-radius: 50%;
  background: rgba(255,255,255,.92);
  box-shadow: inset 0 3px 6px rgba(35,48,74,.18);
  position: relative;
  overflow: hidden;
}

.disc {
  position: absolute;
  inset: 6%;
  border-radius: 50%;
  animation: dropIn .32s cubic-bezier(.4,.05,.6,1.1);
}
.disc.a { background: radial-gradient(circle at 34% 30%, #8FBEFF, var(--sky) 60%, var(--sky-d)); }
.disc.b { background: radial-gradient(circle at 34% 30%, #FFA0A0, var(--coral) 60%, var(--coral-d)); }
@keyframes dropIn { from { transform: translateY(-560%); } to { transform: none; } }

.hole.win .disc { animation: winPulse .7s ease infinite alternate; }
@keyframes winPulse {
  from { box-shadow: 0 0 0 0 rgba(33,199,168,0); transform: scale(1); }
  to   { box-shadow: 0 0 0 6px rgba(33,199,168,.55); transform: scale(1.06); }
}

/* ---------- overlay ---------- */

@media (orientation: landscape) and (max-height: 560px) {
  :root { --chrome: 140px; --board-cap: 460px; }
  .turn-line { margin-top: 6px; }
}
@media (max-width: 480px) {
  :root { --chrome: 200px; --board-cap: 520px; }
}
