/* バイクメモリー LP（mente.smcn-jp.com）。色はアプリの theme.css（黒×ゴールド、49edeec）（docs/mente/04-design-system.md §2）と同じ値
   外へは何も読みに行かない（書体も fonts/ に同梱）。ビルドなしでそのまま配信する */

@font-face {
  font-family: 'M PLUS 1 LP';
  src: url('fonts/mplus1-400.woff2') format('woff2');
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: 'M PLUS 1 LP';
  src: url('fonts/mplus1-700.woff2') format('woff2');
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: 'M PLUS 1 LP';
  src: url('fonts/mplus1-800.woff2') format('woff2');
  font-weight: 800;
  font-display: swap;
}

:root {
  --bg: #ffffff;
  --surface: #f3f4f5;
  --ink: #1b1e22;
  --sub: #5d636b;
  --line: #e3e6e9;
  --edge: #868c95;
  --accent: #1b1e22;        /* 主ボタン: 黒に金の字（9.9） */
  --accent-text: #7d5b10;   /* 金茶の字（白地 6.22） */
  --accent-ink: #e3c477;
  --accent-soft: #f7f0de;
  --gold: #e3c477;
  --ok: #15803d;
  --soon-fill: #facc15;
  --soon-bar: #ca8a04;
  --due: #dc2626;
  --on-bright: #1b1e22;
  --shadow: 0 10px 32px rgba(27, 30, 34, 0.14);
  --radius: 14px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    --bg: #121416; --surface: #1c1f22; --ink: #f2f3f4; --sub: #a9afb6; --line: #2c3035; --edge: #6f767e;
    --accent: #e3c477; --accent-text: #e3c477; --accent-ink: #1b1e22; --accent-soft: #2a2416;
    --ok: #4ade80; --soon-bar: #facc15; --due: #f87171;
    --shadow: 0 0 0 1px #2c3035;
    color-scheme: dark;
  }
}
:root[data-theme='dark'] {
  --bg: #121416; --surface: #1c1f22; --ink: #f2f3f4; --sub: #a9afb6; --line: #2c3035; --edge: #6f767e;
  --accent: #e3c477; --accent-text: #e3c477; --accent-ink: #1b1e22; --accent-soft: #2a2416;
  --ok: #4ade80; --soon-bar: #facc15; --due: #f87171;
  --shadow: 0 0 0 1px #2c3035;
  color-scheme: dark;
}
@media (prefers-contrast: more) {
  :root:not(#_) { --sub: var(--ink); --line: var(--edge); }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 16px; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'M PLUS 1 LP', 'Hiragino Sans', 'Hiragino Kaku Gothic ProN', 'Noto Sans JP', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.8;
  word-break: auto-phrase; /* 語の途中で折らない（Chrome）。ほかは下の wbr と keep-all の見出しで補う */
  overflow-wrap: anywhere;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent-text); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--accent-text); outline-offset: 3px; border-radius: 6px; }
.num { font-variant-numeric: tabular-nums; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 760px; }
.sub { color: var(--sub); }
.small { font-size: 14px; }
.nowrap { white-space: nowrap; }

.skip { position: absolute; left: 8px; top: -60px; background: var(--ink); color: var(--bg); padding: 10px 14px; border-radius: 8px; z-index: 10; }
.skip:focus { top: 8px; }

/* 一番上の帯 */
.top { border-bottom: 1px solid var(--line); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 800; font-size: 18px; min-height: 48px; }
.brand img { width: 36px; height: 36px; border-radius: 9px; }
.top nav { display: flex; gap: 4px; }
.top nav a { color: var(--ink); text-decoration: none; font-size: 15px; padding: 12px 10px; min-height: 48px; display: inline-flex; align-items: center; border-radius: 8px; }
.top nav a:hover { background: var(--surface); }
@media (max-width: 420px) { .top nav a.opt { display: none; } }

/* 見出しの土台 */
h1, h2, h3 { line-height: 1.35; word-break: keep-all; overflow-wrap: anywhere; margin: 0; }
h2 { font-size: clamp(24px, 4.6vw, 34px); font-weight: 800; letter-spacing: 0.01em; }
h3 { font-size: 19px; font-weight: 700; }
section { padding: 72px 0; }
section + section { border-top: 1px solid var(--line); }
.lead-h { margin-bottom: 12px; }
.section-lead { color: var(--sub); margin: 0 0 32px; max-width: 40em; }

/* 一番上 */
.hero { padding: 48px 0 64px; }
.hero .wrap { display: grid; gap: 40px; align-items: center; }
@media (min-width: 880px) { .hero .wrap { grid-template-columns: 1.15fr 0.85fr; gap: 56px; } .hero { padding: 72px 0 88px; } }
.promise { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 20px; padding: 0; list-style: none; }
.promise li { font-weight: 700; font-size: 15px; padding: 4px 12px; border-radius: 6px; border: 2px solid var(--accent-text); color: var(--accent-text); background: var(--accent-soft); }
.hero h1 { font-size: clamp(30px, 7.2vw, 52px); font-weight: 800; letter-spacing: 0.01em; }
.hero h1 .accent { color: var(--accent-text); }
.hero .lead { font-size: 17px; margin: 20px 0 28px; max-width: 34em; }
.cta-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; }
.store-btn {
  display: inline-flex; align-items: center; gap: 10px; min-height: 56px; padding: 8px 22px 8px 18px;
  background: var(--accent); color: var(--accent-ink); border-radius: 12px; text-decoration: none; font-weight: 700; line-height: 1.25;
}
.store-btn:hover { opacity: 0.88; }
.store-btn svg { width: 24px; height: 24px; flex: none; }
.store-btn small { display: block; font-weight: 400; font-size: 12px; opacity: 0.85; }
.cta-note { margin: 0; font-size: 14px; color: var(--sub); }

/* アプリの画面の見本（本物の画面の画像に差し替える。README 参照） */
.phone {
  justify-self: center; width: min(300px, 100%); margin: 0; border-radius: 40px; padding: 12px;
  background: #1b1e22; box-shadow: var(--shadow); position: relative;
}
.phone .screen {
  min-height: 520px; border-radius: 30px; overflow: hidden; background: var(--bg); color: var(--ink);
  display: flex; flex-direction: column; padding: 34px 18px 16px; gap: 14px; font-size: 14px; line-height: 1.5;
}
.phone .screen > img.shot { width: 100%; height: 100%; object-fit: cover; margin: -34px -18px -16px; max-width: none; width: calc(100% + 36px); height: calc(100% + 50px); }
.mock-bike { display: flex; align-items: center; justify-content: space-between; font-weight: 700; }
.mock-bike span:last-child { font-size: 12px; color: var(--sub); font-weight: 400; }
.mock-odo { text-align: center; padding: 10px 0 4px; }
.mock-odo b { display: block; font-size: 44px; font-weight: 800; letter-spacing: 0.01em; line-height: 1.1; }
.mock-odo span { font-size: 12px; color: var(--sub); }
.mock-h { font-size: 12px; color: var(--sub); font-weight: 700; margin-top: 4px; }
.mock-row { display: grid; grid-template-columns: 1fr auto; gap: 2px 8px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.mock-row b { font-weight: 700; }
.mock-row .left { font-size: 13px; }
.mock-row .bar { grid-column: 1 / -1; height: 6px; border-radius: 3px; background: var(--surface); overflow: hidden; }
.mock-row .bar i { display: block; height: 100%; border-radius: 3px; }
.tag { font-size: 11px; font-weight: 800; padding: 1px 6px; border-radius: 4px; }
.tag.due { background: var(--due); color: #fff; }
.tag.soon { background: var(--soon-fill); color: var(--on-bright); }
.mock-medal { display: flex; align-items: center; gap: 10px; margin-top: 6px; padding: 10px; border-radius: 12px; background: var(--surface); }
.mock-medal .medal { width: 52px; flex: none; }
.mock-medal .medal b { font-size: 10px; }
.mock-medal p { margin: 0; font-size: 12px; }
.mock-medal p b { display: block; font-size: 14px; }
.shot-note { text-align: center; font-size: 12px; color: var(--sub); margin: 12px 0 0; }

/* メダル（アプリの絵に数字を重ねる） */
.medal { position: relative; display: block; aspect-ratio: 1; }
.medal img { width: 100%; height: 100%; }
.medal b {
  position: absolute; inset: 0; display: grid; place-items: center; font-weight: 800; color: #3d2a07;
  font-size: clamp(13px, 3.6vw, 20px); font-variant-numeric: tabular-nums; text-shadow: 0 1px 0 rgba(255, 255, 255, 0.45);
}
.medal.silver b { color: #2a2e35; }

/* 困りごと */
.pains { display: grid; gap: 16px; margin: 0; padding: 0; list-style: none; }
@media (min-width: 900px) { .shots { grid-auto-columns: 1fr; overflow: visible; } }
@media (min-width: 760px) { .pains { grid-template-columns: repeat(3, 1fr); gap: 24px; } }
.pains li { border-top: 3px solid var(--ink); padding-top: 16px; }
.pains q { display: block; font-weight: 700; font-size: 17px; quotes: '「' '」'; }
.pains p { margin: 8px 0 0; color: var(--sub); font-size: 15px; }

/* できること */
.features { display: grid; gap: 40px; }
.feature { display: grid; gap: 16px 32px; align-items: center; }
@media (min-width: 760px) { .feature { grid-template-columns: 200px 1fr; } }
.feature .art { display: flex; gap: 8px; max-width: 280px; }
.feature .art .medal { width: 96px; }
.feature .art .medal.big { width: 140px; }
.feature .art.text { flex-direction: column; gap: 2px; font-size: 40px; font-weight: 800; color: var(--accent-text); line-height: 1.1; }
.feature .art.text small { display: block; font-size: 14px; color: var(--sub); font-weight: 700; }
.feature h3 { margin-bottom: 6px; }
.feature p { margin: 0; }
.feature .eg { margin-top: 8px; font-size: 14px; color: var(--sub); }

/* 画面の画像（8枚。ストアの画像と同じ筋書き） */
.shots { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(150px, 44%); gap: 16px; overflow-x: auto; padding: 4px 4px 16px; margin: 0 -4px; scroll-snap-type: x mandatory; list-style: none; }
.shots li { scroll-snap-align: start; }
.shots figure { margin: 0; }
.shot-ph {
  aspect-ratio: 1320 / 2868; border-radius: 22px; border: 2px dashed var(--edge); background: var(--surface);
  display: grid; place-items: center; text-align: center; padding: 16px; color: var(--sub); font-size: 13px;
}
.shot-ph .medal { width: 88px; margin: 0 auto 8px; }
.shots figcaption { margin-top: 10px; font-weight: 700; font-size: 15px; line-height: 1.5; }
.shots figcaption span { display: block; font-weight: 400; color: var(--sub); font-size: 13px; }

/* 使い方 */
.steps { counter-reset: s; display: grid; gap: 20px; margin: 0; padding: 0; list-style: none; }
@media (min-width: 760px) { .steps { grid-template-columns: repeat(3, 1fr); gap: 24px; } }
.steps li { counter-increment: s; display: grid; grid-template-columns: 44px 1fr; gap: 12px; align-items: start; }
.steps li::before {
  content: counter(s); width: 44px; height: 44px; border-radius: 10px; background: var(--accent); color: var(--accent-ink);
  display: grid; place-items: center; font-weight: 800; font-size: 20px;
}
.steps b { display: block; }
.steps p { margin: 4px 0 0; color: var(--sub); font-size: 15px; }

/* 控えの仕組み */
.backup { display: grid; gap: 12px; margin: 0 0 24px; padding: 0; list-style: none; }
@media (min-width: 760px) { .backup { grid-template-columns: repeat(3, 1fr); } }
.backup li { border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; background: var(--bg); }
.backup .where { font-size: 13px; font-weight: 700; color: var(--accent-text); }
.backup b { display: block; font-size: 18px; margin: 2px 0 6px; }
.backup p { margin: 0; font-size: 15px; color: var(--sub); }
.callout { border-left: 4px solid var(--accent-text); padding: 4px 0 4px 16px; margin: 0; }
.callout p { margin: 0 0 8px; }
.callout p:last-child { margin: 0; }

/* 料金 */
.price-grid { display: grid; gap: 16px; }
@media (min-width: 760px) { .price-grid { grid-template-columns: 1fr 1fr; gap: 24px; } }
.plan { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.plan.pro { border: 2px solid var(--accent-text); }
.plan h3 { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; flex-wrap: wrap; }
.plan .yen { font-size: 28px; font-weight: 800; }
.plan .yen small { font-size: 14px; font-weight: 400; color: var(--sub); margin-left: 4px; }
.plan ul { margin: 14px 0 0; padding-left: 1.2em; }
.plan li { margin: 4px 0; }
.plan .after { margin: 14px 0 0; font-size: 14px; color: var(--sub); }
.pr-tag { display: inline-block; font-size: 11px; font-weight: 800; line-height: 1.3; padding: 0 5px; border: 1.5px solid currentColor; border-radius: 4px; vertical-align: 2px; color: var(--sub); }
.affiliate { margin-top: 24px; font-size: 14px; color: var(--sub); }

/* よくある質問 */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none; font-weight: 700; padding: 16px 40px 16px 0; min-height: 56px; position: relative; display: flex; align-items: center;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ''; position: absolute; right: 8px; top: 50%; width: 10px; height: 10px; margin-top: -7px;
  border-right: 2px solid var(--ink); border-bottom: 2px solid var(--ink); transform: rotate(45deg); transition: transform 0.2s;
}
.faq details[open] summary::after { transform: rotate(-135deg); margin-top: -2px; }
.faq .ans { padding: 0 0 18px; }
.faq .ans p { margin: 0 0 8px; }

/* 最後の呼びかけ */
.final { text-align: center; }
.final img { width: 88px; height: 88px; border-radius: 20px; margin: 0 auto 16px; }
.final h2 { margin-bottom: 12px; }
.final .cta-row { justify-content: center; margin-top: 24px; }

/* 一番下 */
.foot { border-top: 1px solid var(--line); padding: 32px 0 48px; font-size: 14px; color: var(--sub); }
.foot nav ul { display: flex; flex-wrap: wrap; gap: 4px 4px; margin: 0 0 12px; padding: 0; list-style: none; }
.foot nav a { color: var(--ink); display: inline-flex; min-height: 44px; align-items: center; padding: 0 8px; margin-left: -8px; margin-right: 8px; }
.foot p { margin: 4px 0; }

/* 規約などの文書 */
.doc { padding: 40px 0 64px; }
.doc h1 { font-size: clamp(26px, 5.6vw, 34px); font-weight: 800; margin-bottom: 8px; }
.doc .meta { color: var(--sub); font-size: 14px; margin: 0 0 28px; }
.doc h2 { font-size: 20px; margin: 40px 0 12px; padding-top: 20px; border-top: 1px solid var(--line); }
.doc h3 { font-size: 17px; margin: 20px 0 8px; }
.doc p, .doc li { max-width: 44em; }
.doc ol, .doc ul { padding-left: 1.4em; }
.doc li { margin: 6px 0; }
.summary-box { background: var(--surface); border-radius: var(--radius); padding: 18px 20px; margin: 0 0 8px; }
.summary-box ul { margin: 0; }
.tbl { overflow-x: auto; margin: 12px 0; -webkit-overflow-scrolling: touch; }
.tbl:focus-visible { outline-offset: 0; }
table { border-collapse: collapse; width: 100%; min-width: 520px; font-size: 15px; }
table.kv { min-width: 0; }
th, td { border-bottom: 1px solid var(--line); padding: 12px 10px; text-align: left; vertical-align: top; }
thead th { color: var(--sub); font-weight: 700; font-size: 14px; white-space: nowrap; }
table.kv th { width: 30%; min-width: 7.5em; color: var(--ink); font-weight: 700; }
@media (max-width: 540px) {
  table.kv, table.kv tbody, table.kv tr, table.kv th, table.kv td { display: block; width: 100%; }
  table.kv th { border-bottom: 0; padding: 14px 0 0; }
  table.kv td { padding: 4px 0 14px; }
}
.todo { background: #fde68a; color: #1b1e22; padding: 0 4px; border-radius: 3px; font-weight: 700; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
.promise-line { color: var(--ink); font-size: 16px; }
/* 小さい画面では、表を1行ずつの札にする（横にスクロールさせない） */
@media (max-width: 540px) {
  table.stack { min-width: 0; }
  table.stack thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  table.stack, table.stack tbody, table.stack tr, table.stack td { display: block; width: 100%; }
  table.stack tr { border-bottom: 1px solid var(--line); padding: 10px 0; }
  table.stack td { border: 0; padding: 4px 0; }
  table.stack td::before { content: attr(data-label); display: block; font-size: 13px; font-weight: 700; color: var(--sub); }
}
.mock-row .bar i.b-due { width: 100%; background: var(--due); }
.mock-row .bar i.b-soon { width: 92%; background: var(--soon-bar); }
.mock-row .bar i.b-ok { width: 60%; background: var(--ok); }
.doc .meta.end { margin-top: 32px; }
