/* tunnel-vendeur.css — Childz.fr seller tunnel
   Palette : --forest #1a3d2e | --amber #d4883a | --cream #f5f0e8
   Préfixe : .t- (isolation totale du thème) */

* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --forest:       #1a3d2e;
  --amber:        #d4883a;
  --cream:        #f5f0e8;
  --warm:         #faf8f4;
  --forest-light: rgba(26,61,46,0.08);
  --forest-mid:   rgba(26,61,46,0.2);
  --forest-muted: rgba(26,61,46,0.45);
}

body {
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--cream);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.tunnel-wrap {
  width: 100%;
  max-width: 430px;
  min-height: 100vh;
  background: var(--cream);
  display: flex;
  flex-direction: column;
  position: relative;
}

/* HEADER */
.t-header {
  padding: 20px 20px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  flex-shrink: 0;
}

.t-back {
  position: absolute;
  left: 20px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--forest);
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 13px;
  font-family: inherit;
  padding: 8px 0;
  visibility: hidden;
}

.t-back svg { width: 16px; height: 16px; }

.t-logo {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 20px;
  font-weight: 900;
  color: var(--forest);
  letter-spacing: -0.5px;
  text-decoration: none;
}

.t-logo span { color: var(--amber); }

.t-skip {
  position: absolute;
  right: 20px;
  font-size: 13px;
  color: var(--forest-muted);
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}

/* PROGRESS */
.t-progress {
  padding: 14px 24px 0;
  flex-shrink: 0;
}

.t-progress-label {
  font-size: 11px;
  font-weight: 500;
  color: var(--forest-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 7px;
}

.t-progress-bar {
  height: 2px;
  background: var(--forest-light);
  border-radius: 99px;
  overflow: hidden;
}

.t-progress-fill {
  height: 100%;
  background: var(--forest);
  border-radius: 99px;
  transition: width 0.4s ease;
}

/* BODY — overflow-y:auto permet le scroll sur desktop quand une étape
   dépasse la hauteur disponible (ex: étape 2 avec 11 univers).
   justify-content:flex-start + margin:auto 0 sur .t-step.active
   conserve le centrage visuel pour les étapes courtes. */
.t-body {
  flex: 1;
  padding: 0 24px 24px;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-height: 0;
  overflow-y: auto;
}

/* STEPS */
.t-step {
  display: none;
  flex-direction: column;
  align-items: center;
  text-align: center;
  animation: fadeIn 0.25s ease;
}

/* margin:auto 0 centre verticalement quand la step est plus courte que
   .t-body ; se réduit à 0 quand elle déborde (laisse le scroll agir). */
.t-step.active { display: flex; margin: auto 0; }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.t-eyebrow {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--amber);
  margin-bottom: 10px;
  margin-top: 24px;
}

.t-title {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 28px;
  font-weight: 900;
  color: var(--forest);
  line-height: 1.15;
  margin-bottom: 8px;
}

.t-sub {
  font-size: 14px;
  color: var(--forest-muted);
  margin-bottom: 28px;
  line-height: 1.5;
  max-width: 300px;
}

/* PHOTO STEP */
.t-photo-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  width: 100%;
  margin-bottom: 14px;
}

.t-photo-btn {
  padding: 22px 12px;
  border: 1px solid var(--forest-mid);
  border-radius: 16px;
  background: white;
  font-size: 14px;
  font-weight: 500;
  color: var(--forest);
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  font-family: inherit;
  transition: border-color 0.15s, background 0.15s;
  position: relative;
  overflow: hidden;
}

.t-photo-btn:hover { border-color: var(--forest); background: var(--forest-light); }
.t-photo-btn input[type="file"] { position: absolute; inset: 0; opacity: 0; cursor: pointer; }

.t-photo-btn svg {
  width: 28px;
  height: 28px;
  stroke: var(--forest);
  stroke-width: 1.5;
  fill: none;
}

.t-photo-previews {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  width: 100%;
  margin-bottom: 12px;
  min-height: 0;
}

.t-photo-thumb {
  width: 60px;
  height: 60px;
  border-radius: 10px;
  object-fit: cover;
  border: 0.5px solid var(--forest-mid);
}

.t-photo-hint {
  font-size: 12px;
  color: var(--forest-muted);
  margin-bottom: 4px;
}

/* OPTIONS */
.t-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.t-option {
  padding: 15px 16px;
  border: 0.5px solid var(--forest-mid);
  border-radius: 14px;
  background: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 14px;
  text-align: left;
  transition: all 0.15s;
  width: 100%;
}

.t-option:hover, .t-option.sel {
  border-color: var(--forest);
  background: var(--forest-light);
}

.t-option-ico {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--forest-light);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
}

.t-option-lbl {
  font-size: 15px;
  font-weight: 500;
  color: var(--forest);
}

.t-option-sub {
  font-size: 12px;
  color: var(--forest-muted);
  margin-top: 2px;
}

/* CHIPS */
.t-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  width: 100%;
  margin-bottom: 16px;
}

.t-chip {
  padding: 10px 18px;
  border: 0.5px solid var(--forest-mid);
  border-radius: 99px;
  background: white;
  font-size: 14px;
  color: var(--forest);
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
}

.t-chip:hover, .t-chip.sel {
  background: var(--forest);
  color: white;
  border-color: var(--forest);
}

/* INPUT */
.t-input {
  width: 100%;
  padding: 16px 18px;
  border: 0.5px solid var(--forest-mid);
  border-radius: 14px;
  font-size: 16px;
  background: white;
  color: var(--forest);
  font-family: inherit;
  outline: none;
  text-align: center;
  transition: border-color 0.15s, box-shadow 0.15s;
  margin-top: 4px;
}

.t-input:focus {
  border-color: var(--forest);
  box-shadow: 0 0 0 3px rgba(26,61,46,0.08);
}

.t-input-lg {
  font-size: 22px;
  font-weight: 500;
  padding: 20px 18px;
}

/* ÉTAT CARDS */
.t-etat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  width: 100%;
}

.t-etat-card {
  padding: 16px 10px;
  border: 0.5px solid var(--forest-mid);
  border-radius: 14px;
  background: white;
  cursor: pointer;
  text-align: center;
  transition: all 0.15s;
}

.t-etat-card:hover, .t-etat-card.sel {
  border-color: var(--forest);
  background: var(--forest-light);
}

.t-etat-ico { font-size: 22px; margin-bottom: 6px; }
.t-etat-lbl { font-size: 13px; font-weight: 500; color: var(--forest); }
.t-etat-sub { font-size: 11px; color: var(--forest-muted); margin-top: 3px; }

/* PRIX */
.t-price-wrap {
  position: relative;
  width: 100%;
  margin-bottom: 14px;
}

.t-price-prefix {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 24px;
  font-weight: 500;
  color: var(--forest);
  pointer-events: none;
}

.t-price-input {
  width: 100%;
  padding: 22px 18px 22px 44px;
  border: 0.5px solid var(--forest-mid);
  border-radius: 14px;
  font-size: 32px;
  font-weight: 500;
  background: white;
  color: var(--forest);
  font-family: inherit;
  outline: none;
  box-sizing: border-box;
  text-align: center;
  transition: border-color 0.15s;
}

.t-price-input:focus { border-color: var(--forest); }

.t-tip {
  font-size: 12px;
  color: var(--forest-muted);
  background: var(--forest-light);
  padding: 10px 14px;
  border-radius: 10px;
  width: 100%;
  text-align: left;
  line-height: 1.5;
}

/* CTA BUTTON */
.t-cta {
  width: 100%;
  margin-top: 24px;
  display: flex;
  justify-content: center;
}

.t-btn {
  padding: 16px 52px;
  background: var(--forest);
  color: var(--amber);
  border: none;
  border-radius: 14px;
  font-size: 16px;
  font-weight: 500;
  cursor: pointer;
  font-family: inherit;
  transition: opacity 0.15s, transform 0.1s;
  min-width: 180px;
  letter-spacing: 0.01em;
}

.t-btn:hover { opacity: 0.92; }
.t-btn:active { transform: scale(0.98); }

.t-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
  transform: none;
}

/* SUCCESS / LOADING */
.t-success {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 32px 20px;
  flex: 1;
}

.t-success-check {
  width: 72px;
  height: 72px;
  background: var(--forest-light);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 22px;
}

.t-success-check svg.t-check-icon {
  width: 34px;
  height: 34px;
  stroke: var(--forest);
  stroke-width: 2.5;
  fill: none;
  display: none;
}

/* Spinner */
.t-spinner {
  width: 32px;
  height: 32px;
  animation: t-spin 0.8s linear infinite;
}

.t-spinner circle {
  fill: none;
  stroke: var(--forest);
  stroke-width: 3;
  stroke-dasharray: 80 40;
  stroke-linecap: round;
}

@keyframes t-spin { to { transform: rotate(360deg); } }

/* DOTS */
.t-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  padding: 16px 0 22px;
  flex-shrink: 0;
}

.t-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--forest-mid);
  transition: all 0.25s ease;
}

.t-dot.active {
  background: var(--forest);
  width: 22px;
  border-radius: 99px;
}

.t-dot.done { background: rgba(26,61,46,0.4); }

/* RESPONSIVE */
@media (min-width: 430px) {
  .tunnel-wrap {
    min-height: 720px;
    border-radius: 28px;
    margin: 20px auto;
    border: 0.5px solid var(--forest-mid);
  }
  body { padding: 20px; }
}
