:root {
  color-scheme: light;
  font-family: system-ui, "Microsoft YaHei UI", sans-serif;
  color: #1b2b28;
  background: #f3f5f0;
  --paper: #fff;
  --ink: #1b2b28;
  --muted: #526760;
  --line: #dce4dc;
  --leaf: #16664e;
  --light: #e8f2e8;
  --dark: #142b27;
  --amber: #ffefcf;
  --radius: 14px;
}
[hidden] { display: none !important; }
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; line-height: 1.55; }
a { color: var(--leaf); text-underline-offset: 4px; }
a:hover { color: #0e4635; }
svg { display: block; width: 20px; height: 20px; flex: none; }
main { width: min(1050px, 100% - 64px); margin: 34px auto 72px; }
main.wide { width: min(1450px, 100% - 58px); }
.app-frame { display: grid; grid-template-columns: 222px minmax(0, 1fr); }
.workspace-shell { min-width: 0; }
.skip-link { position: absolute; z-index: 10; top: -100px; left: 12px; padding: 8px 12px; background: #fff; }
.skip-link:focus { top: 10px; }
.sidebar { position: sticky; top: 0; height: 100vh; height: 100dvh; display: flex; flex-direction: column; padding: 25px 15px 18px; background: var(--dark); color: #eef6ee; overflow: auto; }
.brand { display: flex; align-items: center; gap: 11px; color: inherit; font-weight: 760; text-decoration: none; line-height: 1.2; white-space: nowrap; }
.sidebar .brand { margin: 0 6px 33px; }
.sidebar .brand:hover { color: #fff; }
.brand-mark { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; color: #153c31; background: #c6e2bc; }
.brand small { display: block; font-size: 9px; margin-top: 5px; letter-spacing: .15em; color: #b1c9bd; }
.tools-nav { display: grid; gap: 5px; }
.nav-caption { margin: 0 10px 5px; font-size: 11px; color: #b3c6be; letter-spacing: .12em; }
.nav-divider { margin-top: 18px; }
.tools-nav a { display: flex; gap: 10px; align-items: center; border: 1px solid transparent; padding: 9px 11px; border-radius: 8px; color: #d8e5db; text-decoration: none; font-size: 14px; }
.tools-nav a svg { width: 18px; height: 18px; color: #a9c2b5; }
.tools-nav a:hover, .tools-nav a.selected { color: #fff; background: #28473d; }
.tools-nav a.selected { border-color: #476859; }
.tools-nav a.selected svg { color: #d2e9c8; }
.sidebar-footer { display: flex; align-items: center; gap: 8px; margin-top: auto; padding: 20px 10px 0; color: #b6c8bd; font-size: 12px; }
.status-dot { width: 8px; height: 8px; border-radius: 100%; background: #a7d297; display: inline-block; flex: none; }
.bar { min-height: 62px; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px max(16px, 3vw); background: #fff; border-bottom: 1px solid var(--line); }
.bar-context { color: var(--muted); font-size: 13px; }
.bar-context span { color: #81928a; padding: 0 8px; }
.bar-actions { display: flex; align-items: center; gap: 7px; }
.bar-actions form { margin: 0; }
.bar-actions button { min-height: 36px; padding: 6px 11px; font-size: 13px; }
.guest-brand { color: var(--ink); }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); }
.card.narrow { max-width: 630px; margin: 28px auto; padding: clamp(18px, 4vw, 30px); }
.heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 24px 0 18px; }
.eyebrow, .meta, small, .muted { color: var(--muted); }
.eyebrow { font-size: 12px; letter-spacing: .12em; font-weight: 650; text-transform: uppercase; margin: 0 0 8px; }
h1 { font-size: clamp(1.9rem, 4vw, 3rem); letter-spacing: -.04em; line-height: 1.18; margin: 0; overflow-wrap: anywhere; }
h2 { font-size: clamp(1.1rem, 3vw, 1.42rem); line-height: 1.3; }
.meta { font-size: 12px; margin: 0 0 6px; }
.badge, .table-tag { display: inline-block; padding: 3px 9px; border-radius: 7px; background: var(--light); color: #245b46; font-size: 12px; white-space: nowrap; }
.warn, .notice { background: var(--amber); color: #684a15; }
.notice { padding: 10px 13px; border: 1px solid #ecd8ac; border-radius: 9px; overflow-wrap: anywhere; }
.workspace-hero { display: flex; align-items: end; justify-content: space-between; gap: 16px; min-height: 158px; padding: clamp(21px, 4vw, 38px); background: #e3eee2; border: 1px solid #d5e3d6; border-radius: 18px; }
.workspace-hero p:last-child { margin: 10px 0 0; color: #3f6455; max-width: 45rem; }
.workspace-hero .action-link { flex: none; }
.metrics { display: grid; grid-template-columns: .8fr .8fr 1.6fr; gap: 12px; margin: 17px 0 25px; }
.metric { display: grid; align-content: start; min-height: 96px; padding: 13px 16px; }
.metric span { color: var(--muted); font-size: 12px; }
.metric strong { font-size: 27px; font-variant-numeric: tabular-nums; }
.metric-time strong { font-size: clamp(14px, 2.1vw, 21px); padding-top: 7px; overflow-wrap: anywhere; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 12px 0; }
.section-head h2 { margin: 0; }
.section-head span { color: var(--muted); font-size: 13px; }
.search { display: flex; align-items: center; gap: 9px; margin-bottom: 14px; }
.chat-filter select { max-width: 12rem; }
input, select, textarea, button { font: inherit; border-radius: 8px; padding: 9px 12px; min-height: 42px; }
input, select, textarea { width: 100%; min-width: 0; color: var(--ink); background: #fbfcf9; border: 1px solid #aebfb5; }
input[type=checkbox], input[type=radio] { width: auto; min-width: 18px; min-height: 18px; accent-color: var(--leaf); }
textarea { resize: vertical; }
button, .action-link { display: inline-flex; align-items: center; justify-content: center; border: 1px solid transparent; border-radius: 8px; background: var(--leaf); color: #fff; font-weight: 680; cursor: pointer; white-space: nowrap; }
button:hover, .action-link:hover { color: #fff; background: #104c39; }
.action-link { padding: 8px 14px; min-height: 42px; text-decoration: none; }
button.quiet { background: #fff; border-color: #cedbd1; color: #205540; }
button.quiet:hover { background: #ecf3eb; }
:focus-visible { outline: 3px solid #278662; outline-offset: 3px; }
.sidebar :focus-visible { outline-color: #d2e9c8; }
.stack { display: grid; gap: 16px; }
.stack label { display: grid; gap: 6px; font-size: 14px; font-weight: 590; }
.form-card, .compose { padding: 18px; }
.compose { display: flex; align-items: center; flex-wrap: wrap; gap: 13px; }
.filters { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.gallery-filters { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.row { display: grid; grid-template-columns: 38px minmax(0, 1fr) auto auto; align-items: center; gap: 13px; padding: 14px 17px; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.row:first-child { border-radius: var(--radius) var(--radius) 0 0; }
.row:last-child { border-bottom: 0; border-radius: 0 0 var(--radius) var(--radius); }
.row:only-child { border-radius: var(--radius); }
.row:hover { background: #f2f8f0; }
.thread-mark { display: grid; place-items: center; height: 38px; background: #e7f0e6; border-radius: 9px; color: #255b47; font-weight: 730; }
.row small { display: block; overflow-wrap: anywhere; font-size: 12px; }
.thread-name { min-width: 0; overflow-wrap: anywhere; }
.thread-meta { text-align: right; }
.row-chevron { color: #60776a; font-size: 24px; }
.empty { padding: 18px; }
.pager { display: flex; gap: 13px; margin-top: 16px; }
.pager a { display: inline-block; padding: 7px 11px; border-radius: 7px; background: #fff; border: 1px solid var(--line); text-decoration: none; }
.back { font-size: 14px; }
.chat-tools { display: flex; gap: 9px; flex-wrap: wrap; margin: 0 0 16px; font-size: 13px; }
.chat-tools a { padding: 6px 10px; background: #e8f0e7; border-radius: 7px; text-decoration: none; }
.body { white-space: pre-wrap; overflow-wrap: anywhere; margin: 6px 0; }
.preview { background: #edf4eb; padding: 13px; border-radius: 9px; margin: 16px 0; }
.preview code { overflow-wrap: anywhere; }
.asset, .mention-row { display: flex; gap: 9px; flex-wrap: wrap; }
.asset { font-size: 14px; margin: 8px 0; }
.mention-row small { display: block; }
.draft-image { display: block; max-width: 100%; max-height: 300px; margin-top: 12px; }
.search-results { display: grid; gap: 11px; margin-top: 23px; }
.search-results h2 { margin: 0; }
.search-hit { padding: 15px; overflow-wrap: anywhere; }
.search-hit mark { background: #ffebb1; color: #412600; border-radius: 3px; }
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(215px, 100%), 1fr)); gap: 14px; margin-top: 17px; }
.gallery-tile { overflow: hidden; }
.media-tile { height: 154px; background: #eaf1e8; display: grid; place-items: center; width: 100%; overflow: hidden; }
.media-tile img { width: 100%; height: 154px; object-fit: contain; }
.media-placeholder { font-size: 14px; color: var(--muted); }
.tile-content { display: grid; gap: 6px; padding: 14px; overflow-wrap: anywhere; }
.tile-content .meta { margin: 0; }
.tile-actions { display: flex; gap: 9px; flex-wrap: wrap; font-size: 13px; }
.table-note { font-size: 14px; }
.table-scroll { overflow-x: auto; }
.archive-table { width: 100%; min-width: 720px; border-collapse: collapse; text-align: left; table-layout: fixed; font-size: 14px; }
.archive-table th, .archive-table td { padding: 13px 12px; vertical-align: top; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.archive-table thead th { background: #e8f0e6; font-weight: 720; }
.archive-table tbody tr:last-child > * { border-bottom: 0; }
.archive-table tbody tr:nth-child(even) { background: #f8faf6; }
.archive-table tr.focused, .archive-table tr:target { background: #fff2cf; scroll-margin-top: 16px; }
.archive-table tr.focused > :first-child, .archive-table tr:target > :first-child { box-shadow: inset 3px 0 #1b8c67; }
.archive-table small { display: block; margin-top: 5px; }
.archive-table small:first-child { margin-top: 0; }
.archive-table .body { margin: 0; }
.archive-table .time-cell { font-variant-numeric: tabular-nums; }
.messages-table .time-column { width: 132px; }
.messages-table .nickname-column { width: 14%; }
.messages-table .identity-column { width: 17%; }
.coverage-summary { padding: 12px 16px; margin-bottom: 16px; }
.coverage-summary p { margin: 4px 0; }
.coverage-table th:nth-child(2) { width: 20%; }
.coverage-table th:nth-child(3) { width: 19%; }
.coverage-table th:nth-child(4) { width: 15%; }
.coverage-table th:nth-child(5) { width: 27%; }
.table-warning { color: #785014; }
.directory-results { margin-top: 14px; }
.directory-results .check-column { width: 56px; }
.directory-selection { margin-top: 14px; }
.panel-copy { max-width: 72ch; }
.export-actions { display: flex; flex-wrap: wrap; gap: 9px; }
.tool-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 17px 0; }
.tool-cards h2 { margin-top: 0; }
.code-block { overflow: auto; padding: 12px 14px; border-radius: 9px; background: #eaf0e8; color: #243e35; font-size: 13px; }
.login-main { width: min(1040px, 100% - 48px); margin-top: clamp(28px, 8vh, 90px); }
.login-layout { display: grid; grid-template-columns: 1.13fr .87fr; border-radius: 22px; overflow: hidden; border: 1px solid #d2ded4; background: #fff; }
.login-story { display: grid; min-height: 495px; gap: 20px; padding: clamp(26px, 5vw, 56px); background: #172f29; color: #f4f8ee; }
.login-story .eyebrow { color: #a9c3b4; letter-spacing: .19em; }
.login-story h2 { font-size: clamp(1.8rem, 4.7vw, 3.6rem); letter-spacing: -.05em; margin: 0; }
.login-story p:not(.eyebrow) { max-width: 32ch; color: #c6d8ca; }
.login-foot { align-self: end; display: flex; gap: 9px; align-items: center; font-size: 13px; color: #cfdfd2; }
.archive-mark { display: grid; gap: 6px; align-content: center; width: 160px; padding: 15px; border-radius: 12px; border: 1px solid #587b67; transform: rotate(-8deg); }
.archive-mark span { display: block; height: 13px; border-radius: 4px; background: #516f5d; }
.archive-mark span:first-child { background: #bedeb0; }
.archive-mark span:last-child { width: 70%; }
.login-form { align-self: center; padding: clamp(22px, 5vw, 48px); border: 0; border-radius: 0; }
.login-form .stack { margin-top: 23px; }
@media (max-width: 880px) {
  .app-frame { grid-template-columns: minmax(0, 1fr); }
  .sidebar { position: static; height: auto; padding: 12px 16px 8px; overflow: visible; }
  .sidebar .brand { margin: 0 0 9px; }
  .tools-nav { display: flex; overflow-x: auto; padding-bottom: 3px; }
  .tools-nav a { padding: 7px 8px; flex: none; font-size: 13px; white-space: nowrap; }
  .nav-caption, .sidebar-footer { display: none; }
  main, main.wide { width: calc(100% - 32px); margin-top: 25px; }
}
@media (max-width: 580px) {
  .bar { min-height: 52px; }
  .bar-context span { padding: 0 3px; }
  .workspace-hero { align-items: start; flex-direction: column; }
  .metrics { grid-template-columns: 1fr 1fr; gap: 8px; }
  .metric { min-height: 74px; }
  .metric-time { grid-column: span 2; }
  .filters, .gallery-filters, .tool-cards, .login-layout { grid-template-columns: minmax(0, 1fr); }
  .chat-filter { flex-wrap: wrap; }
  .chat-filter input { flex-basis: 100%; }
  .chat-filter select { flex: 1; max-width: none; }
  .thread-meta small { display: none; }
  .row { gap: 8px; padding-inline: 10px; }
  .archive-mark { display: none; }
  .login-story { min-height: auto; gap: 4px; }
  .login-main { width: calc(100% - 28px); }
  .login-form { padding: 24px; }
}

.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.sidebar .brand { margin-bottom: 26px; }
.tools-nav a.nav-break { margin-top: 11px; }
.workspace-hero { align-items: center; min-height: 108px; }
.login-story { display: grid; place-items: center; min-height: 370px; }
.login-story .archive-mark { width: clamp(105px, 22vw, 200px); }
.chat-heading { margin-block: 14px 15px; }
.chat-tools { align-items: center; flex-wrap: nowrap; overflow-x: auto; padding: 4px 4px 8px; margin-inline: -4px; scrollbar-width: thin; }
.tool-button, .chat-tools .tool-button { display: inline-flex; gap: 7px; flex: none; align-items: center; justify-content: center; min-height: 36px; padding: 7px 11px; border: 1px solid #d3dfd5; background: #fff; color: #22583f; border-radius: 8px; line-height: 1.2; text-decoration: none; font-size: 13px; font-weight: 650; white-space: nowrap; }
.tool-button svg { width: 16px; height: 16px; }
.tool-button:hover, .chat-tools .tool-button:hover, .chat-tools .tool-button[aria-current=page] { background: #e7f1e8; border-color: #a9c6b1; color: #194b36; }
.tool-button:disabled, .chat-tools .tool-button.unavailable { color: #687b70; background: #f6f8f4; cursor: default; opacity: .75; }
.message-card { margin-top: 4px; }
.messages-table { min-width: 570px; }
.messages-table .time-column { width: 112px; }
.messages-table .sender-column { width: clamp(152px, 19vw, 215px); }
.messages-table .actions-column { width: 57px; }
.messages-table th, .messages-table td { padding: 12px 13px; }
.messages-table thead th { background: #f0f5ef; color: #3a564a; font-size: 12px; }
.messages-table tbody tr:nth-child(even):not(.focused):not(:target) { background: #fbfcfa; }
.messages-table tbody tr:hover:not(.focused):not(:target) { background: #f1f7ef; }
.time-cell time { display: block; font-family: ui-monospace, Consolas, monospace; font-weight: 600; font-size: 13px; }
.time-cell time small { font-family: system-ui, sans-serif; font-weight: 400; font-size: 11px; margin-top: 1px; }
.sender-cell strong { font-weight: 680; overflow-wrap: anywhere; }
.sender-main { display: flex; align-items: flex-start; gap: 8px; }
.sender-mark { display: grid; place-items: center; flex: 0 0 25px; height: 25px; border-radius: 7px; background: #e8f1e7; color: #2a6148; font-size: 11px; }
.sender-detail { font-size: 12px; margin-top: 6px; color: #506d5d; }
.sender-detail summary { width: fit-content; cursor: pointer; }
.sender-detail dl { display: grid; grid-template-columns: max-content minmax(0, 1fr); column-gap: 7px; row-gap: 4px; margin: 7px 0 0; }
.sender-detail dd { margin: 0; overflow-wrap: anywhere; color: var(--ink); }
.message-cell .body { line-height: 1.62; }
.quick-link, .message-more { font-size: 13px; margin: 6px 0 0; }
.message-actions { text-align: center; }
.round-action { display: inline-grid; place-items: center; width: 33px; height: 33px; padding: 0; border: 1px solid #d4e1d7; border-radius: 50%; color: #28664d; background: #fff; }
.round-action:hover { background: #e6f1e9; border-color: #9fbfa9; }
.round-action svg { width: 17px; height: 17px; }
.chat-photo { display: grid; place-items: center; width: min(186px, 100%); aspect-ratio: 4 / 3; margin: 5px 0; border: 1px solid #dbe6dc; border-radius: 10px; overflow: hidden; background: #eaf1e8; text-decoration: none; }
.chat-photo img { display: block; width: 100%; height: 100%; object-fit: contain; min-height: 0; }
.chat-photo:hover { border-color: #8eb59c; }
.asset-chip { display: inline-flex; align-items: center; gap: 9px; max-width: 100%; padding: 3px 8px; margin: 4px 3px 0 0; border: 1px solid var(--line); border-radius: 7px; background: #fff; font-size: 12px; }
.asset-chip a { text-decoration: none; }
.asset-chip svg { width: 15px; height: 15px; }
.media-notice { margin-top: 5px; }
.photo-stage { display: grid; place-items: center; margin: 5px 0 0; padding: 12px; border: 1px solid var(--line); border-radius: var(--radius); background: #e8ece7; min-height: 170px; }
.photo-stage img { display: block; max-width: 100%; max-height: 78vh; height: auto; object-fit: contain; }
.photo-stage.photo-original { display: block; max-height: 80vh; overflow: auto; }
.photo-stage.photo-original img { max-width: none; max-height: none; margin-inline: auto; }
.setup-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 7px; }
.mention-row:empty { display: none; }
.mention-row { margin-bottom: 8px; }
.mention-chip { display: inline-flex; align-items: center; gap: 6px; padding: 2px 5px 2px 9px; border-radius: 7px; background: #e8f2e8; font-size: 13px; color: #245b46; }
.mention-chip button { padding: 0; min-height: 24px; min-width: 24px; background: none; color: inherit; }
.mention-chip button:hover { background: #cfe5d3; }
.mention-panel { display: grid; gap: 8px; margin-top: 9px; padding: 10px; border: 1px solid #dce4dc; border-radius: 10px; background: #f7faf6; }
.mention-search { display: flex; gap: 6px; }
.mention-search input { min-height: 36px; padding-block: 6px; }
.mention-panel .meta:empty { display: none; }
.mention-results { max-height: 225px; overflow: auto; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(180px, 100%), 1fr)); gap: 5px; }
.mention-option { display: grid; align-content: start; justify-content: start; min-width: 0; padding: 5px 9px; min-height: 39px; color: var(--ink); border-color: #dce4dc; background: #fff; text-align: left; white-space: normal; overflow-wrap: anywhere; }
.mention-option[aria-pressed=true], .mention-option:hover { background: #e2f1e4; border-color: #94bfa0; color: var(--ink); }
.mention-option small { font-size: 11px; font-weight: 400; }
@media (max-width: 880px) { .tools-nav a.nav-break { margin-top: 0; } }
@media (max-width: 580px) {
  .messages-table .time-column { width: 95px; }
  .messages-table .sender-column { width: 143px; }
  .messages-table th, .messages-table td { padding: 9px; }
  .workspace-hero { align-items: start; }
  .login-story { display: none; }
}
