:root {
  color-scheme: dark;
  --bg: #0b111b;
  --panel: #101a28;
  --line: #25344a;
  --text: #edf3fc;
  --muted: #a5b5ca;
  --cyan: #72d9e9;
  --blue: #90b7ff;
  --violet: #c3a6ff;
  --amber: #f0c783;
  --radius: 15px;
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body.mobile-detail {
  overflow: hidden;
}
body {
  margin: 0;
  background:
    radial-gradient(ellipse at 12% 0%, #142339 0, transparent 50%), var(--bg);
  color: var(--text);
  font:
    15px/1.55 -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
}
button,
a,
input {
  font: inherit;
}
button {
  color: inherit;
  cursor: pointer;
}
a {
  color: var(--cyan);
  text-underline-offset: 3px;
}
button:focus-visible,
a:focus-visible,
summary:focus-visible {
  outline: 2px solid var(--cyan);
  outline-offset: 4px;
}
button:disabled {
  cursor: default;
}
::selection {
  background: #2f6371;
  color: white;
}
.shell {
  max-width: 1512px;
  margin: auto;
  padding: 30px 40px 60px;
}
.masthead {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  margin-bottom: 24px;
}
.brand {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}
.brand a {
  color: var(--text);
  text-decoration: none;
}
.back {
  font-size: 13px;
  text-decoration: none;
  color: var(--muted);
}
.eyebrow {
  font-size: 11px;
  font-weight: 650;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cyan);
}
h1 {
  font-size: clamp(28px, 3vw, 42px);
  line-height: 1.15;
  letter-spacing: -0.035em;
  margin: 10px 0 12px;
  font-weight: 650;
}
h2,
h3,
p {
  margin: 0;
}
.intro {
  max-width: 830px;
  color: var(--muted);
  font-size: 15px;
}
.headnote {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin: 19px 0 27px;
}
.pill {
  font-size: 11px;
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 5px 10px;
  color: var(--muted);
  background: #101a2680;
}
.pill strong {
  color: var(--text);
  font-weight: 600;
}
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 22px;
}
.tab {
  background: #101a28;
  border: 1px solid var(--line);
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 12px;
  line-height: 1.4;
  text-align: left;
  transition: 0.15s;
}
.tab:hover {
  border-color: #587183;
}
.tab[aria-selected="true"] {
  background: #183343;
  border-color: var(--cyan);
  color: #c0f6ff;
}
.topic-summary {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(280px, 1fr);
  gap: 22px;
  padding: 22px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(115deg, #142132, #101923);
  margin-bottom: 19px;
}
.topic-title {
  font-size: 25px;
  line-height: 1.25;
  letter-spacing: -0.025em;
  margin: 8px 0 9px;
}
.subtitle {
  color: var(--muted);
  font-size: 13px;
}
.question {
  margin-top: 15px;
  font-size: 14px;
  max-width: 750px;
}
.hypothesis-summary {
  border-left: 1px solid var(--line);
  padding-left: 22px;
}
.hypothesis-summary .eyebrow {
  color: var(--amber);
}
.hypothesis-summary p {
  margin-top: 10px;
  font-size: 13px;
  color: #d7e3f3;
}
.tool-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
  margin: 20px 0 15px;
}
.guide {
  font-size: 12px;
  color: var(--muted);
  max-width: 900px;
}
.guide strong {
  color: #dce7f5;
}
.smallbtn {
  background: #132031;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 7px 11px;
  font-size: 12px;
  white-space: nowrap;
}
.smallbtn:hover {
  border-color: var(--cyan);
}
.board {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 42px;
  isolation: isolate;
}
.lane {
  min-width: 0;
  position: relative;
  z-index: 1;
}
.lane:nth-of-type(1) {
  --accent: var(--cyan);
}
.lane:nth-of-type(2) {
  --accent: var(--blue);
}
.lane:nth-of-type(3) {
  --accent: var(--violet);
}
.lane:nth-of-type(4) {
  --accent: var(--amber);
}
.lane-head {
  display: flex;
  gap: 10px;
  align-items: center;
  margin: 0 0 13px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
}
.lane-num {
  font-size: 11px;
  border: 1px solid var(--line);
  border-radius: 7px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  background: #111e2d;
  flex-shrink: 0;
}
.node {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  position: relative;
  text-align: left;
  width: 100%;
  margin-bottom: 13px;
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent);
  background: linear-gradient(120deg, #142033, #101a28);
  border-radius: 12px;
  padding: 16px 15px 13px;
  min-height: 150px;
  transition:
    opacity 0.18s,
    border-color 0.18s,
    transform 0.18s;
  box-shadow: 0 6px 18px #00000012;
}
.node:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
}
.node .title {
  font-size: 14px;
  line-height: 1.35;
  font-weight: 600;
  margin: 0 0 8px;
  display: block;
}
.node .short {
  font-size: 12px;
  line-height: 1.55;
  color: var(--muted);
  display: block;
  flex: 1;
}
.node .meta {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  align-items: center;
  margin-top: 12px;
  color: var(--accent);
  font-size: 10px;
}
.node .openmark {
  font-size: 16px;
}
.board.focus .node:not(.lit) {
  opacity: 0.34;
}
.node.selected {
  border-color: var(--accent);
  box-shadow:
    0 0 0 1px var(--accent),
    0 12px 25px #0002;
}
.wires {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  overflow: visible;
}
.wire {
  fill: none;
  stroke: #63829c;
  stroke-opacity: 0.2;
  stroke-width: 1.2;
}
.wire.active {
  stroke: var(--cyan);
  stroke-opacity: 0.9;
  stroke-width: 1.8;
}
.wire.muted {
  stroke-opacity: 0.06;
}
.mobile-links {
  display: none;
}
.meta-section {
  margin-top: 22px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}
.meta-section > details {
  background: #101a28;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 16px 18px;
}
.meta-section > details.wide {
  grid-column: 1/-1;
}
summary {
  cursor: pointer;
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 10px;
}
summary:before {
  content: "+";
  color: var(--cyan);
  font-size: 18px;
  line-height: 1;
}
details[open] > summary:before {
  content: "−";
}
summary::-webkit-details-marker {
  display: none;
}
.summary-note {
  color: var(--muted);
  font-size: 11px;
  font-weight: 400;
  margin-left: auto;
}
.section-body {
  padding-top: 14px;
  color: var(--muted);
  font-size: 13px;
}
.section-body p + p {
  margin-top: 12px;
}
.section-body strong {
  color: var(--text);
}
.protocol {
  margin: 12px 0 0;
  padding-left: 20px;
}
.protocol li {
  margin: 6px 0;
}
.hyp-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.hyp-item {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 13px 15px;
  background: #0e1724;
}
.hyp-title {
  font-size: 13px;
  color: var(--text);
  font-weight: 550;
  line-height: 1.5;
  margin-bottom: 7px;
}
.hyp-id {
  color: var(--amber);
  font-size: 11px;
  font-weight: 650;
  margin-right: 8px;
}
.hyp-test,
.hyp-metric {
  font-size: 12px;
  color: var(--muted);
  margin: 6px 0;
}
.hyp-metric strong {
  color: var(--text);
  font-weight: 500;
}
.hyp-tasks {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.chip {
  background: #162539;
  border: 1px solid #2a415b;
  border-radius: 7px;
  color: #bcd0ea;
  padding: 4px 8px;
  font-size: 11px;
  text-align: left;
}
.chip:hover {
  border-color: var(--cyan);
  color: var(--cyan);
}
.resource {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.resource:first-child {
  padding-top: 0;
}
.resource:last-child {
  border: 0;
  padding-bottom: 0;
}
.resource p {
  font-size: 12px;
  margin: 5px 0 0;
  color: var(--muted);
}
.source-names {
  word-break: break-word;
  color: #8194ad;
  font-size: 11px;
}
.footer {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  flex-wrap: wrap;
  margin-top: 29px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: #8094ae;
  font-size: 11px;
}
.drawer {
  position: fixed;
  z-index: 20;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(530px, 44vw);
  padding: 27px 27px 35px;
  background: #111d2b;
  border-left: 1px solid #37516c;
  box-shadow: -20px 0 75px #0009;
  overflow-y: auto;
  overscroll-behavior: contain;
  transform: translateX(110%);
  visibility: hidden;
  transition: transform 0.22s ease;
}
.drawer.open {
  transform: translateX(0);
  visibility: visible;
}
.drawer-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 21px;
}
.close {
  background: #1d3045;
  border: 1px solid #3a526c;
  border-radius: 9px;
  width: 34px;
  height: 34px;
  font-size: 22px;
  line-height: 1;
}
.drawer h2 {
  font-size: 25px;
  line-height: 1.25;
  letter-spacing: -0.02em;
  margin: 8px 0 12px;
}
.drawer .lead {
  color: #c2d0e2;
  font-size: 14px;
  margin-bottom: 20px;
}
.dsection {
  margin: 21px 0;
}
.dsection h3 {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--cyan);
  margin-bottom: 9px;
}
.dsection p,
.dsection li {
  font-size: 13px;
  color: #c2d0e2;
}
.dsection ol {
  margin: 0;
  padding-left: 19px;
}
.dsection li {
  padding: 3px 0;
}
.contracts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 11px;
}
.contract {
  background: #0d1723;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 13px;
}
.contract h3 {
  margin-bottom: 8px;
}
.independent {
  padding: 14px 15px;
  border: 1px solid #304e58;
  border-radius: 10px;
  background: #142c33;
}
.independent h3 {
  color: var(--cyan);
}
.acceptance {
  padding: 14px 15px;
  border: 1px solid #4d4434;
  border-radius: 10px;
  background: #29251f;
}
.acceptance h3 {
  color: var(--amber);
}
.relation {
  display: block;
  width: 100%;
  text-align: left;
  margin: 7px 0;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #162538;
  padding: 10px 12px;
  font-size: 12px;
}
.relation small {
  display: block;
  color: var(--muted);
  font-size: 11px;
  margin: 3px 0 0;
}
.relation:hover {
  border-color: var(--cyan);
}
.toast {
  position: fixed;
  bottom: 22px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 30;
  background: #244656;
  border: 1px solid var(--cyan);
  border-radius: 10px;
  padding: 10px 16px;
  font-size: 12px;
  box-shadow: 0 8px 30px #0005;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
#topic-view {
  scroll-margin-top: 15px;
}
.readiness {
  font-size: 11px;
  color: var(--muted);
  margin-top: 12px;
}
@media (min-width: 1101px) {
  body.has-detail .shell {
    padding-right: calc(min(530px, 44vw) + 35px);
    max-width: none;
  }
  .has-detail .board {
    gap: 25px;
  }
  .has-detail .node {
    padding: 14px 11px;
    min-height: 170px;
  }
  .has-detail .tabs {
    gap: 6px;
  }
  .has-detail .topic-summary {
    grid-template-columns: 1fr;
  }
  .has-detail .hypothesis-summary {
    border-left: 0;
    padding-left: 0;
    border-top: 1px solid var(--line);
    padding-top: 14px;
  }
  .has-detail .hyp-list {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 1250px) {
  .shell {
    padding: 25px 25px 45px;
  }
  .board {
    gap: 27px;
  }
  .topic-title {
    font-size: 23px;
  }
  .node {
    padding: 14px 12px;
  }
  .tab {
    font-size: 11px;
  }
}
@media (max-width: 1100px) {
  .board {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 25px;
  }
  .wires {
    display: none;
  }
  .mobile-links {
    display: block;
    color: var(--muted);
    font-size: 10px;
    margin-top: 7px;
  }
  .node {
    min-height: 140px;
  }
  .drawer {
    width: min(540px, 90vw);
  }
  .topic-summary {
    grid-template-columns: 1fr;
  }
  .hypothesis-summary {
    border-left: 0;
    border-top: 1px solid var(--line);
    padding: 15px 0 0;
  }
  .hyp-list {
    grid-template-columns: 1fr;
  }
  .tool-row {
    align-items: flex-start;
  }
  .meta-section {
    grid-template-columns: 1fr;
  }
  .summary-note {
    font-size: 10px;
  }
}
@media (max-width: 600px) {
  .shell {
    padding: 20px 16px 35px;
  }
  .masthead {
    margin-bottom: 20px;
  }
  .brand {
    font-size: 10px;
    letter-spacing: 0.08em;
  }
  .back {
    font-size: 11px;
  }
  h1 {
    font-size: 30px;
  }
  .intro {
    font-size: 13px;
  }
  .headnote {
    margin: 16px 0 21px;
    gap: 6px;
  }
  .pill {
    font-size: 10px;
  }
  .tabs {
    gap: 7px;
  }
  .tab {
    flex: 1 1 46%;
    padding: 10px;
    min-height: 48px;
  }
  .tab:first-child {
    flex-basis: 100%;
  }
  .topic-summary {
    padding: 18px;
    gap: 17px;
  }
  .topic-title {
    font-size: 22px;
  }
  .board {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .lane-head {
    font-size: 13px;
  }
  .node {
    min-height: 0;
    padding: 16px;
  }
  .node .title {
    font-size: 15px;
  }
  .node .short {
    font-size: 13px;
  }
  .node .meta {
    margin-top: 10px;
  }
  .guide {
    font-size: 11px;
  }
  .tool-row {
    gap: 10px;
  }
  .smallbtn {
    font-size: 11px;
    padding: 7px 9px;
  }
  .meta-section > details {
    padding: 15px;
  }
  .summary-note {
    display: none;
  }
  .drawer {
    width: 100%;
    padding: 20px;
  }
  .contracts {
    grid-template-columns: 1fr;
  }
  .drawer h2 {
    font-size: 25px;
  }
  .footer {
    font-size: 10px;
  }
  .drawer-bar {
    position: sticky;
    top: -20px;
    background: #111d2b;
    padding: 10px 0;
    z-index: 1;
  }
  .node .openmark {
    font-size: 19px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition: none !important;
  }
  .node:hover {
    transform: none;
  }
}
@media print {
  .drawer,
  .tabs,
  .wires,
  .tool-row,
  .back {
    display: none !important;
  }
  .shell {
    max-width: none;
    padding: 0 !important;
  }
  body {
    background: white;
    color: black;
  }
  .topic-summary,
  .node,
  .meta-section > details {
    background: white;
    color: black;
    border-color: #bbb;
  }
  .node .short,
  .subtitle,
  .intro,
  .guide {
    color: #444;
  }
  .board {
    grid-template-columns: repeat(2, 1fr);
  }
  .node {
    break-inside: avoid;
  }
  .meta-section details {
    display: none;
  }
}

.science-note {
  margin-top: 14px;
  padding: 10px 12px;
  border-left: 2px solid var(--line);
  font-size: 12.5px;
  line-height: 1.55;
}
.science-note + .science-note {
  margin-top: 0;
}
