.form {
  display: grid;
  gap: 14px;
}

.form[hidden] {
  display: none;
}

.form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.field > label:not(.file),
.field > .label {
  display: block;
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 48px;
  padding: 10px 14px;
  border: 1px solid #c8d0da;
  border-radius: 10px;
  font: inherit;
  background: #fff;
  color: var(--ink);
}

.field textarea {
  min-height: 96px;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  border-color: var(--brand);
  outline: none;
  box-shadow: 0 0 0 3px rgba(29, 63, 102, 0.15);
}

.field.is-error input,
.field.is-error select {
  border-color: #c62828;
}

.field__err {
  display: none;
  font-size: 0.85rem;
  color: #c62828;
  margin-top: 4px;
}

.field.is-error .field__err {
  display: block;
}

.form__note {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0;
}

.form .btn {
  width: 100%;
}

.form-ok {
  display: none;
  padding: 24px;
  border-radius: var(--radius);
  background: #e9f6ee;
  color: #155d34;
}

.form-ok.is-visible {
  display: grid;
  gap: 10px;
  justify-items: start;
}

.form-ok h3,
.form-ok p {
  margin: 0;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
  place-items: center;
  padding: 16px;
  background: rgba(10, 18, 28, 0.6);
}

.modal.is-open {
  display: grid;
}

.modal__box {
  position: relative;
  width: 100%;
  max-width: 520px;
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  padding: 32px 28px 28px;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.modal__close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 10px;
  background: #eef2f7;
  font-size: 1.4rem;
  cursor: pointer;
}

@media (max-width: 640px) {
  .form__row {
    grid-template-columns: 1fr;
  }

  .modal__box {
    padding: 28px 18px 20px;
  }
}

.estimate {
  margin: 0;
  padding: 12px 14px;
  border-radius: 10px;
  background: #f1f4f8;
  font-size: 0.93rem;
  color: var(--ink-soft);
}

.estimate span {
  display: block;
}

.estimate span + span {
  margin-top: 4px;
}

.estimate__total {
  color: var(--ink);
}

.field {
  min-width: 0;
}
