
:root {
  --main: #365d95;
  --main-dark: #294670;
  --text: #333333;
  --bg: #fafbfc;
  --header-bg: #fdfdfd;
  --plate: #ffffff;
  --sub: #f7f7f7;
  --footer-bg: #2d2d2d;
  --footer-text: #f4f4f4;
  --font: "游ゴシック体", "Yu Gothic", YuGothic, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
/* フッターを画面の下端に置く（段階6：古い端末は 100vh、iPhone は下のバーで隠れない 100svh が効く） */
body { display: flex; flex-direction: column; min-height: 100vh; min-height: 100svh; background: var(--bg); color: var(--text); font-family: var(--font); font-weight: 500; font-size: 16px; line-height: 1.6; }
main { flex: 1 0 auto; }
a { color: var(--main); }
:focus-visible { outline: 2px solid var(--main); outline-offset: 3px; }
.skip { position: absolute; left: -9999px; top: 0; }
.skip:focus { left: 8px; top: 8px; z-index: 10; padding: 8px 12px; background: var(--plate); color: var(--main); }

/* 1 上部の帯（1280 だけ） */
.topbar { background: var(--main); color: #fff; }
.topbar .inner { max-width: 1396px; margin: 0 auto; padding: 4px 48px; display: flex; align-items: center; font-size: 12px; line-height: 14px; letter-spacing: .2px; }
.topbar .catch { margin: 0 auto 0 0; }
.topbar a { color: #fff; text-decoration: underline; text-underline-offset: 2px; }
.topbar a:hover { text-decoration: none; }

/* 2 ヘッダー */
header.site { background: var(--header-bg); box-shadow: 0 1px 4px rgba(0, 0, 0, .12); position: relative; z-index: 2; }
header.site .inner { max-width: 1396px; margin: 0 auto; padding: 0 48px; height: 80px; display: flex; align-items: center; }
.brand { display: flex; align-items: center; gap: 12px; margin-right: auto; text-decoration: none; color: var(--text); font-weight: 700; }
.brand-logo { display: block; height: 48px; }
.brand-logo img { display: block; height: 100%; width: auto; }
.brand-label { display: block; font-size: 13px; font-weight: 700; line-height: 1; color: var(--main); border: 1px solid var(--main); padding: 5px 8px; letter-spacing: .05em; white-space: nowrap; }
nav.gnav { display: flex; align-self: stretch; }
nav.gnav a { position: relative; display: flex; align-items: center; padding: 0 12px; font-size: 14px; line-height: 14px; color: var(--text); text-decoration: none; white-space: nowrap; }
nav.gnav a::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 0; height: 2px; background: var(--main); opacity: 0; }
nav.gnav a:hover::after, nav.gnav a[aria-current="page"]::after { opacity: 1; }
nav.gnav a:hover { color: var(--main); }
nav.gnav a[aria-current="page"] { font-weight: 700; }
.pill { display: inline-flex; align-items: center; height: 43.2px; margin-left: 12px; padding: 0 21.6px; border-radius: 9999px; background: var(--main); color: #fff; font-size: 14.4px; font-weight: 700; line-height: 1; letter-spacing: 1px; text-decoration: none; white-space: nowrap; }
.pill:hover { background: var(--main-dark); }
.pill:active { background: var(--main-dark); transform: translateY(1px); box-shadow: inset 0 2px 4px rgba(0, 0, 0, .25); }
.menu-btn { display: none; }

/* 3 狭い幅のメニュー（開いた中身）。広い幅では開いていても出さない */
.sp-menu { background: var(--header-bg); border-top: 1px solid #dcdcdc; }
.sp-menu a.item { display: flex; align-items: center; height: 48px; padding: 0 16px; border-bottom: 1px solid #dcdcdc; color: var(--text); font-size: 15.6px; text-decoration: none; }
.sp-menu a.item[aria-current="page"] { font-weight: 700; box-shadow: inset 3px 0 0 var(--main); }
.sp-menu a.item:active { background: var(--sub); }
.sp-menu .pill-wrap { padding: 16px; }
.sp-menu .pill { display: flex; justify-content: center; width: 100%; height: 48px; margin: 0; }
.menu-btn.is-open span { background: transparent; }
.menu-btn.is-open span::before { top: 0; transform: rotate(45deg); }
.menu-btn.is-open span::after { top: 0; transform: rotate(-45deg); }
@media (min-width: 960px) { .sp-menu { display: none !important; } }

/* 本文の白の板（1列 900px） */
main { padding: 40px 48px 96px; }
.plate { max-width: 900px; margin: 0 auto; background: var(--plate); padding: 32px; overflow-wrap: anywhere; }
h1.title { margin: 0; font-size: 24px; line-height: 33.6px; font-weight: 700; color: var(--text); word-break: auto-phrase; }

/* 5 ページの見出し：一覧＝節の見出しの形／中身・登録＝記事の題名の形（h1.title） */
h1.section-ttl { margin: 0; font-size: 22.4px; line-height: 31.36px; font-weight: 700; text-align: center; letter-spacing: .2px; color: var(--text); }
.list-head .lead { margin: 16px 0 44.8px; text-align: center; text-wrap: balance; }
p.lead { margin: 16px 0 32px; font-size: 16px; line-height: 28.8px; word-break: auto-phrase; text-wrap: pretty; }
/* 題名のすぐ下の枠（コードの入力の画面など）は、p.lead の上と同じだけあける（段階7の直し・裁定書 15章） */
h1.title + .notice, h1.title + .error { margin-top: 16px; }

/* 13 カバーの後ろ（冒頭と動画の仮の枠）とカバー。後ろとカバーを同じ升に重ね、高い方に合わせる。題名はカバーの外 */
.teaser-wrap { display: grid; grid-template-columns: minmax(0, 1fr); margin-top: 24px; }
.teaser, .cover { grid-area: 1 / 1; min-width: 0; }
.video-ph { position: relative; aspect-ratio: 16 / 9; background: var(--footer-bg); }
.video-ph .play { position: absolute; left: 50%; top: 50%; width: 72px; height: 72px; margin: -36px 0 0 -36px; border-radius: 50%; background: #fff; }
.video-ph .play::after { content: ""; position: absolute; left: 29px; top: 22px; border-style: solid; border-width: 14px 0 14px 22px; border-color: transparent transparent transparent var(--footer-bg); }
.teaser .body { margin-top: 0; }
.teaser .body p { margin: 24px 0 0; font-size: 16px; line-height: 28.8px; }
.cover { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1fr); align-content: start; justify-items: center; padding: 0; background: rgba(255, 255, 255, .82); }
.cover::before { content: ""; grid-area: 1 / 1; aspect-ratio: 16 / 9; width: 100%; }
.cover-box { grid-area: 1 / 1; align-self: center; width: 100%; max-width: 560px; padding: 32px; background: var(--plate); border: 1px solid var(--main); box-shadow: 0 8px 24px rgba(0, 0, 0, .12); text-align: left; }
.cover-box h2 { margin: 0 0 16px; font-size: 28px; line-height: 1.4; font-weight: 700; color: var(--text); word-break: auto-phrase; text-wrap: pretty; }
.cover-box .desc { margin: 0 0 24px; font-size: 16px; line-height: 28.8px; word-break: auto-phrase; text-wrap: pretty; }
.cover-box form.stack { max-width: none; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; }
/* Safari は auto-phrase を知らないので、HTML に入れた <wbr> の位置だけで折る（段階6） */
@supports not (word-break: auto-phrase) {
  .cover-box h2 { word-break: keep-all; }
}

/* 10 ボタン（押せるものだけピル） */
.button { display: inline-flex; align-items: center; justify-content: center; height: 56px; padding: 0 32px; border: 1px solid var(--main); border-radius: 9999px; background: var(--main); color: #fff; font-family: inherit; font-size: 18px; font-weight: 700; line-height: 1; letter-spacing: .05em; text-decoration: none; white-space: nowrap; cursor: pointer; }
.button:hover { background: var(--main-dark); border-color: var(--main-dark); }
.button:active { background: var(--main-dark); border-color: var(--main-dark); transform: translateY(1px); box-shadow: inset 0 2px 4px rgba(0, 0, 0, .25); }
.button.secondary { padding: 0 24px; background: var(--plate); color: var(--main); font-size: 16px; }
.button.secondary:hover { background: var(--sub); color: var(--main-dark); border-color: var(--main-dark); }
.button.secondary:active { background: var(--sub); color: var(--main-dark); border-color: var(--main-dark); box-shadow: inset 0 2px 4px rgba(0, 0, 0, .12); }
.button.danger { background: var(--plate); color: var(--text); border: 2px solid #DF5656; }
.button.danger:hover { background: var(--sub); color: var(--text); border-color: #DF5656; }
.button.danger:active { background: var(--sub); color: var(--text); border-color: #DF5656; transform: translateY(1px); box-shadow: inset 0 2px 4px rgba(0, 0, 0, .12); }
.button.small { height: 40px; padding: 0 18px; font-size: 14px; }
.button:disabled, .button:disabled:hover { background: var(--sub); color: #666666; border-color: #dcdcdc; cursor: not-allowed; transform: none; box-shadow: none; }

/* 11 動画の枠（本物）・12 ダウンロードの並び */
.video { position: relative; aspect-ratio: 16 / 9; margin-top: 24px; background: var(--footer-bg); }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.downloads { display: flex; flex-wrap: wrap; gap: 16px 24px; margin-top: 16px; }
.downloads .dl { display: flex; flex-direction: column; align-items: flex-start; }
.button.file { height: 48px; padding: 0 24px; font-size: 16px; }
.dl-meta { margin: 8px 0 0; font-size: 14px; line-height: 1.5; color: var(--text); }
.form-sub { margin: 16px 0 0; font-size: 16px; line-height: 1.6; }
.form-sub a { color: var(--main); text-decoration: underline; text-underline-offset: 2px; }
.form-sub a:hover { color: var(--main-dark); text-decoration: none; }

/* 6 本文の組み（H2 の角は 0・段落の左端は題名とそろえる） */
.body { margin-top: 48px; }
.body > :first-child { margin-top: 0; }
.body p { margin: 0 0 32px; font-size: 16px; line-height: 28.8px; word-break: auto-phrase; text-wrap: pretty; }
.body h2 { margin: 89.6px 0 44.8px; padding: 16.8px 22.4px; background: var(--main); color: #fff; font-size: 22.4px; line-height: 31.36px; font-weight: 700; }
.body h3 { margin: 64px 0 32px; padding: 0 0 8px; border-bottom: 2px solid var(--main); font-size: 19.2px; line-height: 1.5; font-weight: 700; }
.body ul, .body ol { margin: 0 0 32px; padding-left: 24px; }
.body li { margin: 4px 0; font-size: 16px; line-height: 28.8px; word-break: auto-phrase; }
.body li::marker { color: var(--main); }
.body a { color: var(--main); text-decoration: underline; text-underline-offset: 2px; }
.body a:hover { color: var(--main-dark); text-decoration: none; }
.body code { padding: 2px 4px; background: var(--sub); font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .9em; }
.body strong { font-weight: 700; }
/* 7 斜線の囲み（あしらいはこの1系統だけ。本文の :::stripe から出す） */
.stripe { margin: 0 0 32px; padding: 32px; background-image: linear-gradient(-45deg, transparent 25%, rgba(199, 199, 199, .15) 25%, rgba(199, 199, 199, .15) 50%, transparent 50%, transparent 75%, rgba(199, 199, 199, .15) 75%, rgba(199, 199, 199, .15)); background-size: 6px 6px; }
.stripe > :last-child { margin-bottom: 0; }

/* 8 青の線の枠（お知らせ・空の状態） */
.notice { margin: 0 0 32px; padding: 32px; background: var(--plate); border: 1px solid var(--main); }
.notice p { margin: 0; font-size: 16px; line-height: 28.8px; word-break: auto-phrase; }
.notice p + p { margin-top: 12px; }
.notice a { color: var(--main); text-underline-offset: 2px; }
.notice a:hover { color: var(--main-dark); text-decoration: none; }
/* 9 注意の囲み（エラー・下書きの帯）：警告の色は左の線だけ・字は #333 */
.error, .draft-banner { margin: 0 0 32px; padding: 16px 20px; background: var(--sub); border-left: 4px solid #E0A23A; }
.error p { margin: 0; font-size: 16px; line-height: 28.8px; }
.draft-banner { font-size: 16px; line-height: 1.6; font-weight: 700; }

/* 14 一覧の行・15 札（札は直角） */
.list { margin: 0; padding: 0; list-style: none; border-top: 1px solid #dcdcdc; }
.list .item { padding: 20px 0; border-bottom: 1px solid #dcdcdc; }
.list .item .title { font-size: 18px; line-height: 1.5; font-weight: 700; color: var(--text); text-decoration: none; word-break: auto-phrase; }
.list .item a.title:hover { color: var(--main); text-decoration: underline; text-underline-offset: 2px; }
.list .item .tags { margin-top: 8px; }
.list .item .summary { margin: 8px 0 0; font-size: 15px; line-height: 1.7; }
.tag { display: inline-block; margin: 2px 8px 2px 0; padding: 3px 8px; background: var(--sub); color: var(--text); font-size: 12px; line-height: 1.4; font-weight: 500; vertical-align: middle; }
.tag.lock { padding: 2px 7px; background: var(--plate); color: var(--main); border: 1px solid var(--main); }
.tags { margin: 8px 0 0; }

/* 16 フォーム */
form.stack { display: grid; gap: 16px; max-width: 560px; }
form.stack > label:not(.check) { margin-bottom: -8px; font-size: 16px; line-height: 1.5; font-weight: 700; }
form.inline { display: inline; }
input[type=email], input[type=text], textarea, select { display: block; width: 100%; height: 48px; padding: 0 14px; border: 1px solid #666666; border-radius: 0; background: #fff; color: var(--text); font: inherit; font-size: 16px; }
textarea { height: auto; padding: 12px 14px; line-height: 1.8; }
input:focus, textarea:focus, select:focus { outline: 2px solid var(--main); outline-offset: 2px; border-color: var(--main); }
input:disabled, textarea:disabled { background: var(--sub); color: #666666; border-color: #dcdcdc; }
input[inputmode=numeric] { max-width: 12em; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 24px; letter-spacing: .3em; }
.help { margin: 0; font-size: 14px; line-height: 1.7; color: var(--text); }
/* 登録の確認：メールマガジンの説明は2つ目のチェックの説明。1つ目との間 24px・2つ目との間 8px（gap 16px との足し引き・14-6 の6） */
.consent-note { margin: 8px 0 -8px; }
#name-note { margin-bottom: 8px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 16px; line-height: 1.7; font-weight: 500; }
.check input { flex: none; width: 20px; height: 20px; margin: 4px 0 0; accent-color: var(--main); }
.form-actions { margin: 8px 0 0; }
/* 同意のチェックの文の最後（「同意します（必須）」）を語の途中で折らない（段階7の直し・裁定書 15章） */
.nobr { white-space: nowrap; }

/* 17 表と説明リスト（表は横にスクロールする入れ物に入れる＝390 で画面が横に広がらない・段階6） */
dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: 0 32px; margin: 0 0 32px; border-top: 1px solid #dcdcdc; }
dl.facts dt, dl.facts dd { margin: 0; padding: 14px 0; border-bottom: 1px solid #dcdcdc; font-size: 16px; line-height: 1.7; }
dl.facts dt { font-weight: 700; }
.table-scroll { max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 0 32px; }
table.data { width: 100%; margin: 0; border-collapse: collapse; font-size: 15px; line-height: 1.6; }
table.data th, table.data td { padding: 12px; border-bottom: 1px solid #dcdcdc; text-align: left; vertical-align: top; }
table.data th { background: var(--sub); font-weight: 700; white-space: nowrap; }
table.data td.num, table.data th.num { text-align: right; font-variant-numeric: tabular-nums; }
/* 本文の表の1列目（項目）を、960px 以上では折らない。959px 以下と管理画面の表（.body の外）には当てない（裁定書 26-1・tests/a40） */
@media (min-width: 960px) { .body table.data th:first-child, .body table.data td:first-child { white-space: nowrap; } }

/* 18 コメント欄（第4段階） */
.comments { margin-top: 64px; }
.comments h2 { margin: 0 0 16px; padding: 0 0 8px; border-bottom: 2px solid var(--main); font-size: 19.2px; line-height: 1.5; font-weight: 700; }
.comment { padding: 16px 0; border-bottom: 1px solid #dcdcdc; }
.comment.reply { margin-left: 24px; padding-left: 16px; border-left: 2px solid #dcdcdc; }
.comment .who { font-size: 15px; font-weight: 700; }
.comment .text { margin: 4px 0; font-size: 16px; line-height: 1.8; white-space: pre-wrap; overflow-wrap: anywhere; }
.comment .date, .comment .deleted { font-size: 12px; }
.prewrap { white-space: pre-wrap; overflow-wrap: anywhere; }

/* 4 フッター */
footer.site { background: var(--footer-bg); color: var(--footer-text); }
footer.site .inner { max-width: 1396px; margin: 0 auto; padding: 24px 48px 16px; text-align: center; }
footer.site ul { display: flex; justify-content: center; flex-wrap: wrap; margin: 0 0 16px; padding: 0; list-style: none; }
footer.site li a { display: block; padding: 0 12px; border-left: 1px solid var(--footer-text); font-size: 13px; line-height: 20.8px; color: var(--footer-text); text-decoration: none; }
footer.site li:last-child a { border-right: 1px solid var(--footer-text); }
footer.site li a:hover { text-decoration: underline; }
footer.site .copyright { margin: 0; font-size: 12px; line-height: 19.2px; }

/* ---- 狭い幅（SWELL と同じ 959px 以下） ---- */
@media (max-width: 959px) {
  .topbar { display: none; }
  header.site .inner { height: 48px; padding: 0 0 0 7.8px; }
  .brand { gap: 8px; }
  .brand-logo { height: 28px; }
  .brand-label { font-size: 12px; padding: 4px 6px; }
  nav.gnav, header.site .pill { display: none; }
  .menu-btn { display: flex; align-items: center; justify-content: center; flex: none; width: 48px; height: 48px; padding: 0; border: 0; background: transparent; cursor: pointer; }
  .menu-btn span { position: relative; display: block; width: 24px; height: 2px; background: var(--text); }
  .menu-btn span::before, .menu-btn span::after { content: ""; position: absolute; left: 0; width: 24px; height: 2px; background: var(--text); }
  .menu-btn span::before { top: -8px; }
  .menu-btn span::after { top: 8px; }
  .menu-btn:active { background: var(--sub); }
  main { padding: 40px 7.8px 84px; }
  .plate { padding: 11.7px; }
  h1.title { font-size: 19.5px; line-height: 27.3px; }
  h1.section-ttl { font-size: 18.72px; line-height: 26.21px; }
  .list-head .lead { margin: 12px 0 37.44px; }
  p.lead { margin: 12px 0 28px; font-size: 15.6px; line-height: 28.08px; }
  h1.title + .notice, h1.title + .error { margin-top: 12px; }
  .teaser-wrap { margin-top: 20px; }
  .teaser .body p { margin-top: 20px; font-size: 15.6px; line-height: 28.08px; }
  .video-ph .play { top: 33.3%; width: 48px; height: 48px; margin: -24px 0 0 -24px; }
  .video-ph .play::after { left: 19px; top: 14px; border-width: 10px 0 10px 15px; }
  .cover { display: flex; align-items: flex-start; justify-content: center; padding: 0 0 16px; }
  .cover::before { display: none; }
  .cover-box { margin-top: 37.5%; padding: 24px 20px; }
  .cover-box h2 { font-size: 26px; }
  .cover-box .desc { font-size: 15.6px; line-height: 28.08px; margin-bottom: 20px; }
  .actions { flex-direction: column; }
  .actions .button { width: 100%; }
  .video { margin-top: 20px; }
  .downloads .dl { width: 100%; }
  .downloads .button.file { width: 100%; justify-content: center; }
  .body { margin-top: 40px; }
  .body p, .body li { font-size: 15.6px; line-height: 28.08px; }
  .body p, .body ul, .body ol { margin-bottom: 31.2px; }
  .body h2 { margin: 74.88px 0 37.44px; padding: 14.04px 18.72px; font-size: 18.72px; line-height: 26.21px; }
  .body h3 { margin: 56px 0 28px; font-size: 17px; }
  .stripe { padding: 23.4px; margin-bottom: 31.2px; }
  .notice { padding: 24px 20px; }
  .notice p { font-size: 15.6px; line-height: 28.08px; }
  .list .item .title { font-size: 16.5px; }
  dl.facts { grid-template-columns: 1fr; }
  dl.facts dt { padding-bottom: 0; border-bottom: 0; }
  dl.facts dd { padding-top: 4px; }
  form.stack .button { width: 100%; }
  footer.site .inner { padding: 20px 7.8px 16px; }
  footer.site li a { padding: 2.925px 5.85px; border: 0; font-size: 12px; line-height: 20px; }
  footer.site li:last-child a { border-right: 0; }
}

/* ==== 19〜23 一覧の型（トップ・/free・/courses・/notes・/lab）====
   正：★G3-3・★G3-4 で承認したカンプ comp-4c.css（.v-a の値だけ。.v-b は不採用の案なので写さない）→ comp-4c2.css。
   クラス名はカンプのまま。仮の注記（.guide.kari-note）は手元の設定のときだけ HTML に出る */
:root { --stage-band: #EDEEF0; --line-hover: #f7f7f7; --card-line: #C9CCD1; --win-bg: #EDEEF0; }

/* 一覧の型は白の板を使わず全幅の帯（16-3）。列は 900px */
main.listing { position: relative; padding: 0 0 96px; overflow-x: clip; }
.wrap { max-width: 900px; margin: 0 auto; }

/* ① 題と1文（左揃え・名乗りは外した 16-15-4） */
.intro { padding-top: 64px; }
.ptitle { margin: 0; font-size: 28px; line-height: 1.4; font-weight: 700; color: var(--text); }
.plead { margin: 8px 0 0; font-size: 16px; line-height: 1.75; color: var(--text); word-break: auto-phrase; }
.plead .who { overflow-wrap: anywhere; }
.filter-now { margin: 12px 0 0; font-size: 15px; line-height: 1.6; }

/* ② 主の段：窓 540×303.75 が左・文字とボタンが右（336）・間 24。地の帯は題のまとまりの上40・下24 で全幅。窓は帯の下の境目をまたぐ */
.stage { position: relative; margin-top: 80px; display: grid; grid-template-columns: 540px minmax(0, 1fr); column-gap: 24px; align-items: start; }
.stage-win { display: block; margin: 0; aspect-ratio: 16 / 9; background: var(--win-bg); }
.stage-win img { display: block; width: 100%; height: 100%; object-fit: cover; }
.mside { display: flex; flex-direction: column; align-items: stretch; }
.mt { position: relative; }
.mt::before { content: ""; position: absolute; left: -100vw; right: -100vw; top: -40px; bottom: -24px; background: var(--stage-band); z-index: -1; }
.mtitle { margin: 0; font-size: 40px; line-height: 1.25; font-weight: 700; letter-spacing: .01em; color: var(--text); }
.mtitle .ph, .ctitle .ph { display: inline-block; }
.ftag { align-self: flex-start; display: inline-block; margin: 0; padding: 6px 8px; border: 1px solid var(--text); background: #fff; color: var(--text); font-size: 13px; line-height: 1; font-weight: 700; white-space: nowrap; }
.mside .ftag { margin-top: 48px; }
.mside .button { width: 100%; margin-top: 12px; padding: 0 16px; font-size: 17px; letter-spacing: .02em; }
.mdesc { margin: 20px 0 0; font-size: 15px; line-height: 1.7; color: var(--text); word-break: auto-phrase; }
.mrow { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: 48px; }
.mrow .ftag, .mside .mrow .ftag { margin: 0; }
.mrow .tag { margin: 0; }

/* ③ カード3列：枠の内側20・窓 16:9・形式のラベル・題 20px・説明 15px（2行で切る 16-18-5 の3）・枠のボタン（下端を1本）。間 24 */
.sec-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; column-gap: 16px; row-gap: 8px; margin: 96px 0 24px; }
.sec-h2 { margin: 0; font-size: 24px; line-height: 1.4; font-weight: 700; color: var(--text); }
.tlink { font-size: 15px; line-height: 1.6; font-weight: 700; color: var(--main); text-decoration: underline; text-underline-offset: 4px; }
.tlink:hover { color: var(--main-dark); text-decoration-thickness: 2px; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.cards.after-stage { margin-top: 72px; }
.card { display: flex; flex-direction: column; padding: 20px; background: #fff; border: 1px solid var(--card-line); }
.win { margin: 0; aspect-ratio: 16 / 9; background: var(--win-bg); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.win img { display: block; width: 100%; height: 100%; object-fit: contain; }
a.win, a.stage-win { color: inherit; text-decoration: none; }

/* 11b 中身の窓：資料の表紙（部品11 の型違い・カンプ comp-4d.css の写し・裁定書 18章・★G3-5 承認 2026-11-23）。
   出るのは PDF だけのページ（動画が無い・子に PDF がある・thumb_key がある）。セレクタは全部 .doc を含め、動画のページと一覧の窓に当てない。
   窓の地・16:9・絵を切らずに置く値は一覧の窓 .win のまま。1280 は 560×315（カバーの箱と同じ幅）、959px 以下は列いっぱい */
.win.doc { display: flex; width: 560px; max-width: 100%; margin-top: 24px; }
a.win.doc { cursor: pointer; }
/* 未登録：窓は覆いの外（1文との間は p.lead の下の余白が効き、動画の枠と同じ y）。覆いは1段落目の上だけ（18-4） */
.teaser-wrap.doc .win.doc { margin-top: 0; }
.teaser-wrap.doc .teaser .body { position: relative; }
.teaser-wrap.doc .teaser .body::after { content: ""; position: absolute; inset: 0; background: rgba(255, 255, 255, .82); }
.teaser-wrap.doc .cover { background: transparent; }
/* 動画の無い行では 16:9 の空きを確保しない（K32） */
.teaser-wrap.doc .cover::before { display: none; }
/* 箱の上端＝表紙の上端＋表紙の高さ×2/3（315×2/3＝210）。箱の左右の端＝表紙の左右の端 */
.teaser-wrap.doc .cover-box { align-self: start; justify-self: start; margin-top: 210px; }
/* K39：後ろの段（表紙と1段落目）は高さを持たず、升の高さ＝カバーの側で決める。1段落目が長くても箱の下端より下に字を出さない */
.teaser-wrap.doc .teaser { contain: size; overflow: hidden; }
/* 4d-2（K39）：1280 では1段落目の幅を表紙と同じ 560px にして、箱の右に字の切れ端を出さない */
@media (min-width: 960px) {
  .teaser-wrap.doc .teaser .body { width: 560px; max-width: 100%; }
}
@media (max-width: 959px) {
  .win.doc { width: 100%; margin-top: 20px; }
  .teaser-wrap.doc .win.doc { margin-top: 0; }
  /* 動画のページと同じ置き方：上端は列の幅の 37.5%（＝16:9 の高さの 2/3）。箱は列いっぱい */
  .teaser-wrap.doc .cover-box { margin-top: 37.5%; }
  /* K39：カバーの下の 16px の余白（.cover の padding）の分だけ後ろの段を短くし、箱の下端で切る */
  .teaser-wrap.doc .teaser { margin-bottom: 16px; }
}
/* 11b-end */

.card .ftag { margin-top: 16px; }
.ctitle { margin: 10px 0 0; min-height: 56px; font-size: 20px; line-height: 1.4; font-weight: 700; color: var(--text); }
.cbody { margin: 6px 0 20px; font-size: 15px; line-height: 1.7; color: var(--text); word-break: auto-phrase; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.cfoot { margin-top: auto; display: flex; flex-direction: column; align-items: stretch; }
.cmeta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin: 0 0 16px; }
.cmeta .tag { margin: 0; }
.cdate { font-size: 13px; line-height: 1.5; color: var(--text); }
/* 見られない人への札（混ざる一覧だけ・K27）はボタンの真上 */
.cfoot .tag.lock { align-self: flex-start; margin: 0 0 12px; }
.btn-line { display: flex; align-items: center; justify-content: center; width: 100%; min-height: 44px; margin-top: 0; padding: 0 8px; border: 2px solid var(--main); border-radius: 22px; background: #fff; color: var(--main); font-size: 15px; line-height: 1.3; font-weight: 700; text-decoration: none; }
.btn-line:hover { background: var(--line-hover); }

/* 代わりの窓（/notes・/lab だけ・16-5）：無彩色の淡色の地＋再生の印（押せる窓だけ・K30）＋長さ。題の字は入れない */
.alt { position: relative; display: flex; align-items: center; justify-content: center; background: #E3E4E6; box-shadow: inset 0 0 0 1px #C9CCD1; }
.alt .play { position: relative; display: block; width: 56px; height: 56px; border-radius: 50%; background: #fff; }
.alt .play::after { content: ""; position: absolute; left: 22px; top: 17px; border-style: solid; border-width: 11px 0 11px 17px; border-color: transparent transparent transparent #333; }
.stage-win.alt .play { width: 72px; height: 72px; }
.stage-win.alt .play::after { left: 29px; top: 22px; border-width: 14px 0 14px 22px; }
.alt .dur { position: absolute; right: 8px; bottom: 8px; padding: 2px 6px; background: #333; color: #fff; font-size: 13px; line-height: 1.4; font-weight: 700; letter-spacing: .02em; }
.stage-win.alt .dur { right: 12px; bottom: 12px; font-size: 14px; }

/* ④ 準備中の帯（窓を持たない）：見出しの行＋3つの列／1件の形（prep1）／0件の説明の形（prep0） */
.prep { margin-top: 24px; padding: 28px 32px; background: #fff; border: 1px solid var(--card-line); }
.listing .prep.first { margin-top: 40px; }
/* 主の段の次に見出しを持たない面（準備中の帯）が来るときの間は、.cards.after-stage と同じ 72px（390 は 56px）。K31・裁定書 17-1 の1 */
.stage-sec + .prep-sec .prep { margin-top: 72px; }
.p3head { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); column-gap: 24px; align-items: start; }
.p3head h3 { margin: 0; font-size: 20px; line-height: 1.4; font-weight: 700; color: var(--text); word-break: auto-phrase; }
.p3head p { margin: 4px 0 0; font-size: 15px; line-height: 1.7; color: var(--text); }
.p3head .plink { margin: 0; text-align: right; }
.prep0 .p3head p { max-width: 36em; }
.p3grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); margin-top: 20px; border-top: 1px solid var(--card-line); }
.p3grid > div { display: flex; flex-direction: column; align-items: flex-start; padding: 20px 24px 4px; }
.p3grid > div:first-child { padding-left: 0; }
.p3grid > div:last-child { padding-right: 0; }
.p3grid > div + div { border-left: 1px solid var(--card-line); }
.p3t { margin: 10px 0 0; font-size: 17px; line-height: 1.45; font-weight: 700; color: var(--text); word-break: auto-phrase; }
.prep1 { display: grid; grid-template-columns: minmax(0, 39fr) minmax(0, 61fr); column-gap: 40px; align-items: start; }
.prep1 h3 { margin: 10px 0 0; font-size: 20px; line-height: 1.4; font-weight: 700; color: var(--text); word-break: auto-phrase; }
.prep1 p.pbody { margin: 0; font-size: 15px; line-height: 1.7; color: var(--text); word-break: auto-phrase; }
/* 1件の形の文字リンク（説明の下・comp-4c2.css の値）。行に text_link_url があるときだけ出る */
.prep1 .plink { margin: 12px 0 0; }
@supports not (word-break: auto-phrase) {
  .p3head h3 { word-break: keep-all; }
  .prep1 p.pbody { word-break: keep-all; }
}

/* ご利用にあたって（/free だけ） */
.use { margin: 96px 0 0; padding-top: 32px; border-top: 1px solid var(--card-line); }
.use h2 { margin: 0; font-size: 16px; line-height: 1.5; font-weight: 700; color: var(--text); }
.use ul { margin: 12px 0 0; padding-left: 1.2em; }
.use li { font-size: 14px; line-height: 1.75; color: var(--text); }

/* 有料の帯（第3段階から・部品22）：全幅・地 #E0E1E3・見出しの左に塗りの札「有料」 */
.paidband { margin-top: 96px; padding: 64px 0; background: #E0E1E3; }
.h2-paid { display: flex; align-items: center; gap: 12px; margin: 0; font-size: 24px; line-height: 1.4; font-weight: 700; color: var(--text); }
.paid { display: inline-flex; align-items: center; height: 26px; padding: 0 9px; background: #333; color: #fff; font-size: 13px; line-height: 1; font-weight: 700; letter-spacing: .06em; }
.paidlead { margin: 12px 0 28px; font-size: 15px; line-height: 1.7; color: var(--text); }

/* 絞り込みの札の行（10件以上で出す・部品23）：現在地は塗りでなく下線2px と太字 */
.filters { display: flex; flex-wrap: wrap; gap: 4px 4px; margin: 32px 0 0; padding: 0; list-style: none; border-bottom: 1px solid var(--card-line); }
.filters a { position: relative; display: block; padding: 10px 12px 12px; font-size: 15px; line-height: 1.4; color: var(--text); text-decoration: none; }
.filters li:first-child a { padding-left: 0; }
.filters a::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: -1px; height: 2px; background: var(--main); opacity: 0; }
.filters li:first-child a::after { left: 0; }
.filters a[aria-current="page"] { font-weight: 700; }
.filters a[aria-current="page"]::after, .filters a:hover::after { opacity: 1; }
.filters a:hover { color: var(--main); }
.listing .filters + .stage { margin-top: 56px; }
.more { margin: 32px 0 0; }

/* 手元の設定のときだけ出す仮の注記（測る対象の外・16-5）：画面の右下に1つ */
.guide.kari-note { position: absolute; right: 16px; bottom: 24px; margin: 0; padding: 4px 10px; border: 1px dashed var(--text); background: #fff; color: var(--text); font-size: 12px; line-height: 1.5; font-weight: 700; }

/* ---- 一覧の型の狭い幅（959px 以下）：列の左右は中身のページと同じ 19.5（x19.5） ---- */
@media (max-width: 959px) {
  .wrap { padding: 0 19.5px; }
  main.listing { padding-bottom: 84px; }
  .intro { padding-top: 32px; }
  .ptitle { font-size: 24px; }
  .plead { font-size: 15px; line-height: 1.7; }
  .stage { margin-top: 36px; grid-template-columns: minmax(0, 1fr); row-gap: 16px; }
  .stage::before { content: ""; position: absolute; left: -100vw; right: -100vw; top: -16px; height: 144px; background: var(--stage-band); z-index: -1; }
  .mt::before { content: none; }
  .mside .ftag { order: -1; margin-top: 0; }
  .mt { padding-top: 8px; }
  /* 題は 40px のまま（390 の本文 15.6px に対して 2.5倍を割らないため・カンプ README-4c1 の迷って決めたこと 4） */
  .mside .button { margin-top: 14px; height: 52px; font-size: 16px; }
  .mrow { margin-top: 0; order: -1; }
  .mside .mrow + .mt { padding-top: 8px; }
  .sec-head { margin: 72px 0 20px; }
  .sec-h2 { font-size: 22px; }
  .cards { grid-template-columns: minmax(0, 1fr); gap: 21px; }
  .cards.after-stage { margin-top: 56px; }
  .ctitle { min-height: 0; }
  .prep { padding: 20px; }
  .listing .prep.first { margin-top: 32px; }
  .stage-sec + .prep-sec .prep { margin-top: 56px; }
  .p3head { grid-template-columns: minmax(0, 1fr); row-gap: 10px; }
  .p3head .plink { text-align: left; }
  .p3grid { grid-template-columns: minmax(0, 1fr); margin-top: 16px; }
  .p3grid > div, .p3grid > div:first-child, .p3grid > div:last-child { padding: 16px 0; }
  .p3grid > div + div { border-left: 0; border-top: 1px solid var(--card-line); }
  .prep1 { grid-template-columns: minmax(0, 1fr); row-gap: 12px; }
  .use { margin-top: 72px; }
  .paidband { margin-top: 72px; padding: 48px 0; }
  .guide.kari-note { right: 8px; bottom: 16px; }
}

