/* Tunnel de commande. Couleurs et polices : tokens.css. */
.co { padding-bottom: var(--section); }
.co__grid { display: grid; gap: 32px; padding-top: 24px; align-items: start; }
@media (min-width: 960px) { .co__grid { grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: 56px; } .co__aside { position: sticky; top: 108px; } }
.co h1 { font-size: clamp(2.2rem, 4vw, 3rem); }
.co__steps { display: flex; gap: 8px; margin: 18px 0 28px; counter-reset: s; }
.co__steps li { counter-increment: s; display: flex; align-items: center; gap: 8px; font-size: .875rem; color: var(--brown-soft); }
.co__steps li::before { content: counter(s); display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; border: 1.5px solid var(--beige); font-weight: 600; transition: all var(--base) var(--ease); }
.co__steps li + li::after { order: -1; content: ""; width: 28px; height: 0; border-top: 2px dotted var(--beige); margin-right: 4px; }
.co__steps li.is-on { color: var(--brown); font-weight: 600; }
.co__steps li.is-on::before { background: var(--brown); border-color: var(--brown); color: var(--paper); }
.co__steps li.is-done::before { content: "✓"; background: var(--gold-deep); border-color: var(--gold-deep); color: var(--paper); }

.co__block { display: grid; gap: 18px; padding: clamp(20px, 3vw, 30px); border-radius: var(--r-panel); background: var(--paper); border: 1px solid var(--line); margin-bottom: 20px; animation: co-in var(--slow) var(--ease) both; }
.co__block h2 { font-size: 1.8rem; }
@keyframes co-in { from { opacity: 0; transform: translateY(16px); } }
.co__row { display: grid; gap: 14px; }
@media (min-width: 620px) { .co__row--2 { grid-template-columns: 1fr 1fr; } .co__row--3 { grid-template-columns: 1fr 2fr; } }
.co .error { margin: 0; }

.ship { display: grid; gap: 10px; }
.ship__opt { position: relative; }
.ship__opt input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.ship__opt > span { display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: center; padding: 16px 18px; border-radius: var(--r-field); border: 1px solid var(--beige); background: var(--ivory); transition: border-color var(--fast), box-shadow var(--fast), transform var(--fast); }
.ship__opt:hover > span { border-color: var(--taupe); }
.ship__opt:has(input:checked) > span { border-color: var(--gold-deep); box-shadow: 0 0 0 1px var(--gold-deep), var(--shadow-s); }
.ship__opt:has(input:focus-visible) > span { outline: 2px solid var(--gold-deep); outline-offset: 2px; }
.ship__opt b { display: block; font-weight: 600; }
.ship__opt small { display: block;  color: var(--brown-soft); font-size: .875rem; }
.ship__opt em { font-style: normal; font-weight: 600; }
.ship__logo { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--cream); color: var(--gold-deep); }

.relay { display: grid; gap: 12px; }
.relay__search { display: flex; gap: 10px; }
.relay__search .input { flex: 1; }
.relay__list { display: grid; gap: 8px; max-height: 420px; overflow-y: auto; padding: 2px; }
.relay__pt { position: relative; animation: co-in .5s var(--ease) both; animation-delay: calc(var(--i) * 60ms); }
.relay__pt input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.relay__pt > span { display: grid; gap: 4px; padding: 14px 16px; border-radius: var(--r-field); border: 1px solid var(--beige); background: var(--ivory); transition: border-color var(--fast), box-shadow var(--fast); }
.relay__pt:has(input:checked) > span { border-color: var(--gold-deep); box-shadow: 0 0 0 1px var(--gold-deep); background: var(--paper); }
.relay__pt:has(input:focus-visible) > span { outline: 2px solid var(--gold-deep); outline-offset: 2px; }
.relay__pt b { font-weight: 600; }
.relay__pt small { color: var(--brown-soft); }
.relay__tag { display: inline-block; margin-left: 6px; padding: 1px 8px; border-radius: var(--r-pill); background: var(--sand); font-size: .75rem; font-weight: 600; vertical-align: 2px; }
.relay__hours { display: none; font-size: .8125rem; color: var(--brown-soft); grid-template-columns: 90px 1fr; gap: 2px 10px; margin-top: 6px; }
.relay__pt:has(input:checked) .relay__hours { display: grid; }

.co__aside .co__block { gap: 14px; }
.co__line { display: grid; grid-template-columns: 64px 1fr auto; gap: 12px; align-items: start; }
.co__line img { width: 64px; height: 80px; object-fit: cover; border-radius: 12px; }
.co__line b { font-family: var(--serif); font-size: 1.15rem; font-weight: 600; line-height: 1.2; }
.co__line small { display: block; color: var(--brown-soft); font-size: .8125rem; line-height: 1.45; }
.co__qty { position: absolute; margin: -8px 0 0 48px; min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--brown); color: var(--paper); font-size: .75rem; font-weight: 700; display: grid; place-items: center; }
.co__sum { display: grid; grid-template-columns: 1fr auto; gap: 8px; padding-top: 14px; border-top: 1px solid var(--line); }
.co__sum .tot { font-family: var(--serif); font-size: 1.7rem; font-weight: 600; padding-top: 8px; border-top: 1px solid var(--line); }
.co__sum .tot + .tot { text-align: right; }

/* Confirmation */
.done { display: grid; justify-items: center; text-align: center; gap: 18px; padding: clamp(48px, 8vw, 96px) 16px; }
.done svg { width: 120px; height: 120px; }
.done circle { fill: none; stroke: var(--gold); stroke-width: 2; stroke-dasharray: 2 6; stroke-linecap: round; animation: spin 12s linear infinite; transform-origin: center; }
.done path { fill: none; stroke: var(--gold-deep); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 60; stroke-dashoffset: 60; animation: check .9s var(--ease) .3s forwards; }
@keyframes check { to { stroke-dashoffset: 0; } }
@keyframes spin { to { transform: rotate(360deg); } }
.done h1 { font-size: clamp(2.4rem, 5vw, 3.6rem); }
.done .lead { margin-inline: auto; }
.stitch-fall { position: fixed; top: -20px; width: 2px; height: 14px; border-radius: 2px; background: var(--gold); pointer-events: none; z-index: 80; animation: fall var(--d) linear forwards; }
@keyframes fall { to { transform: translate(var(--x), 110vh) rotate(var(--r)); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .stitch-fall { display: none; } }
.promo { display: grid; gap: 6px; padding-top: 14px; border-top: 1px solid var(--line); }
.promo label { font-size: .875rem; font-weight: 600; }
.promo__row { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.promo__row .btn { min-height: 52px; padding: 0 18px; }

/* Étapes du tunnel : tiennent sur 390 px. */
@media (max-width: 480px) {
  .co__steps { gap: 4px; font-size: .8125rem; }
  .co__steps li { gap: 6px; font-size: .8125rem; }
  .co__steps li + li::after { width: 14px; margin-right: 2px; }
  .co__steps li:not(.is-on) { font-size: 0; gap: 0; }
  .co__steps li:not(.is-on)::before { font-size: .8125rem; }
  .co__steps li:not(.is-on)::after { margin-right: 4px; }
}

/* Résumé du panier replié en haut du tunnel, sur mobile (28/11) */
.co__mini { display: none; }
@media (max-width: 959px) {
  .co__mini { display: block; position: sticky; top: 78px; z-index: 20; margin: 4px 0 18px; border-radius: 20px; border: 1px solid rgb(255 255 255 / 80%);
    background: rgb(255 255 255 / 86%); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); box-shadow: 0 14px 34px -24px rgb(59 36 48 / 50%); }
  .co__mini summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 52px; padding: 0 18px; cursor: pointer; list-style: none; font-size: .9375rem; }
  .co__mini summary::-webkit-details-marker { display: none; }
  .co__mini-l { display: inline-flex; align-items: center; gap: 8px; color: var(--brown-soft); }
  .co__mini-l svg { color: var(--gold-deep); }
  .co__mini summary b { font-family: var(--serif); font-size: 1.25rem; font-weight: 600; color: var(--brown); font-variant-numeric: tabular-nums; }
  .co__mini-body { display: grid; gap: 12px; padding: 4px 18px 18px; max-height: 55vh; overflow-y: auto; }
  .co__aside { order: 2; }
}
@media (max-width: 959px) { .co__mini[open] { position: relative; top: auto; } }

/* Page /avis */
.avis-page #av-list { display: grid; gap: 16px; max-width: 640px; padding-bottom: 64px; }
.av-card { display: grid; gap: 16px; padding: 22px; border-radius: var(--r-panel); background: rgb(255 255 255 / 72%); border: 1px solid #fff; box-shadow: 0 18px 40px -30px rgb(59 36 48 / 45%); }
.av-card__head { display: flex; align-items: center; gap: 14px; }
.av-card__head img { width: 56px; height: 70px; object-fit: cover; border-radius: 12px; }
.av-card__head h2 { font-size: 1.3rem; }
.av-stars { display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: 4px; border: 0; margin: 0; padding: 0; }
.av-stars input { position: absolute; opacity: 0; pointer-events: none; }
.av-stars label { font-size: 34px; line-height: 1; color: var(--beige); cursor: pointer; padding: 4px; min-width: 44px; text-align: center; transition: color .2s ease; }
.av-stars input:checked ~ label, .av-stars label:hover, .av-stars label:hover ~ label { color: var(--gold); }
.av-stars input:focus-visible + label { outline: 2px solid var(--gold-deep); border-radius: 8px; }
.av-done { display: flex; align-items: center; gap: 8px; color: var(--ok); font-weight: 600; }
