/* 外壁塗装の費用ナビ — 「信頼できる帳票」
   紙色の下地に墨の文字。見出しと数字は明朝、本文はUD書体。アクセントは深緑1色、CTAは朱1色。 */
:root {
  --paper: #f6f3ec; --paper-2: #efe9dc; --ink: #1e2a2b; --ink-2: #3e4c4e; --muted: #5c6b6d; --line: #ddd6c8;
  --green: #1c6b52; --green-dark: #14503d; --green-soft: #e4efe9;
  --cta: #d9531e; --cta-dark: #b8421a; --cta-soft: #fbe9dd;
  --serif: "Shippori Mincho B1", "Hiragino Mincho ProN", "Yu Mincho", "MS PMincho", serif;
  --sans: "BIZ UDPGothic", "Hiragino Sans", "Yu Gothic", "Meiryo", sans-serif;
  --wrap: 1200px; --radius: 8px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); line-height: 1.85; font-size: 16px; }
a { color: var(--green); text-decoration: none; }
a:hover { color: var(--green-dark); text-decoration: underline; }
img { max-width: 100%; height: auto; }
.serif, h1, h2, h3, .num { font-family: var(--serif); font-feature-settings: "tnum" 1; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 16px; }
.label { font-size: 12px; letter-spacing: .08em; color: var(--muted); font-weight: 700; }

/* ヘッダー / フッター */
.site-header { border-bottom: 1px solid var(--line); background: var(--paper); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; }
.brand { display: flex; align-items: baseline; gap: 12px; color: var(--ink); }
.brand a { color: var(--ink); font-family: var(--serif); font-size: 21px; font-weight: 800; letter-spacing: .02em; }
.brand a:hover { text-decoration: none; }
.brand .tagline { font-size: 12px; color: var(--muted); }
.site-nav { display: flex; gap: 22px; font-size: 14px; font-weight: 700; }
.site-nav a { color: var(--ink); display: inline-flex; align-items: center; gap: 6px; }
.site-nav a.tool { color: var(--green); }
.site-nav svg { width: 18px; height: 18px; }
.site-footer { margin-top: 56px; background: var(--ink); color: #cfd6d3; font-size: 13px; }
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 12px 28px; align-items: center; justify-content: space-between; padding-block: 28px; }
.site-footer .brand a { color: #fff; font-size: 18px; }
.site-footer a { color: #cfd6d3; }
.site-footer nav { display: flex; gap: 20px; }

/* ボタン・チップ */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 0 24px; border-radius: 6px; font-weight: 700; font-size: 16px; text-align: center; }
.btn:hover { text-decoration: none; }
.btn-cta { background: var(--cta); color: #fff; box-shadow: 0 2px 0 var(--cta-dark); }
.btn-cta:hover { background: var(--cta-dark); color: #fff; }
.btn-ghost { background: #fff; color: var(--green); border: 1.5px solid var(--green); }
.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 24px; padding: 0 9px; border-radius: 999px; font-size: 12px; font-weight: 700; line-height: 1; white-space: nowrap; }
.chip-src { background: var(--green-soft); color: var(--green); }
.chip-sub { background: var(--cta-soft); color: var(--cta-dark); }
.chip-est { background: var(--paper-2); color: var(--muted); }
/* 印章風の出典バッジ（他サイトと被らない要素） */
.stamp { display: inline-block; border: 1.5px solid var(--green); color: var(--green); border-radius: 3px; padding: 0 6px; font-size: 11px; letter-spacing: .12em; font-weight: 700; line-height: 1.6; transform: rotate(-2deg); }

/* トップページ */
.hero { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px; padding-block: 48px 32px; align-items: start; }
.hero h1 { margin: 0; font-size: 38px; line-height: 1.35; font-weight: 800; text-wrap: pretty; }
.hero .lead { margin: 0; font-size: 17px; color: var(--ink-2); text-wrap: pretty; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; }
.trust { display: flex; flex-wrap: wrap; gap: 10px 22px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 14px; color: var(--ink-2); }
.trust span { display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; }
.trust svg { width: 20px; height: 20px; stroke: var(--green); }
.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: 0 12px 32px rgba(30,42,43,.06); display: flex; flex-direction: column; gap: 14px; }
.panel h2 { margin: 0; font-size: 20px; }
.panel .num { font-size: 32px; font-weight: 800; }
.section-title { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin: 32px 0 14px; }
.section-title h2 { margin: 0; font-size: 24px; font-weight: 800; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.cards.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.card { display: flex; flex-direction: column; gap: 8px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; color: var(--ink); }
.card:hover { text-decoration: none; border-color: var(--green); }
.card h3 { margin: 0; font-size: 18px; line-height: 1.5; font-weight: 800; }
.card p { margin: 0; font-size: 14px; color: var(--ink-2); }
.card .chips { display: flex; flex-wrap: wrap; gap: 6px; }

/* 記事ページ: PC は 目次 | 本文 | CTA の3カラム */
.article-layout { display: grid; grid-template-columns: 200px minmax(0, 1fr) 280px; gap: 40px; padding-block: 32px; align-items: start; }
.rail { position: sticky; top: 20px; display: flex; flex-direction: column; gap: 14px; }
.toc-rail { font-size: 14px; }
.toc-rail .toc-title { margin: 0 0 4px; }
.toc-rail ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.toc-rail ul ul { padding-left: 12px; margin-top: 8px; font-size: 13px; }
.toc-rail a { color: var(--ink-2); border-left: 3px solid transparent; padding-left: 10px; display: block; line-height: 1.5; }
.toc-rail a:hover { color: var(--green); border-left-color: var(--green); text-decoration: none; }
.cta-card { background: #fff; border: 1px solid var(--line); border-top: 4px solid var(--cta); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.cta-card .serif { font-size: 19px; font-weight: 800; line-height: 1.4; }
.cta-card p { margin: 0; font-size: 13px; color: var(--ink-2); }
.rail .card { flex-direction: row; align-items: center; gap: 12px; }
.rail .card svg { width: 28px; height: 28px; flex-shrink: 0; }
.rail .card span { display: flex; flex-direction: column; font-size: 13px; color: var(--muted); }
.rail .card strong { color: var(--ink); font-size: 15px; }

.article { min-width: 0; display: flex; flex-direction: column; gap: 22px; }
.breadcrumb { font-size: 13px; color: var(--muted); }
.breadcrumb a { color: var(--muted); }
.pr-notice, .body .pr-notice { margin: 0 0 10px; font-size: 12px; letter-spacing: .06em; color: var(--muted); font-weight: 700; }
.article h1 { margin: 0; font-size: 32px; line-height: 1.4; font-weight: 800; text-wrap: pretty; }
.meta { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 13px; color: var(--muted); }
/* 根拠バー */
.evidence { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; }
.evidence a { margin-left: auto; font-size: 13px; font-weight: 700; }
/* 結論ブロック: 二重罫線の帳票 */
.conclusion { border-top: 3px double var(--ink); border-bottom: 1px solid var(--line); padding: 18px 4px 16px; display: flex; flex-direction: column; gap: 8px; }
.conclusion .row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px 14px; }
.conclusion .num { font-size: 36px; font-weight: 800; line-height: 1.2; }
.conclusion .cond { font-size: 15px; color: var(--ink-2); }
.conclusion p { margin: 0; font-size: 16px; }
.conclusion .src { font-size: 12px; color: var(--muted); }

/* 本文 */
.body { counter-reset: sec; }
.body h2 { counter-increment: sec; margin: 40px 0 12px; padding: 0 0 8px; border-bottom: 2px solid var(--ink); font-size: 24px; font-weight: 800; line-height: 1.4; display: flex; align-items: baseline; gap: 12px; }
.body h2::before { content: counter(sec, decimal-leading-zero); font-size: 13px; letter-spacing: .12em; color: var(--green); font-family: var(--serif); }
.body h3 { margin: 26px 0 8px; font-size: 18px; font-weight: 800; }
.body p { margin: 0 0 14px; font-size: 16px; text-wrap: pretty; }
.body ul, .body ol { padding-left: 1.4em; margin: 0 0 14px; }
.body li { margin: 4px 0; }
.body table { border-collapse: collapse; width: 100%; font-size: 15px; background: #fff; display: block; overflow-x: auto; margin: 0 0 8px; }
.body th, .body td { border-bottom: 1px solid var(--line); padding: 10px 12px; text-align: left; vertical-align: top; white-space: nowrap; }
.body th { background: var(--paper-2); font-size: 13px; letter-spacing: .04em; }
.body td:first-child { white-space: normal; min-width: 8em; }
.body blockquote { margin: 0 0 14px; padding: 10px 14px; border-left: 2px solid var(--line); color: var(--ink-2); font-size: 15px; }
.body blockquote p { margin: 0; }
.body hr { border: 0; border-top: 1px solid var(--line); margin: 24px 0; }
/* 出典の一行（「（出典: …）」を含む文）は小さく */
.body .src-line { font-size: 13px; color: var(--muted); }
/* 本文中の出典はドメイン名の小さなリンクに畳む（生 URL を並べない） */
.body .cite { font-size: 0.82em; color: var(--muted); white-space: nowrap; }
.body .cite a { color: var(--muted); text-decoration: underline dotted; text-underline-offset: 2px; }
.body .cite a:hover { color: var(--green); }
/* CTA 帯（本文中の CTA 引用ブロックを render.py で変換） */
.cta-band { margin: 20px 0; background: var(--ink); color: #fff; border-radius: var(--radius); padding: 20px 22px; display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 14px 20px; align-items: center; }
.cta-band .t { font-family: var(--serif); font-size: 19px; font-weight: 800; line-height: 1.4; }
.cta-band .s { font-size: 13px; color: #cfd6d3; }
.cta-band .btn { white-space: nowrap; }
/* FAQ: h3 を行に */
.body h3.faq-q { margin: 0; padding: 12px 14px; background: #fff; border: 1px solid var(--line); border-bottom: 0; font-size: 16px; }
.body h3.faq-q + p { margin: 0; padding: 12px 14px 16px; background: #fff; border: 1px solid var(--line); border-top: 0; margin-bottom: 8px; font-size: 15px; }
/* 執筆者・関連・出典 */
.author { display: flex; gap: 14px; align-items: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; }
.author .avatar { width: 52px; height: 52px; border-radius: 50%; background: var(--green-soft); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.tools-box { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; background: #fff; }
.tools-box ul { margin: 6px 0 0; padding-left: 1.2em; }

/* 固定 CTA バー（スマホ） */
.sticky-cta { display: none; }

/* シミュレーター */
.sim-layout { display: grid; grid-template-columns: 400px minmax(0, 1fr); gap: 28px; align-items: start; margin-top: 24px; }
.sim { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; display: flex; flex-direction: column; gap: 16px; }
.sim label { display: flex; flex-direction: column; gap: 6px; font-size: 12px; letter-spacing: .08em; color: var(--muted); font-weight: 700; }
.sim input, .sim select { height: 50px; border: 1.5px solid #cfc6b4; border-radius: 6px; background: #fff; padding: 0 12px; font-size: 16px; font-family: var(--sans); color: var(--ink); }
.sim .hint { font-size: 12px; color: var(--muted); font-weight: 400; letter-spacing: 0; }
.sim button { min-height: 52px; background: var(--green); color: #fff; border: 0; border-radius: 6px; font-size: 16px; font-weight: 700; font-family: var(--sans); cursor: pointer; }
.sim button:hover { background: var(--green-dark); }
.result { display: flex; flex-direction: column; gap: 14px; }
.result-card { background: #fff; border: 1px solid var(--line); border-top: 5px solid var(--green); border-radius: var(--radius); padding: 22px 24px; display: flex; flex-direction: column; gap: 10px; }
.result-card .big { font-family: var(--serif); font-size: 40px; font-weight: 800; line-height: 1.1; }
.result-card .basis { font-size: 13px; color: var(--muted); }
.result-card h3 { margin: 8px 0 0; font-size: 16px; }
.sub-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; background: var(--paper); border-radius: 6px; padding: 10px 14px; }
.sub-row .amt { font-family: var(--serif); font-size: 20px; font-weight: 800; color: var(--cta-dark); white-space: nowrap; }
.result-card .net { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; }
.result-card .net .num { font-size: 26px; font-weight: 800; }
.refs { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 20px; }
.refs .row { display: flex; justify-content: space-between; gap: 12px; font-size: 15px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.refs .row:last-child { border-bottom: 0; }
.examples table { border-collapse: collapse; width: 100%; font-size: 15px; background: #fff; display: block; overflow-x: auto; }
.examples th, .examples td { border-bottom: 1px solid var(--line); padding: 10px 12px; text-align: left; white-space: nowrap; }
.examples th { background: var(--paper-2); font-size: 13px; }
.examples tr.hl { background: var(--green-soft); }

/* 404 / 方針ページ */
.prose { max-width: 760px; }
.prose h1 { font-size: 30px; }
.prose h2 { font-size: 22px; margin-top: 32px; }

/* レスポンシブ */
@media (max-width: 1000px) {
  .hero { grid-template-columns: 1fr; gap: 28px; }
  .cards, .cards.four { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-layout { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .rail { position: static; }
  .toc-rail { order: 2; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; }
  .cta-rail { order: 3; }
  .article { order: 1; }
  .sim-layout { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  body { font-size: 15px; }
  .site-header .wrap { min-height: 56px; }
  .brand .tagline, .site-nav { display: none; }
  .hero { padding-block: 28px 16px; }
  .hero h1 { font-size: 27px; }
  .cards, .cards.four { grid-template-columns: 1fr; }
  .article h1 { font-size: 24px; }
  .conclusion .num { font-size: 30px; }
  .body h2 { font-size: 20px; }
  .cta-band { grid-template-columns: 1fr; }
  .cta-rail .cta-card { display: none; }
  .sticky-cta { display: flex; flex-direction: column; gap: 6px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; background: #fff; border-top: 1px solid var(--line); padding: 10px 16px calc(14px + env(safe-area-inset-bottom)); box-shadow: 0 -8px 24px rgba(30,42,43,.08); }
  .sticky-cta span { font-size: 12px; color: var(--muted); }
  .has-sticky { padding-bottom: 120px; }
  .site-footer .wrap { flex-direction: column; align-items: flex-start; }
  .result-card .big { font-size: 32px; }
}

/* Reader-first navigation and conversion layout */
:root { --paper:#f4f7f6; --paper-2:#eaf0ed; --line:#d3ded8; --cta:#b64019; --cta-dark:#933013; }
html { scroll-padding-top:1.5rem; }
body { font-size:1rem; }
[hidden] { display:none !important; }
a, button, input, select, summary { -webkit-tap-highlight-color:transparent; }
:focus-visible { outline:3px solid #196da1; outline-offset:4px; }
.skip-link { position:fixed; top:8px; left:8px; z-index:100; padding:12px 20px; background:white; transform:translateY(-160%); }
.skip-link:focus { transform:none; }
.label, .sim label { font-size:.875rem; letter-spacing:.025em; }
.site-header { background:#fff; border-top:4px solid var(--green); }
.site-header .wrap { min-height:84px; }
.brand { flex-wrap:wrap; gap:0 12px; }
.site-nav { gap:20px; flex-wrap:wrap; }
.site-nav a { min-height:44px; }
.hero { padding-block:40px 24px; gap:36px; grid-template-columns:minmax(0,1.2fr) minmax(0,1fr); }
.hero-simple { grid-template-columns:1fr; max-width:900px; }
.hero h1 { font-size:clamp(1.75rem,3.2vw,2.65rem); line-height:1.55; }
.hero .lead { font-size:1rem; }
.btn { padding:12px 20px; line-height:1.6; }
.btn-primary { background:var(--green); color:#fff; }
.btn-primary:hover { background:var(--green-dark); color:#fff; }
.panel { border-top:4px solid var(--green); box-shadow:0 8px 24px #173e2710; }
.panel .num { font-size:clamp(1.75rem,3vw,2.4rem); }
.trust { font-size:.875rem; gap:8px 16px; }
.trust span { white-space:normal; }
.trust svg { flex-shrink:0; }
.disclosure { margin:0; font-size:.8125rem; color:var(--muted); }
.disclosure a, .pr-notice a, .body a:not(.btn), .tools-box a { text-decoration:underline; text-underline-offset:3px; }
.section-title { flex-wrap:wrap; }
.card { padding:22px; transition:border-color .15s,box-shadow .15s; }
.card:hover { box-shadow:0 4px 18px #173e2712; }
.card h3 { font-family:var(--sans); }
.card p { font-size:1rem; }
.post-card .card-read { margin-top:auto; padding-top:12px; color:var(--green); font-weight:700; font-size:.875rem; }
.post-card .chips { order:2; }
.post-card .card-read { order:3; }
.decision-box { margin-top:36px; padding:28px; display:grid; grid-template-columns:minmax(0,1fr) auto; gap:24px; align-items:center; background:white; border:1px solid var(--line); border-left:4px solid var(--cta); border-radius:8px; }
.decision-box h2 { margin:6px 0 10px; font-size:1.5rem; }
.decision-box p { margin:0; color:var(--ink-2); }
.decision-action { display:flex; flex-direction:column; gap:8px; text-align:center; }
.article-layout { grid-template-columns:170px minmax(0,1fr) 240px; gap:24px; }
.article { overflow-wrap:anywhere; }
.article h1 { font-size:clamp(1.5rem,2.5vw,2rem); line-height:1.6; }
.body { line-height:2; }
.body h2 { line-height:1.65; }
.conclusion { background:white; border:1px solid var(--line); border-top:4px solid var(--green); border-radius:8px; padding:24px; }
.cta-card p, .rail .card span { font-size:.875rem; }
.toc-rail { max-height:calc(100dvh - 40px); overflow-y:auto; }
.toc-rail a { padding-block:6px; }
.mobile-toc { display:none; }
.pr-notice { font-size:.8125rem; }
.sim label { color:var(--ink-2); }
.sim-layout > *, .hero > * { min-width:0; }
.body table, .examples table { overscroll-behavior-x:contain; }
@media (min-width:1001px) and (max-width:1199px) { .article-layout { grid-template-columns:minmax(0,1fr) 250px; } .toc-rail { display:none; } .mobile-toc { display:block; } }
@media (max-width:1000px) {
  .hero { grid-template-columns:1fr; gap:24px; }
  .article-layout { grid-template-columns:minmax(0,1fr); }
  .toc-rail { display:none; }
  .mobile-toc { display:block; }
  .decision-box { grid-template-columns:1fr; }
  .decision-action { align-items:flex-start; text-align:left; }
}
.mobile-toc { background:white; border:1px solid var(--line); padding:14px 18px; border-radius:8px; }
.mobile-toc summary { font-weight:700; cursor:pointer; min-height:32px; color:var(--green); }
.mobile-toc ul { padding-left:20px; }
.mobile-toc a { display:inline-block; padding-block:6px; }
@media (max-width:640px) {
  .site-header .wrap { flex-direction:column; align-items:flex-start; padding-top:12px; gap:4px; }
  .site-nav { display:flex; width:100%; gap:4px 18px; font-size:.875rem; }
  .site-nav svg { display:none; }
  .site-nav a { min-height:44px; }
  .brand a { font-size:1.2rem; }
  .hero { padding-top:24px; }
  .hero .actions { flex-direction:column; }
  .hero .actions .btn { width:100%; }
  .panel { padding:20px; }
  .trust { gap:8px; }
  .section-title h2 { font-size:1.35rem; }
  .decision-box { padding:20px; }
  .decision-action, .decision-action .btn { width:100%; }
  .cta-rail .cta-card { display:flex; }
  .sticky-cta { position:static; margin:24px 16px; border:1px solid var(--line); box-shadow:none; border-radius:8px; }
  .sticky-back { padding:8px 0; }
  .has-sticky { padding-bottom:0; }
  .conclusion { padding:18px; }
  .site-footer { margin-top:32px; }
}
@media (prefers-reduced-motion:reduce) { *, *::before, *::after { scroll-behavior:auto !important; transition:none !important; } }

.cards { grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr)); }
.cards.four { grid-template-columns:repeat(auto-fit,minmax(min(100%,240px),1fr)); }
.card:only-child { max-width:760px; }
.hero h1 { font-size:clamp(1.75rem,3vw,2.4rem); }
