/* ==========================================================================
   RTP Auto – Homepage
   Depends on the tokens defined in site.css.
   Visual motif: the "Triangle" – angled shapes, outlined numerals, motion
   that respects prefers-reduced-motion.
   ========================================================================== */

.home {
    --c-ink-2: #12223a;
    --c-glass: rgb(255 255 255 / 6%);
    --c-glass-line: rgb(255 255 255 / 12%);
    --c-mint: #3ddc84;

    background: var(--c-bg);
    color: var(--c-text);
    font-family: var(--f-body);
    overflow-x: clip;
}

.home h1, .home h2, .home h3 { font-family: var(--f-display); color: inherit; }
.home p { color: inherit; }
.home ul[role="list"], .home ol[role="list"] { list-style: none; margin: 0; padding: 0; }

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    margin: 0 0 .65rem;
    color: var(--c-brand-text);
    font-family: var(--f-display);
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
}
/* Small triangle glyph – the brand motif */
.eyebrow::before {
    content: "";
    width: 10px;
    height: 9px;
    background: currentColor;
    clip-path: polygon(50% 0, 100% 100%, 0 100%);
}
.eyebrow--light { color: var(--c-brand); }
.muted { color: var(--c-muted); }

/* ---------- Section scaffolding ---------- */
.section { padding: clamp(3rem, 6vw, 5.5rem) 0; }
.section--tight { padding: clamp(2.5rem, 4vw, 3.5rem) 0; }
.section--alt { background: var(--c-surface); border-block: 1px solid var(--c-line); }

.section__head {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 1rem 2rem;
    margin-bottom: 2rem;
}
.section__actions { display: flex; align-items: center; gap: 1rem; flex-shrink: 0; }

.section__title {
    margin: 0;
    font-size: clamp(1.75rem, 1.2rem + 1.8vw, 2.75rem);
    font-weight: 800;
    letter-spacing: -.035em;
    line-height: 1.05;
    text-wrap: balance;
}

.link-arrow {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    flex-shrink: 0;
    padding: .6rem 1.1rem;
    border: 1.5px solid var(--c-line);
    border-radius: 999px;
    background: var(--c-surface);
    color: var(--c-text);
    font-family: var(--f-display);
    font-weight: 700;
    font-size: .875rem;
    text-decoration: none;
    white-space: nowrap;
    transition: background-color .2s, border-color .2s, color .2s;
}
.link-arrow::after { content: "→"; transition: transform .25s var(--ease); }
.link-arrow:hover { background: var(--c-ink); border-color: var(--c-ink); color: #fff; }
.link-arrow:hover::after { transform: translateX(3px); }

/* ==========================================================================
   Hero
   ========================================================================== */
.hero { position: relative; isolation: isolate; }

.hero__stage {
    position: relative;
    padding: clamp(3rem, 7vw, 6rem) 0 clamp(7rem, 10vw, 9rem);
    background:
        radial-gradient(50% 70% at 90% 0%, rgb(43 182 232 / 26%), transparent 65%),
        radial-gradient(45% 60% at 0% 100%, rgb(217 54 62 / 18%), transparent 70%),
        var(--c-ink);
    color: var(--c-on-dark);
    overflow: hidden;
    /* Angled bottom edge */
    clip-path: polygon(0 0, 100% 0, 100% 100%, 0 calc(100% - clamp(2rem, 5vw, 4.5rem)));
}

/* Faint grid + floating triangles */
.hero__decor { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.hero__decor::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgb(255 255 255 / 4%) 1px, transparent 1px),
        linear-gradient(90deg, rgb(255 255 255 / 4%) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: radial-gradient(80% 70% at 60% 30%, #000, transparent 75%);
    -webkit-mask-image: radial-gradient(80% 70% at 60% 30%, #000, transparent 75%);
}
.tri {
    position: absolute;
    clip-path: polygon(50% 0, 100% 100%, 0 100%);
    animation: drift 14s ease-in-out infinite alternate;
}
.tri--a { top: 12%; right: 6%; width: 140px; height: 120px; background: linear-gradient(160deg, rgb(43 182 232 / 35%), transparent 75%); }
.tri--b { bottom: 18%; left: 44%; width: 70px; height: 60px; background: linear-gradient(160deg, rgb(217 54 62 / 40%), transparent 80%); animation-duration: 11s; animation-delay: -4s; }
.tri--c { top: 26%; left: -30px; width: 110px; height: 95px; background: linear-gradient(160deg, rgb(255 255 255 / 10%), transparent 80%); animation-duration: 17s; }
@keyframes drift {
    from { transform: translateY(0) rotate(0deg); }
    to   { transform: translateY(-24px) rotate(14deg); }
}

.hero__inner {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    align-items: center;
    gap: 3rem;
}

.hero__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: .6rem;
    margin-bottom: 1.5rem;
    padding: .45rem 1rem;
    border: 1px solid var(--c-glass-line);
    border-radius: 999px;
    background: var(--c-glass);
    color: var(--c-on-dark-muted);
    font-size: .85rem;
    font-weight: 600;
    backdrop-filter: blur(6px);
}
.hero__eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--c-brand); box-shadow: 0 0 0 4px rgb(43 182 232 / 20%); }

.hero__title {
    margin: 0 0 1.5rem;
    max-width: 14ch;
    font-size: clamp(2.6rem, 1.3rem + 5vw, 5.25rem);
    font-weight: 800;
    letter-spacing: -.045em;
    line-height: .98;
    color: #fff !important;
    text-wrap: balance;
}
.hero__title em {
    position: relative;
    display: inline-block;
    font-style: normal;
    background: linear-gradient(100deg, var(--c-brand) 10%, #8fe3ff 55%, var(--c-brand) 90%);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    animation: shimmer 6s linear infinite;
}
.hero__title em svg {
    position: absolute;
    left: 0;
    bottom: -.12em;
    width: 100%;
    height: .22em;
    overflow: visible;
}
.hero__title em path {
    fill: none;
    stroke: var(--c-coral);
    stroke-width: 5;
    stroke-linecap: round;
    stroke-dasharray: 320;
    stroke-dashoffset: 320;
    animation: draw 1.2s .4s var(--ease) forwards;
}
@keyframes shimmer { to { background-position: -200% 0; } }
@keyframes draw { to { stroke-dashoffset: 0; } }

.hero__lead {
    max-width: 50ch;
    margin: 0;
    color: var(--c-on-dark-muted) !important;
    font-size: clamp(1rem, .95rem + .35vw, 1.2rem);
    line-height: 1.6;
}

.hero__stats {
    display: flex;
    flex-wrap: wrap;
    gap: 1.25rem 2.5rem;
    margin: 2.25rem 0 0;
}
.hero__stats > div { position: relative; padding-left: 1rem; }
.hero__stats > div::before {
    content: "";
    position: absolute;
    left: 0;
    top: .2rem;
    bottom: .2rem;
    width: 3px;
    border-radius: 3px;
    background: linear-gradient(var(--c-brand), var(--c-coral));
}
.hero__stats dt {
    color: var(--c-on-dark-muted);
    font-size: .8rem;
    font-weight: 600;
    letter-spacing: .04em;
}
.hero__stats dd {
    margin: 0;
    color: #fff;
    font-family: var(--f-display);
    font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem);
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.1;
}
.hero__stats > div { display: flex; flex-direction: column-reverse; }

/* ---------- "Just listed" card deck ---------- */
.deck { position: relative; justify-self: center; width: min(100%, 360px); }
.deck__label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    margin: 0 0 1.25rem;
    color: var(--c-on-dark-muted) !important;
    font-family: var(--f-display);
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
}
.pulse { width: 8px; height: 8px; border-radius: 50%; background: var(--c-mint); animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgb(61 220 132 / 60%); } 70% { box-shadow: 0 0 0 8px rgb(61 220 132 / 0%); } 100% { box-shadow: 0 0 0 0 rgb(61 220 132 / 0%); } }

.deck__cards {
    position: relative;
    display: grid;
    height: 340px;
}
.deck__card {
    --offset: calc(var(--i) - (var(--n) - 1) / 2);
    grid-area: 1 / 1;
    align-self: start;
    justify-self: center;
    width: 280px;
    z-index: calc(10 - var(--i));
    transform: translateX(calc(var(--offset) * 34px)) translateY(calc(var(--i) * 14px)) rotate(calc(var(--offset) * 7deg));
    transform-origin: 50% 120%;
    transition: transform .5s var(--ease), z-index 0s .15s;
}
.deck:hover .deck__card {
    transform: translateX(calc(var(--offset) * 70px)) translateY(calc(var(--i) * 6px)) rotate(calc(var(--offset) * 11deg));
}
.deck__card:hover,
.deck__card:focus-within {
    z-index: 20;
    transition: transform .5s var(--ease), z-index 0s;
}
.deck .deck__card:hover,
.deck .deck__card:focus-within {
    transform: translateX(calc(var(--offset) * 70px)) translateY(-14px) rotate(calc(var(--offset) * 4deg)) scale(1.04);
}

.deck__link {
    display: block;
    padding: .6rem .6rem .9rem;
    border: 1px solid rgb(255 255 255 / 14%);
    border-radius: 20px;
    background: linear-gradient(180deg, #1b2c46, #13223a);
    color: inherit;
    text-decoration: none;
    box-shadow: 0 30px 50px -20px rgb(0 0 0 / 70%);
}
.deck__link:hover { color: inherit; }
.deck__link:focus-visible { outline: 3px solid var(--c-brand); outline-offset: 3px; }

.deck__photo {
    position: relative;
    display: grid;
    place-items: center;
    aspect-ratio: 16 / 11;
    border-radius: 14px;
    background: linear-gradient(160deg, #22385a, #172943);
    color: var(--c-on-dark-muted);
    overflow: hidden;
}
.deck__photo img { width: 100%; height: 100%; object-fit: cover; }
.deck__photo .body-icon { width: 60%; height: auto; }
.deck__price {
    position: absolute;
    left: .6rem;
    bottom: .6rem;
    padding: .3rem .7rem;
    border-radius: 999px;
    background: #fff;
    color: var(--c-ink);
    font-family: var(--f-display);
    font-size: .9rem;
    font-weight: 800;
    box-shadow: 0 6px 16px -6px rgb(0 0 0 / 50%);
}
.deck__info { display: block; padding: .75rem .35rem 0; }
.deck__info strong,
.deck__info small { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.deck__info strong { color: #fff; font-family: var(--f-display); font-size: .95rem; }
.deck__info small { margin-top: .15rem; color: var(--c-on-dark-muted); font-size: .8rem; }

/* ---------- Search command bar ---------- */
.hero__search {
    position: relative;
    z-index: 2;
    margin-top: clamp(-6.5rem, -8vw, -5rem);
}

.search {
    position: relative;
    padding: .75rem;
    border-radius: 28px;
    background: var(--c-surface);
    color: var(--c-text);
    box-shadow: var(--shadow-lg), 0 0 0 1px rgb(11 22 38 / 4%);
}

.search__conditions {
    display: inline-flex;
    gap: .25rem;
    margin: 0 0 .6rem;
    padding: .25rem;
    border: 0;
    border-radius: 999px;
    background: var(--c-bg);
}

.seg { position: relative; margin: 0; cursor: pointer; }
.seg input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.seg span {
    display: block;
    padding: .45rem 1rem;
    border-radius: 999px;
    color: var(--c-muted);
    font-family: var(--f-display);
    font-size: .825rem;
    font-weight: 700;
    transition: background-color .2s, color .2s;
}
.seg:hover span { color: var(--c-text); }
.seg input:checked + span { background: var(--c-ink); color: #fff; }
.seg input:focus-visible + span { outline: 3px solid var(--c-brand); outline-offset: 2px; }

.search__fields {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr) minmax(0, .9fr) minmax(0, 1.25fr) auto;
    align-items: stretch;
    border: 1.5px solid var(--c-line);
    border-radius: 22px;
    background: #f8fafc;
}

.field {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
    padding: .7rem 1.1rem .55rem;
    border-radius: 20px;
    transition: background-color .2s, box-shadow .2s;
}
/* Hairline dividers between cells */
.field + .field::before {
    content: "";
    position: absolute;
    left: 0;
    top: 22%;
    bottom: 22%;
    width: 1px;
    background: var(--c-line);
    transition: opacity .2s;
}
.field:hover { background: #eef2f7; }
.field:focus-within {
    background: #fff;
    box-shadow: 0 0 0 2px var(--c-brand), 0 12px 24px -12px rgb(11 22 38 / 30%);
    z-index: 1;
}
.field:hover::before, .field:focus-within::before,
.field:hover + .field::before, .field:focus-within + .field::before { opacity: 0; }

.field label {
    margin: 0;
    color: var(--c-text);
    font-family: var(--f-display);
    font-size: .75rem;
    font-weight: 800;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.field input,
.field select {
    width: 100%;
    height: 30px;
    padding: 0;
    border: 0;
    background-color: transparent;
    color: var(--c-text);
    font: 600 1rem var(--f-body);
}
.field input:focus, .field select:focus { outline: none; }
.field select {
    appearance: none;
    padding-right: 1.5rem;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235a6b80' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0 center;
    background-size: 14px;
}
.field input::placeholder { color: #64748b; font-weight: 400; }
.field input[aria-invalid="true"] { color: var(--c-coral-hover); }
.field:has(input[aria-invalid="true"]) { box-shadow: 0 0 0 2px var(--c-coral); background: #fff5f5; }
.field__error { margin-top: .15rem; color: var(--c-coral-hover); font-size: .8rem; font-weight: 600; }

.zip-group { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: .5rem; align-items: center; }
.zip-group input { letter-spacing: .08em; }
.zip-group select {
    width: auto;
    height: 26px;
    padding: 0 1.4rem 0 .6rem;
    border-radius: 999px;
    background-color: var(--c-bg);
    background-position: right .4rem center;
    background-size: 12px;
    font-size: .85rem;
}

.search__submit {
    align-self: center;
    height: 56px;
    margin: .35rem;
    padding-inline: 1.6rem;
    border-radius: 18px;
    font-size: 1rem;
}

/* ---------- Quick links ---------- */
.quick-links {
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: 1.1rem .25rem .25rem;
    overflow-x: auto;
    scrollbar-width: none;
}
.quick-links::-webkit-scrollbar { display: none; }
.quick-links__label { color: var(--c-muted); font-size: .875rem; font-weight: 600; white-space: nowrap; margin-right: .25rem; }

.chip {
    flex-shrink: 0;
    padding: .5rem 1rem;
    border: 1px solid var(--c-line);
    border-radius: 999px;
    background: var(--c-surface);
    color: var(--c-text);
    font-size: .875rem;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    transition: border-color .2s, background-color .2s, color .2s, transform .2s var(--ease);
}
.chip:hover { border-color: var(--c-ink); background: var(--c-ink); color: #fff; transform: translateY(-2px); }

/* ---------- City marquee ---------- */
.marquee {
    margin-top: clamp(2rem, 4vw, 3rem);
    padding-block: .5rem;
    overflow: hidden;
    mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent);
}
.marquee__track {
    display: flex;
    width: max-content;
    animation: marquee 40s linear infinite;
}
.marquee__track span {
    display: inline-flex;
    align-items: center;
    padding-right: 2.5rem;
    color: transparent;
    font-family: var(--f-display);
    font-size: clamp(2.25rem, 1.5rem + 3vw, 4.25rem);
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.1;
    white-space: nowrap;
    -webkit-text-stroke: 1.5px #c9d3e0;
}
.marquee__track span::after {
    content: "";
    width: .45em;
    height: .4em;
    margin-left: 2.5rem;
    background: var(--c-coral);
    clip-path: polygon(50% 0, 100% 100%, 0 100%);
}
.marquee__track span:nth-child(3n + 2)::after { background: var(--c-brand); }
.marquee__track span:nth-child(3n)::after { background: var(--c-ink); }
@keyframes marquee { to { transform: translateX(-50%); } }
.marquee:hover .marquee__track { animation-play-state: paused; }

/* home.js sets this while the hero is scrolled out of view, so the looping
   shimmer/drift/marquee stop repainting behind the rest of the page. */
.hero.is-offscreen *,
.hero.is-offscreen *::before,
.hero.is-offscreen *::after { animation-play-state: paused !important; }

/* ==========================================================================
   Body styles
   ========================================================================== */
.bstyles {
    display: grid;
    grid-template-columns: repeat(9, minmax(0, 1fr));
    gap: .75rem;
}

.bstyle {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: .15rem;
    height: 100%;
    padding: .9rem .9rem 1rem;
    border: 1px solid var(--c-line);
    border-radius: 18px;
    background: var(--c-surface);
    color: var(--c-text);
    text-decoration: none;
    overflow: hidden;
    isolation: isolate;
    transition: color .3s var(--ease), border-color .3s, transform .3s var(--ease);
}
/* Ink fill sweeps up from the bottom on hover */
.bstyle::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: var(--c-ink);
    clip-path: polygon(0 100%, 100% 100%, 100% 100%, 0 100%);
    transition: clip-path .45s var(--ease);
}
.bstyle__num {
    color: var(--c-muted);
    font-family: var(--f-display);
    font-size: .7rem;
    font-weight: 800;
    letter-spacing: .1em;
}
.bstyle .body-icon {
    width: 100%;
    height: 44px;
    margin: .6rem 0 .7rem;
    color: var(--c-ink);
    transition: color .3s, transform .5s var(--ease);
}
.bstyle__label { font-family: var(--f-display); font-weight: 700; font-size: .9rem; line-height: 1.2; }
.bstyle__count { color: var(--c-muted); font-size: .78rem; transition: color .3s; }
.bstyle:hover, .bstyle:focus-visible { color: #fff; border-color: var(--c-ink); transform: translateY(-4px); }
.bstyle:hover::before, .bstyle:focus-visible::before { clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%); }
.bstyle:hover .body-icon, .bstyle:focus-visible .body-icon { color: var(--c-brand); transform: translateX(8px); }
/* The car rolls 8px forward; 72deg is the matching turn for a ~6px tyre */
.bstyle .body-icon__wheel { transform-box: fill-box; transform-origin: center; transition: transform .5s var(--ease); }
.bstyle:hover .body-icon__wheel, .bstyle:focus-visible .body-icon__wheel { transform: rotate(72deg); }
.bstyle:hover .bstyle__count, .bstyle:hover .bstyle__num,
.bstyle:focus-visible .bstyle__count, .bstyle:focus-visible .bstyle__num { color: var(--c-on-dark-muted); }
/* Dim only the artwork – fading the whole tile drops the text below 4.5:1 */
.bstyle.is-empty { border-style: dashed; }
.bstyle.is-empty .body-icon { opacity: .4; }

/* ==========================================================================
   Vehicle cards
   ========================================================================== */
.vehicle-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 1.25rem;
}
.vehicle-grid > li { display: flex; min-width: 0; }

/* Featured: bento – the first car gets a 2×2 spotlight */
.vehicle-grid--bento {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-flow: dense;
}
.vehicle-grid--bento > li:first-child { grid-column: span 2; grid-row: span 2; }

/* Newest: horizontal rail */
.vehicle-grid--rail {
    display: flex;
    gap: 1.25rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding-inline: 12px;
    margin-inline: -12px;
    padding: .5rem 12px 1.25rem;
    scrollbar-width: none;
}
.vehicle-grid--rail::-webkit-scrollbar { display: none; }
.vehicle-grid--rail:focus-visible { outline: 3px solid var(--c-brand); outline-offset: 4px; border-radius: 18px; }
.vehicle-grid--rail > li { flex: 0 0 calc((100% - 3 * 1.25rem) / 4); scroll-snap-align: start; }

.rail-nav { display: flex; gap: .4rem; }
.rail-nav__btn {
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    padding: 0;
    border: 1.5px solid var(--c-line);
    border-radius: 50%;
    background: var(--c-surface);
    color: var(--c-text);
    cursor: pointer;
    transition: background-color .2s, border-color .2s, color .2s, opacity .2s;
}
.rail-nav__btn svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 2.5; stroke-linecap: round; stroke-linejoin: round; }
.rail-nav__btn:hover:not(:disabled) { background: var(--c-ink); border-color: var(--c-ink); color: #fff; }
.rail-nav__btn:disabled { opacity: .35; cursor: default; }
.rail-nav__btn:focus-visible { outline: 3px solid var(--c-brand); outline-offset: 2px; }

/* Spotlight card (first bento cell): photo fills the card, copy overlays it */
.vehicle-grid--bento > li:first-child .vcard { padding: 0; overflow: hidden; min-height: 420px; background: var(--c-ink); }
.vehicle-grid--bento > li:first-child .vcard__media { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 0; background: linear-gradient(160deg, #1b2c46, #0b1626); }
.vehicle-grid--bento > li:first-child .vcard__nophoto { color: #42597a; }
.vehicle-grid--bento > li:first-child .vcard__flag { top: 1.1rem; left: 1.1rem; }
.vehicle-grid--bento > li:first-child .vcard__body {
    position: relative;
    justify-content: flex-end;
    padding: 6rem 1.5rem 1.4rem;
    background: linear-gradient(to top, rgb(11 22 38 / 92%) 25%, rgb(11 22 38 / 0%));
    color: #fff;
    pointer-events: none;
}
.vehicle-grid--bento > li:first-child .vcard__body a { pointer-events: auto; }
.vehicle-grid--bento > li:first-child .vcard__title { font-size: clamp(1.35rem, 1rem + 1vw, 1.85rem); }
.vehicle-grid--bento > li:first-child .vcard__title a,
.vehicle-grid--bento > li:first-child .vcard__price { color: #fff !important; }
.vehicle-grid--bento > li:first-child .vcard__meta,
.vehicle-grid--bento > li:first-child .vcard__trim,
.vehicle-grid--bento > li:first-child .vcard__facts { color: var(--c-on-dark-muted); }
.vehicle-grid--bento > li:first-child .vcard__facts { border-top-color: rgb(255 255 255 / 18%); }
.vehicle-grid--bento > li:first-child .vcard__price { font-size: clamp(1.6rem, 1.2rem + 1.2vw, 2.25rem); }
.vehicle-grid--bento > li:first-child .vcard__foot { flex: 0; }
.vehicle-grid--bento > li:first-child .vcard__go { width: 48px; height: 48px; background: #fff; color: var(--c-ink); }

.empty-state {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.5rem;
    border: 1.5px dashed #cbd5e1;
    border-radius: 22px;
    background: var(--c-surface);
}
.empty-state p { margin: 0; }

/* ==========================================================================
   Budget ladder + make cloud
   ========================================================================== */
.shop-by {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 1.5rem;
}

.panel {
    padding: clamp(1.5rem, 3vw, 2.5rem);
    border: 1px solid var(--c-line);
    border-radius: 28px;
    background: var(--c-bg);
}
.panel__lead { margin: .6rem 0 2rem; color: var(--c-muted) !important; }

.ladder {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);
    gap: .6rem;
    align-items: end;
}
.ladder__col {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: .45rem;
    color: var(--c-text);
    text-align: center;
    text-decoration: none;
}
.ladder__col:hover { color: var(--c-text); }
.ladder__track {
    position: relative;
    display: block;
    height: 200px;
    border-radius: 14px;
    background: repeating-linear-gradient(0deg, transparent 0 19px, rgb(11 22 38 / 5%) 19px 20px);
    order: 2;
}
.ladder__fill {
    position: absolute;
    inset: auto 0 0;
    height: var(--h);
    border-radius: 14px 14px 10px 10px;
    background: linear-gradient(180deg, var(--c-brand), #1a8fc0);
    transform-origin: bottom;
    transition: background .3s, transform .3s var(--ease);
}
.ladder li:nth-child(odd) .ladder__fill { background: linear-gradient(180deg, #4ac4ee, var(--c-brand-text)); }
.ladder__col:hover .ladder__fill,
.ladder__col:focus-visible .ladder__fill { background: linear-gradient(180deg, #f0606a, var(--c-coral)); transform: scaleX(1.08); }
.ladder__col:focus-visible { outline: none; }
.ladder__col:focus-visible .ladder__track { outline: 3px solid var(--c-brand); outline-offset: 3px; }
.ladder__count { order: 1; color: var(--c-muted); font-size: .78rem; font-weight: 700; white-space: nowrap; }
.ladder__label { order: 3; font-size: .85rem; white-space: nowrap; }
.ladder__label strong { display: block; font-family: var(--f-display); font-size: 1.1rem; letter-spacing: -.02em; }

.cloud {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: .5rem 1.4rem;
}
.cloud__item {
    --size: calc(1rem + var(--w, .5) * 1.6rem);
    display: inline-flex;
    align-items: flex-start;
    gap: .2rem;
    color: var(--c-text);
    font-family: var(--f-display);
    font-size: var(--size);
    font-weight: 800;
    letter-spacing: -.03em;
    line-height: 1.15;
    text-decoration: none;
    transition: color .2s, transform .3s var(--ease);
}
.cloud__name { background: linear-gradient(var(--c-coral), var(--c-coral)) 0 100% / 0 .12em no-repeat; transition: background-size .35s var(--ease); }
.cloud__count {
    margin-top: .15em;
    color: var(--c-brand-text);
    font-size: max(.7rem, calc(var(--size) * .38));
    font-weight: 700;
    letter-spacing: 0;
}
.cloud__item:hover, .cloud__item:focus-visible { color: var(--c-ink); transform: translateY(-2px); }
.cloud__item:hover .cloud__name, .cloud__item:focus-visible .cloud__name { background-size: 100% .12em; }

/* ==========================================================================
   Why us (dark band)
   ========================================================================== */
.why-band {
    position: relative;
    background:
        radial-gradient(40% 60% at 100% 100%, rgb(43 182 232 / 18%), transparent 70%),
        var(--c-ink);
    color: var(--c-on-dark);
    overflow: hidden;
}
.why-band::before {
    content: "";
    position: absolute;
    top: -80px;
    left: -60px;
    width: 340px;
    height: 300px;
    background: linear-gradient(160deg, rgb(255 255 255 / 5%), transparent 70%);
    clip-path: polygon(50% 0, 100% 100%, 0 100%);
    pointer-events: none;
}

.why {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
    gap: clamp(2rem, 6vw, 6rem);
    align-items: start;
}
.why__head { position: sticky; top: 110px; }
.why__head .section__title { color: #fff; font-size: clamp(2rem, 1.3rem + 2.4vw, 3.4rem); }
.why__stat { margin: 1.5rem 0 2rem; color: var(--c-on-dark-muted) !important; font-size: 1.05rem; }
.why__stat strong { color: #fff; font-family: var(--f-display); }

.why__item {
    display: grid;
    grid-template-columns: auto auto minmax(0, 1fr);
    gap: 1.25rem;
    align-items: start;
    padding: 1.75rem 0;
    border-top: 1px solid var(--c-glass-line);
}
.why__item:last-child { border-bottom: 1px solid var(--c-glass-line); }
.why__num {
    min-width: 2.4ch;
    color: transparent;
    font-family: var(--f-display);
    font-size: 2.75rem;
    font-weight: 800;
    line-height: 1;
    -webkit-text-stroke: 1.5px rgb(255 255 255 / 30%);
    transition: color .3s, -webkit-text-stroke-color .3s;
}
.why__item:hover .why__num { color: var(--c-brand); -webkit-text-stroke-color: var(--c-brand); }
.why__icon {
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border: 1px solid var(--c-glass-line);
    border-radius: 14px;
    background: var(--c-glass);
    color: var(--c-brand);
}
.why__icon svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.why__item h3 { margin: .2rem 0 .45rem; color: #fff; font-size: 1.2rem; font-weight: 800; }
.why__item p { margin: 0; color: var(--c-on-dark-muted) !important; line-height: 1.65; }

/* ==========================================================================
   Sell CTA
   ========================================================================== */
.sell {
    display: grid;
    grid-template-columns: 1.15fr 1fr;
    gap: 1.25rem;
}
.sell__card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    min-height: 320px;
    padding: clamp(1.75rem, 3.5vw, 3rem);
    border: 1px solid var(--c-line);
    border-radius: 28px;
    background: var(--c-surface);
    overflow: hidden;
    isolation: isolate;
}
.sell__card h2 { margin: 0 0 .6rem; max-width: 18ch; font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2.25rem); font-weight: 800; letter-spacing: -.03em; line-height: 1.1; }
.sell__card p:not(.eyebrow) { margin: 0 0 1.75rem; max-width: 40ch; color: var(--c-muted) !important; }
.sell__card .rtp-btn { margin-top: auto; }

/* Oversized outline car that rolls in on hover */
.sell__art {
    position: absolute;
    right: -6%;
    bottom: -4%;
    z-index: -1;
    width: 62%;
    height: auto;
    color: var(--c-line);
    stroke-width: 1.25;
    transition: transform .8s var(--ease), color .4s;
}
.sell__card:hover .sell__art { transform: translateX(-6%); color: #cfe9f5; }

.sell__card--dark {
    border: 0;
    background:
        radial-gradient(70% 120% at 100% 0%, rgb(217 54 62 / 30%), transparent 60%),
        radial-gradient(60% 80% at 0% 100%, rgb(43 182 232 / 22%), transparent 60%),
        var(--c-ink);
    color: #fff;
}
.sell__card--dark h2 { color: #fff; }
.sell__card--dark p:not(.eyebrow) { color: var(--c-on-dark-muted) !important; }
.sell__card--dark .sell__art { color: rgb(255 255 255 / 8%); }
.sell__card--dark:hover .sell__art { color: rgb(43 182 232 / 25%); }

/* ==========================================================================
   Scroll reveal – home.js only adds .reveal-pending to elements that start
   below the fold, so nothing flashes and no-JS visitors see everything.
   ========================================================================== */
.reveal-pending { opacity: 0; transform: translateY(28px); }
.reveal-in { transition: opacity .8s var(--ease), transform .8s var(--ease); }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1199.98px) {
    .search__fields { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .25rem; padding: .25rem; }
    .field--grow { grid-column: span 2; order: -1; }
    .field + .field::before { display: none; }
    .search__submit { grid-column: span 2; width: auto; margin: .25rem; }
    .vehicle-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .vehicle-grid--rail > li { flex-basis: calc((100% - 2 * 1.25rem) / 3); }
    .bstyles {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        margin-inline: -12px;
        padding: .5rem 12px .75rem;
        scrollbar-width: none;
    }
    .bstyles::-webkit-scrollbar { display: none; }
    .bstyles > li { flex: 0 0 140px; scroll-snap-align: start; }
}

@media (max-width: 991.98px) {
    .hero__inner { grid-template-columns: 1fr; gap: 2.5rem; }
    .deck { display: none; }
    .vehicle-grid,
    .vehicle-grid--bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .vehicle-grid--bento > li:first-child { grid-row: auto; }
    .vehicle-grid--rail > li { flex-basis: calc((100% - 1.25rem) / 2); }
    .shop-by { grid-template-columns: 1fr; }
    .why { grid-template-columns: 1fr; }
    .why__head { position: static; }
    .sell { grid-template-columns: 1fr; }
}

@media (max-width: 575.98px) {
    .section__head { flex-direction: column; align-items: flex-start; }
    .section__actions { width: 100%; justify-content: space-between; }
    .hero__stats { gap: 1rem 1.5rem; }
    .search { padding: .5rem; border-radius: 22px; }
    .search__conditions { display: flex; overflow-x: auto; max-width: 100%; scrollbar-width: none; }
    .search__fields { grid-template-columns: 1fr; }
    .field--grow, .search__submit { grid-column: auto; }
    .vehicle-grid,
    .vehicle-grid--bento {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        margin-inline: -12px;
        padding: .5rem 12px 1rem;
        scrollbar-width: none;
    }
    .vehicle-grid > li,
    .vehicle-grid--rail > li { flex: 0 0 82%; scroll-snap-align: start; }
    .vehicle-grid--bento > li:first-child .vcard { min-height: 380px; }
    .ladder { gap: .35rem; }
    .ladder__track { height: 160px; }
    .ladder__count { font-size: .68rem; }
    .ladder__label { font-size: .72rem; }
    .ladder__label strong { font-size: .95rem; }
    .why__item { grid-template-columns: auto minmax(0, 1fr); }
    .why__num { display: none; }
    .sell__art { width: 80%; }
}

@media (prefers-reduced-motion: reduce) {
    .home *, .home *::before, .home *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
    .marquee__track { animation: none; }
    .hero__title em path { stroke-dashoffset: 0; }
    .reveal-pending { opacity: 1; transform: none; }
}
.sell__card .sell__note { margin: 0; max-width: 40ch; color: var(--c-on-dark-muted, #9fb0c6) !important; font-size: .92rem; }
