/*
 * N&N アプリ LP 共通テンプレート（app-ops#47 案 B）。
 * アプリごとに変えるのは :root の色だけにする（index.html の <style> で上書き）。
 * 構成: ファーストビュー（見出し・ストアバッジ・QR・端末の画面）→ 3 つのポイント → 画面 → 遊び方 → 中間 CTA → よくある質問 → ほかのアプリ → フッター。
 * スマホでは画面下に CTA を固定する。
 */
:root {
  --accent: #2563eb;
  --accent-ink: #ffffff;
  --hero-a: #1d4ed8;
  --hero-b: #38bdf8;
  --ink: #111827;
  --muted: #4b5563;
  --line: #e5e7eb;
  --soft: #f4f7fc;
  --radius: 18px;
  --wrap: 1040px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Segoe UI", sans-serif;
  color: var(--ink);
  background: #fff;
  line-height: 1.75;
  font-feature-settings: "palt";
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
section { padding: 64px 0; }
.soft { background: var(--soft); }
h2 { font-size: clamp(1.5rem, 4vw, 2rem); line-height: 1.35; margin: 0 0 8px; text-align: center; }
.lead { text-align: center; color: var(--muted); margin: 0 auto 32px; max-width: 40em; }
:focus-visible { outline: 3px solid #facc15; outline-offset: 3px; }

/* ファーストビュー */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background: radial-gradient(circle at 85% 15%, rgba(255, 255, 255, .25) 0 90px, transparent 91px),
              radial-gradient(circle at 10% 85%, rgba(255, 255, 255, .18) 0 60px, transparent 61px),
              linear-gradient(150deg, var(--hero-a) 0%, var(--hero-b) 100%);
  padding: 40px 0 0;
}
.hero .wrap { display: grid; gap: 28px; align-items: center; }
.hero-copy { text-align: center; }
.app-id { display: inline-flex; align-items: center; gap: 12px; margin-bottom: 14px; }
.app-id img { width: 56px; height: 56px; border-radius: 13px; box-shadow: 0 4px 14px rgba(0, 0, 0, .25); }
.app-id span { font-weight: 700; font-size: 1rem; text-align: left; line-height: 1.4; }
.hero h1 { font-size: clamp(2rem, 7vw, 3.4rem); line-height: 1.2; margin: 0 0 14px; letter-spacing: .01em; text-shadow: 0 2px 12px rgba(0, 0, 0, .18); }
.hero .sub { font-size: clamp(1rem, 2.6vw, 1.2rem); margin: 0 auto 18px; max-width: 30em; opacity: .96; }
.chips { list-style: none; padding: 0; margin: 0 0 22px; display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.chips li { background: rgba(255, 255, 255, .2); border: 1px solid rgba(255, 255, 255, .45); border-radius: 999px; padding: 4px 14px; font-size: .9rem; font-weight: 700; }
.chips li::before { content: "✓ "; }
.cta-row { display: flex; align-items: center; justify-content: center; gap: 20px; flex-wrap: wrap; }
.badge img { height: 56px; width: auto; }
.qr { display: none; align-items: center; gap: 10px; background: #fff; color: var(--ink); border-radius: 12px; padding: 8px 12px 8px 8px; font-size: .8rem; line-height: 1.4; }
.qr img { width: 76px; height: 76px; }
.note { font-size: .85rem; opacity: .9; margin: 14px 0 0; }
.hero-visual { position: relative; display: flex; justify-content: center; }
.phone {
  width: min(260px, 70vw); border: 10px solid #0b0f19; border-radius: 42px; overflow: hidden;
  background: #0b0f19; box-shadow: 0 24px 48px rgba(0, 0, 0, .35); transform: translateY(24px);
}
.phone img { width: 100%; aspect-ratio: 540 / 1170; object-fit: cover; }

/* 3 つのポイント */
.points { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.points li { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: 0 6px 20px rgba(17, 24, 39, .05); }
.points .num { display: inline-flex; width: 40px; height: 40px; border-radius: 12px; align-items: center; justify-content: center; background: var(--accent); color: var(--accent-ink); font-weight: 800; margin-bottom: 12px; }
.points h3 { margin: 0 0 6px; font-size: 1.2rem; }
.points p { margin: 0; color: var(--muted); }

/* 画面 */
.shots { display: flex; gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 4px 18px; -webkit-overflow-scrolling: touch; }
.shots figure { flex: 0 0 auto; width: 200px; margin: 0; scroll-snap-align: center; }
.shots img { width: 200px; aspect-ratio: 540 / 1170; border-radius: 20px; box-shadow: 0 8px 22px rgba(0, 0, 0, .14); }
.shots figcaption { font-size: .88rem; color: var(--muted); margin-top: 10px; text-align: center; font-weight: 700; }

/* 遊び方 */
.steps { list-style: none; margin: 0 auto; padding: 0; max-width: 640px; display: grid; gap: 14px; counter-reset: step; }
.steps li { counter-increment: step; position: relative; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px 16px 70px; }
.steps li::before {
  content: counter(step); position: absolute; left: 18px; top: 50%; transform: translateY(-50%);
  width: 36px; height: 36px; border-radius: 50%; background: var(--accent); color: var(--accent-ink);
  display: flex; align-items: center; justify-content: center; font-weight: 800;
}

/* 中間・最後の CTA */
.band { text-align: center; color: #fff; background: linear-gradient(150deg, var(--hero-a) 0%, var(--hero-b) 100%); }
.band h2 { color: #fff; }
.band p { margin: 0 0 22px; opacity: .95; }
.band .cta-row { justify-content: center; }

/* よくある質問 */
.faq { max-width: 760px; margin: 0 auto; }
details { background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 14px 18px; margin-bottom: 10px; }
summary { cursor: pointer; font-weight: 700; }
details p { margin: 10px 0 0; color: var(--muted); }

/* ほかのアプリ */
.apps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; }
.apps a { display: block; height: 100%; padding: 14px 16px; border-radius: 14px; background: #fff; border: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.apps a strong { display: block; color: var(--accent); }
.apps a span { font-size: .88rem; color: var(--muted); }

/* フッター */
footer { background: #0b0f19; color: #cbd5e1; padding: 32px 0 40px; font-size: .9rem; }
footer nav { display: flex; flex-wrap: wrap; gap: 8px 20px; margin-bottom: 12px; }
footer a { color: #e2e8f0; }
footer .en { margin-top: 12px; opacity: .85; }
footer .tm { margin-top: 8px; font-size: .78rem; opacity: .7; }

/* スマホの固定 CTA */
.sticky-cta { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 10; display: flex; gap: 8px; }
.sticky-cta a {
  flex: 1; text-align: center; text-decoration: none; font-weight: 800; font-size: 1.05rem;
  background: var(--accent); color: var(--accent-ink); border-radius: 999px; padding: 14px 8px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, .25);
}
footer { padding-bottom: 116px; }

@media (min-width: 860px) {
  .hero { padding: 72px 0 0; }
  .hero .wrap { grid-template-columns: 1.15fr .85fr; }
  .hero-copy { text-align: left; }
  .hero .sub { margin-left: 0; }
  .chips, .cta-row { justify-content: flex-start; }
  .shots { justify-content: center; overflow-x: visible; }
}
/* マウスで操作する PC だけ QR を出し、固定 CTA を消す（iPad やスマホの横向きでは固定 CTA を残す） */
@media (min-width: 860px) and (hover: hover) and (pointer: fine) {
  .qr { display: inline-flex; }
  .sticky-cta { display: none; }
  footer { padding-bottom: 40px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
