/* =============================================================================
   スマイエ — 汎用ファセット検索（不動産デモ）
   白ベース × ライトブルー（水色〜シアン寄りの青・hue 190〜210°）
   青紫系（hue 230°以上）は不使用。アクセントに琥珀・コーラルを少量。
   ========================================================================== */

:root {
  --accent: #1795d4;        /* ライトブルー（主） */
  --accent-dark: #0f76ab;   /* リンク・hover */
  --accent-deep: #0d4d70;   /* 見出し等の濃色（青のまま暗く） */
  --accent-pale: #e8f5fc;   /* 淡い水色地 */
  --ink: #22333f;
  --muted: #64798a;
  --line: #d9e6ee;
  --bg: #f5fafd;
  --white: #ffffff;
  --price: #e0592b;         /* 価格＝コーラル */
  --amber: #eda53c;         /* フォーカス・PICK UP */
  --heart: #e6485f;         /* お気に入り */
  --radius: 10px;
  --shadow: 0 1px 3px rgba(20, 50, 70, 0.07), 0 4px 14px rgba(20, 50, 70, 0.05);
  --font: "Noto Sans JP", "Hiragino Kaku Gothic ProN", "Hiragino Sans", "Yu Gothic UI", "Yu Gothic", Meiryo, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 64px; }
body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--accent-dark); }

.container { max-width: 1160px; margin: 0 auto; padding: 0 20px; }

/* ---------------------------------------------------------------------------
   ボタン
--------------------------------------------------------------------------- */
.btn {
  display: inline-block;
  padding: 12px 26px;
  border-radius: 999px;
  border: none;
  font-size: 15px;
  font-weight: 700;
  font-family: inherit;
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: background-color 0.15s, transform 0.1s, box-shadow 0.15s;
}
.btn--primary { background: var(--accent); color: #fff; box-shadow: 0 3px 10px rgba(23, 149, 212, 0.32); }
.btn--primary:hover { background: var(--accent-dark); }
.btn--primary:active { transform: translateY(1px); }
.btn--ghost { background: rgba(255, 255, 255, 0.85); color: var(--accent-dark); border: 1.5px solid var(--accent); padding: 10.5px 26px; }
.btn--ghost:hover { background: #fff; }
.btn--sm { padding: 6px 14px; font-size: 13px; background: var(--accent); color: #fff; border-radius: 6px; }

/* ---------------------------------------------------------------------------
   ヘッダー
--------------------------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 60px; }
.brand { display: flex; align-items: baseline; gap: 8px; text-decoration: none; color: var(--ink); }
.brand-mark { width: 26px; height: 26px; fill: var(--accent); align-self: center; }
.brand-name { font-size: 22px; font-weight: 900; letter-spacing: 0.06em; }
.brand-sub { font-size: 10px; letter-spacing: 0.28em; color: var(--muted); font-weight: 600; }
.global-nav { display: flex; align-items: center; gap: 20px; }
.global-nav a { font-size: 14px; font-weight: 600; color: var(--ink); text-decoration: none; }
.global-nav a:hover { color: var(--accent-dark); }
.global-nav .nav-cta {
  background: var(--accent);
  color: #fff;
  padding: 8px 18px;
  border-radius: 999px;
  transition: background-color 0.15s;
}
.global-nav .nav-cta:hover { background: var(--accent-dark); color: #fff; }

/* お気に入りリンク（件数バッジは site.js が localStorage から更新） */
.nav-fav { display: inline-flex; align-items: center; gap: 5px; }
.fav-ico { width: 16px; height: 16px; flex: none; }
.fav-ico path { fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.fav-badge {
  background: var(--heart);
  color: #fff;
  font-size: 10.5px;
  font-weight: 700;
  min-width: 17px;
  height: 17px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 4px;
}
.fav-badge:empty { display: none; }

/* ---------------------------------------------------------------------------
   ヒーロー（ファーストビュー）— 明るいオーバーレイ＋ダークインクの文字
--------------------------------------------------------------------------- */
.hero {
  position: relative;
  background: url("/assets/img/hero.jpg") center 38% / cover no-repeat;
  color: var(--ink);
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg,
    rgba(255, 255, 255, 0.94) 0%,
    rgba(255, 255, 255, 0.78) 42%,
    rgba(245, 250, 253, 0.22) 74%,
    rgba(245, 250, 253, 0) 100%);
}
.hero-inner { position: relative; padding: 88px 20px 72px; max-width: 1160px; }
.hero-eyebrow {
  display: inline-block;
  margin: 0 0 14px;
  padding: 5px 14px;
  border: 1px solid rgba(15, 118, 171, 0.4);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.6);
  color: var(--accent-dark);
  font-size: 12.5px;
  font-weight: 600;
  letter-spacing: 0.12em;
}
.hero-title {
  margin: 0 0 18px;
  font-size: clamp(30px, 4.6vw, 50px);
  font-weight: 900;
  line-height: 1.32;
  letter-spacing: 0.04em;
  color: var(--accent-deep);
  text-shadow: 0 1px 16px rgba(255, 255, 255, 0.85);
}
.hero-lead {
  margin: 0 0 28px;
  max-width: 34em;
  font-size: 15.5px;
  line-height: 1.9;
  color: #33505f;
  text-shadow: 0 1px 10px rgba(255, 255, 255, 0.8);
}
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 26px; }
.hero-scroll { color: var(--accent-dark); font-size: 13.5px; font-weight: 600; text-decoration: none; border-bottom: 1px solid rgba(15, 118, 171, 0.45); padding-bottom: 2px; }
.hero-scroll:hover { border-bottom-color: var(--accent-dark); }

/* 実績バンド — 淡い水色地に青の数字 */
.stats-band {
  background: linear-gradient(180deg, #e9f5fc, #ddeffa);
  color: var(--accent-deep);
  border-top: 1px solid #d3e8f4;
  border-bottom: 1px solid #d3e8f4;
}
.stats-inner { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; padding: 18px 20px; }
.stat { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 2px; padding: 6px 4px; }
.stat strong { font-size: 24px; font-weight: 900; letter-spacing: 0.02em; color: var(--accent-dark); line-height: 1.2; }
.stat strong small { font-size: 14px; margin-left: 1px; }
.stat span { font-size: 11.5px; color: #4b6b80; }

/* ---------------------------------------------------------------------------
   検索セクション レイアウト
--------------------------------------------------------------------------- */
.search-section { padding: 34px 0 60px; }
.search-layout { display: grid; grid-template-columns: 292px minmax(0, 1fr); gap: 24px; align-items: start; }

/* ---- 条件パネル ---- */
.filter-col {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.filter-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px;
  background: linear-gradient(135deg, #e8f5fc, #d8edf9);
  color: var(--accent-deep);
  font-weight: 700;
  font-size: 14.5px;
}
.drawer-close { display: none; cursor: pointer; font-size: 22px; line-height: 1; padding: 0 4px; }

.facet { border: none; border-top: 1px solid var(--line); margin: 0; padding: 14px 16px 16px; min-width: 0; }
.facet:first-of-type { border-top: none; }
.facet-label { font-size: 13.5px; font-weight: 700; color: var(--accent-deep); padding: 0; margin-bottom: 2px; }
.facet-help { margin: 8px 0 0; font-size: 11.5px; color: var(--muted); }

/* AND/OR 切替トグル */
.match-toggle {
  display: flex;
  margin: 8px 0 10px;
  border: 1px solid var(--accent);
  border-radius: 7px;
  overflow: hidden;
}
.match-opt { flex: 1; }
.match-opt input { position: absolute; opacity: 0; pointer-events: none; }
.match-face {
  display: block;
  padding: 6px 4px;
  text-align: center;
  font-size: 12px;
  font-weight: 600;
  color: var(--accent-dark);
  background: #fff;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}
.match-opt + .match-opt .match-face { border-left: 1px solid var(--accent); }
.match-opt input:checked + .match-face { background: var(--accent); color: #fff; }
.match-opt input:focus-visible + .match-face { outline: 2px solid var(--amber); outline-offset: -2px; }

/* 選択肢（チェックボックス型） */
.opts { display: flex; flex-direction: column; gap: 2px; margin-top: 8px; }
.opt { display: block; cursor: pointer; transition: opacity 0.2s; }
.opt.is-zero { opacity: 0.42; }
.opt--checkbox input { position: absolute; opacity: 0; pointer-events: none; }
.opt--checkbox .opt-face {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 6px;
  border-radius: 6px;
  font-size: 13px;
  transition: background-color 0.12s;
}
.opt--checkbox .opt-face:hover { background: var(--accent-pale); }
.opt--checkbox .opt-face::before {
  content: "";
  flex: none;
  width: 16px;
  height: 16px;
  border: 1.5px solid #a9c3d4;
  border-radius: 4px;
  background: #fff center / 11px no-repeat;
  transition: background-color 0.12s, border-color 0.12s;
}
.opt--checkbox input:checked + .opt-face::before {
  background-color: var(--accent);
  border-color: var(--accent);
  background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 12 12"><path fill="none" stroke="white" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" d="M2 6.2 4.8 9 10 3.4"/></svg>');
}
.opt--checkbox input:checked + .opt-face { color: var(--accent-dark); font-weight: 600; }
.opt--checkbox input:focus-visible + .opt-face { outline: 2px solid var(--amber); outline-offset: -2px; }
.opt-text { flex: 1; min-width: 0; }

/* 選択肢（ボタン型） */
.opts--button { flex-direction: row; flex-wrap: wrap; gap: 6px; }
.opt--button input { position: absolute; opacity: 0; pointer-events: none; }
.opt--button .opt-face {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 11px;
  border: 1px solid #a9c3d4;
  border-radius: 999px;
  background: #fff;
  font-size: 12.5px;
  font-weight: 600;
  transition: background-color 0.12s, border-color 0.12s, color 0.12s, box-shadow 0.12s;
}
.opt--button .opt-face:hover { border-color: var(--accent); }
.opt--button input:checked + .opt-face {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 2px 6px rgba(23, 149, 212, 0.35);
}
.opt--button input:focus-visible + .opt-face { outline: 2px solid var(--amber); outline-offset: 1px; }

/* 件数表示（数字がスッと変わる） */
.opt-count { font-size: 11px; color: var(--muted); font-weight: 500; transition: color 0.2s; }
.opt-count::before { content: "("; }
.opt-count::after { content: ")"; }
.opt--button input:checked + .opt-face .opt-count { color: rgba(255, 255, 255, 0.85); }
.opt--checkbox .opt-count { margin-left: auto; }

/* グループ折りたたみ（駅・こだわり等） */
.opt-groups { margin-top: 8px; display: flex; flex-direction: column; gap: 4px; }
.opt-group { border: 1px solid var(--line); border-radius: 7px; background: #fafdff; }
.opt-group-head {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 10px;
  font-size: 12.5px;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
  user-select: none;
}
.opt-group-head::-webkit-details-marker { display: none; }
.opt-group-head::before {
  content: "";
  width: 8px;
  height: 8px;
  border-right: 2px solid var(--accent);
  border-bottom: 2px solid var(--accent);
  transform: rotate(-45deg);
  transition: transform 0.15s;
  flex: none;
}
.opt-group[open] > .opt-group-head::before { transform: rotate(45deg); margin-top: -3px; }
.opt-group-n { margin-left: auto; font-size: 11px; font-weight: 500; color: var(--muted); }
.opt-group .opts { padding: 0 8px 8px; margin-top: 0; }

/* セレクト・範囲 */
.facet-select {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid #a9c3d4;
  border-radius: 7px;
  background: #fff;
  font-size: 13px;
  font-family: inherit;
  color: var(--ink);
  margin-top: 8px;
}
.facet-select:focus-visible { outline: 2px solid var(--amber); }
.range-row { display: flex; align-items: center; gap: 6px; }
.range-row .facet-select { flex: 1; min-width: 0; }
.range-sep { color: var(--muted); flex: none; margin-top: 8px; }

/* パネル下部のアクション */
.filter-actions {
  position: sticky;
  bottom: 0;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.96);
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: center;
}
.btn--apply { width: 100%; padding: 12px 10px; font-size: 14px; }
.filter-reset { font-size: 12.5px; color: var(--muted); }

/* ---------------------------------------------------------------------------
   結果カラム
--------------------------------------------------------------------------- */
.result-col { position: relative; min-width: 0; }

/* 該当件数＋並び替え＝スクロールしても見えるように sticky（デスクトップ） */
.result-toolbar {
  position: sticky;
  top: 60px;   /* ヘッダー（60px）の直下に貼り付く。白背景＋枠＋影で重なりを整える */
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 12px 18px;
  margin-bottom: 12px;
}
.result-summary { margin: 0; display: flex; align-items: baseline; gap: 5px; font-size: 13.5px; }
.sum-total { font-size: 26px; font-weight: 900; color: var(--accent-dark); letter-spacing: 0.01em; line-height: 1; }
.sum-unit { font-weight: 700; }
.sum-range { color: var(--muted); font-size: 12px; margin-left: 6px; }
.sort-form { display: flex; align-items: center; gap: 8px; }
.sort-label { font-size: 12.5px; color: var(--muted); flex: none; }
.sort-select { width: auto; margin-top: 0; min-width: 160px; }

/* チップ */
.chips { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; margin: 0 2px 14px; }
.chips:empty { display: none; }
.chips-caption { font-size: 12px; color: var(--muted); margin-right: 2px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 11px;
  background: var(--accent-pale);
  border: 1px solid #bfe0f2;
  border-radius: 999px;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--accent-deep);
  text-decoration: none;
  transition: background-color 0.12s, border-color 0.12s;
}
.chip:hover { background: #d7edf9; border-color: var(--accent); }
.chip-x { color: var(--accent-dark); font-weight: 700; }
.chip--clear { background: #fff; border-color: #ccc; color: var(--muted); }
.chip--clear:hover { border-color: var(--muted); background: #f2f2f2; }

/* ローディング（控えめ：上部プログレスバー＋結果の減光） */
.result-col::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: linear-gradient(90deg, var(--accent), var(--amber));
  border-radius: 3px;
  opacity: 0;
  z-index: 6;
  transition: opacity 0.15s;
}
.result-col.is-loading::before { opacity: 1; animation: loadbar 1s ease-in-out infinite; }
@keyframes loadbar {
  0% { width: 0; margin-left: 0; }
  55% { width: 62%; margin-left: 18%; }
  100% { width: 0; margin-left: 100%; }
}
.result-col.is-loading .cards { opacity: 0.55; }
.cards { transition: opacity 0.18s; }

/* ---------------------------------------------------------------------------
   物件カード
--------------------------------------------------------------------------- */
.card {
  position: relative;
  display: flex;
  gap: 18px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 14px;
  margin-bottom: 14px;
  transition: box-shadow 0.15s, transform 0.15s;
}
.card:hover { box-shadow: 0 4px 8px rgba(20, 50, 70, 0.12), 0 10px 26px rgba(20, 50, 70, 0.1); transform: translateY(-1px); }
.card-media { position: relative; flex: none; width: 236px; border-radius: 8px; overflow: hidden; align-self: flex-start; }
.card-media img { width: 100%; height: 158px; object-fit: cover; }
.card-badges { position: absolute; top: 8px; left: 8px; display: flex; gap: 5px; }
.badge {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.05em;
  padding: 3px 8px;
  border-radius: 4px;
  color: #fff;
  background: var(--accent);
}
.badge--sale { background: #c1671f; }
.badge--new { background: var(--price); }
.badge--featured { background: var(--amber); color: #4a3005; }
.card-body { flex: 1; min-width: 0; }
.card-tags { display: flex; gap: 6px; margin-bottom: 3px; }
.ptype {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--accent-dark);
  border: 1px solid var(--accent);
  border-radius: 4px;
  padding: 1px 7px;
}
.ptype--movein { color: #9a5b12; border-color: var(--amber); }
.card-title {
  margin: 2px 0 4px;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.45;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
/* カード全体をリンクに（stretched link）。お気に入りボタンは z-index 上 */
.card-title .card-link { color: var(--ink); text-decoration: none; }
.card-link::after { content: ""; position: absolute; inset: 0; border-radius: var(--radius); }
.card:hover .card-title .card-link { color: var(--accent-dark); text-decoration: underline; }
.card-price { margin: 0 0 2px; display: flex; align-items: baseline; gap: 4px; flex-wrap: wrap; }
.price-num { font-size: 25px; font-weight: 900; color: var(--price); line-height: 1.2; }
.price-num--sale { font-size: 21px; }
.price-unit { font-size: 13px; font-weight: 800; color: var(--price); }
.price-sub { font-size: 11.5px; color: var(--muted); margin-left: 6px; }
.card-money { margin: 0 0 6px; font-size: 12px; color: var(--muted); }
.money-sep { margin: 0 4px; color: #bcd2e0; }
.card-specs { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 0; margin: 0 0 6px; padding: 0; font-size: 12.5px; }
.card-specs li { padding: 0 10px; border-left: 1px solid var(--line); }
.card-specs li:first-child { padding-left: 0; border-left: none; }
.card-access { margin: 0; font-size: 12.5px; font-weight: 600; }
.card-address { margin: 0 0 7px; font-size: 11.5px; color: var(--muted); }
.card-feats { display: flex; flex-wrap: wrap; gap: 5px; }
.fbadge {
  font-size: 10.5px;
  font-weight: 600;
  color: var(--accent-deep);
  background: var(--accent-pale);
  border-radius: 4px;
  padding: 2px 8px;
}
.fbadge--more { background: #eef1f3; color: var(--muted); }

/* ---------------------------------------------------------------------------
   お気に入り（ハート）ボタン
--------------------------------------------------------------------------- */
.fav-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 3;
  width: 36px;
  height: 36px;
  padding: 0;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 1px 4px rgba(13, 60, 84, 0.25);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: #8ba4b5;
  transition: color 0.15s, transform 0.1s;
}
.fav-btn svg { width: 20px; height: 20px; display: block; }
.fav-btn svg path { fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.fav-btn:hover { color: var(--heart); }
.fav-btn:active { transform: scale(0.9); }
.fav-btn:focus-visible { outline: 2px solid var(--amber); }
.fav-btn.is-active { color: var(--heart); }
.fav-btn.is-active svg path { fill: currentColor; }

/* 詳細ページ用（ワイド版） */
.fav-btn--wide {
  position: static;
  width: 100%;
  height: 44px;
  margin: 14px 0 10px;
  gap: 8px;
  border: 1.5px solid #f3b8c3;
  border-radius: 8px;
  background: #fff;
  box-shadow: none;
  color: var(--heart);
  font-family: inherit;
  font-size: 14px;
  font-weight: 700;
}
.fav-btn--wide svg { width: 18px; height: 18px; }
.fav-btn--wide:hover { background: #fef4f6; }
.fav-btn--wide.is-active { background: var(--heart); border-color: var(--heart); color: #fff; }

/* 空状態 */
.empty-state {
  background: var(--white);
  border: 1px dashed #b9d3e3;
  border-radius: var(--radius);
  text-align: center;
  padding: 56px 24px;
  color: var(--muted);
}
.empty-title { font-size: 16px; font-weight: 700; color: var(--ink); margin: 0 0 8px; }
.empty-text { margin: 0; font-size: 13px; }
.empty-cta { margin: 18px 0 0; }

/* ---------------------------------------------------------------------------
   ページネーション
--------------------------------------------------------------------------- */
.pager { display: flex; justify-content: center; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 20px; }
.pager:empty { display: none; }
.pg {
  min-width: 38px;
  padding: 8px 12px;
  text-align: center;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--white);
  font-size: 13.5px;
  font-weight: 600;
  color: var(--accent-dark);
  text-decoration: none;
  transition: background-color 0.12s, border-color 0.12s;
}
a.pg:hover { border-color: var(--accent); background: var(--accent-pale); }
.pg.is-current { background: var(--accent); border-color: var(--accent); color: #fff; }
.pg.is-disabled { color: #b8c8d4; pointer-events: none; }
.pg-gap { border: none; background: none; color: var(--muted); min-width: auto; padding: 8px 2px; }

/* ---------------------------------------------------------------------------
   物件詳細ページ（/property/{id}）
--------------------------------------------------------------------------- */
.detail-container { padding: 22px 20px 50px; }
.back-link { margin: 0 0 14px; font-size: 13px; }
.back-link a { color: var(--accent-dark); text-decoration: none; font-weight: 600; }
.back-link a:hover { text-decoration: underline; }
.back-link--bottom { margin: 26px 0 0; }

.detail-head { margin-bottom: 16px; }
.detail-tags { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 8px; }
.detail-title { margin: 0 0 6px; font-size: clamp(20px, 3vw, 28px); font-weight: 800; line-height: 1.4; }
.detail-address { margin: 0; font-size: 13.5px; color: var(--muted); }

.detail-main { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 22px; align-items: start; margin-bottom: 34px; }
.gallery-main { margin: 0; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.gallery-main img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; }
.gallery-thumbs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 8px; }
.gallery-thumbs img { width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; border-radius: 8px; box-shadow: var(--shadow); }
.gallery-note { margin: 8px 0 0; font-size: 11px; color: var(--muted); }

.detail-side { position: sticky; top: 74px; }
.price-box { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; }
.price-box-label { margin: 0; font-size: 12px; color: var(--muted); font-weight: 700; }
.price-box-num { margin: 2px 0 6px; font-size: 32px; font-weight: 900; color: var(--price); line-height: 1.2; }
.price-box-num small { font-size: 16px; margin-left: 2px; }
.price-box-sub { margin: 0 0 4px; font-size: 12.5px; color: var(--muted); }
.price-box-cta { display: block; width: 100%; margin-bottom: 12px; }
.price-box-tel { margin: 0; padding-top: 10px; border-top: 1px dashed var(--line); text-align: center; }
.tel-num { display: block; font-size: 21px; font-weight: 900; color: var(--accent-deep); letter-spacing: 0.02em; }
.tel-note { display: block; font-size: 10.5px; color: var(--muted); line-height: 1.6; margin-top: 3px; }

.detail-section { margin-bottom: 34px; }
.section-title { font-size: 18px; font-weight: 800; color: var(--accent-deep); border-left: 4px solid var(--accent); padding-left: 10px; margin: 0 0 14px; }

/* 間取り図（SVG） */
.floorplan { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px; text-align: center; }
.floorplan-svg { width: 100%; max-width: 470px; height: auto; font-family: var(--font); }
.floorplan-caption { margin: 8px 0 0; font-size: 12px; color: var(--muted); }

.detail-description { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 18px 20px; margin: 0; font-size: 14px; line-height: 2; }

/* 物件概要テーブル */
.overview-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  font-size: 13.5px;
}
.overview-table th, .overview-table td { padding: 11px 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.overview-table tr:last-child th, .overview-table tr:last-child td { border-bottom: none; }
.overview-table th { width: 132px; background: var(--accent-pale); color: var(--accent-deep); font-weight: 700; white-space: nowrap; }
.overview-table th:empty { background: transparent; }

/* 設備一覧 */
.feat-grid {
  list-style: none;
  margin: 0;
  padding: 14px 18px;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 4px 14px;
  font-size: 13px;
}
.feat-item { display: flex; align-items: center; gap: 7px; padding: 4px 0; }
.feat-item::before {
  content: "";
  flex: none;
  width: 15px;
  height: 15px;
  border-radius: 999px;
  background: var(--accent) center / 9px no-repeat
    url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 12 12"><path fill="none" stroke="white" stroke-width="2.2" stroke-linecap="round" stroke-linejoin="round" d="M2 6.2 4.8 9 10 3.4"/></svg>');
}
.feat-none { margin: 0; padding: 16px 18px; background: var(--white); border: 1px dashed #b9d3e3; border-radius: var(--radius); color: var(--muted); font-size: 13px; }

/* お問い合わせ */
.inquiry {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.inquiry-tel { background: var(--accent-pale); padding: 22px 20px; text-align: center; display: flex; flex-direction: column; justify-content: center; }
.inquiry-tel-label { margin: 0; font-size: 12.5px; font-weight: 700; color: var(--accent-deep); }
.inquiry-tel-num { margin: 4px 0; font-size: 30px; font-weight: 900; color: var(--accent-deep); letter-spacing: 0.02em; }
.inquiry-tel-note { margin: 0; font-size: 11px; color: var(--muted); line-height: 1.7; }
.inquiry-form { padding: 20px 22px; }
.inquiry-form-lead { margin: 0 0 12px; font-size: 13px; color: var(--muted); }
.inquiry-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 14px; }
.inquiry-field { display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; font-weight: 700; color: var(--accent-deep); }
.inquiry-field--full { grid-column: 1 / -1; }
.inquiry-field input, .inquiry-field textarea {
  padding: 9px 11px;
  border: 1px solid #a9c3d4;
  border-radius: 7px;
  font-family: inherit;
  font-size: 13.5px;
  font-weight: 400;
  color: var(--ink);
  background: #fff;
  resize: vertical;
}
.inquiry-field input:focus-visible, .inquiry-field textarea:focus-visible { outline: 2px solid var(--amber); }
.inquiry-note {
  margin: 12px 0 0;
  font-size: 12.5px;
  font-weight: 700;
  color: #b3541e;
  background: #fdf3e7;
  border: 1px solid #f0d3ae;
  border-radius: 7px;
  padding: 9px 12px;
}

/* 関連物件 */
.cards--related { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.cards--related .card { margin-bottom: 0; }

/* ---------------------------------------------------------------------------
   お気に入り一覧ページ（/favorites）・404
--------------------------------------------------------------------------- */
.fav-container { padding: 26px 20px 60px; min-height: 45vh; }
.page-head { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; }
.page-title { margin: 0; font-size: 24px; font-weight: 800; color: var(--accent-deep); }
.fav-summary { margin: 0; font-size: 13px; color: var(--muted); }
.fav-summary strong { color: var(--accent-dark); font-size: 17px; }

.notfound { text-align: center; padding: 70px 20px 90px; }
.notfound-code { font-size: 48px; font-weight: 900; color: var(--accent); margin: 0; letter-spacing: 0.05em; }
.notfound-title { font-size: 20px; margin: 6px 0 10px; }
.notfound-text { color: var(--muted); font-size: 13.5px; margin: 0 0 22px; }

/* ---------------------------------------------------------------------------
   フッター（明るいトーン）
--------------------------------------------------------------------------- */
.site-footer { background: #eaf4fb; color: #4d6577; border-top: 1px solid #d3e8f4; margin-top: 30px; }
.footer-inner { padding: 34px 20px 26px; text-align: center; }
.footer-brand { display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 18px; font-weight: 800; color: var(--accent-deep); margin-bottom: 14px; }
.footer-brand .brand-mark { fill: var(--accent); width: 22px; height: 22px; }
.footer-note { max-width: 46em; margin: 0 auto 12px; font-size: 11.5px; line-height: 1.8; }
.footer-copy { margin: 0; font-size: 11px; opacity: 0.7; letter-spacing: 0.08em; }

/* ---------------------------------------------------------------------------
   モバイル：条件パネルをドロワー化（CSSのみで動作＝JS無効でも開閉可）
--------------------------------------------------------------------------- */
.drawer-checkbox { position: absolute; opacity: 0; pointer-events: none; }
.drawer-backdrop { display: none; }
.drawer-fab { display: none; }

@media (max-width: 900px) {
  .search-layout { grid-template-columns: 1fr; }
  .result-toolbar { position: static; }   /* モバイルの件数常時表示は FAB が担う */

  .filter-col {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(360px, 88vw);
    z-index: 60;
    border-radius: 0;
    transform: translateX(-104%);
    transition: transform 0.25s ease;
    overflow-y: auto;
    overscroll-behavior: contain;
  }
  .drawer-checkbox:checked ~ .search-layout .filter-col { transform: none; }
  .drawer-close { display: block; }

  .drawer-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 55;
    background: rgba(13, 60, 84, 0.45);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s;
  }
  .drawer-checkbox:checked ~ .search-layout .drawer-backdrop { opacity: 1; pointer-events: auto; }
  body:has(.drawer-checkbox:checked) { overflow: hidden; }

  /* FAB：現在の総件数を常時表示（[data-total-btn] を JS が更新） */
  .drawer-fab {
    position: fixed;
    left: 50%;
    bottom: 18px;
    transform: translateX(-50%);
    z-index: 40;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--accent);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    padding: 12px 22px;
    border-radius: 999px;
    box-shadow: 0 6px 18px rgba(13, 77, 112, 0.4);
    cursor: pointer;
    white-space: nowrap;
  }
  .fab-total strong { font-weight: 900; font-size: 16px; }
  .fab-sep { opacity: 0.7; }
  .fab-badge {
    background: var(--amber);
    color: #4a3005;
    font-size: 12px;
    min-width: 20px;
    height: 20px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0 6px;
  }
  .fab-badge:empty { display: none; }

  .stats-inner { grid-template-columns: repeat(2, 1fr); }
  .hero-inner { padding: 60px 20px 52px; }
  .global-nav a:not(.nav-cta):not(.nav-fav) { display: none; }

  .detail-main { grid-template-columns: 1fr; }
  .detail-side { position: static; }
  .cards--related { grid-template-columns: 1fr; }
}

@media (max-width: 800px) {
  .inquiry { grid-template-columns: 1fr; }
  .inquiry-fields { grid-template-columns: 1fr; }

  /* 概要テーブル：1行1項目に */
  .overview-table, .overview-table tbody { display: block; }
  .overview-table tr { display: grid; grid-template-columns: 110px 1fr; }
  .overview-table th { width: auto; }
  .overview-table tr:last-child th:not(:empty), .overview-table tr:last-child td { border-bottom: 1px solid var(--line); }
  .overview-table tr:last-child td:last-child, .overview-table tr:last-child th:empty { border-bottom: none; }
}

@media (max-width: 640px) {
  .card { flex-direction: column; gap: 10px; }
  .card-media { width: 100%; }
  .card-media img { height: 190px; }
  .result-toolbar { flex-direction: column; align-items: stretch; gap: 8px; }
  .sort-form { justify-content: flex-end; }
  .stat strong { font-size: 19px; }
  .brand-sub { display: none; }
  .nav-fav-text { display: none; }
  .gallery-thumbs { grid-template-columns: repeat(3, 1fr); gap: 6px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}

/* 控えめなトースト（お気に入り上限などの一言通知） */
.site-toast {
  position: fixed;
  left: 50%;
  bottom: 84px; /* モバイルのFABに重ならない高さ */
  transform: translate(-50%, 8px);
  background: var(--accent-deep, #0d4d70);
  color: #fff;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 13px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s, transform .25s;
  z-index: 80;
  box-shadow: 0 4px 16px rgba(13, 77, 112, .25);
}
.site-toast.is-show { opacity: 1; transform: translate(-50%, 0); }
