:root {
  --bg: #f5f4f0;
  --card: #ffffff;
  --ink: #0a0a0a;
  --gray: #6e6e73;
  --gray-light: #aeaeb2;
  --etoll-red: #e4002b;
  --phone-frame: #2a2a2c;
  --phone-screen: #f2f2f7;
  --icon-tile: #f8f6f0;
  --border: rgba(0, 0, 0, 0.08);

  --display: "Inter", -apple-system, "system-ui", "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif;
  --body: "Inter", -apple-system, "system-ui", "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.container {
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
  padding-left: 64px;
  padding-right: 64px;
}

/* ---------- Nav ---------- */
.nav {
  padding-top: 56px;
  padding-bottom: 24px;
}
.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.wordmark {
  font-size: 18px;
  letter-spacing: 0.3px;
  line-height: 1;
  white-space: nowrap;
}
/* „e-TOLL” nigdy nie łamie się na granicy łącznika. */
.etoll-lock {
  white-space: nowrap;
}
.wm-e {
  font-weight: 700;
  color: var(--etoll-red);
}
.wm-toll {
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--ink);
}
.wm-suffix {
  font-weight: 600;
  color: var(--ink);
  margin-left: 6px;
}
.wm-dot {
  font-weight: 800;
  color: var(--etoll-red);
}

/* ---------- Hero ---------- */
.hero-grid {
  display: grid;
  grid-template-columns: 458px 1fr;
  align-items: center;
  gap: 56px;
  min-height: 680px;
}
.hero-phone {
  display: flex;
  justify-content: center;
}
.hero-copy {
  display: flex;
  flex-direction: column;
}
.hero-title {
  font-family: var(--display);
  font-size: 36px;
  line-height: 42px;
  font-weight: 700;
  letter-spacing: -0.8px;
  color: var(--ink);
  margin: 0;
}
.hero-sub {
  font-size: 16px;
  line-height: 25px;
  color: var(--gray);
  margin: 18px 0 0;
}
.hero-cta {
  margin-top: 28px;
}
.hero-caption {
  font-size: 12px;
  color: var(--gray-light);
  margin: 14px 0 0;
  width: 360px;
  max-width: 100%;
}
.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 24px;
}
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 500;
  color: var(--gray);
  background: rgba(255, 255, 255, 0.85);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 5px 11px;
}
.badge-icon,
.chip-icon {
  flex-shrink: 0;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.badge-icon {
  width: 14px;
  height: 14px;
}

/* ---------- Start button ---------- */
.start-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 54px;
  width: 360px;
  max-width: 100%;
  border-radius: 100px;
  background: var(--ink);
  border: none;
  box-shadow: 0 6px 22px rgba(10, 10, 10, 0.14);
  cursor: pointer;
  text-decoration: none;
  transition: transform 0.15s ease;
}
.start-btn:hover {
  transform: scale(1.02);
}
.start-btn:active {
  transform: scale(0.99);
}
.start-label {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.1px;
  color: #fff;
}

/* ---------- Dlaczego ---------- */
.why {
  padding-top: 130px;
}
.section-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--gray-light);
  padding-left: 2px;
}
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 16px;
  margin-top: 24px;
}
.feature-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  background: var(--card);
  border-radius: 20px;
  border: 1px solid rgba(24, 28, 34, 0.05);
  box-shadow: 0 2px 16px rgba(24, 28, 34, 0.05);
  padding: 24px;
}
.feature-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--icon-tile);
  color: var(--etoll-red);
}
.feature-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.feature-text {
  display: flex;
  flex-direction: column;
}
.feature-title {
  font-family: var(--display);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: -0.1px;
  color: var(--ink);
}
.feature-desc {
  font-size: 13px;
  line-height: 20px;
  color: var(--gray);
  margin-top: 6px;
}

/* ---------- Autorska mapa: layery dróg i bramownic ---------- */
.map-layers {
  padding-top: 110px;
}
.map-layers-head {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}
.map-layers-head .section-label {
  display: block;
}
.map-layers-head .block-title {
  margin-top: 10px;
}
.layer-rows {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 56px;
}
.layer-link {
  position: relative;
  height: 118px;
  margin: -6px 0;
  pointer-events: none;
}
.layer-link svg {
  display: block;
  width: 100%;
  height: 100%;
  overflow: visible;
}
.road-asphalt {
  fill: none;
  stroke: rgba(10, 10, 10, 0.06);
  stroke-width: 16;
  stroke-linecap: round;
}
.road-line {
  fill: none;
  stroke: var(--etoll-red);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-dasharray: 13 19;
  opacity: 0.5;
  animation: road-flow 1.5s linear infinite;
}
@keyframes road-flow {
  to {
    stroke-dashoffset: -32;
  }
}
/* gps-track istnieje tylko w widoku mobilnym */
.gps-track {
  display: none;
}
@media (prefers-reduced-motion: reduce) {
  .road-line {
    animation: none;
  }
}
.layer-row {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 56px;
  align-items: center;
}
.layer-row--reverse .layer-shot {
  order: 2;
}
.layer-shot {
  display: flex;
  justify-content: center;
}
.layer-shot img {
  display: block;
  width: 100%;
  max-width: 300px;
  border-radius: 28px;
  border: 1px solid var(--border);
  box-shadow: -48px 48px 100px rgba(24, 28, 34, 0.32), -18px 18px 38px rgba(24, 28, 34, 0.18);
}
.layer-row--reverse .layer-shot img {
  box-shadow: 48px 48px 100px rgba(24, 28, 34, 0.32), 18px 18px 38px rgba(24, 28, 34, 0.18);
}
.layer-title {
  font-family: var(--display);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.3px;
  color: var(--ink);
  margin: 0;
}
.layer-desc {
  font-size: 15px;
  line-height: 24px;
  color: var(--gray);
  margin: 14px 0 0;
  max-width: 420px;
}

/* ---------- Tytuły bloków (OBU / cennik) ---------- */
.block-title {
  font-family: var(--display);
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.6px;
  line-height: 1.15;
  color: var(--ink);
  margin: 14px 0 0;
}
.block-lead {
  font-size: 15px;
  line-height: 24px;
  color: var(--gray);
  margin: 14px 0 0;
  max-width: 640px;
}

/* ---------- Banner CTA: w trasie ---------- */
.showcase {
  padding-top: 124px;
  padding-bottom: 88px;
}
.showcase-card {
  position: relative;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.16);
}
.showcase-img {
  display: block;
  width: 100%;
  height: clamp(300px, 42vw, 460px);
  object-fit: cover;
}
.showcase-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  padding: clamp(28px, 5vw, 60px);
  background: linear-gradient(
    90deg,
    rgba(8, 8, 8, 0.68) 0%,
    rgba(8, 8, 8, 0.42) 42%,
    rgba(8, 8, 8, 0) 72%
  );
}
.showcase-title {
  font-family: var(--display);
  font-size: clamp(26px, 4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.6px;
  line-height: 1.05;
  color: #fff;
  margin: 0;
}
.showcase-sub {
  font-size: clamp(14px, 1.6vw, 17px);
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.88);
  margin: 14px 0 0;
  max-width: 420px;
}
.showcase-overlay .start-btn {
  margin-top: 26px;
}
.showcase-micro {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.72);
  margin: 14px 0 0;
}

/* ---------- Nasza przewaga ---------- */
.edge {
  padding-top: 130px;
}
.edge-panel {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 44px;
  align-items: center;
  background: var(--icon-tile);
  border: 1px solid var(--border);
  border-radius: 28px;
  padding: 48px;
}
.edge-media {
  margin: 0;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.14);
}
.edge-media img {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 440px;
  object-fit: cover;
}
.edge-points {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-top: 30px;
}
.edge-point {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}
.edge-point .feature-icon {
  background: var(--card);
}

/* ---------- Urządzenia OBU ---------- */
.obu {
  padding-top: 130px;
}
.obu-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 22px;
}
.obu-badges .badge {
  font-size: 12px;
  padding: 6px 13px;
}
.devices-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 16px;
  margin-top: 32px;
}
.device-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: var(--card);
  border-radius: 20px;
  border: 1px solid rgba(24, 28, 34, 0.05);
  box-shadow: 0 2px 16px rgba(24, 28, 34, 0.05);
  padding: 22px 20px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.device-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.09);
}
.device-photo {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 116px;
}
.device-photo img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.device-class {
  font-size: 11px;
  color: var(--gray-light);
  margin-top: 14px;
}
.device-name {
  font-family: var(--display);
  font-size: 17px;
  font-weight: 600;
  color: var(--ink);
  margin-top: 5px;
}
.device-price {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  background: var(--icon-tile);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 7px 16px;
  margin-top: 13px;
}

/* ---------- Cennik ---------- */
.pricing {
  padding-top: 124px;
}
.price-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}
.price-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(228, 0, 43, 0.18);
  border-radius: 12px;
  box-shadow: 0 2px 12px rgba(24, 28, 34, 0.04);
  padding: 8px 14px 8px 10px;
}
.chip-icon {
  width: 18px;
  height: 18px;
  padding: 4px;
  color: #fff;
  background: var(--etoll-red);
  border-radius: 999px;
  stroke-width: 3.2;
}
.plans {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  margin-top: 32px;
}
.plan {
  position: relative;
  background: var(--card);
  border-radius: 24px;
  border: 1px solid var(--border);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.04);
  padding: 30px;
}
.plan-accent {
  border-color: rgba(228, 0, 43, 0.35);
  box-shadow: 0 12px 32px rgba(228, 0, 43, 0.08);
}
.plan-badge {
  position: absolute;
  top: 26px;
  right: 26px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: #fff;
  background: var(--etoll-red);
  border-radius: 100px;
  padding: 5px 12px;
}
.plan-tag {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--gray-light);
}
.plan-total {
  display: block;
  font-family: var(--display);
  font-size: 46px;
  font-weight: 700;
  letter-spacing: -1px;
  line-height: 1;
  color: var(--ink);
  margin-top: 12px;
}
.plan-total small {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0;
  color: var(--gray);
  margin-left: 8px;
}
.plan-then {
  display: block;
  font-size: 13px;
  color: var(--gray);
  margin-top: 10px;
}
.plan-rows {
  list-style: none;
  margin: 22px 0 0;
  padding: 0;
}
.plan-rows li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 16px;
  padding: 13px 0;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  font-size: 14px;
}
.plan-rows li span {
  color: var(--gray);
}
.plan-rows li b {
  color: var(--ink);
  white-space: nowrap;
}
.pricing-note {
  font-size: 12px;
  color: var(--gray-light);
  margin: 18px 0 0;
}

/* ---------- Kontakt (ciemny panel) ---------- */
.contact {
  padding-top: 124px;
}
.contact-panel {
  background: var(--ink);
  border-radius: 28px;
  padding: 56px 48px;
  text-align: center;
}
.section-label--light {
  color: rgba(255, 255, 255, 0.55);
}
.contact-title {
  font-family: var(--display);
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.6px;
  line-height: 1.15;
  color: #fff;
  margin: 14px 0 0;
}
.contact-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 28px;
}
.start-btn--accent {
  width: auto;
  padding: 0 30px;
  background: var(--etoll-red);
  box-shadow: 0 8px 24px rgba(228, 0, 43, 0.3);
}
.start-btn--wa {
  width: auto;
  padding: 0 30px;
  background: #25d366;
  box-shadow: 0 8px 24px rgba(37, 211, 102, 0.3);
}

@media (max-width: 760px) {
  .plans {
    grid-template-columns: 1fr;
  }
  /* mobile: dwupasmowa droga z markerem GPS sterowanym przewijaniem */
  .layer-rows {
    position: relative;
    padding-left: 42px;
    gap: 16px;
  }
  .gps-track {
    display: block;
    position: absolute;
    left: 7px;
    top: 10px;
    bottom: 10px;
    width: 16px;
    /* dwa pasy = krawędzie jezdni */
    background-image: linear-gradient(
        rgba(10, 10, 10, 0.16),
        rgba(10, 10, 10, 0.16)
      ),
      linear-gradient(rgba(10, 10, 10, 0.16), rgba(10, 10, 10, 0.16));
    background-size: 2px 100%, 2px 100%;
    background-position: left center, right center;
    background-repeat: no-repeat;
  }
  .gps-track::before {
    /* oś jezdni — cała trasa, przerywana, przygaszona */
    content: "";
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    transform: translateX(-50%);
    background: repeating-linear-gradient(
      to bottom,
      rgba(10, 10, 10, 0.45) 0 8px,
      transparent 8px 20px
    );
  }
  .gps-marker {
    /* standardowy pin mapy — czubek wskazuje pozycję na trasie */
    position: absolute;
    left: 50%;
    top: 0;
    width: 24px;
    height: 32px;
    transform: translate(-50%, -100%);
    z-index: 2;
  }
  .gps-marker svg {
    display: block;
    width: 100%;
    height: 100%;
    filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.35));
  }
  .gps-marker svg path {
    fill: var(--pin, var(--etoll-red));
    transition: fill 0.35s ease;
  }
  .gps-marker svg circle {
    fill: #fff;
  }
  .layer-row {
    grid-template-columns: 1fr;
    gap: 16px;
    text-align: left;
  }
  .layer-row--reverse .layer-shot {
    order: 0;
  }
  .layer-shot {
    justify-content: flex-start;
  }
  .layer-desc {
    margin-left: 0;
    margin-right: 0;
  }
  .layer-link {
    display: none;
  }
  .footer-break {
    display: block;
  }
  .contact-panel {
    padding: 40px 24px;
  }
  .edge-panel {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 32px 24px;
  }
  .edge-media {
    order: -1;
  }
  .edge-points {
    gap: 18px;
  }
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
}
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: center;
}
.footer-copy {
  font-size: 12.5px;
  color: var(--gray-light);
  margin: 0;
  text-align: center;
}
.footer-name {
  font-weight: 700;
  color: var(--gray);
}
.footer-break {
  display: none;
}

/* ---------- Phone mockup ---------- */
.phone-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.glow {
  position: absolute;
  border-radius: 999px;
}
.glow-1 {
  width: 340px;
  height: 420px;
  background: rgba(251, 183, 60, 0.07);
}
.glow-2 {
  width: 210px;
  height: 270px;
  background: rgba(251, 183, 60, 0.11);
}
.phone-frame {
  position: relative;
  width: 260px;
  height: 562px;
  border-radius: 52px;
  background: var(--phone-frame);
  padding: 10px;
  box-shadow: 0 30px 50px rgba(0, 0, 0, 0.35);
  animation: phone-float 5s ease-in-out infinite;
}

@keyframes phone-float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-12px);
  }
}
@keyframes floor-pulse {
  0%,
  100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(0.9);
    opacity: 0.7;
  }
}
.phone-screen {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  width: 240px;
  height: 542px;
  border-radius: 44px;
  background: var(--phone-screen);
}
.shots {
  position: relative;
  width: 100%;
  height: 100%;
}
.phone-shot {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  opacity: 0;
  z-index: 0;
  transition: opacity 0.6s ease;
  /* Stała warstwa GPU rasteryzowana w pełnej jakości — bez przejściowego
     rozmycia przy animacji opacity dużego, skalowanego obrazu. */
  will-change: opacity;
  transform: translateZ(0);
  backface-visibility: hidden;
}
/* Poprzedni kadr zostaje w pełni widoczny pod spodem, dopóki nowy go nie
   przykryje — dzięki temu w trakcie przejścia nie prześwituje tło. */
.phone-shot.is-prev {
  opacity: 1;
  z-index: 1;
}
.phone-shot.is-active {
  opacity: 1;
  z-index: 2;
}
.notch {
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 30px;
  border-radius: 20px;
  background: var(--ink);
  z-index: 2;
}
.home-indicator {
  position: absolute;
  bottom: 8px;
  left: 50%;
  transform: translateX(-50%);
  width: 110px;
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  z-index: 2;
}
.floor-shadow {
  position: absolute;
  bottom: -34px;
  width: 182px;
  height: 20px;
  border-radius: 260px;
  background: rgba(0, 0, 0, 0.15);
  filter: blur(6px);
  animation: floor-pulse 5s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  .phone-frame,
  .floor-shadow {
    animation: none;
  }
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .container {
    padding-left: 28px;
    padding-right: 28px;
  }
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 48px;
    justify-items: center;
    text-align: center;
    min-height: auto;
  }
  .hero-phone {
    order: -1;
  }
  .hero-copy {
    align-items: center;
    max-width: 458px;
  }
  .hero-title,
  .hero-sub {
    text-align: center;
  }
  .hero-cta {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .hero-caption {
    text-align: center;
  }
  .hero-badges {
    justify-content: center;
  }
  .features {
    grid-template-columns: 1fr;
  }
}
