@charset "utf-8";

.main {
  margin-top: 150px;
}

.contact_content {
  margin: 0 clamp(20px, 10vw, 140px);
}

.contact_p {
  text-align: center;
}

/* フォーム全体 */
.contact_form {
  max-width: 700px;
  margin: 100px auto;
}

/* dl */
.form_list {
  margin: 0;
}

/* 1行 */
.form_row {
  display: grid;
  grid-template-columns: 100px 1fr; /* ←少し広めおすすめ */
  gap: 40px; /* ←これ重要 */
  align-items: center;
  margin-bottom: 25px;
}

/* 注釈 */
.form_note {
  font-size: 12px;
  margin-bottom: 18px;

  display: grid;
  grid-template-columns: 100px 1fr;
  gap: 40px; /* ←これを絶対揃える！！！ */
}

/* 左カラムを空ける */
.form_note::before {
  content: "";
}

/* dt（ラベル） */
.form_row dt {
  text-align: left;
  font-size: 18px;
}

/* dd（入力） */
.form_row dd {
  flex: 1;
}

/* input / textarea */
.form_row input,
.form_row textarea {
  width: 100%;
  padding: 10px;
  border: none;
  background: #f5f2ec;
  color: #192030;
}

/* textarea */
.form_row textarea {
  height: 150px;
  resize: none;
}

/* ボタン */
.contact_btn {
  margin-top: 100px;
  padding: 12px 40px;
  background: #fff0d1;
  border: none;
  cursor: pointer;
}

input:focus,
textarea:focus {
  outline: none;
  box-shadow: 0 0 8px rgba(245, 242, 236, 0.8);
}

/* =========================
  タブレット（768px以下）
========================= */
@media (max-width: 768px) {
  .contact_form {
    max-width: 90%;
  }

  .form_row {
    grid-template-columns: 120px 1fr;
    gap: 20px;
  }

  .form_note {
    grid-template-columns: 120px 1fr;
    gap: 20px;
  }
}

/* =========================
  スマホ（480px以下）
========================= */
@media (max-width: 480px) {
  /* フォーム幅 */
  .contact_form {
    max-width: 100%;
  }

  /* 1行を縦並びに */
  .form_row {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  /* ラベル */
  .form_row dt {
    width: 100%;
  }

  /* 注釈も縦に */
  .form_note {
    display: block;
    margin-bottom: 20px;
  }

  .form_note::before {
    content: none;
  }

  /* 入力欄 */
  input,
  textarea {
    width: 100%;
  }

  /* ボタン中央 */
  .contact_btn {
    display: block;
    margin: 40px auto 0;
    z-index: 10;
  }
}
