/*
 * K・山口総合事務所 売却相談LP / 三校
 * 編集順：共通設定 → PC基本スタイル（ページ順）→ タブレット → SP
 * 同じクラスのSP指定は「17. SP」内にあります。
 * 個別の余白は各セクションの padding / margin / gap で調整します。
 */

/* 00. よく変更する値：色・本文幅・左右余白・フォント */
:root {
  --content-width: 1000px; /* PCの本文の最大幅 */
  --page-gutter: 24px; /* 画面左右の余白（片側） */
  --section-space: 48px; /* 基本のセクション上下余白（個別指定がある箇所を除く） */
  --font-body: "Noto Sans JP", sans-serif;
  --font-label: Montserrat, sans-serif;
  --green: #5b8e24; /* 見出し背景の緑 */
  --deep: #0e4935; /* 濃い緑：お問い合わせ背景など */
  --ink: #18322a; /* 本文の文字色 */
  --muted: #5f6d68; /* 説明文の文字色 */
  --line: #d7dfd5; /* 枠線 */
  --leaf: #dff0d8; /* 濃い背景の上の淡い文字色 */
}

/* 01. 基本設定・リセット */
* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: var(--font-body);
  background: #fffefa;
}

h1,
h2,
h3,
p,
ul,
ol {
  margin: 0;
}

ul,
ol {
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  display: block;
  max-width: 100%;
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
a,
input,
select,
textarea {
  -webkit-tap-highlight-color: transparent;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid #da9b00;
  outline-offset: 4px;
}

/* 02. 共通レイアウト（本文幅1000px、左右余白24px） */
.container {
  width: min(var(--content-width), calc(100% - var(--page-gutter) * 2));
  margin-inline: auto;
  position: relative;
}

.skip {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 10;
  background: white;
  padding: 12px;
}

.skip:focus {
  top: 16px;
}

.sp-break {
  display: none;
}

/* 03. ファーストビュー・ヘッダー */
.hero {
  background:
    linear-gradient(90deg, rgba(0, 30, 19, 0.6), rgba(0, 30, 19, 0.3) 38%, transparent 72%),
    url("assets/imgImageHero.webp") center/cover no-repeat;
  background-color: #1b3325; /* 画像読み込み中の下地色（フラッシュ防止） */
  /* cover は縦横比を保ち、足りない方向をトリミングします。 */
  overflow: hidden;
}

.navigation {
  background: #659532;
  box-shadow: 2px 2px 4px #0004;
  position: relative;
  z-index: 2;
}

.nav-inner {
  height: 92px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  color: white;
}

.brand {
  font-size: 25px;
  font-weight: 900;
  white-space: nowrap;
}

.header-phone {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 28px;
  font-weight: 700;
  white-space: nowrap;
}

.header-phone img {
  width: 32px;
  height: 32px;
}

.hero-content {
  height: 742px;
  padding-top: 60px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 22px;
}

.eyebrow {
  width: 400px;
  padding: 10px;
  border: 1px solid #f3d06b;
  border-radius: 8px;
  text-align: center;
  color: #f3d06b;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
}

h1 {
  font-size: 82px;
  font-weight: 900;
  line-height: 1.6; /* PCの白いマーカー同士の間隔 */
  color: var(--green);
  position: relative;
  z-index: 1;
  white-space: nowrap;
  letter-spacing: 0;
}

h1 span {
  background: white;
  box-shadow:
    8px 0 white,
    -8px 0 white;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.hero-lead {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.8;
  color: white;
}

.hero-person {
  position: absolute;
  right: 20px;
  /* 下端を次のREASONセクションに3px重ね、切り口を隠す。 */
  bottom: -3px;
  width: 352px;
  height: 469px;
  object-fit: cover;
  object-position: top;
}

/* 04. 共通ボタン */
.button {
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(#ffe05c, #ffc40f 48%, #f5a300);
  border: 0;
  border-radius: 999px;
  color: var(--deep);
  font-weight: 700;
  font-size: 20px;
  min-height: 66px;
  padding: 18px;
  box-shadow:
    0 10px 14px #261f0538,
    0 5px 0 #ab6600,
    inset 0 2px 1px #ffffff7a;
  cursor: pointer;
  transition: filter 0.2s;
}

.button:hover {
  filter: brightness(1.1) saturate(0.8);
}

.contact form .button {
  width: 100%;
  max-width: 600px;
  align-self: center;
}

.consent-field {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 15px;
  margin: 8px 0;
}

.consent-field label {
  display: inline;
  font-weight: 700;
  font-size: 15px;
  color: var(--deep);
}

.consent-field a {
  color: var(--green);
  text-decoration: underline;
}

.consent-field input[type="checkbox"] {
  width: 20px;
  height: 20px;
  min-height: 0;
  flex-shrink: 0;
  padding: 0;
  accent-color: var(--green);
}

.hero-cta {
  width: 552px;
  margin-top: 10px;
  font-size: 22px;
  position: relative;
}

/* 05. 共通セクション・見出し */
.section {
  padding: var(--section-space) 0;
}

.section-heading {
  text-align: center;
}

.eyelabel {
  font-family: var(--font-label);
  font-weight: 900;
  font-size: 26px;
  line-height: 1.4;
  color: #91c954;
  margin-bottom: 10px;
}

h2 {
  position: relative;
  background: var(--green);
  padding: 24px 32px;
  border-radius: 8px;
  color: white;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.45;
}

.tail {
  position: absolute;
  width: 32px;
  height: 20px;
  left: calc(50% - 16px);
  bottom: -19px;
}

.lead {
  font-size: 18px;
  line-height: 1.8;
  color: var(--muted);
  text-align: center;
  margin-top: 28px;
}

/* 06. REASON：理由カード */
.reason {
  padding: 56px 0;
  background: #fffefa;
}

.reasons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 28px;
}

.reason-card {
  position: relative;
  min-height: 390px;
  border: 1px solid #eee9db;
  border-radius: 12px;
  background: white;
  padding: 26px 24px;
  box-shadow: 0 18px 45px #1631271f;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.number {
  font-size: 72px;
  font-weight: 700;
  color: #b4bea0;
  line-height: 1.4;
}

.reason-icon {
  position: absolute;
  right: 24px;
  top: 31px;
  width: 76px;
  height: 76px;
}

.reason-card h3 {
  font-size: 18px;
  line-height: 1.45;
}

.reason-card > p:last-child {
  font-size: 17px;
  line-height: 1.85;
  color: var(--muted);
}

/* 07. ISSUE：お悩み一覧 */
.issue {
  overflow: hidden;
  background: #f3f9f2;
}

.worries {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-top: 28px;
}

.worries li {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 72px;
  padding: 16px;
  background: white;
  border: 1px solid var(--line);
  border-radius: 8px;
  font-size: 18px;
  font-weight: 700;
  line-height: 1.5;
}

.worries li span {
  color: #1f6f4a;
  font-size: 20px;
}

.issue-person {
  position: absolute;
  right: 24px;
  /* セクション下余白 + 3px。FLOWとの境界で切り口を隠す。 */
  bottom: calc(-1 * var(--section-space) - 3px);
  width: 139px;
  height: 222px;
  object-fit: cover;
  object-position: top;
  pointer-events: none;
}

/* 08. FLOW：売却までの流れ */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px 16px;
  margin-top: 30px;
}

.steps li {
  background: var(--deep);
  border-radius: 6px;
  min-height: 228px;
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  color: white;
}

.steps p {
  font-size: 14px;
  line-height: 1.3;
  color: var(--leaf);
  font-weight: 700;
}

.steps h3 {
  font-size: 20px;
  line-height: 1.45;
  min-height: 58px;
}

.steps img {
  width: 60px;
  height: 60px;
}

/* 09. CHECK POINT：確認項目 */
.checks {
  background: #faf8f1;
  padding: 40px 0;
}

.check-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px 16px;
  margin-top: 24px;
}

.check-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 74px;
  background: #fffdf8;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 18px;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.5;
}

.check-list img {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

/* 10. LEGAL：法規制 */
.legal {
  background: #fffefa;
}

.laws {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin-top: 28px;
}

.laws article {
  position: relative;
  padding: 28px 28px 28px 100px;
  border: 1px solid #eee9db;
  border-radius: 12px;
  background: white;
  min-height: 200px;
}

.laws img {
  position: absolute;
  left: 20px;
  top: 28px;
  width: 64px;
  height: 64px;
}

.laws h3 {
  font-size: 20px;
  line-height: 1.4;
  margin: 8px 0 18px;
}

.laws p {
  font-size: 17px;
  line-height: 1.8;
  color: var(--muted);
}

/* 11. OPTION：料金・現地確認サービス */
.option {
  background: #f1eedb;
}

.price {
  text-align: center;
  color: var(--deep);
  font-weight: 700;
  line-height: 1.55;
  margin-top: 12px;
  font-size: 32px;
}

.price > span {
  background: linear-gradient(transparent 66%, #f3d06bd9 66%, #f3d06bd9 90%, transparent 90%);
}

.price strong {
  font-size: 58px;
}

.price small {
  font-size: 24px;
}

.price-note {
  font-size: 17px;
  line-height: 1.7;
  text-align: center;
  color: var(--muted);
  margin-top: 4px;
}

.option-person {
  display: none;
}

.service {
  display: grid;
  grid-template-columns: 575fr 400fr;
  gap: 24px;
  margin-top: 28px;
}

.service-photo {
  height: 345px;
  overflow: hidden;
  border-radius: 10px;
  position: relative;
}

.service-photo img {
  position: absolute;
  width: 166.3%;
  max-width: none;
  height: 184.82%;
  left: -18.37%;
  top: -40.51%;
}

.service ul {
  height: 345px;
  background: var(--deep);
  color: white;
  border-radius: 10px;
  padding: 24px 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.service li {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 18px 8px;
  font-size: 20px;
  font-weight: 700;
  white-space: nowrap;
}

.service li img {
  width: 40px;
  height: 40px;
  flex-shrink: 0;
}

/* 12. CONTACT：電話案内 */
.contact {
  background: var(--deep);
}

.contact-card {
  position: relative;
  border: 1px solid #ffffff33;
  background: #ffffff1a;
  border-radius: 8px;
  padding: 28px;
  margin-top: 28px;
  text-align: center;
  color: var(--leaf);
}

.contact-card > p {
  font-size: 17px;
  font-weight: 700;
  line-height: 1.4;
}

.contact-card a {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  color: white;
  font-size: 36px;
  font-weight: 700;
  line-height: 1.4;
  margin-top: 6px;
}

.contact-card a img {
  width: 28px;
  height: 28px;
}

.contact-person {
  position: absolute;
  right: 18px;
  /* フォームまでの32pxの余白 + 枠線1px + 重なり3px。 */
  bottom: -36px;
  width: 244px;
  height: 189px;
  object-fit: cover;
  object-position: top;
  pointer-events: none;
}

/* 13. お問い合わせフォーム */
form {
  position: relative;
  z-index: 1;
  margin-top: 32px;
  padding: 34px;
  background: white;
  border-radius: 8px;
  min-height: 778px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.fields {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
}

label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 15px;
  line-height: 1.4;
  font-weight: 700;
  color: var(--deep);
  min-width: 0;
}

.field-label {
  display: inline-flex;
  align-items: center;
}

.req-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 8px;
  border-radius: 4px;
  background: var(--green);
  color: white;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.6;
  vertical-align: middle;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #cbd6cd;
  border-radius: 8px;
  background: #fbfdfb;
  padding: 16px;
  font-size: 17px;
  line-height: 1.45;
  color: var(--ink);
  font-weight: 400;
  min-height: 57px;
}

input::placeholder,
textarea::placeholder {
  color: #94a09a;
  opacity: 1;
}

/* 土地の種別：ブラウザー標準の装飾による文字・矢印の位置ずれを防ぐ。 */
select {
  display: block;
  appearance: none;
  -webkit-appearance: none;
  height: 57px;
  padding: 0 44px 0 16px;
  line-height: normal;
  cursor: pointer;
  background-image:
    linear-gradient(45deg, transparent 50%, var(--muted) 50%),
    linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position:
    calc(100% - 22px) 50%,
    calc(100% - 17px) 50%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
}

textarea {
  min-height: 132px;
  resize: vertical;
}

.form-note {
  font-size: 18px;
  line-height: 1.8;
  text-align: center;
  color: var(--deep);
  font-weight: 500;
}

#form-status {
  padding: 12px;
  border: 1px solid var(--line);
  line-height: 1.7;
}

/* 14. フッター */
footer {
  padding: 34px 0;
  background: #083426;
  color: var(--leaf);
}

footer .container {
  display: flex;
  justify-content: space-between;
  gap: 40px;
}

footer p {
  font-size: 18px;
  font-weight: 900;
  line-height: 1.4;
}

footer small {
  font-size: 15px;
  line-height: 1.4;
}

/* 15. PC専用：法規制カードと現地確認セクション */
@media (min-width: 768px) {
  .laws article {
    min-height: 225px;
    padding: 34px 24px 34px 100px;
    border-color: #eee4c8;
    border-radius: 8px;
  }

  .laws img {
    left: 15px;
    top: 41px;
    width: 72px;
    height: 72px;
  }

  .laws h3 {
    margin: 0 0 14px;
    padding: 8px 0;
  }

  .laws p {
    font-size: 18px;
    line-height: 1.85;
  }

  .option {
    padding: 56px 0;
    background: #f2efdf;
  }

}

/* 16. タブレット・小さなPC（768〜1100px） */
@media (min-width: 768px) and (max-width: 1100px) {
  h1 {
    font-size: clamp(58px, 7.45vw, 82px);
  }

  /* 中間幅では高さ・文字サイズを連続的に縮めます。 */
  .hero-content {
    height: clamp(600px, 67.45vw, 742px);
    padding-top: clamp(40px, 5.45vw, 60px);
  }

  .hero-person {
    width: 30%;
    height: auto;
    top: auto;
    bottom: -3px;
    right: 0;
  }

  .hero-lead {
    font-size: 18px;
  }

  .hero-cta {
    width: 55%;
  }

  .reason-card {
    padding-inline: 20px;
  }

  .reason-icon {
    width: 60px;
    height: 60px;
    right: 16px;
  }

  .service li {
    font-size: 16px;
    gap: 12px;
    white-space: normal;
  }

  .contact-person {
    width: 190px;
    height: auto;
  }

  h2 {
    font-size: 24px;
  }

}

/* ISSUE：980px以下ではチェック一覧の下に人物を配置。 */
@media (min-width: 768px) and (max-width: 980px) {
  .issue .container {
    /* 人物216px + 上の間隔24px - セクション下余白 */
    padding-bottom: calc(240px - var(--section-space));
  }

  .issue-person {
    left: 50%;
    right: auto;
    transform: translateX(-50%);
    width: 139px;
    height: 216px;
  }
}

/* 17. SP（767px以下）：PCと異なる指定だけ上書き */
@media (max-width: 767px) {
  .sp-break {
    display: block;
  }

  .pc-break {
    display: none;
  }

  .container {
    width: calc(100% - var(--page-gutter) * 2);
  }

  .nav-inner {
    width: calc(100% - 36px);
    height: auto;
    padding: 16px 0;
    gap: 10px;
    justify-content: space-between;
  }

  .brand {
    font-size: 18px;
    line-height: 1.3;
    width: auto;
    flex-shrink: 0;
    text-align: left;
  }

  .brand span {
    display: block;
  }

  .header-phone {
    height: 46px;
    width: 208px;
    justify-content: center;
    gap: 8px;
    padding: 10px;
    background: white;
    border-radius: 10px;
    color: #659532;
    font-size: 22px;
    flex-shrink: 0;
  }

  .header-phone img {
    width: 24px;
    height: 24px;
  }

  .hero {
    /* 写真の幅と高さを別々に指定せず、縦横比を維持。 */
    background-size:
      auto,
      cover;
    background-position:
      center,
      78.75% top;
  }

  .hero-content {
    height: auto;
    padding-top: 32px;
    padding-bottom: 0;
    gap: 20px;
    align-items: center;
  }

  .eyebrow {
    width: 100%;
    max-width: 400px;
    font-size: 16px;
  }

  .hero h1 {
    width: 100%;
    font-size: 48px;
    line-height: 1.55;
    white-space: normal;
  }

  .hero h1 span {
    display: table;
    box-shadow: none;
    padding-inline: 6px;
    margin-left: -6px;
    background: linear-gradient(transparent 9%, white 9%, white 89%, transparent 89%);
  }

  .hero-lead {
    width: 100%;
    font-size: 16px;
    line-height: 1.8;
  }

  .hero-person {
    position: absolute;
    left: 50%;
    right: auto;
    bottom: -3px;
    transform: translateX(calc(-50% - 22px));
    width: 210px;
    height: 274px;
    object-fit: cover;
  }

  .hero-cta {
    width: 100%;
    max-width: 400px;
    font-size: 16px;
    /* ボタンの下に人物用の領域を確保し、人物はセクション下端に固定。 */
    margin: 0 0 294px;
    min-height: 60px;
  }

  .section,
  .reason,
  .checks {
    padding: 40px 0;
  }

  .eyelabel {
    font-size: 18px;
  }

  .section h2 {
    font-size: 22px;
    line-height: 1.45;
    padding: 24px 16px;
  }

  .lead {
    font-size: 16px;
    line-height: 1.8;
    margin-top: 24px;
  }

  .reasons {
    grid-template-columns: 1fr;
    margin-top: 24px;
  }

  .reason-card {
    padding: 26px 20px;
    min-height: 0;
  }

  .number {
    font-size: 48px;
  }

  .reason-card h3 {
    font-size: 16px;
  }

  .reason-icon {
    top: 19px;
    right: 20px;
  }

  .worries {
    grid-template-columns: 1fr;
    gap: 14px;
    margin-top: 24px;
  }

  .worries li {
    font-size: 16px;
    min-height: 68px;
    padding: 12px;
    gap: 12px;
  }

  .issue .container {
    /* 一覧の下に人物の領域を確保。下側40pxはセクションの余白を利用。 */
    padding-bottom: 200px;
  }

  .issue-person {
    position: absolute;
    left: 50%;
    right: auto;
    bottom: -43px;
    transform: translateX(-50%);
    width: 139px;
    height: 216px;
  }

  .steps {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px 12px;
    margin-top: 24px;
  }

  .steps li {
    padding: 20px 14px;
    min-height: 198px;
    gap: 12px;
  }

  .steps h3 {
    font-size: 16px;
    line-height: 1.5;
    min-height: 72px;
  }

  .steps img {
    width: 44px;
    height: 44px;
  }

  .check-list {
    grid-template-columns: 1fr;
    gap: 15px;
  }

  .check-list li {
    min-height: 64px;
    padding: 18px;
    line-height: 1.5;
  }

  .laws {
    grid-template-columns: 1fr;
    gap: 24px;
    margin-top: 24px;
  }

  .laws article {
    padding: 20px 20px 34px;
    min-height: 246px;
    display: flex;
    flex-direction: column;
  }

  .laws img {
    position: static;
    width: 72px;
    height: 72px;
    order: -1;
    margin-bottom: 8px;
  }

  .laws h3 {
    font-size: 16px;
    line-height: 22px;
    margin: 0 0 14px;
    padding: 8px 0;
  }

  .laws p {
    font-size: 17px;
    line-height: 1.8;
  }

  .price strong {
    font-size: 40px;
  }

  .price {
    font-size: 28px;
  }

  .price small {
    font-size: 20px;
  }

  .price-note {
    font-size: 17px;
  }

  .option-person {
    display: block;
    width: 196px;
    height: 162px;
    object-fit: contain;
    margin: 24px auto 0;
  }

  .service {
    display: flex;
    flex-direction: column;
    gap: 24px;
    margin-top: 0;
  }

  .service ul {
    order: -1;
    height: 258px;
    width: 100%;
    padding: 24px 20px;
  }

  .service li {
    height: 70px;
    font-size: 16px;
    padding: 16px 12px;
    gap: 12px;
  }

  .service-photo {
    width: 100%;
    height: auto;
    aspect-ratio: 5/3;
  }

  .contact-card {
    margin-top: 24px;
    padding: 28px 20px;
    text-align: left;
  }

  .contact-card > p {
    font-size: 18px;
    line-height: 1.4;
  }

  .contact-card a {
    justify-content: flex-start;
    font-size: 20px;
    gap: 4px;
    line-height: 1.45;
  }

  .contact-card a img {
    width: 20px;
    height: 21px;
  }

  .contact-person {
    width: 134px;
    height: 103px;
    right: 17px;
    /* フォームまでの16pxの余白 + 枠線1px + 重なり3px。 */
    bottom: -20px;
  }

  .contact form {
    margin-top: 16px;
    padding: 34px 20px;
    min-height: 1148px;
  }

  .fields {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .contact textarea {
    min-height: 107px;
  }

  .contact .button {
    font-size: 16px;
    min-height: 60px;
  }

  .form-note {
    text-align: left;
    font-size: 18px;
    line-height: 1.8;
  }

  footer {
    padding: 40px 0;
  }

  footer .container {
    flex-direction: column;
    gap: 24px;
    text-align: center;
  }

  footer small {
    font-size: 15px;
  }

}

/* 550px以下：ヒーローを左揃えに */
@media (max-width: 550px) {
  .hero-content {
    align-items: flex-start;
  }

  .hero h1,
  .hero-lead {
    text-align: left;
  }

  .hero h1 span {
    margin-inline: 0;
  }

  .hero-person {
    left: auto;
    right: 0;
    transform: none;
  }
}

/* 551〜767px：ヒーローを中央揃えのままにする */
@media (min-width: 551px) and (max-width: 767px) {
  .hero h1,
  .hero-lead {
    text-align: center;
  }

  .hero h1 span {
    margin-inline: auto;
  }
}

/* 18. 小さなスマートフォン（374px以下） */
@media (max-width: 374px) {
  .header-phone {
    font-size: 18px;
    width: 180px;
    gap: 6px;
  }

  .brand {
    font-size: 16px;
    padding-left: 0;
  }

  .hero h1 {
    font-size: clamp(37px, 12.3vw, 48px);
  }

  .hero-lead {
    font-size: 14px;
  }

  .section h2 {
    font-size: 20px;
  }

  .check-list li {
    font-size: 15px;
  }

  .service li {
    padding-inline: 0;
    font-size: 14px;
  }

  .contact-person {
    width: 100px;
    height: auto;
  }

  .contact-card > p {
    font-size: 15px;
  }

  .contact-card a {
    font-size: 18px;
  }

}

/* スマホのh2：Figmaの1行を1つのspanで管理し、指定位置だけで改行。 */
@media (max-width: 767px) {
  .section h2 {
    /* 小さい画面でもデザインの1行が収まる文字サイズ。 */
    font-size: clamp(18px, 5.6vw, 22px);
  }

  .section h2 .heading-line {
    display: block;
    white-space: nowrap;
  }
}

/* CONTACTの電話番号：450〜767pxで20pxから28pxへ徐々に拡大。 */
@media (min-width: 450px) and (max-width: 767px) {
  .contact-card a {
    font-size: clamp(20px, calc(20px + (100vw - 450px) * 0.02524), 28px);
    gap: 6px;
  }

  .contact-card a img {
    width: 1em;
    height: 1em;
  }
}

/* 18-1. 初期表示のオープニングアニメーション（読み込み中の待ち時間を演出） */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 18px;
  background: #0e4935;
  transition: opacity 0.5s ease, visibility 0.5s ease;
}

.preloader-mark svg {
  display: block;
  width: 96px;
  height: 96px;
  animation:
    preloader-intro 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) both,
    preloader-pulse 1.8s ease-in-out 0.7s infinite;
}

.preloader-text {
  color: white;
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-align: center;
  opacity: 0;
  animation: preloader-text-in 0.6s ease-out 0.5s forwards;
}

.preloader-text span {
  display: block;
  margin-top: 4px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.2em;
  color: #dff0d8;
}

.preloader.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

@keyframes preloader-intro {
  0% {
    transform: scale(0) rotate(-20deg);
    opacity: 0;
  }
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
}

@keyframes preloader-pulse {
  0%,
  100% {
    transform: scale(1) rotate(0deg);
    opacity: 1;
  }
  50% {
    transform: scale(1.25) rotate(-6deg);
    opacity: 0.75;
  }
}

@keyframes preloader-text-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* 19-1. スクロールで各セクションをフェードインさせる演出 */
.reveal {
  opacity: 0;
  transform: translateY(48px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* 19. 端末設定に合わせてアニメーションを抑制 */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .button {
    transition: none;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .preloader-mark svg {
    animation: none;
  }

  .preloader-text {
    opacity: 1;
    transform: none;
    animation: none;
  }

}

/* 20. プライバシーポリシーページ */
.legal-page {
  padding: 56px 0 96px;
  background: #fffefa;
}

.legal-inner {
  max-width: 760px;
}

.legal-page h1 {
  font-size: 32px;
  font-weight: 900;
  line-height: 1.4;
  color: var(--deep);
  white-space: normal;
}

.legal-updated {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
}

.legal-inner > p {
  margin-top: 24px;
  line-height: 1.8;
  color: var(--ink);
}

.legal-page h2 {
  background: none;
  padding: 0 0 0 16px;
  border-radius: 0;
  border-left: 6px solid var(--green);
  color: var(--deep);
  font-size: 20px;
  line-height: 1.5;
  margin-top: 40px;
}

.legal-page h2 + p {
  margin-top: 16px;
  line-height: 1.8;
  color: var(--ink);
}

.legal-page ul {
  margin-top: 16px;
  padding-left: 1.4em;
  line-height: 1.8;
  color: var(--ink);
  list-style: disc;
}

.legal-page ul li + li {
  margin-top: 8px;
}

.legal-back {
  margin-top: 48px;
  text-align: center;
}

.thanks-inner {
  text-align: center;
  padding: 40px 0 24px;
}

.thanks-inner h1 {
  text-align: center;
}

body.thanks-page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

body.thanks-page main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.legal-back .button {
  display: flex;
  width: 100%;
  max-width: 600px;
  margin: 0 auto;
  min-height: 0;
  padding: 16px 48px;
}

@media (max-width: 767px) {
  .legal-page {
    padding: 40px 0 64px;
  }

  .legal-page h1 {
    font-size: 24px;
  }

  .legal-page h2 {
    font-size: 18px;
  }
}
