/* Vis-à-vis · direction « split stage » (tasteskill), marine et rose, Work Sans */
:root {
    --bg: #1a2039;
    --surface: #212846;
    --raised: #29315a;
    --edge: #313a68;
    --ink: #f9a3c0;
    --muted: #c697aa;
    --accent: #f9a3c0;
    --accent-ink: #1a2039;

    --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
    --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
    --step-lead: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
    --step-say: clamp(1.5rem, 1.2rem + 1.2vw, 2rem);
    --step-head: clamp(2.5rem, 1.3rem + 3.4vw, 4rem);

    --radius: 16px;
    --gap: 12px;
    --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
    color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
    margin: 0;
    background: var(--bg);
    color: var(--ink);
    font: 400 var(--step-body)/1.55 'Work Sans', system-ui, sans-serif;
    font-variant-numeric: tabular-nums;
}
h1, h2, h3, p, dl, dd, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--accent); color: var(--accent-ink); }
[hidden] { display: none !important; }
.visually-hidden {
    position: absolute; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); white-space: nowrap;
}
.unit { color: var(--muted); font-size: max(0.8em, 12px); }

h1, h2 { font-weight: 300; letter-spacing: -0.035em; line-height: 1.02; }
h1 { font-size: var(--step-head); }
h2 { font-size: var(--step-say); letter-spacing: -0.02em; line-height: 1.15; }
h3 { font-size: var(--step-body); font-weight: 500; }

/* ---------- Boutons et champs : une forme ronde, décidée une fois ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center;
    min-height: 44px; padding: 0 22px;
    border: 0; border-radius: 999px;
    background: var(--accent); color: var(--accent-ink);
    font: 500 var(--step-small)/1 inherit; font-size: 0.9375rem;
    text-decoration: none; cursor: pointer;
    transition: transform 160ms var(--ease), background-color 160ms;
}
.btn:hover { background: #fbb8cf; }
.btn:active { transform: scale(0.97); }
.btn:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }
.btn-quiet { background: var(--raised); color: var(--ink); }
.btn-quiet:hover { background: var(--edge); }

.field { display: grid; gap: 6px; font-size: var(--step-small); color: var(--muted); }
.field input, .field select, .sort select {
    min-height: 44px; padding: 0 16px;
    border: 1px solid var(--edge); border-radius: 999px;
    background: var(--bg); color: var(--ink);
    font: inherit; font-size: 1rem;
}
.field input::placeholder { color: var(--muted); }
.field input:hover, .field select:hover { border-color: var(--muted); }

/* ---------- Pied de page : une ligne ---------- */
.site-footer {
    display: grid; grid-template-columns: 1fr auto 1fr; gap: 24px; align-items: baseline;
    padding: 40px 28px 30px;
    font-size: var(--step-small); color: var(--muted);
}
.site-footer a { color: var(--ink); }
.footer-links { display: flex; gap: 24px; }
.footer-end { justify-self: end; }

/* =========================================================================
   Accueil : la scène partagée
   ========================================================================= */
.stage {
    display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap);
    padding: var(--gap);
}
.stage-text {
    background: var(--surface);
    border-radius: var(--radius);
    padding: 28px clamp(28px, 5vw, 72px) 0;
}
.home-nav {
    display: grid; grid-template-columns: 1fr auto 1fr; align-items: center;
    font-size: var(--step-small);
}
.home-nav a { text-decoration: none; }
.home-nav a:hover { text-decoration: underline; }
.home-nav a:last-child { justify-self: end; }
.wordmark { font-size: var(--step-lead); font-weight: 500; letter-spacing: -0.03em; text-decoration: none; }

.hero {
    display: flex; flex-direction: column; align-items: flex-start;
    padding: 14vh 0 48px;
    max-width: 46ch;
}
.hero h1 { max-width: 14ch; }
.hero .lead { margin: 36px 0 32px; font-size: var(--step-lead); line-height: 1.4; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.picker {
    max-width: 46ch; padding: 24px 0 48px;
    display: grid; grid-template-columns: 1fr 1fr; gap: 14px 12px; align-items: end;
}
.picker-title { grid-column: 1 / -1; font-size: var(--step-small); color: var(--muted); }
.picker .btn { grid-column: 1 / -1; justify-self: start; }

/* Champ à suggestions */
.combo { position: relative; }
.combo input { width: 100%; }
.combo-list {
    position: absolute; z-index: 20; top: calc(100% + 6px); left: 0; right: 0;
    max-height: 288px; overflow-y: auto; overscroll-behavior: contain;
    padding: 6px; margin: 0;
    background: var(--raised); color: var(--ink);
    border-radius: var(--radius);
    box-shadow: 0 16px 40px -16px rgb(0 0 0 / 0.7); /* taste-skill-ignore : liste déroulante, au-dessus de la page */
}
.combo-list li { padding: 10px 14px; border-radius: 10px; cursor: pointer; font-size: 0.9375rem; line-height: 1.3; }
.combo-list li[aria-selected="true"], .combo-list li:hover { background: var(--edge); }

.steps { padding: 40px 0 0; max-width: 46ch; }
.steps h2 { margin-bottom: 8px; }
.step {
    min-height: 78vh;
    display: flex; flex-direction: column; justify-content: center; gap: 14px;
}
.step .step-say { color: var(--muted); transition: color 400ms; }
.step:last-child { min-height: 70vh; }
.step-say { font-size: var(--step-say); line-height: 1.2; letter-spacing: -0.02em; }
.step.is-active .step-say { color: var(--ink); }

/* Le panneau fixe : un champ rose, l'interface posée dessus */
.stage-fixed {
    position: sticky; top: var(--gap);
    height: calc(100svh - 2 * var(--gap));
    align-self: start;
}
.stage-panel {
    position: relative; height: 100%;
    background: var(--accent);
    border-radius: var(--radius);
    overflow: hidden;
}
.stage-panel > figure {
    position: absolute; left: 50%; top: 50%;
    width: min(520px, calc(100% - 48px));
    translate: -50% -50%;
    background: var(--bg);
    border-radius: var(--radius);
    padding: 28px 28px 0;
    opacity: 0; visibility: hidden;
    transition: opacity 600ms var(--ease), visibility 0s 600ms, scale 600ms var(--ease);
    scale: 0.97;
}
.stage-panel > figure.is-shown { opacity: 1; visibility: visible; scale: 1; transition-delay: 0s; }
.panel-bar {
    display: flex; justify-content: space-between; gap: 16px;
    margin: 24px -28px 0; padding: 16px 28px;
    background: var(--surface);
    border-radius: 0 0 var(--radius) var(--radius);
    font-size: var(--step-small); color: var(--muted);
}
.panel-bar a { color: var(--ink); }

/* Le duel */
.duel-head { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 20px; }
.duel-head p { font-size: var(--step-lead); line-height: 1.2; letter-spacing: -0.02em; }
.duel-head p:last-child { text-align: right; }
.duel-brand, .duel-version { display: block; font-size: var(--step-small); color: var(--muted); letter-spacing: 0; }
.duel-rows { transition: opacity 400ms var(--ease); }
.duel.is-swapping .duel-rows, .duel.is-swapping .duel-head { opacity: 0.15; }
.duel-head { transition: opacity 400ms var(--ease); }
.duel-row {
    display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px;
    padding: 10px 0;
}
.duel-row + .duel-row { border-top: 1px solid var(--edge); } /* taste-skill-ignore : fragment d'interface (data-ui) */
.duel-row dt { font-size: var(--step-small); color: var(--muted); text-align: center; min-width: 9ch; }
.duel-row dd { font-size: var(--step-body); font-weight: 500; white-space: nowrap; }
.duel-row dd:last-child { text-align: right; }
.win .unit, .best .value .unit { color: inherit; }
.duel-row dd.win { justify-self: start; }
.duel-row dd:last-child.win { justify-self: end; }
.win {
    background: var(--accent); color: var(--accent-ink);
    border-radius: 999px; padding: 2px 12px; margin: 0 -12px;
}

/* Le catalogue en miniature et ses trois états */
.mini-filters { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 18px; }
.mini-filters span {
    padding: 6px 14px; border-radius: 999px; background: var(--raised);
    font-size: var(--step-small); color: var(--muted);
}
.mini-filters b { color: var(--ink); font-weight: 500; }
.mini-rows li {
    display: grid; grid-template-columns: 20px 1fr auto; gap: 14px; align-items: center;
    padding: 12px 10px; margin: 0 -10px; border-radius: 12px;
    transition: background-color 400ms;
}
.mini-rows li + li { border-top: 1px solid var(--edge); } /* taste-skill-ignore : fragment d'interface (data-ui) */
.mini-check { width: 18px; height: 18px; border: 1.5px solid var(--muted); border-radius: 5px; transition: background-color 400ms, border-color 400ms; }
.mini-name { font-weight: 500; }
.mini-name span { color: var(--muted); font-weight: 400; }
.mini-price { color: var(--muted); }
.mini-bar, .mini-share {
    display: flex; justify-content: space-between; align-items: center; gap: 12px;
    margin-top: 18px; padding: 10px 10px 10px 18px;
    background: var(--raised); border-radius: 999px;
    font-size: var(--step-small);
}
.mini-btn {
    padding: 8px 16px; border-radius: 999px;
    background: var(--accent); color: var(--accent-ink); font-weight: 500;
}
.mini-link { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.mini-share, .mini .when-pick { display: none; }
.mini[data-state="pick"] .picked, .mini[data-state="share"] .picked { background: var(--raised); }
.mini[data-state="pick"] .picked .mini-check, .mini[data-state="share"] .picked .mini-check { background: var(--accent); border-color: var(--accent); }
.mini[data-state="pick"] .when-pick { display: inline; }
.mini[data-state="pick"] .when-filter { display: none; }
.mini:not([data-state="pick"]) .mini-bar .mini-btn { opacity: 0.4; }
.mini[data-state="share"] .mini-bar { display: none; }
.mini[data-state="share"] .mini-share { display: flex; }

/* ---------- Quatre voitures du catalogue : la scène s'ouvre sur toute la largeur ---------- */
.gallery { padding: 160px clamp(28px, 5vw, 84px) 0; }
.gallery h2 { font-size: var(--step-head); max-width: 14ch; margin-bottom: 48px; }
.gallery-list { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); }
.gallery-list a { display: grid; gap: 4px; text-decoration: none; }
.gallery-list img {
    width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover;
    border-radius: var(--radius); margin-bottom: 12px;
    transition: scale 600ms var(--ease);
}
.gallery-list li { overflow: hidden; }
.gallery-list a:hover img { scale: 1.03; }
.gallery-list a:hover .gallery-name { text-decoration: underline; }
.gallery-name { font-size: var(--step-lead); letter-spacing: -0.02em; }
.gallery-meta { color: var(--muted); font-size: var(--step-small); }
.credits { grid-column: 1 / -1; font-size: var(--step-small); }

/* ---------- Les jeux, annoncés sur l'accueil ---------- */
.teaser {
    margin: 160px var(--gap) 0;
    padding: clamp(48px, 7vw, 112px) clamp(28px, 5vw, 72px);
    display: grid; grid-template-columns: 5fr 7fr; gap: 48px clamp(32px, 6vw, 96px); align-items: start;
    background: var(--surface); border-radius: var(--radius);
}
.teaser h2 { font-size: var(--step-head); max-width: 10ch; }
.teaser-text p { margin: 24px 0 28px; max-width: 36ch; }
.teaser-list { display: grid; gap: var(--gap); }
.teaser-list a {
    display: grid; gap: 8px; padding: 28px 32px;
    background: var(--bg); border-radius: var(--radius); text-decoration: none;
    transition: background-color 200ms, translate 200ms var(--ease);
}
.teaser-list a:hover { background: var(--raised); translate: 0 -2px; }
.teaser-list h3 { font-size: var(--step-say); font-weight: 300; letter-spacing: -0.02em; }

/* ---------- Le sens de chaque ligne : la scène s'ouvre sur toute la largeur ---------- */
.sense {
    margin: 120px var(--gap) 0;
    padding: clamp(48px, 7vw, 112px) clamp(28px, 5vw, 72px);
    display: grid; grid-template-columns: 5fr 7fr; gap: 48px clamp(32px, 6vw, 96px);
    background: var(--accent); color: var(--accent-ink);
    border-radius: var(--radius);
}
.sense h2 { font-size: var(--step-head); font-weight: 300; letter-spacing: -0.035em; line-height: 1.02; }
.sense-text p { margin-top: 32px; max-width: 40ch; }
.sense-list { display: grid; gap: 8px; }
.sense-list > div {
    display: flex; justify-content: space-between; align-items: baseline; gap: 24px;
    padding: 14px 24px;
    background: rgb(255 255 255 / 0.22);
    border-radius: 999px;
}
.sense-list dt { font-size: var(--step-say); letter-spacing: -0.02em; line-height: 1.2; }
.sense-list dd { text-align: right; }

/* ---------- Ce qu'il ne fait pas ---------- */
.honest {
    padding: 160px clamp(28px, 5vw, 84px) 0;
    display: grid; grid-template-columns: 5fr 7fr; gap: 48px clamp(32px, 6vw, 96px);
}
.honest h2 { font-size: var(--step-head); font-weight: 300; letter-spacing: -0.035em; line-height: 1.02; max-width: 11ch; }
.honest-list { display: grid; gap: 40px; }
.honest-list h3 { font-size: var(--step-say); font-weight: 300; letter-spacing: -0.02em; line-height: 1.2; margin-bottom: 8px; }
.honest-list p { max-width: 46ch; }

/* ---------- La fin ---------- */
.last {
    padding: 200px clamp(28px, 5vw, 84px) 120px;
    display: grid; justify-items: start; gap: 24px;
}
.last p { font-size: var(--step-lead); max-width: 34ch; line-height: 1.35; }

/* Entrées */
.js-reveal [data-reveal] { opacity: 0; translate: 0 24px; transition: opacity 700ms var(--ease), translate 700ms var(--ease); }
.js-reveal [data-reveal].is-in { opacity: 1; translate: 0 0; }

@media (max-width: 900px) {
    /* Sur téléphone, plus de panneau fixe : accroche, duel, choix des voitures, puis les gestes, dans cet ordre */
    .stage { grid-template-columns: 1fr; padding: 0 20px; gap: 0; }
    .stage-text { display: contents; }
    .home-nav { order: 1; display: flex; align-items: center; gap: 20px; padding: 16px 0; }
    .home-nav .wordmark { order: -1; margin-right: auto; }
    .home-nav a:last-child { justify-self: auto; }
    .hero { order: 2; padding: 32px 0 28px; }
    .hero h1 { font-size: clamp(2.5rem, 11vw, 3.25rem); }
    .hero .lead { margin: 20px 0 24px; font-size: var(--step-body); line-height: 1.5; }
    .hero-actions { display: grid; grid-template-columns: 1fr; width: 100%; }
    .stage-fixed { order: 3; position: static; height: auto; }
    .picker {
        order: 4; max-width: none; margin-top: var(--gap); padding: 20px;
        grid-template-columns: 1fr; background: var(--surface); border-radius: var(--radius);
    }
    .picker .btn { justify-self: stretch; }
    .steps { order: 5; max-width: none; padding-top: 72px; }
    .stage-panel { height: auto; padding: 10px; }
    .stage-panel > figure { position: static; translate: none; width: 100%; padding: 20px 20px 0; }
    .stage-panel > .mini { display: none; }
    .stage-panel > .duel { opacity: 1; visibility: visible; scale: 1; }
    .gallery { padding: 96px 20px 0; }
    .gallery h2 { margin-bottom: 24px; font-size: var(--step-say); }
    .gallery-list { grid-template-columns: 1fr 1fr; gap: 24px 12px; }
    .gallery-list img { aspect-ratio: 4 / 3; margin-bottom: 8px; }
    .gallery-name { font-size: var(--step-body); }
    .teaser { grid-template-columns: 1fr; margin: 96px 0 0; border-radius: 0; padding: 48px 20px; gap: 24px; }
    .teaser h2 { font-size: var(--step-say); }
    .teaser-text p { margin: 16px 0 20px; }
    .teaser-list a { padding: 20px; }
    .panel-bar { margin: 16px -20px 0; padding: 12px 20px; }
    .duel-head p, .duel-row dd { font-size: 1rem; }
    .duel-row dd .unit { font-size: 0.75em; }
    .duel-row dt { min-width: 0; font-size: 0.8125rem; }
    .win { margin: 0 -8px; padding: 2px 8px; }
    .duel-row { padding: 6px 0; }
    .mini-rows li { padding: 8px 10px; }
    .mini-rows li:nth-child(n + 4) { display: none; }
    .hero { min-height: 0; padding: 32px 0 48px; }
    .step { min-height: 0; padding: 20px 0 0; gap: 6px; }
    .step:last-child { min-height: 0; }
    .step .step-say { color: var(--ink); font-size: var(--step-lead); }
    .sense, .honest { grid-template-columns: 1fr; }
    .sense { margin: 96px 0 0; border-radius: 0; padding: 48px 20px; gap: 24px; }
    .sense h2, .honest h2 { font-size: var(--step-say); }
    .sense-text p { margin-top: 16px; }
    .sense-list { gap: 0; }
    .sense-list > div { background: none; border-radius: 0; padding: 12px 0; }
    .sense-list dt { font-size: var(--step-lead); }
    .honest { padding: 96px 20px 0; gap: 24px; }
    .honest-list { gap: 24px; }
    .honest-list h3 { font-size: var(--step-lead); }
    .last { padding: 96px 20px 64px; }
    .last .btn { width: 100%; }
    .site-footer { grid-template-columns: 1fr; gap: 8px; padding: 48px 20px 24px; }
    .footer-end { justify-self: start; }
}
@media (max-width: 480px) {
    .sense-list > div { flex-direction: column; gap: 0; }
    .sense-list dd { text-align: left; }
}

/* =========================================================================
   Écrans de travail : catalogue, comparaison, fiche
   ========================================================================= */
.topbar {
    display: flex; align-items: center; gap: 32px;
    height: 60px; padding: 0 28px;
}
.topbar-links { display: flex; gap: 24px; font-size: var(--step-small); }
.topbar-links a { color: var(--muted); text-decoration: none; }
.topbar-links a:hover, .topbar-links a[aria-current] { color: var(--ink); }
.topbar-links a[aria-current] { text-decoration: underline 2px; text-underline-offset: 0.45em; }

.sheet {
    margin: 0 var(--gap);
    padding: clamp(24px, 3vw, 40px);
    background: var(--surface);
    border: 1px solid var(--edge); /* taste-skill-ignore : bord de la feuille de travail (app sheet) */
    border-radius: var(--radius);
    min-height: calc(100svh - 60px - 120px);
}
.title-row { margin-bottom: 28px; }
.title-row h1 { font-size: clamp(1.375rem, 1.1rem + 1vw, 2rem); font-weight: 300; letter-spacing: -0.03em; line-height: 1.1; }
.title-row p { margin-top: 8px; color: var(--muted); max-width: 60ch; }
.title-row-split { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; }
.title-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.breadcrumb { font-size: var(--step-small); color: var(--muted); margin-bottom: 12px; }

/* Barre de filtres */
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; }
.toolbar .field { flex: 1 1 150px; }
.toolbar .field-q { flex: 2 1 240px; }
.toolbar .field-budget input { width: 100%; }
.list-head {
    display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
    margin: 28px 0 8px;
    font-size: var(--step-small); color: var(--muted);
}
.list-head a { color: var(--ink); }
.sort { display: flex; gap: 10px; align-items: center; }
.sort label { display: flex; gap: 10px; align-items: center; }
.sort select { min-height: 36px; }

/* Le catalogue : une table, des lignes, les chiffres alignés à droite */
.catalog { width: 100%; border-collapse: collapse; }
.catalog th {
    padding: 10px 12px; text-align: left;
    font-size: var(--step-small); font-weight: 400; color: var(--muted);
}
.catalog td { padding: 14px 12px; border-top: 1px solid var(--edge); vertical-align: middle; }
.catalog .num { text-align: right; white-space: nowrap; }
.catalog .price { font-weight: 500; }
.catalog tbody tr { cursor: pointer; transition: background-color 160ms; }
.catalog tbody tr:hover { background: var(--raised); }
.catalog tbody tr.is-picked { background: var(--raised); }
.pick { width: 44px; }
.pick input { width: 20px; height: 20px; accent-color: var(--accent); cursor: pointer; display: block; }
.identity-name { display: block; font-weight: 500; cursor: pointer; }
.identity-name .v-brand { color: var(--muted); font-weight: 400; }
.identity-name .v-name { font-weight: 400; }
.identity-meta { display: block; font-size: var(--step-small); color: var(--muted); }
.identity-meta a { color: var(--ink); }
.empty { padding: 64px 0; display: grid; gap: 20px; justify-items: start; }

/* La barre de comparaison suit le défilement */
.compare-bar {
    position: sticky; bottom: var(--gap); z-index: 5;
    display: flex; align-items: center; gap: 16px;
    margin-top: 24px; padding: 10px 10px 10px 16px;
    background: var(--raised);
    border-radius: 999px;
    border: 1px solid var(--edge); /* taste-skill-ignore : bord de la barre collée au bas de l'écran */
}
.chips { display: flex; flex-wrap: wrap; gap: 6px; flex: 1; min-width: 0; }
.chips li {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 4px 4px 4px 14px; border-radius: 999px;
    background: var(--bg); font-size: var(--step-small);
}
.chips li.chips-empty { background: none; color: var(--muted); padding-left: 0; }
.chips button {
    width: 28px; height: 28px; border: 0; border-radius: 999px;
    background: none; color: var(--muted); font: inherit; font-size: 1.1rem; cursor: pointer;
}
.chips button:hover { background: var(--raised); color: var(--ink); }
.compare-count { color: var(--muted); font-size: var(--step-small); white-space: nowrap; }

/* La comparaison */
.compare { width: 100%; border-collapse: collapse; table-layout: fixed; }
.compare thead td { width: clamp(150px, 18%, 220px); }
.compare th, .compare td { padding: 18px 16px; text-align: left; vertical-align: top; }
.compare thead th { vertical-align: bottom; padding-bottom: 20px; }
.compare tbody tr { border-top: 1px solid var(--edge); }
.compare tbody th { font-weight: 500; }
.compare tbody th small { display: block; font-weight: 400; font-size: var(--step-small); color: var(--muted); }
.compare-photo { margin: 0 0 14px; }
.compare-photo img { display: block; width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 12px; background: var(--raised); }
.compare-car { display: block; text-decoration: none; font-size: var(--step-lead); line-height: 1.2; letter-spacing: -0.02em; }
.compare-car:hover { text-decoration: underline; }
.compare-car .v-brand, .compare-car .v-name { display: block; font-size: var(--step-small); color: var(--muted); letter-spacing: 0; }
.compare-car-meta { display: block; margin-top: 4px; font-size: var(--step-small); color: var(--muted); }
.compare-remove { display: inline-block; margin-top: 8px; font-size: var(--step-small); color: var(--muted); }
.compare .value { font-size: var(--step-lead); font-weight: 500; letter-spacing: -0.01em; white-space: nowrap; }
.compare .best .value {
    background: var(--accent); color: var(--accent-ink);
    border-radius: 999px; padding: 2px 14px; margin-left: -14px;
}
.compare .gap { display: block; margin-top: 6px; font-size: var(--step-small); color: var(--muted); }
.compare .best .gap { color: var(--ink); }
.compare .info td, .compare .info th { color: var(--muted); font-weight: 400; }
.footnote { margin-top: 32px; font-size: var(--step-small); color: var(--muted); }

/* La fiche */
.version-title .v-brand, .version-title .v-name { color: var(--muted); }
.rivals { margin-top: 64px; }
.rivals h2 { font-size: var(--step-lead); font-weight: 400; }
.rivals-lede { margin-top: 6px; color: var(--muted); }
.rivals-list { margin-top: 20px; display: grid; gap: 4px; }
.rivals-list a {
    display: grid; grid-template-columns: 1fr auto auto; gap: 4px 24px; align-items: baseline;
    padding: 14px 16px; margin: 0 -16px; border-radius: 12px;
    text-decoration: none; transition: background-color 160ms;
}
.rivals-list a:hover { background: var(--raised); }
.rivals-name { font-weight: 500; }
.rivals-name .v-brand, .rivals-name .v-name { font-weight: 400; color: var(--muted); }
.rivals-meta { grid-column: 1; grid-row: 2; font-size: var(--step-small); color: var(--muted); }
.rivals-price { grid-column: 2; grid-row: 1 / 3; text-align: right; }
.rivals-diff { grid-column: 3; grid-row: 1 / 3; min-width: 9ch; text-align: right; color: var(--muted); font-size: var(--step-small); }
.specs { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: var(--gap); margin-top: 12px; }
.specs div { padding: 24px; background: var(--bg); border-radius: var(--radius); }
.specs dt { font-size: var(--step-small); color: var(--muted); }
.specs dd { margin-top: 8px; font-size: var(--step-say); font-weight: 300; letter-spacing: -0.02em; }

@media (max-width: 760px) {
    .topbar { padding: 0 20px; gap: 20px; }
    .sheet { margin: 0; border-radius: 0; border-width: 1px 0; padding: 24px 16px; }
    .site-footer { padding-top: 48px; }

    /* Catalogue : deux lignes par version */
    .catalog thead { display: none; }
    .catalog tbody, .catalog tr { display: block; }
    .catalog tr {
        display: flex; flex-wrap: wrap; align-items: baseline;
        padding: 12px 8px; border-top: 1px solid var(--edge);
    }
    .catalog td { border: 0; padding: 0; }
    .catalog .pick { width: 36px; align-self: center; }
    .catalog .identity { width: calc(100% - 36px - 96px); }
    .catalog .price { width: 96px; }
    .catalog td.num:not(.price) { font-size: var(--step-small); color: var(--muted); padding: 6px 12px 0 0; text-align: left; }
    .catalog td.num:nth-child(4) { margin-left: 36px; }

    .compare-bar { border-radius: var(--radius); flex-wrap: wrap; }
    .chips:has(button) { flex-basis: 100%; }
    .compare-count { margin-left: auto; }

    /* Comparaison : une carte par caractéristique, chaque voiture nommée */
    .compare, .compare tbody, .compare tr, .compare th, .compare td { display: block; width: auto; }
    .compare thead tr { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-bottom: 20px; }
    .compare thead td { display: none; }
    .compare thead th { padding: 0; }
    .compare-car { font-size: 1.0625rem; }
    .compare tbody tr { padding: 16px 0; }
    .compare tbody th { padding: 0 0 8px; }
    .compare tbody td {
        display: grid; grid-template-columns: 1fr auto; column-gap: 12px; align-items: baseline;
        padding: 8px 0;
    }
    .compare tbody td::before { content: attr(data-car); font-size: var(--step-small); color: var(--muted); grid-row: span 2; }
    .compare tbody td .value { font-size: 1.0625rem; justify-self: end; }
    .compare .best .value { margin-left: 0; }
    .compare .gap { grid-column: 2; text-align: right; margin-top: 2px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { transition-duration: 0.01ms !important; }
}

/* =========================================================================
   Jeux du jour
   ========================================================================= */
.games { display: grid; grid-template-columns: 1fr 1fr; gap: var(--gap); align-items: start; }
.game { padding: clamp(20px, 3vw, 32px); background: var(--bg); border-radius: var(--radius); }
.game-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.game-head h2 { font-size: var(--step-say); }
.streak { font-size: var(--step-small); color: var(--muted); white-space: nowrap; }
.game-lede { margin-top: 8px; color: var(--muted); }
.game-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 20px; }
.game-result { flex: 1 1 100%; }
.game-result:empty { display: none; }
.game-foot:not(:has(:not([hidden]):not(:empty))) { display: none; }
.game-result a { font-weight: 500; }

.blind-question { margin: 28px 0 16px; font-size: var(--step-lead); line-height: 1.3; }
.blind-step { display: block; font-size: var(--step-small); color: var(--muted); }
.blind-cars { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.blind-car {
    width: 100%; min-height: 104px; padding: 16px; overflow: hidden;
    display: grid; align-content: start; gap: 2px; text-align: left;
    background: var(--raised); color: var(--ink);
    border: 0; border-radius: var(--radius);
    font: inherit; cursor: pointer;
    transition: background-color 200ms, scale 160ms var(--ease);
}
.blind-car:not(:disabled):hover { background: var(--edge); }
.blind-car:not(:disabled):active { scale: 0.98; }
.blind-car:disabled { cursor: default; }
.blind-photo {
    display: block; width: calc(100% + 32px); max-width: none; height: auto; aspect-ratio: 4 / 3; object-fit: cover;
    margin: -16px -16px 12px; border-radius: var(--radius) var(--radius) 0 0;
}
.blind-name { font-weight: 500; line-height: 1.25; }
.blind-version { font-size: var(--step-small); line-height: 1.3; }
.game-credits { margin-top: 16px; font-size: 0.8125rem; color: var(--muted); }
.game-credits a { color: inherit; }

/* La photo à deviner : une vignette minuscule agrandie et floutée, rognée pour cacher les bords flous */
.mystery { position: relative; margin: 20px 0 0; overflow: hidden; border-radius: var(--radius); background: var(--raised); aspect-ratio: 16 / 9; }
.mystery img {
    display: block; width: 100%; height: 100%; object-fit: cover;
    filter: blur(var(--blur, 16px)); scale: 1.12;
    transition: filter 700ms var(--ease), scale 700ms var(--ease);
}
.mystery img.is-sharp { scale: 1; }
.mystery-credit { position: absolute; left: 0; right: 0; bottom: 0; padding: 8px 12px; font-size: 0.8125rem; background: rgb(26 32 57 / 0.85); }
.mystery-credit a { color: inherit; }
.blind-meta { font-size: var(--step-small); color: var(--muted); }
.blind-value { margin-top: 8px; font-size: var(--step-lead); letter-spacing: -0.01em; }
.blind-value:empty { display: none; }
.blind-car.is-right { background: var(--accent); color: var(--accent-ink); }
.blind-car.is-right .blind-meta { color: inherit; }
.blind-car.is-wrong .blind-name { text-decoration: line-through; }

.clues { display: grid; gap: 6px; margin: 24px 0 20px; }
.clues div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 16px; background: var(--raised); border-radius: 12px; }
.clues dt { color: var(--muted); font-size: var(--step-small); }
.clues dd { text-align: right; font-weight: 500; }
.guess-form { display: flex; gap: 10px; align-items: end; }
.guess-form .field { flex: 1; }
.guesses { width: 100%; margin-top: 20px; border-collapse: collapse; font-size: var(--step-small); }
.guesses th, .guesses td { padding: 10px 6px; text-align: left; }
.guesses thead th { color: var(--muted); font-weight: 400; }
.guesses caption { text-align: left; padding-bottom: 8px; color: var(--muted); }
.guesses tbody tr { border-top: 1px solid var(--edge); }
.guesses tbody th { font-weight: 500; }
.guesses td.is-right { background: var(--accent); color: var(--accent-ink); }
.guesses td.is-wrong { color: var(--muted); }
.share {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px;
    margin-top: var(--gap); padding: 16px 16px 16px 24px;
    background: var(--raised); border-radius: var(--radius);
}

/* Pages du catalogue et valeurs inconnues */
.pager { display: flex; justify-content: center; align-items: center; gap: 16px; margin-top: 24px; font-size: var(--step-small); color: var(--muted); }
.unknown { color: var(--muted); }

@media (max-width: 900px) {
    .games { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
    .guess-form { flex-direction: column; align-items: stretch; }
    .guesses thead { display: none; }
    .guesses tbody tr { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; padding: 10px 0; }
    .guesses tbody th { grid-column: 1 / -1; padding: 0 0 4px; }
    .guesses td { padding: 6px; border-radius: 8px; text-align: center; background: var(--raised); }
}
