:root {
  --ink: #152d34;
  --muted: #60767b;
  --paper: #f4f1e8;
  --surface: #fffdf7;
  --line: #d9d8cf;
  --teal: #087f78;
  --teal-dark: #075b58;
  --amber: #d79232;
  --coral: #c96148;
  --blue: #3d6c8f;
  --shadow: 0 18px 50px rgba(31, 57, 61, 0.09);
  font-family:
    Inter, "PingFang SC", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-synthesis: none;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(rgba(21, 45, 52, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(21, 45, 52, 0.035) 1px, transparent 1px),
    var(--paper);
  background-size: 34px 34px;
}

button,
textarea,
select {
  font: inherit;
}

button {
  color: inherit;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  padding: 0 5vw;
  color: #f7f3e9;
  background: rgba(21, 45, 52, 0.96);
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: inherit;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  color: var(--ink);
  font-family: Georgia, "Songti SC", serif;
  font-size: 21px;
  background: #c8e2d8;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  letter-spacing: 0.12em;
}

.brand small {
  margin-top: 2px;
  color: #a9c2bf;
  font-size: 10px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.topbar-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #c8d7d5;
  font-size: 13px;
}

.status-dot {
  width: 7px;
  height: 7px;
  background: #64d4a3;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(100, 212, 163, 0.12);
}

.status-dot.error {
  background: #ef8b72;
  box-shadow: 0 0 0 4px rgba(239, 139, 114, 0.14);
}

.challenge-id {
  margin-left: 10px;
  padding-left: 20px;
  border-left: 1px solid rgba(255, 255, 255, 0.18);
  font-family: "SFMono-Regular", Consolas, monospace;
}

main {
  width: min(1460px, 94vw);
  margin: 0 auto;
}

.hero {
  position: relative;
  padding: 80px 2vw 64px;
  overflow: hidden;
}

.hero::after {
  position: absolute;
  top: 55px;
  right: 5vw;
  width: 290px;
  height: 290px;
  content: "";
  border: 1px solid rgba(8, 127, 120, 0.24);
  border-radius: 50%;
  box-shadow:
    0 0 0 46px rgba(8, 127, 120, 0.045),
    0 0 0 92px rgba(8, 127, 120, 0.025);
}

.eyebrow,
.section-label {
  color: var(--teal-dark);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero h1 {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 20px 0;
  font-family: Georgia, "Songti SC", "STSong", serif;
  font-size: clamp(44px, 6vw, 84px);
  font-weight: 600;
  line-height: 1.04;
  letter-spacing: -0.045em;
}

.hero > p {
  position: relative;
  z-index: 1;
  max-width: 720px;
  margin: 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.9;
}

.hero-proof {
  display: flex;
  flex-wrap: wrap;
  gap: 26px;
  margin-top: 30px;
  color: var(--muted);
  font-size: 13px;
}

.hero-proof b {
  margin-right: 5px;
  color: var(--ink);
  font-family: Georgia, serif;
  font-size: 23px;
}

.workbench {
  display: grid;
  grid-template-columns: 330px minmax(0, 1fr);
  min-height: 750px;
  margin-bottom: 70px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

.control-panel {
  padding: 30px 24px;
  background: #eef0e9;
  border-right: 1px solid var(--line);
}

.domain-label,
.query-label {
  display: block;
  margin-top: 15px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.domain-select {
  width: 100%;
  margin-top: 8px;
  padding: 12px 38px 12px 12px;
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  font-weight: 750;
  background: var(--surface);
  border: 1px solid #c8d1cb;
}

.domain-select:focus {
  border-color: var(--teal);
  outline: 2px solid rgba(8, 127, 120, 0.16);
}

.domain-description {
  min-height: 44px;
  margin: 9px 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.6;
}

.domain-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 28px;
}

.domain-stats span {
  padding: 4px 6px;
  color: var(--teal-dark);
  font-size: 9px;
  font-weight: 800;
  background: #dcebe5;
}

.learner-section-label {
  padding-top: 23px;
  border-top: 1px solid #d8ddd8;
}

.profile-list {
  display: grid;
  gap: 10px;
  margin: 18px 0 30px;
}

.profile-card {
  width: 100%;
  padding: 15px;
  text-align: left;
  background: transparent;
  border: 1px solid #cfd5cf;
  cursor: pointer;
  transition:
    border-color 160ms ease,
    background 160ms ease,
    transform 160ms ease;
}

.profile-card:hover {
  transform: translateY(-1px);
  border-color: var(--teal);
}

.profile-card.active {
  color: #f9f7ef;
  background: var(--ink);
  border-color: var(--ink);
}

.profile-card strong,
.profile-card span,
.profile-card small {
  display: block;
}

.profile-card strong {
  font-size: 15px;
}

.profile-card span {
  margin-top: 5px;
  color: var(--muted);
  font-size: 12px;
}

.profile-card.active span,
.profile-card.active small {
  color: #bcd0ce;
}

.profile-card small {
  margin-top: 10px;
  color: #7d8d90;
  line-height: 1.55;
}

.query-label {
  display: block;
  margin-bottom: 9px;
  font-size: 13px;
  font-weight: 750;
}

textarea {
  width: 100%;
  padding: 13px;
  resize: vertical;
  color: var(--ink);
  line-height: 1.65;
  background: var(--surface);
  border: 1px solid #c8d0cb;
  outline: none;
}

select {
  width: 100%;
  padding: 11px 12px;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid #c8d0cb;
}

input {
  width: 100%;
  padding: 11px 12px;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid #c8d0cb;
  outline: none;
}

.preset-label {
  margin-top: 16px;
}

.preset-description {
  min-height: 34px;
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(8, 127, 120, 0.1);
}

.provider-controls {
  margin-top: 22px;
  padding-top: 20px;
  border-top: 1px solid #ccd4ce;
}

.provider-controls .query-label {
  margin-top: 13px;
}

.secret-input-row {
  display: grid;
  grid-template-columns: 1fr auto;
}

.secret-input-row button {
  padding: 0 12px;
  color: var(--teal-dark);
  background: #e4eee9;
  border: 1px solid #c8d0cb;
  border-left: 0;
  cursor: pointer;
}

.secondary-button {
  width: 100%;
  margin-top: 11px;
  padding: 10px 12px;
  color: var(--teal-dark);
  font-weight: 750;
  background: transparent;
  border: 1px solid var(--teal);
  cursor: pointer;
}

.secondary-button:disabled {
  cursor: wait;
  opacity: 0.6;
}

.provider-test-status {
  min-height: 18px;
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.5;
}

.provider-test-status.success {
  color: #08705f;
}

.provider-test-status.error {
  color: #a54737;
}

.primary-button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin-top: 14px;
  padding: 15px 16px;
  color: white;
  font-weight: 800;
  background: var(--teal);
  border: 0;
  cursor: pointer;
  transition: background 160ms ease;
}

.primary-button:hover {
  background: var(--teal-dark);
}

.primary-button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.privacy-note {
  display: flex;
  gap: 8px;
  margin-top: 16px;
  color: #758487;
  font-size: 11px;
  line-height: 1.6;
}

.runtime-error {
  margin: 10px 0 0;
  padding: 10px 12px;
  color: #8b382d;
  font-size: 11px;
  line-height: 1.55;
  background: #f8e4de;
  border-left: 3px solid var(--coral);
}

.results-panel {
  min-width: 0;
  padding: 32px;
}

.empty-state {
  display: grid;
  min-height: 650px;
  place-content: center;
  text-align: center;
}

.empty-state h2 {
  margin: 32px 0 8px;
  font-family: Georgia, "Songti SC", serif;
  font-size: 26px;
}

.empty-state p {
  max-width: 460px;
  margin: 0;
  color: var(--muted);
  line-height: 1.8;
}

.empty-visual {
  position: relative;
  width: 150px;
  height: 150px;
  margin: 0 auto;
}

.orbit,
.orbit-core {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.orbit {
  border: 1px solid #9abdb7;
  border-radius: 50%;
}

.orbit-a {
  width: 140px;
  height: 70px;
  transform: translate(-50%, -50%) rotate(24deg);
}

.orbit-b {
  width: 70px;
  height: 140px;
  transform: translate(-50%, -50%) rotate(24deg);
}

.orbit-core {
  display: grid;
  width: 54px;
  height: 54px;
  place-items: center;
  color: white;
  font-size: 12px;
  font-weight: 800;
  background: var(--teal);
  border-radius: 50%;
}

.result-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 22px;
}

.result-content > * {
  min-width: 0;
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr) 1.2fr;
  background: var(--ink);
}

.metric-strip article {
  min-width: 0;
  min-height: 120px;
  padding: 22px;
  color: #edf3ef;
  border-right: 1px solid rgba(255, 255, 255, 0.12);
}

.metric-strip article:last-child {
  border-right: 0;
}

.metric-strip span,
.metric-strip small {
  display: block;
  color: #a9bfbd;
  font-size: 11px;
}

.metric-strip strong {
  display: block;
  margin: 8px 0 4px;
  color: #f4d89a;
  font-family: Georgia, serif;
  font-size: 31px;
}

.metric-strip .metric-note {
  background: #21464c;
}

.metric-note p {
  margin: 10px 0 0;
  font-family: Georgia, "Songti SC", serif;
  font-size: 16px;
  line-height: 1.6;
}

.panel-block {
  padding: 26px;
  background: #fffefa;
  border: 1px solid var(--line);
}

.block-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
}

.block-heading.compact {
  align-items: flex-start;
}

.block-heading h2 {
  margin: 7px 0 0;
  font-family: Georgia, "Songti SC", serif;
  font-size: 22px;
  font-weight: 600;
}

.quiet-badge {
  padding: 6px 9px;
  color: var(--teal-dark);
  font-size: 11px;
  background: #e5f1ed;
}

.provider-run-block {
  border-left: 4px solid var(--teal);
}

.provider-run-block .offline-badge {
  color: #8a5b1e;
  background: #f7ead3;
}

.provider-run-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.provider-run-meta span {
  padding: 6px 8px;
  color: #486266;
  font-family: Consolas, monospace;
  font-size: 10px;
  background: #edf2ee;
}

.provider-warnings {
  margin-top: 14px;
  padding: 10px 12px;
  color: #91611d;
  font-size: 11px;
  line-height: 1.6;
  background: #f7ead3;
}

.live-answer-card {
  margin-top: 18px;
  padding: 18px;
  background: #f4f5ef;
  border: 1px solid #d8ddd5;
}

.live-answer-card span {
  color: var(--teal-dark);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.live-answer-card p {
  margin: 9px 0 0;
  color: #385055;
  line-height: 1.8;
  white-space: pre-wrap;
}

.agent-trace {
  display: grid;
  grid-template-columns: repeat(3, minmax(180px, 1fr));
  gap: 18px;
  overflow-x: auto;
}

.specialist-agent-trace {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 22px;
}

.specialist-card {
  display: grid;
  grid-template-columns: minmax(150px, 0.7fr) 1fr auto;
  align-items: center;
  gap: 18px;
  padding: 15px;
  background: #edf4f1;
  border: 1px solid #cadbd5;
}

.specialist-card span,
.specialist-card strong {
  display: block;
}

.specialist-card span {
  color: var(--teal-dark);
  font-size: 10px;
  font-weight: 800;
}

.specialist-card strong {
  margin-top: 4px;
  font-size: 13px;
}

.specialist-card p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
}

.specialist-card small {
  color: var(--teal-dark);
  font-family: Consolas, monospace;
  font-size: 9px;
}

.triad-divider {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 10px;
}

.triad-divider::after {
  height: 1px;
  flex: 1;
  content: "";
  background: var(--line);
}

.triad-divider span {
  color: var(--ink);
  font-weight: 800;
}

.trace-step {
  position: relative;
  min-width: 130px;
  padding: 0 18px 0 0;
}

.trace-step:not(:last-child)::after {
  position: absolute;
  top: 13px;
  right: 7px;
  width: 18px;
  height: 1px;
  content: "";
  background: #9cb4b0;
}

.trace-index {
  display: grid;
  width: 26px;
  height: 26px;
  margin-bottom: 13px;
  place-items: center;
  color: white;
  font-size: 10px;
  font-weight: 800;
  background: var(--teal);
  border-radius: 50%;
}

.trace-step strong,
.trace-step span,
.trace-step small {
  display: block;
}

.trace-step strong {
  min-height: 38px;
  font-size: 13px;
  line-height: 1.45;
}

.trace-step span {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
}

.trace-step small {
  margin-top: 8px;
  color: #819093;
  font-family: Consolas, monospace;
}

.analysis-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(300px, 0.75fr);
  gap: 22px;
}

.legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--muted);
  font-size: 10px;
}

.legend span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.legend i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.legend-paper {
  background: var(--blue);
}

.legend-concept {
  background: var(--teal);
}

.legend-outcome {
  background: var(--amber);
}

.graph-scroll {
  overflow-x: auto;
  background: #f7f6ef;
  border: 1px solid #e6e3d8;
}

.knowledge-graph {
  display: block;
  width: 100%;
  min-width: 680px;
  min-height: 390px;
}

.retrieval-plan {
  display: grid;
  grid-template-columns: 0.75fr 0.65fr 1.4fr;
  margin-bottom: 18px;
  background: var(--ink);
}

.retrieval-plan > div {
  min-width: 0;
  min-height: 112px;
  padding: 18px;
  color: #f5f1e7;
  border-right: 1px solid rgba(255, 255, 255, 0.12);
}

.retrieval-plan > div:last-child {
  border-right: 0;
}

.retrieval-plan span {
  display: block;
  color: #a9bfbd;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.retrieval-plan strong {
  display: block;
  margin-top: 8px;
  color: #f4d89a;
  font-family: Georgia, "Songti SC", serif;
  font-size: 17px;
  overflow-wrap: anywhere;
}

.retrieval-plan p {
  margin: 8px 0 0;
  color: #c6d4d1;
  font-size: 11px;
  line-height: 1.6;
}

.graph-rag-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(260px, 0.7fr);
  gap: 18px;
}

.concept-graph-wrap {
  position: relative;
  overflow-x: auto;
  background: #f7f6ef;
  border: 1px solid #e2e0d7;
}

.concept-legend {
  position: absolute;
  z-index: 2;
  top: 12px;
  left: 14px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  color: var(--muted);
  font-size: 9px;
}

.concept-legend span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.concept-legend i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.concept-method {
  background: var(--teal);
}

.concept-task {
  background: var(--blue);
}

.concept-dataset {
  background: var(--amber);
}

.concept-seed {
  background: transparent;
  border: 2px solid var(--coral);
}

.query-concept-graph {
  min-width: 680px;
  min-height: 420px;
}

.concept-edge {
  stroke: #aebbb7;
  stroke-width: 1.4;
}

.concept-edge-label {
  fill: #758588;
  font-size: 8px;
  text-anchor: middle;
}

.concept-node circle:not(.seed-ring) {
  stroke: white;
  stroke-width: 3;
}

.concept-node .seed-ring {
  fill: none;
  stroke: var(--coral);
  stroke-width: 2;
  stroke-dasharray: 3 3;
}

.concept-node text {
  fill: var(--ink);
  font-size: 9px;
  font-weight: 750;
  text-anchor: middle;
}

.graph-rag-grid aside {
  min-width: 0;
}

.graph-rag-grid aside h3 {
  margin: 0 0 10px;
  font-size: 12px;
}

.graph-rag-grid aside h3:not(:first-child) {
  margin-top: 20px;
}

.graph-paper-recommendations {
  display: grid;
  gap: 7px;
}

.graph-paper-recommendations a {
  display: grid;
  gap: 5px;
  padding: 10px;
  color: inherit;
  background: #f4f2e9;
  border-left: 3px solid var(--teal);
  text-decoration: none;
}

.graph-paper-recommendations a:hover {
  background: #e9f2ee;
}

.graph-paper-recommendations span,
.graph-paper-recommendations small {
  color: var(--muted);
  font-size: 9px;
  line-height: 1.45;
}

.graph-paper-recommendations strong {
  font-size: 11px;
  line-height: 1.45;
}

.graph-followups {
  display: grid;
  gap: 6px;
  margin: 0;
  padding-left: 18px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

.graph-edge {
  stroke: #b7c1bd;
  stroke-width: 1.2;
}

.graph-edge.evidence {
  stroke: #a8b9c9;
  stroke-dasharray: 4 4;
}

.graph-label {
  fill: #738386;
  font-size: 9px;
  text-anchor: middle;
}

.graph-node circle {
  stroke: white;
  stroke-width: 3;
  filter: drop-shadow(0 5px 7px rgba(21, 45, 52, 0.12));
}

.graph-node text {
  fill: var(--ink);
  font-size: 10px;
  font-weight: 700;
  text-anchor: middle;
}

.report-block h3 {
  margin: 22px 0 10px;
  font-size: 12px;
}

.match-score {
  color: var(--teal);
  font-family: Georgia, serif;
  font-size: 29px;
}

.knowledge-bars {
  display: grid;
  gap: 9px;
}

.knowledge-bar {
  display: grid;
  grid-template-columns: 76px 1fr 28px;
  align-items: center;
  gap: 8px;
  font-size: 11px;
}

.bar-track {
  height: 6px;
  overflow: hidden;
  background: #e2e5df;
}

.bar-fill {
  height: 100%;
  background: var(--teal);
}

.difficulty-curve {
  display: flex;
  align-items: flex-end;
  height: 74px;
  gap: 8px;
  padding-top: 8px;
  border-bottom: 1px solid #d8ddd8;
}

.difficulty-point {
  position: relative;
  flex: 1;
  min-width: 0;
  background: rgba(8, 127, 120, 0.16);
  border-top: 2px solid var(--teal);
}

.difficulty-point span {
  position: absolute;
  right: 0;
  bottom: -20px;
  left: 0;
  overflow: hidden;
  color: var(--muted);
  font-size: 9px;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.learning-path {
  display: grid;
  gap: 7px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: path;
}

.learning-path li {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #455c61;
  font-size: 11px;
  counter-increment: path;
}

.learning-path li::before {
  display: grid;
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  place-items: center;
  content: counter(path);
  color: white;
  font-size: 9px;
  background: var(--ink);
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

th,
td {
  padding: 13px 11px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid #e4e3dc;
}

th {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.08em;
}

td {
  font-size: 12px;
  line-height: 1.55;
}

.claim-main {
  font-weight: 750;
}

.evidence-chip {
  display: inline-block;
  margin: 0 4px 4px 0;
  padding: 3px 5px;
  color: var(--blue);
  font-family: Consolas, monospace;
  font-size: 10px;
  background: #edf2f6;
}

.verdict {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 7px;
  font-size: 10px;
  font-weight: 800;
}

.verdict.accepted {
  color: #08705f;
  background: #dff2ea;
}

.verdict.review {
  color: #91611d;
  background: #f7ead3;
}

.verdict.needs_review {
  color: #91611d;
  background: #f7ead3;
}

.verdict.rejected {
  color: #a54737;
  background: #f6e1db;
}

.evidence-snippet,
.judge-reason {
  display: block;
  margin-top: 7px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.55;
}

.scope-warning {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.7;
}

.featured-row {
  background: #eef6f1;
  box-shadow: inset 3px 0 var(--teal);
}

.method-tag,
.unverified-tag {
  display: inline-block;
  margin-left: 8px;
  padding: 3px 6px;
  color: var(--teal-dark);
  font-size: 9px;
  font-weight: 800;
  background: #dceee8;
}

.insight-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  gap: 22px;
}

.literature-timeline {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.literature-timeline li {
  display: grid;
  grid-template-columns: 54px 1fr;
  gap: 14px;
  padding: 12px 0;
  border-top: 1px solid #e7e4dc;
}

.literature-timeline time {
  color: var(--teal-dark);
  font-family: Georgia, serif;
  font-size: 17px;
}

.literature-timeline a {
  color: var(--ink);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.5;
  text-decoration: none;
}

.literature-timeline a:hover {
  color: var(--teal);
}

.literature-timeline p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.6;
}

.research-ideas {
  display: grid;
  gap: 11px;
}

.idea-card {
  padding: 15px;
  background: #f7f6ef;
  border: 1px solid #e3e0d5;
}

.idea-card .unverified-tag {
  margin-left: 0;
  color: #8a5b17;
  background: #f4e5c8;
}

.idea-card h3 {
  margin: 9px 0 6px;
  font-size: 14px;
}

.idea-card p,
.idea-card details {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.65;
}

.idea-card details {
  margin-top: 9px;
}

.idea-card ul {
  margin-bottom: 0;
  padding-left: 20px;
}

.secondary-button {
  padding: 10px 13px;
  color: var(--teal-dark);
  font-weight: 800;
  background: #e2f0eb;
  border: 1px solid #b9d5cd;
  cursor: pointer;
}

.secondary-button:hover {
  color: white;
  background: var(--teal);
  border-color: var(--teal);
}

.secondary-button:disabled {
  cursor: wait;
  opacity: 0.6;
}

.rag-results {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 10px;
  margin-top: 15px;
}

.rag-result {
  display: grid;
  gap: 7px;
  padding: 13px;
  color: inherit;
  background: #f7f6ef;
  border: 1px solid #e1dfd5;
  text-decoration: none;
}

.rag-result:hover {
  border-color: var(--teal);
}

.rag-result span,
.rag-result small {
  color: var(--muted);
  font-size: 9px;
}

.rag-result strong {
  font-size: 12px;
  line-height: 1.5;
}

.resource-tabs {
  display: flex;
  border-bottom: 1px solid var(--line);
}

.tab-button {
  padding: 9px 13px;
  color: var(--muted);
  background: transparent;
  border: 0;
  border-bottom: 2px solid transparent;
  cursor: pointer;
}

.tab-button.active {
  color: var(--teal-dark);
  font-weight: 800;
  border-bottom-color: var(--teal);
}

.resource-content {
  min-height: 210px;
}

.resource-title {
  margin: 0 0 6px;
  font-family: Georgia, "Songti SC", serif;
  font-size: 24px;
}

.resource-strategy {
  margin: 0 0 18px;
  color: var(--muted);
}

.brief-section,
.guide-step,
.quiz-item {
  padding: 14px 0;
  border-top: 1px solid #e7e4dc;
}

.brief-section h3,
.guide-step h3,
.quiz-item h3 {
  margin: 0 0 6px;
  font-size: 14px;
}

.brief-section p,
.guide-step p,
.quiz-item p {
  margin: 0;
  color: #52676b;
  font-size: 12px;
  line-height: 1.7;
}

.guide-step {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 12px;
}

.step-number {
  display: grid;
  width: 28px;
  height: 28px;
  place-items: center;
  color: white;
  font-size: 11px;
  background: var(--teal);
}

.quiz-options {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 7px;
  margin-top: 9px;
}

.quiz-options span {
  padding: 8px 9px;
  color: #536a6e;
  font-size: 11px;
  background: #f1f2ed;
}

.blue-ocean {
  display: grid;
  grid-template-columns: 145px 1fr;
  gap: 7px 18px;
  margin-top: 22px;
  padding: 17px;
  color: #f8f4e9;
  background: var(--ink);
}

.blue-ocean span {
  grid-row: span 2;
  color: #e1b66e;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.blue-ocean strong {
  font-family: Georgia, "Songti SC", serif;
  font-size: 15px;
}

.blue-ocean p {
  margin: 0;
  color: #b7cac7;
  font-size: 11px;
}

.feedback-panel {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 25px;
  padding: 25px 28px;
  background: #e4eee9;
  border-left: 4px solid var(--teal);
}

.ablation-table td small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 9px;
  line-height: 1.25;
}

.feedback-panel h2 {
  margin: 6px 0;
  font-family: Georgia, "Songti SC", serif;
  font-size: 21px;
}

.feedback-panel p {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
}

.feedback-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.feedback-actions button {
  padding: 10px 12px;
  background: var(--surface);
  border: 1px solid #bdcbc5;
  cursor: pointer;
}

.feedback-actions button:hover {
  color: white;
  background: var(--teal);
  border-color: var(--teal);
}

.feedback-actions button:disabled {
  cursor: wait;
  opacity: 0.6;
}

footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 5vw;
  color: #7a898b;
  font-size: 11px;
  border-top: 1px solid #d3d5ce;
}

@media (max-width: 1100px) {
  .workbench {
    grid-template-columns: 280px minmax(0, 1fr);
  }

  .results-panel {
    padding: 22px;
  }

  .agent-trace {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    overflow-x: visible;
  }

  .trace-step {
    min-width: 0;
  }

  .metric-strip {
    grid-template-columns: repeat(3, 1fr);
  }

  .metric-note {
    display: none;
  }

  .analysis-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .insight-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .graph-rag-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .specialist-card {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .innovation-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 780px) {
  .topbar-meta > span:not(.status-dot) {
    display: none;
  }

  .hero {
    padding-top: 55px;
  }

  .hero::after {
    opacity: 0.45;
  }

  .workbench {
    grid-template-columns: 1fr;
  }

  .control-panel {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .profile-list {
    grid-template-columns: 1fr;
  }

  .results-panel {
    padding: 16px;
  }

  .metric-strip {
    grid-template-columns: 1fr;
  }

  .specialist-agent-trace,
  .retrieval-plan {
    grid-template-columns: 1fr;
  }

  .retrieval-plan > div {
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  }

  .metric-strip article {
    min-height: auto;
    border-right: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  }

  .block-heading,
  .feedback-panel {
    align-items: flex-start;
    flex-direction: column;
  }

  .resource-tabs {
    width: 100%;
    overflow-x: auto;
  }

  .blue-ocean {
    grid-template-columns: 1fr;
  }

  .blue-ocean span {
    grid-row: auto;
  }

  .quiz-options {
    grid-template-columns: 1fr;
  }

  .innovation-grid,
  .innovation-detail-grid {
    grid-template-columns: 1fr;
  }

  footer {
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}

/* ── 账号登录与注册视图 ─────────────────────────────── */
.auth-view {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 48px;
  max-width: 1080px;
  margin: 0 auto;
  padding: 72px 40px;
  align-items: center;
}

.auth-showcase .auth-kicker {
  font-size: 11pt;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--accent, #057dbc);
}

.auth-showcase h1 {
  font-size: 42pt;
  line-height: 1.15;
  font-weight: 700;
  margin: 18px 0 16px;
}

.auth-showcase p {
  color: var(--muted, #666);
  max-width: 46ch;
}

.auth-proof {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 30px;
}

.auth-proof span {
  border: 2px solid currentColor;
  padding: 8px 14px;
  font-size: 9.5pt;
  font-weight: 600;
}

.auth-card {
  border: 2px solid var(--rule, #141414);
  background: var(--surface, #fff);
  padding: 30px;
  box-shadow: 8px 8px 0 rgba(0, 0, 0, 0.08);
}

.auth-card-heading {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 22px;
}

.auth-card-heading strong {
  display: block;
  font-size: 15pt;
}

.auth-card-heading small {
  color: var(--muted, #666);
}

.auth-tabs {
  display: flex;
  border: 1px solid var(--rule, #141414);
  margin-bottom: 22px;
}

.auth-tabs button {
  flex: 1;
  min-height: 42px;
  background: transparent;
  border: none;
  font-weight: 700;
  cursor: pointer;
  color: var(--ink, #141414);
}

.auth-tabs button.active {
  background: var(--ink, #141414);
  color: var(--inverted, #fff);
}

.auth-form {
  display: grid;
  gap: 14px;
}

.auth-form label {
  font-size: 9.5pt;
  font-weight: 600;
}

.auth-form input,
.auth-form select,
.auth-form textarea {
  min-height: 42px;
  padding: 0 12px;
  border: 1px solid var(--rule, #141414);
  font-size: 11pt;
  background: var(--surface, #fff);
}

.auth-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.auth-form-grid label,
.compact-form label,
.survey-form label {
  display: grid;
  gap: 7px;
}

.consent-row {
  display: grid !important;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 10px !important;
  color: var(--muted, #666);
  line-height: 1.55;
}

.consent-row input {
  width: 18px;
  min-height: 18px;
  margin: 2px 0 0;
}

.auth-hint {
  margin-top: 18px;
  font-size: 9.5pt;
  color: var(--muted, #666);
}

.account-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border: 2px solid var(--rule, #141414);
  background: var(--surface, #fff);
  padding: 12px 16px;
  margin-bottom: 20px;
}

.account-summary .account-status {
  font-size: 10pt;
  font-weight: 600;
  margin: 0;
}

.profile-editor {
  margin: 12px 0 20px;
  padding: 12px;
  border: 1px solid var(--line);
  background: #f7f6ef;
}

.profile-editor summary {
  color: var(--teal-dark);
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
}

.compact-form {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.compact-form input,
.compact-form textarea,
.survey-form input,
.survey-form textarea,
.survey-form select {
  width: 100%;
  padding: 8px;
  border: 1px solid #bdcbc5;
  background: white;
}

.progress-panel {
  margin-bottom: 22px;
  padding: 22px;
  border: 1px solid #b9d5cd;
  border-left: 4px solid var(--teal);
  background: #edf4f1;
}

.progress-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.progress-heading h2 {
  margin: 6px 0;
  font-family: Georgia, "Songti SC", serif;
  font-size: 20px;
}

.progress-heading p {
  margin: 0;
  color: var(--muted);
  font-family: Consolas, monospace;
  font-size: 11px;
}

.progress-timeline {
  display: grid;
  gap: 0;
  margin: 18px 0 0;
  padding: 0;
  list-style: none;
}

.progress-event {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  padding: 9px 0 9px 18px;
  border-left: 2px solid #9cb4b0;
}

.progress-event::before {
  position: absolute;
  width: 8px;
  height: 8px;
  margin: 4px 0 0 -23px;
  content: "";
  background: var(--teal);
  border-radius: 50%;
}

.progress-event span { font-size: 12px; }
.progress-event small { color: var(--muted); font-family: Consolas, monospace; font-size: 9px; }
.progress-event.completed { border-left-color: #2c8c68; }
.progress-event.failed,
.progress-event.cancelled { border-left-color: var(--coral); }

.survey-panel {
  display: block;
}

.survey-form {
  display: grid;
  grid-template-columns: repeat(3, minmax(130px, 1fr));
  gap: 12px;
  margin-top: 20px;
}

.survey-comment,
.survey-form .primary-button,
.survey-form > small {
  grid-column: 1 / -1;
}

@media (max-width: 820px) {
  .auth-view {
    grid-template-columns: 1fr;
    padding: 40px 20px;
    gap: 32px;
  }

  .auth-form-grid,
  .survey-form {
    grid-template-columns: 1fr;
  }
}
