:root{font-family:Inter,"Segoe UI","PingFang SC","Microsoft YaHei",sans-serif;color:#173e32;background:#f6f5ec;font-synthesis:none}*{box-sizing:border-box}body{margin:0;min-height:100svh;overscroll-behavior:none;background:radial-gradient(ellipse at 35% 40%,#fffef6,#f2f3e8 75%)}button,a,input{-webkit-tap-highlight-color:transparent}button,input{font:inherit}button{cursor:pointer}button:disabled{cursor:wait;opacity:.65}button:focus-visible,a:focus-visible,input:focus-visible,canvas:focus-visible{outline:3px solid #df9f35;outline-offset:4px}.page{max-width:1260px;padding:28px 36px 18px;margin:auto}.topbar{display:flex;align-items:center;justify-content:space-between;padding-bottom:23px;border-bottom:1px solid #173e321c;margin-bottom:20px}.brand{color:#173e32;display:flex;align-items:center;gap:10px;font-size:22px;font-weight:900;letter-spacing:1px;text-decoration:none;line-height:1.05}.brand-icon{font-size:38px;font-weight:400}.brand-small{display:block;font-size:10px;letter-spacing:3px;font-weight:700;margin-top:6px}.header-right{display:flex;align-items:center;gap:24px}.season{font-size:11px;letter-spacing:1.5px;color:#7b897b}.profile-button{display:flex;align-items:center;gap:9px;border:1px solid #d2dace;border-radius:30px;background:#ffffff85;color:#244537;padding:5px 12px 5px 5px;max-width:240px;font-size:13px}.profile-button>span:nth-child(2){overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:120px}.avatar{width:32px;height:32px;border-radius:50%;display:inline-flex;align-items:center;justify-content:center;flex-shrink:0;background:#efc965;font-weight:800;color:#183e32;font-size:14px;overflow:hidden}.avatar img{width:100%;height:100%;object-fit:cover}.avatar.large{width:84px;height:84px;font-size:30px;border:4px solid white;box-shadow:0 4px 16px #163e3320}.layout{display:grid;grid-template-columns:minmax(180px,1fr) 388px minmax(230px,1fr);gap:40px;align-items:center}.eyebrow{font-size:10px;letter-spacing:2px;font-weight:700;color:#69816a}.intro h1{font-size:clamp(36px,4vw,51px);line-height:1.23;letter-spacing:-2px;margin:24px 0;font-weight:900}.intro h1 span{color:#85a55b}.intro>p{font-size:15px;color:#71806a;line-height:1.9}.scoring-guide{margin-top:28px;border-top:1px solid #d4decf;padding-top:16px;max-width:225px}.scoring-guide h2{font-size:14px;margin:0 0 15px}.scoring-guide>div{display:flex;align-items:center;gap:12px;font-size:13px;margin:11px 0}.scoring-guide b{margin-left:auto;font:700 17px monospace}.ball{display:inline-block;width:18px;height:18px;border-radius:50%;box-shadow:inset -3px -3px 0 #00000012,0 1px 3px #173e3225;border:1px solid #a9b7a670;flex-shrink:0}.ball.white{background:#fff}.ball.pink{background:#f2a4bf}.ball.gold{background:#f1c247}.scoring-guide small{display:block;color:#7e8c75;font-size:11px;margin-top:17px}.intro .tiny{font-size:12px;margin-top:26px}.machine{min-width:0;width:100%}.hud{display:flex;align-items:center;justify-content:space-between;height:52px;padding:0 3px 12px}.hud>div:first-child{display:flex;align-items:baseline;gap:10px}.stat-label{font-size:12px;color:#70816a}.hud strong{font:700 24px monospace}.hud-tools{display:flex;gap:7px}.icon-btn{border:1px solid #c9d6c4;background:#ffffff80;color:#214c3a;min-width:34px;height:33px;border-radius:9px;font-size:19px}.icon-btn:hover{background:#e7edde}.screen{position:relative;width:100%;aspect-ratio:390/610;border:5px solid #194c39;border-radius:22px;overflow:hidden;box-shadow:0 9px 0 #0d332a,0 20px 35px #163e331c;touch-action:none;user-select:none;-webkit-user-select:none;background:#d3e8cf}canvas{display:block;width:100%;height:100%;touch-action:none;outline:none}.score{position:absolute;top:20px;left:0;right:0;text-align:center;font:900 47px/1 monospace;color:#fffef1;text-shadow:2px 3px #24563b,-1px -1px #24563b;pointer-events:none}.pickup-counter{position:absolute;top:75px;left:0;right:0;display:flex;gap:12px;justify-content:center;color:#244b3b;font-size:12px;pointer-events:none}.pickup-counter b{font:700 14px monospace}.overlay{position:absolute;inset:0;display:flex;flex-direction:column;justify-content:center;align-items:center;text-align:center;padding:24px;pointer-events:none}.overlay[hidden],[hidden]{display:none!important}.start-heading{position:absolute;top:12%;left:0;right:0}.course-tag{font-size:10px;letter-spacing:3px;color:#396346;font-weight:700}.start-heading h2{margin:15px 0 12px;font-size:58px;font-weight:950;letter-spacing:4px;line-height:1.06;color:#174a36;text-shadow:0 3px #f6f3cb}.start-heading h2 span{color:#f9fff2;display:block;text-shadow:2px 3px #39633f,-1px -1px #39633f}.start-heading p{font-size:10px;letter-spacing:3px;color:#55785a}.start-controls{position:absolute;top:63%;left:24px;right:24px}.primary{pointer-events:auto;display:block;border:0;border-bottom:4px solid #092e21;background:#174d36;color:#fff9df;border-radius:12px;min-height:49px;padding:12px 22px;font-size:16px;font-weight:700;width:100%;box-shadow:0 2px 0 #ffffff20 inset;transition:background .15s}.primary:hover{background:#276444}.primary:active{transform:translateY(2px)}.secondary{pointer-events:auto;display:block;border:1px solid #d0dbc7;border-radius:10px;background:transparent;color:#31543d;width:100%;padding:11px 15px;margin-top:10px;font-size:14px}.hint{font-size:12px;color:#3f6545;margin:12px 0;line-height:1.5}.text-button{pointer-events:auto;border:0;background:transparent;color:#7b4827;font-size:13px;text-decoration:underline;padding:7px}.mini-legend{display:flex;align-items:center;justify-content:center;gap:19px;margin:19px 0;font:700 13px monospace;color:#315138}.mini-legend>span{display:flex;align-items:center;gap:6px}.mini-legend .ball{width:16px;height:16px}.card{pointer-events:auto;background:#fffef0f5;border:1px solid #e4e6c8;border-radius:20px;width:100%;padding:26px 23px;box-shadow:0 9px 0 #194c3925,0 15px 35px #163e3320}.card h2{font-size:22px;margin:14px 0 10px;letter-spacing:-.5px}.card>p{font-size:13px;color:#6d8066;line-height:1.6;margin:0 0 18px}.results{display:flex;justify-content:space-around;border-top:1px solid #dce3cf;border-bottom:1px solid #dce3cf;margin:20px 0 15px;padding:17px 0}.results span{display:block;font-size:11px;color:#7b8a6d;margin-bottom:7px}.results strong{font:800 40px monospace}.result-balls{font-size:12px;color:#6b785d;display:flex;gap:15px;justify-content:center;margin-bottom:13px}.card .save-status{font-size:12px;margin-bottom:8px}.game-footer{display:flex;justify-content:space-between;gap:10px;padding:22px 4px 0;font-size:11px;color:#788771}.online-label{color:#46704d}.leaderboard{background:#fffef6;border:1px solid #dde4d2;border-radius:18px;padding:22px 19px;align-self:center;min-width:0}.board-title,.dialog-head{display:flex;align-items:center;justify-content:space-between;gap:12px}.board-title h2,dialog h2{font-size:19px;letter-spacing:-.5px;margin:7px 0 0}.board-title .icon-btn{border:0;background:#eef2e6}.board-sub{font-size:12px;color:#7e8b73;margin:13px 0 17px}.board-list{max-height:300px;overflow:auto;scrollbar-width:thin;scrollbar-color:#cad6be transparent}.rank-row{display:flex;align-items:center;gap:10px;padding:12px 0;border-top:1px solid #e5eadc}.rank-num{width:19px;font:600 13px monospace;color:#8a967e;flex-shrink:0}.rank-row:nth-child(-n+3) .rank-num{color:#b4862d;font-weight:900}.rank-name{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-size:13px;flex:1}.rank-points{font:700 18px monospace}.rank-row .avatar{width:28px;height:28px;font-size:12px}.rank-row.me{background:#f1f5e6}.my-rank{margin-top:15px;padding:13px 12px;border-radius:10px;background:#eaf0df;font-size:12px;color:#4d6845;line-height:1.7}.board-foot{font-size:11px;line-height:1.8;color:#8b957e;margin:17px 0 0}.empty{font-size:13px;color:#839174;text-align:center;line-height:1.9;padding:30px 0}.page-footer{display:flex;justify-content:space-between;margin-top:30px;padding-top:15px;border-top:1px solid #173e3215;font-size:9px;letter-spacing:1.5px;color:#99a18c}.page-footer span{letter-spacing:1px}dialog{width:min(410px,calc(100vw - 28px));max-height:90svh;border:1px solid #dce3cf;border-radius:22px;background:#fffef5;color:#183f31;padding:25px;box-shadow:0 24px 70px #092e2160}dialog::backdrop{background:#123c3280;backdrop-filter:blur(5px)}dialog .board-list{max-height:50svh}.dialog-head h2{margin:0;font-size:21px}.close{border:0;background:#ecf0e3;font-size:25px}form>label{display:block;font-size:13px;margin:22px 0 8px}input[type=text],input:not([type]){width:100%;padding:13px 15px;border:1px solid #cbd8bd;border-radius:10px;background:#fffef8;color:#183f31;font-size:16px}input#nickname{width:100%;padding:13px 15px;border:1px solid #cbd8bd;border-radius:10px;background:#fffef8;color:#183f31;font-size:16px}.field-hint{font-size:12px;line-height:1.8;color:#839171}.profile-preview{display:flex;align-items:center;justify-content:center;gap:9px;margin-top:24px}.wing{font-size:48px;color:#a9b998;transform:rotate(20deg)}.wing.right{transform:scaleX(-1) rotate(20deg)}form .upload-label{text-align:center;cursor:pointer;color:#537944;text-decoration:underline;margin:16px 0 5px}.profile-preview~.field-hint:first-of-type{text-align:center}.file-input{position:absolute;opacity:0;width:1px;height:1px}.file-input:focus-visible+.field-hint{outline:2px solid #df9f35}#profileStatus{font-size:13px;color:#896024;min-height:18px}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}
@media(max-width:1050px){.page{max-width:970px;padding:22px 25px}.layout{grid-template-columns:1fr 355px 230px;gap:23px}.intro h1{font-size:36px}.intro>p{font-size:13px}.scoring-guide{max-width:170px}.leaderboard{padding:18px 14px}.board-title h2{font-size:17px}.rank-row{gap:7px}.season{display:none}}
@media(max-width:820px){.page{max-width:700px}.layout{grid-template-columns:1fr 365px;gap:35px}.desktop-board{display:none}.intro h1{font-size:42px}.intro>p{font-size:15px}.scoring-guide{max-width:210px}}
@media(max-width:600px){.page{max-width:440px;padding:max(12px,env(safe-area-inset-top)) 14px max(12px,env(safe-area-inset-bottom))}.topbar{padding-bottom:12px;margin-bottom:4px}.brand{font-size:17px;gap:7px}.brand-icon{font-size:31px}.brand-small{font-size:8px;letter-spacing:2px;margin-top:4px}.profile-button{font-size:12px;gap:6px;max-width:190px}.profile-button>span:nth-child(2){max-width:90px}.avatar{width:29px;height:29px;font-size:12px}.layout{display:block}.intro{display:none}.hud{height:47px;padding-bottom:9px}.hud strong{font-size:22px}.screen{width:min(100%,calc((100svh - 159px)*390/610));min-width:220px;margin:auto;border-width:4px;border-radius:20px}.game-footer{font-size:10px;padding-top:20px}.page-footer{display:none}.icon-btn{height:31px;min-width:32px;font-size:18px}.overlay{padding:20px}.start-heading h2{font-size:clamp(39px,12vw,58px)}.start-controls{left:22px;right:22px}.primary{min-height:45px;font-size:15px;padding:11px 18px}.hint{font-size:11px}.mini-legend{margin-top:15px;font-size:12px}.card{padding:22px 18px}.card h2{font-size:20px}.results{margin:15px 0;padding:12px 0}.results strong{font-size:35px}.score{font-size:43px}.pickup-counter{top:68px}.course-tag{font-size:9px}.card>p{font-size:12px}.result-balls{font-size:11px;gap:10px}}
@media(max-height:670px) and (max-width:600px){.start-heading{top:9%}.start-heading h2{font-size:38px}.start-heading p{margin:8px 0;font-size:8px}.start-controls{top:62%;left:16px;right:16px}.primary{min-height:38px;padding:8px 12px;font-size:14px}.hint{margin:8px 0;font-size:10px}.mini-legend{margin:9px 0;font-size:11px}.mini-legend .ball{width:13px;height:13px}.card{padding:15px}.card h2{font-size:18px;margin:9px 0}.card>p{margin-bottom:10px}.results{padding:9px 0;margin:10px 0}.results strong{font-size:28px}.secondary{padding:8px;margin-top:7px;font-size:12px}.result-balls{margin-bottom:7px}}
@media(orientation:landscape) and (max-height:580px){.page{max-width:760px;padding:8px 20px}.topbar{padding-bottom:8px;margin-bottom:0}.layout{display:grid;grid-template-columns:1fr 220px;gap:40px}.intro{display:block}.intro h1{font-size:32px;margin:14px 0}.intro>p{font-size:13px}.scoring-guide,.intro .tiny,.desktop-board,.page-footer{display:none}.hud{height:40px}.screen{width:210px;min-width:0;border-width:3px}.game-footer{display:none}.start-heading h2{font-size:31px}.start-heading p{font-size:7px}.course-tag{font-size:7px}.primary{min-height:30px;padding:7px;font-size:12px}.hint{font-size:9px;margin:7px 0}.mini-legend{font-size:9px;margin:7px 0;gap:10px}.mini-legend .ball{width:11px;height:11px}.start-controls{left:15px;right:15px}.overlay{padding:13px}.card{padding:13px}.card h2{font-size:15px;margin:8px 0}.card>p{font-size:10px;margin-bottom:7px}.results{padding:7px 0;margin:8px 0}.results strong{font-size:25px}.results span{font-size:9px}.result-balls,.card .save-status{font-size:9px;margin-bottom:6px}.secondary{font-size:10px;padding:6px;margin-top:6px}.eyebrow{font-size:8px}.score{font-size:30px}.pickup-counter{top:54px;font-size:9px}}

/* English labels need more horizontal room than the original copy. */
.intro h1{font-size:clamp(32px,3.5vw,45px);letter-spacing:-1.5px}.start-heading h2{font-size:49px;letter-spacing:1px}.board-title h2{font-size:18px}.header-right .profile-button{max-width:235px}.card h2{line-height:1.25}.hint{line-height:1.45}.result-balls{flex-wrap:wrap;line-height:1.6}.profile-button>span:nth-child(2){max-width:130px}
@media(max-width:600px){.start-heading h2{font-size:clamp(35px,11vw,46px)}.profile-button>span:nth-child(2){max-width:105px}.game-footer{font-size:10px}.card .save-status{font-size:11px}.results span{font-size:10px}.header-right{min-width:0}.brand{flex-shrink:0}}
@media(max-height:670px) and (max-width:600px){.start-heading h2{font-size:34px}.hint{font-size:10px}.card h2{font-size:18px}.result-balls{font-size:10px}}
@media(orientation:landscape) and (max-height:580px){.start-heading h2{font-size:29px}.card h2{font-size:16px}}

.character-field{border:0;padding:0;margin:20px 0 0}.character-field legend{font-size:14px;font-weight:700}.character-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;margin-top:12px}.character-choice{display:flex;flex-direction:column;align-items:center;gap:5px;border:2px solid #dce3cf;border-radius:12px;background:#f6f8ed;color:#31543d;padding:8px 3px;font-size:11px;min-height:82px}.character-choice[aria-pressed=true]{border-color:#2f744c;background:#e5efda;box-shadow:0 0 0 1px #2f744c}.character-choice img{width:47px;height:47px;object-fit:contain}.character-choice:disabled{cursor:default;opacity:.5;border-style:dashed}.character-placeholder{height:47px;font-size:31px;color:#96a68b}.profile-preview{margin-top:16px}.result-avatar{margin:0 auto 10px}.result-avatar img{object-fit:contain}.mood-timer{position:absolute;top:98px;left:0;right:0;text-align:center;pointer-events:none;color:#685013;font-size:12px;font-weight:700}.avatar img{object-fit:contain}@media(max-height:670px){.result-avatar.avatar.large{width:49px;height:49px}.character-choice{min-height:70px}.character-choice img{height:38px;width:38px}}

/* Framed portraits, with matching feathered wings on the large player cards. */
.avatar{border:2px solid #e9c566;box-shadow:0 0 0 1px #587456}.avatar.large{border:4px solid #e9c566;box-shadow:0 0 0 2px #587456,0 4px 16px #163e3320;overflow:visible;position:relative;isolation:isolate}.avatar.large img{border-radius:50%;background:inherit}.profile-preview>.wing{display:none}.avatar.large::before,.avatar.large::after{content:'';position:absolute;top:12%;width:48px;height:55px;z-index:-1;background:center/contain no-repeat url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 55'%3E%3Cpath d='M5 46C20 48 40 29 44 10Q44 1 36 12L26 27Q39 1 29 5Q23 7 17 25Q20 7 12 14Q3 25 5 46Z' fill='%23fffef0' stroke='%23648362' stroke-width='2'/%3E%3Cpath d='M12 38Q27 28 35 16' fill='none' stroke='%23d7dfc5' stroke-width='2'/%3E%3C/svg%3E");transform-origin:5% 70%;animation:portrait-wing .65s ease-in-out infinite alternate}.avatar.large::after{left:88%}.avatar.large::before{right:88%;scale:-1 1}.result-avatar{display:flex;margin-bottom:16px}.result-avatar::before,.result-avatar::after{animation:none;transform:rotate(10deg)}@keyframes portrait-wing{from{transform:rotate(-17deg)}to{transform:rotate(19deg)}}@media(prefers-reduced-motion:reduce){.avatar.large::before,.avatar.large::after{animation:none}}

.hud{height:58px;padding:4px 2px 12px;gap:10px;font-family:Inter,"Segoe UI",Arial,sans-serif}.hud>div:first-child{gap:10px;align-items:center}.hud .stat-label{font:600 11px/1.25 Inter,"Segoe UI",Arial,sans-serif;letter-spacing:.25px;color:#75816e}.hud strong{font:750 27px/1 Inter,"Segoe UI",Arial,sans-serif;letter-spacing:-1px;font-variant-numeric:tabular-nums;color:#214c3a}.hud-tools{gap:6px;align-items:center;padding:3px;border:1px solid #dde3d5;border-radius:14px;background:#eef1e6}.hud-tools .icon-btn{display:inline-flex;align-items:center;justify-content:center;padding:0;width:36px;min-width:36px;height:36px;border:0;border-radius:10px;background:#fffef7;color:#3a5c48;box-shadow:0 1px 3px #173e3210;transition:background .15s,transform .15s}.hud-tools .icon-btn:hover{background:#e1ead7}.hud-tools .icon-btn:active{transform:scale(.94)}.hud-tools .icon-btn[aria-pressed=true]{background:#e9dca9}.hud-tools svg{display:block;flex-shrink:0}@media(max-width:600px){.hud{height:54px;padding-bottom:9px}.hud strong{font-size:25px}.hud .stat-label{font-size:10px}.hud-tools{gap:4px;padding:2px}.hud-tools .icon-btn{width:34px;min-width:34px;height:34px}}@media(orientation:landscape) and (max-height:580px){.hud{height:46px;gap:4px}.hud>div:first-child{gap:5px}.hud .stat-label{font-size:9px}.hud strong{font-size:20px}.hud-tools .icon-btn{width:29px;min-width:29px;height:29px}.hud-tools svg{width:17px;height:17px}.hud-tools{gap:3px}}

.game-footer{gap:8px;flex-wrap:wrap}.online-label{color:#73836b;font-size:10px;white-space:nowrap}.online-label::before{display:none}

/* Keep result portraits at their original size and omit decorative wings. */
#resultAvatar::before,#resultAvatar::after{display:none}


#resultUsername{text-transform:none;overflow-wrap:anywhere;letter-spacing:1px}

/* Mirror the artwork without moving its attachment point. */
.avatar.large::before{scale:none;background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 48 55'%3E%3Cg transform=%27translate(48 0) scale(-1 1)%27%3E%3Cpath d='M5 46C20 48 40 29 44 10Q44 1 36 12L26 27Q39 1 29 5Q23 7 17 25Q20 7 12 14Q3 25 5 46Z' fill='%23fffef0' stroke='%23648362' stroke-width='2'/%3E%3Cpath d='M12 38Q27 28 35 16' fill='none' stroke='%23d7dfc5' stroke-width='2'/%3E%3C/g%3E%3C/svg%3E");transform-origin:95% 70%;animation-name:portrait-wing-left}.avatar.large::after{transform-origin:5% 70%}@keyframes portrait-wing-left{from{transform:rotate(17deg)}to{transform:rotate(-19deg)}}

.start-heading h2{font-size:44px;letter-spacing:0}@media(max-width:600px){.start-heading h2{font-size:clamp(29px,9vw,40px)}}@media(max-height:670px) and (max-width:600px){.start-heading h2{font-size:29px}}@media(orientation:landscape) and (max-height:580px){.start-heading h2{font-size:24px}}

/* Give leaderboard entries soft edges and room around every column. */
.rank-row{gap:12px;padding:13px 16px;margin:8px 0;border:1px solid #e4e9dc;border-radius:16px;background:#fffef8}.rank-row.me{background:#f1f5e6;border-color:#dce5ca}.rank-num{width:24px;text-align:center}.rank-points{flex-shrink:0;padding-left:8px;font-variant-numeric:tabular-nums}.rank-name{line-height:1.45}.rank-row .avatar{margin-right:2px}@media(max-width:380px){.rank-row{gap:9px;padding:12px}.rank-num{width:21px}}

.hud .stat-label{font-family:Inter,'Segoe UI',Arial,sans-serif;font-size:12px;font-weight:600;letter-spacing:.1px;line-height:1.3}.hud strong{font-family:Inter,'Segoe UI',Arial,sans-serif;font-size:28px;font-weight:800;letter-spacing:-.7px}.hud>div:first-child{gap:10px;min-width:0}.hud .stat-label{max-width:94px}@media(max-width:380px){.hud .stat-label{font-size:11px;max-width:78px}.hud strong{font-size:26px}.hud>div:first-child{gap:8px}}@media(orientation:landscape) and (max-height:580px){.hud .stat-label{font-size:10px;max-width:60px}.hud strong{font-size:22px}}
