/* =========================================================
   DEMO: Veloce Motors
   Paleta: asfaltowa biel, czerń, wyścigowa czerwień
   ========================================================= */
:root {
  --paper: #F0F0EC;
  --ink: #000;
  --red: #E10600;
  --gray: #8A8A86;
  --line: rgba(0, 0, 0, .14);
  --f: "Archivo", "Arial Narrow", system-ui, sans-serif;
  --pad: clamp(18px, 4vw, 64px);
  --cursor-bg: #E10600;
}
body { background: var(--paper); color: var(--ink); font-family: var(--f); font-size: 17px; line-height: 1.5; overflow-x: hidden; }
h1, h2, h3 { font-weight: 900; font-stretch: 125%; font-style: italic; line-height: .85; letter-spacing: -.02em; text-transform: uppercase; }
h2 { font-size: clamp(48px, 8vw, 140px); }
::selection { background: var(--red); color: #fff; }

.v-btn { display: inline-flex; align-items: center; justify-content: center; height: 54px; padding: 0 28px; background: var(--red); color: #fff; font-weight: 800; font-stretch: 112%; font-size: 14px; text-transform: uppercase; letter-spacing: .02em; text-decoration: none; clip-path: polygon(10px 0, 100% 0, calc(100% - 10px) 100%, 0 100%); transition: background .3s; }
.v-btn:hover { background: var(--ink); }
.v-btn--sm { height: 42px; padding: 0 22px; font-size: 12px; }
.v-btn--full { width: 100%; height: 62px; font-size: 16px; }

/* Nawigacja */
.v-nav { position: fixed; z-index: 300; top: 0; left: 0; right: 0; display: flex; align-items: center; gap: 36px; padding: 16px var(--pad); background: rgba(240,240,236,.85); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.v-logo { display: flex; align-items: center; gap: 6px; font-weight: 900; font-stretch: 125%; font-style: italic; font-size: 24px; letter-spacing: -.02em; text-decoration: none; margin-right: auto; }
.v-logo i { width: 26px; height: 5px; background: var(--red); transform: skewX(-20deg); }
.v-nav nav { display: flex; gap: 28px; }
.v-nav nav a { text-decoration: none; font-weight: 600; font-size: 14px; text-transform: uppercase; }
.v-nav nav a:hover { color: var(--red); }

/* Hero */
.v-hero { height: 260vh; position: relative; }
.v-hero__sticky { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; display: grid; grid-template-rows: auto 1fr; padding-top: 86px; }
.v-title { font-size: clamp(80px, 20.5vw, 400px); line-height: .78; padding: 0 var(--pad); white-space: nowrap; transform: translateX(calc(var(--p, 0) * -38vw)); position: relative; z-index: 2; }
.v-title__row { display: flex; }
.v-title__row span { display: inline-block; transform: translateX(var(--tx, 0)) skewX(var(--sk, 0deg)); opacity: var(--to, 1); transition: transform 1.1s var(--ease-out), opacity .6s; transition-delay: calc(var(--i) * 60ms + 200ms); }
.js .v-title__row span { --tx: 60vw; --sk: -25deg; --to: 0; }
.is-ready .v-title__row span { --tx: 0; --sk: 0deg; --to: 1; }
.v-title__row span:nth-child(6) { color: var(--red); }
.v-car { position: relative; margin: -2vw var(--pad) var(--pad); overflow: hidden; background: #1a1a1a; clip-path: polygon(4% 0, 100% 0, 96% 100%, 0 100%); }
.v-car img { position: absolute; inset: 0 -10%; width: 120%; height: 100%; object-fit: cover; transform: translateX(calc(var(--p, 0) * -8%)) scale(1.05); }
.v-lines { position: absolute; inset: 0; z-index: 1; pointer-events: none; opacity: calc(var(--p, 0) * 1.4); mix-blend-mode: screen;
  background: repeating-linear-gradient(180deg, transparent 0 18px, rgba(255,255,255,.35) 18px 19px, transparent 19px 47px),
              repeating-linear-gradient(180deg, transparent 0 31px, rgba(225,6,0,.5) 31px 32px, transparent 32px 83px);
  background-size: 260px 100%, 420px 100%;
  -webkit-mask: linear-gradient(90deg, #000, transparent 70%); mask: linear-gradient(90deg, #000, transparent 70%);
  animation: streak .35s linear infinite;
}
@keyframes streak { to { background-position: -260px 0, -420px 0; } }
.v-speed { position: absolute; z-index: 3; right: calc(var(--pad) + 8%); bottom: calc(var(--pad) + 26px); color: #fff; text-align: right; font-style: italic; }
.v-speed__num { display: block; font-size: clamp(60px, 9vw, 150px); font-weight: 900; font-stretch: 125%; line-height: .8; font-variant-numeric: tabular-nums; }
.v-speed span { font-weight: 700; font-size: 16px; letter-spacing: .1em; }
.v-speed__bar { width: clamp(160px, 22vw, 340px); height: 6px; margin: 14px 0 0 auto; background: rgba(255,255,255,.2); transform: skewX(-20deg); }
.v-speed__bar i { display: block; height: 100%; background: var(--red); transform-origin: left; transform: scaleX(var(--p, 0)); }
.v-hero__lead { position: absolute; z-index: 3; left: calc(var(--pad) + 5%); bottom: calc(var(--pad) + 30px); max-width: 30ch; color: #fff; font-weight: 500; font-size: clamp(16px, 1.3vw, 20px); }

/* Pasek marek */
.v-strip { background: var(--ink); color: var(--paper); padding: 18px 0; font-weight: 900; font-stretch: 125%; font-style: italic; text-transform: uppercase; font-size: clamp(28px, 4vw, 60px); }
.v-strip span { padding: 0 .4em; }
.v-strip span:nth-child(even) { -webkit-text-stroke: 1.5px var(--paper); color: transparent; }

/* Flota */
.v-fleet { padding: clamp(90px, 10vw, 150px) var(--pad); }
.v-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; flex-wrap: wrap; margin-bottom: 50px; }
.v-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.v-chips button { padding: 10px 18px; border: 1.5px solid var(--ink); font-weight: 700; font-size: 13px; text-transform: uppercase; transition: background .3s, color .3s; }
.v-chips button.is-on, .v-chips button:hover { background: var(--ink); color: var(--paper); }
.v-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; background: var(--line); border: 2px solid var(--line); }
.car { position: relative; background: var(--paper); padding: 22px; display: flex; flex-direction: column; gap: 18px; transition: opacity .4s, transform .6s var(--ease-out); }
.car.is-out { display: none; }
.car.is-enter { animation: carIn .7s var(--ease-out) backwards; animation-delay: calc(var(--i) * 70ms); }
@keyframes carIn { from { opacity: 0; transform: translateY(30px); } }
.car__img { aspect-ratio: 16 / 10; overflow: hidden; background: #ddd; }
.car__img img { width: 100%; height: 100%; object-fit: cover; transition: transform 1s var(--ease-out); }
.car:hover .car__img img { transform: scale(1.07) translateX(-2%); }
.car__top { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.car h3 { font-size: 26px; line-height: .95; }
.car__cat { font-size: 12px; font-weight: 700; text-transform: uppercase; color: var(--red); white-space: nowrap; }
.car__specs { display: grid; gap: 10px; }
.spec { display: grid; grid-template-columns: 92px 1fr 70px; align-items: center; gap: 12px; font-size: 13px; }
.spec span { color: var(--gray); font-weight: 500; }
.spec b { text-align: right; font-weight: 800; font-variant-numeric: tabular-nums; }
.spec i { height: 4px; background: var(--line); position: relative; overflow: hidden; }
.spec i::after { content: ""; position: absolute; inset: 0; background: var(--ink); transform-origin: left; transform: scaleX(0); transition: transform 1.2s var(--ease-out); }
.car.is-in .spec i::after, .car:hover .spec i::after { transform: scaleX(var(--v)); }
.car:hover .spec i::after { background: var(--red); }
.car__foot { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 16px; border-top: 1px solid var(--line); }
.car__price { font-weight: 900; font-stretch: 112%; font-size: 24px; }
.car__price small { font-size: 13px; font-weight: 500; color: var(--gray); }
.car__pick { font-weight: 800; font-size: 13px; text-transform: uppercase; border-bottom: 2px solid var(--red); padding-bottom: 2px; }

/* Kalkulator */
.v-calc { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(30px, 5vw, 80px); padding: clamp(90px, 10vw, 150px) var(--pad); background: var(--ink); color: var(--paper); }
.v-calc h2 { margin-bottom: 50px; }
.v-field { margin-bottom: 36px; border: 0; }
.v-field > label:not(.v-toggle), .v-field legend { display: flex; justify-content: space-between; font-weight: 700; text-transform: uppercase; font-size: 13px; letter-spacing: .04em; margin-bottom: 14px; color: #bbb; width: 100%; }
.v-days-out { font-size: 44px; font-weight: 900; font-stretch: 125%; font-style: italic; color: var(--paper); line-height: 1; font-variant-numeric: tabular-nums; }
.v-select { width: 100%; height: 58px; padding: 0 18px; background: #111; border: 1.5px solid #333; color: var(--paper); font-family: var(--f); font-size: 18px; font-weight: 600; outline: none; }
.v-select:focus { border-color: var(--red); }
.v-range { width: 100%; -webkit-appearance: none; appearance: none; height: 6px; background: linear-gradient(90deg, var(--red) var(--fill, 20%), #333 var(--fill, 20%)); outline: none; transform: skewX(-20deg); }
.v-range::-webkit-slider-thumb { -webkit-appearance: none; width: 28px; height: 28px; background: var(--paper); border: 4px solid var(--red); cursor: grab; transform: skewX(20deg); }
.v-range::-moz-range-thumb { width: 22px; height: 22px; background: var(--paper); border: 4px solid var(--red); border-radius: 0; }
.v-range:focus-visible { outline: 2px solid var(--paper); outline-offset: 6px; }
.v-hint { margin-top: 14px; font-size: 14px; color: #999; }
.v-opts { display: grid; gap: 12px; }
.v-toggle { display: grid; grid-template-columns: 46px 1fr; gap: 4px 14px; align-items: center; padding: 14px 16px; border: 1.5px solid #2a2a2a; font-weight: 500; transition: border-color .3s; position: relative; }
.v-toggle:hover { border-color: #555; }
.v-toggle input { position: absolute; opacity: 0; }
.v-toggle span { grid-row: span 2; width: 46px; height: 26px; background: #333; position: relative; transition: background .3s; }
.v-toggle span::after { content: ""; position: absolute; top: 3px; left: 3px; width: 20px; height: 20px; background: var(--paper); transition: transform .4s var(--ease-out); }
.v-toggle input:checked + span { background: var(--red); }
.v-toggle input:checked + span::after { transform: translateX(20px); }
.v-toggle input:focus-visible + span { outline: 2px solid var(--paper); outline-offset: 3px; }
.v-toggle em { font-style: normal; font-size: 13px; color: #999; }
.v-total { position: sticky; top: 100px; align-self: start; background: var(--paper); color: var(--ink); padding: 26px; }
.v-total__img { aspect-ratio: 16 / 9; overflow: hidden; background: #ddd; margin-bottom: 18px; }
.v-total__img img { width: 100%; height: 100%; object-fit: cover; }
.v-total__img img.swap { animation: slideCar .8s var(--ease-out); }
@keyframes slideCar { from { transform: translateX(40%); opacity: 0; filter: blur(8px); } }
.v-total__car { font-weight: 900; font-stretch: 125%; font-style: italic; font-size: 26px; text-transform: uppercase; line-height: 1; margin-bottom: 16px; }
.v-total__rows { display: grid; gap: 8px; padding: 14px 0; border-block: 1px solid var(--line); font-size: 15px; }
.v-total__rows div { display: flex; justify-content: space-between; }
.v-total__rows dd { font-weight: 700; font-variant-numeric: tabular-nums; }
.v-total__rows .is-disc dd { color: var(--red); }
.v-total__sum { display: flex; align-items: baseline; gap: 8px; margin: 18px 0 6px; }
.v-total__sum span { margin-right: auto; font-weight: 700; text-transform: uppercase; font-size: 14px; }
.v-total__num { font-size: clamp(44px, 4.5vw, 68px); font-weight: 900; font-stretch: 125%; font-style: italic; line-height: 1; font-variant-numeric: tabular-nums; }
.v-total__sum small { font-weight: 700; font-size: 18px; }
.v-total__dep { font-size: 14px; color: var(--gray); margin-bottom: 20px; }

/* Jak to działa */
.v-how { padding: clamp(90px, 10vw, 150px) var(--pad); }
.v-how h2 { margin-bottom: 60px; }
.v-how ol { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; background: var(--line); border: 2px solid var(--line); }
.v-how li { background: var(--paper); padding: 30px 26px 40px; }
.v-how li b { display: block; font-size: 64px; font-weight: 900; font-stretch: 125%; font-style: italic; color: var(--red); line-height: 1; margin-bottom: 30px; }
.v-how h3 { font-size: 24px; margin-bottom: 14px; }
.v-how p { color: #444; }

/* Stopka */
.v-foot { background: var(--red); color: #fff; padding: clamp(80px, 10vw, 140px) var(--pad) 110px; }
.v-foot__big { font-weight: 900; font-stretch: 125%; font-style: italic; text-transform: uppercase; font-size: clamp(56px, 11vw, 200px); line-height: .82; letter-spacing: -.02em; }
.v-foot__row { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-top: 60px; padding-top: 22px; border-top: 2px solid rgba(255,255,255,.4); font-weight: 600; }
.v-foot a { text-decoration: none; }

@media (max-width: 1000px) {
  .v-grid { grid-template-columns: 1fr 1fr; }
  .v-calc { grid-template-columns: 1fr; }
  .v-total { position: relative; top: auto; }
}
@media (max-width: 680px) {
  .v-nav nav { display: none; }
  .v-grid, .v-how ol { grid-template-columns: 1fr; }
  .v-hero__lead { display: none; }
  .v-car { clip-path: none; }
}
