/* =========================================================
   01 あなたは、どれですか。（#paths）□ 和紙
   結び目から一本の白帯が下へ垂れ、五つの入口へ枝分かれする。
   カードは使わず、明朝の大きな文字と髪の毛ほどの線だけで組む。
   ========================================================= */

.paths {
  --paths-ink: rgba(34, 32, 29, .72);
  --paths-band: #FBF9F5;
  --paths-x: 30px;      /* 帯（幹）の左端＝結び目の垂れの左端 */
  --paths-w: 10px;      /* 帯の幅（線込み） */
  --paths-indent: 72px; /* 文字の開始位置 */
  --paths-fs: clamp(1.3rem, 5.6vw, 1.95rem); /* 入口の文字 */
  --paths-pt: 12px;     /* 入口の上の余白 */
  --paths-y: calc(var(--paths-pt) + var(--paths-fs) * .775); /* 枝の高さ＝文字の中心 */
}

.paths__inner {
  display: grid;
  gap: clamp(36px, 8vw, 56px);
}

/* ---------- 見出し ---------- */
/* 見出しは base.css の .section-head（共通の型） */
.paths__br { display: none; }
.paths__lead { max-width: 26em; }

/* ---------- 結び目と帯（幹） ---------- */
.paths__route {
  position: relative;
  padding-top: 70px;
}
.paths__knot {
  position: absolute;
  top: 0;
  left: 0;
  width: 100px;
  height: 72px;
  overflow: visible;
}
.paths__knot-band,
.paths__knot-tail,
.paths__knot-knot {
  fill: var(--paths-band);
  stroke: var(--paths-ink);
  stroke-width: 1;
  stroke-linejoin: round;
}
.paths__knot-stitch {
  fill: none;
  stroke: var(--paths-ink);
  stroke-width: .8;
  stroke-dasharray: 2.5 2.5;
  opacity: .45;
}
.paths__knot-crease { fill: none; stroke: var(--paths-ink); stroke-width: .8; opacity: .35; }

/* ---------- 五つの入口 ---------- */
.paths__list { position: relative; }
.paths__item {
  position: relative;
  padding-left: var(--paths-indent);
}
/* 帯の続き（項目ごとに描いて、つなげる） */
.paths__item::before {
  content: "";
  position: absolute;
  top: -1px;
  bottom: 0;
  left: var(--paths-x);
  width: var(--paths-w);
  background: var(--paths-band);
  border-inline: 1px solid var(--paths-ink);
}
/* 最後の項目で帯が終わる（帯の先） */
.paths__item:last-child::before {
  bottom: auto;
  height: calc(var(--paths-y) + 18px);
  border-bottom: 1px solid var(--paths-ink);
}
/* 枝：帯から文字へ */
.paths__item::after {
  content: "";
  position: absolute;
  top: var(--paths-y);
  left: calc(var(--paths-x) + var(--paths-w));
  width: calc(var(--paths-indent) - var(--paths-x) - var(--paths-w) - 10px);
  height: 1px;
  background: var(--paths-ink);
  transform-origin: left center;
  transition: background-color .3s var(--ease), transform .35s var(--ease);
}

.paths__link {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "label go"
    "hint  go";
  column-gap: 12px;
  row-gap: 4px;
  align-items: center;
  min-height: 44px;
  padding: var(--paths-pt) 0 20px;
  border-bottom: 1px solid var(--line);
  text-decoration: none;
  color: var(--ink);
}
.paths__item:first-child .paths__link { border-top: 1px solid var(--line); }
.paths__label {
  grid-area: label;
  font-family: var(--font-mincho);
  font-weight: 700;
  font-size: var(--paths-fs);
  line-height: 1.55;
  letter-spacing: .08em;
  font-feature-settings: "palt" 1;
  word-break: auto-phrase;
  transition: color .25s var(--ease);
}
.paths__hint {
  grid-area: hint;
  font-size: .9rem;
  line-height: 1.75;
  word-break: auto-phrase;
  letter-spacing: .05em;
  color: var(--ink-2);
}
.paths__nb { white-space: nowrap; }
.paths__go {
  grid-area: go;
  width: 22px;
  height: 22px;
  color: var(--shu);
  transition: transform .3s var(--ease);
}

.paths__link:hover .paths__label,
.paths__link:focus-visible .paths__label { color: var(--shu); }
.paths__link:hover .paths__go,
.paths__link:focus-visible .paths__go { transform: translateX(4px); }
.paths__item:has(.paths__link:hover)::after,
.paths__item:has(.paths__link:focus-visible)::after { background: var(--shu); transform: scaleY(2); }
.paths__link:focus-visible { outline-offset: 6px; }

/* 迷ったときの出口 */
.paths__alt {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 16px;
  font-size: .95rem;
  color: var(--ink-2);
}
.paths__alt .link-arrow { min-height: 44px; border-bottom: 0; padding: 0; color: var(--ink); text-decoration: underline; text-decoration-color: var(--shu); text-underline-offset: .45em; }
.paths__alt .link-arrow .icon { color: var(--shu); }

/* ---------- タブレット ---------- */
@media (min-width: 768px) {
  .paths {
    --paths-indent: 92px;
    --paths-pt: 16px;
  }
  .paths__link { padding: var(--paths-pt) 4px 22px 0; column-gap: 24px; }
  .paths__hint { font-size: .95rem; }
}

/* ---------- PC：見出しを左、入口を右に ---------- */
@media (min-width: 1024px) {
  .paths {
    --paths-pt: 20px;
    --paths-fs: clamp(1.7rem, 2.3vw, 2.05rem);
  }
  .paths__inner {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    grid-template-rows: auto 1fr;
    grid-template-areas:
      "head route"
      "alt  route";
    column-gap: clamp(56px, 7vw, 112px);
    row-gap: 40px;
    align-items: start;
  }
  .paths__head { grid-area: head; padding-top: 8px; }
  .paths__route { grid-area: route; }
  .paths__alt { grid-area: alt; flex-direction: column; align-items: flex-start; gap: 4px; padding-top: 24px; border-top: 1px solid var(--line); max-width: 22em; }
  .paths__br { display: inline; }
  .paths__link {
    grid-template-columns: minmax(0, 1fr) auto;
    padding: var(--paths-pt) 4px 26px 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .paths__item::after, .paths__go, .paths__label { transition: none; }
}
