:root {
  color-scheme: light;
  --ink: #182927;
  --muted: #526561;
  --accent: #0b6b58;
  --accent-dark: #084b41;
  --pale: #e7f3ec;
  --line: #dce6df;
  --page: #f6f8f5;
  --white: #fff;
  --blue: #1f4e79;
  --amber: #8a5011;
  --font: "Segoe UI", "Microsoft YaHei UI", "PingFang SC", sans-serif;
}
* { box-sizing: border-box; }
html, body { min-width: 300px; margin: 0; }
body { font-family: var(--font); background: var(--page); color: var(--ink); }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }
button:disabled { cursor: default; opacity: .54; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 2px solid #168671; outline-offset: 2px;
}
a { color: var(--accent); }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(1.65rem, 3.7vw, 2.35rem); line-height: 1.23; letter-spacing: -.045em; }
h2 { font-size: 1.06rem; }
h3 { font-size: .95rem; }
[hidden] { display: none !important; }
.shell { display: grid; grid-template-columns: 226px minmax(0, 1fr); min-height: 100dvh; }
.sidebar {
  background: #102e2a; color: #ecf7f2; padding: 26px 17px 18px; display: flex;
  flex-direction: column; position: sticky; top: 0; height: 100dvh; overflow: auto;
}
.brand { display: flex; align-items: center; gap: 11px; margin: 0 5px 47px; text-decoration: none; color: inherit; }
.brand-mark { background: #9ee1be; color: #113a2e; width: 43px; height: 43px; border-radius: 13px; display: grid; place-items: center; font-size: 27px; font-weight: 750; }
.brand strong { display: block; font-size: 1.18rem; letter-spacing: .07em; }
.brand small { display: block; color: #a3c5b9; margin-top: 3px; font-size: .61rem; letter-spacing: .1em; font-weight: 650; }
.nav-group { display: grid; gap: 6px; }
.nav-item, .project-nav button {
  width: 100%; display: flex; align-items: center; gap: 11px; text-align: left;
  color: #d8ebe3; background: transparent; border: 0; border-radius: 9px; padding: 11px 10px; font-size: .9rem;
}
.nav-item span { font-size: 1rem; display: inline-block; width: 20px; text-align: center; color: #a2d6c4; }
.nav-item:hover, .nav-item.selected, .project-nav button:hover, .project-nav button.selected { background: #235047; color: #fff; }
.sidebar-divider { height: 1px; margin: 26px 5px 19px; background: #35514a; flex: 0 0 auto; }
.sidebar-label { color: #b7cdc4; display: flex; align-items: center; justify-content: space-between; padding-left: 8px; font-size: .78rem; }
.project-nav { margin-top: 4px; }
.project-nav button { padding: 9px 8px; font-size: .81rem; overflow-wrap: anywhere; }
.project-nav button::before { content: ''; flex: 0 0 7px; height: 7px; border: 1px solid #9ee1be; border-radius: 2px; }
.sidebar-footer { display: flex; align-items: center; gap: 9px; margin-top: auto; padding: 21px 3px 0; }
.sidebar-footer div { flex: 1; overflow: hidden; }
.sidebar-footer strong, .sidebar-footer small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar-footer strong { font-size: .83rem; }
.sidebar-footer small { color: #b2cdc1; font-size: .69rem; margin-top: 3px; }
.avatar { display: grid; place-content: center; border-radius: 50%; width: 35px; min-width: 35px; height: 35px; background: #b9dbc4; color: #133a33; font-size: .92rem; font-weight: 750; }
.icon-button { border: 0; padding: 3px 7px; min-width: 29px; min-height: 29px; border-radius: 6px; color: inherit; background: transparent; font-size: 1.1rem; line-height: 1; }
.icon-button:hover { background: #839d8d30; }
.main { min-width: 0; }
.topbar { height: 66px; background: #fbfdfa; border-bottom: 1px solid var(--line); padding: 0 33px; display: flex; justify-content: space-between; align-items: center; gap: 15px; }
.breadcrumb { display: flex; gap: 10px; align-items: center; color: var(--muted); font-size: .86rem; }
.breadcrumb strong { color: var(--ink); white-space: nowrap; }
.top-actions, .hero-actions, .inline-actions, .composer-actions { display: flex; gap: 10px; align-items: center; }
.connection {
  border: 1px solid var(--line); background: var(--white); color: #32564b; padding: 8px 10px;
  border-radius: 20px; white-space: nowrap; font-size: .75rem;
}
.dot { width: 7px; height: 7px; display: inline-block; border-radius: 50%; background: #49977c; margin-right: 4px; }
.dot.amber { background: #c07927; }
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  border: 1px solid transparent; border-radius: 8px; background: #edf3ed; color: var(--ink);
  font-weight: 650; padding: 9px 14px; white-space: nowrap; text-decoration: none; font-size: .86rem;
}
.button:hover:enabled { filter: brightness(.94); }
.button.primary { background: var(--accent); color: white; }
.button.outline { background: var(--white); border-color: #cddcd3; }
.button.small { padding: 7px 11px; font-size: .78rem; }
.quiet { border: 0; border-radius: 5px; background: transparent; color: var(--accent); padding: 5px; font-size: .8rem; }
.quiet:hover { background: #ecf5ec; }
.content { width: min(1320px, 100%); margin: 0 auto; padding: 28px 33px 40px; }
.hero {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(175px, 38%);
  min-height: 208px; border-radius: 16px; overflow: hidden; color: var(--ink);
  border: 1px solid #cdddce; background: linear-gradient(112deg, #edf7e7 2%, #dcefe5 63%, #cfebdf);
}
.hero-content { padding: 29px 31px 32px; }
.hero-content p { margin-top: 12px; max-width: 32rem; color: #3a5950; font-size: .91rem; line-height: 1.65; }
.hero-actions { margin-top: 21px; flex-wrap: wrap; }
.hero-diagram {
  position: relative; overflow: hidden;
  background: radial-gradient(circle, #427e6544 1px, transparent 1.2px) 0 0 / 17px 17px;
  mask-image: linear-gradient(90deg, transparent, black 16%);
}
.diagram-node { color: #2b6658; background: #fff8; border: 1px solid #8db4a5; border-radius: 12px; width: 47px; height: 47px; display: grid; place-content: center; position: absolute; font: 25px Georgia, serif; z-index: 1; box-shadow: 0 5px 15px #30685317; }
.node-root { top: 42%; left: 11%; color: #e8fbf2; background: #2e6a59; }
.node-one { top: 14%; left: 48%; }
.node-two { top: 64%; left: 51%; }
.node-three { top: 29%; left: 77%; color: #496b3f; background: #f1f9e8; }
.diagram-line { height: 1px; display: block; background: #6eae95; position: absolute; transform-origin: left center; }
.diagram-one { top: 51%; left: 23%; width: 35%; transform: rotate(-28deg); }
.diagram-two { top: 54%; left: 23%; width: 34%; transform: rotate(26deg); }
.diagram-three { top: 25%; left: 55%; width: 26%; transform: rotate(17deg); }
.metrics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 17px 0; }
.metric { background: #fff; border: 1px solid var(--line); border-radius: 11px; padding: 14px 17px; }
.metric span { display: block; font-size: .83rem; color: var(--muted); }
.metric strong { display: block; font-size: 1.63rem; line-height: 1; margin-top: 9px; }
.overview-grid, .settings-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 17px; }
.panel { background: var(--white); border: 1px solid var(--line); border-radius: 12px; min-width: 0; }
.panel-head { min-height: 56px; display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 13px 17px; border-bottom: 1px solid var(--line); }
.list { padding: 2px 16px 6px; }
.list-item { display: flex; text-align: left; align-items: center; gap: 10px; justify-content: space-between; background: transparent; width: 100%; min-width: 0; color: var(--ink); border: 0; padding: 13px 2px; }
.list-item + .list-item { border-top: 1px solid #edf1ee; }
button.list-item:hover { color: var(--accent); }
.list-item strong { display: block; font-size: .9rem; overflow-wrap: anywhere; }
.list-item small { display: block; margin-top: 4px; font-size: .76rem; color: var(--muted); line-height: 1.42; overflow-wrap: anywhere; }
.badge { background: #ebf3ed; color: #306653; padding: 4px 8px; border-radius: 6px; font-size: .72rem; white-space: nowrap; }
.badge.idle { background: #f6f1e9; color: var(--amber); }
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 6px 0 22px; }
.page-head p { margin-top: 7px; }
.muted { color: var(--muted); font-size: .86rem; line-height: 1.58; }
.empty-state { padding: 31px 24px; display: grid; gap: 18px; justify-items: start; color: var(--muted); }
.empty-note { padding: 20px 16px; color: var(--muted); font-size: .87rem; line-height: 1.65; }
.project-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr); gap: 15px; }
.conversation-panel { display: flex; flex-direction: column; min-height: 525px; }
.messages { flex: 1; max-height: 490px; overflow: auto; padding: 12px 15px; }
.message { padding: 10px 13px; margin: 8px 0; border-radius: 8px; background: #edf4ed; }
.message.assistant { background: #eaf1f7; }
.message strong { display: block; font-size: .74rem; margin-bottom: 6px; color: var(--accent-dark); }
.message p { white-space: pre-wrap; overflow-wrap: anywhere; font-size: .89rem; line-height: 1.55; }
.composer { padding: 12px 15px; border-top: 1px solid var(--line); }
input, select, textarea {
  color: var(--ink); border-radius: 7px; border: 1px solid #c6d7cb; background: #fcfefa; padding: 8px 9px;
  font-size: .87rem; max-width: 100%; min-width: 0;
}
textarea { width: 100%; resize: vertical; line-height: 1.45; }
.composer-actions { justify-content: flex-end; margin-top: 6px; }
.resource-tabs { display: flex; gap: 10px; padding: 4px 12px; border-bottom: 1px solid var(--line); overflow: auto; }
.resource-tabs button { border: 0; border-bottom: 2px solid transparent; background: transparent; color: var(--muted); font-size: .85rem; padding: 8px 4px; white-space: nowrap; }
.resource-tabs button.active { border-bottom-color: var(--accent); color: var(--accent-dark); font-weight: 650; }
.resource-body { padding: 12px 15px; }
.file-editor { display: grid; gap: 9px; margin-top: 11px; border-top: 1px solid var(--line); padding-top: 10px; }
.file-editor strong { font: .81rem Consolas, monospace; overflow-wrap: anywhere; }
.file-editor textarea { min-height: 170px; font-family: Consolas, "Courier New", monospace; }
.native-features { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-bottom: 17px; }
.native-features .panel { padding: 15px; }
.native-features h2 { margin-bottom: 7px; }
.feature-status { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.feature-preview { border-top: 1px solid var(--line); margin-top: 13px; padding-top: 10px; }
.feature-preview summary { color: var(--accent); cursor: pointer; font-size: .84rem; }
.task-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 17px; }
.task-row + .task-row { border-top: 1px solid var(--line); }
.task-row strong { display: block; overflow-wrap: anywhere; }
.task-row p { margin-top: 3px; overflow-wrap: anywhere; }
.settings-form { display: grid; padding: 18px; gap: 10px; max-width: 36rem; }
.settings-form label { font-size: .86rem; font-weight: 650; }
.small-text { font-size: .76rem; }
.pending-panel { margin-top: 16px; }
dialog { max-width: calc(100% - 28px); width: 420px; padding: 23px; color: var(--ink); border: 1px solid var(--line); border-radius: 15px; box-shadow: 0 23px 70px #193a3340; }
dialog::backdrop { background: #132e2b66; }
.dialog-head, .dialog-actions { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.dialog-head h2 { font-size: 1.22rem; }
#dialog-description { margin-top: 6px; }
#dialog-fields { display: grid; gap: 10px; padding: 15px 0; }
#dialog-fields label { display: grid; gap: 5px; font-size: .86rem; }
.dialog-actions { justify-content: flex-end; }
.error { font-size: .83rem; color: #9d2d21; line-height: 1.45; margin-bottom: 8px; }
.toast { position: fixed; right: 18px; bottom: 18px; z-index: 4; max-width: min(370px, calc(100% - 36px)); background: #133c34; color: white; padding: 11px 14px; border-radius: 9px; font-size: .86rem; box-shadow: 0 5px 21px #152d2a38; overflow-wrap: anywhere; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
@media (max-width: 870px) {
  .shell { grid-template-columns: 176px minmax(0, 1fr); }
  .sidebar { padding-left: 11px; padding-right: 11px; }
  .content, .topbar { padding-left: 19px; padding-right: 19px; }
  .project-grid, .overview-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 620px) {
  .shell { display: block; }
  .sidebar { position: static; display: block; height: auto; padding: 10px 10px 9px; }
  .brand { margin: 0 3px 9px; }
  .brand-mark { width: 33px; height: 33px; border-radius: 8px; font-size: 20px; }
  .brand strong { font-size: .94rem; }
  .brand small { font-size: .53rem; }
  .nav-group { display: flex; overflow: auto; gap: 3px; }
  .nav-item { width: auto; gap: 3px; padding: 7px; white-space: nowrap; font-size: .75rem; }
  .nav-item span { width: 14px; font-size: .77rem; }
  .sidebar-divider, .sidebar-label, .project-nav, .sidebar-footer { display: none; }
  .topbar { height: 49px; padding: 0 11px; }
  .breadcrumb { gap: 5px; font-size: .72rem; }
  .top-actions { gap: 4px; }
  .connection { padding: 5px 6px; font-size: .68rem; }
  .content { padding: 12px 11px 25px; }
  .hero { display: block; min-height: 0; }
  .hero-content { padding: 20px 15px; }
  .hero-diagram { display: none; }
  .hero-actions { margin-top: 14px; }
  .metrics { gap: 6px; margin: 10px 0; }
  .metric { padding: 9px 7px; }
  .metric span { font-size: .72rem; }
  .metric strong { font-size: 1.18rem; }
  .settings-grid, .native-features { grid-template-columns: minmax(0, 1fr); }
  .page-head { flex-wrap: wrap; }
}
.proof-form { display: grid; gap: 12px; margin-block: 14px; }
.proof-form label { display: grid; gap: 5px; }
.proof-form label.proof-consent { display: flex; align-items: start; gap: 8px; }
.proof-form .button { justify-self: start; }
.proof-result { overflow: auto; white-space: pre-wrap; overflow-wrap: anywhere; }
