/* ================================================================
   助成金・補助金マッチングツール スタイル（道具箱共通デザイン）
   ================================================================ */

:root {
  --navy:    #1E2A4A;
  --navy2:   #2c3c63;
  --orange:  #C87A2A;
  --orange-l:#e9a14e;
  --bg:      #F4F1EA;
  --card:    #fff;
  --ink:     #2b2b2b;
  --mut:     #7a7568;
  --line:    #e3ddd2;
  --green:   #3f7d57;
  --red:     #b4452f;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.75;
  -webkit-text-size-adjust: 100%;
}

.wrap { max-width: 680px; margin: 0 auto; padding: 0 16px 64px; }

/* ── ヘッダー ── */
.site-header {
  background: linear-gradient(135deg, var(--navy), var(--navy2));
  color: #fff;
  border-radius: 0 0 20px 20px;
  padding: 28px 22px 24px;
  text-align: center;
}
.header-logo { font-size: 18px; font-weight: 800; letter-spacing: .04em; }
.header-sub  { font-size: 13px; color: #cdd4e6; margin-top: 6px; }

/* ── カード共通 ── */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 22px 20px;
  margin-top: 16px;
}

.section-title { font-size: 16px; font-weight: 800; color: var(--navy); margin-bottom: 16px; }

/* ── イントロ ── */
.intro-card { text-align: center; }
.lead { font-size: 15px; line-height: 1.8; margin-bottom: 14px; }
.lead strong { color: var(--navy); }
.intro-points { list-style: none; text-align: left; display: inline-block; margin-bottom: 20px; }
.intro-points li { font-size: 13.5px; color: #4a4536; margin-bottom: 5px; }

/* ── フォーム ── */
.field { margin-bottom: 18px; }
.field-label { display: block; font-size: 13px; font-weight: 700; color: var(--navy); margin-bottom: 8px; }
.req { font-size: 11px; background: var(--orange); color: #fff; padding: 2px 7px; border-radius: 10px; margin-left: 5px; }
.opt { font-size: 11px; background: #bbb; color: #fff; padding: 2px 7px; border-radius: 10px; margin-left: 5px; }

.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 18px; }
@media (max-width: 480px) { .field-grid { grid-template-columns: 1fr; } }

.radio-row { display: flex; gap: 16px; flex-wrap: wrap; }
.radio-row label { display: flex; align-items: center; gap: 6px; font-size: 14px; cursor: pointer; padding: 8px 12px; border-radius: 8px; border: 1.5px solid var(--line); background: #fdfcfa; }
.radio-row label:has(input:checked) { background: #fff7ec; border-color: var(--orange-l); font-weight: 700; }
.radio-row input { accent-color: var(--orange); }

select, input[type="number"], input[type="text"] {
  width: 100%;
  padding: 10px 12px;
  font-size: 16px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  background: #fdfcfa;
  color: var(--ink);
  font-family: inherit;
}
select:focus, input:focus { outline: none; border-color: var(--orange); }

.hint { font-size: 12px; color: var(--mut); display: block; margin-top: 4px; }

/* ── カテゴリグリッド ── */
.check-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
@media (max-width: 380px) { .check-grid { grid-template-columns: 1fr; } }

.check-card {
  display: flex; align-items: center; gap: 8px;
  padding: 9px 11px;
  border: 1.5px solid var(--line);
  border-radius: 10px;
  background: #fdfcfa;
  cursor: pointer;
  font-size: 13px;
  transition: all .1s;
}
.check-card:has(input:checked) { background: #fff7ec; border-color: var(--orange-l); font-weight: 700; }
.check-card input { accent-color: var(--orange); flex-shrink: 0; }
.check-emoji { font-size: 16px; flex-shrink: 0; }

/* ── アコーディオン ── */
.accordion { border: 1px solid var(--line); border-radius: 10px; margin-bottom: 18px; }
.accordion summary { padding: 12px 14px; font-size: 13px; font-weight: 700; color: var(--navy); cursor: pointer; list-style: none; }
.accordion summary::-webkit-details-marker { display: none; }
.accordion-body { padding: 0 14px 14px; }
.check-col { display: flex; flex-direction: column; gap: 8px; margin-bottom: 14px; }
.check-col label { display: flex; align-items: flex-start; gap: 8px; font-size: 13px; cursor: pointer; }
.check-col input { accent-color: var(--orange); flex-shrink: 0; margin-top: 3px; }

/* ── ボタン ── */
.btn {
  display: inline-block;
  border: none;
  border-radius: 10px;
  padding: 11px 20px;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  font-family: inherit;
  text-decoration: none;
  transition: opacity .1s;
}
.btn:active { opacity: .85; }
.btn-primary { background: var(--orange); color: #fff; }
.btn-ghost   { background: transparent; color: var(--mut); border: 1px solid var(--line); font-weight: 600; }
.btn-lg      { display: block; width: 100%; padding: 15px; font-size: 16px; text-align: center; letter-spacing: .04em; }
.btn-link    { display: block; width: 100%; text-align: center; margin-top: 12px; padding: 14px; }
.form-actions { margin-top: 6px; }

/* ── 結果エリア ── */
.result-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 20px;
  flex-wrap: wrap;
  gap: 8px;
}
.result-note { font-size: 13px; color: var(--mut); margin: 8px 2px 4px; line-height: 1.8; }
.result-note a { color: var(--orange); }
.result-list { margin-top: 4px; }

/* ── 補助金カード ── */
.subsidy-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px;
  margin-top: 12px;
  box-shadow: 0 1px 6px rgba(30,42,74,.05);
}

.card-top {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}

/* バッジ */
.badge {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  padding: 4px 8px;
  border-radius: 10px;
  font-size: 18px;
  font-weight: 900;
  flex-shrink: 0;
  line-height: 1.2;
}
.badge small { font-size: 10px; font-weight: 600; white-space: nowrap; }
.badge-high { background: #fff7ec; color: var(--orange); border: 2px solid var(--orange-l); }
.badge-mid  { background: #f0f4ff; color: var(--navy2); border: 2px solid #b0bcdd; }
.badge-low  { background: #f5f5f5; color: #888; border: 2px solid #ddd; }

.subsidy-name { font-size: 14px; font-weight: 700; color: var(--navy); line-height: 1.5; flex: 1; min-width: 0; }

.scope-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 9px;
  border-radius: 10px;
  background: var(--green);
  color: #fff;
  white-space: nowrap;
  align-self: flex-start;
  flex-shrink: 0;
}

/* 補助額・補助率 */
.amount-row { display: flex; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.amount, .rate { font-size: 14px; font-weight: 700; color: var(--navy); }
.amount-label { font-size: 11px; font-weight: 600; color: var(--mut); display: block; margin-bottom: 2px; }

/* マッチ理由・警告 */
.reasons { list-style: none; margin-bottom: 8px; }
.reasons li { font-size: 13px; color: var(--green); padding: 2px 0; }
.warnings { list-style: none; margin-bottom: 8px; }
.warnings li { font-size: 12px; color: var(--orange); background: #fff7ec; border-radius: 6px; padding: 4px 8px; margin-bottom: 3px; }

/* 締切 */
.dl       { font-size: 13px; font-weight: 700; padding: 4px 0; }
.dl-ok    { color: var(--ink); }
.dl-soon  { color: var(--red); }
.dl-past  { color: var(--mut); }
.dl-none  { color: var(--mut); font-weight: 500; }
.dl-note  { font-size: 12px; color: var(--mut); margin-bottom: 8px; }

/* 詳細アコーディオン */
.card-detail { margin-top: 10px; }
.card-detail > summary { font-size: 12px; color: var(--mut); cursor: pointer; list-style: none; padding: 4px 0; }
.card-detail > summary::-webkit-details-marker { display: none; }
.detail-body { padding-top: 10px; }
.kv { display: flex; gap: 8px; font-size: 12px; margin-bottom: 8px; line-height: 1.6; }
.kv .k { font-weight: 700; color: var(--navy); white-space: nowrap; min-width: 80px; }
.kv .v { color: #4a4536; }

/* ── CTA ── */
.offer {
  background: linear-gradient(135deg, #1f2a44, #33406b);
  border-radius: 18px;
  padding: 28px 22px;
  margin-top: 24px;
  text-align: center;
  color: #fff;
  box-shadow: 0 8px 28px rgba(31,42,68,.22);
}
.offer-en    { display: block; font-size: 11px; letter-spacing: .16em; color: var(--orange-l); font-weight: 700; margin-bottom: 10px; }
.offer-title { font-size: 19px; font-weight: 800; line-height: 1.55; margin-bottom: 10px; }
.offer-lead  { font-size: 13px; line-height: 1.9; color: #dbe0ee; margin-bottom: 20px; }
.offer-btn {
  display: block;
  width: 100%;
  border: none;
  border-radius: 12px;
  padding: 17px;
  font-size: 16px;
  font-weight: 800;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  background: linear-gradient(135deg, #f0a23e, #d97b1f);
  color: #fff;
  font-family: inherit;
}
.offer-note  { font-size: 11.5px; color: #aeb6c9; margin-top: 12px; line-height: 1.7; }

/* ── フッター ── */
.site-footer { text-align: center; color: var(--mut); font-size: 11px; margin-top: 24px; line-height: 1.9; padding-bottom: 32px; }
.disclaimer { font-size: 11px; background: #efeae1; border-radius: 8px; padding: 10px 14px; line-height: 1.7; text-align: left; }

/* ── ユーティリティ ── */
.hidden { display: none !important; }
