/* Home hero: featured-car stage and the bottom card row (original showroom design, now fed by the API). */
/* Text sits in its own row above the stage, so the car never covers the title or tagline. */
.hero{position:relative;display:flex;flex-direction:column;padding:20px 34px 44px;overflow-x:clip}
.hero-top{display:flex;justify-content:space-between;align-items:flex-start;gap:24px;position:relative;z-index:3}
.headline{min-width:0;max-width:62%}
.headline h1{font-size:clamp(28px,3.4vw,48px);font-weight:800;letter-spacing:-1px;line-height:1.25}
.headline em{font-style:normal;color:var(--accent)}
.headline p{font-size:14px;color:var(--text-2);margin-top:4px;max-width:60ch}
.headline .badges{display:flex;gap:6px;flex-wrap:wrap;margin-top:10px}
.hero-price{flex:none;text-align:left}
.hero-price strong{display:flex;align-items:center;gap:10px;font-size:clamp(28px,3.4vw,48px);font-weight:800;letter-spacing:-1px;line-height:1.25;direction:rtl}
.hero-price small{font-size:13px;font-weight:600;color:var(--muted-2);line-height:1.35;text-align:right}
.hero-price a{font-size:13.5px;font-weight:600;color:var(--link);margin-top:4px;display:inline-block}
.hero-price a:hover{color:var(--link);text-decoration:underline}
.stage{position:relative;height:clamp(230px,24vw,370px);margin:6px -34px 0;display:flex;align-items:flex-end;justify-content:center}
.podium{position:absolute;left:50%;bottom:6%;width:min(980px,82%);height:22%;transform:translateX(-50%);border-radius:50%;background:radial-gradient(closest-side,#f7f7f7 0%,#f1f1f1 55%,#ebebeb00 100%);box-shadow:inset 0 -1px 0 #d9dadb}
.podium:after{content:'';position:absolute;inset:18% 8%;border-radius:50%;border:1px solid #dcdddf}
.car{position:relative;z-index:2;width:min(820px,62%);height:100%;display:flex;align-items:flex-end;justify-content:center;padding-bottom:3%}
.car img{width:100%;height:100%;object-fit:contain;object-position:bottom;user-select:none}
.car .demo-note{position:absolute;bottom:-4px;left:0;font-size:10px;color:#8b9095}
.peek{position:absolute;bottom:12%;width:min(330px,24%);z-index:1;transition:transform .3s}
.peek img{width:100%;height:auto;object-fit:contain}
.peek-next{left:-9%}
.peek-prev{right:-9%}
.peek-next:hover{transform:translateX(12px)}
.peek-prev:hover{transform:translateX(-12px)}
.enter-next{animation:enter-next .55s cubic-bezier(.2,.75,.2,1) both}
.enter-prev{animation:enter-prev .55s cubic-bezier(.2,.75,.2,1) both}
@keyframes enter-next{from{opacity:0;transform:translateX(-70px)}}
@keyframes enter-prev{from{opacity:0;transform:translateX(70px)}}
.arrows{position:absolute;left:50%;bottom:-6px;transform:translateX(-50%);z-index:4;display:flex;gap:4px;align-items:center;background:var(--card);border-radius:30px 30px 0 0;padding:10px 14px 6px;white-space:nowrap}
.arrows button{height:34px;border-radius:20px;display:grid;place-items:center;transition:background .2s}
.arrows button:not(.sort){width:38px}
.arrows button:hover{background:var(--hover)}
.arrows button:focus-visible{outline:2px solid var(--accent);outline-offset:1px}
.arrows svg{width:20px;height:20px;fill:none;stroke:var(--ink);stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.arrows .divider{width:1px;height:18px;background:var(--line);margin:0 6px}
.arrows .sort{display:flex;align-items:center;gap:6px;padding:0 12px;font-size:12.5px;font-weight:600;color:var(--ink)}
.arrows .sort svg{width:16px;height:16px}
.arrows .pos{font-size:11px;color:var(--muted);min-width:34px;text-align:center}

.hero-cards{display:grid;grid-template-columns:minmax(0,2.3fr) repeat(3,minmax(0,1fr)) minmax(0,2.3fr);grid-template-rows:repeat(2,minmax(92px,auto));gap:6px;padding:0 4px 4px;position:relative;z-index:5}
.hero-cards .card,.hero-cards .spec{background:var(--card);border-radius:14px}
.valuation{grid-column:1;grid-row:1/3;display:flex;flex-direction:column;justify-content:space-between;gap:8px;padding:14px 18px 16px;overflow:hidden}
.valuation header{display:flex;align-items:baseline;justify-content:space-between;gap:10px}
.valuation header strong{font-size:15px;font-weight:800;flex:none}
.valuation header small{font-size:11px;color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;min-width:0}
.valuation dl{display:grid;gap:5px}
.valuation dl div{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:6px 12px;border-radius:12px;background:var(--soft)}
.valuation dt{font-size:12px;color:var(--text-2)}
.valuation dt .badge{margin-right:4px}
.valuation dd{display:flex;align-items:baseline;gap:5px;font-size:17px;font-weight:800;letter-spacing:-.3px;white-space:nowrap}
.valuation dd small{font-size:10px;font-weight:500;color:var(--muted);letter-spacing:0}
.valuation .btn{width:100%}
.hero-cards .spec{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:12px 8px;gap:3px}
.hero-cards .spec svg{width:20px;height:20px;fill:none;stroke:var(--ink);stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;margin-bottom:4px}
.hero-cards .spec strong{font-size:14px;font-weight:700}
.hero-cards .spec small{font-size:10.5px;color:var(--muted)}
.colors{grid-column:5;grid-row:1/3;display:grid;grid-template-columns:1fr minmax(0,1fr) auto;align-items:center;gap:12px;padding:16px 18px}
.colors-copy p{font-size:13px;line-height:1.6;color:var(--text-2)}
.colors-copy p b{font-size:14px}
.colors-copy b{color:var(--ink);font-weight:700}
.colors-copy strong{display:block;white-space:nowrap;font-size:20px;font-weight:800;margin-top:8px;letter-spacing:-.5px}
.colors-copy small{font-size:11px;color:var(--muted);display:block;line-height:1.6;margin-top:2px}
.mini-car{align-self:center}
.mini-car img{width:100%;height:auto;object-fit:contain}
.swatches{display:flex;flex-direction:column;gap:8px}
.swatches button{width:26px;height:26px;border-radius:50%;background:var(--swatch);box-shadow:inset 0 0 0 1px #0002;position:relative;transition:transform .2s}
.swatches button:hover{transform:scale(1.1)}
.swatches button[aria-checked="true"]{box-shadow:0 0 0 2px var(--card),0 0 0 4px var(--ink)}
.swatches button[aria-checked="true"]:after{content:'';position:absolute;left:8px;top:6px;width:8px;height:5px;border:solid #fff;border-width:0 0 2px 2px;transform:rotate(-45deg);mix-blend-mode:difference}

/* 16 shortcuts: 8 / 4 / 2 per row so every row is full. */
.modules{display:grid;grid-template-columns:repeat(8,minmax(0,1fr));gap:10px}
.module{background:var(--card);border-radius:16px;padding:14px;display:flex;flex-direction:column;gap:6px;transition:transform .2s,box-shadow .2s}
.module:hover{transform:translateY(-2px);box-shadow:0 10px 24px #0000001a;color:var(--ink)}
.module svg{width:26px;height:26px;fill:none;stroke:var(--accent);stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}
.module strong{font-size:13.5px}
.module small{font-size:11.5px;color:var(--muted);line-height:1.5}

@media(max-width:1280px){.modules{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:1100px){
  .hero-cards{grid-template-columns:repeat(3,minmax(0,1fr));grid-template-rows:auto}
  .valuation{grid-column:1/3;grid-row:auto;order:-1}
  .colors{grid-column:3/4;grid-row:span 2;grid-template-columns:1fr auto}
  .colors .mini-car{display:none}
}
@media(max-width:760px){
  .hero{padding:16px 16px 56px}
  .hero-top{flex-direction:column;gap:6px}
  .headline{max-width:none}
  .headline h1,.hero-price strong{font-size:27px}
  .hero-price{text-align:right}
  .hero-price strong{justify-content:flex-start}
  .stage{height:auto;margin:14px -16px 0}
  .car{width:84%;height:auto}
  .car img{height:auto;max-height:240px}
  .peek{width:34%;bottom:16%}.peek-next{left:-22%}.peek-prev{right:-22%}
  .podium{width:110%;height:34%;bottom:2%}
  .arrows .sort span{display:none}
  .arrows .sort{padding:0 10px}
  .hero-cards{grid-template-columns:repeat(3,minmax(0,1fr))}
  .valuation,.colors{grid-column:1/-1;grid-row:auto}
  .colors{grid-template-columns:1fr 38% auto}
  .colors .mini-car{display:block}
  .hero-cards .spec strong{font-size:12.5px}
  .modules{grid-template-columns:repeat(2,minmax(0,1fr))}
}

/* Dark mode: the car stands in a pool of IMEN-blue light on a dark floor. */
@media screen{
  [data-theme="dark"] .stage:before{content:'';position:absolute;left:50%;bottom:6%;width:58%;height:42%;transform:translateX(-50%);border-radius:50%;background:radial-gradient(closest-side,rgba(58,95,192,.75),rgba(38,69,147,.35) 60%,transparent);filter:blur(42px);pointer-events:none}
  [data-theme="dark"] .peek{opacity:.5;filter:saturate(.8)}
  [data-theme="dark"] .peek:hover{opacity:.8}
  [data-theme="dark"] .podium{background:radial-gradient(closest-side,rgba(143,176,255,.10) 0%,rgba(143,176,255,.04) 55%,transparent 100%);box-shadow:none}
  [data-theme="dark"] .podium:after{border-color:rgba(143,176,255,.14)}
  [data-theme="dark"] .arrows{box-shadow:inset 0 1px 0 var(--line)}
  [data-theme="dark"] .hero-cards .spec{box-shadow:inset 0 0 0 1px var(--line)}
  [data-theme="dark"] .module{box-shadow:inset 0 0 0 1px var(--line)}
  [data-theme="dark"] .module:hover{box-shadow:inset 0 0 0 1px var(--line-strong),0 14px 30px #0008}
  [data-theme="dark"] .valuation dl div{background:var(--soft)}
}
