:root {
  --ink: #2d2830;
  --muted: #655e68;
  --line: #c9c2ca;
  --line-strong: #756d78;
  --surface: #ffffff;
  --base: #f7f4f1;
  --pale: #f1ecef;
  --main: #3b2637;
  --main-hover: #2c1b29;
  --main-active: #21131f;
  --gold: #cba955;
  --gold-light: #f3df9a;
  --cream: #fff7df;
  --error: #b3212b;
  --focus: #ffd43b;
  --cta-red: #7b1020;
  --cta-red-hover: #5c0915;
  --cta-red-active: #4a0811;
  --sans: "Noto Sans JP", sans-serif;
  --serif: "Noto Serif JP", serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; background: var(--main); }
body { margin: 0; color: var(--ink); background: var(--base); font: 16px/1.8 var(--sans); -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button, input, textarea { font: inherit; }
button { cursor: pointer; }
[hidden] { display: none !important; }
.honeypot { position: absolute !important; left: -10000px !important; width: 1px !important; height: 1px !important; overflow: hidden !important; }

:where(a, button, input, select, textarea):focus-visible {
  outline: 3px solid #000;
  box-shadow: 0 0 0 6px var(--focus);
  outline-offset: 2px;
}

.skip-link { position: fixed; z-index: 1000; top: 8px; left: 8px; padding: 10px 16px; transform: translateY(-160%); color: #fff; background: #000; }
.skip-link:focus { transform: none; }
.form-container { width: min(1120px, calc(100% - 48px)); margin-inline: auto; }
.form-container-narrow { width: min(820px, calc(100% - 48px)); }
.pc-only { display: block; }

.form-header { color: #fff; background: rgba(35, 21, 32, .98); border-bottom: 1px solid #cba95588; }
.header-inner { display: flex; align-items: center; width: min(1120px, calc(100% - 48px)); min-height: 82px; margin-inline: auto; gap: 24px; }
.logo-link { display: inline-flex; min-height: 44px; align-items: center; }
.logo-link img { width: 150px; }

.form-hero { position: relative; overflow: hidden; padding: 72px 0 64px; color: #fff; background: linear-gradient(135deg, #2a1826, #493141 58%, #2d2032); text-align: center; }
.form-hero::before, .form-hero::after { position: absolute; content: ""; pointer-events: none; border: 1px solid #cba95533; border-radius: 50%; }
.form-hero::before { width: 420px; height: 420px; top: -300px; left: -80px; }
.form-hero::after { width: 300px; height: 300px; right: -120px; bottom: -240px; }
h1 { margin: 0; color: var(--cream); font: 900 clamp(34px, 5vw, 52px)/1.45 var(--serif); letter-spacing: .04em; }
.hero-copy { margin: 22px 0 0; font-size: 17px; }

.form-section { padding: 72px 0 96px; }
.form-notice { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin: 0 0 20px; color: var(--muted); font-size: 14px; }
.form-notice p { margin: 0; }
.form-notice strong { color: var(--main); font-size: 16px; }
.required-mark { color: var(--error); font-size: .82em; font-weight: 700; white-space: nowrap; }
.optional-mark { color: var(--muted); font-size: .82em; font-weight: 500; white-space: nowrap; }

.progress { margin-bottom: 24px; }
.progress ol { position: relative; display: grid; grid-template-columns: repeat(6, 1fr); margin: 0; padding: 0; list-style: none; }
.progress ol::before { position: absolute; z-index: 0; content: ""; top: 18px; right: 8.33%; left: 8.33%; height: 2px; background: var(--line); }
.progress li { position: relative; z-index: 1; display: grid; justify-items: center; gap: 5px; color: var(--muted); }
.progress li span { display: grid; width: 38px; height: 38px; place-items: center; border: 2px solid var(--line-strong); border-radius: 50%; background: var(--base); font-weight: 700; line-height: 1; }
.progress li small { font-size: 11px; font-weight: 700; }
.progress li.is-complete span { border-color: var(--main); color: #fff; background: var(--main); }
.progress li[aria-current="step"] { color: var(--main); }
.progress li[aria-current="step"] span { border-color: var(--gold); color: var(--main); background: var(--gold-light); box-shadow: 0 0 0 4px #cba95524; }

.form-card { padding: clamp(28px, 5vw, 56px); border: 1px solid #d8d2d8; border-radius: 12px; background: var(--surface); box-shadow: 0 18px 50px #291b2520; }
.step-number { margin: 0 0 12px; color: #7a5a22; font: 700 12px/1.4 var(--serif); letter-spacing: .2em; }
fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
legend, .step-title { width: 100%; margin: 0; padding: 0; color: var(--main); font: 700 clamp(23px, 3.2vw, 31px)/1.55 var(--serif); }
.support-text { margin: 10px 0 0; color: var(--muted); font-size: 14px; }
.error-text { margin: 12px 0 0; color: var(--error); font-size: 14px; font-weight: 700; }

.choice-grid { display: grid; gap: 12px; margin-top: 28px; }
.choice-grid-two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.choice { position: relative; display: block; min-width: 0; cursor: pointer; }
.choice input { position: absolute; width: 1px; height: 1px; margin: -1px; clip: rect(0 0 0 0); clip-path: inset(50%); overflow: hidden; white-space: nowrap; }
.choice span { position: relative; display: flex; min-height: 58px; align-items: center; padding: 12px 18px 12px 52px; border: 2px solid var(--line); border-radius: 6px; background: #fff; font-weight: 500; transition: border-color .18s, background-color .18s, box-shadow .18s; }
.choice span::before { position: absolute; content: ""; left: 18px; width: 20px; height: 20px; border: 2px solid var(--line-strong); background: #fff; }
.choice input[type="radio"] + span::before { border-radius: 50%; }
.choice input[type="checkbox"] + span::before { border-radius: 3px; }
.choice input[type="checkbox"]:checked + span::before { border-color: var(--main); background: var(--main); }
.choice input[type="checkbox"]:checked + span::after { position: absolute; content: ""; left: 24px; top: 50%; width: 7px; height: 12px; border: solid #fff; border-width: 0 2px 2px 0; transform: translateY(-62%) rotate(45deg); }
.choice input[type="radio"]:checked + span::before { border: 6px solid var(--main); }
.choice input:checked + span { border-color: var(--main); background: #f6f0f4; box-shadow: inset 0 0 0 1px var(--main); }
.choice input:focus-visible + span { outline: 3px solid #000; outline-offset: 2px; box-shadow: 0 0 0 6px var(--focus); }
.choice:hover span { border-color: var(--main); }
.choice-wide { grid-column: 1 / -1; }

.file-field { margin-top: 24px; padding: 24px; border: 2px dashed var(--line-strong); border-radius: 8px; background: #faf8fa; }
.field-label { display: block; margin: 0 0 5px; color: var(--ink); font-weight: 700; }
.photo-slots { display: grid; gap: 12px; margin-top: 18px; }
.photo-slot { min-width: 0; padding: 14px; border: 1px solid var(--line); border-radius: 6px; background: #fff; }
.photo-slot.is-selected { border-color: var(--gold); box-shadow: inset 3px 0 0 var(--gold); }
.photo-slot-label { display: block; margin-bottom: 7px; color: var(--main); font-weight: 700; }
.photo-input { display: block; width: 100%; min-width: 0; padding: 7px; border: 1px solid var(--line-strong); border-radius: 5px; background: #fff; font: inherit; }
.photo-input::file-selector-button { min-height: 44px; margin-right: 12px; padding: 8px 16px; border: 1px solid var(--main); border-radius: 4px; color: var(--main); background: #fff; font-weight: 700; cursor: pointer; }
.photo-input:hover::file-selector-button { color: #fff; background: var(--main); }
.photo-input:disabled { cursor: wait; opacity: .55; }
.photo-slot-result { display: flex; min-width: 0; align-items: center; justify-content: space-between; gap: 10px; margin-top: 8px; }
.photo-slot-result p { min-width: 0; margin: 0; color: var(--muted); font-size: 13px; overflow-wrap: anywhere; }
.photo-slot.is-selected .photo-slot-result p { color: var(--ink); font-weight: 500; }
.photo-remove { min-width: 58px; min-height: 36px; padding: 5px 10px; border: 1px solid var(--line-strong); border-radius: 4px; color: var(--main); background: #fff; font-weight: 700; }
.photo-remove:hover { border-color: var(--main); background: #f4eef2; }
.file-status { margin: 10px 0 0; color: var(--muted); font-size: 13px; }
.file-field[aria-busy="true"] { border-color: var(--gold); background: var(--cream); }
.file-field[aria-invalid="true"] { border-color: var(--error); background: #fff8f8; }

.field-list { display: grid; gap: 28px; margin-top: 30px; }
.field input:not([type="file"]), .field textarea, .field select { display: block; width: 100%; margin-top: 10px; border: 2px solid var(--line-strong); border-radius: 5px; color: var(--ink); background: #fff; transition: border-color .18s, box-shadow .18s; }
.field input:not([type="file"]) { min-height: 54px; padding: 10px 14px; }
.field select { min-height: 54px; padding: 10px 42px 10px 14px; }
.field textarea { min-height: 150px; padding: 14px; resize: vertical; }
.field input:hover, .field textarea:hover, .field select:hover { border-color: var(--main); }
.field input:user-invalid, .field textarea:user-invalid, .field select:user-invalid { border-color: var(--error); background-color: #fff8f8; }
.field-short { max-width: 360px; }
.field-medium { max-width: 520px; }
.name-fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 10px; }
.sub-label { display: block; color: var(--muted); font-size: 13px; font-weight: 700; }
.name-fields input { margin-top: 5px !important; }

.privacy-note { margin-top: 34px; color: var(--muted); font-size: 14px; }
.privacy-note p { margin: 0; }
.privacy-note p + p { margin-top: 5px; }
.privacy-note a { color: #4c2d48; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

.step-actions { display: flex; justify-content: space-between; align-items: center; gap: 18px; margin-top: 42px; }
.step-actions-first { justify-content: flex-end; }
.button { display: inline-flex; min-width: 176px; min-height: 56px; align-items: center; justify-content: center; gap: 20px; padding: 12px 25px; border-radius: 5px; font-weight: 700; line-height: 1.5; transition: background-color .18s, border-color .18s, transform .18s; }
.button-primary { border: 2px solid var(--cta-red); color: #fff; background: linear-gradient(135deg, #8e1a2b, var(--cta-red) 56%, #5c0915); box-shadow: 0 8px 20px #4a08112e; }
.button-primary:hover { border-color: var(--cta-red-hover); background: var(--cta-red-hover); transform: translateY(-1px); }
.button-primary:active { border-color: var(--cta-red-active); background: var(--cta-red-active); transform: none; }
.button-primary span { font-size: 25px; line-height: 1; }
.button-secondary { border: 2px solid var(--main); color: var(--main); background: #fff; }
.button-secondary:hover { background: #f4eef2; }
.button:disabled { cursor: wait; opacity: .72; transform: none; }

.review-intro { margin: 12px 0 0; color: var(--muted); }
.review-list { margin: 30px 0 0; border-top: 1px solid var(--line); }
.review-list > div { display: grid; grid-template-columns: 180px minmax(0, 1fr); border-bottom: 1px solid var(--line); }
.review-list dt, .review-list dd { margin: 0; padding: 16px 18px; }
.review-list dt { background: #f4f0f2; font-weight: 700; }
.review-list dd { overflow-wrap: anywhere; white-space: pre-wrap; }

.form-footer { padding: 52px 24px 28px; color: #fff; background: #21131f; }
.footer-inner { width: min(1120px, 100%); margin-inline: auto; text-align: center; }
.footer-inner > img { width: 150px; margin: 0 auto 22px; }
.license { margin: 0; color: #e7dfe5; font-size: 13px; }
.form-footer nav { display: flex; justify-content: center; flex-wrap: wrap; gap: 10px 28px; margin-top: 24px; }
.form-footer nav a { min-height: 44px; display: inline-flex; align-items: center; color: #fff; font-size: 13px; text-underline-offset: 4px; }
.form-footer nav a:hover { color: var(--gold-light); }
.form-footer nav small { margin-left: 5px; padding: 1px 5px; border: 1px solid #cba95588; color: var(--gold-light); font-size: 9px; text-decoration: none; }
.copyright { margin: 26px 0 0; padding-top: 20px; border-top: 1px solid #ffffff22; color: #c8bbc4; font-size: 11px; }

.thanks-section { display: grid; min-height: 560px; padding: 88px 0 104px; place-items: center; }
.thanks-card { padding: clamp(38px, 7vw, 72px); border: 1px solid #d8d2d8; border-radius: 12px; background: var(--surface); box-shadow: 0 18px 50px #291b2520; text-align: center; }
.thanks-card h1 { color: var(--main); font-size: clamp(30px, 4.5vw, 46px); }
.thanks-message { max-width: 680px; margin: 30px auto 0; color: var(--ink); line-height: 2; }
.thanks-message p { margin: 0; }
.thanks-message p + p { margin-top: 18px; }
.thanks-actions { display: flex; justify-content: center; margin-top: 38px; }
.thanks-actions .button { text-decoration: none; }

@media (max-width: 767px) {
  body { font-size: 15px; }
  .form-container, .form-container-narrow, .header-inner { width: calc(100% - 32px); }
  .pc-only { display: none; }
  .header-inner { min-height: 66px; }
  .logo-link img { width: 116px; }
  .form-hero { padding: 48px 0 44px; }
  h1 { font-size: 31px; }
  .hero-copy { margin-top: 16px; font-size: 15px; text-align: left; }
  .form-section { padding: 46px 0 72px; }
  .form-notice { display: block; }
  .form-notice p + p { margin-top: 5px; }
  .progress { margin-inline: -3px; }
  .progress ol::before { top: 15px; }
  .progress li span { width: 32px; height: 32px; font-size: 13px; }
  .progress li small { font-size: 9px; }
  .form-card { padding: 28px 20px 32px; border-radius: 8px; }
  legend, .step-title { font-size: 23px; }
  .choice-grid-two { grid-template-columns: 1fr; }
  .choice-wide { grid-column: auto; }
  .choice span { min-height: 56px; padding-left: 49px; }
  .choice span::before { left: 16px; }
  .choice input[type="checkbox"]:checked + span::after { left: 22px; }
  .file-field { padding: 20px 16px; }
  .photo-input::file-selector-button { display: block; width: 100%; margin: 0 0 6px; }
  .field-short, .field-medium { max-width: none; }
  .name-fields { grid-template-columns: 1fr; gap: 16px; }
  .step-actions { flex-direction: column-reverse; align-items: stretch; gap: 12px; margin-top: 34px; }
  .step-actions-first { flex-direction: column; }
  .button { width: 100%; min-width: 0; }
  .button-secondary { min-height: 50px; }
  .review-list > div { display: block; }
  .review-list dt { padding-bottom: 7px; }
  .review-list dd { padding-top: 7px; }
  .form-footer { padding-inline: 16px; }
  .form-footer nav { display: grid; justify-items: center; gap: 4px; }
  .thanks-section { min-height: 480px; padding: 56px 0 72px; }
  .thanks-card { padding: 34px 20px 38px; }
  .thanks-card h1 { font-size: 28px; }
  .thanks-message { margin-top: 24px; text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
