:root {
  --bg: #fbfaf7; --panel: #ffffff; --ink: #1f2328; --muted: #6b6f76; --line: #e3e0d8;
  --accent: #2f5d8a; --accent-soft: #e8eff6; --now: #1f2328; --past: #cfd6de; --machine: #8a6d2f;
  --machine-soft: #faf5ea; --back: #7a4f8a;
  /* 문서 내용 표: 바탕과 갈리되 튀지 않는 옅은 회청색 */
  --table-bg: #ffffff; --table-head: #edf1f5; --table-head-inner: #f5f7fa; --table-line: #d6dce3;
  --table-head-ink: #3a4350; --table-shadow: 0 1px 2px rgba(31, 35, 40, .06);
  /* 머리 메뉴 버튼: 표와 같은 회청색 계열 */
  --nav-bg: #f1f4f7; --nav-line: #d6dce3; --nav-ink: #3a4350; --nav-hover: #e3e9ef;
  /* 등록부의 여덟 상태·세 대기열: 왼쪽 옅게 → 오른쪽 짙게 (짙은 끝도 옅은 회청색에 머문다) */
  --step-1: #f5f8fb; --step-2: #eff3f8; --step-3: #e8eef5; --step-4: #e2eaf2;
  --step-5: #dce5ef; --step-6: #d5e0eb; --step-7: #cfdce8; --step-8: #c9d7e6; --step-line: #c3cfdc;
  font-family: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #16181b; --panel: #1e2125; --ink: #e7e9ec; --muted: #9aa0a6; --line: #33373d;
    --accent: #8db4dc; --accent-soft: #23303d; --now: #e7e9ec; --past: #3a4048; --machine: #d6b36a;
    --machine-soft: #2a261d; --back: #c39ad2;
    --table-bg: #1b1e22; --table-head: #262d35; --table-head-inner: #21272e; --table-line: #3a424c;
    --table-head-ink: #c3cad3; --table-shadow: 0 1px 2px rgba(0, 0, 0, .35);
    --nav-bg: #22282f; --nav-line: #3a424c; --nav-ink: #c3cad3; --nav-hover: #2b333c;
    --step-1: #1f2329; --step-2: #21272e; --step-3: #232a32; --step-4: #252d36;
    --step-5: #27303a; --step-6: #29333e; --step-7: #2b3642; --step-8: #2d3946; --step-line: #3a4552; }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); line-height: 1.55; font-size: 15px; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
.top { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; padding: 12px 20px;
  border-bottom: 1px solid var(--line); background: var(--panel); position: sticky; top: 0; z-index: 2; }
.brand { font-weight: 700; color: var(--ink); letter-spacing: .02em; font-size: 30px; line-height: 1; }  /* 본문(15px)의 두 배 */
.top nav { display: flex; gap: 6px; flex-wrap: wrap; }
/* 메뉴 하나하나를 버튼처럼: 옅은 회청색 바탕, 지금 화면은 강조색 테두리 */
.top nav a { display: inline-block; padding: 5px 11px; font-size: 13.5px; line-height: 1.4; color: var(--nav-ink);
  background: var(--nav-bg); border: 1px solid var(--nav-line); border-radius: 6px;
  transition: background-color var(--nav-speed, 120ms) ease, border-color var(--nav-speed, 120ms) ease; }
.top nav a:hover { background: var(--nav-hover); border-color: var(--past); }
.top nav a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.top nav a:active { transform: translateY(1px); }
.top nav a[aria-current="page"] { background: var(--accent-soft); border-color: var(--accent); color: var(--accent);
  font-weight: 600; }
@media (prefers-reduced-motion: reduce) { .top nav a { transition: none; } .top nav a:active { transform: none; } }
.seat { margin-left: auto; color: var(--muted); font-size: 13px; }
.who { font-size: 13px; margin-left: 12px; }
main { max-width: 1180px; margin: 0 auto; padding: 20px 16px 60px; }
h1 { font-size: 20px; margin: 4px 0 12px; }
h2 { font-size: 15px; margin: 22px 0 8px; color: var(--muted); font-weight: 600; }
.card { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 14px 16px; margin: 10px 0; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.grid { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 20px; }
@media (max-width: 900px) { .grid { grid-template-columns: 1fr; } }
.firstline { display: flex; gap: 22px; flex-wrap: wrap; font-size: 15px; }
.firstline b { font-weight: 700; }
.ribbon { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 4px; margin: 14px 0; }
.ribbon div { padding: 8px 4px; text-align: center; font-size: 12px; border-radius: 4px; border: 1px solid var(--line);
  cursor: default; user-select: none; }
.ribbon .지난 { background: var(--past); }
.ribbon .지금 { background: var(--now); color: var(--bg); font-weight: 700; }
.ribbon .back { display: block; font-size: 11px; color: var(--back); }
.ribbon .지금 .back { color: var(--bg); }
@media (max-width: 640px) { .ribbon { grid-template-columns: repeat(4, 1fr); } }
.timeline { border-left: 2px solid var(--line); margin-left: 6px; padding-left: 16px; }
.tl { margin: 0 0 14px; }
.tl .when { font-size: 12px; color: var(--muted); }
.tl.backward .move { color: var(--back); }
details summary { cursor: pointer; color: var(--muted); font-size: 13px; }
pre, textarea { font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; }
pre { white-space: pre-wrap; word-break: break-word; background: var(--bg); padding: 10px; border-radius: 6px; margin: 6px 0; }
textarea { width: 100%; min-height: 260px; background: var(--bg); color: var(--ink); border: 1px solid var(--line);
  border-radius: 6px; padding: 10px; }
input, select { font: inherit; color: var(--ink); background: var(--panel); border: 1px solid var(--line);
  border-radius: 6px; padding: 6px 8px; }
button { font: inherit; border: 1px solid var(--accent); background: var(--accent-soft); color: var(--accent);
  border-radius: 6px; padding: 6px 12px; cursor: pointer; }
.errors { color: var(--back); margin: 6px 0; padding-left: 18px; }
.ok { color: var(--accent); }
.reference { background: var(--machine-soft); border: 1px dashed var(--machine); border-radius: 8px; padding: 12px 14px;
  align-self: start; position: sticky; top: 70px; }
.reference h3 { margin: 0 0 4px; font-size: 14px; color: var(--machine); }
.reference .item { border-top: 1px dashed var(--line); padding: 8px 0; font-size: 13.5px; }
.tag { display: inline-block; font-size: 11.5px; padding: 1px 7px; border: 1px solid var(--line); border-radius: 10px;
  margin: 2px 4px 2px 0; color: var(--muted); }
.kind-see { color: var(--accent); } .kind-rid_candidate { color: var(--machine); } .kind-temporal_conflict { color: var(--back); }
table { border-collapse: collapse; width: 100%; font-size: 13.5px; }
th, td { border-bottom: 1px solid var(--line); padding: 6px 8px; text-align: left; vertical-align: top; }
th { color: var(--muted); font-weight: 600; white-space: nowrap; }  /* 머리글이 글자 단위로 갈라지지 않게 */
.cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 800px) { .cols { grid-template-columns: 1fr; } }
.states { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 6px; }
@media (max-width: 800px) { .states { grid-template-columns: repeat(2, 1fr); } }
.states .col { border: 1px solid var(--line); border-radius: 6px; padding: 8px; background: var(--panel); min-height: 70px; }
.states .col .n { font-size: 13px; color: var(--table-head-ink); }
.states .col:nth-child(1) { background: var(--step-1); }
.states .col:nth-child(2) { background: var(--step-2); }
.states .col:nth-child(3) { background: var(--step-3); }
.states .col:nth-child(4) { background: var(--step-4); }
.states .col:nth-child(5) { background: var(--step-5); }
.states .col:nth-child(6) { background: var(--step-6); }
.states .col:nth-child(7) { background: var(--step-7); }
.states .col:nth-child(8) { background: var(--step-8); }
.states .col { border-color: var(--step-line); }
.queues > .card { border-color: var(--step-line); }
.queues > .card:nth-child(1) { background: var(--step-1); }
.queues > .card:nth-child(2) { background: var(--step-4); }
.queues > .card:nth-child(3) { background: var(--step-8); }
.queues > .card .muted { color: var(--table-head-ink); }
.tree { list-style: none; padding-left: 16px; border-left: 1px solid var(--line); margin: 4px 0; }
.tree li { margin: 6px 0; }
.edge.closed { color: var(--muted); text-decoration: line-through; }
.row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }

/* 전이 문서 칸별 입력 */
.docform { display: grid; gap: 12px; margin: 8px 0 12px; }
.field { display: grid; gap: 4px; }
.flabel b { font-weight: 600; }
.req { color: var(--accent); font-size: 12px; }
.req-when { color: var(--muted); }
.field.needed .req-when { color: var(--accent); font-weight: 600; }
.ftext { width: 100%; }
textarea.ftext { min-height: 0; font-family: inherit; font-size: 14px; }
fieldset.obj { border: 1px solid var(--line); border-radius: 6px; padding: 8px 12px 12px; display: grid; gap: 10px; margin: 0; }
fieldset.obj legend { color: var(--muted); font-size: 13px; padding: 0 4px; }
.list { display: grid; gap: 6px; }
.list-row { display: flex; gap: 6px; align-items: flex-start; }
.list-row > :first-child { flex: 1; }
.checks { display: flex; flex-direction: column; gap: 3px; font-size: 14px; }
button.ghost { background: transparent; border-color: var(--line); color: var(--muted); padding: 4px 10px; font-size: 13px; }
.machine { background: var(--machine-soft); border: 1px dashed var(--machine); border-radius: 6px; padding: 6px 8px; }
.machine:empty { display: none; }
.confirm { border: 1px solid var(--accent); border-radius: 8px; padding: 10px 14px; margin-top: 10px; }
/* 문서 내용의 표: 칸 이름 | 적은 내용 */
table.doc-table { margin: 6px 0; font-size: 14px; border: 1px solid var(--table-line); background: var(--table-bg);
  border-radius: 6px; border-collapse: separate; border-spacing: 0; overflow: hidden; box-shadow: var(--table-shadow); }
table.doc-table > tbody > tr > th, table.doc-table > tbody > tr > td { border-bottom: 1px solid var(--table-line); }
table.doc-table th { width: 30%; min-width: 110px; white-space: normal; background: var(--table-head);
  color: var(--table-head-ink);
  border-right: 1px solid var(--table-line); }
table.doc-table td { word-break: break-word; }
table.doc-table tr:last-child > th, table.doc-table tr:last-child > td { border-bottom: 0; }
table.doc-table table.doc-table { margin: 0; font-size: 13.5px; box-shadow: none; }
table.doc-table table.doc-table th { background: var(--table-head-inner); }
table.doc-table td > div > table.doc-table + table.doc-table { margin-top: 6px; }
table.doc-table ul { margin: 0; padding-left: 18px; }
.fnum { width: 90px; }
.step .row { margin-bottom: 4px; }
.gap { color: var(--muted); border-left: 3px solid var(--line); padding: 2px 8px; margin: 4px 0; }
.machine-tl { color: var(--machine); }
.machine-tl .when { color: var(--muted); }
.decide { margin-top: 4px; }
.decide input { max-width: 120px; }
.decide input[style] { max-width: none; margin-top: 4px; }
.notices { margin: -6px 0 12px; display: grid; gap: 2px; }
td.edge.closed, td.small { white-space: pre-line; }

/* 표시(보류·인계·취하·파생 쟁점): 문서와 달리 상태를 옮기지 않으므로 이력에서 점선으로 둔다 */
.tl.mark-tl { border-left-style: dotted; }
.notices.machine { border-style: dashed; }

/* 등록 양식의 빈 자리 (결정 D4): 형태 검사이므로 경고가 아니라 메모로 둔다 */
.notices.gaps { border-style: dashed; }

/* 역할별 홈 (화면 3·4·5). 어느 칸도 누를 수 없는 표시이며 점수·순위를 만들지 않는다 */
.ribbon.mini { grid-template-rows: none; margin: 6px 0; }
.ribbon.mini > div { height: 10px; padding: 0; font-size: 0; }
.ribbon.mini .back { font-size: 10px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.qcard { display: grid; gap: 4px; }

/* 규제 개선 건의 (화면 10): 카드 안에 들어가는 알림 줄은 위로 끌어올리지 않는다 */
.card .notices { margin: 8px 0 0; }

/* 등록부의 적체 칸에서 표시가 붙은 줄. 재촉이 아니므로 경고색을 쓰지 않는다 */
.states .marked { opacity: 0.75; }

/* 인계 자료 (화면 11): 그래프에 새로 붙은 것 */
ul.grew { margin: 4px 0; padding-left: 18px; font-size: 13px; }
ul.grew li { margin: 1px 0; }

/* 조문에 붙는 이력 한 줄 (부록 D-10). 성적표가 아니라 정비의 순서를 정하는 자리가 읽는 줄이다 */
.card.ledger { border-left: 3px solid var(--line); }
.card.ledger .row { align-items: baseline; }

/* 표 27 — 남지 않은 줄도 함께 보인다 (p.95) */
table.left-behind tr.empty-row td { color: var(--muted); }

/* 참고 영역의 '아래' 목록 — 실제 법령에서는 대여섯 개가 붙는다. 한 줄에 하나씩 둔다 */
.reference .down { padding: 2px 0 2px 10px; border-left: 2px solid var(--line); margin: 2px 0; }
/* 총칙 조항(목적·정의)은 늘 걸린다. 뒤로 보내고 흐리게 둘 뿐, 숨기지 않는다 */
.reference .down.housekeeping { color: var(--muted); }

a.button { display: inline-block; padding: 4px 10px; border: 1px solid var(--line); border-radius: 6px; text-decoration: none; }
.claim-box { border-left: 3px solid var(--accent, #3b6ea5); }
.not-mine { opacity: 0.75; border-style: dashed; }

/* 누가 쓸 차례인가 (결정 D44) */
.turn { border-left: 4px solid var(--accent); background: var(--accent-soft); }
.turn-title { font-weight: 700; margin-bottom: 6px; }
.turn-row { margin: 4px 0; }
.turn-mine { color: #1f7a3a; font-weight: 700; }
.turn-other { color: #9a5b00; }
.tag.seat { background: var(--accent); color: #fff; border-color: var(--accent); }
.writer { font-weight: 600; color: var(--accent); }
.me-chip { background: var(--accent-soft); border: 1px solid var(--accent); border-radius: 999px; padding: 2px 10px; }
.warn-seat { color: #b3261e; margin-top: 4px; }
input[readonly] { background: var(--accent-soft); }
.demo-switch { font-size: 12px; }
.writer-banner { background: var(--accent-soft); border-left: 3px solid var(--accent); padding: 6px 10px; margin: 6px 0 10px; border-radius: 4px; font-size: 13.5px; }
button.ghost.listening { border-color: #c0392b; color: #c0392b; background: transparent; }

/* ── 그래프 (온톨로지) ── 노드 색은 무리(클래스), 선 색은 출처. 점선은 기계뿐 */
:root {
  --g-rule: #2f5d8a; --g-service: #2e7d6b; --g-rid: #b5532f; --g-doc: #6b6f76; --g-person: #7a4f8a;
  --g-notice: #8a5a2f; --g-domain: #4f7a2f; --g-observed: #2f7a8a; --g-term: #9a8a5a; --g-entity: #a8326e; --g-umbrella: #6b6f76; --g-vocab: #8a7a2f;
  --o-statute: #2f5d8a; --o-human: #3a4350; --o-observed: #2f7a8a; --o-machine: #8a6d2f;
}
@media (prefers-color-scheme: dark) {
  :root {
    --g-rule: #6f9cc9; --g-service: #5fb39f; --g-rid: #d98a69; --g-doc: #9aa0a6; --g-person: #b48cc4;
    --g-notice: #c99a69; --g-domain: #8fbf69; --g-observed: #69b3c4; --g-term: #c4b585; --g-entity: #e07aac; --g-umbrella: #9aa0a6; --g-vocab: #c4b070;
    --o-statute: #8db4dc; --o-human: #c3cad3; --o-observed: #69b3c4; --o-machine: #d6b36a;
  }
}
.tabs { display: flex; gap: 4px; margin: 8px 0 10px; border-bottom: 1px solid var(--line); }
.tabs .tab { padding: 6px 14px; border: 1px solid transparent; border-bottom: none; border-radius: 6px 6px 0 0;
  text-decoration: none; color: var(--muted); margin-bottom: -1px; }
.tabs .tab:hover { color: var(--ink); background: var(--nav-hover); }
.tabs .tab.on { color: var(--ink); background: var(--panel); border-color: var(--line); font-weight: 600; }
.graph-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; margin: 8px 0; color: var(--muted); }
.legend-item { display: inline-flex; align-items: center; gap: 5px; }
.legend-item .dot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }
.legend-item .line { width: 24px; height: 0; border-top: 2.5px solid; display: inline-block; }
.legend-item .line.dashed { border-top-style: dashed; }
.legend-sep { width: 1px; height: 14px; background: var(--line); }
.graph-wrap { display: flex; gap: 12px; align-items: stretch; }
.graph-canvas { flex: 1; min-width: 0; height: 68vh; min-height: 420px; background: var(--panel);
  border: 1px solid var(--line); border-radius: 8px; }
.graph-canvas.tall { height: 78vh; }
.graph-side { width: 300px; flex-shrink: 0; max-height: 68vh; overflow: auto; margin: 0; }
.graph-side h3 { margin: 2px 0 6px; }
.graph-side blockquote { margin: 6px 0; padding-left: 8px; border-left: 3px solid var(--line); color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 3px; }
@media (max-width: 800px) {
  .graph-wrap { flex-direction: column; }
  .graph-side { width: auto; max-height: none; }
  .graph-canvas { height: 60vh; min-height: 340px; }
}
.live-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--g-service); display: inline-block;
  animation: live-pulse 1.6s ease-in-out infinite; }
@keyframes live-pulse { 50% { opacity: .25; } }
@media (prefers-reduced-motion: reduce) { .live-dot { animation: none; } }

/* 질문하기의 차례 (질문 → 서비스 → 쟁점 후보 → 끝). 점수가 아니라 지금 어디인가만 보인다 */
.stepper { display: flex; gap: 0; list-style: none; padding: 0; margin: 8px 0 14px; counter-reset: st; flex-wrap: wrap; }
.stepper li { counter-increment: st; padding: 4px 14px 4px 10px; font-size: 13px; color: var(--muted); border-bottom: 2px solid var(--line); }
.stepper li::before { content: counter(st) " "; font-weight: 700; }
.stepper li.done { color: var(--ink, inherit); border-bottom-color: var(--muted); }
.stepper li.now { color: var(--accent); border-bottom-color: var(--accent); font-weight: 700; }
/* 쓰는 법 — 가운데 본문의 단계 목록 */
/* 왼쪽 보조 메뉴 — RoRop 아래: 그래프 · 누가 쓰나 · 쓰는 법. 머리 메뉴와 같은 단추 모양 */
.side { display: flex; flex-direction: column; gap: 6px; }
.side a, .side .manual-toggle { display: block; text-align: left; padding: 6px 11px; font-size: 13.5px; line-height: 1.4;
  color: var(--nav-ink); background: var(--nav-bg); border: 1px solid var(--nav-line); border-radius: 6px; font-weight: 400; }
.side a:hover, .side .manual-toggle:hover { background: var(--nav-hover); border-color: var(--past); text-decoration: none; }
.side a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.side a[aria-current="page"] { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); font-weight: 600; }
.side .manual-toggle[aria-expanded="true"] { border-color: var(--past); font-weight: 600; }
/* 넓은 화면: 머리 아래 왼쪽(RoRop 밑)에 붙고 본문은 그 오른쪽. 좁은 화면: 본문 위 한 줄 */
/* '쓰는 법' 아래로 펼쳐지는 참여자 목록 — 들여 써서 하위 메뉴임을 보인다 */
.side-sub { display: flex; flex-direction: column; gap: 2px; margin: 0 0 0 10px; padding-left: 8px; border-left: 2px solid var(--nav-line); }
.side-sub[hidden] { display: none; }
.side .side-sub a { padding: 3px 8px; font-size: 12.5px; background: none; border-color: transparent; }
.side .side-sub a.mine::after { content: " ●"; font-size: 9px; vertical-align: 2px; }
.side .manual-toggle { width: 100%; cursor: pointer; }
.side .manual-toggle::after { content: " ▸"; color: var(--muted); }
.side .manual-toggle[aria-expanded="true"]::after { content: " ▾"; }
@media (min-width: 1100px) {
  .side { position: fixed; left: 20px; top: calc(var(--top-h, 64px) + 20px); width: 160px; z-index: 1; }
  main { margin-left: max(200px, calc((100% - 1180px) / 2)); }  /* 사이드바를 비켜서, 넓으면 가운데 */
}
@media (max-width: 1099px) { .side { flex-direction: row; flex-wrap: wrap; padding: 10px 16px 0; } }
/* 동작 원리 — 단계별 흐름도. 사람은 실선, 기계는 점선 (원칙 6) */
.how-legend { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 0 0 18px; color: var(--muted); }
.how-actor { display: inline-block; font-size: 11.5px; padding: 1px 8px; border-radius: 10px; white-space: nowrap; }
.how-actor.how-human { border: 1.5px solid var(--accent); color: var(--accent); }
.how-actor.how-machine { border: 1.5px dashed var(--machine); color: var(--machine); background: var(--machine-soft); }
.how-issues, .how-links { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 4px; }
.how-issue { border-style: dashed; border-color: var(--machine); color: var(--machine); }
/* SID-RID 관계 — 왼쪽 서비스, 오른쪽 쟁점. 제기는 파랑, 연결은 보라 (결정 D63) */
/* SID-RID 관계 맨 위: 한 장의 그림 — 질의(사람) → 시스템 → SID → 총괄 확정 → 시스템 → RID 여럿 (sidrid.js flow) */
.sf { margin: 4px 0 22px; max-width: 1200px; }
.sf-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: 14px; background: var(--panel); box-shadow: var(--shadow-up); }
.sf-svg { display: block; width: 100%; min-width: 780px; height: auto; font-family: inherit; }
.sf-svg text { fill: var(--ink); }
.sf-person { fill: var(--accent); }
/* 참여자마다 색 — 같은 사람은 그림 어디서나 같은 색 */
.sf-p-designer { fill: var(--accent); }
.sf-p-coord { fill: var(--navy); }
.sf-p-owner { fill: var(--st-7); }
.sf-p-responder { fill: var(--back); }
.sf-p-standards { fill: var(--st-4); }
.sf-p-policy { fill: var(--fig-policy); }
.sf-p-steward { fill: var(--fig-steward); }
.sf-p-plain { fill: var(--muted); }
.sf-p-admin { fill: var(--fig-admin); }
.sf-svg-how { min-width: 900px; }
.sf-sec { font-size: 15px; font-weight: 800; fill: var(--muted) !important; letter-spacing: .02em; }
.sf-state-t { font-size: 13.5px; font-weight: 700; fill: #fff !important; }
.sf-bracket { fill: none; stroke: var(--muted); stroke-width: 1.5; }
.sf-propose { fill: none; stroke: var(--accent); stroke-width: 2; stroke-dasharray: 6 5; }
.sf-propose-t { font-size: 12.5px; font-weight: 700; fill: var(--accent-strong) !important; }
.sf-arrow-t { font-size: 13px; font-weight: 700; fill: var(--navy) !important; }
.sf-loop { fill: none; stroke: var(--st-8); stroke-width: 2; stroke-dasharray: 7 5; }
.sf-sensor { fill: var(--machine); }
.sf-sensor-wave { fill: none; stroke: var(--machine); stroke-width: 2; }
.sf-who { font-size: 15px; font-weight: 700; }
.sf-cap { font-size: 14px; font-weight: 700; fill: var(--accent-strong) !important; }
.sf-cap-s { font-size: 12.5px; fill: var(--muted) !important; }
.sf-bubble { fill: var(--accent-soft); stroke: var(--accent); stroke-width: 1.5; }
.sf-say { font-size: 14.5px; }
.sf-arrow { fill: none; stroke: var(--muted); stroke-width: 2.2; }
.sf-head { fill: var(--muted); }
.sf-link { stroke: var(--navy); stroke-width: 2; }
.sf-sys { fill: var(--machine-soft); stroke: var(--machine); stroke-width: 2; stroke-dasharray: 7 5; }
.sf-gear { font-size: 34px; fill: var(--machine) !important; }
.sf-sys-t { font-size: 16px; font-weight: 700; fill: var(--machine) !important; }
.sf-sys-s { font-size: 12.5px; fill: var(--muted) !important; }
.sf-sid-box { fill: var(--panel); stroke: var(--accent); stroke-width: 2; }
.sf-sid-fold { fill: var(--accent-soft); stroke: var(--accent); stroke-width: 1.5; }
.sf-sid-code { font-size: 15px; font-weight: 800; fill: var(--accent-strong) !important; }
.sf-sid-name { font-size: 12px; fill: var(--muted) !important; }
.sf-sid-step { font-size: 12.5px; }
.sf-ok { fill: var(--accent); }
.sf-ok-t { font-size: 18px; font-weight: 800; fill: #fff !important; text-anchor: middle; }
.sf-rid-box { fill: var(--panel); stroke: var(--accent); stroke-width: 1.8; }
.sf-rid-code { font-size: 14px; font-weight: 800; fill: var(--accent-strong) !important; }
.sf-rid-q { font-size: 12px; fill: var(--muted) !important; }
.sf-rid-more { fill: none; stroke: var(--line); stroke-width: 1.5; stroke-dasharray: 5 4; }
.sf figcaption { margin-top: 10px; color: var(--muted); display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.sf-key { display: inline-block; width: 22px; height: 0; border-top: 2px solid var(--accent); margin-right: 2px; }
.sf-key-m { border-top: 2px dashed var(--machine); }
.sf-key-p { border-top: 2px dashed var(--accent); }
.sr-points { margin: 6px 0 12px; padding-left: 20px; max-width: 900px; }
.sr-points li { margin: 3px 0; }
.sr-card { max-width: 800px; overflow-x: auto; }
.sr-svg { display: block; min-width: 560px; font-size: 12.5px; }
.sr-node rect { fill: var(--panel); stroke: var(--step-line); stroke-width: 1.2; }
.sr-sid rect { fill: var(--step-2); }
.sr-rid rect { fill: var(--accent-soft); stroke: var(--accent); }
.sr-node text { fill: var(--ink); }
.sr-id { font-weight: 700; }
.sr-edge { fill: none; stroke-width: 2; }
.sr-edge.sr-open { stroke: var(--accent); }
.sr-edge.sr-link { stroke: var(--back); stroke-dasharray: none; }
.sr-legend { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 8px 0; color: var(--muted); }
.sr-key { display: inline-block; padding: 0 8px; border-radius: 10px; font-weight: 600; border-bottom: 3px solid; }
.sr-key.sr-open { color: var(--accent); border-color: var(--accent); }
.sr-key.sr-link { color: var(--back); border-color: var(--back); }
.sr-edge.sr-merge { stroke: var(--ink); stroke-width: 2.5; }
.sr-key.sr-merge { color: var(--ink); border-color: var(--ink); }
.linked-services { margin: -4px 0 10px; }
.linked-services .tag { margin-left: 3px; }
.sr-merged rect { stroke: var(--back); stroke-width: 2.5; fill: var(--accent-soft); }
.sr-note { margin-top: 8px; max-width: 760px; }

/* 쟁점 병합 (결정 D64) */
.merge-form { display: grid; gap: 6px; }
.merge-form input, .merge-form textarea { width: 100%; box-sizing: border-box; font: inherit; }
.merged-line .sr-alias { font-weight: 600; }

.sr-qtable { margin: 10px 0; width: 100%; }
.sr-qtable td:first-child { white-space: nowrap; }

/* 온톨로지 그래프 (결정 D171·D173): 흰 바탕, 클래스 색의 구 범례, 전체 화면 */
.graph-canvas.owl-canvas { height: max(460px, calc(100vh - 340px)); }
.graph-wrap:has(.owl-canvas) .graph-side { max-height: max(460px, calc(100vh - 340px)); }
.owl-canvas { border-radius: 14px; border-color: var(--line); background: var(--panel); box-shadow: var(--shadow); }  /* 흰 바탕 (D173) */
.owl-legend { display: flex; flex-direction: column; gap: 6px; margin: 8px 0 10px; }
.owl-legend-row { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; }
.owl-legend .oc-orb { width: 14px; height: 14px; border-radius: 50%; display: inline-block;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--line) 60%, transparent); }
.owl-legend .lg-hex { width: 14px; height: 13px; display: inline-block; background: color-mix(in srgb, var(--oc-rule) 35%, var(--panel));
  clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%); }
.owl-legend .lg-board { width: 22px; height: 12px; display: inline-block; border-radius: 3px;
  border: 1.6px solid var(--oc-issue); background: color-mix(in srgb, var(--oc-issue) 45%, var(--panel)); }
.owl-legend .lg-value { width: 22px; height: 11px; display: inline-block; border-radius: 6px;
  border: 1.2px solid color-mix(in srgb, var(--oc-issue) 70%, var(--panel)); background: color-mix(in srgb, var(--oc-issue) 10%, var(--panel)); }
.graph-wrap:fullscreen, .graph-wrap.max { background: var(--bg); padding: 14px; gap: 14px; }
.graph-wrap.max { position: fixed; inset: 0; z-index: 1000; }
.graph-wrap.max .graph-canvas.owl-canvas, .graph-wrap.max .graph-side { height: calc(100vh - 28px); max-height: calc(100vh - 28px); }
.graph-wrap:fullscreen .graph-canvas { height: calc(100vh - 28px); }
.graph-wrap:fullscreen .graph-side { max-height: calc(100vh - 28px); }

/* 내 서비스 진행 (결정 D177) — 막대는 여덟 단계 중 지금 칸, 고리는 RID 평균 */
.dp-panel { margin: 28px 0 8px; }
.dp-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(480px, 100%), 1fr)); gap: 14px; margin-top: 12px; align-items: start; }
.dp-card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px 18px; }
.dp-card-head { display: flex; gap: 16px; align-items: center; }
.dp-kicker { color: var(--muted); letter-spacing: .02em; }
.dp-sid { margin: 2px 0 4px; font-size: 1.1rem; }
.dp-ring { --size: 76px; flex: none; width: var(--size); height: var(--size); border-radius: 50%; display: grid; place-items: center;
  background: conic-gradient(var(--st-8) calc(var(--p) * 1%), var(--line) 0); position: relative; }
.dp-ring::before { content: ""; position: absolute; inset: 9px; border-radius: 50%; background: var(--panel); }
.dp-ring span { position: relative; font-weight: 700; font-size: 1.05rem; color: var(--ink); }
.dp-rids { display: grid; gap: 8px; margin-top: 14px; border-top: 1px solid var(--line); padding-top: 12px; }
.dp-rid { display: block; color: inherit; text-decoration: none; padding: 8px 10px; border-radius: 8px; }
.dp-rid:hover, .dp-rid:focus-visible { background: var(--accent-soft); }
.dp-rid-head { display: flex; gap: 8px; align-items: baseline; min-width: 0; }
.dp-rid-draft { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.dp-rid-bar { display: flex; align-items: center; gap: 10px; margin-top: 6px; flex-wrap: wrap; }
.dp-ticks { display: grid; grid-template-columns: repeat(8, 1fr); gap: 3px; flex: 1 1 220px; min-width: 160px; }
.dp-ticks span { height: 10px; border-radius: 3px; background: var(--line); }
.dp-ticks span.on { background: var(--c); }
.dp-pct { font-weight: 700; min-width: 3.2em; text-align: right; font-variant-numeric: tabular-nums; }
.dp-state { font-size: .85rem; padding: 2px 8px; border-radius: 999px; color: var(--c); border: 1px solid var(--c); }
.dp-fold { margin-top: 12px; }
.dp-fold > summary { cursor: pointer; color: var(--accent); }
.dp-fold .dp-rids { margin-top: 8px; }

/* 쟁점 책임자별 단계 (결정 D178) — 버튼은 이름 차례, 수를 붙이지 않는다 */
.db-owner-btns { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.db-owner-btn { padding: 6px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel); color: var(--ink); cursor: pointer; font: inherit; }
.db-owner-btn:hover { border-color: var(--accent); background: var(--accent-soft); }
.db-owner-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.db-owner-btn[aria-pressed="true"] { background: var(--navy); border-color: var(--navy); color: #fff; font-weight: 600; }
.db-owner-view { display: grid; grid-template-columns: minmax(200px, 260px) 1fr; gap: 6px 24px; align-items: start; }
.db-owner-head { display: flex; align-items: center; gap: 10px; grid-column: 1 / -1; }
.db-owner-facts { flex-direction: column; align-self: center; }
.db-owner-facts .db-fact { grid-template-columns: auto 1fr; justify-items: start; align-items: baseline; gap: 10px; background: var(--bg); border-color: var(--line); color: var(--ink); }
.db-owner-facts .db-fact span { color: var(--muted); font-size: 13px; }
.db-owner-facts .db-fact b { font-size: 24px; }
.db-owner-rids { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px 10px; }
@media (max-width: 720px) { .db-owner-view { grid-template-columns: 1fr; } .db-owner-facts { flex-direction: row; } }
.db-owner-view .db-chart { max-width: 620px; width: 100%; }
