/* ============================================================
   Contact Page  ― お問い合わせページ専用
   ============================================================ */

#contact-page {
  background: var(--color-white);
}

.contact-page-inner {
  max-width: 680px;
  margin: 0 auto;
}

/* ---- リード文 ---- */
.contact-lead {
  font-size: clamp(13px, 1vw, 15px);
  line-height: 2;
  color: rgba(35, 24, 21, 0.75);
  margin-bottom: clamp(36px, 4vw, 52px);
  text-align: justify;
}

/* ---- 電話・FAX ---- */
.contact-tel-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: clamp(40px, 5vw, 64px);
  padding: clamp(24px, 3vw, 36px);
  background: rgba(0, 18, 181, 0.03);
  border-radius: 8px;
  border: 1px solid rgba(0, 18, 181, 0.08);
}

.contact-tel-item {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.contact-tel-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  color: var(--color-blue);
  letter-spacing: 0.08em;
}

.contact-tel-number {
  font-family: var(--font-en);
  font-size: clamp(22px, 2.5vw, 30px);
  font-weight: 700;
  color: var(--color-dark);
  letter-spacing: 0.04em;
  line-height: 1;
}

a.contact-tel-number:hover {
  color: var(--color-blue);
}

/* ---- フォーム ---- */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 0;
  background: #f9f9fc;
  border: 1px solid rgba(0, 18, 181, 0.08);
  border-radius: 12px;
  padding: clamp(28px, 4vw, 48px);
}

.contact-form-row {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 16px;
  align-items: center;
  padding: 18px 0;
  border-bottom: 1px solid rgba(0, 18, 181, 0.07);
}

.contact-form-row:last-of-type {
  border-bottom: none;
}

.contact-form-row--textarea {
  align-items: start;
}

.contact-form-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: var(--color-dark);
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.contact-required {
  font-size: 10px;
  font-weight: 700;
  color: var(--color-white);
  background: var(--color-red);
  padding: 2px 7px;
  border-radius: 3px;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

/* ---- インプット共通 ---- */
.contact-form-input,
.contact-form-select,
.contact-form-textarea {
  width: 100%;
  font-family: var(--font-ja);
  font-size: clamp(13px, 1vw, 15px);
  color: var(--color-dark);
  background: var(--color-white);
  border: 1.5px solid rgba(0, 18, 181, 0.18);
  border-radius: 6px;
  padding: 11px 14px;
  outline: none;
  transition:
    border-color 0.22s cubic-bezier(0.16, 1, 0.3, 1),
    box-shadow 0.22s cubic-bezier(0.16, 1, 0.3, 1);
  appearance: none;
  -webkit-appearance: none;
}

.contact-form-input::placeholder,
.contact-form-textarea::placeholder {
  color: rgba(35, 24, 21, 0.3);
}

.contact-form-input:focus,
.contact-form-select:focus,
.contact-form-textarea:focus {
  border-color: var(--color-blue);
  box-shadow: 0 0 0 3px rgba(0, 18, 181, 0.08);
}

.contact-form-textarea {
  resize: vertical;
  min-height: 140px;
  line-height: 1.8;
}

/* ---- セレクト ---- */
.contact-select-wrap {
  position: relative;
}

.contact-select-arrow {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  color: var(--color-blue);
  pointer-events: none;
}

/* ---- 同意チェック ---- */
.contact-agree {
  margin: clamp(24px, 3vw, 36px) 0 clamp(20px, 2.5vw, 32px);
  display: flex;
  justify-content: center;
}

.contact-agree-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  color: var(--color-dark);
  cursor: pointer;
}

.contact-agree-check {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.contact-agree-box {
  display: inline-block;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(0, 18, 181, 0.3);
  border-radius: 4px;
  flex-shrink: 0;
  background: var(--color-white);
  transition: border-color 0.2s, background 0.2s;
  position: relative;
}

.contact-agree-check:checked + .contact-agree-box {
  background: var(--color-blue);
  border-color: var(--color-blue);
}

.contact-agree-check:checked + .contact-agree-box::after {
  content: '';
  position: absolute;
  left: 4px;
  top: 1px;
  width: 8px;
  height: 12px;
  border: 2px solid var(--color-white);
  border-top: none;
  border-left: none;
  transform: rotate(45deg);
}

.contact-agree-label a {
  color: var(--color-blue);
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* ---- 送信ボタン ---- */
.contact-submit-wrap {
  text-align: center;
}

.contact-submit-btn {
  display: inline-block;
  background: var(--color-dark);
  color: var(--color-white);
  font-family: var(--font-ja);
  font-size: clamp(14px, 1.1vw, 16px);
  font-weight: 700;
  letter-spacing: 0.2em;
  padding: 18px clamp(48px, 6vw, 80px);
  border: none;
  border-radius: 4px;
  cursor: pointer;
  transition:
    background 0.25s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.contact-submit-btn:hover {
  background: var(--color-blue);
  transform: translateY(-2px);
}

/* ---- エラーリスト ---- */
.contact-errors {
  background: #fff0f0;
  border: 1.5px solid #e05252;
  border-radius: 8px;
  padding: 16px 20px;
  margin-bottom: 24px;
  list-style: none;
}

.contact-errors li {
  font-size: 13px;
  color: #c0392b;
  padding: 3px 0;
}

.contact-errors li::before {
  content: '※ ';
}

/* ---- 確認テーブル ---- */
.confirm-table {
  background: #f9f9fc;
  border: 1px solid rgba(0, 18, 181, 0.08);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: clamp(24px, 3vw, 40px);
}

.confirm-row {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 16px;
  padding: 16px 24px;
  border-bottom: 1px solid rgba(0, 18, 181, 0.07);
}

.confirm-row:last-child {
  border-bottom: none;
}

.confirm-label {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-dark);
  flex-shrink: 0;
}

.confirm-value {
  font-size: 14px;
  color: var(--color-dark);
  line-height: 1.7;
  word-break: break-all;
  white-space: pre-wrap;
}

/* ---- 確認ボタン群 ---- */
.confirm-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
}

.btn-back {
  display: inline-block;
  background: transparent;
  color: var(--color-dark);
  font-family: var(--font-ja);
  font-size: clamp(13px, 1vw, 15px);
  font-weight: 700;
  letter-spacing: 0.12em;
  padding: 16px clamp(28px, 4vw, 48px);
  border: 2px solid rgba(35, 24, 21, 0.3);
  border-radius: 4px;
  cursor: pointer;
  transition: border-color 0.22s;
}

.btn-back:hover {
  border-color: var(--color-dark);
}

/* ---- 完了画面 ---- */
.contact-complete {
  text-align: center;
  padding: clamp(40px, 6vw, 80px) 0;
}

.contact-complete-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--color-blue);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto clamp(20px, 2.5vw, 28px);
}

.contact-complete h2 {
  font-size: clamp(18px, 2vw, 24px);
  font-weight: 700;
  margin-bottom: 16px;
  letter-spacing: 0.04em;
}

.contact-complete p {
  font-size: clamp(13px, 1vw, 15px);
  line-height: 2;
  color: rgba(35, 24, 21, 0.75);
  margin-bottom: clamp(28px, 3vw, 40px);
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 768px) {
  .contact-tel-wrap {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .contact-form-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .confirm-row {
    grid-template-columns: 1fr;
    gap: 4px;
    padding: 14px 18px;
  }

  .confirm-actions {
    flex-direction: column-reverse;
    align-items: stretch;
  }

  .btn-back {
    text-align: center;
  }
}

@media (max-width: 480px) {
  .contact-form {
    padding: clamp(20px, 5vw, 32px) clamp(16px, 4vw, 24px);
  }
}
