/* ═══ ORDER FORM MODAL ═══ */

.order-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.order-modal.open {
  pointer-events: all;
  opacity: 1;
}

.order-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 25, 0.75);
  backdrop-filter: blur(4px);
  cursor: pointer;
}

.order-sheet {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 580px;
  max-height: 95svh;
  background: var(--cream);
  border-radius: 20px 20px 0 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  transform: translateY(40px);
  transition: transform 0.4s cubic-bezier(0.34, 1.2, 0.64, 1);
}
.order-modal.open .order-sheet {
  transform: translateY(0);
}

@media (min-width: 640px) {
  .order-modal { align-items: center; }
  .order-sheet {
    border-radius: 20px;
    max-height: 92svh;
  }
}

/* ─── HEADER ─── */
.order-header {
  background: var(--navy);
  padding: 1.4rem 1.5rem 1.1rem;
  flex-shrink: 0;
}
.order-header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.2rem;
}
.order-tier-badge {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--navy);
  background: var(--gold);
  padding: 0.28rem 0.85rem;
  border-radius: 20px;
}
.order-close {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: rgba(255,255,255,0.1);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
  flex-shrink: 0;
}
.order-close:hover { background: rgba(255,255,255,0.2); }
.order-close svg { width: 13px; height: 13px; stroke: white; fill: none; stroke-width: 2; stroke-linecap: round; }

.order-progress-track {
  height: 2px;
  background: rgba(255,255,255,0.12);
  border-radius: 2px;
  margin-bottom: 0.7rem;
  overflow: hidden;
}
.order-progress-fill {
  height: 100%;
  background: var(--gold);
  border-radius: 2px;
  transition: width 0.45s cubic-bezier(0.4, 0, 0.2, 1);
  width: 0%;
}
.order-step-count {
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
}

/* ─── BODY ─── */
.order-body {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 2rem 1.5rem 1rem;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
}
@media (min-width: 640px) {
  .order-body { padding: 2.5rem 2.5rem 1.5rem; }
}

/* ─── STEPS ─── */
.order-step { display: none; }
.order-step.active {
  display: block;
  animation: stepIn 0.32s ease;
}
.order-step.going-back.active {
  animation: stepInBack 0.32s ease;
}
@keyframes stepIn {
  from { opacity: 0; transform: translateX(18px); }
  to   { opacity: 1; transform: translateX(0); }
}
@keyframes stepInBack {
  from { opacity: 0; transform: translateX(-18px); }
  to   { opacity: 1; transform: translateX(0); }
}

.order-step-eyebrow {
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--gold);
  display: block;
  margin-bottom: 0.5rem;
}
.order-step-title {
  font-family: 'Cormorant Garant', serif;
  font-size: clamp(1.65rem, 5vw, 2.2rem);
  font-weight: 400;
  color: var(--navy);
  line-height: 1.2;
  margin-bottom: 0.6rem;
}
.order-step-subtitle {
  font-size: 0.88rem;
  color: var(--text-light);
  line-height: 1.65;
  margin-bottom: 1.75rem;
}

/* ─── FIELDS ─── */
.order-field { margin-bottom: 1.4rem; }

.order-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-dark);
  margin-bottom: 0.45rem;
  letter-spacing: 0.02em;
}

.order-input,
.order-select,
.order-textarea {
  width: 100%;
  background: var(--white);
  border: 1.5px solid rgba(26,26,46,0.13);
  border-radius: 8px;
  padding: 0.8rem 1rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  color: var(--text-dark);
  transition: border-color 0.2s, box-shadow 0.2s;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}
.order-input::placeholder,
.order-textarea::placeholder { color: rgba(74,74,106,0.45); }

.order-input:focus,
.order-select:focus,
.order-textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201,168,76,0.12);
}
.order-input.error,
.order-select.error,
.order-textarea.error { border-color: #b94040; }

.order-select {
  cursor: pointer;
  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='%234A4A6A' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
}

.order-textarea {
  min-height: 150px;
  resize: vertical;
  line-height: 1.7;
}
.order-textarea.large { min-height: 180px; }

.order-hint {
  font-size: 0.77rem;
  color: var(--text-light);
  margin-top: 0.5rem;
  font-style: italic;
  line-height: 1.5;
}
.order-error-msg {
  font-size: 0.76rem;
  color: #b94040;
  margin-top: 0.4rem;
  display: none;
}
.order-error-msg.visible { display: block; }

/* ─── CHIPS ─── */
.order-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 0.25rem;
}
.order-chip {
  padding: 0.5rem 1.05rem;
  border-radius: 30px;
  border: 1.5px solid rgba(26,26,46,0.14);
  background: var(--white);
  font-family: 'Inter', sans-serif;
  font-size: 0.84rem;
  color: var(--text-mid);
  cursor: pointer;
  transition: all 0.18s;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}
.order-chip:hover { border-color: var(--gold); color: var(--navy); }
.order-chip.selected {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--navy);
  font-weight: 500;
}

/* ─── RADIO CARDS ─── */
.order-radio-cards { display: flex; flex-direction: column; gap: 0.65rem; }

.order-radio-card { position: relative; cursor: pointer; }
.order-radio-card input { position: absolute; opacity: 0; pointer-events: none; }
.order-radio-card-inner {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.95rem 1.2rem;
  background: var(--white);
  border: 1.5px solid rgba(26,26,46,0.12);
  border-radius: 10px;
  transition: all 0.2s;
  cursor: pointer;
}
.order-radio-card input:checked + .order-radio-card-inner {
  border-color: var(--gold);
  background: rgba(201,168,76,0.05);
}
.order-radio-card-inner:hover { border-color: rgba(201,168,76,0.5); }

.order-radio-dot {
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(26,26,46,0.2);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}
.order-radio-card input:checked + .order-radio-card-inner .order-radio-dot {
  border-color: var(--gold);
  background: var(--gold);
}
.order-radio-dot::after {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--navy);
  opacity: 0;
  transition: opacity 0.2s;
}
.order-radio-card input:checked + .order-radio-card-inner .order-radio-dot::after { opacity: 1; }

.order-radio-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
  width: 28px;
  text-align: center;
}
.order-radio-text { flex: 1; }
.order-radio-title {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-dark);
  margin-bottom: 0.1rem;
}
.order-radio-desc { font-size: 0.77rem; color: var(--text-light); }
.order-radio-tag {
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  background: rgba(201,168,76,0.12);
  border-radius: 10px;
  padding: 0.2rem 0.55rem;
  flex-shrink: 0;
}

/* ─── TOGGLE ─── */
.order-toggle-field {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.95rem 1.2rem;
  background: var(--white);
  border: 1.5px solid rgba(26,26,46,0.1);
  border-radius: 10px;
}
.order-toggle-text { flex: 1; }
.order-toggle-title {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-dark);
  margin-bottom: 0.1rem;
}
.order-toggle-desc { font-size: 0.77rem; color: var(--text-light); }

.order-toggle {
  position: relative;
  width: 44px; height: 24px;
  flex-shrink: 0;
}
.order-toggle input { opacity: 0; width: 0; height: 0; position: absolute; }
.order-toggle-track {
  position: absolute;
  inset: 0;
  background: rgba(26,26,46,0.15);
  border-radius: 12px;
  cursor: pointer;
  transition: background 0.2s;
}
.order-toggle input:checked + .order-toggle-track { background: var(--gold); }
.order-toggle-track::after {
  content: '';
  position: absolute;
  left: 3px; top: 3px;
  width: 18px; height: 18px;
  background: white;
  border-radius: 50%;
  transition: transform 0.2s;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.order-toggle input:checked + .order-toggle-track::after { transform: translateX(20px); }

/* Locked vocal option (Дует — Signature only) */
.order-radio-card.vocal-locked {
  opacity: 0.4;
  pointer-events: none;
}
.order-radio-card.vocal-locked .order-radio-card-inner {
  cursor: not-allowed;
}
/* Unlocked when Signature tier is active */
.order-radio-card:not(.vocal-locked) input[value="duet"] ~ .order-radio-card-inner {
  cursor: pointer;
}

/* ─── STEP 4: dual radio groups ─── */
.order-field-group-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-light);
  margin-bottom: 0.6rem;
  display: block;
}

/* ─── FOOTER ─── */
.order-footer {
  padding: 1.1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  border-top: 1px solid rgba(26,26,46,0.07);
  background: var(--cream);
  flex-shrink: 0;
}
@media (min-width: 640px) { .order-footer { padding: 1.1rem 2.5rem; } }

.order-btn-back {
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
  font-size: 0.84rem;
  color: var(--text-light);
  padding: 0.7rem 0;
  transition: color 0.2s;
  white-space: nowrap;
}
.order-btn-back:hover { color: var(--navy); }
.order-btn-back.hidden { visibility: hidden; pointer-events: none; }

.order-btn-next {
  background: var(--gold);
  color: var(--navy);
  border: none;
  border-radius: 4px;
  padding: 0.82rem 1.8rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.86rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}
.order-btn-next:hover { background: #b8973e; transform: translateY(-1px); }
.order-btn-next.final { padding: 0.82rem 1.4rem; font-size: 0.82rem; }

/* ─── SUCCESS ─── */
.order-success {
  display: none;
  text-align: center;
  padding: 3rem 1.5rem 2.5rem;
  animation: stepIn 0.4s ease;
}
.order-success.active { display: block; }

.order-success-icon {
  font-size: 3.2rem;
  display: block;
  margin-bottom: 1.5rem;
}
.order-success h2 {
  font-family: 'Cormorant Garant', serif;
  font-size: 2rem;
  font-weight: 400;
  color: var(--navy);
  margin-bottom: 1rem;
  line-height: 1.25;
}
.order-success p {
  font-size: 0.9rem;
  color: var(--text-mid);
  line-height: 1.75;
  margin-bottom: 0.5rem;
  max-width: 380px;
  margin-left: auto;
  margin-right: auto;
}
.order-success-email {
  font-weight: 600;
  color: var(--navy);
}
.order-success-close {
  margin-top: 2rem;
  background: var(--navy);
  color: var(--white);
  border: none;
  border-radius: 4px;
  padding: 0.85rem 2rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.86rem;
  font-weight: 500;
  cursor: pointer;
  transition: opacity 0.2s;
}
.order-success-close:hover { opacity: 0.85; }

/* ─── STEP 7: PAYMENT ─── */
.payment-summary {
  background: var(--navy);
  border-radius: 10px;
  padding: 1.1rem 1.4rem;
  margin-bottom: 1.75rem;
}
.payment-summary-inner {}
.payment-summary-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  font-size: 0.88rem;
  color: rgba(255,255,255,0.85);
  margin-bottom: 0.3rem;
}
.payment-summary-row strong { color: #fff; }
.payment-summary-price {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--gold);
  white-space: nowrap;
}
.payment-summary-detail {
  font-size: 0.76rem;
  color: rgba(255,255,255,0.45);
}

.payment-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.85rem;
  padding: 2rem 0;
}
.payment-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid rgba(201,168,76,0.2);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }
.payment-loading-text {
  font-size: 0.82rem;
  color: var(--text-light);
}

.payment-element-container { margin-bottom: 0.75rem; }

.payment-error-msg {
  display: none;
  background: #fef2f2;
  border: 1px solid #fca5a5;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  font-size: 0.84rem;
  color: #b91c1c;
  margin-top: 0.75rem;
  line-height: 1.5;
}

.payment-secure-note {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.74rem;
  color: var(--text-light);
  margin-top: 1rem;
}
.payment-secure-note svg {
  flex-shrink: 0;
  stroke: var(--text-light);
  fill: none;
  width: 14px; height: 14px;
}

/* ─── ORDER BTN disabled state ─── */
.order-btn-next:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

/* ─── 3DS success banner ─── */
.payment-success-banner {
  display: none;
  position: fixed;
  top: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 300;
  background: #fff;
  border: 1.5px solid #22c55e;
  border-radius: 10px;
  padding: 0.9rem 1.5rem;
  box-shadow: 0 8px 30px rgba(0,0,0,0.12);
  align-items: center;
  gap: 0.75rem;
  font-size: 0.88rem;
  color: var(--navy);
  font-weight: 500;
  white-space: nowrap;
  animation: bannerIn 0.4s cubic-bezier(0.34,1.2,0.64,1);
}
@keyframes bannerIn {
  from { opacity: 0; transform: translateX(-50%) translateY(-16px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}
.payment-success-banner-icon { font-size: 1.2rem; }
