/* Runaway — App 視窗、訊息、設定 */
.win{position:absolute;inset:0;z-index:40;background:var(--app-bg);color:var(--app-fg);display:flex;flex-direction:column;transform:translateX(100%);transition:transform .26s cubic-bezier(.2,.8,.2,1);user-select:none;-webkit-user-select:none}
.win.in{transform:none}
.win.out{transform:translateX(100%)}
@media (prefers-reduced-motion:reduce){.win{transition:none}}
.bar{display:flex;align-items:center;gap:6px;padding:calc(var(--sb) + 6px) 10px 8px;min-height:52px;background:var(--app-bg);position:relative;z-index:2}
.bar .ttl{flex:1;min-width:0;font-weight:700;font-size:16px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.bar .big{font-family:var(--f-display);font-weight:400;font-size:32px;line-height:1;letter-spacing:.01em}
.ib{width:38px;height:38px;border-radius:12px;border:none;background:transparent;color:inherit;display:grid;place-items:center;cursor:pointer;flex:none;padding:0;position:relative}
.ib svg{width:22px;height:22px;stroke:currentColor;fill:none;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.ib:active{background:var(--app-line)}
.scroll{flex:1;overflow-y:auto;overflow-x:hidden;min-height:0;-webkit-overflow-scrolling:touch}
.muted{color:var(--app-muted)}

/* ---------- 聊天列表 ---------- */
.tl{list-style:none;margin:0;padding:0 0 20px}
.tl li{display:flex;gap:12px;align-items:center;padding:10px 16px;cursor:pointer;position:relative}
.tl li:active{background:var(--app-line)}
.tl li.pinned{background:color-mix(in srgb,var(--app-line) 45%,transparent)}
.tl .av{width:50px;height:50px}
.tl .b{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px}
.tl .r1{display:flex;justify-content:space-between;gap:8px;align-items:baseline}
.tl .n{font-weight:700;font-size:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tl .tm{font-size:11px;color:var(--app-muted);flex:none;font-variant-numeric:tabular-nums}
.tl .r2{display:flex;justify-content:space-between;gap:8px;align-items:center}
.tl .pv{font-size:13px;color:var(--app-muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tl .ub{min-width:19px;height:19px;padding:0 6px;border-radius:10px;background:var(--danger);color:#fff;font-size:11px;font-weight:700;display:grid;place-items:center;flex:none}
.tl .grp{font-size:10px;padding:1px 6px;border-radius:6px;background:var(--app-line);color:var(--app-muted);margin-left:6px;font-weight:500;vertical-align:2px}
.empty-state{padding:40px 28px;text-align:center;color:var(--app-muted);font-size:14px;line-height:1.7}
.empty-state b{display:block;color:var(--app-fg);font-size:16px;margin-bottom:6px}
.empty-state .row{justify-content:center;margin-top:14px}

/* ---------- 聊天室 ---------- */
.chat .bar{border-bottom:1px solid var(--app-line)}
.chat .who{flex:1;min-width:0;display:flex;align-items:center;gap:10px;cursor:pointer}
.chat .who .av{width:36px;height:36px;font-size:14px}
.chat .who .tx{min-width:0;display:flex;flex-direction:column}
.chat .who .n{font-weight:700;font-size:15px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.chat .who .s{font-size:11px;color:var(--app-muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.msgs{flex:1;overflow-y:auto;overflow-x:hidden;padding:10px 12px 14px;display:flex;flex-direction:column;gap:6px;min-height:0;background:var(--chat-bg,var(--app-bg));background-size:cover;background-position:center}
.more-old{align-self:center;font-size:12px;color:var(--app-muted);background:var(--card);border:1px solid var(--app-line);border-radius:999px;padding:5px 12px;cursor:pointer;margin-bottom:6px}
.sep{align-self:center;font-size:11px;color:var(--app-muted);margin:8px 0 2px;font-variant-numeric:tabular-nums}
.notice{align-self:center;font-size:12px;color:var(--app-muted);background:color-mix(in srgb,var(--app-line) 70%,transparent);padding:4px 10px;border-radius:999px;max-width:86%;text-align:center}
.m{display:flex;gap:8px;align-items:flex-end;max-width:100%}
.m.me{flex-direction:row-reverse}
.m .av{width:34px;height:34px;font-size:13px;align-self:flex-start}
.m.cont .av{visibility:hidden;height:0}
.m .col{display:flex;flex-direction:column;gap:3px;min-width:0;max-width:76%}
.m.me .col{align-items:flex-end}
.m .nm{font-size:11px;color:var(--app-muted);padding:0 4px}
.bub{padding:9px 13px;border-radius:18px;font-size:15px;line-height:1.5;word-break:break-word;white-space:pre-wrap;background:var(--bub-them);color:var(--bub-them-fg);user-select:text;-webkit-user-select:text;box-shadow:0 1px 1px rgba(0,0,0,.04)}
.m.me .bub{background:var(--bub-me);color:var(--bub-me-fg)}
.m:not(.me) .bub{border-top-left-radius:6px}
.m.me .bub{border-top-right-radius:6px}
.m.cont:not(.me) .bub{border-top-left-radius:18px}
.m.cont.me .bub{border-top-right-radius:18px}
.bub .q{display:block;font-size:12px;opacity:.75;border-left:2px solid currentColor;padding-left:8px;margin-bottom:6px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:240px}
.bub.html{white-space:normal}
.bub details{margin:2px 0}
.bub summary{cursor:pointer;opacity:.8}
.tm-in{font-size:10px;color:var(--app-muted);padding:0 4px;font-variant-numeric:tabular-nums}
.stk{width:120px;height:120px;border-radius:12px;object-fit:contain;max-width:none;background:transparent}
.pic{max-width:200px;max-height:260px;border-radius:14px;display:block;object-fit:cover}
.photo{width:200px;border-radius:16px;overflow:hidden;background:var(--card);border:1px solid var(--app-line)}
.photo .ph{aspect-ratio:4/3;background:linear-gradient(150deg,var(--t4),var(--t2) 75%,var(--t1));display:grid;place-items:center;color:rgba(255,255,255,.9)}
.photo .ph svg{width:32px;height:32px;stroke:currentColor;fill:none;stroke-width:1.5}
.photo .ds{padding:8px 10px;font-size:12px;line-height:1.5;color:var(--app-fg);white-space:pre-wrap;display:none}
.photo.open .ds{display:block}
.voice{display:flex;align-items:center;gap:8px;min-width:110px;cursor:pointer}
.voice .bars{display:flex;gap:2px;align-items:center;height:16px}
.voice .bars i{width:3px;border-radius:2px;background:currentColor;opacity:.75}
.voice .sec{font-size:12px;opacity:.8;font-variant-numeric:tabular-nums}
.voice-tx{font-size:13px;line-height:1.5;padding:7px 11px;border-radius:12px;background:var(--card);color:var(--app-fg);border:1px solid var(--app-line);max-width:100%;white-space:pre-wrap;user-select:text}
.xfer{width:220px;border-radius:16px;overflow:hidden;background:var(--warm);color:#fff;cursor:pointer}
.xfer.done{opacity:.72}
.xfer .tp{display:flex;gap:10px;align-items:center;padding:12px 14px}
.xfer .tp svg{width:30px;height:30px;stroke:currentColor;fill:none;stroke-width:1.5;flex:none}
.xfer .amt{font-size:17px;font-weight:700;font-variant-numeric:tabular-nums}
.xfer .nt{font-size:12px;opacity:.9;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:150px}
.xfer .ft{font-size:11px;padding:6px 14px;background:rgba(0,0,0,.12)}
.recall{align-self:center;font-size:12px;color:var(--app-muted);cursor:pointer}
.typing{display:flex;gap:4px;padding:12px 14px;border-radius:18px;background:var(--bub-them);width:max-content}
.typing i{width:6px;height:6px;border-radius:50%;background:var(--app-muted);animation:blink 1.2s infinite}
.typing i:nth-child(2){animation-delay:.2s}.typing i:nth-child(3){animation-delay:.4s}
@keyframes blink{0%,60%,100%{opacity:.25}30%{opacity:1}}
.err{align-self:center;max-width:90%;font-size:12px;color:var(--danger);background:var(--card);border:1px solid var(--app-line);border-radius:12px;padding:8px 12px;text-align:center;line-height:1.5}
.err button{margin-top:6px}

/* 輸入列 */
.composer{border-top:1px solid var(--app-line);background:var(--app-bg);padding:8px 8px calc(8px + env(safe-area-inset-bottom,0px))}
.qbar{display:flex;gap:8px;align-items:center;font-size:12px;color:var(--app-muted);padding:4px 6px 8px}
.qbar span{flex:1;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;border-left:2px solid var(--t3);padding-left:8px}
.crow{display:flex;gap:6px;align-items:flex-end}
.crow textarea{flex:1;min-height:40px;max-height:120px;border-radius:20px;padding:9px 14px;resize:none;background:var(--card);border:1px solid var(--app-line);font-size:15px;line-height:1.45;user-select:text;-webkit-user-select:text;color:var(--app-fg)}
.crow .ib{width:40px;height:40px;border-radius:50%}
.send{background:var(--t1)!important;color:#fff}
.spark{color:var(--t2)}
.spark.busy svg{animation:spin 1s linear infinite}
@keyframes spin{to{transform:rotate(360deg)}}
.tray{display:grid;grid-template-columns:repeat(4,1fr);gap:12px;padding:14px 6px 6px}
.tray button{border:none;background:none;color:var(--app-fg);display:flex;flex-direction:column;align-items:center;gap:6px;font:12px var(--f-body);cursor:pointer}
.tray button span{width:52px;height:52px;border-radius:16px;background:var(--card);border:1px solid var(--app-line);display:grid;place-items:center}
.tray svg{width:24px;height:24px;stroke:currentColor;fill:none;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.stickers{display:grid;grid-template-columns:repeat(4,1fr);gap:8px;padding:10px 4px;max-height:240px;overflow:auto}
.stickers button{border:none;background:var(--card);border-radius:12px;padding:4px;cursor:pointer;display:flex;flex-direction:column;align-items:center;gap:2px;color:var(--app-muted);font-size:10px;min-width:0}
.stickers img{width:100%;aspect-ratio:1;object-fit:contain;max-width:none}
.stickers span{max-width:100%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}

/* ---------- 表單頁（設定、聊天資訊） ---------- */
.form{padding:4px 16px 40px;display:flex;flex-direction:column;gap:6px;user-select:text;-webkit-user-select:text}
.form h3{font-size:12px;letter-spacing:.12em;color:var(--app-muted);margin:18px 4px 4px;font-weight:500}
.group{background:var(--card);border-radius:16px;overflow:hidden;border:1px solid var(--app-line)}
.fi{display:flex;align-items:center;gap:10px;padding:12px 14px;border-bottom:1px solid var(--app-line);min-height:48px}
.fi:last-child{border-bottom:none}
.fi>label,.fi>.lb{flex:1;min-width:0;font-size:14px}
.fi .sub{display:block;font-size:12px;color:var(--app-muted);margin-top:2px;line-height:1.45}
.fi.col{flex-direction:column;align-items:stretch}
.fi.link{cursor:pointer}
.fi.link::after{content:"›";color:var(--app-muted);font-size:20px}
.fi input[type=text],.fi input[type=number],.fi input[type=url],.fi input[type=password],.fi textarea,.fi select{border-color:var(--app-line);background:var(--app-bg)}
.fi input[type=number]{width:84px;text-align:right}
.fi .v{color:var(--app-muted);font-size:13px;max-width:55%;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.tg{appearance:none;-webkit-appearance:none;width:46px;height:28px;border-radius:14px;background:var(--app-line);position:relative;cursor:pointer;flex:none;transition:background .2s;border:none;margin:0}
.tg::after{content:"";position:absolute;top:3px;left:3px;width:22px;height:22px;border-radius:50%;background:#fff;box-shadow:0 1px 3px rgba(0,0,0,.25);transition:transform .2s}
.tg:checked{background:var(--t2)}
.tg:checked::after{transform:translateX(18px)}
.avpick{display:flex;gap:18px;justify-content:center;padding:14px 0 4px}
.avpick button{border:none;background:none;display:flex;flex-direction:column;align-items:center;gap:6px;color:var(--app-muted);font-size:12px;cursor:pointer}
.avpick .av{width:72px;height:72px;font-size:26px}
.chips{display:flex;flex-wrap:wrap;gap:6px}
.chip{border:1px solid var(--app-line);background:var(--app-bg);color:var(--app-fg);border-radius:999px;padding:6px 12px;font:13px var(--f-body);cursor:pointer}
.chip.on{background:var(--t2);border-color:var(--t2);color:#fff}
.mono{font-family:ui-monospace,Menlo,Consolas,monospace;font-size:12px}
.progress{font-size:13px;color:var(--app-muted);padding:6px 2px}

/* ---------- 位置、連結、通話卡片 ---------- */
.loc{width:220px;border-radius:16px;overflow:hidden;background:var(--card);border:1px solid var(--app-line);color:var(--app-fg)}
.loc .map{height:92px;position:relative;background:
  linear-gradient(90deg,transparent 47%,color-mix(in srgb,var(--t4) 60%,transparent) 47% 53%,transparent 53%) 0 0/46px 46px,
  linear-gradient(0deg,transparent 46%,color-mix(in srgb,var(--t4) 45%,transparent) 46% 54%,transparent 54%) 0 0/62px 38px,
  color-mix(in srgb,var(--t4) 22%,var(--card))}
.loc .map i{position:absolute;left:50%;top:50%;width:18px;height:18px;margin:-16px 0 0 -9px;border-radius:50% 50% 50% 0;transform:rotate(-45deg);background:var(--danger);box-shadow:0 2px 6px rgba(0,0,0,.25)}
.loc .map i::after{content:"";position:absolute;inset:5px;border-radius:50%;background:#fff}
.loc .lt{padding:9px 12px;display:flex;flex-direction:column;gap:2px}
.loc .lt b{font-size:14px;line-height:1.4}
.loc .lt span{font-size:11px;color:var(--app-muted)}
.loc .lt .nt{color:var(--app-fg);font-size:12px}
.lnk{display:flex;flex-direction:column;gap:3px;width:230px;padding:10px 12px;border-radius:16px;background:var(--card);border:1px solid var(--app-line);color:var(--app-fg);text-decoration:none}
.lnk b{font-size:14px;line-height:1.4}
.lnk span{font-size:12px;color:var(--app-muted);line-height:1.45}
.lnk i{font-style:normal;font-size:11px;color:var(--t3)}
.callb{display:flex;align-items:center;gap:8px;cursor:pointer}
.callb svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:1.7}
.locreq{width:240px;padding:12px;border-radius:16px;background:var(--card);border:1px solid var(--app-line);display:flex;flex-direction:column;gap:10px;color:var(--app-fg)}
.locreq .lq{display:flex;gap:8px;align-items:center;font-size:14px}
.locreq .lq svg{width:20px;height:20px;stroke:var(--t2);fill:none;stroke-width:1.7;flex:none}
.locreq .muted{font-size:12px}

/* ---------- 通話畫面 ---------- */
.callwin{background:#0c121b;color:#eef2f7;align-items:center;overflow:hidden}
.callwin .cbg{position:absolute;inset:-40px;background:linear-gradient(160deg,var(--t2),var(--t1));background-size:cover;background-position:center;filter:blur(36px) brightness(.45) saturate(1.1);transform:scale(1.1)}
.callwin>*:not(.cbg){position:relative}
.ctop{margin-top:calc(var(--sb) + 40px);text-align:center}
.ctop .cn{font-size:24px;font-weight:700}
.ctop .cs{font-size:14px;opacity:.75;margin-top:6px;font-variant-numeric:tabular-nums}
.cav{margin-top:34px;border-radius:50%;padding:6px;position:relative}
.cav .av{width:124px;height:124px;font-size:42px;box-shadow:0 10px 40px rgba(0,0,0,.4)}
.cav::before,.cav::after{content:"";position:absolute;inset:0;border-radius:50%;border:2px solid rgba(255,255,255,.35);opacity:0}
.cav.live.companion::before,.cav.ring::before{animation:ripple 2.6s ease-out infinite}
.cav.live.companion::after,.cav.ring::after{animation:ripple 2.6s ease-out 1.3s infinite}
.cav.talking::before{animation:ripple 1.1s ease-out infinite}
@keyframes ripple{0%{transform:scale(1);opacity:.7}100%{transform:scale(1.55);opacity:0}}
@media (prefers-reduced-motion:reduce){.cav::before,.cav::after{animation:none!important}}
.ccap{flex:1;min-height:0;width:100%;overflow-y:auto;padding:22px 26px 10px;display:flex;flex-direction:column;gap:10px;user-select:text;-webkit-user-select:text}
.ccap p{margin:0;font-size:16px;line-height:1.6;max-width:92%}
.ccap p.them{align-self:flex-start}
.ccap p.me{align-self:flex-end;opacity:.7;text-align:right;font-size:14px}
.ccap p.hint{align-self:center;text-align:center;opacity:.7;font-size:14px;margin-top:auto;margin-bottom:auto}
.ccap p.err{align-self:center;color:#ffb4a8;font-size:13px;text-align:center}
.cin{width:calc(100% - 32px);display:flex;gap:8px;align-items:flex-end;margin-bottom:6px}
.cin textarea{flex:1;min-height:42px;max-height:100px;border-radius:21px;padding:10px 16px;background:rgba(255,255,255,.12);border:1px solid rgba(255,255,255,.18);color:#fff;font-size:15px;resize:none}
.cin textarea::placeholder{color:rgba(255,255,255,.55)}
.cin .ib{width:42px;height:42px;border-radius:50%;background:rgba(255,255,255,.16);color:#fff}
.cbtns{width:100%;display:grid;grid-template-columns:1fr 1fr 1fr;justify-items:center;padding:18px 20px calc(30px + env(safe-area-inset-bottom,0px))}
.cb{border:none;background:none;color:#eef2f7;display:flex;flex-direction:column;align-items:center;gap:8px;font:12px var(--f-body);cursor:pointer}
.cb span{width:64px;height:64px;border-radius:50%;display:grid;place-items:center;background:rgba(255,255,255,.16)}
.cb svg{width:26px;height:26px;stroke:currentColor;fill:none;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.cb.on span{background:#eef2f7;color:#0c121b}
.cb.end span{background:#d9483b}
.cb.end svg{transform:rotate(135deg)}
.cb.ok span{background:#3e9d62}

.stickers .addstk{justify-content:center;border:1.5px dashed var(--app-line);background:transparent}
.stickers .addstk .plus{width:100%;aspect-ratio:1;display:grid;place-items:center;color:var(--app-muted)}
.stickers .addstk svg{width:28px;height:28px;stroke:currentColor;fill:none;stroke-width:1.6}

.fi input[type=time],.fi input[type=date]{border:1px solid var(--app-line);background:var(--app-bg);border-radius:10px;padding:7px 9px;font:14px var(--f-body);color:inherit}

/* ---------- 酒館 ---------- */
.tavernwin{background:#11120f}
.tavernwin #mini-tavern-root{top:var(--sb)}

.btn svg{width:16px;height:16px;vertical-align:-3px;stroke:currentColor;fill:none;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}

/* ---------- 語音 ---------- */
.vrow{display:flex;align-items:center;gap:6px}
.m.me .vrow{flex-direction:row-reverse}
.vtx{border:none;background:none;color:var(--app-muted);font:12px var(--f-body);cursor:pointer;padding:4px}
.voice.real{min-width:120px}
.vplay{width:22px;height:22px;border-radius:50%;display:grid;place-items:center;background:color-mix(in srgb,currentColor 18%,transparent)}
.vplay svg{width:12px;height:12px;stroke:currentColor;fill:currentColor;transform:rotate(45deg) translate(-1px,1px)}
.voice.playing .bars i{animation:vb .8s ease-in-out infinite alternate}
.voice.playing .bars i:nth-child(2n){animation-delay:-.4s}
@keyframes vb{from{transform:scaleY(.4)}to{transform:scaleY(1.2)}}
.rec{display:flex;flex-direction:column;align-items:center;gap:10px;padding:14px 0 4px}
.recbtn{width:84px;height:84px;border-radius:50%;border:4px solid var(--sheet-line);background:transparent;display:grid;place-items:center;cursor:pointer;padding:0}
.recbtn span{width:56px;height:56px;border-radius:50%;background:var(--danger);transition:all .2s}
.recbtn.on span{width:30px;height:30px;border-radius:8px;animation:pulse 1.2s ease-in-out infinite}
@keyframes pulse{50%{opacity:.6}}
.rect{font:500 22px var(--f-body);font-variant-numeric:tabular-nums;color:var(--sheet-fg)}

/* ---------- 漂流 ---------- */
.drift .bar .ttl.big{flex:1}
.dtabs{display:flex;gap:4px;padding:0 14px 8px;border-bottom:1px solid var(--app-line)}
.dtabs button{flex:1;border:none;background:none;color:var(--app-muted);font:600 14px var(--f-body);padding:8px 0;border-bottom:2px solid transparent;cursor:pointer}
.dtabs button.on{color:var(--app-fg);border-bottom-color:var(--app-fg)}
.dfeed{display:flex;flex-direction:column;gap:10px;padding:10px 0 30px}
.dpost{background:var(--card);border-top:1px solid var(--app-line);border-bottom:1px solid var(--app-line);padding:12px 0 10px;user-select:text;-webkit-user-select:text}
.dpost header{display:flex;align-items:center;gap:10px;padding:0 14px}
.dpost header .av{width:40px;height:40px;font-size:15px}
.dh{flex:1;min-width:0;display:flex;flex-direction:column;cursor:pointer}
.dh b{font-size:14px}
.dh span{font-size:11px;color:var(--app-muted)}
.dtext{padding:10px 14px 4px;font-size:15px;line-height:1.6;white-space:pre-wrap;word-break:break-word}
.dm-media{margin-top:8px;display:flex;overflow-x:auto;scroll-snap-type:x mandatory;scrollbar-width:none;background:#000}
.dm-media::-webkit-scrollbar{display:none}
.dm-media img,.dm-media video{flex:0 0 100%;width:100%;max-height:520px;object-fit:contain;scroll-snap-align:center;max-width:none;display:block;background:#000}
.dm-count{font-size:11px;color:var(--app-muted);text-align:right;padding:4px 14px 0}
.dm-photo{margin:8px 14px 0;border-radius:14px;overflow:hidden;border:1px solid var(--app-line);cursor:pointer}
.dm-photo .ph{aspect-ratio:4/3;background:linear-gradient(150deg,var(--t4),var(--t2) 75%,var(--t1));display:flex;flex-direction:column;gap:6px;align-items:center;justify-content:center;color:rgba(255,255,255,.92);font-size:12px}
.dm-photo .ph svg{width:30px;height:30px;stroke:currentColor;fill:none;stroke-width:1.5}
.dm-photo .ds{display:none;padding:9px 12px;font-size:13px;line-height:1.55}
.dm-photo.open .ds{display:block}
.dact{display:flex;gap:16px;padding:8px 10px 0}
.dact button{border:none;background:none;color:var(--app-fg);display:flex;align-items:center;gap:5px;font:13px var(--f-body);cursor:pointer;padding:4px}
.dact svg{width:22px;height:22px;stroke:currentColor;fill:none;stroke-width:1.7}
.dact button.on{color:var(--danger)}
.dact button.on svg{fill:currentColor}
.dlikes{font-size:13px;font-weight:600;padding:2px 14px 0}
.dcmts{padding:4px 14px 0;display:flex;flex-direction:column;gap:3px}
.dcmts p{margin:0;font-size:13px;line-height:1.5}
.dcmts i,.dc i{font-style:normal;color:var(--app-muted);font-size:12px}
.dcmts .more{border:none;background:none;color:var(--app-muted);font:12px var(--f-body);padding:2px 0;text-align:left;cursor:pointer}
.dwait{font-size:12px;color:var(--app-muted);padding:6px 14px 0}
.dgrid{display:grid;grid-template-columns:repeat(3,1fr);gap:2px;padding:2px 0 30px}
.gi{aspect-ratio:1;border:none;padding:0;position:relative;overflow:hidden;background:var(--app-line);cursor:pointer}
.gi img,.gi video{width:100%;height:100%;object-fit:cover;max-width:none;display:block}
.gi .gt{width:100%;height:100%;display:flex;align-items:center;justify-content:center;padding:8px;font-size:12px;line-height:1.45;color:var(--app-fg);background:var(--card);text-align:left;overflow:hidden}
.gi .gt.ph{flex-direction:column;gap:6px;background:linear-gradient(150deg,var(--t4),var(--t2));color:#fff;font-size:11px;text-align:center}
.gi .gt.ph svg{width:22px;height:22px;stroke:currentColor;fill:none;stroke-width:1.5}
.gi .gv,.gi .gm{position:absolute;top:6px;right:6px;color:#fff;filter:drop-shadow(0 1px 2px rgba(0,0,0,.6))}
.gi .gv svg,.gi .gm svg{width:16px;height:16px;stroke:currentColor;fill:none;stroke-width:1.8}
.dprof{display:flex;align-items:center;gap:22px;padding:14px 20px 8px}
.dprof .av{width:84px;height:84px;font-size:30px}
.dstats{display:flex;gap:26px}
.dstats div{display:flex;flex-direction:column;align-items:center}
.dstats b{font-size:18px;font-variant-numeric:tabular-nums}
.dstats span{font-size:12px;color:var(--app-muted)}
.dbio{margin:0;padding:0 20px 12px;font-size:14px;line-height:1.55;white-space:pre-wrap}
.dall{padding:6px 14px 20px;display:flex;flex-direction:column;gap:14px}
.dc{display:flex;gap:10px}
.dc .av{width:34px;height:34px;font-size:13px}
.dc b{font-size:13px}
.dc p{margin:2px 0;font-size:14px;line-height:1.5;user-select:text}
.dc span{font-size:11px;color:var(--app-muted)}
.dc button{border:none;background:none;color:var(--app-muted);font:600 11px var(--f-body);padding:0;cursor:pointer}
.dpick{display:grid;grid-template-columns:repeat(4,1fr);gap:6px;margin-top:8px}
.dpick .pk{position:relative;aspect-ratio:1;border-radius:10px;overflow:hidden;background:var(--sheet-line)}
.dpick img,.dpick video{width:100%;height:100%;object-fit:cover;max-width:none}
.dpick button{position:absolute;top:3px;right:3px;width:22px;height:22px;border-radius:50%;border:none;background:rgba(0,0,0,.55);color:#fff;font-size:14px;line-height:20px;padding:0;cursor:pointer}

/* ---------- 放映室 ---------- */
.cinema{background:#0d1117;color:#e8edf3}
.cinema .bar{background:#0d1117;color:#e8edf3}
.cinema .bar .btn{color:#e8edf3;border-color:#2a3442}
.cn-stage{background:#000}
.cn-player{aspect-ratio:16/9;width:100%;max-width:100%;position:relative;display:grid;place-items:center}
.cn-player iframe,.cn-player video,.cn-player>div{width:100%;height:100%;border:0}
.cn-player video{background:#000}
.cn-empty{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;color:#9aa6b4;font-size:12px;text-align:center;padding:10px}
.cn-empty svg{width:34px;height:34px;stroke:currentColor;fill:none;stroke-width:1.4}
.cn-empty b{color:#e8edf3;font-size:14px}
.cn-empty .btn{margin-top:6px}
.cn-meta{display:flex;justify-content:space-between;gap:10px;padding:6px 12px;font-size:11px;color:#9aa6b4;background:#0d1117;font-variant-numeric:tabular-nums}
.cn-with{display:flex;align-items:center;gap:10px;padding:8px 12px;border-bottom:1px solid #1d2630;overflow-x:auto}
.cn-with>span{font-size:12px;color:#9aa6b4;flex:none}
.cn-with .chips{flex-wrap:nowrap}
.cn-with .chip{background:#141b24;border-color:#263140;color:#dbe3ec;white-space:nowrap}
.cn-with .chip.on{background:#3d6ca8;border-color:#3d6ca8;color:#fff}
.cn-chat{flex:1;min-height:0;overflow-y:auto;padding:12px;display:flex;flex-direction:column;gap:10px}
.cn-hint{color:#7d8a9a;font-size:13px;text-align:center;margin:auto 10px}
.cn-m{display:flex;flex-direction:column;gap:3px;max-width:86%;user-select:text;-webkit-user-select:text}
.cn-m b{font-size:11px;color:#9aa6b4}
.cn-m span{background:#1a2230;padding:8px 12px;border-radius:14px;font-size:14px;line-height:1.55;white-space:pre-wrap}
.cn-m.me{align-self:flex-end}
.cn-m.me span{background:#3d6ca8;color:#fff}
.cn-m i{font-style:normal;font-size:10px;color:#6f7d8e}
.cinema .composer{background:#0d1117;border-top-color:#1d2630}
.cinema .crow textarea{background:#141b24;border-color:#263140;color:#e8edf3}
.cinema .crow .ib{color:#e8edf3}
.cn-auto{display:flex;align-items:center;gap:6px;font-size:12px;color:#9aa6b4;padding:8px 6px 0}

.photo.real img{width:100%;display:block;max-width:none}
.photo .ph span{font-size:11px;margin-top:6px}
.photo .ph{flex-direction:column;display:flex;align-items:center;justify-content:center}

/* ---------- 宵夜 ---------- */
.shops{padding:4px 14px 90px;display:flex;flex-direction:column;gap:14px}
.shop h3{margin:6px 2px 8px;font-size:14px}
.menu{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
.dish{position:relative;border:1px solid var(--app-line);background:var(--card);color:var(--app-fg);border-radius:14px;padding:12px;text-align:left;display:flex;flex-direction:column;gap:3px;cursor:pointer;font:inherit}
.dish b{font-size:14px}
.dish span{font-size:12px;color:var(--app-muted);font-variant-numeric:tabular-nums}
.dish.on{border-color:var(--t2);box-shadow:inset 0 0 0 1px var(--t2)}
.dish i{position:absolute;top:8px;right:10px;font-style:normal;font-weight:700;color:var(--t2);font-size:13px}
.cartbar{position:absolute;left:12px;right:12px;bottom:calc(14px + env(safe-area-inset-bottom,0px));display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 12px 10px 16px;border-radius:18px;background:var(--app-fg);color:var(--app-bg);box-shadow:0 10px 30px -10px rgba(0,0,0,.4);font-weight:600}
.xfer.food{background:var(--t2)}

/* ---------- 生活 App 共用 ---------- */
.pickc{display:grid;grid-template-columns:repeat(auto-fill,minmax(76px,1fr));gap:10px}
.pickc button{border:none;background:none;display:flex;flex-direction:column;align-items:center;gap:6px;color:var(--sheet-fg);font:12px var(--f-body);cursor:pointer;padding:4px}
.pickc .av{width:56px;height:56px}
.pickc button.on .av{box-shadow:0 0 0 3px var(--t2)}
.fab{position:absolute;right:18px;bottom:calc(22px + env(safe-area-inset-bottom,0px));width:56px;height:56px;border-radius:50%;border:none;background:var(--t1);color:#fff;display:grid;place-items:center;box-shadow:0 10px 24px -8px rgba(0,0,0,.45);cursor:pointer;z-index:3}
.fab svg{width:24px;height:24px;stroke:currentColor;fill:none;stroke-width:1.8}
.up-h{font-size:12px;letter-spacing:.12em;color:var(--app-muted);margin:18px 16px 8px;font-weight:500}
.story{display:flex;flex-direction:column;gap:4px;text-align:left;border:1px solid var(--app-line);background:var(--card);color:var(--app-fg);border-radius:16px;padding:14px;cursor:pointer;font:inherit}
.story b{font-size:15px}
.story span{font-size:12px;color:var(--app-muted)}
.story p{margin:4px 0 0;font-size:13px;line-height:1.55;color:var(--app-fg);opacity:.85}

/* 日子 */
.cal-head{display:flex;align-items:center;justify-content:space-between;padding:6px 10px}
.cal-head b{font-size:16px}
.cal{display:grid;grid-template-columns:repeat(7,1fr);gap:4px;padding:0 12px;text-align:center}
.cal b{font-size:11px;color:var(--app-muted);font-weight:500;padding:4px 0}
.cal button{aspect-ratio:1;border:none;background:none;border-radius:50%;font:14px var(--f-body);color:var(--app-fg);position:relative;cursor:pointer;font-variant-numeric:tabular-nums}
.cal button.today{color:var(--t2);font-weight:700}
.cal button.sel{background:var(--t1);color:#fff}
.cal button.ev::after{content:"";position:absolute;bottom:5px;left:50%;width:4px;height:4px;margin-left:-2px;border-radius:50%;background:var(--danger)}
.cal-day{margin:12px 14px 0;padding:12px 14px;background:var(--card);border:1px solid var(--app-line);border-radius:16px}
.cal-day h3{margin:0;font-size:15px}
.evr{display:flex;gap:10px;align-items:center;padding:9px 0;border-bottom:1px solid var(--app-line);cursor:pointer}
.evr:last-child{border-bottom:none}
.evr i{width:8px;height:8px;border-radius:50%;flex:none}
.evr i.me{background:var(--t3)}.evr i.both{background:var(--danger)}.evr i.his{background:var(--warm)}
.evr div{display:flex;flex-direction:column;min-width:0}
.evr b{font-size:14px;font-weight:500}
.evr span{font-size:12px;color:var(--app-muted)}
.evr .dd{font-size:12px;color:var(--app-muted);width:42px;flex:none;font-variant-numeric:tabular-nums}
.up{margin:0 14px 30px;padding:0 14px;background:var(--card);border:1px solid var(--app-line);border-radius:16px}
.w-cal .g .ev{text-decoration:underline;text-decoration-color:var(--danger);text-underline-offset:2px}

/* 錢包 */
.ledger-sum{display:grid;grid-template-columns:repeat(3,1fr);padding:14px 6px}
.ledger-sum div{display:flex;flex-direction:column;align-items:center;gap:3px}
.ledger-sum span{font-size:11px;color:var(--app-muted)}
.ledger-sum b{font-size:16px;font-variant-numeric:tabular-nums}
.catbar{display:flex;height:10px;border-radius:5px;overflow:hidden;gap:2px}
.catleg{display:flex;flex-wrap:wrap;gap:6px 12px;margin-top:8px;font-size:12px;color:var(--app-muted)}
.catleg i,.catdot{display:inline-block;width:8px;height:8px;border-radius:50%;margin-right:4px;flex:none}

/* 字卡 */
.cards-top{display:flex;flex-direction:column;gap:8px;padding:8px 16px}
.cards-top .chip{align-self:flex-start}
.wcard{margin:14px 22px;padding:30px 24px 18px;border-radius:6px;min-height:180px;display:flex;flex-direction:column;justify-content:space-between;box-shadow:0 14px 30px -14px rgba(0,0,0,.35)}
.wcard p{margin:0;font-family:"Noto Serif TC",var(--f-display),serif;font-size:20px;line-height:1.8;white-space:pre-wrap}
.wcard span{font-size:11px;opacity:.7;text-align:right;margin-top:16px}
.wcard.paper,.cmini.paper{background:#f6f1e7;color:#3b3127}
.wcard.night,.cmini.night{background:#1d2433;color:#e8e2d4}
.wcard.rose,.cmini.rose{background:#f3e1e1;color:#5a3138}
.wcard.sea,.cmini.sea{background:#dde8f0;color:#24384d}
.wcard.film,.cmini.film{background:#2b2622;color:#f0e6d6}
.flip{animation:flip .6s ease}
@keyframes flip{from{transform:rotateY(80deg);opacity:0}}
.cgrid{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;padding:0 14px 30px}
.cmini{aspect-ratio:3/4;border:none;border-radius:6px;padding:10px;font:12px/1.5 "Noto Serif TC",serif;text-align:left;overflow:hidden;cursor:pointer;display:flex}
.cmini span{display:-webkit-box;-webkit-line-clamp:6;-webkit-box-orient:vertical;overflow:hidden}

/* 占卜 */
.spread{display:flex;justify-content:center;gap:10px;flex-wrap:wrap;margin:8px 0}
.ocard{width:94px;aspect-ratio:2/3;border-radius:10px;background:linear-gradient(160deg,var(--t1),#1a1428);color:#f2e8d0;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:8px;text-align:center;animation:deal .5s ease both;box-shadow:0 8px 18px -8px rgba(0,0,0,.5);border:1px solid rgba(242,232,208,.35)}
.ocard i{font-style:normal;font-size:10px;opacity:.7}
.ocard b{font-family:"Noto Serif TC",serif;font-size:15px}
.ocard span{font-size:10px;color:#ffb4a8}
.ocard.rev b{transform:rotate(180deg)}
.ocard.oracle{background:linear-gradient(160deg,#6f5b7d,#2e2540)}
.ocard.dice{background:linear-gradient(160deg,#28507f,#0f1c2e)}
@keyframes deal{from{transform:translateY(20px) rotate(-6deg);opacity:0}}
.oread{background:var(--card);border:1px solid var(--app-line);border-radius:16px;padding:14px;font-size:14px;line-height:1.75;white-space:pre-wrap;user-select:text;-webkit-user-select:text}

/* 我們 */
.us-head{display:flex;flex-direction:column;align-items:center;gap:6px;padding:4px 0 12px}
.pair{display:flex;align-items:center;gap:14px}
.pair .av{width:58px;height:58px}
.hrt svg{width:24px;height:24px;fill:var(--danger);stroke:var(--danger)}
.days{font-size:13px;color:var(--app-muted);cursor:pointer}
.days b{font-family:var(--f-display);font-size:34px;color:var(--app-fg);font-weight:400}
.letter{display:flex;flex-direction:column;gap:3px;text-align:left;border:none;background:#f6f1e7;color:#3b3127;border-radius:4px;padding:14px 16px;cursor:pointer;font:inherit;box-shadow:0 6px 16px -10px rgba(0,0,0,.4)}
.letter.mine{background:#e6eef5;color:#24384d}
.letter b{font-family:"Noto Serif TC",serif;font-size:16px}
.letter span{font-size:11px;opacity:.65}
.letter p{margin:4px 0 0;font-size:13px;line-height:1.6;opacity:.85}
.letter-full{background:#f6f1e7;color:#3b3127;border-radius:6px;padding:20px 18px;font-family:"Noto Serif TC",serif}
.letter-full h2{color:#3b3127}
.letter-full p{color:#3b3127!important;font-size:16px!important;line-height:2!important;white-space:pre-wrap}
.letter-full span{display:block;text-align:right;font-size:12px;opacity:.7;margin-top:10px}
.dday h3{margin:16px 4px 6px}
.dent{background:var(--card);border:1px solid var(--app-line);border-radius:14px;padding:10px 12px;margin-bottom:6px}
.dent.his{border-left:3px solid var(--warm)}
.dent b{font-size:12px;color:var(--app-muted)}
.dent p{margin:4px 0 0;font-size:14px;line-height:1.65;white-space:pre-wrap;user-select:text}
.focus{display:flex;flex-direction:column;align-items:center;gap:14px;padding:24px 20px}
.focus .ring{width:200px;height:200px;border-radius:50%;border:6px solid var(--app-line);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px}
.focus .ring.on{border-color:var(--t2);animation:pulse 3s ease-in-out infinite}
.focus .ring b{font-family:var(--f-display);font-size:48px;font-weight:400;font-variant-numeric:tabular-nums}
.focus .ring span{font-size:12px;color:var(--app-muted)}
.fmsg{font-size:15px;text-align:center;line-height:1.6;min-height:24px;margin:0}

/* 他的手機 */
.his-body{background:#0f1218;color:#e6eaf0}
.app-his .bar{background:#0f1218;color:#e6eaf0}
.app-his .bar .btn{color:#e6eaf0;border-color:#2a303a}
.his-lock{padding:16px}
.hw{aspect-ratio:3/2;border-radius:18px;background:linear-gradient(160deg,#3a4a66,#141a24);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;padding:16px;text-align:center;font-size:12px;color:#c9d2de}
.hw svg{width:26px;height:26px;stroke:currentColor;fill:none;stroke-width:1.4}
.his-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:14px;margin:18px 0}
.his-grid button{border:none;background:none;color:#e6eaf0;display:flex;flex-direction:column;align-items:center;gap:6px;font:12px var(--f-body);cursor:pointer}
.his-grid span{width:56px;height:56px;border-radius:16px;background:#1d2430;display:grid;place-items:center}
.his-grid svg{width:24px;height:24px;stroke:currentColor;fill:none;stroke-width:1.6}
.his-list{padding:0 14px 30px;display:flex;flex-direction:column;gap:8px}
.hrow{display:flex;flex-direction:column;gap:3px;text-align:left;border:none;background:#171c25;color:#e6eaf0;border-radius:12px;padding:12px;cursor:pointer;font:inherit}
.hrow.static{flex-direction:row;align-items:center;gap:10px;cursor:default}
.hrow b{font-size:14px}.hrow b.miss{color:#ff8a7a}
.hrow span{font-size:12px;color:#97a1ae}
.hrow svg{width:16px;height:16px;stroke:#97a1ae;fill:none;stroke-width:1.7;flex:none}
.hnote{background:#f3eed8;color:#3a352a;border-radius:10px;padding:12px}
.hnote b{font-size:14px}.hnote p{margin:6px 0 0;font-size:13px;line-height:1.6;white-space:pre-wrap}
.hphotos{display:grid;grid-template-columns:repeat(2,1fr);gap:8px}
.hp{background:#171c25;border-radius:12px;overflow:hidden}
.hp .ph{aspect-ratio:1;background:linear-gradient(150deg,#3d6ca8,#1b3557);display:grid;place-items:center;color:#cfe0f5}
.hp .ph svg{width:24px;height:24px;stroke:currentColor;fill:none;stroke-width:1.4}
.hp p{margin:0;padding:8px 10px 2px;font-size:12px;line-height:1.5}
.hp span{display:block;padding:0 10px 8px;font-size:10px;color:#97a1ae}
.hconv{display:flex;flex-direction:column;gap:6px}
.hconv div{display:flex}.hconv div.me{justify-content:flex-end}
.hconv span{background:var(--sheet-line);color:var(--sheet-fg);padding:7px 11px;border-radius:14px;font-size:14px;max-width:80%}
.hconv div.me span{background:var(--t2);color:#fff}

/* 樹洞 */
.reader{padding:10px 22px 40px;font-family:"Noto Serif TC",serif;user-select:text;-webkit-user-select:text}
.reader h2{font-size:18px;margin:26px 0 12px}
.reader p{font-size:16px;line-height:2;margin:0 0 1em;text-indent:2em}

/* 唱片 */
.player{display:flex;flex-direction:column;align-items:center;gap:6px;padding:10px 24px 4px}
.player .cover{width:210px;height:210px;border-radius:50%;background:radial-gradient(circle,#222 30%,#111 31%,#1b1b1b 60%,#0b0b0b);display:grid;place-items:center;overflow:hidden;box-shadow:0 14px 30px -12px rgba(0,0,0,.6);color:#888}
.player .cover img{width:100%;height:100%;object-fit:cover;max-width:none}
.player .cover svg{width:40%;height:40%;stroke:currentColor;fill:none;stroke-width:1.2}
.player .cover.spin{animation:spin 18s linear infinite}
.player b{font-size:18px;margin-top:10px;text-align:center}
.player>span{font-size:13px;color:var(--app-muted)}
.player input[type=range]{width:100%;accent-color:var(--t2)}
.ptime{width:100%;display:flex;justify-content:space-between;font-size:11px;color:var(--app-muted);font-variant-numeric:tabular-nums}
.pbtns{display:flex;align-items:center;gap:14px}
.pbtns .big{width:62px;height:62px;border-radius:50%;background:var(--t1);color:#fff}
.pbtns .big svg{width:26px;height:26px;stroke:none}
.lyrics{height:180px;overflow-y:auto;margin:10px 16px;text-align:center;scroll-behavior:smooth;mask-image:linear-gradient(transparent,#000 20%,#000 80%,transparent)}
.lyrics p{margin:8px 0;font-size:14px;color:var(--app-muted);transition:all .2s}
.lyrics p.on{color:var(--app-fg);font-size:16px;font-weight:600}
.plist{display:flex;flex-direction:column;padding:0 14px 30px;gap:6px}
.plist button{display:grid;grid-template-columns:1fr auto;grid-template-rows:auto auto;column-gap:10px;text-align:left;border:1px solid var(--app-line);background:var(--card);color:var(--app-fg);border-radius:12px;padding:10px 12px;cursor:pointer;font:inherit}
.plist button.on{border-color:var(--t2)}
.plist b{font-size:14px}.plist span{font-size:12px;color:var(--app-muted)}
.plist i{grid-row:1/3;grid-column:2;align-self:center;font-style:normal;font-size:12px;color:var(--t2)}
.flyric{position:absolute;left:50%;top:calc(var(--sb) + 40px);transform:translateX(-50%);z-index:85;max-width:88%;display:flex;gap:8px;align-items:center;padding:7px 14px;border-radius:999px;background:rgba(15,20,28,.72);color:#fff;backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);font-size:13px;box-shadow:0 6px 18px -6px rgba(0,0,0,.4);touch-action:none;cursor:grab}
.flyric b{font-weight:500;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.lnk.music{cursor:pointer}

/* 遊戲室 */
.game{background:var(--app-bg)}
.game .cn-m span{background:var(--card);color:var(--app-fg);border:1px solid var(--app-line)}
.game .cn-m.me span{background:var(--t1);color:#fff;border:none}
.game .cn-m b{color:var(--app-muted)}
.dicebox{display:flex;flex-direction:column;align-items:center;gap:10px;padding:14px 14px calc(18px + env(safe-area-inset-bottom,0px));border-top:1px solid var(--app-line)}
.dscore{font-size:15px;font-weight:600;font-variant-numeric:tabular-nums}
.app-game .cn-m span{font-size:15px}

/* ---------- 用量與花費 ---------- */
.usage-big{display:flex;flex-direction:column;gap:4px;margin-top:10px;padding:14px;border-radius:14px;background:var(--app-soft,rgba(127,127,127,.08))}
.usage-big span{font-size:12px;color:var(--app-muted)}
.usage-big b{font-family:var(--f-display);font-size:34px;line-height:1.1;font-variant-numeric:tabular-nums}
.usage-big i,.ledger-sum i{font-style:normal;font-size:11px;color:var(--app-muted);text-align:center;line-height:1.4}
.usage-big i{text-align:left}
.usage-pr{display:flex;gap:8px;margin-top:6px}
.usage-pr label{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px}
.usage-pr span{font-size:11px;color:var(--app-muted)}
.usage-pr input{width:100%}

/* ---------- 通話 App ---------- */
.clist{display:flex;flex-direction:column;padding:4px 0}
.crow2{display:flex;align-items:center;gap:12px;padding:10px 16px;border-bottom:1px solid var(--app-line,rgba(127,127,127,.15));cursor:pointer}
.crow2 .av{width:44px;height:44px;flex:none}
.crow2 .cm{flex:1;min-width:0;display:flex;flex-direction:column;gap:2px}
.crow2 .cm b{font-size:15px;font-weight:600}
.crow2 .cm b.miss{color:var(--danger)}
.crow2 .cm span{font-size:12px;color:var(--app-muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.crow2 .ct{font-size:11px;color:var(--app-muted);flex:none}
.crow2 .ib.cgo{color:var(--ok)}

/* ---------- 小鋪 ---------- */
.shop-top{padding:10px 14px 4px}
.shop-top .chips{flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none}
.shop-top .chips::-webkit-scrollbar{display:none}
.sgrid{display:grid;grid-template-columns:1fr 1fr;gap:10px;padding:10px 14px 14px}
.sitem{display:flex;flex-direction:column;gap:4px;text-align:left;padding:0 0 10px;border-radius:14px;overflow:hidden;background:var(--app-card,#fff);border:1px solid var(--app-line,rgba(127,127,127,.15));color:inherit;font:inherit;cursor:pointer}
.sitem .sic{aspect-ratio:1.3;display:grid;place-items:center;color:rgba(255,255,255,.85)}
.sitem .sic svg{width:34px;height:34px}
.sitem .sic.c0{background:var(--t1)}.sitem .sic.c1{background:var(--t2)}.sitem .sic.c2{background:var(--t3)}.sitem .sic.c3{background:var(--t4)}
.sitem b{font-size:13px;font-weight:600;padding:0 10px;line-height:1.35}
.sitem span{font-size:11px;color:var(--app-muted);padding:0 10px;line-height:1.4;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.sitem i{font-style:normal;font-size:14px;font-weight:600;padding:0 10px;font-variant-numeric:tabular-nums}
.xfer.parcel{background:var(--t1)}
.unbox{text-align:center;padding:10px 0}
.unbox>svg{width:48px;height:48px;color:var(--t2)}
.shop-top .chip{flex:none;white-space:nowrap}
.sitem .sic svg,.unbox>svg{fill:none;stroke:currentColor;stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}

/* ---------- 世界書（SillyTavern 風格） ---------- */
.wi-dot{display:inline-block;width:9px;height:9px;border-radius:50%;flex:none;margin-right:6px;vertical-align:middle}
.wi-dot.b{background:#3B82F6}.wi-dot.g{background:#22A06B}
.wi-row{gap:4px}
.wi-row .lb.link{cursor:pointer}
.wi-row.off .lb{opacity:.45}
.wi-adv{margin-top:12px}
.wi-adv summary{cursor:pointer;font-size:13px;color:var(--sheet-muted,var(--app-muted));padding:6px 2px}
.wi-ed .fi.col .sub,.wi-adv .sub{font-size:11px}

/* ---------- 跨國轉帳 ---------- */
.xfer .fxl{font-size:11px;opacity:.85;margin-top:3px}
.fx-rate{display:flex;align-items:baseline;gap:10px}
.fx-rate b{font-family:var(--f-display);font-size:22px;font-variant-numeric:tabular-nums}
.fx-rate .up{color:#D9534F;font-size:12px}.fx-rate .dn{color:#22A06B;font-size:12px}
.fx-demo{display:flex;flex-direction:column;gap:3px;margin:12px 0 4px;padding:12px 14px;border-radius:14px;background:var(--app-soft,rgba(127,127,127,.08))}
.fx-demo span{font-size:12px;opacity:.7}
.fx-demo b{font-size:20px;font-variant-numeric:tabular-nums}
.fx-demo i{font-style:normal;font-size:12px;opacity:.7}

/* ---------- 記憶互通／頭像圖庫 ---------- */
.ml-row .av{width:36px;height:36px;flex:none}
.ml-opt{margin-top:8px;gap:8px;flex-wrap:wrap;align-items:center}
.avgal{display:grid;grid-template-columns:repeat(3,1fr);gap:10px;margin-top:12px}
.avg{display:flex;flex-direction:column;gap:6px;padding:8px;border-radius:14px;background:var(--app-card,#fff);border:1.5px solid transparent}
.avg.on{border-color:var(--t2)}
.avg img{width:100%;aspect-ratio:1;object-fit:cover;border-radius:50%}
.avg input{font-size:12px;padding:6px 8px;text-align:center}
.avg .row{justify-content:space-between;flex-wrap:nowrap;gap:4px}
.avg .btn{font-size:11px;padding:5px 8px;flex:1}
.avg .ib{width:28px;height:28px}
.avg.add{align-items:center;justify-content:center;min-height:150px;border:1.5px dashed var(--app-line,rgba(127,127,127,.3));background:none;color:var(--app-muted);font:inherit;cursor:pointer}
.avg.add svg{width:28px;height:28px;fill:none;stroke:currentColor;stroke-width:1.6}

/* ---------- 心聲 ---------- */
.chat .who .s{cursor:pointer}
.ivbtn{color:#D9677A}
.ivbtn.new::after{content:"";position:absolute;top:9px;right:9px;width:7px;height:7px;border-radius:50%;background:#D9677A}
.ivbtn{position:relative}
.ivs{margin-top:10px;padding:12px 14px;border-radius:14px;background:var(--sheet-soft,rgba(127,127,127,.08))}
.ivs b,.ivf b{font-size:12px;color:var(--sheet-muted)}
.ivs p,.ivf p{margin:3px 0 0;line-height:1.6;white-space:pre-wrap}
.ivs span{font-size:11px;color:var(--sheet-muted)}
.ivc{display:flex;flex-direction:column;gap:10px;padding:12px 14px;border-radius:14px;background:linear-gradient(135deg,rgba(217,103,122,.10),rgba(127,127,127,.06))}
.ivh{margin-top:14px}
.ivh summary{cursor:pointer;font-size:13px;color:var(--sheet-muted)}
.ivold{margin-top:10px}
.ivold>span{font-size:11px;color:var(--sheet-muted)}

/* ---------- 聊天氣泡設定 ---------- */
.bubble-demo{position:relative;width:64px;height:64px;margin:18px auto 10px}
.bubble-demo .av{width:64px;height:64px;border-radius:50%;font-size:24px;box-shadow:0 8px 20px -6px rgba(0,0,0,.4)}
.bubble-demo span{position:absolute;top:-2px;right:-4px;min-width:20px;height:20px;border-radius:10px;background:#E5484D;color:#fff;font-size:11px;font-weight:700;display:grid;place-items:center;border:2px solid #fff;padding:0 4px}
.his-pick{padding:30px 18px;text-align:center}.his-pick p{margin:0 0 16px;color:#aab3c0}.his-pick .pickc button{color:#e6eaf0}

/* ---------- 情侶空間 ---------- */
.cp-head{display:flex;flex-direction:column;align-items:center;gap:6px;padding:6px 16px 12px;background:var(--app-bg)}
.cp-head .pair{display:flex;align-items:center;gap:10px}
.cp-head .pair .av{width:52px;height:52px}
.cp-head .hrt svg{width:22px;height:22px;fill:#E5677D;stroke:#E5677D}
.cp-days{font-size:13px;color:var(--app-muted);cursor:pointer}.cp-days b{font-family:var(--f-display);font-size:24px;color:var(--app-fg);margin:0 2px}
.cp-board{padding:12px;display:flex;flex-direction:column;gap:12px}
.cp-compose{background:var(--app-card,#fff);border-radius:18px;padding:12px}
.cp-compose textarea{width:100%;border:none;background:transparent;resize:none;font:inherit;color:inherit;outline:none}
.cp-post{background:var(--app-card,#fff);border-radius:18px;padding:12px 14px}
.cp-post header{display:flex;align-items:center;gap:10px}
.cp-post header .av{width:36px;height:36px}
.cp-post header div{flex:1;display:flex;flex-direction:column}
.cp-post header b{font-size:14px}.cp-post header span{font-size:11px;color:var(--app-muted)}
.cp-text{margin:10px 2px;line-height:1.7;white-space:pre-wrap;font-size:15px}
.cp-acts{display:flex;align-items:center;gap:12px}
.cp-acts button{display:flex;align-items:center;gap:4px;border:none;background:none;color:var(--app-muted);font:inherit;font-size:13px;cursor:pointer;padding:4px}
.cp-acts button svg{width:18px;height:18px;fill:none;stroke:currentColor;stroke-width:1.8}
.cp-acts button.on{color:#E5677D}.cp-acts button.on svg{fill:#E5677D;stroke:#E5677D}
.cp-cmts{margin-top:6px;padding:8px 10px;border-radius:12px;background:var(--app-bg);font-size:13px;line-height:1.6}
.cp-cmts p{margin:2px 0}
.cp-reply{display:flex;gap:6px;margin-top:8px;align-items:center}
.cp-reply input{flex:1;min-width:0;font-size:13px;padding:8px 12px;border-radius:999px}
.cp-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:3px;padding:0 3px}
.cp-ph{position:relative;aspect-ratio:1;border:none;padding:0;background:var(--app-card,#ddd);overflow:hidden;cursor:pointer}
.cp-ph img{width:100%;height:100%;object-fit:cover;display:block}
.cp-ph i{position:absolute;right:5px;bottom:5px;font-style:normal;font-size:11px;background:rgba(0,0,0,.55);color:#fff;border-radius:10px;padding:1px 7px}
.cp-noimg{width:100%;height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:6px;padding:8px;background:linear-gradient(135deg,var(--t3),var(--t2));color:#fff;font-size:11px;text-align:center}
.cp-noimg svg{width:24px;height:24px;fill:none;stroke:currentColor;stroke-width:1.6}
.cp-noimg.big{aspect-ratio:4/3;font-size:14px;padding:24px}
.cp-big{width:100%;display:block}
.cp-story{padding:14px 16px;border-bottom:1px solid var(--app-line)}
.cp-story span{font-size:12px;color:var(--app-muted)}.cp-story p{margin:6px 0 0;line-height:1.7;white-space:pre-wrap}
.cp-cmts.big{background:none;padding:10px 16px;display:flex;flex-direction:column;gap:12px}
.cp-c{display:flex;gap:10px}.cp-c .av{width:32px;height:32px;flex:none}
.cp-c b{font-size:13px}.cp-c p{margin:2px 0;font-size:14px;line-height:1.6}.cp-c span{font-size:11px;color:var(--app-muted)}
.cp-prev{display:flex;gap:6px;overflow-x:auto}.cp-prev img{width:90px;height:90px;object-fit:cover;border-radius:10px;flex:none}
.tl{padding:6px 16px 20px}
.tl-i{display:grid;grid-template-columns:48px 16px 1fr;gap:8px;position:relative}
.tl-t{font-size:12px;color:var(--app-muted);padding-top:2px;font-variant-numeric:tabular-nums;text-align:right}
.tl-d{position:relative}.tl-d::before{content:"";position:absolute;left:7px;top:0;bottom:0;width:2px;background:var(--app-line)}
.tl-d::after{content:"";position:absolute;left:3px;top:4px;width:10px;height:10px;border-radius:50%;background:var(--t2);box-shadow:0 0 0 3px var(--app-bg)}
.tl-c{padding-bottom:18px}.tl-c b{font-size:14px;font-weight:600}
.tl-c span{display:flex;align-items:center;gap:3px;font-size:12px;color:var(--app-muted);margin-top:2px}
.tl-c span svg{width:12px;height:12px;fill:none;stroke:currentColor;stroke-width:2}
.tl-c p{margin:6px 0 0;font-size:13px;line-height:1.6;padding:8px 10px;border-radius:10px;background:var(--app-card,#fff);font-style:italic}
.cp-modes{display:grid;grid-template-columns:repeat(3,1fr);gap:8px;padding:12px}
.cp-modes button{display:flex;flex-direction:column;align-items:center;gap:4px;padding:14px 6px;border:none;border-radius:16px;background:var(--app-card,#fff);color:inherit;font:inherit;cursor:pointer}
.cp-modes span{width:40px;height:40px;border-radius:50%;display:grid;place-items:center;background:var(--t1);color:#fff}
.cp-modes span svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:1.7}
.cp-modes b{font-size:13px}.cp-modes i{font-style:normal;font-size:10px;color:var(--app-muted);text-align:center}
.ck{margin:12px;padding:12px 14px;border-radius:16px;position:relative}
.ck-time{display:block;font-size:11px;opacity:.6;margin-bottom:6px}
.ck.cam{background:#101418;color:#d8e0e8;font-family:ui-monospace,monospace}
.ck.cam .ck-rec{color:#ff5a5f;font-size:12px;letter-spacing:.06em;margin-bottom:8px}
.ck.cam img{width:100%;border-radius:8px;filter:saturate(.7) contrast(1.05);margin-bottom:8px}
.ck.cam p{font-family:var(--f-body);line-height:1.7;margin:0 0 8px}
.ck.cam dl{display:grid;grid-template-columns:40px 1fr;gap:4px 8px;margin:0;font-family:var(--f-body);font-size:13px}
.ck.cam dt{opacity:.55}.ck.cam dd{margin:0}
.ck.cam .btn{margin-top:10px;color:#d8e0e8;border-color:#333b44}
.ck.pc{background:var(--app-card,#fff)}
.pc-screen{background:#1d2330;border-radius:10px;padding:8px;color:#e6eaf0;font-size:12px;display:flex;flex-direction:column;gap:6px}
.pc-tabs{display:flex;gap:4px;overflow-x:auto}.pc-tabs span{flex:none;max-width:140px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;background:#2c3445;padding:4px 8px;border-radius:6px 6px 0 0;font-size:11px}
.pc-win{background:#f4f6f9;color:#1f2b3a;border-radius:8px;overflow:hidden}
.pc-tb{display:flex;align-items:center;gap:4px;padding:5px 8px;background:#dfe4ea;font-size:11px}
.pc-tb i{width:8px;height:8px;border-radius:50%;background:#ff5f57}.pc-tb i+i{background:#febc2e}.pc-tb i+i+i{background:#28c840}
.pc-tb b{margin-left:4px}
.pc-win p{margin:0;padding:8px 10px;line-height:1.6;font-size:12px;white-space:pre-wrap}
.pc-typing{background:#2c3445;padding:8px 10px;border-radius:8px}.pc-typing .cur{animation:blink 1s steps(1) infinite}
@keyframes blink{50%{opacity:0}}
.pc-music{opacity:.75;font-size:11px}
.ck.bag{background:var(--app-card,#fff)}
.ck.bag ul{margin:8px 0;padding-left:18px;line-height:1.8;font-size:14px}
.ck-secret{padding:10px 12px;border-radius:12px;background:rgba(229,103,125,.1);font-size:13px}
.cp-choose{display:flex;flex-direction:column;align-items:center;text-align:center;padding:40px 22px;gap:10px}
.cp-choose>svg{width:54px;height:54px;fill:none;stroke:var(--t2);stroke-width:1.4}
.cp-choose p{color:var(--app-muted);font-size:13px;line-height:1.7;margin:0 0 10px}
/* ---------- 查崗 ---------- */
.pk-who{display:flex;gap:10px;overflow-x:auto;padding:4px 14px 10px;background:var(--app-bg);scrollbar-width:none}
.pk-who::-webkit-scrollbar{display:none}
.pk-who button{flex:none;display:flex;flex-direction:column;align-items:center;gap:4px;border:none;background:none;color:var(--app-muted);font:inherit;font-size:11px;cursor:pointer;opacity:.55}
.pk-who button .av{width:46px;height:46px}
.pk-who button.on{opacity:1;color:var(--app-fg)}.pk-who button.on .av{box-shadow:0 0 0 2px var(--app-bg),0 0 0 4px var(--t2)}
.pk-tip{margin:12px 14px 0;font-size:12px;color:var(--app-muted)}
