:root {
    --cell: 44px;
    --gap: 5px;
    --pad: 8px;
    --radius: 11px;
    --pcell: 26px; /* veličina ćelije figurice u tacni (skalira se na malim ekranima) */

    /* tema: neon (podrazumevana) */
    --text: #fff;
    --text-dim: rgba(255, 255, 255, 0.55);
    --surface: rgba(255, 255, 255, 0.04);
    --surface-bd: rgba(255, 255, 255, 0.08);
    --cell-empty: rgba(255, 255, 255, 0.035);
    --board-bg: #0a0712;
    --stage-bg: rgba(20, 14, 40, 0.55);
    --bg1: #0a0616;
    --bg2: #120a26;
    --bg3: #05030a;
    --aura1: rgba(124, 77, 255, 0.28);
    --aura2: rgba(0, 242, 254, 0.20);
    --aura3: rgba(255, 126, 179, 0.18);
}

[data-theme="dark"] {
    --text: #e8eaf0;
    --text-dim: rgba(232, 234, 240, 0.5);
    --surface: rgba(255, 255, 255, 0.03);
    --surface-bd: rgba(255, 255, 255, 0.06);
    --cell-empty: rgba(255, 255, 255, 0.03);
    --board-bg: #070a0f;
    --stage-bg: rgba(16, 20, 28, 0.6);
    --bg1: #0b0d12;
    --bg2: #11151c;
    --bg3: #05070a;
    --aura1: rgba(90, 100, 130, 0.16);
    --aura2: rgba(60, 90, 120, 0.14);
    --aura3: rgba(110, 110, 140, 0.12);
}

[data-theme="light"] {
    --text: #1c1340;
    --text-dim: rgba(28, 19, 64, 0.55);
    --surface: rgba(255, 255, 255, 0.65);
    --surface-bd: rgba(28, 19, 64, 0.12);
    --cell-empty: rgba(28, 19, 64, 0.07);
    --board-bg: #e7e3f6;
    --stage-bg: rgba(255, 255, 255, 0.6);
    --bg1: #eef0ff;
    --bg2: #e1e7ff;
    --bg3: #f6f0ff;
    --aura1: rgba(124, 77, 255, 0.18);
    --aura2: rgba(0, 170, 254, 0.16);
    --aura3: rgba(255, 126, 179, 0.18);
}

* {
    box-sizing: border-box;
    -webkit-user-select: none;
    -moz-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
    -webkit-tap-highlight-color: transparent;
}

html, body {
    margin: 0;
    width: 100%;
    min-height: 100vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text);
    /* SEO blok ispod igre: vertikalni skrol dozvoljen; touch-action:none je na .vb-app
       (drag počinje unutar igre pa gestovi igre i dalje ne skroluju stranicu). */
    overflow-x: hidden;
    overscroll-behavior: none;
    background: linear-gradient(160deg, var(--bg1) 0%, var(--bg2) 50%, var(--bg3) 100%);
    background-attachment: fixed;
    transition: color 0.3s ease;
}

.vb-app {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    padding: calc(12px + env(safe-area-inset-top)) 12px calc(18px + env(safe-area-inset-bottom));
    min-height: 100vh;
    min-height: 100dvh;
    touch-action: none;   /* gestovi igre (drag) ne smeju da skroluju stranicu */
}

/* ---------- Gear / settings dugme ---------- */
/* ---------- Top bar (novčići + dugmad) ---------- */
.vb-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    width: 100%;
    max-width: 420px;
}
.vb-topbar__btns { display: flex; gap: 10px; }

.vb-iconbtn {
    position: relative;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--text);
    border: 1px solid var(--surface-bd);
    border-radius: 14px;
    background: var(--surface);
    backdrop-filter: blur(10px);
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease;
}
.vb-iconbtn:hover { transform: translateY(-2px); }
#settingsBtn:hover { transform: rotate(45deg); }
.vb-iconbtn .ic { width: 22px; height: 22px; }

/* ---------- Ikone (uniformne linijske, iz sprite-a) ---------- */
.vb-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
.ic {
    display: block;
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.ic .f { fill: currentColor; stroke: none; }

.vb-missions-btn__badge {
    position: absolute;
    top: -6px;
    right: -6px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 800;
    color: #1a1030;
    background: #ffd86b;
    border-radius: 999px;
}
.vb-missions-btn__badge[hidden] { display: none; }

/* Brojač novčića (pila) je SDK widget: .vasa-coins (Vasa.mountCoins). */

/* novčić — CSS disk (nezavisno od emoji fonta) */
.coin {
    display: inline-block;
    width: 0.95em;
    height: 0.95em;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #fff3c4, #ffd24d 55%, #e0a52e);
    box-shadow: inset 0 0 0 1.5px #c98a1e, inset 0 0 0 3px rgba(255, 255, 255, 0.25), 0 1px 1px rgba(0, 0, 0, 0.35);
    vertical-align: -0.12em;
}

/* ---------- Header ---------- */
.vb-header {
    width: 100%;
    max-width: 420px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
}

/* Logo ostaje u DOM-u zbog SEO/pristupačnosti, ali je vizuelno skriven
   (oslobađa ceo jedan red na malim ekranima). */
.vb-logo {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.vb-scores {
    display: flex;
    gap: 12px;
    width: 100%;
}

.vb-score {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 10px 8px;
    border-radius: 18px;
    background: var(--surface);
    border: 1px solid var(--surface-bd);
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
}

.vb-score__label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--text-dim);
}

.vb-score__value {
    font-size: 26px;
    font-weight: 800;
    color: var(--text);
    transition: transform 0.18s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.vb-score--best .vb-score__value { color: #ffb02e; }

.vb-score__value.pop { transform: scale(1.25); }

/* ---------- Combo ---------- */
.vb-combo {
    height: 26px;
    font-size: 20px;
    font-weight: 900;
    letter-spacing: 1px;
    background: linear-gradient(90deg, #ff7eb3, #ffd86b);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    opacity: 0;
    transform: translateY(8px) scale(0.8);
}

.vb-combo.show { animation: comboPop 0.9s ease forwards; }

@keyframes comboPop {
    0%   { opacity: 0; transform: translateY(8px) scale(0.8); }
    25%  { opacity: 1; transform: translateY(0) scale(1.15); }
    70%  { opacity: 1; transform: translateY(0) scale(1); }
    100% { opacity: 0; transform: translateY(-6px) scale(1); }
}

/* ---------- Board ---------- */
.vb-stage {
    position: relative;
    padding: var(--pad);
    border-radius: 26px;
    background: var(--stage-bg);
    border: 1px solid var(--surface-bd);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.4), inset 0 0 30px rgba(120, 90, 255, 0.08);
}

.vb-board {
    display: grid;
    grid-template-columns: repeat(8, var(--cell));
    grid-template-rows: repeat(8, var(--cell));
    gap: var(--gap);
    padding: var(--pad);
    border-radius: 18px;
    background: var(--board-bg);
    box-shadow: inset 0 0 0 1px var(--surface-bd);
}

.cell {
    position: relative;
    overflow: hidden;
    width: var(--cell);
    height: var(--cell);
    border-radius: var(--radius);
    background: var(--cell-empty);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.025);
    transition: background 0.12s ease, box-shadow 0.12s ease;
}

.cell.filled {
    box-shadow: inset 0 3px 6px rgba(255, 255, 255, 0.35),
                inset 0 -3px 6px rgba(0, 0, 0, 0.25);
}

.cell.filled::after,
.pcell.filled::after,
#drag .dcell.filled::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0) 48%);
    pointer-events: none;
}

.cell.preview {
    opacity: 0.5;
    box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.6);
}

.cell.preview-bad {
    background: rgba(255, 70, 70, 0.4) !important;
    box-shadow: inset 0 0 0 2px rgba(255, 90, 90, 0.7) !important;
}

@keyframes explode {
    0%   { transform: scale(1);   filter: brightness(2.2); }
    45%  { transform: scale(1.18); filter: brightness(2.6); }
    100% { transform: scale(0); opacity: 0; filter: brightness(3); }
}

.cell.clearing {
    animation: explode 0.34s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
    z-index: 5;
}

/* ---------- Hold + Tray ---------- */
.vb-bottom {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    max-width: 470px;
}

.vb-hold {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    flex: 0 0 auto;
}
.vb-hold[hidden] { display: none; }

.vb-hold__label {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--text-dim);
}

.vb-hold__slot {
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 18px;
    border: 2px dashed var(--surface-bd);
    background: var(--surface);
    transition: border-color 0.2s ease, background 0.2s ease;
}
.vb-hold__slot.filled { border-style: solid; }

.vb-hold__hint {
    font-size: 30px;
    color: var(--text-dim);
    opacity: 0.5;
}

.vb-tray {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    align-items: center;
    justify-items: center;
    gap: 8px;
    min-height: 110px;
    padding: 6px 4px;
}

.piece-slot {
    display: grid;
    gap: 4px;
    padding: 6px;
    cursor: grab;
    transition: transform 0.18s ease, opacity 0.15s ease;
}
.piece-slot:active { cursor: grabbing; }
.piece-slot.dragging { opacity: 0.18; }

.pcell { width: var(--pcell); height: var(--pcell); }

.pcell.filled {
    position: relative;
    overflow: hidden;
    border-radius: 7px;
    box-shadow: inset 0 2px 3px rgba(255, 255, 255, 0.4),
                inset 0 -2px 3px rgba(0, 0, 0, 0.25);
}

/* ---------- Drag clone ---------- */
#drag {
    position: fixed;
    left: 0;
    top: 0;
    display: none;
    gap: var(--gap);
    pointer-events: none;
    z-index: 9999;
    will-change: transform;
    filter: drop-shadow(0 18px 30px rgba(0, 0, 0, 0.85));
}
#drag.active { display: grid; }

#drag .dcell { width: var(--cell); height: var(--cell); }

#drag .dcell.filled {
    position: relative;
    overflow: hidden;
    border-radius: var(--radius);
    box-shadow: inset 0 3px 6px rgba(255, 255, 255, 0.4),
                inset 0 -3px 6px rgba(0, 0, 0, 0.25);
}

/* ---------- Dugmad ---------- */
.vb-restart {
    padding: 11px 26px;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: 1px;
    color: #fff;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    background: linear-gradient(135deg, #7c4dff, #b14dff);
    box-shadow: 0 10px 25px rgba(124, 77, 255, 0.4);
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.vb-restart:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(124, 77, 255, 0.55); }
.vb-restart:active { transform: translateY(0); }
.vb-restart--big { padding: 14px 40px; font-size: 18px; }
.vb-restart small { font-weight: 500; opacity: 0.8; }

.vb-restart--ghost {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: none;
    color: rgba(255, 255, 255, 0.85);
}
.vb-restart--ghost:hover { background: rgba(255, 255, 255, 0.08); box-shadow: none; }

/* ---------- Power-upovi ---------- */
.vb-powerups {
    display: flex;
    gap: 10px;
}

.vb-pup {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    min-width: 64px;
    padding: 8px 14px;
    border-radius: 16px;
    color: var(--text);
    background: var(--surface);
    border: 1px solid var(--surface-bd);
    cursor: pointer;
    transition: transform 0.15s ease, background 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}
.vb-pup:hover { transform: translateY(-2px); }
.vb-pup:active { transform: translateY(0); }
.vb-pup__icon { font-size: 24px; line-height: 1; }
.vb-pup__cost { font-size: 11px; font-weight: 800; color: var(--text-dim); }
.vb-pup.cant-afford { opacity: 0.55; }

.vb-pup.active {
    background: linear-gradient(135deg, #7c4dff, #b14dff);
    color: #fff;
    box-shadow: 0 8px 22px rgba(124, 77, 255, 0.5);
}
.vb-pup.active .vb-pup__cost { color: rgba(255, 255, 255, 0.85); }

.vb-pup-hint {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 1px;
    color: #ffd86b;
    animation: hintPulse 1s ease-in-out infinite;
}
.vb-pup-hint[hidden] { display: none; }

@keyframes hintPulse { 0%, 100% { opacity: 0.6; } 50% { opacity: 1; } }

.vb-board.targeting {
    box-shadow: inset 0 0 0 1px var(--surface-bd), 0 0 0 2px rgba(255, 216, 107, 0.6), inset 0 0 30px rgba(255, 216, 107, 0.14);
}
.vb-board.targeting .cell { cursor: crosshair; }

/* ---------- Reklamni banner ---------- */
.vb-adbanner {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 360px;
    height: 56px;
    border-radius: 14px;
    border: 1px dashed var(--surface-bd);
    background: var(--surface);
    color: var(--text-dim);
    font-size: 12px;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* Rewarded reklama je SDK widget: .vasa-ad (Vasa.showRewardedAd). */

/* ---------- Overlay (game over + settings) ---------- */
.vb-overlay {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: rgba(5, 3, 12, 0.78);
    backdrop-filter: blur(8px);
    z-index: 10000;
    animation: fadeIn 0.3s ease;
}
.vb-overlay[hidden] { display: none; }

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.vb-overlay__card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    padding: 34px 44px;
    border-radius: 28px;
    text-align: center;
    color: #fff;
    background: linear-gradient(160deg, rgba(40, 28, 78, 0.96), rgba(18, 10, 38, 0.96));
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 30px 70px rgba(0, 0, 0, 0.7);
    animation: cardIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes cardIn {
    from { opacity: 0; transform: scale(0.8) translateY(20px); }
    to   { opacity: 1; transform: scale(1) translateY(0); }
}

.vb-overlay__card h2 {
    margin: 0 0 6px;
    font-size: 30px;
    font-weight: 900;
    letter-spacing: 2px;
    color: #ff7eb3;
}

.vb-overlay__label { margin: 8px 0 0; font-size: 13px; letter-spacing: 2px; color: rgba(255, 255, 255, 0.55); }
.vb-overlay__score { font-size: 56px; font-weight: 900; color: #ffd86b; line-height: 1; }
.vb-overlay__best { margin: 2px 0 14px; font-size: 14px; color: rgba(255, 255, 255, 0.7); }
.vb-overlay__best span { color: #ffd86b; font-weight: 700; }

.vb-overlay__stats {
    display: flex;
    gap: 10px;
    margin-bottom: 18px;
}
.vb-overlay__stats > div {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    min-width: 74px;
    padding: 10px 6px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.06);
}
.vb-overlay__stats span { font-size: 22px; font-weight: 800; color: #fff; }
.vb-overlay__stats small { font-size: 10px; letter-spacing: 1px; color: rgba(255, 255, 255, 0.5); text-transform: uppercase; }

.vb-overlay__coins { margin: 0 0 16px; font-size: 15px; color: rgba(255, 255, 255, 0.8); }
.vb-overlay__coins span { color: #ffd86b; font-weight: 800; }

.vb-overlay__badge {
    margin-bottom: 4px;
    padding: 5px 16px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 2px;
    color: #1a1030;
    background: linear-gradient(90deg, #ffd86b, #ff7eb3);
    box-shadow: 0 6px 20px rgba(255, 216, 107, 0.5);
    animation: badgePulse 1.2s ease-in-out infinite;
}
.vb-overlay__badge[hidden] { display: none; }

@keyframes badgePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.08); }
}

/* Prodavnica je SDK widget: .vasa-shop/.vasa-pack (Vasa.openShop). */

/* ---------- Misije ---------- */
.vb-missions { min-width: 320px; gap: 6px; }

.vb-streak {
    margin: 0 0 12px;
    font-size: 15px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.85);
}
.vb-streak span { color: #ffb02e; font-size: 18px; }

.vb-missions__list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
    margin-bottom: 16px;
}

.vb-mission {
    padding: 12px 14px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.06);
    text-align: left;
    transition: background 0.25s ease;
}
.vb-mission.done { background: rgba(66, 230, 149, 0.16); }

.vb-mission__top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 600;
}
.vb-mission__reward { color: #ffd86b; font-weight: 800; white-space: nowrap; }
.vb-mission.done .vb-mission__reward { color: #42e695; }

.vb-mission__bar {
    height: 7px;
    margin: 8px 0 4px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    overflow: hidden;
}
.vb-mission__bar i {
    display: block;
    height: 100%;
    border-radius: 999px;
    background: linear-gradient(90deg, #7c4dff, #b14dff);
    transition: width 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.vb-mission.done .vb-mission__bar i { background: linear-gradient(90deg, #42e695, #3bb2b8); }

.vb-mission__num {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.5);
    text-align: right;
}

/* ---------- Vodič (tutorial spotlight) ---------- */
.vb-tour { position: fixed; inset: 0; z-index: 10050; }
.vb-tour[hidden] { display: none; }
.vb-tour__spot {
    position: absolute;
    border-radius: 14px;
    box-shadow: 0 0 0 9999px rgba(5, 3, 12, 0.8);
    pointer-events: none;
    transition: left 0.25s ease, top 0.25s ease, width 0.25s ease, height 0.25s ease;
}
.vb-tour__pop {
    position: absolute;
    width: calc(100vw - 24px);
    max-width: 300px;
    padding: 16px 18px;
    border-radius: 16px;
    color: #fff;
    background: linear-gradient(160deg, #281c4e, #120a26);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
    transition: top 0.25s ease, left 0.25s ease;
}
.vb-tour__title { font-size: 16px; font-weight: 800; margin-bottom: 6px; color: #ffd86b; }
.vb-tour__text { font-size: 14px; color: #ccbff0; line-height: 1.5; }
.vb-tour__row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 14px; }
.vb-tour__count { font-size: 12px; color: rgba(255, 255, 255, 0.5); }
.vb-tour__skip { background: transparent; border: none; color: rgba(255, 255, 255, 0.6); cursor: pointer; font-size: 13px; font-weight: 600; }
.vb-tour__next { padding: 8px 18px; font-size: 14px; }

/* ---------- Toast ---------- */
.vb-toast {
    position: fixed;
    top: 74px;
    left: 50%;
    transform: translateX(-50%);
    padding: 10px 20px;
    border-radius: 999px;
    font-size: 14px;
    font-weight: 700;
    color: #1a1030;
    background: linear-gradient(90deg, #ffd86b, #ff7eb3);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
    z-index: 10001;
    pointer-events: none;
    animation: toastInOut 2.4s ease forwards;
}

@keyframes toastInOut {
    0%   { opacity: 0; transform: translate(-50%, -16px); }
    12%  { opacity: 1; transform: translate(-50%, 0); }
    85%  { opacity: 1; transform: translate(-50%, 0); }
    100% { opacity: 0; transform: translate(-50%, -16px); }
}

/* ---------- Settings panel ---------- */
.vb-settings { gap: 4px; min-width: 300px; }

.vb-setting {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    width: 100%;
    padding: 9px 2px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}
.vb-setting + .vb-setting { border-top: 1px solid rgba(255, 255, 255, 0.06); }
.vb-setting small { color: rgba(255, 255, 255, 0.45); font-weight: 500; }
.vb-setting__l { display: flex; align-items: center; gap: 12px; min-width: 0; }
.vb-setting__ic {
    flex: 0 0 auto;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
    color: #fff;
    background: linear-gradient(135deg, #7c4dff, #b14dff);
    box-shadow: 0 3px 10px rgba(124, 77, 255, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}
.vb-setting__ic .ic { width: 18px; height: 18px; }

.vb-toggle {
    -webkit-appearance: none;
    appearance: none;
    position: relative;
    flex: 0 0 auto;
    width: 48px;
    height: 26px;
    border: none;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    cursor: pointer;
    transition: background 0.2s ease;
}
.vb-toggle::after {
    content: '';
    position: absolute;
    top: 3px;
    left: 3px;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    transition: transform 0.2s ease;
}
.vb-toggle:checked { background: linear-gradient(90deg, #7c4dff, #b14dff); }
.vb-toggle:checked::after { transform: translateX(22px); }

.vb-select {
    -webkit-appearance: none;
    appearance: none;
    padding: 7px 14px;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    cursor: pointer;
}
.vb-select option { color: #1a1030; }

.vb-settings__hint {
    margin: 10px 0 4px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.45);
    max-width: 280px;
}

/* ---------- Nalog / auth ---------- */
[hidden] { display: none !important; }

.vb-auth { min-width: 300px; max-width: 340px; gap: 4px; }

.vb-auth__tabs { display: flex; gap: 8px; width: 100%; margin-bottom: 14px; }
.vb-auth__tab {
    flex: 1;
    padding: 9px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.15s ease;
}
.vb-auth__tab.is-active { background: linear-gradient(135deg, #7c4dff, #b14dff); border-color: transparent; }

.vb-auth__step { display: flex; flex-direction: column; gap: 10px; width: 100%; }

.vb-field { display: flex; flex-direction: column; gap: 5px; text-align: left; font-size: 13px; font-weight: 600; color: rgba(255, 255, 255, 0.7); }
.vb-field input, .vb-field select, .vb-auth__code {
    padding: 11px 12px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.06);
    color: #fff;
    font-size: 15px;
    outline: none;
}
.vb-field input:focus, .vb-field select:focus, .vb-auth__code:focus { border-color: #b14dff; }
.vb-field select option { color: #1a1030; }

.vb-auth__code {
    width: 100%;
    text-align: center;
    letter-spacing: 12px;
    font-size: 26px;
    font-weight: 800;
}

.vb-auth__hint { font-size: 13px; color: rgba(255, 255, 255, 0.65); margin: 0 0 4px; }
.vb-auth__err { color: #ff8a8a; font-size: 13px; margin: 2px 0 0; }
.vb-auth__row { display: flex; gap: 8px; }
.vb-auth__row .vb-restart { flex: 1; padding: 10px; }

/* Account/profil/avatar i kampanje su SDK widgeti (.vasa-acc/.vasa-prof/.vasa-camp).
   .vb-auth*/.vb-field gore ostaju — koristi ih admin strana (/admin/campaigns). */

/* ---------- Admin stranica ---------- */
.vb-admin {
    max-width: 720px;
    margin: 0 auto;
    padding: calc(20px + env(safe-area-inset-top)) 16px 40px;
    color: var(--text);
}
.vb-admin__head { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.vb-admin__head h1 { font-size: 22px; font-weight: 800; margin: 0; }
.vb-admin__back { color: var(--text-dim); text-decoration: none; font-weight: 600; }
.vb-admin__back:hover { color: var(--text); }
.vb-admin__denied { text-align: center; padding: 40px 0; color: var(--text-dim); display: flex; flex-direction: column; gap: 14px; align-items: center; }
.vb-admin__list { display: flex; flex-direction: column; gap: 12px; margin-top: 18px; }
.vb-admin__empty { color: var(--text-dim); padding: 20px 0; text-align: center; }
.vb-admin__card { padding: 14px 16px; border-radius: 14px; background: var(--surface); border: 1px solid var(--surface-bd); }
.vb-admin__card-top { display: flex; align-items: center; gap: 10px; font-size: 17px; }
.vb-admin__meta { font-size: 12px; color: var(--text-dim); margin-top: 4px; }
.vb-admin__desc { font-size: 13px; color: var(--text); opacity: 0.85; margin-top: 8px; }

.vb-tag { font-size: 11px; font-weight: 800; letter-spacing: 1px; padding: 2px 9px; border-radius: 999px; background: rgba(255,255,255,0.12); color: var(--text); }
.vb-tag--ok { background: rgba(66,230,149,0.2); color: #42e695; }
.vb-tag--off { background: rgba(255,255,255,0.1); color: var(--text-dim); }
.vb-tag--win { background: rgba(255,216,107,0.22); color: #ffd86b; }
.vb-tag--plain { background: rgba(124,77,255,0.2); color: #b69bff; }

.vb-admin__section { display: flex; align-items: center; gap: 8px; margin: 18px 0 4px; }
.vb-admin__count { font-size: 12px; color: var(--text-dim); }
.vb-admin__img { width: 100%; max-height: 150px; object-fit: cover; border-radius: 10px; margin-bottom: 10px; display: block; background: rgba(0,0,0,0.25); }
.vb-admin__win { margin-top: 8px; font-size: 13px; color: #ffd86b; }
.vb-admin__actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

.vb-mini {
    padding: 7px 12px;
    font-size: 13px;
    font-weight: 700;
    color: var(--text);
    border: 1px solid var(--surface-bd);
    border-radius: 10px;
    background: rgba(255,255,255,0.06);
    cursor: pointer;
    transition: background 0.15s ease;
}
.vb-mini:hover { background: rgba(255,255,255,0.12); }
.vb-mini--go { background: linear-gradient(135deg, #7c4dff, #b14dff); border-color: transparent; color: #fff; }
.vb-mini--danger { color: #ff8a8a; border-color: rgba(255,90,90,0.4); }
.vb-mini--danger:hover { background: rgba(255,90,90,0.15); }
.vb-mini:disabled { opacity: 0.4; cursor: default; }

/* Admin · korisnici (tabela + filter + stranicenje) */
.vb-admin__toolbar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 4px 0 16px; }
.vb-input {
    flex: 1;
    min-width: 220px;
    padding: 11px 14px;
    font-size: 14px;
    color: var(--text);
    background: var(--surface);
    border: 1px solid var(--surface-bd);
    border-radius: 12px;
    outline: none;
}
.vb-input:focus { border-color: #b14dff; }
.vb-utable-wrap { overflow-x: auto; border-radius: 14px; border: 1px solid var(--surface-bd); }
.vb-utable { width: 100%; border-collapse: collapse; font-size: 14px; background: var(--surface); }
.vb-utable th, .vb-utable td { text-align: left; padding: 11px 14px; white-space: nowrap; }
.vb-utable thead th {
    font-size: 11px; font-weight: 800; letter-spacing: 0.6px; text-transform: uppercase;
    color: var(--text-dim); border-bottom: 1px solid var(--surface-bd); background: rgba(255,255,255,0.03);
}
.vb-utable tbody tr { border-bottom: 1px solid rgba(255,255,255,0.06); }
.vb-utable tbody tr:last-child { border-bottom: none; }
.vb-utable tbody tr:hover { background: rgba(255,255,255,0.04); }
.vb-utable__date { color: var(--text-dim); font-size: 13px; }
.vb-utable__empty { text-align: center; color: var(--text-dim); padding: 24px 0; }
.vb-admin__pager { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 16px; }

/* ---------- Aurora ---------- */
body::before {
    content: '';
    position: fixed;
    inset: -20%;
    z-index: -1;
    background: radial-gradient(circle at 28% 30%, var(--aura1), transparent 42%),
                radial-gradient(circle at 72% 68%, var(--aura2), transparent 42%),
                radial-gradient(circle at 50% 95%, var(--aura3), transparent 45%);
    filter: blur(46px);
    animation: drift 20s ease-in-out infinite alternate;
}

@keyframes drift {
    from { transform: translate(-4%, -3%) scale(1); }
    to   { transform: translate(5%, 4%) scale(1.18); }
}

/* ---------- Trešenje ---------- */
.vb-stage.shake { animation: shake 0.36s ease; }

@keyframes shake {
    0%, 100% { transform: translate(0, 0); }
    20% { transform: translate(-5px, 3px); }
    40% { transform: translate(6px, -3px); }
    60% { transform: translate(-4px, 2px); }
    80% { transform: translate(3px, -2px); }
}

/* ---------- Leteći poeni ---------- */
.vb-pop {
    position: absolute;
    font-size: 30px;
    font-weight: 900;
    color: #ffd86b;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7), 0 0 18px rgba(255, 216, 107, 0.6);
    pointer-events: none;
    z-index: 20;
    animation: floatUp 0.95s ease forwards;
}

@keyframes floatUp {
    0%   { opacity: 0; transform: translate(-50%, -50%) scale(0.5); }
    25%  { opacity: 1; transform: translate(-50%, -80%) scale(1.15); }
    100% { opacity: 0; transform: translate(-50%, -190%) scale(1); }
}

/* ---------- Čestice ---------- */
.vb-particle {
    position: absolute;
    width: 11px;
    height: 11px;
    border-radius: 3px;
    pointer-events: none;
    z-index: 15;
    animation: burst 0.6s cubic-bezier(0.2, 0.7, 0.3, 1) forwards;
}

@keyframes burst {
    0%   { opacity: 1; }
    100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(0.2) rotate(var(--rot)); }
}

/* ---------- Mali ekrani ---------- */
@media (max-width: 430px) {
    :root { --cell: 38px; --gap: 4px; }
    .vb-app { gap: 10px; }
    .vb-score { padding: 7px 8px; }
    .vb-score__value { font-size: 22px; }
    .vb-combo { height: 22px; font-size: 18px; }
    .vb-tray { min-height: 96px; padding: 4px; }
    .vb-pup { padding: 6px 12px; }
    .vb-pup__icon { font-size: 22px; }
    .vb-adbanner { height: 48px; }
    .vb-pop { font-size: 26px; }
    .vb-hold__slot { width: 84px; height: 84px; }
}

/* ----- Niski ekrani: sve mora da stane bez skrola ----- */
@media (max-height: 760px) {
    :root { --cell: 33px; --pcell: 22px; }
    .vb-tray { min-height: 80px; }
}

/* iPhone SE i slično (~667px) */
@media (max-height: 690px) {
    :root { --cell: 29px; --pcell: 18px; }
    .vb-app { gap: 7px; padding-top: calc(8px + env(safe-area-inset-top)); padding-bottom: calc(10px + env(safe-area-inset-bottom)); }
    .vb-iconbtn { height: 40px; }
    .vb-score { padding: 5px 8px; }
    .vb-score__value { font-size: 19px; }
    .vb-score__label { font-size: 10px; }
    .vb-combo { height: 16px; font-size: 15px; }
    .vb-tray { min-height: 64px; padding: 2px; }
    .vb-pup { padding: 4px 11px; }
    .vb-pup__icon { font-size: 19px; }
    .vb-pup__cost { font-size: 10px; }
    .vb-adbanner { height: 40px; font-size: 11px; }
}

/* vrlo niski ekrani */
@media (max-height: 600px) {
    :root { --cell: 26px; --pcell: 16px; }
    .vb-tray { min-height: 56px; }
    .vb-adbanner { height: 34px; }
}
