/* 내부 도구 — 꾸밈보다 상태가 한눈에. 색은 상태를 말할 때만 쓴다. */
:root {
  --bg: #f5f6f8;
  --card: #fff;
  --ink: #1d2230;
  --ink2: #5b6275;
  --ink3: #8d93a3;
  --line: #e2e5ec;
  --brand: #3b6cf6;
  --brand-soft: #e9efff;
  --ok: #18915a;
  --ok-soft: #e2f5ea;
  --warn: #c27c00;
  --warn-soft: #fff1d9;
  --bad: #d23f3f;
  --bad-soft: #fde6e6;
  --muted-soft: #eef0f4;
  --add: #e3f6e8;
  --del: #fde8e8;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 14px/1.6 -apple-system, BlinkMacSystemFont, 'Apple SD Gothic Neo', 'Noto Sans KR', sans-serif;
}
a { color: var(--brand); text-decoration: none; }
a.ext { text-decoration: underline; text-underline-offset: 2px; }
button {
  font: inherit;
  cursor: pointer;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--ink);
  border-radius: 8px;
  padding: 6px 12px;
}
button:hover { border-color: var(--ink3); }
button.primary { background: var(--brand); border-color: var(--brand); color: #fff; }
button:disabled { opacity: 0.5; cursor: default; }
input, textarea, select {
  font: inherit;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 7px 10px;
  width: 100%;
  background: #fff;
  color: var(--ink);
}
textarea { resize: vertical; min-height: 64px; }
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 24px;
  background: var(--card);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 5;
}
.brand { font-weight: 800; color: var(--ink); font-size: 16px; }
.me { color: var(--ink2); font-size: 13px; }
.me button { margin-left: 8px; padding: 2px 8px; font-size: 12px; }
main { max-width: 1180px; margin: 0 auto; padding: 20px 24px 80px; }
h1 { font-size: 22px; margin: 4px 0 6px; }
h2 { font-size: 16px; margin: 0 0 8px; }
h3 { font-size: 14px; margin: 14px 0 6px; }
.muted { color: var(--ink2); }
.small { font-size: 12px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.stack > * + * { margin-top: 12px; }
.error { color: var(--bad); }

/* 상태 */
.badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.s-idea { background: var(--muted-soft); color: var(--ink2); }
.s-review { background: var(--brand-soft); color: var(--brand); }
.s-confirmed { background: var(--ok-soft); color: var(--ok); }
.s-implementing { background: var(--warn-soft); color: var(--warn); }
.s-implemented { background: var(--ok); color: #fff; }
.s-on_hold { background: var(--muted-soft); color: var(--ink3); }
.s-dropped { background: var(--muted-soft); color: var(--ink3); text-decoration: line-through; }

/* 3명의 체크 */
.votes { display: inline-flex; gap: 4px; }
.vote { font-size: 12px; padding: 2px 7px; border-radius: 6px; background: var(--muted-soft); color: var(--ink3); white-space: nowrap; }
.vote.agree { background: var(--ok-soft); color: var(--ok); }
.vote.changes { background: var(--warn-soft); color: var(--warn); }
.vote.reject { background: var(--bad-soft); color: var(--bad); }

/* 목록 */
.filters { margin: 10px 0 14px; }
.filters button.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.plans { display: grid; gap: 10px; }
.plan-card { display: grid; grid-template-columns: 1fr auto; gap: 6px 16px; cursor: pointer; }
.plan-card:hover { border-color: var(--ink3); }
.plan-card .title { font-weight: 700; font-size: 15px; }
.plan-card .meta { grid-column: 1 / -1; }

/* 상세 */
.detail { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 16px; align-items: start; }
.side { position: sticky; top: 64px; }
.section { scroll-margin-top: 70px; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.section-head h2 { margin: 0; }
.md p { margin: 6px 0; }
.md ul, .md ol { margin: 6px 0; padding-left: 22px; }
.md code { background: var(--muted-soft); padding: 1px 5px; border-radius: 4px; font-size: 12.5px; }
.md pre { background: #1f2430; color: #e6e9f0; padding: 10px 12px; border-radius: 8px; overflow-x: auto; font-size: 12.5px; }
.md pre code { background: none; padding: 0; color: inherit; }
.md table { border-collapse: collapse; width: 100%; margin: 8px 0; font-size: 13px; }
.md th, .md td { border: 1px solid var(--line); padding: 5px 8px; text-align: left; vertical-align: top; }
.md th { background: var(--muted-soft); }
.comments { margin-top: 10px; border-top: 1px dashed var(--line); padding-top: 8px; }
.comment { font-size: 13px; padding: 4px 0; }
.comment b { margin-right: 6px; }
.comment .old { color: var(--ink3); font-size: 11px; margin-left: 4px; }
.comment-box { display: flex; gap: 6px; margin-top: 6px; }
.comment-box textarea { min-height: 38px; }
.comment-box button { white-space: nowrap; align-self: flex-end; }
.issue { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; }
.issue + .issue { margin-top: 10px; }
.option { display: grid; grid-template-columns: 1fr auto; gap: 4px 10px; padding: 8px 0; border-top: 1px solid var(--line); }
.option:first-of-type { border-top: none; }
.option .label { font-weight: 700; }
.option .who { display: flex; gap: 4px; flex-wrap: wrap; justify-content: flex-end; align-items: center; align-self: start; }
.option.mine .label::after { content: ' · 내 선택'; color: var(--brand); font-size: 12px; font-weight: 600; }
.pick { font-size: 12px; padding: 3px 9px; }
.chip { display: inline-block; line-height: 1.6; font-size: 11.5px; padding: 1px 7px; border-radius: 999px; background: var(--brand-soft); color: var(--brand); }
.rec { font-size: 11px; color: var(--ok); font-weight: 700; margin-left: 6px; }
.proto { width: 100%; height: 620px; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
.vote-buttons { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.vote-buttons button.on.agree { background: var(--ok); border-color: var(--ok); color: #fff; }
.vote-buttons button.on.changes { background: var(--warn); border-color: var(--warn); color: #fff; }
.vote-buttons button.on.reject { background: var(--bad); border-color: var(--bad); color: #fff; }
.who-voted { display: grid; gap: 4px; margin-top: 8px; }
.who-voted div { display: flex; justify-content: space-between; font-size: 13px; }
.notice { padding: 10px 12px; border-radius: 10px; font-size: 13px; }
.notice.ok { background: var(--ok-soft); color: var(--ok); }
.notice.warn { background: var(--warn-soft); color: var(--warn); }
.notice.info { background: var(--brand-soft); color: var(--brand); }
.events { font-size: 12px; color: var(--ink2); max-height: 260px; overflow-y: auto; }
.events div { padding: 2px 0; }
.diff-line { white-space: pre-wrap; font-family: ui-monospace, Menlo, monospace; font-size: 12.5px; padding: 0 6px; }
.diff-line.add { background: var(--add); }
.diff-line.del { background: var(--del); text-decoration: line-through; color: var(--ink2); }
.toc a { display: block; font-size: 13px; padding: 1px 0; color: var(--ink2); }
.login { max-width: 380px; margin: 80px auto; }
.login label { display: block; margin-bottom: -6px; }
.guide code { background: var(--muted-soft); padding: 1px 5px; border-radius: 4px; }

/* Claude Code 창에 쓰는 말 */
.say { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; }
.say code { font-family: inherit; background: #1f2430; color: #e6e9f0; padding: 3px 8px; border-radius: 6px; font-size: 12.5px; white-space: normal; }
.say .copy { font-size: 11.5px; padding: 2px 8px; flex: none; }
.guide-box { margin: 10px 0 4px; }
.guide-box summary { cursor: pointer; }
.sayings { border-collapse: collapse; width: 100%; margin-top: 10px; }
.sayings th { text-align: left; font-weight: 600; color: var(--ink2); white-space: nowrap; padding: 6px 14px 6px 0; vertical-align: top; width: 1%; }
.sayings td { padding: 6px 0; border-top: 1px solid var(--line); }
.sayings tr:first-child td { border-top: none; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); border: 0; }

/* 층 — 큰그림 · 기능 기획 · 작은 일 */
.lv { display: inline-block; font-size: 11.5px; font-weight: 800; padding: 1px 7px; border-radius: 6px; margin-right: 4px; vertical-align: 2px; }
.lv-vision { background: #2b2f44; color: #fff; }
.lv-feature { background: var(--brand-soft); color: var(--brand); }
.lv-task { background: var(--muted-soft); color: var(--ink2); }
h1 .lv { font-size: 13px; vertical-align: 4px; }
.plan-card.child { border-left: 3px solid var(--line); }
h3.group { margin: 18px 0 8px; font-size: 14px; }
.child-row { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 6px 0; border-top: 1px solid var(--line); }
.child-row:first-of-type { border-top: none; }
