#hk-town-world{position:fixed!important;inset:0!important;z-index:10020!important;display:block!important;overflow:hidden!important;width:100vw!important;height:100vh!important;height:var(--hk-viewport-height,100dvh)!important;min-height:0!important;margin:0!important;padding:0!important;background:#5e5d5d;color:#fff4cc;font-family:system-ui,-apple-system,"Segoe UI",sans-serif;isolation:isolate;touch-action:none;overscroll-behavior:none;user-select:none;-webkit-user-select:none}
#hk-town-world *{box-sizing:border-box}
#hk-town-canvas{position:absolute;inset:0;display:block;width:100%;height:100%;touch-action:none;outline:0}
#hk-town-world-labels{position:absolute;z-index:4;inset:0;overflow:hidden;pointer-events:none}
.hk-town-topbar{position:absolute;z-index:5;top:calc(10px + env(safe-area-inset-top) + var(--hk-safe-top,0px));right:calc(12px + env(safe-area-inset-right) + var(--hk-safe-right,0px));left:calc(12px + env(safe-area-inset-left) + var(--hk-safe-left,0px));display:flex;align-items:center;gap:10px;min-height:54px;pointer-events:none}
.hk-town-player-chip,.hk-town-wallet,.hk-town-menu-toggle{pointer-events:auto;border:1px solid #e9d58d9c;background:linear-gradient(135deg,#0a211bdc,#102c23e8);box-shadow:0 8px 26px #10231d45,inset 0 1px #ffffff19;backdrop-filter:blur(9px);-webkit-backdrop-filter:blur(9px)}
.hk-town-player-chip{display:flex;align-items:center;gap:9px;min-width:0;max-width:min(300px,44vw);padding:6px 11px 6px 14px;border-radius:16px}
.hk-town-player-chip img{width:38px;height:38px;flex:none;object-fit:cover;border:2px solid #f1d789;border-radius:50%;background:#17392b}
.hk-town-player-chip span{display:grid;min-width:0;line-height:1.3}.hk-town-player-chip small{color:#b9d8c1;font-size:9px;font-weight:850}.hk-town-player-chip strong{overflow:hidden;color:#fff0bd;font-size:13px;text-overflow:ellipsis;white-space:nowrap}
.hk-town-wallet{display:flex;align-items:center;gap:6px;padding:6px;border-radius:15px;margin-inline-start:auto}
.hk-town-wallet button{display:flex;align-items:center;gap:6px;min-height:36px;padding:0 10px;border:1px solid #e5d18a38;border-radius:11px;background:#0719128a;color:#fff0b5;font:900 12px system-ui;cursor:pointer}
.hk-town-wallet button>span{font-size:15px}.hk-town-wallet button i{display:grid;place-items:center;width:17px;height:17px;border-radius:50%;background:#d1b85c;color:#172519;font-size:13px;font-style:normal}.hk-town-score{padding-inline:7px;color:#f4e2a6;font-size:11px;font-weight:900;white-space:nowrap}
.hk-town-menu-toggle{display:grid;align-content:center;justify-items:center;gap:4px;width:45px;height:45px;flex:none;border-radius:14px;cursor:pointer}.hk-town-menu-toggle span{display:block;width:19px;height:2px;border-radius:2px;background:#ffe7a3}
.hk-town-xp{position:absolute;z-index:4;top:calc(72px + env(safe-area-inset-top) + var(--hk-safe-top,0px));right:calc(13px + env(safe-area-inset-right) + var(--hk-safe-right,0px));display:flex;align-items:center;width:min(235px,45vw);height:9px;overflow:visible;border:1px solid #fff0ad6b;border-radius:999px;background:#10231acc;box-shadow:0 4px 14px #0003}.hk-town-xp>span{height:100%;border-radius:inherit;background:linear-gradient(90deg,#48d6a0,#d6d06a);box-shadow:0 0 10px #7dffbb88}.hk-town-xp small{position:absolute;right:0;top:13px;color:#fff5d2;font-size:9px;font-weight:900;text-shadow:0 2px 5px #07130d;white-space:nowrap}
.hk-town-menu{position:absolute;z-index:10;top:calc(66px + env(safe-area-inset-top) + var(--hk-safe-top,0px));left:calc(12px + env(safe-area-inset-left) + var(--hk-safe-left,0px));display:grid;gap:6px;width:min(285px,calc(100vw - 24px));padding:12px;border:1px solid #e8d389a3;border-radius:19px;background:linear-gradient(145deg,#102b23f5,#071812f5);box-shadow:0 20px 55px #0009;backdrop-filter:blur(15px);-webkit-backdrop-filter:blur(15px)}.hk-town-menu[hidden],.hk-town-chat[hidden],.hk-town-chat-choices[hidden]{display:none!important}.hk-town-menu-head{display:flex;align-items:center;justify-content:space-between;padding:2px 4px 7px;color:#ffedb0}.hk-town-menu-head strong{font-size:16px}.hk-town-menu-head button,.hk-town-chat header button{width:32px;height:32px;border:1px solid #ffe7a344;border-radius:10px;background:#ffffff0a;color:#fff0bd;font-size:20px;cursor:pointer}.hk-town-menu>button{min-height:42px;padding:8px 11px;border:1px solid #e4d28b37;border-radius:12px;background:linear-gradient(120deg,#ffffff0d,#ffffff05);color:#f8edcf;text-align:right;font:850 12px system-ui;cursor:pointer}.hk-town-menu>button:active,.hk-town-wallet button:active{transform:scale(.98)}.hk-town-menu>small{padding:5px 3px 1px;color:#b8d2c1;font-size:10px;line-height:1.7}
.hk-town-chat-fab{position:absolute;z-index:7;right:calc(14px + env(safe-area-inset-right) + var(--hk-safe-right,0px));bottom:calc(14px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));display:grid;place-items:center;width:52px;height:52px;border:1px solid #f0d786;border-radius:18px;background:linear-gradient(145deg,#174734,#0a2118);box-shadow:0 8px 24px #0007,0 0 18px #f2d57629;color:#fff1b7;font-size:23px;cursor:pointer}
.hk-town-chat{position:absolute;z-index:11;right:calc(14px + env(safe-area-inset-right) + var(--hk-safe-right,0px));bottom:calc(76px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));display:grid;gap:8px;width:min(335px,calc(100vw - 28px));max-height:min(62vh,460px);overflow:auto;padding:13px;border:1px solid #ead58eaa;border-radius:19px;background:linear-gradient(145deg,#102b23f5,#071812f5);box-shadow:0 18px 48px #0009;color:#fff1c6;backdrop-filter:blur(14px);-webkit-backdrop-filter:blur(14px)}.hk-town-chat header{display:flex;align-items:center;justify-content:space-between}.hk-town-chat header strong{font-size:14px}.hk-town-chat p{margin:0;color:#c9ddcd;font-size:11px;line-height:1.7}.hk-town-chat-choices{display:grid;gap:6px}.hk-town-chat-choices button{min-height:38px;padding:8px 10px;border:1px solid #ecd68d5c;border-radius:11px;background:#ffffff0a;color:#fff0c0;text-align:right;font:800 11px/1.5 system-ui;cursor:pointer}.hk-town-chat-choices button:active{background:#2e6044}.hk-town-chat>small{min-height:16px;color:#9ee0bc;font-size:10px}
.hk-town-joystick{position:absolute;z-index:6;left:calc(18px + env(safe-area-inset-left) + var(--hk-safe-left,0px));bottom:calc(18px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));display:grid;place-items:center;width:126px;height:126px;border:1px solid #e8d58a66;border-radius:50%;background:radial-gradient(circle,#83c59b42,#1439279c 68%,#061810c9);box-shadow:0 12px 34px #0006,inset 0 0 22px #a5e6ad24;touch-action:none;cursor:grab}.hk-town-joystick:active{cursor:grabbing}.hk-town-joystick-ring{position:absolute;inset:25%;border:1px solid #d7edba3a;border-radius:50%;pointer-events:none}.hk-town-joystick-knob{position:absolute;left:50%;top:50%;width:45px;height:45px;transform:translate(-50%,-50%);border:2px solid #fff0b7;border-radius:50%;background:linear-gradient(145deg,#f2de9a,#b9944a);box-shadow:0 4px 12px #0007;pointer-events:none;will-change:transform}
.hk-town-nameplate{position:absolute;left:0;top:0;display:flex;align-items:center;gap:5px;min-height:27px;max-width:148px;padding:3px 7px 3px 5px;transform:translate(-50%,-100%);border:1px solid #eed791a8;border-radius:999px;background:#0b1c16e8;color:#fff2ca;box-shadow:0 3px 12px #0007;font:850 10px system-ui;white-space:nowrap;pointer-events:auto;cursor:pointer;backdrop-filter:blur(5px)}.hk-town-nameplate img{width:19px;height:19px;flex:none;object-fit:cover;border:1px solid #f3dc8d;border-radius:50%;background:#dce5d7}.hk-town-nameplate span{overflow:hidden;text-overflow:ellipsis}.hk-town-nameplate.is-self{border-color:#ffe27c;box-shadow:0 0 14px #ffe27c55,0 3px 12px #0007}
.hk-town-toast{position:absolute;z-index:8;left:50%;top:calc(85px + env(safe-area-inset-top) + var(--hk-safe-top,0px));max-width:min(420px,calc(100vw - 24px));padding:8px 13px;transform:translate(-50%,-8px);border:1px solid #efdb98;border-radius:999px;background:#0b1c16e8;color:#fff2c9;font-size:11px;font-weight:900;text-align:center;opacity:0;pointer-events:none;transition:opacity .2s,transform .2s}.hk-town-toast.is-visible{transform:translate(-50%,0);opacity:1}
.hk-town-portal-prompt{position:absolute;z-index:7;left:50%;bottom:calc(22px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));display:grid;gap:2px;min-width:200px;padding:9px 14px;transform:translateX(-50%);border:1px solid #f2dc91;border-radius:14px;background:#0b1b15e8;box-shadow:0 8px 25px #0006;color:#fff0bd;text-align:center;pointer-events:none;backdrop-filter:blur(7px)}.hk-town-portal-prompt[hidden]{display:none!important}.hk-town-portal-prompt span{font-size:14px;font-weight:950}.hk-town-portal-prompt small{font-size:9px;color:#c7ddcb}
.hk-town-connect-state{position:absolute;z-index:4;left:50%;top:calc(13px + env(safe-area-inset-top));padding:5px 9px;transform:translateX(-50%);border:1px solid #f0d98c55;border-radius:999px;background:#09181199;color:#f2e6b5;font-size:9px;font-weight:850;white-space:nowrap;pointer-events:none}.hk-town-connect-state.is-connected{color:#bfffd4}.hk-town-connect-state.is-error{color:#ffd0bd;border-color:#ffb19b77}
@media(max-width:700px){.hk-town-topbar{top:calc(8px + env(safe-area-inset-top) + var(--hk-safe-top,0px));right:calc(8px + env(safe-area-inset-right) + var(--hk-safe-right,0px));left:calc(8px + env(safe-area-inset-left) + var(--hk-safe-left,0px));gap:6px}.hk-town-player-chip{gap:6px;max-width:33vw;padding:5px 7px}.hk-town-player-chip img{width:32px;height:32px}.hk-town-player-chip strong{font-size:11px}.hk-town-player-chip small{font-size:8px}.hk-town-wallet{gap:3px;padding:4px}.hk-town-wallet button{min-height:32px;gap:3px;padding:0 6px;font-size:10px}.hk-town-wallet button>span{font-size:12px}.hk-town-wallet button i{width:14px;height:14px;font-size:11px}.hk-town-score{display:none}.hk-town-menu-toggle{width:39px;height:39px}.hk-town-xp{top:calc(58px + env(safe-area-inset-top) + var(--hk-safe-top,0px));right:calc(8px + env(safe-area-inset-right) + var(--hk-safe-right,0px));width:min(165px,42vw);height:7px}.hk-town-xp small{top:10px;font-size:8px}.hk-town-joystick{left:calc(12px + env(safe-area-inset-left) + var(--hk-safe-left,0px));bottom:calc(12px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));width:112px;height:112px}.hk-town-joystick-knob{width:41px;height:41px}.hk-town-chat-fab{right:calc(12px + env(safe-area-inset-right) + var(--hk-safe-right,0px));bottom:calc(12px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));width:47px;height:47px}.hk-town-portal-prompt{bottom:calc(14px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));min-width:180px;padding:7px 10px}.hk-town-connect-state{top:auto;bottom:calc(17px + env(safe-area-inset-bottom));left:50%;font-size:8px}.hk-town-toast{top:calc(94px + env(safe-area-inset-top))}}
@media(orientation:landscape) and (max-height:520px){.hk-town-topbar{top:calc(5px + env(safe-area-inset-top));min-height:42px}.hk-town-player-chip{padding:4px 8px}.hk-town-player-chip img{width:29px;height:29px}.hk-town-wallet{padding:3px}.hk-town-wallet button{min-height:29px}.hk-town-menu-toggle{width:36px;height:36px}.hk-town-xp{top:calc(51px + env(safe-area-inset-top));width:185px}.hk-town-joystick{width:96px;height:96px;left:calc(10px + env(safe-area-inset-left));bottom:calc(9px + env(safe-area-inset-bottom))}.hk-town-joystick-knob{width:36px;height:36px}.hk-town-chat-fab{width:41px;height:41px;right:calc(10px + env(safe-area-inset-right));bottom:calc(9px + env(safe-area-inset-bottom))}.hk-town-portal-prompt{bottom:calc(8px + env(safe-area-inset-bottom))}}
@media(prefers-reduced-motion:reduce){.hk-town-toast,.hk-town-menu,.hk-town-chat{scroll-behavior:auto!important;transition-duration:.01ms!important}}

/* Phones use the light, draggable game carousel and never initialize WebGL. */
#hk-town-world.hk-town-mobile-mode{background:radial-gradient(ellipse at 50% 38%,#1d6045 0,#103528 38%,#071811 100%);touch-action:pan-y}
#hk-town-world.hk-town-mobile-mode #hk-town-canvas,
#hk-town-world.hk-town-mobile-mode #hk-town-world-labels,
#hk-town-world.hk-town-mobile-mode .hk-town-joystick,
#hk-town-world.hk-town-mobile-mode .hk-town-fire-button,
#hk-town-world.hk-town-mobile-mode .hk-town-sprint-button,
#hk-town-world.hk-town-mobile-mode .hk-town-keyboard-hint,
#hk-town-world.hk-town-mobile-mode .hk-town-portal-prompt,
#hk-town-world.hk-town-mobile-mode .hk-town-portal-countdown,
#hk-town-world.hk-town-mobile-mode .hk-town-store,
#hk-town-world.hk-town-mobile-mode .hk-town-build-menu,
#hk-town-world.hk-town-mobile-mode .hk-town-collect-apples,
#hk-town-world.hk-town-mobile-mode .hk-town-plant-hint,
#hk-town-world.hk-town-mobile-mode .hk-town-range-hint,
#hk-town-world.hk-town-mobile-mode .hk-town-welcome,
#hk-town-world.hk-town-mobile-mode .hk-town-chat-fab,
#hk-town-world.hk-town-mobile-mode .hk-town-apples,
#hk-town-world.hk-town-mobile-mode .hk-town-connect-state{display:none!important}
#hk-town-world.hk-town-mobile-mode .hk-town-mobile-lobby{position:absolute;z-index:1;inset:0;display:flex;flex-direction:column;align-items:center;gap:8px;padding:calc(100px + env(safe-area-inset-top)) 16px calc(14px + env(safe-area-inset-bottom));overflow:hidden;background:radial-gradient(ellipse at 50% 38%,#1e6248aa 0,transparent 54%);touch-action:pan-y}
#hk-town-world.hk-town-mobile-mode .hk-town-mobile-lobby[hidden]{display:none!important}
.hk-town-mobile-heading{display:grid;gap:3px;text-align:center;line-height:1.45;flex:none}
.hk-town-mobile-heading span{color:#ffe08a;font-size:10px;font-weight:950;letter-spacing:.12em}
.hk-town-mobile-heading b{color:#fff5cf;font-size:clamp(19px,5vw,27px);font-weight:1000;text-shadow:0 3px 14px #0008}
.hk-town-mobile-heading small{color:#c4e3d0;font-size:11px}
.hk-town-mobile-stage{position:relative;flex:1;min-height:250px;width:100%;max-height:53vh;--hk-carousel-depth:min(135vw,530px);perspective:1300px;perspective-origin:50% 48%;touch-action:pan-y;overscroll-behavior:contain;user-select:none;-webkit-user-select:none}
.hk-town-mobile-ring{position:absolute;left:50%;top:48%;width:1px;height:1px;transform-style:preserve-3d;will-change:transform;transition:none}
.hk-town-mobile-card{position:absolute;left:0;top:0;display:grid;grid-template-rows:1fr auto auto;gap:0;width:clamp(148px,52vw,210px);height:clamp(250px,38vh,330px);padding:0;overflow:hidden;transform:translate(-50%,-50%) rotateY(var(--card-angle)) translateZ(var(--hk-carousel-depth,530px));transform-style:flat;border:1px solid color-mix(in srgb,var(--card-color),#fff 38%);border-radius:19px;background:linear-gradient(155deg,#15382bdc,#071b14f2);box-shadow:0 16px 34px #0007,0 0 20px color-mix(in srgb,var(--card-color),transparent 65%),inset 0 1px #ffffff42;color:#fff2cb;text-align:right;text-decoration:none;opacity:calc(1 - min(var(--card-distance,0)*.16,.56));filter:brightness(calc(1 - min(var(--card-distance,0)*.2,.65)));transition:opacity .2s,filter .2s,border-color .2s,box-shadow .2s;backface-visibility:hidden;-webkit-backface-visibility:hidden;cursor:pointer}
.hk-town-mobile-card.is-selected{border-width:2px;box-shadow:0 22px 50px #0009,0 0 28px color-mix(in srgb,var(--card-color),transparent 35%),inset 0 1px #ffffff66}
.hk-town-mobile-card img{display:block;width:100%;height:100%;min-height:0;object-fit:cover;border-radius:18px 18px 0 0;clip-path:inset(0 round 18px 18px 0 0);background:#13291f;pointer-events:none}
.hk-town-mobile-card-label{padding:12px 14px 2px;color:#fff1bf;font-size:15px;font-weight:1000;line-height:1.4}
.hk-town-mobile-card i{padding:0 14px 12px;color:#a9dec0;font-size:10px;font-style:normal;font-weight:800}
.hk-town-mobile-selected{display:grid;gap:10px;width:min(100%,500px);flex:none;padding:13px 14px;border:1px solid #e5d18880;border-radius:20px;background:linear-gradient(135deg,#0d2c21eF,#081a14f4);box-shadow:0 12px 32px #0005,inset 0 1px #ffffff19;backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px)}
.hk-town-mobile-quick-actions{display:flex;justify-content:center;gap:8px;flex-wrap:wrap}.hk-town-mobile-quick-actions button,.hk-town-daily-icon{display:inline-flex;align-items:center;justify-content:center;gap:6px;min-height:34px;padding:6px 11px;border:1px solid #f0d67f99;border-radius:999px;background:linear-gradient(135deg,#184638,#092018);box-shadow:0 7px 20px #0006,0 0 15px #f0d67f22;color:#fff0b9;font:900 11px system-ui;cursor:pointer;touch-action:manipulation}.hk-town-mobile-quick-actions button:hover,.hk-town-daily-icon:hover{filter:brightness(1.16);transform:translateY(-1px)}.hk-town-daily-icon{min-width:34px;min-height:32px;padding:4px 8px;font-size:16px}.hk-town-daily-icon.offer{border-color:#58d9cb99}
.hk-town-mobile-selected>div:first-child{min-width:0;text-align:center}
.hk-town-mobile-selected small{color:#b9d7bf;font-size:10px;font-weight:900}
.hk-town-mobile-selected h1{margin:3px 0;color:#ffecae;font-size:19px;line-height:1.35}
.hk-town-mobile-selected p{margin:0;color:#d5e6d9;font-size:11px;line-height:1.55}
.hk-town-mobile-actions{display:grid;grid-template-columns:42px 1fr 42px;gap:8px;align-items:center}
.hk-town-mobile-actions button{height:42px;border:1px solid #ebd78e88;border-radius:13px;background:#ffffff0b;color:#ffe7a0;font:900 22px system-ui;cursor:pointer;touch-action:manipulation}
.hk-town-mobile-actions .hk-town-mobile-launch{display:flex;justify-content:center;align-items:center;gap:10px;background:linear-gradient(110deg,#d9bb5a,#f2d985 52%,#c2a64c);color:#13251a;font-size:14px;box-shadow:0 5px 18px #d1b85c35}
.hk-town-mobile-launch span{font-size:18px}
#hk-town-world.hk-town-mobile-mode .hk-town-menu{z-index:30;top:calc(61px + env(safe-area-inset-top));left:calc(8px + env(safe-area-inset-left));max-height:calc(100dvh - 78px - env(safe-area-inset-top));}
#hk-town-world.hk-town-mobile-mode .hk-town-lounge{z-index:31;right:8px;bottom:calc(8px + env(safe-area-inset-bottom));width:min(420px,calc(100vw - 16px));max-height:min(76dvh,660px)}
#hk-town-world.hk-town-mobile-mode .hk-town-chat{z-index:32}
#hk-town-world.hk-town-mobile-mode .hk-town-topbar{z-index:20}
#hk-town-world.hk-town-mobile-mode .hk-town-toast{z-index:40}
@media(max-width:700px){#hk-town-world.hk-town-mobile-mode .hk-town-player-chip{max-width:29vw}.hk-town-mobile-stage{--hk-carousel-depth:min(135vw,530px)}.hk-town-mobile-card{width:min(52vw,210px);height:clamp(235px,35vh,310px)}}
@media(max-width:380px){#hk-town-world.hk-town-mobile-mode .hk-town-wallet button{padding-inline:4px}.hk-town-mobile-stage{--hk-carousel-depth:min(145vw,530px)}.hk-town-mobile-card{width:min(51vw,194px);height:250px}}
@media(orientation:landscape) and (max-height:520px){#hk-town-world.hk-town-mobile-mode .hk-town-mobile-lobby{gap:4px;padding-top:calc(54px + env(safe-area-inset-top));padding-bottom:calc(6px + env(safe-area-inset-bottom))}.hk-town-mobile-heading{gap:0}.hk-town-mobile-heading b{font-size:17px}.hk-town-mobile-heading small{font-size:9px}.hk-town-mobile-stage{min-height:135px;max-height:44vh;--hk-carousel-depth:min(110vw,550px)}.hk-town-mobile-card{width:clamp(135px,25vw,205px);height:clamp(150px,42vh,205px);border-radius:17px}.hk-town-mobile-card img{border-radius:16px 16px 0 0;clip-path:inset(0 round 16px 16px 0 0)}.hk-town-mobile-card-label{padding:7px 9px 0;font-size:12px}.hk-town-mobile-card i{padding:0 9px 7px;font-size:9px}.hk-town-mobile-selected{grid-template-columns:1fr auto;align-items:center;gap:5px;padding:7px 10px;border-radius:14px}.hk-town-mobile-selected h1{margin:1px 0;font-size:15px}.hk-town-mobile-selected p{font-size:9px}.hk-town-mobile-actions{grid-template-columns:32px minmax(120px,180px) 32px;gap:5px}.hk-town-mobile-actions button{height:33px;font-size:18px}.hk-town-mobile-actions .hk-town-mobile-launch{font-size:11px}}

/* CSS-only phone fallback: keep the world and its game controls out even when a
   messenger/WebView delays the inline bootstrap or reports a desktop viewport. */
@media(max-width:600px){
    #hk-town-world{background:radial-gradient(ellipse at 50% 35%,#205b43 0,#103528 43%,#071811 100%)!important;touch-action:pan-y!important}
    #hk-town-world #hk-town-canvas,
    #hk-town-world #hk-town-world-labels,
    #hk-town-world .hk-town-joystick,
    #hk-town-world .hk-town-sprint-button,
    #hk-town-world .hk-town-fire-button,
    #hk-town-world .hk-town-chat-fab,
    #hk-town-world .hk-town-connect-state,
    #hk-town-world .hk-town-portal-prompt,
    #hk-town-world .hk-town-portal-countdown,
    #hk-town-world .hk-town-store,
    #hk-town-world .hk-town-build-menu,
    #hk-town-world .hk-town-collect-apples,
    #hk-town-world .hk-town-plant-hint,
    #hk-town-world .hk-town-range-hint,
    #hk-town-world .hk-town-welcome,
    #hk-town-world .hk-town-chat,
    #hk-town-world .hk-town-toast,
    #hk-town-world .hk-town-keyboard-help,
    #hk-town-world .hk-town-apples{display:none!important}
    #hk-town-world .hk-town-mobile-lobby,
    #hk-town-world .hk-town-mobile-lobby[hidden]{position:absolute;z-index:15;inset:0;display:flex!important;flex-direction:column;align-items:center;gap:8px;padding:calc(100px + env(safe-area-inset-top)) 16px calc(14px + env(safe-area-inset-bottom));overflow:hidden;background:radial-gradient(ellipse at 50% 38%,#1e6248aa 0,transparent 54%);touch-action:pan-y}
    #hk-town-world .hk-town-topbar{z-index:20}
    #hk-town-world .hk-town-xp{z-index:19}
}

/* PUBG-style sprint latch: the icon appears only while the movement stick is pushed forward. */
.hk-town-sprint-button{position:absolute;z-index:7;left:calc(54px + env(safe-area-inset-left) + var(--hk-safe-left,0px));bottom:calc(158px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));display:grid;place-items:center;width:54px;height:54px;padding:0;border:1px solid #ffe6a8;border-radius:50%;background:radial-gradient(circle at 34% 25%,#45634d,#10251bd9 72%);box-shadow:0 5px 17px #0008,inset 0 1px #fff5,0 0 12px #f3d67820;color:#fff3c5;touch-action:none;pointer-events:none;user-select:none;-webkit-user-select:none;opacity:.96;transition:transform .12s,filter .12s,box-shadow .12s}
.hk-town-sprint-button[hidden]{display:none!important}.hk-town-sprint-button.is-active{transform:scale(.91);filter:brightness(1.22);box-shadow:0 2px 8px #0008,inset 0 0 0 3px #ffe7a344,0 0 15px #ffe28a55}
.hk-town-sprint-icon{width:30px;height:30px;fill:#fff0bf;stroke:#fff0bf;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
.hk-town-keyboard-help{display:none}
@media(min-width:900px) and (hover:hover) and (pointer:fine){.hk-town-keyboard-help{position:absolute;z-index:4;right:calc(18px + env(safe-area-inset-right) + var(--hk-safe-right,0px));bottom:calc(18px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));display:flex;align-items:center;gap:9px;padding:6px 9px;border:1px solid #f4e2ad47;border-radius:10px;background:#0b1c16a8;box-shadow:0 3px 12px #0003;color:#f6ebc9;font:700 9px/1.2 system-ui;opacity:.78;pointer-events:none;backdrop-filter:blur(5px)}.hk-town-keyboard-help span{display:inline-flex;align-items:center;gap:4px;white-space:nowrap}.hk-town-keyboard-help kbd{padding:2px 4px;border:1px solid #eee1b955;border-radius:4px;background:#fff1;color:#fff1c9;font:800 8px system-ui}}
@media(max-width:700px){.hk-town-sprint-button{left:calc(47px + env(safe-area-inset-left) + var(--hk-safe-left,0px));bottom:calc(143px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));width:48px;height:48px}.hk-town-sprint-icon{width:27px;height:27px}}
@media(orientation:landscape) and (max-height:520px){.hk-town-sprint-button{left:calc(39px + env(safe-area-inset-left));bottom:calc(122px + env(safe-area-inset-bottom));width:43px;height:43px}.hk-town-sprint-icon{width:24px;height:24px}}
#hk-town-portal-prompt{pointer-events:auto}
.hk-town-action-button{position:absolute;z-index:7;right:calc(20px + env(safe-area-inset-right) + var(--hk-safe-right,0px));display:grid;place-items:center;gap:2px;width:62px;height:62px;padding:5px;border:1px solid #f7e5ac;border-radius:50%;background:radial-gradient(circle at 31% 24%,#3c5140,#071811 74%);box-shadow:0 8px 22px #0008,inset 0 1px #ffffff48;color:#fff0b5;font-size:22px;font-weight:1000;touch-action:none;user-select:none;-webkit-user-select:none;cursor:pointer}.hk-town-action-button small{font:900 9px/1 system-ui}.hk-town-action-button:active,.hk-town-action-button.is-active{transform:scale(.94);filter:brightness(1.2)}.hk-town-fire-button{bottom:calc(78px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));border-color:#f3db91;background:radial-gradient(circle at 30% 25%,#f5dfa0,#c19a45 72%,#70501e);color:#10261b}.hk-town-cannonball-icon{display:block;width:24px;height:24px;border:1px solid #d9d1b2;border-radius:50%;background:radial-gradient(circle at 32% 26%,#e9e6dc 0 7%,#8c8981 24%,#333431 68%,#171916 100%);box-shadow:inset -3px -4px 6px #050705aa,0 2px 4px #0008}
@media(max-width:700px){.hk-town-action-button{right:calc(12px + env(safe-area-inset-right) + var(--hk-safe-right,0px));width:56px;height:56px}.hk-town-fire-button{bottom:calc(69px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px))}.hk-town-cannonball-icon{width:22px;height:22px}}
@media(orientation:landscape) and (max-height:520px){.hk-town-action-button{right:calc(10px + env(safe-area-inset-right));width:49px;height:49px;font-size:18px}.hk-town-fire-button{bottom:calc(56px + env(safe-area-inset-bottom))}.hk-town-cannonball-icon{width:19px;height:19px}}
.hk-town-speech-bubble{position:absolute;left:50%;bottom:calc(100% + 7px);display:block;width:max-content;max-width:min(210px,65vw);padding:6px 9px;transform:translateX(-50%);border:1px solid #f0d88b;border-radius:12px;background:#10251cf2;box-shadow:0 5px 14px #0007;color:#fff1c6;font:800 10px/1.55 system-ui;text-align:center;white-space:normal;z-index:2}
.hk-town-local-speech-anchor{position:absolute;left:0;top:0;display:none;width:0;height:0;transform:translate(-50%,-100%);pointer-events:none}
.hk-town-menu{max-height:calc(var(--hk-viewport-height,100dvh) - 88px);overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#bca560 #10231d}
.hk-town-menu-section{padding:7px 5px 2px;border-top:1px solid #e4d28b35;color:#d9c987;font-size:10px;font-weight:950;letter-spacing:.04em}
.hk-town-player-chip{max-width:min(330px,48vw)}
.hk-town-lounge-open{display:grid;place-items:center;gap:0;flex:none;width:38px;height:38px;padding:2px;border:1px solid #f0d986;border-radius:13px;background:linear-gradient(145deg,#dfc56d,#a88434);box-shadow:0 3px 11px #0005,inset 0 1px #fff8;color:#14291d;cursor:pointer}
.hk-town-lounge-open span{font-size:17px;line-height:1}.hk-town-lounge-open small{font:900 8px/1 system-ui}.hk-town-lounge-open:active{transform:scale(.94);filter:brightness(1.1)}
.hk-town-lounge{position:absolute;z-index:16;top:calc(80px + env(safe-area-inset-top) + var(--hk-safe-top,0px));right:calc(12px + env(safe-area-inset-right) + var(--hk-safe-right,0px));display:grid;grid-template-rows:auto minmax(0,1fr) auto;gap:10px;width:min(430px,calc(100vw - 24px));max-height:min(70vh,650px);max-height:min(70dvh,650px);overflow:hidden;padding:13px;border:1px solid #e7d18a;border-radius:20px;background:linear-gradient(145deg,#133b2df7,#071812f7);box-shadow:0 20px 56px #000b,inset 0 1px #ffffff25;color:#fff1c5;backdrop-filter:blur(15px);-webkit-backdrop-filter:blur(15px)}
.hk-town-lounge[hidden],.hk-town-lounge-feed[hidden],.hk-town-lounge-compose[hidden],#hk-town-lounge-unlock[hidden]{display:none!important}
.hk-town-lounge>header{display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;gap:7px;padding-bottom:9px;border-bottom:1px solid #ffffff20}.hk-town-lounge>header>div{display:grid;gap:3px;min-width:0}.hk-town-lounge>header strong{color:#ffe49b;font-size:14px}.hk-town-lounge>header small{color:#c4d9c9;font-size:10px;line-height:1.45}.hk-town-lounge>header button{min-height:36px;padding:0 9px;border:1px solid #e8cf7b77;border-radius:11px;background:linear-gradient(135deg,#f2dc91,#c3a14d);color:#17261b;font:900 10px system-ui;cursor:pointer}.hk-town-lounge>header #hk-town-lounge-close{width:34px;padding:0;background:#ffffff0b;color:#ffedb5;font-size:21px}
.hk-town-lounge-gate{display:grid;align-content:center;justify-items:center;gap:8px;min-height:110px;padding:16px;border:1px solid #ffffff17;border-radius:14px;background:#ffffff08;text-align:center;line-height:1.8}.hk-town-lounge-gate b{color:#ffe49b;font-size:15px}.hk-town-lounge-gate span{color:#d1dfd2;font-size:12px}.hk-town-lounge-feed{display:flex;flex-direction:column;gap:8px;min-height:120px;overflow:auto;padding:4px 2px;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#b69a54 #10271c}.hk-town-lounge-message{display:grid;grid-template-columns:34px minmax(0,1fr);gap:8px;align-items:start;max-width:96%;padding:8px 10px;border:1px solid #ffffff1b;border-radius:14px;background:#ffffff0a}.hk-town-lounge-message.is-own{align-self:flex-start;border-color:#f0d57b44;background:#d5c66d12}.hk-town-lounge-message img{width:32px;height:32px;border:1px solid #f0d57b88;border-radius:50%;object-fit:cover}.hk-town-lounge-message b{display:block;margin-bottom:3px;color:#ffe69c;font-size:11px}.hk-town-lounge-message p{margin:0;overflow-wrap:anywhere;white-space:pre-wrap;font-size:12px;line-height:1.6}.hk-town-lounge-message a{display:inline-block;margin-top:4px;color:#9ce7c2;font-weight:900}
.hk-town-lounge-compose{position:relative;display:flex;align-items:flex-end;gap:8px;padding-top:9px;border-top:1px solid #ffffff20}.hk-town-lounge-compose textarea{flex:1;min-width:0;min-height:44px;max-height:100px;resize:none;padding:10px 12px;border:1px solid #d8d9a755;border-radius:13px;background:#071710;color:#fff4d2;font:inherit;font-size:14px;line-height:1.5;outline:none}.hk-town-lounge-compose textarea:focus{border-color:#edda91}.hk-town-lounge-compose>button{flex:none;width:48px;height:44px;border:1px solid #f2d77c;border-radius:13px;background:linear-gradient(125deg,#f5df97,#c4a34f);color:#15251a;font-size:19px;font-weight:1000}.hk-town-lounge-compose>button:disabled{opacity:.5}.hk-town-lounge-compose small{position:absolute;bottom:calc(100% + 3px);left:3px;color:#b7cfad;font-size:9px;pointer-events:none}
@media(max-width:700px){.hk-town-player-chip{max-width:min(330px,45vw)}.hk-town-lounge-open{width:34px;height:34px;border-radius:12px}.hk-town-lounge{top:calc(73px + env(safe-area-inset-top) + var(--hk-safe-top,0px));right:calc(8px + env(safe-area-inset-right) + var(--hk-safe-right,0px));width:min(410px,calc(100vw - 16px));max-height:min(73vh,600px);max-height:min(73dvh,600px);padding:10px;border-radius:17px}.hk-town-lounge>header strong{font-size:13px}.hk-town-lounge>header button{min-height:34px;padding-inline:7px;font-size:9px}.hk-town-lounge-compose textarea{font-size:16px}.hk-town-lounge-compose small{display:none}}
@media(orientation:landscape) and (max-height:520px){.hk-town-lounge{top:calc(54px + env(safe-area-inset-top));max-height:calc(100dvh - 66px);width:min(390px,calc(100vw - 20px));padding:9px}.hk-town-lounge-feed{min-height:70px}.hk-town-lounge-gate{min-height:70px;padding:9px}}
.hk-town-lounge-compose textarea{user-select:text;-webkit-user-select:text;touch-action:manipulation}

.hk-town-apples{display:flex;align-items:center;gap:4px;min-height:34px;padding:0 9px;border:1px solid #e7d18a55;border-radius:11px;background:#ffffff0a;color:#ffedb1;font-size:12px;font-weight:900;white-space:nowrap}.hk-town-apples b{font-size:11px}
.hk-town-store{position:absolute;z-index:12;left:50%;top:50%;display:grid;gap:11px;width:min(520px,calc(100vw - 24px));max-height:calc(var(--hk-viewport-height,100dvh) - 112px);overflow:auto;padding:15px;transform:translate(-50%,-50%);border:1px solid #e9d18a;border-radius:22px;background:linear-gradient(145deg,#163e2ff5,#081a14f7);box-shadow:0 22px 70px #000b,inset 0 1px #ffffff2b;color:#fff0c4;backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px)}.hk-town-store[hidden],.hk-town-collect-apples[hidden],.hk-town-plant-hint[hidden],.hk-town-range-hint[hidden],.hk-town-welcome[hidden]{display:none!important}.hk-town-store>header{display:flex;align-items:center;justify-content:space-between;gap:10px;padding-bottom:10px;border-bottom:1px solid #f3df9a35}.hk-town-store>header div{display:grid;gap:3px}.hk-town-store>header strong{color:#ffe59e;font-size:18px;font-weight:1000}.hk-town-store>header small,.hk-town-store footer>span{color:#c6dccb;font-size:10px;line-height:1.6}.hk-town-store>header button,.hk-town-welcome button{display:grid;place-items:center;width:36px;height:36px;border:1px solid #f0d88c77;border-radius:12px;background:#ffffff0c;color:#ffefbd;font-size:22px;cursor:pointer}.hk-town-store-items{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px}.hk-town-store-items button{display:grid;justify-items:center;gap:5px;min-height:116px;padding:11px 7px;border:1px solid #dac4776e;border-radius:16px;background:linear-gradient(150deg,#ffffff12,#ffffff05);color:#fff0c4;text-align:center;cursor:pointer;transition:transform .15s,border-color .15s,background .15s}.hk-town-store-items button:hover{transform:translateY(-2px);border-color:#ffe28d;background:#f9df8c14}.hk-town-store-items button>span{font-size:27px}.hk-town-store-items button>b{font-size:12px}.hk-town-store-items button>small{color:#c1d6c4;font-size:9px;line-height:1.45}.hk-town-store footer{display:flex;align-items:center;justify-content:space-between;gap:8px;padding-top:9px;border-top:1px solid #f3df9a35}.hk-town-store footer button{min-height:37px;padding:0 11px;border:1px solid #f3d987;border-radius:12px;background:linear-gradient(135deg,#f4df9b,#cba84f);color:#17281d;font:950 11px system-ui;cursor:pointer}.hk-town-store button:disabled{opacity:.55;cursor:wait}
.hk-town-collect-apples{position:absolute;z-index:7;left:50%;bottom:calc(86px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));display:flex;align-items:center;gap:8px;padding:11px 15px;transform:translateX(-50%);border:1px solid #f2d886;border-radius:15px;background:linear-gradient(135deg,#24583b,#0d2c1f);box-shadow:0 8px 25px #0008;color:#fff0bc;font:950 12px system-ui;cursor:pointer}.hk-town-collect-apples small{display:grid;place-items:center;min-width:25px;height:25px;border-radius:50%;background:#f1d77b;color:#16291e}.hk-town-plant-hint{position:absolute;z-index:8;left:50%;top:calc(85px + env(safe-area-inset-top));max-width:calc(100vw - 24px);padding:8px 12px;transform:translateX(-50%);border:1px solid #b8edbe;border-radius:999px;background:#0a2119e8;color:#d9f6df;font-size:11px;font-weight:900;text-align:center;pointer-events:none}.hk-town-range-hint{position:absolute;z-index:5;left:50%;top:calc(89px + env(safe-area-inset-top));display:grid;gap:3px;max-width:min(410px,calc(100vw - 24px));padding:9px 13px;transform:translateX(-50%);border:1px solid #ffe19a;border-radius:14px;background:#0b1b16dc;box-shadow:0 7px 22px #0006;color:#fff1c6;text-align:center;pointer-events:none}.hk-town-range-hint strong{font-size:12px}.hk-town-range-hint span{color:#d4e4cf;font-size:9px;line-height:1.5}
.hk-town-welcome{position:absolute;z-index:20;left:50%;top:50%;display:grid;grid-template-columns:minmax(150px,.78fr) minmax(0,1.5fr);align-items:center;gap:17px;width:min(660px,calc(100vw - 24px));padding:18px;transform:translate(-50%,-50%);border:1px solid #f2dc91;border-radius:23px;background:linear-gradient(125deg,#092019f5,#174632f4 52%,#0b2019f7);box-shadow:0 24px 80px #000c,inset 0 1px #ffffff30;color:#fff0c3;backdrop-filter:blur(16px);-webkit-backdrop-filter:blur(16px)}.hk-town-welcome-art{position:relative;display:grid;place-items:center;min-height:155px;overflow:hidden;border:1px solid #f0d88966;border-radius:17px;background:radial-gradient(ellipse at 50% 45%,#41ae8647,transparent 69%),linear-gradient(145deg,#173c2b,#091a15)}.hk-town-welcome-art>span{font-size:68px;filter:drop-shadow(0 7px 10px #0008)}.hk-town-welcome-art i{position:absolute;top:18px;right:25px;color:#ffe78d;font-style:normal;font-size:22px;animation:hk-town-welcome-glow 2s ease-in-out infinite alternate}.hk-town-welcome-art>b{position:absolute;bottom:12px;letter-spacing:.28em;color:#ffe5a0;font:1000 12px system-ui;text-shadow:0 2px 9px #000}.hk-town-welcome>div:last-child{display:grid;gap:6px}.hk-town-welcome>div:last-child>small{color:#8fe5ba;font-size:10px;font-weight:950;letter-spacing:.08em}.hk-town-welcome h2{margin:0;color:#ffe5a0;font-size:clamp(20px,4vw,29px)}.hk-town-welcome p{margin:0 0 5px;color:#d1e3d3;font-size:12px;line-height:1.8}.hk-town-welcome button{display:flex;align-items:center;justify-content:center;gap:9px;width:max-content;min-width:128px;padding:0 15px;background:linear-gradient(130deg,#f2df9c,#c7a251);color:#17271b;font:950 12px system-ui}.hk-town-welcome button span{font-size:19px}
@keyframes hk-town-welcome-glow{from{transform:scale(.92);opacity:.65}to{transform:scale(1.14);opacity:1}}
@media(max-width:700px){.hk-town-apples{min-height:31px;padding:0 6px;font-size:10px}.hk-town-store{gap:8px;padding:11px;border-radius:18px}.hk-town-store>header strong{font-size:16px}.hk-town-store-items{grid-template-columns:1fr;gap:6px}.hk-town-store-items button{grid-template-columns:34px minmax(0,1fr);grid-template-rows:auto auto;justify-items:start;min-height:61px;padding:8px 10px;text-align:right}.hk-town-store-items button>span{grid-row:1/3;align-self:center;font-size:23px}.hk-town-store-items button>b{font-size:11px}.hk-town-store-items button>small{font-size:9px}.hk-town-store footer{align-items:flex-start;flex-direction:column}.hk-town-store footer button{width:100%}.hk-town-collect-apples{bottom:calc(78px + env(safe-area-inset-bottom) + var(--hk-safe-bottom,0px));font-size:11px}.hk-town-range-hint{top:auto;bottom:calc(145px + env(safe-area-inset-bottom));padding:7px 9px}.hk-town-range-hint span{font-size:8px}.hk-town-welcome{grid-template-columns:minmax(80px,.62fr) minmax(0,1.7fr);gap:10px;padding:11px;border-radius:18px}.hk-town-welcome-art{min-height:124px}.hk-town-welcome-art>span{font-size:48px}.hk-town-welcome-art>b{font-size:9px}.hk-town-welcome h2{font-size:19px}.hk-town-welcome p{font-size:10px;line-height:1.65}.hk-town-welcome button{min-height:35px;font-size:10px}}
@media(orientation:landscape) and (max-height:520px){.hk-town-store{top:52%;width:min(530px,calc(100vw - 24px));padding:9px 12px}.hk-town-store-items{grid-template-columns:repeat(3,minmax(0,1fr))}.hk-town-store-items button{grid-template-columns:1fr;grid-template-rows:auto auto auto;justify-items:center;min-height:82px;text-align:center}.hk-town-store-items button>span{grid-row:auto;font-size:20px}.hk-town-store footer{flex-direction:row;align-items:center}.hk-town-welcome{grid-template-columns:140px 1fr;width:min(600px,calc(100vw - 24px));padding:10px 14px}.hk-town-welcome-art{min-height:112px}.hk-town-welcome-art>span{font-size:46px}.hk-town-welcome p{font-size:10px;margin:0}.hk-town-welcome h2{font-size:20px}.hk-town-collect-apples{bottom:calc(64px + env(safe-area-inset-bottom))}.hk-town-range-hint{top:auto;bottom:calc(65px + env(safe-area-inset-bottom))}}
@media(prefers-reduced-motion:reduce){.hk-town-welcome-art i{animation:none}}

.hk-town-portal-countdown{position:absolute;z-index:6;left:50%;top:44%;display:grid;justify-items:center;gap:5px;min-width:144px;padding:12px 17px 10px;transform:translate(-50%,-50%);border:1px solid #f6df9b;border-radius:21px;background:radial-gradient(ellipse at 50% 15%,#28543ddb,#071711ed 76%);box-shadow:0 0 0 5px #ffe69316,0 12px 34px #0009,inset 0 1px #ffffff38;color:#fff1bf;text-align:center;pointer-events:none;backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);animation:hk-town-countdown-enter .28s cubic-bezier(.2,.8,.25,1.2)}.hk-town-portal-countdown[hidden]{display:none!important}.hk-town-portal-countdown-ring{position:relative;display:grid;place-items:center;width:94px;height:94px;border:1px solid #ffe89f;border-radius:50%;background:conic-gradient(from -90deg,#ffe38a var(--hk-countdown-progress,0%),#ffffff2b 0);box-shadow:0 0 22px #ffe58a66,0 0 42px #55e7be38,inset 0 0 12px #fff4;isolation:isolate}.hk-town-portal-countdown-ring::before{position:absolute;inset:5px;border:1px solid #ffffff52;border-radius:50%;background:radial-gradient(circle at 38% 28%,#2c6649,#0a2119 72%);box-shadow:inset 0 0 19px #0008;content:""}.hk-town-portal-countdown-ring span{position:relative;z-index:1;color:#fff1b5;font:1000 51px/1 system-ui,-apple-system,"Segoe UI",sans-serif;text-shadow:0 2px 2px #70491a,0 0 17px #ffe68caa}.hk-town-portal-countdown>b{font-size:13px;font-weight:950;text-shadow:0 2px 8px #000}.hk-town-portal-countdown>small{color:#c8e4cf;font-size:10px;font-weight:800}.hk-town-portal-countdown-ring.is-tick{animation:hk-town-countdown-tick .32s ease-out}
@keyframes hk-town-countdown-enter{from{opacity:0;transform:translate(-50%,-45%) scale(.78)}to{opacity:1;transform:translate(-50%,-50%) scale(1)}}@keyframes hk-town-countdown-tick{0%{transform:scale(.86);filter:brightness(1.5)}100%{transform:scale(1);filter:brightness(1)}}
@media(max-width:700px){.hk-town-portal-countdown{top:43%;min-width:126px;padding:9px 13px;border-radius:18px}.hk-town-portal-countdown-ring{width:82px;height:82px}.hk-town-portal-countdown-ring span{font-size:44px}.hk-town-portal-countdown>b{font-size:12px}.hk-town-portal-countdown>small{font-size:9px}}
@media(orientation:landscape) and (max-height:520px){.hk-town-portal-countdown{top:44%;gap:3px;min-width:105px;padding:6px 10px;border-radius:15px}.hk-town-portal-countdown-ring{width:64px;height:64px}.hk-town-portal-countdown-ring::before{inset:4px}.hk-town-portal-countdown-ring span{font-size:35px}.hk-town-portal-countdown>b{font-size:10px}.hk-town-portal-countdown>small{font-size:8px}}
@media(prefers-reduced-motion:reduce){.hk-town-portal-countdown,.hk-town-portal-countdown-ring.is-tick{animation:none!important}}

/* Island fruit market: selling only. */
#hk-town-store{width:min(420px,calc(100vw - 24px));gap:14px}
#hk-town-store[hidden],#hk-town-build-menu[hidden]{display:none!important}
.hk-town-fruit-counter{display:grid;grid-template-columns:58px minmax(0,1fr) auto;align-items:center;gap:12px;padding:13px;border:1px solid #f0d47c55;border-radius:18px;background:linear-gradient(135deg,#ffffff12,#0a2018b8);box-shadow:inset 0 1px #ffffff1a,0 9px 20px #0003}
.hk-town-fruit-art{display:grid;place-items:center;width:54px;height:54px;border:1px solid #f7d778;border-radius:17px;background:radial-gradient(circle at 35% 25%,#fff3bd,#d89136 45%,#6a2a1b 100%);font-size:30px;box-shadow:0 5px 14px #0005,inset 0 2px #fff8}
.hk-town-fruit-counter>div{display:grid;gap:5px}.hk-town-fruit-counter>div b{color:#fff0bf;font-size:13px}.hk-town-fruit-counter>div small{color:#bad4c0;font-size:10px;line-height:1.5}
.hk-town-fruit-counter>strong{display:grid;justify-items:center;min-width:48px;padding:5px 8px;border:1px solid #e9ce745e;border-radius:13px;background:#071c15aa;color:#ffe49a;font-size:19px}.hk-town-fruit-counter>strong small{color:#c0d6c5;font-size:9px}
#hk-town-store footer{display:grid;grid-template-columns:minmax(0,1fr) auto;align-items:center;gap:10px}
#hk-town-store footer>span{font-size:10px;line-height:1.6}
#hk-town-sell-apples{min-height:44px;padding:0 16px;border:1px solid #ffe18b;border-radius:14px;background:linear-gradient(145deg,#f6d878,#b57828 68%,#70451c);box-shadow:inset 0 1px #fff9,0 5px 13px #0005;color:#21190c;font:950 12px system-ui;cursor:pointer}
#hk-town-sell-apples:disabled{opacity:.55;filter:saturate(.6);cursor:not-allowed}
.hk-town-build-menu{position:fixed;z-index:42;display:grid;gap:10px;width:min(340px,calc(100vw - 20px));max-height:calc(100dvh - 20px);overflow:auto;padding:13px;border:1px solid #e8ce78;border-radius:20px;background:linear-gradient(150deg,#174735f5,#071a14f7 78%);box-shadow:0 18px 54px #000a,inset 0 1px #fff3;color:#ffedb9;backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);touch-action:manipulation}
.hk-town-build-menu>header{display:flex;align-items:center;justify-content:space-between;gap:8px;padding-bottom:8px;border-bottom:1px solid #ffe9ad30}.hk-town-build-menu>header>div{display:grid;gap:3px}.hk-town-build-menu>header strong{font-size:15px;font-weight:1000;color:#ffe39a}.hk-town-build-menu>header small{font-size:9px;color:#c5ddca}
.hk-town-build-menu>header button{width:34px;height:34px;border:1px solid #f4d88870;border-radius:11px;background:#ffffff10;color:#fff0bf;font-size:20px;cursor:pointer}
.hk-town-build-options{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}
.hk-town-build-options button{display:grid;justify-items:center;align-content:center;gap:5px;min-width:0;min-height:91px;padding:9px 5px;border:1px solid #d7c8798c;border-radius:15px;background:linear-gradient(150deg,#285941,#102a20 76%);box-shadow:inset 0 1px #fff3,0 5px 12px #0005;color:#fff0bc;font:900 10px system-ui;cursor:pointer;transition:transform .16s ease,filter .16s ease,border-color .16s ease}
.hk-town-build-options button:hover,.hk-town-build-options button:focus-visible{transform:translateY(-2px);border-color:#ffe58a;filter:brightness(1.15);outline:none}.hk-town-build-options button:active{transform:translateY(1px)}
.hk-town-build-options button>span{display:grid;place-items:center;width:36px;height:36px;border:1px solid #ffe08a9c;border-radius:12px;background:radial-gradient(circle at 35% 25%,#fff2b4,#be8b32 70%,#543817);box-shadow:inset 0 1px #fff8,0 3px 8px #0005;font-size:20px}
.hk-town-build-options button>b{font-size:9px;line-height:1.35;text-align:center}.hk-town-build-options button>small{padding:3px 8px;border:1px solid #f5d98270;border-radius:999px;background:#071b14;color:#ffe49a;font-size:9px;font-weight:1000}
.hk-town-build-status{display:block;min-height:28px;padding:7px 9px;border-radius:11px;background:#061a14a8;color:#c3d9c8;font-size:9px;line-height:1.55;text-align:center}
@media(max-width:700px){#hk-town-store{gap:10px;padding:11px}.hk-town-fruit-counter{grid-template-columns:48px minmax(0,1fr) auto;gap:8px;padding:10px}.hk-town-fruit-art{width:46px;height:46px;font-size:25px}.hk-town-fruit-counter>div b{font-size:11px}.hk-town-fruit-counter>div small{font-size:9px}#hk-town-store footer{grid-template-columns:1fr;gap:8px}#hk-town-sell-apples{width:100%;font-size:11px}.hk-town-build-menu{gap:8px;padding:10px;border-radius:17px}.hk-town-build-menu>header strong{font-size:13px}.hk-town-build-options{grid-template-columns:1fr;gap:6px}.hk-town-build-options button{grid-template-columns:36px minmax(0,1fr) auto;justify-items:start;min-height:50px;padding:6px 9px;text-align:right}.hk-town-build-options button>span{grid-row:1;width:32px;height:32px;font-size:18px}.hk-town-build-options button>b{font-size:10px}.hk-town-build-options button>small{justify-self:end}}
@media(orientation:landscape) and (max-height:520px){.hk-town-build-menu{width:min(360px,calc(100vw - 16px));gap:6px;padding:8px}.hk-town-build-menu>header{padding-bottom:4px}.hk-town-build-options{grid-template-columns:repeat(3,minmax(0,1fr))}.hk-town-build-options button{grid-template-columns:1fr;justify-items:center;min-height:65px;padding:4px}.hk-town-build-options button>span{grid-row:auto;width:26px;height:26px;font-size:15px}.hk-town-build-options button>b{font-size:8px}.hk-town-build-options button>small{font-size:8px}.hk-town-build-status{min-height:0;padding:4px;font-size:8px}}
@media(max-width:700px) and (orientation:portrait){.hk-town-mobile-stage{--hk-carousel-depth:min(158vw,620px)}.hk-town-mobile-card{width:min(48vw,198px)}}
@media(max-width:380px) and (orientation:portrait){.hk-town-mobile-stage{--hk-carousel-depth:min(162vw,590px)}.hk-town-mobile-card{width:min(48vw,180px)}}
@media(prefers-reduced-motion:reduce){.hk-town-build-options button{transition:none}}

/* Direct room entry in the salon menu and phone carousel. Keep controls
   self-contained because host pages and embedded webviews apply global form styles. */
#hk-town-world .hk-town-menu > .hk-town-invite-entry,
#hk-town-world .hk-town-mobile-selected > .hk-town-invite-entry--mobile {
    display:grid!important;grid-template-columns:minmax(0,1fr)!important;gap:8px!important;
    box-sizing:border-box!important;width:100%!important;min-width:0!important;margin:3px 0!important;padding:10px!important;
    border:1px solid #d9c47770!important;border-radius:15px!important;
    background:linear-gradient(145deg,#183a2df2,#0b2019f5 72%,#101a1af5)!important;
    box-shadow:inset 0 1px #ffffff18,0 7px 18px #0003!important;color:#fff0be!important;
}
#hk-town-world .hk-town-invite-entry label {
    display:block!important;margin:0!important;color:#ffe7a0!important;
    font:900 11px/1.4 system-ui,-apple-system,"Segoe UI",sans-serif!important;text-align:right!important;
}
#hk-town-world .hk-town-invite-entry > div,
#hk-town-world .hk-town-invite-entry--mobile {
    display:grid!important;grid-template-columns:minmax(0,1fr) 66px!important;
    align-items:center!important;gap:7px!important;min-width:0!important;
}
#hk-town-world .hk-town-invite-entry input {
    display:block!important;box-sizing:border-box!important;flex:none!important;width:100%!important;
    min-width:0!important;height:40px!important;min-height:40px!important;margin:0!important;padding:0 11px!important;
    border:1px solid #b8d5c04d!important;border-radius:11px!important;
    background:linear-gradient(180deg,#071a14,#10281f)!important;color:#fff2ca!important;
    font:750 12px/1.2 system-ui,-apple-system,"Segoe UI",sans-serif!important;
    text-align:right!important;direction:rtl!important;outline:none!important;
    box-shadow:inset 0 2px 7px #0005!important;appearance:none!important;-webkit-appearance:none!important;
}
#hk-town-world .hk-town-invite-entry input::placeholder { color:#a9bdb2!important;opacity:1!important; }
#hk-town-world .hk-town-invite-entry input:focus {
    border-color:#70e3bb!important;box-shadow:0 0 0 3px #70e3bb25,inset 0 2px 7px #0005!important;
}
#hk-town-world .hk-town-invite-entry button {
    display:inline-flex!important;flex:none!important;align-items:center!important;justify-content:center!important;
    box-sizing:border-box!important;width:66px!important;min-width:66px!important;height:40px!important;min-height:40px!important;
    margin:0!important;padding:0 10px!important;border:1px solid #ffe39a!important;border-radius:11px!important;
    background:linear-gradient(135deg,#ffe99e,#d8b956 58%,#b38b38)!important;
    box-shadow:inset 0 1px #fff9,0 4px 10px #0004!important;color:#192a1e!important;
    font:950 12px/1 system-ui,-apple-system,"Segoe UI",sans-serif!important;white-space:nowrap!important;
    cursor:pointer!important;touch-action:manipulation!important;appearance:none!important;-webkit-appearance:none!important;
}
#hk-town-world .hk-town-invite-entry button:hover { filter:brightness(1.08)!important; }
#hk-town-world .hk-town-invite-entry button:active { transform:translateY(1px)!important;filter:brightness(.97)!important; }
#hk-town-world .hk-town-invite-entry--mobile { width:min(100%,390px)!important;padding:8px!important; }
#hk-town-world .hk-town-mobile-selected > .hk-town-invite-entry--mobile {
    grid-template-columns:minmax(0,1fr) 66px!important;
}
#hk-town-world .hk-town-invite-entry--mobile input,
#hk-town-world .hk-town-invite-entry--mobile button { height:38px!important;min-height:38px!important; }
#hk-town-world.hk-town-mobile-mode .hk-town-menu{z-index:30!important;}
