:root{font-family:Inter,ui-sans-serif,system-ui,-apple-system,Segoe UI,Arial,sans-serif;color:#f8f1df;background:#102827;font-synthesis:none}*{box-sizing:border-box}body{margin:0;min-width:320px}button,select{font:inherit}button{cursor:pointer}button:disabled{cursor:not-allowed;opacity:.42}button:focus-visible,select:focus-visible{outline:3px solid #f6cf71;outline-offset:3px}.app{min-height:100dvh;padding:clamp(12px,2vw,28px);background:radial-gradient(circle at 50% 34%,#28564e 0,#173b38 43%,#0d2828 100%)}.shell{max-width:1260px;margin:auto}.top{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:18px}.brand{display:flex;align-items:center;gap:10px;font-weight:900;letter-spacing:.025em;font-size:clamp(19px,2.4vw,27px)}.brandmark{width:32px;height:32px;border:2px solid #f6cf71;border-radius:8px;display:grid;place-items:center;color:#f6cf71;font-size:19px;transform:rotate(-8deg)}.topright,.row{display:flex;align-items:center;gap:8px;flex-wrap:wrap}.pill,.button{border:1px solid #88aa9e66;border-radius:11px;background:#ffffff13;color:#f8f1df;padding:10px 14px;min-height:42px}.button:hover:not(:disabled),.pill:hover{background:#ffffff25}.button.primary{background:#f1c66e;color:#17312c;border-color:#f1c66e;font-weight:800}.button.primary:hover{background:#ffe09b}.button.danger{border-color:#b97b6d}.button.small{font-size:13px;padding:8px 11px;min-height:38px}.table{border:1px solid #a6c4b447;border-radius:24px;background:linear-gradient(135deg,#1d4b43,#164038);box-shadow:0 18px 50px #04171480,inset 0 0 0 8px #ffffff06;padding:clamp(13px,2vw,26px);min-height:calc(100dvh - 90px);display:flex;flex-direction:column;gap:16px}.scorebar{display:flex;justify-content:space-between;align-items:center;gap:12px;border-bottom:1px solid #ffffff30;padding-bottom:14px}.score{display:flex;align-items:center;gap:10px}.avatar{width:38px;height:38px;border-radius:50%;background:#e6bb63;color:#193c36;display:grid;place-items:center;font-weight:900}.avatar.bot{background:#a1d4c3}.score strong{font-size:23px;display:block;line-height:1}.muted{color:#c3d4c9;font-size:13px}.turntag{background:#f1c66e;color:#15352f;border-radius:30px;padding:7px 12px;font-weight:800;font-size:12px;text-align:center}.opponent{text-align:center;min-height:82px}.backs{display:flex;justify-content:center;padding:9px 0}.back{width:31px;height:45px;border:2px solid #dbebd8;border-radius:5px;background:repeating-linear-gradient(45deg,#224d4b 0 5px,#3f7f77 5px 8px);box-shadow:2px 2px 0 #0d2b2b;margin-left:-14px}.back:first-child{margin-left:0}.center{display:grid;grid-template-columns:minmax(105px,1fr) minmax(105px,1fr);gap:14px;align-items:start}.pilebox{border:1px solid #ffffff26;border-radius:16px;padding:13px;background:#082c2b66;min-height:118px}.label{font-size:11px;text-transform:uppercase;letter-spacing:.12em;color:#c6d9cf;font-weight:800;margin-bottom:11px}.piles{display:flex;gap:10px;align-items:flex-start}.stock{width:64px;height:88px;flex:none;border:2px solid #f6e8c2;border-radius:7px;background:repeating-linear-gradient(45deg,#2e6c64 0 6px,#204c4a 6px 12px);box-shadow:0 3px 0 #0a2927;color:#fff;display:grid;place-items:center;font-weight:900}.stock:disabled{background:#37524f}.discards{display:flex;overflow-x:auto;overflow-y:hidden;min-height:91px;padding:1px 2px 7px;scrollbar-width:thin}.discards .card{margin-left:-26px;flex:none}.discards .card:first-child{margin-left:0}.discards .card:hover{transform:translateY(-5px);z-index:4}.card{width:64px;height:88px;background:#fffaf0;color:#24332f;border:2px solid #ede6d4;border-radius:8px;display:flex;flex-direction:column;justify-content:space-between;padding:5px 6px;box-shadow:0 3px 6px #001c1d66;position:relative;user-select:none;touch-action:manipulation}.card.red{color:#c1443b}.card .corner{font-size:17px;font-weight:900;line-height:1}.card .big{font-size:30px;text-align:center;line-height:1}.card.selected{transform:translateY(-12px);border-color:#f4cd73;box-shadow:0 0 0 3px #f4cd7388,0 9px 12px #001c1d66}.card.hint{box-shadow:0 0 0 3px #a6e9b4,0 6px 11px #001c1d66}.card.illegal{opacity:.5}.meldzone{border:1px dashed #c6ddc463;border-radius:15px;min-height:124px;padding:13px;background:#0c342e77}.melds{display:flex;flex-wrap:wrap;gap:10px}.meld{border:1px solid #ffffff2d;background:#ffffff0c;border-radius:10px;padding:9px;min-width:100px}.meld .cards{display:flex;padding-left:1px}.meld .card{width:38px;height:53px;margin-left:-10px;padding:3px 4px}.meld .card:first-child{margin-left:0}.meld .card .corner{font-size:11px}.meld .card .big{font-size:18px}.meld .muted{margin-top:5px;font-size:11px}.handarea{margin-top:auto;border-top:1px solid #ffffff30;padding-top:13px}.handhead{display:flex;justify-content:space-between;gap:10px;align-items:center;margin-bottom:14px}.hand{display:flex;justify-content:center;flex-wrap:wrap;gap:6px;min-height:90px}.hand .card{width:clamp(43px,5vw,64px);height:clamp(65px,7vw,88px);padding:4px}.hand .card .big{font-size:clamp(20px,2.8vw,30px)}.hand .card .corner{font-size:clamp(13px,1.6vw,17px)}.actions{display:flex;justify-content:center;gap:8px;flex-wrap:wrap;margin-top:16px}.message{color:#ffe1a4;text-align:center;min-height:22px;font-size:14px}.overlay{position:fixed;inset:0;background:#061d1dc9;display:grid;place-items:center;padding:16px;z-index:20;overflow:auto}.modal{width:min(630px,100%);max-height:calc(100dvh - 32px);overflow:auto;border:1px solid #b9d2b55a;border-radius:23px;background:#193e39;box-shadow:0 20px 80px #0008;padding:clamp(20px,4vw,34px)}.modal h1,.modal h2{margin:0 0 10px;font-size:clamp(27px,5vw,42px);line-height:1.1}.modal p{color:#d7e4d9;line-height:1.55}.modal .button{margin:4px}.modal .wide{width:100%;margin:6px 0}.hero{font-size:56px;margin:0 0 4px}.rulelist{padding-left:21px;line-height:1.6;color:#dce9df}.statgrid{display:grid;grid-template-columns:1fr 1fr;gap:10px}.stat{padding:15px;border:1px solid #ffffff2b;border-radius:11px;background:#ffffff0a}.stat strong{display:block;font-size:25px;color:#f6cf71}.credits{font-size:13px;border-top:1px solid #ffffff30;padding-top:12px;margin-top:22px}.sr{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}@media(max-width:650px){.top{margin-bottom:8px}.topright .button{padding:8px 9px;font-size:12px;min-height:38px}.table{min-height:calc(100dvh - 65px);gap:9px;border-radius:17px;padding:11px}.score strong{font-size:18px}.avatar{width:30px;height:30px}.turntag{font-size:10px;padding:6px 8px}.center{gap:7px}.pilebox{padding:8px;min-height:110px}.stock,.pilebox>.piles>.card,.discards .card{width:49px;height:68px}.discards .card{margin-left:-25px}.card .corner{font-size:13px}.card .big{font-size:23px}.hand{gap:4px}.hand .card{width:clamp(41px,11vw,52px);height:68px}.hand .card .corner{font-size:13px}.hand .card .big{font-size:22px}.meldzone{min-height:92px}.opponent{min-height:56px}.back{width:24px;height:35px;margin-left:-13px}.handhead{margin-bottom:7px}.actions{margin-top:9px}.actions .button{font-size:12px;padding:8px 10px;min-height:40px}}@media(max-width:390px){.brand{font-size:17px}.brandmark{width:26px;height:26px}.topright{gap:4px}.topright .button{font-size:11px}.hand .card{width:39px;height:62px}.hand .card .big{font-size:20px}}@media(prefers-reduced-motion:no-preference){.card,.button{transition:transform .13s ease,background .13s ease,box-shadow .13s ease}.modal{animation:pop .2s ease-out}@keyframes pop{from{opacity:0;transform:translateY(9px)}to{opacity:1;transform:none}}}

.handPoints{color:#d7d4bf;text-align:center;font-size:13px;padding:10px;line-height:1.5}.row{flex-wrap:wrap}@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation:none!important;transition:none!important}}

/* Narrow embedded viewport; wrap controls instead of clipping content. */
body{min-width:0}.top,.handhead{flex-wrap:wrap}.topright{margin-left:auto}.actions{flex-wrap:wrap}.center>*{min-width:0}.handPoints{overflow-wrap:anywhere}@media(max-width:360px){.topright .pill{display:none}.app{padding:8px}.table{padding:8px}.center{grid-template-columns:60px minmax(0,1fr)}.scorebar{flex-wrap:wrap;justify-content:center}.turntag{white-space:normal;text-align:center}.handhead{gap:8px}.modal{padding:18px}}
