*, *::before, *::after { box-sizing: border-box; line-height: 1.5; }

:root {
  --font-family: "Helvetica Neue", Arial, "Hiragino Kaku Gothic ProN", "Hiragino Sans", Meiryo, sans-serif;
  --primary-blue: #005bac;
  --text: #3d3d3d;
  --text-sub: #4f5a64;
  --page-bg: #ecf1f4;
  --white: #ffffff;
  --border: #8795a3;
  --placeholder: #66727e;
  --req: #b3261e;
  --opt: #5f6b76;
}

html { font-size: 16px; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--page-bg);
  color: var(--text);
  font-family: var(--font-family);
  overflow-wrap: break-word;
}

a { color: var(--primary-blue); text-decoration: none; transition: 0.3s; }
a:hover, a:focus { text-decoration: underline; opacity: 0.7; }

.container {
  display: grid;
  grid-template-columns: minmax(360px, 35%) 1fr;
  min-height: 100vh;
}

.container > aside { background: var(--white); }
.aside__wrap { padding: 40px 3rem; max-width: 560px; margin: 0 auto; }
aside p { margin: 0 0 12px; font-size: clamp(14px, 1.11vw, 16px); line-height: 1.7; }

.form-header_logo { margin-bottom: 12px; }
.form-header_logo img { max-width: 100%; height: auto; }
.form-header_title { margin: 0 0 16px; font-size: calc(1.3rem + .6vw); color: var(--primary-blue); }

.panel { margin: 0 0 16px; padding: 16px; background: #f5f8fa; border-radius: 6px; }
.panel__title { margin: 0 0 8px; font-size: 16px; }
.panel p, .panel li { font-size: 15px; line-height: 1.8; }
.panel p { margin: 0 0 8px; }
.panel__img { margin: 14px 0; }
.panel__img img { display: block; width: 100%; max-width: 360px; height: auto; margin: 0 auto; border: 1px solid #d5dce3; }
.panel ol { margin: 0; padding-left: 1.3em; }

.docprev { margin: 0 0 16px; }
.docprev__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.docprev__item { margin: 0; }
.docprev__item--cover { grid-column: 1 / -1; }
.docprev__item img { display: block; width: 100%; height: auto; border: 1px solid #d5dce3; background: #f5f8fa; }
.docprev figcaption { margin-top: 4px; font-size: 12px; color: var(--text-sub); }
.docprev__points { margin: 10px 0 0; padding-left: 1.3em; font-size: 14px; line-height: 1.8; }

.telbox { margin: 0 0 16px; padding: 14px 16px; background: #f5f8fa; border: 1px solid #d5dce3; border-radius: 6px; text-align: center; }
.telbox p { margin: 0; }
.telbox .telbox__label { font-size: 14px; font-weight: bold; line-height: 1.5; }
.telbox .telbox__num { display: flex; align-items: center; justify-content: center; gap: 6px; margin: 2px 0 0; }
.telbox .telbox__num svg { flex: none; }
.telbox .telbox__num a { display: inline-flex; align-items: center; min-height: 44px; font-size: 26px; font-weight: bold; }
.telbox--sp { display: none; margin: 16px 0 0; }
.sales-note { font-size: 13px; }
.sales-note--sp { display: none; margin: 12px 0 0; }

.container > main { display: flex; align-items: flex-start; justify-content: center; padding: 24px 20px 40px; }
.container form { width: 100%; max-width: 600px; background: var(--white); border-radius: 8px; padding: 24px 28px; }
.form__title { margin: 0 0 16px; font-size: 20px; }
.field { margin: 0 0 14px; }

.lbl { display: inline-block; margin-bottom: 6px; font-weight: bold; font-size: 15px; }
.lbl--req::after, .lbl--opt::after, .badge-req {
  display: inline-block;
  margin-left: 6px;
  padding: 2px 8px;
  border-radius: 2px;
  color: var(--white);
  font-size: 12px;
  font-weight: bold;
  line-height: 1.2;
  vertical-align: text-bottom;
}
.lbl--req::after, .badge-req { background: var(--req); content: "\5fc5 \9808 "; }
.lbl--opt::after { background: var(--opt); content: "\4efb \610f "; }

.input, .textarea {
  display: block;
  width: 100%;
  min-height: 48px;
  padding: 0.5rem 0.75rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 4px;
  color: var(--text);
  font-family: var(--font-family);
  font-size: 16px; 
}
.textarea { min-height: 92px; resize: vertical; }
.input:hover, .textarea:hover { border-color: var(--text); }
.input:focus-visible, .textarea:focus-visible, .check:focus-visible, .submit:focus-visible {
  outline: 3px solid var(--primary-blue);
  outline-offset: 2px;
}
.input:user-invalid { border-color: var(--req); }
::placeholder { color: var(--placeholder); opacity: 1; }

.name-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.hint { margin: 6px 0 0; font-size: 13px; color: var(--text-sub); }
.hint--warn { color: var(--req); font-weight: bold; }

.privacy { display: flex; align-items: flex-start; gap: 12px; margin: 0 0 20px; font-size: 14px; }
.check { flex: none; width: 24px; height: 24px; margin: 0; cursor: pointer; }
.privacy__text { margin: 0; line-height: 1.8; }
.privacy__agree { cursor: pointer; font-weight: bold; }

.submit {
  position: relative;
  display: block;
  width: 100%;
  min-height: 52px;
  padding: 0.8rem;
  border: 0;
  border-radius: 4px;
  background: var(--primary-blue);
  color: var(--white);
  font: inherit;
  font-weight: bold;
  font-size: 17px;
  cursor: pointer;
  transition: 0.3s;
}
.submit:hover { opacity: 0.8; }
.spinner {
  display: none;
  position: absolute;
  right: 16px;
  top: 50%;
  width: 22px;
  height: 22px;
  margin-top: -11px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top-color: var(--white);
  border-radius: 50%;
  animation: spin 1s ease-in-out infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.after { margin: 12px 0 0; font-size: 13px; line-height: 1.7; color: var(--text-sub); }

@media only screen and (max-width: 750px) {
  .container { grid-template-columns: 1fr; min-height: 0; }
  .aside__wrap { padding: 1.25rem 1rem 0.5rem; max-width: none; }
  aside p { font-size: 16px; }
  .form-header_logo { display: flex; justify-content: center; }
  .form-header_title { text-align: center; }
  .container > main { padding: 16px 8px 32px; }
  .container form { padding: 20px 14px; }

  .docprev { display: flex; flex-direction: column; }
  .docprev__grid { display: contents; }
  .docprev__item--cover { order: 1; }
  .docprev__points { order: 2; }
  .docprev .docprev__item--page { order: 3; margin-top: 16px; }

  .telbox--aside { display: none; }
  .telbox--sp { display: block; }
  .sales-note--aside { display: none; }
  .sales-note--sp { display: block; }
}
