@font-face{font-family:"Noto Sans Hebrew";src:url("fonts/noto-hebrew-hebrew.woff2") format("woff2");font-weight:500 800;font-display:swap;unicode-range:U+0307-0308,U+0590-05FF,U+200C-2010,U+20AA,U+25CC,U+FB1D-FB4F}
@font-face{font-family:"Noto Sans Hebrew";src:url("fonts/noto-hebrew-latin.woff2") format("woff2");font-weight:500 800;font-display:swap;unicode-range:U+0000-00FF,U+2000-206F,U+2212}
:root{--sat:env(safe-area-inset-top,0px);--sab:env(safe-area-inset-bottom,0px);--ink:#3b2410;--wood:#8a4a12}
*{box-sizing:border-box;-webkit-tap-highlight-color:transparent;-webkit-user-select:none;user-select:none}
html,body{margin:0;height:100%;overflow:hidden;background:#3d7fc4;font-family:"Noto Sans Hebrew",Arial,sans-serif;color:var(--ink);overscroll-behavior:none}
button{font-family:inherit;border:0;cursor:pointer;touch-action:manipulation;color:inherit}
input{font-family:inherit;-webkit-user-select:text;user-select:text}
#app{position:fixed;inset:0;overflow:hidden}
.screen{position:absolute;inset:0;display:none;align-items:center;justify-content:center;flex-direction:column;overflow:hidden}
.screen.active{display:flex}
.bg{position:absolute;inset:0;background:url(img/hall.webp?v=b3) center/cover no-repeat}
.bg.dim::after{content:"";position:absolute;inset:0;background:rgba(255,250,230,.18)}
.big-btn{position:relative;z-index:3;background:linear-gradient(#ffe066,#ffb300);color:#5a3200;font-size:26px;font-weight:800;padding:12px 34px;border-radius:40px;box-shadow:0 6px 0 #c77d00,0 10px 22px rgba(90,50,0,.3),inset 0 2px 0 rgba(255,255,255,.7);min-height:60px;line-height:1.3}
.big-btn:active{transform:translateY(4px);box-shadow:0 2px 0 #c77d00}
.big-btn:disabled{filter:grayscale(.7) opacity(.55)}
.big-btn.small{font-size:19px;padding:9px 20px;min-height:50px}
.big-btn.alt{background:linear-gradient(#a8e1ff,#4fb3ff);color:#0c3a66;box-shadow:0 6px 0 #2a7fc4,inset 0 2px 0 rgba(255,255,255,.7)}
.small-btn{background:rgba(255,255,255,.92);font-size:17px;font-weight:700;padding:9px 18px;border-radius:24px;box-shadow:0 3px 0 rgba(0,0,0,.14);margin-top:10px}
.pulse{animation:pulse 1.6s ease-in-out infinite}
@keyframes pulse{50%{transform:scale(1.06)}}
.card{position:relative;z-index:2;background:rgba(255,253,245,.95);border-radius:28px;padding:18px 16px;width:min(92vw,460px);max-height:calc(100% - 90px - var(--sat));overflow:auto;text-align:center;box-shadow:0 12px 40px rgba(20,60,20,.3);margin-top:calc(var(--sat) + 40px)}
.card.wide{width:min(94vw,620px)}
.card h2{margin:0 0 10px;font-size:24px;line-height:1.55;color:#6b3a10}
.say{background:#fff1b8;border-radius:50%;width:42px;height:42px;font-size:21px;vertical-align:middle;box-shadow:0 2px 0 #e0c060;padding:0}
.row{display:flex;gap:10px;justify-content:center;flex-wrap:wrap}
/* title */
#s-title{background:#9fd6ff;justify-content:flex-end}
.splash-wrap{position:absolute;inset:0;overflow:hidden;animation:zoomIn 2.4s cubic-bezier(.2,.8,.2,1) both}
.splash{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:50% 70%}
.scene-box{position:absolute;pointer-events:none}
.scene-box img{-webkit-user-drag:none;will-change:transform,opacity}
@keyframes zoomIn{from{transform:scale(1.12)}to{transform:none}}
.splash-fade{position:absolute;left:0;right:0;top:0;height:42%;background:linear-gradient(rgba(10,60,110,.35),rgba(10,60,110,0))}
.t-head{position:absolute;top:calc(var(--sat) + 4vh);left:0;right:0;text-align:center;z-index:2;animation:drop .9s .2s cubic-bezier(.3,1.5,.5,1) both}
@keyframes drop{from{transform:translateY(-120%);opacity:0}}
.t-world{display:inline-block;font-size:17px;font-weight:800;color:#fff;background:rgba(40,110,40,.75);padding:3px 16px 5px;border-radius:999px;border:2px solid rgba(255,255,255,.8);margin-bottom:6px}
.t-title{margin:0;font-size:min(15vw,66px);line-height:1.12;font-weight:800;color:#ffd21f;-webkit-text-stroke:2px #7a3c00;paint-order:stroke fill;text-shadow:0 4px 0 #7a3c00,0 8px 16px rgba(0,0,0,.45)}
#t-start{margin-bottom:calc(var(--sab) + 9vh)}
.noa-credit{position:absolute;left:0;right:0;bottom:calc(var(--sab) + 6px);margin:0;text-align:center;font-size:12px;font-weight:700;color:rgba(255,255,255,.95);text-shadow:0 1px 3px rgba(0,0,0,.7);pointer-events:none;z-index:5}
/* mode */
.stars-total{font-size:19px;font-weight:800;color:#a05a00;margin:-4px 0 10px}
.menu-grid{display:flex;flex-direction:column;gap:12px}
.mode-btn{background:linear-gradient(#fffaf0,#ffe6b8);border-radius:22px;padding:12px 10px;display:grid;grid-template-columns:64px 1fr;grid-template-rows:auto auto;align-items:center;text-align:right;column-gap:10px;box-shadow:0 5px 0 #dfae63,0 8px 16px rgba(0,0,0,.1);min-height:86px}
.mode-btn:active{transform:translateY(3px)}
.mode-btn .ico{grid-row:1/3;font-size:38px;text-align:center}
.mode-btn .mt{font-size:23px;font-weight:800;color:#6b3a10}
.mode-btn .ms{font-size:15px;font-weight:600;color:#8a6a4a}
/* pick */
.pick-players{display:flex;flex-direction:column;gap:12px;margin-bottom:14px}
.pl-box{background:#fff4dc;border-radius:20px;padding:10px 10px 12px}
.pl-t{font-weight:800;font-size:18px;color:#8a5a2a;margin-bottom:6px}
.pl-box input{width:min(100%,280px);font-size:22px;font-weight:700;text-align:center;padding:8px 10px;border-radius:14px;border:3px solid #f0c27a;background:#fff;color:#3b2410;outline:none}
.pl-box input:focus{border-color:#ff9f1a}
.heroes{display:flex;gap:12px;justify-content:center;margin-top:10px}
.hero{background:#fff;border-radius:20px;padding:6px 8px 4px;width:122px;border:4px solid transparent;box-shadow:0 4px 0 #e6c78f;display:flex;flex-direction:column;align-items:center}
.hero img{height:130px;width:auto;display:block;filter:drop-shadow(0 6px 6px rgba(0,0,0,.2))}
.hero span{font-size:20px;font-weight:800}
.hero.b span{color:#1d5bd6}.hero.g span{color:#e0408a}
.hero.sel.b{border-color:#2f7cff;background:#e8f1ff}.hero.sel.g{border-color:#ff5aa5;background:#ffeaf4}
.hero.sel{transform:scale(1.04)}
.split-pick .hero img{height:96px}.split-pick .hero{width:104px}
/* level */
.lvl-list{display:flex;flex-direction:column;gap:10px}
.lvl-btn{position:relative;display:grid;grid-template-columns:1fr auto;grid-template-rows:auto auto;text-align:right;background:linear-gradient(#fffaf0,#ffe6b8);border-radius:20px;padding:10px 14px;box-shadow:0 5px 0 #dfae63;min-height:78px;align-items:center}
.lvl-btn:active{transform:translateY(3px)}
.lvl-btn b{font-size:24px;color:#6b3a10}.lvl-btn span{font-size:16px;font-weight:700;color:#8a6a4a}
.lv-ic{grid-column:2;grid-row:1/3;display:flex;gap:2px;align-items:center}
.lv-ic img{height:46px}
.lvl-btn .done{position:absolute;top:-6px;left:-4px;font-style:normal;font-size:24px}

/* end */
.end-wrap{position:relative;z-index:2;text-align:center;display:flex;flex-direction:column;align-items:center;gap:8px;padding:20px;background:rgba(255,253,243,.93);border-radius:28px;width:min(92vw,440px);box-shadow:0 12px 40px rgba(0,0,0,.3)}
.end-chars{display:flex;gap:10px;align-items:flex-end;justify-content:center}
.end-chars img{height:150px;filter:drop-shadow(0 8px 8px rgba(0,0,0,.3));animation:bob 1.6s ease-in-out infinite}
.end-chars img.lose{height:110px;opacity:.85;animation:none}
@keyframes bob{50%{transform:translateY(-8px)}}
#end-h{margin:4px 0 0;font-size:28px;line-height:1.45;color:#1f7a2a}
.end-sub{font-size:20px;font-weight:700;color:#6b3a10;line-height:1.5}
/* cert */
.cert-wrap{position:relative;z-index:2;display:flex;flex-direction:column;align-items:center;gap:10px;padding:calc(var(--sat) + 60px) 12px calc(var(--sab) + 12px);height:100%;width:100%;justify-content:center}
.cert-img{max-width:min(92vw,440px);max-height:calc(100% - 210px);border-radius:16px;box-shadow:0 10px 30px rgba(0,0,0,.4);background:#fffdf7;min-height:120px}
.cert-btns{display:flex;gap:10px}
.save-btn{font-size:28px;padding:10px 46px}
.sheet{position:fixed;inset:0;background:rgba(0,0,0,.5);z-index:80;display:none;align-items:flex-end;justify-content:center}
.sheet.on{display:flex}
.sheet-card{position:relative;background:#fff;border-radius:28px 28px 0 0;padding:20px 16px calc(var(--sab) + 22px);width:min(100%,520px);display:flex;flex-direction:column;gap:12px;align-items:center}
.sheet-x{position:absolute;top:10px;left:12px;width:40px;height:40px;border-radius:50%;background:#eee;font-size:20px}
.sheet-prev{max-height:38vh;max-width:80%;border-radius:12px;box-shadow:0 4px 14px rgba(0,0,0,.2)}
.sh-btn{width:100%;font-size:22px;font-weight:800;padding:14px;border-radius:20px;display:flex;gap:10px;align-items:center;justify-content:center}
.sh-btn.save{background:#e8f3ff;color:#0c3a66}
.sh-btn.wa{background:#25d366;color:#fff}
/* back + ask */
.noa-back{position:fixed;z-index:72;top:calc(var(--sat) + 10px);right:10px;display:none;width:44px;height:44px;padding:0;border-radius:50%;border:3px solid #fff;background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4.5 12h14M12.5 5.5 19 12l-6.5 6.5'/%3E%3C/svg%3E") center/22px 22px no-repeat,radial-gradient(circle at 32% 26%,rgba(255,255,255,.95) 0 8%,rgba(255,255,255,0) 28%),linear-gradient(180deg,#5d74d6 0%,#34489a 55%,#1d2b6b 100%);box-shadow:0 5px 14px rgba(20,30,110,.35),inset 0 -4px 0 rgba(10,20,90,.28)}
.noa-back.on{display:block}
.noa-back:active{transform:scale(.92)}
body.split-game .noa-back{top:var(--midy,50%);right:6px;margin-top:-22px}
.ask{position:fixed;inset:0;z-index:90;background:rgba(0,0,0,.45);display:none;align-items:center;justify-content:center}
.ask.on{display:flex}
.ask-card{background:#fff;border-radius:26px;padding:18px 22px;text-align:center;width:min(84vw,330px);box-shadow:0 10px 30px rgba(0,0,0,.35)}
.ask-ic{font-size:40px}
.ask-q{font-size:22px;font-weight:800;line-height:1.5;margin:6px 0 12px;color:#3b2410}
.ask-row{display:flex;gap:12px;justify-content:center}
.ask-row button{font-size:22px;font-weight:800;padding:10px 26px;border-radius:20px}
.ask-yes{background:linear-gradient(#ffe066,#ffb300);color:#5a3200;box-shadow:0 4px 0 #c77d00}
.ask-no{background:#e8f3ff;color:#0c3a66;box-shadow:0 4px 0 #9fc3e8}
@media (min-width:700px){.view.single{left:50%;right:auto;width:520px;margin-left:-260px;box-shadow:0 0 60px rgba(0,0,0,.5)}}

/* ---- two phones ---- */
.lobby-card .sh-btn{margin:6px 0 4px}
.code-big{font-size:60px;font-weight:800;letter-spacing:12px;color:#6b3a10;margin:0 0 6px;line-height:1.1;font-family:Arial,sans-serif}
.code-big.in{display:flex;gap:8px;justify-content:center;letter-spacing:0}
.code-big.in span{width:58px;height:70px;border-radius:16px;background:#fff3c4;border:3px solid #f0c27a;display:flex;align-items:center;justify-content:center}
.keypad{display:grid;grid-template-columns:repeat(3,76px);gap:9px;justify-content:center;margin:10px 0 4px}
.keypad button{height:56px;border-radius:16px;background:#fff;font-size:28px;font-weight:800;color:#3b2410;box-shadow:0 4px 0 #e0c48f;font-family:Arial,sans-serif}
.keypad button:active{transform:translateY(3px);box-shadow:0 1px 0 #e0c48f}
.keypad button[data-k="✓"]{background:linear-gradient(#ffe066,#ffb300);color:#5a3200}
.hint{font-size:16px;font-weight:600;color:#6a5a4a;line-height:1.6;margin-top:4px}
.status{margin:10px 0 6px;font-weight:800;font-size:18px;display:flex;gap:8px;justify-content:center;align-items:center;line-height:1.5;color:#3b2410}
.status:empty{display:none}
.status .dot{flex:none;width:12px;height:12px;border-radius:50%;background:#f0b400;animation:npulse 1s infinite}
.status.ok .dot{background:#2bb24c;animation:none}.status.bad .dot{background:#e5484d;animation:none}
@keyframes npulse{50%{opacity:.3}}
.vs{display:flex;align-items:flex-end;justify-content:center;gap:14px;font-weight:800;font-size:19px;color:#3b2410}
.vs:empty{display:none}
.vs .p{display:flex;flex-direction:column;align-items:center;gap:2px}
.vs img{height:110px;filter:drop-shadow(0 5px 5px rgba(0,0,0,.2))}
.vs .x{font-size:32px;align-self:center}
.lobby-card .big-btn{margin-top:10px}
.fail p{font-weight:700;line-height:1.6}
.net-ic{animation:npulse 1.2s infinite}
.vopp{position:absolute;z-index:7;display:flex;align-items:center;gap:5px;background:rgba(255,255,255,.92);border-radius:999px;padding:2px 12px 2px 6px;font-size:17px;box-shadow:0 2px 6px rgba(0,0,0,.15);font-weight:800;color:#6b3a10;pointer-events:none;max-width:230px;white-space:nowrap;overflow:hidden}
.vopp img{height:34px;width:auto}
.vopp .on{direction:ltr;color:#a05a00}


/* ===== v2: rules screen, who-is-who, status line, turn banners ===== */
.rules-card{padding:16px 14px 18px}
.rules-card h2{margin-bottom:8px}
.who-row{display:flex;flex-wrap:wrap;gap:8px;justify-content:center;margin:2px 0 10px}
.who{display:flex;align-items:center;gap:6px;background:#fff;border-radius:999px;padding:4px 12px 4px 8px;border:3px solid #ddd;box-shadow:0 3px 0 rgba(0,0,0,.08);font-size:20px;font-weight:800}
.who.mx{border-color:#2f7cff;color:#1d4fb8}.who.mo{border-color:#ff5aa5;color:#c02a75}
.who .wav{height:46px;width:auto;margin-top:-10px;filter:drop-shadow(0 3px 3px rgba(0,0,0,.2))}
.who .wav.ph{font-size:28px;height:auto;margin:0}
.who b{max-width:120px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.who .eq{font-size:22px;color:#6b3a10}
.who .ipc{height:38px;width:38px}
.ipc{height:30px;width:30px;object-fit:contain;vertical-align:middle;filter:drop-shadow(0 2px 2px rgba(0,0,0,.25))}
.who-row.small .who{font-size:18px}.who-row.small .wav{height:40px}
#mark-assign{min-height:58px;margin:4px 0 12px}
.rules-list{list-style:none;margin:6px 0 14px;padding:0;display:flex;flex-direction:column;gap:8px;text-align:right}
.rules-list li{display:flex;align-items:center;gap:10px;background:#fff6e0;border-radius:18px;padding:8px 10px;font-size:19px;font-weight:700;line-height:1.5;color:#4a2a0a;animation:rin .45s both}
@keyframes rin{from{transform:translateY(12px);opacity:0}}
.rules-list .ric{flex:0 0 40px;height:40px;border-radius:50%;background:#fff;display:flex;align-items:center;justify-content:center;font-size:24px;box-shadow:0 2px 0 #ecd29a}
.rules-list li:nth-child(3){background:#ffeede}
#rules-go{font-size:30px;padding:12px 48px}
.rules-ov{position:fixed;inset:0;z-index:70;background:rgba(20,30,10,.55);display:none;align-items:center;justify-content:center;padding:calc(var(--sat) + 60px) 10px calc(var(--sab) + 10px)}
.rules-ov.on{display:flex}
.ov-card{background:rgba(255,253,245,.98);border-radius:26px;width:min(94vw,560px);max-height:100%;overflow:auto;text-align:center;box-shadow:0 12px 40px rgba(0,0,0,.4);animation:pin .3s cubic-bezier(.3,1.5,.5,1)}
.ov-card h2{margin:0 0 8px;font-size:24px;color:#6b3a10}
.ov-card .rules-list li{font-size:18px}
.noa-help{position:fixed;z-index:72;top:calc(var(--sat) + 10px);right:62px;display:none;width:44px;height:44px;padding:0;border-radius:50%;border:3px solid #fff;font-size:24px;font-weight:800;color:#fff;line-height:1;background:radial-gradient(circle at 32% 26%,rgba(255,255,255,.9) 0 8%,rgba(255,255,255,0) 28%),linear-gradient(180deg,#ffb84d 0%,#f08a00 55%,#b85f00 100%);box-shadow:0 5px 14px rgba(110,60,0,.35),inset 0 -4px 0 rgba(90,40,0,.28);text-shadow:0 1px 2px rgba(0,0,0,.35)}
.noa-help.on{display:block}
.noa-help:active{transform:scale(.92)}

