/* מסע החשבון – עיצוב המשחקים */
.g-root{position:relative;overflow:hidden;max-width:100%;margin:1rem 0}
.g-root:fullscreen{background:var(--bg,#fffaf0);overflow:auto;padding:1.2rem;--fs:22px;font-size:1.25rem}
.g-root::backdrop{background:var(--bg,#fffaf0)}
.g-bar{display:flex;flex-wrap:wrap;gap:.5rem 1rem;align-items:center;justify-content:space-between;margin-bottom:.6rem}
.g-tools{display:flex;gap:.5rem;align-items:center;flex-wrap:wrap}
.g-root .lv button{min-height:3rem}
.g-modes button[aria-pressed=true]{background:#f76707;border-color:#f76707;color:#fff}
.g-card{background:#fff;border:3px solid var(--line,#e3dcff);border-radius:22px;padding:1rem 1.1rem;box-shadow:0 6px 0 #e9e3ff;margin:.6rem 0}
.g-center{text-align:center}
.g-h{margin:.3rem 0 .6rem;font-size:1.4rem;color:var(--pri,#5b3cc4)}
.g-emoji{font-size:3.4rem;line-height:1.1}
.g-big{font-size:1.5rem;font-weight:800}
.g-small{font-size:.92em;color:var(--mut,#4a4a68)}
.g-ask{font-weight:700;margin:.2rem 0 .6rem}
.g-q{font-size:clamp(1.5rem,6.5vw,2.4rem);font-weight:800;text-align:center;margin:.6rem 0 1rem;color:#1d1b3a;overflow-wrap:anywhere}
.g-q .math{white-space:nowrap}
.g-root .opts{justify-content:center}
.g-root .opts button{min-height:3.4rem;min-width:5.5rem;font-size:1.3rem}
.g-root .opts button:disabled{cursor:default;opacity:1}
.g-root .opts button:focus-visible,.g-root button:focus-visible,.g-linebox:focus-visible,.g-root input:focus-visible{outline:4px solid #f59f00;outline-offset:2px}
.g-fb{margin-top:.8rem;padding:.7rem .9rem;border-radius:14px;line-height:1.7;display:none}
.g-fb.ok{background:var(--okb,#e6f7ea);border:2px solid var(--ok,#1f7a3a)}
.g-fb.no{background:var(--nob,#fde8e6);border:2px solid var(--no,#b3261e)}
.g-fb.info{background:#fff9db;border:2px solid #fab005}
.g-fb p{margin:.4rem 0 0}
.g-steps{margin:.4rem 0 0;padding-inline-start:1.6rem}
.g-steps li{margin:.15rem 0}
.g-row{display:flex;flex-wrap:wrap;gap:.6rem;justify-content:center;margin-top:.8rem}
.g-stats{display:flex;flex-wrap:wrap;gap:.5rem;align-items:center;justify-content:center;margin:.3rem 0}
.g-timer{border-color:#ff922b}
/* מסלול */
.g-track{background:linear-gradient(#e7f5ff,#d0ebff);border-radius:18px;padding:.2rem .4rem;border:2px solid #a5d8ff}
.g-tracksvg{width:100%;height:auto;display:block;max-height:110px}
.g-road{fill:#495057}.g-dash{stroke:#ffd43b;stroke-width:4;stroke-linecap:round}
.g-rk{transition:transform .6s cubic-bezier(.3,1.4,.6,1)}
/* סדר פעולות */
.g-expr{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:.35rem;font-size:clamp(1.4rem,6vw,2.1rem);font-weight:800;margin:.8rem 0;direction:ltr}
.g-num,.g-opb{font:inherit;min-width:3.2rem;min-height:3.2rem;border-radius:14px;border:3px solid #b197fc;background:#f8f0fc;color:#1d1b3a;cursor:pointer;padding:0 .4rem}
.g-num.on{background:#d0bfff;border-color:#5b3cc4}
.g-opb{background:#fff9db;border-color:#fab005;border-style:dashed;min-width:3rem}
.g-num:disabled,.g-opb:disabled{cursor:default}
.g-par{color:#e8590c;font-size:1.25em}
.g-op{color:#5b3cc4;padding:0 .1rem}
.g-tgt{background:#ebfbee;border:3px solid #2b8a3e;border-radius:14px;padding:.1rem .6rem}
.g-n{padding:0 .1rem}
.g-eqt{white-space:nowrap;display:inline-flex;align-items:center;gap:.3rem}
/* ציר */
.g-linebox{background:#f3fbf5;border:2px solid #b2f2bb;border-radius:18px;padding:.2rem;margin:.4rem 0;touch-action:manipulation}
.g-linesvg{width:100%;height:auto;display:block;cursor:pointer}
.g-ax{stroke:#1d1b3a;stroke-width:4;stroke-linecap:round}.g-axh{fill:#1d1b3a}
.g-tick{stroke:#1d1b3a;stroke-width:3}
.g-lbl{font-size:24px;font-weight:800;fill:#1d1b3a;font-family:inherit}
.g-qm{fill:#e03131}
.g-pt{fill:#e03131;stroke:#fff;stroke-width:3}
.g-arc{fill:none;stroke:#2b8a3e;stroke-width:3;stroke-dasharray:6 5;opacity:0;transition:opacity .3s}
.g-arc.on{opacity:1}
.g-frog{transition:transform .45s ease}
.g-hop.go{animation:g-hop .45s ease}
@keyframes g-hop{50%{transform:translateY(-26px)}}
.g-mv button{min-width:4rem;font-size:1.4rem}
.fr{display:inline-flex;flex-direction:column;vertical-align:middle;text-align:center;font-size:.8em;line-height:1.05;margin:0 .1em}
.fr>span:first-child{border-bottom:2px solid currentColor;padding:0 .15em}
/* דו־קרב */
.g-duel{display:flex;align-items:stretch;justify-content:center;gap:.5rem;margin:.8rem 0;direction:ltr}
.g-side{flex:1 1 0;min-width:0;background:linear-gradient(#f3f0ff,#fff);border:3px solid #d0bfff;border-radius:18px;padding:.7rem .4rem;text-align:center;font-size:clamp(1.05rem,4.6vw,1.9rem);font-weight:800;display:flex;align-items:center;justify-content:center;flex-wrap:wrap;gap:.2rem;overflow-wrap:anywhere}
.g-vs{flex:0 0 auto;align-self:center;width:3.2rem;height:3.2rem;border-radius:50%;background:#ffd43b;display:flex;align-items:center;justify-content:center;font-size:1.8rem;font-weight:900;direction:ltr}
.g-vs.ok{background:#b2f2bb}.g-vs.no{background:#ffc9c9}
.g-syms button{min-width:5rem;font-size:2rem!important}
.g-ans{font-weight:900;font-size:1.2em}
.g-names{display:grid;gap:.7rem;margin:.8rem 0}
.g-names label{display:flex;flex-direction:column;gap:.3rem;font-weight:700}
.g-names input{font:inherit;font-size:1.15rem;padding:.6rem .8rem;border-radius:12px;border:3px solid #d0bfff;min-height:3rem;max-width:100%}
.g-teams{display:flex;gap:.6rem;justify-content:space-between;flex-wrap:wrap}
.g-team{flex:1 1 9rem;border-radius:18px;padding:.5rem .8rem;font-weight:800;font-size:1.3rem;display:flex;align-items:center;gap:.4rem;justify-content:space-between;color:#fff}
.g-team.red{background:#e03131}.g-team.blue{background:#1971c2}
.g-pts{font-size:1.8rem}
.g-tug{display:flex;align-items:center;gap:.4rem;margin:.6rem 0}
.g-rope{position:relative;flex:1;height:14px;border-radius:7px;background:linear-gradient(90deg,#74c0fc 0 50%,#ff8787 50% 100%)}
.g-knot{position:absolute;top:50%;transform:translate(-50%,-50%);font-size:1.8rem;transition:left .6s ease}
.g-who .btn.red{background:#e03131;box-shadow:0 4px 0 #a61e1e}.g-who .btn.blue{background:#1971c2;box-shadow:0 4px 0 #0b4f8a}
.g-who .btn[aria-pressed=true]{outline:4px solid #ffd43b;outline-offset:2px}
.g-who .btn:disabled{opacity:.45}
.big-ui .g-side{font-size:clamp(1.3rem,5.5vw,2.6rem)}
.big-ui .g-ask{font-size:1.25rem}
/* קונפטי */
.g-confetti{position:absolute;inset:0;pointer-events:none;overflow:hidden;z-index:5}
.g-confetti span{position:absolute;top:-2.5rem;font-size:1.8rem;animation:g-fall linear forwards}
@keyframes g-fall{to{transform:translateY(110vh) rotate(540deg)}}
@media (max-width:480px){.g-expr{gap:.2rem}.g-num,.g-opb{min-width:48px;min-height:48px}.g-card{padding:.8rem .7rem}.g-root .opts button{min-width:4.6rem;font-size:1.15rem}.g-vs{width:2.6rem;height:2.6rem;font-size:1.5rem}.g-bar{justify-content:center}}
@media (prefers-reduced-motion:reduce){.g-confetti{display:none}.g-rk,.g-frog,.g-knot{transition:none}.g-hop.go{animation:none}}
@media print{.g-tools,.g-row,.g-confetti{display:none!important}}
