@charset "utf-8";
/* ==========================================================================
   サイト工房 v8.13｜本申し込みフォーム専用スタイル
   --------------------------------------------------------------------------
   - apply/ 配下の6ページだけで読み込みます。
   - 配色・書体・余白・罫線・ボタンは assets/css/site.css を継承します。
     このファイルは申込画面に必要な差分だけを持ちます。
   - v8.9以降の編集方針にならい、白いカードや影は使わず、
     余白・文字階層・細い罫線でまとまりを作ります。
   ========================================================================== */

/* ==========================================================================
   1. ページ骨格
   ========================================================================== */
.apply-main { padding-block: clamp(28px, 4vw, 52px) clamp(44px, 6vw, 88px); }

.apply-wrap {
  width: 100%;
  max-width: 880px;
  margin-inline: auto;
  padding-inline: var(--pad);
}

.apply-head { text-align: center; }

.apply-progress {
  display: block;
  font-family: var(--font-num);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .1em;
  color: var(--brand);
  margin-bottom: 10px;
}

.apply-head h1 {
  font-size: clamp(23px, 3.6vw, 38px);
  line-height: 1.3;
}

.apply-lede {
  margin-top: 14px;
  color: var(--ink-soft);
  font-size: clamp(14.5px, 1.15vw, 16px);
  line-height: 2;
}

/* 進捗の一覧。色だけでなく文字でも現在位置が分かるようにしています。 */
.apply-steps {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 14px;
  margin-top: clamp(18px, 2.4vw, 26px);
  padding-top: clamp(14px, 2vw, 20px);
  border-top: 1px solid var(--line);
  font-size: 12px;
  line-height: 1.7;
  color: var(--ink-mute);
}
.apply-steps li { display: flex; align-items: baseline; gap: 6px; }
.apply-steps .num { font-family: var(--font-num); font-weight: 600; }
.apply-steps [aria-current="step"] {
  color: var(--brand);
  font-weight: 700;
}

.apply-figure {
  margin: clamp(20px, 3vw, 32px) auto 0;
  width: clamp(120px, 22vw, 168px);
}
.apply-figure img { width: 100%; height: auto; }

.apply-figure--complete { margin-top: clamp(24px, 3.4vw, 36px); }

.apply-body { margin-top: clamp(26px, 3.6vw, 42px); }

/* ==========================================================================
   2. 通知・警告
   ========================================================================== */
.apply-note,
.apply-alert {
  margin-top: 18px;
  padding: 14px 16px;
  border: 1.5px solid var(--line);
  background: var(--surface);
  font-size: 14px;
  line-height: 1.9;
  text-align: left;
}
.apply-alert {
  border-color: var(--brand);
  background: var(--brand-tint);
  color: var(--ink);
}
.apply-note[hidden],
.apply-alert[hidden] { display: none; }

.apply-noscript {
  margin-top: 18px;
  padding: 14px 16px;
  border: 1.5px solid var(--brand);
  background: var(--brand-tint);
  font-size: 14px;
  line-height: 1.9;
  text-align: left;
}

/* ==========================================================================
   3. 入力欄
   ========================================================================== */
/* div と fieldset のどちらでも同じ区切りになるよう、まとめて指定します。 */
.field,
fieldset.field {
  margin: 0;
  padding: clamp(20px, 2.6vw, 28px) 0;
  border: 0;
  border-top: 1px solid var(--line-soft);
}
.error-summary + .field { border-top: 0; padding-top: 0; }

.field-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px;
}

.field-label {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(15.5px, 1.3vw, 17px);
  line-height: 1.5;
}

.field-badge {
  flex: none;
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .06em;
  line-height: 1.5;
  padding: 2px 8px;
  border: 1px solid currentColor;
  border-radius: 2px;
}
.field-badge--required { color: var(--brand); }
.field-badge--optional { color: var(--ink-mute); }

.field-hint {
  margin-top: 8px;
  font-size: 13px;
  line-height: 1.85;
  color: var(--ink-mute);
}

.field-control { margin-top: 12px; }

.input,
.textarea,
.select {
  display: block;
  width: 100%;
  min-height: 52px;
  padding: 12px 14px;
  border: 1.5px solid var(--line);
  border-radius: 2px;
  background: var(--surface);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
}
.textarea { min-height: 112px; resize: vertical; }
.input:focus-visible,
.textarea:focus-visible { border-color: var(--brand); }

.field.is-invalid .input,
.field.is-invalid .textarea { border-color: var(--brand); background: var(--brand-tint); }

.field-counter {
  margin-top: 6px;
  font-family: var(--font-num);
  font-size: 12px;
  color: var(--ink-mute);
}
.field-counter.is-over { color: var(--brand); font-weight: 600; }

.field-error {
  margin-top: 8px;
  font-size: 13.5px;
  font-weight: 700;
  line-height: 1.8;
  color: var(--brand);
}
.field-error[hidden] { display: none; }

/* 選択肢 */
.choices { display: grid; gap: 10px; margin: 0; padding: 0; border: 0; }
.choice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-height: 44px;
  padding: 11px 14px;
  border: 1.5px solid var(--line);
  border-radius: 2px;
  background: var(--surface);
  cursor: pointer;
}
.choice:hover { border-color: var(--ink-soft); }
.choice input { flex: none; width: 20px; height: 20px; margin-top: 4px; accent-color: var(--brand); }
.choice input:disabled { cursor: not-allowed; }
.choice-text { display: block; min-width: 0; }
.choice-label { display: block; font-weight: 700; line-height: 1.6; }
.choice-price {
  display: block;
  margin-top: 2px;
  font-family: var(--font-num);
  font-size: 12.5px;
  color: var(--ink-mute);
}

fieldset.field > legend { padding: 0; }

/* 同意チェック */
.consent {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-height: 44px;
  margin-top: clamp(22px, 3vw, 30px);
  padding: 16px;
  border: 1.5px solid var(--line);
  background: var(--surface);
  cursor: pointer;
  text-align: left;
}
.consent input { flex: none; width: 22px; height: 22px; margin-top: 3px; accent-color: var(--brand); }
.consent input:disabled { cursor: not-allowed; }
.consent-text { font-weight: 700; line-height: 1.8; }
.consent:has(input:disabled) { opacity: .62; cursor: not-allowed; }

/* ==========================================================================
   4. エラー要約
   ========================================================================== */
.error-summary {
  margin-bottom: clamp(22px, 3vw, 30px);
  padding: 16px 18px;
  border: 1.5px solid var(--brand);
  background: var(--brand-tint);
  text-align: left;
}
.error-summary[hidden] { display: none; }
.error-summary-title {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--brand);
}
.error-summary-list { margin-top: 8px; display: grid; gap: 4px; }
.error-summary-list a { color: var(--brand); font-weight: 600; }

/* ==========================================================================
   5. 法務文書の表示枠
   ========================================================================== */
.doc-meta {
  display: grid;
  gap: 4px 18px;
  margin: 0 0 clamp(18px, 2.4vw, 24px);
  padding-bottom: clamp(16px, 2.2vw, 20px);
  border-bottom: 1px solid var(--line);
  font-size: 14px;
  text-align: left;
}
@media (min-width: 560px) {
  .doc-meta { grid-template-columns: 8em 1fr; }
}
.doc-meta dt { color: var(--ink-mute); font-size: 13px; }
.doc-meta dd { font-weight: 700; }

.doc-frame { border: 1.5px solid var(--line); background: var(--surface); }
.doc-frame[hidden] { display: none; }
.doc-object { display: block; width: 100%; height: clamp(360px, 62vh, 640px); border: 0; }
.doc-fallback { padding: 20px; font-size: 14px; line-height: 1.9; }

.doc-open { margin-top: 14px; text-align: left; }
.doc-open[hidden] { display: none; }

.doc-status {
  padding: 18px;
  border: 1.5px dashed var(--line);
  background: var(--surface);
  color: var(--ink-soft);
  font-weight: 700;
  text-align: center;
}
.doc-status[hidden] { display: none; }

/* ==========================================================================
   6. 確認一覧
   ========================================================================== */
.review-list {
  display: grid;
  gap: 0;
  margin: 0;
  text-align: left;
}
@media (min-width: 640px) {
  .review-list { grid-template-columns: 14em minmax(0, 1fr); }
}
.review-list dt {
  padding: 14px 0 4px;
  border-top: 1px solid var(--line-soft);
  font-size: 13px;
  font-weight: 700;
  color: var(--ink-mute);
}
.review-list dd {
  padding: 0 0 14px;
  font-size: 15.5px;
  line-height: 1.9;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
@media (min-width: 640px) {
  .review-list dt { padding: 14px 18px 14px 0; }
  .review-list dd { padding: 14px 0; border-top: 1px solid var(--line-soft); }
}

/* ==========================================================================
   7. 操作ボタン
   ========================================================================== */
.apply-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-top: clamp(26px, 3.6vw, 36px);
}
.apply-actions .btn { width: 100%; max-width: 420px; }
.apply-actions .btn[disabled] {
  background: var(--line);
  border-color: var(--line);
  color: var(--ink-mute);
  cursor: not-allowed;
}
.apply-actions .btn--ghost[disabled] { background: transparent; }

.apply-back { font-size: 14.5px; }
.apply-back a { color: var(--ink-soft); }

.after-send {
  margin-top: clamp(24px, 3.2vw, 32px);
  padding: 18px;
  border: 1.5px solid var(--brand);
  background: var(--brand-tint);
  text-align: center;
}
.after-send[hidden] { display: none; }
.after-send p { font-weight: 700; line-height: 1.9; }
.after-send .btn { margin-top: 16px; }

/* ==========================================================================
   8. 完了ページ
   ========================================================================== */
.complete-text {
  margin-top: clamp(6px, 1vw, 12px);
  font-size: clamp(15px, 1.4vw, 17px);
  line-height: 2.1;
  text-align: left;
  max-width: 34em;
  margin-inline: auto;
}

/* ==========================================================================
   9. 簡易フッター
   ========================================================================== */
.apply-footer {
  border-top: 1px solid var(--line);
  padding-block: clamp(24px, 3vw, 34px);
  font-size: 12.5px;
  line-height: 1.9;
  color: var(--ink-mute);
  text-align: center;
}
.apply-footer .copyright { margin-top: 8px; font-family: var(--font-num); }

/* ==========================================================================
   10. 印刷
   ========================================================================== */
@media print {
  .apply-actions, .after-send { display: none !important; }
  body { background: #fff; }
}

/* fieldset の legend も通常の見出し行と同じ並びにします。 */
.field-legend { padding: 0; width: 100%; }
.field-legend .field-head { display: flex; }
