:root{font-family:system-ui,"Microsoft JhengHei",sans-serif;color:#16352e;background:#f2f5f0;font-synthesis:none}*{box-sizing:border-box}body{margin:0}main{max-width:760px;margin:44px auto;padding:0 20px 30px}header{margin-bottom:30px}.brand{font-size:12px;font-weight:800;letter-spacing:3px;color:#567565}h1{font-size:34px;letter-spacing:-1px;margin:14px 0 8px}header p{color:#587064;margin:0}section{background:#fff;border:1px solid #dce5dc;border-radius:20px;padding:28px;margin-bottom:20px;box-shadow:0 6px 25px #23483005}h2{font-size:18px;margin:0 0 20px}.row{display:grid;grid-template-columns:1fr 1fr;gap:18px}label{display:block;font-size:14px;font-weight:650;margin:18px 0 8px}.row label{margin-top:0}input,select,textarea{font:inherit;color:inherit;width:100%;padding:13px 12px;border:1px solid #c7d5cb;border-radius:10px;background:#fcfdfb;outline:none}input:focus,select:focus,textarea:focus{border-color:#238464;box-shadow:0 0 0 3px #23846419}textarea{resize:vertical;line-height:1.65}.optional,.hint{color:#6b7f73;font-weight:400;font-size:13px}.hint{line-height:1.6;margin:10px 0}button{cursor:pointer;font:inherit;font-weight:650;padding:14px 22px;border:0;border-radius:10px;background:#196c51;color:white;margin-top:18px;min-height:46px}button:disabled{cursor:wait;opacity:.45}#submit,#loginForm button{width:100%}.quiet{float:right;background:transparent;color:#567565;padding:0 10px;margin:0}#message{padding:12px 4px;line-height:1.6;white-space:pre-wrap;color:#864227}footer{text-align:center;font-size:12px;color:#7d8f82;margin-top:28px}.job{padding:16px 0;border-top:1px solid #e8eee7}.job:first-child{border-top:0}.job strong{display:block;font-size:15px;overflow-wrap:anywhere}.job p{font-size:13px;color:#667b6e;line-height:1.5;margin:6px 0}.job a{color:#167657;font-size:14px;display:inline-block;padding:8px 0}.badge{font-size:12px;display:inline-block;padding:4px 8px;border-radius:6px;background:#edf3ed;color:#34664f;margin-top:8px} [hidden]{display:none!important}@media(max-width:540px){main{margin:26px auto;padding:0 14px 20px}section{padding:20px;border-radius:16px}.row{grid-template-columns:1fr;gap:16px}h1{font-size:29px}input,select,textarea{font-size:16px}}

.attachment{display:flex;align-items:center;justify-content:space-between;gap:8px;padding:6px 0;font-size:13px;overflow-wrap:anywhere}.attachment button{width:auto;min-height:32px;margin:0;padding:5px 10px;background:#edf3ed;color:#245b45}.job button{width:auto;min-height:36px;margin:8px 0;padding:8px 12px}
.secondary{width:auto;background:#edf3ed;color:#245b45;margin-top:10px}
.tuning{margin-top:18px}summary{cursor:pointer;font-weight:650}#defaults h3{font-size:15px;margin:18px 0 0}#defaults .row label{margin-top:12px}select:disabled{opacity:.6}
.alert{white-space:pre-wrap;background:#fdecea;color:#8a1f11;border:1px solid #f3c2bb;border-radius:12px;padding:12px 14px;margin:0 0 16px;line-height:1.6;font-weight:600}.badge.bad{background:#fdecea;color:#a3261a}.badge.warn{background:#fff4d6;color:#7a5200}.badge.purple{background:#efe6fb;color:#5b2fa0}.badge.ok{background:#e3f4ea;color:#1d6b43}.badge.muted{background:#eef0ee;color:#667066}

.toolbarTop{display:flex;gap:10px;align-items:center}.toolbarTop button{margin:0;white-space:nowrap}.toolbarTop input{flex:1}
.danger{background:#fdecea;color:#a3261a}.danger.armed{background:#a3261a;color:#fff}
.groupHead{font-size:13px;font-weight:750;color:#34664f;background:#edf3ed;border-radius:8px;padding:6px 10px;margin:14px 0 4px}
.groupHead:first-child{margin-top:0}.badge.muted{background:#eef0ee;color:#6b7a70}.badge.ok{background:#e3f4ea;color:#1d6a45}
.badge{margin-right:6px}.statusHead{display:flex;justify-content:space-between;gap:12px;align-items:flex-start}
.statusHead strong{font-size:17px;overflow-wrap:anywhere}.notice{background:#fff6dc;color:#6e5300;border-radius:10px;padding:10px 12px;line-height:1.6}
fieldset{border:1px solid #dce5dc;border-radius:10px;margin:18px 0 0;padding:6px 14px 12px}legend{font-size:14px;font-weight:650;padding:0 6px}
.choice{display:flex;gap:8px;align-items:flex-start;font-weight:400;margin:8px 0}.choice input{width:auto;margin-top:3px}
.readonly{white-space:pre-wrap;background:#f6f8f5;border:1px solid #e1e8e1;border-radius:10px;padding:10px 12px;font-size:14px;line-height:1.5;max-height:340px;overflow:auto;overflow-wrap:anywhere}
#autoSendsBox summary{font-size:14px;font-weight:600;margin:22px 0 8px;cursor:pointer}#lastPromptBox h3,#history h3{font-size:14px;margin:22px 0 8px}.hist{font-size:13px;color:#546a5d;padding:6px 0;border-top:1px solid #eef2ee}
#back{margin:0 0 14px}
@media(max-width:540px){.grid3{grid-template-columns:1fr 1fr}.statusHead{flex-direction:column}}

/* compact list: one line per conversation, no separators, status = name background */
.controls{display:flex;flex-wrap:wrap;gap:8px;align-items:center;margin-top:12px}.controls button,.controls select{width:auto;margin:0;min-height:36px;padding:6px 12px;font-size:14px}
.toggle{background:#edf3ed;color:#245b45}.toggle.open{background:#196c51;color:#fff}.toggle.open .optional{color:#dfeee6}label.inline{display:inline;margin:0 0 0 6px;font-size:14px}
.panel{margin-top:10px;border:1px solid #e1e8e1;border-radius:12px;padding:4px 14px 14px}.panel .row label{margin:12px 0 6px}
.conv{display:flex;align-items:center;gap:6px;padding:2px 0;cursor:pointer;min-width:0}
.name{flex:0 1 auto;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:13px;font-weight:650;padding:3px 8px;border-radius:7px}
.conv .project{flex:1 1 auto;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:13px;color:#6b7f73}
.tone-blue{background:#2f6fd6;color:#fff}.tone-green{background:#1f8a4c;color:#fff}.tone-orange{background:#ef8a17;color:#fff}.tone-red{background:#d23a2a;color:#fff}.tone-purple{background:#7b4bc4;color:#fff}.tone-unsure{background:#fff;color:#5b2fa0;box-shadow:inset 0 0 0 2px #7b4bc4}.tone-darkred{background:#7a1a12;color:#fff}.tone-gray{background:#b5bcb7;color:#fff}.tone-later{background:#6f7873;color:#fff}.tone-standby{background:#c9cfcb;color:#36423c}.tone-lost{background:#1d1d1d;color:#ff6b5c}.tone-closed{background:#e6e9e6;color:#8a948d;text-decoration:line-through}
/* 00451: 管外 — a session this site did not open: yellow name instead of white, on the same status colour */
.name.external{color:#ffe14a;text-shadow:0 0 2px #000,0 0 2px #000}.tone-legend-external{background:#555c58}.tone-closed.external{color:#a8961c;text-shadow:none}
.legend{display:inline-grid;gap:4px;margin-top:10px}.legend .name{font-size:11px;padding:1px 6px;font-weight:600;text-align:center}
#convList .groupHead{margin:8px 0 2px;padding:3px 8px}#convList .groupHead:first-child{margin-top:0}
.grid3{display:grid;grid-template-columns:repeat(3,1fr);gap:0 14px}.grid3 label{margin:12px 0 6px}
.actions button{width:auto;min-height:34px;margin:0;padding:6px 12px;font-size:13px}
.outgoing{padding:8px 0 10px;border-bottom:1px solid #f3c2bb}.outgoing strong{font-size:15px;overflow-wrap:anywhere}.outgoing p{font-size:13px;color:#667b6e;line-height:1.5;margin:4px 0}.outgoing .actions{display:flex;flex-wrap:wrap;gap:8px;margin-top:6px}.outgoing p.raw{font-size:12px;color:#8a9a90}.outgoing .peek summary{font-size:13px;color:#2f6b4f;cursor:pointer}.outgoing .peekText{white-space:pre-wrap;overflow-wrap:anywhere;max-height:40vh;overflow:auto;background:#f7faf8;border-radius:6px;padding:6px 8px;color:#1f2d24}
@media(max-width:540px){.grid3{grid-template-columns:1fr 1fr}.panel .row{grid-template-columns:1fr 1fr;gap:12px}}
.controls{flex-wrap:nowrap}.controls .toggle,.controls label{flex:none;white-space:nowrap}.controls select{flex:0 1 auto;min-width:0}
.conv .project{flex:0 100 auto}
@media(max-width:540px){.controls{gap:6px}.controls button,.controls select{padding:6px 8px}}
@media(max-width:540px){#sortLabel{display:none}}

/* 00377: 發送 · 睡眠 · 關閉 always side by side, 發送 twice as wide; top and bottom of the detail page */
.triple{display:grid;grid-template-columns:1.6fr 1.6fr 1fr 1fr;gap:8px;margin:0 0 16px}.triple button{width:100%;margin:0;min-height:44px;padding:10px 6px}@media(max-width:540px){.triple{gap:6px}.triple button{font-size:14px;padding:8px 4px;line-height:1.25}}
#bottomActions{margin:18px 0 0}.danger.armed{background:#a3261a;color:#fff}
/* 00378: extra 「回到列表」 in spare corners (phone); the computer layout has the sidebar instead */
.backLink{background:transparent;color:#196c51;margin:0;padding:4px 6px;min-height:0;font-size:13px;font-weight:650;white-space:nowrap;flex:none}
.backBtn{margin:0 0 14px}#detailView>.backBtn:last-child{margin:4px 0 0}
#lastPromptBox h3{display:flex;align-items:center;gap:6px;flex-wrap:wrap}#lastPromptBox h3 .backLink{margin-left:auto}
/* 00379: new conversation shows tool, computer, category, project first; the rest is folded */
#convSettings{border:1px solid #dce5dc;border-radius:12px;padding:10px 14px}#convSettings>summary{font-size:15px}
#convSettings.flat{border:0;padding:0}#convSettings.flat>summary{display:none}#convSettings.forked{border-color:#ef8a17;background:#fffaf2}
.settingsBody>.row{margin-top:16px}#convSettings.flat .settingsBody>.row:first-child{margin-top:0}
#advanced{margin-top:16px;border-top:1px solid #eef2ee;padding-top:12px}#advanced>summary{font-size:14px}
#settingsSummary,#advancedSummary{overflow-wrap:anywhere}#forkNotice{margin:14px 0 0}#forkNotice button{margin:8px 0 0}
/* 00375: one card per A／B／C number */
.cardsHead{display:flex;justify-content:space-between;align-items:center;margin-top:18px}.cardsHead h3{font-size:15px;margin:0}
.card{border:1px solid #dce5dc;border-left:5px solid #b5bcb7;border-radius:12px;padding:12px 14px;margin:10px 0;background:#fcfdfb}
.card-a{border-left-color:#d23a2a}.card-b{border-left-color:#2f6fd6}.card-c{border-left-color:#1f8a4c}
.cardHead{display:flex;gap:8px;align-items:center;flex-wrap:wrap}.cardHead strong{flex:1 1 auto;min-width:0;font-size:15px;overflow-wrap:anywhere}
.letter{flex:none;display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:6px;color:#fff;font-size:13px;font-weight:800;background:#b5bcb7}
.card-a .letter{background:#d23a2a}.card-b .letter{background:#2f6fd6}.card-c .letter{background:#1f8a4c}
.plain{white-space:pre-wrap;line-height:1.65;margin:8px 0;overflow-wrap:anywhere}
.pro>summary{font-size:13px;color:#567565;font-weight:600}.proText{white-space:pre-wrap;font-size:14px;line-height:1.6;color:#36574a;background:#f6f8f5;border-radius:8px;padding:8px 10px;margin-top:6px;overflow-wrap:anywhere}
.editWrap{position:relative;margin-top:10px}.editWrap textarea{padding-right:42px}
/* 00496/00497: no drag corner — on a phone a stray touch on it squashed the box to one line and put the ✕ on top of it.
   The box is never shorter than two lines and grows with the text instead (app.js grows it where field-sizing is missing). */
.editWrap textarea{resize:none;field-sizing:content;min-height:calc(3.3em + 28px);max-height:50vh;overflow-y:auto}
.editWrap .x{position:absolute;top:6px;right:6px;width:30px;height:30px;min-height:0;margin:0;padding:0;border-radius:50%;background:#eef0ee;color:#5f6d64;font-size:14px;line-height:30px}
#skipped{display:flex;align-items:center;flex-wrap:wrap;gap:6px}#skipped button{margin:0;min-height:30px;padding:4px 10px}
/* 00374: computer layout — list as a sidebar beside the open conversation, like the Claude Code web page */
@media(min-width:900px){
main{max-width:1440px;margin:0 auto;padding:14px 24px 24px}header{margin-bottom:14px}h1{font-size:24px;letter-spacing:0;margin:6px 0 4px}
#workspace{display:grid;grid-template-columns:320px minmax(0,1fr);gap:0 20px;align-items:start}#alerts{grid-column:1/-1}
#listView{grid-column:1;position:sticky;top:12px;max-height:calc(100vh - 24px);overflow-y:auto;overscroll-behavior:contain}
#listView section{padding:14px;margin-bottom:12px;border-radius:14px}.controls{flex-wrap:wrap}
#detailView,#emptyView{grid-column:2;min-width:0}
.conv:hover{background:#f3f7f2;border-radius:8px}
/* 00394: the open conversation must be obvious in the sidebar: black band, white project text.
   2026-10-06: with a long name the band is mostly off to the right, so the row also gets a thick black frame
   (white gap, then 4 px black), with margins so the frame is not cut off by the list box or covers the next row. */
.conv.active,.conv.active:hover{background:#000;border-radius:8px;box-shadow:0 0 0 2px #fff,0 0 0 6px #000;margin:8px 6px;padding:2px 3px}.conv.active .project{color:#fff;font-weight:700}.conv.active .name{outline:2px solid #fff}
.conv.active.flag{box-shadow:0 0 0 2px #fff,0 0 0 6px #000,0 0 0 8px #d23a2a;margin:10px 8px}
[data-back]{display:none!important}}
/* 00388: page hint and availability line take no space when empty */
#pageHint:empty,.hint:empty{display:none}
/* 00399: no brand line, no counts box, no status card; the page title is only kept on a phone, where
   there is no sidebar to show which conversation is open. Log out moved to the footer. */
footer .quiet{float:none;width:auto;min-height:0;font-size:12px}
@media(min-width:900px){header{display:none}main{padding-top:12px}}
@media(max-width:899px){header{margin-bottom:12px}h1{font-size:22px;letter-spacing:0;margin:0}}
/* 00385: no buttons in the sidebar rows; the conversation name is the same size as the project name, so the sidebar is narrower */
.conv{user-select:none;-webkit-user-select:none;-webkit-touch-callout:none}
/* 00404–00407: the sidebar toolbar is one sticky line — 新增 · 篩選 · 排序 · 分組 at the conversation-name size;
   no search box, no count line; filter, sort and group panels open only when tapped, one column */
.toolbar{position:sticky;top:0;z-index:5}#listView .toolbar{padding:8px 10px}
.controls{display:flex;flex-wrap:nowrap;gap:6px;margin:0}
.controls .toggle{flex:none;white-space:nowrap;font-size:13px;font-weight:650;min-height:0;margin:0;padding:5px 10px;border-radius:7px}
#newConv{background:#196c51;color:#fff}
.toolbar .panel{margin-top:8px;padding:8px 10px;max-height:calc(100vh - 90px);overflow-y:auto;overscroll-behavior:contain}
.stack{display:grid;gap:5px}.stack>div{display:grid;grid-template-columns:5.5em minmax(0,1fr);align-items:center;gap:8px}
.stack label{margin:0;font-size:13px;font-weight:600}
/* 00482: filter rows drag by their name; category and project sit together as one two-level item. */
#filterStack>div{border-radius:7px}#filterStack label{cursor:grab;user-select:none;-webkit-user-select:none;-webkit-touch-callout:none}#filterStack>.dragging{background:#e3efe7;box-shadow:0 2px 8px rgba(22,53,46,.18);position:relative;z-index:1}#filterStack>.dragging label{cursor:grabbing}
#filterStack>.pair{display:grid;grid-template-columns:1fr;gap:5px}#filterStack>.pair>div{display:grid;grid-template-columns:5.5em minmax(0,1fr);align-items:center;gap:8px}#filterStack .sub label{padding-left:.9em;font-weight:500}#filterStack .sub label::before{content:'└ ';color:#8aa59a}
.stack select{font-size:13px;padding:3px 6px;border-radius:7px;min-height:0}
#resetFilters{font-size:13px;min-height:0;padding:5px 12px;margin-top:8px}
/* 00416: the sidebar is three quarters of its former width (320 → 240 px) */
@media(min-width:900px){#workspace{grid-template-columns:240px minmax(0,1fr)}}
/* 00417: long names are no longer cut off; the sidebar list scrolls sideways instead. The list has its own scroll box under
   the toolbar, so its bottom scrollbar stays at the bottom of the window, and #hTop repeats the sideways bar above the list.
   Scrollbars are drawn always-on (not the thin auto-hiding kind), on every page. */
html{overflow-y:scroll}
::-webkit-scrollbar{width:12px;height:12px}::-webkit-scrollbar-track{background:#e3eae3}::-webkit-scrollbar-thumb{background:#8ea596;border-radius:6px;border:2px solid #e3eae3}::-webkit-scrollbar-thumb:hover{background:#5f7d6b}::-webkit-scrollbar-corner{background:#e3eae3}
#listView{display:flex;flex-direction:column;position:sticky;top:0;max-height:100dvh;overflow:hidden}
#listView>.toolbar{flex:none;margin-bottom:6px}
.hbar{flex:none;overflow-x:scroll;overflow-y:hidden;max-width:100%;margin:0 0 4px}.hbar>div{height:1px}
#listScroll{flex:1 1 auto;min-height:0;overflow:scroll;overscroll-behavior:contain}
#listBox{width:max-content;min-width:100%}
.outgoing{contain:inline-size}
.conv{min-width:0}.conv .name,.conv .project{flex:none;overflow:visible;text-overflow:clip}
@media(max-width:899px){#listView{max-height:calc(100dvh - 76px)}}
@media(min-width:900px){#listView{top:12px;max-height:calc(100vh - 24px);overflow:hidden}}
/* 00416: four toolbar buttons still fit on one line in the narrower sidebar */
@media(min-width:900px){.controls{gap:4px}.controls .toggle{padding:5px 6px}}
/* 00421: the defaults heading sits in the 240 px sidebar; a smaller size keeps it on one line */
#defaults>summary{font-size:13px;white-space:nowrap}
/* 00435: files the AI sent with its answer, always open, one tap downloads */
#answerFiles{margin:10px 0 4px}
.fileLink{display:flex;align-items:center;flex-wrap:wrap;gap:8px;margin:6px 0;padding:8px 12px;border:1px solid #9cc5ae;border-radius:10px;background:#edf6f0;color:#14563a;font-weight:600;overflow-wrap:anywhere}
.fileLink .fileName{flex:1 1 12em;min-width:0}.fileLink .size{font-weight:400;font-size:13px;color:#4c6b5a;white-space:nowrap}
/* 00618: AI 回傳的檔案 — 預覽 and 下載 on each row */
.fileLink button{margin:0;min-height:36px;padding:6px 14px;width:auto}.fileDownload{white-space:nowrap;font-size:14px;font-weight:400;color:#14563a}
/* 00607: a red frame instead of a floating toast */
#notice{grid-column:1/-1}
.redFrame{border:2px solid #d23a2a;border-radius:10px;background:#fff;color:#8a1c12;padding:8px 12px;margin:0 0 12px;font-size:14px;line-height:1.5;white-space:pre-wrap}
.conv.flag{box-shadow:0 0 0 2px #d23a2a;border-radius:8px;padding:3px 4px;margin:3px 0}
.legend .flagLegend{background:#fff;color:#16352e;box-shadow:inset 0 0 0 2px #d23a2a}
/* 00453/00454: 搜尋 joins the toolbar as a fifth folding button (新增 · 篩選 · 排序 · 分組 · 搜尋, still one line);
   the ▾ marks are gone so the line stays compact. The search box is input + magnifier + clear on one row. */
.searchRow{display:flex;gap:4px;align-items:center;margin:0}
.searchRow input{flex:1 1 auto;min-width:0;margin:0;font-size:13px;padding:5px 8px;border-radius:7px;min-height:0}
.searchRow button{flex:none;width:auto;margin:0;min-height:0;padding:4px 8px;font-size:13px;border-radius:7px}
#searchInfo{margin:6px 0 0;font-size:12px}
.conv .hit{flex:none;white-space:nowrap;font-size:12px;color:#8a6d1f}/* 00577: only-in-content hit, with the matching words */
.conv.active .hit{color:#fff}
@media(max-width:540px){.searchRow input{font-size:16px}}
/* 00453: with five buttons the "(n)" counts no longer fit on the line, so each count is a small badge on the button's
   top-right corner that takes no width: 篩選 = how many filters are on, 分組 = 1 when grouped, 搜尋 = how many words. */
.controls .toggle{position:relative}.controls .mark:empty{display:none}
.controls .mark{position:absolute;top:-6px;right:-5px;min-width:15px;height:15px;line-height:15px;padding:0 3px;border-radius:8px;background:#c2410c;color:#fff;font-size:10px;font-weight:700;text-align:center;pointer-events:none}
/* 00455: 重要 — a star sits in the space between the computer letter and the name. The space stays a plain space,
   so the letter-to-name distance is exactly what it was; the star is drawn on top of it at a smaller size, taking no width. */
.name .gap{position:relative}
.name.important .gap::after{content:'*';position:absolute;left:50%;top:50%;transform:translate(-50%,-32%);font-size:1.1em;line-height:1;font-weight:800;pointer-events:none}
.name .star{font-weight:800;margin-right:2px}
/* 00509: 置頂 keeps the 重要 star and adds a dark bar under the name; box-shadow takes no width. */
.name.pinned{box-shadow:inset 0 -3px 0 #0009}
/* 00580: where 置頂 ends in an ungrouped list — a 2px line fading out at both ends. It spans the visible part of the
   sideways-scrolling sidebar (--seen, set by app.js) and stays put while it scrolls, so both fades are always in view. */
.pinDivider{position:sticky;left:14px;width:calc(var(--seen,100%) - 28px);height:2px;margin:5px 0;border-radius:1px;background:linear-gradient(90deg,transparent,#5e8f75 20%,#5e8f75 80%,transparent)}
.triple select{width:100%;margin:0;min-height:44px;padding:8px 6px;font-weight:650;text-align:center;background:#edf3ed;color:#245b45;border:0;border-radius:10px}
.name .owner{font-size:.85em;opacity:.75;margin-left:4px}
/* 00467、00468、00458 progress box */
#progressBox h3{font-size:14px;margin:0 0 8px}#progressLinesBox h3{margin-top:14px}.prow{display:grid;grid-template-columns:7.5em 1fr;gap:8px;font-size:14px;line-height:1.55;padding:5px 0;border-top:1px solid #eef2ee}.prow:first-child{border-top:0}.prow .k{color:#6b7f73}.prow .v{overflow-wrap:anywhere}.prow .v button{margin:0;padding:0;min-height:0;background:none;color:#167657;text-decoration:underline;font-weight:600}.prow.warn .v{color:#8a5200}.lines{font-family:ui-monospace,Consolas,"Microsoft JhengHei",monospace;font-size:13px;white-space:pre-wrap}.lines .t{color:#8a9a90}.lines .u{color:#5b2fa0}.lines .tool{color:#196c51}@media(max-width:540px){.prow{grid-template-columns:1fr;gap:2px}}
/* 00462: 對話中心 Chat Center — one thin bar at the very top on every screen: name, who is signed in, mode switch (admin only) */
#appBar{display:flex;align-items:center;flex-wrap:wrap;gap:6px 12px;margin:0 0 10px;padding:4px 2px;font-size:13px;color:#36574a}
#appBar .brandName{font-size:15px;font-weight:800;color:#16352e;letter-spacing:1px;white-space:nowrap}#appBar .brandName b{font-weight:800;color:#1f8a4c}#appBar .brandName span{font-weight:600;font-size:12px;color:#567565}
#whoami{margin-left:auto;white-space:nowrap}#whoami:empty{display:none}
#modeSwitch{display:inline-flex;gap:0;border:1px solid #b9cbbf;border-radius:8px;overflow:hidden}#modeSwitch[hidden]{display:none}
#modeSwitch button{width:auto;min-height:0;margin:0;padding:4px 10px;border:0;border-radius:0;background:#fff;color:#36574a;font-size:13px;font-weight:600}
#modeSwitch button+button{border-left:1px solid #b9cbbf}#modeSwitch button.on{background:#16352e;color:#fff}
.googleBtn{display:inline-block;padding:12px 22px;border-radius:10px;background:#1a73e8;color:#fff;font-weight:700;text-decoration:none}
.googleBtn.disabled{background:#b5bcb7;pointer-events:none}
.userRow{display:flex;flex-wrap:wrap;align-items:center;gap:4px 10px;padding:8px 0;border-top:1px solid #e3e9e4}.userRow:first-child{border-top:0}
.userName{font-weight:700}.userMail{font-size:12px;color:#567565;overflow-wrap:anywhere}.userRow select{width:100%;margin:0}
@media(min-width:900px){main{padding-top:8px}#listView{max-height:calc(100vh - 52px)}}
/* 00494/00495: 發送紀錄 and 最近一輪 show what was sent — text, pictures, files */
.histHead{margin-bottom:6px}.histText{color:#1f2a24;margin:4px 0 6px}.sentFiles{display:flex;flex-wrap:wrap;gap:8px;margin:6px 0 4px}.sentFile{font-size:13px;overflow-wrap:anywhere;max-width:100%}.sentFile img{display:block;max-width:min(100%,320px);max-height:240px;border:1px solid #e1e8e1;border-radius:8px;background:#fff}.sentFile a{color:#245b45}
/* 00541: what the chosen 來源 means, under its select (the dropdown itself holds names only, 00538) */
#fOriginHint{grid-column:1/-1;margin:0;font-size:12px}#fOriginHint:empty{display:none}
/* 00546–00548: a conversation still with the AI opens on what was sent; 編輯 pauses a queued send for editing or adds to the running CLI */
#detailView.preview #taskArea,#detailView.preview #cardsBox,#detailView.preview #plainAnswer,#detailView.preview [data-send],#detailView.preview #submit,#detailView.preview #lastPromptBox,#detailView.preview #autoSendsBox,#detailView.preview #answerFiles{display:none}
/* 00802: an automatic send (timed wake, monitor) is working: the answer stays, only the send controls step aside */
#detailView.autorun #taskArea,#detailView.autorun [data-send],#detailView.autorun #submit,#detailView.autorun #lastPromptBox{display:none}
.editRow{display:flex;flex-wrap:wrap;gap:8px}.editRow button{margin-top:12px;width:auto}
#heldNotice{margin:14px 0}#heldNotice .choice{margin:10px 0 0;font-weight:500}#heldNotice button{margin-top:10px;width:auto}
.appendItem{border-top:1px solid #e8eee7;padding:10px 0}.appendItem:first-child{border-top:0}.appendHead{font-size:13px;color:#4c6457;margin-bottom:6px}.appendItem.failed .appendHead{color:#9b2c1c}.appendItem.sent .appendHead{color:#2f6b4f}.appendItem .actions{display:flex;gap:8px;margin-top:6px}
/* 00493: the hold menu on phones */
.levelMenu{position:fixed;inset:0;background:#0006;display:flex;align-items:flex-end;justify-content:center;z-index:60}
.levelBox{background:#fff;width:min(420px,100vw);border-radius:14px 14px 0 0;padding:12px 16px calc(16px + env(safe-area-inset-bottom));display:flex;flex-direction:column;gap:8px}
.levelTitle{font-weight:700;padding:4px 2px 6px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.levelBox button{width:100%;min-height:46px;font-size:16px;margin:0}
.levelHint{margin:0 2px 4px}
.levelBox button.current{outline:3px solid #000;outline-offset:-3px}
/* 00559: attachment preview */
.attachment button+button{margin-left:6px}.attachment span{flex:1}
.filePreview{position:fixed;inset:0;background:#000b;display:flex;align-items:center;justify-content:center;z-index:70;padding:16px}
.fpBox{background:#fff;border-radius:14px;width:min(960px,100%);max-height:100%;display:flex;flex-direction:column;overflow:hidden}
.fpHead{display:flex;align-items:center;gap:10px;padding:10px 12px;border-bottom:1px solid #e3eae3}
.fpName{flex:1;min-width:0;font-size:13px;overflow-wrap:anywhere}
.fpOpen{font-size:13px;color:#167657;white-space:nowrap}
.fpHead button{margin:0;min-height:36px;padding:6px 14px;width:auto}
.fpBody{overflow:auto;min-height:120px;display:flex;flex-direction:column;align-items:center}
.fpBody img{max-width:100%;max-height:calc(100vh - 110px);max-height:calc(100dvh - 160px);object-fit:contain;display:block}
.fpPages{width:100%;padding:8px;box-sizing:border-box;display:flex;flex-direction:column;gap:8px;background:#e8e8e8}
.fpPage{display:block;width:100%;height:auto;background:#fff;box-shadow:0 1px 3px rgba(0,0,0,.25)}
.fpText{align-self:stretch;margin:0;padding:12px;font-size:13px;white-space:pre-wrap;overflow-wrap:anywhere}
.fpBody .hint{padding:0 16px}
.fpBody img.fpFit{max-width:none;max-height:none;object-fit:fill;flex:none}.fpDim{margin:6px 0 10px}
/* 00570: settings of a send shown with its text; 00571: sent attachments as rows with 預覽／下載 */
.sentSettings{font-size:13px;color:#245b45;background:#eef5ef;border-radius:8px;padding:6px 10px;margin:4px 0 8px;overflow-wrap:anywhere}
.sentFiles{flex-direction:column}.sentFile.attachment{display:flex;align-items:center;gap:8px}.sentFile.attachment button{margin:0;min-height:36px;padding:6px 14px;width:auto}
.sentDownload{white-space:nowrap;font-size:13px}
/* 00579: the row just tapped, while its conversation is loading */
.conv.opening .name{opacity:.6}.conv.opening::after{content:'開啟中…';flex:none;font-size:.85em;color:#1b5e3a;font-weight:700}
#usageBox summary{cursor:pointer;font-size:14px;line-height:1.6;margin:0 0 6px}#usageBox summary b{margin-right:4px}#usageLine{color:#2d4a3a}@media(min-width:541px){#usageBox .prow{grid-template-columns:9.5em 1fr}}#usageBox .usub{font-weight:700;font-size:13px;color:#2d4a3a;margin:12px 0 2px}#usageBox .usub:first-child{margin-top:0}#usageBox meter{width:5em;height:.8em;vertical-align:middle}
/* 00073 (PCSlowWhite): why a queued row waits and its place, on its own line under the name, readable on a phone */
/* a grid, not a wrapping flex row: in the max-content list a wrapping flex row is as wide as all its items on one line */
/* 00618: Markdown preview laid out as a page */
.fpToggle{margin:0;min-height:36px;padding:6px 14px;width:auto}
.fpBody>.md{align-self:stretch;min-width:0;width:100%;box-sizing:border-box}
.md{max-width:820px;margin:0 auto;padding:14px 20px 24px;font-size:15px;line-height:1.75;color:#1f2a24;overflow-wrap:anywhere;text-align:left}
.md>:first-child{margin-top:0}
.md p{margin:0 0 12px}
.md .mdH{margin:22px 0 10px;line-height:1.35;font-weight:700;color:#14301f}
.md h1.mdH{font-size:1.6em;padding-bottom:6px;border-bottom:2px solid #d5e4d9}
.md h2.mdH{font-size:1.35em;padding-bottom:4px;border-bottom:1px solid #e1e8e1}
.md h3.mdH{font-size:1.15em}.md h4.mdH{font-size:1.02em}.md h5.mdH,.md h6.mdH{font-size:.95em;color:#4c6b5a}
.md a{color:#167657;text-decoration:underline}
.md code{overflow-wrap:anywhere;word-break:break-word;font-family:ui-monospace,Consolas,"Cascadia Mono",monospace;font-size:.88em;background:#eef3ef;border:1px solid #e1e8e1;border-radius:5px;padding:1px 5px}
.md pre.mdCode{margin:0 0 14px;padding:12px 14px;background:#f5f8f6;border:1px solid #e1e8e1;border-radius:8px;overflow:auto;line-height:1.5}
.md pre.mdCode code{background:none;border:0;padding:0;font-size:13px;white-space:pre}
.md pre.mdFront{margin:0 0 14px;padding:8px 12px;font-size:12px;color:#4c6b5a;background:#f7f7f2;border-left:3px solid #c9d6c9;white-space:pre-wrap}
.md ul.mdUl,.md ol.mdOl{margin:0 0 12px;padding-left:1.6em}
.md li{margin:3px 0}.md li>ul,.md li>ol{margin:4px 0 4px}
.md li.mdTask{list-style:none;margin-left:-1.3em}.md li.mdTask input{margin:0 6px 0 0;vertical-align:-2px;width:auto;min-height:0}
.md blockquote.mdQuote{margin:0 0 12px;padding:6px 14px;border-left:4px solid #9cc5ae;background:#f4f9f5;color:#33493d}
.md blockquote.mdQuote>:last-child{margin-bottom:0}
.md hr.mdRule{border:0;border-top:1px solid #d5e0d7;margin:20px 0}
.md .mdTableWrap{overflow-x:auto;margin:0 0 14px}
.md table.mdTable{border-collapse:collapse;font-size:14px;line-height:1.5;min-width:50%}
.md table.mdTable th,.md table.mdTable td{border:1px solid #d5e0d7;padding:6px 10px;vertical-align:top}
/* PCSlow 00157: .md overflow-wrap:anywhere lets a cell shrink to one character, so a two-digit 編號 wrapped; break-word keeps numbers and short words whole */
.md table.mdTable th,.md table.mdTable td{overflow-wrap:break-word}
.md table.mdTable th{background:#eaf3ec;font-weight:700;text-align:left}
.md table.mdTable tbody tr:nth-child(even){background:#f8fbf8}
.md .mdImg,.md .mdLocal{color:#4c6b5a}.md .mdLocal{text-decoration:underline dotted}
.md del{color:#6b7a70}
@media (max-width:600px){.md{padding:12px 12px 20px;font-size:15px}.md table.mdTable{font-size:13px}}
/* 00650: chosen files as 列表／小圖／大圖 with a tick each; a full-screen viewer to step one by one and tick */
.pickButtons{display:flex;flex-wrap:wrap;gap:8px}.pickButtons button{width:auto;margin:8px 0 0}
.attachBar{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px;margin:10px 0 6px;font-size:13px}
.attachViews{display:inline-flex;border:1px solid #b9cbbf;border-radius:8px;overflow:hidden}.attachViews button{width:auto;min-height:34px;margin:0;padding:4px 14px;border:0;border-radius:0;background:#fff;color:#245b45;font-size:14px}
.attachViews button+button{border-left:1px solid #b9cbbf}.attachViews button.on{background:#16352e;color:#fff}
.pick{position:relative;font-size:13px;overflow-wrap:anywhere}.pick button{margin:0;width:auto}
.pickPic{display:block;padding:0;border:0;border-radius:8px;overflow:hidden;background:#e3ebe5;color:#245b45;min-height:0}.pickPic img{display:block;width:100%;height:100%;object-fit:cover}
.pick:not(.on) .pickPic img,.pick:not(.on) .pickExt{opacity:.5}
.pickExt{display:flex;align-items:center;justify-content:center;width:100%;height:100%;font-weight:700;font-size:13px}
.pick .pickTick{position:absolute;top:6px;left:6px;width:30px;height:30px;min-height:0;padding:0;border-radius:50%;border:2px solid #fff;background:#0005;color:#fff;font-size:17px;line-height:1;box-shadow:0 1px 3px #0006}
.pick.on .pickTick{background:#1f8a4c}.pick .pickRemove{margin-left:auto}
.pickRemove{min-height:30px;padding:4px 10px;background:#edf3ed;color:#245b45;font-size:13px}
.attachItems.list .pick{display:flex;align-items:center;gap:10px;padding:6px 0;border-top:1px solid #eef2ee}.attachItems.list .pickPic{width:56px;height:56px;flex:none}
.attachItems.list .pick .pickTick{position:static;flex:none;border-color:#9fb5a7;box-shadow:none;background:#fff;color:#1f8a4c}.attachItems.list .pick.on .pickTick{background:#1f8a4c;color:#fff;border-color:#1f8a4c}
.attachItems.list .pickInfo{flex:1}.attachItems.list .pick .pickTick{order:-1}
.attachItems.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(96px,1fr));gap:6px}.attachItems.grid .pickPic{width:100%;aspect-ratio:1}
.attachItems.grid .pickInfo{display:block;white-space:nowrap;text-overflow:ellipsis;font-size:12px;line-height:1.3;margin-top:2px;max-height:2.6em;overflow:hidden}.attachItems.grid .pickRemove{display:none}
.attachItems.big .pick{margin:0 0 14px}.attachItems.big .pickPic{width:100%}.attachItems.big .pickPic img{height:auto;object-fit:contain;outline:1px solid #d5ded7;outline-offset:-1px}.attachItems.big .pickExt{height:120px}
.attachItems.big .pick .pickTick{width:40px;height:40px;font-size:22px;top:8px;left:8px}.attachItems.big .pickInfo{display:block;margin:4px 0}
.pickViewer{position:fixed;inset:0;z-index:72;background:#000;color:#fff;display:flex;flex-direction:column}
.pvHead{display:flex;align-items:center;justify-content:space-between;gap:10px;padding:10px 12px;font-size:14px}
.pvHead button{width:auto;margin:0;min-height:38px;padding:6px 16px;background:#fff;color:#16352e}
.pvStage{position:relative;flex:1;min-height:0;display:flex;align-items:center;justify-content:center;touch-action:pan-y;user-select:none;-webkit-user-select:none}
.pvImg{max-width:100%;max-height:100%;object-fit:contain}.pickViewer[data-loading] .pvImg{visibility:hidden}
.pvPrev,.pvNext{position:absolute;top:50%;transform:translateY(-50%);width:46px;height:64px;min-height:0;margin:0;padding:0;border-radius:10px;background:#fff3;color:#fff;font-size:34px;line-height:1}
.pvPrev{left:6px}.pvNext{right:6px}.pvPrev:disabled,.pvNext:disabled{opacity:.15}
.pvFoot{padding:8px 12px 14px}.pvName{font-size:13px;opacity:.85;margin-bottom:8px;overflow-wrap:anywhere}
.pvRow{display:flex;gap:10px}.pvRow button{margin:0;min-height:48px;font-size:17px}.pvRemove{width:auto;padding:6px 16px;background:#fff2;color:#fff}
.pvPick{flex:1;background:#fff;color:#16352e}.pvPick.on{background:#1f8a4c;color:#fff}
.copyBar{display:flex;gap:8px;flex-wrap:wrap;align-items:center;margin:6px 0}.copyBar>button{width:auto;min-height:36px;padding:6px 14px;margin:0}.histCards .card{margin:8px 0}
.histAnswer{margin:6px 0 4px;padding-left:10px;border-left:3px solid #d6e4da}.histAnswer>button{margin:0 0 6px;min-height:36px;padding:6px 14px;width:auto}.histAnswerText{color:#1f2a24;margin:4px 0 8px;overflow-wrap:anywhere}
/* 00748: the list page shows no title line; the header collapses whenever both of its lines are empty */
header:has(>#pageTitle:empty):has(>#pageHint:empty){display:none}
/* 00747 (user 2026-10-09「跟新增和篩選放到同一行，稍微再緊湊一點」): on a phone the three mode buttons close the toolbar line;
   everything shrinks a little so eight buttons fit one line down to a 360 px wide screen */
@media(max-width:899px){#listView .toolbar{padding:7px 7px}.controls{gap:4px}.controls .toggle{padding:5px 7px}
  .controls #modeSwitch{flex:none;margin-left:auto;border-radius:7px}.controls #modeSwitch button{padding:5px 6px;font-size:12px}}
@media(max-width:380px){.controls .toggle{padding:5px 5px}.controls #modeSwitch button{padding:5px 4px}}
/* 00762: usage sits at the top of the settings card, not a card of its own */
#usageBox{margin:0 0 12px}

/* 00808: an answer without A／B／C, shown read-only above the task box */
#plainAnswerBody .md{padding:8px 0 0;margin:0;max-width:none}
/* 00841: 要你回答 blinks the name on its own state colour instead of turning it red */
@keyframes qsBlink{0%,100%{opacity:1}50%{opacity:.3}}.name.blink{animation:qsBlink 1.2s ease-in-out infinite}
/* 00862: a send still within its normal time — visible at once, but not the red alarm card */
.outgoing.calm{border-bottom-color:#dce5dc}.outgoing.calm strong{display:block}
