/* ============================================================
   styles-lp.css — 紹介ページ(LP)専用スタイル
   ・アプリ本体の styles.css は読み込まない（不要CSSを排除するため）。
     よって :root 変数・リセットはこのファイルで自前に定義する。
   ・全クラスに lp- 接頭辞を付け、既存 styles.css との衝突を避ける。
   ・外部リソース禁止（CSP: font-src 'self' / img-src 'self' data:）。
     ただし**インラインSVGは外部リソースではない**のでCSPに触れない。
     アイコンは絵文字ではなくSVGで描く（絵文字は端末ごとに絵が変わり、
     ブランドとして機能しないため）。
   ・意匠は「母子手帳の質感」。紙のクリーム地＋線画アイコン＋影を使わず
     1pxの罫線で面を分ける。影は端末モックアップ（実際に浮いている物）
     にのみ許す。
   ============================================================ */

:root {
  /* アプリ本体(styles.css)と同じブランド値 */
  --lp-green: #4caf82;        /* 装飾・塗り用（白文字は載せない） */
  --lp-bg: #faf6ee;          /* 紙のクリーム。ink 11.08 / muted 4.95 / green 5.30（実測） */
  --lp-card: #ffffff;
  --lp-ink: #2b3a34;
  --lp-line: #e7dfd1;        /* 罫線もクリームに合わせて暖色へ */
  --lp-radius: 14px;

  /* LP用に追加した2色（理由: 既存の --green/--muted は白文字・小文字での
     コントラスト比がWCAG AAに届かないため。実測値は下記コメント参照） */
  --lp-green-strong: #2b7352; /* クリーム地では #2f7d59 が 4.64 と余裕がないため一段濃く。
                                 cream 5.30 / white 5.71 / 白文字を載せて 5.71（実測） */
  --lp-muted: #5d6f68;        /* 補助テキスト。--lp-bg 上で 4.9:1 (AA合格) */
}

/* ── リセット・ベース ───────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  /* 先頭を欧文専用フォントにする。system-ui を先頭に置くと Windows では
     日本語がフォントリンク経由で palt 非対応の書体に確定し、下の palt が
     無効化される(実測: 効果 0px)。この順なら和文が palt 対応書体に落ちて
     18%詰まり、欧文の描画幅は変わらない(実測 122.4px で同一)。 */
  font-family: -apple-system, "Segoe UI", Roboto, "Hiragino Sans",
    "Noto Sans JP", "Yu Gothic Medium", "Yu Gothic", sans-serif;
  background: var(--lp-bg);
  color: var(--lp-ink);
  /* 和文の一次資料(デジタル庁150-175% / SmartHR 1.5)の上限に合わせる */
  line-height: 1.75;
  /* palt: 「」（）・ などの約物の余分な空きを詰める。無いと和文が間延びする */
  font-feature-settings: "palt" 1;
  /* 合成ボールド/斜体を禁止。font-weight:800 を持たない和文書体で
     ブラウザが太らせて潰れるのを防ぐ(実太さ700で描かれる) */
  font-synthesis: none;
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden; /* 端末フレームの rotate がはみ出しても横スクロールさせない */
}

img { max-width: 100%; height: auto; }

a { color: var(--lp-green-strong); }

:focus-visible {
  outline: 2px solid var(--lp-green-strong);
  outline-offset: 3px;
}

/* ── レイアウト共通 ─────────────────────────────── */
.lp-container {
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
  padding: 0 20px;
}

.lp-section { padding: 68px 0; }
/* sticky ヘッダ(60px)の下に潜らせない。スキップリンクや今後の
   ページ内リンクの着地点がヘッダに隠れるのを防ぐ。 */
section[id] { scroll-margin-top: 68px; }
.lp-section--white { background: var(--lp-card); }
.lp-section--tint { background: var(--lp-bg); }

.lp-section__heading {
  font-size: 1.4rem;
  font-weight: 800;
  text-align: center;
  color: var(--lp-ink);
  margin: 0 0 32px;
  line-height: 1.45;
  letter-spacing: -0.01em;
}

/* ── スキップリンク ────────────────────────────── */
.lp-skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 300;
  background: #ffffff;
  color: var(--lp-green-strong);
  padding: 12px 18px;
  font-weight: 700;
  border-radius: 0 0 10px 0;
}
.lp-skip-link:focus { left: 0; }

/* ── ヘッダ ────────────────────────────────────── */
.lp-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--lp-green-strong);
  color: #ffffff;
  min-height: 56px;
  display: flex;
  align-items: center;
}
.lp-header__inner {
  width: 100%;
  max-width: 860px;
  margin: 0 auto;
  padding: 8px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
/* ロゴマーク —— 絵文字(🍎)は端末ごとに絵が変わり、ブランドマークとして機能しない。
   自作アイコン(icons/logo.png の透過版)に統一する。 */
.logo-mark {
  height: 1.15em;
  width: auto;
  vertical-align: -0.18em;
}

.lp-header__logo {
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* ── CTAボタン ─────────────────────────────────── */
.lp-cta-btn {
  display: flex;
  width: 100%;
  max-width: 340px;
  min-height: 52px;
  margin: 0 auto;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 14px 32px;
  background: var(--lp-green-strong);
  color: #ffffff;
  font-size: 1.05rem;
  font-weight: 700;
  text-decoration: none;
  border-radius: 40px;
  transition: background .15s, transform .1s;
}
.lp-cta-btn:hover { background: #26694b; transform: translateY(-1px); }
.lp-cta-btn:active { transform: translateY(0); opacity: .9; }

/* ヘッダ内の小さいCTA */
.lp-cta-btn--sm {
  display: inline-flex;
  width: auto;
  max-width: none;
  min-height: 44px;
  margin: 0;
  padding: 8px 16px;
  background: #ffffff;
  color: var(--lp-green-strong);
  font-size: .82rem;
  border-radius: 22px;
  white-space: nowrap;
}
.lp-cta-btn--sm:hover { background: var(--lp-bg); transform: none; }

/* 緑背景の上に置く白いCTA */
.lp-cta-btn--white {
  background: #ffffff;
  color: var(--lp-green-strong);
}
.lp-cta-btn--white:hover { background: var(--lp-bg); }

.lp-cta-note {
  margin: 12px 0 0;
  font-size: .8rem;
  color: var(--lp-muted);
  text-align: center;
}

/* ── フローティングCTA（モバイルのみ） ──────────── */
.lp-float-cta {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 56px;
  padding: 0 16px calc(env(safe-area-inset-bottom, 0px));
  background: var(--lp-green-strong);
  color: #ffffff;
  font-size: 1rem;
  font-weight: 700;
  text-decoration: none;
  transform: translateY(110%);
  transition: transform .25s ease;
}
.lp-float-cta.is-visible { transform: translateY(0); }

/* ── ヒーロー ──────────────────────────────────── */
.lp-hero { padding: 40px 0 0; background: var(--lp-bg); }
.lp-hero__body { text-align: center; }

.lp-hero__heading {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.35;
  margin: 0;
  color: var(--lp-ink);
  letter-spacing: -0.015em;
}
.lp-hero__heading-accent { color: var(--lp-green-strong); }

.lp-hero__sub {
  margin: 14px 0 0;
  font-size: 1rem;
  color: var(--lp-muted);
}

.lp-hero__badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin: 20px 0 24px;
  padding: 0;
  list-style: none;
}

.lp-badge {
  display: inline-block;
  padding: 6px 14px;
  border: 2px solid var(--lp-green);
  border-radius: 40px;
  background: #ffffff;
  color: var(--lp-green-strong);
  font-size: .82rem;
  font-weight: 700;
}

.lp-hero__screenshot {
  position: relative;
  width: 220px;
  height: 190px;
  margin: 36px auto 0;
  overflow: hidden;
  border-radius: 18px 18px 0 0;
  box-shadow: 0 8px 24px rgba(0, 0, 0, .18);
}
.lp-hero__screenshot img {
  display: block;
  width: 100%;
  height: auto;
}
.lp-hero__screenshot::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 40%, var(--lp-bg) 100%);
}

/* ── 困りごと ──────────────────────────────────── */
.lp-pain__list { margin: 0; padding: 0; list-style: none; }
.lp-pain__item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--lp-line);
}
.lp-pain__icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--lp-green-strong);
}
.lp-pain__bridge {
  margin: 28px 0 0;
  text-align: center;
  color: var(--lp-green-strong);
  font-weight: 700;
}

/* ── 3つの価値 ─────────────────────────────────── */
.lp-values__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
.lp-value-card {
  background: var(--lp-card);
  border: 1px solid var(--lp-line);
  border-radius: var(--lp-radius);
  padding: 28px 22px;
}
/* ── 線画アイコン ──────────────────────────────
   絵文字を置き換えたインラインSVG。色は currentColor なので
   親の color を変えれば追随する。 */
.lp-value-card__icon {
  display: block;
  width: 40px;
  height: 40px;
  margin-bottom: 14px;
  padding: 7px;
  box-sizing: content-box;
  color: var(--lp-green-strong);
  background: color-mix(in oklab, var(--lp-green) 12%, white);
  border-radius: 50%;
}
.lp-value-card__title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--lp-green-strong);
}
.lp-value-card__body { margin: 8px 0 0; font-size: .95rem; }

/* ── 数字・機能一覧 ────────────────────────────── */
.lp-stat-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  margin: 0 0 32px;
  padding: 0;
  list-style: none;
}
.lp-stat { text-align: center; }
.lp-stat__num {
  display: block;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--lp-green-strong);
  line-height: 1.35;
  letter-spacing: -0.01em;
  /* 「0か月〜17歳」だけ2行に折れるため、3つのラベルの縦位置を揃える。
     min-height を外すと1つだけラベルが下がって列が崩れる。 */
  min-height: 2.7em;
}
/* 「0か月〜17歳」が「17 / 歳」のように語中で折れないよう、意味の切れ目で改行させる */
.lp-stat__num > span { display: inline-block; }
.lp-stat__label { display: block; font-size: .75rem; color: var(--lp-muted); }

.lp-features__list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.lp-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--lp-line);
}
.lp-feature-item__icon {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--lp-green-strong);
}
.lp-feature-item__title { margin: 0; font-size: 1rem; font-weight: 700; }
.lp-feature-item__desc { margin: 2px 0 0; font-size: .9rem; color: var(--lp-muted); }

/* ── カード内スクリーンショット ────────────────
   独立した「アプリの画面」セクションを廃し、対応する主張の直下に置く。
   カード幅いっぱい(旧: 横2列で各50%)になるため、画面の中身が実際に読める。 */
.lp-phone-frame {
  display: block;
  max-height: 380px;
  overflow: hidden;
  border: 8px solid var(--lp-ink);
  border-radius: 22px;
  background: var(--lp-ink);
  box-shadow: 0 12px 32px rgba(0, 0, 0, .18);
}
.lp-phone-frame img {
  display: block;
  width: 100%;
  height: 364px;
  object-fit: cover;
  object-position: top;
}
.lp-value-card__shot { margin-top: 18px; }

/* ── 数字の帯(ヒーロー直下) ────────────────────
   具体的な事実を最初に出す。ヒーローの続きなので上余白を詰める。 */
.lp-statband {
  padding: 8px 0 40px;
  background: var(--lp-bg);
}

/* ── 安心 ──────────────────────────────────────── */
.lp-trust__points {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 12px;
}
.lp-trust__points li {
  background: var(--lp-bg);
  border-radius: var(--lp-radius);
  padding: 16px 18px;
  font-size: .92rem;
  color: var(--lp-muted);
}
.lp-trust__points b {
  display: block;
  font-size: .98rem;
  color: var(--lp-ink);
  margin-bottom: 4px;
}
.lp-trust__source {
  margin: 16px 0 0;
  font-size: .95rem;
}
.lp-trust__source strong { color: var(--lp-green-strong); }
.lp-trust__disclaimer {
  margin: 20px 0 0;
  padding-top: 16px;
  border-top: 1px dashed var(--lp-line);
  font-size: .8rem;
  color: var(--lp-muted);
}

/* ── 3ステップ ─────────────────────────────────── */
.lp-steps { margin: 0; padding: 0; list-style: none; }
.lp-step { display: flex; gap: 16px; }
.lp-step__num {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--lp-green-strong);
  color: #ffffff;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}
.lp-step__body { padding-bottom: 4px; }
.lp-step__title { margin: 8px 0 0; font-size: 1rem; font-weight: 700; }
.lp-step__desc { margin: 4px 0 0; font-size: .92rem; color: var(--lp-muted); }
.lp-step__line {
  height: 28px;
  margin: 4px 0 4px 19px;
  border-left: 2px dashed var(--lp-line);
}

/* ── FAQ ───────────────────────────────────────── */
.lp-faq__list { max-width: 700px; margin: 0 auto; }
.lp-faq__item { border-bottom: 1px solid var(--lp-line); }
.lp-faq__question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 16px 0;
  min-height: 44px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
}
.lp-faq__question::-webkit-details-marker { display: none; }
.lp-faq__question::after {
  content: "＋";
  flex: 0 0 auto;
  color: var(--lp-green-strong);
  font-size: 1.1rem;
}
.lp-faq__item[open] .lp-faq__question { color: var(--lp-green-strong); }
.lp-faq__item[open] .lp-faq__question::after { content: "－"; }
.lp-faq__answer {
  margin: 0;
  padding: 0 0 18px;
  font-size: .95rem;
  color: var(--lp-muted);
}

/* ── 最終CTA ───────────────────────────────────── */
.lp-final-cta {
  background: var(--lp-green-strong);
  text-align: center;
}
.lp-final-cta__heading {
  margin: 0;
  font-size: 1.4rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.5;
  letter-spacing: -0.01em;
}
.lp-final-cta__sub {
  margin: 12px 0 28px;
  color: rgba(255, 255, 255, .92);
  font-size: .95rem;
}

/* ── フッター ──────────────────────────────────── */
.lp-footer {
  background: #eef3f0;
  border-top: 1px solid var(--lp-line);
  padding: 32px 20px calc(80px + env(safe-area-inset-bottom, 0px));
  text-align: center;
}
.lp-footer__links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 20px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.lp-footer__links a { font-size: .85rem; color: var(--lp-green-strong); }
.lp-footer__copy { margin: 18px 0 0; font-size: .8rem; color: var(--lp-muted); }
.lp-footer__disclaimer {
  max-width: 620px;
  margin: 8px auto 0;
  font-size: .8rem;
  color: var(--lp-muted);
  line-height: 1.65;
}

/* ── 768px 以上（タブレット・PC） ───────────────── */
@media (min-width: 768px) {
  .lp-container { padding: 0 32px; }
  .lp-section { padding: 96px 0; }
  .lp-section__heading { font-size: 1.8rem; }

  .lp-hero { padding: 56px 0 0; }
  .lp-hero__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 48px;
    min-height: 520px;
  }
  .lp-hero__body { text-align: left; }
  .lp-hero__heading { font-size: 2.4rem; }
  .lp-hero__badges { justify-content: flex-start; }
  .lp-hero__screenshot { width: 280px; height: 460px; margin: 0 auto; }
  .lp-cta-btn { display: inline-flex; width: auto; margin: 0; }
  .lp-cta-note { text-align: left; }

  .lp-values__grid { grid-template-columns: repeat(3, 1fr); gap: 24px; }
  .lp-features__list { grid-template-columns: repeat(2, 1fr); gap: 0 32px; }
  .lp-stat__num { font-size: 1.9rem; }

    .lp-phone-frame { max-height: 440px; }
  .lp-phone-frame img { height: 424px; }

  .lp-final-cta__heading { font-size: 1.8rem; }
  .lp-float-cta { display: none; }
  .lp-footer { padding-bottom: 32px; }
}

/* ── 動きを減らす設定への配慮 ──────────────────── */
@media (prefers-reduced-motion: reduce) {
  .lp-float-cta { transition: none; }
  .lp-cta-btn { transition: none; }
  .lp-cta-btn:hover { transform: none; }
}
