:root {
  --bg: #f3f4f6;
  --surface: #ffffff;
  --surface-alt: #f8fafc;
  --text: #111827;
  --muted: #4b5563;
  --line: rgba(17, 24, 39, 0.12);
  --line-strong: rgba(17, 24, 39, 0.2);
  --blue: #1f4b8f;
  --blue-hover: #163c74;
  --chip: #edf1f5;
  --radius-l: 1rem;
  --radius-m: 0.75rem;
  --radius-s: 0.5rem;
  --shadow-soft: 0 3px 14px rgba(15, 23, 42, 0.06);
  --shadow-card: 0 8px 24px rgba(15, 23, 42, 0.08);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  font-family:
    -apple-system,
    BlinkMacSystemFont,
    "SF Pro Text",
    "SF Pro Display",
    "Helvetica Neue",
    Helvetica,
    Arial,
    "PingFang SC",
    "Hiragino Sans GB",
    "Microsoft YaHei",
    sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #f8fafc 0%, var(--bg) 24%, var(--bg) 100%);
  line-height: 1.52;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a {
  color: inherit;
  text-decoration: none;
}

p {
  margin: 0;
  color: var(--muted);
}

h1,
h2,
h3 {
  margin-top: 0;
  margin-bottom: 0;
  color: var(--text);
  font-weight: 700;
  letter-spacing: -0.012em;
  line-height: 1.08;
}

.container {
  width: min(1220px, 93vw);
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 1rem;
  min-height: 4.05rem;
  padding: 0.48rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 0;
}

.brand-logo {
  width: 2.3rem;
  height: 2.3rem;
  object-fit: contain;
  flex-shrink: 0;
}

.brand-text {
  display: grid;
  gap: 0.05rem;
  line-height: 1.2;
  min-width: 0;
  max-width: 14.2rem;
}

.brand-text strong {
  font-size: 0.9rem;
  font-weight: 700;
  color: #1f2937;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand-text span {
  font-size: 0.72rem;
  color: #667085;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.main-nav {
  justify-self: center;
  display: flex;
  align-items: center;
  gap: 0.16rem;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 0;
  max-width: 100%;
}

.main-nav::-webkit-scrollbar {
  display: none;
}

.nav-link {
  white-space: nowrap;
  font-size: 0.76rem;
  font-weight: 600;
  color: #374151;
  border-bottom: 2px solid transparent;
  border-radius: 0.35rem;
  padding: 0.3rem 0.46rem;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.nav-link:hover {
  background: #edf1f5;
  color: #111827;
}

.nav-link.active {
  background: transparent;
  color: var(--blue);
  border-bottom-color: var(--blue);
  border-radius: 0;
}

.language-switch {
  display: flex;
  gap: 0.22rem;
  background: var(--chip);
  border-radius: 0.55rem;
  padding: 0.14rem;
  border: 1px solid var(--line);
}

.lang-btn {
  border: 0;
  border-radius: 0.45rem;
  background: transparent;
  color: #4d4d52;
  padding: 0.26rem 0.58rem;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease;
}

.lang-btn.active {
  background: #fff;
  color: #111827;
  box-shadow: 0 1px 2px rgba(17, 24, 39, 0.14);
}

main {
  padding: 2.6rem 0 4.2rem;
}

.hero {
  display: grid;
  grid-template-columns: 1fr 0.78fr;
  gap: 1.35rem;
  align-items: stretch;
}

.hero-simple {
  grid-template-columns: 1fr;
}

.hero-content,
.hero-aside {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-l);
  box-shadow: var(--shadow-soft);
}

.hero-content {
  padding: clamp(1.6rem, 3vw, 2.6rem);
  text-align: left;
}

.hero-aside {
  padding: 1.3rem 1.2rem;
}

.kicker {
  color: #6b7280;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.hero-content h1 {
  margin-top: 0.58rem;
  margin-bottom: 0.8rem;
  font-size: clamp(1.9rem, 4.9vw, 3.2rem);
  letter-spacing: -0.027em;
}

.lead {
  max-width: 70ch;
  margin: 0;
  font-size: clamp(1rem, 1.5vw, 1.12rem);
  color: #4b5563;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-start;
  gap: 0.65rem;
  margin-top: 1.25rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.58rem;
  border: 1px solid transparent;
  padding: 0.56rem 0.92rem;
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: -0.01em;
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--blue);
  color: #fff;
  box-shadow: 0 4px 12px rgba(31, 75, 143, 0.24);
}

.btn-primary:hover {
  background: var(--blue-hover);
}

.btn-secondary {
  background: #f8fafc;
  border-color: var(--line-strong);
  color: #1d1d1f;
}

.btn-secondary:hover {
  background: #eef2f7;
}

.section {
  margin-top: 3.75rem;
}

.section h2 {
  font-size: clamp(1.52rem, 2.7vw, 2.35rem);
  letter-spacing: -0.02em;
  margin-bottom: 0.78rem;
}

.card-grid,
.phase-grid,
.timeline-grid,
.room-grid {
  margin-top: 1rem;
  display: grid;
  gap: 1rem;
}

.card-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card-grid.two-col {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.phase-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.timeline-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.room-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.card,
.phase-card,
.timeline-card,
.debate-card,
.room-card,
.stack-item,
.highlight-list,
.theory-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

.card,
.phase-card,
.timeline-card,
.debate-card,
.room-card {
  padding: 1.18rem;
}

.card h3,
.phase-card h3,
.timeline-card h3,
.debate-card h3,
.room-card h3 {
  margin-bottom: 0.52rem;
  font-size: clamp(1.03rem, 1.4vw, 1.22rem);
  letter-spacing: -0.02em;
}

.check-list {
  margin: 0.45rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.62rem;
}

.check-list li {
  position: relative;
  padding-left: 1.1rem;
  color: #4b5563;
}

.check-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.52rem;
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 999px;
  background: #64748b;
}

.stack-list {
  margin-top: 1rem;
  display: grid;
  gap: 0.8rem;
}

.stack-item {
  padding: 0.9rem 1rem;
}

.stack-label,
.file-meta,
.room-badge {
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.045em;
  text-transform: uppercase;
}

.stack-label {
  color: #4b5563;
}

.highlight-list {
  padding: 1rem 1.06rem;
}

.protocol-list {
  margin: 0.92rem 0 0;
  padding-left: 1.16rem;
  display: grid;
  gap: 0.55rem;
}

.protocol-list li {
  color: #4b5563;
}

.table-wrap {
  margin-top: 1rem;
  overflow: auto;
  border-radius: var(--radius-m);
  border: 1px solid var(--line);
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.rubric-table {
  border-collapse: collapse;
  width: 100%;
  min-width: 640px;
}

.rubric-table th,
.rubric-table td {
  text-align: left;
  padding: 0.86rem 0.95rem;
  border-bottom: 1px solid var(--line);
}

.rubric-table th {
  background: #f3f4f6;
  font-size: 0.88rem;
  font-weight: 600;
  color: #4b4b50;
  letter-spacing: 0.01em;
}

.download-card {
  display: grid;
  gap: 0.64rem;
}

.file-meta {
  color: #6b7280;
}

.inline-link {
  color: var(--blue);
  text-decoration: underline;
  text-underline-offset: 2px;
  text-decoration-thickness: 1px;
}

.contact-form {
  margin-top: 1rem;
  padding: 1.1rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-m);
  box-shadow: var(--shadow-soft);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.85rem;
}

.form-row {
  display: grid;
  gap: 0.35rem;
}

.form-row-full {
  grid-column: span 2;
}

.contact-form label {
  color: #374151;
  font-size: 0.9rem;
  font-weight: 500;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: 0.78rem;
  padding: 0.64rem 0.72rem;
  font: inherit;
  color: #1d1d1f;
  background: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: rgba(31, 75, 143, 0.58);
  box-shadow: 0 0 0 3px rgba(31, 75, 143, 0.12);
}

.contact-form textarea {
  resize: vertical;
}

.contact-form button {
  justify-self: start;
}

.debate-grid {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
}

.theory-map-wrap {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: 1.12fr 0.88fr;
  gap: 1rem;
}

.legend-row {
  margin-top: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.legend-item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.8rem;
  color: #4b5563;
}

.legend-swatch {
  width: 0.9rem;
  height: 0.32rem;
  border-radius: 999px;
  background: rgba(61, 61, 66, 0.4);
}

.legend-swatch.agreement {
  background: rgba(22, 163, 74, 0.55);
}

.legend-swatch.disagreement {
  background: rgba(185, 28, 28, 0.55);
}

.legend-swatch.issue {
  background: transparent;
  border-top: 2px dashed rgba(31, 75, 143, 0.6);
  border-radius: 0;
}

.legend-swatch.taxonomy {
  background: rgba(61, 61, 66, 0.42);
}

.legend-swatch.pressure {
  background: transparent;
  border-top: 2px dashed rgba(185, 28, 28, 0.62);
  border-radius: 0;
}

.legend-swatch.support {
  background: transparent;
  border-top: 2px dashed rgba(22, 163, 74, 0.62);
  border-radius: 0;
}

.legend-swatch.constraint {
  background: transparent;
  border-top: 2px dashed rgba(31, 75, 143, 0.62);
  border-radius: 0;
}

.theory-graph {
  position: relative;
  min-height: 700px;
  border: 1px solid var(--line);
  border-radius: var(--radius-l);
  background: #fff;
  box-shadow: var(--shadow-soft);
}

.theory-lines {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.theory-edge {
  stroke: rgba(61, 61, 66, 0.34);
  stroke-width: 2;
  opacity: 0.8;
}

.theory-edge.agreement {
  stroke: rgba(22, 163, 74, 0.55);
}

.theory-edge.disagreement {
  stroke: rgba(185, 28, 28, 0.55);
}

.theory-edge.issue {
  stroke: rgba(31, 75, 143, 0.44);
  stroke-dasharray: 4 4;
}

.theory-edge.issue.pressure {
  stroke: rgba(185, 28, 28, 0.58);
}

.theory-edge.issue.support {
  stroke: rgba(22, 163, 74, 0.58);
}

.theory-edge.issue.constraint {
  stroke: rgba(31, 75, 143, 0.58);
}

.theory-edge.connected {
  opacity: 1;
  stroke-width: 2.6;
}

.theory-edge.dimmed {
  opacity: 0.18;
}

.theory-node {
  position: absolute;
  transform: translate(-50%, -50%);
  max-width: 8.6rem;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  padding: 0.35rem 0.62rem;
  font-size: 0.73rem;
  font-weight: 600;
  line-height: 1.2;
  text-align: center;
  color: #2d2d32;
  background: #fff;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.09);
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.theory-node:hover {
  transform: translate(-50%, -50%) scale(1.03);
}

.theory-node.issue {
  background: #f8f9fc;
}

.theory-node.active {
  color: #fff;
  background: var(--blue);
  border-color: var(--blue);
  box-shadow: 0 8px 16px rgba(31, 75, 143, 0.25);
}

.theory-panel {
  padding: 1.08rem;
}

.theory-panel h3 {
  margin-bottom: 0.58rem;
}

.theory-panel h4 {
  margin: 0 0 0.45rem;
  font-size: 1.08rem;
  color: #242428;
}

#theoryPanelWhat,
#theoryPanelWhy,
#theoryPanelClassic,
#normPanelCore,
#normPanelIntuition,
#normPanelClassic {
  margin: 0.1rem 0 0.35rem;
  color: #4b5563;
  line-height: 1.45;
}

.theory-panel ul {
  margin: 0.62rem 0 0;
  padding-left: 1.08rem;
  display: grid;
  gap: 0.42rem;
}

.relation-heading {
  margin: 0.72rem 0 0.3rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: #4b5563;
}

#theoryPanelIssueReasons,
#normPanelIssueReasons {
  list-style: none;
  padding-left: 0;
  margin-top: 0.55rem;
  gap: 0.52rem;
}

.relation-reason-item {
  padding: 0.58rem 0.62rem;
  border: 1px solid var(--line);
  border-radius: 0.75rem;
  background: #f8fafc;
}

.relation-reason-title {
  margin: 0;
  font-size: 0.81rem;
  font-weight: 600;
  color: #1f2937;
}

.relation-reason-body {
  margin: 0.26rem 0 0;
  font-size: 0.8rem;
  line-height: 1.45;
  color: #4b5563;
}

.relation-reason-sources {
  margin: 0.34rem 0 0;
  font-size: 0.74rem;
  color: #6b7280;
}

.relation-reason-sources a {
  color: var(--blue);
  text-decoration: none;
}

.relation-reason-sources a:hover {
  text-decoration: underline;
}

.room-card {
  gap: 0.5rem;
  display: grid;
}

.room-badge {
  width: fit-content;
  border-radius: 999px;
  padding: 0.22rem 0.54rem;
  color: #4b5563;
  background: var(--chip);
  border: 1px solid var(--line);
}

.room-topic-list {
  margin: 0;
  padding-left: 1.08rem;
  display: grid;
  gap: 0.35rem;
}

.callout {
  text-align: center;
  padding: clamp(1.5rem, 3vw, 2.1rem);
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-radius: var(--radius-l);
  box-shadow: var(--shadow-soft);
}

.callout p {
  margin-bottom: 1rem;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: #f7f7f9;
}

.site-footer .container {
  padding: 1rem 0 1.25rem;
}

.site-footer p {
  color: #6b7280;
  font-size: 0.84rem;
}

.reveal {
  opacity: 0;
  transform: translateY(10px);
  transition:
    opacity 0.62s ease,
    transform 0.62s ease;
  transition-delay: var(--delay, 0s);
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
}

@media (max-width: 1120px) {
  .header-inner {
    grid-template-columns: 1fr;
    gap: 0.68rem;
    justify-items: start;
    padding: 0.55rem 0;
  }

  .main-nav {
    justify-self: stretch;
    width: 100%;
  }

  .language-switch {
    justify-self: start;
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .card-grid,
  .card-grid.two-col,
  .phase-grid,
  .timeline-grid,
  .room-grid,
  .debate-grid {
    grid-template-columns: 1fr;
  }

  .theory-map-wrap {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  main {
    padding-top: 2rem;
  }

  .brand-logo {
    width: 2.25rem;
    height: 2.25rem;
  }

  .brand-text {
    max-width: 11.6rem;
  }

  .hero-content {
    padding: 1.4rem 1.1rem;
  }

  .section {
    margin-top: 2.7rem;
  }

  .contact-form {
    grid-template-columns: 1fr;
  }

  .form-row-full {
    grid-column: auto;
  }

  .theory-graph {
    min-height: 760px;
  }
}
