:root{--primary:#4a72e9;--link:#3658c0;--primary-dark:#222c36;--text:#222c36;--sub-text:#5f6169;--light-bg:#f4f6fb;--line:#d9d9d9;--gradient:linear-gradient(90deg,#62e2a3 0%,#2fbbdc 50%,#4a72e9 100%);}
/* ヘルプセンター共通のスタイル。色は build.mjs が :root の変数として先頭に足す（site.config.json の colors）。
   白ベース・Noto Sans JP のみ・角丸の箱を多用しない・本文 16px 以上・横スクロールを出さない。 */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: #fff;
  color: var(--text);
  font-family: "Noto Sans JP", sans-serif;
  font-size: 17px;
  line-height: 1.85;
  overflow-wrap: anywhere;
}
a { color: var(--link); text-underline-offset: 0.18em; }
a:hover { color: var(--primary-dark); }
:focus-visible { outline: 3px solid var(--link); outline-offset: 2px; }
img { max-width: 100%; height: auto; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; background: #fff; padding: 8px 12px; z-index: 10; }

/* ヘッダー */
.site-header { border-bottom: 1px solid var(--line); position: relative; }
.site-header::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: var(--gradient); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding-top: 14px; padding-bottom: 14px; flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text); font-weight: 700; font-size: 16px; }
.brand img { height: 32px; width: auto; display: block; }
/* ロゴの画像は下に吹き出しのしっぽの余白があり、箱の中心で揃えると「ヘルプセンター」が約 3px 下がって見える。
   ロゴの文字（RepeaTalk）の中心に合わせて文字の大きさの 0.18 倍だけ上げる（2026-11-17 実測: 16px で 2.9px のずれ） */
.brand span { border-left: 1px solid var(--line); padding-left: 12px; white-space: nowrap; }
.site-repeatalk .brand span { position: relative; top: -0.18em; }
.search { display: flex; flex: 1 1 280px; max-width: 420px; }
.search input { flex: 1; min-width: 0; font: inherit; font-size: 16px; padding: 8px 12px; border: 1px solid #8a8d96; border-right: 0; border-radius: 0; background: #fff; color: var(--text); }
.search button, .button {
  font: inherit; font-size: 16px; font-weight: 700; background: var(--link); color: #fff; border: 1px solid var(--link);
  padding: 8px 18px; cursor: pointer; text-decoration: none; display: inline-block; border-radius: 0;
}
.search button:hover, .button:hover { background: var(--primary-dark); border-color: var(--primary-dark); color: #fff; }
/* チャットが無いぶん、どのページからも 1 手で問い合わせへ行けるようにヘッダーに常に出す */
.header-contact { font-weight: 700; font-size: 16px; color: var(--link); border: 2px solid var(--link); background: #fff; padding: 6px 14px; text-decoration: none; white-space: nowrap; }
.header-contact:hover { background: var(--link); color: #fff; }
.header-contact[aria-current] { background: var(--light-bg); }
/* お問い合わせのページにいるとき: 上の行の薄い背景がマウスを載せたときの塗りより強く、白い文字が見えなくなっていた（2026-11-17 小泉さん指摘）。載せたときは塗りに戻す */
.header-contact[aria-current]:hover { background: var(--link); color: #fff; }

/* パンくず */
.crumbs ol { list-style: none; margin: 20px 0 0; padding: 0; display: flex; flex-wrap: wrap; font-size: 15px; color: var(--sub-text); }
.crumbs li + li::before { content: "›"; margin: 0 8px; color: var(--sub-text); }
.crumbs a { color: var(--sub-text); }

main, main.wrap { padding-bottom: 72px; }
h1 { font-size: 30px; line-height: 1.45; margin: 24px 0 12px; letter-spacing: 0.02em; }
h2 { font-size: 22px; line-height: 1.5; letter-spacing: 0.02em; }
.lead { color: var(--sub-text); margin-top: 0; }
.thin { font-weight: 300; }
.nb { display: inline-block; }
/* 英字の小見出し（セクションラベル）。左にブランドのグラデーションの短い線 */
.eyebrow { margin: 0; font-size: 13px; font-weight: 700; letter-spacing: 0.2em; color: var(--sub-text); text-transform: uppercase; display: flex; align-items: center; gap: 10px; }
.eyebrow::before { content: ""; width: 28px; height: 2px; background: var(--gradient); flex: none; }
.block { margin-top: 72px; }
.block-head h2 { font-size: clamp(24px, 3vw, 32px); margin: 6px 0 20px; line-height: 1.4; }

/* トップ（白地・余白で区切る。角丸・塗りの箱は使わない） */
.hero { padding: 72px 0 8px; text-align: center; }
.hero .eyebrow { justify-content: center; }
.hero h1 { margin: 10px 0 6px; font-size: clamp(32px, 4.6vw, 48px); line-height: 1.35; }
.hero-lead { margin: 0 0 28px; font-size: 18px; color: var(--sub-text); }
.hero .search { margin: 0 auto; max-width: 640px; }
.hero .search input { padding: 14px 18px; font-size: 17px; }
.hero .search button { padding: 0 32px; }

/* よくある質問 */
.faq-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); column-gap: 48px; border-top: 1px solid var(--line); }
.faq-list li { border-bottom: 1px solid var(--line); }
.faq-list a { display: flex; align-items: baseline; gap: 14px; padding: 18px 4px; color: var(--text); text-decoration: none; }
.faq-q { font-size: 20px; font-weight: 700; color: var(--link); line-height: 1; flex: none; }
.faq-t { flex: 1; font-weight: 700; }
.faq-role { font-size: 14px; font-weight: 700; color: var(--sub-text); flex: none; }
.faq-go { color: var(--link); flex: none; transition: transform .15s; }
.faq-list a:hover .faq-t { text-decoration: underline; text-underline-offset: 0.2em; }
.faq-list a:hover .faq-go { transform: translateX(4px); }

/* 立場ごとの入口（topLayout: split）。枠で囲まず、上下の罫線と縦線で区切る */
.role-cards { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.role-card { display: flex; flex-direction: column; gap: 10px; padding: 36px 40px 32px; color: var(--text); text-decoration: none; transition: background .15s; }
.role-card + .role-card { border-left: 1px solid var(--line); }
.role-card:hover { background: var(--light-bg); color: var(--text); }
.role-card-en { font-size: 13px; font-weight: 700; letter-spacing: 0.2em; color: var(--sub-text); }
.role-card-label { font-size: 28px; font-weight: 700; line-height: 1.35; }
.role-card-lead { color: var(--sub-text); }
.role-card-secs { font-size: 15px; color: var(--sub-text); }
.role-card-secs .sec-name { display: inline-block; }
.role-card-secs .sec-name:not(:last-child)::after { content: "／"; margin: 0 8px; color: var(--line); }
.role-card-go { margin-top: auto; padding-top: 12px; font-weight: 700; color: var(--link); }
.role-card:hover .role-card-go { text-decoration: underline; text-underline-offset: 0.2em; }

/* 先生／生徒の色分け（色＝役割）。生徒＝リピートークの青（音読と同じ）・先生＝紫（ブランドのグラデーションの紫・AIP のように区別）。
   文字の色は白地でコントラスト 4.5:1 以上（生徒 6.2・先生 6.0）。印（四角・上の帯）は飾りなので明るい色 */
/* --role-label / --role-on: 札（塗り）はブランドガイドの色そのまま。文字の色は塗りに合わせて白か黒（2026-11-17 小泉さん「デザインガイドラインの色じゃなくない？」）。
   --role: 白地に置く小さな文字の色。ガイドラインの明るい紫・緑は白地で読めない（1.6〜3.9:1）ので、同じ色の濃いめを使う */
.role-student { --role: #0A58D5; --role-mark: #2F6EED; --role-bg: #F2F5FF; --role-label: #0A58D5; --role-on: #FFFFFF; }
.role-teacher { --role: #6747D9; --role-mark: #8C69ED; --role-bg: #F6F3FF; --role-label: #8C69ED; --role-on: #16171A; }
/* KOOM の立場（ロゴのグラデーションの青と緑）。文字の色は白地で 管理者 6.3・先生 5.3 */
.role-admin { --role: #3658C0; --role-mark: #4A72E9; --role-bg: #EEF2FD; --role-label: #4A72E9; --role-on: #FFFFFF; }
.role-user { --role: #0B7A55; --role-mark: #62E2A3; --role-bg: #EAF8F1; --role-label: #62E2A3; --role-on: #222C36; }
.role-card { box-shadow: inset 0 4px 0 var(--role-mark, transparent); }
.role-card .role-card-en { color: var(--role, var(--sub-text)); }
.role-card .role-card-go { color: var(--role, var(--link)); }
.role-card:hover { background: var(--role-bg, var(--light-bg)); }
.faq-role { color: var(--role, var(--sub-text)); }
.faq-list .faq-q, .faq-list .faq-go { color: var(--role, var(--link)); }
/* 立場の札: 角丸の四角で囲む（2026-11-17 小泉さん「ラベルで角丸矩形で囲む」。ピル形にはしない）。
   枠の線はブランドガイドの色そのまま（--role-label）、中はごく薄い同じ色（--role-bg）、文字は読める濃さの同じ系統（--role）。
   塗りつぶしにすると、ガイドラインの明るい紫・緑では白い文字も黒い文字も読みにくかった（「ちょっとみれないかも」）。
   文字と地のコントラストは RT 生徒 5.7・RT 先生 5.5・KOOM 管理者 5.7・KOOM 先生 4.9 */
.faq-role.role-student, .faq-role.role-teacher, .faq-role.role-admin, .faq-role.role-user,
.article-role.role-student, .article-role.role-teacher, .article-role.role-admin, .article-role.role-user {
  display: inline-block; background: var(--role-bg); color: var(--role); border: 1.5px solid var(--role-label, var(--role)); padding: 1px 9px; border-radius: 4px;
  font-size: 13px; font-weight: 700; line-height: 1.6; letter-spacing: 0.04em;
}
.page-head .eyebrow { color: var(--role, var(--sub-text)); }
.page-head.role-student .eyebrow::before, .page-head.role-teacher .eyebrow::before, .page-head.role-admin .eyebrow::before, .page-head.role-user .eyebrow::before { background: var(--role-mark); }

/* 立場ごとのページ（カテゴリ） */
.page-head { padding: 32px 0 0; }
.page-head h1 { font-size: clamp(28px, 3.6vw, 40px); margin: 10px 0 8px; }
.role-switch { margin: 12px 0 0; font-size: 15px; }
.role-switch a { text-decoration: none; font-weight: 700; }
.role-switch a:hover { text-decoration: underline; }
.page-head + .block { margin-top: 48px; }
.sec-boxes { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 48px 48px; }
.sec-box h3 { font-size: 20px; margin: 0 0 4px; padding-bottom: 12px; background: var(--gradient) left bottom / 100% 2px no-repeat; display: flex; align-items: baseline; gap: 10px; }
.sec-box h3 a { color: var(--text); text-decoration: none; }
.sec-box h3 a:hover { text-decoration: underline; }
.sec-box .count { font-size: 14px; font-weight: 400; color: var(--sub-text); }
.more { display: inline-block; margin-top: 12px; font-size: 15px; font-weight: 700; text-decoration: none; }
.more:hover { text-decoration: underline; }

/* 全セクションを並べるトップ（topLayout: list・KOOM） */
.category { margin-top: 56px; }
.category > h2 { margin: 0 0 4px; padding-bottom: 10px; background: var(--gradient) left bottom / 100% 2px no-repeat; }
.category > h2 a { color: var(--text); text-decoration: none; }
.category > h2 a:hover { text-decoration: underline; }
.sections { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 8px 48px; }
.section-block h3 { font-size: 18px; margin: 24px 0 6px; }
.section-block h3 a { color: var(--text); text-decoration: none; }
.section-block h3 a:hover { text-decoration: underline; }

/* 記事の一覧（下線はマウスを載せたときだけ） */
.article-list { list-style: none; padding: 0; margin: 0; }
.article-list li { border-bottom: 1px solid var(--line); }
.article-list a { display: block; padding: 12px 0; text-decoration: none; }
.article-list a:hover { text-decoration: underline; text-underline-offset: 0.2em; }

/* 記事 */
.article-head { margin-bottom: 28px; padding-bottom: 20px; border-bottom: 1px solid var(--line); }
.article-role { margin: 28px 0 0; font-size: 14px; font-weight: 700; letter-spacing: 0.08em; color: var(--role, var(--link)); }
.article-head h1 { margin-top: 6px; font-size: clamp(26px, 3vw, 34px); }
.article-meta { color: var(--sub-text); font-size: 15px; margin: 0; }
.article-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 56px; }
.article-layout > * { min-width: 0; }
@media (max-width: 860px) { .article-layout { grid-template-columns: minmax(0, 1fr); gap: 24px; } }
.toc { margin: 0 0 36px; padding: 20px 24px; border: 1px solid var(--line); }
.toc-title { margin: 0 0 8px; font-size: 13px; font-weight: 700; letter-spacing: 0.2em; color: var(--sub-text); }
.toc ol { list-style: none; margin: 0; padding: 0; }
.toc li { padding: 4px 0; }
.toc .toc-l3 { padding-left: 1.2em; font-size: 15px; }
.toc a { text-decoration: none; }
.toc a:hover { text-decoration: underline; }
.article-body { font-size: 17px; }
.article-body p { margin: 0 0 1em; }
.article-body h2 { font-size: 23px; margin: 2.2em 0 0.8em; padding-bottom: 10px; background: var(--gradient) left bottom / 100% 2px no-repeat; }
.article-body h3 { font-size: 20px; margin: 2em 0 0.6em; padding-left: 12px; border-left: 3px solid var(--text); line-height: 1.5; }
.article-body h4 { font-size: 18px; margin: 1.6em 0 0.5em; }
.article-body img { margin: 12px 0; border: 1px solid var(--line); }
.article-body figure { margin: 1em 0; }
.article-body table { border-collapse: collapse; display: block; overflow-x: auto; max-width: 100%; }
.article-body td, .article-body th { border: 1px solid var(--line); padding: 6px 10px; vertical-align: top; }
.article-body pre { overflow-x: auto; background: var(--light-bg); padding: 12px; font-size: 15px; }
.article-body iframe { max-width: 100%; width: 560px; height: auto; aspect-ratio: 16 / 9; border: 0; }
.article-body hr { border: 0; border-top: 1px solid var(--line); margin: 2.4em 0; }
.attachments { margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--line); }
.attachments h2 { font-size: 19px; margin: 0 0 8px; }
.attachments ul { padding-left: 1.2em; margin: 0; }
.side { padding-top: 28px; }
.side h2 { font-size: 17px; margin: 0 0 4px; padding-bottom: 10px; background: var(--gradient) left bottom / 100% 2px no-repeat; }
.side .article-list a { font-size: 15px; padding: 10px 0; }
.side .article-list [aria-current] { font-weight: 700; color: var(--text); }
/* 問い合わせへの案内（全ページ）。塗りは薄い地色だけ・角丸なし */
.contact-box { margin-top: 64px; padding: 28px 32px; background: var(--light-bg); display: flex; align-items: center; justify-content: space-between; gap: 16px 24px; flex-wrap: wrap; }
.contact-lead { margin: 0; font-weight: 700; }

/* 検索 */
.results { list-style: none; padding: 0; }
.results li { border-bottom: 1px solid var(--line); padding: 14px 0; }
.results a { font-weight: 700; font-size: 18px; }
.results .where { color: var(--sub-text); font-size: 14px; margin: 2px 0; }
.results .snippet { margin: 4px 0 0; font-size: 15px; }
mark { background: #fff3a8; color: inherit; }

/* フォーム */
.chooser { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin: 24px 0; }
.chooser a { display: block; padding: 20px; border: 1px solid var(--line); border-left: 4px solid var(--link); font-weight: 700; font-size: 18px; text-decoration: none; }
.chooser a:hover { background: var(--light-bg); }
.notice { padding: 12px 16px; border-left: 4px solid #b42318; background: #fef3f2; margin: 16px 0; }
.form { max-width: 720px; }
.field { margin: 0 0 22px; }
.field[hidden] { display: none; }
.field > label, .field > .label { display: block; font-weight: 700; margin-bottom: 4px; }
.req { color: #b42318; font-size: 14px; font-weight: 700; margin-left: 6px; }
.help { color: var(--sub-text); font-size: 15px; margin: 0 0 6px; }
.field input[type=text], .field input[type=email], .field select, .field textarea {
  width: 100%; font: inherit; font-size: 16px; padding: 10px 12px; border: 1px solid #8a8d96; border-radius: 0; background: #fff; color: var(--text);
}
.field textarea { min-height: 200px; resize: vertical; }
.field .check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; }
.field .check input { width: 20px; height: 20px; margin-top: 5px; flex: none; }
.field.has-error input, .field.has-error select, .field.has-error textarea { border-color: #b42318; border-width: 2px; }
.error { color: #b42318; font-size: 15px; margin: 4px 0 0; font-weight: 700; }
.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.form-status { margin: 16px 0; }
.field-images input[type=file] { font: inherit; font-size: 15px; max-width: 100%; }
.image-list { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 8px; }
.image-list:empty { display: none; }
.image-list li { display: flex; align-items: center; gap: 12px; padding: 8px; border: 1px solid var(--line); background: #fff; }
.image-list img { width: 64px; height: 64px; object-fit: cover; flex: none; background: var(--light-bg); }
.image-name { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: 15px; }
.image-remove { flex: none; font: inherit; font-size: 14px; padding: 6px 12px; border: 1px solid var(--line); background: #fff; color: var(--text); cursor: pointer; }
.image-remove:hover { border-color: var(--sub-text); }
.image-status { color: var(--sub-text); font-size: 15px; margin: 6px 0 0; }
.image-status:empty { display: none; }
.form-note { color: var(--sub-text); font-size: 15px; margin: 0 0 16px; padding: 10px 14px; background: var(--light-bg); }
.fallback { padding: 16px 20px; border-left: 4px solid #b42318; background: #fef3f2; }
.fallback textarea { width: 100%; min-height: 160px; font: inherit; font-size: 15px; margin-top: 8px; }
.done { padding: 20px 24px; border-left: 4px solid #067647; background: #ecfdf3; }
button[disabled] { opacity: 0.6; cursor: wait; }

/* フッター */
.site-footer { border-top: 1px solid var(--line); background: #fff; font-size: 15px; }
.footer-inner { padding-top: 24px; padding-bottom: 32px; }
.footer-links { list-style: none; padding: 0; margin: 0 0 8px; display: flex; flex-wrap: wrap; gap: 8px 24px; }
.operator { margin: 0; color: var(--sub-text); }

@media (max-width: 600px) {
  body { font-size: 16px; }
  h1 { font-size: 26px; }
  .brand img { height: 26px; }
  .search { max-width: none; flex-basis: 100%; order: 3; }
  .wrap { padding: 0 16px; }
  .hero { padding: 40px 0 0; }
  .block { margin-top: 56px; }
  .faq-list { grid-template-columns: minmax(0, 1fr); }
  .role-cards { grid-template-columns: minmax(0, 1fr); }
  .role-card { padding: 28px 4px; }
  .role-card + .role-card { border-left: 0; border-top: 1px solid var(--line); }
  .role-card-label { font-size: 24px; }
  .sec-boxes { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .contact-box { padding: 24px 20px; }
  .toc { padding: 16px 18px; }
  .header-inner.wrap { gap: 8px; padding-top: 10px; padding-bottom: 10px; }
  .brand { gap: 8px; font-size: 14px; }
  .brand span { padding-left: 8px; }
  .header-contact { order: 2; font-size: 15px; padding: 4px 8px; }
  .article-body { font-size: 16px; }
}

/* ===== 丸み（リピートーク・KOOM 共通）（2026-11-17 小泉さん「RT ってこんなに直線的なイメージだっけ」） =====
   ロゴの吹き出し・アプリのボタンに合わせて角を丸める。KOOM も同じ（2026-11-17 小泉さん「KOOM もおなじでいいよ」）。body を頭に付けて元の指定より強くしている。
   ボタンと検索欄は両端の丸い形、箱（入口・問い合わせの案内・目次・入力欄）は角 16px（ブランドガイドの角丸）。 */
body { --r-box: 16px; --r-field: 10px; }
body .button, body .header-contact { border-radius: 999px; }
body .header-contact { padding-left: 18px; padding-right: 18px; }
body .search input { border-radius: 999px 0 0 999px; padding-left: 18px; }
body .search button { border-radius: 0 999px 999px 0; padding-right: 22px; }
/* 立場の入口: 丸い角の 2 枚のカード。上に太い色の帯は付けない（角の丸みと重なって M 字に曲がり、AI が作ったような見た目になる・2026-11-17 小泉さん）。立場の色は英字と「〜へ」の文字、マウスを載せたときの枠で出す */
body .role-cards { border: 0; gap: 24px; }
body .role-card { border: 1px solid var(--line); border-radius: var(--r-box); box-shadow: none; }
body .role-card + .role-card { border-left: 1px solid var(--line); }
body .role-card:hover { border-color: var(--role-mark, var(--link)); }
body .contact-box { border-radius: var(--r-box); }
body .toc { border-radius: var(--r-box); }
body .form-note, body .notice, body .fallback, body .done { border-radius: var(--r-field); }
body .field input[type=text], body .field input[type=email], body .field select, body .field textarea { border-radius: var(--r-field); }
body .article-body img { border-radius: 8px; }
/* お問い合わせの入口（立場のカード） */
.chooser-cards { margin: 24px 0 8px; }
.role-card-note { display: inline-block; align-self: flex-start; font-size: 14px; font-weight: 700; color: var(--role, var(--text)); background: var(--role-bg, var(--light-bg)); padding: 2px 10px; border-radius: 6px; }
@media (max-width: 600px) {
  body .role-cards { gap: 16px; }
  body .role-card { padding: 24px 20px; }
  body .role-card + .role-card { border-left: 1px solid var(--line); border-top: 1px solid var(--line); }
}
