@charset "utf-8";

.p-contact-form-container {
  --form-color-note: #ca3021;

  box-sizing: content-box;
  max-width: 768px;
  margin-right: auto;
  margin-left: auto;
  padding: 40px 20px;
  font-size: 1.6rem;
}

.c-error-message {
  display: block;
  margin-top: 0.5em;
  color: var(--form-color-note);
  font-size: 1.5rem;
  font-weight: 500;
}

.p-contact-form {
  margin-top: 48px;
}

.p-contact-form-heading {
  margin-bottom: 60px;
  font-size: clamp(24px, 6vw, 32px);
  font-family: "Zen Kaku Gothic New", sans-serif;
  color: black;
  position: relative;
  text-align: center;
  letter-spacing: 0.2rem;
}

.p-contact-form-heading::before {
  position: absolute;
  content: attr(data-en);
  font-size: clamp(40px, 10vw, 48px);
  font-family: "Oswald", sans-serif;
  color: rgba(0, 153, 214, 0.3);
  font-weight: 400;
  top: 0.5vw;
  left: 50%;
  transform: translateX(-50%);
  z-index: -1;
  white-space: nowrap;
}

.p-contact-form-lead {
  max-width: fit-content;
  margin-right: auto;
  margin-left: auto;
  font-size: clamp(1.5rem, 3.5vw, 1.6rem);
  line-height: 1.8;
}

.p-contact-form__block {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.p-contact-form__block + .p-contact-form__block {
  margin-top: 32px;
}

.p-contact-form__block[data-group] {
  display: none; /* JS読み込み完了までの非表示 */
}

.p-contact-form__label {
  display: flex;
  align-items: baseline;
  gap: 8px;
  font-weight: 500;
}

.p-contact-form__label::before {
  content: "任意";
  padding: 4px 0.5em 5px;
  background-color: #333;
  color: #fff;
  font-size: 1.4rem;
}

.p-contact-form__label.is-required::before {
  content: "必須";
  background-color: var(--form-color-note);
}

.p-contact-form__note {
  margin-top: 0.5em;
  color: #555;
  font-size: 15px;
}

.p-privacy-policy-block {
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-width: fit-content;
  margin-top: 48px;
  margin-right: auto;
  margin-left: auto;
  padding: 32px;
  border: 1px dashed #ccc;
  align-items: center;
  text-align: center;
}

.p-contact-form__privacy {
  margin-bottom: 10px;
  font-size: 1.5rem;
}

.p-contact-form__privacy a {
  color: #00a0e9;
  text-decoration: underline;
}
.p-contact-form__privacy a:hover {
  text-decoration: none;
}

.p-contact-form__privacy-checkbox {
  font-weight: 500;
}

/* エラー */
.p-contact-form-error-title {
  margin-bottom: 1em;
  color: var(--form-color-note);
  font-size: 1.8rem;
  font-weight: bold;
  text-align: center;
}

/* form部品
---------------------------------------------- */
.c-form-input,
.c-form-textarea,
.c-form-select {
  /* ▼標準の見た目をリセット */
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-color: transparent;

  /* ▼基本のスタイル */
  display: block;
  width: 100%;
  padding: 12px;
  border: 1px solid #ccc;
  border-radius: 4px;
  background-color: #fff;
  color: #333;
  font-family: inherit; /* bodyのフォントを継承 */
  font-size: 16px;
  line-height: 1.5;
  transition: border-color 0.3s, box-shadow 0.3s;

  /* ▼paddingとborderを含めてwidth:100%にするための必須設定 */
  box-sizing: border-box;
}

/* --- 2. select要素の個別調整 --- */
.c-form-select {
  /* ▼独自の矢印を追加 */
  background-image: url('data:image/svg+xml;charset=utf-8,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path fill="none" stroke="%23333" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="m2 5 6 6 6-6"/></svg>');
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px 16px;
  padding-right: 40px; /* 矢印と文字が被らないように余白を確保 */
}

/* --- 3. textareaの個別調整 --- */
.c-form-textarea {
  resize: vertical; /* 垂直方向のみリサイズ可能にする */
  min-height: 120px;
}

/* --- 4. フォーカス時のスタイル --- */
.c-form-input:focus,
.c-form-textarea:focus,
.c-form-select:focus {
  outline: none; /* 標準の青い枠線を消す */
  border-color: #3498db; /* 代わりの枠線色 */
  box-shadow: 0 0 5px rgba(52, 152, 219, 0.5); /* ほのかに光る効果 */
}

/* --- 5. プレースホルダーのスタイル --- */
.c-form-input::placeholder,
.c-form-textarea::placeholder {
  color: #afafaf;
  opacity: 1; /* Firefoxでの半透明化を防ぐ */
}

/* --- 6. 無効化（disabled）時のスタイル --- */
.c-form-input:disabled,
.c-form-textarea:disabled,
.c-form-select:disabled {
  background-color: #f1f1f1;
  cursor: not-allowed;
  opacity: 0.7;
}

/* 郵便番号 */
.c-form-input.c-form-input--zip {
  max-width: 200px;
}

/* ボタンなどフォームアクション
---------------------------------------------- */
/* --- ボタンの共通ベーススタイル --- */
.p-form-button {
  display: inline-block; /* 横並びにするため */
  border: none;
  padding: 12px 30px;
  font-size: 1.6rem;
  font-weight: 500;
  line-height: 1.5;
  border-radius: 4px;
  background-color: #00a0e9;
  color: white;
  border: 1px solid #00a0e9;
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  transition: all 0.2s ease-in-out;
}

.p-form-button:hover {
  opacity: 0.5;
  /* filter: brightness(1.2); */
}

.p-form-button--secondary {
  background-color: #f1f1f1;
  border: 1px solid #ccc;
  color: #333;
}
.p-form-button--secondary:hover {
  /* filter: brightness(0.9); */
}

/* フォームアクション */
.p-contact-form__actions {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin-top: 40px;
}

/* 確認画面
---------------------------------------------- */
.c-dl-table {
  width: 100%;
  border: 1px solid #dee2e6;
  border-radius: 4px;
  overflow: hidden;

  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
}

.c-dl-table dt,
.c-dl-table dd {
  display: grid;
  height: 100%;
  margin: 0;
  padding: 20px;
  border-top: 1px solid #dee2e6;
}

.c-dl-table dt:first-of-type,
.c-dl-table dd:first-of-type {
  border-top: none;
}

.c-dl-table dt {
  display: grid;
  font-weight: bold;
  color: #00a0e9;
}

.c-dl-table dd {
  line-height: 1.7;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

@media (max-width: 600px) {
  .c-dl-table {
    grid-template-columns: minmax(0, 1fr);
  }

  .c-dl-table dd {
    padding-top: 0;
    border-top: none;
  }
}
