/* 分かれ道の図の部品（ai-guide.html・security-guide.html で共有）
   2026-10-09、両ページで同じだった指定をここへ移した。各ページだけの部品は、そのページの <style> に残している */

body { line-height: 1.75; }
.wrap { --wrap-max: 980px; }
.dest .name, .ans b { word-break: auto-phrase; overflow-wrap: anywhere; }

/* ページの見出し */
.page-head { padding-block: 40px 28px; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 0.72rem; font-weight: 500; letter-spacing: 0.16em;
  color: var(--mono); text-transform: uppercase; margin: 0 0 14px;
}
.eyebrow::before { content: "//"; opacity: 0.6; }
.page-head h1 { font-size: clamp(1.7rem, 4.6vw, 2.3rem); font-weight: 700; line-height: 1.45; margin: 0 0 12px; }
.page-head .copy { color: var(--ink-soft); font-size: 1rem; margin: 0 0 10px; max-width: 46em; }
.page-head .meta { color: var(--ink-faint); font-size: 0.78rem; margin: 0; font-variant-numeric: tabular-nums; }

/* はじめに */
.about {
  border: 1px solid var(--teal);
  border-radius: 8px;
  background: color-mix(in srgb, var(--bg-raised) 85%, transparent);
  padding: 16px 20px 18px;
  margin-bottom: 36px;
}
.about h2 { font-size: 0.95rem; margin: 0 0 6px; }
.about ul { margin: 0; padding-left: 1.2em; font-size: 0.92rem; display: flex; flex-direction: column; gap: 2px; }

/* 道 */
.flow { display: flex; flex-direction: column; }
.q {
  background: var(--band-bg);
  color: var(--band-fg);
  border-radius: 8px;
  padding: 14px 20px 16px;
  display: flex; flex-direction: column; gap: 2px;
}
.q .no { font-size: 0.72rem; letter-spacing: 0.14em; color: var(--band-sub); }
.q h2 { color: var(--band-fg); font-size: clamp(1.1rem, 2.6vw, 1.35rem); margin: 0; line-height: 1.5; }
.q .hint { margin: 0; font-size: 0.86rem; color: var(--band-sub); }

.branches {
  list-style: none; margin: 0; padding: 18px 0 0;
  display: grid; grid-template-rows: auto auto auto;
  position: relative;
}
.branches.n2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.branches.n3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.branches.n4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.branches::before {
  content: ""; position: absolute; top: 0; left: calc(50% - 1px);
  width: 2px; height: 18px; background: var(--rail);
}
.branch {
  position: relative;
  display: grid; grid-template-rows: subgrid; grid-row: span 3;
  padding: 20px 7px 0; min-width: 0;
}
.branch::before {
  content: ""; position: absolute; top: 0; left: calc(50% - 1px);
  width: 2px; height: 20px; background: var(--rail);
}
.branch::after {
  content: ""; position: absolute; top: 0; left: 0; right: 0;
  height: 2px; background: var(--rail);
}
.branch:first-child::after { left: calc(50% - 1px); }
.branch:last-child::after { right: calc(50% - 1px); }

.ans {
  margin: 0;
  border: 1.5px solid var(--rail);
  border-radius: 6px;
  background: var(--bg);
  padding: 10px 12px;
  display: flex; flex-direction: column; gap: 2px; min-width: 0;
}
.ans b { font-size: 0.97rem; line-height: 1.5; }
.ans span { font-size: 0.83rem; color: var(--ink-soft); line-height: 1.6; }
.stem { justify-self: center; position: relative; width: 2px; height: 26px; background: var(--rail); }
.stem::after {
  content: ""; position: absolute; bottom: 0; left: -5px;
  border-left: 6px solid transparent; border-right: 6px solid transparent;
  border-top: 9px solid var(--rail);
}
.dest {
  background: var(--dest-bg);
  border: 1.5px solid var(--leaf);
  border-radius: 6px;
  padding: 10px 14px 12px;
  display: flex; flex-direction: column; gap: 2px; min-width: 0;
}
.dest .tagline { font-size: 0.7rem; letter-spacing: 0.08em; color: var(--leaf-text); font-weight: 700; }
.dest .name { font-family: var(--font-head); font-size: 1.15rem; font-weight: 700; line-height: 1.4; }
.dest .why { font-size: 0.86rem; line-height: 1.6; }
.dest.end, .dest.go { background: var(--end-bg); border-color: var(--rail); }
.dest.end .tagline, .dest.go .tagline { color: var(--ink-soft); }

.next { display: flex; flex-direction: column; align-items: center; gap: 4px; padding-top: 8px; }
.next .txt { font-size: 0.83rem; color: var(--ink-soft); text-align: center; }
.next .stem { height: 30px; }

section.block { padding-block: 44px; border-top: 1px solid var(--border); }
h2.section-title { margin: 0 0 12px; font-size: 1.2rem; font-weight: 700; }
.note { margin: 0 0 16px; font-size: 0.86rem; color: var(--ink-soft); max-width: 48em; }

/* 一覧 */
.scroll { overflow-x: auto; border: 1px solid var(--border); border-radius: 8px; background: color-mix(in srgb, var(--bg-raised) 85%, transparent); }
table { border-collapse: collapse; width: 100%; min-width: 760px; font-size: 0.88rem; }
th, td { padding: 10px 12px; border-bottom: 1px solid var(--border); vertical-align: top; text-align: left; }
thead th { font-size: 0.74rem; letter-spacing: 0.06em; color: var(--ink-faint); font-weight: 500; white-space: nowrap; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: none; }
tbody th { font-weight: 700; white-space: nowrap; }
td.num { font-variant-numeric: tabular-nums; }

/* 守ること・今日できる3つ */
.promises { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.promises li {
  border: 1px solid var(--border); border-radius: 8px;
  background: color-mix(in srgb, var(--bg-raised) 85%, transparent);
  padding: 16px 18px; display: flex; flex-direction: column; gap: 6px; min-width: 0;
}
.promises b { font-size: 0.98rem; line-height: 1.5; }
.promises span { font-size: 0.86rem; color: var(--ink-soft); }

@media (max-width: 820px) {
  .branches.n2, .branches.n3, .branches.n4 { grid-template-columns: minmax(0, 1fr); grid-template-rows: none; padding-top: 0; }
  .branches::before { display: none; }
  .branch { display: flex; flex-direction: column; grid-row: auto; padding: 18px 0 0 26px; }
  .branch::before { top: 40px; left: 0; width: 26px; height: 2px; }
  .branch::after, .branch:first-child::after { top: 0; bottom: 0; left: 0; right: auto; width: 2px; height: auto; }
  .branch:last-child::after { right: auto; bottom: auto; height: 42px; }
  .stem { align-self: flex-start; margin-left: 24px; }
  .next { align-items: flex-start; }
  .next .stem { margin-left: 0; }
  .next .txt { text-align: left; }
  .promises { grid-template-columns: minmax(0, 1fr); }
}
