/* Parcours d'estimation : réutilise les tokens de style.css */
[hidden] { display: none !important; }
.est-page { background: var(--pale); }
.est-back { margin-left: auto; font-size: .95rem; }
.est { padding-block: 32px 80px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Rail de progression */
.rail { margin-bottom: 28px; }
.rail__mobile { display: flex; justify-content: space-between; gap: 12px; font-size: .9rem; color: var(--muted); margin-bottom: 10px; }
.rail__mobile strong { color: var(--ink); }
.rail__track { height: 4px; background: var(--line); border-radius: 4px; overflow: hidden; }
.rail__fill { display: block; height: 100%; width: 100%; background: var(--blue); transform-origin: left; transform: scaleX(0); }
.rail__list { display: none; }
@media (min-width: 960px) {
  .rail__mobile { display: none; }
  .rail { position: relative; }
  .rail__track { position: absolute; left: 14px; right: 14px; top: 13px; height: 2px; }
  .rail__list { display: grid; grid-template-columns: repeat(12, 1fr); list-style: none; margin: 0; padding: 0; position: relative; }
  .rail__item { display: flex; flex-direction: column; align-items: center; gap: 8px; text-align: center; }
  .rail__btn {
    display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%;
    border: 2px solid var(--line); background: var(--paper); color: var(--muted);
    font: 700 .75rem var(--body); cursor: default; padding: 0;
  }
  .rail__item.is-done .rail__btn { background: var(--blue); border-color: var(--blue); color: #fff; cursor: pointer; }
  .rail__item.is-current .rail__btn { border-color: var(--blue); color: var(--blue); box-shadow: 0 0 0 5px rgba(36,64,168,.15); }
  .rail__name { font-size: .78rem; color: var(--muted); line-height: 1.2; }
  .rail__item.is-current .rail__name { color: var(--ink); font-weight: 700; }
}

/* Grille principale */
.est__grid { display: grid; gap: 24px; align-items: start; }
@media (min-width: 960px) { .est__grid { grid-template-columns: minmax(0, 1fr) 320px; } }

.stage { position: relative; background: var(--paper); border-radius: 24px; padding: 28px 20px; overflow: hidden; }
@media (min-width: 720px) { .stage { padding: 40px; } }
.pane { display: grid; gap: 20px; }
.pane__title { font-size: clamp(1.4rem, 3vw, 2rem); text-wrap: balance; }
.pane__title:focus { outline: none; }
.pane__lead { color: var(--muted); max-width: 60ch; margin-top: -8px; }

/* Choix */
.choices { display: grid; gap: 12px; }
.choices--3 { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.choices--2 { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.choices--brands { grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.choices--states { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.choice {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  min-height: 88px; padding: 18px 14px; text-align: center;
  background: var(--paper); color: var(--ink); border: 2px solid var(--line); border-radius: 18px;
  font: 500 1rem var(--body); cursor: pointer;
  transition: border-color .2s, box-shadow .2s, transform .15s;
}
.choice:hover { border-color: #b7c3e4; }
.choice:active { transform: scale(.97); }
.choice[aria-pressed="true"] { border-color: var(--blue); box-shadow: 0 0 0 4px rgba(36,64,168,.12); }
.choice[aria-pressed="true"]::after {
  content: ""; position: absolute; top: 10px; right: 10px; width: 22px; height: 22px; border-radius: 50%;
  background: var(--blue) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12l4 4 8-9'/%3E%3C/svg%3E") center/14px no-repeat;
  animation: pop .3s cubic-bezier(.3,1.6,.6,1);
}
@keyframes pop { from { transform: scale(0); } }
.choice__label { font-weight: 700; font-size: 1.05rem; }
.choice__sub { font-size: .85rem; color: var(--muted); }
.choice--media { padding: 0 0 16px; overflow: hidden; justify-content: flex-start; }
.choice--media img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; margin-bottom: 8px; }
.badge { font-size: .78rem; font-weight: 700; color: #8a4b00; background: #fff4e5; border: 1px solid #f5d1a3; border-radius: 999px; padding: 3px 10px; }
.choice--state { padding: 0 0 16px; overflow: hidden; justify-content: flex-start; text-align: left; align-items: stretch; }
.choice--state img { width: 100%; aspect-ratio: 900 / 620; object-fit: cover; }
.choice--state .choice__label, .choice--state .choice__sub { padding: 0 16px; }
.choice--state .choice__label { margin-top: 8px; }
.choice__factor { padding: 0 16px; font-size: .8rem; color: var(--blue); font-weight: 700; }

.wm { font-weight: 700; font-size: 1.15rem; }

.dot { width: 14px; height: 14px; border-radius: 50%; }
.dot--ok { background: var(--ok); }
.dot--ko { background: #c53b3b; }

/* Champs */
.field { display: grid; gap: 6px; border: 0; padding: 0; margin: 0; min-width: 0; }
.field label, .field legend, .other label { font-weight: 700; font-size: .95rem; padding: 0; }
.opt { font-weight: 400; color: var(--muted); }
input[type="text"], input[type="email"], input[type="tel"], input:not([type]), select {
  width: 100%; min-height: 48px; padding: 0 14px; border: 2px solid var(--line); border-radius: 12px;
  font: 400 1rem var(--body); color: var(--ink); background: var(--paper);
}
input:focus-visible, select:focus-visible { border-color: var(--blue); outline: none; box-shadow: 0 0 0 4px rgba(36,64,168,.15); }
.pills { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.pill { min-height: 44px; padding: 0 18px; border-radius: 999px; border: 2px solid var(--line); background: var(--paper); font: 500 .95rem var(--body); color: var(--ink); cursor: pointer; }
.pill[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.other__row { display: flex; gap: 8px; }
.other { display: grid; gap: 6px; }
.upto { background: var(--pale); border-radius: 14px; padding: 14px 16px; color: var(--muted); }
.upto strong { color: var(--blue); font-size: 1.15rem; font-variant-numeric: tabular-nums; }
.form { display: grid; gap: 16px; }
.form__grid { display: grid; gap: 14px; }
@media (min-width: 640px) { .form__grid { grid-template-columns: 1fr 1fr; } .field--wide { grid-column: 1 / -1; } }
.hint { font-size: .85rem; color: var(--muted); }
.tick { display: flex; gap: 10px; align-items: flex-start; font-size: .95rem; cursor: pointer; }
.tick input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--blue); flex: none; }
.error { color: #b42318; font-weight: 500; }
.checks { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.checks li { padding-left: 28px; position: relative; }
.checks li::before { content: ""; position: absolute; left: 4px; top: 6px; width: 6px; height: 11px; border: solid var(--ok); border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
.warn { background: #fff8eb; border-left: 4px solid #e0a106; border-radius: 0 12px 12px 0; padding: 12px 16px; font-size: .95rem; }

/* Navigation des étapes */
.nav-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 8px; }
.nav-row .btn { margin-left: auto; }
.btn[disabled] { opacity: .45; cursor: not-allowed; }
.back { background: none; border: 0; padding: 10px 0; min-height: 44px; font: 500 1rem var(--body); color: var(--muted); cursor: pointer; text-decoration: underline; text-underline-offset: 4px; }
.back:hover { color: var(--ink); }

/* Offre */
.offer { text-align: center; padding: 28px 16px; background: var(--pale); border-radius: 20px; }
.offer__device { color: var(--muted); }
.offer__price { font: 700 clamp(3rem, 9vw, 5rem)/1.05 var(--display); color: var(--blue); font-variant-numeric: tabular-nums; margin: 8px 0; }
.offer__note { color: var(--muted); }

/* Étiquette d'envoi */
.label-slot { padding: 8px; background: linear-gradient(var(--ink), var(--ink)) top / 100% 8px no-repeat; border-radius: 6px; overflow: hidden; }
.label { max-width: 360px; margin: 0 auto; background: var(--paper); border: 1px solid var(--line); border-radius: 8px; padding: 16px; display: grid; gap: 12px; box-shadow: 0 16px 32px -20px rgba(22,23,27,.5); }
.label__top { display: flex; justify-content: space-between; font-size: .85rem; color: var(--muted); }
.label__top strong { color: #1d4b9b; }
.label__to { font-weight: 700; line-height: 1.35; }
.label__bars { height: 56px; background: repeating-linear-gradient(90deg, var(--ink) 0 2px, transparent 2px 4px, var(--ink) 4px 7px, transparent 7px 9px, var(--ink) 9px 10px, transparent 10px 13px); }
.label__num { font: 500 .95rem var(--body); letter-spacing: .08em; text-align: center; font-variant-numeric: tabular-nums; }
.howto { margin: 0; padding-left: 22px; display: grid; gap: 6px; }

/* Confirmation */
.done { display: grid; justify-items: center; gap: 12px; text-align: center; }
.done__check { width: 72px; height: 72px; }
.done__check circle { fill: none; stroke: var(--ok); stroke-width: 3; }
.done__check path { fill: none; stroke: var(--ok); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; }
.recap { display: grid; grid-template-columns: auto 1fr; gap: 10px 20px; margin: 0; padding: 20px; background: var(--pale); border-radius: 16px; }
.recap dt { color: var(--muted); }
.recap dd { margin: 0; font-weight: 500; text-align: right; overflow-wrap: anywhere; }

/* Récapitulatif */
.summary { background: var(--paper); border-radius: 24px; padding: 24px; display: grid; gap: 18px; }
@media (min-width: 960px) { .summary { position: sticky; top: 92px; } }
.summary__title { font-family: var(--body); font-size: 1.05rem; }
.summary__list { margin: 0; display: grid; gap: 8px; }
.summary__list:empty::before { content: "Vos choix s'afficheront ici."; color: var(--muted); font-size: .95rem; }
.summary__row { display: flex; justify-content: space-between; gap: 12px; font-size: .95rem; }
.summary__row dt { color: var(--muted); }
.summary__row dd { margin: 0; font-weight: 500; text-align: right; }
.summary__est { display: flex; justify-content: space-between; align-items: baseline; padding: 14px 16px; background: var(--blue); color: #fff; border-radius: 14px; }
.summary__est strong { font: 700 1.6rem var(--display); font-variant-numeric: tabular-nums; }
.summary__perks { list-style: none; margin: 0; padding: 16px 0 0; border-top: 1px solid var(--line); display: grid; gap: 8px; font-size: .9rem; color: var(--muted); }
.summary__perks li { padding-left: 22px; position: relative; }
.summary__perks li::before { content: ""; position: absolute; left: 3px; top: 5px; width: 5px; height: 10px; border: solid var(--blue); border-width: 0 2px 2px 0; transform: rotate(45deg); }

/* Fenêtre « bientôt disponible » */
.modal { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; padding: 16px; background: rgba(22,23,27,.45); }
.modal[hidden] { display: none; }
.modal__box { position: relative; width: min(440px, 100%); background: var(--paper); border-radius: 22px; padding: 28px; display: grid; gap: 12px; }
.modal__box h2 { font-size: 1.3rem; padding-right: 32px; }
.modal__close { position: absolute; top: 12px; right: 12px; width: 44px; height: 44px; border: 0; background: none; font-size: 1.6rem; cursor: pointer; color: var(--muted); }
.soon__form { display: flex; gap: 8px; flex-wrap: wrap; }
.soon__form input { flex: 1 1 180px; }
.soon__ok { color: var(--ok); font-weight: 500; }

@media (prefers-reduced-motion: reduce) {
  .choice[aria-pressed="true"]::after { animation: none; }
}
.rgpd { font-size: .82rem; color: var(--muted); max-width: 70ch; }
.rgpd a { color: inherit; }
