.order-modal[hidden] {
  display: none;
}

.order-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 18px;
}

.order-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(13, 18, 15, 0.76);
  backdrop-filter: blur(8px);
}

.order-modal__dialog {
  position: relative;
  width: min(100%, 540px);
  max-height: calc(100svh - 36px);
  overflow-y: auto;
  color: var(--ink, #20231f);
  background: var(--cream, #f7f2e6);
  border: 1px solid rgba(61, 81, 68, 0.18);
  border-radius: 24px;
  box-shadow: 0 32px 90px rgba(7, 10, 8, 0.32);
  padding: clamp(28px, 6vw, 48px);
}

.order-modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  color: var(--ink, #20231f);
  background: rgba(61, 81, 68, 0.08);
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  font-size: 25px;
  line-height: 1;
  transition: background 0.18s ease, transform 0.18s ease;
}

.order-modal__close:hover {
  background: rgba(61, 81, 68, 0.14);
  transform: rotate(5deg);
}

.order-modal__eyebrow {
  margin: 0 0 14px;
  color: var(--sage, #3d5144);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 11px;
  font-weight: 700;
}

.order-modal h2 {
  max-width: 420px;
  margin: 0;
  font: 500 clamp(38px, 7vw, 56px) / 0.98 var(--display, Georgia, serif);
  letter-spacing: -0.035em;
}

.order-modal__lead {
  max-width: 420px;
  margin: 18px 0 30px;
  color: var(--muted, #686b65);
  font-size: 15px;
  line-height: 1.65;
}

.order-form {
  display: grid;
  gap: 16px;
}

.order-form__field {
  display: grid;
  gap: 8px;
}

.order-form__field > span {
  color: var(--muted, #686b65);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.order-form input {
  width: 100%;
  min-height: 58px;
  color: var(--ink, #20231f);
  background: rgba(255, 255, 255, 0.5);
  border: 1px solid rgba(61, 81, 68, 0.26);
  border-radius: 12px;
  padding: 0 18px;
  font: 500 16px/1.2 var(--body, system-ui, sans-serif);
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}

.order-form input:focus {
  background: #fffdf7;
  border-color: var(--sage, #3d5144);
  box-shadow: 0 0 0 4px rgba(61, 81, 68, 0.11);
}

.order-form__submit {
  min-height: 62px;
  margin-top: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--cream, #f7f2e6);
  background: var(--sage, #3d5144);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font: 700 16px/1 var(--body, system-ui, sans-serif);
  transition: background 0.18s ease, transform 0.18s ease;
}

.order-form__submit:hover {
  background: #314237;
  transform: translateY(-2px);
}

.order-form__submit:disabled {
  opacity: 0.64;
  cursor: wait;
  transform: none;
}

.order-form__note {
  margin: 0;
  color: var(--muted, #686b65);
  text-align: center;
  font-size: 11px;
  line-height: 1.55;
}

.order-form__status {
  min-height: 20px;
  margin: 0;
  color: #9a3a2f;
  text-align: center;
  font-size: 13px;
  line-height: 1.45;
}

.order-form__confirm {
  display: grid;
  gap: 16px;
  padding: 24px;
  text-align: center;
  background: rgba(61, 81, 68, 0.06);
  border: 1px solid rgba(61, 81, 68, 0.16);
  border-radius: 18px;
}

.order-form__confirm[hidden] {
  display: none;
}

.order-form__confirm-label {
  margin: 0;
  color: var(--sage, #3d5144);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.order-form__confirm-phone {
  color: var(--ink, #20231f);
  font: 600 clamp(25px, 6vw, 34px) / 1.1 var(--display, Georgia, serif);
  letter-spacing: -0.025em;
}

.order-form__confirm p:not(.order-form__confirm-label) {
  max-width: 390px;
  margin: 0 auto 4px;
  color: var(--muted, #686b65);
  font-size: 14px;
  line-height: 1.55;
}

.order-form__confirm-send,
.order-form__confirm-edit {
  min-height: 56px;
  border-radius: 999px;
  cursor: pointer;
  font: 700 15px/1 var(--body, system-ui, sans-serif);
}

.order-form__confirm-send {
  color: var(--cream, #f7f2e6);
  background: var(--sage, #3d5144);
  border: 0;
}

.order-form__confirm-edit {
  color: var(--sage, #3d5144);
  background: transparent;
  border: 1px solid rgba(61, 81, 68, 0.28);
}

.order-form__confirm-send:disabled {
  opacity: 0.64;
  cursor: wait;
}

.order-form__success {
  min-height: 360px;
  display: grid;
  align-content: center;
  text-align: center;
}

.order-form__success-mark {
  width: 64px;
  height: 64px;
  margin: 0 auto 22px;
  display: grid;
  place-items: center;
  color: var(--cream, #f7f2e6);
  background: var(--sage, #3d5144);
  border-radius: 50%;
  font-size: 28px;
}

.order-form__success h2 {
  margin-inline: auto;
}

.order-form__success p {
  margin: 18px auto 0;
  color: var(--muted, #686b65);
  line-height: 1.6;
}

.order-form__honeypot {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

body.order-modal-open {
  overflow: hidden;
}

@media (max-width: 560px) {
  .order-modal {
    padding: 8px;
    align-items: end;
  }

  .order-modal__dialog {
    width: 100%;
    max-height: calc(100svh - 16px);
    border-radius: 22px;
    padding: 30px 20px 24px;
  }

  .order-modal h2 {
    padding-right: 34px;
    font-size: clamp(38px, 12vw, 48px);
  }

}

@media (prefers-reduced-motion: reduce) {
  .order-modal *,
  .order-modal *::before,
  .order-modal *::after {
    transition-duration: 1ms !important;
  }
}
