/* anyconcept research page
   sidebar layout + long-form content sections. */

/* ---------- sidebar ---------- */
.research-sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 200px;
  height: 100vh;
  background: var(--bg-page);
  border-right: 0.5px solid var(--border);
  padding: 120px 24px 40px;
  z-index: 50;
}

.research-sidebar__nav {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.research-sidebar__link {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.1em;
  color: var(--text-tertiary);
  transition: color 120ms ease;
}

.research-sidebar__link:hover {
  color: var(--text-secondary);
}

.research-sidebar__link.is-active {
  color: var(--red);
}

/* ---------- main content ---------- */
.research-main {
  margin-left: 200px;
  max-width: 1100px;
  padding: 120px 80px 120px 48px;
}

/* ---------- opening ---------- */
.research-opening {
  padding-bottom: 80px;
  border-bottom: 0.5px solid var(--border);
  margin-bottom: 80px;
}

.research-display {
  font: var(--font-display);
  letter-spacing: var(--tracking-display);
  max-width: 600px;
  margin-bottom: 24px;
}

/* ---------- section label ---------- */
.research-section-label {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 32px;
}

/* ---------- sections ---------- */
.research-section {
  padding-bottom: 80px;
  border-bottom: 0.5px solid var(--border);
  margin-bottom: 80px;
  scroll-margin-top: 100px;
}

.research-section--last {
  border-bottom: none;
  padding-bottom: 0;
  margin-bottom: 0;
}

/* ---------- headlines ---------- */
.research-headline {
  font: 600 28px/1.2 'Inter', sans-serif;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
}

/* ---------- body copy ---------- */
.research-body {
  font: 400 15px/1.75 'Inter', sans-serif;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

/* ---------- limitation subtitles (section 05) ---------- */
.research-limitation-title {
  font: 500 15px/1.4 'Inter', sans-serif;
  color: var(--text-primary);
  margin-top: 32px;
  margin-bottom: 8px;
}

/* ---------- visuals ---------- */
.research-visual {
  margin-top: 48px;
}

/* -- attention visual (section 02) -- */
.research-visual__legend {
  display: flex;
  gap: 20px;
  margin-bottom: 16px;
}

.research-visual__legend-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  color: rgba(255, 255, 255, 0.5);
}

.research-visual__swatch {
  display: inline-block;
  width: 8px;
  height: 8px;
}

.research-visual__swatch--relevant {
  background: rgba(45, 155, 111, 0.7);
}

.research-visual__swatch--wait {
  background: rgba(196, 125, 32, 0.7);
}

.research-visual__swatch--irrelevant {
  background: rgba(255, 255, 255, 0.1);
}

.research-visual__browser-wrap {
  overflow-x: auto;
}

.research-visual__browser {
  width: 100%;
  height: auto;
}

.research-visual__caption {
  margin-top: 8px;
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  color: rgba(255, 255, 255, 0.4);
}

/* -- key facts strip -- */
.key-facts {
  padding: 48px 0;
}

.key-facts__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
}

.key-facts__value {
  font-family: var(--font-family-mono);
  font-size: 13px;
  color: var(--red);
  letter-spacing: 0.06em;
  margin-bottom: 10px;
}

.key-facts__desc {
  font-family: var(--font-family-body);
  font-size: 13px;
  font-weight: 400;
  color: var(--text-secondary);
  line-height: 1.65;
}

/* -- node evaluation visual (section 03) -- */
.node-eval {
  background: var(--bg-surface);
  border: 0.5px solid var(--border);
  border-radius: 4px;
  padding: 40px 48px;
  max-width: 560px;
}

.node-eval__label {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 32px;
}

.node-eval__header {
  display: grid;
  grid-template-columns: 140px 1fr;
  padding: 10px 0;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 32px;
}

.node-eval__header-left {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.3);
}

.node-eval__header-right {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.8;
}

.node-eval__outcome-label {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.3);
  margin-bottom: 20px;
}

.node-eval__row {
  display: grid;
  grid-template-columns: 140px 1fr;
  padding: 16px 0;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.06);
}

.node-eval__row--last {
  border-bottom: none;
}

.node-eval__status {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  font-weight: 500;
  letter-spacing: 0.08em;
}

.node-eval__status--proceed { color: #2D9B6F; }
.node-eval__status--warning { color: #C47D20; }
.node-eval__status--stop { color: #C0392B; }

.node-eval__desc {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.4);
  line-height: 1.8;
}

/* -- training visual (section 04) -- */
.research-visual__training-svg {
  width: 100%;
  max-width: 900px;
  height: auto;
}

/* -- benchmark visual (section 06) -- */
.benchmark-spec {
  background: var(--bg-surface);
  border: 0.5px solid var(--border);
  border-radius: 4px;
  padding: 40px 48px;
  max-width: 560px;
}

.benchmark-spec__label {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.4);
  margin-bottom: 24px;
}

.benchmark-spec__header {
  display: grid;
  grid-template-columns: 200px 1fr;
  padding: 10px 0;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.06);
  margin-bottom: 32px;
}

.benchmark-spec__header-left,
.benchmark-spec__header-right {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.08em;
  color: rgba(255, 255, 255, 0.3);
}

.benchmark-spec__row {
  display: grid;
  grid-template-columns: 200px 1fr;
  padding: 16px 0;
  border-bottom: 0.5px solid rgba(255, 255, 255, 0.06);
}

.benchmark-spec__row--last {
  border-bottom: none;
}

.benchmark-spec__metric {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  font-weight: 500;
  letter-spacing: 0.06em;
  color: rgba(255, 255, 255, 0.7);
}

.benchmark-spec__question {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.04em;
  color: rgba(255, 255, 255, 0.35);
  line-height: 1.8;
}

.benchmark-spec__footer {
  border-top: 0.5px solid rgba(255, 255, 255, 0.06);
  margin-top: 32px;
  padding-top: 24px;
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.08em;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.2);
}

/* ---------- footer offset ---------- */
.research-main ~ .footer {
  margin-left: 200px;
}

/* ---------- lab notebook tab (mobile nav) ---------- */
.labtab {
  display: none;
  position: fixed;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  z-index: 100;
}

.labtab__handle {
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 36px;
  height: 64px;
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  border-right: none;
  border-radius: 6px 0 0 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 150ms ease;
}

.labtab__handle:hover {
  background: var(--bg-card);
}

.labtab__current {
  font-family: var(--font-family-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--red);
  writing-mode: vertical-lr;
  text-orientation: mixed;
}

.labtab__drawer {
  position: absolute;
  right: 36px;
  top: 50%;
  transform: translateY(-50%) scaleX(0);
  transform-origin: right center;
  background: var(--bg-elevated);
  border: 0.5px solid var(--border);
  border-right: none;
  border-radius: 6px 0 0 6px;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: transform 200ms ease, opacity 150ms ease;
}

.labtab.is-open .labtab__drawer {
  transform: translateY(-50%) scaleX(1);
  opacity: 1;
  pointer-events: auto;
}

.labtab__link {
  font-family: var(--font-family-mono);
  font-size: var(--font-size-mono);
  letter-spacing: 0.1em;
  color: var(--text-tertiary);
  transition: color 120ms ease;
  padding: 4px 0;
}

.labtab__link:hover {
  color: var(--text-secondary);
}

.labtab__link.is-active {
  color: var(--red);
}

/* ---------- responsive ---------- */
@media (max-width: 1024px) {
  .research-sidebar {
    display: none;
  }

  .labtab {
    display: block;
  }

  .research-main ~ .footer {
    margin-left: 0;
  }

  .research-main {
    margin-left: 0;
    padding: 100px 40px;
  }
}

@media (max-width: 900px) {
  .key-facts__grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px 0;
  }
}

@media (max-width: 720px) {
  .research-main {
    padding: 80px 20px;
  }

  .node-eval,
  .benchmark-spec {
    padding: 24px 20px;
  }

  .node-eval__header,
  .node-eval__row {
    grid-template-columns: 100px 1fr;
  }

  .benchmark-spec__header,
  .benchmark-spec__row {
    grid-template-columns: 140px 1fr;
  }
}
