.stretch-form {
  display: grid;
  gap: 16px;
  max-width: 680px;
}

.stretch-form--width-narrow {
  max-width: 480px;
}

.stretch-form--width-wide {
  max-width: 920px;
}

.stretch-form--layout-compact {
  gap: 12px;
}

.stretch-form--layout-compact .stretch-form__field {
  grid-template-columns: minmax(140px, 0.4fr) minmax(0, 1fr);
  align-items: start;
}

.stretch-form--layout-compact .stretch-form__field--consent,
.stretch-form--layout-compact .stretch-form__field--signature {
  grid-template-columns: 1fr;
}

.stretch-form__field {
  display: grid;
  gap: 6px;
}

.stretch-form__progress {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.stretch-form__progress li {
  padding: 4px 10px;
  border: 1px solid #8c8f94;
  border-radius: 999px;
  font-size: 13px;
}

.stretch-form__progress [aria-current='step'] {
  border-color: #0f6f5c;
  color: #fff;
  background: #0f6f5c;
}

.stretch-form__step {
  display: grid;
  gap: 16px;
}

.stretch-form__step h3 {
  margin: 0;
  font-size: 18px;
}

.stretch-form.is-enhanced .stretch-form__step[hidden],
.stretch-form.is-enhanced .stretch-form__field[hidden],
.stretch-form.is-enhanced .stretch-form__submit[hidden],
.stretch-form.is-enhanced [data-step-next][hidden] {
  display: none;
}

.stretch-form__step-actions {
  display: flex;
  gap: 8px;
}

.stretch-form__step-button {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid #8c8f94;
  border-radius: 4px;
  background: #fff;
  cursor: pointer;
}

.stretch-form__step-button:disabled {
  cursor: not-allowed;
  opacity: 0.65;
}

.stretch-form__step-status {
  min-height: 20px;
  color: #0f6f5c;
  font-weight: 600;
}

.stretch-form label {
  font-weight: 600;
}

.stretch-form input:not([type='checkbox']),
.stretch-form textarea,
.stretch-form select {
  width: 100%;
  min-height: 42px;
  padding: 8px 10px;
  border: 1px solid #8c8f94;
  border-radius: 4px;
  background: #fff;
}

.stretch-form textarea {
  min-height: 120px;
  resize: vertical;
}

.stretch-form__field-hint {
  margin: 0;
  color: #646970;
  font-size: 13px;
}

.stretch-form__choices {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
}

.stretch-form__choices label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 400;
}

.stretch-form__signature {
  display: grid;
  gap: 8px;
}

.stretch-form__signature canvas {
  width: 100%;
  max-width: 560px;
  height: 180px;
  border: 1px solid #8c8f94;
  border-radius: 4px;
  background: #fff;
  touch-action: none;
}

.stretch-form__signature-clear {
  width: fit-content;
  min-height: 34px;
  padding: 0 12px;
  border: 1px solid #8c8f94;
  border-radius: 4px;
  background: #fff;
  cursor: pointer;
}

.stretch-form__results {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid #c3c4c7;
  border-radius: 4px;
  background: #f6f7f7;
}

.stretch-form__results p {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin: 0;
}

.stretch-form__presentation,
.stretch-form__poll-results {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid #0f6f5c;
  border-radius: 4px;
  background: #f0f7f5;
}

.stretch-form__presentation h3,
.stretch-form__poll-results h3 {
  margin: 0;
  font-size: 18px;
}

.stretch-form__poll-results ol {
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.stretch-form__poll-results li {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px 12px;
  align-items: center;
}

.stretch-form__poll-bar {
  grid-column: 1 / -1;
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #dcdcde;
}

.stretch-form__poll-bar::before {
  display: block;
  width: var(--stretch-poll-percent, 0%);
  height: 100%;
  border-radius: inherit;
  background: #0f6f5c;
  content: '';
}

.stretch-form__poll-results p {
  margin: 0;
  color: #3c434a;
}

.stretch-form__share {
  width: fit-content;
  font-weight: 600;
}

.stretch-form__draft-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.stretch-form__draft-save {
  min-height: 38px;
  padding: 0 14px;
  border: 1px solid #0f6f5c;
  border-radius: 4px;
  color: #0f6f5c;
  background: #fff;
  cursor: pointer;
}

.stretch-form__draft-save:disabled {
  cursor: not-allowed;
  opacity: 0.65;
}

.stretch-form__draft-status {
  color: #3c434a;
  font-size: 13px;
}

.stretch-form__submit {
  width: fit-content;
  min-height: 42px;
  padding: 0 18px;
  border: 0;
  border-radius: 4px;
  color: #fff;
  background: #0f6f5c;
  cursor: pointer;
}

.stretch-form__notice {
  padding: 12px 14px;
  border-left: 4px solid #0f6f5c;
  background: #f0f7f5;
}

.stretch-form__hp {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

@media (max-width: 640px) {
  .stretch-form--layout-compact .stretch-form__field {
    grid-template-columns: 1fr;
  }
}
