/* 使い方（共通・VS Code 拡張・Web 版・デスクトップアプリ）。紹介ページと同じ配色で、本文を読みやすい幅に収める。 */
/* 差し色（style.css の --accent）は、リンク・番号・選択中のタブ・見出しの印に限って使い、本文やコードの地には使わない */
.guide a { color: var(--accent); text-decoration-color: color-mix(in srgb, var(--accent) 45%, transparent); text-underline-offset: 3px; }
.guide a:hover { text-decoration-color: var(--accent); }
.guide { max-width: 820px; padding-top: 40px; padding-bottom: 64px; }
/* 版の切り替え。ヘッダーの nav の既定（右寄せ）を打ち消し、4つを同じ幅で並べる */
.guide-tabs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin: 0 0 48px; border-bottom: 1px solid var(--line); font-size: 14px; }
.guide-tabs a { padding: 12px 8px; text-align: center; color: var(--ink-2); }
.guide-tabs a:hover { color: var(--accent); }
.guide-tabs a[aria-current="page"] { color: var(--accent); font-weight: 600; box-shadow: inset 0 -2px var(--accent); }
.guide .guide-eyebrow { margin: 0 0 14px; color: var(--accent); font-size: 14px; font-weight: 600; letter-spacing: 0.04em; }
.guide h1 { margin: 0 0 24px; font-size: clamp(28px, 5vw, 42px); line-height: 1.5; font-weight: 300; }
.guide-lead { color: var(--ink-2); font-size: 17px; }
.guide-contents { margin: 32px 0 16px; padding: 16px 0; border-block: 1px solid var(--line); flex-wrap: wrap; gap: 8px 22px; font-size: 14px; }
.guide-contents a { color: var(--ink-2); }
.guide-contents a:hover { color: var(--accent); text-decoration: underline; }
/* 節の区切りは見出しの余白で示し、紹介ページの section の罫線は使わない */
.guide section { padding: 0; margin-top: 64px; border-top: 0; scroll-margin-top: 90px; }
/* 見出しの左に短い印を付け、長いページでも節の切れ目を追いやすくする */
.guide h2 { margin: 0 0 16px; padding-left: 14px; border-left: 3px solid var(--accent); font-size: 24px; font-weight: 500; line-height: 1.4; }
.guide p, .guide li, .guide dd { color: var(--ink); font-size: 16px; line-height: 1.95; overflow-wrap: anywhere; }
.guide li + li { margin-top: 12px; }
.guide ol, .guide ul { padding-left: 1.5em; }
.guide strong { color: var(--ink); font-weight: 600; }
/* 記法と結果の対応表。左に打つ記号、右に結果を並べ、行ごとに罫線で区切る */
.guide dl { display: grid; grid-template-columns: minmax(9em, max-content) 1fr; margin: 24px 0; border-top: 1px solid var(--line); }
.guide dt, .guide dd { margin: 0; padding: 12px 0; border-bottom: 1px solid var(--line); }
.guide dt { padding-right: 24px; font-weight: 500; overflow-wrap: anywhere; }
/* インラインのコードは本文と見分けられるよう薄い地を敷く */
.guide code { padding: 1px 6px; border-radius: 4px; background: #f0f0ee; color: var(--ink); font-size: .9em; white-space: nowrap; }
.guide table { width: 100%; min-width: 0; border-collapse: collapse; font-size: 14px; }
.guide th, .guide td { padding: 10px 12px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.guide th { width: 45%; font-weight: 400; color: var(--ink); }
/* 画面の切り抜き。白い画面が背景に溶けないよう、枠と淡い影で区切る */
.guide-shot { margin: 24px 0; }
.guide-shot img { max-width: 100%; border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 6px 20px -12px rgba(0, 0, 0, 0.25); }
.guide-shot figcaption { margin-top: 10px; font-size: 13.5px; color: var(--ink-3); }
/* 画像に重ねる番号。画像に焼き込まず CSS で描くので、差し色を変えても撮り直さなくてよい */
.shot-marked { position: relative; display: inline-block; max-width: 100%; }
.shot-mark { position: absolute; width: 20px; height: 20px; margin: -10px 0 0 -10px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 12px; font-weight: 600; line-height: 20px; text-align: center; }
/* 画像の番号に対応する説明。番号を画像と同じ黒丸で示す */
.guide-legend { counter-reset: legend; list-style: none; padding-left: 0 !important; }
.guide-legend li { counter-increment: legend; position: relative; padding-left: 32px; }
.guide-legend li::before { content: counter(legend); position: absolute; left: 0; top: 5px; width: 20px; height: 20px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 12px; font-weight: 600; line-height: 20px; text-align: center; }
.guide-next { margin-top: 56px; padding: 18px 22px; border-radius: 8px; background: var(--accent-soft); font-size: 14px; }
.guide kbd { display: inline-block; padding: 0 6px; margin-inline: 2px; border: 1px solid #cfcfcf; border-bottom-width: 2px; border-radius: 4px; background: var(--bg); color: var(--ink); font: .85em/1.6 Consolas, monospace; white-space: nowrap; }
@media (max-width: 560px) {
  .guide { padding-top: 24px; }
  .guide-tabs { grid-template-columns: repeat(2, 1fr); margin-bottom: 32px; }
  .guide h2 { font-size: 21px; }
  .guide dl { grid-template-columns: 1fr; }
  .guide dt { padding-bottom: 0; border-bottom: 0; }
  /* ショートカットの表は、項目とキーを縦に並べて横にはみ出さないようにする */
  .guide table, .guide tbody, .guide tr, .guide th, .guide td { display: block; width: auto; }
  .guide th, .guide td { padding: 4px 0; }
  .guide tr { border-bottom: 1px solid var(--line); padding-bottom: 8px; }
  .guide td { border-bottom: 0; }
  .guide th { padding-top: 12px; border-bottom: 0; }
}
