/* WORKNEL 소개 페이지의 브랜드 색상, 서체와 반응형 화면을 정의합니다. */

@font-face {
  font-family: "Manrope";
  src: url("assets/fonts/Manrope-Variable.ttf") format("truetype");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --navy: #0B1D3A;
  --navy-2: #13284C;
  --cobalt: #2B5CFF;
  --cobalt-ink: #2350E6;
  --cobalt-light: #9DB4FF;
  --cobalt-soft: #EBF0FF;
  --white: #FFFFFF;
  --paper: #F5F7FB;
  --ink: #0B1D3A;
  --muted: #4A5670;
  --line: #DAE0EB;
  --line-dark: rgba(255, 255, 255, 0.16);
  --on-dark-muted: #B9C3D6;

  --font: "Manrope", "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans CJK KR", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --gutter: clamp(20px, 5vw, 56px);
  --section-y: clamp(80px, 11vw, 152px);
  --header-h: 72px;
  --radius: 4px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--white);
  font-feature-settings: "ss01" off;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }

h1, h2, h3 { margin: 0; line-height: 1.12; font-weight: 700; letter-spacing: -0.02em; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

a { color: inherit; }

:focus-visible {
  outline: 3px solid var(--cobalt);
  outline-offset: 3px;
  border-radius: 2px;
}

.architecture :focus-visible,
.site-footer :focus-visible { outline-color: var(--cobalt-light); }

.wrap {
  width: 100%;
  max-width: 1240px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

section[id] { scroll-margin-top: var(--header-h); }

.skip-link {
  position: absolute;
  left: 12px;
  top: -100px;
  z-index: 100;
  padding: 12px 18px;
  background: var(--navy);
  color: var(--white);
  font-weight: 700;
  text-decoration: none;
}
.skip-link:focus { top: 12px; }

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.94);
  border-bottom: 1px solid var(--line);
}

@supports (backdrop-filter: blur(8px)) {
  .site-header {
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: saturate(1.4) blur(12px);
  }
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: var(--header-h);
}

/* The logo file includes its own clear space; offset it so the mark aligns with the grid. */
.brand { display: block; margin-left: -10px; }
.brand img { width: 226px; height: auto; }

.site-nav ul { display: flex; gap: 4px; }

.site-nav a {
  display: block;
  padding: 10px 14px;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
  border-radius: var(--radius);
  transition: color 0.15s ease, background-color 0.15s ease;
}

.site-nav a:hover { color: var(--ink); background: var(--paper); }

.site-nav a.is-current { color: var(--ink); box-shadow: inset 0 -2px 0 var(--cobalt); border-radius: 0; }

.language-switch {
  display: flex;
  flex: none;
  align-items: center;
  gap: 2px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
}

.language-switch a {
  display: grid;
  place-items: center;
  min-height: 44px;
  padding: 8px 12px;
  font-size: 0.875rem;
  font-weight: 700;
  white-space: nowrap;
  text-decoration: none;
  border-radius: 2px;
  color: var(--muted);
}

.language-switch a:hover { background: var(--paper); color: var(--ink); }
.language-switch a[aria-current="page"] { background: var(--navy); color: var(--white); }

@media (max-width: 1100px) {
  .site-nav { display: none; }
}

@media (max-width: 520px) {
  .header-inner { gap: 12px; }
  .brand img { width: 154px; }
  .language-switch a { font-size: 0.8125rem; padding-inline: 8px; }
}

/* 한글은 단어 단위로 줄을 나누고 제목과 본문의 줄 간격을 확보합니다. */
html:lang(ko) body { word-break: keep-all; overflow-wrap: anywhere; line-height: 1.8; }
html:lang(ko) h1,
html:lang(ko) h2,
html:lang(ko) h3 { line-height: 1.35; letter-spacing: -0.035em; }
html:lang(ko) .hero h1 { font-size: clamp(2.5rem, 5.6vw, 4.75rem); line-height: 1.22; }
html:lang(ko) .statement { line-height: 1.4; }
html:lang(ko) .lede,
html:lang(ko) .body-large { line-height: 1.8; }
html:lang(ko) .section-index,
html:lang(ko) .figure-label,
html:lang(ko) .panel-step,
html:lang(ko) .arch-tag,
html:lang(ko) .timeline-state { letter-spacing: 0.03em; }

/* ---------- Shared pieces ---------- */

.kernel-dot {
  display: inline-block;
  flex: none;
  width: 9px;
  height: 9px;
  background: var(--cobalt);
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 8px 14px;
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  color: var(--navy);
  background: var(--cobalt-soft);
  border: 1px solid #D3DEFF;
  border-radius: 999px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 52px;
  padding: 14px 24px;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  border-radius: var(--radius);
  border: 2px solid transparent;
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.button-primary { background: var(--cobalt); color: var(--white); }
.button-primary:hover { background: var(--navy); }

.button-quiet { color: var(--navy); border-color: var(--line); }
.button-quiet:hover { border-color: var(--navy); }

.section { padding-block: var(--section-y); }

.split {
  display: grid;
  grid-template-columns: minmax(160px, 3fr) 9fr;
  gap: clamp(24px, 4vw, 64px);
}

.split-main { min-width: 0; max-width: 860px; }

.section-index {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: 14px;
  border-top: 2px solid var(--navy);
  align-self: start;
}

.section-index span {
  display: block;
  margin-bottom: 4px;
  font-size: 2.25rem;
  letter-spacing: -0.02em;
  color: var(--cobalt);
  line-height: 1.1;
}

h2 {
  font-size: clamp(2rem, 4.4vw, 3.5rem);
  letter-spacing: -0.03em;
  margin-bottom: 28px;
}

.body-large {
  font-size: clamp(1.0625rem, 1.5vw, 1.25rem);
  line-height: 1.65;
  color: var(--muted);
  max-width: 62ch;
}

@media (max-width: 800px) {
  .split { grid-template-columns: 1fr; gap: 28px; }
  .section-index { display: flex; align-items: baseline; gap: 12px; }
  .section-index span { display: inline; font-size: 1.5rem; margin: 0; }
}

/* ---------- Hero ---------- */

.hero {
  position: relative;
  padding-block: clamp(56px, 9vw, 120px) clamp(72px, 10vw, 136px);
  overflow: hidden;
  background:
    linear-gradient(var(--white), rgba(255, 255, 255, 0) 30%, rgba(255, 255, 255, 0) 70%, var(--white)),
    repeating-linear-gradient(90deg, transparent 0 79px, rgba(11, 29, 58, 0.05) 79px 80px),
    repeating-linear-gradient(0deg, transparent 0 79px, rgba(11, 29, 58, 0.05) 79px 80px);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: clamp(40px, 6vw, 96px);
  align-items: center;
}

.hero-copy { min-width: 0; }

.hero h1 {
  margin: 32px 0 28px;
  font-size: clamp(2.5rem, 7.2vw, 6rem);
  overflow-wrap: break-word;
  line-height: 0.98;
  letter-spacing: -0.045em;
  font-weight: 800;
  color: var(--navy);
}

.lede {
  font-size: clamp(1.125rem, 1.8vw, 1.375rem);
  line-height: 1.55;
  color: var(--muted);
  max-width: 34em;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 40px;
}

.hero-figure {
  margin: 0;
  min-width: 0;
}

.layers-art {
  position: relative;
  aspect-ratio: 1;
  width: 100%;
  max-width: 440px;
  margin-inline: auto;
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: 0 30px 60px -40px rgba(11, 29, 58, 0.35);
}

.layers-art img { width: 100%; height: 100%; }

/* Marker positions follow the symbol geometry (120-unit viewBox). */
.marker {
  position: absolute;
  display: grid;
  place-items: center;
  width: clamp(20px, 5.4%, 26px);
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  font-size: clamp(0.6875rem, 1.2vw, 0.8125rem);
  font-weight: 800;
  line-height: 1;
  border-radius: 50%;
}

.marker-1 { left: 20.4%; top: 50%; background: var(--white); color: var(--navy); box-shadow: 0 0 0 2px var(--cobalt); }
.marker-2 { left: 50%; top: 34.6%; background: var(--white); color: var(--navy); box-shadow: 0 0 0 2px var(--cobalt); }
.marker-3 { left: 50%; top: 50%; background: transparent; color: var(--white); }

.hero-figure figcaption {
  max-width: 440px;
  margin: 24px auto 0;
}

.figure-label {
  display: block;
  margin-bottom: 12px;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.layers-legend { counter-reset: layer; }

.layers-legend li {
  counter-increment: layer;
  position: relative;
  padding: 10px 0 10px 40px;
  font-size: 0.9375rem;
  line-height: 1.5;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

.layers-legend li::before {
  content: counter(layer);
  position: absolute;
  left: 0;
  top: 11px;
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--navy);
  border-radius: 50%;
  box-shadow: inset 0 0 0 2px var(--cobalt);
}

.layers-legend li:last-child::before { background: var(--cobalt); color: var(--white); box-shadow: none; border-radius: 0; }

.layers-legend strong { color: var(--ink); }

@media (max-width: 960px) {
  .hero-grid { grid-template-columns: 1fr; }
  .hero-figure { max-width: 520px; }
}

/* ---------- Why ---------- */

.why { border-top: 1px solid var(--line); }

.statement {
  font-size: clamp(1.875rem, 4vw, 3.25rem);
  line-height: 1.12;
  margin-bottom: 36px;
}

.statement-accent { color: var(--cobalt-ink); }

.chain {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin-top: clamp(48px, 6vw, 80px);
  border-top: 2px solid var(--navy);
}

.chain li {
  position: relative;
  padding: 28px 24px 8px 0;
}

.chain li + li { padding-left: 24px; border-left: 1px solid var(--line); }

/* Connector arrow on the top rule */
.chain li + li::before {
  content: "";
  position: absolute;
  top: -7px;
  left: -6px;
  width: 12px;
  height: 12px;
  background: var(--white);
  border-top: 2px solid var(--navy);
  border-right: 2px solid var(--navy);
  transform: rotate(45deg);
}

.chain-num {
  display: inline-block;
  margin-bottom: 14px;
  font-family: var(--mono);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--cobalt-ink);
}

.chain h3 { font-size: 1.1875rem; margin-bottom: 8px; }
.chain p { font-size: 0.9375rem; color: var(--muted); }

.chain li:last-child h3::after {
  content: "";
  display: inline-block;
  width: 9px;
  height: 9px;
  margin-left: 10px;
  vertical-align: 0.15em;
  background: var(--cobalt);
}

@media (max-width: 900px) {
  .chain { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .chain li:nth-child(3) { padding-left: 0; border-left: 0; }
  .chain li:nth-child(3)::before { display: none; }
  .chain li:nth-child(n+3) { border-top: 1px solid var(--line); margin-top: 16px; }
}

@media (max-width: 520px) {
  .chain { grid-template-columns: 1fr; border-top: 0; border-left: 2px solid var(--navy); }
  .chain li,
  .chain li + li { padding: 4px 0 24px 24px; border-left: 0; border-top: 0; margin-top: 0; }
  .chain li:nth-child(n+3) { border-top: 0; margin-top: 0; }
  .chain li + li::before,
  .chain li:nth-child(3)::before { display: block; top: -10px; left: -8px; transform: rotate(135deg); }
}

/* ---------- Workflow ---------- */

.workflow { background: var(--paper); border-top: 1px solid var(--line); }

.split-head { margin-bottom: clamp(40px, 5vw, 64px); }

.flow {
  background: var(--white);
  border: 1px solid var(--line);
  box-shadow: 0 40px 80px -60px rgba(11, 29, 58, 0.4);
}

.flow-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  padding: 14px clamp(20px, 3vw, 32px);
  font-size: 0.875rem;
  color: var(--on-dark-muted);
  background: var(--navy);
}

.flow-banner-tag {
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--white);
  padding: 4px 10px;
  border: 1px solid var(--cobalt-light);
}

.flow-tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
}

.flow-tabs[hidden] { display: none; }

.flow-tabs [role="tab"] {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 72px;
  padding: 18px clamp(16px, 2.4vw, 32px);
  font: inherit;
  font-size: 1rem;
  font-weight: 700;
  text-align: left;
  color: var(--muted);
  background: transparent;
  border: 0;
  cursor: pointer;
  transition: color 0.15s ease, background-color 0.15s ease;
}

.flow-tabs [role="tab"] + [role="tab"] { border-left: 1px solid var(--line); }
.flow-tabs [role="tab"]:hover { color: var(--ink); background: var(--paper); }
.flow-tabs [role="tab"]:focus-visible { outline-offset: -4px; }

.flow-tabs [role="tab"]::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 3px;
  background: transparent;
}

.flow-tabs [role="tab"][aria-selected="true"] { color: var(--ink); }
.flow-tabs [role="tab"][aria-selected="true"]::after { background: var(--cobalt); }

.tab-num {
  display: grid;
  place-items: center;
  flex: none;
  width: 32px;
  height: 32px;
  font-size: 0.875rem;
  border: 2px solid currentColor;
  border-radius: 50%;
}

[aria-selected="true"] .tab-num { background: var(--cobalt); border-color: var(--cobalt); color: var(--white); }

.flow-panel {
  display: grid;
  grid-template-columns: 5fr 7fr;
  gap: clamp(28px, 4vw, 64px);
  padding: clamp(28px, 4vw, 56px) clamp(20px, 3vw, 32px) clamp(32px, 4vw, 56px);
}

/* Without JavaScript all three stages are shown in sequence. */
.flow-panel + .flow-panel { border-top: 1px solid var(--line); }
.js .flow-panel + .flow-panel { border-top: 0; }
.flow-panel[hidden] { display: none; }

@media (prefers-reduced-motion: no-preference) {
  .js .flow-panel:not([hidden]) { animation: panel-in 0.28s ease-out; }
  @keyframes panel-in {
    from { opacity: 0; transform: translateY(6px); }
    to { opacity: 1; transform: none; }
  }
}

.panel-step {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cobalt-ink);
  margin-bottom: 14px;
}

.panel-copy h3 { font-size: clamp(1.625rem, 2.6vw, 2.25rem); letter-spacing: -0.03em; margin-bottom: 16px; }
.panel-copy p:not(.panel-step) { font-size: 1.125rem; color: var(--muted); }

.panel-copy p.panel-note {
  margin-top: 24px;
  padding-left: 16px;
  font-size: 0.9375rem;
  color: var(--ink);
  border-left: 3px solid var(--cobalt);
}

.record {
  align-self: start;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
}

.record-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 20px;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.record-tag {
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0;
  text-transform: none;
  color: var(--muted);
  padding: 2px 8px;
  border: 1px dashed #A9B3C6;
  border-radius: 999px;
}

.record-title {
  padding: 20px 20px 0;
  font-size: 1.1875rem;
  font-weight: 700;
}

.record-sub { font-weight: 500; color: var(--muted); }

.record-instruction {
  margin: 10px 20px 0;
  font-family: var(--mono);
  font-size: 0.875rem;
  color: var(--muted);
}

.record-fields { margin: 0; padding: 8px 20px 12px; }

.record-fields > div {
  display: grid;
  grid-template-columns: 9.5rem 1fr;
  gap: 4px 16px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.record-fields > div:first-child { border-top: 0; }

.record-fields dt {
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--cobalt-ink);
  padding-top: 2px;
}

.record-fields dd { margin: 0; font-size: 0.9375rem; }

.diff {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: stretch;
  gap: 12px;
  margin: 20px 20px 8px;
}

.diff-col {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.diff-after { border-color: var(--cobalt); background: var(--cobalt-soft); }

.diff-label { font-family: var(--mono); font-size: 0.75rem; color: var(--muted); }
.diff-value { font-weight: 700; }
.diff-arrow { align-self: center; font-size: 1.25rem; color: var(--cobalt-ink); }

.checklist { padding: 8px 20px 12px; counter-reset: check; }

.checklist li {
  display: grid;
  grid-template-columns: 6.5rem 1fr;
  gap: 16px;
  padding: 14px 0;
  font-size: 0.9375rem;
  border-top: 1px solid var(--line);
}

.checklist li:first-child { border-top: 0; }

.check-key {
  font-family: var(--mono);
  font-size: 0.8125rem;
  color: var(--cobalt-ink);
  padding-top: 2px;
}

.checklist li:last-child { font-weight: 700; }

@media (max-width: 860px) {
  .flow-panel { grid-template-columns: 1fr; }
  .flow-tabs { grid-template-columns: 1fr; }
  .flow-tabs [role="tab"] { min-height: 60px; }
  .flow-tabs [role="tab"] + [role="tab"] { border-left: 0; border-top: 1px solid var(--line); }
  .flow-tabs [role="tab"]::after { top: 0; bottom: 0; right: auto; width: 3px; height: auto; }
}

@media (max-width: 520px) {
  .record-fields > div,
  .checklist li { grid-template-columns: 1fr; gap: 2px; }
  .diff { grid-template-columns: 1fr; }
  .diff-arrow { justify-self: center; transform: rotate(90deg); }
}

/* ---------- Architecture ---------- */

.architecture {
  color: var(--white);
  background: var(--navy);
}

.architecture .section-index { color: var(--on-dark-muted); border-top-color: var(--white); }
.architecture .section-index span { color: var(--cobalt-light); }
.architecture .body-large { color: var(--on-dark-muted); }

.arch-figure { margin: 0; }

.arch-diagram {
  display: grid;
  grid-template-columns: 7fr 5fr;
  gap: 0;
  align-items: stretch;
}

.arch-env {
  position: relative;
  padding: clamp(24px, 3vw, 40px);
  border: 1.5px dashed rgba(255, 255, 255, 0.4);
}

.arch-env-label {
  position: absolute;
  top: -0.8em;
  left: 20px;
  padding: 0 10px;
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  background: var(--navy);
  color: var(--white);
}

.arch-core {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 16px 18px;
  align-items: center;
  padding: clamp(20px, 3vw, 32px);
  background: var(--cobalt);
  border-radius: var(--radius);
}

.arch-core-mark { width: 56px; height: 56px; margin: -6px; }

.arch-core h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); }
.arch-core p { font-size: 0.9375rem; color: rgba(255, 255, 255, 0.88); }

.arch-duties {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.3);
}

.arch-duties li {
  padding: 6px 12px;
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--navy);
  background: var(--white);
  border-radius: 999px;
}

.arch-agents {
  position: relative;
  margin-top: 40px;
}

/* Vertical connector between core and agents */
.arch-agents::before {
  content: "";
  position: absolute;
  left: 40px;
  top: -40px;
  height: 40px;
  border-left: 2px solid rgba(255, 255, 255, 0.5);
}

.arch-agent {
  padding: 20px 24px;
  border: 1px solid var(--line-dark);
  border-radius: var(--radius);
  background: var(--navy-2);
  box-shadow: 8px 8px 0 -1px var(--navy), 8px 8px 0 0 var(--line-dark);
}

.arch-agent h3 { font-size: 1.125rem; margin-bottom: 6px; }
.arch-agent p { font-size: 0.9375rem; color: var(--on-dark-muted); }

.arch-links {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 20px;
  padding-left: clamp(28px, 4vw, 56px);
  position: relative;
}

.arch-ext {
  position: relative;
  padding: 22px 24px;
  border-radius: var(--radius);
}

/* Horizontal connector from the customer boundary */
.arch-ext::before {
  content: "";
  position: absolute;
  top: 50%;
  right: 100%;
  width: clamp(28px, 4vw, 56px);
  border-top: 2px dashed rgba(255, 255, 255, 0.5);
}

.arch-claude { background: var(--white); color: var(--navy); }
.arch-claude::before { border-top-style: solid; border-color: var(--cobalt-light); }

.arch-offline { border: 1px solid var(--line-dark); }

.arch-tag {
  margin-bottom: 8px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.arch-claude .arch-tag { color: var(--cobalt-ink); }
.arch-offline .arch-tag { color: var(--cobalt-light); }

.arch-ext h3 { font-size: 1.25rem; margin-bottom: 6px; }
.arch-claude p:not(.arch-tag) { font-size: 0.9375rem; color: var(--muted); }
.arch-offline p:not(.arch-tag) { font-size: 0.9375rem; color: var(--on-dark-muted); }

.arch-figure figcaption {
  margin-top: 28px;
  font-size: 0.875rem;
  color: var(--on-dark-muted);
}

@media (max-width: 900px) {
  .arch-diagram { grid-template-columns: 1fr; }
  .arch-links { padding-left: 0; padding-top: 40px; }
  .arch-ext::before { top: auto; bottom: 100%; right: auto; left: 40px; width: 0; height: 20px; border-top: 0; border-left: 2px dashed rgba(255, 255, 255, 0.5); }
  .arch-claude::before { border-left-style: solid; border-color: var(--cobalt-light); }
}

@media (max-width: 420px) {
  .arch-core { grid-template-columns: 1fr; }
}

/* ---------- Stage ---------- */

.timeline {
  position: relative;
  margin-top: clamp(40px, 5vw, 64px);
}

.timeline li {
  position: relative;
  padding: 0 0 40px 48px;
}

.timeline li:last-child { padding-bottom: 0; }

/* Rail */
.timeline li::before {
  content: "";
  position: absolute;
  left: 9px;
  top: 22px;
  bottom: -2px;
  border-left: 2px solid var(--line);
}

.timeline li:last-child::before { display: none; }

/* Node */
.timeline li::after {
  content: "";
  position: absolute;
  left: 0;
  top: 2px;
  width: 20px;
  height: 20px;
  box-sizing: border-box;
}

.timeline .is-done::after { background: var(--navy); }
.timeline .is-done::before { border-left-color: var(--navy); }
.timeline .is-next::after { background: var(--white); border: 2px solid var(--cobalt); box-shadow: inset 0 0 0 4px var(--white), inset 0 0 0 10px var(--cobalt); }
.timeline .is-later::after { background: var(--white); border: 2px dashed #9AA5BA; }

.timeline-state {
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}

.is-next .timeline-state { color: var(--cobalt-ink); }

.timeline h3 { font-size: clamp(1.25rem, 2.2vw, 1.625rem); margin-bottom: 8px; letter-spacing: -0.02em; }
.timeline p:not(.timeline-state) { color: var(--muted); max-width: 60ch; }

.timeline .is-next {
  padding-top: 24px;
  padding-bottom: 64px;
}

.timeline .is-next::after { top: 26px; }
.timeline .is-next::before { top: 46px; }

/* ---------- Footer ---------- */

.site-footer {
  padding-block: clamp(56px, 8vw, 96px) 48px;
  color: var(--on-dark-muted);
  background: var(--navy);
  border-top: 1px solid var(--line-dark);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 40px 64px;
}

.footer-brand img { width: 226px; margin-left: -10px; }

.footer-tagline {
  margin-top: 12px;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--white);
}

.footer-status {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
  font-size: 0.9375rem;
}

.footer-status .kernel-dot { background: var(--cobalt-light); }

.footer-nav ul { display: grid; gap: 4px; }

.footer-nav a {
  display: inline-block;
  padding: 6px 0;
  font-weight: 600;
  color: var(--white);
  text-decoration: none;
}

.footer-nav a:hover { text-decoration: underline; text-underline-offset: 4px; }

.footer-fine {
  grid-column: 1 / -1;
  display: grid;
  gap: 8px;
  padding-top: 28px;
  font-size: 0.8125rem;
  line-height: 1.6;
  border-top: 1px solid var(--line-dark);
}

.footer-fine a { color: var(--white); text-underline-offset: 3px; }

@media (max-width: 700px) {
  .footer-grid { grid-template-columns: 1fr; }
}

/* ---------- Motion & contrast preferences ---------- */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

@media (forced-colors: active) {
  .kernel-dot,
  .chain li:last-child h3::after { forced-color-adjust: none; }
  .flow-tabs [role="tab"][aria-selected="true"] { outline: 2px solid CanvasText; }
}
