:root{--vw:1vw;--vh:1vh;--red:#b3262b;--cream:#fff8e8;--ink:#2b1a12;--felt:#7a1a1f;--wood1:#a8693a;--wood2:#7d4624;--gold:#ffd84a;--green:#4fc24a;--sat:env(safe-area-inset-top,0px);--sab:env(safe-area-inset-bottom,0px)}
*{box-sizing:border-box;-webkit-tap-highlight-color:transparent;-webkit-touch-callout:none;user-select:none;-webkit-user-select:none}
input,textarea{user-select:text;-webkit-user-select:text}
html,body{margin:0;height:100%;overflow:hidden;font-family:"Segoe UI",Arial,"Noto Sans Hebrew",sans-serif;color:var(--ink);background:#4a0f13;overscroll-behavior:none;touch-action:manipulation}
body{background:radial-gradient(ellipse at 50% 30%,#9a2229 0,#6d1519 60%,#3d0a0d 100%)}
body:before{content:"";position:fixed;inset:0;opacity:.13;background:repeating-linear-gradient(45deg,#fff 0 14px,transparent 14px 28px),repeating-linear-gradient(-45deg,#fff 0 14px,transparent 14px 28px);pointer-events:none}
#app{position:fixed;inset:0;max-width:760px;margin:0 auto;overflow:hidden;padding-top:var(--sat);padding-bottom:var(--sab)}
.ico{width:1.25em;height:1.25em;vertical-align:middle;flex:none}
button{font:inherit;cursor:pointer;border:0;border-radius:16px;padding:11px 16px;background:linear-gradient(#fff,#f1e6cc);color:var(--ink);font-weight:800;box-shadow:0 4px 0 #b9a77d,0 6px 8px rgba(0,0,0,.3);display:inline-flex;align-items:center;justify-content:center;gap:7px;transition:transform .08s,box-shadow .08s}
button:active{transform:translateY(3px);box-shadow:0 1px 0 #b9a77d}
button.primary{background:linear-gradient(#ffe46b,#ffc928);box-shadow:0 4px 0 #b48500,0 6px 8px rgba(0,0,0,.3)}
button.primary:active{box-shadow:0 1px 0 #b48500}
button.good{background:linear-gradient(#8fe06a,#4fc24a);box-shadow:0 4px 0 #2b7d28,0 6px 8px rgba(0,0,0,.3)}
button.warn{background:linear-gradient(#ffa585,#ff7b52);box-shadow:0 4px 0 #b24a28}
button[disabled]{opacity:.45;filter:grayscale(.4);pointer-events:none}
button.big{font-size:21px;padding:15px 30px;border-radius:22px}
.ib{width:42px;height:42px;padding:0;border-radius:50%;background:linear-gradient(#fff,#f1e6cc)}
.ib.lg{width:52px;height:52px}
.ib .ico{width:22px;height:22px}
.screen{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;padding:20px;gap:14px;text-align:center;animation:scin .35s ease-out}
@keyframes scin{from{opacity:0;transform:scale(.96) translateY(10px)}}
.title{gap:12px}
.logowrap{animation:bob 3.2s ease-in-out infinite}
@keyframes bob{50%{transform:translateY(-8px) rotate(-1deg)}}
.logo{width:min(calc(var(--vw)*78),calc(var(--vh)*38),320px);border-radius:22px;background:#fff;border:5px solid #fff;box-shadow:0 10px 0 rgba(0,0,0,.28),0 16px 30px rgba(0,0,0,.4)}
.ver{color:#ffd9a8;font-size:12px;opacity:.8;margin-top:-4px}
.setup{width:min(calc(var(--vw)*88),360px);background:rgba(0,0,0,.28);border:2px solid rgba(255,255,255,.18);border-radius:22px;padding:14px;display:flex;flex-direction:column;gap:10px}
.setup input{width:100%;font:inherit;font-weight:700;padding:12px;border-radius:14px;border:3px solid #e6d3a0;background:#fffdf5;text-align:center;outline:0}
.lab2{color:#fff;font-weight:800}
.bots{display:flex;gap:8px}
.botbtn{flex:1;flex-direction:column;gap:2px;padding:8px 4px;font-size:13px;border-radius:16px;background:linear-gradient(#f3ead5,#d9c9a2);color:#6b4a2b;box-shadow:0 3px 0 #a38d5c}
.botbtn .bi{display:flex;gap:1px;height:22px;align-items:center}.botbtn .ico{width:20px;height:20px}
.botbtn.on{background:linear-gradient(#ffe46b,#ffc928);color:var(--ink);box-shadow:0 3px 0 #b48500}
.playbtn{width:min(calc(var(--vw)*88),360px);font-size:26px;padding:16px;border-radius:26px;animation:pulsebtn 1.6s ease-in-out infinite}
.playbtn .ico{width:28px;height:28px}
@keyframes pulsebtn{50%{transform:scale(1.04)}}
.dockrow{display:flex;gap:18px;margin-top:6px}
/* game */
#game{position:absolute;inset:0;display:flex;flex-direction:column;gap:5px;padding:6px 8px 8px;animation:scin .3s ease-out}
#game.final{display:block;overflow:auto}
.hud{display:flex;align-items:center;justify-content:space-between;gap:8px;flex:none}
.turn{background:rgba(0,0,0,.4);color:#fff;font-weight:800;border-radius:99px;padding:6px 16px;font-size:14px;border:2px solid rgba(255,255,255,.2)}
.pill{display:inline-flex;align-items:center;gap:4px;background:linear-gradient(#fff,#f1e6cc);border-radius:99px;padding:4px 10px;font-size:15px;box-shadow:0 3px 0 #b9a77d;font-weight:900}
.pill .ico{width:17px;height:17px}
.pill.pt{background:linear-gradient(#bfe9ff,#7cc8f2);box-shadow:0 3px 0 #3e8db5}
.pill.sc{background:linear-gradient(#ffe46b,#ffc928);box-shadow:0 3px 0 #b48500}
.pill.dk{background:rgba(0,0,0,.4);color:#fff;box-shadow:none;border:2px solid rgba(255,255,255,.2)}
.opps{display:flex;gap:6px;justify-content:center;flex:none}
.opp{background:rgba(0,0,0,.33);border:2px solid rgba(255,255,255,.15);border-radius:16px;padding:4px 6px 5px;text-align:center;flex:1;max-width:200px;color:#fff;display:flex;flex-direction:column;align-items:center;gap:3px;transition:all .2s}
.opp.active{border-color:var(--gold);background:rgba(255,216,74,.2);box-shadow:0 0 14px rgba(255,216,74,.5)}
.oh{display:flex;gap:6px;align-items:center;font-size:12px;width:100%;justify-content:center;white-space:nowrap}
.oh b{font-size:13px}.oi{display:inline-flex;align-items:center;gap:2px}.oi .ico{width:12px;height:12px}.oi.st{color:var(--gold)}
.tray{flex:none;background:linear-gradient(var(--wood1),var(--wood2));border-radius:16px;padding:3px 6px 7px;box-shadow:inset 0 2px 0 rgba(255,255,255,.25),0 4px 0 #4e2a12,0 6px 8px rgba(0,0,0,.35)}
.lab{color:#ffe9c6;font-weight:800;font-size:11px;padding:0 4px 2px;opacity:.9}
.buffet{display:flex;gap:5px;justify-content:center;padding-top:6px}
.bcard{position:relative;flex:1;max-width:76px;border-radius:10px;border:3px solid var(--gc,#999);background:#fff;overflow:hidden;box-shadow:0 3px 0 rgba(0,0,0,.35);cursor:pointer;transition:transform .15s}
.bcard.deal{animation:deal .45s ease-out}
@keyframes deal{from{transform:translateY(-30px) scale(.7);opacity:0}}
.bcard img{display:block;width:100%;aspect-ratio:372/340;object-fit:cover;pointer-events:none}
.bcard .nm{font-size:10px;font-weight:700;line-height:1.1;padding:2px;text-align:center;background:#fff;height:22px;overflow:hidden}
.bcard .price{position:absolute;top:2px;inset-inline-start:2px;width:21px;height:21px;border-radius:50%;background:var(--gold);border:2px solid var(--ink);font-weight:900;font-size:12px;display:flex;align-items:center;justify-content:center}
.bcard .price.free{background:#8fe06a}
.bcard.ok{box-shadow:0 0 0 3px var(--gold),0 5px 8px rgba(0,0,0,.4);transform:translateY(-3px)}
.bcard.sel{box-shadow:0 0 0 4px #fff,0 8px 12px rgba(0,0,0,.5);transform:translateY(-7px)}
.bcard.dim{opacity:.5;filter:grayscale(.5)}
.msg{flex:none;background:rgba(0,0,0,.4);color:#fff;border-radius:14px;padding:5px 12px;font-size:13px;line-height:1.25;min-height:34px;text-align:center;display:flex;align-items:center;justify-content:center;border:2px solid rgba(255,255,255,.12)}
.msg b{color:var(--gold)}
.mine{container-type:size;flex:1;min-height:0;display:flex;flex-direction:column;align-items:center;gap:5px}
.mineh{display:flex;align-items:center;gap:6px;color:#fff;justify-content:center;flex:none}
.mineh>b{font-size:15px}
.mine .board{flex:none;width:min(100cqw,calc((100cqh - 38px)*1.09),380px);min-width:0}
.board{display:grid;grid-template-columns:repeat(3,1fr);gap:5px;direction:ltr;margin:0 auto;padding:6px;border-radius:16px;background:rgba(0,0,0,.28);border:3px solid rgba(255,255,255,.14);width:100%;max-width:380px}
.cell{position:relative;aspect-ratio:372/340;border-radius:9px;background:rgba(255,255,255,.1);border:2px dashed rgba(255,255,255,.35);overflow:hidden;display:flex;align-items:center;justify-content:center}
.cell:not(.empty){border:3px solid var(--gc,#999);background:#fff;border-style:solid;cursor:pointer;box-shadow:0 3px 0 rgba(0,0,0,.35)}
.cell.pop{animation:pop .5s cubic-bezier(.2,1.6,.4,1)}
@keyframes pop{from{transform:scale(.3) rotate(-8deg);opacity:0}}
.cell img{width:100%;height:100%;object-fit:cover;display:block;pointer-events:none}
.cell .slot{color:#fff;font-size:11px;opacity:.75;text-align:center;direction:rtl}
.cell .nm{position:absolute;bottom:0;left:0;right:0;font-size:11px;font-weight:700;background:rgba(255,255,255,.9);text-align:center;direction:rtl;padding:1px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cell .pts{position:absolute;top:2px;right:2px;min-width:26px;padding:1px 5px;border-radius:99px;font-weight:900;font-size:14px;text-align:center;border:2px solid #fff;color:#fff;box-shadow:0 2px 0 rgba(0,0,0,.3)}
.pts.pos{background:#2fa02f}.pts.neg{background:#c2202a}.pts.zero{background:#777}
.cell .tag{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;font-weight:900;color:#fff;font-size:16px;background:rgba(0,0,0,.55)}
.cell .tag.off{background:rgba(20,30,60,.65)}
.cell.hl{box-shadow:0 0 0 3px var(--gold);animation:pulse 1s infinite;border-color:var(--gold);cursor:pointer;background:rgba(255,216,74,.25)}
.cell.dim{opacity:.55}
@keyframes pulse{50%{box-shadow:0 0 0 7px rgba(255,216,74,.5)}}
.board.sm{gap:2px;max-width:130px;padding:3px;border-width:2px;border-radius:9px;background:rgba(0,0,0,.2);min-width:0;width:100%}
.cell.sm{border-width:2px;border-radius:4px;box-shadow:none}.cell.sm .nm,.cell.sm .pts{display:none}
.finboard .board.sm{max-width:200px}
.finboard .cell.sm .pts{display:block;font-size:10px;min-width:16px;padding:0 3px;border-width:1px}
.acts{display:flex;gap:7px;justify-content:center;align-items:stretch;flex:none;padding-top:2px}
.act{flex:1;flex-direction:column;gap:2px;padding:8px 4px;font-size:13px;border-radius:18px;max-width:150px}
.act .ico{width:24px;height:24px}
.hint{color:#fff;font-weight:800;font-size:15px;align-self:center;flex:1;text-align:center}
.acts>button:not(.act){padding:11px 20px}
.sheet{display:none}
.modal{position:absolute;inset:0;background:rgba(15,4,4,.72);display:flex;align-items:center;justify-content:center;padding:14px;z-index:60;overflow:auto;animation:fadein .2s}
@keyframes fadein{from{opacity:0}}
.modal .panel{max-height:94%;overflow:auto;animation:modalin .3s cubic-bezier(.2,1.3,.4,1)}
@keyframes modalin{from{transform:scale(.85);opacity:0}}
.panel{position:relative;background:linear-gradient(#fffaf0,#fff1d6);border-radius:24px;padding:18px;box-shadow:0 8px 0 rgba(0,0,0,.3),0 0 0 4px #e8c978;max-width:480px;width:100%;text-align:center}
.xbtn{position:absolute;top:8px;inset-inline-end:8px;width:34px;height:34px;padding:0;border-radius:50%;background:linear-gradient(#ffa585,#ff7b52);color:#fff;box-shadow:0 3px 0 #b24a28;z-index:2}
.xbtn .ico{width:16px;height:16px}
h1{margin:0;color:#fff}
h2{margin:0 0 8px;color:#7a1a1f}
.fullimg{width:min(calc(var(--vw)*86),330px);max-height:calc(var(--vh)*56);object-fit:contain;border-radius:12px;display:block;margin:0 auto;cursor:zoom-out;box-shadow:0 5px 0 rgba(0,0,0,.25)}
.big{font-size:20px;font-weight:900;margin-top:6px}
.small{font-size:13px;opacity:.9}
.row{display:flex;gap:10px;justify-content:center;flex-wrap:wrap}
.rules p{text-align:right;font-size:15px;line-height:1.5;margin:6px 0}
.menulist{display:flex;flex-direction:column;gap:9px;margin-top:6px}
.mi{justify-content:flex-start;font-size:17px;padding:13px 16px}
.mi .ico{width:24px;height:24px}
textarea{width:100%;font:inherit;padding:10px;border-radius:12px;border:3px solid #e6d3a0;background:#fff;margin-bottom:8px}
.optgrid{display:grid;grid-template-columns:repeat(2,1fr);gap:8px}
.opt{flex-direction:column;gap:2px;padding:6px;font-size:13px}
.opt img{width:100px;border-radius:6px}
.toast{position:absolute;top:34%;left:50%;transform:translateX(-50%);z-index:70;pointer-events:none;text-align:center;animation:fade 1.7s forwards;width:max-content;max-width:90%}
.toast .t{background:linear-gradient(#ffe46b,#ffc928);border-radius:16px;padding:9px 16px;font-weight:900;font-size:18px;box-shadow:0 5px 0 #b48500,0 8px 14px rgba(0,0,0,.4)}
@keyframes fade{0%{opacity:0;transform:translate(-50%,14px) scale(.8)}12%{opacity:1;transform:translate(-50%,0) scale(1.05)}20%{transform:translate(-50%,0) scale(1)}80%{opacity:1}100%{opacity:0;transform:translate(-50%,-12px)}}
table{border-collapse:collapse;width:100%;font-size:13px}th,td{padding:5px 4px;border-bottom:1px solid #d8cba8;text-align:center}
tr.first td{background:rgba(255,216,74,.45);font-weight:800}
.fin{padding:18px 12px;color:#fff;text-align:center;animation:scin .4s}.fin h2{color:var(--gold);font-size:28px;text-shadow:0 3px 0 rgba(0,0,0,.35)}
.cup{width:84px;height:84px;margin:0 auto;border-radius:50%;background:linear-gradient(#ffe46b,#ffc928);color:#7a1a1f;display:flex;align-items:center;justify-content:center;box-shadow:0 6px 0 #b48500,0 0 30px rgba(255,216,74,.6);animation:bob 2.4s ease-in-out infinite}
.cup .ico{width:50px;height:50px}
.fin table{background:var(--cream);color:var(--ink);border-radius:16px;overflow:hidden;box-shadow:0 5px 0 rgba(0,0,0,.3)}
.finboard{display:inline-block;margin:8px;vertical-align:top}
.ok-t{color:#1d7a1d;font-weight:800}.bad-t{color:#b3141e;font-weight:800}
.logbox{max-height:calc(var(--vh)*50);overflow:auto;text-align:right;font-size:14px}
.logbox div{padding:3px 0;border-bottom:1px dashed #d8cba8}
#ov{position:absolute;inset:0;pointer-events:none;z-index:50}#ov>*{pointer-events:auto}#ov>.toast{pointer-events:none}
html.short .opp .board{display:none}
@media (prefers-reduced-motion:reduce){*{animation:none!important;transition:none!important}}

/* depth, drag, avatars */
.bcard{touch-action:none;box-shadow:0 4px 0 rgba(0,0,0,.4),0 8px 10px rgba(0,0,0,.35),inset 0 0 0 1px rgba(255,255,255,.6)}
.bcard:after,.cell:not(.empty):after{content:"";position:absolute;inset:0;pointer-events:none;background:linear-gradient(115deg,rgba(255,255,255,.38) 0,rgba(255,255,255,.06) 28%,transparent 40%,transparent 100%);border-radius:inherit}
.bcard.lifted{opacity:.25;transform:scale(.9)}
.cell:not(.empty){box-shadow:0 4px 0 rgba(0,0,0,.4),0 7px 9px rgba(0,0,0,.3),inset 0 0 0 1px rgba(255,255,255,.6)}
.cell.target{background:rgba(255,216,74,.55);box-shadow:0 0 0 4px #fff,0 0 22px 6px rgba(255,216,74,.8);transform:scale(1.05);z-index:2;transition:transform .12s}
.ghost{position:absolute;left:0;top:0;z-index:80;pointer-events:none;border-radius:12px;border:4px solid #999;background:#fff;overflow:hidden;box-shadow:0 22px 24px rgba(0,0,0,.5),0 0 0 2px rgba(255,255,255,.7);will-change:transform;transform-origin:50% 60%}
.ghost img{display:block;width:100%}
.ghost .gnm{font-size:12px;font-weight:800;text-align:center;padding:2px 0 3px;background:#fff}
.spark{position:absolute;width:9px;height:9px;margin:-4px 0 0 -4px;border-radius:50%;background:radial-gradient(#fff,#ffd84a 60%,transparent 70%);z-index:75;pointer-events:none;animation:spark .7s ease-out forwards}
@keyframes spark{to{transform:translate(var(--dx),var(--dy)) scale(.2);opacity:0}}
.av{width:22px;height:22px;border-radius:50%;background:radial-gradient(circle at 35% 30%,#ffe9a8,#e0a62b);color:#5a3217;font-weight:900;font-size:13px;display:inline-flex;align-items:center;justify-content:center;box-shadow:0 0 0 2px rgba(255,255,255,.6),0 2px 0 rgba(0,0,0,.35);flex:none}
.opp.active .av{box-shadow:0 0 0 3px var(--gold),0 0 14px var(--gold);animation:pulse2 1s infinite}
@keyframes pulse2{50%{transform:scale(1.12)}}
.tray:after{content:"";display:block;height:5px;margin:3px -2px -4px;border-radius:0 0 12px 12px;background:linear-gradient(#c58952,#8b5a2d);box-shadow:0 2px 0 #4e2a12}
body{background:radial-gradient(ellipse at 50% 18%,rgba(255,190,120,.35) 0,transparent 45%),radial-gradient(ellipse at 50% 30%,#a02930 0,#6d1519 60%,#350a0c 100%)}
#ov>.ghost,#ov>.spark{pointer-events:none}

/* landscape and short screens */
html.land .title{display:grid;grid-template-columns:1fr 1fr;grid-template-rows:1fr auto auto 1fr;grid-template-areas:"logo ." "logo setup" "logo play" "ver dock";align-items:center;justify-items:center;column-gap:18px;row-gap:8px;padding:8px 24px}
html.land .logowrap{grid-area:logo;align-self:center}
html.land .logo{width:min(calc(var(--vw)*42),calc(var(--vh)*62),340px)}
html.land .ver{grid-area:ver;align-self:end;margin:0}
html.land .setup{grid-area:setup;padding:8px;gap:6px;width:min(calc(var(--vw)*44),380px)}
html.land .setup input{padding:7px}
html.land .botbtn{padding:4px}html.land .botbtn .bi{height:16px}
html.land .playbtn{grid-area:play;font-size:20px;padding:10px;width:min(calc(var(--vw)*44),380px)}
html.land .dockrow{grid-area:dock;align-self:start;margin:0;gap:14px}
html.land .ib.lg{width:40px;height:40px}
html.land #game{display:grid;grid-template-columns:minmax(0,1fr) 38vh 108px;grid-template-columns:minmax(0,1fr) calc(var(--vh)*72) 112px;grid-template-rows:auto auto auto minmax(0,1fr);gap:5px 10px;padding:4px max(10px,env(safe-area-inset-right)) 4px max(10px,env(safe-area-inset-left));align-content:start}
html.land .hud{grid-column:1/-1;grid-row:1}
html.land .opps{grid-column:1;grid-row:2}
html.land .tray{grid-column:1;grid-row:3}
html.land .msg{grid-column:1;grid-row:4;align-self:start;min-height:30px;font-size:12px}
html.land .mine{grid-column:2;grid-row:2/5;min-height:0}
html.land .mine .board{width:min(100cqw,calc((100cqh - 30px)*1.09),380px);padding:4px;gap:4px}
html.land .mineh{gap:4px}html.land .mineh>b{font-size:13px}
html.land .acts{grid-column:3;grid-row:2/5;flex-direction:column;justify-content:center;gap:6px}
html.land .act{max-width:none;flex:none;flex-direction:row;padding:7px 8px;font-size:12px;border-radius:14px}
html.land .act .ico{width:20px;height:20px}
html.land .hint{font-size:13px}
html.land .opps .opp{padding:3px 6px}
html.land .hud .ib{width:34px;height:34px}
html.land .turn{padding:3px 12px;font-size:13px}
html.land .fullimg{max-height:calc(var(--vh)*66);width:auto;max-width:calc(var(--vw)*40)}
html.land .panel{display:flex;flex-wrap:wrap;gap:6px 14px;align-items:center;justify-content:center;max-width:calc(var(--vw)*92)}
html.land .panel>.fullimg{flex:none}
html.land .panel>.small,html.land .panel>.big,html.land .panel>button.big{flex:1 1 40%}
html.tiny .pill{padding:2px 8px;font-size:13px}
html.land .pts{font-size:12px}

html.land #app{max-width:none}html.land .mine{min-width:0}html.land #game{overflow:hidden}html.land .opps{min-width:0}html.land .tray{min-width:0;overflow:hidden}

.pill small{font-size:11px;font-weight:700;opacity:.75}
.num{direction:ltr;unicode-bidi:isolate;display:inline-block}
.pill.sc.neg{background:linear-gradient(#ff8a80,#e53935);color:#fff;box-shadow:0 3px 0 #8e1a17}
.oi.st.neg{color:#ff8a80}.oi.st.neg .num{font-weight:900}
.dseg .botbtn{font-weight:900;font-size:16px;padding:10px 4px}
.hud .ib{background:linear-gradient(#7a2e2e,#4a1414);border:2px solid #f2c14e;box-shadow:0 3px 0 #2a0a0a,inset 0 1px 0 rgba(255,255,255,.25);color:#f2c14e}
.pts{direction:ltr;unicode-bidi:isolate}
html.land.tiny .title{padding:4px 18px;row-gap:4px}
html.land.tiny .lab2{font-size:12px;margin:0;line-height:1.1}
html.land.tiny .setup{gap:3px;padding:6px}
html.land.tiny .setup input{padding:4px;font-size:14px}
html.land.tiny .botbtn{padding:2px}html.land.tiny .botbtn .bi{height:13px}html.land.tiny .botbtn .ico{width:13px;height:13px}
html.land.tiny .botbtn,html.land.tiny .dseg .botbtn{font-size:12px}
html.land.tiny .dseg .botbtn{padding:5px 2px}
html.land.tiny .playbtn{font-size:16px;padding:6px}
html.land.tiny .ib.lg{width:30px;height:30px}html.land.tiny .ib.lg .ico{width:16px;height:16px}
html.land.tiny .dockrow{gap:10px}
html.land.tiny .logo{width:min(calc(var(--vw)*34),calc(var(--vh)*58),300px)}
html.short:not(.land) .title{gap:8px;padding:10px 18px}
html.short:not(.land) .logo{width:min(calc(var(--vw)*52),calc(var(--vh)*26))}
html.short:not(.land) .ib.lg{width:44px;height:44px}
html.short:not(.land) .botbtn{padding:6px 4px}
.finbar{position:sticky;bottom:0;display:flex;gap:8px;justify-content:center;flex-wrap:wrap;padding:10px 8px calc(10px + env(safe-area-inset-bottom));margin:12px -8px 0;background:linear-gradient(transparent,rgba(60,10,10,.92) 30%);z-index:5}
.finbar button{flex:1 1 30%;min-width:0;display:flex;align-items:center;justify-content:center;gap:6px}
html.short .finbar button{font-size:13px;padding:8px 6px}

.mutebtn.on{opacity:.75;color:#ff8a80}
.bigcode{font-size:44px;font-weight:900;letter-spacing:8px;direction:ltr;color:var(--gold);text-shadow:0 3px 0 rgba(0,0,0,.35);margin:4px 0}
.plist{display:flex;flex-direction:column;gap:6px;margin:10px 0}.pl{background:rgba(0,0,0,.25);border-radius:12px;padding:8px 12px;font-weight:700}.pl.me{outline:2px solid var(--gold)}
.boardlist table,.finsoc table{width:100%;background:var(--cream);color:var(--ink);border-radius:12px;overflow:hidden}
.boardlist h3,.finsoc h3{margin:10px 0 4px}
.finsoc{margin-top:10px}
.finbar .mutebtn{flex:0 0 auto}
html.tiny .bigcode{font-size:28px}
.boardlist{max-height:calc(var(--vh)*58);overflow:auto}
.dockrow{flex-wrap:wrap;justify-content:center;gap:8px}
.dockrow .ib.lg{width:46px;height:46px}
html.land.tiny .dockrow .ib.lg{width:28px;height:28px}
html.land.tiny .dockrow{gap:6px}
.panel>button.primary,.panel>button:not(.xbtn){display:block;width:100%;margin:6px 0}
.panel>.row>button{flex:1}
.panel input[type=text]{width:100%;box-sizing:border-box;margin:4px 0}

/* v0.9 UI: friends popup cards, code boxes, dock labels */
.mk-in{width:100%;box-sizing:border-box;font:inherit;font-weight:800;font-size:18px;color:#3a1d10;background:linear-gradient(#fff8e6,#f6e6bd);border:3px solid #a8693a;border-radius:16px;padding:12px 14px;outline:0;box-shadow:inset 0 3px 6px rgba(80,40,10,.25),0 2px 0 #fff;text-align:right}
.mk-in::placeholder{color:#a58a63;font-weight:700}
.mk-in:focus{border-color:#ffc928;box-shadow:0 0 0 3px #fff3b0,inset 0 3px 6px rgba(80,40,10,.25)}
.panel .mk-sec{background:rgba(255,255,255,.55);border:2px solid #e8c978;border-radius:18px;padding:12px;text-align:right;display:flex;flex-direction:column;gap:8px;margin-top:8px}
.panel .mk-sec .hint{font-size:13px;color:#6b4a2b;font-weight:700;text-align:center}
.mk-lab{display:flex;align-items:center;gap:8px;font-weight:900;font-size:16px;color:#7a1a1f}
.mk-lab .ico{width:20px;height:20px;color:#b3262b}
.codebox{position:relative;cursor:text}
.cells{display:flex;gap:6px;direction:ltr;justify-content:center}
.cells .cell{width:46px;height:56px;border-radius:12px;border:3px solid #a8693a;background:linear-gradient(#fff8e6,#f6e6bd);box-shadow:inset 0 3px 6px rgba(80,40,10,.25);display:flex;align-items:center;justify-content:center;font-weight:900;font-size:26px;color:#3a1d10}
.cells .cell.cur{border-color:#ffc928;box-shadow:0 0 0 3px #fff3b0,inset 0 3px 6px rgba(80,40,10,.25)}
.codein{position:absolute;inset:0;width:100%;height:100%;opacity:0;font-size:16px;border:0;padding:0;background:transparent;direction:ltr}
.dkw{display:flex;flex-direction:column;align-items:center;gap:4px;width:54px}
.dkw span{font-size:12px;font-weight:900;color:#fff;text-shadow:0 1px 2px #000;white-space:nowrap;line-height:1.1}
.dockrow{gap:6px !important;flex-wrap:nowrap !important;align-items:flex-start}
.dockrow .ib.lg{width:46px;height:46px}
html.land .panel .mk-sec{flex:1 1 28%;min-width:0;margin-top:0}html.land .panel>h2,html.land .panel>p.small{flex:1 1 100%;margin:2px 0}html.land .cells{gap:3px}html.land .cells .cell{width:30px;height:36px;font-size:18px}html.land .mk-in{padding:7px 10px;font-size:16px}html.land .panel>div.small{flex:1 1 100%}
html.land.tiny .dk{width:44px;gap:1px}html.land.tiny .dkw span{font-size:10px}
html.land.tiny .dockrow{gap:4px !important}
html.land.tiny .dockrow .ib.lg{width:28px;height:28px}
html.land.tiny .cells .cell{width:36px;height:40px;font-size:20px}
html.land .panel .mk-sec button.big{font-size:17px;padding:10px 8px;white-space:nowrap}

/* v1.0 mock: selection changes color only */
.botbtn{border:0;transform:none !important}
.botbtn.on{transform:none !important;box-shadow:0 3px 0 #b48500}
/* landscape: one right column with equal gaps, bigger logo */
html.land .title{grid-template-rows:1fr auto auto auto 1fr;grid-template-areas:"logo ." "logo setup" "logo play" "logo dock" "logo ver";row-gap:14px;align-content:center}
html.land .logowrap{align-self:center}
html.land .logo{width:min(calc(var(--vw)*44),calc(var(--vh)*72),400px)}
html.land.tiny .logo{width:min(calc(var(--vw)*40),calc(var(--vh)*68),360px)}
html.land .playbtn{margin:4px 0}
html.land .dockrow{align-self:center}
html.land .ver{align-self:end;justify-self:end;margin:0}
html.land .title{gap:0 18px}html.land .setup{margin-bottom:12px}html.land .playbtn{margin:4px 0 16px}
html.land .logo{width:min(calc(var(--vw)*46),calc(var(--vh)*88),420px)}
html.land.tiny .logo{width:min(calc(var(--vw)*42),calc(var(--vh)*84),380px)}
/* popups: close button always visible, soft fade shows there is more above */
.modal .panel{padding-bottom:0}
.modal .panel>.row:last-child{position:sticky;bottom:0;margin:10px -18px 0 !important;padding:22px 18px 16px;background:linear-gradient(rgba(255,241,214,0),#fff1d6 42%);z-index:3;border-radius:0 0 24px 24px}
html.land .modal .panel>.row:last-child{flex:1 1 100%;padding:14px 18px 10px}

/* turn highlighting (mock) */
.msg{gap:8px}
.tchip{flex:none;font-weight:900;border-radius:999px;padding:3px 10px;font-size:13px}
.msg.tm{background:linear-gradient(#ffe46b,#ffc928);color:#3a2300;border-color:#fff;box-shadow:0 0 0 2px #ffc928,0 0 18px rgba(255,216,74,.85);animation:tglow 1.4s ease-in-out infinite}
.msg.tm b{color:#7a1a1f}
.msg.tm .tchip{background:#7a1a1f;color:#fff}
.msg.to{background:rgba(35,70,120,.75);border-color:#8cc4ff}
.msg.to .tchip{background:#8cc4ff;color:#0e2748}
@keyframes tglow{50%{box-shadow:0 0 0 2px #ffc928,0 0 6px rgba(255,216,74,.4)}}
.mine.mt{outline:3px solid #ffd84a;outline-offset:2px;border-radius:20px;box-shadow:0 0 22px rgba(255,216,74,.55);background:rgba(255,216,74,.08)}
.mine.mw{opacity:.72}
.opps.idle .opp{opacity:.62}
.opp.active{border-color:#8cc4ff;background:rgba(80,150,255,.28);box-shadow:0 0 0 2px #8cc4ff,0 0 22px rgba(120,185,255,.8);position:relative}
.opp.active .av{box-shadow:0 0 0 3px #8cc4ff,0 0 14px #8cc4ff}
.ontag{background:#8cc4ff;color:#0e2748;font-size:11px;font-weight:900;border-radius:999px;padding:1px 8px;line-height:1.3}
html.land .mine.mt{outline-offset:-4px}
html.land .hud .pill.dk small{display:none}html.land .hud .pill.dk{padding:4px 9px;white-space:nowrap}

.pill.tok{padding:3px 10px 3px 6px;gap:6px;cursor:pointer}
.pill.tok .tcoin{width:24px;height:24px;border-radius:50%;background:var(--gold);border:2px solid var(--ink);font-weight:900;font-size:14px;display:inline-flex;align-items:center;justify-content:center;color:var(--ink);flex:none}
.pill.tok .tlab{font-size:14px;font-weight:900}
html.tiny .pill.tok{padding:2px 8px 2px 4px}html.tiny .pill.tok .tcoin{width:20px;height:20px;font-size:12px}

/* tutorial */
#tut{position:absolute;inset:0;z-index:70}
#tut .tblock{position:absolute;inset:0;pointer-events:auto}
#tut .tblock.dim{background:rgba(15,4,4,.78)}
#tut .tspot{position:absolute;pointer-events:none;border-radius:20px;box-shadow:0 0 0 9999px rgba(15,4,4,.76),0 0 0 4px #ffd84a,0 0 22px 6px rgba(255,216,74,.8)}
#tut .tcw{position:absolute;left:10px;right:10px;display:flex;justify-content:center;z-index:2;pointer-events:none}
#tut .tcw>.tpanel{pointer-events:auto}
#tut .tarrow{position:absolute;top:-12px;width:0;height:0;margin-left:-11px;border-left:11px solid transparent;border-right:11px solid transparent;border-bottom:13px solid #fffaf0;pointer-events:none}
.tpanel{padding:12px 14px;max-height:calc(var(--vh)*96);overflow:auto}
.tpanel h2{margin:0 0 5px;font-size:19px}
.tpanel p{margin:0 0 8px;font-size:14.5px;line-height:1.4;color:#5a3a22}
.tdots{display:flex;gap:6px;justify-content:center;margin-bottom:8px}
.tdots .td{width:9px;height:9px;border-radius:9px;background:#e8d3a0}
.tdots .td.on{background:#ffc928}.tdots .td.cur{width:22px}
.trow{display:flex;gap:8px;margin-top:6px}
.trow button{flex:1;padding:8px 6px;font-size:14px}
.tchk{display:flex;align-items:center;justify-content:center;gap:8px;margin-top:8px;font-size:13px;color:#6b4a2b;font-weight:800;cursor:pointer}
.tchk input{appearance:none;-webkit-appearance:none;width:22px;height:22px;margin:0;border-radius:6px;border:2.5px solid #b48500;background:#fff;display:inline-block;position:relative;flex:none;cursor:pointer}
.tchk input:checked{background:#ffc928}
.tchk input:checked:after{content:"✓";position:absolute;inset:0;text-align:center;line-height:17px;font-size:15px;color:var(--ink)}
.tlegend{display:flex;align-items:center;justify-content:center;gap:10px;margin:2px 0 8px;font-weight:900;font-size:14px;color:#2b1a12}
.tlegend .tcoin{width:24px;height:24px;border-radius:50%;background:var(--gold);border:2px solid var(--ink);display:inline-flex;align-items:center;justify-content:center;font-size:14px}
.tflow{position:absolute;inset:0;overflow:auto;display:flex;flex-direction:column;align-items:center;gap:12px;padding:10px 10px 14px;z-index:2;pointer-events:auto}
.tflow .tpanel{width:100%;flex:none}
.tcardimg{position:relative;flex:none;width:min(270px,calc(var(--vh)*30),62vw);margin:4px 0}
.tcardimg img{display:block;width:100%;border-radius:14px;box-shadow:0 0 0 4px #ffd84a,0 8px 24px rgba(0,0,0,.6)}
.tbadge{position:absolute;left:calc(100% + 9px);width:30px;height:30px;margin-top:-15px;border-radius:50%;background:#ffc928;color:var(--ink);font-weight:900;font-size:17px;display:flex;align-items:center;justify-content:center;box-shadow:0 3px 0 #b48500,0 0 0 2px #fff}
.tcardleg{flex:none;width:100%;max-width:480px;background:linear-gradient(#fffaf0,#fff1d6);border-radius:18px;box-shadow:0 0 0 3px #e8c978;padding:8px 12px;font-size:13.5px;line-height:1.55;color:var(--ink);font-weight:700;text-align:right}
.tcardleg b{color:#b48500}
.tutrow{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-top:2px}
.tutrow .tchk{margin:0;color:#fff;font-size:13px}
.tutbtn{padding:7px 12px;font-size:14px}
html.land .tpanel{display:block;max-width:560px}
html.land .tpanel .trow button{white-space:nowrap}
html.land .tflow{display:grid;grid-template-columns:1fr auto;grid-template-rows:auto 1fr;align-items:start;justify-items:stretch;column-gap:46px;padding:8px 52px 8px 10px}
html.land .tflow .tpanel{grid-column:1;grid-row:1;max-width:none}
html.land .tflow .tcardleg{grid-column:1;grid-row:2;max-width:none}
html.land .tflow .tcardimg{grid-column:2;grid-row:1/3;width:calc(var(--vh)*44);margin:0}

.accrow{display:flex;align-items:center;justify-content:space-between;gap:8px;margin-top:6px;color:#fff;font-weight:800;font-size:13px}.accrow .small{color:#fff}.accname{font-weight:900}.gbox{display:flex;justify-content:center;min-height:44px;margin:6px 0}.linkbtn{background:none;border:0;color:#6b4a2b;text-decoration:underline;font:inherit;font-weight:800;cursor:pointer;padding:4px}.panel a{color:#6b4a2b;font-weight:800}

/* v0.13 start screen A + login modal A */
.setup{background:none;border:0;padding:0;gap:10px}
.acard{display:flex;align-items:center;justify-content:space-between;gap:10px;background:rgba(0,0,0,.28);border:2px dashed rgba(255,255,255,.4);border-radius:20px;padding:10px 12px;color:#fff;text-align:right}
.acard.user{border:2px solid var(--green)}
.aid{display:flex;align-items:center;gap:10px;min-width:0}
.aav{width:44px;height:44px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-weight:900;font-size:20px;flex:none}
.aav.g{background:rgba(255,255,255,.14);border:2px dashed rgba(255,255,255,.55);color:#fff}
.aav.u{background:var(--green);border:3px solid #fff;color:#143a12}
.attl{font-weight:900;font-size:16px}.asub{font-size:12.5px;color:#f1dcc0;margin-top:2px}
.atx{min-width:0}
.sm{padding:8px 14px;font-size:14px;border-radius:14px}
.alink{background:none;box-shadow:none;color:#ffe9a8;text-decoration:underline;font-weight:800;font-size:13px;padding:4px}
.scard{background:rgba(0,0,0,.28);border:2px solid rgba(255,255,255,.18);border-radius:20px;padding:12px;display:flex;flex-direction:column;gap:10px}
.srow{display:flex;align-items:center;gap:10px}
.slbl{font-weight:800;color:#fff;font-size:14px;white-space:nowrap;min-width:44px;text-align:right}
.srow .bots{flex:1;gap:6px}.srow .botbtn{padding:8px 4px;font-size:14px;flex-direction:row}
.playwrap{display:flex;flex-direction:column;align-items:center;gap:8px}
.playwrap .tutrow{justify-content:center;gap:10px;margin:0}
.playwrap .tchk{color:#f1dcc0}
.tutlink{background:none;box-shadow:none;color:#ffe9a8;text-decoration:underline;font-weight:800;font-size:13px;padding:4px}
html.land .playwrap{grid-area:play}
html.land .playwrap .playbtn{grid-area:auto}
.panel .aav.big{margin:2px auto 6px;width:54px;height:54px;background:#fff0c8;border:3px dashed #c98f5a;color:#7a1a1f}
.panel .asub2{margin:2px 0 12px;color:#6b4a38}
.panel .dvd{display:flex;align-items:center;gap:10px;color:#8a6a55;font-size:13px;margin:12px 0}
.panel .dvd:before,.panel .dvd:after{content:"";flex:1;height:1px;background:#d8cba8}
.panel .mk-in{margin:0 0 10px}
.panel .swrow{margin-top:10px;font-size:14px;color:#6b4a38}
.panel .swb{color:#7a1a1f;padding:2px 4px}
.panel .legal{margin:12px 0 0;font-size:12px;color:#8a6a55}
.panel>button.primary.big{margin:4px 0 0}
.panel .linkbtn,.panel>button.linkbtn{background:none;box-shadow:none;width:auto;display:inline-block;margin:6px auto 0;padding:4px 8px}
.panel input.mk-in[type="text"],.panel input.mk-in{margin:0 0 10px}
html:not(.land) .title .logo{width:min(calc(var(--vw)*54),calc(var(--vh)*23),240px)}
html.land .authp{display:block;overflow:auto;padding:12px 16px;max-width:420px}
html.land .authp .aav.big,html.land .authp .asub2{display:none}
html.land .authp h2{margin:0 0 6px;font-size:20px}
html.land .authp .dvd{margin:6px 0}
html.land .authp .mk-in{padding:6px 10px;margin-bottom:6px}
html.land .authp .gbox{min-height:40px;margin:2px 0}
html.land .authp .legal{margin-top:6px}
@media (max-height:395px){html.land .authp{padding:8px 14px}html.land .authp h2{font-size:17px;margin:0 0 3px}html.land .authp .mk-in{padding:3px 10px;margin-bottom:4px}html.land .authp .gbox{min-height:34px}html.land .authp .dvd{margin:3px 0}html.land .authp .btn{padding:6px}}
.authp{padding-bottom:20px!important}
.authp .legal{margin-bottom:4px}
html.land .authp{padding-bottom:16px!important}

/* v0.14 turn timer */
.tmr{display:inline-flex;align-items:center;gap:6px;background:rgba(0,0,0,.45);border:2px solid rgba(255,255,255,.25);border-radius:99px;padding:3px 12px 3px 5px;color:#fff;font-weight:900;font-size:16px;flex:none}
.tmr .ring{width:26px;height:26px;border-radius:50%;background:conic-gradient(#7be07b calc(var(--p,100)*1%),rgba(255,255,255,.18) 0);display:grid;place-items:center}
.tmr .ring i{width:18px;height:18px;border-radius:50%;background:#3a1418;display:block}
.tmr.hot{background:#c4161c;border-color:#ffd84a;font-size:20px;box-shadow:0 0 0 3px rgba(255,216,74,.7),0 0 18px rgba(255,60,60,.9);animation:tmrp .5s infinite alternate}
.tmr.hot .ring{background:conic-gradient(#fff calc(var(--p,100)*1%),rgba(255,255,255,.3) 0)}
.tmr.hot .ring i{background:#c4161c}
@keyframes tmrp{to{transform:scale(1.15)}}
.tbar{height:6px;border-radius:4px;background:rgba(255,255,255,.15);overflow:hidden;flex:none;margin:2px 0}
.tbar b{display:block;height:100%;width:var(--w,100%);background:#7be07b;border-radius:4px}
.tbar.hot b{background:#ff4040}
html.land .tbar{display:none}
.cnt{display:inline-block;direction:rtl;font-weight:800;font-size:12px;background:rgba(255,255,255,.12);padding:2px 8px;border-radius:99px;margin-top:3px;white-space:nowrap}
.cnt b{color:#ffd84a;font-size:14px}
.banner{position:fixed;top:30%;left:50%;transform:translateX(-50%);z-index:70;width:84%;max-width:420px;text-align:center;background:linear-gradient(#fff,#ffe9e0);border:3px solid #c4161c;border-radius:18px;padding:12px 14px;box-shadow:0 6px 0 #7a0d12,0 10px 18px rgba(0,0,0,.5);color:#5a0d12;font-weight:900;font-size:18px}
.banner small{display:block;font-weight:700;font-size:13px;margin-top:3px;color:#7a2a2a}

/* v0.14 centered board */
.mine{position:relative;justify-content:center}
.mine .mineh{position:absolute;top:0;left:0;right:0}
.mine .board{width:min(calc(100cqw - 16px),calc((100cqh - 68px)*1.09),380px);margin:0 auto}
html.land .mine .mineh{gap:3px;flex-wrap:nowrap}html.land .mine .mineh .pill{padding:2px 6px;font-size:11px}html.land .mine .mineh b{font-size:12px}html.land .mine .mineh .pill small{font-size:9px}html.land .mine .mineh .pill.tok{padding:2px 6px 2px 3px;gap:3px}html.land .mine .mineh .pill.tok .tlab{font-size:11px}html.land .mine .mineh .pill.tok .tcoin{width:18px;height:18px;font-size:11px}html.land .mine .mineh>b{font-size:12px}html.land .mine .mineh .pill{gap:2px;padding:2px 5px}html.land .mine .mineh .pill .ico{width:12px;height:12px}
html.land .mine .board{width:min(calc(100cqw - 16px),calc((100cqh - 68px)*1.09),380px)}

.coinpill{position:relative;gap:5px;padding:4px 10px;font-size:16px;cursor:pointer}
.coinpill.topc{position:absolute;top:calc(10px + var(--sat));inset-inline-end:10px;z-index:5}
.coinpill.hudc{padding:2px 7px;font-size:14px}
.coinic{width:1.2em;height:1.2em;flex:none}
.rdot{position:absolute;top:-3px;inset-inline-start:-3px;width:12px;height:12px;border-radius:50%;background:#e22;border:2px solid #fff}
.bigbal{display:flex;gap:8px;align-items:center;justify-content:center;font-size:34px;font-weight:900;margin:4px 0}
.bigbal .coinic{width:1.1em;height:1.1em}
.ledger{text-align:start;max-height:34vh;overflow:auto}
.lrow{display:flex;justify-content:space-between;padding:6px 4px;border-bottom:1px solid #e8d9b0;font-weight:700;font-size:14px;gap:8px}
.lrow .pos{color:#1a8a2e}.lrow .neg{color:#c4161c}
.coinres{margin:8px 0;text-align:center}
.coinwin{display:flex;gap:6px;align-items:center;justify-content:center;font-size:24px;font-weight:900;color:#ffd84a}
.how{margin:8px 0}
@media (max-width:430px){.hud .pill.dk small{display:none}}
@media (max-width:430px){.hud{gap:4px}.hud .ib{width:38px;height:38px}.hud .row{gap:3px!important}.hud .coinpill.hudc{padding:1px 6px;font-size:13px}.hud .pill.dk{padding:3px 7px}.hud .turn{font-size:13px;padding:2px 8px;min-width:0}}

.mi.vol{display:flex;gap:10px;align-items:center;justify-content:space-between}.mi.vol input{flex:1;max-width:60%}

.product-lock{position:fixed;inset:0;z-index:99999;background:#27151b;display:flex;align-items:center;justify-content:center;padding:20px;text-align:center}.product-lock .panel{max-width:480px;color:#2b1a12}.lock-warning{position:fixed;top:0;inset-inline:0;z-index:99998;padding:8px;background:#ffd84a;color:#2b1a12;text-align:center;font-weight:bold}.inapp-msg{border-bottom:1px solid #bc9b65;padding:10px 0}.inapp-msg p{white-space:pre-wrap}.consent{display:flex;gap:8px;font-size:14px;align-items:start}.dockrow{flex-wrap:wrap}

.dockrow{gap:5px!important;flex-wrap:wrap!important;max-width:100%}.dockrow .ib.lg{width:40px;height:40px}.dkw{max-width:46px}.dkw>span{font-size:11px}
@media(max-width:350px){.hud{gap:2px}.hud .ib{width:29px;height:29px}.hud .row{gap:2px!important}.hud .turn{font-size:11px;padding:2px 4px}.hud .tmr{font-size:16px;min-width:0}.hud .pill.dk{padding:2px 4px}.hud .coinpill.hudc{padding:2px 4px;font-size:11px}.hud .ico{width:15px;height:15px}.mine .mineh{gap:2px}.mine .mineh>b{font-size:11px}.mine .mineh .pill{font-size:11px;padding:2px 4px;gap:2px}.mine .mineh .pill small{font-size:9px}.mine .mineh .ico{width:12px;height:12px}.mine .mineh .tok .tlab{font-size:11px}.mine .mineh .tok .tcoin{width:19px;height:19px;font-size:12px}}

.panel .soundmute{display:flex;align-items:center;justify-content:center;gap:10px}.panel .soundmute .mutebtn{width:44px;min-width:44px;height:44px;flex:none}.panel input[type=text],.panel input[type=password],.panel input[type=email],.panel select{font:inherit;padding:9px;border:1px solid #b69d6e;border-radius:10px;max-width:100%;box-sizing:border-box}
.report-link{font-size:12px;padding:4px 8px;margin-inline-start:6px;min-height:32px}.consent{display:flex;align-items:flex-start;gap:10px;text-align:right;line-height:1.5;margin:12px 0}.consent input{width:22px;height:22px;flex:0 0 22px}.panel .danger{background:#8a2020;color:white}.acard.user{flex-wrap:wrap}.panel select{font:inherit;padding:10px;width:100%;margin:8px 0}

/* Short landscape menu: intrinsic rows, safe top, and reachable overflow. */
html.land .title,html.land.tiny .title{grid-template-columns:minmax(0,1fr) minmax(0,1fr);grid-template-rows:auto auto auto auto;grid-template-areas:"logo setup" "logo play" "logo dock" "logo ver";align-content:start;gap:8px 18px;padding:calc(14px + var(--sat)) max(18px,env(safe-area-inset-right)) calc(14px + var(--sab)) max(18px,env(safe-area-inset-left));overflow-y:auto;overflow-x:hidden;scroll-padding:14px}
html.land .title>.setup{width:100%;max-width:420px;margin:0;padding:0;gap:6px;min-width:0}
html.land .title .acard{padding:6px 10px;gap:5px}
html.land .title .aid{flex:1 1 100%}
html.land .title .aav{width:34px;height:34px;font-size:18px}
html.land .title .attl{font-size:15px}
html.land .title .asub{font-size:12px}
html.land .title .scard{padding:6px 10px;gap:5px}
html.land .title .srow .botbtn{padding:5px 4px}
html.land .title>.playwrap{width:100%;max-width:420px;min-width:0;gap:5px}
html.land .title .playbtn{width:100%;margin:0;padding:9px;font-size:20px;animation:none}
html.land .title .tutrow{gap:6px;font-size:12px;flex-wrap:wrap}
html.land .title>.dockrow{margin:0;align-self:start;justify-content:center}
html.land .title>.ver{justify-self:center;align-self:start;font-size:11px}
html.land .title .logo{width:min(100%,calc(var(--vh)*70),400px);max-width:100%}
html.land .title>.logowrap{width:100%;min-width:0;align-self:center}
html.land .title>.coinpill.topc{position:relative;grid-column:1;grid-row:1;grid-area:1/1;justify-self:end;align-self:start;inset:auto;top:auto;margin:0;z-index:5}
@media(orientation:portrait){.title{overflow-y:auto;overflow-x:hidden;justify-content:flex-start;padding-top:calc(44px + var(--sat));padding-bottom:calc(16px + var(--sab))}.title>*{flex-shrink:0}.title .setup,.title .playwrap{max-width:100%}}
 
/* v0.17: intro cards, rules in five parts, card detail */
.modal .panel{padding:18px 18px 22px}
.modal .panel>.row:last-child{padding:22px 18px 18px}
.panel h2{color:#7a1a1f}
.panel .big2{font-size:19px;line-height:1.5;margin:8px 4px}.panel .big2.sm{font-size:16px;opacity:.85}
.panel .ill{display:flex;gap:8px;justify-content:center;margin:10px 0}.panel .ill img{width:64px;border-radius:8px;border:3px solid #e8c978}
.ci-gap{height:12px}
.ci-def{font-size:14px;line-height:1.4;background:#fff1c9;border-radius:12px;padding:7px 10px;margin:8px 0;text-align:right}.ci-def.first{margin-top:0}
.intro-ol{text-align:right;margin:8px 0;padding:0;list-style:none;font-size:16px;line-height:1.45}.intro-ol li{display:flex;gap:10px;align-items:flex-start;margin:9px 0}
.rn{flex:none;width:28px;height:28px;border-radius:50%;background:#ffc928;border:2px solid #2b1a12;display:flex;align-items:center;justify-content:center;font-size:15px;color:#2b1a12}
.rules5 .rr{border-top:2px solid #ead7a6;padding:6px 2px;text-align:right}.rules5 .rr:first-child{border-top:0}
.rules5 .rh{display:flex;align-items:center;gap:10px;font-size:19px;font-weight:900;color:#7a1a1f}.rules5 .rh .rn{width:26px;height:26px;font-size:14px}
.rules5 .rt{font-size:15px;line-height:1.4;margin:3px 36px 0 0}
.ci-sp{height:30px}.ci-ttl{font-size:34px;font-weight:900;color:#7a1a1f;margin:6px 0 4px;text-shadow:0 3px 0 #ffd84a}
.ci-bar{height:5px;border-radius:5px;background:linear-gradient(90deg,#ffc928,#b3262b,#ffc928);margin:0 20% 10px}
.ci-sum{font-size:20px;font-weight:900;line-height:1.35;margin:6px 4px;color:#2b1a12}
.ci-chip{display:inline-block;background:#ffe9a8;border-radius:12px;padding:6px 12px;font-weight:800;margin:3px}
.modal .panel>button.primary.big{margin:0;width:100%}
.panel .fullimg.ci-img{width:150px;max-width:60%;max-height:none;height:auto;display:block;margin:8px auto;border-radius:10px;box-shadow:0 4px 0 rgba(0,0,0,.25)}
html.land .panel .fullimg.ci-img{width:auto;height:min(46vh,190px);max-width:none}
html.land .panel.blk{display:block;padding-bottom:18px}
html.land .panel.blk .ill img{width:44px}
html.land .panel.blk h2{margin:2px 0}
html.land .rules5{display:grid;grid-template-columns:1fr 1fr;gap:0 18px}
html.land .rules5 .rr{padding:4px 2px}html.land .rules5 .rh{font-size:16px}html.land .rules5 .rt{font-size:13px;line-height:1.3;margin-top:1px}
html.land .rules5 .rr:nth-child(2){border-top:0}html.land .rules5 .rr:nth-child(2){grid-row:span 2}
html.land .panel.blk .big2{font-size:15px;margin:3px}html.land .panel.blk .intro-ol{font-size:14px;margin:4px 0}html.land .panel.blk .intro-ol li{margin:4px 0}
html.land .panel.blk>button.primary.big{margin-top:8px}
html.land .panel.stk>.fullimg.ci-img{flex:none;height:min(40vh,150px);width:auto;max-width:none;margin:2px 0}
html.land .panel.stk>button.primary.big{flex:1 1 100%;margin-top:6px;position:static}

.zoomwrap{display:flex;flex-direction:column;align-items:center;justify-content:flex-start;overflow:auto;background:rgba(0,0,0,.88);z-index:60}
.zoomimg{width:min(100vw,640px);height:auto;max-width:none;margin:0 auto;display:block}
html.land .zoomimg{height:auto;width:min(92vw,560px)}
.zoomhint{color:#fff;font-size:14px;padding:8px}
.ci-sing{font-size:16px;margin:6px 4px;text-align:right}.ci-sing summary{font-weight:800;cursor:pointer}
/* Safe update and final-board presentation. */
.lobby-version{margin:12px 0 0;padding-top:10px;border-top:1px solid #8b542940;text-align:center;direction:rtl}
.game-update{position:fixed;inset:auto 12px 12px;z-index:95;max-width:520px;margin:auto;display:flex;gap:12px;align-items:center;justify-content:center;background:#fff8e8;color:#69151b;border:2px solid #d8aa3c;border-radius:16px;padding:12px;box-shadow:0 3px 16px #0005;direction:rtl}
.game-update button{font-size:15px;padding:8px 12px}.end-summary{position:absolute;inset:0;overflow:auto;display:flex;flex-direction:column;align-items:center;gap:10px;padding:16px 16px 24px;color:#6d1519;text-align:center;background:#fff8e8}.end-summary header,.end-summary footer,.end-score{width:100%;max-width:460px}.end-summary h2{font-size:25px;margin:0 0 8px}.end-summary p{margin:6px 0;line-height:1.45}.end-score{display:flex;flex-direction:column;gap:5px;padding:10px;border:1px solid #c59940;border-radius:14px;background:#ffedbf}.end-score b{font-size:21px}.end-board{width:min(100%,330px);flex-shrink:0}.end-board .board{width:100%}.end-summary footer .big{width:100%;max-width:330px}.end-reason{font-weight:bold}.end-summary .cell{cursor:default}.update-guide-link{margin-top:6px}@media(orientation:landscape){.end-summary{display:grid;grid-template-columns:minmax(200px,1fr) minmax(180px,280px);align-content:start;align-items:center;justify-items:center;padding:12px 24px;gap:10px 24px}.end-summary header{grid-column:1;grid-row:1}.end-score{grid-column:1;grid-row:2}.end-board{grid-column:2;grid-row:1/4;width:min(100%,240px)}.end-summary footer{grid-column:1;grid-row:3}}

.end-summary .cell.empty{background:#d8d2c6;border-color:#8c8074}.end-summary .cell.empty .slot{color:#4b4037;opacity:1}.update-guide-modal .panel{padding-top:54px}.update-guide-modal h2{padding:0;margin-top:0}
.update-guide-modal .panel>.row:last-child{position:static;background:none;padding:12px 0;margin:0!important}.update-guide-modal .panel{padding-bottom:12px}.update-guide-modal .panel>button:not(.xbtn){margin:14px 0}.update-guide-modal .panel a{display:inline-block;padding:8px 2px}html.land .update-guide-modal .panel{display:block;max-width:680px}
