/* ============================================================
   SELF ANALYSIS — UIリニューアル検討デモ（demo-v2）専用CSS
   本番の style.css とは独立。パーソナルダッシュボード方向の検証用。
   ============================================================ */

:root {
  --paper: #ffffff;
  --paper-soft: #f4f4f5;
  --ink: #3a3a40;          /* 黒→濃いグレー（2026-09-25指示） */
  --ink-soft: #5a5a60;
  --sub: #8a8a90;
  --faint: #b5b5ba;
  --line: #e5e5e8;
  --accent: #3a3a40;        /* グレースケール厳守：強調は濃いグレー */
  --accent-soft: #ececee;
  --serif: 'Noto Serif JP', serif;
  --sans: 'Noto Sans JP', sans-serif;
  --maxw: 640px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-weight: 300;
  font-size: 15px;
  line-height: 1.9;
  letter-spacing: 0.01em;
  padding-bottom: 84px; /* 下部ナビぶん */
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }

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

/* ---- デモ注記バー ---- */
.demo-note {
  position: relative; z-index: 2;
  background: var(--ink);
  color: #cfccc5;
  font-size: 10.5px;
  letter-spacing: 0.12em;
  text-align: center;
  padding: 6px 12px;
}

/* ---- ヘッダー ---- */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0 6px;
}
.top-brand { font-family: var(--sans); font-size: 10px; letter-spacing: 0.32em; color: var(--faint); font-weight: 400; }
.top-quota { font-size: 11px; color: var(--sub); letter-spacing: 0.04em; }
.top-quota strong { color: var(--ink); font-weight: 500; font-size: 12.5px; }

/* ---- 見出しの型 ---- */
.eyebrow {
  font-family: var(--sans);
  font-size: 10.5px;
  font-weight: 400;
  letter-spacing: 0.3em;
  color: var(--sub);
  text-transform: uppercase;
}
.h-display {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 26px;
  line-height: 1.55;
  letter-spacing: 0.02em;
}
.h-section {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 18px;
  letter-spacing: 0.05em;
}
.muted { color: var(--sub); }
.small { font-size: 12.5px; }

/* ---- ボタン ---- */
.btn-primary {
  display: block;
  width: 100%;
  text-align: center;
  background: var(--accent);
  color: #fff;
  border: none;
  padding: 16px 0;
  font-size: 15px;
  font-weight: 400;
  letter-spacing: 0.18em;
  font-family: var(--serif);
  border-radius: 2px;
}
.btn-primary:active { opacity: 0.88; }
.btn-ghost {
  display: inline-block;
  background: transparent;
  border: none;
  color: var(--accent);
  font-size: 13px;
  letter-spacing: 0.06em;
  border-bottom: 1px solid currentColor;
  padding: 0 0 2px;
}

/* ---- 区切り ---- */
.hr { border: 0; border-top: 1px solid var(--line); margin: 34px 0; }

/* ============ ホーム ============ */
.greet { margin-top: 26px; }
.greet-hello { font-family: var(--serif); font-weight: 400; font-size: 22px; letter-spacing: 0.04em; }
.greet-date { font-size: 12px; color: var(--sub); margin-top: 4px; letter-spacing: 0.08em; }

.today { margin-top: 30px; }
.today-head { display: flex; align-items: baseline; gap: 12px; }
.today-phase { font-family: var(--serif); font-weight: 500; font-size: 20px; letter-spacing: 0.06em; }
.today-phase-note { font-size: 11.5px; color: var(--accent); letter-spacing: 0.08em; }
.today-line { margin-top: 10px; font-size: 14px; color: var(--ink-soft); }
.today-focus { margin-top: 14px; padding-left: 14px; border-left: 2px solid var(--accent); font-family: var(--serif); font-size: 14.5px; color: var(--ink); line-height: 1.9; }
.today-quote { margin-top: 18px; font-size: 12.5px; color: var(--sub); }
.today-quote em { font-style: normal; color: var(--ink-soft); }

.home-cta { margin: 30px 0 8px; }
.home-cta-sub { text-align: center; font-size: 11.5px; color: var(--sub); margin-top: 10px; }

.gates { margin-top: 14px; }
.gate { padding: 26px 0; border-bottom: 1px solid var(--line); display: block; }
.gate:first-child { border-top: 1px solid var(--line); }
.gate-title { font-family: var(--serif); font-weight: 500; font-size: 19px; letter-spacing: 0.06em; display: flex; justify-content: space-between; align-items: center; }
.gate-title .arr { color: var(--faint); font-size: 14px; font-weight: 300; }
.gate-desc { font-size: 12.5px; color: var(--sub); margin-top: 6px; }
.gate-links { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px 18px; }
.gate-links a { font-size: 12.5px; color: var(--ink-soft); border-bottom: 1px solid var(--line); padding-bottom: 2px; }

.home-foot { margin-top: 30px; font-size: 12px; color: var(--faint); }
.home-foot a { color: var(--sub); margin-right: 18px; }

/* ============ 下部ナビ ============ */
.bnav {
  position: fixed;
  left: 0; right: 0; bottom: 0;
  background: rgba(255, 255, 255, 0.96);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-top: 1px solid var(--line);
  display: flex;
  justify-content: space-around;
  padding: 8px 8px calc(10px + env(safe-area-inset-bottom));
  z-index: 100;
}
.bnav a {
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  font-size: 10px; letter-spacing: 0.1em; color: var(--faint);
  min-width: 64px;
}
.bnav a svg { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 1.5; }
.bnav a.is-active { color: var(--accent); }

/* ============ 分析レポート ============ */
.rep-hero { margin-top: 34px; text-align: center; }
.rep-catch {
  font-family: var(--serif); font-weight: 500;
  font-size: 27px; line-height: 1.7; letter-spacing: 0.04em;
  margin-top: 16px;
}
.rep-catch-sub { font-size: 13px; color: var(--sub); margin-top: 12px; }
.rep-types { margin-top: 22px; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.rep-type {
  font-size: 11.5px; color: var(--ink-soft);
  border: 1px solid var(--line); border-radius: 999px;
  padding: 5px 13px; letter-spacing: 0.05em; background: #fff;
}
.rep-type b { font-weight: 500; color: var(--ink); }

/* タブ（横スクロール・sticky） */
.rep-tabs {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, 0.97);
  border-bottom: 1px solid var(--line);
  margin: 30px -22px 0;
  padding: 0 22px;
  display: flex; gap: 24px;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.rep-tabs::-webkit-scrollbar { display: none; }
.rep-tab {
  flex: none;
  font-family: var(--serif); font-size: 14px; letter-spacing: 0.06em;
  color: var(--sub);
  padding: 13px 2px 11px;
  border-bottom: 2px solid transparent;
  background: none; border-top: none; border-left: none; border-right: none;
}
.rep-tab.is-active { color: var(--ink); border-bottom-color: var(--accent); }

.rep-sec { padding: 40px 0 8px; }
.rep-sec-eyebrow { font-size: 10.5px; letter-spacing: 0.3em; color: var(--accent); }
.rep-pull {
  font-family: var(--serif); font-weight: 500;
  font-size: 21px; line-height: 1.8; letter-spacing: 0.03em;
  margin-top: 14px;
}
.rep-sum { margin-top: 14px; font-size: 14px; color: var(--ink-soft); }
.rep-more { margin-top: 16px; }
.rep-more summary {
  list-style: none; display: inline-block;
  font-size: 12.5px; color: var(--accent); letter-spacing: 0.06em;
  border-bottom: 1px solid currentColor; padding-bottom: 2px; cursor: pointer;
}
.rep-more summary::-webkit-details-marker { display: none; }
.rep-more[open] summary { opacity: 0.5; }
.rep-more-body { margin-top: 16px; font-family: var(--serif); font-weight: 400; font-size: 14.5px; line-height: 2.1; color: var(--ink-soft); }
.rep-more-body p + p { margin-top: 14px; }
.rep-note { font-size: 11.5px; color: var(--faint); margin-top: 14px; }

/* これからの流れ */
.flow-list { margin-top: 18px; }
.flow-row {
  display: flex; align-items: baseline; gap: 14px;
  padding: 12px 0; border-bottom: 1px solid var(--line);
}
.flow-year { font-family: var(--serif); font-size: 15px; width: 52px; flex: none; }
.flow-phase { font-family: var(--serif); font-size: 14.5px; font-weight: 500; width: 62px; flex: none; }
.flow-gloss { font-size: 12px; color: var(--sub); }
.flow-row.is-now { border-left: 2px solid var(--accent); padding-left: 12px; margin-left: -14px; }
.flow-row.is-now .flow-year { color: var(--accent); }

/* PC調整 */
@media (min-width: 900px) {
  body { font-size: 15.5px; }
  .wrap { max-width: 720px; }
  .rep-catch { font-size: 32px; }
}

/* ============ 今日のじぶん ============ */
.jn-head { margin-top: 34px; }
.jn-q { font-family: var(--serif); font-weight: 500; font-size: 24px; letter-spacing: 0.04em; margin-top: 10px; }
.jn-date { font-size: 12px; color: var(--sub); margin-top: 6px; letter-spacing: 0.06em; }

.jn-block { margin-top: 34px; }
.jn-label { font-family: var(--serif); font-size: 15px; font-weight: 500; letter-spacing: 0.06em; }
.jn-label small { font-family: var(--sans); font-size: 10.5px; color: var(--faint); font-weight: 300; margin-left: 10px; letter-spacing: 0.12em; }
.jn-input {
  width: 100%;
  border: none;
  border-bottom: 1px solid var(--line);
  background: transparent;
  font-family: var(--serif);
  font-size: 15px;
  line-height: 2;
  padding: 10px 2px 8px;
  color: var(--ink);
  outline: none;
  resize: none;
}
.jn-input:focus { border-bottom-color: var(--accent); }
.jn-input::placeholder { color: var(--faint); font-size: 13.5px; }
.jn-save { margin-top: 34px; }

/* 観察の進み具合 */
.jn-progress { margin-top: 40px; }
.jn-progress-line { display: flex; align-items: center; gap: 7px; margin-top: 12px; }
.jn-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--line); }
.jn-dot.is-done { background: var(--accent); }
.jn-progress-text { font-size: 12.5px; color: var(--sub); margin-top: 10px; }
.jn-progress-text strong { color: var(--ink); font-weight: 500; }

/* リズム（コンパクト） */
.jn-rhythm { margin-top: 40px; padding-top: 26px; border-top: 1px solid var(--line); }
.jn-rhythm-line { display: flex; align-items: baseline; gap: 12px; margin-top: 10px; }
.jn-rhythm-phase { font-family: var(--serif); font-size: 17px; font-weight: 500; }
.jn-rhythm-tag { font-size: 12px; color: var(--sub); }

/* ============ メンター相談 ============ */
.mt-head { margin-top: 36px; }
.mt-q { font-family: var(--serif); font-weight: 500; font-size: 23px; line-height: 1.7; letter-spacing: 0.03em; margin-top: 10px; }
.mt-input {
  width: 100%;
  margin-top: 20px;
  border: 1px solid var(--line);
  border-radius: 2px;
  background: #fff;
  font-family: var(--serif);
  font-size: 15px;
  line-height: 2;
  padding: 16px 16px;
  min-height: 130px;
  color: var(--ink);
  outline: none;
  resize: none;
}
.mt-input:focus { border-color: var(--accent); }
.mt-input::placeholder { color: var(--faint); font-size: 13.5px; }

.mt-styles { margin-top: 30px; }
.mt-style-row { margin-top: 12px; display: flex; flex-direction: column; gap: 8px; }
.mt-style {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  border: 1px solid var(--line); border-radius: 2px; background: #fff;
  padding: 13px 16px; text-align: left; width: 100%;
}
.mt-style-name { font-family: var(--serif); font-size: 15px; letter-spacing: 0.05em; }
.mt-style-desc { font-size: 11px; color: var(--sub); }
.mt-style.is-active { border-color: var(--accent); }
.mt-style.is-active .mt-style-name { color: var(--accent); }

.mt-voices { margin-top: 18px; display: none; }
.mt-voices.is-open { display: block; }
.mt-voices-label { font-size: 11px; color: var(--sub); letter-spacing: 0.1em; }
.mt-voice-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.mt-voice {
  border: 1px solid var(--line); border-radius: 999px; background: #fff;
  font-size: 12px; color: var(--ink-soft); padding: 6px 14px; letter-spacing: 0.04em;
}
.mt-voice.is-active { border-color: var(--accent); color: var(--accent); }

.mt-send { margin-top: 26px; }
.mt-note { text-align: center; font-size: 11px; color: var(--faint); margin-top: 10px; letter-spacing: 0.04em; }

/* ---- 第二段階の微調整（GPTレビュー反映） ---- */
body { padding-bottom: 96px; }
.today-quote { font-size: 11.5px; color: var(--faint); }
.rep-animal { margin-top: 14px; font-size: 12px; color: var(--sub); letter-spacing: 0.04em; }
.rep-more summary::after { content: "▾"; margin-left: 7px; font-size: 10px; display: inline-block; transition: transform 0.15s; }
.rep-more[open] summary::after { transform: rotate(180deg); }
.gate:active { background: var(--paper-soft); }
.mt-style:active, .mt-voice:active, .rep-tab:active { background: var(--paper-soft); }

/* ---- 気になる人 ---- */
.pp-addwrap { margin-top: 24px; }
.pp-add {
  background: transparent; border: 1px solid var(--line); border-radius: 999px;
  padding: 9px 20px; font-size: 13px; color: var(--ink); letter-spacing: 0.06em;
}
.pp-add:active { background: var(--paper-soft); }
.pp-list { margin-top: 10px; }
.pp { padding: 22px 0; border-bottom: 1px solid var(--line); }
.pp-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.pp-name { font-family: var(--serif); font-weight: 500; font-size: 18px; letter-spacing: 0.05em; }
.pp-meta { font-size: 12px; color: var(--sub); }
.pp-acts { margin-top: 10px; display: flex; flex-wrap: wrap; gap: 8px 18px; }
.pp-acts a { font-size: 12.5px; color: var(--ink-soft); border-bottom: 1px solid var(--line); padding-bottom: 2px; }
.pp-acts a:active { color: var(--ink); border-bottom-color: var(--ink); }

/* ---- 相性診断 ---- */
.af-person { margin-top: 32px; }
.af-label { font-size: 10.5px; letter-spacing: 0.3em; color: var(--sub); }
.af-me { margin-top: 12px; display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.af-me-name { font-family: var(--serif); font-weight: 500; font-size: 18px; }
.af-me-meta { font-size: 11.5px; color: var(--sub); }
.af-change { font-size: 11.5px; color: var(--sub); border-bottom: 1px solid var(--line); padding-bottom: 1px; }
.af-seg { display: flex; gap: 0; margin-top: 14px; border: 1px solid var(--line); border-radius: 2px; overflow: hidden; }
.af-seg-btn {
  flex: 1; background: #fff; border: none; padding: 11px 0;
  font-size: 12.5px; color: var(--sub); letter-spacing: 0.04em;
}
.af-seg-btn.is-active { background: var(--ink); color: #fff; }
.af-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 14px; }
.af-chip {
  border: 1px solid var(--line); border-radius: 999px; background: #fff;
  font-size: 12.5px; color: var(--ink-soft); padding: 8px 16px; letter-spacing: 0.03em;
}
.af-chip.is-active { border-color: var(--ink); color: var(--ink); background: var(--paper-soft); }

/* ---- マイプロフィール ---- */
.pf-list { margin-top: 14px; }
.pf-row {
  display: grid; grid-template-columns: 1fr auto; grid-template-rows: auto auto;
  padding: 17px 0; border-bottom: 1px solid var(--line); align-items: baseline; column-gap: 10px;
}
.pf-row-title { font-family: var(--serif); font-weight: 500; font-size: 16px; letter-spacing: 0.05em; }
.pf-row-sub { grid-column: 1; font-size: 12px; color: var(--sub); margin-top: 4px; }
.pf-arr { grid-row: 1 / span 2; align-self: center; color: var(--faint); font-size: 14px; }
.pf-row:active { background: var(--paper-soft); }

/* ---- 第三段階：言葉の具体化・操作画面の密度調整 ---- */
.jn-lead { font-size: 12.5px; color: var(--sub); line-height: 1.9; margin-top: 10px; }
body.dense .greet { margin-top: 20px; }
body.dense .greet-hello { font-size: 20px; }
body.dense .today { margin-top: 24px; }
body.dense .home-cta { margin: 26px 0 6px; }
body.dense .hr { margin: 28px 0 0; }
body.dense .gate { padding: 22px 0; }
body.dense .gate-title { font-size: 18px; }
body.dense .jn-head { margin-top: 26px; }
body.dense .jn-q { font-size: 21px; }
body.dense .pp { padding: 18px 0; }
body.dense .pp-addwrap { margin-top: 18px; }
body.dense .af-person { margin-top: 26px; }
body.dense .pf-row { padding: 15px 0; }
.rep-catch-body { margin: 18px auto 0; max-width: 30em; font-size: 14px; line-height: 2; color: var(--ink-soft); text-align: left; }

/* ---- 仕上げパス：不具合修正と整理 ---- */
/* プロフィールのリズム行：矢印が左に落ちるグリッドバグを修正 */
.pf-row { grid-template-columns: 1fr auto; }
.pf-row-title { grid-column: 1; grid-row: 1; justify-self: start; }
.pf-row-sub { grid-column: 1; grid-row: 2; }
.pf-arr { grid-column: 2; grid-row: 1 / span 2; }
/* ホームの入口：未実装項目（リンクなし）は薄く、リンクと見分けがつくように */
.gate-links span { font-size: 12.5px; color: var(--faint); padding-bottom: 2px; }
/* レポート：セクション見出し削除に伴い上余白を微調整 */
.rep-sec { padding-top: 34px; }

/* ============ 質感パス：グレー濃淡の奥行き・弱い立体感・角丸統一（参考画像の2割） ============ */
/* 背景にごく薄いグレー、面はわずかに白く。色相は増やさない */
body { background: #fafafa; }

/* ホーム：今日のあなた＝ヒーローパネル（写真なし・グレー濃淡のみ） */
.today, body.dense .today {
  margin-top: 22px;
  background: linear-gradient(180deg, #ffffff 0%, #f1f1f3 100%);
  border: 1px solid #ececee;
  border-radius: 18px;
  padding: 22px 20px 20px;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 10px 28px rgba(20, 20, 25, 0.05);
}

/* 主要CTA：角丸12px統一＋ごく弱い立体感 */
.btn-primary {
  border-radius: 12px;
  background: linear-gradient(180deg, #4a4a51 0%, #3a3a40 100%);
  box-shadow: 0 6px 16px rgba(31, 31, 35, 0.16);
  transition: transform 0.1s, box-shadow 0.1s;
}
.btn-primary:active {
  transform: translateY(1px);
  box-shadow: 0 3px 8px rgba(31, 31, 35, 0.14);
  opacity: 1;
}

/* レポート冒頭：ここだけ少し特別に（本文は従来どおり） */
.rep-hero {
  margin-top: 22px;
  background: linear-gradient(180deg, #ffffff 0%, #f2f2f4 100%);
  border: 1px solid #ececee;
  border-radius: 20px;
  padding: 30px 20px 26px;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 10px 28px rgba(20, 20, 25, 0.05);
}
.rep-catch-body { text-align: center; }
.rep-tabs { background: rgba(250, 250, 250, 0.97); }

/* タイプタグ：白面＋ごく弱い影で上質に */
.rep-type {
  background: #fff;
  border-color: #e8e8ea;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}

/* 入力欄・選択肢：角丸を12pxに統一し、選択状態は薄グレー背景で */
.mt-input { border-radius: 12px; border-color: #e5e5e8; }
.mt-style { border-radius: 12px; }
.mt-style.is-active { background: #f4f4f5; border-color: var(--ink); }
.mt-style.is-active .mt-style-name { color: var(--ink); }
.af-seg { border-radius: 10px; }
.af-chip.is-active { background: #f0f0f2; }
.pp-form { background: #fff; border: 1px solid #ececee; border-radius: 14px; padding: 4px 16px 20px; margin-top: 14px; }

/* 下部ナビ：白ベース＋薄い境界線のまま、選択中だけ濃く（現状踏襲・明示） */
.bnav { background: rgba(255, 255, 255, 0.94); }
.bnav a.is-active { color: var(--ink); }
.bnav a.is-active svg { stroke-width: 1.9; }

/* ---- 質感の最終調整：影を1段弱め、全画面でトーンを統一 ---- */
/* ①レポート冒頭カード：影と背景差を弱めてなじませる */
.rep-hero {
  background: linear-gradient(180deg, #ffffff 0%, #f5f5f7 100%);
  border-color: #efeff1;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 6px 16px rgba(20, 20, 25, 0.035);
}
.today, body.dense .today {
  background: linear-gradient(180deg, #ffffff 0%, #f4f4f6 100%);
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 6px 16px rgba(20, 20, 25, 0.035);
}
/* ②主要ボタンの影を1段弱く統一 */
.btn-primary { box-shadow: 0 4px 12px rgba(31, 31, 35, 0.12); }
.btn-primary:active { box-shadow: 0 2px 6px rgba(31, 31, 35, 0.10); }
/* ③タグ・チップの見た目を全画面で統一（白面＋1px影＋角丸999） */
.af-chip, .mt-voice, .pp-add {
  background: #fff;
  border-color: #e8e8ea;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.af-chip.is-active { background: #f0f0f2; box-shadow: none; }
.mt-voice.is-active { background: #f0f0f2; box-shadow: none; border-color: var(--ink); color: var(--ink); }

/* ============ モーションパス：操作への返事だけ、短く小さく ============ */
/* OSの「視差効果を減らす」設定の人には自動で無効化 */
@media (prefers-reduced-motion: no-preference) {

  /* ① 選択・ホバーの状態変化をふわっと（0.18s） */
  .rep-tab, .af-seg-btn, .gate, .pf-row, .bnav a, .pp-acts a,
  .gate-links a, .rep-more summary, .jn-input, .mt-input {
    transition: background-color 0.18s ease, border-color 0.18s ease,
                color 0.18s ease, box-shadow 0.18s ease;
  }

  /* ② 押した感：チップ・選択肢はわずかに縮む（0.12s） */
  .af-chip, .mt-voice, .mt-style, .pp-add {
    transition: background-color 0.18s ease, border-color 0.18s ease,
                color 0.18s ease, box-shadow 0.18s ease, transform 0.12s ease;
  }
  .af-chip:active, .mt-voice:active, .mt-style:active, .pp-add:active {
    transform: scale(0.985);
  }

  /* ③ 開閉・出現：スッと入る（0.22-0.24s、操作直後だけ） */
  @keyframes v2FadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: none; }
  }
  .rep-more[open] .rep-more-body { animation: v2FadeIn 0.24s ease; }
  .mt-voices.is-open { animation: v2FadeIn 0.22s ease; }
  .pp-form:not([hidden]) { animation: v2FadeIn 0.24s ease; }
  #af-input:not([hidden]) { animation: v2FadeIn 0.22s ease; }

  /* ④ レポートのタブ切替：セクションがひと呼吸で現れる */
  .rep-sec { animation: v2FadeIn 0.24s ease; }
}

/* ============ 最終統一トークン：影・角丸・枠線を全画面で完全に揃える ============ */
/* ①主要ボタン：影をさらに1段弱く（全ページ同一） */
.btn-primary { box-shadow: 0 3px 8px rgba(31, 31, 35, 0.10); }
.btn-primary:active { box-shadow: 0 1px 4px rgba(31, 31, 35, 0.08); }

/* ②ヒーローカード（ホーム今日のあなた・レポート冒頭）：影をさらに弱く */
.rep-hero, .today, body.dense .today {
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 4px 12px rgba(20, 20, 25, 0.025);
}

/* ③タグ・チップ類：白面／枠線#e6e6e9／角丸999／影0 1px 2px で完全統一 */
.rep-type, .af-chip, .mt-voice, .pp-add {
  background: #fff;
  border: 1px solid #e6e6e9;
  border-radius: 999px;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.af-chip.is-active, .mt-voice.is-active {
  background: #f0f0f2;
  border-color: var(--ink);
  color: var(--ink);
  box-shadow: none;
}
/* 面要素の枠線色も同じトークンに */
.mt-style, .mt-input, .af-seg, .pp-form { border-color: #e6e6e9; }

/* ---- プロフィール：基本タイプをタップ可能なナビに ---- */
.pf-types { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.pf-type { display: inline-flex; align-items: center; gap: 4px; color: var(--ink-soft); }
.pf-type:active { background: #f0f0f2; }
.pf-chev { color: var(--faint); font-size: 13px; margin-left: 3px; line-height: 1; }
.pf-animal { margin-top: 12px; font-size: 12px; color: var(--sub); letter-spacing: 0.04em; }

/* ============ プロフィール：見本反映（2列タイプカード・アイコン・キャラ別枠） ============ */
.pf-types2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.pf-card {
  display: flex; align-items: center; gap: 8px;
  min-width: 0;
  background: #fff; border: 1px solid #e6e6e9; border-radius: 999px;
  padding: 12px 12px 12px 14px;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.pf-card:active { background: #f0f0f2; }
.pf-card-t { display: flex; flex-direction: column; line-height: 1.35; min-width: 0; overflow-wrap: anywhere; }
.pf-card-t small { font-size: 10.5px; color: var(--sub); letter-spacing: 0.08em; }
.pf-card-t { font-family: var(--serif); font-weight: 500; font-size: 13.5px; color: var(--ink); }
.pf-card .pf-chev { margin-left: auto; }
.pf-ic { width: 20px; height: 20px; color: #9a9aa0; flex: none; }
.pf-card .pf-ic { width: 17px; height: 17px; }
.pf-ic svg { width: 100%; height: 100%; stroke: currentColor; fill: none; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.pf-chara {
  display: inline-flex; align-items: center; gap: 10px;
  background: #fff; border: 1px solid #e6e6e9; border-radius: 999px;
  padding: 10px 20px; margin-top: 12px; color: var(--ink-soft);
}
.pf-chara b { font-family: var(--serif); font-weight: 500; font-size: 14px; color: var(--ink); }
/* リズム行：アイコン列を追加 */
.pf-row { grid-template-columns: auto 1fr auto; column-gap: 14px; }
.pf-row .pf-ic { grid-column: 1; grid-row: 1 / span 2; align-self: center; width: 22px; height: 22px; }
.pf-row-title { grid-column: 2; grid-row: 1; }
.pf-row-sub { grid-column: 2; grid-row: 2; }
.pf-arr { grid-column: 3; grid-row: 1 / span 2; }

/* ============ ホーム：今日のあなた＝1日1回のボトムシート＋コンパクト導線 ============ */
.today-mini {
  display: flex; flex-direction: column; align-items: flex-start; gap: 6px;
  width: 100%; text-align: left; margin-top: 22px;
  background: linear-gradient(180deg, #ffffff 0%, #f4f4f6 100%);
  border: 1px solid #ececee; border-radius: 16px;
  padding: 18px 18px 16px;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 4px 12px rgba(20, 20, 25, 0.025);
}
.today-mini-phase { font-family: var(--serif); font-weight: 500; font-size: 19px; letter-spacing: 0.05em; color: var(--ink); }
.today-mini-link { font-size: 12.5px; color: var(--ink-soft); border-bottom: 1px solid var(--line); padding-bottom: 1px; margin-top: 2px; }
.today-mini:active { background: #f1f1f3; }

.sheet-backdrop {
  position: fixed; inset: 0; z-index: 1300;
  background: rgba(25, 25, 30, 0.35);
  opacity: 0; transition: opacity 0.28s ease;
}
.sheet-backdrop.is-open { opacity: 1; }
.today-sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 1310;
  background: #fff;
  border-radius: 22px 22px 0 0;
  padding: 30px 26px calc(30px + env(safe-area-inset-bottom));
  max-height: 88vh; overflow-y: auto;
  box-shadow: 0 -8px 40px rgba(20, 20, 25, 0.14);
  transform: translateY(100%); transition: transform 0.28s ease;
}
.today-sheet.is-open { transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .today-sheet, .sheet-backdrop { transition: none; }
}
.sheet-close {
  position: absolute; top: 14px; right: 16px;
  background: transparent; border: none; font-size: 22px; color: var(--faint);
  width: 36px; height: 36px; line-height: 1;
}
.sheet-block { margin-top: 26px; }
.sheet-label { font-size: 10.5px; letter-spacing: 0.3em; color: var(--sub); }
.sheet-phase { font-family: var(--serif); font-weight: 500; font-size: 22px; letter-spacing: 0.05em; margin-top: 8px; }
.sheet-phase-note { font-size: 12px; color: var(--sub); letter-spacing: 0.08em; margin-left: 8px; }
.sheet-quote { font-family: var(--serif); font-weight: 500; font-size: 17px; line-height: 2; color: var(--ink); margin-top: 10px; }
.sheet-focus { font-family: var(--serif); font-size: 15px; line-height: 2; color: var(--ink); margin-top: 10px; padding-left: 14px; border-left: 2px solid var(--ink); }
.sheet-ok { margin-top: 32px; }

/* ---- ホーム再構成：今日の一言が主役、運勢はシートで ---- */
.quote-hero {
  margin-top: 22px;
  background: linear-gradient(180deg, #ffffff 0%, #f4f4f6 100%);
  border: 1px solid #ececee;
  border-radius: 16px;
  padding: 20px 20px 18px;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 4px 12px rgba(20, 20, 25, 0.025);
}
.quote-hero-body {
  font-family: var(--serif); font-weight: 500;
  font-size: 19px; line-height: 1.95; letter-spacing: 0.03em;
  color: var(--ink); margin-top: 12px;
}
.fortune-link {
  display: inline-block; margin-top: 16px;
  background: none; border: none; padding: 0 0 2px;
  font-size: 13px; color: var(--ink-soft);
  border-bottom: 1px solid var(--line); letter-spacing: 0.04em;
}
.fortune-link:active { color: var(--ink); border-bottom-color: var(--ink); }
.sheet-desc { font-size: 13.5px; line-height: 2; color: var(--ink-soft); margin-top: 12px; }

/* ---- 一言は左罫線のテキスト、リズム導線は独立した行ボタンに ---- */
.quote-hero2 { margin-top: 26px; padding-left: 16px; border-left: 2px solid var(--ink); }
.rhythm-row {
  display: flex; align-items: center; gap: 12px;
  width: 100%; margin-top: 24px; text-align: left;
  background: linear-gradient(180deg, #ffffff 0%, #f4f4f6 100%);
  border: 1px solid #ececee; border-radius: 14px;
  padding: 15px 16px;
  font-family: inherit; font-size: 14.5px; color: var(--ink); letter-spacing: 0.04em;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 4px 12px rgba(20, 20, 25, 0.025);
}
.rhythm-row:active { background: #f1f1f3; }
.rhythm-row-arr { margin-left: auto; color: var(--faint); font-size: 14px; }

/* 「詳しく読む」：開いたら閉じる操作は不要（リンクごと消えて本文が残る） */
.rep-more[open] summary { display: none; }
.rep-more[open] .rep-more-body { margin-top: 4px; }

/* ---- リズム全文＋リズムカレンダー ---- */
.sheet-suited { list-style: none; padding: 0; margin: 10px 0 0; }
.sheet-suited li {
  padding: 9px 0; border-bottom: 1px solid var(--line);
  font-size: 13px; line-height: 1.8; color: var(--ink-soft);
}
.sheet-suited li:last-child { border-bottom: none; }
.sheet-suited li b { display: block; font-weight: 600; font-size: 13.5px; color: var(--ink); letter-spacing: 0.03em; }
.sheet-caution { font-size: 13.5px; line-height: 2; color: var(--ink-soft); margin-top: 10px; padding-left: 14px; border-left: 2px solid #c9c9ce; }
.sheet-cal-link {
  display: inline-block; margin-top: 26px;
  font-size: 13px; color: var(--ink-soft); letter-spacing: 0.04em;
  border-bottom: 1px solid var(--line); padding-bottom: 2px;
}
.sheet-cal-link:active { color: var(--ink); border-bottom-color: var(--ink); }
.rep-more-body .sheet-cal-link { margin-top: 4px; }

.dcal-head {
  display: flex; align-items: center; justify-content: space-between;
  margin-top: 24px;
}
.dcal-month { font-family: var(--serif); font-weight: 500; font-size: 17px; letter-spacing: 0.08em; }
.dcal-navbtn {
  display: flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 12px;
  background: #fff; border: 1px solid var(--line);
  color: var(--ink-soft); font-size: 18px; line-height: 1;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.dcal-navbtn:active { background: #f0f0f2; }
.dcal-back { margin-top: 10px; font-size: 12.5px; }
.dcal-back a { color: var(--ink-soft); border-bottom: 1px solid var(--line); padding-bottom: 1px; }
.dcal-grid {
  display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px;
  margin-top: 16px;
  background: linear-gradient(180deg, #ffffff 0%, #f4f4f6 100%);
  border: 1px solid #ececee; border-radius: 16px;
  padding: 14px 10px 12px;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 4px 12px rgba(20, 20, 25, 0.025);
}
.dcal-wd { text-align: center; font-size: 10px; letter-spacing: 0.15em; color: var(--faint); padding-bottom: 6px; }
.dcal-day {
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  padding: 7px 0 6px; border-radius: 10px;
  background: transparent; border: 1px solid transparent;
  font-family: inherit; color: var(--ink);
}
.dcal-day:active { background: #f0f0f2; }
.dcal-num { font-size: 13px; line-height: 1; }
.dcal-phase { font-size: 8.5px; letter-spacing: 0.02em; color: var(--sub); }
.dcal-day.is-today { background: #f0f0f2; border-color: var(--ink); }
.dcal-day.is-today .dcal-num { font-weight: 700; }
.dcal-empty { border: none; background: transparent; }
@media (prefers-reduced-motion: no-preference) {
  .dcal-day { transition: background 0.18s ease; }
}

/* ---- ハンバーガードロワー（4タブに入らない機能の置き場） ---- */
.top-right { display: flex; align-items: center; gap: 10px; }
.top-menu {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 10px;
  background: transparent; border: none; color: var(--ink); padding: 0;
}
.top-menu svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; }
.top-menu:active { background: #f0f0f2; }

.drawer-backdrop {
  position: fixed; inset: 0; z-index: 1400;
  background: rgba(25, 25, 30, 0.35);
  opacity: 0; transition: opacity 0.28s ease;
}
.drawer-backdrop.is-open { opacity: 1; }
.drawer {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 1410;
  width: min(78vw, 300px);
  background: #fff;
  padding: 54px 24px calc(24px + env(safe-area-inset-bottom));
  overflow-y: auto;
  box-shadow: -8px 0 40px rgba(20, 20, 25, 0.14);
  transform: translateX(100%); transition: transform 0.28s ease;
  display: flex; flex-direction: column;
}
.drawer.is-open { transform: translateX(0); }
@media (prefers-reduced-motion: reduce) {
  .drawer, .drawer-backdrop { transition: none; }
}
.dw-group { margin-bottom: 26px; }
.dw-eyebrow { font-size: 10px; letter-spacing: 0.3em; color: var(--sub); margin-bottom: 4px; }
.dw-item {
  display: block; padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 14px; letter-spacing: 0.04em; color: var(--ink);
}
.dw-group .dw-item:last-child { border-bottom: none; }
a.dw-item:active { color: var(--sub); }
.dw-account {
  margin-top: auto; padding-top: 18px;
  border-top: 1px solid var(--line);
}
.dw-account-line { font-size: 12.5px; color: var(--ink-soft); letter-spacing: 0.04em; }
.dw-account-line strong { font-weight: 600; color: var(--ink); }
.dw-account-link {
  display: inline-block; margin-top: 8px;
  font-size: 12px; color: var(--sub);
  border-bottom: 1px solid var(--line); padding-bottom: 1px;
}
.drawer[hidden] { display: none; }

/* ---- これからの流れ：月×年の2サイクル＋深い分析タブ ---- */
.flow-label { font-size: 10.5px; letter-spacing: 0.3em; color: var(--sub); margin-top: 24px; }
.flow-mark { flex: none; font-size: 10.5px; color: var(--faint); letter-spacing: 0.08em; }
.flow-row-m .flow-year { width: 44px; }
.flow-m-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.flow-m-top { display: flex; align-items: baseline; gap: 8px; font-family: var(--serif); font-size: 14.5px; }
.flow-m-top b { font-weight: 500; }
.flow-ynote { font-size: 10.5px; letter-spacing: 0.2em; color: var(--faint); margin: 16px 0 2px; }
.flow-more {
  display: inline-block; margin-top: 16px;
  background: none; border: none; padding: 0 0 2px;
  font-family: inherit; font-size: 13px; color: var(--ink-soft);
  letter-spacing: 0.04em; border-bottom: 1px solid var(--line);
}
.flow-more::after { content: " ▾"; font-size: 10px; }
.flow-more:active { color: var(--ink); border-bottom-color: var(--ink); }
@media (prefers-reduced-motion: no-preference) {
  .flow-reveal { animation: v2FadeIn 0.24s ease; }
}

.rep-tab .tab-key { width: 13px; height: 13px; margin-right: 5px; vertical-align: -2px; opacity: 0.55; }
.rep-tab.is-active .tab-key { opacity: 1; }
.deep-card {
  margin-top: 20px;
  background: linear-gradient(180deg, #ffffff 0%, #f4f4f6 100%);
  border: 1px solid #ececee; border-radius: 16px;
  padding: 22px 20px;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 4px 12px rgba(20, 20, 25, 0.025);
}
.deep-list { list-style: none; padding: 0; margin: 0; }
.deep-list li {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 0; border-bottom: 1px solid var(--line);
  font-size: 13.5px; letter-spacing: 0.03em; color: var(--ink);
}
.deep-list li:last-child { border-bottom: none; }
.deep-list .tab-key { flex: none; width: 14px; height: 14px; margin: 0; opacity: 0.45; }
.flow-more[hidden] { display: none; }

/* ---- 返事が途中で切れたときの「続きを読む」（見本） ---- */
.mt-resume { margin-top: 8px; }
.mt-bubble {
  margin-top: 14px;
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  padding: 16px 18px;
  font-size: 13.5px; line-height: 2; color: var(--ink-soft);
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 4px 12px rgba(20, 20, 25, 0.025);
}
.mt-bubble p + p { margin-top: 10px; }
.mt-bubble.is-cut { position: relative; padding-bottom: 26px; }
.mt-bubble.is-cut::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 34px;
  background: linear-gradient(180deg, rgba(255,255,255,0) 0%, #fff 85%);
  border-radius: 0 0 16px 16px;
}
.mt-resume-act { margin-top: 12px; text-align: center; }
.mt-continue {
  display: inline-block;
  background: #fff; border: 1px solid var(--ink); border-radius: 999px;
  padding: 10px 22px;
  font-family: inherit; font-size: 13.5px; color: var(--ink); letter-spacing: 0.04em;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.mt-continue:active { background: #f0f0f2; }
.mt-continue-note { margin-top: 7px; font-size: 11.5px; color: var(--sub); letter-spacing: 0.05em; }
.mt-resume-act[hidden] { display: none; }

/* ---- レポートのタブ列：スマホで「深い分析」が隠れる対策 ---- */
.rep-tabs-wrap {
  position: sticky; top: 0; z-index: 50;
  margin: 30px -22px 0;
  overflow: hidden;
}
.rep-tabs-wrap .rep-tabs { position: static; margin: 0; gap: 18px; }
.rep-tabs-wrap::after {
  content: ""; position: absolute; top: 0; right: 0; bottom: 1px; width: 60px;
  background: linear-gradient(90deg, rgba(250, 250, 250, 0) 0%, rgba(250, 250, 250, 0.96) 75%);
  pointer-events: none;
  opacity: 1; transition: opacity 0.18s ease;
}
.rep-tabs-wrap.at-end::after { opacity: 0; }
/* 右端の「まだ先がある」矢印（ゆっくり明滅、末尾までスクロールしたら消える） */
.rep-tabs-wrap::before {
  content: "›"; position: absolute; right: 9px; top: 50%;
  transform: translateY(-56%);
  font-size: 19px; line-height: 1; color: var(--ink-soft);
  z-index: 1; pointer-events: none;
  animation: tabs-hint 2.2s ease-in-out infinite;
}
@keyframes tabs-hint {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 0.9; }
}
@media (prefers-reduced-motion: reduce) {
  .rep-tabs-wrap::before { animation: none; opacity: 0.6; }
}
.rep-tabs-wrap.at-end::before { animation: none; opacity: 0; transition: opacity 0.18s ease; }

/* ---- 日本語の文字組み見直し（意味のまとまり優先・2026-09-25指示） ---- */
/* 文節の切れ目で折り返す（Chrome系。未対応ブラウザは通常折返し） */
body { word-break: auto-phrase; line-break: strict; }

/* 見出し・キャッチ：行のバランスを取り、1つの言葉として見えるよう行間を締める */
.rep-catch, .rep-pull, .jn-q, .mt-q, .quote-hero-body, .sheet-phase { text-wrap: balance; }
.rep-catch { line-height: 1.55; }
.rep-pull { line-height: 1.6; }
.quote-hero-body { line-height: 1.75; }
.mt-q { line-height: 1.6; }

/* 本文：左揃え・段落末の孤立を防ぐ（中央揃えは短いキャッチのみ） */
p { text-wrap: pretty; }
.rep-catch-body { text-align: left; }

/* 文字数に応じた可変サイズ（base.htmlのJSが長文にだけ付与） */
.rep-catch.fit-sm { font-size: 23px; }
.rep-catch.fit-xs { font-size: 20px; }
.quote-hero-body.fit-sm { font-size: 17px; }
.quote-hero-body.fit-xs { font-size: 15.5px; }
.rep-pull.fit-sm { font-size: 18.5px; }
.mt-q.fit-sm, .jn-q.fit-sm { font-size: 20px; }

/* ---- ホームの背景：グレーの葉影＋淡い光（質感2割・ホームのみ） ---- */
body.leafy { position: relative; }
body.leafy::before {
  content: ""; position: fixed; left: 0; right: 0; top: 0; height: 68vh;
  background:
    linear-gradient(115deg, rgba(58, 58, 64, 0) 42%, rgba(255, 255, 255, 0.55) 52%, rgba(58, 58, 64, 0) 62%),
    url("/static/demo-v2-leaves.svg") no-repeat right -80px top -60px / 540px auto,
    linear-gradient(180deg, rgba(58, 58, 64, 0.045) 0%, rgba(58, 58, 64, 0) 80%);
  pointer-events: none; z-index: 0;
  -webkit-mask-image: linear-gradient(180deg, #000 55%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 55%, transparent 100%);
}
body.leafy .wrap { position: relative; z-index: 1; }

/* ============================================================
   ここから本番専用の追加（base_v2 系）
   ============================================================ */

/* 期限切れカウントダウンバナー（旧 expiry-banner の v2 版） */
.expiry-banner {
  background: #f0f0f2; color: var(--ink);
  font-size: 12px; letter-spacing: 0.04em;
  text-align: center; padding: 8px 12px;
  border-bottom: 1px solid var(--line);
  position: relative; z-index: 2;
}
.expiry-banner-link { color: var(--ink); font-weight: 600; border-bottom: 1px solid var(--ink); margin-left: 6px; }

/* 今日の一言：本文の改行をそのまま表示＋お気に入り */
.quote-hero-body { white-space: pre-line; }
.quote-like-row { display: flex; align-items: center; gap: 14px; margin-top: 12px; padding-left: 16px; }
.quote-like {
  display: inline-flex; align-items: center; gap: 6px;
  background: none; border: none; padding: 2px 0;
  font-family: inherit; font-size: 12.5px; color: var(--sub); letter-spacing: 0.04em;
}
.quote-like.is-liked { color: var(--ink); }
.quote-liked-list-link { font-size: 12px; color: var(--sub); border-bottom: 1px solid var(--line); padding-bottom: 1px; }

/* ロック行（初回の顔） */
.gate-locked .gate-title { color: var(--sub); }
.gate-lock-ic { width: 13px; height: 13px; margin-right: 6px; vertical-align: -1.5px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; }

/* 使い方・FAQ などの読み物ページ */
.prose { margin-top: 10px; }
.prose h2 { font-family: var(--serif); font-weight: 500; font-size: 19px; letter-spacing: 0.04em; margin: 34px 0 10px; }
.prose h3 { font-family: var(--serif); font-weight: 500; font-size: 15.5px; letter-spacing: 0.03em; margin: 24px 0 8px; }
.prose p, .prose li { font-size: 13.5px; line-height: 2; color: var(--ink-soft); }
.prose ul, .prose ol { padding-left: 1.3em; margin: 8px 0; }
.prose section { margin-bottom: 8px; }
.prose details { margin: 10px 0; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; }
.prose details summary { font-size: 13.5px; color: var(--ink); letter-spacing: 0.03em; cursor: pointer; }
.prose details[open] summary { margin-bottom: 8px; }
.prose a { color: var(--ink); border-bottom: 1px solid var(--line); }
.sheet-optout {
  display: flex; align-items: center; gap: 8px;
  margin-top: 20px;
  font-size: 12px; color: var(--sub); letter-spacing: 0.03em;
}
.sheet-optout input { accent-color: var(--ink); width: 15px; height: 15px; }

/* ---- 本番レポート（result.html v2） ---- */
.rep-block { margin-bottom: 36px; }
.rep-label { font-size: 10.5px; letter-spacing: 0.3em; color: var(--sub); margin-bottom: 6px; }
.rep-body { margin-top: 12px; font-family: var(--serif); font-weight: 400; font-size: 14.5px; line-height: 2.1; color: var(--ink-soft); }
.rep-sub-h { font-family: var(--serif); font-weight: 500; font-size: 15.5px; letter-spacing: 0.03em; margin-top: 22px; }
.rep-kv { display: grid; grid-template-columns: auto 1fr; gap: 8px 18px; margin-top: 12px; }
.rep-kv dt { font-size: 12px; color: var(--sub); letter-spacing: 0.05em; padding-top: 1px; }
.rep-kv dd { font-size: 13.5px; color: var(--ink); letter-spacing: 0.03em; }

details.frow { border-bottom: 1px solid var(--line); }
details.frow summary {
  list-style: none; display: flex; align-items: baseline; gap: 14px;
  padding: 13px 0; cursor: pointer;
}
details.frow summary::-webkit-details-marker { display: none; }
details.frow summary::after { content: "▾"; margin-left: auto; font-size: 10px; color: var(--faint); transition: transform 0.15s; }
details.frow[open] summary::after { transform: rotate(180deg); }
details.frow .flow-year { width: 52px; flex: none; }
.frow-name { font-family: var(--serif); font-size: 14.5px; font-weight: 500; }
.frow-age { font-size: 10.5px; color: var(--faint); margin-left: 7px; font-weight: 400; }
details.frow.is-now { border-left: 2px solid var(--accent); padding-left: 12px; margin-left: -14px; }
.frow-detail { padding: 2px 0 18px; }
.frow-tagline { font-family: var(--serif); font-weight: 500; font-size: 14px; color: var(--ink); }
.frow-detail .rep-body { margin-top: 8px; font-size: 13.5px; line-height: 2; }
.frow-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
.frow-cols .sheet-label { margin-bottom: 6px; }
.frow-ul { list-style: none; padding: 0; margin: 0; }
.frow-ul li {
  font-size: 12.5px; line-height: 1.8; color: var(--ink-soft);
  padding: 5px 0; border-bottom: 1px solid var(--line);
}
.frow-ul li:last-child { border-bottom: none; }
@media (prefers-reduced-motion: no-preference) {
  details.frow[open] .frow-detail { animation: v2FadeIn 0.22s ease; }
}

.lock-note { margin-top: 22px; text-align: center; }
.lock-note p { font-size: 12.5px; color: var(--sub); margin-bottom: 12px; }

/* ---- 第2段：相性フォーム・プロフィール ---- */
.form-error { margin-top: 14px; font-size: 13px; color: var(--ink); padding: 10px 14px; background: #f0f0f2; border-left: 2px solid var(--ink); }
.af-chip input[type=radio] { position: absolute; opacity: 0; pointer-events: none; }
.af-chip { position: relative; }
.af-chips-s .af-chip { font-size: 12px; padding: 7px 14px; }
.dob-row3 { display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 8px; }
.v2-select {
  width: 100%; appearance: none; -webkit-appearance: none;
  background: #fff url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%238a8a90' stroke-width='1.4' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 12px center;
  border: 1px solid var(--line); border-radius: 12px;
  padding: 12px 28px 12px 14px;
  font-family: inherit; font-size: 14px; color: var(--ink);
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.v2-select:focus { outline: none; border-color: var(--ink); }
.dob-age { margin-top: 8px; font-size: 12px; color: var(--sub); letter-spacing: 0.05em; }
.af-pick-empty { margin-top: 12px; font-size: 12.5px; line-height: 1.9; color: var(--sub); }
.af-me-meta { font-size: 12px; color: var(--sub); }

.ref-box { margin-top: 16px; }
.ref-row { display: flex; gap: 8px; margin-top: 6px; }
.ref-input { flex: 1; font-size: 12px; color: var(--ink-soft); }
.ref-copy {
  flex: none; background: #fff; border: 1px solid var(--ink); border-radius: 999px;
  padding: 0 18px; font-family: inherit; font-size: 12.5px; color: var(--ink); letter-spacing: 0.04em;
}
.ref-copy.copied { background: #f0f0f2; }
.ref-code-line { margin-top: 12px; font-size: 12.5px; color: var(--sub); }
.ref-code { font-size: 14px; color: var(--ink); letter-spacing: 0.12em; margin-left: 8px; }
.ref-stats { margin-top: 8px; font-size: 12.5px; color: var(--sub); }
.ref-stats b { color: var(--ink); }

.pf-delete {
  background: none; border: none; padding: 0 0 2px;
  font-family: inherit; font-size: 12px; color: var(--faint);
  border-bottom: 1px solid var(--line); letter-spacing: 0.04em;
}
.pf-delete:active { color: var(--ink); }
button.af-change {
  background: none; border: none; padding: 0 0 1px;
  font-family: inherit; font-size: 12px; color: var(--sub);
  border-bottom: 1px solid var(--line); letter-spacing: 0.04em;
}

/* ---- 第3段：メンターチャット（クラス名は旧実装を継承） ---- */
body.mentor-v2 .wrap { padding-bottom: 210px; }
.mentor-convo-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  margin-top: 14px;
}
.mentor-convo-label { display: block; font-size: 10px; letter-spacing: 0.25em; color: var(--faint); }
.mentor-convo-title { font-size: 13px; color: var(--ink-soft); }
.mentor-convo-actions { display: flex; gap: 8px; flex: none; }
.mentor-convo-btn {
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 7px 13px; font-family: inherit; font-size: 12px; color: var(--ink-soft);
  letter-spacing: 0.03em; box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.mentor-convo-btn:active { background: #f0f0f2; }
.mentor-convo-menu-wrap { position: relative; }
.mentor-convo-menu {
  position: absolute; right: 0; top: calc(100% + 8px); z-index: 900;
  width: min(78vw, 320px); max-height: 60vh; overflow-y: auto;
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: 10px 14px;
  box-shadow: 0 8px 32px rgba(20, 20, 25, 0.14);
}
.mentor-convo-menu-empty { font-size: 12px; color: var(--sub); padding: 8px 0; }
.mentor-convo-menu-list { list-style: none; padding: 0; margin: 0; }
.mentor-convo-menu-date { font-size: 10.5px; letter-spacing: 0.2em; color: var(--faint); padding: 10px 0 4px; }
.mentor-convo-menu-item { display: flex; align-items: center; gap: 6px; border-bottom: 1px solid var(--line); }
.mentor-convo-menu-item:last-child { border-bottom: none; }
.mentor-convo-menu-item.is-active .mentor-convo-menu-title { color: var(--ink); font-weight: 600; }
.mentor-convo-menu-link {
  flex: 1; min-width: 0; text-align: left;
  background: none; border: none; padding: 9px 0; font-family: inherit;
}
.mentor-convo-menu-title { display: block; font-size: 13px; color: var(--ink-soft); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.mentor-convo-menu-meta { display: block; font-size: 10.5px; color: var(--faint); margin-top: 2px; }
.mentor-convo-menu-delete {
  flex: none; background: none; border: none; font-size: 15px; color: var(--faint);
  width: 30px; height: 30px; line-height: 1;
}

.mentor-mode-row { display: flex; flex-direction: column; gap: 8px; margin-top: 18px; }
.mentor-mode-chip {
  display: flex; align-items: baseline; gap: 10px; width: 100%;
  background: #fff; border: 1px solid var(--line); border-radius: 14px;
  padding: 12px 16px; text-align: left; font-family: inherit;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.mentor-mode-chip .mentor-mode-name { font-family: var(--serif); font-weight: 500; font-size: 14.5px; color: var(--ink); flex: none; }
.mentor-mode-chip .mentor-mode-desc { font-size: 11.5px; color: var(--sub); }
.mentor-mode-chip[aria-pressed="true"] { background: #f0f0f2; border-color: var(--ink); box-shadow: none; }
.mentor-spicy-panel { margin-top: 10px; }
.mentor-spicy-hint { font-size: 11.5px; color: var(--sub); letter-spacing: 0.03em; }
.mentor-spicy-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.mentor-spicy-chip {
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 8px 14px; font-family: inherit; font-size: 12px; color: var(--ink-soft);
  letter-spacing: 0.03em; box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.mentor-spicy-chip[aria-pressed="true"] { background: #f0f0f2; border-color: var(--ink); color: var(--ink); box-shadow: none; }

.mentor-chat { margin-top: 22px; }
.mentor-welcome {
  background: linear-gradient(180deg, #ffffff 0%, #f4f4f6 100%);
  border: 1px solid #ececee; border-radius: 16px; padding: 20px 18px;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 4px 12px rgba(20, 20, 25, 0.025);
}
.mentor-welcome-body { font-size: 13.5px; line-height: 2; color: var(--ink-soft); }
.mentor-parenting-guide { margin-top: 14px; padding-top: 12px; border-top: 1px solid var(--line); }
.mentor-parenting-guide-text { font-size: 12px; line-height: 1.9; color: var(--sub); }
.mentor-guide-btns { display: flex; gap: 8px; margin-top: 10px; }
.mentor-parenting-guide-btn {
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 8px 14px; font-size: 12px; color: var(--ink-soft); letter-spacing: 0.03em;
}

.mentor-bubble-wrap { margin-top: 16px; }
.mentor-bubble { border-radius: 16px; padding: 13px 16px; font-size: 13.5px; line-height: 2; }
.mentor-bubble-user { display: flex; flex-direction: column; align-items: flex-end; }
.mentor-bubble-user-body {
  max-width: 85%; background: linear-gradient(180deg, #4a4a51 0%, #3a3a40 100%);
  color: #fff; border-radius: 16px 16px 4px 16px;
  white-space: pre-wrap;
}
.mentor-bubble-assistant-body {
  background: #fff; border: 1px solid var(--line);
  border-radius: 16px 16px 16px 4px;
  color: var(--ink-soft);
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 4px 12px rgba(20, 20, 25, 0.025);
}
.mentor-bubble-error-body {
  background: #f0f0f2; border-left: 2px solid var(--ink);
  border-radius: 4px 14px 14px 4px; color: var(--ink);
  font-size: 12.5px;
}
.mentor-bubble-meta { margin-top: 5px; font-size: 10.5px; color: var(--faint); letter-spacing: 0.05em; }
.mentor-bubble-user .mentor-bubble-meta { text-align: right; }
.mentor-answer-p { white-space: pre-wrap; }
.mentor-answer-p + .mentor-answer-p { margin-top: 10px; }
.mentor-answer-head {
  font-family: var(--serif); font-weight: 500; font-size: 14px; color: var(--ink);
  padding-left: 10px; border-left: 2px solid var(--ink);
  margin: 16px 0 6px;
}
.mentor-answer-head:first-child { margin-top: 0; }
.mentor-bubble-thinking { display: flex; align-items: center; gap: 10px; color: var(--sub); font-size: 12.5px; }
.mentor-thinking-dots { display: inline-flex; gap: 4px; }
.mentor-thinking-dots span {
  width: 5px; height: 5px; border-radius: 50%; background: var(--faint);
  animation: mentorDot 1.2s ease-in-out infinite;
}
.mentor-thinking-dots span:nth-child(2) { animation-delay: 0.2s; }
.mentor-thinking-dots span:nth-child(3) { animation-delay: 0.4s; }
@keyframes mentorDot { 0%, 60%, 100% { opacity: 0.35; } 30% { opacity: 1; } }

.mentor-continue-act { margin-top: 10px; display: flex; align-items: center; gap: 10px; }
.mentor-continue-btn {
  background: #fff; border: 1px solid var(--ink); border-radius: 999px;
  padding: 9px 18px; font-family: inherit; font-size: 12.5px; color: var(--ink);
  letter-spacing: 0.04em; box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.mentor-continue-btn:disabled { opacity: 0.5; }
.mentor-continue-note { font-size: 11px; color: var(--sub); }

.mentor-bottom-fixed {
  position: fixed; left: 0; right: 0; bottom: calc(58px + env(safe-area-inset-bottom));
  z-index: 950;
  background: rgba(250, 250, 250, 0.97);
  border-top: 1px solid var(--line);
  padding: 8px 16px 10px;
}
.mentor-input-hint { font-size: 10.5px; color: var(--faint); text-align: center; letter-spacing: 0.04em; margin-bottom: 7px; }
.mentor-input-area { display: flex; align-items: flex-end; gap: 8px; max-width: var(--maxw); margin: 0 auto; }
.mentor-input {
  flex: 1; resize: none;
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  padding: 11px 15px; font-family: inherit; font-size: 14px; line-height: 1.7; color: var(--ink);
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.04);
}
.mentor-input:focus { outline: none; border-color: var(--ink); }
.mentor-send {
  flex: none; width: 42px; height: 42px; border-radius: 50%;
  background: linear-gradient(180deg, #4a4a51 0%, #3a3a40 100%);
  border: none; display: flex; align-items: center; justify-content: center;
  box-shadow: 0 3px 8px rgba(31, 31, 35, 0.14);
}
.mentor-send:disabled { opacity: 0.5; }
.mentor-send svg { width: 17px; height: 17px; fill: none; stroke: #fff; stroke-width: 1.8; stroke-linejoin: round; }

/* ---- 回数確認モーダル（quota-confirm.js が生成するDOM） ---- */
#quota-confirm-overlay {
  position: fixed; inset: 0; z-index: 1500;
  background: rgba(25, 25, 30, 0.35);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
}
.quota-confirm-card {
  width: min(100%, 340px);
  background: #fff; border-radius: 18px;
  padding: 24px 22px;
  box-shadow: 0 12px 40px rgba(20, 20, 25, 0.18);
}
.quota-confirm-title { font-family: var(--serif); font-weight: 500; font-size: 16px; letter-spacing: 0.04em; color: var(--ink); }
.quota-confirm-body { margin-top: 10px; font-size: 13px; line-height: 1.9; color: var(--ink-soft); }
.quota-confirm-buttons { display: flex; gap: 10px; margin-top: 18px; }
.quota-confirm-btn {
  flex: 1; border-radius: 12px; padding: 12px 0;
  font-family: inherit; font-size: 13.5px; letter-spacing: 0.06em;
}
.quota-confirm-cancel { background: #fff; border: 1px solid var(--line); color: var(--ink-soft); }
.quota-confirm-ok {
  background: linear-gradient(180deg, #4a4a51 0%, #3a3a40 100%);
  border: none; color: #fff;
  box-shadow: 0 3px 8px rgba(31, 31, 35, 0.14);
}
.quota-confirm-skip {
  display: block; margin: 14px auto 0;
  background: none; border: none; padding: 0 0 1px;
  font-family: inherit; font-size: 11.5px; color: var(--sub);
  border-bottom: 1px solid var(--line);
}

/* ---- 相談履歴・お気に入り・画像保存 ---- */
.mh-list { margin-top: 20px; }
.mentor-history-empty, .liked-quotes-empty { font-size: 13px; line-height: 2; color: var(--sub); padding: 24px 0; text-align: center; }
details.mentor-history-item { border-bottom: 1px solid var(--line); }
.mentor-history-summary {
  list-style: none; display: block; padding: 14px 0; cursor: pointer;
}
.mentor-history-summary::-webkit-details-marker { display: none; }
.mentor-history-date { display: block; font-size: 10.5px; color: var(--faint); letter-spacing: 0.06em; }
.mentor-history-question { display: block; margin-top: 4px; font-size: 13.5px; color: var(--ink); line-height: 1.8; }
.mentor-history-detail { padding: 4px 0 18px; }
.mentor-history-block { margin-top: 10px; }
.mentor-history-block-label { font-size: 10.5px; letter-spacing: 0.25em; color: var(--sub); }
.mentor-history-block-body { margin-top: 6px; font-size: 13px; line-height: 2; color: var(--ink-soft); white-space: pre-wrap; }
.mentor-history-acts { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 14px; }
.mentor-history-continue {
  font-size: 12.5px; color: var(--ink); border-bottom: 1px solid var(--line); padding-bottom: 1px;
}
.mentor-history-delete, .mentor-history-clear {
  background: none; border: none; padding: 0 0 1px;
  font-family: inherit; font-size: 11.5px; color: var(--faint);
  border-bottom: 1px solid var(--line);
}
.mentor-history-actions { margin-top: 18px; text-align: center; }

.liked-quote-card {
  position: relative;
  background: #fff; border: 1px solid var(--line); border-radius: 16px;
  padding: 18px; margin-bottom: 12px;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03), 0 4px 12px rgba(20, 20, 25, 0.025);
}
.quote-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.quote-label { font-size: 10px; letter-spacing: 0.25em; color: var(--sub); }
.quote-date { font-size: 11px; color: var(--faint); }
.liked-quote-card .quote-body {
  margin-top: 12px; font-family: var(--serif); font-weight: 500;
  font-size: 15.5px; line-height: 2; color: var(--ink); letter-spacing: 0.03em;
}
.liked-quote-card .quote-actions { margin-top: 12px; }

/* share-image.js が生成するボタン */
.share-card-btn {
  position: absolute; right: 12px; bottom: 12px;
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  padding: 6px 12px; font-family: inherit; font-size: 11px; color: var(--ink-soft);
  letter-spacing: 0.04em; box-shadow: 0 1px 2px rgba(20, 20, 25, 0.06);
}
.share-fab {
  position: fixed; right: 16px; bottom: calc(76px + env(safe-area-inset-bottom)); z-index: 940;
  background: linear-gradient(180deg, #4a4a51 0%, #3a3a40 100%);
  color: #fff; border: none; border-radius: 999px;
  padding: 11px 18px; font-family: inherit; font-size: 12px; letter-spacing: 0.05em;
  box-shadow: 0 4px 14px rgba(31, 31, 35, 0.22);
}
.share-fab-toast {
  position: fixed; left: 50%; transform: translateX(-50%);
  bottom: calc(130px + env(safe-area-inset-bottom)); z-index: 941;
  background: #3a3a40; color: #fff; border-radius: 999px;
  padding: 9px 16px; font-size: 12px; opacity: 0; transition: opacity 0.2s;
  pointer-events: none;
}
.share-fab-toast.is-visible { opacity: 1; }

/* ---- ホーム：よく使う機能ショートカット ---- */
.sc-sec { margin-top: 26px; }
.sc-head { display: flex; align-items: baseline; justify-content: space-between; }
.sc-edit {
  background: none; border: none; padding: 0 0 1px;
  font-family: inherit; font-size: 12px; color: var(--sub);
  border-bottom: 1px solid var(--line); letter-spacing: 0.04em;
}
.sc-edit:active { color: var(--ink); }
.sc-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; margin-top: 14px; }
.sc-item { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.sc-ic {
  display: flex; align-items: center; justify-content: center;
  width: 60px; height: 60px; border-radius: 50%;
  background: #f0f0f2;
  box-shadow: 0 1px 2px rgba(20, 20, 25, 0.03);
}
.sc-ic svg { width: 24px; height: 24px; fill: none; stroke: var(--ink); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.sc-item:active .sc-ic { background: #e8e8ea; }
.sc-label { font-size: 11px; color: var(--ink-soft); letter-spacing: 0.03em; text-align: center; }
@media (prefers-reduced-motion: no-preference) {
  .sc-ic { transition: background 0.15s ease, transform 0.12s ease; }
  .sc-item:active .sc-ic { transform: scale(0.96); }
}

.sc-pick-list { list-style: none; padding: 0; margin: 12px 0 0; }
.sc-pick {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 0; border-bottom: 1px solid var(--line);
  cursor: pointer;
}
.sc-pick:last-child { border-bottom: none; }
.sc-pick-num {
  flex: none; width: 24px; height: 24px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--line); font-size: 12px; color: var(--sub);
}
.sc-pick.is-on .sc-pick-num { background: var(--ink); border-color: var(--ink); color: #fff; }
.sc-pick-ic { width: 38px; height: 38px; flex: none; }
.sc-pick-ic svg { width: 19px; height: 19px; }
.sc-pick-label { font-size: 13.5px; color: var(--ink); letter-spacing: 0.03em; }
.sc-pick.is-on .sc-pick-label { font-weight: 600; }
/* 保存ボタンはシート下部に常時表示（リストが長くてもスクロールに沈まない） */
#sc-sheet { padding-bottom: 0; }
.sc-save-wrap {
  position: sticky; bottom: 0; z-index: 2;
  margin: 8px -26px 0;
  padding: 14px 26px calc(16px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, #fff 32%);
}
.sc-save-wrap .sheet-ok { margin-top: 0; }
button.rep-type { font-family: inherit; cursor: pointer; }
button.rep-type:active { background: #f0f0f2; }

/* 旧style.cssのアイコン縮小ルールを移植（_icon_*.html のSVGが原寸で巨大表示されるのを防ぐ） */
.ic {
  width: 1em; height: 1em; display: inline-block;
  vertical-align: -0.125em; flex: none;
}
