/* 技能継承 LP。素の CSS。色・余白の目安は明るい青系、角は大きく丸める */
:root {
  --bg: #f8fafc;
  --text: #1f2937;
  --muted: #64748b;
  --line: #e2e8f0;
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --soft: #eff6ff;
  --card: #ffffff;
  --rose-bg: #fff1f2;
  --rose-text: #be123c;
  --max: 72rem;
  --radius: 1.5rem;
  --header-h: 4rem;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 1rem); -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", "Noto Sans JP", system-ui, -apple-system, "Hiragino Sans", sans-serif;
  font-size: 1.0625rem;
  line-height: 1.8;
  overflow-x: hidden;
  /* 日本語を単語の途中で切らない。区切りは句読点と <wbr>。はみ出すときだけどこでも折る */
  word-break: keep-all;
  overflow-wrap: anywhere;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3, p { margin: 0; }
h1, h2, h3 { line-height: 1.4; letter-spacing: -0.01em; font-weight: 700; }
h1, h2, h3, p, li, summary, figcaption, label { word-break: keep-all; overflow-wrap: anywhere; }

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 1.5rem; }
.wrap.narrow { max-width: 52rem; }

/* ── ヘッダー ── */
.site-header {
  position: sticky; top: 0; z-index: 10;
  background: rgba(248, 250, 252, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap { max-width: 80rem; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: var(--header-h); }
.brand { font-weight: 700; font-size: 1.125rem; text-decoration: none; letter-spacing: 0.04em; white-space: nowrap; }
.nav { display: flex; align-items: center; gap: 0.25rem; }
.nav a { text-decoration: none; font-size: 0.9375rem; color: var(--muted); padding: 0.4rem 0.75rem; border-radius: 999px; white-space: nowrap; }
.nav a:hover { color: var(--text); background: #eef2f7; }
.nav .nav-cta { color: #fff; background: var(--primary); margin-left: 0.5rem; }
.nav .nav-cta:hover { background: var(--primary-dark); color: #fff; }

/* ── 共通 ── */
.section { padding: 8rem 0 0; }
.label { font-size: 0.8125rem; font-weight: 700; letter-spacing: 0.12em; color: var(--primary); }
.heading { display: flex; flex-direction: column; gap: 0.9rem; }
.heading.center { align-items: center; text-align: center; }
.heading h2 { font-size: clamp(1.75rem, 1.2rem + 2.2vw, 2.6rem); }
.lead { color: var(--muted); max-width: 40rem; font-size: 1.0625rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  padding: 0.9rem 1.6rem; border-radius: 999px; font-weight: 700; font-size: 1rem;
  text-decoration: none; border: 1px solid transparent; cursor: pointer; font-family: inherit;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); }
.btn-ghost { background: var(--card); border-color: var(--line); color: var(--text); }
.btn-ghost:hover { border-color: #cbd5e1; }
.btn:disabled { background: #cbd5e1; color: #fff; cursor: not-allowed; }

.shot { margin: 0; }
.shot img { border-radius: var(--radius); border: 1px solid var(--line); background: #fff; box-shadow: 0 24px 48px -24px rgba(15, 23, 42, 0.18); }
.shot figcaption { margin-top: 0.75rem; font-size: 0.8125rem; color: var(--muted); line-height: 1.6; }

/* ── ヒーロー（上に大きな見出し、下に学習サイクルのフローを全幅で。PC 1440x900 でヘッダー込みで収める） ──
   フローは無地の上に、細い線と丸・ひし形のノード、小さなタグだけ（方眼や外枠は使わない）。
   全面ダークにはしない（暗いと見づらいため）。インクは濃紺〜スレート、赤／橙はエラーと「分からない」だけ。
   余白は 4/8/12/16/24 の刻み */
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.hero { --ink: #0f1e36; --slate: #475569; --edge: #e2e8f0; padding: 1.5rem 0 1rem; display: flex; flex-direction: column; }
.hero-grid { max-width: 80rem; display: flex; flex-direction: column; gap: 1.25rem; }
/* 見出し：PC は1行。狭いと「、」のあとで2行、スマホは3行（ベテランの／「それは違う」を、／工場に残る形にする。）。palt で約物を詰める */
.hero h1 {
  font-size: clamp(2.25rem, 3.8vw, 3.4rem); line-height: 1.3; letter-spacing: 0;
  font-feature-settings: "palt"; color: var(--ink);
}
.hero h1 .nb { display: inline-block; white-space: nowrap; }

/* 下：フロー（ヒーローの幅いっぱい、枠なし）。上に名前と注記の1行と、細い区切り線。図は scripts/lp-flow.js が作る */
.hero-flow { margin: 0; display: flex; flex-direction: column; align-items: center; }
.flow-bar {
  align-self: stretch; margin: 0 0 0.75rem; padding: 0 0 0.5rem; display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  border-bottom: 1px solid var(--edge); font-size: 0.75rem; line-height: 1.5; color: var(--slate);
}
.flow-name { display: inline-flex; align-items: center; gap: 0.5rem; font-weight: 700; color: var(--ink); letter-spacing: 0.06em; }
.flow-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15); }
.flow-note { color: var(--muted); }
.flow-svg { display: block; width: 100%; height: auto; overflow: visible; }
/* 高さが足りない画面では、見出し・帯・余白の分を引いた高さに合わせて縮める */
.flow-pc { max-height: calc(100vh - var(--header-h) - 11rem); }
.flow-sp { display: none; }

.flow-svg text { font-family: "Inter", "Noto Sans JP", system-ui, sans-serif; fill: var(--ink); }
.flow-svg .t { font-size: 16px; font-weight: 700; }
.flow-svg .t .no { font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 14px; font-weight: 700; fill: var(--primary); }
.flow-svg .k { font-size: 11px; font-weight: 500; letter-spacing: 0.12em; fill: #8391a7; }
.flow-svg .c { text-anchor: middle; }
.flow-svg .k .no { font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 13px; font-weight: 700; letter-spacing: 0; fill: var(--primary); }
.flow-svg .s { font-size: 13px; fill: var(--slate); }
.flow-svg .node > circle { fill: #fff; stroke: #c3cdda; stroke-width: 1.5; }
.flow-svg .ic { fill: none; stroke: #1e3a5f; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.flow-svg .warn .ic { stroke: var(--rose-text); }
.flow-svg .dot.err { fill: #e11d48; stroke: #fff; stroke-width: 2; }
.flow-svg .badge rect { fill: #fff; stroke: #c3cdda; stroke-width: 1; }
.flow-svg .badge text { font-size: 10.5px; font-weight: 700; text-anchor: middle; fill: var(--slate); letter-spacing: 0.06em; }
.flow-svg .badge.on rect { fill: var(--ink); stroke: var(--ink); }
.flow-svg .badge.on text { fill: #fff; }
.flow-svg .ln { fill: none; stroke: #94a3b8; stroke-width: 1.5; }
.flow-svg .ln.no { stroke: #ea580c; stroke-width: 1.5; }
.flow-svg .ln.loop { stroke: var(--primary); stroke-width: 1.5; }
.flow-svg .ah { fill: #94a3b8; }
.flow-svg .ah-no { fill: #ea580c; }
.flow-svg .ah-loop { fill: var(--primary); }
.flow-svg .join { fill: #94a3b8; }
.flow-svg .diamond path { fill: #fff; stroke: #c3cdda; stroke-width: 1.5; }
.flow-svg .diamond text { font-size: 14px; font-weight: 700; text-anchor: middle; }
.flow-svg .lb { font-size: 12.5px; font-weight: 700; fill: var(--slate); }
.flow-svg .lb.no { fill: #c2410c; }
.flow-svg .lb.loop { fill: var(--primary); }
.flow-svg .bubble path { fill: #fff; stroke: #cbd5e1; stroke-width: 1; stroke-linejoin: round; }
.flow-svg .bubble text { font-size: 14px; }
.flow-svg .bubble.err path { stroke: #fda4af; }
.flow-svg .bubble.err text { fill: var(--rose-text); }
.flow-svg .bubble.boss path { stroke: #1e3a5f; }
.flow-svg .bubble.boss text { font-weight: 500; }
.flow-svg .rule path { stroke: var(--primary); stroke-width: 2; }
.flow-svg .rule text { font-size: 13px; fill: var(--slate); }
.flow-svg .rule .kw { font-family: "JetBrains Mono", ui-monospace, monospace; font-size: 12px; font-weight: 700; fill: var(--primary); }
.flow-svg .vt { writing-mode: vertical-rl; text-orientation: upright; text-anchor: middle; letter-spacing: 0.1em; }
/* 段が順番に、ふちだけ青く光る（動きを減らす設定では止める） */
.flow-svg .node > circle, .flow-svg .diamond path { animation: flow-step 9s linear infinite; animation-delay: calc(var(--i) * 1s); }
@keyframes flow-step {
  0%, 12%, 100% { stroke: #c3cdda; stroke-width: 1.5; }
  4% { stroke: var(--primary); stroke-width: 2.5; }
}
.flow-svg .diamond path { animation-name: flow-step-d; }
@keyframes flow-step-d {
  0%, 12%, 100% { stroke: #c3cdda; stroke-width: 1.5; }
  4% { stroke: var(--primary); stroke-width: 2.5; }
}
@media (prefers-reduced-motion: reduce) {
  .flow-svg .node > circle, .flow-svg .diamond path { animation: none; }
}
.flow-svg .tag { font-size: 14px; font-weight: 700; fill: var(--primary); }

@media (min-width: 1100px) and (min-height: 700px) {
  /* 次のセクションがファーストビューに覗かないよう、ヒーローを画面の高さいっぱいにする */
  .hero { min-height: calc(100vh - var(--header-h)); }
}
@media (max-width: 1099px) {
  /* 横の図が小さくなりすぎる幅では、縦一列の図にする */
  .hero { padding: 2.5rem 0 0; }
  .flow-pc { display: none; }
  .flow-sp { display: block; max-width: 22rem; }
}
}

/* ── 困りごと ── */
.trouble-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2.5rem; margin-top: 4rem; }
.trouble { border-top: 2px solid var(--text); padding-top: 1.5rem; }
.tag { font-size: 0.8125rem; font-weight: 700; color: var(--primary); }
.trouble h3 { font-size: 1.3rem; margin-top: 0.35rem; }
.pair { border-radius: 1rem; padding: 0.85rem 1.1rem; margin-top: 0.75rem; font-size: 0.9875rem; line-height: 1.7; }
.pair:first-of-type { margin-top: 1.25rem; }
.pair-label { font-size: 0.75rem; font-weight: 700; }
.pair-problem { background: var(--rose-bg); }
.pair-problem .pair-label { color: var(--rose-text); }
.pair-solution { background: var(--soft); font-weight: 500; }
.pair-solution .pair-label { color: var(--primary-dark); }

/* ── 考え方（Steps） ── */
.steps { display: flex; flex-direction: column; gap: 7rem; margin-top: 5rem; }
.step { display: grid; grid-template-columns: 2fr 3fr; gap: 3.5rem; align-items: center; }
.step.reverse { grid-template-columns: 3fr 2fr; }
.step.reverse .step-text { order: 2; }
.step-no { font-family: "Inter", sans-serif; font-weight: 700; color: var(--primary); font-size: 0.9375rem; }
.step h3 { font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2.1rem); margin-top: 0.4rem; }
.checks { list-style: none; padding: 0; margin: 1.5rem 0 0; display: flex; flex-direction: column; gap: 0.7rem; }
.checks li { position: relative; padding-left: 1.75rem; }
.checks li::before {
  content: ""; position: absolute; left: 0.1rem; top: 0.55em; width: 0.9rem; height: 0.5rem;
  border-left: 2.5px solid var(--primary); border-bottom: 2.5px solid var(--primary); transform: rotate(-45deg);
}
.note { margin-top: 1.75rem; background: var(--soft); border-radius: 1rem; padding: 1rem 1.25rem; font-size: 0.9875rem; font-weight: 500; }
.note-label { font-size: 0.75rem; font-weight: 700; color: var(--primary); }

/* ── 定義（このページの核） ── */
.section-band { margin-top: 8rem; padding: 7rem 0; background: var(--card); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.definition { list-style: none; padding: 0; margin: 3.5rem 0 0; border-top: 1px solid var(--line); }
.definition li { display: grid; grid-template-columns: 4.5rem 1fr; gap: 1.5rem; padding: 2.25rem 0; border-bottom: 1px solid var(--line); }
.def-no { font-family: "Inter", sans-serif; font-size: 3rem; font-weight: 700; line-height: 1; color: var(--primary); }
.definition h3 { font-size: clamp(1.25rem, 1rem + 0.9vw, 1.6rem); }
.definition p { margin-top: 0.6rem; color: #475569; }
.statement { margin-top: 3.5rem; padding-left: 1.5rem; border-left: 4px solid var(--primary); }
.statement-main { font-size: clamp(1.3rem, 1rem + 1vw, 1.75rem); font-weight: 700; line-height: 1.5; }
.statement p + p { margin-top: 0.75rem; color: #475569; }

/* ── 進め方 ── */
.process { list-style: none; padding: 0; margin: 4.5rem 0 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; }
.process li { border-top: 2px solid var(--primary); padding-top: 1.25rem; }
.process-no { font-family: "Inter", sans-serif; font-weight: 700; color: var(--primary); font-size: 0.9375rem; }
.process h3 { font-size: 1.15rem; margin-top: 0.4rem; }
.process p { margin-top: 0.6rem; color: #475569; font-size: 0.9875rem; }
.process-note { margin: 3.5rem auto 0; text-align: center; font-size: 1.25rem; font-weight: 700; }

/* ── 画面 ── */
.screens { display: flex; flex-direction: column; gap: 6rem; margin-top: 5rem; }
.screen { display: grid; grid-template-columns: 1fr 2fr; gap: 3.5rem; align-items: center; }
.screen-name { font-size: 0.8125rem; font-weight: 700; color: var(--primary); }
.screen h3 { font-size: clamp(1.35rem, 1.05rem + 1vw, 1.8rem); margin-top: 0.35rem; }
.screen-text p:last-child { margin-top: 0.9rem; color: #475569; }
.screen-solve { margin-top: 0.8rem; padding-left: 0.8rem; border-left: 3px solid var(--primary); font-weight: 700; color: var(--primary-dark); line-height: 1.6; }
.screen-mobile { grid-template-columns: 1fr 1fr; }
.shot-phone { max-width: 20rem; justify-self: center; }
.shot-phone img { max-height: 44rem; object-fit: cover; object-position: top; border-radius: 2rem; }

/* ── FAQ ── */
.faq { max-width: 48rem; margin: 3rem auto 0; background: var(--card); border: 1px solid var(--line); border-radius: 2rem; padding: 0.5rem 2.5rem; }
.faq details { border-bottom: 1px solid var(--line); }
.faq details:last-child { border-bottom: 0; }
.faq summary {
  list-style: none; cursor: pointer; padding: 1.4rem 2.5rem 1.4rem 0; position: relative;
  font-weight: 700; font-size: 1.0625rem;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: 0.4rem; top: 50%; width: 0.6rem; height: 0.6rem; margin-top: -0.45rem;
  border-right: 2px solid var(--muted); border-bottom: 2px solid var(--muted); transform: rotate(45deg); transition: transform 0.2s;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -0.1rem; }
.faq details p { padding: 0 0 1.5rem; color: #475569; }

/* ── お問い合わせ ── */
#contact { padding-bottom: 6rem; }
.closing { background: var(--soft); border-radius: 2rem; padding: 5rem 2rem; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.closing h2 { font-size: clamp(1.6rem, 1.1rem + 2vw, 2.4rem); }
.contact-form { width: 100%; max-width: 34rem; margin-top: 1.5rem; display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; text-align: left; }
.contact-form label { display: flex; flex-direction: column; gap: 0.35rem; font-size: 0.875rem; font-weight: 500; color: var(--muted); }
.contact-form .full { grid-column: 1 / -1; }
.contact-form input, .contact-form textarea {
  font: inherit; font-size: 1rem; padding: 0.75rem 1rem; border: 1px solid var(--line); border-radius: 0.9rem; background: #fff; color: var(--text);
}
.contact-form input:disabled, .contact-form textarea:disabled { background: #f8fafc; }
.contact-status { font-size: 0.875rem; color: var(--muted); }

/* ── フッター ── */
.site-footer { border-top: 1px solid var(--line); padding: 2.5rem 0 3rem; font-size: 0.875rem; color: var(--muted); }
.footer-inner { display: flex; flex-wrap: wrap; gap: 0.5rem 2rem; align-items: baseline; }
.footer-inner .brand { color: var(--text); font-size: 1rem; }

/* ── タブレット以下 ── */
@media (max-width: 960px) {
  .step, .step.reverse, .screen, .screen-mobile { grid-template-columns: 1fr; gap: 2rem; }
  .step.reverse .step-text { order: 0; }
  .trouble-grid { grid-template-columns: 1fr; gap: 3rem; }
  .process { grid-template-columns: 1fr 1fr; gap: 2.5rem 2rem; }
  .steps, .screens { gap: 5rem; }
}

/* ── スマホ ── */
@media (max-width: 640px) {
  :root { --header-h: 5.75rem; }
  body { font-size: 1rem; }
  .wrap { padding: 0 1.25rem; }
  .header-inner { flex-direction: column; align-items: flex-start; gap: 0.25rem; padding-top: 0.6rem; padding-bottom: 0.4rem; }
  .nav { width: calc(100% + 0.75rem); overflow-x: auto; scrollbar-width: none; margin-left: -0.75rem; padding-bottom: 0.2rem; }
  .nav::-webkit-scrollbar { display: none; }
  .nav a { padding: 0.35rem 0.7rem; }
  .nav .nav-cta { display: none; }
  .hero { padding-top: 1.75rem; }
  .hero-grid { gap: 1.5rem; }
  .hero h1 { font-size: clamp(2rem, 9.4vw, 2.6rem); line-height: 1.34; }
  .hero h1 .nb { display: block; }
  .flow-bar { margin-bottom: 0.5rem; }
  .flow-pc { display: none; }
  .flow-sp { display: block; max-width: 22rem; }
  .section { padding-top: 5.5rem; }
  .section-band { margin-top: 5.5rem; padding: 4.5rem 0; }
  .definition li { grid-template-columns: 2.75rem 1fr; gap: 1rem; padding: 1.75rem 0; }
  .def-no { font-size: 2.1rem; }
  .process { grid-template-columns: 1fr; }
  .faq { padding: 0.25rem 1.25rem; border-radius: 1.5rem; }
  .closing { padding: 3.5rem 1.25rem; border-radius: 1.5rem; }
  .contact-form { grid-template-columns: 1fr; }
  .shot img { border-radius: 1rem; }
  .br-pc, br.pc { display: none; }
}
