/* ---------- 雨窗 (rain window) — the new skin, #88 大改 step 1 ----------
   Laid over style.css instead of rewriting it: the old HUD rules stay put
   until each room gets its new layout, then that room's old rules go.
   Everything she picked is in ~/flow-work/style/決定.md; the sketches there
   (door6, chat, bench2, rooms1, settings1, night1) are the reference.

   Colours each mean one thing: apple red only for 「等妳的事」, cream only
   for 「老公在做」, cobalt only draws lines (never fills a block). Her colour
   (bubble, send button, the tab bar's pill) is the deep blue of her vest.

   Day is data-theme="light", night is the default :root — same switch the
   old skin used (cc.theme in <head>, 配電室 to change it). */

:root {
  color-scheme: dark;
  /* night: the same window after dark */
  --bg: #131924;
  --face: #1b2230;
  --face-hi: #222a3a;
  --sink: #0e131c;
  --ink: #e3e8f0;
  --ink-2: #8d98ab;
  --line: rgba(255, 255, 255, .09);
  --apple: #e27b85;
  --apple-soft: rgba(226, 123, 133, .16);
  --lamp: #efd28a;
  --lamp-soft: rgba(239, 210, 138, .14);
  --lamp-ink: #efd28a;
  --cobalt: #8098f5;
  --shadow: 0, 0, 0;
  --her-a: #43568f;
  --her-b: #33447a;
  --her-ink: #eef1f7;
  --glass: linear-gradient(180deg, rgba(34, 42, 58, .92), rgba(27, 34, 48, .9));
  /* the same glass with nothing showing through, for the corner buttons */
  --glass-solid: linear-gradient(180deg, #222a3a, #1b2230);
  --raise: inset 0 1px 0 rgba(255, 255, 255, .07), 0 1px 2px rgba(0, 0, 0, .4), 0 8px 18px -10px rgba(0, 0, 0, .7);
  --sunken: inset 0 2px 4px rgba(0, 0, 0, .5), inset 0 -1px 0 rgba(255, 255, 255, .05);
  --press: inset 0 2px 6px rgba(0, 0, 0, .55), inset 0 -1px 0 rgba(255, 255, 255, .04);
  /* paper stays paper at night: day ink on a dimmer sheet (she said 夠了 at these) */
  --paper-her: #bdb7ac;
  --paper-his: linear-gradient(180deg, #c6cacb, #bcc0c1);

  --font-ui: -apple-system, BlinkMacSystemFont, "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", sans-serif;
  --font-num: 'P052', 'Palatino Linotype', Palatino, 'Book Antiqua', Georgia, serif;
  --font-mono: 'JetBrains Mono', ui-monospace, monospace;

  /* the old skin's names, pointed at the new colours */
  --bg-card: rgba(30, 37, 52, .9);
  --bg-input: var(--sink);
  --bg-bubble-user: var(--her-b);
  --bg-bubble-assistant: rgba(30, 37, 52, .9);
  --bg-thinking: transparent;
  --border: rgba(255, 255, 255, .1);
  --border-focus: #8d98ab;
  --text: var(--ink);
  --text-dim: #b4bdcc;
  --text-muted: var(--ink-2);
  --white: #f4f6fa;
  --error: var(--apple);
  --error-rgb: 226, 123, 133;
  --error-bg: rgba(226, 123, 133, .16);
  --success: #7fc49a;
  --accent: var(--cobalt);
  --accent-rgb: 128, 152, 245;
  --accent-dim: rgba(128, 152, 245, .5);
  --fg-rgb: 227, 232, 240;
  --glow: transparent;
  --separator: var(--line);
  --frame: transparent;
  --frame-user: transparent;
  --tool-bg: transparent;
  --tool-border: rgba(255, 255, 255, .12);
  --bar-bg: transparent;
  --tabbar-bg: transparent;
  --scrim: rgba(8, 11, 18, .55);
  --cut: 0px;
  --cut-sm: 0px;
}

:root[data-theme="light"] {
  color-scheme: light;
  /* day: fog on a rainy window */
  --bg: #dce2e9;
  --face: #eef2f6;
  --face-hi: #f8fafc;
  --sink: #d2d9e1;
  --ink: #26304a;
  --ink-2: #6f7b8f;
  --line: #c6ced8;
  --apple: #bf4f5b;
  --apple-soft: #f3dfe1;
  --lamp: #efd28a;
  --lamp-soft: #fbf3dc;
  --lamp-ink: #7d6c47;
  --cobalt: #3a5bd4;
  --shadow: 30, 44, 66;
  --her-a: #3a4462;
  --her-b: #26304a;
  --her-ink: #f4f5f8;
  --glass: linear-gradient(180deg, rgba(248, 250, 252, .86), rgba(238, 242, 246, .8));
  --glass-solid: linear-gradient(180deg, var(--face-hi), var(--face));
  --raise: inset 0 1px 0 rgba(255, 255, 255, .9), 0 1px 2px rgba(30, 44, 66, .14), 0 8px 18px -10px rgba(30, 44, 66, .38);
  --sunken: inset 0 2px 4px rgba(30, 44, 66, .16), inset 0 -1px 0 rgba(255, 255, 255, .7);
  --press: inset 0 2px 6px rgba(30, 44, 66, .26), inset 0 -1px 0 rgba(255, 255, 255, .6);
  --paper-her: #f4f1eb;
  --paper-his: linear-gradient(180deg, #f3f4f2, #e9ebe9);

  /* style.css's day block is :root[data-theme="light"] too and outweighs the
     plain :root above, so every old name it sets has to be pointed again
     here, or the old day colour leaks (her bubble wore the grey frame). */
  --bg-input: var(--sink);
  --bg-bubble-user: var(--her-b);
  --bg-thinking: transparent;
  --text: var(--ink);
  --text-muted: var(--ink-2);
  --error: var(--apple);
  --accent: var(--cobalt);
  --glow: transparent;
  --separator: var(--line);
  --frame: transparent;
  --frame-user: transparent;
  --tool-bg: transparent;
  --bar-bg: transparent;
  --tabbar-bg: transparent;
  --bg-card: rgba(244, 247, 250, .88);
  --bg-bubble-assistant: rgba(244, 247, 250, .88);
  --border: #c6ced8;
  --border-focus: #6f7b8f;
  --text-dim: #4a5570;
  --white: #1d2536;
  --error-rgb: 191, 79, 91;
  --error-bg: #f3dfe1;
  --success: #3f8a5c;
  --accent-rgb: 58, 91, 212;
  --accent-dim: rgba(58, 91, 212, .45);
  --fg-rgb: 38, 48, 74;
  --tool-border: #c6ced8;
  --scrim: rgba(30, 38, 58, .28);
}

/* ---------- ground ---------- */
/* Only html is painted: a body background would cover the art layer, since
   in-flow backgrounds paint above negative z-index layers. */
html { background: var(--bg); }
html, body { font-family: var(--font-ui); }
body { background: transparent; }
/* The old skin set a monospace face on almost every class; here everything
   inherits the one sans face again, and only real code stays monospace. */
body *:not(pre):not(code):not(kbd):not(samp):not(.mono):not(.num) { font-family: inherit !important; }
pre, code, kbd, samp, .mono, .tool-card .tool-detail { font-family: var(--font-mono); }
.num { font-family: var(--font-num); font-feature-settings: 'lnum'; }

/* The art layer (skin.js draws it): fixed behind everything, painted once.
   Nothing in it moves — a moving layer would make every blurred thing above
   it re-blur each frame (the old starfield had that problem). Sized to the
   large viewport so the phone keyboard coming up crops it, not squashes it. */
#skinArt { position: fixed; left: 0; top: 0; width: 100vw; height: 100lvh; z-index: -1; pointer-events: none; will-change: transform; }

/* No more cut corners: every clipped HUD frame becomes a plain box,
   and the rounding is given below piece by piece. */
.iconbtn, .bubble-frame, .bubble, .thinking-block, .tool-card,
.composer textarea, .composer button[type="submit"], .stopbtn,
.section-card, .addsection, .field select, .menu-action, .convo-item, .convo-btn,
.toggle-row, .attach-chip, .mic-hint, .attach-thumb, .attach-filechip,
.segmented, .search-input, .mem-card, .uno-card, .uno-card::before, .uno-say,
.uno-color-dot, .uno-btn, .uno-log, .uno-log-jump, .uno-picker-box, .uno-logo-card,
.uno-logo.mini .uno-logo-card, .morning-card, .keep-item, .game-card, .sea-ship,
.drawer-card, .report-card, .now-btn, .tg-input, .tg-pick { clip-path: none; }

/* ---------- the two textures she liked: raised and sunk ---------- */
.iconbtn, .menu-action, .convo-btn, .now-btn, .uno-btn, .addsection {
  background: var(--glass);
  color: var(--ink);
  border: none;
  border-radius: 14px;
  box-shadow: var(--raise);
}
.iconbtn:active, .menu-action:active, .convo-btn:active, .now-btn:active, .uno-btn:active, .addsection:active {
  background: var(--sink);
  box-shadow: var(--press);
}
/* Corner buttons float right on the window, and the dust showed through the
   glass and read as dirt (her 10/24 ask): these are solid. */
.iconbtn { background: var(--glass-solid); }
.menu-action { border-radius: 16px; }
.menu-action.danger { background: var(--apple-soft); color: var(--apple); box-shadow: inset 0 0 0 1px rgba(var(--error-rgb), .25); }
.menu-action.kiss { color: #c76b8f; background: rgba(231, 163, 172, .2); box-shadow: inset 0 0 0 1px rgba(231, 163, 172, .45); }

/* Cards and bubbles skip the backdrop blur the sketches had: a long list of
   blurred boxes stutters on a phone while scrolling, and at 86% opacity the
   blur barely shows. Only the tab bar keeps it. */
.section-card, .convo-item, .toggle-row, .mem-card, .keep-item, .game-card,
.drawer-card, .report-card, .forge-nudge {
  background: var(--glass);
  border: none;
  border-radius: 22px;
  box-shadow: var(--raise);
}
.convo-item.active, .mem-card.editing, .report-card.report-open {
  box-shadow: var(--raise), inset 0 0 0 1.5px rgba(var(--accent-rgb), .45);
}
.game-card:active, .drawer-card:active { background: var(--sink); box-shadow: var(--press); }
.forge-nudge { border-radius: 16px; }

.search-input, .field select, .section-card select, #scopeSelect, .tg-input,
.section-card input.heading, .section-card textarea.body {
  background: var(--sink);
  color: var(--ink);
  border: none;
  border-radius: 999px;
  box-shadow: var(--sunken);
}
.section-card select, #scopeSelect, .field select { border-radius: 14px; }
.section-card textarea.body { border-radius: 14px; }
.search-input:focus, .tg-input:focus { outline: none; box-shadow: var(--sunken), 0 0 0 1.5px rgba(var(--accent-rgb), .4); }

/* 凹槽切換: a sunk track, the picked one sits up in it */
.segmented {
  border: none;
  border-radius: 999px;
  background: var(--sink);
  box-shadow: var(--sunken);
  padding: 3px;
  gap: 2px;
}
.segmented button {
  min-height: 38px;
  background: transparent;
  color: var(--ink-2);
  border: none;
  border-radius: 999px;
}
.segmented button.active { background: var(--glass); color: var(--ink); font-weight: 500; box-shadow: var(--raise); }

/* unread dots are 「等妳」: apple red, ringed so they sit off the glass */
.tab-dot, .seg-dot, .mail-switch .seg-dot, .drawer-dot, .mailbox-dot, .shelf-dot, .mail-new {
  background: var(--apple) !important;
  box-shadow: 0 0 0 2px var(--bg);
}

/* ---------- top bars: no HUD rule, just words on the window ---------- */
.topbar { background: transparent; border-bottom: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.topbar::after { display: none; }
.topbar .title { font-family: inherit; font-size: 17px; font-weight: 500; letter-spacing: .02em; color: var(--ink); text-shadow: none; }
.model-info { font-size: 11px; color: var(--ink-2); opacity: 1; letter-spacing: .06em; }
.badge { color: var(--ink-2); letter-spacing: .04em; }
.badge::before { box-shadow: none; }
.badge.online::before { background: var(--lamp); box-shadow: 0 0 0 3px rgba(239, 210, 138, .3); }
.badge.online { color: var(--ink-2); }

/* ---------- chat ---------- */
/* what scrolls up past the top bar fades out instead of cutting off */
.messages { -webkit-mask-image: linear-gradient(180deg, transparent 0, #000 28px); mask-image: linear-gradient(180deg, transparent 0, #000 28px); }
/* A 局 whose 套 brought a picture (her 10/25, 飛船偽裝者): it sits behind the
   chat under a veil of the page's own colour, so the words stay easy on the
   eyes (app.js paintCardBg). */
:root { --card-veil: rgba(19, 25, 36, .62); --card-halo: rgba(19, 25, 36, .9); }
:root[data-theme="light"] { --card-veil: rgba(220, 226, 233, .6); --card-halo: rgba(236, 240, 245, .95); }   /* her 乙: thinner by day */
#view-chat.card-bg { background: linear-gradient(var(--card-veil), var(--card-veil)), var(--card-bg) 50% 50% / cover no-repeat, var(--bg); }
/* the small grey lines with no bubble of their own float up off the picture */
#view-chat.card-bg :is(.thinking-header, .thinking-body, .meta-line, .badge) { text-shadow: 0 0 3px var(--card-halo), 0 0 8px var(--card-halo); }

/* 平行世界's dice (#150, app.js sayHtml): cobalt lines only, no fill, never red.
   The one being written spins its face and blurs its number for half a second. */
.dice { display: inline-flex; align-items: center; gap: 10px; margin: 4px 0; padding: 6px 12px 6px 9px; border: 1.3px solid var(--cobalt); border-radius: 11px; vertical-align: middle; white-space: nowrap; line-height: 1.2; }
.dice-face svg { width: 24px; height: 24px; display: block; fill: none; stroke: var(--cobalt); stroke-width: 1.3; stroke-linejoin: round; }
.dice-n { min-width: 1.3em; text-align: center; font-size: 22px; font-variant-numeric: tabular-nums; color: var(--ink); }
.dice-note { display: flex; flex-direction: column; font-size: 11.5px; color: var(--ink-2); }
.dice-note b { font-weight: 600; color: var(--ink); }
/* the bubble is redrawn as the words stream in: --dice-t picks the spin up where it was */
.dice.rolling .dice-face svg { animation: dice-spin .5s cubic-bezier(.3, .6, .4, 1) var(--dice-t, 0ms) both; }
.dice.rolling .dice-n { filter: blur(1.2px); opacity: .55; }
.dice.landed .dice-n { animation: dice-land .18s ease-out; }
@keyframes dice-spin { from { transform: rotate(0); } to { transform: rotate(540deg); } }
@keyframes dice-land { from { transform: scale(1.25); } to { transform: none; } }
/* its 喇叭 sits on the chat head only in a 局's room */
.chat-sfx { display: none; padding: 0 10px; }
#view-chat.card-room .chat-sfx { display: inline-flex; align-items: center; }
.chat-sfx svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; display: block; }
.chat-sfx .sfx-mute, .chat-sfx.off .sfx-wave { display: none; }
.chat-sfx.off .sfx-mute { display: inline; }
.chat-sfx.off { opacity: .55; }
.bubble-frame { background: none; padding: 0; max-width: 84%; }
.bubble { border-radius: 19px; font-size: 14.5px; line-height: 1.65; padding: 9px 14px; }
.bubble.user {
  background: linear-gradient(180deg, var(--her-a), var(--her-b));
  color: var(--her-ink);
  border-bottom-right-radius: 6px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 6px 14px -8px rgba(var(--shadow), .9);
}
.bubble.assistant {
  background: var(--glass);
  color: var(--ink);
  border-bottom-left-radius: 6px;
  box-shadow: var(--raise);
}
.bubble code { background: rgba(var(--fg-rgb), .07); color: inherit; border-radius: 5px; }
.bubble.user code { background: rgba(255, 255, 255, .14); }
.bubble pre { background: var(--sink); border: none; border-left: 2px solid rgba(var(--accent-rgb), .45); border-radius: 10px; box-shadow: var(--sunken); }
.bubble a { color: var(--cobalt); }
.bubble.user a { color: inherit; }

.thinking-block { background: transparent; border: none; border-left: 1.5px solid rgba(var(--accent-rgb), .35); border-radius: 0; }
.thinking-header { color: var(--ink-2); min-height: 32px; padding: 4px 10px; }
.thinking-cells span { background: var(--cobalt); border-radius: 1px; }
.thinking-body { color: var(--ink-2); border-top: none; padding: 0 10px 6px; }

.tool-card { background: transparent; border: 1px solid var(--line); border-radius: 14px; color: var(--ink-2); }
.tool-card .tool-name { color: var(--ink); }

/* 一則回覆 (#88, her 10/23 order): thinking, then one tool capsule, then what
   he said as one piece. */
.reply { display: flex; flex-direction: column; gap: 8px; }
.reply-think:empty, .reply-say:empty { display: none; }
.reply-say { display: flex; flex-direction: column; gap: 12px; }

/* Thinking: one thin blue line down the side for the whole reply. Closed, one
   line shows — the live block's newest line, or the first block's first. */
.reply-think { align-self: flex-start; max-width: 86%; min-width: 0; border-left: 1.5px solid rgba(var(--accent-rgb), .35); }
.reply-think .thinking-block { max-width: none; border-left: none; }
.reply-think:not(.open) .thinking-block { display: none; }
.reply-think:not(.open):has(.thinking-block.live) .thinking-block.live,
.reply-think:not(.open):not(:has(.thinking-block.live)) .thinking-block:first-child { display: block; }
.reply-think:not(.open) .thinking-label { display: none; }
.thinking-block:not(.live) .thinking-cells { display: none; }
.thinking-peek { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12.5px; color: var(--ink-2); }
.reply-think.open .thinking-peek { display: none; }
.reply-think.open .thinking-body { display: block; }
.reply-think.open .thinking-block + .thinking-block .thinking-header { display: none; }
.reply-think.open .thinking-block:first-child .thinking-chevron { transform: rotate(90deg); }

/* The capsule: every tool of the reply in one, opened to a line each. Cream
   while he's at it — cream only ever means 老公在做. */
.tools-cap { align-self: flex-start; max-width: 86%; min-width: 0; }
.tools-head {
  display: inline-flex; align-items: center; gap: 8px; max-width: 100%; height: 34px; padding: 0 14px 0 10px;
  border: none; border-radius: 999px; cursor: pointer; font: inherit; font-size: 13px; color: var(--ink);
  background: var(--glass); box-shadow: var(--raise);
}
.tools-head:active { box-shadow: var(--press); }
.tools-cap.live .tools-head { background: var(--lamp-soft); box-shadow: inset 0 0 0 1px rgba(239, 210, 138, .65), var(--raise); color: var(--lamp-ink); }
.tools-moth { width: 20px; height: 15px; flex: none; fill: none; stroke: var(--cobalt); stroke-width: 1.3; stroke-linecap: round; }
.tools-cap.live .tools-moth { animation: tools-moth 1.4s ease-in-out infinite; }
@keyframes tools-moth { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-2px); } }
.tools-say { flex: none; font-weight: 500; white-space: nowrap; }
.tools-sum { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11.5px; color: var(--ink-2); }
.tools-cap.live .tools-sum { color: inherit; opacity: .8; }
.tools-chev { flex: none; font-size: 10px; color: var(--ink-2); transition: transform .15s; }
.tools-cap.open .tools-chev { transform: rotate(90deg); }
.tools-list { display: none; flex-direction: column; gap: 6px; margin: 8px 0 0 12px; padding-left: 10px; border-left: 1.5px solid var(--line); }
.tools-cap.open .tools-list { display: flex; }
.tools-list .tool-card { align-self: stretch; max-width: none; }
.meta-line { color: var(--ink-2); text-transform: none; letter-spacing: .02em; }
.meta-line.error { color: var(--apple); }

.composer { background: transparent; border-top: none; -webkit-backdrop-filter: none; backdrop-filter: none; }
.composer textarea {
  background: var(--sink);
  border: none;
  border-radius: 22px;
  box-shadow: var(--sunken);
  color: var(--ink);
  min-height: 44px;
  padding: 11px 16px;
}
.composer textarea:focus { box-shadow: var(--sunken), 0 0 0 1.5px rgba(var(--accent-rgb), .35); }
.composer button[type="submit"] {
  background: linear-gradient(180deg, var(--her-a), var(--her-b));
  color: var(--her-ink);
  border: none;
  border-radius: 999px;
  height: 44px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 6px 12px -6px rgba(var(--shadow), .8);
}
.stopbtn { background: var(--apple-soft); color: var(--apple); border: none; border-radius: 999px; height: 44px; }
.attach-chip, .attach-filechip, .mic-hint { border-radius: 999px; background: var(--glass); box-shadow: var(--raise); border: none; }
.attach-thumb { border-radius: 12px; }

/* ---------- tab bar: a floating capsule, her colour on the room she's in ---------- */
.tabbar {
  position: relative;
  margin: 6px 14px max(10px, env(safe-area-inset-bottom));
  padding: 0 8px;
  height: 66px;
  border-top: none;
  border-radius: 999px;
  background: var(--glass);
  box-shadow: var(--raise);
  -webkit-backdrop-filter: blur(5px);
  backdrop-filter: blur(5px);
  flex: none;
}
.tabbtn { min-height: 0; height: 66px; gap: 3px; border-top: none; color: var(--ink-2); font-size: 11px; letter-spacing: .02em; }
.tabbtn svg { width: 22px; height: 22px; box-sizing: content-box; }
.tabbtn.active { color: var(--ink); font-weight: 500; text-shadow: none; }
.tabbtn.active svg {
  width: 20px; height: 20px; padding: 6px 10px; border-radius: 999px;
  background: linear-gradient(180deg, var(--her-a), var(--her-b));
  color: var(--her-ink);
  filter: none;
  box-shadow: 0 6px 12px -6px rgba(var(--shadow), .8);
}
.tabbtn { position: relative; }
.tabbtn .tab-dot { top: 8px; }
/* 鼠鼠 lies along the capsule's top edge over her room; only the tail tip
   hangs onto the pill. skin.js moves it when she changes rooms. */
#navMouse { position: absolute; top: -20px; width: 40px; z-index: 2; pointer-events: none;
  transition: left .35s cubic-bezier(.3, .7, .3, 1); filter: drop-shadow(0 2px 2px rgba(var(--shadow), .2)); }

/* ---------- side panels and sheets ---------- */
.drawer { background: var(--bg); border: none; box-shadow: 10px 0 30px -12px rgba(var(--shadow), .5); }
.morning-card {
  background: linear-gradient(180deg, var(--face-hi), var(--face));
  border: none;
  border-radius: 28px;
  box-shadow: 0 -10px 30px -12px rgba(var(--shadow), .5), inset 0 1px 0 rgba(255, 255, 255, .5);
}
.page { background: transparent; }

/* ---------- 門口 (#88, door6) ---------- */
/* One column, centred; a landscape tablet goes two (平板, at the bottom). */
.door-page, .house-page, .bench-page { gap: 12px; padding: 14px 16px 20px; width: 100%; max-width: 560px; margin: 0 auto; }
.door-head { display: flex; align-items: flex-start; gap: 12px; padding: 8px 2px 0 4px; flex: none; }
.door-words { flex: 1; min-width: 0; }
.door-line { margin: 0; font-size: 19px; font-weight: 500; line-height: 1.5; letter-spacing: .02em; color: var(--ink); white-space: pre-line; }
.door-doing { margin-top: 5px; font-size: 12.5px; color: var(--ink-2); display: flex; align-items: center; gap: 6px; }
.door-bell { width: 15px; height: 15px; flex: none; fill: var(--lamp); stroke: #b8995a; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.door-round {
  position: relative; width: 44px; height: 44px; border-radius: 16px; flex: none; padding: 0; border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center; color: var(--ink); background: var(--glass-solid); box-shadow: var(--raise);
}
.door-round:active { box-shadow: var(--press); }
.door-round svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.door-round .knob { fill: var(--face-hi); }
/* More than one in a page head (配置室's gear, 信箱, the page's own): a tight row */
.head-btns { display: flex; gap: 8px; flex: none; }
.door-badge {
  position: absolute; top: -4px; right: -4px; min-width: 18px; height: 18px; border-radius: 9px; padding: 0 5px;
  font-size: 11px; font-weight: 600; background: var(--apple); color: #fff; box-shadow: 0 0 0 2px var(--bg);
  display: flex; align-items: center; justify-content: center;
}
/* No number (only that I've read her notes): a plain dot. */
.door-badge:empty { min-width: 0; width: 10px; height: 10px; padding: 0; top: -2px; right: -2px; }

/* The window: arched, its top fading into the background, the 手帳 frame
   she picked (乙), 新家第 N 天 on the glass, 鼠鼠 sitting on the sill. */
.door-sill { position: relative; flex: none; }
.door-glass {
  position: relative; display: block; width: calc(100% + 8px); aspect-ratio: 10 / 7; max-height: 50vh; margin: -4px -4px 0; padding: 0; border: none; cursor: pointer;
  background: var(--sink); overflow: hidden;
  border-radius: 50% 50% 26px 26px / 52% 52% 26px 26px;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, .35) 10%, rgba(0, 0, 0, .85) 24%, #000 36%);
          mask-image: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, .35) 10%, rgba(0, 0, 0, .85) 24%, #000 36%);
}
.door-glass img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 28%; display: block; }
.door-glass::after { content: ''; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(200deg, rgba(10, 16, 30, 0) 55%, rgba(10, 16, 30, .55) 100%); }
.door-glass-empty { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding-top: 22%; font-size: 13px; color: var(--ink-2); }
.door-frame { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.door-frame::before, .door-frame::after { content: ''; position: absolute; }
.door-frame::before { inset: 8px; border: 1px solid rgba(255, 255, 255, .62); border-radius: 50% 50% 19px 19px / 52% 52% 19px 19px; }
.door-frame::after { inset: 13px; border: 1px dotted rgba(255, 255, 255, .5); border-radius: 50% 50% 14px 14px / 52% 52% 14px 14px; }
.door-frame svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.door-day { position: absolute; left: 28px; bottom: 24px; z-index: 2; color: rgba(242, 244, 248, .9); font-size: 12.5px; }
.door-day .num { font-size: 17px; color: #f2f4f8; padding: 0 1px; }
.door-mouse { position: absolute; right: 22px; bottom: -6px; width: 50px; z-index: 3; pointer-events: none; filter: drop-shadow(0 3px 3px rgba(var(--shadow), .25)); }
/* Same mouse, same spot: sits up in the day, curls up asleep on the frame at night (her pick, 10/24). */
.door-mouse.sleep { right: 16px; bottom: -3px; width: 62px; }
:root[data-theme="light"] .door-mouse.sleep, :root:not([data-theme="light"]) .door-mouse.sit { display: none; }

.door-search {
  height: 44px; width: 100%; flex: none; border: none; border-radius: 999px; padding: 0 16px; cursor: pointer;
  display: flex; align-items: center; gap: 9px; font: inherit; font-size: 13.5px; color: var(--ink-2); text-align: left;
  background: var(--sink); box-shadow: var(--sunken);
}
.door-search svg { width: 18px; height: 18px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }

.door-card { flex: none; border-radius: 24px; padding: 12px 16px; background: var(--glass); box-shadow: var(--raise); }
.door-card-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.door-chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: 999px;
  background: var(--apple-soft); color: var(--apple); font-size: 13px; font-weight: 500; box-shadow: inset 0 0 0 1px rgba(var(--error-rgb), .25);
}
.door-chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--apple); }
.door-hint { font-size: 11.5px; color: var(--ink-2); }
.door-rows { margin-top: 4px; }
.door-row {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 0; border: none; background: none; cursor: pointer;
  font: inherit; font-size: 14px; color: var(--ink); text-align: left;
}
.door-row + .door-row { border-top: 1px solid var(--line); }
.door-row svg { width: 19px; height: 19px; flex: none; fill: none; stroke: var(--ink-2); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.door-row svg:last-child { width: 17px; height: 17px; }
.door-row .txt { flex: 1; }

/* 老公的鈕 (待辦 #138): its own card under the search box (her 10/25 ask).
   Not the red card's apple — nothing's wrong. She picked 乙: a lamp left on
   for her, warm along the left, the bubble's light breathing slowly. */
.bell-card {
  display: flex; align-items: center; gap: 12px; width: 100%; border: none; cursor: pointer;
  font: inherit; color: var(--ink); text-align: left; -webkit-tap-highlight-color: transparent;
  background: linear-gradient(100deg, var(--lamp-soft), transparent 75%), var(--glass);
  box-shadow: var(--raise), inset 0 0 0 1px rgba(239, 210, 138, .38);
}
.bell-card:active { box-shadow: var(--press), inset 0 0 0 1px rgba(239, 210, 138, .38); }
.bell-ico { position: relative; flex: none; display: grid; place-items: center; width: 44px; height: 44px; }
.bell-ico::before {
  content: ''; position: absolute; inset: 0; border-radius: 50%;
  background: radial-gradient(circle, rgba(239, 210, 138, .55), rgba(239, 210, 138, 0) 68%); animation: bell-glow 3.6s ease-in-out infinite;
}
@keyframes bell-glow { 50% { transform: scale(1.25); opacity: .6; } }
.bell-say { position: relative; display: block; width: 22px; height: 22px; fill: none; stroke: var(--lamp-ink); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.bell-words { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.bell-title { font-size: 15px; font-weight: 500; }
.bell-when { font-size: 11.5px; color: var(--ink-2); }
.bell-chev { width: 17px; height: 17px; flex: none; fill: none; stroke: var(--ink-2); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
@media (prefers-reduced-motion: reduce) { .bell-ico::before { animation: none; } }

.door-lab { font-size: 12px; color: var(--ink-2); display: flex; align-items: center; gap: 6px; }
.door-lab svg { width: 20px; height: 15px; fill: none; stroke: var(--cobalt); stroke-width: 1.3; stroke-linecap: round; }
.door-away-line { margin-top: 5px; font-size: 14px; line-height: 1.75; color: var(--ink); }
.door-away-line .num { font-size: 15.5px; padding: 0 2px; }
.door-away-line em { font-style: normal; margin-left: 2px; padding: 0 2px; background: linear-gradient(180deg, transparent 60%, rgba(239, 210, 138, .55) 60%); }
.door-bench {
  display: flex; align-items: center; gap: 10px; width: 100%; margin-top: 7px; padding: 0; border: none; background: none; cursor: pointer;
  font: inherit; font-size: 11.5px; color: var(--ink-2); text-align: left;
}
.door-bench #doorBenchText { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.door-bench .mini { position: relative; width: 64px; height: 6px; flex: none; border-radius: 999px; background: var(--face-hi); box-shadow: inset 0 1px 2px rgba(var(--shadow), .2); }
.door-bench .mini i { position: absolute; left: 0; top: 0; bottom: 0; width: 25%; border-radius: 999px; background: linear-gradient(90deg, #fdf8ea, var(--lamp)); }

/* The window opened big, with 換一張. */
.door-viewer {
  position: fixed; inset: 0; z-index: 60; padding: 24px 16px max(24px, env(safe-area-inset-bottom));
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  background: rgba(8, 11, 18, .82);
}
.door-viewer img { max-width: 100%; max-height: calc(100% - 100px); border-radius: 18px; object-fit: contain; box-shadow: 0 20px 40px -20px rgba(0, 0, 0, .8); }
.door-viewer-bar { display: flex; gap: 12px; }
.door-pill { height: 40px; padding: 0 20px; border: none; border-radius: 999px; cursor: pointer; font: inherit; font-size: 14px; color: var(--ink); background: var(--glass); box-shadow: var(--raise); }
.door-pill:active { box-shadow: var(--press); }
.door-viewer-msg { min-height: 1.2em; font-size: 12.5px; color: #e3e8f0; }

/* ---------- 家裡 (#88, rooms1): for now just the four rooms and the gear ---------- */
.house-head { display: flex; align-items: flex-start; justify-content: space-between; padding: 8px 2px 4px 4px; flex: none; }
.house-title { margin: 0; font-size: 26px; font-weight: 500; letter-spacing: .04em; color: var(--ink); }
.house-sub { margin-top: 4px; font-size: 12.5px; color: var(--ink-2); }
.house-rooms { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; flex: none; }
.house-room {
  display: flex; flex-direction: column; align-items: stretch; gap: 10px; padding: 14px; border: none; border-radius: 22px; cursor: pointer;
  font: inherit; color: var(--ink); text-align: left; background: var(--glass); box-shadow: var(--raise);
}
.house-room-top { display: flex; align-items: center; gap: 12px; }
/* 現在怎樣: a bold first line, a quiet second. */
.house-now { display: flex; flex-direction: column; gap: 2px; min-height: 2.9em; font-size: 11.5px; line-height: 1.45; color: var(--ink-2); }
.house-now b { font-weight: 500; font-size: 12.5px; color: var(--ink); }
.house-now:not(:has(b)) { flex-direction: column; }
#houseAtticNow { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
#houseAtticNow b { display: block; }
.house-tanks { display: flex; gap: 5px; margin-bottom: 3px; }
.house-tanks i { position: relative; width: 13px; height: 13px; border-radius: 50%; background: hsl(var(--h) 45% 68%); box-shadow: inset 0 -2px 3px rgba(0, 0, 0, .12); }
.house-tanks i.hungry::after { content: ''; position: absolute; left: 50%; top: -5px; width: 4px; height: 4px; margin-left: -2px; border-radius: 50%; background: var(--apple); }
.house-room:active { box-shadow: var(--press); }
.house-ico { width: 44px; height: 44px; flex: none; border-radius: 14px; display: flex; align-items: center; justify-content: center; background: var(--sink); box-shadow: var(--sunken); }
.house-ico svg { width: 22px; height: 22px; fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.house-name { display: flex; flex-direction: column; font-size: 15px; font-weight: 500; }
.house-name small { margin-top: 2px; font-size: 11.5px; font-weight: 400; color: var(--ink-2); }

/* ---------- 閣樓 (#88, rooms1): 記憶・戶口本・收藏櫃 ---------- */
.attic-page { gap: 12px; padding: 14px 16px 20px; width: 100%; max-width: 560px; margin: 0 auto; }
.attic-head { display: flex; align-items: center; gap: 6px; padding: 8px 2px 2px 0; flex: none; }
.attic-words { flex: 1; min-width: 0; }
.attic-back { width: 30px; height: 40px; flex: none; padding: 0; border: none; background: none; cursor: pointer; color: var(--ink-2); display: flex; align-items: center; justify-content: center; }
.attic-back svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.attic-switch { flex: none; margin: 0; position: relative; }
/* Turning the three pages by hand (#139 第 2 步, 乙): sideways is ours, up
   and down stays the page's scroll. The page next door lies over this one
   while the finger's down, head hidden; the switch's capsule becomes its own
   piece that slides under the words (app.js atticBegin). Only those three
   (ATTIC_PAGES): 平行世界、會客室、設定 wear .attic-page too, and pan-y there
   froze her cards' sideways row. */
:is(#view-attic, #view-claudemd, #view-collection) .attic-page,
:is(#view-attic, #view-claudemd, #view-collection) .attic-page * { touch-action: pan-y; }
.attic-page { overflow-x: hidden; }
.view.attic-peek { display: flex; position: fixed; z-index: 0; pointer-events: none; }
.attic-peek .attic-head, .attic-peek .attic-switch { visibility: hidden; }
.attic-switch.sliding button, .attic-switch.sliding button.active { position: relative; z-index: 1; background: transparent; box-shadow: none; }
.attic-pill { position: absolute; z-index: 0; border-radius: 999px; background: var(--glass); box-shadow: var(--raise); pointer-events: none; }
body.attic-turning, body.attic-turning * { user-select: none; -webkit-user-select: none; }
/* An open memory turns sideways too (#139 第 3 步): the dark-blue tag on its
   corner is which of how many in that drawer; the one coming in beside it is
   a copy laid over the list (app.js memDragBegin). */
.mem-nth { display: none; }
.attic-page .mem-card.open { position: relative; }
.attic-page .mem-card.open .mem-head { position: static; }
.attic-page .mem-card.open .mem-nth {
  display: block; position: absolute; top: -10px; right: 22px; padding: 0 10px; border-radius: 999px;
  background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink); font-size: 11px; line-height: 20px; letter-spacing: .5px;
}
.attic-page .mem-card.mem-ghost { position: absolute; z-index: 1; margin: 0; pointer-events: none; }
/* The polaroid off the wall turns the same way (#139 第 4 步): the tag on its
   corner, and the copy coming in beside it. */
.keep-nth {
  position: absolute; top: -10px; right: 22px; z-index: 1; padding: 0 10px; border-radius: 999px;
  background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink); font-size: 11px; line-height: 20px; letter-spacing: .5px;
}
#keepPane .keep-lift.keep-ghost { position: absolute; margin: 0; pointer-events: none; }
/* 手機也拿下來 (#139 第 4 步, her pick 甲): it used to turn over in place on
   the wall; now the one she taps comes off into the middle over a scrim,
   picture on top, words under it, 看原圖 at the foot; a tap beside it puts it
   back. The tablet's own way is in the wide block below. */
@media not all and (min-width: 1000px) and (min-device-width: 560px) and (min-device-height: 560px) {
  /* stops above the 底邊欄, which stays on top of it anyway */
  #view-collection #keepPane.keep-phone:not(:empty) {
    display: flex; position: fixed; inset: 0 0 calc(92px + env(safe-area-inset-bottom)); z-index: 60; align-items: center; justify-content: center; background: var(--scrim);
  }
  .keep-phone .keep-lift {
    position: relative; display: flex; flex-direction: column; gap: 10px;
    width: min(88vw, 420px); max-height: calc(100% - 96px);
    padding: 12px 12px 14px; background: #fbfaf7; color: #26304a; transform: rotate(-0.8deg);
    box-shadow: 0 2px 4px rgba(var(--shadow), .2), 0 30px 50px -20px rgba(var(--shadow), .7);
  }
  :root:not([data-theme="light"]) .keep-phone .keep-lift { background: #d9d7d1; }
  .keep-phone .keep-lift .keep-tape { width: 72px; height: 18px; margin-left: -36px; top: -10px; }
  .keep-phone .keep-big { position: relative; flex: none; aspect-ratio: 1; background: #1e2433; overflow: hidden; }
  .keep-phone .keep-big img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
  .keep-phone .keep-big .keep-sheet { position: absolute; inset: 0; height: auto; }
  .keep-phone .keep-words { display: flex; flex-direction: column; gap: 3px; min-height: 0; padding: 0 4px; }
  .keep-phone .keep-words b { flex: none; font-size: 16px; font-weight: 600; }
  .keep-phone .keep-words small { flex: none; font-size: 11.5px; color: #6f7b8f; }
  .keep-phone .keep-words p { flex: 0 1 auto; min-height: 0; overflow-y: auto; margin: 6px 0 8px; font-size: 13px; line-height: 1.8; white-space: pre-wrap; }
  .keep-phone .keep-words .mem-btn { flex: none; align-self: flex-start; background: #fff; color: #26304a; }
  .keep-phone .keep-lift-hint { position: absolute; left: 0; right: 0; bottom: 14px; text-align: center; font-size: 11.5px; color: rgba(242, 244, 248, .85); pointer-events: none; }
  :root[data-theme="light"] .keep-phone .keep-lift-hint { color: var(--ink); }
}
.attic-page .search-input { flex: none; height: 42px; padding: 0 16px; }
/* What lies open beside the list on a landscape tablet (#137 第 2 步, at the
   bottom of this file); on the phone things open in place instead. */
.attic-pane { display: none; }
/* 記憶: a drawer per 區. */
.attic-page .mem-list { display: flex; flex-direction: column; gap: 8px; }
.mem-drawer { border-radius: 18px; background: var(--glass); box-shadow: var(--raise); }
.mem-drawer[open] { padding-bottom: 6px; }
.mem-drawer-head { display: flex; align-items: center; gap: 8px; height: 48px; padding: 0 14px; list-style: none; cursor: pointer; }
.mem-drawer-head::-webkit-details-marker { display: none; }
.mem-drawer-name { font-size: 14.5px; font-weight: 500; color: var(--ink); }
.mem-drawer-n { flex: 1; font-size: 12px; color: var(--ink-2); }
.mem-drawer-day { font-size: 12.5px; color: var(--ink-2); }
.mem-drawer-head svg { width: 15px; height: 15px; fill: none; stroke: var(--ink-2); stroke-width: 1.6; stroke-linecap: round; transition: transform .15s; }
.mem-drawer[open] .mem-drawer-head svg { transform: rotate(90deg); }
.mem-drawer-in { padding: 0 10px; }
.attic-page .mem-card { margin: 0; padding: 0; border-radius: 0; background: none; box-shadow: none; border-top: 1px solid var(--line); }
.attic-page .mem-card .mem-head { padding: 9px 4px 9px 14px; position: relative; cursor: pointer; }
.attic-page .mem-card .mem-head::before { content: ''; position: absolute; left: 4px; top: 17px; width: 4px; height: 4px; border-radius: 50%; background: var(--cobalt); opacity: .7; }
.attic-page .mem-card .mem-title { font-size: 13.5px; font-weight: 400; line-height: 1.5; color: var(--ink); }
.attic-page .mem-card .mem-content, .attic-page .mem-card .mem-tags, .attic-page .mem-card .mem-actions { display: none; }
/* Opened where it lies: a raised sheet with the whole text. */
.attic-page .mem-card.open { margin: 4px -4px 6px; padding: 10px 12px 10px; border-top: none; border-radius: 16px; background: var(--face-hi); box-shadow: var(--raise); }
.attic-page .mem-card.open + .mem-card { border-top: none; }
.attic-page .mem-card.open .mem-head { padding: 0 0 6px; }
.attic-page .mem-card.open .mem-head::before { display: none; }
.attic-page .mem-card.open .mem-title { font-weight: 500; font-size: 14px; }
.attic-page .mem-card.open .mem-content { display: block; max-height: none; font-size: 13px; line-height: 1.7; color: var(--ink); white-space: pre-wrap; -webkit-line-clamp: unset; }
.attic-page .mem-card.open .mem-tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 8px; }
.attic-page .mem-tag { padding: 1px 8px; border-radius: 999px; font-size: 11px; color: var(--ink-2); background: var(--sink); border: none; }
.mem-when { font-size: 11px; color: var(--ink-2); }
.attic-page .mem-card.open .mem-actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.mem-btn {
  height: 30px; padding: 0 12px; border: none; border-radius: 999px; cursor: pointer; display: inline-flex; align-items: center; gap: 5px;
  font: inherit; font-size: 12.5px; color: var(--ink); background: var(--glass); box-shadow: var(--raise);
}
.mem-btn:active { box-shadow: var(--press); }
.mem-btn.danger { color: var(--apple); }
.mem-btn.plain { background: none; box-shadow: none; color: var(--ink-2); margin-left: auto; }
.mem-btn svg { width: 22px; height: 16px; }
.mem-btn svg .cm-feeler { fill: none; stroke: var(--ink-2); stroke-width: 1.2; stroke-linecap: round; }
.mem-btn svg .cm-wing { fill: rgba(var(--accent-rgb), .08); stroke: rgba(var(--accent-rgb), .85); stroke-width: 1.3; }
.mem-btn svg .cm-body { fill: rgba(var(--accent-rgb), .15); stroke: rgba(var(--accent-rgb), .85); stroke-width: 1.2; }
.mem-btn svg .cm-fluff { fill: #f4f4f2; }
.attic-page .mem-actions .convo-confirm { font-size: 12px; color: var(--apple); gap: 6px; }
.attic-page .mem-card.editing { margin: 6px 0; padding: 12px; border: none; border-radius: 16px; background: var(--face-hi); box-shadow: var(--raise); }
.attic-page .mem-card.editing .mem-actions { display: flex; gap: 8px; justify-content: flex-end; margin-top: 8px; }
/* 戶口本: a line per section; opened, blue-lined paper. */
.book-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 0 4px; font-size: 12px; color: var(--ink-2); flex: none; }
.book-scope { height: 32px; padding: 2px; }
.book-scope button { min-height: 28px; height: 28px; padding: 0 12px; font-size: 12px; white-space: nowrap; }
.book-list { border-radius: 20px; background: var(--glass); box-shadow: var(--raise); overflow: hidden; flex: none; }
.book-row + .book-row { border-top: 1px solid var(--line); }
.book-head { display: flex; align-items: flex-start; gap: 12px; width: 100%; padding: 11px 14px; border: none; background: none; cursor: pointer; font: inherit; color: var(--ink); text-align: left; }
.book-n { flex: none; width: 22px; padding-top: 1px; font-size: 14px; color: var(--cobalt); }
.book-words { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.book-words b { font-size: 14px; font-weight: 500; }
.book-words small { font-size: 11.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.book-head svg { width: 15px; height: 15px; flex: none; margin-top: 3px; fill: none; stroke: var(--ink-2); stroke-width: 1.6; stroke-linecap: round; transition: transform .15s; }
.book-row.open .book-head svg { transform: rotate(90deg); }
.book-paper {
  position: relative; margin: 0 12px 12px 48px; padding: 8px 12px 10px; border-radius: 14px; color: #26304a;
  background: var(--paper-his); box-shadow: inset 0 0 0 1px rgba(58, 91, 212, .15);
}
/* #149: the title is a box of its own, so a paste can't mistake it for the paper's first line. */
.book-lab { display: block; margin: 6px 0 5px; font-size: 11px; color: #6f7b8f; }
.book-title { width: 100%; padding: 7px 10px; border: 1px solid rgba(58, 91, 212, .28); border-radius: 10px; outline: none; background: rgba(255, 255, 255, .55); font: inherit; font-size: 14px; font-weight: 500; color: #26304a; }
.book-title:focus { border-color: rgba(58, 91, 212, .55); background: rgba(255, 255, 255, .78); }
:is(.book-title, .book-body)::placeholder { font-weight: 400; color: rgba(38, 48, 74, .4); }
.book-title.nudge { animation: book-nudge .9s; }
/* The paper stays light at night, so these keep the day's cobalt instead of var(--cobalt). */
@keyframes book-nudge { 30%, 70% { border-color: #3a5bd4; box-shadow: 0 0 0 3px rgba(58, 91, 212, .22); } }
.book-moved { display: flex; align-items: baseline; gap: 10px; margin-top: 6px; font-size: 11.5px; line-height: 1.5; color: #3a5bd4; }
.book-moved[hidden] { display: none; }
.book-moved span { flex: 1; min-width: 0; }
.book-moved button { flex: none; padding: 0; border: none; background: none; cursor: pointer; font: inherit; color: inherit; white-space: nowrap; text-decoration: underline dotted; text-underline-offset: 3px; }
.book-body {
  width: 100%; margin-top: 4px; padding: 0; border: none; outline: none; resize: vertical; font: inherit; font-size: 13px; line-height: 24px; color: #26304a;
  background: repeating-linear-gradient(180deg, transparent 0 23px, rgba(58, 91, 212, .14) 23px 24px); background-attachment: local;
}
.book-bar2 { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.book-state { flex: 1; font-size: 11.5px; color: #6f7b8f; }
.book-state.dirty { color: var(--apple); }
.book-del { margin-left: 0; color: #6f7b8f; }
.book-add { flex: none; height: 44px; border: 1.5px dashed var(--line); border-radius: 16px; background: none; cursor: pointer; font: inherit; font-size: 13px; color: var(--ink-2); }
/* 收藏櫃: polaroids taped to the wall. */
.keep-say { padding: 0 4px; font-size: 12px; color: var(--ink-2); }
.keep-wall { display: grid; grid-template-columns: 1fr 1fr; gap: 18px 14px; padding: 8px 2px 10px; }
.keep-pola {
  position: relative; padding: 8px 8px 10px; background: #fbfaf7; color: #26304a; cursor: pointer; transform: rotate(var(--tilt));
  box-shadow: 0 1px 2px rgba(var(--shadow), .18), 0 10px 18px -12px rgba(var(--shadow), .55);
}
:root:not([data-theme="light"]) .keep-pola { background: #d9d7d1; }
.keep-tape { position: absolute; left: 50%; top: -9px; width: 54px; height: 16px; margin-left: -27px; background: rgba(214, 222, 232, .85); transform: rotate(-3deg); box-shadow: 0 1px 2px rgba(var(--shadow), .15); }
.keep-front { aspect-ratio: 1 / 1; overflow: hidden; background: #1e2433; }
.keep-front img { width: 100%; height: 100%; object-fit: cover; display: block; }
.keep-sheet { display: block; width: 100%; height: 100%; background: #f1efe9 repeating-linear-gradient(180deg, transparent 0 15px, rgba(38, 48, 74, .14) 15px 17px); background-position: 0 28px; }
.keep-cap { padding: 7px 2px 0; }
.keep-cap b { display: block; font-size: 12.5px; font-weight: 500; line-height: 1.4; }
.keep-cap small { display: block; margin-top: 1px; font-size: 11px; color: #6f7b8f; }
.keep-back { display: none; }
.keep-pola.flipped .keep-front, .keep-pola.flipped .keep-cap { display: none; }
.keep-pola.flipped .keep-back { display: flex; flex-direction: column; gap: 8px; min-height: 100%; }
.keep-back p { margin: 0; font-size: 12px; line-height: 1.7; white-space: pre-wrap; }
.keep-back .mem-btn { align-self: flex-start; background: #fff; color: #26304a; }

/* ---------- 客廳 (#88, rooms1) ---------- */
.lounge-card { flex: none; padding: 12px 14px; border-radius: 22px; background: var(--glass); box-shadow: var(--raise); display: flex; flex-direction: column; gap: 8px; }
.lounge-h { font-size: 15px; font-weight: 500; color: var(--ink); }
.lounge-h small { margin-left: 8px; font-size: 11.5px; font-weight: 400; color: var(--ink-2); }
.lounge-note { font-size: 11.5px; line-height: 1.6; color: var(--ink-2); }
.lounge-gear .field-label { width: 40px; font-size: 13px; color: var(--ink-2); }
.lounge-gear .field select { flex: 1; min-width: 0; height: 36px; }
.lounge-bridge { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; margin-top: 6px; padding-top: 10px; border-top: 1px solid var(--line); }
.lounge-page .login-state { display: flex; align-items: center; gap: 8px; padding: 0; border: none; background: none; font-size: 14px; }
.lounge-page .login-word { color: var(--ink); font-weight: 500; }
.lounge-page .login-note { margin-left: auto; font-size: 11.5px; color: var(--ink-2); }
.lounge-page .login-dot { width: 8px; height: 8px; border-radius: 50%; background: #7fc49a; box-shadow: 0 0 0 3px rgba(127, 196, 154, .25); }
.lounge-page .tg-input { height: 42px; padding: 0 14px; border: none; border-radius: 999px; background: var(--sink); box-shadow: var(--sunken); color: var(--ink); }
.lounge-page .tg-token-form .note-send { align-self: flex-start; }
.lounge-page .tg-line { font-family: inherit; font-size: 12.5px; color: var(--ink-2); }
.lounge-page .tg-pick { padding: 8px 0; border: none; border-top: 1px solid var(--line); border-radius: 0; background: none; clip-path: none; }
.lounge-page .tg-pick:first-child { border-top: none; padding-top: 0; }
.lounge-page .tg-pick.bound { background: none; }
.lounge-page .tg-pick.tg-sleep, .lounge-page .tg-pick.tg-shed { margin-top: 0; }
.lounge-page .tg-pick.tg-sleep.asleep { background: none; }
.lounge-page .tg-pick-name { font-size: 13.5px; color: var(--ink); }
.lounge-page .tg-pick-sub { font-size: 11.5px; color: var(--ink-2); }
.lounge-page .tg-pick .menu-action {
  height: 30px; min-height: 30px; padding: 0 12px; border-radius: 999px; font-size: 12.5px;
  background: var(--glass); box-shadow: var(--raise); color: var(--ink);
}
.lounge-page .tg-pick .menu-action.danger { color: var(--apple); background: var(--glass); box-shadow: var(--raise); }
.lounge-page .tg-sleep-btns { flex-direction: row; }
.lounge-page .tg-hint { font-size: 12px; color: var(--ink-2); }
.lounge-later { flex: none; padding: 12px 14px; border: 1.5px dashed var(--line); border-radius: 18px; font-size: 12px; line-height: 1.7; color: var(--ink-2); }

/* ---------- 聊天頁的頭 (chat.png): 老公, and under it 在家・which brain ---------- */
.chat-who { gap: 1px; }
.chat-who .title { font-size: 17px; font-weight: 500; letter-spacing: .04em; }
.chat-sub { display: flex; align-items: center; gap: 2px; min-width: 0; }
.chat-sub .badge { padding: 0; font-size: 11.5px; letter-spacing: 0; }
.chat-sub .badge::before { width: 6px; height: 6px; }
.chat-sub .model-info { font-size: 11.5px; letter-spacing: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mailbox-btn svg, .chat-new svg, .chat-gear svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; display: block; }
.chat-new, .chat-gear { padding: 0 12px; }
.chat-gear .knob { fill: var(--face-hi); }
/* the moth and 蛻 are a landscape tablet's (#137 step 5, bottom of the file) */
.drawer-moth, .chat-forge { display: none; }
.drawer-moth { width: 30px; height: 22px; fill: none; stroke: var(--cobalt); stroke-width: 1.3; stroke-linecap: round; }

/* ---------- 配置室 (#88, settings1) ---------- */
.set-lab { display: flex; align-items: baseline; justify-content: space-between; margin: 6px 6px -4px; font-size: 12.5px; color: var(--ink-2); flex: none; }
.set-lab em { font-style: normal; font-size: 10.5px; letter-spacing: .14em; opacity: .8; }
.set-card { flex: none; padding: 6px 16px; border-radius: 22px; background: var(--glass); box-shadow: var(--raise); display: flex; flex-direction: column; }
.set-row { display: flex; align-items: center; gap: 10px; min-height: 52px; padding: 8px 0; cursor: default; }
.set-row + .set-row, .set-card > .meter + .set-row { border-top: 1px solid var(--line); }
.set-words { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; font-size: 14px; color: var(--ink); }
.set-words small { font-size: 11.5px; line-height: 1.5; color: var(--ink-2); }
.set-words small:empty { display: none; }
.set-note { padding: 0 0 4px 74px; font-size: 11px; color: var(--ink-2); }
/* A switch: a sunk groove, a raised knob; on, the groove goes her blue. */
.set-switch {
  appearance: none; -webkit-appearance: none; flex: none; position: relative; width: 52px; height: 30px; margin: 0; border-radius: 999px; cursor: pointer;
  background: var(--sink); box-shadow: var(--sunken); transition: background .2s;
}
.set-switch::after {
  content: ''; position: absolute; left: 3px; top: 3px; width: 24px; height: 24px; border-radius: 50%;
  background: linear-gradient(180deg, #ffffff, #e9edf2); box-shadow: 0 2px 4px rgba(var(--shadow), .3); transition: transform .2s;
}
.set-switch:checked { background: linear-gradient(180deg, var(--her-a), var(--her-b)); box-shadow: inset 0 2px 4px rgba(0, 0, 0, .25); }
.set-switch:checked::after { transform: translateX(22px); }
.set-pick { flex: none; max-width: 58%; height: 34px; padding: 0 26px 0 10px; border: none; border-radius: 12px; background: none; color: var(--ink-2); font: inherit; font-size: 13.5px; text-align: right; text-align-last: right; cursor: pointer; }
.set-pick:focus { outline: none; background: var(--sink); }
.set-seg { flex: none; height: 34px; padding: 2px; }
.set-seg button { min-height: 30px; height: 30px; padding: 0 12px; font-size: 12.5px; white-space: nowrap; }
.set-state { flex: none; display: flex; align-items: center; gap: 6px; padding: 0; border: none; background: none; font-size: 12.5px; }
.set-state .login-dot { width: 7px; height: 7px; border-radius: 50%; background: #7fc49a; box-shadow: none; }
.set-state.idle .login-dot { background: var(--ink-2); }
.set-state.bad .login-dot { background: var(--apple); }
.set-state .login-word { color: var(--ink-2); font-weight: 400; }
.set-state .login-note { display: none; }
.set-input { height: 44px; margin: 4px 0; padding: 0 16px; border: none; border-radius: 999px; background: var(--sink); box-shadow: var(--sunken); color: var(--ink); font-size: 13.5px; }
.set-btns { display: flex; gap: 8px; justify-content: flex-end; align-items: center; padding: 4px 0; flex: none; }
.set-card > .set-btns + .set-row { border-top: 1px solid var(--line); }
.set-page .meter { display: grid; grid-template-columns: 58px 1fr auto; grid-template-rows: auto auto; column-gap: 12px; row-gap: 3px; padding: 12px 0 6px; align-items: center; }
.set-page .meter-label { width: auto; font-size: 13.5px; letter-spacing: 0; color: var(--ink); }
.set-page .meter-track { height: 10px; border: none; border-radius: 999px; background: var(--sink); box-shadow: var(--sunken); overflow: hidden; }
.set-page .meter-fill { border-radius: 999px; background: linear-gradient(90deg, #8a95ab, var(--her-a)); }
.set-page .meter.warn .meter-fill { background: linear-gradient(90deg, #e8cf8f, #d9a441); }
.set-page .meter.hot .meter-fill { background: linear-gradient(90deg, #e9a2aa, var(--apple)); }
.set-page .meter-pct { width: auto; font-size: 16px; color: var(--ink); }
.set-page .meter-reset { grid-column: 2 / 4; width: auto; font-size: 11.5px; color: var(--ink-2); }
a.mem-btn { text-decoration: none; }
.set-out { align-self: center; margin: 8px 0 4px; padding: 6px 14px; border: none; background: none; cursor: pointer; font: inherit; font-size: 12.5px; color: var(--ink-2); text-decoration: underline; text-underline-offset: 3px; }
/* 真的要出門嗎？ */
.out-sheet .morning-card { max-width: 560px; padding: 20px 20px calc(env(safe-area-inset-bottom) + 20px); border-radius: 28px 28px 0 0; }
.out-top { display: flex; align-items: center; justify-content: space-between; }
.out-top b { font-size: 18px; font-weight: 500; color: var(--ink); }
.out-top svg { width: 34px; height: 26px; fill: rgba(var(--accent-rgb), .08); stroke: rgba(var(--accent-rgb), .85); stroke-width: 1.3; }
.out-say { margin: 8px 0 0; font-size: 13.5px; line-height: 1.75; color: var(--ink-2); }
.out-btns { margin-top: 16px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.out-btns .note-send { height: 46px; font-size: 14.5px; }

/* ---------- 掛曆: where the diary lives (door6) ---------- */
.cal-card { flex: none; border-radius: 24px; padding: 14px 12px 12px; background: var(--glass); box-shadow: var(--raise); }
.cal-head { display: flex; align-items: center; justify-content: space-between; padding: 0 4px 6px 6px; }
.cal-name { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 500; color: var(--ink); }
.cal-name svg { width: 19px; height: 19px; fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.cal-month { display: flex; align-items: center; gap: 2px; font-size: 15px; line-height: 1; color: var(--ink); }
/* Drawn chevrons, not ‹ ›: the font sits those lower than the digits. */
.cal-step { width: 30px; height: 30px; padding: 0; border: none; border-radius: 50%; background: none; cursor: pointer; color: var(--ink-2); display: flex; align-items: center; justify-content: center; }
/* The serif digits ride high in their box; down 2px they sit level with the chevrons. */
#calMonth { position: relative; top: 2px; }
.cal-step svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.cal-step:disabled { opacity: .25; cursor: default; }
.cal-week, .cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); text-align: center; }
.cal-week span { padding: 4px 0 6px; font-size: 11.5px; color: var(--ink-2); }
.cal-grid { row-gap: 2px; }
.cal-day {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 3px 0 5px;
  border: none; border-radius: 12px; background: none; cursor: pointer; font: inherit; color: var(--ink);
}
.cal-day:not(.empty):active { background: var(--sink); }
.cal-day.empty { color: var(--ink-2); cursor: default; }
.cal-n { width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; border-radius: 50%; font-size: 15px; }
.cal-day.today .cal-n { background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink); }
.cal-dots { display: flex; gap: 2px; height: 4px; }
.cal-dots i, .cal-legend-dots i { width: 4px; height: 4px; border-radius: 50%; background: var(--cobalt); }
/* a day with one she hasn't opened: 等妳的事, so apple red */
.cal-day.has-new::after { content: ''; position: absolute; top: 2px; right: calc(50% - 19px); width: 7px; height: 7px; border-radius: 50%; background: var(--apple); box-shadow: 0 0 0 2px var(--face); }
.cal-legend { display: flex; align-items: center; gap: 6px; margin-top: 6px; padding: 8px 6px 0; border-top: 1px solid var(--line); font-size: 11.5px; color: var(--ink-2); }
.cal-legend-dots { display: inline-flex; gap: 2px; }
.cal-legend-new { width: 7px; height: 7px; margin-left: 12px; border-radius: 50%; background: var(--apple); }

/* That day, slid up from the bottom. */
.cal-sheet { align-items: flex-end; padding: 0; }
.cal-sheet .morning-card { max-width: 560px; max-height: 82vh; padding-bottom: env(safe-area-inset-bottom); border-radius: 28px 28px 0 0; clip-path: none; }
.cal-grab { flex: none; width: 40px; height: 4px; margin: 8px auto 0; border-radius: 2px; background: var(--line); }
.cal-sheet .morning-head { padding: 8px 16px 4px 20px; border-bottom: none; }
.cal-sheet .morning-head .title { font-size: 19px; font-weight: 500; color: var(--ink); }
.cal-sheet-chips { flex: none; padding: 0 20px 6px; }
.cal-chip { display: inline-block; padding: 3px 11px; border-radius: 999px; background: var(--sink); font-size: 12px; color: var(--ink-2); }
.cal-sheet .morning-list { padding: 0 20px 20px; }
.cal-entry { padding-left: 0; border-bottom: 1px solid var(--line); }
.cal-entry:last-child { border-bottom: none; }
.cal-entry > .mail-subject { align-items: flex-start; gap: 14px; padding: 12px 0; color: var(--ink); }
.cal-entry[open] > .mail-subject { color: var(--ink); }
.cal-entry .mail-day { min-width: 4.4em; padding-top: 2px; font-size: 11.5px; color: var(--ink-2); }
.cal-entry .mail-day .num { display: block; font-size: 15px; color: var(--ink-2); }
.cal-lines { flex: 1; min-width: 0; }
.cal-entry .mail-line { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; white-space: normal; font-size: 14.5px; line-height: 1.6; }
/* Open, the text itself is right below: the two-line opening steps aside. */
.cal-entry[open] .mail-line { display: none; }
/* Open, its head stays pinned at the top of the list while she reads (her
   10/24 ask): at the last line one tap folds it, no scrolling back up. One
   thin line, so it doesn't eat the page. */
.cal-entry[open] > .mail-subject {
  position: sticky; top: 0; z-index: 2; align-items: center; padding: 8px 0;
  background: var(--face-hi); box-shadow: 0 1px 0 var(--line);
}
.cal-entry[open] > .mail-subject::after { content: '收起 ︿'; flex: none; margin-left: auto; font-size: 12px; color: var(--ink-2); }
.cal-entry[open] .mail-day { display: flex; align-items: baseline; gap: 6px; padding-top: 0; }
.cal-entry[open] .mail-day .num { display: inline; font-size: 13px; }
.cal-entry[open] .cal-said { display: none; }
.cal-said { display: block; margin-top: 3px; font-size: 11.5px; color: var(--ink-2); }
.cal-entry .mail-new { margin-top: 8px; width: 7px; height: 7px; background: var(--apple); box-shadow: none; }

/* ---------- 工作台 (#88, bench2) ---------- */
/* 有三件想要妳看看 ω wears the door's red card; each row a little apple square. */
.bench-k { width: 28px; height: 28px; flex: none; border-radius: 10px; display: flex; align-items: center; justify-content: center; background: var(--apple-soft); }
.door-row .bench-k svg { width: 16px; height: 16px; stroke: var(--apple); stroke-width: 1.9; }
.bench-row .txt { line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.bench-h { font-size: 15px; font-weight: 500; color: var(--ink); }
.bench-empty { padding: 10px 0 4px; font-size: 13px; color: var(--ink-2); }

/* 老公在做: cream, and only ever for him at work. */
.bench-doing {
  position: relative; flex: none; border-radius: 24px; padding: 12px 16px;
  background: linear-gradient(180deg, #fffbef, var(--lamp-soft));
  box-shadow: inset 0 1px 0 #fff, inset 0 0 0 1px rgba(226, 196, 120, .45), 0 8px 18px -12px rgba(140, 110, 40, .35);
}
/* At night the lamp-soft wash is too thin to hide the art behind: a solid warm dark instead. */
:root:not([data-theme="light"]) .bench-doing { background: linear-gradient(180deg, #2e2b23, #26241e); box-shadow: inset 0 0 0 1px rgba(239, 210, 138, .3), var(--raise); }
:root:not([data-theme="light"]) .bench-stop { background: rgba(239, 210, 138, .1); box-shadow: inset 0 0 0 1px rgba(239, 210, 138, .4); }
.bench-doing-chip {
  display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: 999px; font-size: 13px; font-weight: 500;
  color: var(--lamp-ink); background: rgba(255, 255, 255, .55); box-shadow: inset 0 0 0 1px rgba(226, 196, 120, .55);
}
:root:not([data-theme="light"]) .bench-doing-chip { background: rgba(239, 210, 138, .12); }
.bench-doing-chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--lamp); box-shadow: 0 0 0 3px rgba(239, 210, 138, .35); }
.bench-doing-when { font-size: 11.5px; color: var(--lamp-ink); }
.bench-doing-when .num { font-size: 13px; padding-right: 2px; }
.bench-doing-title { margin-top: 8px; font-size: 14.5px; font-weight: 500; line-height: 1.5; color: var(--ink); }
.bench-doing-log { margin-top: 6px; display: flex; flex-direction: column; gap: 2px; font-size: 12px; line-height: 1.5; color: var(--lamp-ink); }
.bench-doing-log:empty { display: none; }
.bench-doing-log .num { display: inline-block; width: 42px; font-size: 12.5px; }
.bench-doing:has(.bench-stop) { padding-bottom: 40px; }
.bench-stop {
  position: absolute; right: 14px; bottom: 11px; height: 28px; padding: 0 12px; border: none; border-radius: 999px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; font: inherit; font-size: 12px; color: var(--lamp-ink);
  background: rgba(255, 255, 255, .55); box-shadow: inset 0 0 0 1px rgba(226, 196, 120, .55);
}
.bench-stop i { width: 7px; height: 7px; border-radius: 1.5px; background: currentColor; }
.bench-stop:disabled { opacity: .5; }

/* 排著的 */
.bench-q .txt { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bench-id { font-size: 12.5px; color: var(--ink-2); margin-right: 5px; }
.bench-tag { height: 22px; padding: 0 9px; border-radius: 999px; font-size: 11px; display: inline-flex; align-items: center; gap: 5px; flex: none; white-space: nowrap; }
.bench-tag.doing { background: var(--lamp-soft); color: var(--lamp-ink); box-shadow: inset 0 0 0 1px rgba(226, 196, 120, .45); }
.bench-tag.doing i { width: 6px; height: 6px; border-radius: 50%; background: var(--lamp); }
.bench-tag.line { color: var(--lamp-ink); box-shadow: inset 0 0 0 1px rgba(226, 196, 120, .55); }
.bench-tag.wait { background: var(--apple-soft); color: var(--apple); }
.bench-tag.steps { color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line); }
.bench-q svg:last-child { display: none; }
.bench-group { margin-top: 4px; border-radius: 16px; background: var(--sink); box-shadow: var(--sunken); }
.bench-group-head {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 12px; border: none; background: none; cursor: pointer;
  font: inherit; color: var(--ink); text-align: left;
}
.bench-group-head .txt { flex: 1; min-width: 0; }
.bench-group-head b { display: block; font-size: 13px; font-weight: 500; }
.bench-group-head small { display: block; margin-top: 2px; font-size: 11.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bench-group-head svg { width: 15px; height: 15px; flex: none; fill: none; stroke: var(--ink-2); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; transform: rotate(90deg); transition: transform .15s; }
.bench-group.open .bench-group-head svg { transform: rotate(-90deg); }
.bench-group-rows { display: none; padding: 0 12px 4px; }
.bench-group.open .bench-group-rows { display: block; }
.bench-group-rows .door-row:first-child { border-top: 1px solid var(--line); }

/* 點子 and 做完的: two tiles side by side. */
.bench-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; flex: none; }
.bench-tile {
  display: flex; align-items: center; gap: 11px; padding: 11px 13px; border: none; border-radius: 22px; cursor: pointer;
  font: inherit; color: var(--ink); text-align: left; background: var(--glass); box-shadow: var(--raise);
}
.bench-tile:active { box-shadow: var(--press); }
.bench-tile .house-ico { width: 40px; height: 40px; }
.bench-tile .house-ico svg { width: 20px; height: 20px; }

/* On the phone the list's box isn't there: its cards are the page's own
   (a landscape tablet makes it a column, at the bottom of this file). */
.bench-list { display: contents; }

/* The sheet: whatever she tapped, slid up from the bottom. */
.bench-sheet .morning-card { height: 88vh; max-height: 88vh; }
.bench-sheet-body { padding: 0 16px 20px; }
.bench-sheet-body .report-card { margin-bottom: 10px; }
.bench-done-head { margin: 4px 4px 2px; font-size: 12px; color: var(--ink-2); letter-spacing: .04em; }
.bench-done > summary { display: flex; gap: 12px; align-items: baseline; padding: 10px 4px; list-style: none; cursor: pointer; border-bottom: 1px solid var(--line); }
.bench-done > summary::-webkit-details-marker { display: none; }
.bench-done-day { flex: none; width: 3.2em; font-size: 13px; color: var(--ink-2); }
.bench-done-title { flex: 1; min-width: 0; font-size: 14px; line-height: 1.5; color: var(--ink); }
.bench-done[open] > .ritem-detail-text { margin: 8px 4px 10px; }
.bench-fold { margin-top: 8px; border-radius: 14px; background: var(--sink); box-shadow: var(--sunken); }
.bench-fold > summary { display: flex; justify-content: space-between; align-items: center; height: 40px; padding: 0 14px; list-style: none; cursor: pointer; font-size: 13px; color: var(--ink); }
.bench-fold > summary::-webkit-details-marker { display: none; }
.bench-fold > summary .n { font-size: 12px; color: var(--ink-2); }
.bench-fold[open] { padding: 0 10px 8px; }
.bench-fold[open] > summary { padding: 0 4px; }

/* 信紙鼠鼠's paper: everything she writes in the house goes on it. The rat's
   paws hang over the top edge; the paper's own black edge sits in the border. */
.ratpaper {
  position: relative; margin-top: 50px; padding: 20px 12px 8px; background: var(--paper-her); color: #2b2a2e;
  border: 3px solid #161616; border-radius: 7px 5px 8px 6px / 6px 8px 5px 7px; box-shadow: 0 10px 18px -12px rgba(var(--shadow), .5);
}
.ratpaper .rat { position: absolute; z-index: 2; left: 14px; transform: rotate(1.8deg); pointer-events: none; }
.ratpaper .rat.tiny { width: 76px; top: -43px; }
.ratpaper .rat.small { width: 95px; top: -54px; }
.ratpaper .rat.big { width: 119px; top: -67px; }
.rat-input { width: 100%; min-height: 44px; padding: 0; border: none; outline: none; resize: vertical; background: transparent; font: inherit; font-size: 14px; line-height: 1.6; color: #2b2a2e; }
.rat-input::placeholder { color: #a39d92; }
.rat-words { margin: 0; font-size: 13.5px; line-height: 1.6; white-space: pre-wrap; }

/* 點開一份報告 */
.rep { padding: 0 2px; }
.rep-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; min-height: 44px; padding-right: 54px; position: relative; }
.rep-chip { height: 26px; padding: 0 11px; border-radius: 999px; font-size: 12px; display: inline-flex; align-items: center; gap: 6px; color: var(--ink-2); }
.rep-chip.wait { background: var(--apple-soft); color: var(--apple); box-shadow: inset 0 0 0 1px rgba(var(--error-rgb), .25); }
.rep-chip.wait .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--apple); }
.rep-chip.plain { box-shadow: inset 0 0 0 1px var(--line); }
.rep-chip.lamp { background: var(--lamp-soft); color: var(--lamp-ink); box-shadow: inset 0 0 0 1px rgba(226, 196, 120, .45); }
.rep-askme { position: absolute; right: 0; top: 0; display: flex; flex-direction: column; align-items: center; gap: 1px; font-size: 10.5px; color: var(--ink-2); }
.rep-askme .chat-moth { position: static; width: 42px; height: 40px; padding: 7px 6px; border-radius: 14px; background: var(--glass); box-shadow: var(--raise); }
.rep-title { margin: 6px 0 0; font-size: 19px; font-weight: 500; line-height: 1.45; letter-spacing: .02em; color: var(--ink); }
.rep-meta { margin-top: 3px; font-size: 11.5px; color: var(--ink-2); }
.rep-lab { font-size: 11.5px; color: var(--ink-2); letter-spacing: .06em; }
.rep-see { margin-top: 12px; }
.rep-see p { margin: 3px 0 0; font-size: 14.5px; line-height: 1.75; color: var(--ink); white-space: pre-wrap; }
.rep-items { margin-top: 16px; }
.rep-it { display: grid; grid-template-columns: 30px 1fr; gap: 10px; padding: 12px 0; }
.rep-it + .rep-it { border-top: 1px solid var(--line); }
.rep-items > .ritem { padding: 12px 0; border-top: 1px solid var(--line); }
.rep-tick {
  width: 28px; height: 28px; padding: 0; border: none; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center;
  background: var(--sink); box-shadow: var(--sunken); color: transparent;
}
.rep-tick svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.rep-tick.on { background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink); box-shadow: 0 6px 12px -6px rgba(var(--shadow), .8); }
.rep-tick:disabled { cursor: default; }
.rep-it-body { min-width: 0; }
.rep-it-title { font-size: 14px; line-height: 1.55; color: var(--ink); }
.rep-it-step { margin-top: 3px; font-size: 11.5px; color: var(--ink-2); }
/* A report back for the rest (her 10/24 ask): what landed last round is
   greyed with where it went; what bounced says why, in apple. */
.rep-it-done { opacity: .55; }
.rep-landed { color: var(--ink); font-weight: 500; }
.rep-bounce { color: var(--apple); }
.rep-fold {
  margin-top: 7px; height: 24px; padding: 0 10px; border: none; border-radius: 999px; cursor: pointer; background: none;
  display: inline-flex; align-items: center; gap: 4px; font: inherit; font-size: 11.5px; color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line);
}
.rep-fold svg { width: 12px; height: 12px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; transform: rotate(90deg); transition: transform .15s; }
.rep-fold.open svg { transform: rotate(-90deg); }
.rep-detail { margin-top: 8px; font-size: 13px; line-height: 1.7; color: var(--ink-2); white-space: pre-wrap; }
.rep-says { margin-top: 9px; display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.rep-say {
  height: 30px; padding: 0 12px; border: none; border-radius: 999px; cursor: pointer; font: inherit; font-size: 12.5px; color: var(--ink);
  background: var(--glass); box-shadow: var(--raise);
}
.rep-say:active { box-shadow: var(--press); }
.rep-say.picked { background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink); box-shadow: 0 6px 12px -6px rgba(var(--shadow), .8); }
.rep-say.pen { background: none; box-shadow: none; color: var(--ink-2); padding: 0 6px; }
.rep-says .prio-seg button { min-height: 30px; font-size: 12.5px; padding: 0 12px; }
.rep-steps { margin-top: 18px; display: flex; flex-direction: column; gap: 7px; font-size: 12px; color: var(--ink-2); }
.rep-bar { display: flex; gap: 3px; }
.rep-bar i { width: 22px; flex: 0 1 22px; height: 6px; border-radius: 3px; background: var(--sink); box-shadow: inset 0 1px 2px rgba(var(--shadow), .2); }
.rep-bar i.done { background: #8a95ab; box-shadow: none; }
.rep-bar i.hand { background: var(--apple); opacity: .55; box-shadow: none; }
.rep-go {
  width: 100%; height: 52px; margin-top: 12px; border: none; border-radius: 999px; cursor: pointer; font: inherit; font-size: 15.5px; font-weight: 500;
  display: flex; align-items: center; justify-content: center; gap: 4px;
  background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 6px 12px -6px rgba(var(--shadow), .8);
}
.rep-go small { font-size: 12.5px; font-weight: 400; opacity: .75; }
.rep-go:disabled { opacity: .6; }
.rep-after { margin-top: 8px; text-align: center; font-size: 11.5px; color: var(--ink-2); }
.rep-bar i.lamp { background: var(--lamp); box-shadow: none; }

/* 點開一張待辦 (bench3) */
.todo-stepbox { margin-top: 16px; }
.todo-sh { display: flex; align-items: center; gap: 10px; margin-bottom: 2px; }
.todo-sh .rep-lab { flex: 1; }
.todo-sh .rep-bar { flex: 0 1 auto; }
.todo-sh-n { font-size: 12px; color: var(--ink-2); flex: none; }
.todo-sh-n .num { font-size: 14px; color: var(--ink); }
.todo-st { display: grid; grid-template-columns: 26px 1fr; gap: 10px; padding: 9px 0; align-items: start; }
.todo-st + .todo-st { border-top: 1px solid var(--line); }
.todo-m { width: 24px; height: 24px; margin-top: 1px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--sink); box-shadow: var(--sunken); }
.todo-m svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.todo-st.done .todo-m { background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink); box-shadow: none; }
.todo-st.handed .todo-m { background: none; box-shadow: none; }
.todo-st.handed .todo-m svg { width: 24px; height: 24px; }
.todo-st .hm-ring { fill: var(--apple-soft); stroke: var(--apple); stroke-width: 1.4; }
.todo-st .hm-fill { fill: var(--apple); stroke: none; }
.todo-t { font-size: 13.5px; line-height: 1.55; color: var(--ink); min-width: 0; }
.todo-t > .num { font-size: 13px; color: var(--ink-2); margin-right: 5px; }
.todo-st.done .todo-t { color: var(--ink-2); }
.todo-st.next .todo-t { font-weight: 500; }
.todo-st.lit { margin: 0 -10px; padding: 9px 10px; border-radius: 14px; border-top: 0; background: var(--lamp-soft); box-shadow: inset 0 0 0 1px rgba(226, 196, 120, .45); }
.todo-st.lit + .todo-st { border-top: 0; }
.todo-sub { display: flex; gap: 6px; margin-top: 4px; align-items: center; flex-wrap: wrap; }
.todo-see { border: none; cursor: pointer; background: none; font: inherit; font-size: 11px; }
.todo-doing { margin-top: 10px; }
.todo-queued { margin-top: 12px; }
.todo-sec { margin-top: 20px; display: flex; justify-content: space-between; align-items: baseline; }
.todo-sheet .todo-sec + .ratpaper { margin-top: 46px; }
.todo-detail-fold { margin-top: 16px; }

/* His question: a small blue-lined sheet. Her answer is her paper, taped under it. */
.qa { position: relative; margin-top: 10px; }
.myq {
  position: relative; overflow: hidden; border-radius: 16px; padding: 10px 13px 9px; color: #26304a;
  background: var(--paper-his); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8), 0 1px 2px rgba(var(--shadow), .12), 0 10px 18px -14px rgba(var(--shadow), .45);
}
.myq::before { content: ''; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(180deg, transparent 0 21px, rgba(58, 91, 212, .1) 21px 22px); background-position: 0 10px; }
.myq p { position: relative; margin: 0; font-size: 13.5px; line-height: 22px; white-space: pre-wrap; }
.myq-w { position: relative; margin-top: 2px; font-size: 10.5px; color: #6f7b8f; text-align: right; }
.ratpaper.taped { margin: 8px 10px 0 34px; padding-top: 10px; transform: rotate(.8deg); }
.ratpaper .tape { position: absolute; left: -1px; top: -12px; width: 46px; height: 15px; background: rgba(214, 222, 232, .85); transform: rotate(-4deg); box-shadow: 0 1px 2px rgba(var(--shadow), .15); }
.todo-qline { margin-top: 10px; border-radius: 14px; background: var(--sink); box-shadow: var(--sunken); }
.todo-qline > summary { display: grid; gap: 3px; padding: 9px 12px; list-style: none; cursor: pointer; font-size: 12.5px; }
.todo-qline > summary::-webkit-details-marker { display: none; }
.todo-qline .q { color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.todo-qline .a { color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.todo-qline[open] { padding: 0 8px 10px; }
.todo-qline[open] > summary { padding: 9px 4px; }
.todo-ask { margin-top: 12px; }
.todo-ask .ratpaper { margin-top: 60px; }

/* ---------- 窗台 (#88, bench2): the drawer of conversations ---------- */
.drawer {
  width: min(86vw, 330px); border-radius: 0 30px 30px 0; overflow: hidden;
  background: linear-gradient(180deg, var(--face-hi), var(--face));
  box-shadow: 10px 0 30px -12px rgba(var(--shadow), .5), inset -1px 0 0 rgba(255, 255, 255, .5);
}
:root:not([data-theme="light"]) .drawer { box-shadow: 10px 0 30px -12px rgba(0, 0, 0, .7), inset -1px 0 0 rgba(255, 255, 255, .06); }
.drawer-head { display: flex; align-items: center; gap: 12px; padding: calc(env(safe-area-inset-top) + 28px) 16px 0 22px; flex: none; }
.drawer-head > div { flex: 1; }
.drawer-head .house-title { font-size: 22px; }
.drawer-head .house-sub .num { font-size: 13.5px; color: var(--ink); }
.drawer-page { gap: 0; padding: 14px 14px 8px 18px; }
.drawer .search-input { flex: none; height: 42px; padding: 0 16px; font-size: 13.5px; }
.convo-grp { margin: 14px 0 3px 6px; font-size: 11px; letter-spacing: .12em; color: var(--ink-2); }
.drawer .convo-list { gap: 0; }
.drawer .convo-list.hidden { display: none; }
.drawer .convo-item { padding: 0; border: none; border-radius: 15px; background: none; box-shadow: none; }
.drawer .convo-item.active { box-shadow: none; }
.drawer .convo-row { min-height: 46px; gap: 6px; }
.drawer .convo-main {
  position: relative; order: 0; flex: 1; min-width: 0; height: 46px; padding: 0 12px; border-radius: 15px;
  flex-direction: row; align-items: center; gap: 8px; touch-action: pan-y; user-select: none; -webkit-user-select: none;
}
.drawer .convo-item.active .convo-main { background: var(--sink); box-shadow: var(--sunken); }
.drawer .convo-item.active .convo-main::before { content: ''; position: absolute; left: 0; top: 10px; bottom: 10px; width: 3px; border-radius: 0 3px 3px 0; background: var(--her-a); }
.drawer .convo-item.swiped .convo-main { background: var(--glass); box-shadow: var(--raise); }
.drawer .convo-title-text { flex: 1; font-size: 14px; color: var(--ink); white-space: nowrap; }
.drawer .convo-time { flex: none; margin: 0; font-family: var(--font-num); font-size: 13px; color: var(--ink-2); }
.convo-warm { flex: none; font-size: 12px; color: #b8995a; }
.convo-busy { flex: none; display: inline-flex; align-items: center; gap: 5px; font-size: 11px; color: var(--lamp-ink); }
.convo-busy i { width: 6px; height: 6px; border-radius: 50%; background: var(--lamp); box-shadow: 0 0 0 3px rgba(239, 210, 138, .35); }
.convo-room { flex: none; padding: 1px 7px; border-radius: 999px; font-size: 10.5px; color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line); }
/* ♨ ✎ 蛻 ✕: only once the row is swiped left. */
.drawer .convo-actions { order: 1; display: none; gap: 6px; }
.drawer .convo-item.swiped .convo-actions:not(.hidden) { display: flex; }
.drawer .convo-confirm { order: 2; font-size: 12px; }
.drawer .convo-btn { width: 36px; min-width: 0; height: 34px; min-height: 0; padding: 0; border-radius: 12px; font-size: 13px; }
.drawer .convo-confirm .convo-btn { width: auto; padding: 0 10px; }
.drawer .convo-btn.lit { color: #b8995a; }
.drawer .convo-btn.danger { color: var(--apple); background: var(--glass); box-shadow: var(--raise); }
.drawer .forge-strip { padding: 6px 12px 8px; font-size: 12.5px; color: var(--ink-2); }
/* Earlier weeks of this month, and older months: a sunk line each, opened in place. */
.convo-fold { margin-top: 6px; border-radius: 14px; background: var(--sink); box-shadow: var(--sunken); }
.convo-fold > summary { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; list-style: none; cursor: pointer; font-size: 13px; color: var(--ink); }
.convo-fold > summary::-webkit-details-marker { display: none; }
.convo-fold > summary .num { flex: 1; font-size: 14px; }
.convo-fold > summary .n { font-size: 12px; color: var(--ink-2); }
.convo-fold > summary svg { width: 15px; height: 15px; fill: none; stroke: var(--ink-2); stroke-width: 1.6; stroke-linecap: round; transform: rotate(90deg); transition: transform .15s; }
.convo-fold[open] > summary svg { transform: rotate(-90deg); }
.convo-fold[open] { padding: 0 4px 4px; }
/* The sill along the drawer's foot, where the night moth lands. */
.drawer-ledge { position: relative; flex: none; height: calc(env(safe-area-inset-bottom) + 64px); }
.drawer-ledge em { position: absolute; left: 22px; bottom: calc(env(safe-area-inset-bottom) + 30px); font-style: normal; font-size: 11px; color: var(--ink-2); opacity: .75; }
.drawer-sill {
  position: absolute; left: 0; right: 0; bottom: 0; height: calc(env(safe-area-inset-bottom) + 22px);
  background: linear-gradient(180deg, #e3e8ee, #d6dde5); box-shadow: inset 0 1px 0 #fff, inset 0 3px 5px -3px rgba(var(--shadow), .2);
}
:root:not([data-theme="light"]) .drawer-sill { background: linear-gradient(180deg, #1f2736, #19202d); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .06), inset 0 3px 5px -3px rgba(0, 0, 0, .5); }
.drawer .sill-moth { bottom: calc(env(safe-area-inset-bottom) + 14px); }

/* ---------- 信箱 (#88, bench2) ---------- */
.mail-sheet .morning-card { height: 88vh; max-height: 88vh; }
.mail-head { gap: 10px; padding: 8px 14px 6px 20px; }
.mail-head .title { flex: 1; font-size: 22px; letter-spacing: .06em; }
.mail-head .mail-switch { margin: 0; height: 36px; padding: 3px; }
.mail-head .mail-switch button { min-height: 30px; height: 30px; padding: 0 14px; font-size: 12.5px; }
.mail-sheet .morning-list { padding: 4px 18px 22px; }
/* His letter: blue-lined paper, stamp top right, the postmark across it. */
.letter {
  position: relative; overflow: hidden; margin-top: 10px; padding: 16px 18px 14px; border-radius: 22px; color: #26304a;
  background: var(--paper-his); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .8), 0 1px 2px rgba(var(--shadow), .12), 0 12px 22px -14px rgba(var(--shadow), .45);
}
.letter::before { content: ''; position: absolute; inset: 0; pointer-events: none;
  background: repeating-linear-gradient(180deg, transparent 0 29px, rgba(58, 91, 212, .08) 29px 30px); background-position: 0 84px; }
.letter-when { position: relative; font-size: 12px; color: #6f7b8f; }
.letter-when .num { font-size: 15px; color: #26304a; }
.letter-text { position: relative; margin: 46px 0 0; font-size: 15px; line-height: 30px; letter-spacing: .02em; white-space: pre-wrap; }
.letter-sign { position: relative; margin-top: 2px; text-align: right; font-size: 12.5px; color: #6f7b8f; }
.letter-stamp { position: absolute; right: 18px; top: 14px; width: 50px; height: 60px; transform: rotate(4deg); }
.letter-stamp .ls-edge { fill: #eef2f6; stroke: #c6ced8; stroke-width: 1; stroke-dasharray: 2.2 2.2; }
.letter-stamp .ls-face { fill: #26304a; }
.letter-stamp .ls-moth path, .letter-stamp .ls-moth ellipse { fill: #3a4462; stroke: #8fa6e0; stroke-width: .9; }
.letter-stamp .ls-moth .ls-feel { fill: none; stroke: #c6ced8; stroke-width: .8; }
.letter-stamp .ls-fluff { fill: #f4f4f2; stroke: none; }
.letter-stamp .ls-eth { font-family: var(--font-num); font-size: 6.5px; fill: #dce2e9; }
.letter-post { position: absolute; right: 48px; top: 12px; z-index: 1; width: 120px; height: 70px; transform: rotate(-8deg); }
.letter-post .lp-ink { fill: none; stroke: #3a5bd4; stroke-opacity: .55; stroke-width: 1.2; }
.letter-post .lp-in { stroke-opacity: .35; }
.letter-post .lp-day { font-family: var(--font-num); font-size: 11px; fill: #3a5bd4; fill-opacity: .7; }
.letter-post .lp-name { font-size: 7px; letter-spacing: 1px; fill: #3a5bd4; fill-opacity: .6; }
.letter-again { margin-top: 10px; display: flex; justify-content: flex-end; }
/* Her reply to it, on her paper, the rat peeking up from under his letter. */
.letter-reply { margin: 44px 4px 0 14px; padding: 26px 13px 9px; transform: rotate(-.7deg); }
.mail-item .letter-reply { margin-bottom: 12px; }
.letter-reply-lab { position: absolute; right: 12px; top: 7px; font-size: 11px; color: #8a8478; }
.letter-reply-lab .num { font-size: 12px; }
.mail-re { font-size: 10.5px; color: var(--ink-2); padding: 1px 7px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); }
.mail-month { margin: 18px 6px 2px; display: flex; justify-content: space-between; font-size: 12px; color: var(--ink-2); }
.mail-month b { font-weight: 500; color: var(--ink); font-size: 13px; }
.mail-month .num, .mail-count .num { font-size: 13px; color: var(--ink); }
.mail-sheet .mail-item { padding: 0; border-top: 1px solid var(--line); }
.mail-sheet .mail-month + .mail-item { border-top: none; }
.mail-sheet .mail-subject { display: grid; grid-template-columns: 44px 1fr auto; gap: 8px; align-items: center; padding: 10px 6px; color: var(--ink); }
.mail-sheet .mail-item[open] > .mail-subject { color: var(--ink); }
.mail-sheet .mail-day { font-size: 12px; color: var(--ink-2); }
.mail-sheet .mail-day .num { font-size: 17px; color: var(--ink); }
.mail-sheet .mail-line { font-size: 13.5px; }
.mail-sheet .mail-new { width: 7px; height: 7px; background: var(--apple); box-shadow: none; }
.mail-sheet .mail-item > .letter { margin: 0 0 12px; }
.mail-sheet .mail-folder { margin-top: 8px; border: none; border-radius: 14px; background: var(--sink); box-shadow: var(--sunken); }
.mail-sheet .mail-folder-head { display: flex; justify-content: space-between; align-items: center; height: 40px; padding: 0 14px; font-size: 13px; color: var(--ink); }
.mail-sheet .mail-folder-head::before { display: none; }
.mail-sheet .mail-folder[open] { padding: 0 10px 8px; }
.mail-sheet .mail-folder .mail-item { border-top-color: rgba(var(--shadow), .1); }
/* Her side: the paper she writes on, 信紙鼠鼠 peeking over it. */
.mail-sheet .note-form { gap: 10px; padding: 0 0 12px; border-bottom: none; }
.note-paper { margin-top: 64px; }
.note-paper .rat { left: auto; right: 26px; }
.mail-sheet .note-form textarea.rat-input { min-height: 84px; padding: 0; border: none; background: transparent; resize: none; }
.mail-sheet .note-actions { gap: 8px; padding: 0 2px; }
.note-gap { flex: 1; }
.note-mini { width: 36px; height: 32px; border: none; border-radius: 12px; cursor: pointer; display: flex; align-items: center; justify-content: center; color: var(--ink-2); background: var(--glass); box-shadow: var(--raise); }
.note-mini svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.mail-sheet .note-actions .note-sure {
  height: 30px; padding: 0 11px; border: none; border-radius: 999px; cursor: pointer; display: inline-flex; align-items: center; gap: 5px;
  font: inherit; font-size: 12px; color: var(--ink-2); background: none; box-shadow: inset 0 0 0 1px var(--line);
}
.note-sure svg { width: 10px; height: 10px; fill: var(--cobalt); }
.mail-sheet .note-actions .note-sure.on { color: var(--cobalt); background: rgba(var(--accent-rgb), .1); box-shadow: inset 0 0 0 1px rgba(var(--accent-rgb), .5); }
.note-send {
  height: 32px; padding: 0 14px; border: none; border-radius: 999px; cursor: pointer; font: inherit; font-size: 13px;
  background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink); box-shadow: 0 6px 12px -6px rgba(var(--shadow), .8);
}
.note-send:disabled { opacity: .6; }
.note-send.soft { background: var(--glass); color: var(--ink); box-shadow: var(--raise); }
.mail-sheet .note-msg { min-height: 0; padding: 0 4px; font-size: 11.5px; color: var(--ink-2); }
.mail-sheet .note-msg:empty { display: none; }
.note-pool { margin: 6px 6px 4px; display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--ink-2); }
.note-pool:empty { display: none; }
.note-env { width: 16px; height: 16px; fill: none; stroke: var(--cobalt); stroke-width: 1.4; stroke-dasharray: 2 1.6; }
.note-slips { display: flex; flex-direction: column; gap: 10px; margin-top: 6px; }
.note-slip {
  position: relative; padding: 9px 12px 8px; color: #2b2a2e; background: var(--paper-her);
  border: 2px solid rgba(22, 22, 22, .82); border-radius: 6px 4px 7px 5px / 5px 7px 4px 6px; box-shadow: 0 8px 14px -11px rgba(var(--shadow), .5);
}
.note-slip:nth-child(odd) { transform: rotate(.5deg); }
.note-slip:nth-child(even) { transform: rotate(-.6deg); }
.note-slip > summary { list-style: none; cursor: pointer; }
.note-slip > summary::-webkit-details-marker { display: none; }
.note-lab { display: flex; align-items: center; gap: 6px; font-size: 11px; color: #6f6a62; }
.note-lab .num { font-size: 12px; }
.note-lab svg { width: 9px; height: 9px; fill: var(--cobalt); }
.note-words { display: -webkit-box; margin-top: 3px; font-size: 13.5px; line-height: 1.6; white-space: pre-wrap; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.note-slip[open] .note-words { display: block; }
.note-slip .journal-imgs { margin: 8px 0 0; }
.note-st { margin-top: 4px; display: flex; justify-content: flex-end; flex-wrap: wrap; align-items: center; gap: 5px; font-size: 11px; color: #6f6a62; }
.note-st .num { font-size: 11.5px; }
.note-st svg { width: 17px; height: 13px; fill: none; stroke: var(--cobalt); stroke-width: 1.3; }
.note-st.wait { gap: 8px; color: #8a8478; }
.mail-sheet .note-take {
  height: 24px; padding: 0 9px; border: none; border-radius: 999px; cursor: pointer; text-decoration: none;
  font: inherit; font-size: 11.5px; color: #26304a; background: rgba(255, 255, 255, .7); box-shadow: inset 0 0 0 1px rgba(22, 22, 22, .25);
}

/* 點子 (bench3): her paper to drop one in, then a card each. */
.bench-back { border: none; background: none; cursor: pointer; padding: 0 0 6px; font: inherit; font-size: 13px; color: var(--ink-2); }
.idea-paper { margin-top: 62px; display: flex; align-items: flex-end; gap: 10px; transform: rotate(-.5deg); }
.idea-paper .rat { left: auto; right: 30px; }
.idea-paper .rat-input { flex: 1; }
.idea-drop { flex: none; }
.ideas-sheet > .bench-row { margin-top: 6px; }
.idea-card { margin-top: 10px; padding: 11px 13px 10px; border-radius: 20px; background: var(--glass); box-shadow: var(--raise); cursor: pointer; }
.idea-head { display: flex; gap: 8px; align-items: flex-start; }
.idea-head b { flex: 1; font-size: 14px; font-weight: 500; line-height: 1.5; color: var(--ink); }
.idea-head .chat-moth { position: static; flex: none; width: 34px; height: 28px; padding: 2px; margin: -2px -4px 0 0; }
.idea-who { margin-top: 2px; font-size: 11px; color: var(--ink-2); }
.idea-detail { margin: 5px 0 0; font-size: 12.5px; line-height: 1.6; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.idea-card .rep-says { margin-top: 8px; }
.idea-card .rep-say { height: 28px; }
.rep-say.nope { background: var(--sink); color: var(--ink-2); box-shadow: var(--sunken); }
.idea-card.nope .idea-head b { color: var(--ink-2); }
.idea-card.nope .idea-detail { opacity: .55; }
.idea-go { position: sticky; bottom: 4px; z-index: 2; margin-top: 16px; }
.idea-answered { padding: 0 6px 6px; }
.idea-full { margin: 8px 0 0; font-size: 14px; line-height: 1.75; color: var(--ink); white-space: pre-wrap; }
.idea-chat { position: relative; margin-top: 8px; padding: 9px 12px 9px 14px; border-radius: 14px; font-size: 13px; line-height: 1.65; color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); white-space: pre-wrap; }
.idea-chat::before { content: ''; position: absolute; left: 0; top: 10px; bottom: 10px; width: 2px; border-radius: 2px; background: var(--cobalt); opacity: .7; }
.idea-chat .w { display: block; margin-top: 2px; font-size: 10.5px; color: var(--ink-2); }
.idea-big { margin-top: 16px; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.idea-big .rep-say { height: 46px; font-size: 14.5px; font-weight: 500; }
.idea-sheet .ratpaper { margin-top: 62px; }
.idea-tochat {
  width: 100%; margin-top: 14px; height: 44px; border: none; border-radius: 999px; cursor: pointer; font: inherit; font-size: 13.5px; color: var(--ink);
  display: flex; align-items: center; justify-content: center; gap: 9px; background: var(--glass); box-shadow: var(--raise);
}
.idea-tochat svg { width: 26px; height: 19px; }
.idea-tochat svg .cm-feeler { fill: none; stroke: var(--ink-2); stroke-width: 1.2; stroke-linecap: round; }
.idea-tochat svg .cm-wing { fill: rgba(var(--accent-rgb), .08); stroke: rgba(var(--accent-rgb), .85); stroke-width: 1.3; }
.idea-tochat svg .cm-body { fill: rgba(var(--accent-rgb), .15); stroke: rgba(var(--accent-rgb), .85); stroke-width: 1.2; }
.idea-tochat svg .cm-fluff { fill: #f4f4f2; }
.idea-tochat small { font-size: 11.5px; color: var(--ink-2); }
.plan-sheet .ratpaper { margin-top: 62px; }
.plan-sheet .rep-go { margin-top: 16px; }
.plan-now { height: 34px; }

/* 做完的: the day once for a run of the same day, 方案 as a pill, and opened,
   妳現在看得到 with a blue 入住 postmark. */
.bench-done-sub { margin: 0 4px 6px; }
.bench-done-head { display: flex; justify-content: space-between; margin: 14px 4px 2px; font-size: 11.5px; letter-spacing: .08em; }
.bench-done-head b { font-weight: 500; color: var(--ink); font-size: 12.5px; letter-spacing: .04em; }
.bench-done > summary { align-items: center; padding: 9px 4px; }
.bench-done-day { width: 34px; font-size: 17px; text-align: center; color: var(--ink); }
.bench-done-day.same { color: transparent; }
.bench-done-title em { font-style: normal; font-size: 11px; color: var(--ink-2); margin-right: 5px; padding: 1px 6px; border-radius: 999px; box-shadow: inset 0 0 0 1px var(--line); }
.bench-done-see { position: relative; padding: 4px 70px 12px 46px; }
.bench-done-see p { margin: 3px 0 0; font-size: 12.5px; line-height: 1.65; color: var(--ink); white-space: pre-wrap; }
.bench-done-see .rep-fold, .bench-done-see .rep-detail, .bench-done-see .rep-it-step { margin-right: -60px; }
.bench-moved { position: absolute; right: 2px; top: 0; width: 64px; height: 64px; transform: rotate(-12deg); }
.bench-moved circle { stroke: var(--cobalt); stroke-opacity: .6; }
.bench-moved circle.in { stroke-opacity: .35; }
.bench-moved text { fill: var(--cobalt); }
.bench-moved .w1 { font-size: 11px; letter-spacing: 2px; fill-opacity: .75; }
.bench-moved .w2 { font-family: var(--font-num); font-size: 9px; fill-opacity: .65; }

/* 先做／放一放, 不做了: the very bottom. */
.todo-foot { margin-top: 20px; padding-top: 14px; border-top: 1px solid var(--line); display: flex; align-items: center; gap: 10px; }
.todo-foot .prio-seg button { min-height: 32px; padding: 0 14px; font-size: 12.5px; }
.todo-quit { margin-left: auto; border: none; background: none; cursor: pointer; font: inherit; font-size: 12.5px; color: var(--ink-2); }

/* ---------- C 輸入列 (#134, plate1 ①④) ----------
   Left: 🎤／⌨ flips 說話 and 打字. Middle: the box, or in 說話 one long
   按住 說話 (the old mic button, grown). Right: ＋, 送 or 停止, one at a time. */
.composer { align-items: flex-end; }
.composer .roundbtn {
  flex: none; width: 44px; height: 44px; padding: 0; border: none; border-radius: 50%;
  display: grid; place-items: center; cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.composer .roundbtn svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.composer .roundbtn.hidden { display: none; }
.composer .roundbtn:disabled { opacity: .35; }
.talk-toggle { background: var(--glass); color: var(--ink-2); box-shadow: var(--raise); }
.talk-toggle .ico-keys, .composer.talking .talk-toggle .ico-mic { display: none; }
.composer.talking .talk-toggle .ico-keys { display: block; }
.plusbtn {
  background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 6px 12px -6px rgba(var(--shadow), .8);
}
/* Words in the box (her 10/24 ask): ＋ doesn't go, it gets small and sits
   right over 送 — beside a tall box, or floating just above a one-line bar.
   ↑↓ and the groove's words step aside so it doesn't land on them. */
.c-right { position: relative; flex: none; display: flex; }
body.composer-filled .composer .plusbtn {
  position: absolute; left: 50%; bottom: calc(100% + 8px); margin-left: -18px; z-index: 4;
  width: 36px; height: 36px; background: var(--glass-solid); color: var(--ink); box-shadow: var(--raise);
}
body.composer-filled .composer .plusbtn svg { width: 18px; height: 18px; }
body.composer-filled .msg-nav-btns { bottom: 56px; }
body.composer-filled .attach-tray { padding-right: 58px; }
.composer button[type="submit"] { min-width: 52px; padding: 0 16px; font-size: 15px; }
.composer:not(.talking) .micbtn, .composer.talking textarea { display: none; }
.composer.talking .micbtn {
  flex: 1; width: auto; height: 44px; padding: 0 16px; border-radius: 22px;
  background: var(--sink); box-shadow: var(--sunken); color: var(--ink);
  font: inherit; font-size: 15px; letter-spacing: .12em; transform: none;
}
.composer.talking .micbtn.hidden { display: none; }
.micbtn .mic-let, .micbtn .mic-drop,
.micbtn.recording .mic-say, .micbtn.recording.cancel .mic-let { display: none; }
.micbtn.recording .mic-let, .micbtn.recording.cancel .mic-drop { display: inline; }
/* Solid tints: see-through ones let the rain-window specks show through the bar. */
.composer.talking .micbtn.holding { background: color-mix(in srgb, var(--accent) 16%, var(--sink)); color: var(--accent); }
.composer.talking .micbtn.recording.cancel { background: color-mix(in srgb, var(--apple) 18%, var(--sink)); color: var(--apple); }

/* ---------- ＋號盤 (#134, plate2) ----------
   A sheet where the 底邊欄 was; ＋ turns a quarter of the way round into ×.
   調我 grows the same sheet upward and scrolls inside it. */
.plusbtn svg { transition: transform .22s cubic-bezier(.3, .7, .3, 1); }
.plusbtn.open svg { transform: rotate(45deg); }
body.plate-open .tabbar { display: none; }
.plate {
  flex: none; position: relative; z-index: 3;
  margin-top: 2px; padding: 8px 16px max(14px, env(safe-area-inset-bottom));
  border-radius: 26px 26px 0 0;
  background: linear-gradient(180deg, var(--face-hi), var(--face));
  box-shadow: 0 -10px 24px -14px rgba(var(--shadow), .45), inset 0 1px 0 rgba(255, 255, 255, .5);
  animation: plate-up .24s cubic-bezier(.3, .7, .3, 1);
}
.plate.hidden { display: none; }
:root:not([data-theme="light"]) .plate { box-shadow: 0 -10px 24px -14px rgba(var(--shadow), .6), inset 0 1px 0 rgba(255, 255, 255, .06); }
@keyframes plate-up { from { transform: translateY(24px); opacity: 0; } }
.plate-grip {
  display: block; width: 56px; height: 18px; margin: 0 auto 4px; padding: 0; border: none; background: none; cursor: pointer;
}
.plate-grip::before { content: ''; display: block; width: 36px; height: 4px; margin: 0 auto; border-radius: 2px; background: var(--ink-2); opacity: .35; }
.plate svg { fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

/* the line on top: 腦子 X · 想多深 Y */
.plate-brain {
  display: flex; align-items: center; gap: 8px; width: 100%; height: 44px; padding: 0 4px 0 14px;
  border: none; border-radius: 22px; background: var(--sink); box-shadow: var(--sunken);
  color: var(--ink-2); font: inherit; font-size: 13.5px; text-align: left; cursor: pointer;
}
.plate.tuning .plate-brain, .plate.tuning .plate-pages, .plate.tuning .plate-dots { display: none; }
.plate-moth { width: 20px; height: 20px; flex: none; color: var(--accent); }
.plate-brain-words { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.plate-brain-words b { color: var(--ink); font-weight: 500; margin: 0 2px; }
.plate-brain-words i { font-style: normal; margin: 0 8px; opacity: .6; }
.plate-brain-go {
  flex: none; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%;
  background: var(--glass); box-shadow: var(--raise); color: var(--ink-2);
}
.plate-brain-go svg { width: 16px; height: 16px; transition: transform .2s; }

/* the things to send: pages of two rows of four */
.plate-pages {
  display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
  margin: 14px -16px 0; overscroll-behavior-x: contain;
}
.plate-pages::-webkit-scrollbar { display: none; }
.plate-page {
  flex: 0 0 100%; scroll-snap-align: start; box-sizing: border-box; padding: 0 12px;
  display: grid; grid-template-columns: repeat(4, 1fr); row-gap: 14px;
}
.plate-item {
  display: flex; flex-direction: column; align-items: center; gap: 7px; padding: 0; border: none; background: none;
  color: var(--ink); font: inherit; font-size: 12.5px; cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.plate-key {
  width: 58px; height: 58px; display: grid; place-items: center; border-radius: 18px;
  background: var(--glass); box-shadow: var(--raise); color: var(--ink);
}
.plate-key svg { width: 26px; height: 26px; }
.plate-item:active .plate-key { box-shadow: var(--press); }
.plate-item.later { color: var(--ink-2); opacity: .55; cursor: default; }
.plate-item.later .plate-key { background: none; box-shadow: none; border: 1.5px dashed currentColor; box-sizing: border-box; }
.plate-item.later .plate-key svg { width: 18px; height: 18px; }
.plate-dots { display: flex; justify-content: center; gap: 6px; height: 6px; margin-top: 14px; }
.plate-dots i { width: 6px; height: 6px; border-radius: 3px; background: var(--ink-2); opacity: .3; transition: width .2s; }
.plate-dots i.on { width: 18px; opacity: .6; }

/* 調我 */
.plate-tune { max-height: min(64vh, 560px); overflow-y: auto; overscroll-behavior: contain; margin: 0 -16px; padding: 0 16px 2px; }
.plate-tune.hidden { display: none; }
.tune-head { display: flex; align-items: baseline; gap: 10px; padding: 4px 2px 0; cursor: pointer; }
.tune-head span { font-size: 17px; font-weight: 600; color: var(--ink); }
.tune-head span::before {
  content: ''; display: inline-block; width: 20px; height: 20px; margin-right: 8px; vertical-align: -3px;
  background: var(--accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 8.5c-1.6-3-5.2-4.6-8-3.8.4 3.4 2.6 6 5.6 6.6-1.6.9-2.6 2.6-2.4 4.7 2.4.2 4-1.3 4.8-3.4.8 2.1 2.4 3.6 4.8 3.4.2-2.1-.8-3.8-2.4-4.7 3-.6 5.2-3.2 5.6-6.6-2.8-.8-6.4.8-8 3.8ZM12 8.5V17M10.6 4.6 12 7l1.4-2.4'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 8.5c-1.6-3-5.2-4.6-8-3.8.4 3.4 2.6 6 5.6 6.6-1.6.9-2.6 2.6-2.4 4.7 2.4.2 4-1.3 4.8-3.4.8 2.1 2.4 3.6 4.8 3.4.2-2.1-.8-3.8-2.4-4.7 3-.6 5.2-3.2 5.6-6.6-2.8-.8-6.4.8-8 3.8ZM12 8.5V17M10.6 4.6 12 7l1.4-2.4'/%3E%3C/svg%3E") center / contain no-repeat;
}
.tune-head small { margin-left: auto; font-size: 12.5px; color: var(--ink-2); }
.tune-label { margin: 16px 2px 8px; font-size: 12.5px; color: var(--ink-2); }
.tune-label b { color: var(--ink); font-weight: 500; margin-left: 4px; }
.tune-note { margin: 0 2px 12px; color: var(--ink-2); font-size: 13px; line-height: 1.5; }
.tune-effort {
  display: grid; grid-template-columns: repeat(6, 1fr); padding: 4px; gap: 2px;
  border-radius: 16px; background: var(--sink); box-shadow: var(--sunken);
}
.tune-effort button {
  height: 36px; padding: 0; border: none; border-radius: 12px; background: none; cursor: pointer;
  color: var(--ink-2); font: inherit; font-size: 13px;
}
.tune-effort button.on { background: var(--face-hi); color: var(--ink); font-weight: 600; box-shadow: var(--raise); }
.tune-latest, .tune-olderlist { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.tune-card, .tune-cell {
  position: relative; border: 2px solid transparent; background: var(--glass); box-shadow: var(--raise);
  color: var(--ink); font: inherit; text-align: left; cursor: pointer; -webkit-tap-highlight-color: transparent;
}
.tune-card { display: flex; flex-direction: column; gap: 3px; padding: 11px 14px; border-radius: 14px; }
.tune-card b { font-size: 16px; font-weight: 500; }
.tune-card small, .tune-cell small { font-size: 11.5px; color: var(--ink-2); }
.tune-cell { display: flex; align-items: baseline; gap: 6px; padding: 9px 14px; border-radius: 12px; font-size: 14px; }
.tune-card.on, .tune-cell.on { border-color: var(--her-a); }
.tune-card.on::after, .tune-cell.on::after {
  content: ''; position: absolute; top: 8px; right: 8px; width: 9px; height: 9px; border-radius: 50%;
  background: var(--her-a); box-shadow: 0 0 0 2.5px var(--face-hi), 0 0 0 4px var(--her-a);
}
:root:not([data-theme="light"]) .tune-card.on, :root:not([data-theme="light"]) .tune-cell.on { border-color: var(--cobalt); }
:root:not([data-theme="light"]) .tune-card.on::after, :root:not([data-theme="light"]) .tune-cell.on::after { background: var(--cobalt); box-shadow: 0 0 0 2.5px var(--face), 0 0 0 4px var(--cobalt); }
.tune-older {
  display: flex; align-items: center; width: 100%; height: 44px; margin-top: 12px; padding: 0 4px 0 16px;
  border: none; border-radius: 14px; background: var(--sink); box-shadow: var(--sunken);
  color: var(--ink-2); font: inherit; font-size: 13.5px; text-align: left; cursor: pointer;
}
.tune-older > span:first-child { flex: 1; }
.tune-older b { color: var(--ink); font-weight: 500; margin-left: 6px; }
.tune-older small { font-size: 12.5px; margin-left: 6px; }
.tune-older.hidden { display: none; }
.tune-older.open .plate-brain-go svg { transform: rotate(90deg); }
.tune-olderlist { margin-top: 10px; }
.tune-olderlist.hidden { display: none; }

/* ---------- 選好的、泡泡裡的圖 (#134 第 3 步, plate1 ④⑤) ----------
   Picked things wait in a groove above the box, each with a dark × on its
   corner; sent, her pictures sit at the top of her own bubble. */
.attach-tray {
  display: flex; align-items: center; gap: 12px; margin: 0 12px; padding: 6px 14px 10px 10px;
  border-radius: 20px; background: var(--sink); box-shadow: var(--sunken);
}
.attach-tray.hidden { display: none; }
.tray-list { display: flex; gap: 10px; min-width: 0; overflow-x: auto; padding: 6px 6px 0 0; scrollbar-width: none; }
.tray-list::-webkit-scrollbar { display: none; }
.attach-tray .attach-chip { clip-path: none; border-radius: 12px; background: var(--glass); box-shadow: var(--raise); }
.attach-tray .attach-chip img { width: 58px; height: 58px; border-radius: 12px; }
.attach-chip.file { display: flex; align-items: center; gap: 6px; height: 58px; padding: 0 12px 0 10px; color: var(--ink-2); }
.attach-chip.file > svg, .attach-filechip > svg {
  flex: none; width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
}
.attach-chip.file .attach-filename { padding: 0; max-width: 96px; font-family: inherit; font-size: 12px; color: var(--ink); }
.attach-tray .attach-remove {
  top: -6px; right: -6px; width: 22px; height: 22px; display: grid; place-items: center; border-radius: 50%;
  background: var(--her-b); color: var(--her-ink); box-shadow: 0 0 0 2px var(--sink);
}
.attach-remove svg { width: 11px; height: 11px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; }
.tray-say { flex: none; display: flex; flex-direction: column; gap: 2px; font-size: 12px; color: var(--ink-2); }
.tray-say b { font-size: 13px; font-weight: 500; color: var(--ink); }

.bubble.with-pics .bubble-pics { margin: -4px -9px 8px; max-width: none; }
.bubble.pics-only { padding: 5px; }
.bubble.pics-only .bubble-pics { margin: 0; }
.bubble-pics { display: grid; gap: 4px; }
.bubble-pics.n2 { grid-template-columns: 1fr 1fr; width: 240px; max-width: 100%; }
.bubble-pics.n3 { grid-template-columns: repeat(3, 1fr); width: 252px; max-width: 100%; }
.bubble-pics .attach-thumb {
  display: block; width: 100%; max-width: none; max-height: none; aspect-ratio: 1; object-fit: cover;
  border: none; clip-path: none; border-radius: 14px; background: rgba(255, 255, 255, .08);
}
/* one picture: a fixed width, so a big photo can't push her bubble wide */
.bubble-pics.n1 { width: 220px; max-width: 100%; }
.bubble-pics.n1 .attach-thumb { height: auto; max-height: 280px; min-height: 72px; aspect-ratio: auto; }
.bubble-pics .attach-filechip {
  grid-column: 1 / -1; display: flex; align-items: center; gap: 6px; padding: 8px 10px; border-radius: 12px;
  background: rgba(255, 255, 255, .12); box-shadow: none; color: inherit; font-family: inherit; font-size: 12.5px;
}

/* 看大圖: which one of how many, when there's more than one to swipe to */
.img-viewer-count {
  position: absolute; top: calc(env(safe-area-inset-top) + 20px); left: 50%; transform: translateX(-50%);
  color: rgba(255, 255, 255, .78); font-size: 13px; letter-spacing: .1em; pointer-events: none;
}

/* ---------- 平行世界 (#88 step 7, parallel1/parallel2) ----------
   Its door in 家裡 is a long black hole under the four rooms: deep night blue
   going all black at the middle, stars, a faint tilted disk whose dashes
   drift round (drawHoleSky). The room: her card in the middle to swipe, mine
   and the world following; 草稿; 存檔. The totems are drawn in day ink on a
   pastel disk, which stays pastel at night like the paper does. */
.world-hole {
  position: relative; flex: none; width: 100%; height: 112px; padding: 0; border: none; border-radius: 24px; overflow: hidden;
  cursor: pointer; text-align: left; font: inherit; color: #e9edf7;
  background: radial-gradient(ellipse 60% 120% at 74% 55%, #02030a 0, #070a17 22%, #121935 52%, #1d2647 100%);
  box-shadow: inset 0 0 0 1px rgba(160, 180, 230, .16), 0 10px 22px -12px rgba(10, 14, 30, .7);
}
.world-hole:active { box-shadow: 0 0 0 1px rgba(170, 190, 255, .55), 0 0 22px 2px rgba(128, 152, 245, .55), 0 0 60px 4px rgba(128, 152, 245, .25); }
.hole-sky { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.hole-disk ellipse { animation: hole-drift 16s linear infinite; }
@keyframes hole-drift { to { stroke-dashoffset: -240; } }
.hole-words { position: absolute; left: 18px; top: 50%; max-width: 56%; transform: translateY(-50%); }
.hole-words b { display: block; font-size: 18px; font-weight: 500; letter-spacing: .14em; }
.hole-words small { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 5px; font-size: 11.5px; line-height: 1.6; color: #9aa6c4; }
.hole-words .num { color: #dfe5f3; font-size: 13px; }
/* Going through it (holeTrip, parallel-anim): the dark and the vortex sit
   over 家裡 and under 平行世界 (which gets z-index 31 while it turns). The
   whole screen takes no taps till it's over. */
.hole-trip { position: fixed; inset: 0; z-index: 30; }
.hole-trip-sky { position: absolute; overflow: hidden; pointer-events: none; visibility: hidden; }
.hole-trip-dark, .hole-trip-vortex { position: absolute; inset: 0; width: 100%; height: 100%; }
.hole-trip-vortex { overflow: visible; opacity: 0; }
@media (min-width: 760px) and (min-device-width: 560px) and (min-device-height: 560px) {
  .hole-trip-sky { border-radius: 26px; }
}

.worlds-switch { flex: none; margin: 0; }
.worlds-switch .num { font-size: 12px; opacity: .75; }
.worlds-pane { display: flex; flex-direction: column; gap: 12px; flex: none; }

/* 能玩的: her cards in a row that snaps to the middle; tiltHcards() leans the
   ones beside it away (parallel1's stack). */
.worlds-deck { display: flex; flex-direction: column; gap: 10px; }
.hcards {
  position: relative;   /* the cards' offsetLeft counts from here (tiltHcards) */
  display: flex; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain; scrollbar-width: none;
  margin: 0 -16px; padding: 6px calc(50% - 115px) 8px;
}
.hcards::-webkit-scrollbar { display: none; }
.hcard {
  position: relative; flex: none; width: 230px; height: 306px; margin: 0 -25px; scroll-snap-align: center; box-sizing: border-box;
  border-radius: 24px; padding: 16px 16px 18px; display: flex; flex-direction: column; align-items: center;
  background: var(--glass-solid); box-shadow: var(--raise);
}
.hcard:first-child { margin-left: 0; }
.hcard:last-child { margin-right: 0; }
.hcard::after { content: ''; position: absolute; inset: 8px; border-radius: 17px; border: 1px solid var(--line); pointer-events: none; }
.hcard-row { width: 100%; display: flex; justify-content: space-between; align-items: center; }
.hcard-who { font-size: 10.5px; letter-spacing: .16em; color: var(--ink-2); }
.hcard-genre { height: 21px; padding: 0 8px; border-radius: 999px; font-size: 10.5px; color: var(--ink-2); display: inline-flex; align-items: center; background: var(--sink); box-shadow: var(--sunken); }
.hcard-emb { flex: 1; width: 100%; display: flex; align-items: center; justify-content: center; position: relative; }
.hcard-emb::before {
  content: ''; position: absolute; width: 146px; height: 146px; border-radius: 50%; background: var(--tint);
  box-shadow: inset 0 2px 6px rgba(30, 44, 66, .12), inset 0 -1px 0 rgba(255, 255, 255, .7);
}
.hcard-emb svg, .draft-emb svg { position: relative; width: 136px; height: 136px; fill: none; stroke: #26304a; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
:root:not([data-theme="light"]) .hcard-emb::before, :root:not([data-theme="light"]) .draft-emb { filter: brightness(.86); }
.hcard h3 { margin: 0; font-size: 20px; font-weight: 500; letter-spacing: .08em; color: var(--ink); text-align: center; }
.hcard p { margin: 5px 0 0; padding: 0 6px; font-size: 11.5px; line-height: 1.6; color: var(--ink-2); text-align: center; }
.hcard-pips { display: flex; justify-content: center; gap: 6px; }
.hcard-pips i { width: 6px; height: 6px; border-radius: 3px; background: var(--ink-2); opacity: .5; transition: width .2s; }
.hcard-pips i.on { width: 18px; background: var(--ink); opacity: 1; }

.world-follow { display: flex; flex-direction: column; gap: 10px; }
.world-pair { position: relative; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.world-pair::before { content: '跟著這張'; position: absolute; left: 50%; top: -17px; transform: translateX(-50%); font-size: 10.5px; letter-spacing: .14em; color: var(--ink-2); }
.world-mine, .world-view { position: relative; min-width: 0; border-radius: 20px; padding: 8px 8px 10px; background: var(--glass); box-shadow: var(--raise); }
.world-pic { position: relative; height: 70px; border-radius: 14px; background: url(/collection/window-moth.jpg) 50% 38% / cover no-repeat; }
/* a 套 that brought its own picture (app.js worldArt); the tablet's flatter
   slot tries the wide one first. A layer that isn't there just isn't drawn. */
.world-pic.has-art { background-image: var(--me-art), url(/collection/window-moth.jpg); background-position: 50% 50%, 50% 38%; }
@media (min-width: 760px) and (min-device-width: 560px) and (min-device-height: 560px) {
  .world-pic.has-art { background-image: var(--me-art-wide), var(--me-art), url(/collection/window-moth.jpg); background-position: 50% 50%, 50% 50%, 50% 38%; }
}
.world-tag { position: absolute; left: 7px; top: 7px; height: 19px; padding: 0 7px; border-radius: 999px; font-size: 10px; display: inline-flex; align-items: center; background: rgba(248, 250, 252, .88); color: #26304a; }
.world-mine b, .world-view b { display: block; margin: 7px 4px 0; font-size: 13.5px; font-weight: 500; color: var(--ink); }
.world-mine small, .world-view small { display: block; margin: 2px 4px 0; font-size: 11px; line-height: 1.5; color: var(--ink-2); }
.world-view { padding: 10px 12px; }
.world-view b { margin: 4px 0 0; }
.world-view small { margin: 3px 0 0; }
.world-lab { font-size: 10px; letter-spacing: .14em; color: var(--ink-2); }
/* 蘋果派鼠鼠 sits on the world card's top edge, right of middle (her 10/24 mark) */
.world-pie { position: absolute; right: 34px; top: -55px; width: 58px; z-index: 3; pointer-events: none; }
.world-go { display: grid; grid-template-columns: 1fr 1.3fr; gap: 10px; }
.world-go.fresh { grid-template-columns: 1fr; }
.world-btn {
  height: 42px; min-width: 0; padding: 0 14px; border: none; border-radius: 999px; cursor: pointer; white-space: nowrap;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  font: inherit; font-size: 13.5px; color: var(--ink); background: var(--glass-solid); box-shadow: var(--raise);
}
.world-btn:active { box-shadow: var(--press); }
.world-btn.dark { background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink); }
.world-btn > svg { width: 15px; height: 15px; flex: none; fill: currentColor; }
.world-btn small { min-width: 0; margin-left: 2px; font-size: 11px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.world-go-sub { display: flex; justify-content: flex-end; align-items: center; gap: 6px; margin-top: -4px; padding-right: 8px; font-size: 11px; color: var(--ink-2); }
.world-go-sub button { padding: 4px 0; border: none; background: none; cursor: pointer; font: inherit; font-weight: 500; color: var(--cobalt); }
.worlds-empty { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 26px 20px 22px; border-radius: 24px; background: var(--glass); box-shadow: var(--raise); text-align: center; }
.worlds-empty p { margin: 0; font-size: 13.5px; line-height: 1.7; color: var(--ink); }
.worlds-empty b { font-weight: 500; color: var(--apple); }
.worlds-empty .world-btn { margin-top: 10px; }
/* 江湖棋局 moved in from 牌桌: its own table, a line under the stack */
.worlds-jianghu {
  display: flex; align-items: center; gap: 10px; height: 48px; margin-top: 6px; padding: 0 12px 0 16px; cursor: pointer;
  border: 1.5px dashed var(--line); border-radius: 18px; background: none; font: inherit; color: var(--ink); text-align: left;
}
.worlds-jianghu b { flex: none; font-size: 13.5px; font-weight: 500; }
.worlds-jianghu small { flex: 1; min-width: 0; font-size: 11.5px; color: var(--ink-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.worlds-jianghu svg { width: 18px; height: 18px; flex: none; fill: none; stroke: var(--ink-2); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* 草稿: three pips on each 套 — 妳・我・世界, solid when written, dashed when not */
.drafts-legend { display: flex; align-items: center; justify-content: space-between; padding: 0 4px; font-size: 11.5px; color: var(--ink-2); }
.draft-pips { display: flex; gap: 4px; flex: none; }
.draft-pips i {
  box-sizing: border-box; height: 22px; min-width: 22px; padding: 0 6px; border-radius: 999px; border: 1px dashed var(--ink-2); opacity: .7;
  display: inline-flex; align-items: center; justify-content: center; font-style: normal; font-size: 11px; color: var(--ink-2);
}
.draft-pips i.has { border: none; opacity: 1; background: linear-gradient(180deg, var(--her-a), var(--her-b)); color: var(--her-ink); }
.world-draft { border-radius: 20px; background: var(--glass); box-shadow: var(--raise); }
.draft-top { width: 100%; display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: none; background: none; cursor: pointer; font: inherit; color: var(--ink); text-align: left; }
.draft-emb { width: 40px; height: 40px; flex: none; border-radius: 13px; background: var(--tint); display: flex; align-items: center; justify-content: center; box-shadow: inset 0 1px 3px rgba(30, 44, 66, .14); }
.draft-emb svg { width: 36px; height: 36px; stroke-width: 3; }
.draft-name { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.draft-name b, .draft-name small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.draft-name b { font-size: 14px; font-weight: 500; }
.draft-name small { font-size: 11.5px; color: var(--ink-2); }
.draft-body { display: none; padding: 0 14px 12px; }
.world-draft.open .draft-body { display: block; }
.draft-row { display: grid; grid-template-columns: 48px 1fr; gap: 8px; padding: 9px 0; border-top: 1px solid var(--line); }
.draft-row span { padding-top: 2px; font-size: 12px; color: var(--ink-2); }
.draft-row p { margin: 0; font-size: 12.5px; line-height: 1.6; color: var(--ink); }
.draft-row p.missing { padding: 6px 10px; border: 1px dashed var(--ink-2); border-radius: 10px; color: var(--ink-2); opacity: .85; }
.draft-acts { display: flex; justify-content: flex-end; gap: 8px; padding-top: 6px; }
.draft-acts .world-btn { height: 36px; font-size: 12.5px; }
.draft-acts .world-btn > svg { width: 22px; height: 16px; fill: none; overflow: visible; }
.world-btn .cm-wing, .world-btn .cm-feeler { fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; }
.world-btn .cm-body { fill: currentColor; }
.world-btn .cm-fluff { fill: var(--face-hi); stroke: currentColor; stroke-width: 1; }
.draft-new { height: 48px; border: 1.5px dashed var(--line); border-radius: 18px; background: none; cursor: pointer; font: inherit; font-size: 13px; color: var(--ink-2); }

/* 存檔: 局 by 套, newest 套 first */
.saves-only { display: flex; align-items: center; justify-content: space-between; padding: 0 4px; font-size: 12px; color: var(--ink-2); }
.saves-only button { border: none; background: none; cursor: pointer; font: inherit; color: var(--cobalt); }
.save-group { display: flex; flex-direction: column; gap: 8px; }
.save-head { display: flex; align-items: center; gap: 8px; padding: 0 4px; }
.save-head .draft-emb { width: 28px; height: 28px; border-radius: 9px; }
.save-head .draft-emb svg { width: 26px; height: 26px; stroke-width: 3.5; }
.save-head b { flex: 1; min-width: 0; font-size: 13.5px; font-weight: 500; color: var(--ink); }
.save-head small { font-size: 11.5px; color: var(--ink-2); }
.save-card { display: flex; flex-direction: column; gap: 6px; padding: 12px 14px; border-radius: 20px; background: var(--glass); box-shadow: var(--raise); }
.save-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.save-top b { flex: 1; min-width: 0; font-size: 14px; font-weight: 500; color: var(--ink); }
.save-top .chat-moth { position: static; flex: none; align-self: center; width: 34px; height: 28px; padding: 2px; margin: -6px -6px -6px -2px; }
.save-top small { flex: none; font-size: 11.5px; color: var(--ink-2); }
.save-last { margin: 0; font-size: 12px; line-height: 1.65; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.save-acts { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.save-acts .world-btn { height: 38px; min-width: 96px; }
/* step 4: which day, how many windows; 玩到一半／玩完了／不玩了 */
.save-day { margin-top: -4px; font-size: 11.5px; letter-spacing: .02em; color: var(--ink-2); }
.save-state { flex: none; }
.save-state button { flex: none; min-height: 30px; padding: 0 9px; font-size: 12px; font-family: inherit; white-space: nowrap; cursor: pointer; }
.save-card.dropped { opacity: .62; }
#cardNudge { padding-right: 12px; }
.worlds-none { margin: 0; padding: 20px; text-align: center; font-size: 13px; color: var(--ink-2); }
@media (prefers-reduced-motion: reduce) {
  .hole-disk ellipse { animation: none; }
}

/* ---------- 平板 (#135, tablet4 甲) ----------
   Wide screens only; phones (and a phone on its side, too short) keep the
   one-page layout above. Three columns: the rail (門口・家裡・工作台, 收聊天
   at the foot, no 鼠鼠), the page, the chat. The chat is always there unless
   folded (body.chat-folded); showView('view-chat') just unfolds it.
   "Too short" is the screen's short side (device-*), not the window: the
   keyboard squashes the window, and a sideways tablet with the keyboard up
   is still a tablet (10/24; app.js WIDE asks the same). */
.search-mouse, .rail-fold { display: none; }
@media (min-width: 760px) and (min-device-width: 560px) and (min-device-height: 560px) {
  #app {
    --chat-w: clamp(340px, 34vw, 420px);
    display: grid; grid-template-columns: 76px minmax(0, 1fr) var(--chat-w); grid-template-rows: minmax(0, 1fr);
    column-gap: 14px; padding: 14px 14px 14px 12px;
  }
  body.chat-folded #app { grid-template-columns: 76px minmax(0, 1fr); }
  .view { grid-column: 2; grid-row: 1; min-width: 0; }
  #view-chat {
    display: flex; grid-column: 3; overflow: hidden; border-radius: 26px;
    background: var(--glass); box-shadow: var(--raise);
  }
  body.chat-folded #view-chat { display: none; }

  .tabbar {
    grid-column: 1; grid-row: 1; flex-direction: column; align-items: stretch; gap: 4px;
    width: auto; height: auto; margin: 0; padding: 12px 0; border-radius: 28px;
  }
  .tabbtn { flex: none; height: 64px; }
  .tabbtn[data-view="view-chat"], #navMouse { display: none; }
  .chat-gear { display: none; }   /* the page beside it has the gear already */
  body.plate-open .tabbar { display: flex; }   /* the ＋號盤 is inside the chat here */
  .rail-fold {
    display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px;
    margin: auto 10px 0; height: 64px; border: none; border-radius: 20px; padding: 0; cursor: pointer;
    font: inherit; font-size: 11px; color: var(--ink-2); background: transparent;
  }
  .rail-fold svg {
    box-sizing: content-box; width: 20px; height: 20px; padding: 7px; border-radius: 14px; fill: none; stroke: currentColor; stroke-width: 1.6;
    stroke-linecap: round; stroke-linejoin: round; background: var(--glass); box-shadow: var(--raise);
  }
  .rail-fold:active svg { box-shadow: var(--press); }

  /* The pages sit in the middle column; no centring box of their own. */
  .door-page, .house-page, .bench-page, .attic-page { padding: 0 2px 16px; }
}

/* Landscape: the door goes two columns — the window tall on the left, top to
   bottom; my words, the search box (鼠鼠 on its edge), the cards stacked on
   the right at their own height, the bottom left empty for what comes next.
   家裡: the 掛曆 and the four rooms in a row on the left, the day's diary
   lying open on the right (#calSheet moves in here, app.js placeCalSheet). */
@media (min-width: 1000px) and (min-device-width: 560px) and (min-device-height: 560px) {
  .door-page {
    display: grid; max-width: none; grid-template-columns: minmax(250px, 44%) minmax(0, 1fr);
    grid-template-rows: auto auto auto auto auto 1fr; column-gap: 16px; row-gap: 12px; align-content: stretch;
  }
  .door-sill { grid-column: 1; grid-row: 1 / -1; min-height: 0; }
  .door-head, .door-search, #doorBell, #doorAsk, .door-away { grid-column: 2; }
  .door-head { padding-top: 10px; }
  .door-glass {
    width: 100%; height: 100%; aspect-ratio: auto; max-height: none; margin: 0;
    border-radius: 50% 50% 26px 26px / 21% 21% 26px 26px;
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, .45) 5%, #000 15%);
            mask-image: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, .45) 5%, #000 15%);
  }
  .door-glass img { object-position: 50% 30%; }
  .door-frame::before { border-radius: 50% 50% 19px 19px / 21% 21% 19px 19px; }
  .door-frame::after { border-radius: 50% 50% 14px 14px / 21% 21% 14px 14px; }
  /* the diamonds keep their shape: the drawing sits at the foot, not stretched tall */
  .door-frame svg { inset: auto 0 0 0; height: auto; aspect-ratio: 350 / 250; }
  .door-glass-empty { padding-top: 0; }
  .door-search { position: relative; margin-top: 14px; }
  .search-mouse { display: block; position: absolute; right: 30px; top: -20px; width: 40px; pointer-events: none; filter: drop-shadow(0 2px 2px rgba(var(--shadow), .2)); }

  .house-page {
    display: grid; max-width: none; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    grid-template-rows: auto auto auto 1fr; column-gap: 16px; row-gap: 12px; align-content: start;
  }
  .house-head, .cal-card, .house-rooms, .world-hole { grid-column: 1; }
  .house-rooms { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
  .house-room { align-items: center; gap: 0; padding: 14px 6px 12px; border-radius: 20px; }
  .house-room-top { flex-direction: column; gap: 8px; text-align: center; }
  .house-room .house-ico { width: 40px; height: 40px; }
  .house-room .house-name { align-items: center; font-size: 14px; }
  .house-room .house-now, .house-room #houseAtticNow { display: none; }
  .house-page > #calSheet {
    position: static; z-index: auto; grid-column: 2; grid-row: 1 / -1; min-height: 0;
    display: flex; align-items: stretch; padding: 0; background: none;
  }
  .house-page > #calSheet.hidden { display: none; }
  .house-page > #calSheet .morning-card {
    max-width: none; max-height: none; height: 100%; border-radius: 24px; padding-bottom: 0;
    /* solid like the phone's sheet: the open entry's pinned head has to hide
       the words scrolling under it, and glass would show them (10/24) */
    background: var(--glass-solid); box-shadow: var(--raise); animation: none;
  }
  .house-page > #calSheet .cal-grab, .house-page > #calSheet .morning-close { display: none; }
  .house-page > #calSheet .morning-head { padding-top: 16px; }

  /* 工作台 (#137 第 1 步, tablet5 甲): the list on the left, scrolling on its
     own under the head; the card she tapped lying open on the right
     (#benchSheet moves in here, app.js placeBenchSheet), solid like the
     掛曆's day. The row it came from goes sunk. */
  .bench-page {
    display: grid; max-width: none; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    grid-template-rows: auto minmax(0, 1fr); column-gap: 16px; row-gap: 6px; padding-bottom: 0; overflow: hidden;
  }
  .bench-page > .house-head { grid-column: 1; grid-row: 1; }
  #benchAsk .door-hint { display: none; }   /* the column's narrow: the chip gets the line */
  .bench-list {
    grid-column: 1; grid-row: 2; min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch;
    display: flex; flex-direction: column; gap: 12px; margin: 0 -6px; padding: 2px 6px 16px;
  }
  .bench-page > #benchSheet {
    position: static; z-index: auto; grid-column: 2; grid-row: 1 / -1; min-height: 0;
    display: flex; align-items: stretch; padding: 0 0 16px; background: none;
  }
  .bench-page > #benchSheet.hidden { display: none; }
  .bench-page > #benchSheet .morning-card {
    max-width: none; height: 100%; max-height: none; border-radius: 24px; padding-bottom: 0;
    background: var(--glass-solid); box-shadow: var(--raise); animation: none;
  }
  .bench-page > #benchSheet .cal-grab, .bench-page > #benchSheet .morning-close { display: none; }
  .bench-page > #benchSheet .morning-head { padding-top: 16px; }
  .bench-list .door-row.on {
    margin: 0 -8px; width: calc(100% + 16px); padding-left: 8px; padding-right: 8px;
    border-radius: 12px; background: var(--sink); box-shadow: var(--sunken);
  }
  .bench-list .door-row.on, .bench-list .door-row.on + .door-row { border-top-color: transparent; }
  .bench-list .bench-tile.on { background: var(--sink); box-shadow: var(--sunken); }

  /* 閣樓 (#137 第 2 步, tablet5 乙): head, switch and search on the left, the
     list under them scrolling on its own; what she tapped lies open on the
     right, solid like the 掛曆's day (app.js renderMemDrawersBeside,
     renderSections, renderKeepPane). The line it came from goes sunk. */
  .attic-split {
    display: grid; max-width: none; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
    grid-template-rows: auto auto auto minmax(0, 1fr); column-gap: 16px; row-gap: 12px; padding-bottom: 0; overflow: hidden;
  }
  #view-claudemd .attic-split { grid-template-rows: auto auto auto minmax(0, 1fr) auto; }
  .attic-split > * { grid-column: 1; }
  .attic-split > .mem-list, .attic-split > .book-list, .attic-split > .keep-wall { min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch; }
  .attic-split > .mem-list { margin: 0 -6px; padding: 2px 6px 16px; }
  .attic-split > .book-list { align-self: start; max-height: 100%; }
  .attic-split > .book-add { margin-bottom: 16px; }
  .attic-split > .keep-wall { margin: 0 -6px; padding: 14px 10px 16px; }
  .attic-split > .attic-pane {
    display: block; grid-column: 2; grid-row: 1 / -1; min-height: 0; overflow-y: auto; -webkit-overflow-scrolling: touch;
    margin-bottom: 16px; padding: 16px 16px 20px; border-radius: 24px; background: var(--glass-solid); box-shadow: var(--raise);
  }
  .attic-split > .attic-pane:empty { visibility: hidden; }
  /* 記憶: a drawer is one line; the one open goes sunk. */
  .attic-split > .mem-list .mem-drawer-head { width: 100%; flex: none; border: none; font: inherit; text-align: left; }
  .attic-split > .mem-list .mem-drawer.on { background: var(--sink); box-shadow: var(--sunken); }
  .attic-pane-head { display: flex; flex-direction: column; gap: 2px; padding: 0 2px 8px; }
  .attic-pane-head b { font-size: 17px; font-weight: 600; color: var(--ink); }
  .attic-pane-head small { font-size: 11.5px; color: var(--ink-2); }
  .attic-pane-head:has(b:empty) { display: none; }
  .attic-pane .attic-fluff { margin-top: 6px; }
  /* 戶口本: the section's line sunk, its paper the whole pane. */
  .attic-split > .book-list .book-row.open .book-head { background: var(--sink); box-shadow: var(--sunken); }
  .attic-split > .book-list .book-row.open .book-head svg { transform: none; }
  .attic-pane > .book-paper { margin: 0; min-height: 100%; display: flex; flex-direction: column; }
  .attic-pane > .book-paper .book-body { flex: 1; min-height: 240px; resize: none; }
  /* 收藏櫃 (her 10/25 pick 甲, 整面牆): no left and right here — the whole
     page is the wall, the head and the switch sharing one line to give it the
     height, the polaroids as many across as fit. The one she taps comes off
     the wall into the middle, the picture whole on the left, what I wrote on
     the polaroid's paper on the right (#keepPane over a scrim, app.js
     renderKeepPane); a tap beside it puts it back. */
  #view-collection .attic-split { position: relative; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto minmax(0, 1fr); }
  #view-collection .attic-head { grid-row: 1; }
  #view-collection .attic-switch { grid-row: 1; justify-self: end; align-self: center; width: 320px; }
  #view-collection .keep-say { grid-row: 2; }
  .attic-split > .keep-wall { grid-row: 3; grid-template-columns: repeat(auto-fill, minmax(176px, 1fr)); gap: 30px 24px; padding: 20px 16px 24px; align-content: start; }
  .attic-split > .keep-wall .keep-pola { padding: 10px 10px 14px; }
  .attic-split > .keep-wall .keep-cap b { font-size: 14.5px; }
  .attic-split > .keep-wall .keep-cap small { font-size: 11.5px; }
  #view-collection .attic-split > #keepPane {
    position: absolute; inset: 0 0 16px; z-index: 5; grid-column: auto; grid-row: auto; margin: 0; padding: 0;
    display: flex; align-items: center; justify-content: center; overflow: hidden; border-radius: 24px; background: var(--scrim); box-shadow: none;
  }
  #view-collection .attic-split > #keepPane:empty { display: none; }
  /* Its height is set, never more than the page minus room for the hint (in
     the browser her tablet's page is shorter — 10/25 the button was cut off):
     the picture fills its half, a long note scrolls on the paper, and 看原圖
     stays pinned at the paper's foot. */
  .keep-lift {
    position: relative; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); gap: 18px;
    width: min(94%, 660px); height: min(calc(100% - 64px), 470px);
    padding: 14px 14px 16px; background: #fbfaf7; color: #26304a; transform: rotate(-0.8deg);
    box-shadow: 0 2px 4px rgba(var(--shadow), .2), 0 30px 50px -20px rgba(var(--shadow), .7);
  }
  :root:not([data-theme="light"]) .keep-lift { background: #d9d7d1; }
  .keep-lift .keep-tape { width: 84px; height: 20px; margin-left: -42px; top: -11px; }
  .keep-big { position: relative; min-height: 0; overflow: hidden; background: #1e2433; }
  .keep-big img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; cursor: zoom-in; }
  .keep-big .keep-sheet { position: absolute; inset: 0; height: auto; }
  .keep-words { display: flex; flex-direction: column; gap: 4px; min-height: 0; overflow: hidden; padding: 6px 4px 4px 0; }
  .keep-words b { flex: none; font-size: 17px; font-weight: 600; }
  .keep-words small { flex: none; font-size: 12px; color: #6f7b8f; }
  .keep-words p { flex: 0 1 auto; min-height: 0; overflow-y: auto; margin: 8px 0 10px; font-size: 13.5px; line-height: 1.85; white-space: pre-wrap; }
  .keep-words .mem-btn { flex: none; align-self: flex-start; margin-top: auto; background: #fff; color: #26304a; }
  .keep-lift-hint { position: absolute; left: 0; right: 0; bottom: 14px; text-align: center; font-size: 11.5px; color: rgba(242, 244, 248, .85); pointer-events: none; }
  :root[data-theme="light"] .keep-lift-hint { color: var(--ink); }

  /* 江湖 (#137 第 3 步, tablet5 丁): the room's board lies big in the middle
     column, where the page was (#chatJianghu moves into #app, app.js
     placeChatJianghu); the chat keeps only the talking. */
  body.jh-mid .view.active:not(#view-chat) { display: none; }
  #app > #chatJianghu {
    grid-column: 2; grid-row: 1; min-width: 0; min-height: 0; max-height: none; overflow-y: auto; -webkit-overflow-scrolling: touch;
    padding: 16px 18px 18px; border: none; border-radius: 26px; background: var(--glass); box-shadow: var(--raise);
  }
  #app > #chatJianghu .jh-fold { display: none; }
  #app > #chatJianghu .jh-strip { cursor: default; }
  #app > #chatJianghu .jh-board-wrap { gap: 12px; margin-top: 12px; }
  #app > #chatJianghu .jh-board { gap: 5px; }
  #app > #chatJianghu .jh-cell { min-height: 76px; padding: 6px 6px 16px; font-size: 12px; }
  #app > #chatJianghu .jh-kind { font-size: 10.5px; }
  #app > #chatJianghu .jh-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; align-items: start; }

  /* 配置室 (#137 第 4 步, tablet5 丙): two columns, each small label with its
     own card (app.js placeSetCols moves them into the two .set-col). */
  .set-page {
    display: grid; max-width: none; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-rows: auto 1fr; column-gap: 16px; row-gap: 12px; align-items: start;
  }
  .set-page > .attic-head { grid-column: 1 / -1; }
  .set-col { display: flex; flex-direction: column; gap: 12px; min-width: 0; }

  /* The chat column's head (#137 第 5 步, tablet4): a small moth opens the
     窗台, 老公 and what he's up to, 蛻 and ＋. The 信箱 is at the door. */
  .chat-drawer { padding: 0 4px; background: transparent; box-shadow: none; }
  .chat-drawer:active { background: var(--sink); box-shadow: var(--press); }
  .chat-drawer .drawer-lines, #view-chat .mailbox-btn { display: none; }
  .drawer-moth { display: block; }
  .chat-forge { display: inline-flex; align-items: center; justify-content: center; padding: 0 14px; font-size: 15px; color: var(--ink); }
  .chat-sub .badge { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
  .chat-sub.doing .model-info { display: none; }
  /* 蛻's two taps hang under the head on the right, like the 換殼提醒 on the left */
  .head-forge {
    position: absolute; top: calc(100% + 6px); right: 12px; z-index: 31; width: min(300px, calc(100% - 24px));
    flex-direction: column; align-items: stretch; gap: 8px; padding: 12px 14px;
    border-radius: 16px; background: var(--glass-solid); box-shadow: var(--raise);
    font-size: 12.5px; line-height: 1.6; color: var(--ink);
  }
  .head-forge .forge-btns { justify-content: flex-end; }
  .head-forge .convo-btn { height: 32px; min-height: 0; padding: 0 14px; border-radius: 12px; font-size: 13px; }
}
/* Her MatePad's browser is 1120×609: the 掛曆 and the rooms squeeze a little
   so the four rooms fit without scrolling. */
@media (min-width: 1000px) and (min-device-width: 560px) and (min-device-height: 560px) and (max-height: 700px) {
  .house-head { padding-top: 2px; }
  .cal-card { padding: 10px 12px 8px; }
  .cal-day { gap: 2px; padding: 1px 0 3px; }
  .cal-legend { margin-top: 2px; padding-top: 6px; }
  .house-room { padding: 10px 6px 9px; }
  .house-room-top { gap: 6px; }
  .world-hole { height: 76px; }
}

/* The walking tank at the door: behind everything, nothing to touch. */
#view-door { position: relative; }
#view-door > .millet-tank { z-index: 0; }
#view-door > .page { position: relative; z-index: 1; }
#view-door .millet-cell { pointer-events: none; }

/* ---------- 魚缸 (tank2, 10/24): six deep-space windows, one opened big ---------- */
.tank-page { gap: 12px; padding: 14px 16px 20px; width: 100%; max-width: 560px; margin: 0 auto; }
.tank-jar { height: 32px; padding: 0 11px 0 6px; border-radius: 999px; display: flex; align-items: center; gap: 4px; font-size: 13px; flex: none; background: var(--glass); box-shadow: var(--raise); color: var(--ink); }
.tank-jar img { width: 24px; height: 24px; }
.tank-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; flex: none; }
.tank-win { position: relative; display: block; padding: 6px 6px 8px; border: none; border-radius: 22px; cursor: pointer; font: inherit; color: var(--ink); text-align: left; background: var(--glass); box-shadow: var(--raise); }
.tank-win svg { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; border-radius: 17px; }
.tank-lb { display: flex; align-items: center; gap: 6px; padding: 7px 6px 0; font-size: 13px; }
.tank-lb b { font-weight: 500; }
.tank-lb small { font-size: 11px; color: var(--ink-2); }
.tank-st { margin-left: auto; font-size: 11px; color: var(--ink-2); }
.tank-hungry { width: 7px; height: 7px; border-radius: 50%; background: #d9534f; flex: none; }
.tank-walk { position: absolute; top: 12px; right: 12px; height: 20px; padding: 0 8px; border-radius: 999px; font-size: 10.5px; display: flex; align-items: center; background: rgba(239, 210, 138, .92); color: #4c3f20; }
.tank-doors { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; flex: none; }
.tank-doors .tank-door { flex-direction: row; align-items: center; gap: 10px; padding: 10px 12px; min-height: 64px; border-radius: 20px; }
.tank-door img { width: 40px; height: 40px; flex: none; }
.tank-door b { display: block; font-size: 14px; font-weight: 500; }
.tank-door small { display: block; font-size: 11px; color: var(--ink-2); margin-top: 1px; }

/* The big one: over everything, the bottom bar included; nothing scrolls. */
.tank-big { position: fixed; inset: 0; z-index: 45; overflow: hidden; touch-action: none; color: #e7ecf6; background: #0b1124; }
.tank-big-space, .tank-big-cells { position: absolute; inset: 0; width: 100%; height: 100%; }
.tank-big-space { pointer-events: none; }
.tank-big-cells { pointer-events: none; }
.tank-big-cells .tank-cell { pointer-events: auto; cursor: pointer; }
.tank-big-float { position: absolute; inset: 0; pointer-events: none; }
.tank-decor { position: absolute; transform: rotate(var(--turn, 0deg)); animation: tank-bob 6s ease-in-out infinite; animation-delay: calc(var(--d, 0s) * -1); filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .35)); }
.tank-decor { pointer-events: auto; touch-action: none; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; -webkit-user-drag: none; }
.tank-decor.decor-lamp { animation: none; filter: drop-shadow(0 0 12px rgba(255, 228, 150, .55)); }
.tank-decor.lifted { animation: none; transform: scale(1.12) rotate(var(--turn, 0deg)); filter: drop-shadow(0 14px 18px rgba(0, 0, 0, .5)); z-index: 2; }
.tank-cord { position: absolute; top: 0; width: 1px; background: rgba(230, 236, 250, .5); }
@keyframes tank-bob { 50% { transform: translateY(-7px) rotate(var(--turn, 0deg)); } }
.tank-big-bubbles { position: absolute; inset: 0; pointer-events: none; }
.tank-bubble { position: absolute; width: 22px; height: 22px; margin: -11px; padding: 0; border: none; border-radius: 50%; cursor: pointer; pointer-events: auto;
  background: radial-gradient(circle at 34% 30%, rgba(255, 255, 255, .85) 0 12%, rgba(200, 220, 255, .18) 13% 62%, rgba(200, 220, 255, .38) 63% 100%);
  box-shadow: 0 0 0 1px rgba(210, 225, 255, .55); animation: tank-bubble 4s ease-in-out infinite; animation-delay: calc(var(--d, 0s) * -1); }
.tank-bubble.popping { animation: tank-pop .26s ease-out forwards; }
@keyframes tank-bubble { 50% { transform: translate(3px, -6px); } }
@keyframes tank-pop { to { transform: scale(1.7); opacity: 0; } }
.tank-big-head { position: absolute; left: 0; right: 0; top: 0; display: flex; align-items: center; gap: 10px; padding: calc(env(safe-area-inset-top, 0px) + 14px) 16px 0; }
.tank-big-round { width: 40px; height: 40px; flex: none; border: none; border-radius: 50%; cursor: pointer; color: #e7ecf6; background: rgba(255, 255, 255, .08); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12); display: flex; align-items: center; justify-content: center; }
.tank-big-round svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.tank-big-words { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.tank-big-words b { font-size: 18px; font-weight: 500; }
.tank-big-words small { font-size: 11.5px; color: #9aa6c4; }
.tank-big .tank-jar { background: rgba(255, 255, 255, .08); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12); color: #e7ecf6; }
.tank-big-event { position: absolute; left: 16px; right: 16px; top: calc(env(safe-area-inset-top, 0px) + 68px); font-size: 12px; line-height: 1.5; color: #b9c3dc; pointer-events: none; }
.tank-big-caps { position: absolute; left: 50%; bottom: calc(env(safe-area-inset-bottom, 0px) + 22px); transform: translateX(-50%); display: flex; gap: 4px; padding: 5px; border-radius: 999px;
  background: rgba(255, 255, 255, .08); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14), 0 10px 30px -10px rgba(0, 0, 0, .6); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.tank-big-caps button { height: 42px; padding: 0 16px; white-space: nowrap; flex: none; border: none; border-radius: 999px; cursor: pointer; font: inherit; font-size: 14px; color: #e7ecf6; background: none; display: flex; align-items: center; gap: 6px; }
.tank-big-caps button:active { background: rgba(255, 255, 255, .1); }
.tank-big-caps svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.tank-grain { width: 18px; height: 18px; border-radius: 50%; background: radial-gradient(circle, rgba(170, 190, 255, .55) 0 40%, rgba(170, 190, 255, .15) 41% 100%); box-shadow: 0 0 0 1.5px rgba(190, 205, 255, .7); }
.tank-grain-drop { position: absolute; width: 7px; height: 9px; margin: -4px; border-radius: 50%; background: #f3e6c4; box-shadow: 0 0 6px rgba(243, 230, 196, .7); pointer-events: none; animation: tank-grain-in .6s ease-out; }
@keyframes tank-grain-in { from { transform: translateY(-40px); opacity: 0; } }
.tank-struggle { fill: none; stroke: rgba(230, 238, 255, .8); stroke-width: 2; stroke-linecap: round; pointer-events: none; }
.tank-heart { position: absolute; font-size: 22px; color: #f28fb4; transform: translate(-50%, 0); }

/* 小賣部: a striped wall, shelves with a plank under each, the jar on the counter. */
.shop-room { flex: none; border-radius: 22px; overflow: hidden; background: var(--glass); box-shadow: var(--raise); }
#shopShelves { padding: 12px 12px 4px;
  background: repeating-linear-gradient(90deg, transparent 0 22px, rgba(var(--accent-rgb), .045) 22px 44px); }
.shop-shelf { padding: 8px 2px 10px; border-bottom: 5px solid rgba(var(--accent-rgb), .12); box-shadow: 0 3px 0 -1px rgba(0, 0, 0, .06); margin-bottom: 12px; }
.shop-label { font-size: 12px; font-weight: 500; color: var(--ink); margin: 0 2px 8px; }
.shop-label small { font-weight: 400; color: var(--ink-2); margin-left: 6px; font-size: 11px; }
.shop-tanks { display: flex; flex-wrap: wrap; gap: 6px; margin: -2px 2px 10px; }
.shop-tank { height: 26px; padding: 0 10px; border: none; border-radius: 999px; font: inherit; font-size: 12px; cursor: pointer; color: var(--ink-2); background: hsla(var(--h), 40%, 60%, .12); }
.shop-tank.on { color: var(--ink); background: hsla(var(--h), 45%, 62%, .32); box-shadow: inset 0 0 0 1.5px hsla(var(--h), 45%, 50%, .6); }
.shop-items { display: flex; flex-wrap: wrap; gap: 4px 2px; justify-content: flex-start; }
.shop-item { width: calc((100% - 8px) / 5); min-width: 56px; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 0 0 2px; border: none; background: none; cursor: pointer; font: inherit; color: var(--ink); }
.shop-item img { width: 48px; height: 48px; object-fit: contain; filter: drop-shadow(0 3px 3px rgba(0, 0, 0, .12)); }
.shop-item span { font-size: 11px; white-space: nowrap; }
.shop-item b { font-size: 10.5px; font-weight: 400; color: var(--ink-2); display: flex; align-items: center; gap: 2px; }
.shop-item b::before { content: ''; width: 8px; height: 8px; border-radius: 50%; box-shadow: inset 0 0 0 1.3px rgba(var(--accent-rgb), .7); }
.shop-item:disabled { opacity: .45; cursor: default; }
.shop-placed-row { display: flex; flex-wrap: wrap; gap: 6px; margin: 10px 2px 0; }
.shop-placed { height: 24px; padding: 0 4px 0 10px; border: none; border-radius: 999px; font: inherit; font-size: 11.5px; cursor: pointer; color: var(--ink); background: var(--glass-solid, var(--glass)); box-shadow: var(--raise); display: flex; align-items: center; gap: 4px; }
.shop-placed i { font-style: normal; width: 16px; height: 16px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: var(--ink-2); background: rgba(var(--accent-rgb), .1); }
.shop-empty { font-size: 11.5px; color: var(--ink-2); }
.shop-later { height: 48px; border-radius: 14px; border: 1.5px dashed rgba(var(--accent-rgb), .3); display: flex; align-items: center; justify-content: center; font-size: 12px; color: var(--ink-2); }
.shop-counter { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-top: 1px solid rgba(var(--accent-rgb), .12); background: rgba(var(--accent-rgb), .04); }
.shop-counter img { width: 64px; height: 64px; flex: none; }
.shop-counter b { display: block; font-size: 14px; font-weight: 500; }
.shop-counter small { display: block; font-size: 11px; color: var(--ink-2); line-height: 1.5; margin-top: 2px; }
.shop-note { flex: none; font-size: 12px; color: var(--ink-2); padding: 0 4px; min-height: 0; }
.shop-note:empty { display: none; }
.shop-orders { flex: none; display: flex; flex-direction: column; gap: 6px; }

/* 收集冊 */
.book { flex: none; padding: 12px; border-radius: 22px; background: var(--glass); box-shadow: var(--raise); }
.book-sub { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--ink-2); margin: 0 2px 10px; }
.book-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.book-card { position: relative; aspect-ratio: 5 / 7; border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; padding-bottom: 8px; font-size: 10.5px; color: var(--ink-2); text-align: center; }
.book-card.got img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.book-card.got { box-shadow: var(--raise); cursor: zoom-in; }
.book-card.blank { border: 1.5px dashed rgba(var(--accent-rgb), .28); }
.book-card.back { justify-content: center; gap: 6px; padding: 0; background: linear-gradient(180deg, #1b2452, #0c1226); color: #c9d3f0; box-shadow: var(--raise); }
.book-card.back svg, .book-btn svg { width: 30px; height: 22px; }
.book-card.back svg ellipse, .book-btn svg ellipse { fill: #8fa6e8; opacity: .9; }
.book-card.back svg ellipse.b, .book-btn svg ellipse.b { fill: #eef1f7; }
.book-card.taped { background: #fbfaf6; box-shadow: var(--raise); color: #4c4a44; }
.book-card.taped b { font-weight: 500; font-size: 10.5px; }
.book-tape { position: absolute; top: 14px; left: 50%; transform: translateX(-50%) rotate(-3deg); width: 82%; padding: 3px 0; font-size: 9.5px; line-height: 1.35; color: #6b5a2c; background: rgba(239, 210, 138, .75); }
.book-card.landing > * { visibility: hidden; }
.book-card.fresh { animation: aq-card-pop 0.55s ease-out; }
.book-grid.complete .book-card { animation: aq-card-shimmer 0.9s ease-in-out calc(var(--i, 0) * 80ms) 1 both; }
.album-whole { margin-top: 10px; height: 64px; border-radius: 14px; border: 1.5px dashed rgba(var(--accent-rgb), .28); display: flex; align-items: center; justify-content: center; font-size: 12px; color: var(--ink-2); overflow: hidden; }
.album-whole.got { border: none; height: auto; box-shadow: var(--raise); }
.album-whole.got img { width: 100%; display: block; }
.book-draw { flex: none; display: flex; align-items: center; gap: 12px; padding: 0 2px; }
.book-btn { height: 44px; padding: 0 18px 0 12px; border: none; border-radius: 999px; cursor: pointer; font: inherit; font-size: 14px; display: flex; align-items: center; gap: 6px; color: #eef1f7; background: #33447a; box-shadow: var(--raise); flex: none; }
.book-btn:disabled { opacity: .5; cursor: default; }
.book-hint { font-size: 11px; color: var(--ink-2); line-height: 1.5; }
