/* ЗГЕНЕРОВАНО design/build-home.py з макетів Claude Design — руками не правити, правки в design/home-extra.css */
/* ================= ТОКЕНИ БАЗИ: світла/темна тема міняє тільки «стіл» ================= */
.h2-app{
  --ease-out:cubic-bezier(.22,.8,.3,1); --ease-back:cubic-bezier(.3,1.5,.5,1); --spring:cubic-bezier(.2,2.2,.4,1);
  --red:#d3443c; --red2:#e4534a; --goldFill:#e8b93c; --onGold:#2b2826;
  --leaf1:#e8b93c; --leaf2:#f2cf63; --leaf3:#c9992a;
}
.h2-app.h2-theme-dark{
  --bg1:#221f1d; --bg2:#191715;
  --glass:rgba(46,42,39,.62); --panel:#2e2a27; --panel2:#38332f; --line:rgba(243,234,217,.14);
  --gold:#e8b93c; --txt:#f3ead9; --dim:#b5aa9b; --mute:#8a8073;
  --bark:#8a6a48; --edge:rgba(0,0,0,.34);
  --blob1:#4b2142; --blob2:#2e6f40; --blob3:#976e65; --blobO:.5;
}
/* яскравіша палітра: той самий стіл на пару тонів світліший, речі соковитіші */
.h2-app.h2-theme-vivid{
  --bg1:#322b27; --bg2:#27211e;
  --glass:rgba(66,58,52,.6); --panel:#423a34; --panel2:#50463f; --line:rgba(255,244,224,.2);
  --gold:#f7cc4d; --txt:#fff6e6; --dim:#d0c2af; --mute:#a39684;
  --bark:#a67c52; --edge:rgba(0,0,0,.3);
  --blob1:#8a2f78; --blob2:#3fa25c; --blob3:#e2895f; --blobO:.62;
  --goldFill:#f7cc4d; --leaf1:#f7cc4d; --leaf2:#ffe07a; --leaf3:#e0a92e;
}
.h2-theme-vivid .h2-table,.h2-theme-vivid .h2-chips{filter:saturate(1.3) brightness(1.1)}
.h2-app.h2-theme-light{
  --bg1:#f4eee2; --bg2:#ebe2d0;
  --glass:rgba(255,250,242,.66); --panel:#fffaf2; --panel2:#f1e8d8; --line:rgba(43,40,38,.14);
  --gold:#7d5a1c; --txt:#2b2826; --dim:#6b6157; --mute:#94897c;
  --bark:#6b4a2f; --edge:rgba(70,52,30,.22);
  --blob1:#d8bfd8; --blob2:#81aa8e; --blob3:#f3d99b; --blobO:.7;
}

/* ================= ПАЛІТРИ РЕЧЕЙ: --g колір речі, --gi чорнило на ній ================= */
.h2-h-durak{--g:#f3d99b;--gi:#2e282f}.h2-h-uno{--g:#d98c6d;--gi:#2e282f}.h2-h-bj{--g:#81aa8e;--gi:#2e282f}.h2-h-poker{--g:#615a73;--gi:#f6ecd9}
.h2-h-ruleta{--g:#e4534a;--gi:#2a1a1a}
.h2-h-chess{--g:#cfac89;--gi:#2e282f}.h2-h-checkers{--g:#715656;--gi:#f6ecd9}.h2-h-tafl{--g:#715656;--gi:#f6ecd9}.h2-h-bezier{--g:#cfac89;--gi:#2e282f}
.h2-h-bomber{--g:#5f4942;--gi:#f6ecd9}.h2-h-request{--g:#433c43;--gi:#f6ecd9}
.h2-h-paper{--g:#f4e9d8;--gi:#4b2142}
.h2-h-arcade{--g:#2e6f40;--gi:#f2f7ef}.h2-h-mc{--g:#7a5c3e;--gi:#f2e8c9}
.h2-h-beta{--g:#c9a46c;--gi:#2e2a24}.h2-h-farm{--g:#7d9a6a;--gi:#1f1c18}
.h2-h-luck{--g:#e8b93c;--gi:#2b2826}

/* ================= КАРКАС ================= */
.h2-app{position:relative;width:390px;height:844px;overflow:hidden;box-sizing:border-box;
  font-family:Rubik,system-ui,sans-serif;color:var(--txt);background:linear-gradient(var(--bg1),var(--bg2))}
.h2-app *{box-sizing:border-box}
.h2-app button{font:inherit;color:inherit;cursor:pointer;-webkit-tap-highlight-color:transparent}
/* іконки: дуотон — контур 2px + напівпрозора заливка тим самим кольором */
.h2-app svg.h2-ln{fill:currentColor;fill-opacity:.26;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.h2-scene{position:absolute;inset:0;transition:filter .4s var(--ease-out),transform .4s var(--ease-out)}
.h2-ph-launch .h2-scene{filter:blur(12px) brightness(.55);transform:scale(.96)}
.h2-scroll{position:absolute;inset:0;overflow-y:auto;overflow-x:hidden;padding:20px 16px 32px;display:flex;flex-direction:column}

/* живе тло: три розмиті плями повільно пливуть */
.h2-blob{position:absolute;width:320px;height:320px;border-radius:50%;filter:blur(64px);opacity:var(--blobO)}
.h2-bl1{left:-120px;top:120px;background:var(--blob1);animation:h2drift1 19s ease-in-out infinite alternate}
.h2-bl2{right:-140px;top:330px;background:var(--blob2);animation:h2drift2 23s ease-in-out infinite alternate}
.h2-bl3{left:40px;bottom:-140px;background:var(--blob3);animation:h2drift3 27s ease-in-out infinite alternate}
@keyframes h2drift1{to{transform:translate(170px,150px) scale(1.2)}}
@keyframes h2drift2{to{transform:translate(-190px,-170px) scale(.85)}}
@keyframes h2drift3{to{transform:translate(120px,-230px) scale(1.15)}}

/* ================= ВІДЧУТТЯ НАТИСКУ =================
   .press — будь-яка кнопка. Палець вниз: річ нахиляється до точки дотику і втискається в стіл (0,09 с).
   Палець вгору: пружинить назад з перельотом (0,55 с, --spring). --rx/--ry ставить JS з точки дотику. */
.h2-press{transition:transform .55s var(--spring),box-shadow .25s var(--ease-out),filter .25s var(--ease-out)}
.h2-press.h2-pressed{transition:transform .09s var(--ease-out),box-shadow .09s var(--ease-out),filter .09s var(--ease-out);
  transform:perspective(700px) rotateX(var(--rx,0deg)) rotateY(var(--ry,0deg)) translateY(4px) scale(.965);
  box-shadow:0 2px 0 var(--edge);filter:brightness(.94)}
.h2-gcard.h2-press.h2-pressed{transform:translateY(-18px) scale(1.08);box-shadow:0 18px 22px rgba(0,0,0,.4);filter:none;z-index:5}
.h2-sq.h2-press.h2-pressed,.h2-glass.h2-press.h2-pressed,.h2-ktag.h2-press.h2-pressed{box-shadow:none}
.h2-sq.h2-press.h2-pressed{transform:scale(.94);filter:brightness(.88)}

/* наведення мишкою: річ трохи піднімається, її іконка оживає */
.h2-app svg{transform-box:fill-box;transform-origin:50% 60%}
@media (hover:hover){
  .h2-press:hover:not(.h2-pressed){transform:translateY(-3px)}
  .h2-gcard.h2-press:hover:not(.h2-pressed){transform:translateY(-12px) scale(1.04);z-index:4}
  .h2-sq.h2-press:hover:not(.h2-pressed){transform:none;filter:brightness(1.07)}
  .h2-press:hover svg{animation:h2wig .7s var(--ease-back) both}
  .h2-press:hover .h2-doodle,.h2-press:hover .h2-pad{animation:h2hop .6s var(--ease-back) both}
  .h2-tkt:hover .h2-tktStub{animation:h2hop .6s var(--ease-back) both}
  .h2-stars svg:nth-child(2){animation-delay:.08s}.h2-stars svg:nth-child(3){animation-delay:.16s}
}
@keyframes h2wig{0%{transform:none}30%{transform:rotate(-12deg) scale(1.18)}60%{transform:rotate(9deg) scale(1.12)}100%{transform:none}}
@keyframes h2hop{0%{transform:none}40%{transform:translateY(-8px) rotate(-5deg)}100%{transform:none}}

/* ================= ШАПКА ================= */
.h2-glass{background:var(--glass);border:1px solid var(--line);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px)}
.h2-top{display:flex;gap:8px;align-items:center}
.h2-me{flex:1;min-width:0;display:flex;gap:10px;align-items:center;height:64px;padding:0 12px 0 8px;border-radius:20px}
.h2-app a.h2-me{color:var(--txt);text-decoration:none}
.h2-ava{width:48px;height:48px;flex:none;border-radius:50%;background:var(--goldFill);color:var(--onGold);
  display:grid;place-items:center;font-weight:700;font-size:22px}
.h2-meCol{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px;align-items:flex-start}
.h2-meName.h2-two{white-space:normal;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow-wrap:anywhere;line-height:1.1}
.h2-meName{font-weight:700;font-size:16px;line-height:1.15;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.h2-bal{position:relative;display:flex;gap:5px;align-items:center;height:24px;padding:0 10px 0 6px;border-radius:999px;
  background:var(--panel2);color:var(--gold);font-weight:700;font-size:14px}
.h2-bal svg{width:16px;height:16px}
.h2-dot{position:absolute;inset-block-start:-3px;inset-inline-end:-3px;width:9px;height:9px;border-radius:50%;background:var(--red2)}
.h2-iconbtn{width:44px;height:44px;flex:none;display:grid;place-items:center;padding:0;border-radius:14px;color:var(--txt)}
.h2-iconbtn svg{width:22px;height:22px}

.h2-meRow{display:flex;gap:6px;align-items:center;min-width:0;align-self:stretch}
/* 1.3.7: the coin pill never sticks out of the profile card — it may shrink, and home2.js shrinks its font */
.h2-meRow .h2-bal{flex:none;white-space:nowrap;padding:0 8px 0 5px;gap:4px}
.h2-meRow .h2-bal svg{flex:none}
.h2-meRow .h2-bal.h2-noico svg{display:none}
/* 1.3.7: a tighter header so the name and balance get room next to 4 icon buttons */
.h2-top{gap:6px}
.h2-top .h2-iconbtn{width:40px}
.h2-top .h2-me{gap:8px;padding:0 10px 0 7px}
.h2-top .h2-ava{width:44px;height:44px}
.h2-streak{display:flex;gap:3px;align-items:center;height:24px;padding:0 9px 0 5px;border-radius:999px;background:var(--panel2);color:var(--red2);font-weight:700;font-size:14px}
.h2-streak svg{width:16px;height:16px}
.h2-chips{display:flex;gap:8px;margin-top:10px;align-items:stretch}
.h2-chip{flex:1;min-width:0;min-height:60px;display:flex;flex-direction:column;gap:5px;align-items:flex-start;justify-content:center;padding:8px 10px;border-radius:18px;text-align:start}
.h2-chip>svg{width:20px;height:20px;color:var(--gold)}
.h2-chip.h2-sm{flex:0 0 62px;align-items:center;padding:8px 4px}
.h2-chip.h2-fire>svg{width:24px;height:24px;color:var(--red2)}
.h2-chip.h2-fire .h2-chipT{font-size:14px}
.h2-chipT{font-weight:700;font-size:11.5px;line-height:1.15}
.h2-stars{display:flex;gap:3px;color:var(--mute)}
.h2-stars svg{width:17px;height:17px}
.h2-app .h2-stars svg{fill-opacity:0}
/* білетик — Удача */
.h2-tkt{position:relative;flex:0 0 114px;min-width:0;min-height:60px;display:flex;padding:0;border:0;border-radius:10px;text-align:start;
  background:var(--g);rotate:-2deg;box-shadow:0 5px 0 var(--edge)}
.h2-app button.h2-tkt{color:var(--gi)}
.h2-tkt::before,.h2-tkt::after{content:"";position:absolute;top:50%;width:14px;height:14px;margin-top:-7px;border-radius:50%;background:var(--bg1)}
.h2-tkt::before{left:-7px}.h2-tkt::after{right:-7px}
.h2-tktMain{flex:1;min-width:0;display:flex;flex-direction:column;justify-content:center;gap:4px;padding:8px 4px 8px 14px}
.h2-tktT{font-weight:700;font-size:15px;line-height:1.1}
.h2-stamp{align-self:flex-start;padding:1px 5px;border:1.5px solid currentColor;border-radius:3px;font-size:8.5px;font-weight:700;letter-spacing:.12em;rotate:-4deg}
.h2-tktStub{width:34px;flex:none;display:grid;place-items:center;margin-inline-end:8px;border-inline-start:2px dashed currentColor;font-weight:700;font-size:27px;line-height:1}

.h2-brand{margin:14px auto 0;padding:0;background:none;border:0;display:flex;flex-direction:column;align-items:center}
.h2-brandTop{font-size:12px;line-height:16px;letter-spacing:.32em;color:var(--dim);font-weight:500;padding-inline-start:.32em}
.h2-brandName{font-family:Pacifico,cursive;font-size:46px;line-height:60px;color:var(--txt)}

/* ================= РЕЧІ НА СТОЛІ ================= */
.h2-table{display:flex;flex-direction:column;gap:18px;margin-top:16px}
.h2-obj{position:relative;display:block;width:100%;padding:0;border:0;background:none;text-align:start}
.h2-app button.h2-obj{color:var(--gi)}
.h2-gname{display:block;font-weight:700;font-size:19px;line-height:1.15}
.h2-gsub{display:block;margin-top:3px;font-size:12.5px;line-height:1.3}
.h2-obj svg{fill:currentColor;fill-opacity:.26;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.h2-app .h2-obj svg.h2-doodle,.h2-app .h2-ps svg{fill:none}

/* 1. набій — Весела Рулетка */
/* реалістичний набій: латунне денце з металевим відблиском, ребристий пластиковий корпус, закатаний край */
.h2-shell{display:flex;min-height:96px;border-radius:5px 18px 18px 5px;overflow:hidden;rotate:-1.5deg;
  box-shadow:0 14px 18px rgba(0,0,0,.5),0 3px 4px rgba(0,0,0,.4);
  background:
    repeating-linear-gradient(0deg,rgba(0,0,0,.11) 0 1px,rgba(255,255,255,0) 1px 7px),
    linear-gradient(180deg,#7a1e19 0%,#c23830 10%,#ee6258 26%,#ff978c 35%,#f06a5f 43%,#e4534a 55%,#bf3a32 76%,#8e2923 92%,#6d1b17 100%)}
.h2-shell.h2-press.h2-pressed{box-shadow:0 4px 6px rgba(0,0,0,.55)}
.h2-shCap{position:relative;display:block;width:62px;flex:none;
  background:linear-gradient(180deg,#4d3814 0%,#a67f33 9%,#dcb961 22%,#fff3c4 34%,#f3d98c 41%,#cfa64c 56%,#a57c2f 76%,#6b4f1d 92%,#3f2d0f 100%);
  box-shadow:inset -3px 0 3px rgba(0,0,0,.45),inset 2px 0 2px rgba(255,255,255,.35)}
.h2-shRim{position:absolute;inset:0 auto 0 0;width:9px;border-inline-end:2px solid rgba(0,0,0,.45);background:linear-gradient(90deg,rgba(255,255,255,.25),rgba(0,0,0,.18))}
.h2-shKnurl{position:absolute;inset:0 6px 0 auto;width:12px;background:repeating-linear-gradient(90deg,rgba(0,0,0,.34) 0 1px,rgba(255,255,255,.22) 1px 2px,rgba(0,0,0,0) 2px 4px)}
.h2-shBody{flex:1;min-width:0;display:flex;flex-direction:column;justify-content:center;padding:12px 14px}
.h2-shell .h2-gname{font-size:23px;text-shadow:0 1px 0 rgba(255,255,255,.28)}
.h2-shCrimp{display:block;width:30px;flex:none;
  background:radial-gradient(120% 60% at 100% 50%,rgba(0,0,0,.6),rgba(0,0,0,0) 72%),
    repeating-linear-gradient(0deg,rgba(0,0,0,.28) 0 2px,rgba(0,0,0,0) 2px 12px);
  box-shadow:inset 2px 0 2px rgba(0,0,0,.35)}

/* детонація набою: 0,7 с перед стартом гри */
.h2-is-boom .h2-scene{animation:h2shake .5s linear both}
.h2-is-boom .h2-shell{animation:h2recoil .7s var(--ease-out) both}
.h2-boom{position:absolute;inset:0;z-index:5;pointer-events:none;overflow:hidden}
.h2-boom i{position:absolute;left:var(--bx);top:var(--by);display:block}
.h2-bWhite{inset:0;left:0!important;top:0!important;width:100%;height:100%;background:#fff;animation:h2whiteOut .32s ease-out both}
.h2-bFlash{width:260px;height:260px;margin:-130px 0 0 -130px;border-radius:50%;mix-blend-mode:screen;filter:blur(6px);
  background:radial-gradient(circle,#fff 0,#fff3b0 16%,#ffb347 36%,rgba(228,83,74,.75) 56%,rgba(228,83,74,0) 72%);
  animation:h2flash .38s cubic-bezier(.1,.8,.2,1) both}
.h2-bCore{width:70px;height:70px;margin:-35px 0 0 -35px;border-radius:50%;background:#fff;filter:blur(3px);animation:h2core .2s ease-out both}
.h2-boom .h2-sp{width:28px;height:3px;margin-top:-1.5px;border-radius:2px;background:linear-gradient(90deg,#fff,#ffd36b 60%,rgba(255,150,60,0));
  transform-origin:0 50%;rotate:var(--a);animation:h2spark .46s cubic-bezier(.1,.7,.3,1) var(--dl,0s) both}
.h2-boom .h2-pl{width:7px;height:7px;margin:-3.5px 0 0 -3.5px;border-radius:50%;background:radial-gradient(circle at 35% 30%,#f2f2f2,#8a8a8a 45%,#2b2b2b);
  rotate:var(--a);animation:h2pellet .56s cubic-bezier(.05,.6,.3,1) .04s both}
.h2-boom .h2-sm{width:96px;height:96px;margin:-48px 0 0 -48px;border-radius:50%;filter:blur(7px);
  background:radial-gradient(circle,rgba(236,230,220,.8),rgba(190,182,172,.45) 45%,rgba(190,182,172,0) 70%);
  animation:h2smoke .7s cubic-bezier(.1,.6,.3,1) var(--dl,.06s) both}
.h2-a0{--a:0deg;--r:190px}.h2-a1{--a:24deg;--r:150px;--dl:.02s}.h2-a2{--a:-21deg;--r:160px}.h2-a3{--a:52deg;--r:120px;--dl:.03s}
.h2-a4{--a:-48deg;--r:130px;--dl:.01s}.h2-a5{--a:88deg;--r:90px;--dl:.04s}.h2-a6{--a:-84deg;--r:96px}.h2-a7{--a:128deg;--r:70px;--dl:.03s}
.h2-a8{--a:-131deg;--r:74px;--dl:.02s}.h2-a9{--a:11deg;--r:210px;--dl:.05s}.h2-a10{--a:-9deg;--r:220px;--dl:.03s}.h2-a11{--a:172deg;--r:60px}
.h2-p0{--a:-26deg;--r:250px}.h2-p1{--a:-18deg;--r:310px}.h2-p2{--a:-11deg;--r:280px}.h2-p3{--a:-4deg;--r:340px}.h2-p4{--a:3deg;--r:300px}
.h2-p5{--a:9deg;--r:330px}.h2-p6{--a:16deg;--r:270px}.h2-p7{--a:23deg;--r:300px}.h2-p8{--a:30deg;--r:240px}
.h2-m0{--sx:70px;--sy:-30px}.h2-m1{--sx:40px;--sy:-80px;--dl:.1s}.h2-m2{--sx:90px;--sy:26px;--dl:.08s}.h2-m3{--sx:-30px;--sy:-50px;--dl:.14s}
@keyframes h2shake{0%{transform:none}8%{transform:translate(-9px,4px) rotate(-.6deg)}18%{transform:translate(8px,-5px) rotate(.5deg)}30%{transform:translate(-6px,3px)}
  44%{transform:translate(4px,-2px)}60%{transform:translate(-2px,1px)}100%{transform:none}}
@keyframes h2recoil{0%{transform:none;filter:brightness(1)}6%{transform:translateX(-22px) rotate(-3deg) scale(1.03);filter:brightness(1.9)}
  22%{transform:translateX(-12px) rotate(-1.5deg);filter:brightness(1.2)}55%{transform:translateX(-7px) rotate(-.5deg);filter:brightness(1)}100%{transform:translateX(-5px);filter:brightness(1)}}
@keyframes h2whiteOut{0%{opacity:0}12%{opacity:.7}100%{opacity:0}}
@keyframes h2flash{0%{transform:scale(.15);opacity:1}35%{transform:scale(1.25);opacity:1}100%{transform:scale(1.7);opacity:0}}
@keyframes h2core{0%{transform:scale(.4);opacity:1}100%{transform:scale(2.2);opacity:0}}
@keyframes h2spark{0%{transform:translateX(8px) scaleX(.4);opacity:1}70%{opacity:1}100%{transform:translateX(var(--r)) scaleX(1.5);opacity:0}}
@keyframes h2pellet{0%{transform:translateX(0);opacity:1}80%{opacity:1}100%{transform:translateX(var(--r));opacity:0}}
@keyframes h2smoke{0%{transform:scale(.25);opacity:0}15%{opacity:.95}100%{transform:translate(var(--sx),var(--sy)) scale(2.4);opacity:0}}

/* 2. рука з картами — Дурень, УНО, Блекджек, Покер */
.h2-hand{position:relative;height:180px}
.h2-gcard{position:absolute;left:var(--l);top:var(--t);width:108px;height:150px;padding:10px;border-radius:12px;
  display:flex;flex-direction:column;justify-content:space-between;
  background:var(--g);rotate:var(--r);transform-origin:50% 130%;box-shadow:0 6px 0 var(--edge)}
.h2-gcard::after{content:"";position:absolute;inset:5px;border:1px solid currentColor;border-radius:8px;opacity:.35;pointer-events:none}
.h2-k1{--l:0px;--t:18px;--r:-8deg}.h2-k2{--l:83px;--t:6px;--r:-3deg}.h2-k3{--l:167px;--t:6px;--r:3deg}.h2-k4{--l:250px;--t:18px;--r:8deg}
.h2-gcIdx{display:flex;flex-direction:column;gap:2px;align-items:flex-start;font-size:11px;font-weight:700;line-height:1}
.h2-gcIdx svg{width:18px;height:18px}
.h2-gcMid{position:absolute;left:50%;top:50%;width:46px;height:46px;margin:-26px 0 0 -23px}
.h2-gcName{display:block;font-weight:700;font-size:15px;line-height:1.1;max-width:84px}
/* гральні карти: стара кремова «сорочка обличчям», кольорове чорнило, потертості */
.h2-k1{--ink:#c9382f}.h2-k2{--ink:#b4552d}.h2-k3{--ink:#2e282f}.h2-k4{--ink:#4d466b}
.h2-app button.h2-gcard{color:var(--ink)}
.h2-gcard{background-color:#f4e8cc;
  box-shadow:0 6px 0 var(--edge),inset 0 0 0 1px rgba(110,76,40,.35),inset 0 0 10px rgba(110,76,40,.22);
  background-image:
    linear-gradient(115deg,rgba(255,255,255,0) 38%,rgba(255,255,255,.5) 38.6%,rgba(255,255,255,0) 39.6%),
    linear-gradient(72deg,rgba(90,60,30,0) 61%,rgba(90,60,30,.2) 61.4%,rgba(90,60,30,0) 62%),
    linear-gradient(160deg,rgba(90,60,30,0) 74%,rgba(90,60,30,.16) 74.3%,rgba(90,60,30,0) 75%),
    linear-gradient(98deg,rgba(90,60,30,0) 22%,rgba(90,60,30,.1) 22.3%,rgba(90,60,30,0) 23%),
    radial-gradient(44px 36px at 100% 100%,rgba(120,84,44,.4),rgba(120,84,44,0)),
    radial-gradient(36px 30px at 0 0,rgba(120,84,44,.3),rgba(120,84,44,0)),
    radial-gradient(30px 26px at 100% 0,rgba(120,84,44,.22),rgba(120,84,44,0)),
    radial-gradient(64px 52px at 30% 68%,rgba(255,255,255,.34),rgba(255,255,255,0)),
    radial-gradient(120% 120% at 50% 50%,rgba(110,76,40,0) 58%,rgba(110,76,40,.3)),
    repeating-linear-gradient(0deg,rgba(0,0,0,.03) 0 1px,rgba(0,0,0,0) 1px 3px)}
.h2-gcard::after{inset:6px;border-width:1.5px;opacity:.45}
.h2-app .h2-gcard svg{fill:currentColor;fill-opacity:1;stroke:none}
.h2-gcIdx{align-items:center;gap:1px}
.h2-gcIdx .h2-rk{font-size:17px;font-weight:700;line-height:1;letter-spacing:-.02em}
.h2-gcIdx svg{width:15px;height:15px}
.h2-gcIdx.h2-inv{display:none}
.h2-gcMid{width:50px;height:50px;margin:-30px 0 0 -25px;opacity:.92}
.h2-gcBot{display:flex;flex-direction:column;gap:2px;align-items:flex-start}
.h2-gcPl{font-size:10.5px;font-weight:700;opacity:.8}

/* 3. дошка — Шахи, Шашки, Тафл, Безьє */
.h2-board{padding:7px;border-radius:16px;background:#5f4942;box-shadow:0 6px 0 var(--edge)}
.h2-boardIn{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));border-radius:10px;overflow:hidden}
.h2-sq{display:flex;flex-direction:column;justify-content:flex-end;min-height:150px;padding:12px;background:var(--g)}
.h2-sq{min-height:168px;padding-top:94px}
/* ілюстрації на клітинках дошки: об'ємні фігури з тінню, світлом і бліком */
.h2-app .h2-obj svg.h2-sqArt{position:absolute;left:6px;right:6px;top:6px;width:calc(100% - 12px);height:86px;fill:none;fill-opacity:1;stroke:none;overflow:visible}
@media (hover:hover){.h2-app .h2-press:hover svg.h2-sqArt{animation:h2hop .6s var(--ease-back) both}}

/* 4. аркуш у клітинку — Ігри на папері */
.h2-sheet{min-height:136px;padding:20px 108px 16px 44px;border-radius:4px;rotate:1.2deg;box-shadow:0 6px 0 var(--edge);
  background-color:var(--g);
  background-image:linear-gradient(90deg,transparent 31px,rgba(75,33,66,.45) 31px,rgba(75,33,66,.45) 32.5px,transparent 32.5px),
    repeating-linear-gradient(0deg,transparent 0 15px,#d8bfd8 15px 16px),
    repeating-linear-gradient(90deg,transparent 0 15px,#d8bfd8 15px 16px)}
.h2-sheet .h2-gname{font-family:Oswald,Rubik,sans-serif;font-weight:600;font-size:22px;line-height:1.2}
.h2-tape{position:absolute;top:-9px;left:42%;width:72px;height:20px;background:#5f7a3a;opacity:.88;rotate:-4deg}
.h2-doodle{position:absolute;inset-block-start:26px;inset-inline-end:16px;width:84px;height:84px}
.h2-app .h2-doodle{stroke-width:2.2}
.h2-doodle .h2-gr{stroke:#5f7a3a}
.h2-doodle .h2-dk{stroke:#2b2b2b}

/* 5. картридж — Класичні Аркади */
.h2-cart{display:flex;gap:10px;align-items:stretch;padding:12px;border:3px solid #3b2f2f;border-radius:8px;background:var(--g);box-shadow:0 6px 0 var(--edge)}
.h2-cartLabel{flex:1;min-width:0;display:flex;flex-direction:column;justify-content:center;padding:14px 12px 12px;border-radius:4px;
  background:#f2f7ef;color:#3b2f2f;border-top:8px solid #f4b266}
.h2-cart .h2-gname{font-family:"Press Start 2P",Rubik,monospace;font-weight:400;font-size:12px;line-height:1.6}
.h2-cart .h2-gsub{margin-top:6px}
.h2-pad{display:block;width:84px;height:92px;flex:none;align-self:center}
/* мультяшний стиль аркад: товстий темний контур, соковита заливка, блік */
.h2-app svg.h2-toon{fill:none;fill-opacity:1;stroke:#3b2f2f;stroke-width:3;stroke-linejoin:round;stroke-linecap:round}
.h2-app svg.h2-toon .h2-hl{stroke:none;fill:#f2f7ef;opacity:.75}

/* 6. ящик і пакетик насіння — Підривник, Ґаздівство */
.h2-pair{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.h2-crate{display:flex;flex-direction:column;justify-content:flex-end;min-height:176px;padding:12px;border:2px solid #433c43;border-radius:6px;
  background-color:var(--g);background-image:repeating-linear-gradient(0deg,transparent 0 34px,rgba(0,0,0,.28) 34px 36px);box-shadow:0 6px 0 var(--edge);rotate:-1deg}
/* ящик: зв'язка динамітних шашок стирчить над верхнім краєм, іскра на ґноті мерехтить */
.h2-pair{margin-top:22px}
.h2-crate::before{content:"";position:absolute;left:-5px;right:-5px;top:-3px;height:20px;z-index:1;border:2px solid #2e2320;border-radius:4px;
  background:radial-gradient(circle at 10px 50%,#1d1513 0 2.500px,rgba(0,0,0,0) 3px),radial-gradient(circle at calc(100% - 10px) 50%,#1d1513 0 2.500px,rgba(0,0,0,0) 3px),
    linear-gradient(180deg,#6b5148,#4a3832);box-shadow:0 3px 4px rgba(0,0,0,.35)}
.h2-app .h2-obj svg.h2-dyn{position:absolute;left:20%;top:-30px;width:60%;height:42px;fill:none;fill-opacity:1;stroke:none;overflow:visible;
  clip-path:inset(-30px -20px 0 -20px)}
/* дерево ящика: дошки зі щілинами, волокна, сучок, бічні планки з цвяхами, потертості й тіні */
.h2-app .h2-crate{width:80%;min-height:138px;justify-self:center;align-self:end;margin-bottom:6px}
.h2-crate .h2-gname{font-size:16px}
.h2-crate .h2-gsub{font-size:11.500px}
.h2-app .h2-crate{padding:10px 18px;border:0;border-radius:5px;background-color:#6a4c3b;
  box-shadow:0 12px 16px rgba(0,0,0,.45),0 3px 4px rgba(0,0,0,.4),inset 0 -10px 14px rgba(0,0,0,.38),inset 0 0 0 2px #2e2320;
  text-shadow:0 1px 2px rgba(0,0,0,.6);
  background-image:
    radial-gradient(circle at 7px 22%,#1d1513 0 2px,rgba(0,0,0,0) 2.600px),radial-gradient(circle at 7px 78%,#1d1513 0 2px,rgba(0,0,0,0) 2.600px),
    radial-gradient(circle at calc(100% - 7px) 22%,#1d1513 0 2px,rgba(0,0,0,0) 2.600px),radial-gradient(circle at calc(100% - 7px) 78%,#1d1513 0 2px,rgba(0,0,0,0) 2.600px),
    linear-gradient(90deg,rgba(0,0,0,.3) 0 14px,rgba(255,255,255,.12) 14px 15px,rgba(0,0,0,0) 15px calc(100% - 15px),rgba(0,0,0,.4) calc(100% - 15px) calc(100% - 14px),rgba(0,0,0,.3) calc(100% - 14px)),
    linear-gradient(180deg,rgba(0,0,0,.6) 0,rgba(0,0,0,0) 36px),
    linear-gradient(118deg,rgba(255,255,255,0) 44%,rgba(255,255,255,.18) 44.400%,rgba(255,255,255,0) 45.200%),
    linear-gradient(76deg,rgba(0,0,0,0) 68%,rgba(0,0,0,.3) 68.300%,rgba(0,0,0,0) 69%),
    linear-gradient(101deg,rgba(255,255,255,0) 24%,rgba(255,255,255,.1) 24.300%,rgba(255,255,255,0) 25%),
    radial-gradient(54px 14px at 68% 30%,rgba(255,255,255,.14),rgba(255,255,255,0)),
    radial-gradient(44px 12px at 30% 60%,rgba(0,0,0,.3),rgba(0,0,0,0)),
    radial-gradient(circle at 76% 52%,rgba(0,0,0,.45) 0 2.500px,rgba(0,0,0,.16) 3.500px 6px,rgba(0,0,0,0) 7.500px),
    repeating-linear-gradient(0deg,rgba(0,0,0,.6) 0 2px,rgba(255,255,255,.13) 2px 3px,rgba(0,0,0,0) 3px 42px),
    repeating-linear-gradient(2deg,rgba(0,0,0,.1) 0 1px,rgba(0,0,0,0) 1px 5px),
    repeating-linear-gradient(-1.500deg,rgba(255,255,255,.06) 0 1px,rgba(0,0,0,0) 1px 9px),
    linear-gradient(90deg,rgba(0,0,0,.25),rgba(0,0,0,0) 30%,rgba(0,0,0,0) 70%,rgba(0,0,0,.3))}
.h2-dyn .h2-spk{transform-box:fill-box;transform-origin:center;animation:h2spk .28s steps(2) infinite alternate}
@keyframes h2spk{from{transform:scale(.7) rotate(0deg);opacity:.75}to{transform:scale(1.25) rotate(40deg);opacity:1}}
@media (hover:hover){.h2-app .h2-press:hover svg.h2-dyn{animation:h2hop .6s var(--ease-back) both}}
.h2-stencil{position:absolute;inset-block-start:10px;inset-inline-end:10px;width:48px;height:48px;border-radius:4px;background:#e4534a;color:#2a1a1a;display:grid;place-items:center}
.h2-stencil svg{width:30px;height:30px}
.h2-seed{display:flex;flex-direction:column;min-height:176px;padding:0 10px 12px;border-radius:8px;overflow:hidden;
  background:#f2e8c9;box-shadow:0 6px 0 var(--edge);rotate:1deg}
.h2-crimp{display:block;height:14px;margin:0 -10px 8px;background:repeating-linear-gradient(90deg,#7d9a6a 0 5px,#6b8759 5px 10px);border-bottom:2px solid #2e2a24}
.h2-win{display:block;width:100%;height:76px;flex:none;margin-bottom:8px;border-radius:6px;border:2px solid #2e2a24;background:#cfe6d3}
.h2-seed .h2-tag{position:absolute;top:30px;left:16px;background:#2e2a24;color:#f2e8c9}
.h2-seed .h2-sun{transform-box:fill-box;transform-origin:center;animation:h2spin 14s linear infinite}
@media (hover:hover){.h2-app .h2-press:hover .h2-win{animation:none}.h2-seed:hover .h2-sprout{transform-box:fill-box;transform-origin:50% 100%;animation:h2hop .6s var(--ease-back) both}}
.h2-app button.h2-seed{color:#2e2a24}
.h2-flap{position:absolute;inset:0 0 auto 0;height:32px;border-radius:6px 6px 0 0;background:var(--g);border-bottom:2px dashed #2e2a24;
  display:flex;align-items:center;padding:0 10px}
.h2-seedIco{position:absolute;inset-block-start:42px;inset-inline-end:10px;width:40px;height:40px;color:#5f7a3a}
.h2-tag{height:18px;padding:0 8px;border-radius:999px;background:#f2e8c9;color:#2e2a24;font-size:10.5px;font-weight:700;letter-spacing:.12em;display:flex;align-items:center}

/* 7. блок — Minecraft SMP */
.h2-block{min-height:104px;padding:38px 78px 12px 14px;border-radius:3px;background:var(--g);box-shadow:0 6px 0 var(--edge);
  background-image:linear-gradient(#7fb069,#7fb069),repeating-linear-gradient(90deg,#7fb069 0 16px,transparent 16px 32px);
  background-size:100% 18px,100% 8px;background-position:0 0,0 18px;background-repeat:no-repeat}
/* банер Minecraft SMP: піксельний пейзаж на заході сонця, блоковий заголовок, піксельний опис */
.h2-app .h2-block{min-height:168px;padding:0;display:flex;flex-direction:column;justify-content:flex-end;overflow:hidden;
  border:3px solid #2e2320;border-radius:4px;background:#2b2350}
.h2-app .h2-obj svg.h2-mcArt{position:absolute;inset:0;width:100%;height:100%;fill:none;fill-opacity:1;stroke:none}
.h2-mcArt path{stroke-width:1.02}
.h2-mcArt .h2-tw{animation:h2blink 1.6s steps(2) infinite}
.h2-app a.h2-block{color:#fff;text-decoration:none}
.h2-mcShade{position:absolute;inset:0;background:linear-gradient(180deg,rgba(18,12,30,0) 34%,rgba(18,12,30,.9) 80%)}
.h2-mcT{position:relative;display:block;padding:0 14px;font-family:"Press Start 2P",Rubik,monospace;font-size:17px;line-height:1.35;color:#ffffff;
  text-shadow:3px 0 0 #3b2f2f,-3px 0 0 #3b2f2f,0 -3px 0 #3b2f2f,0 3px 0 #3b2f2f,3px 3px 0 #3b2f2f,-3px 3px 0 #3b2f2f,3px -3px 0 #3b2f2f,-3px -3px 0 #3b2f2f,0 7px 0 rgba(0,0,0,.55)}
.h2-mcS{position:relative;display:block;padding:9px 14px 12px;font-family:"Pixelify Sans",Rubik,system-ui,sans-serif;font-size:14px;line-height:1.25;color:#f6ecd9}
@media (hover:hover){.h2-app .h2-press:hover svg.h2-mcArt{animation:none}.h2-block:hover .h2-mcT{animation:h2hop .5s steps(4) both}}

/* 8. подарунок — Ігри на прохання */
.h2-gift{min-height:100px;padding:16px 96px 14px 14px;border-radius:8px;background:var(--g);box-shadow:0 6px 0 var(--edge);overflow:hidden}
.h2-ribV{position:absolute;inset-block:0;inset-inline-end:44px;width:18px;background:#e4534a}
.h2-ribH{position:absolute;inset-inline:0;top:50%;height:6px;margin-top:-3px;background:#e4534a;opacity:.35}
.h2-bow{position:absolute;inset-block-start:10px;inset-inline-end:33px;width:40px;height:40px;color:#f3d99b}
.h2-gift .h2-gsub{display:flex;gap:5px;align-items:flex-start}
.h2-lock{width:14px;height:14px;flex:none;margin-top:1px}
.h2-gift .h2-gname,.h2-gift .h2-gsub{position:relative}

/* 9. крафтова бирка — БЕТА-ігри */
.h2-ktag{min-height:104px;padding:16px 78px 16px 58px;background:var(--g);rotate:-1.2deg;
  clip-path:polygon(30px 0,100% 0,100% 100%,30px 100%,0 50%)}
.h2-ktag::after{content:"";position:absolute;inset:6px 6px 6px 40px;border:1.5px dashed #7a5c3e;border-radius:4px;pointer-events:none}
.h2-hole{position:absolute;left:22px;top:50%;width:14px;height:14px;margin-top:-7px;border-radius:50%;background:var(--bg1);border:2px solid #7a5c3e}
.h2-flask{position:absolute;inset-block-start:50%;inset-inline-end:18px;width:52px;height:52px;margin-top:-26px;border-radius:50%;background:#7d9a6a;display:grid;place-items:center}
.h2-flask svg{width:28px;height:28px}

/* ================= НИЗ ================= */
.h2-join{display:flex;gap:8px;margin-top:24px}
.h2-code{width:108px;height:48px;flex:none;border-radius:14px;background:var(--panel);border:1px solid var(--line);
  color:var(--txt);font:inherit;font-weight:700;font-size:16px;letter-spacing:.3em;text-align:center}
.h2-code::placeholder{color:var(--mute)}
.h2-btn{flex:1;min-width:0;min-height:48px;padding:8px 14px;border-radius:14px;border:0;font-weight:700;font-size:16px;box-shadow:0 5px 0 var(--edge)}
.h2-app .h2-btn.h2-primary{background:var(--red);color:#fff}
.h2-secT{margin-top:22px;font-size:12px;letter-spacing:.24em;color:var(--dim);font-weight:500}
.h2-empty{margin-top:10px;font-size:14px;line-height:1.4;color:var(--dim)}
.h2-foot{margin-top:20px;display:flex;flex-wrap:wrap;gap:4px 12px;justify-content:center;font-size:13px;color:var(--dim)}
.h2-foot a,.h2-foot span{min-height:44px;display:flex;align-items:center}

/* ================= АНІМАЦІЯ 1: ДЕРЕВО → ГОЛОВНА ================= */
.h2-tree{position:absolute;inset:0;pointer-events:none;overflow:hidden;z-index:3}
.h2-trunk{position:absolute;left:115px;top:260px;width:160px;height:340px;color:var(--bark);transform-origin:50% 100%;
  animation:h2treeGrow .7s var(--ease-back) 0s both, h2treeGone .5s var(--ease-out) 1.9s forwards}
.h2-crown{position:absolute;left:var(--x);top:var(--y);width:var(--s);height:var(--s);
  margin:calc(var(--s) / -2) 0 0 calc(var(--s) / -2);border-radius:50%;background:var(--c);
  animation:h2crownPop .5s var(--ease-back) calc(.75s + var(--i) * 60ms) both,
            h2crownFly .7s var(--ease-out) calc(1.9s + var(--i) * 40ms) forwards}
.h2-c1{--i:0;--x:195px;--y:280px;--s:124px;--c:var(--leaf1);--tx:0px;--ty:-80px}
.h2-c2{--i:1;--x:135px;--y:320px;--s:100px;--c:var(--leaf2);--tx:-18px;--ty:-268px}
.h2-c3{--i:2;--x:255px;--y:320px;--s:100px;--c:var(--leaf3);--tx:-60px;--ty:-200px}
.h2-c4{--i:3;--x:165px;--y:365px;--s:96px;--c:var(--leaf3);--tx:-45px;--ty:-63px}
.h2-c5{--i:4;--x:228px;--y:368px;--s:92px;--c:var(--leaf1);--tx:42px;--ty:-66px}
.h2-c6{--i:5;--x:105px;--y:370px;--s:76px;--c:var(--leaf1);--tx:-51px;--ty:90px}
.h2-c7{--i:6;--x:288px;--y:370px;--s:76px;--c:var(--leaf2);--tx:16px;--ty:90px}
.h2-c8{--i:7;--x:150px;--y:265px;--s:82px;--c:var(--leaf2);--tx:-13px;--ty:185px}
.h2-c9{--i:8;--x:242px;--y:262px;--s:82px;--c:var(--leaf3);--tx:-22px;--ty:188px}
.h2-leaf{position:absolute;left:var(--x);top:var(--y);width:12px;height:12px;border-radius:0 70% 0 70%;background:var(--leaf2);opacity:0;
  animation:h2leafFall 1.3s cubic-bezier(.4,0,.8,.6) var(--dl) both}
.h2-l1{--x:120px;--y:330px;--fx:-40px;--dl:1.75s}.h2-l2{--x:180px;--y:300px;--fx:30px;--dl:1.85s}
.h2-l3{--x:230px;--y:340px;--fx:-20px;--dl:1.8s}.h2-l4{--x:280px;--y:320px;--fx:44px;--dl:1.95s}
.h2-l5{--x:150px;--y:380px;--fx:18px;--dl:2s}.h2-l6{--x:256px;--y:378px;--fx:-34px;--dl:1.9s}
.h2-treeMark{position:absolute;left:0;right:0;top:620px;text-align:center;font-size:12px;letter-spacing:.32em;color:var(--dim);font-weight:500;
  animation:h2markIn .4s var(--ease-out) .9s both, h2markOut .3s var(--ease-out) 1.8s forwards}

.h2-is-intro .h2-in{animation:h2uiIn .5s var(--ease-back) calc(2.05s + var(--d) * 45ms) both}
.h2-is-intro .h2-gcard.h2-in{animation-name:h2dealIn;animation-duration:.6s}
.h2-d0{--d:0}.h2-d1{--d:1}.h2-d2{--d:2}.h2-d3{--d:3}.h2-d4{--d:4}.h2-d5{--d:5}.h2-d6{--d:6}.h2-d7{--d:7}.h2-d8{--d:8}.h2-d9{--d:9}.h2-d10{--d:10}.h2-d11{--d:11}.h2-d12{--d:12}

@keyframes h2treeGrow{from{transform:scale(.25,0)}to{transform:none}}
@keyframes h2treeGone{to{transform:translateY(60px) scale(.9);opacity:0}}
@keyframes h2crownPop{from{transform:scale(0)}to{transform:none}}
@keyframes h2crownFly{from{transform:none;opacity:1}to{transform:translate(var(--tx),var(--ty)) scale(2.4);opacity:0}}
@keyframes h2leafFall{0%{transform:none;opacity:0}15%{opacity:1}100%{transform:translate(var(--fx),420px) rotate(320deg);opacity:0}}
@keyframes h2markIn{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}
@keyframes h2markOut{to{opacity:0}}
@keyframes h2uiIn{from{opacity:0;transform:scale(.55)}to{opacity:1;transform:none}}
@keyframes h2dealIn{from{opacity:0;transform:translateY(120px) rotate(-30deg) scale(.7)}to{opacity:1;transform:none}}

/* ================= АНІМАЦІЯ 2: СТАРТ ГРИ (звичайний) ================= */
.h2-launch{position:absolute;inset:0;overflow:hidden;z-index:4;display:flex;flex-direction:column;align-items:center;justify-content:center;
  padding:24px;text-align:center;color:var(--gi)}
.h2-lFlood{position:absolute;left:var(--lx,195px);top:var(--ly,422px);width:120px;height:120px;margin:-60px 0 0 -60px;border-radius:50%;
  background:var(--g);animation:h2flood .6s var(--ease-out) both}
/* яскравіший перелив поверх заливки: світлі промені повільно крутяться, під іконкою сяйво */
.h2-lSheen{position:absolute;left:-55%;top:-20%;width:210%;height:140%;filter:blur(30px);
  background:conic-gradient(from 0deg,rgba(255,255,255,0),rgba(255,255,255,.34),rgba(255,255,255,0) 28%,rgba(255,236,170,.3) 52%,rgba(255,255,255,0) 74%,rgba(255,255,255,.2) 90%,rgba(255,255,255,0));
  animation:h2fadeIn .6s var(--ease-out) .35s both, h2spin 12s linear infinite}
.h2-lGlow{position:absolute;left:50%;top:350px;width:300px;height:300px;margin:-150px 0 0 -150px;border-radius:50%;
  background:radial-gradient(circle,rgba(255,255,255,.5),rgba(255,255,255,0) 68%);animation:h2fadeIn .5s var(--ease-out) .4s both, h2pulse 2.4s ease-in-out 1s infinite alternate}
@keyframes h2pulse{to{transform:scale(1.15);opacity:.7}}
.h2-lRing{position:absolute;left:50%;top:350px;width:150px;height:150px;margin:-75px 0 0 -75px;border-radius:50%;
  border:2px solid var(--gi);opacity:0;animation:h2ring .8s var(--ease-out) both}
.h2-lRing.h2-r1{animation-delay:.55s}.h2-lRing.h2-r2{animation-delay:.72s}
.h2-lIcon{position:relative;width:132px;height:132px;border-radius:50%;display:grid;place-items:center;
  background:var(--gi);color:var(--g);animation:h2iconIn .6s var(--ease-back) .2s both}
.h2-lIcon svg{width:72px;height:72px}
/* УНО: на екрані старту замість круглої іконки — велика картка «+4» */
.h2-lCardC,.h2-lCardBig{display:none}
.h2-h-uno .h2-lIcon{width:132px;height:184px;border-radius:14px;rotate:-7deg;background:#f4e8cc;color:#b4552d;
  box-shadow:0 14px 22px rgba(0,0,0,.35),inset 0 0 0 7px #f4e8cc,inset 0 0 0 9px #b4552d,inset 0 0 14px rgba(110,76,40,.3)}
.h2-h-uno .h2-lIcon svg{display:none}
.h2-h-uno .h2-lCardBig{display:block;font-weight:700;font-size:60px;line-height:1;letter-spacing:-.03em;rotate:-8deg}
.h2-h-uno .h2-lCardC{display:block;position:absolute;left:16px;top:15px;font-weight:700;font-size:17px;line-height:1}
.h2-h-uno .h2-lCardC.h2-inv{left:auto;top:auto;right:16px;bottom:15px;rotate:180deg}
.h2-app .h2-gcard svg.h2-art{width:58px;height:58px;margin:-36px 0 0 -29px;opacity:1}
/* УНО: червона картка, нахилена кремова плашка «+4», чотири кольори гри */
.h2-k2{--ink:#fff3dc}
.h2-gcard.h2-k2{background-color:#d8342b}
.h2-k2 .h2-gcIdx svg{display:none}
.h2-unoMid{position:absolute;left:50%;top:50%;width:68px;height:46px;margin:-34px 0 0 -34px;border-radius:14px;rotate:-18deg;
  display:grid;place-items:center;background:#fff3dc;color:#d8342b;border:3px solid #2e282f;font-weight:700;font-size:27px;line-height:1;letter-spacing:-.03em}
.h2-unoDots{position:absolute;top:12px;right:12px;display:grid;grid-template-columns:7px 7px;gap:2px}
.h2-unoDots i{display:block;width:7px;height:7px;border-radius:2px;border:1px solid #2e282f}
.h2-unoDots i:nth-child(1){background:#fff3dc}.h2-unoDots i:nth-child(2){background:#e9b420}.h2-unoDots i:nth-child(3){background:#2d9a4e}.h2-unoDots i:nth-child(4){background:#2567c8}
.h2-app .h2-h-uno .h2-lIcon{background:#d8342b;color:#fff3dc;
  box-shadow:0 14px 22px rgba(0,0,0,.35),inset 0 0 0 7px #d8342b,inset 0 0 0 9px #fff3dc,inset 0 0 14px rgba(0,0,0,.25)}
.h2-app .h2-h-uno .h2-lCardBig{padding:10px 12px;border-radius:18px;background:#fff3dc;color:#d8342b;border:4px solid #2e282f;font-size:52px;rotate:-12deg}
.h2-lName{position:relative;margin-top:22px;font-family:Oswald,Rubik,sans-serif;font-weight:600;font-size:32px;line-height:1.25;animation:h2riseIn .4s var(--ease-out) .55s both}
.h2-lSub{position:relative;margin-top:6px;max-width:280px;font-size:14px;line-height:1.4;animation:h2riseIn .4s var(--ease-out) .65s both}
.h2-lBar{position:relative;margin-top:28px;width:160px;height:10px;padding:2px;border-radius:999px;border:1.5px solid var(--gi);animation:h2riseIn .3s var(--ease-out) .75s both}
.h2-lBarFill{width:100%;height:100%;border-radius:999px;background:var(--gi);transform-origin:0 50%;animation:h2barFill .8s linear .85s both}
.h2-app .h2-lBack{position:absolute;inset-block-start:20px;inset-inline-start:16px;z-index:2;background:var(--panel);border:1px solid var(--line);color:var(--txt);animation:h2riseIn .3s var(--ease-out) .7s both}
@keyframes h2flood{from{transform:scale(0)}to{transform:scale(18)}}
@keyframes h2ring{from{transform:scale(.6);opacity:.9}to{transform:scale(2.6);opacity:0}}
@keyframes h2iconIn{from{transform:translate(var(--ix,0px),var(--iy,0px)) scale(.3) rotate(-14deg);opacity:0}to{transform:none;opacity:1}}
@keyframes h2riseIn{from{opacity:0;transform:translateY(16px)}to{opacity:1;transform:none}}
@keyframes h2barFill{from{transform:scaleX(0)}to{transform:none}}

/* ================= АНІМАЦІЯ 3: ІГРИ НА ПАПЕРІ — сторінка зошита перегортається, ігри домальовує ручка =================
   сторінка: rotateY −92°→0 від лівого краю · 0,65 с · --ease-out
   малюнки: stroke-dashoffset → 0 · 0,9 с (дрібні 0,5 с) · ease-out, по черзі для трьох ігор
   маркер під назвою: scaleX 0→1 · 0,4 с · --ease-out */
.h2-nbWrap{position:absolute;inset:0;z-index:4;perspective:1300px;perspective-origin:0 50%;overflow:hidden}
.h2-nb{position:absolute;inset:0;padding:84px 20px 24px 62px;display:flex;flex-direction:column;gap:6px;color:#4b2142;
  transform-origin:0 50%;animation:h2pageIn .65s var(--ease-out) both;box-shadow:-30px 0 60px rgba(0,0,0,.5);
  background-color:#f4e9d8;
  background-image:
    radial-gradient(circle at 16px 22px,#2b2b2b 0 6px,rgba(43,43,43,0) 7px),
    linear-gradient(90deg,rgba(0,0,0,0) 45px,rgba(75,33,66,.5) 45px,rgba(75,33,66,.5) 46.5px,rgba(0,0,0,0) 46.5px),
    radial-gradient(60% 40% at 100% 0%,rgba(216,191,216,.75),rgba(216,191,216,0)),
    radial-gradient(70% 40% at 0% 100%,rgba(95,122,58,.28),rgba(95,122,58,0)),
    repeating-linear-gradient(0deg,rgba(0,0,0,0) 0 19px,#d8bfd8 19px 20px),
    repeating-linear-gradient(90deg,rgba(0,0,0,0) 0 19px,#d8bfd8 19px 20px);
  background-size:32px 44px,auto,auto,auto,auto,auto;background-repeat:repeat-y,no-repeat,no-repeat,no-repeat,repeat,repeat}
.h2-nb .h2-lBack{animation:none}
.h2-nbHead{align-self:flex-start;margin-bottom:6px}
.h2-nbTitle{font-family:Oswald,Rubik,sans-serif;font-weight:600;font-size:31px;line-height:1.2;animation:h2riseIn .4s var(--ease-out) .5s both}
.h2-nbLine{display:block;width:240px;height:14px}
.h2-app .h2-nb svg{fill:none;fill-opacity:1;stroke:#4b2142;stroke-width:2.4;stroke-linecap:round;stroke-linejoin:round}
.h2-ink{stroke-dasharray:720;stroke-dashoffset:720;animation:h2draw .9s ease-out var(--dl,.7s) forwards}
.h2-ink.h2-s{stroke-dasharray:260;stroke-dashoffset:260;animation-duration:.5s;animation-delay:calc(var(--dl,.7s) + .65s)}
.h2-ink.h2-u{stroke-dasharray:260;stroke-dashoffset:260;animation-duration:.5s;animation-delay:.75s}
.h2-app .h2-nb .h2-gr{stroke:#5f7a3a}
.h2-app .h2-nb .h2-dk{stroke:#2b2b2b;animation-delay:calc(var(--dl,.7s) + 1.1s)}
.h2-app .h2-nb .h2-fl{fill:#4b2142;stroke:none;opacity:0;animation:h2fadeIn .3s ease-out calc(var(--dl,.7s) + .7s) forwards}
.h2-pg{display:flex;align-items:center;gap:16px;flex:1;min-height:150px;padding:0;border:0;background:none;text-align:start;
  transition:transform .5s var(--spring)}
.h2-app button.h2-pg{color:#4b2142}
.h2-pg:active{transform:scale(.95) rotate(-1deg);transition:transform .09s var(--ease-out)}
.h2-pgD{width:116px;height:116px;flex:none}
.h2-g1{--dl:.8s}.h2-g2{--dl:1.15s}.h2-g3{--dl:1.5s}.h2-g4{--dl:1.85s}
.h2-g4{flex-direction:row-reverse}.h2-g4 .h2-pgD{rotate:3deg}
.h2-g1 .h2-pgD{rotate:-3deg}.h2-g2{flex-direction:row-reverse}.h2-g2 .h2-pgD{rotate:4deg}.h2-g3 .h2-pgD{rotate:-2deg}
.h2-nm{position:relative;isolation:isolate;font-family:Oswald,Rubik,sans-serif;font-weight:600;font-size:23px;line-height:1.2;animation:h2riseIn .35s var(--ease-out) calc(var(--dl) + .5s) both}
.h2-nm::before{content:"";position:absolute;z-index:-1;inset:52% -8px 6% -8px;border-radius:3px;background:#d8bfd8;rotate:-1.5deg;
  transform-origin:0 50%;animation:h2barFill .4s var(--ease-out) calc(var(--dl) + .8s) both}
.h2-pg:active .h2-nm::before{background:#9fbf74}
@media (hover:hover){.h2-pg:hover .h2-nm::before{background:#9fbf74}.h2-pg:hover .h2-pgD{animation:h2hop .6s var(--ease-back) both}}
@keyframes h2pageIn{from{transform:rotateY(-92deg)}to{transform:none}}
@keyframes h2draw{to{stroke-dashoffset:0}}
@media (prefers-reduced-motion:reduce){.h2-ink,.h2-ink.h2-s,.h2-ink.h2-u{stroke-dashoffset:0}.h2-app .h2-nb .h2-fl{opacity:1}}

/* (стара версія зі стопкою — класи нижче більше не використовуються) */
.h2-paperX{position:absolute;inset:0;overflow:hidden;z-index:4;animation:h2fadeIn .35s var(--ease-out) both}
.h2-pxGrad{position:absolute;left:-60%;top:-30%;width:220%;height:160%;opacity:.86;
  background:conic-gradient(from 0deg,#4b2142,#2b2b2b,#5f7a3a,#4b2142,#d8bfd8,#4b2142);filter:blur(40px);
  animation:h2spin 16s linear infinite}
.h2-pxTitle{position:absolute;left:0;right:0;top:84px;text-align:center;font-family:Oswald,Rubik,sans-serif;font-weight:600;font-size:31px;line-height:1.2;color:#f4e9d8;
  animation:h2riseIn .4s var(--ease-out) .5s both}
.h2-ps{position:absolute;left:var(--x);top:var(--y);width:150px;height:186px;margin:-93px 0 0 -75px;padding:14px 12px;border:0;border-radius:4px;
  rotate:var(--r);display:flex;flex-direction:column;align-items:center;justify-content:space-between;
  background-color:#f4e9d8;box-shadow:0 14px 24px rgba(0,0,0,.4);
  background-image:repeating-linear-gradient(0deg,transparent 0 14px,#d8bfd8 14px 15px),repeating-linear-gradient(90deg,transparent 0 14px,#d8bfd8 14px 15px);
  animation:h2scatter .75s var(--ease-back) calc(.3s + var(--i) * 90ms) both, h2sway 4s ease-in-out calc(1.4s + var(--i) * .3s) infinite alternate}
.h2-app button.h2-ps{color:#4b2142}
.h2-ps svg{width:104px;height:104px;stroke-width:2.2}
.h2-ps .h2-gr{stroke:#5f7a3a}
.h2-ps .h2-fl{fill:#4b2142;stroke:none}
.h2-ps .h2-nm{font-family:Oswald,Rubik,sans-serif;font-weight:600;font-size:18px;line-height:1.2}
.h2-ps{transition:scale .5s var(--spring)}
.h2-ps:active{scale:.93;transition:scale .09s var(--ease-out)}
.h2-s1{--i:0;--x:108px;--y:300px;--r:-8deg;--sx:87px;--sy:140px;--sr:10deg}
.h2-s2{--i:1;--x:282px;--y:390px;--r:7deg;--sx:-87px;--sy:50px;--sr:-12deg}
.h2-s3{--i:2;--x:140px;--y:580px;--r:4deg;--sx:55px;--sy:-140px;--sr:-6deg}
.h2-blank{position:absolute;left:195px;top:440px;width:150px;height:186px;margin:-93px 0 0 -75px;border-radius:4px;background:#f4e9d8;opacity:0;
  animation:h2flyOff .9s var(--ease-out) var(--dl) both}
.h2-f1{--fx:-330px;--fy:-420px;--fr:-70deg;--dl:.3s}.h2-f2{--fx:340px;--fy:-180px;--fr:85deg;--dl:.36s}.h2-f3{--fx:300px;--fy:460px;--fr:-50deg;--dl:.42s}
@keyframes h2fadeIn{from{opacity:0}to{opacity:1}}
@keyframes h2spin{to{transform:rotate(360deg)}}
@keyframes h2scatter{from{opacity:0;transform:translate(var(--sx),var(--sy)) rotate(var(--sr)) scale(.92)}20%{opacity:1}to{opacity:1;transform:none}}
@keyframes h2sway{to{transform:translateY(-6px) rotate(1.2deg)}}
@keyframes h2flyOff{0%{opacity:1;transform:none}100%{opacity:0;transform:translate(var(--fx),var(--fy)) rotate(var(--fr))}}

/* ================= АНІМАЦІЯ 4: КЛАСИЧНІ АРКАДИ — піксельний перехід ================= */
.h2-arcX{position:absolute;inset:0;overflow:hidden;z-index:4;font-family:"Press Start 2P",Rubik,monospace;color:#f2f7ef}
.h2-pxl{position:absolute;inset:0;display:grid;grid-template-columns:repeat(10,39px);grid-auto-rows:39px}
.h2-pxl>:not(i){display:contents}
.h2-pxl i{display:block;background:#2e6f40;animation:h2pxIn .01s steps(1) var(--q) both}
.h2-pxl i.h2-alt{background:#286238}
.h2-q0{--q:0s}.h2-q1{--q:.05s}.h2-q2{--q:.1s}.h2-q3{--q:.15s}.h2-q4{--q:.2s}.h2-q5{--q:.25s}.h2-q6{--q:.3s}.h2-q7{--q:.35s}.h2-q8{--q:.4s}.h2-q9{--q:.45s}.h2-q10{--q:.5s}.h2-q11{--q:.55s}
.h2-scan{position:absolute;inset:0;background:repeating-linear-gradient(0deg,rgba(0,0,0,.16) 0 2px,transparent 2px 4px);pointer-events:none}
.h2-arcBody{position:absolute;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:22px;padding:24px;text-align:center}
.h2-arcT{font-size:17px;line-height:1.7;animation:h2pxIn .01s steps(1) .7s both}
.h2-arcS{font-size:11px;color:#f4b266;animation:h2pxIn .01s steps(1) .8s both, h2blink 1s steps(2) 1.6s infinite}
.h2-slots{display:flex;gap:8px}
.h2-slot{width:60px;height:76px;padding:6px 0 0;border:3px solid #3b2f2f;border-radius:10px;background:#7fb069;
  display:flex;flex-direction:column;align-items:center;gap:6px;font-size:8px;box-shadow:0 5px 0 #3b2f2f;
  animation:h2pxIn .01s steps(1) calc(.9s + var(--i) * 80ms) both;transition:transform .5s var(--spring),box-shadow .2s}
.h2-app button.h2-slot{color:#3b2f2f}
.h2-app button.h2-slot.h2-on{background:#f4b266}
.h2-slot:active{transform:translateY(4px) scale(.95);box-shadow:0 1px 0 #3b2f2f;transition:transform .09s var(--ease-out),box-shadow .09s}
.h2-slot svg{width:40px;height:40px;animation:h2bob 1.1s ease-in-out calc(1.4s + var(--i) * .16s) infinite alternate}
@keyframes h2bob{to{transform:translateY(-4px) rotate(-4deg)}}
.h2-sl0{--i:0}.h2-sl1{--i:1}.h2-sl2{--i:2}.h2-sl3{--i:3}.h2-sl4{--i:4}
/* піксельний ігровий автомат із ЕПТ-екраном: рівні кути, товсті темні рамки, смужки розгортки
   автомат: з'являється ривками, translateY 48px→0 · 0,35 с · steps(5), затримка 0,6 с
   екран вмикається: scaleY .02→1 з яскравою лінією · 0,45 с, затримка 0,95 с
   рядки меню: по одному · steps(1), крок 90 мс · смуга розгортки біжить згори вниз 5 с по колу */
.h2-cab{position:absolute;left:24px;right:24px;top:74px;bottom:22px;display:flex;flex-direction:column;
  background:#2e6f40;border:6px solid #3b2f2f;box-shadow:8px 8px 0 rgba(0,0,0,.35);animation:h2cabIn .35s steps(5) .6s both}
.h2-marq{flex:none;padding:8px 10px;background:#f4b266;border-bottom:6px solid #3b2f2f;display:flex;flex-direction:column;gap:7px;align-items:center}
.h2-marqT{font-size:13px;line-height:1.5;color:#3b2f2f;text-align:center}
.h2-bulbs{display:flex;gap:8px}
.h2-bulbs i{display:block;width:8px;height:8px;background:#3b2f2f}
.h2-bulbs i:nth-child(odd){background:#f2f7ef;animation:h2blink 1s steps(2) 1.2s infinite}
.h2-bulbs.h2-alt i:nth-child(even){background:#f2f7ef;animation:h2blink 1s steps(2) 1.7s infinite}
.h2-bulbs.h2-alt i:nth-child(odd){background:#3b2f2f;animation:none}
.h2-bezel{flex:1;min-height:0;margin:12px;padding:12px;background:#3b2f2f;display:flex}
.h2-crt{position:relative;flex:1;border-radius:22px;overflow:hidden;background:radial-gradient(120% 100% at 50% 40%,#1c4a28,#0b1f11 78%);
  box-shadow:inset 0 0 26px rgba(0,0,0,.8),0 0 18px rgba(127,176,105,.35);animation:h2crtOn .45s cubic-bezier(.2,.9,.3,1) .95s both}
.h2-crtIn{position:absolute;inset:0;padding:22px 16px 16px;display:flex;flex-direction:column;gap:9px;color:#b9f29a;
  text-shadow:0 0 6px rgba(127,176,105,.9);animation:h2flick 3.7s steps(1) 2s infinite}
.h2-crtH{font-size:11px;color:#f4b266;text-shadow:0 0 6px rgba(244,178,102,.9);margin-bottom:4px;animation:h2pxIn .01s steps(1) 1.4s both}
.h2-rowA{flex:1;min-height:44px;max-height:58px;display:flex;align-items:center;gap:10px;padding:0 10px;border:3px solid #7fb069;background:rgba(0,0,0,0);
  font-size:11px;text-align:start;animation:h2pxIn .01s steps(1) calc(1.5s + var(--i) * 90ms) both}
.h2-app button.h2-rowA{color:#b9f29a}
.h2-rowA svg{width:30px;height:30px;flex:none;animation:h2bob 1.1s ease-in-out calc(2s + var(--i) * .16s) infinite alternate}
.h2-rowA span:nth-of-type(1){flex:1}
.h2-rowA .h2-cur{opacity:0;color:#f4b266}
.h2-app button.h2-rowA.h2-on,.h2-app button.h2-rowA:active{background:#7fb069;color:#0b1f11;text-shadow:none}
.h2-rowA.h2-on .h2-cur{opacity:1;animation:h2blink .8s steps(2) infinite;color:#3b2f2f}
@media (hover:hover){.h2-app button.h2-rowA:hover{background:#7fb069;color:#0b1f11;text-shadow:none}}
.h2-r0{--i:0}.h2-r1{--i:1}.h2-r2{--i:2}.h2-r3{--i:3}.h2-r4{--i:4}.h2-r5{--i:5}.h2-r6{--i:6}
.h2-crtScan{position:absolute;inset:0;pointer-events:none;background:repeating-linear-gradient(0deg,rgba(0,0,0,.3) 0 2px,rgba(0,0,0,0) 2px 4px)}
.h2-crtBar{position:absolute;left:0;right:0;top:-90px;height:90px;pointer-events:none;
  background:linear-gradient(180deg,rgba(185,242,154,0),rgba(185,242,154,.13),rgba(185,242,154,0));animation:h2sweep 5s linear 1.6s infinite}
.h2-crtVig{position:absolute;inset:0;pointer-events:none;
  background:radial-gradient(90% 80% at 50% 45%,rgba(0,0,0,0) 55%,rgba(0,0,0,.55)),linear-gradient(120deg,rgba(255,255,255,.1),rgba(255,255,255,0) 30%)}
.h2-deck{flex:none;height:92px;display:flex;align-items:center;justify-content:space-between;padding:0 30px;background:#29653a;border-top:6px solid #3b2f2f;border-bottom:6px solid #3b2f2f}
.h2-stick{position:relative;width:60px;height:66px}
.h2-stick i,.h2-btns i,.h2-cabBase i{display:block}
.h2-stBall{position:absolute;left:16px;top:0;width:28px;height:28px;background:#f4b266;border:5px solid #3b2f2f}
.h2-stRod{position:absolute;left:25px;top:26px;width:10px;height:24px;background:#3b2f2f}
.h2-stBase{position:absolute;left:0;bottom:0;width:60px;height:18px;background:#7fb069;border:5px solid #3b2f2f}
.h2-btns{display:flex;gap:10px;align-items:flex-end}
.h2-btns i{width:30px;height:30px;border:5px solid #3b2f2f;box-shadow:0 5px 0 #3b2f2f}
.h2-bA{background:#f4b266}.h2-bB{background:#f2f7ef;margin-bottom:12px}.h2-bC{background:#7fb069}
.h2-cabBase{flex:none;height:56px;display:flex;gap:14px;align-items:center;justify-content:center;
  background:repeating-linear-gradient(90deg,#2e6f40 0 12px,#29653a 12px 24px)}
.h2-coin{width:14px;height:30px;background:#0b1f11;border:4px solid #3b2f2f}
/* автомат на весь екран, без піксельного тла; ігри — картки з піксель-артом
   автомат: виїжджає знизу ривками · 0,35 с · steps(5) · екран вмикається · 0,45 с, затримка 0,35 с · картки по одній, крок 90 мс */
.h2-app .h2-cab{inset:0;left:0;right:0;top:0;bottom:0;border:0;box-shadow:none;animation-delay:0s}
.h2-app .h2-marq{position:relative;padding:22px 60px 10px}
.h2-pxBack{position:absolute;left:12px;top:20px;width:44px;height:44px;padding:8px;border:5px solid #3b2f2f;background:#f2f7ef;box-shadow:0 4px 0 #3b2f2f}
.h2-pxBack svg{display:block;width:100%;height:100%;fill:none;stroke:#3b2f2f;stroke-width:1}
.h2-pxBack:active{transform:translateY(4px);box-shadow:none}
.h2-app .h2-marqT{font-size:14px}
.h2-app .h2-bezel{margin:10px;padding:10px}
.h2-app .h2-crt{animation-delay:.35s}
.h2-app .h2-crtIn{padding:18px 12px 14px;gap:8px;overflow-y:auto}
.h2-gm{flex:1;min-height:84px;display:flex;align-items:stretch;padding:0;border:3px solid #7fb069;background:rgba(0,0,0,.28);text-align:start;
  animation:h2pxIn .01s steps(1) calc(.85s + var(--i) * 90ms) both}
.h2-app button.h2-gm{color:#b9f29a}
.h2-gm .h2-art{display:grid;place-items:center;width:100px;flex:none;background:var(--sky);border-inline-end:3px solid #7fb069}
.h2-spr{display:block;width:80px;height:auto;fill:none;stroke-width:1.02;animation:h2bob 1.1s steps(3) calc(1.6s + var(--i) * .16s) infinite alternate}
.h2-gmT{flex:1;min-width:0;display:flex;flex-direction:column;justify-content:center;gap:5px;padding:6px 8px 6px 10px}
.h2-gmTag{align-self:flex-start;padding:3px 5px 2px;background:#f2f7ef;color:#0b1f11;font-size:7px;line-height:1;text-shadow:none}
.h2-gmN{font-size:10.5px;line-height:1.5;color:#f2f7ef}
.h2-gmS{font-family:Rubik,system-ui,sans-serif;font-size:11.5px;line-height:1.25;color:#b9f29a;text-shadow:none}
.h2-c-bird{--sky:#6fb1f0}.h2-c-snake{--sky:#a6dc7a}.h2-c-waka{--sky:#4b2f9a}.h2-c-duck{--sky:#8ed0c6}.h2-c-candy{--sky:#c75fd0}.h2-c-cake{--sky:#ff8fab}.h2-c-sar{--sky:#e4384d}
.h2-app button.h2-gm:active{border-color:#f4b266;background:rgba(244,178,102,.18)}
.h2-gm:active .h2-art{border-color:#f4b266}
@media (hover:hover){
  .h2-app button.h2-gm:hover{border-color:#f4b266;background:rgba(244,178,102,.14)}
  .h2-gm:hover .h2-art{border-color:#f4b266}
  .h2-gm:hover .h2-spr{animation:h2hop .5s steps(4) both}
}
.h2-app .h2-deck{height:84px}
@keyframes h2cabIn{from{transform:translateY(48px);opacity:0}to{transform:none;opacity:1}}
@keyframes h2crtOn{0%{transform:scale(1,.02);filter:brightness(4)}45%{transform:scale(1,.02);filter:brightness(4)}100%{transform:none;filter:none}}
@keyframes h2sweep{to{transform:translateY(640px)}}
@keyframes h2flick{0%{opacity:1}3%{opacity:.86}6%{opacity:1}52%{opacity:1}54%{opacity:.9}56%{opacity:1}}
@keyframes h2pxIn{from{opacity:0}to{opacity:1}}
@keyframes h2blink{50%{opacity:0}}

@media (prefers-reduced-motion:reduce){
  .h2-app *{animation:none!important;transition:none!important}
  .h2-tree,.h2-blank{display:none}
  .h2-lFlood{left:0;top:0;width:100%;height:100%;margin:0;border-radius:0}
  .h2-lRing{display:none}
}

/* ===== КАБІНЕТ ===== */
/* ті самі токени бази, що й на головній */
.h2p-app{
  --ease-out:cubic-bezier(.22,.8,.3,1); --ease-back:cubic-bezier(.3,1.5,.5,1); --spring:cubic-bezier(.2,2.2,.4,1);
  --red:#d3443c; --red2:#e4534a; --goldFill:#e8b93c; --onGold:#2b2826;
}
.h2p-app.h2p-theme-dark{
  --bg1:#221f1d; --bg2:#191715;
  --glass:rgba(46,42,39,.62); --panel:#2e2a27; --panel2:#38332f; --line:rgba(243,234,217,.14);
  --gold:#e8b93c; --txt:#f3ead9; --dim:#b5aa9b; --mute:#8a8073; --edge:rgba(0,0,0,.34);
  --blob1:#4b2142; --blob2:#2e6f40; --blob3:#976e65; --blobO:.5;
}
.h2p-app.h2p-theme-vivid{
  --bg1:#322b27; --bg2:#27211e;
  --glass:rgba(66,58,52,.6); --panel:#423a34; --panel2:#50463f; --line:rgba(255,244,224,.2);
  --gold:#f7cc4d; --txt:#fff6e6; --dim:#d0c2af; --mute:#a39684; --edge:rgba(0,0,0,.3);
  --blob1:#8a2f78; --blob2:#3fa25c; --blob3:#e2895f; --blobO:.62; --goldFill:#f7cc4d;
}
.h2p-app.h2p-theme-light{
  --bg1:#f4eee2; --bg2:#ebe2d0;
  --glass:rgba(255,250,242,.66); --panel:#fffaf2; --panel2:#f1e8d8; --line:rgba(43,40,38,.14);
  --gold:#7d5a1c; --txt:#2b2826; --dim:#6b6157; --mute:#94897c; --edge:rgba(70,52,30,.22);
  --blob1:#d8bfd8; --blob2:#81aa8e; --blob3:#f3d99b; --blobO:.7;
}



.h2p-app{position:relative;width:390px;height:844px;overflow:hidden;box-sizing:border-box;
  font-family:Rubik,system-ui,sans-serif;color:var(--txt);background:linear-gradient(var(--bg1),var(--bg2))}
.h2p-app *{box-sizing:border-box}
.h2p-app button{font:inherit;color:inherit;cursor:pointer;-webkit-tap-highlight-color:transparent}
.h2p-app svg.h2p-ln{fill:currentColor;fill-opacity:.26;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;
  transform-box:fill-box;transform-origin:50% 60%}
.h2p-blob{position:absolute;width:320px;height:320px;border-radius:50%;filter:blur(64px);opacity:var(--blobO)}
.h2p-bl1{left:-140px;top:-60px;background:var(--blob1);animation:h2pdrift1 19s ease-in-out infinite alternate}
.h2p-bl2{right:-150px;top:300px;background:var(--blob2);animation:h2pdrift2 23s ease-in-out infinite alternate}
.h2p-bl3{left:20px;bottom:-160px;background:var(--blob3);animation:h2pdrift3 27s ease-in-out infinite alternate}
@keyframes h2pdrift1{to{transform:translate(150px,120px) scale(1.2)}}
@keyframes h2pdrift2{to{transform:translate(-170px,-150px) scale(.85)}}
@keyframes h2pdrift3{to{transform:translate(110px,-200px) scale(1.15)}}

.h2p-scroll{position:absolute;inset:0;overflow-y:auto;overflow-x:hidden;padding:20px 16px 32px;display:flex;flex-direction:column;gap:14px}
.h2p-glass{background:var(--glass);border:1px solid var(--line);-webkit-backdrop-filter:blur(16px);backdrop-filter:blur(16px)}

/* натиск і наведення — як на головній */
.h2p-press{transition:transform .55s var(--spring),filter .25s var(--ease-out)}
.h2p-press:active{transform:translateY(3px) scale(.96);filter:brightness(.94);transition:transform .09s var(--ease-out),filter .09s var(--ease-out)}
@media (hover:hover){
  .h2p-press:hover{transform:translateY(-3px)}
  .h2p-press:hover svg,.h2p-kpi:hover svg,.h2p-grow:hover .h2p-gbadge svg{animation:h2pwig .7s var(--ease-back) both}
  .h2p-kpi:hover .h2p-kNum{animation:h2phop .6s var(--ease-back) both}
}
@keyframes h2pwig{0%{transform:none}30%{transform:rotate(-12deg) scale(1.18)}60%{transform:rotate(9deg) scale(1.12)}100%{transform:none}}
@keyframes h2phop{0%{transform:none}40%{transform:translateY(-6px)}100%{transform:none}}

.h2p-bar{display:flex;align-items:center;gap:10px}
.h2p-iconbtn{width:44px;height:44px;flex:none;display:grid;place-items:center;padding:0;border-radius:14px}
.h2p-app a.h2p-iconbtn{color:var(--txt)}
.h2p-iconbtn svg{width:22px;height:22px}
.h2p-barT{flex:1;font-family:Oswald,Rubik,sans-serif;font-weight:600;font-size:22px;line-height:44px}

/* герой */
.h2p-hero{display:flex;flex-direction:column;align-items:center;gap:10px;padding:8px 0 2px}
.h2p-avaWrap{position:relative;width:108px;height:108px;display:grid;place-items:center}
.h2p-avaRing{position:absolute;inset:0;border-radius:50%;background:conic-gradient(var(--goldFill),#e4534a,#8e839b,#81aa8e,var(--goldFill));animation:h2pspin 9s linear infinite}
.h2p-ava{position:relative;width:94px;height:94px;border-radius:50%;background:var(--goldFill);color:var(--onGold);border:4px solid var(--bg1);
  display:grid;place-items:center;font-weight:700;font-size:42px}
.h2p-name{font-weight:700;font-size:22px;line-height:1.1}
.h2p-pills{display:flex;gap:8px}
.h2p-pill{display:flex;gap:5px;align-items:center;height:30px;padding:0 12px 0 8px;border-radius:999px;font-weight:700;font-size:15px}
.h2p-pill svg{width:18px;height:18px}
.h2p-pill.h2p-coin{color:var(--gold)}.h2p-pill.h2p-fire{color:var(--red2)}
@keyframes h2pspin{to{transform:rotate(360deg)}}

/* три головні числа */
.h2p-kpis{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}
.h2p-kpi{display:flex;flex-direction:column;gap:6px;align-items:flex-start;padding:12px;border-radius:18px;min-height:104px}
.h2p-kpi svg{width:20px;height:20px;color:var(--gold)}
.h2p-kNum{font-weight:700;font-size:28px;line-height:1;font-variant-numeric:tabular-nums}
.h2p-kLab{font-size:11.5px;line-height:1.2;color:var(--dim)}

/* завдання дня */
.h2p-daily{display:flex;align-items:center;gap:12px;padding:12px 14px;border-radius:18px}
.h2p-dTxt{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}
.h2p-dT{font-weight:700;font-size:15px}
.h2p-dS{font-size:12.5px;color:var(--dim)}
.h2p-stars{display:flex;gap:4px;color:var(--mute)}
.h2p-stars svg{width:24px;height:24px}
.h2p-app .h2p-stars svg{fill-opacity:0}

/* ігри: частка перемог — один колір, значення підписані текстом */
.h2p-secT{margin-top:6px;font-size:12px;letter-spacing:.24em;color:var(--dim);font-weight:500}
.h2p-games{display:flex;flex-direction:column;gap:8px}
.h2p-grow{display:flex;align-items:center;gap:12px;padding:10px 12px;border-radius:18px}
.h2p-gbadge{width:44px;height:44px;flex:none;border-radius:12px;background:var(--g);color:var(--gi);display:grid;place-items:center;rotate:-4deg;box-shadow:0 4px 0 var(--edge)}
.h2p-gbadge svg{width:24px;height:24px}
.h2p-gMid{flex:1;min-width:0;display:flex;flex-direction:column;gap:6px}
.h2p-gTop{display:flex;justify-content:space-between;gap:8px;align-items:baseline}
.h2p-gName{font-weight:700;font-size:15px}
.h2p-gCnt{font-size:12px;color:var(--dim);font-variant-numeric:tabular-nums}
.h2p-meter{height:8px;border-radius:4px;background:var(--panel2);overflow:hidden}
.h2p-fill{height:100%;border-radius:4px;background:var(--gold);transform-origin:0 50%;animation:h2pgrow .8s var(--ease-out) calc(.5s + var(--d) * 70ms) both}
.h2p-w63{width:63%}.h2p-w55{width:55%}.h2p-w48{width:48%}.h2p-w42{width:42%}.h2p-w33{width:33%}
.h2p-gPct{width:40px;flex:none;text-align:end;font-weight:700;font-size:15px;font-variant-numeric:tabular-nums}
.h2p-note{font-size:11.5px;line-height:1.35;color:var(--mute)}

.h2p-in{animation:h2prise .5s var(--ease-back) calc(var(--d) * 70ms) both}
.h2p-d0{--d:0}.h2p-d1{--d:1}.h2p-d2{--d:2}.h2p-d3{--d:3}.h2p-d4{--d:4}.h2p-d5{--d:5}.h2p-d6{--d:6}.h2p-d7{--d:7}.h2p-d8{--d:8}.h2p-d9{--d:9}
@keyframes h2prise{from{opacity:0;transform:translateY(22px) scale(.94)}to{opacity:1;transform:none}}
@keyframes h2pgrow{from{transform:scaleX(0)}to{transform:none}}
@media (prefers-reduced-motion:reduce){.h2p-app *{animation:none!important;transition:none!important}}

/* ===== ПРИПАСУВАННЯ ДО ГРАЛЬНІ ===== */
/* Макет намальовано під екран 390 px. Щоб нічого не роз'їхалось на вужчих і ширших телефонах,
   корінь лишається 390 px завширшки, а home2.js масштабує його цілком (zoom) під ширину вікна. */
#home.h2on{padding:0;overflow:hidden;gap:0}
#home.h2on>:not(.h2-wrap){display:none!important}
#home>.h2-wrap{position:absolute;inset:0;z-index:1;display:flex;justify-content:center;overflow:hidden;background:#191715}
body.light #home>.h2-wrap{background:#ebe2d0}
.h2-app{flex:none}
.h2-app [hidden]{display:none!important}
.h2-scroll{padding-top:calc(20px + var(--sat));padding-bottom:calc(32px + var(--sab));-webkit-overflow-scrolling:touch}
.h2-app button.h2-me{text-align:start;color:var(--txt)}
.h2-app button.h2-block{color:#fff;text-align:start}
.h2-app input{font-family:inherit}

/* аватар гравця з гардеробу замість літери */
.h2-ava:not(:empty){background:none}
.h2-ava .ava,.h2-ava .ava.xl{width:48px;height:48px;font-size:22px}
.h2p-ava:not(:empty){background:var(--bg1)}
.h2p-ava .ava,.h2p-ava .ava.xl{width:86px;height:86px;font-size:40px}

/* живі дані */
.h2-app .h2-stars svg.h2-on,.h2-app .h2p-stars svg.h2-on{color:var(--gold);fill-opacity:.9}
.h2-chip.h2-fire.h2-blue>svg,.h2-chip.h2-fire.h2-blue .h2-chipT,.h2p-pill.h2p-fire.h2-blue{color:#4aa8ff}
.h2-gift .h2-gsub.h2-open .h2-lock{display:none}
.h2-bal.h2-x2::after{content:"×2";position:absolute;inset-inline-start:-8px;top:-8px;padding:1px 5px;border-radius:99px;background:#ffd45a;color:#3a2600;font-size:10px;font-weight:700}

/* старт гри в Гральні коротший, ніж у макеті: показали заливку з назвою — і одразу гра */
.h2-lName{animation-delay:.3s}.h2-lSub{animation-delay:.36s}
.h2-lBar{animation-delay:.3s}.h2-lBarFill{animation-duration:.5s;animation-delay:.4s}
.h2-launch.h2-out,.h2-nbWrap.h2-out,.h2-arcX.h2-out{opacity:0;transition:opacity .18s linear;pointer-events:none}
.h2-nb .h2-pg{min-height:0}
.h2-app .h2-nb .h2-lBack svg{stroke:var(--txt);fill:var(--txt);fill-opacity:.26}

/* низ: справжні столи й посилання */
.h2-rooms{margin-top:10px;display:flex;flex-direction:column;gap:8px}
.h2-rooms .subhead{margin-top:14px;font-size:13px;color:var(--dim);font-weight:600}
.h2-rooms .empty{text-align:start;padding:0;font-size:14px;line-height:1.4;color:var(--dim)}
.h2-foot button,.h2-foot a{min-height:44px;display:flex;align-items:center;padding:0;border:0;background:none;font:inherit;color:var(--dim);text-decoration:underline;text-underline-offset:3px;cursor:pointer}
.h2-app .h2-foot button{color:var(--dim)}

/* аркуші зі списком ігор (на прохання, бета): звичайні плитки Гральні */
.h2-list .sheetCard{max-height:86vh;overflow-y:auto}
.h2-list .games{margin:12px 0}
.h2-list .games>.gtile{animation:none}
.h2-list .gtile b{font-size:17px;overflow-wrap:anywhere}

/* ===== кабінет ===== */
.h2p-app{position:absolute;inset:0;z-index:6;width:auto;height:auto;animation:h2pIn .28s cubic-bezier(.22,.8,.3,1) both}
.h2p-app.h2-out{opacity:0;transform:translateX(24px);transition:opacity .18s linear,transform .18s linear;pointer-events:none}
@keyframes h2pIn{from{opacity:0;transform:translateX(24px)}to{opacity:1;transform:none}}
.h2p-scroll{padding-top:calc(20px + var(--sat));padding-bottom:calc(32px + var(--sab))}
.h2p-app button.h2p-avaWrap{padding:0;border:0;background:none}
.h2p-avaWrap>span{display:grid}
.h2p-avaRing{display:block}
.h2p-app input.h2p-name{width:100%;max-width:300px;padding:4px 8px;border:1px dashed transparent;border-radius:10px;background:none;color:var(--txt);text-align:center;font-weight:700;font-size:22px;line-height:1.1;outline:none}
.h2p-app input.h2p-name:focus{border-color:var(--line);background:var(--panel)}
.h2p-nameHint{margin-top:-6px;font-size:11.5px;color:var(--mute)}
.h2p-app button.h2p-daily{width:100%;text-align:start;color:var(--txt)}
.h2p-fill{width:var(--w,0%)}
.h2p-gbadge svg{fill:currentColor;fill-opacity:.26;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.h2p-note:empty{display:none}
@media (prefers-reduced-motion:reduce){.h2p-app{animation:none}}

/* ===== меню перед грою (шторка #setup): стіл, «річ» гри в шапці, кнопки в її кольорах ===== */
#setup.h2s{background:rgba(10,8,7,.72)}
#setup.h2s .sheetCard{--bg1:#221f1d;--bg2:#191715;--glass:rgba(46,42,39,.62);--panel:#2e2a27;--panel2:#38332f;--line:rgba(243,234,217,.14);--txt:#f3ead9;--dim:#b5aa9b;--mute:#8a8073;--edge:rgba(0,0,0,.34);
  position:relative;overflow-x:hidden;gap:14px;padding-top:14px;border-radius:26px 26px 0 0;border-color:var(--line);
  background:radial-gradient(120% 60% at 0% 0%,color-mix(in srgb,var(--g) 26%,transparent),transparent 70%),linear-gradient(var(--bg1),var(--bg2));color:var(--txt);font-family:Rubik,system-ui,sans-serif}
body.light #setup.h2s .sheetCard{--bg1:#f4eee2;--bg2:#ebe2d0;--glass:rgba(255,250,242,.66);--panel:#fffaf2;--panel2:#f1e8d8;--line:rgba(43,40,38,.14);--txt:#2b2826;--dim:#6b6157;--mute:#94897c;--edge:rgba(70,52,30,.22)}
#setup.h2s .sheetHead{justify-content:flex-end;margin-bottom:-6px}
#setup.h2s #setupTitle{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
#setup.h2s #setupClose{width:44px;height:44px;border-radius:14px;background:var(--glass);border:1px solid var(--line);color:var(--txt)}
.h2s-wrap.h2-app{position:relative;width:auto;height:auto;overflow:visible;background:none;margin:0 4px 4px;flex:none}
.h2s-wrap .h2-obj{pointer-events:none}
.h2s-wrap .h2-sq{min-height:156px;padding-top:98px;border:7px solid #5f4942;border-radius:16px;box-shadow:0 6px 0 var(--edge)}
.h2s-wrap .h2-sq .h2-gname{font-family:Oswald,Rubik,sans-serif;font-weight:600;font-size:24px}
.h2s-wrap .h2-sheet{min-height:128px;color:var(--gi)}
.h2s-wrap svg.h2s-pg{fill:none;stroke:#4b2142;stroke-width:2.6;--dl:.15s}
.h2s-wrap svg.h2s-pg .h2-gr{stroke:#5f7a3a}.h2s-wrap svg.h2s-pg .h2-dk{stroke:#2b2b2b}
.h2s-wrap svg.h2s-pg .h2-fl{fill:#4b2142;stroke:none}
.h2s-band{position:relative;display:flex;align-items:center;gap:14px;min-height:118px;padding:14px 16px;border-radius:18px;background:var(--g);color:var(--gi);box-shadow:0 6px 0 var(--edge);rotate:-1deg}
.h2s-t{flex:1;min-width:0}
.h2s-name{font-family:Oswald,Rubik,sans-serif;font-weight:600;font-size:26px;line-height:1.2;overflow-wrap:anywhere}
.h2s-sub{margin-top:4px;font-size:12.5px;line-height:1.3}
.h2s-badge{width:78px;height:78px;flex:none;border-radius:50%;display:grid;place-items:center;background:var(--gi);color:var(--g)}
.h2s-badge svg{width:44px;height:44px}
.h2s-mini{position:relative;width:88px;height:112px;flex:none;margin-top:-22px}
.h2s-mini .h2-gcard{left:0;top:0;rotate:7deg;transform:scale(.8);transform-origin:0 0}
.h2s-mini .h2-gcBot{display:none}
#setup.h2s .optBlock{padding:12px;border-radius:18px;background:var(--glass);border:1px solid var(--line);gap:9px}
#setup.h2s .optLabel{font-size:11.5px;letter-spacing:.2em;color:var(--dim);font-weight:500}
#setup.h2s .pills{gap:8px}
#setup.h2s .pill{padding:9px 15px;border:0;border-radius:14px;background:var(--panel2);color:var(--txt);font-weight:700;font-size:14.5px;box-shadow:0 3px 0 var(--edge);transition:transform .35s cubic-bezier(.2,2.2,.4,1),background .15s}
#setup.h2s .pill:active{transform:translateY(3px);box-shadow:none;transition:transform .08s}
#setup.h2s .pill.on{background:var(--g);color:var(--gi)}
#setup.h2s .tempoNote{margin:-6px 8px 2px;color:var(--mute)}
#setup.h2s .lvlInfo{padding:12px 14px;border-radius:18px;background:var(--glass);border:1px solid var(--line);color:var(--txt)}
#setup.h2s .lvlInfo small{color:var(--mute)}
#setup.h2s .actionsCol{gap:12px;margin-top:2px;padding-bottom:6px}
#setup.h2s .btn{min-height:52px;flex:0 0 52px;border:0;border-radius:16px;font-weight:700;font-size:16px;background:var(--panel2);color:var(--txt);box-shadow:0 5px 0 var(--edge);transition:transform .35s cubic-bezier(.2,2.2,.4,1)}
#setup.h2s .btn:active{transform:translateY(4px);box-shadow:0 1px 0 var(--edge);transition:transform .08s}
#setup.h2s .btn.primary{background:var(--g);color:var(--gi);text-shadow:none}
/* меню перед грою — на весь екран: заливка старту гри переходить просто в нього */
#setup.h2s{align-items:stretch;background:#191715;backdrop-filter:none}
#setup.h2s .sheetCard{height:100%;max-height:none;border:0;border-radius:0;padding-top:calc(var(--sat) + 14px);padding-bottom:0;animation:h2sIn .22s ease-out}
#setup.h2s .actionsCol{position:sticky;bottom:0;z-index:2;margin:auto -16px 0;padding:14px 16px calc(var(--sab) + 18px);background:linear-gradient(rgba(25,23,21,0),var(--bg2) 26%)}
@keyframes h2sIn{from{opacity:0}to{opacity:1}}
@media (prefers-reduced-motion:reduce){#setup.h2s .sheetCard{animation:none}}
#setup.h2s #setupOpts{display:flex;flex-direction:column;gap:12px}
.h2s-wrap svg.h2s-pg{width:84px;height:84px}

/* ===== «Бізнес»: комп'ютер 2000-х, на екрані біржа й акції, що падають ===== */
.h2-h-biz{--g:#d8d2c0;--gi:#1f2a44}
.h2-pc{display:flex;align-items:stretch;gap:12px;min-height:124px;padding:10px;border-radius:6px;background:linear-gradient(180deg,#e6e1d2,#cfc8b4);
  box-shadow:0 6px 0 var(--edge),inset 0 0 0 2px #f3efe3,inset 0 0 0 3px #a59e88;rotate:.8deg}
.h2-pcMon{position:relative;display:block;width:136px;flex:none;padding:8px 8px 18px;border-radius:8px 8px 4px 4px;background:linear-gradient(180deg,#d9d3c1,#b9b29c);box-shadow:inset 0 0 0 2px #efeadc,0 2px 0 #8f8873}
.h2-pcScr{position:relative;display:block;height:100%;min-height:82px;border-radius:10px/8px;overflow:hidden;background:radial-gradient(120% 100% at 50% 40%,#0c2a14,#020a05 80%);box-shadow:inset 0 0 12px rgba(0,0,0,.9),0 0 0 2px #6f6955}
.h2-pcScr::after{content:"";position:absolute;inset:0;background:repeating-linear-gradient(0deg,rgba(0,0,0,.28) 0 1px,rgba(0,0,0,0) 1px 3px);pointer-events:none}
.h2-app .h2-obj svg.h2-pcArt{position:absolute;inset:0;width:100%;height:100%;fill:none;fill-opacity:1;stroke:none;stroke-linecap:square;stroke-linejoin:miter}
.h2-pcDn{stroke-dasharray:90;stroke-dashoffset:90;animation:h2pcFall 3.2s steps(12) infinite}
@keyframes h2pcFall{0%{stroke-dashoffset:90}55%{stroke-dashoffset:0}100%{stroke-dashoffset:0}}
.h2-pcTick{position:absolute;left:6px;top:5px;font:400 7px/1 "Press Start 2P",monospace;color:#ff4d4d;animation:h2blink 1s steps(2) infinite}
.h2-pcLed{position:absolute;right:10px;bottom:6px;width:6px;height:6px;border-radius:50%;background:#35ff6b;box-shadow:0 0 4px #35ff6b}
.h2-pcTxt{flex:1;min-width:0;display:flex;flex-direction:column;justify-content:center}
.h2-pc .h2-gname{font-family:"Press Start 2P",Rubik,monospace;font-weight:400;font-size:15px;line-height:1.5}
.h2-pc .h2-gsub{margin-top:6px}
@media (hover:hover){.h2-app .h2-press:hover svg.h2-pcArt{animation:none}}
.h2-foot .h2-ver{flex:1 0 100%;justify-content:center;min-height:24px;font-size:11.5px;letter-spacing:.12em;color:var(--mute)}
/* набій: денце й закатаний край тримаються на абсолютних позиціях — у старішому Safari (macOS) діти кнопки-flex не розтягувались на висоту й зникали */
.h2-app .h2-shell .h2-shCap{position:absolute;left:0;top:0;bottom:0;height:auto}
.h2-app .h2-shell .h2-shCrimp{position:absolute;right:0;top:0;bottom:0;height:auto}
.h2-app .h2-shell .h2-shBody{margin-left:62px;margin-right:30px;min-height:96px}
/* те саме для білетика «Удача» й комп'ютера: не покладаємось на розтягування дітей кнопки */
.h2-app .h2-tkt{align-items:center}
.h2-app .h2-tktStub{min-height:44px}
.h2-app .h2-pcMon{min-height:104px}
.h2-pair.h2-solo{grid-template-columns:1fr}.h2-pair.h2-solo .h2-crate{width:62%}
.h2-win.h2-gzlogo{object-fit:contain;background:linear-gradient(#bfe3f5,#e3f2d8);padding:2px;box-sizing:border-box}
/* 1.2.7: шторка вибору гри завжди рівно в екран, вміст прокручується — «Грати з ботами» досяжна на низьких екранах */
#setup.h2s{position:fixed;inset:0;height:auto}
#setup.h2s .sheetCard{height:100%;max-height:100%;overflow-y:auto;-webkit-overflow-scrolling:touch;overscroll-behavior:contain;box-sizing:border-box}

/* 1.2.27 catalog */
.h2-catBar{display:flex;align-items:center;gap:8px;margin:2px auto 14px;padding:10px 16px;border-radius:999px;border:1px solid rgba(255,255,255,.18);background:rgba(0,0,0,.28);color:inherit;font:600 14px/1 inherit;cursor:pointer}
.h2-theme-light .h2-catBar{background:rgba(255,255,255,.6);border-color:rgba(0,0,0,.12)}
.h2-catIco{font-size:15px}
.h2-catCard .h2-catQ{width:100%;box-sizing:border-box;margin:8px 0 10px;padding:12px 14px;border-radius:12px;border:1px solid var(--line);background:var(--panel);color:inherit;font-size:16px;outline:0}
.h2-catCard .h2-catQ:focus{border-color:var(--gold)}
.h2-catF{display:flex;gap:6px;overflow-x:auto;padding-bottom:8px;scrollbar-width:none}
.h2-catChip{flex:0 0 auto;padding:7px 13px;border-radius:999px;border:1px solid var(--line);background:transparent;color:inherit;font-size:13px;cursor:pointer}
.h2-catChip.on{background:var(--gold);border-color:var(--gold);color:#111;font-weight:700}
.h2-catNone{text-align:center;margin:14px 0}

/* 1.2.31: catalog bar never floats over launch/loading screens */
.h2-ph-launch .h2-catBar,.h2-is-boom .h2-catBar{visibility:hidden}
/* 1.3: pill row + event strip never cover the intro tree or launch screens; they appear with the rest of the UI */
.h2-ph-launch .h2-pillRow,.h2-is-boom .h2-pillRow,.h2-ph-launch .h2-evStrip,.h2-is-boom .h2-evStrip{visibility:hidden}
.h2-is-intro .h2-pillRow,.h2-is-intro .h2-evStrip,.h2-is-intro .h2-friendsBtn,body:has(.h2-is-intro) .weGuestBar{animation:h2fadeIn .45s var(--ease-out) 2.1s both}
@keyframes h2fadeIn{from{opacity:0}to{opacity:1}}
/* 1.2.31: compact top chips — everything fits in one row; daily quests = one star + done/total */
.h2-chips{gap:6px}
.h2-chip{min-height:52px;padding:6px 8px;border-radius:16px;gap:3px}
.h2-sm{flex:0 0 54px;padding:6px 3px}
.h2-chip svg{width:19px;height:19px}
.h2-chipT{font-size:10.5px}
.h2-tktT{font-size:13px}
.h2-tktStub{width:28px;font-size:22px;margin-inline-end:6px;min-height:38px}
.h2-chip[data-act="quests"]{flex:0 0 54px;align-items:center;padding:6px 3px}
.h2-chip[data-act="quests"] .h2-stars svg:not(:first-child){display:none}
.h2-chip[data-act="quests"] .h2-stars svg{width:20px;height:20px}
.h2-app .h2-chips{gap:5px}
.h2-app .h2-chips .h2-tkt{flex:0 0 104px}
.h2-app .h2-chips .h2-sm{flex:0 0 56px}
.h2-app .h2-chips .h2-chip[data-act="quests"]{flex:0 0 52px}

/* 1.2.33 pill row under the title: catalog · referrals · add bot to group */
.h2-pillRow{display:flex;flex-wrap:wrap;justify-content:center;gap:6px;margin:2px 10px 14px}
.h2-pillRow .h2-catBar{margin:0;padding:9px 12px;font-size:13px}
.h2-pillRow .h2-gift2{border-color:rgba(232,185,49,.7);color:#f2cd5c}
.h2-theme-light .h2-pillRow .h2-gift2{color:#8a6500}

/* 1.2.33 profile tabs Гральня | Майнкрафт */
.h2p-tabs,.h2p-mcPer{display:flex;gap:6px;margin:4px 0 10px;padding:4px;border-radius:14px;background:rgba(127,127,127,.12)}
.h2p-tab{flex:1;padding:9px 10px;border:0;border-radius:10px;background:transparent;color:inherit;font:700 13.5px/1 inherit;cursor:pointer;opacity:.7}
.h2p-tab.on{background:var(--gold,#e8b931);color:#111;opacity:1}
.h2p-mcPer{background:transparent;padding:0}.h2p-mcPer .h2p-tab{border:1px solid rgba(127,127,127,.3);font-size:12.5px;padding:7px 8px}
.h2p-mcMode .h2p-kpis,.h2p-mcMode .h2p-daily,.h2p-mcMode .h2p-secT,.h2p-mcMode .h2p-games,.h2p-mcMode .h2p-note:not(.h2p-mc .h2p-note){display:none}
.h2p-mc{display:flex;flex-direction:column;gap:10px}
.h2p-mcCard{padding:12px 14px;border-radius:16px}
.h2p-mcHd{display:flex;justify-content:space-between;align-items:baseline;gap:8px;margin-bottom:8px}
.h2p-mcHd b{font-size:15px}.h2p-mcPl{font-size:12px;opacity:.7}
.h2p-mcGrid{display:grid;grid-template-columns:repeat(3,1fr);gap:6px}
.h2p-mcM{display:flex;flex-direction:column;align-items:center;padding:8px 4px;border-radius:10px;background:rgba(127,127,127,.12)}
.h2p-mcM b{font-size:16px}.h2p-mcM span{font-size:11px;opacity:.7;text-align:center}
.h2p-mcGo{flex:none;border:1px solid rgba(127,127,127,.3);padding:11px;opacity:1}
.h2-pillRow{gap:5px;flex-wrap:wrap;justify-content:center;margin-left:8px;margin-right:8px}   /* 2.0: 4 pills — wrap instead of squeezing into each other */
.h2-pillRow .h2-catBar{padding:8px 10px;font-size:12px;gap:5px;white-space:nowrap;flex:0 0 auto}
.h2-pillRow .h2-catIco{font-size:13px}

/* 1.2.33 profile canvas + seasonal strip */
.h2p-hero[data-bn]{border-radius:22px;padding:16px 10px 12px;margin:0 6px;box-shadow:inset 0 -80px 70px -30px rgba(0,0,0,.5)}
.h2p-hero[data-bn="bn_none"]{background:none;box-shadow:none}
.h2-evStrip{display:flex;align-items:center;justify-content:space-between;gap:8px;width:calc(100% - 32px);max-width:360px;margin:-6px auto 12px;padding:9px 14px;border-radius:14px;border:1px solid rgba(255,122,0,.6);background:rgba(255,122,0,.14);color:inherit;font:600 13px/1.2 inherit;cursor:pointer}
.h2-ev-winter{border-color:rgba(160,220,255,.6);background:rgba(160,220,255,.12)}   /* 1.3.11: flat tint instead of a two-colour gradient */
@media (prefers-reduced-motion:reduce){.h2-is-intro .h2-pillRow,.h2-is-intro .h2-evStrip,.h2-is-intro .h2-friendsBtn,body:has(.h2-is-intro) .weGuestBar{animation:none}}

/* 1.3.7: profile card background (tab «🎨 Картка») */
.h2p-bgPv{display:flex;flex-direction:column;gap:4px;justify-content:flex-end;min-height:96px;padding:14px 16px;border-radius:16px;border:1px solid rgba(255,255,255,.1);color:#f3efe6}
.h2p-bgPv b{font-size:22px}.h2p-bgPv span{font-size:12px;color:rgba(255,255,255,.7)}
.h2p-bgDef{padding:10px;border-radius:12px;border:1px solid rgba(127,127,127,.3);background:transparent;color:inherit;font:700 13.5px/1 inherit;cursor:pointer}
.h2p-bgDef.on{border-color:var(--gold,#e8b931);box-shadow:inset 0 0 0 1px var(--gold,#e8b931)}
.h2p-bgH{margin-top:4px;font-size:13px;font-weight:700;opacity:.75}
.h2p-bgG{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
.h2p-bgS{display:flex;flex-direction:column;align-items:center;gap:4px;padding:8px 4px;border-radius:12px;border:1px solid rgba(127,127,127,.25);background:rgba(127,127,127,.08);color:inherit;cursor:pointer;min-width:0}
.h2p-bgS i{width:34px;height:34px;border-radius:10px;box-shadow:inset 0 0 0 1px rgba(255,255,255,.25)}
.h2p-bgS .n{font-size:11px;line-height:1.15;text-align:center;max-width:100%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.h2p-bgS .p{font-size:11px;font-weight:700;color:var(--gold,#e8b931)}
.h2p-bgS.own .p{color:#7fe0a0}.h2p-bgS.on{border-color:var(--gold,#e8b931);box-shadow:inset 0 0 0 1px var(--gold,#e8b931)}
.h2p-bgCu{display:flex;align-items:center;gap:8px;padding:8px;border-radius:14px;border:1px solid rgba(127,127,127,.25)}
.h2p-bgCu.on{border-color:var(--gold,#e8b931)}
.h2p-bgCu>i{flex:1;height:40px;border-radius:10px}
.h2p-bgCu label{position:relative;width:36px;height:36px;border-radius:10px;flex:none;box-shadow:inset 0 0 0 1px rgba(255,255,255,.3);overflow:hidden}
.h2p-bgCu label input{position:absolute;inset:0;opacity:0;width:100%;height:100%;cursor:pointer}
.h2p-bgCu .h2p-tab{flex:0 0 auto;padding:10px 14px}
/* ===== 2.0.2 «Школа гори»: стопка підручників і герб школи ===== */
.h2-h-school{--g:#f6f0de;--gi:#1a2550}
.h2-school{position:relative;display:flex;align-items:center;gap:10px;min-height:128px;padding:12px 14px 12px 8px;border-radius:6px;color:#1a2550;
  background:linear-gradient(90deg,transparent 46px,#e8858f 46px,#e8858f 48px,transparent 48px),repeating-linear-gradient(0deg,#f8f3e3 0 19px,#cfdcef 19px 20px);background-color:#f8f3e3;
  box-shadow:0 6px 0 var(--edge),inset 0 0 0 2px #fffaf0;rotate:-.6deg}
.h2-schBooks{width:126px;flex:none;filter:drop-shadow(0 3px 2px rgba(0,0,0,.18));transform-origin:50% 90%;transition:transform .25s}
.h2-schTxt{flex:1;min-width:0;display:flex;flex-direction:column;align-items:flex-start}
.h2-schLogo{position:absolute;right:10px;top:-14px;width:58px;height:58px;rotate:8deg;filter:drop-shadow(0 4px 4px rgba(0,0,0,.35));transition:rotate .3s}
.h2-school .h2-gname{font-family:'Russo One',Rubik,sans-serif;font-size:20px;line-height:1.15;letter-spacing:.02em;color:#1a2550;padding-right:54px}
.h2-school .h2-gsub{margin-top:6px;color:#4a5578}
@media (hover:hover){.h2-school:hover .h2-schBooks{transform:rotate(-3deg) translateY(-2px)}.h2-school:hover .h2-schLogo{rotate:-4deg}}
.h2-theme-light .h2-school{color:#1a2550}
/* 2.1.1: «Re-Flash» cabinet — the same arcade machine, repainted in old-Flash red */
.h2-c-bomb{--sky:#d63a30}.h2-c-aces{--sky:#5a8ee8}.h2-c-hog{--sky:#d8601a}.h2-c-fury{--sky:#1e8a4a}.h2-c-rico{--sky:#8a7a62}.h2-c-fasty{--sky:#c8642a}.h2-c-dig{--sky:#7a4a2a}.h2-c-soon{--sky:#5a5e66}
.h2-rfX .h2-marq{background:#e4534a}.h2-rfX .h2-marqT{color:#fff6e8;text-shadow:0 2px 0 #3b2f2f}
.h2-rfX .h2-gm[disabled]{opacity:.55;filter:grayscale(.6)}

/* 2.1.5 Re-Flash: the home tile is a compilation CD, the room is a 2007 flash-games portal */
.h2-pair.h2-rfPair{grid-template-columns:1fr}
.h2-app button.h2-rfTile{position:relative;width:100%;min-height:118px;display:flex;align-items:center;padding:12px 14px;border:3px solid #3b2f2f;border-radius:8px;overflow:hidden;color:#f2f7ef;text-align:start;
  background:#121821 url(reflash-tile.svg) right -46px center/auto 100% no-repeat;box-shadow:0 6px 0 #2a2027}
.h2-rfTxt{position:relative;z-index:1;display:flex;flex-direction:column;align-items:flex-start;gap:4px;max-width:52%;text-shadow:0 1px 3px #121821}
.h2-rfTile .h2-gname{font-size:19px;font-weight:800}.h2-rfTile .h2-gsub{font-size:12px;opacity:.82;line-height:1.3}
.h2-rfTile .h2-tag{background:#ffe15a;color:#7a1a10}
.h2-fs{position:absolute;inset:0;z-index:4;display:flex;flex-direction:column;background:#c9d3de;font-family:Verdana,Tahoma,Rubik,sans-serif;color:#1a2a3a;animation:h2fsIn .32s cubic-bezier(.2,.9,.3,1.2) both}
.h2-fs.h2-out{animation:h2fsIn .2s reverse both}
@keyframes h2fsIn{from{transform:translateY(24px) scale(.96);opacity:0}}
.h2-fsTop{flex:none;display:flex;align-items:center;gap:8px;padding:calc(8px + env(safe-area-inset-top)) 10px 8px;background:linear-gradient(#f4f6f9,#d5dbe3);border-bottom:1px solid #9aa6b4}
.h2-app button.h2-fsBack{width:34px;height:30px;border-radius:15px;border:1px solid #8a97a6;background:linear-gradient(#fff,#dfe5ec);color:#2a3a4a;font:700 22px/1 Verdana,sans-serif;padding-bottom:3px}
.h2-fsUrl{flex:1;height:26px;border-radius:13px;border:1px solid #a9b4c0;background:#fff;display:flex;align-items:center;padding:0 12px;font:12px monospace;color:#4a5a6a;overflow:hidden;white-space:nowrap}
.h2-fsPage{flex:1;overflow-y:auto;overscroll-behavior:contain;padding-bottom:calc(16px + env(safe-area-inset-bottom))}
.h2-fsHead{position:relative;overflow:hidden;padding:20px 16px 18px;background:linear-gradient(#9ee2ff,#3fb2f0 60%,#1678c8);border-bottom:4px solid #ff8a00}
.h2-fsRays{position:absolute;inset:-60%;background:repeating-conic-gradient(from 0deg at 50% 70%,rgba(255,255,255,.16) 0 7deg,transparent 7deg 18deg);animation:h2fsSpin 40s linear infinite}
@keyframes h2fsSpin{to{transform:rotate(360deg)}}
.h2-fsLogo{position:relative;font:900 44px/1 "Arial Rounded MT Bold","Arial Black",Rubik,sans-serif;color:#fff;-webkit-text-stroke:2px #0a4f8a;paint-order:stroke;text-shadow:0 4px 0 rgba(10,79,138,.45)}
.h2-fsLogo span{color:#ffd23a}
.h2-fsTag{position:relative;margin-top:6px;font:700 13px Verdana,sans-serif;color:#fff;text-shadow:0 1px 0 #0a4f8a}
.h2-fsStar{position:absolute;right:10px;top:12px;width:78px;height:78px;transform:rotate(12deg);animation:h2fsPulse 1.6s ease-in-out infinite}
.h2-fsStar path{fill:#ff2d6f;stroke:#fff;stroke-width:3}.h2-fsStar text{font:900 14px "Arial Black",Arial,sans-serif;fill:#fff}
@keyframes h2fsPulse{50%{transform:rotate(12deg) scale(1.08)}}
.h2-fsNav{display:flex;gap:4px;padding:8px 10px 0;background:#e8edf2;border-bottom:1px solid #b8c3cf;overflow-x:auto}
.h2-fsNav span{flex:none;padding:7px 12px 6px;border:1px solid #b8c3cf;border-bottom:0;border-radius:8px 8px 0 0;background:linear-gradient(#fff,#dde4ec);font:700 12px Verdana,sans-serif;color:#4a5a6a}
.h2-fsNav span.on{background:#fff;color:#ff6a00;position:relative;top:1px}
.h2-fsGrid{display:grid;grid-template-columns:1fr 1fr;gap:12px;padding:14px 12px;background:#fff}
.h2-app button.h2-fsCard{display:flex;flex-direction:column;align-items:stretch;gap:4px;padding:6px 6px 8px;border:1px solid #c3ccd6;border-radius:10px;background:linear-gradient(#fff,#f1f4f7);color:#1a2a3a;text-align:start;box-shadow:0 2px 0 #d5dce4;
  animation:h2fsCard .4s calc(.08s + var(--i) * .06s) cubic-bezier(.2,.9,.3,1.3) both}
@keyframes h2fsCard{from{transform:translateY(14px);opacity:0}}
.h2-fsCard:active{transform:scale(.97)}
.h2-fsThumb{position:relative;display:grid;place-items:center;aspect-ratio:4/3;border-radius:6px;overflow:hidden;background:linear-gradient(160deg,var(--c1),var(--c2));box-shadow:inset 0 0 0 1px rgba(0,0,0,.12)}
.h2-fsThumb::after{content:"";position:absolute;left:0;right:0;top:0;height:45%;background:linear-gradient(rgba(255,255,255,.45),rgba(255,255,255,0))}
.h2-fsSpr{width:70%;height:auto;fill:none;stroke-width:1.02;image-rendering:pixelated;filter:drop-shadow(0 3px 0 rgba(0,0,0,.18))}
.h2-fsCard:hover .h2-fsSpr,.h2-fsCard:focus-visible .h2-fsSpr{animation:h2hop .5s steps(4) both}
.h2-fsBadge{position:absolute;right:4px;top:4px;z-index:1;padding:2px 6px;border-radius:4px;background:#ff2d6f;color:#fff;font:900 10px "Arial Black",Arial,sans-serif;transform:rotate(6deg);box-shadow:0 1px 0 rgba(0,0,0,.25)}
.h2-fsSize{position:absolute;left:4px;bottom:4px;z-index:1;padding:1px 4px;border-radius:3px;background:rgba(0,0,0,.45);color:#fff;font:10px monospace}
.h2-fsName{font:700 13.5px Verdana,sans-serif;color:#0a4f8a;margin-top:2px}
.h2-fsSub{font:11px/1.3 Verdana,sans-serif;color:#5a6a7a;flex:1}.h2-fsSub .plN{display:none}
.h2-fsPlay{align-self:flex-start;display:flex;align-items:center;gap:6px;margin-top:4px;padding:5px 12px 5px 9px;border-radius:999px;border:1px solid #c24f00;color:#fff;font:900 12px "Arial Black",Arial,sans-serif;
  background:linear-gradient(#ffb347,#ff7a00 50%,#f05a00 51%,#ff8a1a);box-shadow:inset 0 1px 0 rgba(255,255,255,.6),0 2px 0 #a64200;text-shadow:0 1px 0 #a64200}
.h2-fsTri{width:0;height:0;border-left:8px solid #fff;border-top:5px solid transparent;border-bottom:5px solid transparent}
.h2-fsFoot{display:flex;flex-direction:column;align-items:center;gap:6px;padding:14px;font:11px Verdana,sans-serif;color:#5a6a7a}
.h2-fsCnt{padding:2px 6px;background:#111;color:#37ff6a;font:13px monospace;letter-spacing:.2em;border:2px inset #777}
@media (prefers-reduced-motion:reduce){.h2-fsRays,.h2-fsStar,.h2-fsCard{animation:none}}

/* 2.2 «Віконна класика» home tile: a tiny desktop with a card game in a blue window */
.h2-app button.h2-wcTile{position:relative;width:100%;min-height:118px;display:flex;align-items:center;padding:12px 14px;border:3px solid #3b2f2f;border-radius:8px;overflow:hidden;color:#fff;text-align:start;background:#123a8c;box-shadow:0 6px 0 #2a2027}
.h2-wcScr{position:absolute;right:-6px;top:10px;bottom:-4px;width:58%;border-radius:6px 0 0 0;overflow:hidden;box-shadow:-4px 0 14px rgba(0,0,0,.35)}
.h2-wcWall{position:absolute;inset:0;background:linear-gradient(#2a6fdc,#6fb6f5 55%,#cfeaff 56%,#cfeaff 58%),#2a6fdc}
.h2-wcWall::after{content:"";position:absolute;left:-20%;right:-20%;bottom:-40%;height:85%;border-radius:50% 50% 0 0;background:linear-gradient(#7ccf4a,#2f8a2c)}
.h2-wcWin{position:absolute;left:12%;top:10%;right:6%;bottom:24%;border:2px solid #0831d9;border-top:0;border-radius:5px 5px 0 0;background:#0b7a2f;overflow:hidden}
.h2-wcTb{display:block;height:13px;padding:0 4px;font:700 8.5px/13px Tahoma,Verdana,sans-serif;color:#fff;background:linear-gradient(#0997ff,#0053ee 20%,#06f 85%,#003dd7)}
.h2-wcCards{position:absolute;left:8%;right:8%;top:22px;display:flex;gap:4%}
.h2-wcCards i{flex:1;aspect-ratio:5/7;border-radius:2px;background:#fbf7ec;box-shadow:0 1px 0 rgba(0,0,0,.4)}
.h2-wcCards i:nth-child(1)::after{content:"A♠";display:block;font:700 8px/1 monospace;color:#1d1d2b;padding:2px}
.h2-wcCards i:nth-child(2){background:repeating-linear-gradient(45deg,#7d1620 0 3px,#5c101a 3px 6px);border:1.5px solid #f3eee2}
.h2-wcCards i:nth-child(3)::after{content:"K♥";display:block;font:700 8px/1 monospace;color:#d8342b;padding:2px}
.h2-wcCards i:nth-child(4){background:repeating-linear-gradient(45deg,#7d1620 0 3px,#5c101a 3px 6px);border:1.5px solid #f3eee2}
.h2-wcBar{position:absolute;left:0;right:0;bottom:0;height:17%;background:linear-gradient(#3168d5,#4993e6 10%,#2157d7 30%,#245ddb)}
.h2-wcSt{position:absolute;left:0;top:0;bottom:0;padding:0 10px 0 6px;border-radius:0 8px 8px 0;font:italic 700 10px/1 "Trebuchet MS",sans-serif;display:flex;align-items:center;background:linear-gradient(#3c9b39,#6ad06a 15%,#3fa33c 40%,#2d7d2a)}
.h2-wcTile .h2-rfTxt{max-width:44%}
.h2-wcTile .h2-tag{background:#3fa33c;color:#fff}
/* 2.5.0: WestEastWarWorld — the pixel world map tile */
.h2-weww{position:relative;display:block;padding:0;border-radius:12px;overflow:hidden;background:#152238;box-shadow:0 6px 14px rgba(0,0,0,.35),inset 0 0 0 1px rgba(255,255,255,.08)}
.h2-wwLogo{display:block;width:100%;height:auto;aspect-ratio:360/112}
.h2-wwTxt{display:flex;align-items:center;gap:8px;padding:8px 12px 10px;background:#0b1220}
.h2-weww .h2-gsub{color:#9fb0c4;font-size:12px;line-height:1.3}
.h2-weww .h2-tag{position:static;flex:none}
@media (hover:hover){.h2-weww:hover .h2-wwLogo{filter:brightness(1.08)}}
