.tmo-wizard {
  --tmo-ink: #1c2230;
  --tmo-navy: #232a3b;
  --tmo-gold: #b78c46;
  --tmo-gold-light: #d9b876;
  --tmo-cream: #f8f4ea;
  --tmo-cream-dark: #efe6d3;
  --tmo-text-soft: #625d54;
  --tmo-white: #ffffff;
  --tmo-radius: 10px;
  --tmo-shadow: 0 10px 30px rgba(28, 34, 48, 0.08);
  max-width: 900px;
  margin: 0 auto;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  box-sizing: border-box;
}
.tmo-wizard * { box-sizing: border-box; }
.tmo-wizard h3 { font-size: 1.2rem; color: var(--tmo-ink); margin: 0 0 6px; }
.tmo-wizard .tmo-muted { color: var(--tmo-text-soft); font-size: 0.88rem; }

.tmo-steps {
  display: flex;
  justify-content: space-between;
  margin: 0 0 36px;
  font-size: 0.78rem;
}
.tmo-step { flex: 1; text-align: center; position: relative; color: var(--tmo-text-soft); }
.tmo-dot {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--tmo-white); border: 2px solid #d8d2c2;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 6px; font-weight: 700; color: var(--tmo-text-soft);
}
.tmo-step.active .tmo-dot, .tmo-step.done .tmo-dot { border-color: var(--tmo-gold); background: var(--tmo-gold); color: #fff; }
.tmo-step.active { color: var(--tmo-ink); font-weight: 700; }

.tmo-panel { display: none; }
.tmo-panel.active { display: block; }

.tmo-banner {
  background: #fbf6ea;
  border: 1px solid #e5ddc9;
  border-radius: var(--tmo-radius);
  padding: 14px 18px;
  font-size: 0.85rem;
  color: var(--tmo-text-soft);
  margin-bottom: 22px;
}

.tmo-grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px 24px; }
.tmo-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 4px; }
.tmo-field label { font-size: 0.82rem; font-weight: 600; color: var(--tmo-ink); }

.tmo-wizard input[type="text"],
.tmo-wizard input[type="tel"],
.tmo-wizard input[type="email"],
.tmo-wizard input[type="number"],
.tmo-wizard input[type="file"],
.tmo-wizard select,
.tmo-wizard textarea {
  font-family: inherit;
  font-size: 0.95rem;
  padding: 10px 12px;
  border: 1px solid #d8d2c2;
  border-radius: 8px;
  background: var(--tmo-white);
  color: #262420;
  width: 100%;
}
.tmo-wizard input:focus, .tmo-wizard select:focus, .tmo-wizard textarea:focus { outline: none; border-color: var(--tmo-gold); }

.tmo-checkbox-row { display: flex; gap: 8px; align-items: center; margin-top: 20px; font-size: 0.88rem; }
.tmo-checkbox-row input { width: auto; }

.tmo-unit-toggle { display: inline-flex; border: 1px solid #d8d2c2; border-radius: 999px; overflow: hidden; flex-shrink: 0; }
.tmo-unit-toggle button { border: none; background: var(--tmo-white); padding: 7px 16px; font-family: inherit; cursor: pointer; font-size: 0.82rem; }
.tmo-unit-toggle button.active { background: var(--tmo-gold); color: #fff; }

.tmo-flex-between { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 14px; margin-bottom: 18px; }

.tmo-choice-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 16px; }
.tmo-choice-card {
  background: var(--tmo-white);
  border: 2px solid #e5ddc9;
  border-radius: var(--tmo-radius);
  padding: 20px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s, transform 0.15s;
}
.tmo-choice-card:hover { transform: translateY(-2px); }
.tmo-choice-card.selected { border-color: var(--tmo-gold); background: #fbf6ea; }
.tmo-choice-card .tmo-price { font-size: 0.76rem; color: var(--tmo-text-soft); margin-top: 4px; }

.tmo-fabric-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; }
.tmo-fabric-card {
  background: var(--tmo-white);
  border-radius: var(--tmo-radius);
  overflow: hidden;
  box-shadow: var(--tmo-shadow);
  border: 2px solid transparent;
  cursor: pointer;
  transition: border-color 0.15s, transform 0.15s;
}
.tmo-fabric-card:hover { transform: translateY(-3px); }
.tmo-fabric-card.selected { border-color: var(--tmo-gold); }
.tmo-fabric-swatch { width: 100%; aspect-ratio: 1 / 1; }
.tmo-fabric-card .tmo-body { padding: 14px; }
.tmo-fabric-card .tmo-tier { font-size: 0.66rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--tmo-gold); font-weight: 700; }
.tmo-fabric-card h4 { margin: 4px 0 6px; font-size: 0.95rem; color: var(--tmo-ink); }
.tmo-fabric-card p { font-size: 0.82rem; color: var(--tmo-text-soft); margin: 0; }

.tmo-review-table { width: 100%; border-collapse: collapse; margin: 16px 0; }
.tmo-review-table td, .tmo-review-table th { padding: 8px 10px; border-bottom: 1px solid #ece5d5; text-align: left; font-size: 0.9rem; }
.tmo-review-table th { color: var(--tmo-text-soft); font-weight: 600; width: 40%; }

.tmo-confirmation { text-align: center; padding: 50px 16px; }
.tmo-order-id { font-size: 1.3rem; font-weight: 700; color: var(--tmo-gold); letter-spacing: 0.03em; margin: 10px 0 18px; }

.tmo-btn {
  display: inline-block;
  font-weight: 600;
  font-size: 0.85rem;
  padding: 11px 22px;
  border-radius: 999px;
  border: 1px solid var(--tmo-gold);
  color: var(--tmo-ink);
  background: var(--tmo-gold);
  cursor: pointer;
  text-decoration: none;
}
.tmo-btn:hover { background: var(--tmo-gold-light); }
.tmo-btn.tmo-btn-outline { background: transparent; color: var(--tmo-ink); border-color: #d8d2c2; }
.tmo-btn.tmo-btn-dark { background: var(--tmo-ink); color: #fff; border-color: var(--tmo-ink); padding: 8px 16px; }
.tmo-btn:disabled { opacity: 0.5; cursor: not-allowed; }

.tmo-actions { display: flex; justify-content: space-between; margin-top: 32px; }

.tmo-field-ref-image {
  width: 140px;
  max-width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid #e5ddc9;
  margin-bottom: 4px;
}

.tmo-hover-zoom { cursor: zoom-in; }

.tmo-zoom-preview {
  display: none;
  position: fixed;
  width: 260px;
  height: 260px;
  background-color: var(--tmo-white);
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  border: 3px solid var(--tmo-white);
  border-radius: 10px;
  box-shadow: 0 12px 32px rgba(0,0,0,0.28);
  pointer-events: none;
  z-index: 9999;
}

/* Click-to-open full-size popup (JS-driven, see measurement.js / tracking.js). */
.tmo-lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 100000;
  background: rgba(20, 18, 14, 0.82);
  align-items: center;
  justify-content: center;
  cursor: zoom-out;
}
.tmo-lightbox.active { display: flex; }
.tmo-lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  border-radius: 6px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

/* Country-code + number phone input, used everywhere a phone is collected. */
.tmo-phone-group { display: flex; gap: 8px; }
.tmo-phone-cc { flex: 0 0 152px; }
.tmo-phone-number { flex: 1; min-width: 0; }

/* Same-address vs new-address toggle under "Ship to me". */
.tmo-radio-row { display: flex; gap: 22px; flex-wrap: wrap; }
.tmo-radio-inline { display: flex; align-items: center; gap: 6px; font-size: 0.85rem; font-weight: 500; color: var(--tmo-ink); cursor: pointer; }
.tmo-radio-inline input { width: auto; }

/* Submit progress bar (0–100%). */
.tmo-progress-wrap { margin-top: 18px; display: flex; align-items: center; gap: 12px; }
.tmo-progress-bar { flex: 1; height: 10px; border-radius: 999px; background: #ece5d5; overflow: hidden; }
.tmo-progress-fill { height: 100%; width: 0%; background: var(--tmo-gold); transition: width 0.2s ease; }
.tmo-progress-label { font-size: 0.8rem; font-weight: 700; color: var(--tmo-text-soft); min-width: 38px; text-align: right; }

.tmo-cancelled-banner {
  background: #fdeceb;
  border: 1px solid #f0b8b3;
  color: #9a2f24;
  border-radius: 8px;
  padding: 14px 18px;
  font-weight: 700;
  text-align: center;
}

.tmo-msg-images { display: flex; flex-wrap: wrap; margin-top: 8px; }
.tmo-msg-thumb {
  width: 64px;
  height: 64px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid #e5ddc9;
  margin: 0 6px 6px 0;
  cursor: zoom-in;
}

.tmo-fabric-contact-card {
  border: 2px dashed #d8ceb4 !important;
  box-shadow: none !important;
  background: #fbf6ea;
  display: flex;
  align-items: center;
  justify-content: center;
}
.tmo-fabric-contact-card:hover { transform: none; }

.tmo-review-thumb {
  width: 64px;
  height: 64px;
  object-fit: cover;
  border-radius: 6px;
  border: 1px solid #e5ddc9;
  cursor: zoom-in;
}

.tmo-message-thread { max-height: 360px; overflow-y: auto; margin-bottom: 8px; }
.tmo-msg {
  border-radius: 8px;
  padding: 10px 14px;
  margin-bottom: 10px;
  font-size: 0.88rem;
}
.tmo-msg strong { font-size: 0.82rem; }
.tmo-msg-customer { background: #fbf6ea; }
.tmo-msg-admin { background: #eef3ff; }
.tmo-msg-system { background: #f4f4f2; color: var(--tmo-text-soft); font-style: italic; }

@media (max-width: 640px) {
  .tmo-grid-2 { grid-template-columns: 1fr; }
  .tmo-steps { font-size: 0.65rem; }
  .tmo-phone-cc { flex-basis: 130px; }
}
