/* ==========================================================================
   STORIUM インバイトLP — style.css（第4版・スタートアップ専用の1ページ）
   色と書体の出典は storium.jp のテーマCSS（storium-v2 bundle.css）。design_notes.md §2
   ========================================================================== */

:root {
  /* 文字と罫線 */
  --ink: #1b2129;          /* 見出し・強い罫線 */
  --text: #333;            /* 本文（storium.jp --text） */
  --muted: #5d6670;        /* 補足（白地 5.9:1） */
  --rule: #d6dade;         /* 細い罫線 */
  --paper: #fff;

  /* 主CTAだけが使う色。ほかの要素には使わない（ヘッダーのロゴも単色版にしている） */
  --cta: #0556a5;          /* storium.jp --primary */
  --cta-hover: #2c4a67;    /* storium.jp --primary-hover */

  /* 写真（撮影予定）の枠と、制作用の注記 */
  --photo: #e9ecef;
  --photo-ink: #454d56;
  --todo-bg: #fff7da;
  --todo-ink: #5c4500;
  --todo-line: #c9a227;

  /* フッター */
  --footer: #17212b;
  --footer-ink: #e8ecf0;
  --footer-muted: #aab4bf;

  /* 組織種別の目印（storium.jp の公式色。点の装飾にだけ使い、文字には使わない） */
  --dot-startup: #45c936;
  --dot-investor: #ff4626;
  --dot-innovator: #42a6f7;
  --dot-supporter: #ff69b4;

  --font: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic", Meiryo, sans-serif;
  --wrap: 1120px;
  --gutter: 20px;
}

/* ---------- 基本 ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.9;
  letter-spacing: .04em;
  line-break: strict;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
p, ul, ol, dl, figure, h1, h2, h3 { margin: 0; }
a { color: var(--ink); text-decoration-thickness: 1px; text-underline-offset: .28em; }
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 3px;
}
h1, h2, h3 {
  color: var(--ink);
  font-weight: 700;
  font-feature-settings: "palt" 1;   /* 約物を詰める */
}
/* 本文は最終行が1〜2文字だけになる「泣き別れ」を避ける（対応ブラウザのみ） */
p, li, td, small, figcaption, .todo, .photo-todo { text-wrap: pretty; }
/* 行が短くなるSPで単語の途中（プロ｜フィール、資金調｜達）で割れないよう、本文も文節で折り返す */
.hero__lead, .hero__invite, .hero__why, .section__intro, .pageinfo__list li, .notes li,
.asks li, .terms td, .terms-note, .faq__a p, .orgs__label { word-break: auto-phrase; }
/* 短い見出し・ラベルは文節で折り返す（対応ブラウザのみ。非対応でも通常の折り返し） */
h1, h2, h3, figcaption, .apply__title, .closing__title,
.faq summary, .hero__who, .org-links__name, .notes b {
  word-break: auto-phrase;
  text-wrap: balance;
}

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

.skip-link {
  position: absolute; left: 8px; top: -60px; z-index: 50;
  background: var(--ink); color: #fff; padding: 10px 14px; text-decoration: none;
}
.skip-link:focus { top: 8px; }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ---------- ヘッダー（ロゴ＋主CTAだけ） ---------- */
.site-header { background: var(--paper); border-bottom: 1px solid var(--rule); }
.site-header__in { display: flex; align-items: center; justify-content: space-between; min-height: 60px; }
.site-header__logo { display: inline-flex; align-items: center; min-height: 44px; }
.site-header__logo img { width: 128px; }
.site-header .btn-cta { display: none; }   /* SPは画面下の固定バーが担う */

/* ---------- 主CTA（全ページ・全位置で同じ文言と色） ---------- */
.btn-cta {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  width: 100%; min-height: 56px; padding: 0 22px;
  background: var(--cta); color: #fff;
  font-size: 17px; font-weight: 700; letter-spacing: .06em;
  text-decoration: none; border-radius: 4px;
}
.btn-cta:hover { background: var(--cta-hover); }
.btn-cta__arrow { font-size: 20px; line-height: 1; }
.btn-cta--sm { width: auto; min-height: 44px; padding: 0 18px; font-size: 15px; }

.cta-note { margin-top: 10px; font-size: 16px; line-height: 1.7; color: var(--muted); }

/* 副CTA（問い合わせ）。塗りも枠もない文字リンクにして、主CTAより弱く見せる。
   折り返しても矢印が文の末尾に付いてくるよう inline-block（高さは上下の余白で44pxを確保） */
.link-sub {
  display: inline-block; padding: 10px 0; line-height: 1.6;
  font-size: 16px; color: var(--ink);
  text-decoration: underline;
}

.nw { white-space: nowrap; }

/* 文中の「行き先が分かるリンク」。行の高さは変えずに、押せる範囲だけ上下に広げる */
.link-go, .faq__a a { white-space: nowrap; }
.link-go, .faq__a a { display: inline; min-height: 0; padding: 12px 0; }

/* ---------- ヒーロー ---------- */
.hero { padding: 28px 0 48px; }
.hero__who {
  display: flex; align-items: center; gap: 8px;
  font-size: 14px; font-weight: 700; color: var(--ink); letter-spacing: .08em;
}
.dot { display: inline-block; vertical-align: middle; width: 10px; height: 10px; border-radius: 50%; background: var(--ink); flex: none; }
.dot--startup { background: var(--dot-startup); }
.dot--investor { background: var(--dot-investor); }
.dot--innovator { background: var(--dot-innovator); }
.dot--supporter { background: var(--dot-supporter); }

/* 見出しはブランドの正式表現（56字）をそのまま置くので、文字を抑えて行数を減らす */
.hero h1 { margin-top: 14px; font-size: 25px; line-height: 1.5; letter-spacing: .02em; }
.hero__lead { margin-top: 18px; font-size: 16px; line-height: 1.85; }
/* 「あなた宛ての招待です」と分かる一文。墨の縦線で本文と分ける */
.hero__invite {
  margin-top: 18px; padding: 2px 0 2px 14px; border-left: 3px solid var(--ink);
  font-size: 16px; line-height: 1.8; font-weight: 700; color: var(--ink);
}
.hero__why { margin-top: 12px; font-size: 16px; line-height: 1.8; color: var(--muted); }
.hero__action { margin-top: 24px; }
.hero__action .link-sub { margin-top: 6px; }
.hero__figure { margin-top: 36px; }
.hero__figure img { width: 100%; max-width: 560px; }

figcaption { margin-top: 8px; font-size: 13px; line-height: 1.7; color: var(--muted); }

/* ---------- セクション（背景は塗り分けず、罫線と余白で区切る） ---------- */
.section { padding: 56px 0; border-top: 1px solid var(--rule); }
.section h2 { font-size: 25px; line-height: 1.45; letter-spacing: .03em; }
.section__intro { margin-top: 12px; }
.section__body { margin-top: 24px; }
.section--tight { padding: 44px 0; }

/* できること：最初の1項目を大きく、残り2項目は写真と組にする */
.feature-lead h3 { font-size: 23px; line-height: 1.5; }
.feature-lead p { margin-top: 10px; font-size: 17px; line-height: 1.9; max-width: 34em; }

.pair { display: grid; gap: 40px; margin-top: 40px; padding-top: 32px; border-top: 1px solid var(--rule); }
.pair__item h3 { margin-top: 14px; font-size: 19px; line-height: 1.55; }
.pair__item p { margin-top: 6px; }
.pair__item p, .feature-lead p, .flow small, .cta-note { word-break: auto-phrase; }
.pair__item figure img, .photo-todo { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }

/* 写真（撮影予定）の枠。ダミーではなく「ここに何の写真が入るか」を書いた指示枠 */
.photo-todo {
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 16px 18px; background: var(--photo); color: var(--photo-ink);
  font-size: 13px; line-height: 1.7;
}
.photo-todo b { font-size: 14px; color: var(--ink); }

/* 参加している投資家・事業会社：storium.jp の公開一覧から取った名前 */
.orgs { display: grid; gap: 36px; }
.orgs__group h3 {
  display: flex; align-items: center; gap: 10px;
  padding-bottom: 10px; border-bottom: 2px solid var(--ink); font-size: 18px; line-height: 1.5;
}
.orgs__label { flex: 1 1 0; min-width: 0; }
.orgs__count { flex: none; font-size: 14px; font-weight: 400; color: var(--muted); font-variant-numeric: tabular-nums; }
/* SP は区分名の幅を確保するため、社数を区分名の下の行に回す（640px 以上は右端に並べる） */
.orgs__group h3 { flex-wrap: wrap; row-gap: 0; }
.orgs__count { flex-basis: 100%; padding-left: 20px; }
/* 名簿は段組みにせず、名前ごとに流して並べる（段組みだと「株式｜会社」のように名前の途中で割れる）。
   名前の中は割らず（keep-all）、1行に収まらない長い名前だけ括弧や中黒の位置で折る */
.orgs__clip { overflow: hidden; margin-top: 12px; }
.orgs__names { list-style: none; padding: 0; margin-left: -1.4em; font-size: 16px; line-height: 1.75; color: var(--ink); }
.orgs__names li {
  display: inline-block; position: relative; max-width: calc(100% - 1.4em);
  margin: 0 0 6px 1.4em; word-break: keep-all; overflow-wrap: anywhere;
}
/* 名前の左の区切り線。行頭の名前の線は .orgs__clip の外に出るので見えない */
.orgs__names li::before {
  content: ""; position: absolute; left: -.7em; top: .45em; width: 1px; height: .9em; background: var(--rule);
}
.orgs__more summary {
  display: inline-flex; align-items: center; gap: 6px; min-height: 44px; cursor: pointer; list-style: none;
  font-size: 16px; color: var(--ink); text-decoration: underline; text-underline-offset: .28em;
}
.orgs__more summary::-webkit-details-marker { display: none; }
.orgs__more summary::after { content: "＋"; text-decoration: none; }
.orgs__more[open] summary::after { content: "－"; }
.orgs + .org-links { margin-top: 32px; }

/* 参加している企業：storium.jp の公開一覧へのリンク */
.org-links { list-style: none; padding: 0; margin-top: 20px; border-top: 2px solid var(--ink); }
.org-links a {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 60px; padding: 10px 0; border-bottom: 1px solid var(--rule);
  text-decoration: none; color: var(--ink);
}
.org-links__name { display: flex; align-items: center; gap: 10px; font-size: 17px; font-weight: 700; }
.org-links__go { font-size: 15px; text-decoration: underline; text-underline-offset: .28em; white-space: nowrap; }

/* 登録の条件と料金（表） */
.terms { width: 100%; border-collapse: collapse; border-top: 2px solid var(--ink); }
.terms tr { border-bottom: 1px solid var(--rule); }
.terms th, .terms td { display: block; text-align: left; vertical-align: top; }
.terms th { padding: 16px 0 2px; font-size: 14px; color: var(--muted); font-weight: 700; letter-spacing: .08em; }
.terms td { padding: 0 0 16px; }
.terms__fee { display: block; font-size: 26px; font-weight: 700; color: var(--ink); line-height: 1.4; }
.terms__fee + span { display: block; margin-top: 4px; font-size: 16px; }
.terms-note { margin-top: 14px; font-size: 16px; line-height: 1.8; color: var(--muted); }

/* STORIUMのページで分かること */
.pageinfo__list { list-style: none; padding: 0; }
.pageinfo__list li {
  position: relative; padding: 11px 0 11px 18px; border-bottom: 1px solid var(--rule);
  font-size: 16px; line-height: 1.75;
}
.pageinfo__list li::before {
  content: ""; position: absolute; left: 2px; top: 22px;
  width: 6px; height: 6px; border-radius: 50%; background: var(--ink);
}

/* 申請の前に：注意書き3点（南里さんの「ブレーキ」。申請フォームの説明より先に読ませる） */
.notes { list-style: none; padding: 0; margin-bottom: 44px; border-top: 2px solid var(--ink); counter-reset: note; }
.notes li { position: relative; padding: 14px 0 14px 32px; border-bottom: 1px solid var(--rule); font-size: 16px; line-height: 1.8; }
.notes li::before {
  counter-increment: note; content: counter(note) ".";
  position: absolute; left: 0; top: 14px; font-weight: 700; color: var(--ink); font-variant-numeric: tabular-nums;
}
.notes li b { display: block; font-size: 17px; color: var(--ink); }

/* 申請の前に */
.prep { display: grid; gap: 36px; }
.prep h3 { font-size: 18px; line-height: 1.5; padding-bottom: 10px; border-bottom: 2px solid var(--ink); }
.asks { list-style: none; padding: 0; }
.asks li { padding: 12px 0; border-bottom: 1px solid var(--rule); font-size: 16px; line-height: 1.8; }
.asks li b { display: block; color: var(--ink); font-size: 16px; }
.flow { list-style: none; padding: 0; counter-reset: step; }
.flow li { position: relative; padding: 9px 0 9px 42px; font-size: 17px; color: var(--ink); }
.flow li::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 11px;
  width: 26px; height: 26px; border: 1px solid var(--ink); border-radius: 50%;
  font-size: 13px; line-height: 24px; text-align: center; letter-spacing: 0;
  font-variant-numeric: tabular-nums; background: var(--paper);
}
.flow li:not(:last-child)::after {
  content: ""; position: absolute; left: 13px; top: 37px; bottom: -11px; width: 1px; background: var(--rule);
}
.flow small { display: block; font-size: 16px; color: var(--muted); line-height: 1.7; }

.apply { margin-top: 40px; padding-top: 28px; border-top: 2px solid var(--ink); }
.apply__title { font-size: 22px; line-height: 1.5; }
.apply .btn-cta { margin-top: 16px; }

/* よくある質問 */
.faq { border-top: 2px solid var(--ink); }
.faq details { border-bottom: 1px solid var(--rule); }
.faq summary {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  min-height: 60px; padding: 14px 0; cursor: pointer; list-style: none;
  font-size: 17px; font-weight: 700; color: var(--ink); line-height: 1.6;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "＋"; flex: none; font-weight: 400; }
.faq details[open] summary::after { content: "－"; }
.faq__a { padding: 0 0 20px; }

.closing { margin-top: 48px; }
.closing__title { font-size: 24px; line-height: 1.5; }
.closing .btn-cta { margin-top: 18px; }

/* ---------- 制作用の注記（公開時に削除） ---------- */
.todo {
  display: block; margin-top: 12px; padding: 8px 12px;
  background: var(--todo-bg); color: var(--todo-ink); border-left: 3px solid var(--todo-line);
  font-size: 13px; line-height: 1.7; letter-spacing: .02em;
}

/* ---------- フッター ---------- */
.site-footer { background: var(--footer); color: var(--footer-ink); padding: 44px 0 120px; font-size: 14px; }
.site-footer a { color: var(--footer-ink); }
.site-footer a:focus-visible { outline-color: #fff; }
.site-footer__desc { margin-top: 18px; line-height: 1.8; color: var(--footer-muted); }
.site-footer__links { list-style: none; padding: 0; margin-top: 14px; display: flex; flex-wrap: wrap; column-gap: 20px; }
.site-footer__links a { display: inline-flex; align-items: center; min-height: 44px; }
.site-footer__copy { margin-top: 12px; color: var(--footer-muted); font-size: 13px; }

/* ---------- SP 固定CTAバー（親指の届く画面下） ---------- */
.cta-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
  padding: 10px var(--gutter) calc(10px + env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, .97); border-top: 1px solid var(--rule);
}
.cta-bar.is-hidden { display: none; }

/* ==========================================================================
   640px〜：横に余裕が出たら、ボタンを内容の幅に
   ========================================================================== */
@media (min-width: 640px) {
  .btn-cta { width: auto; min-width: 340px; }
  .btn-cta--sm { min-width: 0; }
  .hero__action { display: flex; flex-wrap: wrap; align-items: center; column-gap: 24px; }
  .hero__action .cta-note { flex-basis: 100%; }
  .pair { grid-template-columns: 1fr 1fr; column-gap: 32px; }
  .prep { grid-template-columns: 1fr 1fr; column-gap: 40px; }
  .terms th, .terms td { display: table-cell; }
  .terms th { width: 8.5em; padding: 18px 16px 18px 0; }
  .terms td { padding: 16px 0; }
  .orgs__group h3 { flex-wrap: nowrap; }
  .orgs__count { flex-basis: auto; padding-left: 0; }
}

/* ==========================================================================
   829px〜：PCの組み（storium.jp の small/default の境目に合わせる）
   ========================================================================== */
@media (min-width: 829px) {
  body { font-size: 17px; }
  :root { --gutter: 40px; }

  .site-header { position: sticky; top: 0; z-index: 20; }
  .site-header__in { min-height: 72px; }
  .site-header__logo img { width: 152px; }
  .site-header .btn-cta { display: inline-flex; }

  .cta-bar { display: none; }
  .site-footer { padding-bottom: 48px; }

  .hero { padding: 72px 0 96px; }
  .hero__grid { display: grid; grid-template-columns: minmax(0, 13fr) minmax(0, 11fr); column-gap: 56px; align-items: center; }
  .hero__figure img { max-width: none; }
  .hero h1 { font-size: 37px; line-height: 1.45; }
  .hero__lead { font-size: 17px; max-width: 33em; }
  .hero__why { font-size: 16px; max-width: 38em; }
  .hero__figure { margin-top: 0; }

  .section { padding: 96px 0; }
  .section--tight { padding: 64px 0; }
  .section .cols { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); column-gap: 48px; }
  .section .cols > .section__body { margin-top: 0; }
  .section h2 { font-size: 34px; line-height: 1.4; }
  .section__intro { font-size: 16px; color: var(--muted); }

  .feature-lead h3 { font-size: 30px; line-height: 1.45; }
  .pair__item h3 { font-size: 21px; }

  .faq summary { font-size: 18px; }
  .closing__title { font-size: 30px; }
  .apply__title { font-size: 26px; }

}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
}
