/* すまい帖 — 不動産業向けアプリデモ（タキコーポレーション 制作）
   色は :root のトークンのみで定義し、ダークは下でまとめて上書きする */

:root {
  --bg: #e6e5df;
  --bg-2: #dcdbd3;
  --app-bg: #f5f4f0;
  --surface: #fcfbf8;
  --surface-2: #efeee8;
  --ink: #1c201e;
  --ink-2: #474c48;
  --muted: #80857f;
  --line: #d9d7cf;
  --line-strong: #bdbbb2;
  --accent: #2e4a40;
  --accent-2: #3f6356;
  --accent-ink: #f3f1ea;
  --accent-soft: #dfe7e1;
  --brass: #8f7340;
  --brass-soft: #efe7d6;
  --warn: #a8700f;
  --warn-soft: #f6ead0;
  --danger: #962f2f;
  --danger-soft: #f3dddb;
  --plan-wall: #1c201e;
  --plan-room: #fbfaf6;
  --plan-wet: #eef1f0;
  --plan-hi: #d6e3db;
  --shadow: 0 1px 2px rgba(28, 32, 30, .06), 0 8px 24px rgba(28, 32, 30, .07);
  --device: #1a1c1b;
  --font-min: "Shippori Mincho", "Zen Old Mincho", "Hiragino Mincho ProN", serif;
  --font-sans: "Zen Kaku Gothic New", "Hiragino Sans", "Noto Sans JP", sans-serif;
  --font-num: "Inter", "Zen Kaku Gothic New", "Hiragino Sans", sans-serif;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0d0f0e;
    --bg-2: #141715;
    --app-bg: #121513;
    --surface: #1a1e1c;
    --surface-2: #222724;
    --ink: #ebe9e2;
    --ink-2: #bebdb5;
    --muted: #8a8f89;
    --line: #2b302d;
    --line-strong: #3c423e;
    --accent: #a4c7b6;
    --accent-2: #86ad9b;
    --accent-ink: #0f1513;
    --accent-soft: #223029;
    --brass: #cdb07a;
    --brass-soft: #2c271d;
    --warn: #e0ad4f;
    --warn-soft: #2f2617;
    --danger: #e08a82;
    --danger-soft: #34201e;
    --plan-wall: #d9d7cf;
    --plan-room: #1a1e1c;
    --plan-wet: #1f2523;
    --plan-hi: #2a3c33;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 10px 30px rgba(0, 0, 0, .35);
    --device: #050606;
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #0d0f0e;
  --bg-2: #141715;
  --app-bg: #121513;
  --surface: #1a1e1c;
  --surface-2: #222724;
  --ink: #ebe9e2;
  --ink-2: #bebdb5;
  --muted: #8a8f89;
  --line: #2b302d;
  --line-strong: #3c423e;
  --accent: #a4c7b6;
  --accent-2: #86ad9b;
  --accent-ink: #0f1513;
  --accent-soft: #223029;
  --brass: #cdb07a;
  --brass-soft: #2c271d;
  --warn: #e0ad4f;
  --warn-soft: #2f2617;
  --danger: #e08a82;
  --danger-soft: #34201e;
  --plan-wall: #d9d7cf;
  --plan-room: #1a1e1c;
  --plan-wet: #1f2523;
  --plan-hi: #2a3c33;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 10px 30px rgba(0, 0, 0, .35);
  --device: #050606;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; padding: 0; -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
svg { display: block; }
.num { font-family: var(--font-num); font-feature-settings: "tnum" 1, "lnum" 1; font-variant-numeric: tabular-nums lining-nums; letter-spacing: -.01em; }
.min { font-family: var(--font-min); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- ステージ（PC: 端末＋解説） ---------- */
.stage {
  position: relative;
  display: grid;
  grid-template-columns: minmax(440px, 1fr) minmax(400px, 560px);
  gap: clamp(32px, 5vw, 88px);
  max-width: 1320px;
  margin: 0 auto;
  padding: 0 clamp(24px, 4vw, 64px);
}
.stage::before {
  /* 窓から差し込む光 */
  content: "";
  position: fixed;
  inset: -20% auto auto -10%;
  width: 70vw;
  height: 140vh;
  background: linear-gradient(115deg, transparent 30%, rgba(255, 255, 255, .45) 45%, transparent 62%);
  pointer-events: none;
  transform: rotate(-8deg);
}
:root[data-theme="dark"] .stage::before { background: linear-gradient(115deg, transparent 30%, rgba(164, 199, 182, .05) 45%, transparent 62%); }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .stage::before { background: linear-gradient(115deg, transparent 30%, rgba(164, 199, 182, .05) 45%, transparent 62%); }
}

.device-col {
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
}
.device {
  --s: 1;
  position: relative;
  width: calc(414px * var(--s));
  height: calc(868px * var(--s));
  flex: none;
}
.device-inner {
  position: absolute;
  top: 0; left: 0;
  width: 414px;
  height: 868px;
  transform: scale(var(--s));
  transform-origin: top left;
  border-radius: 62px;
  background: var(--device);
  padding: 12px;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, .06) inset,
    0 0 0 2px #2c2f2d,
    0 40px 80px -20px rgba(20, 24, 22, .45),
    0 12px 24px -8px rgba(20, 24, 22, .3);
}
.device-inner::after {
  /* ダイナミックアイランド */
  content: "";
  position: absolute;
  top: 23px; left: 50%;
  width: 118px; height: 34px;
  transform: translateX(-50%);
  background: #000;
  border-radius: 20px;
  z-index: 50;
}
.device-caption {
  margin: 0;
  font-size: 12px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
  letter-spacing: .04em;
}
.device-caption .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); animation: pulse 2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .3; } }

/* ---------- アプリ本体 ---------- */
.app {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
  border-radius: 50px;
  background: var(--app-bg);
  display: grid;
  grid-template-rows: 50px 1fr auto;
  isolation: isolate;
  container-type: inline-size;
}
.statusbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 30px 0 40px;
  font-family: var(--font-num);
  font-weight: 600;
  font-size: 15px;
  z-index: 40;
}
.statusbar .sb-icons { display: flex; gap: 6px; align-items: center; }
.views { position: relative; overflow: hidden; }
.tab-view {
  position: absolute;
  inset: 0;
  display: none;
  transition: transform .42s cubic-bezier(.2, .8, .2, 1), filter .42s;
}
.tab-view.active { display: block; }
.tab-view.pushed { transform: translateX(-28%); filter: brightness(.92); }
.scroller {
  position: absolute;
  inset: 0;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  scrollbar-width: none;
}
.scroller::-webkit-scrollbar { display: none; }

/* ヘッダー */
.app-head {
  padding: 10px 20px 4px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}
.brand { display: flex; flex-direction: column; line-height: 1.2; }
.brand-mark { display: flex; align-items: center; gap: 8px; font-family: var(--font-min); font-weight: 700; font-size: 22px; letter-spacing: .08em; }
.brand-mark svg { color: var(--accent); }
.brand-sub { font-size: 10.5px; color: var(--muted); letter-spacing: .14em; margin-top: 3px; }
.page-title { font-family: var(--font-min); font-weight: 600; font-size: 26px; letter-spacing: .06em; margin: 0; line-height: 1.3; }
.page-kicker { font-size: 11px; letter-spacing: .2em; color: var(--muted); }
.icon-btn {
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 50%;
  color: var(--ink);
  position: relative;
  transition: background .2s;
}
.icon-btn:hover { background: var(--surface-2); }
.icon-btn .badge-dot { position: absolute; top: 9px; right: 10px; width: 7px; height: 7px; background: var(--brass); border-radius: 50%; border: 1.5px solid var(--app-bg); }

/* AI の希望プロファイル */
.pref-strip {
  margin: 12px 20px 0;
  padding: 12px 14px 12px 16px;
  border-left: 2px solid var(--brass);
  background: linear-gradient(90deg, var(--brass-soft), transparent 85%);
  display: flex;
  align-items: center;
  gap: 12px;
  width: calc(100% - 40px);
  text-align: left;
}
.pref-strip .pref-label { font-size: 10.5px; letter-spacing: .14em; color: var(--brass); display: flex; align-items: center; gap: 5px; font-weight: 500; }
.pref-strip .pref-val { font-size: 13px; color: var(--ink); margin-top: 2px; line-height: 1.5; }
.pref-strip .pref-edit { margin-left: auto; font-size: 12px; color: var(--ink-2); display: flex; align-items: center; gap: 2px; white-space: nowrap; }

/* 条件チップ */
.chips {
  display: flex;
  gap: 8px;
  padding: 14px 20px 4px;
  overflow-x: auto;
  scrollbar-width: none;
}
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none;
  height: 34px;
  padding: 0 12px 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 17px;
  font-size: 13px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--ink-2);
  background: var(--surface);
  transition: background .2s, color .2s, border-color .2s;
  white-space: nowrap;
}
.chip svg { opacity: .6; }
.chip.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.chip.on svg { opacity: .9; }
.chip.ghost { border-style: dashed; background: transparent; }

.list-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px 10px;
}
.count { font-size: 13px; color: var(--ink-2); }
.count b { font-family: var(--font-num); font-size: 20px; font-weight: 600; color: var(--ink); margin-right: 2px; }
.seg {
  display: inline-flex;
  background: var(--surface-2);
  border-radius: 9px;
  padding: 2px;
  gap: 2px;
}
.seg button {
  font-size: 12px;
  padding: 5px 9px;
  border-radius: 7px;
  color: var(--ink-2);
  transition: background .2s, color .2s;
  white-space: nowrap;
}
.seg button.on { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, .08); font-weight: 500; }

/* 物件一覧 */
.listing { padding: 0 20px 28px; }
.prop {
  position: relative;
  display: block;
  width: 100%;
  text-align: left;
  color: inherit;
}
.prop-feature { margin-bottom: 22px; }
.prop-feature .ph { aspect-ratio: 16 / 11; border-radius: 3px; overflow: hidden; position: relative; }
.ph svg { width: 100%; height: 100%; }
.ph .ph-tag {
  position: absolute; left: 10px; top: 10px;
  font-size: 10.5px; letter-spacing: .12em;
  background: rgba(16, 18, 17, .55);
  color: #f2f0ea;
  padding: 3px 8px;
  backdrop-filter: blur(6px);
}
.prop-feature .pf-body { padding-top: 12px; }
.prop-row {
  display: grid;
  grid-template-columns: 112px 1fr;
  gap: 14px;
  padding: 16px 0;
  border-top: 1px solid var(--line);
}
.prop-row .ph { width: 112px; height: 132px; border-radius: 2px; overflow: hidden; position: relative; }
.prop-name { font-family: var(--font-min); font-weight: 600; font-size: 16.5px; letter-spacing: .04em; line-height: 1.35; margin: 0; }
.prop-feature .prop-name { font-size: 20px; }
.prop-loc { font-size: 12px; color: var(--ink-2); display: flex; align-items: center; gap: 4px; margin-top: 3px; }
.prop-loc svg { flex: none; }
.prop-loc .pl-t { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.prop-loc .pl-line { color: var(--muted); }
.prop-row .prop-name { padding-right: 26px; }
.prop-row > div:nth-child(2), .prop-feature .pf-body { min-width: 0; }
.prop-spec { font-size: 12px; color: var(--muted); margin-top: 2px; }
.prop-spec .num { color: var(--ink-2); }
.price { display: flex; align-items: baseline; gap: 2px; margin-top: 6px; }
.price .v { font-family: var(--font-num); font-feature-settings: "tnum" 1; font-weight: 600; font-size: 22px; letter-spacing: -.02em; }
.prop-feature .price .v { font-size: 27px; }
.price .u { font-size: 12px; color: var(--ink-2); }
.price .tag-new { margin-left: 8px; font-size: 10px; letter-spacing: .1em; border: 1px solid var(--brass); color: var(--brass); padding: 0 5px; align-self: center; }

.match {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
}
.ring { position: relative; width: 40px; height: 40px; flex: none; }
.ring svg { width: 40px; height: 40px; transform: rotate(-90deg); }
.ring .ring-bg { stroke: var(--line); }
.ring .ring-fg { stroke: var(--brass); transition: stroke-dashoffset .8s cubic-bezier(.2, .8, .2, 1); }
.ring span { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--font-num); font-weight: 600; font-size: 12px; font-feature-settings: "tnum" 1; }
.match-text { font-size: 11.5px; line-height: 1.5; color: var(--ink-2); }
.match-text b { color: var(--brass); font-weight: 500; display: block; font-size: 11px; letter-spacing: .06em; }
.prop-row .match { margin-top: 8px; gap: 8px; }
.prop-row .ring, .prop-row .ring svg { width: 34px; height: 34px; }
.prop-row .ring span { font-size: 10.5px; }

.heart-btn {
  position: absolute;
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: 50%;
  color: var(--ink-2);
  transition: transform .2s;
}
.heart-btn:active { transform: scale(.88); }
.heart-btn.on { color: #c2413a; }
.heart-btn.on svg { animation: beat .35s ease; }
@keyframes beat { 40% { transform: scale(1.3); } }
.prop-feature .heart-btn { top: 8px; right: 8px; background: rgba(250, 249, 245, .85); backdrop-filter: blur(6px); color: #2a2d2b; }
.prop-feature .heart-btn.on { color: #c2413a; }
.prop-row .heart-btn { top: 10px; right: -8px; }

.empty {
  text-align: center;
  padding: 40px 28px;
  color: var(--ink-2);
}
.empty svg { margin: 0 auto 14px; color: var(--line-strong); }
.empty h3 { font-family: var(--font-min); font-weight: 600; font-size: 17px; margin: 0 0 6px; color: var(--ink); }
.empty p { font-size: 13px; margin: 0 0 16px; }

/* ---------- ボタン ---------- */
.btn {
  height: 48px;
  padding: 0 20px;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 500;
  font-size: 14.5px;
  letter-spacing: .04em;
  transition: background .2s, transform .1s, opacity .2s;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: var(--accent-2); }
.btn-primary:disabled { opacity: .35; cursor: not-allowed; }
.btn-line { border: 1px solid var(--line-strong); background: var(--surface); }
.btn-text { color: var(--accent); font-size: 13px; height: auto; padding: 4px 0; }
.btn-block { width: 100%; }

/* ---------- 詳細（スタック遷移） ---------- */
.detail {
  visibility: hidden;
  position: absolute;
  top: 50px; left: 0; right: 0; bottom: 0;
  background: var(--app-bg);
  z-index: 30;
  transform: translateX(102%);
  transition: transform .42s cubic-bezier(.2, .8, .2, 1), visibility 0s .42s;
  box-shadow: -12px 0 30px rgba(0, 0, 0, .12);
  display: grid;
  grid-template-rows: 1fr auto;
}
.detail.open { transform: translateX(0); visibility: visible; transition: transform .42s cubic-bezier(.2, .8, .2, 1), visibility 0s; }
.detail.dragging { transition: none; }
.detail .scroller { position: relative; inset: auto; height: 100%; }
.detail-top { position: absolute; top: 10px; left: 12px; right: 12px; display: flex; justify-content: space-between; z-index: 5; pointer-events: none; }
.detail-top > * { pointer-events: auto; }
.float-btn {
  width: 40px; height: 40px; border-radius: 50%;
  background: rgba(250, 249, 245, .82);
  backdrop-filter: blur(8px);
  color: #1c201e;
  display: grid; place-items: center;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .12);
}
.float-btn.on { color: #c2413a; }
.float-group { display: flex; gap: 8px; }

.gallery { position: relative; }
.g-track {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  aspect-ratio: 4 / 3.3;
}
.g-track::-webkit-scrollbar { display: none; }
.g-slide { flex: 0 0 100%; scroll-snap-align: start; position: relative; }
.g-slide svg { width: 100%; height: 100%; }
.g-cap {
  position: absolute; left: 14px; bottom: 12px;
  color: #f2f0ea;
  font-size: 11px; letter-spacing: .14em;
  display: flex; align-items: center; gap: 10px;
  text-shadow: 0 1px 6px rgba(0, 0, 0, .4);
}
.g-cap .num { font-size: 12px; }
.g-nav {
  position: absolute; bottom: 8px; right: 10px;
  display: flex; gap: 6px;
}
.g-nav button {
  width: 32px; height: 32px; border-radius: 50%;
  background: rgba(16, 18, 17, .45);
  color: #f2f0ea;
  display: grid; place-items: center;
  backdrop-filter: blur(6px);
}
.g-thumbs { display: flex; gap: 6px; padding: 8px 20px 0; }
.g-thumbs button { flex: 1; height: 40px; overflow: hidden; border-radius: 2px; opacity: .45; transition: opacity .2s; outline-offset: 1px; }
.g-thumbs button.on { opacity: 1; outline: 1.5px solid var(--ink); }
.g-thumbs svg { width: 100%; height: 100%; }

.d-sec { padding: 22px 20px; border-top: 1px solid var(--line); }
.d-sec:first-of-type { border-top: 0; }
.d-head { padding: 18px 20px 20px; }
.tags { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.tag { font-size: 10.5px; letter-spacing: .08em; padding: 2px 8px; border: 1px solid var(--line-strong); color: var(--ink-2); }
.tag.solid { background: var(--ink); color: var(--app-bg); border-color: var(--ink); }
.d-name { font-family: var(--font-min); font-weight: 600; font-size: 25px; letter-spacing: .05em; margin: 0; line-height: 1.35; }
.d-sub { font-size: 12.5px; color: var(--ink-2); margin-top: 4px; }
.d-price-row { display: flex; align-items: flex-end; justify-content: space-between; margin-top: 14px; gap: 10px; }
.d-price-row .price { margin-top: 0; }
.d-price-row .price .v { font-size: 32px; }
.monthly-pill {
  text-align: right;
  font-size: 11px;
  color: var(--ink-2);
  line-height: 1.35;
  border-bottom: 1px solid var(--line-strong);
  padding-bottom: 2px;
}
.monthly-pill b { font-family: var(--font-num); font-size: 16px; font-weight: 600; color: var(--ink); font-feature-settings: "tnum" 1; }
.keyfacts { display: grid; grid-template-columns: repeat(4, 1fr); margin-top: 18px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.keyfacts div { padding: 10px 0; text-align: center; border-left: 1px solid var(--line); }
.keyfacts div:first-child { border-left: 0; }
.keyfacts .k { font-size: 10px; color: var(--muted); letter-spacing: .1em; display: block; }
.keyfacts .v { font-family: var(--font-num); font-weight: 600; font-size: 15px; font-feature-settings: "tnum" 1; }
.keyfacts .v small { font-family: var(--font-sans); font-weight: 400; font-size: 10.5px; color: var(--ink-2); margin-left: 1px; }

.sec-title { font-family: var(--font-min); font-weight: 600; font-size: 17px; letter-spacing: .06em; margin: 0 0 14px; display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.sec-title small { font-family: var(--font-sans); font-weight: 400; font-size: 11px; color: var(--muted); letter-spacing: .04em; }

.ai-box { background: var(--brass-soft); padding: 16px; position: relative; }
.ai-box .ai-top { display: flex; align-items: center; gap: 14px; }
.ai-box .ring, .ai-box .ring svg { width: 56px; height: 56px; }
.ai-box .ring span { font-size: 15px; }
.ai-box h4 { margin: 0; font-size: 14px; font-weight: 500; line-height: 1.5; }
.ai-box h4 .num { font-size: 18px; color: var(--brass); font-weight: 700; }
.ai-box .ai-note { font-size: 10.5px; color: var(--muted); letter-spacing: .06em; }
.reasons { list-style: none; margin: 12px 0 0; padding: 0; display: grid; gap: 6px; }
.reasons li { display: grid; grid-template-columns: 18px 1fr; gap: 6px; font-size: 12.5px; line-height: 1.5; color: var(--ink-2); }
.reasons li svg { margin-top: 2px; }
.reasons li.ok svg { color: var(--accent); }
.reasons li.ng svg { color: var(--warn); }

.plan-wrap { background: var(--surface); border: 1px solid var(--line); padding: 10px 8px 6px; }
.plan-wrap svg { width: 100%; height: auto; }
.plan-svg .room rect.fill { fill: var(--plan-room); transition: fill .2s; }
.plan-svg .room.wet rect.fill { fill: var(--plan-wet); }
.plan-svg .room { cursor: pointer; }
.plan-svg .room:hover rect.fill, .plan-svg .room.on rect.fill { fill: var(--plan-hi); }
.plan-svg .wall { fill: none; stroke: var(--plan-wall); }
.plan-svg .fx { fill: none; stroke: var(--plan-wall); stroke-width: .8; opacity: .55; }
.plan-svg .door { fill: none; stroke: var(--plan-wall); stroke-width: .7; opacity: .7; }
.plan-svg .lbl { fill: var(--ink); font-family: var(--font-sans); font-size: 10px; font-weight: 500; }
.plan-svg .jo { fill: var(--ink-2); font-family: var(--font-num); font-size: 9px; }
.plan-svg .balc { fill: none; stroke: var(--plan-wall); stroke-dasharray: 3 3; stroke-width: .8; }
.plan-svg .balc-l { fill: var(--muted); font-size: 8.5px; font-family: var(--font-sans); letter-spacing: .1em; }
.plan-svg .win { stroke: var(--app-bg); stroke-width: 2; }
.plan-svg .win2 { stroke: var(--plan-wall); stroke-width: .7; }
.plan-svg .compass { fill: var(--muted); font-family: var(--font-num); font-size: 9px; }
.plan-read { display: flex; justify-content: space-between; align-items: center; font-size: 12px; color: var(--ink-2); padding: 8px 4px 2px; }
.plan-read b { color: var(--ink); font-weight: 500; }

.spec-table { width: 100%; border-collapse: collapse; font-size: 12.5px; }
.spec-table th, .spec-table td { text-align: left; padding: 9px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.spec-table th { width: 32%; font-weight: 400; color: var(--muted); font-size: 11.5px; letter-spacing: .04em; padding-right: 10px; }
.spec-table td .num { font-weight: 500; }

.mini-map { background: var(--surface-2); height: 172px; position: relative; overflow: hidden; margin-bottom: 12px; }
.mini-map svg { width: 100%; height: 100%; }
.env-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.env-list li { display: flex; align-items: center; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 12.5px; }
.env-list li svg { color: var(--accent); flex: none; }
.env-list .walk { margin-left: auto; font-size: 11.5px; color: var(--ink-2); white-space: nowrap; }

.loan-card { border: 1px solid var(--line-strong); padding: 16px; background: var(--surface); }
.loan-card .lc-top { display: flex; align-items: baseline; justify-content: space-between; }
.loan-card .lc-label { font-size: 12px; color: var(--ink-2); }
.loan-card .lc-val { font-family: var(--font-num); font-weight: 600; font-size: 28px; font-feature-settings: "tnum" 1; letter-spacing: -.02em; }
.loan-card .lc-val small { font-size: 13px; font-family: var(--font-sans); font-weight: 400; margin-left: 2px; color: var(--ink-2); }
.loan-card .lc-cond { font-size: 11px; color: var(--muted); margin: 4px 0 12px; }

.action-bar {
  display: grid;
  grid-template-columns: 48px 1fr 1.4fr;
  gap: 8px;
  padding: 10px 14px 26px;
  background: color-mix(in srgb, var(--app-bg) 88%, transparent);
  backdrop-filter: blur(14px);
  border-top: 1px solid var(--line);
}
.action-bar .btn { padding: 0 10px; font-size: 14px; }
.action-bar .heart-square { position: static; width: 48px; height: 48px; border: 1px solid var(--line-strong); border-radius: 4px; background: var(--surface); display: grid; place-items: center; }
.action-bar .heart-square.on { color: #c2413a; }

/* ---------- タブバー ---------- */
.tabbar {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  padding: 6px 8px 26px;
  border-top: 1px solid var(--line);
  background: color-mix(in srgb, var(--app-bg) 90%, transparent);
  backdrop-filter: blur(14px);
  z-index: 20;
  transition: transform .42s cubic-bezier(.2, .8, .2, 1);
}
.tabbar.hide { transform: translateY(110%); }
.tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 6px 0 2px;
  font-size: 10.5px;
  letter-spacing: .06em;
  color: var(--muted);
  position: relative;
  transition: color .2s;
}
.tab.on { color: var(--accent); font-weight: 500; }
.tab.on::before { content: ""; position: absolute; top: -7px; width: 22px; height: 2px; background: var(--accent); }
.tab .tab-count {
  position: absolute; top: 2px; left: calc(50% + 6px);
  min-width: 16px; height: 16px; padding: 0 4px;
  border-radius: 8px; background: var(--brass); color: #fff;
  font-family: var(--font-num); font-size: 9.5px; font-weight: 600;
  display: grid; place-items: center;
}

/* ---------- シート ---------- */
.backdrop {
  position: absolute; inset: 0;
  background: rgba(10, 12, 11, .38);
  opacity: 0; pointer-events: none;
  transition: opacity .3s;
  z-index: 60;
}
.backdrop.show { opacity: 1; pointer-events: auto; }
.sheet {
  position: absolute; left: 0; right: 0; bottom: 0;
  background: var(--app-bg);
  border-radius: 18px 18px 0 0;
  padding: 8px 20px 30px;
  z-index: 61;
  transform: translateY(105%);
  transition: transform .38s cubic-bezier(.2, .8, .2, 1);
  max-height: 80%;
  overflow-y: auto;
}
.sheet.show { transform: translateY(0); }
.sheet .grab { width: 36px; height: 4px; border-radius: 2px; background: var(--line-strong); margin: 0 auto 14px; }
.sheet h3 { font-family: var(--font-min); font-weight: 600; font-size: 19px; margin: 0 0 4px; letter-spacing: .05em; }
.sheet .sheet-sub { font-size: 12px; color: var(--muted); margin: 0 0 16px; }
.opt-list { display: grid; gap: 8px; margin-bottom: 18px; }
.opt {
  display: flex; align-items: center; justify-content: space-between;
  padding: 13px 14px;
  border: 1px solid var(--line);
  background: var(--surface);
  font-size: 14px;
  text-align: left;
  width: 100%;
}
.opt .sub { font-size: 11.5px; color: var(--muted); margin-left: 8px; }
.opt .check { width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid var(--line-strong); display: grid; place-items: center; flex: none; }
.opt.on { border-color: var(--accent); }
.opt.on .check { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.opt-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 18px; }
.opt-grid .opt { justify-content: center; }
.field-label { font-size: 12px; color: var(--ink-2); margin: 0 0 8px; display: flex; justify-content: space-between; }
.field-label .num { color: var(--ink); font-weight: 600; font-size: 14px; }

/* ---------- 資金計画 ---------- */
.plan-target {
  margin: 10px 20px 0;
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  background: var(--surface);
  width: calc(100% - 40px);
  text-align: left;
}
.plan-target .thumb { width: 44px; height: 44px; overflow: hidden; flex: none; border-radius: 2px; }
.plan-target .thumb svg { width: 100%; height: 100%; }
.plan-target .pt-k { font-size: 10.5px; color: var(--muted); letter-spacing: .08em; }
.plan-target .pt-v { font-size: 13.5px; font-family: var(--font-min); font-weight: 600; }
.plan-target .pt-chg { margin-left: auto; font-size: 12px; color: var(--accent); white-space: nowrap; }

.result {
  margin: 14px 20px 0;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 18px 18px 16px;
  position: relative;
  overflow: hidden;
}
.result::after {
  /* 格子の陰影 */
  content: "";
  position: absolute; inset: 0;
  background-image: linear-gradient(90deg, rgba(255, 255, 255, .06) 1px, transparent 1px);
  background-size: 22px 100%;
  mask-image: linear-gradient(90deg, transparent 40%, #000);
  pointer-events: none;
}
.result .r-label { font-size: 11.5px; letter-spacing: .14em; opacity: .8; }
.result .r-main { font-family: var(--font-num); font-feature-settings: "tnum" 1; font-weight: 600; font-size: 44px; letter-spacing: -.03em; line-height: 1.15; }
.result .r-main small { font-family: var(--font-sans); font-size: 15px; font-weight: 400; margin-left: 4px; letter-spacing: 0; }
.result .r-grid { display: grid; grid-template-columns: repeat(3, 1fr); margin-top: 12px; border-top: 1px solid rgba(255, 255, 255, .18); padding-top: 10px; }
:root[data-theme="dark"] .result .r-grid { border-top-color: rgba(0, 0, 0, .2); }
.result .r-grid .k { font-size: 10.5px; opacity: .75; display: block; letter-spacing: .06em; }
.result .r-grid .v { font-family: var(--font-num); font-weight: 600; font-size: 14.5px; font-feature-settings: "tnum" 1; }
.result .r-grid .v small { font-family: var(--font-sans); font-weight: 400; font-size: 10.5px; margin-left: 1px; }

.burden { margin: 14px 20px 0; padding: 14px 16px; border: 1px solid var(--line); background: var(--surface); }
.burden-top { display: flex; justify-content: space-between; align-items: baseline; }
.burden-top .k { font-size: 12px; color: var(--ink-2); }
.burden-top .v { font-family: var(--font-num); font-weight: 600; font-size: 22px; font-feature-settings: "tnum" 1; }
.bar { position: relative; height: 8px; background: var(--surface-2); margin: 10px 0 6px; overflow: visible; }
.bar .fill { position: absolute; left: 0; top: 0; bottom: 0; background: var(--accent); transition: width .35s, background .35s; }
.bar .mark { position: absolute; top: -4px; bottom: -4px; width: 1px; background: var(--ink-2); }
.bar-scale { position: relative; height: 14px; font-family: var(--font-num); font-size: 9.5px; color: var(--muted); }
.bar-scale span { position: absolute; transform: translateX(-50%); }
.burden-msg { display: flex; gap: 8px; align-items: flex-start; font-size: 12px; line-height: 1.5; margin-top: 8px; padding: 8px 10px; background: var(--accent-soft); color: var(--ink); }
.burden-msg svg { flex: none; margin-top: 2px; color: var(--accent); }
.burden.warn .fill { background: var(--warn); }
.burden.warn .burden-top .v { color: var(--warn); }
.burden.warn .burden-msg { background: var(--warn-soft); }
.burden.warn .burden-msg svg { color: var(--warn); }
.burden.danger .fill { background: var(--danger); }
.burden.danger .burden-top .v { color: var(--danger); }
.burden.danger .burden-msg { background: var(--danger-soft); }
.burden.danger .burden-msg svg { color: var(--danger); }

.inputs { padding: 6px 20px 0; }
.inp { padding: 14px 0; border-bottom: 1px solid var(--line); }
.inp-top { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 8px; }
.inp-top label { font-size: 13px; color: var(--ink-2); }
.inp-top .v { font-family: var(--font-num); font-weight: 600; font-size: 18px; font-feature-settings: "tnum" 1; }
.inp-top .v small { font-family: var(--font-sans); font-weight: 400; font-size: 12px; color: var(--ink-2); margin-left: 2px; }
.inp-hint { font-size: 11px; color: var(--muted); margin-top: 4px; }
input[type="range"] {
  -webkit-appearance: none; appearance: none;
  width: 100%; height: 24px; background: transparent; margin: 0;
  --p: 50%;
}
input[type="range"]::-webkit-slider-runnable-track {
  height: 3px;
  background: linear-gradient(90deg, var(--accent) var(--p), var(--line-strong) var(--p));
}
input[type="range"]::-moz-range-track { height: 3px; background: var(--line-strong); }
input[type="range"]::-moz-range-progress { height: 3px; background: var(--accent); }
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px; height: 22px; margin-top: -9.5px;
  border-radius: 50%;
  background: var(--surface);
  border: 1.5px solid var(--accent);
  box-shadow: 0 2px 6px rgba(0, 0, 0, .15);
}
input[type="range"]::-moz-range-thumb { width: 20px; height: 20px; border-radius: 50%; background: var(--surface); border: 1.5px solid var(--accent); }
.rate-switch { display: grid; grid-template-columns: 1fr 1fr; border: 1px solid var(--line-strong); margin-bottom: 10px; }
.rate-switch button { padding: 8px 0; font-size: 13px; color: var(--ink-2); line-height: 1.3; }
.rate-switch button small { display: block; font-size: 10px; color: var(--muted); }
.rate-switch button.on { background: var(--ink); color: var(--app-bg); }
.rate-switch button.on small { color: var(--app-bg); opacity: .7; }

.chart-box { margin: 18px 20px 0; }
.chart-legend { display: flex; gap: 14px; font-size: 11px; color: var(--ink-2); margin-bottom: 6px; }
.chart-legend i { display: inline-block; width: 10px; height: 10px; margin-right: 5px; vertical-align: -1px; }
.chart-svg { width: 100%; height: auto; touch-action: pan-y; cursor: crosshair; }
.chart-svg .axis { fill: var(--muted); font-family: var(--font-num); font-size: 9px; }
.chart-svg .grid { stroke: var(--line); stroke-width: 1; }
.chart-svg .bp { fill: var(--accent); }
.chart-svg .bi { fill: var(--brass); opacity: .85; }
.chart-svg .bal { fill: none; stroke: var(--ink); stroke-width: 1.4; stroke-dasharray: 3 2; }
.chart-svg .cursor { stroke: var(--ink); stroke-width: 1; }
.chart-svg.touched .bar-g.dim rect { opacity: .45; }
.chart-read { display: grid; grid-template-columns: auto 1fr 1fr 1fr; gap: 10px; align-items: baseline; font-size: 11px; color: var(--ink-2); padding: 10px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: 6px; }
.chart-read .yr { font-family: var(--font-num); font-weight: 600; font-size: 14px; color: var(--ink); }
.chart-read .num { color: var(--ink); font-weight: 600; font-size: 12.5px; display: block; }
.disclaimer { font-size: 10.5px; color: var(--muted); line-height: 1.6; padding: 12px 20px 0; margin: 0; }
.cta-row { padding: 16px 20px 28px; display: grid; gap: 8px; }

/* ---------- お気に入り ---------- */
.fav-list { padding: 4px 20px 0; }
.fav-item {
  display: grid;
  grid-template-columns: 24px 64px 1fr 32px;
  gap: 12px;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.fav-item .ph { width: 64px; height: 64px; border-radius: 2px; overflow: hidden; }
.fav-item .ph svg { width: 100%; height: 100%; }
.fav-item .fi-name { font-family: var(--font-min); font-weight: 600; font-size: 14px; line-height: 1.35; }
.fav-item .fi-sub { font-size: 11.5px; color: var(--muted); }
.fav-item .fi-price { font-family: var(--font-num); font-weight: 600; font-size: 14px; font-feature-settings: "tnum" 1; }
.fav-item .fi-open { text-align: left; }
.cbox {
  width: 22px; height: 22px; border: 1.5px solid var(--line-strong); border-radius: 4px;
  display: grid; place-items: center; color: transparent; transition: background .15s, border-color .15s;
}
.cbox.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.fav-hint { padding: 12px 20px 0; font-size: 11.5px; color: var(--muted); }
.compare { margin: 18px 0 0; padding: 0 0 28px; }
.compare .sec-title { padding: 0 20px; }
.cmp-scroll { overflow-x: auto; padding: 0 20px; scrollbar-width: none; }
.cmp-scroll::-webkit-scrollbar { display: none; }
.cmp { border-collapse: collapse; width: 100%; font-size: 12px; table-layout: fixed; }
.cmp th, .cmp td { padding: 9px 6px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.cmp thead th { border-bottom: 1.5px solid var(--ink); padding-bottom: 10px; }
.cmp tbody th { font-weight: 400; color: var(--muted); font-size: 10.5px; width: 62px; letter-spacing: .04em; padding-left: 0; }
.cmp .cmp-ph { height: 64px; overflow: hidden; margin-bottom: 6px; }
.cmp .cmp-ph svg { width: 100%; height: 100%; }
.cmp .cmp-name { font-family: var(--font-min); font-weight: 600; font-size: 12.5px; line-height: 1.35; display: block; }
.cmp td .num { font-weight: 600; font-size: 13px; }
.cmp td.best { color: var(--accent); }
.cmp td.best::after { content: "最良"; display: block; font-size: 9.5px; letter-spacing: .1em; color: var(--accent); margin-top: 1px; }
.cmp-note { font-size: 10.5px; color: var(--muted); padding: 10px 20px 0; margin: 0; }

/* ---------- 内見予約 ---------- */
.steps { display: flex; gap: 6px; padding: 10px 20px 0; }
.steps span { flex: 1; height: 3px; background: var(--line); transition: background .3s; }
.steps span.on { background: var(--accent); }
.steps-label { padding: 6px 20px 0; font-size: 11px; color: var(--muted); letter-spacing: .06em; }
.v-sec { padding: 18px 20px 4px; }
.v-sec h4 { font-size: 12px; color: var(--ink-2); font-weight: 500; margin: 0 0 10px; letter-spacing: .06em; display: flex; align-items: center; gap: 8px; }
.v-sec h4 .stepn { font-family: var(--font-num); width: 18px; height: 18px; border-radius: 50%; border: 1px solid var(--ink-2); display: grid; place-items: center; font-size: 10px; }
.select-prop {
  width: 100%;
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border: 1px solid var(--line-strong); background: var(--surface); text-align: left;
}
.select-prop .thumb { width: 48px; height: 48px; overflow: hidden; border-radius: 2px; flex: none; }
.select-prop .thumb svg { width: 100%; height: 100%; }
.select-prop .sp-name { font-family: var(--font-min); font-weight: 600; font-size: 14px; }
.select-prop .sp-sub { font-size: 11.5px; color: var(--muted); }
.select-prop > svg { margin-left: auto; color: var(--muted); }
.method { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.method button { border: 1px solid var(--line); padding: 10px; text-align: left; font-size: 13px; background: var(--surface); display: flex; gap: 8px; align-items: center; }
.method button.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }

.cal { border: 1px solid var(--line); background: var(--surface); padding: 12px 10px 10px; }
.cal-head { display: flex; align-items: center; justify-content: space-between; padding: 0 4px 8px; }
.cal-head .m { font-family: var(--font-min); font-weight: 600; font-size: 16px; letter-spacing: .06em; }
.cal-head .m .num { font-family: var(--font-num); font-size: 18px; margin-right: 1px; }
.cal-head button { width: 32px; height: 32px; display: grid; place-items: center; border-radius: 50%; }
.cal-head button:disabled { opacity: .25; cursor: default; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; text-align: center; }
.cal-grid .dow { font-size: 10px; color: var(--muted); padding: 4px 0; }
.cal-grid .dow.sun { color: var(--danger); }
.cal-grid .dow.sat { color: var(--accent); }
.day {
  height: 42px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  font-family: var(--font-num); font-size: 13.5px; font-feature-settings: "tnum" 1;
  border-radius: 4px;
  transition: background .15s;
}
.day:not(:disabled):hover { background: var(--surface-2); }
.day:disabled { color: var(--line-strong); cursor: default; }
.day .av { width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }
.day .av.low { background: var(--warn); }
.day .closed { font-family: var(--font-sans); font-size: 8.5px; color: var(--muted); line-height: 1; }
.day.on { background: var(--accent); color: var(--accent-ink); }
.day.on .av { background: var(--accent-ink); }
.day.today { box-shadow: inset 0 0 0 1px var(--line-strong); }
.cal-legend { display: flex; gap: 12px; font-size: 10.5px; color: var(--muted); padding: 8px 4px 0; }
.cal-legend i { display: inline-block; width: 6px; height: 6px; border-radius: 50%; margin-right: 4px; vertical-align: 1px; }

.slots { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.slot {
  height: 44px; border: 1px solid var(--line-strong); background: var(--surface);
  font-family: var(--font-num); font-size: 13.5px; font-feature-settings: "tnum" 1;
  display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.15;
}
.slot small { font-family: var(--font-sans); font-size: 9px; color: var(--warn); }
.slot:disabled { color: var(--line-strong); background: transparent; border-style: dashed; cursor: default; text-decoration: line-through; }
.slot.on { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.slot.on small { color: var(--accent-ink); }

.form { display: grid; gap: 12px; }
.form label { display: grid; gap: 5px; font-size: 12px; color: var(--ink-2); }
.form .lt { display: flex; align-items: center; }
.people { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line-strong); border-radius: 3px; overflow: hidden; background: var(--surface); }
.people button { height: 42px; font-size: 13px; border-left: 1px solid var(--line); }
.people button:first-child { border-left: 0; }
.people button.on { background: var(--ink); color: var(--app-bg); }
.form label .req { color: var(--danger); font-size: 10px; margin-left: 4px; }
.form input, .form select, .form textarea {
  height: 46px; padding: 0 12px;
  border: 1px solid var(--line-strong); border-radius: 3px; background: var(--surface);
  font-size: 15px; color: var(--ink);
  outline: none; transition: border-color .2s, box-shadow .2s;
}
.form textarea { height: 72px; padding: 10px 12px; resize: none; }
.form input:focus, .form select:focus, .form textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.form .err input { border-color: var(--danger); }
.form .err-msg { color: var(--danger); font-size: 11px; display: none; }
.form .err .err-msg { display: block; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.v-submit { padding: 18px 20px 30px; }
.v-summary { font-size: 12px; color: var(--ink-2); margin: 0 0 10px; display: flex; align-items: center; gap: 6px; }
.v-summary b { color: var(--ink); font-weight: 500; }
.spinner { width: 16px; height: 16px; border-radius: 50%; border: 2px solid currentColor; border-right-color: transparent; animation: spin .7s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.done { padding: 30px 24px 30px; text-align: center; }
.done-mark { width: 76px; height: 76px; margin: 10px auto 18px; border-radius: 50%; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; animation: pop .5s cubic-bezier(.2, 1.4, .4, 1); }
.done-mark path { stroke-dasharray: 30; stroke-dashoffset: 30; animation: draw .5s .25s forwards; }
@keyframes pop { from { transform: scale(.4); opacity: 0; } }
@keyframes draw { to { stroke-dashoffset: 0; } }
.done h3 { font-family: var(--font-min); font-weight: 600; font-size: 22px; margin: 0 0 6px; letter-spacing: .06em; }
.done p { font-size: 13px; color: var(--ink-2); margin: 0 0 18px; }
.ticket { text-align: left; border: 1px solid var(--line-strong); background: var(--surface); position: relative; margin-bottom: 18px; }
.ticket::before, .ticket::after { content: ""; position: absolute; top: 74px; width: 16px; height: 16px; border-radius: 50%; background: var(--app-bg); border: 1px solid var(--line-strong); }
.ticket::before { left: -9px; clip-path: inset(0 0 0 50%); }
.ticket::after { right: -9px; clip-path: inset(0 50% 0 0); }
.ticket .t-top { padding: 14px 16px; border-bottom: 1px dashed var(--line-strong); min-height: 82px; display: flex; gap: 12px; align-items: center; }
.ticket .t-top .thumb { width: 52px; height: 52px; overflow: hidden; border-radius: 2px; flex: none; }
.ticket .t-top .thumb svg { width: 100%; height: 100%; }
.ticket dl { margin: 0; padding: 10px 16px 14px; display: grid; grid-template-columns: 76px 1fr; gap: 6px 10px; font-size: 12.5px; }
.ticket dt { color: var(--muted); font-size: 11.5px; }
.ticket dd { margin: 0; }
.notify { display: flex; gap: 10px; align-items: flex-start; text-align: left; padding: 12px 14px; background: var(--accent-soft); font-size: 12px; line-height: 1.55; margin-bottom: 18px; }
.notify svg { flex: none; color: var(--accent); margin-top: 1px; }

/* ---------- トースト ---------- */
.toast {
  position: absolute; left: 50%; bottom: 104px;
  transform: translate(-50%, 20px);
  background: var(--ink); color: var(--app-bg);
  font-size: 12.5px; padding: 10px 16px; border-radius: 22px;
  opacity: 0; pointer-events: none;
  transition: opacity .25s, transform .25s;
  z-index: 80; white-space: nowrap;
  display: flex; align-items: center; gap: 8px;
  max-width: 92%;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* ---------- 解説パネル ---------- */
.pitch { padding: 72px 0 120px; position: relative; }
.pitch-eyebrow { font-size: 11.5px; letter-spacing: .22em; color: var(--muted); display: flex; align-items: center; gap: 10px; margin: 0 0 22px; }
.pitch-eyebrow::before { content: ""; width: 28px; height: 1px; background: var(--ink-2); }
.pitch h1 { font-family: var(--font-min); font-weight: 600; font-size: clamp(28px, 2.6vw, 38px); line-height: 1.5; letter-spacing: .04em; margin: 0 0 20px; }
.pitch h1 em { font-style: normal; background: linear-gradient(transparent 70%, var(--brass-soft) 70%); }
.pitch .lead { font-size: 14.5px; color: var(--ink-2); line-height: 1.9; margin: 0 0 40px; max-width: 34em; }
.pitch h2 { font-family: var(--font-min); font-weight: 600; font-size: 19px; letter-spacing: .06em; margin: 0 0 4px; }
.pitch .h2-sub { font-size: 12px; color: var(--muted); margin: 0 0 18px; }
.benefits { list-style: none; margin: 0 0 14px; padding: 0; counter-reset: b; }
.benefit {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 4px 16px;
  padding: 22px 0;
  border-top: 1px solid var(--line-strong);
  counter-increment: b;
}
.benefit:last-child { border-bottom: 1px solid var(--line-strong); }
.benefit .b-ico { width: 44px; height: 44px; display: grid; place-items: center; background: var(--surface); border: 1px solid var(--line); color: var(--accent); grid-row: 1 / span 4; grid-column: 1; }
.benefit > *:not(.b-ico) { grid-column: 2; }
.benefit h3 { margin: 0; font-size: 16px; font-weight: 700; letter-spacing: .03em; display: flex; align-items: baseline; gap: 10px; }
.benefit h3::before { content: "0" counter(b); font-family: var(--font-num); font-size: 11px; color: var(--muted); font-weight: 500; }
.benefit p { margin: 0; font-size: 13px; color: var(--ink-2); line-height: 1.8; }
.benefit .metric { display: flex; align-items: baseline; gap: 10px; margin-top: 10px; flex-wrap: wrap; }
.benefit .metric .mv { font-family: var(--font-num); font-weight: 600; font-size: 26px; letter-spacing: -.02em; color: var(--ink); font-feature-settings: "tnum" 1; }
.benefit .metric .mv small { font-family: var(--font-sans); font-size: 13px; font-weight: 500; margin-left: 2px; }
.benefit .metric .mk { font-size: 11.5px; color: var(--ink-2); }
.benefit .metric .assume { font-size: 10px; letter-spacing: .1em; border: 1px solid var(--line-strong); color: var(--muted); padding: 0 6px; }
.try-btn { justify-self: start; margin-top: 10px; font-size: 12.5px; color: var(--accent); display: inline-flex; align-items: center; gap: 4px; border-bottom: 1px solid currentColor; padding-bottom: 1px; }
.try-btn:hover { color: var(--accent-2); }
.pitch-note { font-size: 11px; color: var(--muted); margin: 0 0 44px; }
.custom { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--line); border: 1px solid var(--line); margin: 0 0 40px; }
.custom div { background: var(--bg); padding: 16px; }
.custom b { display: block; font-size: 13.5px; margin-bottom: 4px; }
.custom span { font-size: 12px; color: var(--ink-2); line-height: 1.7; display: block; }
.cta-box { background: var(--ink); color: var(--app-bg); padding: 28px; position: relative; overflow: hidden; }
.cta-box::after { content: ""; position: absolute; right: -40px; top: -40px; width: 180px; height: 180px; border: 1px solid rgba(255, 255, 255, .12); transform: rotate(45deg); }
.cta-box h2 { color: inherit; font-size: 20px; margin-bottom: 8px; }
.cta-box p { font-size: 13px; opacity: .8; margin: 0 0 18px; line-height: 1.8; }
.cta-box .btn { background: var(--app-bg); color: var(--ink); text-decoration: none; }
.cta-box .btn:hover { opacity: .9; }
.cta-links { display: flex; gap: 18px; margin-top: 16px; font-size: 12px; flex-wrap: wrap; }
.cta-links a { opacity: .75; text-decoration: none; border-bottom: 1px solid rgba(255, 255, 255, .3); }
.theme-row { display: flex; align-items: center; justify-content: space-between; margin-top: 36px; font-size: 12px; color: var(--muted); }

/* 常設バッジ */
.demo-badge {
  position: fixed;
  left: 20px; bottom: 18px;
  z-index: 100;
  display: flex; align-items: center; gap: 10px;
  font-size: 11.5px;
  color: var(--ink-2);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(10px);
  border: 1px solid var(--line-strong);
  padding: 6px 12px;
  letter-spacing: .03em;
}
.demo-badge a { color: var(--ink); text-decoration: none; border-bottom: 1px solid var(--line-strong); }
.demo-badge .sep { width: 1px; height: 12px; background: var(--line-strong); }
.demo-badge .to-pitch, .demo-badge .b-short { display: none; }


/* 一覧の入場アニメーション */
.prop.enter { animation: rise .5s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } }

/* 周辺マップ */
.mm-road { stroke: var(--surface); stroke-width: 5; fill: none; }
.mm-water { stroke: #9fb8c4; stroke-opacity: .55; stroke-width: 14; fill: none; }
.mm-park { fill: #9db495; opacity: .45; }
.mm-rail { stroke: var(--ink-2); stroke-width: 4; fill: none; }
.mm-rail2 { stroke: var(--surface-2); stroke-width: 2; stroke-dasharray: 6 6; fill: none; }
.mm-ring { fill: var(--accent); fill-opacity: .06; stroke: var(--accent); stroke-dasharray: 3 3; stroke-width: 1; }
.mm-ring-l { fill: var(--accent); font-size: 9px; font-family: var(--font-sans); letter-spacing: .06em; }
.mm-poi { fill: var(--brass); stroke: var(--surface); stroke-width: 1.5; }
.mm-lbl { fill: var(--ink-2); font-size: 9px; font-family: var(--font-sans); paint-order: stroke; stroke: var(--surface-2); stroke-width: 3px; }
.mm-st { fill: var(--ink); }
.mm-st-l { fill: var(--app-bg); font-size: 9px; font-family: var(--font-sans); font-weight: 500; }
.mm-home { fill: var(--accent); }
.mm-home-ring { fill: var(--accent); opacity: .15; }

/* ---------- レスポンシブ ---------- */
@media (max-width: 1079px) {
  .stage { grid-template-columns: 1fr; max-width: 720px; }
  .device-col { position: relative; height: auto; padding: 48px 0 8px; }
  .pitch { padding-top: 40px; }
}

/* スマホ幅: 端末フレームなしで全画面アプリ、解説は下 */
@media (max-width: 699px) {
  body { font-size: 14.5px; }
  .stage { display: block; padding: 0; }
  .stage::before { display: none; }
  .device-col { height: calc(100dvh - 30px); padding: 0; margin-top: 30px; }
  .device { width: 100% !important; height: 100% !important; }
  .device-inner { position: static; width: 100%; height: 100%; transform: none; border-radius: 0; padding: 0; box-shadow: none; background: none; }
  .device-inner::after { display: none; }
  .device-caption { display: none; }
  .app { border-radius: 0; grid-template-rows: 0 1fr auto; }
  .statusbar { visibility: hidden; }
  .detail { top: 0; }
  .tabbar { padding-bottom: calc(8px + env(safe-area-inset-bottom)); }
  .action-bar { padding-bottom: calc(10px + env(safe-area-inset-bottom)); }
  .pitch { padding: 44px 20px 60px; }
  .custom { grid-template-columns: 1fr; }
  .demo-badge {
    top: 0; left: 0; right: 0; bottom: auto;
    height: 30px; padding: 0 14px;
    border: 0; border-bottom: 1px solid var(--line);
    font-size: 10.5px; gap: 8px;
    background: var(--bg);
    backdrop-filter: none;
    justify-content: flex-start;
    white-space: nowrap;
    overflow: hidden;
  }
  .demo-badge .to-pitch { display: inline; margin-left: auto; }
  .demo-badge .b-full { display: none; }
  .demo-badge .b-short { display: inline; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}
