#together-bar {
  position:absolute; z-index:15; left:50%; top: max(9px,env(safe-area-inset-top)); transform:translateX(-50%);
  display:flex; align-items:center; gap:.45em; padding:.38em .6em; border:1px solid #ab906b; border-radius:16px;
  background:#fff3dceF;color:#54422e;box-shadow:0 3px 12px #52382738;
}
#together-bar b { white-space:nowrap; font-size:clamp(12px,1.6vw,17px) }
#together-bar .out-btn { white-space:nowrap; padding:.45em .7em; min-height:36px; }
#together-bar[hidden],.composing-photo #together-bar,body:has(#panel[open]) #together-bar {display:none}
.pair-head,.pair-baking {display:flex;align-items:center;gap:1em;margin-bottom:.6em}
.pair-head img {width:62px;height:62px;object-fit:cover;border-radius:50%;border:3px solid #dfc79d}
.pair-head h3,.pair-baking h3 {margin:0 0 .25em}
.pair-list {display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.pair-list button {display:flex;text-align:left;align-items:center;gap:10px;padding:10px 12px;color:#4e5442;background:#f5eed9;border:1px solid #c7bc99;border-radius:13px}
.pair-list button:not(:disabled):active {background:#e1ebd2}
.pair-list button:disabled {opacity:.70}
.pair-list svg {width:29px;height:29px;flex:none}
.pair-list span,.pair-list small {display:block}
.pair-list small,.pair-baking small {font-size:.79em;line-height:1.4}
.pair-baking>div {flex:1}
.pair-baking img {width:23%;max-width:130px}
.pair-note .out-btn,.pair-baking .out-btn {margin:3px}
#pair-icing {display:block;width:min(100%,330px);height:105px;touch-action:none;border:3px solid #d29762;border-radius:27px;background:linear-gradient(165deg,#e7aa73,#c48353);box-shadow:inset 0 4px 9px #fff4}
.dish-result img[alt="我们画的奶油花纹"] {width:min(220px,35vw);height:min(156px,31vh);object-fit:cover;border-radius:16px}
@media(max-width:720px){#together-bar {top:58px}.pair-list button {padding:8px}.pair-head img {width:42px;height:42px}}
#emote-key {
  position:absolute; right:max(8px,env(safe-area-inset-right)); top:50%; transform:translateY(-50%);
  min-width:48px; height:52px; border-radius:17px; color:#73584a;
}
#emote-key .icon {width:24px;height:24px}
.performing-emote :is(#near,#stick,#aim,#hint,#tools,#story-resume,.rightside) {visibility:hidden}
#panel[data-page="emoteWheel"] {
  --wheel-viewport:100vh;
  --wheel-limit:364px;
  --wheel-controls:98px;
  --wheel-size:min(var(--wheel-limit),82vw,calc(var(--wheel-viewport) - var(--wheel-controls)));
  width:min(560px,100vw); height:min(486px,var(--wheel-viewport)); max-width:100vw; max-height:var(--wheel-viewport); margin:auto;
  background:transparent; border:0; box-shadow:none; overflow:visible; color:#503e34;
}
/* Custom properties accept unknown units. Test a real height declaration
   before using dvh, or older WebViews lose the ring and portrait dimensions. */
@supports (height:100dvh) {
  #panel[data-page="emoteWheel"] {--wheel-viewport:100dvh}
}
#panel[data-page="emoteWheel"]::backdrop {background:#233e38a1}
#panel[data-page="emoteWheel"] > header,
#panel[data-page="emoteWheel"] #guide-follow {display:none}
#panel[data-page="emoteWheel"] #content {
  display:grid;place-items:center; width:100%; height:100%; padding:0; overflow:visible;
}
#panel[data-page="emoteWheel"] #reply:not(:empty) {
  position:absolute;bottom:0;left:50%;transform:translateX(-50%);width:max-content;max-width:min(96vw,500px);
  padding:6px 14px;border-radius:12px;background:#443d31;color:white;text-align:center;z-index:4;
}
.ew-shell {display:grid;justify-items:center;align-content:center;gap:5px}
.ew-ring {
  width:var(--wheel-size); height:var(--wheel-size); position:relative; isolation:isolate;
  border:2px solid #c4ab80; border-radius:50%;
  background:radial-gradient(circle,#f6edda 0% 28%,#baa783 28.3% 28.7%,#e0cfab 29% 31%,#f9f0db 31.5% 68%,#e6d5b8 69%);
  box-shadow:inset 0 0 0 4px #fff8e7,inset 0 0 0 6px #d7c8a6,0 8px 28px #1f302e42;
}
.ew-ring::before {
  content:"";position:absolute;inset:4%;border:1px dashed #c5b18b;border-radius:inherit;pointer-events:none;
}
.ew-choice {
  position:absolute;transform:translate(-50%,-50%);width:25%;height:26%;min-height:44px;
  display:flex;flex-direction:column;align-items:center;justify-content:center;gap:1px;
  border:0;background:transparent;color:#534332;line-height:1.05;touch-action:manipulation;
  border-radius:18px;font-size:clamp(10px,2.8vmin,14px);font-weight:650;
}
.ew-choice:is(:hover,:focus-visible),.ew-choice:active {background:#e5d9bcb0}
.ew-choice .emote-sticker,.ew-choice > .icon {display:block;width:auto;height:64%;max-width:100%;aspect-ratio:1;flex:none}
.ew-choice span {line-height:1.18;text-align:center}
.ew-center {
  position:absolute; top:50%; left:50%; transform:translate(-50%,-50%);
  width:42%;display:grid;justify-items:center;gap:2px; color:#4f654e; line-height:1.15;
}
.ew-center>b {font-size:clamp(12px,3.4vmin,17px)}
.ew-portraits {height:calc(var(--wheel-size) * .135);display:flex;justify-content:center}
.ew-portraits img {width:auto;height:100%;object-fit:contain}
.ew-portraits img+img {margin-left:-2px}
.ew-bond,.ew-status {
  display:flex;align-items:center;gap:3px;border:1px solid #d8bfa1;border-radius:20px;
  background:#fffaed;color:#775a41;font-size:12px;min-width:40px;min-height:24px;padding:2px 7px;justify-content:center
}
.ew-bond .icon {width:15px;height:15px}
.ew-tabs,.ew-pager {display:flex;align-items:center;background:#fcf4e1;border:1px solid #c8b08b;border-radius:30px;padding:2px;gap:2px;box-shadow:0 2px 7px #20342c36}
.ew-tabs button,.ew-pager button {background:transparent;color:#65543e;border:0;border-radius:26px;min-height:36px;padding:5px 15px;font-weight:650}
.ew-tabs button[aria-pressed="true"] {color:white;background:#526e52}
.ew-pager button {font-size:22px;min-width:45px;line-height:1}
.ew-pager span {min-width:38px;text-align:center;font-size:12px;font-variant-numeric:tabular-nums}
.ew-close {
  position:absolute;top:8px;right:max(6px,env(safe-area-inset-right));z-index:2;border-radius:50%;
  border:1px solid #cbb28d;width:40px;height:40px;background:#fff6df;color:#69553e;font-size:24px;line-height:1;
}
.ew-ledger {position:relative;background:#fff5dd;border:1px solid #c6ae88;border-radius:23px;padding:18px 22px;width:min(350px,91vw);max-height:calc(var(--wheel-viewport) * .95);overflow:auto;box-shadow:0 8px 30px #273a3544}
.ew-ledger h3 {margin:0 40px 5px 0;color:#506d55}
.ew-score {font-size:24px;color:#976253}
.ew-ledger p {font-size:13px;line-height:1.5;margin:10px 0;color:#716451}
.ew-ledger>div {display:flex;justify-content:space-between;gap:8px;border-top:1px solid #dacdb1;padding:7px 0;font-size:13px}
.ew-ledger>button:not(.ew-close) {background:#526e52;color:white;border:0;border-radius:16px;min-height:40px;padding:4px 16px}
@media (orientation:landscape) and (max-height:370px) {
  #panel[data-page="emoteWheel"] {--wheel-limit:320px;--wheel-controls:90px}
  .ew-shell {gap:1px}
}
