/* Capacity intake: preserve the existing form and request.js state hooks. */
.request { max-width: 800px; padding: 88px 0 104px; }
.request-head { max-width: 720px; margin: 0 auto 44px; text-align: center; }
.request-head h1 {
  margin: 0; font: 500 clamp(40px, 4.45vw, 64px)/1.02 var(--display);
  letter-spacing: -.035em; text-wrap: balance;
}
.request-head h1 > span { display: block; color: var(--blue); }
.request-head p {
  max-width: 580px; margin: 24px auto 0; color: var(--muted);
  font: 400 16px/1.6 var(--sans); text-wrap: balance;
}
.choose { display: flex; flex-direction: column; gap: 12px; max-width: 440px; margin: 0 auto; }
.choose[hidden], .direct-booking[hidden], .audience-back[hidden], .request-panel[hidden] { display: none; }
.request:has(> .choose:not([hidden])) { min-height: calc(100vh - 220px); min-height: calc(100dvh - 220px); }
.choose-option {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  min-height: 64px; padding: 0 24px; border: 1px solid var(--line); background: #fff;
  color: var(--ink); font: 500 18px/1.3 var(--display); letter-spacing: -.02em; text-decoration: none;
  transition: border-color .2s ease, color .2s ease;
}
.choose-option span { color: var(--blue); }
.choose-option:hover { border-color: var(--blue); color: var(--blue); }
.choose-option:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
.request-head .direct-booking {
  margin: 12px auto 0; color: var(--muted); text-align: center;
  font: 400 14px/1.6 var(--sans);
}
.direct-booking a { display: inline-block; padding-block: 4px; color: var(--blue); text-decoration: none; }
.direct-booking a:hover { color: var(--blue-dark); }
.audience-back {
  display: inline-flex; align-items: center; min-height: 44px; margin-bottom: 8px;
  color: var(--muted); font: 400 13px/1 var(--mono); text-decoration: none;
}
.audience-back:hover { color: var(--ink); }
.request-panel { min-width: 0; padding: 40px; border: 1px solid var(--line); background: #fff; }
.request-form { display: flex; flex-direction: column; gap: 28px; }
.request-form[hidden], .request-done[hidden], .form-error[hidden], .suggestions[hidden],
.remove-model[hidden], .add-model[hidden] { display: none; }
.form-section { display: flex; flex-direction: column; gap: 20px; padding-top: 28px; border-top: 1px solid var(--line); }
.form-section:first-child { padding-top: 0; border-top: 0; }
.form-section > h2 { margin: 0; font: 500 26px/1.2 var(--display); letter-spacing: -.025em; }
.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; margin: 0; padding: 0; border: 0; }
.field-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px; }
.field > label, .field legend, .chips-label {
  padding: 0; color: var(--muted); font: 400 11px/1.55 var(--mono);
  letter-spacing: .035em; text-transform: uppercase;
}
.field legend { margin-bottom: 8px; }
.req { font-style: normal; color: var(--blue); }
.field input, .field select, .field textarea {
  width: 100%; min-width: 0; min-height: 48px; padding: 11px 14px;
  border: 1px solid #d9d6cf; border-radius: 0; background: #fff;
  color: var(--ink); font: 400 16px/1.5 var(--sans);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.field select {
  appearance: none; padding-right: 40px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M2 4l4 4 4-4' fill='none' stroke='%23302e23' stroke-width='1.4'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.field textarea { min-height: 112px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: #8a8578; opacity: 1; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--blue); box-shadow: 0 0 0 2px rgba(49, 92, 218, .12);
}
.field input[type="number"] { -moz-appearance: textfield; appearance: textfield; }
.field input[type="number"]::-webkit-outer-spin-button,
.field input[type="number"]::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.field input[aria-invalid="true"], .field select[aria-invalid="true"],
.chips[aria-invalid="true"] .chip span { border-color: var(--error); }
.field small { color: var(--muted); font-size: 12px; line-height: 1.5; }
.model-blocks { display: flex; flex-direction: column; gap: 20px; }
.model-block {
  position: relative; display: flex; flex-direction: column; gap: 20px;
  min-width: 0; margin: 0; padding: 24px; border: 1px solid var(--line); background: var(--paper);
}
.model-block > .field:first-of-type > label { display: flex; align-items: center; min-height: 32px; padding-right: 80px; }
.remove-model {
  position: absolute; top: 16px; right: 16px; min-height: 44px; padding: 8px;
  border: 0; background: none; color: var(--muted); font-size: 13px;
  text-decoration: underline; text-underline-offset: 3px;
}
.remove-model:hover { color: var(--error); }
.add-model {
  align-self: flex-start; min-height: 44px; padding: 10px 16px;
  border: 1px solid #c9d8f8; background: #f5f7fe; color: var(--blue);
  font: 500 14px/1.5 var(--sans); transition: background .2s ease, border-color .2s ease;
}
.add-model:hover { background: #eaf0fd; border-color: var(--blue); }
.throughput { display: flex; flex-direction: column; gap: 8px; }
.throughput-head, .throughput-row { display: grid; grid-template-columns: 120px minmax(0, 1fr) minmax(0, 1fr); gap: 10px; align-items: center; }
.throughput-head span { padding-left: 14px; color: var(--muted); font: 400 11px/1.5 var(--mono); letter-spacing: .035em; text-transform: uppercase; }
.throughput-unit { color: var(--ink); font-size: 13px; }
.typeahead { position: relative; }
.suggestions {
  position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 5;
  max-height: 296px; margin: 0; padding: 4px 0; overflow-y: auto; list-style: none;
  border: 1px solid var(--line); background: #fff; box-shadow: 0 8px 24px rgba(48, 46, 35, .09);
}
.suggestions li { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 44px; padding: 10px 14px; font-size: 14px; cursor: pointer; }
.suggestions li span:first-child { min-width: 0; overflow-wrap: anywhere; }
.suggestions li span:last-child { max-width: 35%; color: var(--muted); font: 400 11px/1.5 var(--mono); overflow-wrap: anywhere; }
.suggestions li[aria-selected="true"], .suggestions li:hover { background: #edf2fd; }
.suggestions li mark { background: transparent; color: inherit; font-weight: 600; }
.suggestions .empty { color: var(--muted); cursor: default; }
.suggestions .empty:hover { background: transparent; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { position: relative; cursor: pointer; user-select: none; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip span {
  display: inline-flex; align-items: center; min-height: 44px; padding: 9px 14px;
  border: 1px solid #d9d6cf; background: #fff; color: var(--ink); font: 400 14px/1.5 var(--sans);
  transition: background .2s ease, border-color .2s ease, color .2s ease;
}
.chip:hover span { border-color: var(--blue); }
.chip input:checked + span { border-color: var(--blue); background: var(--blue); color: #fff; }
.chip input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: 3px; }
.consent {
  display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 12px; align-items: start;
  min-height: 44px; padding-block: 8px; color: var(--muted); font-size: 14px; line-height: 1.6; cursor: pointer;
}
.consent input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--blue); cursor: pointer; }
.consent a { color: var(--blue); text-decoration: underline; text-underline-offset: 3px; }
.consent input[aria-invalid="true"] { outline: 2px solid var(--error); outline-offset: 2px; }
.submit { width: 100%; min-height: 52px; font-size: 16px; }
.submit[disabled] { opacity: .6; cursor: default; }
.form-error { margin: 0; color: var(--error); font-size: 14px; line-height: 1.5; }
.request-done { padding: 16px 0; }
.request-done .eyebrow { color: var(--blue); margin: 0 0 20px; }
.request-done h2 { margin: 0 0 18px; font: 500 48px/1.1 var(--display); letter-spacing: -.035em; }
.request-done p { max-width: 480px; margin: 0 0 24px; color: var(--muted); font-size: 16px; line-height: 1.6; }
.request-done .text-link { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; color: var(--blue); }
.terms-dialog {
  width: min(800px, calc(100% - 40px)); max-height: min(88vh, 960px); max-height: min(88dvh, 960px);
  margin: auto; padding: 0; border: 1px solid var(--line); border-radius: 0;
  background: var(--paper); color: var(--ink); box-shadow: 0 24px 80px rgba(48, 46, 35, .2);
  display: none; grid-template-rows: auto minmax(0, 1fr) auto;
}
.terms-dialog[open] { display: grid; }
.terms-dialog::backdrop { background: rgba(48, 46, 35, .5); }
.terms-dialog-head { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 28px; border-bottom: 1px solid var(--line); }
.terms-dialog-head h2 { margin: 0; font: 500 28px/1.15 var(--display); letter-spacing: -.025em; }
.terms-dialog-close { flex-shrink: 0; width: 44px; height: 44px; padding: 0; border: 1px solid var(--line); background: #fff; color: var(--ink); font: 400 28px/1 var(--sans); }
.terms-dialog-close:hover { border-color: var(--blue); color: var(--blue); }
.terms-dialog-body { min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding: 8px 28px 28px; }
.terms-dialog-body .terms { width: 100%; max-width: none; padding: 0; }
.terms-dialog-body .terms h1 { display: none; }
.terms-loading { padding: 16px 0; color: var(--muted); font-size: 14px; }
.terms-dialog-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 18px 28px; border-top: 1px solid var(--line); background: #fff; }
.terms-dialog-foot a { display: inline-flex; align-items: center; min-height: 44px; color: var(--muted); font-size: 13px; text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 700px) {
  .request { padding: 48px 0 64px; }
  .request-head { margin-bottom: 32px; }
  .request-head h1 { font-size: clamp(36px, 8vw, 48px); }
  .request-head p { margin-top: 20px; font-size: 15px; }
  .request-panel { padding: 24px 18px; }
  .choose-option { min-height: 56px; padding: 0 18px; }
  .request-form { gap: 24px; }
  .field-row { grid-template-columns: minmax(0, 1fr); gap: 20px; }
  .model-block { padding: 16px 14px 20px; }
  .remove-model { top: 8px; right: 6px; }
  .throughput-head, .throughput-row { grid-template-columns: 84px minmax(0, 1fr) minmax(0, 1fr); gap: 8px; }
  .throughput-head span { padding-left: 8px; }
  .throughput input { padding-inline: 8px; }
  .throughput-unit { font-size: 12px; }
  .terms-dialog { width: calc(100% - 24px); max-height: 92vh; max-height: 92dvh; }
  .terms-dialog-head, .terms-dialog-body, .terms-dialog-foot { padding-left: 18px; padding-right: 18px; }
  .terms-dialog-head h2 { font-size: 24px; }
  .terms-dialog-foot { flex-wrap: wrap; gap: 8px 16px; }
  .request-done h2 { font-size: 40px; }
}
@media (max-width: 390px) {
  .request-panel { padding-inline: 14px; }
  .model-block { padding-inline: 12px; }
  .throughput-head, .throughput-row { grid-template-columns: 72px minmax(0, 1fr) minmax(0, 1fr); gap: 6px; }
  .throughput input { padding-inline: 5px; }
  .chip span { padding-inline: 12px; }
}
