/* リフォーム提案LP 第2便（index.html・input.html 共通）。結果・相談の画面は result.css が r-* で上に重ねる。
   色・書体・余白は下の変数（--*）だけを正とする。外部フォント・外部画像は読まない（同一オリジンの静的配信だけ）。 */
:root {
  /* 2026-10-15 代表指定の配色: 背景 #F8F6F2・文字 #22272C・アクセント #B49765・カード #FFFFFF */
  --paper: #f8f6f2;      /* 背景 */
  --paper-2: #f0ece5;    /* 一段沈んだ地 */
  --paper-3: #e6e1d8;
  --card: #ffffff;       /* カード・入力欄・選択肢の面 */
  --ink: #22272c;        /* 文字（チャコール。paper 13.95・card 15.06） */
  --ink-2: #4a5058;      /* 補足（paper 7.54・paper-2 6.91・paper-3 6.25・card 8.14） */
  --ink-3: #5b6168;      /* 注記・入力例（paper 5.80・paper-2 5.32・paper-3 4.81・card 6.26） */
  --line: #dcd6cc;
  --line-2: #c4bdb0;
  --accent: #b49765;     /* アクセントの金（装飾・線・アイコンだけ。地の上では 2.6:1 のため文字や操作の印には使わない。炭の上では 5.42:1） */
  --accent-ink: #22272c; /* CTA の地・リンク・フォーカス・必須・選択中の印はチャコール（白文字で 15.06:1） */
  --accent-soft: #f3ecdf; /* 金の薄い地（選択中の面・選択範囲） */
  --ok: #3f6b4f;
  --err: #a8321f;
  --serif: "Hiragino Mincho ProN", "Yu Mincho", "YuMincho", "BIZ UDPMincho", "Noto Serif JP", serif;
  --sans: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "BIZ UDPGothic", "Yu Gothic UI", "Yu Gothic", "Meiryo", system-ui, sans-serif;
  --wrap: 1180px;
  --gutter: clamp(20px, 4vw, 48px);
  --radius: 6px;
  --shadow: 0 10px 30px -18px rgba(34, 39, 44, .45);
  --ease: cubic-bezier(.16, 1, .3, 1);
  color-scheme: light;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body {
  word-break: auto-phrase; line-break: strict;
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--sans); font-size: 16px; line-height: 1.8; letter-spacing: .02em;
  font-feature-settings: "palt" 1; text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--accent-ink); text-underline-offset: .22em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
::selection { background: var(--accent-soft); color: var(--ink); }
:focus-visible { outline: 2px solid var(--accent-ink); outline-offset: 3px; border-radius: 2px; }
button, input, select, textarea { font: inherit; color: inherit; letter-spacing: inherit; }
input, textarea { caret-color: var(--accent-ink); }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.32; letter-spacing: .03em; margin: 0; text-wrap: balance; }
p { margin: 0; }
.nb { display: inline-block; }
.num { font-variant-numeric: tabular-nums lining-nums; font-feature-settings: "tnum" 1, "lnum" 1; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; } /* SVG の部品置き場（CSP の style-src 'self' のためインラインの style をやめた） */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
.wrap { width: min(100% - 2 * var(--gutter), var(--wrap)); margin-inline: auto; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--ink); color: var(--paper); padding: 8px 14px; z-index: 50; border-radius: var(--radius); }
.skip:focus { top: 10px; }
.ico { width: 1.25em; height: 1.25em; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex: none; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 10px; border: 2px solid var(--paper); }
::-webkit-scrollbar-track { background: var(--paper); }

/* ── 代表確認用の帯（全画面共通・控えめに明確に） */
.demo-badge { display: inline-flex; align-items: center; gap: .45em; padding: .2em .7em; border: 1px solid var(--line-2); border-radius: 999px; font-size: 12px; line-height: 1.6; color: var(--ink-2); background: var(--card); white-space: nowrap; }
.demo-badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }

/* ── ヘッダー */
.site-header { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: saturate(1.2) blur(8px); border-bottom: 1px solid transparent; transition: border-color .3s; }
.site-header.is-scrolled { border-bottom-color: var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 16px; min-height: 64px; }
.brand { display: inline-flex; align-items: baseline; gap: 10px; color: var(--ink); text-decoration: none; }
.brand b { font-family: var(--serif); font-size: 22px; font-weight: 700; letter-spacing: .12em; }
.brand b i { font-style: normal; color: var(--accent); }
.brand span { font-size: 12px; color: var(--ink-2); letter-spacing: .06em; }
.header-right { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.header-cta { font-size: 14px; font-weight: 600; padding: .55em 1.1em; border-radius: 999px; background: var(--ink); color: var(--paper); text-decoration: none; white-space: nowrap; }
.header-cta:hover { background: #000; }
@media (max-width: 720px) {
  .brand span { display: none; }
  .header-cta { display: none; }
  .site-header .wrap { min-height: 56px; }
}

/* ── ボタン */
.button { display: inline-flex; align-items: center; justify-content: center; gap: .6em; min-height: 56px; padding: .9em 1.8em; border: 0; border-radius: 999px; background: var(--accent-ink); color: #fff; font-weight: 700; font-size: 17px; letter-spacing: .06em; text-decoration: none; cursor: pointer; box-shadow: 0 12px 24px -14px rgba(34, 39, 44, .55); /* 中立色の影（暖色の発光をやめる・offset/blur は同じ） */ transition: background .2s, transform .25s var(--ease), box-shadow .25s; }
.button:hover { background: #3a4047; transform: translateY(-1px); text-decoration: none; }
.button:active { transform: translateY(0); }
.button .ico { width: 1.1em; height: 1.1em; stroke-width: 2; transition: transform .3s var(--ease); }
.button:hover .ico { transform: translateX(3px); }
.button[disabled] { background: var(--line-2); color: var(--ink-2); box-shadow: none; cursor: not-allowed; transform: none; }
.button.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-2); }
.button.ghost:hover { background: var(--paper-2); }
.cta-note { margin-top: 12px; font-size: 13px; color: var(--ink-2); display: flex; flex-wrap: wrap; gap: 4px 16px; }
.cta-note span { display: inline-flex; align-items: center; gap: .35em; }
.cta-note .ico { color: var(--ok); width: 1.05em; height: 1.05em; stroke-width: 2; }

/* ── HERO（写真が主役） */
.hero { position: relative; display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); min-height: min(calc(100svh - 64px), 820px); }
.hero-copy { position: relative; z-index: 2; display: flex; flex-direction: column; justify-content: center; padding: clamp(40px, 6vw, 88px) clamp(24px, 4vw, 64px) clamp(40px, 6vw, 80px) max(var(--gutter), calc((100vw - var(--wrap)) / 2)); }
.hero h1 { font-size: clamp(2.1rem, 3.9vw, 3.9rem); line-height: 1.28; letter-spacing: .02em; }
.hero h1 .q { color: var(--ink); text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: .07em; text-underline-offset: .16em; } /* 強調は金の下線（金の文字は地の上で読みにくいため） */
.hero-sub { margin-top: 24px; max-width: 30em; font-size: clamp(15px, 1.25vw, 17px); color: var(--ink-2); line-height: 1.95; }
.hero-cta { margin-top: 32px; }
.hero-photo { position: relative; margin: 0; overflow: hidden; background: var(--paper-2); }
.hero-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 40% 60%; animation: heroIn 1.6s var(--ease) both; }
@keyframes heroIn { from { transform: scale(1.06); filter: saturate(.85); } to { transform: none; filter: none; } }
.photo-tag { position: absolute; left: 16px; bottom: 16px; z-index: 2; display: inline-flex; gap: .5em; align-items: center; max-width: calc(100% - 32px); padding: .35em .8em; border-radius: 4px; background: rgba(34, 39, 44, .78); color: #fbf8f2; font-size: 12px; line-height: 1.5; }
.photo-tag b { font-weight: 700; color: #fff; }
.award { margin-top: 40px; padding-top: 22px; border-top: 1px solid var(--line); display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; align-items: center; max-width: 30em; }
.award .laurel { width: 46px; height: 46px; color: var(--accent); stroke-width: 1.3; grid-row: span 2; }
.award p { font-family: var(--serif); font-size: 15px; line-height: 1.55; }
.award p strong { display: block; font-size: 18px; letter-spacing: .04em; }
.award small { font-size: 12px; color: var(--ink-3); line-height: 1.6; }
/* 出典・受賞のリンクのタップ領域（行の高さは変えず、上下の余白で 44px 前後に広げる） */
.award small a, .award-feature .meta a, .site-footer li a { display: inline-block; padding-block: 13px; margin-block: -13px; }
.award-feature .meta a { padding-block: 10px; margin-block: -10px; }
@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: 0; }
  .hero-photo { order: -1; aspect-ratio: 4 / 3.1; }
  .hero-copy { padding: 28px var(--gutter) 44px; }
  .hero h1 { font-size: clamp(1.95rem, 8.4vw, 2.6rem); }
  .hero-cta .button { width: 100%; }
  .award { margin-top: 30px; }
}

/* ── セクション共通 */
.section { padding-block: clamp(72px, 10vw, 136px); }
.section.tint { background: var(--paper-2); }
.section.ink { background: var(--ink); color: #efe9df; }
.section-head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 24px clamp(24px, 5vw, 80px); align-items: end; margin-bottom: clamp(36px, 5vw, 64px); }
.section-head h2 { font-size: clamp(1.7rem, 3vw, 2.6rem); }
.section-head p { color: var(--ink-2); max-width: 34em; }
.section.ink .section-head p { color: #cfc8bc; }
@media (max-width: 820px) { .section-head { grid-template-columns: 1fr; align-items: start; } }

/* ── 3つの道（図） */
.paths { position: relative; display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; }
.paths::before { content: ""; position: absolute; left: 7%; right: 7%; top: 47px; height: 2px; background: linear-gradient(90deg, var(--line-2), var(--accent)); }
.path { position: relative; padding: 0 clamp(12px, 2vw, 32px); text-align: center; }
.path .dot { position: relative; z-index: 1; display: grid; place-items: center; margin: 0 auto; border-radius: 50%; background: var(--paper); border: 2px solid var(--line-2); color: var(--ink); }
.path:nth-child(1) .dot { width: 64px; height: 64px; margin-top: 16px; margin-bottom: 38px; }
.path:nth-child(2) .dot { width: 80px; height: 80px; margin-top: 8px; margin-bottom: 30px; border-color: var(--accent); }
.path:nth-child(3) .dot { width: 96px; height: 96px; margin-top: 0; margin-bottom: 22px; border-color: var(--accent); background: var(--accent-soft); }
.path .dot .ico { width: 44%; height: 44%; stroke-width: 1.4; }
.path h3 { font-size: clamp(1.15rem, 1.7vw, 1.4rem); }
.path p { margin-top: 8px; color: var(--ink-2); font-size: 15px; }
.scope-axis { display: flex; justify-content: space-between; margin: 28px 7% 0; font-size: 12px; color: var(--ink-3); letter-spacing: .1em; }
.paths-foot { margin-top: clamp(36px, 5vw, 56px); display: flex; flex-wrap: wrap; gap: 12px 40px; justify-content: center; font-size: 15px; }
.paths-foot span { display: inline-flex; align-items: center; gap: .5em; }
.paths-foot .ico { color: var(--accent); }
@media (max-width: 720px) {
  .paths { grid-template-columns: 1fr; gap: 28px; }
  .paths::before { left: 31px; right: auto; top: 20px; bottom: 30px; width: 2px; height: auto; background: linear-gradient(180deg, var(--line-2), var(--accent)); }
  .path { display: grid; grid-template-columns: 64px 1fr; gap: 0 18px; text-align: left; padding: 0; align-items: center; }
  .path .dot, .path:nth-child(n) .dot { width: 64px; height: 64px; margin: 0; grid-row: span 2; }
  .path p { margin-top: 2px; }
  .scope-axis { display: none; }
  .paths-foot { justify-content: flex-start; flex-direction: column; }
}

/* ── 施工例（施工前→施工後・同じ現場の組だけ） */
.works-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 28px; padding: 0; border: 0; }
.works-tabs legend { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.works-tabs label { position: relative; cursor: pointer; }
.works-tabs input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.works-tabs span { display: inline-flex; align-items: center; gap: .45em; padding: .5em 1.15em; border-radius: 999px; border: 1px solid var(--line-2); font-size: 15px; background: var(--card); transition: background .2s, color .2s, border-color .2s; }
.works-tabs input:checked + span { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.works-tabs input:focus-visible + span { outline: 2px solid var(--accent-ink); outline-offset: 3px; }
.ba { margin: 0; display: none; grid-template-columns: minmax(0, 4fr) auto minmax(0, 7fr); gap: clamp(12px, 2vw, 28px); align-items: center; }
.works:has(#w-ldk:checked) .ba-ldk, .works:has(#w-kitchen:checked) .ba-kitchen, .works:has(#w-bath:checked) .ba-bath, .works:has(#w-toilet:checked) .ba-toilet { display: grid; animation: baIn .7s var(--ease) both; }
@keyframes baIn { from { opacity: 0; clip-path: inset(0 0 0 8%); } to { opacity: 1; clip-path: inset(0); } }
.ba figure { margin: 0; position: relative; }
.ba .before img, .ba .after img { width: 100%; object-fit: cover; border-radius: var(--radius); background: var(--paper-3); }
.ba .before img { aspect-ratio: 4 / 3; }
.ba .after img { aspect-ratio: 3 / 2; box-shadow: var(--shadow); }
.ba-bath .before img { aspect-ratio: 3 / 4; max-height: 420px; width: auto; margin-inline: auto; }
.ba .stamp { position: absolute; top: 12px; left: 12px; padding: .1em .7em; border-radius: 3px; font-size: 12px; font-weight: 700; letter-spacing: .12em; background: var(--card); color: var(--ink); }
.ba .after .stamp { background: var(--accent-ink); color: #fff; }
.ba-arrow { color: var(--accent); width: 34px; height: 34px; stroke-width: 1.4; }
.ba figcaption { grid-column: 1 / -1; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 6px 24px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 14px; color: var(--ink-2); }
.ba figcaption b { color: var(--ink); font-weight: 700; }
.ba figcaption small { font-size: 12px; color: var(--ink-3); }
@media (max-width: 720px) {
  .works-tabs span { font-size: 14px; padding: .45em .95em; }
  .ba { grid-template-columns: 1fr; }
  .ba-arrow { transform: rotate(90deg); margin: -4px auto; }
  .ba .before { width: 64%; }
  .ba-bath .before img { max-height: 300px; margin-inline: 0; }
}
.cg-row { margin-top: clamp(48px, 7vw, 88px); display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(24px, 4vw, 64px); align-items: center; }
.cg-row figure { margin: 0; position: relative; }
.cg-row img { border-radius: var(--radius); box-shadow: var(--shadow); aspect-ratio: 960 / 679; object-fit: cover; width: 100%; }
.cg-row h3 { font-size: clamp(1.35rem, 2.2vw, 1.8rem); }
.cg-row p { margin-top: 14px; color: var(--ink-2); }
.tag-cg { position: absolute; top: 12px; left: 12px; padding: .15em .7em; border-radius: 3px; background: rgba(34, 39, 44, .82); color: #fff; font-size: 12px; font-weight: 700; letter-spacing: .1em; }
@media (max-width: 820px) { .cg-row { grid-template-columns: 1fr; } }

/* ── 4つの視点（管理会社だから） */
.views { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid rgba(239, 233, 223, .25); }
.view { padding: 32px 28px 8px 0; }
.view + .view { padding-left: 28px; border-left: 1px solid rgba(239, 233, 223, .18); }
.view .ico { width: 40px; height: 40px; color: var(--accent); stroke-width: 1.3; }
.view h3 { margin-top: 18px; font-size: 1.25rem; color: #fbf7f0; }
.view p { margin-top: 8px; font-size: 15px; color: #cfc8bc; }
.section.ink h2 { color: #fbf7f0; }
@media (max-width: 900px) {
  .views { grid-template-columns: 1fr 1fr; }
  .view:nth-child(3) { padding-left: 0; border-left: 0; }
  .view:nth-child(n+3) { border-top: 1px solid rgba(239, 233, 223, .18); }
}
@media (max-width: 520px) {
  .views { grid-template-columns: 1fr; }
  .view, .view + .view { padding: 22px 0 18px; border-left: 0; display: grid; grid-template-columns: 40px 1fr; gap: 0 16px; }
  .view + .view { border-top: 1px solid rgba(239, 233, 223, .18); }
  .view .ico { grid-row: span 2; }
  .view h3 { margin-top: 0; }
}

/* ── 受賞作品 */
.award-feature { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(28px, 5vw, 80px); align-items: center; }
.award-feature figure { margin: 0; }
.award-feature img { width: 100%; aspect-ratio: 1024 / 682; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); }
.award-feature figcaption { margin-top: 10px; font-size: 12px; color: var(--ink-3); }
.award-feature .laurel { width: 56px; height: 56px; color: var(--accent); stroke-width: 1.2; }
.award-feature .year { margin-top: 18px; font-size: 14px; letter-spacing: .14em; color: var(--ink-2); }
.award-feature h2 { margin-top: 6px; font-size: clamp(1.8rem, 3.2vw, 2.7rem); }
.award-feature .work { margin-top: 18px; font-family: var(--serif); font-size: 1.1rem; line-height: 1.7; }
.award-feature .meta { margin-top: 18px; font-size: 13px; color: var(--ink-2); line-height: 1.9; }
@media (max-width: 820px) { .award-feature { grid-template-columns: 1fr; } }

/* ── AFTY の理由（罫線の一覧） */
.reasons { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 clamp(28px, 5vw, 72px); margin: 0; }
.reason { display: grid; grid-template-columns: 44px 1fr; gap: 4px 18px; padding: 26px 0; border-top: 1px solid var(--line); }
.reason dt { grid-column: 2; font-family: var(--serif); font-size: 1.2rem; font-weight: 600; line-height: 1.5; }
.reason dd { grid-column: 2; margin: 0; color: var(--ink-2); font-size: 15px; }
.reason .ico { grid-row: 1 / span 2; grid-column: 1; width: 40px; height: 40px; color: var(--accent); stroke-width: 1.3; }
@media (max-width: 720px) { .reasons { grid-template-columns: 1fr; } }

/* ── 診断でわかること（入力 → 結果の図） */
.diagram { display: grid; grid-template-columns: minmax(0, 4fr) 64px minmax(0, 7fr); align-items: stretch; gap: 0; }
.diagram .col h3 { font-size: 14px; font-family: var(--sans); font-weight: 700; letter-spacing: .14em; color: var(--ink-3); margin-bottom: 14px; }
.diagram ol { list-style: none; margin: 0; padding: 0; counter-reset: d; }
.diagram .in li { display: flex; align-items: center; gap: 14px; padding: 16px 18px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); font-weight: 600; }
.diagram .in li + li { margin-top: 10px; }
.diagram .in li .ico { color: var(--accent); width: 26px; height: 26px; }
.diagram .in li small { display: block; font-weight: 400; font-size: 13px; color: var(--ink-2); }
.diagram .arrow { display: grid; place-items: center; color: var(--accent); }
.diagram .arrow .ico { width: 36px; height: 36px; stroke-width: 1.3; }
.diagram .out ol { display: grid; grid-template-columns: 1fr 1fr; gap: 0 28px; }
.diagram .out li { counter-increment: d; display: grid; grid-template-columns: 2.2em 1fr; padding: 12px 0; border-top: 1px solid var(--line); font-size: 15px; }
.diagram .out li small { display: block; font-size: 13px; color: var(--ink-2); line-height: 1.6; }
.diagram .out li::before { content: counter(d); font-family: var(--serif); font-size: 1.35rem; line-height: 1.3; color: var(--accent-ink); font-variant-numeric: tabular-nums; }
.diagram .out li.wide { grid-column: 1 / -1; }
.diagram-note { margin-top: 26px; display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; border-radius: var(--radius); background: var(--card); border: 1px dashed var(--line-2); font-size: 14px; color: var(--ink-2); }
.diagram-note .ico { color: var(--ink-2); margin-top: .2em; }
@media (max-width: 900px) {
  .diagram { grid-template-columns: 1fr; }
  .diagram .arrow { padding: 14px 0; }
  .diagram .arrow .ico { transform: rotate(90deg); }
}
@media (max-width: 520px) { .diagram .out ol { grid-template-columns: 1fr; } }

/* ── 相談の流れ */
.flow { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(5, 1fr); position: relative; }
.flow::before { content: ""; position: absolute; top: 27px; left: 10%; right: 10%; height: 1px; background: var(--line-2); }
.flow li { position: relative; text-align: center; padding: 0 10px; }
.flow .ico-wrap { position: relative; z-index: 1; width: 56px; height: 56px; margin: 0 auto 16px; border-radius: 50%; display: grid; place-items: center; background: var(--paper); border: 1px solid var(--line-2); color: var(--ink); }
.flow li.here .ico-wrap { background: var(--accent-ink); color: #fff; border-color: var(--accent-ink); }
.flow .ico-wrap .ico { width: 24px; height: 24px; }
.flow b { display: block; font-family: var(--serif); font-size: 1.05rem; }
.flow small { display: block; margin-top: 4px; font-size: 13px; color: var(--ink-2); line-height: 1.6; }
@media (max-width: 820px) {
  .flow { grid-template-columns: 1fr; gap: 18px; }
  .flow::before { left: 27px; right: auto; top: 10px; bottom: 10px; width: 1px; height: auto; }
  .flow li { display: grid; grid-template-columns: 56px 1fr; gap: 0 16px; text-align: left; align-items: center; padding: 0; }
  .flow .ico-wrap { margin: 0; grid-row: span 2; }
}

/* ── よくある質問 */
.faq { max-width: 860px; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 16px; padding: 22px 0; font-family: var(--serif); font-size: 1.1rem; font-weight: 600; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .ico { color: var(--accent); transition: transform .3s var(--ease); margin-top: .25em; }
.faq details[open] summary .ico { transform: rotate(45deg); }
.faq details p { padding: 0 0 22px; color: var(--ink-2); max-width: 46em; }

/* ── 最後の CTA */
.closing { position: relative; display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); min-height: 460px; background: var(--ink); color: #f4efe6; }
.closing figure { margin: 0; position: relative; overflow: hidden; }
.closing figure img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.closing .copy { padding: clamp(40px, 6vw, 88px) var(--gutter); display: flex; flex-direction: column; justify-content: center; }
.closing h2 { font-size: clamp(1.7rem, 3vw, 2.5rem); color: #fbf7f0; }
.closing p { margin-top: 16px; color: #d8d1c4; }
.closing .button { margin-top: 30px; align-self: flex-start; }
.closing .cta-note { color: #cfc8bc; }
@media (max-width: 820px) { .closing { grid-template-columns: 1fr; } .closing figure { aspect-ratio: 16 / 10; } .closing .button { align-self: stretch; } }

/* ── フッター */
.site-footer { padding: 48px 0 calc(48px + env(safe-area-inset-bottom)); font-size: 13px; color: var(--ink-2); }
.site-footer .wrap { display: grid; gap: 18px; }
.site-footer .row { display: flex; flex-wrap: wrap; gap: 8px 28px; align-items: baseline; justify-content: space-between; }
.site-footer h2 { font-family: var(--sans); font-size: 13px; font-weight: 700; letter-spacing: .1em; color: var(--ink); }
.site-footer ul { margin: 6px 0 0; padding-left: 1.2em; line-height: 1.9; }
.site-footer li + li { margin-top: 20px; } /* 隣のリンクとタップ領域が重ならない間隔 */
.site-footer li a { padding-block: 10px; margin-block: -10px; }
.site-footer .demo { padding: 14px 16px; border-radius: var(--radius); background: var(--paper-2); }

/* ── スマホの下の固定 CTA（index のみ） */
.sticky-cta { display: none; }
@media (max-width: 720px) {
  .sticky-cta { display: block; position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: color-mix(in srgb, var(--paper) 94%, transparent); backdrop-filter: blur(8px); border-top: 1px solid var(--line); transform: translateY(110%); transition: transform .4s var(--ease); }
  .sticky-cta.is-on { transform: none; }
  .sticky-cta .button { width: 100%; min-height: 52px; }
  body.has-sticky .site-footer { padding-bottom: 110px; }
}

/* ════════ 入力（input.html） ════════ */
.form-page { padding: clamp(28px, 4vw, 56px) 0 120px; }
.form-wrap { width: min(100% - 2 * var(--gutter), 820px); margin-inline: auto; }
.form-intro h1 { font-size: clamp(1.55rem, 3vw, 2.2rem); }
.form-intro p { margin-top: 10px; color: var(--ink-2); font-size: 15px; }
.progress { list-style: none; margin: 28px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; counter-reset: s; }
.progress li { counter-increment: s; position: relative; padding-top: 14px; font-size: 14px; color: var(--ink-3); }
.progress li::before { content: ""; position: absolute; top: 0; left: 0; right: 0; height: 4px; border-radius: 4px; background: var(--paper-3); }
.progress li::after { content: ""; position: absolute; top: 0; left: 0; height: 4px; width: 0; border-radius: 4px; background: var(--accent-ink); transition: width .5s var(--ease); }
.progress li.done::after, .progress li[aria-current="step"]::after { width: 100%; }
.progress li[aria-current="step"]::after { background: var(--accent); }
.progress li[aria-current="step"], .progress li.done { color: var(--ink); }
.progress li b { font-family: var(--serif); font-weight: 600; margin-right: .4em; font-variant-numeric: tabular-nums; }
@media (max-width: 520px) { .progress li span { display: none; } .progress li[aria-current="step"] span { display: inline; } }
.step { margin-top: 36px; }
.step[hidden] { display: none; }
.step-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 16px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.step-head h2 { font-size: clamp(1.35rem, 2.6vw, 1.75rem); outline: none; }
.step-head p { font-size: 13px; color: var(--ink-2); }
.req, .opt { display: inline-block; margin-left: .45em; padding: 0 .5em; border-radius: 3px; font-size: 11px; font-weight: 700; line-height: 1.75; letter-spacing: .06em; vertical-align: .12em; font-family: var(--sans); }
.req { background: var(--accent-ink); color: #fff; }
.opt { background: var(--paper-3); color: var(--ink-2); }
.error-summary { margin-top: 20px; padding: 14px 16px; border-radius: var(--radius); background: #fbeae4; color: var(--err); font-size: 14px; outline: none; }
.error-summary b { display: block; margin-bottom: 2px; }
.error-summary ul { margin: 4px 0 0; padding-left: 1.2em; }
.error-summary a { color: var(--err); }
.fatal { margin-top: 24px; padding: 18px; border-radius: var(--radius); background: #fbeae4; color: var(--err); }

/* 写した物件フォーム（3fc50fec の qa-grid / qa-f の欄をそのまま使う） */
.qa-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 20px 18px; margin-top: 24px; }
.qa-f { grid-column: span 3; display: flex; flex-direction: column; min-width: 0; }
.qa-f.qa-trio { grid-column: span 2; }
.qa-f.qa-wide, .qa-f.qa-city { grid-column: span 3; }
.qa-f label, .field > label, .field > .label, fieldset.field > legend { font-weight: 700; font-size: 15px; margin-bottom: 8px; padding: 0; }
.qa-f select, .qa-f input, .field select, .field input[type="text"], .field textarea {
  width: 100%; min-height: 52px; padding: 12px 14px; border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--card); font-size: 16px; line-height: 1.5; appearance: none; -webkit-appearance: none; transition: border-color .2s, box-shadow .2s;
}
.qa-f select, .field select { padding-right: 42px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23545a56' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; }
.field textarea { min-height: 96px; resize: vertical; }
.qa-f select:hover, .qa-f input:hover, .field select:hover, .field input:hover, .field textarea:hover { border-color: var(--ink-3); }
.qa-f select:focus, .qa-f input:focus, .field select:focus, .field input:focus, .field textarea:focus { outline: none; border-color: var(--accent-ink); box-shadow: 0 0 0 3px var(--accent-soft); }
[aria-invalid="true"] { border-color: var(--err) !important; box-shadow: 0 0 0 3px #f6d6cc !important; }
.qa-f select:disabled { background-color: var(--paper-2); color: var(--ink-3); }
::placeholder { color: var(--ink-3); opacity: 1; } /* 入力欄の地 card で 5.95:1（旧 #8a8e8a は 3.27:1） */
.qa-help, .qa-note, .help { margin-top: 6px; font-size: 13px; color: var(--ink-2); line-height: 1.6; }
.field-error { min-height: 0; margin-top: 6px; font-size: 13px; color: var(--err); font-weight: 600; line-height: 1.5; }
.field-error:empty { display: none; }
.source-note { margin-top: 16px; font-size: 12px; color: var(--ink-3); }
@media (max-width: 640px) {
  .qa-grid { grid-template-columns: 1fr 1fr; gap: 18px 12px; }
  .qa-f, .qa-f.qa-wide, .qa-f.qa-city { grid-column: 1 / -1; }
  .qa-f.qa-trio { grid-column: span 1; }
  .qa-f.qa-walk { grid-column: 1 / -1; }
}

/* 選択肢のタイル（ラジオ・チェック） */
.field { margin: 28px 0 0; padding: 0; border: 0; min-width: 0; }
fieldset.field > legend { display: block; width: 100%; }
.choices { display: grid; gap: 10px; }
.choices.c2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.choices.c3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.choices.c4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.choices.c6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
@media (max-width: 720px) { .choices.c4, .choices.c6 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .choices.c3 { grid-template-columns: 1fr; } }
@media (max-width: 420px) { .choices.c4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .choices.c6 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.choice { position: relative; display: block; cursor: pointer; }
.choice input { position: absolute; opacity: 0; width: 100%; height: 100%; inset: 0; margin: 0; cursor: pointer; }
.choice > span { display: flex; align-items: center; gap: 10px; height: 100%; min-height: 56px; padding: 12px 14px; border: 1px solid var(--line-2); border-radius: var(--radius); background: var(--card); font-weight: 600; font-size: 15px; line-height: 1.45; transition: border-color .2s, background .2s, box-shadow .2s; }
.choice > span small { display: block; font-weight: 400; font-size: 12px; color: var(--ink-2); }
.choice .ico { width: 26px; height: 26px; color: var(--ink-2); stroke-width: 1.4; }
.choice.tile > span { flex-direction: column; justify-content: center; text-align: center; gap: 6px; min-height: 92px; padding: 14px 8px; }
.choice.tile .ico { width: 30px; height: 30px; }
.choice:hover > span { border-color: var(--ink-3); }
.choice input:checked + span { border-color: var(--accent-ink); background: var(--accent-soft); box-shadow: inset 0 0 0 1px var(--accent-ink); }
.choice input:checked + span .ico { color: var(--accent-ink); }
.choice input:focus-visible + span { outline: 2px solid var(--accent-ink); outline-offset: 2px; }
.choice input:disabled + span { opacity: .5; cursor: not-allowed; }
.choice .mark { position: absolute; top: 8px; right: 8px; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--line-2); background: var(--card); display: grid; place-items: center; }
.choice input[type="checkbox"] ~ .mark { border-radius: 4px; }
.choice input:checked ~ .mark { background: var(--accent-ink); border-color: var(--accent-ink); }
.choice input:checked ~ .mark::after { content: ""; width: 8px; height: 5px; border: 2px solid #fff; border-top: 0; border-right: 0; transform: translateY(-1px) rotate(-45deg); }
.fieldset-error[aria-invalid="true"] .choice > span { border-color: var(--err); }
.choices[aria-invalid="true"] { box-shadow: none !important; border: 0 !important; }
.choices[aria-invalid="true"] .choice > span { border-color: var(--err); }
.sub-panel { margin-top: 14px; padding: 18px; border-radius: var(--radius); background: var(--paper-2); border: 1px solid var(--line); }
.sub-panel[hidden] { display: none; }
.sub-panel .field:first-child { margin-top: 0; }
.inline-input { display: flex; align-items: center; gap: 10px; max-width: 260px; }
.inline-input input { text-align: right; }
.inline-input span { white-space: nowrap; font-weight: 600; }
.counter { margin-top: 4px; font-size: 12px; color: var(--ink-3); text-align: right; }
.photo-note { margin-top: 28px; display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; border-radius: var(--radius); border: 1px dashed var(--line-2); background: var(--card); font-size: 14px; color: var(--ink-2); }
.photo-note .ico { color: var(--accent); width: 24px; height: 24px; }
.photo-note b { color: var(--ink); }

/* 段の下のボタン */
.step-nav { margin-top: 40px; display: flex; gap: 12px; align-items: center; justify-content: space-between; }
.step-nav .button { min-width: 180px; }
.step-nav .back { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-2); min-width: 120px; }
.step-nav .back:hover { background: var(--paper-2); }
.step-nav .back .ico { transform: scaleX(-1); }
.step-nav .back:hover .ico { transform: scaleX(-1) translateX(3px); }
.step-nav .spacer { flex: 1; }
.save-note { margin-top: 18px; font-size: 12px; color: var(--ink-3); display: flex; gap: .4em; align-items: center; }
.save-note .ico { width: 1em; height: 1em; }
@media (max-width: 720px) {
  .step-nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; margin: 0; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: color-mix(in srgb, var(--paper) 95%, transparent); backdrop-filter: blur(8px); border-top: 1px solid var(--line); }
  .step-nav .button { min-width: 0; flex: 1; min-height: 52px; font-size: 16px; padding-inline: 1em; }
  .step-nav .back { flex: 0 0 auto; }
  .step-nav .spacer { display: none; }
}
@media (forced-colors: active) { .choice input:checked + span { outline: 3px solid CanvasText; } .button { border: 1px solid ButtonText; } }

/* 選択工事の追加質問は既存配色・入力幅に合わせる。 */
.cost-work{margin:1.2rem 0;padding-top:1rem;border-top:1px solid #ddd7ca}.cost-work h4{margin:0 0 .65rem}.cost-work select,.cost-work input,#cost-area{max-width:100%;width:100%;box-sizing:border-box}.repair-note{border-left:3px solid #B49765;padding-left:1rem}#cost-questions small{display:block;line-height:1.7;color:#51575d}

/* ── iframe に埋め込んだときだけ（html.is-embedded は reform-lp-client.js が iframe の中でだけ付ける。2026-10-19 ゼロ決定）
   iframe の中では position:fixed が iframe の一番下に貼り付き、中身から離れて見えなくなる。
   下の固定 CTA は出さず、段の下のボタンはページの流れの中に置く。直接開いたときの見た目は上の既存ルールのまま変えない */
html.is-embedded .sticky-cta { display: none; }
@media (max-width: 720px) {
  html.is-embedded body.has-sticky .site-footer { padding-bottom: calc(48px + env(safe-area-inset-bottom)); }
  html.is-embedded .step-nav { position: static; margin-top: 32px; padding: 0; background: none; backdrop-filter: none; border-top: 0; }
}
