/* 縦に読み進めるガイド（/guide/quest-setup/ など）。ヘッダー・メニューは /site-header.js と /list.css。
   色と字はカタログにそろえる（黒地・Hiragino）。目立たせるのは写真の上の「押す所」（黄色い枠）だけ */
body[data-view=doc]{background:#000}
.doc{--ink:#eeeff2;--sub:#a3a7b0;--faint:#7d828c;--line:#24262c;--panel:#121317;--mk:#e8590c;color:var(--ink);font-size:16px;line-height:1.8}
.doc a{color:inherit;text-decoration:underline;text-underline-offset:3px}
.doc [id]{scroll-margin-top:calc(var(--hh,61px) + 52px)}
html:has(body[data-view=doc]){scroll-padding-top:calc(var(--hh,61px) + 52px)}  /* キーボードで移った所もヘッダーに隠れない */
.doc a[target=_blank]::after{content:'↗';display:inline-block;margin-left:.2em;font-size:.85em;text-decoration:none}  /* ほかのサイトへ移るリンク */  /* ページ内リンクで飛んだ先が、ヘッダーと上の帯に隠れない */
.doc-main{max-width:680px;margin:0 auto;padding:0 16px 120px;box-sizing:content-box}  /* 下は「目次へ戻る」に隠れない余白 */

/* 最初: 何をするページか・用意するもの */
.d-top{padding:24px 0 0}
.d-top h1{margin:0 0 6px;font-size:27px;line-height:1.35;font-weight:700}
.nw{white-space:nowrap}  /* 言葉の途中で折り返さない */
.d-lead{margin:0 0 12px;color:var(--sub)}
.d-lead+.d-lead{margin-bottom:20px;font-size:15px}
.d-lead a{color:var(--ink)}
.d-need{margin:0 0 14px;padding:14px 16px;border-radius:10px;background:var(--panel)}
.d-need h2{margin:0 0 4px;font-size:14px;font-weight:700;color:var(--sub)}
.d-need ul{margin:0 0 8px;padding-left:1.2em}
.d-need p{margin:0 0 6px;font-size:15px}
.d-need p:last-child{margin:0;color:var(--sub);font-size:14px}
.d-need a{color:var(--ink)}

/* 今いる章: 目次より下を読んでいる間、ヘッダーのすぐ下に細く出す。押すと章の一覧（広い画面も同じ。横に目次は置かない） */
.d-now{position:sticky;top:var(--hh,61px);z-index:15;margin:0 -16px -45px;background:#000;box-shadow:0 0 0 100vmax #000,0 1px 0 100vmax var(--line);clip-path:inset(0 -100vmax -1px);transition:opacity .15s}  /* 帯と下の線は画面の端から端まで。下の余白を負にして、出ていないときに場所を取らない */
.d-now[data-hidden]{opacity:0;pointer-events:none}
.d-now>button{all:unset;box-sizing:border-box;display:flex;align-items:center;gap:10px;width:100%;min-height:44px;padding:0 16px;cursor:pointer;font-size:14px}
.d-now>button span{color:var(--sub);font-variant-numeric:tabular-nums}
.d-now>button b{flex:1;font-weight:700;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.d-now>button::after{content:'';width:7px;height:7px;border-right:2px solid var(--sub);border-bottom:2px solid var(--sub);transform:rotate(45deg) translateY(-2px)}
.d-now[data-open]>button::after{transform:rotate(-135deg) translateY(-2px)}
.d-now>button:focus-visible{outline:2px solid #fff;outline-offset:-4px}
.d-menu{display:none;padding:4px 16px 12px}
.d-now[data-open] .d-menu{display:block}
.d-menu a{display:flex;gap:10px;padding:9px 0;text-decoration:none;font-size:15px;border-top:1px solid var(--line)}
.d-menu a span{width:20px;color:var(--sub);text-align:center}
.d-menu a[aria-current]{font-weight:700}
.d-menu p{margin:12px 0 4px;color:var(--sub);font-size:14px;font-weight:700}
.d-menu p+a{border-top:0}

/* ダウンロードの囲み（連動アプリ）: 用意するものと同じ囲み。ボタンはカタログと同じ（白・高さ48px・角10px） */
.d-dl{margin:0 0 14px;padding:14px 16px 4px;border-radius:10px;background:var(--panel)}
.d-dl h2{margin:0 0 8px;font-size:14px;font-weight:700;color:var(--sub)}
.d-dl p{margin:0 0 10px;font-size:15px}
.d-dl a{color:var(--ink)}
.doc .d-btn{margin:14px 0 12px}
.doc .d-btn a{display:flex;align-items:center;justify-content:center;min-height:48px;padding:8px 16px;border-radius:10px;background:#fff;color:#000;font-weight:700;font-size:16px;text-decoration:none}
.doc .d-btn a:focus-visible{outline:2px solid #fff;outline-offset:3px}
/* 項目と中身の一覧（バージョン・動作環境） */
.spec{display:grid;grid-template-columns:max-content minmax(0,1fr);gap:6px 16px;margin:0 0 10px}
.spec dt{color:var(--sub);font-size:15px}
.spec dd{margin:0}
/* 機器の確認状況の表 */
.dev{width:100%;margin:0 0 12px;border-collapse:collapse;font-size:15px}
.dev th{padding:8px 10px;border-bottom:1px solid #3a3d45;color:var(--sub);font-weight:700;text-align:left}
.dev td{padding:10px;border-bottom:1px solid var(--line);vertical-align:top}
.dev td:first-child{width:45%}

/* 目次: 「目次」の見出しの付いた囲み（本文との境目が分かるように）。中は本の目次の形で、1行に番号と章の名前。押すとその章へ */
.toc{margin:14px 0 0;padding:14px 16px 4px;border-radius:10px;background:var(--panel)}
.toc h2{margin:0 0 10px;font-size:14px;font-weight:700;color:var(--sub)}
.toc-group{margin:0;padding:0 0 2px;color:var(--sub);font-size:14px;font-weight:700}
.toc ol{margin:0 0 14px;padding:0;list-style:none}
.toc a{display:flex;align-items:baseline;gap:10px;min-height:44px;padding:9px 0;box-sizing:border-box;font-size:16px;line-height:1.6;text-decoration:none}
.toc a .t{word-break:auto-phrase;text-decoration:underline;text-decoration-color:#5b606a;text-underline-offset:3px}  /* 下線は章の名前だけ */
.toc a .n{flex:none;width:18px;color:var(--sub);font-variant-numeric:tabular-nums;text-align:right}
.toc a{flex-wrap:wrap}
.toc a small{flex-basis:100%;padding-left:28px;color:var(--sub);font-size:14px;line-height:1.4}  /* 「（スマホで操作）」は章の名前の下の行に */
.toc a:hover .t{text-decoration-color:currentColor}
.toc a:focus-visible{outline:2px solid #fff;outline-offset:2px;border-radius:4px}

/* 本文の章（全部開いたまま）。章の番号は灰色の文字（手順の丸い番号と見分ける） */
.ch-group{margin:56px 0 0;padding:0 0 8px;border-bottom:1px solid var(--line);color:var(--sub);font-size:14px;font-weight:700}
.ch{padding-top:40px;scroll-margin-top:calc(var(--hh,61px) + 52px)}
.ch-group+.ch{padding-top:24px}
.ch-head h2{display:flex;align-items:baseline;gap:10px;margin:0 0 2px;font-size:23px;line-height:1.4;font-weight:700}
.ch-head h2 .ch-n{flex:none;color:var(--sub);font-variant-numeric:tabular-nums}
.ch-sub{margin:0 0 8px;color:var(--sub);font-size:14px}
.ch-head p{margin:0 0 8px;color:var(--sub);font-size:15px}
.ch-head .ch-why{margin:6px 0 10px;color:var(--ink);font-size:16px}  /* その章を何のためにするのか */
.ch-head .ch-vr{margin:0 0 10px;padding:10px 14px;border-radius:10px;background:var(--panel);color:var(--ink);font-size:15px}  /* Quest をかぶる章の入り口 */
.here{font-weight:700;word-break:break-all}
.ch-head .links{color:var(--ink)}

/* 手順: 左に番号と、次の手順へつながる線 */
.steps{margin:16px 0 0;padding:0;list-style:none;counter-reset:st}
.step{position:relative;counter-increment:st;padding:0 0 32px 46px;scroll-margin-top:calc(var(--hh,61px) + 52px)}
.step::before{content:counter(st);position:absolute;left:0;top:0;display:grid;place-items:center;width:30px;height:30px;border:2px solid #fff;border-radius:50%;font-size:14px;font-weight:700;line-height:1;font-variant-numeric:tabular-nums}
.step::after{content:'';position:absolute;left:15px;top:36px;bottom:6px;width:2px;background:var(--line)}
.step:last-child{padding-bottom:4px}
.step:last-child::after{display:none}
.step h3{margin:0 0 6px;padding-top:2px;font-size:18px;line-height:1.5;font-weight:700}
.step p,.after p{margin:0 0 10px}
.cases{margin:0 0 10px}
.cases dt{margin-top:8px;font-size:14px;font-weight:700;color:var(--sub)}
.cases dd{margin:0}
.links{display:flex;flex-wrap:wrap;gap:0 20px;margin:0 0 6px}
.links a{display:inline-block;padding:9px 0}  /* 押しやすい高さ（44px 以上）。↗ が文の後ろに付いたまま折り返す */
.checks{margin:0 0 10px;padding-left:1.2em}

/* 画面写真と「押す所」 */
.shot{margin:4px 0 12px}
.shot .fr{position:relative;display:block}  /* 幅は書き出しが style で決める */
.shot img{display:block;width:100%;height:auto;border:1px solid var(--line);border-radius:10px;cursor:zoom-in}
.shot figcaption{margin-top:4px;color:var(--sub);font-size:14px}
.mk{position:absolute;border:3px solid var(--mk);border-radius:6px;pointer-events:none}  /* 縁取りは付けない。この橙は白の上で 3.6:1、黒の上で 5.9:1（WCAG 1.4.11 の 3:1 以上）。形（四角い線）でも分かる */

/* 手順の途中の「〜とき」: 当てはまる人だけ読む。左に細い線の控えめな囲み */
.note{margin:14px 0 0;padding:2px 0 2px 14px;border-left:3px solid #3a3d45;font-size:15px}
.note-h{margin:0 0 4px !important;font-weight:700;color:var(--ink)}
.note p{margin:0 0 8px}
.note ol,.note ul{margin:0 0 8px;padding-left:1.3em}
.note li{margin-bottom:8px}
.note>*:last-child{margin-bottom:0}

/* 困ったとき: 症状1つを1つの囲みに（用意するもの・目次と同じ囲み）。囲みの間を空けて、塊を分ける */
.faq{display:grid;gap:12px;margin-top:14px}
.qa{padding:14px 16px 16px;border-radius:10px;background:var(--panel)}
.qa h3{margin:0 0 8px;font-size:18px;line-height:1.5}
.qa p{margin:0 0 10px}
.qa ol,.qa ul{margin:0;padding-left:1.5em}
.qa li::marker{color:var(--sub);font-variant-numeric:tabular-nums}
.doc a.to{display:block;width:fit-content;margin-top:2px;color:var(--sub);font-size:14px;text-decoration-color:#4a4e57}  /* 行の下の「→ 3章の手順1」。長い見出しでも折り返す */
.doc a.to:hover{color:var(--ink)}
.qa li{margin-bottom:8px;padding-left:2px}
.qa li:last-child{margin-bottom:0}
.qa>*:last-child{margin-bottom:0}

/* セットアップのあと（次回から・更新・困ったとき）は、手順の番号の線を付けない読み物の形 */
.after h3{margin:18px 0 6px;font-size:17px}
.after ol,.after ul{margin:0 0 10px;padding-left:1.3em}

/* スマホの横向きなど高さが低い画面: 今いる章の帯は出さない（読める所を広く） */
@media (max-height:500px){.d-now{display:none}}

/* 広い画面: 手順ごとに、左に説明、右に写真（説明と押す所を同時に見られる）。説明の文の幅は狭い画面と同じくらい */
@media (min-width:1024px){
 /* 広い画面も1列。題名・目次・手順・写真・困ったときを全部同じ幅にして、真ん中に置く。文字だけ少し大きく */
 .doc-main{max-width:720px}
 .doc{font-size:17px}
}

/* Quest のブラウザ（幅1280px のパソコン表示で開く）: 全体を少し大きく。Meta は 18px 以上を読みやすいとしている */
html.vr{zoom:1.125}  /* ヘッダーも一緒に。この中だけの大きさなので、固定の帯の位置もずれない */

/* 写真を押すと、同じページの上に大きく出す（押す所の枠も一緒に）。もう一度押すか Esc で閉じる */
.lb{position:fixed;inset:0;z-index:100;display:grid;place-items:center;padding:16px;background:rgba(0,0,0,.92);cursor:zoom-out}
.lb .fr{position:relative;display:inline-block;width:auto !important}
.lb img{display:block;max-width:calc(100vw - 32px);max-height:calc(100svh - 32px);width:auto;height:auto;border-radius:10px}
.lb-x{all:unset;position:fixed;top:12px;right:12px;display:grid;place-items:center;width:44px;height:44px;border-radius:50%;background:#fff;color:#000;font-size:24px;line-height:1;cursor:pointer}
.lb-x:focus-visible{outline:2px solid #fff;outline-offset:3px}
body.lb-open{overflow:hidden}
.shot img:focus-visible{outline:2px solid #fff;outline-offset:3px}
/* 目次へ戻る: 目次より下を読んでいる間、右下に出す（長いページなので。文字付き） */
.to-toc{position:fixed;right:16px;bottom:calc(16px + env(safe-area-inset-bottom));z-index:20;display:inline-flex;align-items:center;gap:6px;min-height:44px;padding:0 16px;border-radius:999px;background:#fff;color:#000 !important;font-size:14px;font-weight:700;text-decoration:none !important;box-shadow:0 2px 12px rgba(0,0,0,.5);transition:opacity .15s}
.to-toc::before{content:'';width:7px;height:7px;border-left:2px solid #000;border-top:2px solid #000;transform:rotate(45deg) translate(2px,2px)}
.to-toc[hidden]{display:inline-flex;opacity:0;pointer-events:none}
.to-toc:focus-visible{outline:2px solid #fff;outline-offset:3px}
@media (prefers-reduced-motion:reduce){.d-now,.to-toc{transition:none}}
