:root {
  --ink: #142638;
  --muted: #626b77;
  --accent: #10756d;
  --line: #d9dee5;
  --surface: #f5f7fa;
  --selected: #e0f0ed;
  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  color: var(--ink);
  background: #fff;
  font-size: 15px;
  line-height: 1.55;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
}
[hidden] {
  display: none !important;
}
button,
input,
textarea {
  font: inherit;
}
button {
  cursor: pointer;
}
button:disabled {
  cursor: wait;
  opacity: 0.55;
}
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
summary:focus-visible,
a:focus-visible {
  outline: 3px solid #6ebdb5;
  outline-offset: 3px;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font-size: 34px;
  letter-spacing: -1.1px;
  line-height: 1.2;
  margin-bottom: 10px;
  font-weight: 700;
}
h2 {
  font-size: 18px;
  line-height: 1.4;
  margin-bottom: 12px;
}
h3 {
  font-size: 16px;
}
code {
  font-size: 12px;
  overflow-wrap: anywhere;
}
svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
.skip {
  position: absolute;
  top: -60px;
  left: 12px;
  background: white;
  padding: 12px;
  z-index: 5;
}
.skip:focus {
  top: 8px;
}
.header {
  height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 30px;
  border-bottom: 1px solid var(--line);
  gap: 20px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 24px;
  white-space: nowrap;
}
.wordmark {
  font-size: 36px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -1.8px;
}
.product {
  font-size: 23px;
  font-weight: 600;
  letter-spacing: -0.5px;
  border-left: 1px solid #a9b1ba;
  padding-left: 24px;
}
.identity {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 14px;
}
.identity > span {
  border-left: 1px solid var(--line);
  padding-left: 22px;
}
.shell {
  display: grid;
  grid-template-columns: 205px minmax(0, 1fr);
  min-height: calc(100dvh - 76px);
}
.sidebar {
  background: var(--surface);
  padding: 28px 12px 24px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-right: 1px solid #eef1f4;
}
.nav-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  border: 0;
  background: none;
  color: var(--ink);
  text-align: left;
  padding: 11px 18px;
  margin-bottom: 5px;
  font-size: 16px;
  border-radius: 5px;
  position: relative;
}
.nav-item.selected {
  background: var(--selected);
  font-weight: 650;
}
.nav-item.selected:before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: var(--accent);
  border-radius: 4px;
}
.simulation {
  margin: 40px 8px 0;
  font-size: 13px;
  color: var(--muted);
}
main {
  padding: 32px 40px 48px;
  min-width: 0;
}
main > section,
main > div {
  max-width: 1100px;
  margin: 0 auto;
}
.subtitle {
  font-size: 18px;
  color: var(--muted);
  line-height: 1.5;
  margin-bottom: 24px;
}
.context {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 24px;
  color: #495362;
  font-size: 14px;
}
.context > span + span {
  border-left: 1px solid #aeb7c1;
  padding-left: 20px;
}
.composer {
  border: 1px solid #b8c2ce;
  border-radius: 8px;
  padding: 18px 20px;
}
.composer > label {
  display: block;
  font-size: 16px;
  font-weight: 650;
  margin-bottom: 12px;
}
textarea,
input[type="password"] {
  width: 100%;
  color: var(--ink);
  background: #fff;
  border: 1px solid #b8c2ce;
  border-radius: 5px;
  padding: 12px 14px;
  font-size: 15px;
}
textarea {
  min-height: 98px;
  max-height: 300px;
  resize: vertical;
  display: block;
  line-height: 1.5;
}
textarea::placeholder,
input::placeholder {
  color: #737c85;
}
.composer-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-top: 16px;
}
.checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  color: #48515d;
}
.checkbox input {
  width: 17px;
  height: 17px;
  accent-color: var(--accent);
  margin: 0;
}
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  min-height: 40px;
  padding: 8px 17px;
  border: 1px solid #b8c2ce;
  border-radius: 5px;
  background: #fff;
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  text-decoration: none;
}
.button:hover {
  background: #f4f7f8;
}
.button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  font-weight: 650;
}
.button.primary:hover {
  background: #0b625c;
}
.button.danger {
  background: #b53d3d;
  border-color: #b53d3d;
  color: #fff;
}
.suggestions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 20px;
}
.answer {
  margin-top: 30px;
}
.section-title {
  display: flex;
  align-items: center;
  gap: 16px;
  border-bottom: 1px solid #b8c2ce;
  padding-bottom: 12px;
  margin-bottom: 20px;
}
.section-title h2 {
  margin: 0;
}
.section-title > span {
  font-size: 13px;
  color: var(--muted);
}
.empty {
  padding: 22px 0;
  color: var(--muted);
}
.finding {
  border-bottom: 1px solid var(--line);
  padding: 17px 0;
}
.finding:first-child {
  padding-top: 0;
}
.finding-text {
  margin-bottom: 8px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  line-height: 1.65;
}
.finding.summary .finding-text {
  font-weight: 600;
  font-size: 20px;
  line-height: 1.45;
  letter-spacing: -0.3px;
}
.finding summary,
.trace summary {
  cursor: pointer;
  font-size: 13px;
  color: var(--accent);
  font-weight: 550;
  width: fit-content;
  padding: 5px 0;
}
.evidence {
  background: var(--surface);
  padding: 16px;
  margin: 10px 0;
  border-radius: 5px;
  font-size: 12px;
  overflow: auto;
  max-height: 330px;
}
.evidence p {
  margin-bottom: 10px;
}
.evidence table {
  border-collapse: collapse;
  width: 100%;
  min-width: 520px;
  text-align: left;
}
.evidence th,
.evidence td {
  padding: 8px 10px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.evidence th {
  font-weight: 650;
}
.evidence code {
  font-size: 11px;
}
.method {
  color: var(--muted);
  font-size: 13px;
}
.trace {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 12px 0;
  margin-top: 20px;
}
.trace summary {
  font-size: 15px;
  color: var(--ink);
  font-weight: 650;
}
.trace ol {
  padding-left: 24px;
  color: var(--muted);
  font-size: 14px;
}
.trace li {
  margin: 6px 0;
}
.status-note {
  color: var(--muted);
  margin-top: 12px;
}
.proposal-link {
  margin: 18px 0;
}
.loading {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 25px 0;
}
.loading p {
  font-size: 13px;
  color: var(--muted);
  margin: 3px 0;
}
.spinner {
  display: inline-block;
  width: 22px;
  height: 22px;
  border: 2px solid #cce2df;
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.9s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}
.error {
  background: #fff3f1;
  border-left: 3px solid #b84739;
  padding: 12px 16px;
  color: #8b3025;
  margin: 18px 0;
  overflow-wrap: anywhere;
}
.page-title {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
}
.review-note {
  font-size: 14px;
  color: var(--muted);
  margin: 5px 0 25px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}
.proposal {
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}
.proposal:first-child {
  padding-top: 0;
}
.proposal-head {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  align-items: flex-start;
}
.proposal-head h2 {
  margin: 0 0 5px;
}
.proposal-meta {
  color: var(--muted);
  font-size: 13px;
  margin-bottom: 12px;
}
.proposal-status {
  font-size: 12px;
  font-weight: 650;
  color: #54716b;
  padding: 3px 10px;
  background: #ecf4f1;
  border-radius: 4px;
  text-transform: capitalize;
}
.proposal-actions {
  display: flex;
  gap: 10px;
  margin-top: 14px;
}
.count {
  font-size: 11px;
  background: white;
  color: var(--accent);
  border-radius: 10px;
  padding: 1px 6px;
}
.connect-panel {
  max-width: 540px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 26px;
  margin-top: 35px;
}
.connect-panel p {
  font-size: 14px;
  color: var(--muted);
}
.connect-panel label {
  display: block;
  font-weight: 600;
  font-size: 14px;
  margin: 20px 0 8px;
}
.hint {
  font-size: 12px;
  color: var(--muted);
  margin: 9px 0 18px;
}
dialog {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 28px;
  max-width: 600px;
  width: calc(100% - 32px);
  color: var(--ink);
  box-shadow: 0 24px 70px #16273326;
}
dialog::backdrop {
  background: #12263866;
}
dialog p {
  font-size: 14px;
}
.decision-details {
  background: var(--surface);
  padding: 16px;
  max-height: 42vh;
  overflow: auto;
  border-radius: 5px;
}
.decision-details .digest {
  word-break: break-all;
  font-size: 11px;
  color: var(--muted);
}
.dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
}
.review-empty {
  padding: 35px 0;
}
.review-empty p {
  color: var(--muted);
}
@media (max-width: 900px) {
  .header {
    padding: 0 20px;
  }
  .product {
    font-size: 20px;
  }
  .brand {
    gap: 16px;
  }
  .product {
    padding-left: 16px;
  }
  .identity {
    gap: 12px;
  }
  .identity > span {
    padding-left: 12px;
  }
  .shell {
    grid-template-columns: 175px minmax(0, 1fr);
  }
  main {
    padding: 30px 26px;
  }
  .nav-item {
    font-size: 15px;
    padding: 10px 13px;
  }
  h1 {
    font-size: 30px;
  }
  .subtitle {
    font-size: 16px;
  }
}
@media (max-width: 760px) {
  .header {
    height: auto;
    min-height: 76px;
    flex-wrap: wrap;
    padding: 18px 20px;
    gap: 15px;
  }
  .wordmark {
    font-size: 29px;
  }
  .product {
    font-size: 18px;
  }
  .identity {
    font-size: 12px;
    width: 100%;
    gap: 12px;
  }
  .identity .button {
    margin-left: auto;
    min-height: 32px;
    font-size: 12px;
    padding: 5px 12px;
  }
  .shell {
    display: block;
    min-height: calc(100dvh - 110px);
  }
  .sidebar {
    padding: 10px 16px;
    display: flex;
    flex-direction: row;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    align-items: center;
  }
  .sidebar nav {
    display: flex;
    gap: 6px;
  }
  .nav-item {
    width: auto;
    white-space: nowrap;
    font-size: 14px;
    margin: 0;
    padding: 9px 14px;
  }
  .simulation {
    font-size: 11px;
    margin: 0 0 0 12px;
    max-width: 70px;
    text-align: right;
  }
  main {
    padding: 26px 20px 40px;
  }
  h1 {
    font-size: 28px;
    letter-spacing: -0.7px;
  }
  .subtitle {
    font-size: 15px;
    margin-bottom: 20px;
  }
  .context {
    font-size: 12px;
    gap: 12px;
    margin-bottom: 18px;
  }
  .context > span + span {
    padding-left: 12px;
  }
  .composer {
    padding: 15px;
  }
  .composer > label {
    font-size: 15px;
  }
  .composer-footer {
    flex-wrap: wrap;
  }
  .checkbox {
    font-size: 12px;
  }
  .composer-footer .button {
    margin-left: auto;
  }
  .suggestions {
    gap: 8px;
  }
  .suggestions .button {
    font-size: 12px;
    padding: 7px 10px;
    min-height: 36px;
  }
  .section-title {
    gap: 10px;
  }
  .section-title > span {
    font-size: 11px;
  }
  .finding.summary .finding-text {
    font-size: 18px;
  }
  .finding-text {
    font-size: 14px;
  }
  .page-title {
    flex-wrap: wrap;
    gap: 0;
  }
  .page-title .button {
    margin-bottom: 20px;
  }
  .connect-panel {
    padding: 20px;
    margin-top: 25px;
  }
  .proposal-head {
    flex-wrap: wrap;
  }
  .proposal-actions {
    flex-wrap: wrap;
  }
  dialog {
    padding: 22px;
  }
  .connect-screen h1 {
    font-size: 27px;
  }
}
@media (prefers-reduced-motion: reduce) {
  .spinner {
    animation: none;
  }
}
@media (min-width: 1200px) {
  .header {
    height: 92px;
    padding: 0 40px;
  }
  .brand {
    gap: 35px;
  }
  .wordmark {
    font-size: 48px;
  }
  .product {
    font-size: 29px;
    padding-left: 30px;
  }
  .identity {
    font-size: 20px;
    gap: 28px;
  }
  .identity > span {
    padding-left: 28px;
  }
  .identity .button {
    font-size: 18px;
    min-height: 46px;
  }
  .shell {
    grid-template-columns: 256px minmax(0, 1fr);
    min-height: calc(100dvh - 92px);
  }
  .sidebar {
    padding: 34px 14px 30px;
  }
  .nav-item {
    font-size: 20px;
    padding: 12px 24px;
    margin-bottom: 7px;
  }
  .simulation {
    font-size: 18px;
    margin-left: 14px;
  }
  main {
    padding: 34px 40px 48px;
  }
  main > section,
  main > div {
    max-width: none;
  }
  h1 {
    font-size: 48px;
    letter-spacing: -1.4px;
  }
  .subtitle {
    font-size: 26px;
    margin-bottom: 24px;
  }
  .context {
    font-size: 20px;
    gap: 24px;
    margin-bottom: 24px;
  }
  .context > span + span {
    padding-left: 24px;
  }
  .composer {
    padding: 18px 22px;
  }
  .composer > label {
    font-size: 22px;
    margin-bottom: 14px;
  }
  textarea {
    font-size: 20px;
    min-height: 120px;
    padding: 12px 16px;
  }
  .composer-footer {
    margin-top: 22px;
  }
  .checkbox {
    font-size: 20px;
    gap: 16px;
  }
  .checkbox input {
    width: 22px;
    height: 22px;
  }
  .button {
    font-size: 20px;
    min-height: 50px;
    padding: 9px 24px;
  }
  .composer-footer .button {
    min-width: 200px;
  }
  .suggestions {
    margin-top: 26px;
    gap: 16px;
  }
  .answer {
    margin-top: 34px;
  }
  .section-title {
    gap: 18px;
    padding-bottom: 14px;
    margin-bottom: 22px;
  }
  .section-title h2 {
    font-size: 24px;
  }
  .section-title > span {
    font-size: 18px;
  }
  .finding-text {
    font-size: 19px;
  }
  .finding.summary .finding-text {
    font-size: 24px;
  }
  .finding summary {
    font-size: 17px;
  }
  .trace summary {
    font-size: 20px;
  }
  .proposal-head h2 {
    font-size: 22px;
  }
}
