@font-face{font-family:Tj;src:url(Tajawal-Medium.ttf);font-weight:500}
@font-face{font-family:Tj;src:url(Tajawal-ExtraBold.ttf);font-weight:800}
@font-face{font-family:Tj;src:url(Tajawal-Black.ttf);font-weight:900}
*{box-sizing:border-box;margin:0;padding:0}
html,body{height:100%}
body{font-family:Tj,sans-serif;font-weight:800;color:#5b2a86;background:#7fcdf2}
.app{position:relative;height:100%;min-height:100dvh;overflow:hidden;isolation:isolate;container-type:size;direction:rtl}
.app::before{content:'';position:absolute;inset:-3%;background:url(bg.webp) center 72%/cover;z-index:-2;animation:drift 28s ease-in-out infinite alternate}
.app.dim::after{content:'';position:absolute;inset:0;background:#fff6;z-index:-1}
@keyframes drift{to{transform:scale(1.07) translateY(-1%)}}
.stage{position:absolute;inset:0;overflow-y:auto;overflow-x:hidden;padding:12px 16px 22px;display:flex;flex-direction:column;align-items:center;gap:12px;z-index:1}
.host .stage{padding:2.5cqh 3cqw;gap:2cqh}
.scenery{position:absolute;inset:0;overflow:hidden;pointer-events:none;z-index:0}
.scenery i{position:absolute;top:105%;animation:rise linear infinite}
.candy{width:26px;height:26px;border-radius:50%;border:2px solid #fff;background:repeating-conic-gradient(#ff7fa8 0 30deg,#fff 0 60deg);opacity:.85}
.candy.c1{background:repeating-conic-gradient(#68b7ee 0 30deg,#fff 0 60deg)}.candy.c2{background:repeating-conic-gradient(#b78ae0 0 30deg,#fff 0 60deg);width:18px;height:18px}.candy.c3{background:repeating-conic-gradient(#ffd34d 0 30deg,#fff 0 60deg)}
.spark{width:9px;height:9px;background:#fff;clip-path:polygon(50% 0,62% 38%,100% 50%,62% 62%,50% 100%,38% 62%,0 50%,38% 38%)}
@keyframes rise{to{transform:translate(40px,-130cqh) rotate(540deg)}}
.confetti{position:absolute;inset:0;pointer-events:none;z-index:9}
.wipe{position:absolute;left:50%;top:50%;width:40px;height:40px;margin:-20px;border-radius:50%;background:repeating-conic-gradient(#ff7fa8 0 20deg,#fff 0 40deg);z-index:8;pointer-events:none;animation:wipe .75s ease-in-out forwards}
@keyframes wipe{0%{transform:scale(0)}45%{transform:scale(60) rotate(90deg);opacity:1}100%{transform:scale(70) rotate(180deg);opacity:0}}
.card{background:#fffffff5;border:3px solid #5b2a86;border-radius:24px;padding:14px 18px;text-align:center;width:min(100%,520px);box-shadow:0 6px 0 #0002,0 12px 28px #3a105022;animation:pop .55s cubic-bezier(.2,1.6,.4,1) backwards}
.host .card{width:min(92cqw,1100px)}
h1{font-size:clamp(30px,9cqw,44px);line-height:1.3;font-weight:900}h2{font-size:22px;line-height:1.5}
.host h1{font-size:min(7cqw,9cqh)}.host h2{font-size:max(18px,min(3cqw,4.6cqh))}
.q{font-size:24px;line-height:1.6}.host .q{font-size:max(22px,min(4.4cqw,6.5cqh))}
@keyframes pop{from{transform:scale(.5) translateY(30px);opacity:0}}
@keyframes slide{from{transform:translateX(-110%);opacity:0}}
button{font:inherit;cursor:pointer;border:3px solid #fff;border-radius:20px;background:#e03e62;color:#fff;font-size:22px;padding:11px 30px;box-shadow:0 6px 0 #9e2441;flex:none;transition:transform .1s,box-shadow .1s}
button:active{transform:translateY(5px);box-shadow:0 1px 0 #9e2441}
button:focus-visible,input:focus-visible{outline:4px solid #5b2a86}
.go{animation:breathe 1.8s ease-in-out infinite}
@keyframes breathe{50%{box-shadow:0 6px 0 #9e2441,0 0 0 10px #e03e6255}}
.opts{display:grid;gap:10px;width:min(100%,520px)}.host .opts{width:min(92cqw,1100px);grid-template-columns:repeat(auto-fit,minmax(230px,1fr))}
.opt{display:flex;align-items:center;gap:10px;justify-content:center;color:#fff;font-size:23px;padding:14px;min-height:64px;background:#d93a63;box-shadow:0 6px 0 #962042;animation:slide .5s cubic-bezier(.2,1.2,.4,1) backwards}
.opt:nth-child(2){background:#2279bd;box-shadow:0 6px 0 #155082;animation-delay:.12s}.opt:nth-child(3){background:#b86f00;box-shadow:0 6px 0 #7c4a00;animation-delay:.24s}
.opt s{text-decoration:none;font-size:20px}
.host .opt{font-size:max(20px,min(3cqw,4.5cqh));cursor:default}
.opt.off{opacity:.35;filter:saturate(.4)}.opt.right{opacity:1;filter:none;outline:5px solid #38c172;animation:win 1s ease-in-out infinite}
@keyframes win{50%{scale:1.05}}
.opt.mine{outline:5px solid #5b2a86}
.bar{display:flex;justify-content:space-between;align-items:center;width:min(100%,520px);gap:8px;font-size:17px}.host .bar{width:min(92cqw,1100px);font-size:max(16px,2cqw)}
.pill{background:#5b2a86;color:#fff;border-radius:16px;padding:6px 16px;border:2px solid #fff}.pill.y{background:#ffd34d;color:#5b2a86}
.big{font-size:min(14cqw,13cqh);font-weight:900;line-height:1}
.bump{animation:bump .45s}@keyframes bump{40%{transform:scale(1.35)}}
.girl{margin-top:auto;height:min(32cqh,320px);min-height:110px;max-width:80%;object-fit:contain;filter:drop-shadow(0 8px 5px #0003);animation:enter .8s cubic-bezier(.2,1.3,.4,1) backwards,idle 3.2s ease-in-out .8s infinite;transform-origin:50% 100%;flex:0 1 auto}
.girl.jump{animation:enter .6s backwards,jump .9s ease-in-out .6s infinite}
@keyframes enter{from{transform:translateX(120px) rotate(8deg);opacity:0}}
@keyframes idle{50%{transform:translateY(-7px) scale(1.012,.992) rotate(-.8deg)}}
@keyframes jump{0%,100%{transform:scale(1.05,.95)}45%{transform:translateY(-34px) scale(.97,1.04)}}
.host .girl.side{position:absolute;left:1cqw;bottom:0;height:34cqh;z-index:-1}
input{font:inherit;font-size:22px;width:100%;padding:12px;border:3px solid #5b2a86;border-radius:16px;text-align:center;color:#5b2a86;margin-top:10px}
.err{color:#b3123c;font-size:17px;min-height:1.2em}
.names{display:flex;flex-wrap:wrap;gap:10px;justify-content:center;width:min(92cqw,1100px)}
.name{background:#fff;border-radius:30px;padding:8px 18px;font-size:max(17px,2cqw);border:3px solid #e03e62;animation:pop .6s cubic-bezier(.2,1.8,.4,1) backwards;cursor:pointer;color:#5b2a86;box-shadow:0 4px 0 #0002}
.join{display:flex;gap:3cqw;align-items:center;justify-content:center;flex-wrap:wrap}.join svg{width:max(130px,24cqh);height:max(130px,24cqh);background:#fff;padding:8px;border-radius:12px}
.pin{font-size:max(40px,min(8cqw,11cqh));letter-spacing:.12em;font-weight:900;direction:ltr}
.url{font-size:16px;direction:ltr;word-break:break-all}
.chart{display:flex;gap:3cqw;align-items:flex-end;height:16cqh;min-height:80px;justify-content:center}
.col{display:flex;flex-direction:column;justify-content:flex-end;align-items:center;height:100%;width:max(60px,9cqw)}
.col i{width:100%;border-radius:12px 12px 0 0;background:#d93a63;animation:grow .8s cubic-bezier(.2,1.2,.4,1) .3s backwards;transform-origin:bottom}.col:nth-child(2) i{background:#2279bd}.col:nth-child(3) i{background:#b86f00}
@keyframes grow{from{transform:scaleY(0)}}
.rows{display:flex;flex-direction:column;gap:7px;width:min(100%,520px);flex:none}.host .rows{width:min(92cqw,900px)}
.row{display:flex;align-items:center;gap:12px;background:#fff;border-radius:16px;padding:8px 14px;font-size:max(17px,min(2.4cqw,3.6cqh));border:3px solid #fff;box-shadow:0 4px 0 #0002}
.row b{flex:none;width:1.9em;height:1.9em;display:grid;place-items:center;border-radius:50%;background:#5b2a86;color:#fff}
.row:nth-child(1) b{background:#e0a100}.row:nth-child(2) b{background:#8d99ae}.row:nth-child(3) b{background:#b5703a}
.row span{flex:1;text-align:start;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.row em{font-style:normal}.row small{font-size:.7em;font-weight:500}.row.me{border-color:#e03e62;background:#ffe9ef}
.podium{display:flex;align-items:flex-end;justify-content:center;gap:1.5cqw;width:min(94cqw,900px);flex:none}
.step{flex:1;display:flex;flex-direction:column;align-items:center;gap:6px;text-align:center;animation:up .9s cubic-bezier(.2,1.4,.4,1) backwards;min-width:0}
.step .who{background:#fff;border-radius:14px;padding:6px 10px;font-size:max(16px,2.4cqw);max-width:100%;overflow-wrap:anywhere}
.step .block{width:100%;border-radius:18px 18px 0 0;color:#fff;display:grid;place-items:center;font-size:max(30px,5cqw);border:3px solid #fff;border-bottom:0}
.p1 .block{height:24cqh;background:linear-gradient(#ffd34d,#d99a00)}.p2 .block{height:17cqh;background:linear-gradient(#cfd8e8,#8d99ae)}.p3 .block{height:12cqh;background:linear-gradient(#e3a874,#a8632f)}
.p1{order:2;animation-delay:2.4s}.p2{order:1;animation-delay:1.3s}.p3{order:3;animation-delay:.4s}
@keyframes up{from{transform:translateY(60cqh);opacity:0}}
.gate{position:absolute;inset:0;z-index:7;pointer-events:none;display:flex;direction:ltr;perspective:900px;animation:gone .1s 3.1s forwards}
.gate div{flex:1;background:repeating-linear-gradient(90deg,#8a4b2f 0 38px,#a45c39 38px 76px);border:10px solid #fff;box-shadow:inset 0 0 0 8px #e03e62;animation:openL 1.8s cubic-bezier(.6,0,.4,1) 1.1s forwards;transform-origin:left}
.gate div+div{animation-name:openR;transform-origin:right}
.gate::after{content:'';position:absolute;inset:0;background:radial-gradient(#fff,#ffe58a88 30%,#0000 65%);opacity:0;animation:light 2s 1.2s}
@keyframes openL{to{transform:rotateY(104deg)}}@keyframes openR{to{transform:rotateY(-104deg)}}@keyframes light{40%{opacity:1}}@keyframes gone{to{visibility:hidden}}
.tools{position:absolute;bottom:8px;right:8px;display:flex;gap:6px;z-index:10}.tools button{font-size:14px;padding:6px 12px;background:#5b2a86;box-shadow:none;border-width:2px}
@media (prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}.scenery,.gate,.wipe{display:none}}
.timer{position:relative;flex:none;width:76px;height:76px;border-radius:50%;display:grid;place-items:center;background:conic-gradient(#38c172 calc(var(--k)*1turn),#fff6 0)}
.timer::before{content:'';position:absolute;inset:8px;border-radius:50%;background:#fff}.timer b{position:relative;font-size:28px;font-weight:900}
.host .timer{width:max(80px,15cqh);height:max(80px,15cqh)}.host .timer b{font-size:max(28px,6cqh)}
.timer.low{background:conic-gradient(#e03e62 calc(var(--k)*1turn),#fff6 0);animation:beat .5s infinite}@keyframes beat{50%{transform:scale(1.14)}}
.map{display:flex;gap:2cqw;justify-content:center;flex-wrap:wrap;width:min(94cqw,1000px)}
.spot{background:#fff;border-radius:20px;padding:10px 14px;text-align:center;border:4px solid #fff;min-width:130px;font-size:max(15px,2cqw);animation:pop .6s backwards}
.spot b{display:grid;place-items:center;width:46px;height:46px;margin:auto;border-radius:50%;background:#999;color:#fff}.spot.done b{background:#27844d}.spot.next{border-color:#e03e62;animation:pop .6s backwards,win 1.2s .7s infinite}.spot.next b{background:#e03e62}
.host .rows.many{display:grid;grid-auto-flow:column;grid-template-columns:1fr 1fr;grid-template-rows:repeat(var(--n),auto);gap:1cqh 1.5cqw;width:min(92cqw,1100px)}
.host .rows.many .row{font-size:max(14px,min(1.8cqw,2.6cqh));padding:.4cqh 1cqw;min-width:0}
.host .podium~.rows .row{font-size:max(12px,min(1.5cqw,2cqh));padding:.1cqh 1cqw}.host .podium~.rows{gap:.5cqh 1.5cqw}
.host .podium~h2{display:none}.host .p1 .block{height:15cqh}.host .p2 .block{height:11cqh}.host .p3 .block{height:8cqh}.host .podium .block{font-size:max(24px,5cqh)}
