[hidden]{display:none!important}
@font-face{font-family:Manrope;src:url(/fonts/manrope.woff2) format("woff2");font-weight:200 800;font-display:swap}
@font-face{font-family:Gilda;src:url(/fonts/gilda.woff2) format("woff2");font-weight:400;font-display:swap}
:root{--brand:#017785;--brand-d:#01606b;--brand-dd:#014b54;--t50:#eef7f8;--t100:#d9eef0;--t200:#b3dde2;--t300:#80c6ce;--ink:#0d1517;--ink2:#2a3537;--muted:#647275;--line:#e4eced;--bg:#ffffff;--soft:#f6f9f9;--win:#ff5a5f;--gold:#f2b84b;
--r:18px;--sh:0 1px 2px rgba(1,60,68,.06),0 6px 18px rgba(1,60,68,.07);--safe-b:env(safe-area-inset-bottom,0px);--safe-t:env(safe-area-inset-top,0px)}
*{box-sizing:border-box}html{-webkit-text-size-adjust:100%;height:100%}
body{margin:0;min-height:100%;font-family:Manrope,system-ui,-apple-system,Segoe UI,sans-serif;color:var(--ink);background:var(--bg);-webkit-font-smoothing:antialiased;overscroll-behavior-y:none}
h1,h2,h3{font-family:Gilda,Georgia,serif;font-weight:400;letter-spacing:.005em;margin:0}
button,input,select,textarea{font:inherit;color:inherit}
button{cursor:pointer;-webkit-tap-highlight-color:transparent}
a{color:var(--brand)}
:focus-visible{outline:3px solid var(--t300);outline-offset:2px;border-radius:10px}
.boot{display:grid;place-items:center;height:100vh}
.wrap{max-width:1180px;margin:0 auto;padding:0 18px}
/* top bar */
.top{position:sticky;top:0;z-index:20;background:rgba(255,255,255,.94);backdrop-filter:saturate(1.4) blur(10px);-webkit-backdrop-filter:saturate(1.4) blur(10px);border-bottom:1px solid var(--line);padding-top:var(--safe-t)}
.top .wrap{display:flex;align-items:center;gap:12px;height:62px}
.brand{display:flex;align-items:center;gap:10px;text-decoration:none;color:var(--ink);min-width:0}
.brand img{height:26px;width:auto;display:block}
.brand b{font-family:Gilda,serif;font-weight:400;font-size:20px;color:var(--brand);white-space:nowrap}
.sp{flex:1}
.pill{display:inline-flex;align-items:center;gap:7px;border:0;border-radius:999px;padding:8px 14px 8px 9px;background:var(--brand);color:#fff;font-weight:800;font-size:15px;text-decoration:none;white-space:nowrap;box-shadow:0 2px 8px rgba(1,119,133,.25)}
.pill .coin{width:22px;height:22px;border-radius:50%;background:#fff;color:var(--brand);display:grid;place-items:center;font-size:12px;font-weight:800}
.pill small{font-weight:600;opacity:.85;font-size:12px}
.nav{display:flex;gap:4px}
.nav a{padding:9px 12px;border-radius:12px;text-decoration:none;color:var(--ink2);font-weight:700;font-size:14.5px}
.nav a.on{background:var(--t50);color:var(--brand-d)}
.tabbar{display:none}
@media (max-width:760px){.nav{display:none}.brand b{display:none}
.tabbar{display:flex;position:fixed;left:0;right:0;bottom:0;z-index:30;background:rgba(255,255,255,.97);border-top:1px solid var(--line);padding:6px 6px calc(6px + var(--safe-b));backdrop-filter:blur(10px)}
.tabbar a{flex:1;display:flex;flex-direction:column;align-items:center;gap:3px;font-size:11.5px;font-weight:700;color:var(--muted);text-decoration:none;padding:4px 0}
.tabbar a svg{width:24px;height:24px}.tabbar a.on{color:var(--brand)}
main.page{padding-bottom:calc(84px + var(--safe-b))}}
main.page{padding-top:18px;padding-bottom:60px}
.hello{display:flex;align-items:flex-end;justify-content:space-between;gap:12px;margin:6px 0 16px}
.hello h1{font-size:34px;line-height:1.1}
.hello p{margin:6px 0 0;color:var(--muted);font-weight:600}
.search{position:relative;margin:0 0 18px;display:block}
.search input{width:100%;height:52px;border-radius:16px;border:1.5px solid var(--line);background:var(--soft);padding:0 16px 0 48px;font-size:16px;font-weight:600;outline:none}
.search input:focus{border-color:var(--t300);background:#fff}
.search svg{position:absolute;left:16px;top:50%;margin-top:-11px;width:22px;height:22px;color:var(--muted)}
.cats{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:10px;margin:0 0 22px}
@media (max-width:760px){.cats{grid-template-columns:repeat(auto-fit,minmax(96px,1fr))}}
.cat{border:1.5px solid var(--line);background:#fff;border-radius:16px;padding:12px 10px;display:flex;flex-direction:column;align-items:center;gap:6px;font-weight:800;font-size:14px;color:var(--ink)}
.cat svg{width:28px;height:28px;color:var(--brand)}
.cat small{font-weight:700;color:var(--muted);font-size:12px}
.cat.on{background:var(--brand);border-color:var(--brand);color:#fff}.cat.on svg,.cat.on small{color:#fff}
.hero{position:relative;overflow:hidden;border-radius:24px;background:linear-gradient(120deg,var(--brand-dd),var(--brand) 70%,#0a8f9d);color:#fff;padding:22px;display:flex;align-items:center;gap:18px;margin:0 0 26px;text-decoration:none;box-shadow:var(--sh)}
.hero .k{font-size:12px;font-weight:800;letter-spacing:.12em;text-transform:uppercase;opacity:.85}
.hero h2{font-size:30px;margin:6px 0 4px}
.hero p{margin:0 0 14px;opacity:.9;font-weight:600;font-size:14.5px}
.hero .art{width:150px;height:150px;flex:none;border-radius:22px;overflow:hidden;box-shadow:0 10px 30px rgba(0,0,0,.25)}
.hero .art svg{display:block;width:100%;height:100%}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;border:0;border-radius:14px;padding:12px 18px;font-weight:800;font-size:15px;text-decoration:none;background:var(--brand);color:#fff;min-height:46px}
.btn.w{background:#fff;color:var(--brand-d)}.btn.ghost{background:var(--t50);color:var(--brand-d)}.btn.line{background:#fff;border:1.5px solid var(--line);color:var(--ink)}
.btn.sm{padding:8px 12px;min-height:36px;font-size:13.5px;border-radius:11px}.btn.big{min-height:56px;font-size:17px;padding:14px 22px}
.btn:disabled{opacity:.45;cursor:default}
.btn.danger{background:var(--win)}
.row-h{display:flex;align-items:baseline;justify-content:space-between;margin:0 0 12px}
.row-h h2{font-size:24px}.row-h span{color:var(--muted);font-weight:700;font-size:13.5px}
.strip{display:grid;grid-auto-flow:column;grid-auto-columns:minmax(150px,1fr);gap:14px;overflow-x:auto;padding:2px 2px 12px;margin:0 -2px 18px;scroll-snap-type:x mandatory}
.strip::-webkit-scrollbar{display:none}
.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(160px,1fr));gap:16px;margin-bottom:26px}
@media (max-width:420px){.grid{grid-template-columns:repeat(2,1fr);gap:12px}}
.tile{display:block;text-decoration:none;color:var(--ink);scroll-snap-align:start;border-radius:20px;background:#fff;border:1px solid var(--line);overflow:hidden;box-shadow:var(--sh);transition:transform .15s}
.tile:active{transform:scale(.98)}
.tile .art{aspect-ratio:1/1;display:block}.tile .art svg{display:block;width:100%;height:100%}
.tile .meta{padding:10px 12px 12px}
.tile b{display:block;font-size:15px;font-weight:800;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tile .like{display:block;color:var(--muted);font-size:12.5px;font-weight:600;margin-top:2px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tile .pts{display:inline-block;margin-top:7px;font-size:12px;font-weight:800;color:var(--brand-d);background:var(--t50);border-radius:999px;padding:3px 9px}
.empty{color:var(--muted);font-weight:600;padding:30px 0;text-align:center}
.foot{color:var(--muted);font-size:12.5px;text-align:center;padding:10px 0 20px}
/* game page */
.gtop{display:flex;align-items:center;gap:10px;margin:0 0 12px;flex-wrap:wrap}
.gtop h1{font-size:28px;line-height:1.1}
.gtop .like{color:var(--muted);font-weight:700;font-size:13.5px}
.back{width:42px;height:42px;border-radius:13px;border:1.5px solid var(--line);background:#fff;display:grid;place-items:center;text-decoration:none;color:var(--ink);flex:none}
.back svg{width:22px;height:22px}
.vbar{display:flex;gap:8px;align-items:center;flex-wrap:wrap;margin:0 0 12px}
.vbar select{height:42px;border-radius:12px;border:1.5px solid var(--line);padding:0 12px;font-weight:700;background:#fff;max-width:100%}
.earn{font-weight:800;color:var(--brand-d);background:var(--t50);border-radius:999px;padding:8px 12px;font-size:13.5px}
.status{min-height:24px;font-weight:700;color:var(--ink2);margin:0 0 10px;font-size:15px}
.stage{position:relative;user-select:none;-webkit-user-select:none;touch-action:manipulation}
.howto{color:var(--muted);font-size:14px;font-weight:600;max-width:640px;margin:16px 0 0}
/* sheets / modal */
.scrim{position:fixed;inset:0;z-index:60;background:rgba(5,25,28,.45);display:grid;place-items:center;padding:18px;animation:fade .15s}
@keyframes fade{from{opacity:0}}
.sheet{background:#fff;border-radius:26px;max-width:440px;width:100%;padding:26px 22px 22px;box-shadow:0 30px 80px rgba(0,0,0,.25);text-align:center;max-height:92vh;overflow:auto}
.sheet h2{font-size:30px;margin:6px 0 6px}.sheet p{color:var(--ink2);font-weight:600;margin:8px 0}
.sheet .big{font-size:46px;font-weight:800;color:var(--brand);letter-spacing:-.02em}
.sheet .acts{display:flex;gap:10px;justify-content:center;flex-wrap:wrap;margin-top:16px}
.sheet .qr{width:190px;height:190px;margin:10px auto;display:block;border-radius:14px;border:1px solid var(--line);image-rendering:pixelated}
.burst{width:74px;height:74px;margin:0 auto;border-radius:50%;background:var(--t50);display:grid;place-items:center;color:var(--brand)}
.burst svg{width:40px;height:40px}
.field{display:block;text-align:left;margin:12px 0;font-weight:700;font-size:14px;color:var(--ink2)}
.field input,.field select,.field textarea{display:block;width:100%;margin-top:6px;height:50px;border-radius:14px;border:1.5px solid var(--line);padding:0 14px;font-size:16px;font-weight:600;background:#fff;outline:none}
.field textarea{height:80px;padding:12px 14px}
.field input:focus{border-color:var(--brand)}
.err{color:#c4323a;font-weight:700;font-size:14px;min-height:20px}
.toast{position:fixed;left:50%;bottom:calc(96px + var(--safe-b));transform:translateX(-50%);background:var(--ink);color:#fff;padding:12px 18px;border-radius:14px;font-weight:700;z-index:80;max-width:90vw;box-shadow:var(--sh);animation:fade .2s}
/* rewards */
.bal{border-radius:26px;background:linear-gradient(135deg,var(--brand-dd),var(--brand));color:#fff;padding:24px;margin:0 0 22px;box-shadow:var(--sh)}
.bal .k{font-weight:800;font-size:12px;letter-spacing:.12em;text-transform:uppercase;opacity:.85}
.bal .n{font-size:50px;font-weight:800;letter-spacing:-.03em;line-height:1.05;margin:6px 0 2px}
.bal .n small{font-size:20px;font-weight:700;opacity:.85}
.bal .v{font-weight:700;opacity:.92}
.bar{height:10px;border-radius:99px;background:rgba(255,255,255,.25);margin:16px 0 8px;overflow:hidden}.bar i{display:block;height:100%;background:#fff;border-radius:99px}
.cols{display:grid;grid-template-columns:1fr 1.25fr;gap:22px}
@media (max-width:860px){.cols{grid-template-columns:1fr}}
.card{border:1px solid var(--line);border-radius:22px;background:#fff;padding:18px;box-shadow:var(--sh);margin-bottom:18px}
.card h2{font-size:23px;margin-bottom:10px}
.li{display:flex;align-items:center;gap:12px;padding:11px 0;border-top:1px solid var(--line)}
.li:first-of-type{border-top:0}
.li .ic{width:42px;height:42px;border-radius:12px;overflow:hidden;flex:none}.li .ic svg{width:100%;height:100%;display:block}
.li .t{flex:1;min-width:0}.li .t b{display:block;font-size:15px}.li .t small{color:var(--muted);font-weight:600}
.plus{font-weight:800;color:var(--brand)}.minus{font-weight:800;color:var(--ink2)}
.house{display:flex;align-items:center;gap:12px;padding:12px 0;border-top:1px solid var(--line)}
.house:first-of-type{border-top:0}
.house .ph{width:58px;height:58px;border-radius:14px;flex:none;background:var(--t50);display:grid;place-items:center;color:var(--brand);font-family:Gilda,serif;font-size:22px}
.house .t{flex:1;min-width:0}.house b{display:block}.house small{color:var(--muted);font-weight:700}
.need{font-size:12.5px;font-weight:800;color:var(--muted)}
.note{background:var(--t50);border-radius:16px;padding:12px 14px;color:var(--brand-dd);font-weight:600;font-size:14px;margin:0 0 16px}
/* admin */
.adm{display:grid;grid-template-columns:repeat(2,1fr);gap:18px}
@media (max-width:900px){.adm{grid-template-columns:1fr}}
.adm .card.wide{grid-column:1/-1}
.seg{display:inline-flex;background:var(--soft);border:1.5px solid var(--line);border-radius:14px;padding:4px;gap:4px;flex-wrap:wrap}
.seg button{border:0;background:transparent;border-radius:10px;padding:9px 14px;font-weight:800;font-size:14px;color:var(--ink2)}
.seg button.on{background:var(--brand);color:#fff}
.sw{position:relative;width:52px;height:31px;flex:none;border-radius:99px;border:0;background:#cfd8da;transition:background .15s;padding:0}
.sw::after{content:"";position:absolute;left:3px;top:3px;width:25px;height:25px;border-radius:50%;background:#fff;box-shadow:0 1px 3px rgba(0,0,0,.25);transition:left .15s}
.sw.on{background:var(--brand)}.sw.on::after{left:24px}
.set{display:flex;align-items:center;gap:12px;padding:10px 0;border-top:1px solid var(--line)}
.set:first-of-type{border-top:0}
.set .t{flex:1;min-width:0}.set b{display:block;font-size:14.5px}.set small{color:var(--muted);font-weight:600;font-size:12.5px}
.num{width:104px;height:42px;border-radius:12px;border:1.5px solid var(--line);padding:0 10px;font-weight:800;text-align:right;font-size:15px}
.stat{display:grid;grid-template-columns:repeat(4,1fr);gap:10px}
@media (max-width:520px){.stat{grid-template-columns:repeat(2,1fr)}}
.stat div{background:var(--t50);border-radius:16px;padding:12px}.stat b{display:block;font-size:24px;color:var(--brand-dd)}.stat small{font-weight:700;color:var(--muted)}
table.t{width:100%;border-collapse:collapse;font-size:14px}table.t th{text-align:left;color:var(--muted);font-size:12px;text-transform:uppercase;letter-spacing:.06em;padding:8px 6px}table.t td{border-top:1px solid var(--line);padding:9px 6px;vertical-align:middle}
.tag{display:inline-block;border-radius:99px;padding:3px 9px;font-size:12px;font-weight:800;background:var(--soft);color:var(--muted)}
.tag.ok{background:var(--t50);color:var(--brand-d)}.tag.new{background:#fff1e0;color:#a35b00}
.scroll{max-height:440px;overflow:auto}
/* table (kiosk) mode */
body.kiosk{background:var(--brand-dd);overflow:hidden;position:fixed;inset:0}
.kio{position:fixed;inset:0;background:radial-gradient(120% 90% at 20% 0%,var(--brand) 0%,var(--brand-d) 55%,var(--brand-dd) 100%);color:#fff;display:flex;flex-direction:column;padding:calc(22px + var(--safe-t)) 28px calc(18px + var(--safe-b))}
.kio header{display:flex;align-items:center;gap:16px}
.kio header img{height:34px}
.kio header h1{font-size:34px}
.kio header h1 span{opacity:.75}
.kio .kgrid{flex:1;display:grid;grid-template-columns:repeat(4,1fr);grid-auto-rows:1fr;gap:18px;margin:22px 0 18px;min-height:0}
.ktile{border:0;border-radius:26px;background:rgba(255,255,255,.1);color:#fff;padding:12px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;text-align:center;box-shadow:inset 0 0 0 1px rgba(255,255,255,.16);min-height:0}
.ktile .art{width:min(120px,52%);aspect-ratio:1;border-radius:22px;overflow:hidden;box-shadow:0 8px 24px rgba(0,0,0,.22)}
.ktile .art svg{width:100%;height:100%;display:block}
.ktile b{font-size:19px;font-weight:800}.ktile small{opacity:.8;font-weight:600;font-size:13px}
.kio footer{display:flex;align-items:center;gap:16px}
.kqr{display:flex;align-items:center;gap:12px;background:rgba(255,255,255,.1);border-radius:18px;padding:10px 14px 10px 10px}
.kqr img{width:74px;height:74px;border-radius:10px;background:#fff}
.kqr b{display:block;font-size:15px}.kqr small{opacity:.8;font-weight:600}
.lock{display:flex;align-items:center;gap:10px;border:0;background:transparent;color:#fff;opacity:.8;font-weight:700;padding:12px;border-radius:14px;user-select:none;-webkit-user-select:none;-webkit-touch-callout:none}
.lock svg{width:26px;height:26px}.lock i{display:block;width:0;height:3px;background:#fff;border-radius:3px;transition:width .1s linear}
.lock.hold{opacity:1;background:rgba(255,255,255,.12)}
@media (max-width:900px){.kio .kgrid{grid-template-columns:repeat(3,1fr)}}
@media (max-width:600px){.kio .kgrid{grid-template-columns:repeat(2,1fr);gap:12px}.kio header h1{font-size:24px}.kqr small{display:none}.ktile b{font-size:16px}}
.kgame{position:fixed;inset:0;background:#fff;overflow:auto;padding:calc(14px + var(--safe-t)) 18px calc(14px + var(--safe-b))}
.pad{display:grid;grid-template-columns:repeat(3,72px);gap:12px;justify-content:center;margin:16px 0 6px}
.pad button{height:72px;border-radius:50%;border:1.5px solid var(--line);background:#fff;font-size:26px;font-weight:800}
.pad button:active{background:var(--t50)}
.dots{display:flex;gap:10px;justify-content:center;margin:12px 0}.dots i{width:14px;height:14px;border-radius:50%;border:2px solid var(--brand)}.dots i.f{background:var(--brand)}

.skel{border-radius:22px;min-height:360px;background:linear-gradient(90deg,var(--soft) 25%,var(--t50) 50%,var(--soft) 75%);background-size:300% 100%;animation:sk 1.2s infinite linear;margin-bottom:18px}@keyframes sk{from{background-position:100% 0}to{background-position:0 0}}
