/* ============ Fonts ============ */
@font-face {
  font-family: "Manrope";
  src: url("../fonts/manrope-latin.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
  unicode-range: U+0000-00FF, U+2013-2014, U+2019, U+201C-201E, U+2026;
}
@font-face {
  font-family: "Manrope";
  src: url("../fonts/manrope-latin-ext.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
  unicode-range: U+0100-024F, U+0104-0107, U+0118-0119, U+0141-0144, U+015A-015B, U+0179-017C;
}

/* ============ Design tokens ============ */
:root {
  --bg: #080c18;
  --bg-raised: #0a0f1f;
  --surface: #0e1425;
  --surface-border: rgba(120, 160, 255, 0.12);
  --accent: #2c6bff;
  --accent-soft: #3b82f6;
  --accent-light: #5b9bff;
  --accent-glow: #8fc2ff;
  --text-heading: #f2f6ff;
  --text-body: #a8b4cc;
  --text-caption: #8391ae; /* >=4.5:1 on card surface #0E1425 (original #6C7A94 was ~4.2:1) */
  --radius-card: 14px;
  --radius-btn: 9px;
  --radius-pill: 999px;
  --nav-h: 72px;
  --container: 1200px;
  --section-pad: clamp(64px, 8vw, 120px);
  --shadow-glow: 0 10px 30px -14px rgba(3, 8, 24, 0.8);
  --shadow-card: 0 24px 60px -24px rgba(3, 8, 24, 0.9);
  --transition: 0.25s ease;
}

/* ============ Base ============ */
*,
*::before,
*::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
}

body {
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-body);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; height: auto; }

a { color: inherit; text-decoration: none; }

ul { list-style: none; }

h1, h2, h3 {
  color: var(--text-heading);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.sprite { display: none; }

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(16px, 4vw, 32px);
}

:focus-visible {
  outline: 2px solid var(--accent-light);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection { background: rgba(44, 107, 255, 0.4); color: var(--text-heading); }

/* ============ Buttons ============ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 12px 22px;
  border-radius: var(--radius-btn);
  font-weight: 600;
  font-size: 0.92rem;
  line-height: 1.2;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background var(--transition), border-color var(--transition),
    color var(--transition);
}
.btn svg { transition: translate var(--transition); }
.btn:hover svg { translate: 3px 0; }

.btn--primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 8px 22px -12px rgba(3, 8, 24, 0.9);
}
.btn--primary:hover { background: var(--accent-soft); }

.btn--outline {
  border-color: rgba(120, 160, 255, 0.3);
  color: var(--text-heading);
  background: transparent;
}
.btn--outline:hover {
  border-color: var(--accent-light);
  color: #fff;
}

.btn--ghost {
  border-color: rgba(120, 160, 255, 0.2);
  color: var(--text-body);
  background: transparent;
}
.btn--ghost:hover {
  border-color: rgba(120, 160, 255, 0.45);
  color: var(--text-heading);
}

/* ============ Header / nav ============ */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  transition: background var(--transition), border-color var(--transition),
    box-shadow var(--transition);
  border-bottom: 1px solid transparent;
}

.site-header.is-scrolled {
  background: rgba(8, 12, 24, 0.86);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  border-bottom-color: var(--surface-border);
  box-shadow: 0 12px 40px -20px rgba(3, 8, 24, 0.9);
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
  height: var(--nav-h);
}

.nav__logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
}
.nav__logo-icon { color: var(--accent-light); }
.nav__logo-text {
  font-weight: 800;
  font-size: 1.25rem;
  letter-spacing: 0.02em;
  color: var(--text-heading);
}
.nav__logo-text span { color: var(--accent-light); }

.nav__links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav__link {
  display: inline-block;
  padding: 8px 14px;
  border-radius: var(--radius-btn);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-body);
  transition: color var(--transition), background var(--transition);
}
.nav__link:hover { color: var(--text-heading); background: rgba(44, 107, 255, 0.1); }
.nav__link.is-active { color: var(--text-heading); }
.nav__link.is-active::after {
  content: "";
  display: block;
  margin: 2px auto 0;
  width: 16px;
  height: 2px;
  border-radius: 2px;
  background: var(--accent-light);
}

.nav__cta { padding: 10px 18px; font-size: 0.9rem; white-space: nowrap; }

.nav__toggle {
  display: none;
  background: none;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-btn);
  color: var(--text-heading);
  padding: 8px;
  cursor: pointer;
}

/* Mobile fullscreen menu */
.mobile-menu {
  position: fixed;
  inset: var(--nav-h) 0 0 0;
  background: rgba(8, 12, 24, 0.98);
  -webkit-backdrop-filter: blur(20px);
  backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 40px;
  z-index: 99;
}
.mobile-menu[hidden] { display: none; }

.mobile-menu__links { text-align: center; display: grid; gap: 8px; }
.mobile-menu__link {
  display: inline-block;
  padding: 12px 24px;
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-heading);
}
.mobile-menu__link:hover { color: var(--accent-light); }

/* ============ Sections shared ============ */
.section { padding-block: var(--section-pad); }

/* ============ Hero ============ */
.hero {
  position: relative;
  padding-top: calc(var(--nav-h) + clamp(48px, 7vw, 96px));
  padding-bottom: clamp(64px, 8vw, 120px);
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 55% 45% at 78% 20%, rgba(44, 107, 255, 0.1), transparent 65%),
    radial-gradient(ellipse 40% 35% at 12% 65%, rgba(44, 107, 255, 0.05), transparent 70%),
    linear-gradient(180deg, var(--bg-raised) 0%, var(--bg) 100%);
}
.hero__bg::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(91, 155, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(91, 155, 255, 0.035) 1px, transparent 1px);
  background-size: 72px 72px;
  -webkit-mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.9) 0%, transparent 78%);
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.9) 0%, transparent 78%);
}
.hero__bg::after {
  content: "";
  position: absolute;
  top: -12%;
  right: -6%;
  width: 60%;
  height: 70%;
  background:
    linear-gradient(115deg, transparent 46%, rgba(91, 155, 255, 0.5) 49.5%, rgba(143, 194, 255, 0.75) 50%, rgba(91, 155, 255, 0.5) 50.5%, transparent 54%),
    linear-gradient(115deg, transparent 62%, rgba(91, 155, 255, 0.3) 65.5%, rgba(91, 155, 255, 0.45) 66%, rgba(91, 155, 255, 0.3) 66.5%, transparent 70%);
  filter: blur(2px);
  opacity: 0.22;
  -webkit-mask-image: linear-gradient(180deg, black 40%, transparent 95%);
  mask-image: linear-gradient(180deg, black 40%, transparent 95%);
}

.hero__grid {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: start;
}
.hero__grid > * { min-width: 0; }

.hero__title {
  font-size: clamp(2.5rem, 5vw, 4rem);
  margin-bottom: 20px;
}

.hero__lead {
  font-size: clamp(1rem, 1.4vw, 1.125rem);
  max-width: 44ch;
  margin-bottom: 32px;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 28px;
}

.hero__pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.85rem;
  color: var(--text-caption);
}
.hero__pill svg { flex-shrink: 0; color: var(--accent-light); opacity: 0.8; }

/* Presentation window (glass) */
.hero__visual { position: relative; }

.pres-window {
  position: relative;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  background: rgba(14, 20, 37, 0.62);
  -webkit-backdrop-filter: blur(18px);
  backdrop-filter: blur(18px);
  box-shadow: var(--shadow-card);
  overflow: hidden;
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .pres-window { background: var(--surface); }
}

.pres-window__header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--surface-border);
}
.pres-window__header svg { color: var(--accent-light); flex-shrink: 0; }
.pres-window__title {
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--text-heading);
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.pres-window__title span { color: var(--text-caption); margin-inline: 2px; }

.pres-window__body {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
}

.pres-window__rail {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 8px;
  border-right: 1px solid var(--surface-border);
}

.rail-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 9px 4px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: none;
  color: var(--text-caption);
  font-family: inherit;
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  line-height: 1.25;
  text-align: center;
  cursor: pointer;
  transition: color var(--transition), background var(--transition), border-color var(--transition);
}
.rail-tab:hover { color: var(--text-heading); background: rgba(44, 107, 255, 0.1); }
.rail-tab[aria-selected="true"] {
  color: var(--text-heading);
  background: rgba(44, 107, 255, 0.14);
  border-color: rgba(120, 160, 255, 0.3);
}
.rail-tab[aria-selected="true"] svg { color: var(--accent-light); }

.pres-window__stage {
  position: relative;
  min-height: 340px;
}

.pres-panel {
  position: absolute;
  inset: 0;
  opacity: 1;
  transition: opacity 0.3s ease;
}
.pres-panel[hidden] { display: none; }
.pres-panel.is-fading { opacity: 0; }
.pres-panel img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.pres-panel--light { background: #fff; }
.pres-panel img.contain { object-fit: contain; padding: 10px; }

.pres-panel__play {
  position: absolute;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  border-radius: 50%;
  color: #fff;
  background: rgba(44, 107, 255, 0.9);
  box-shadow: 0 10px 30px -10px rgba(3, 8, 24, 0.8);
}
.pres-panel__play svg { margin-left: 4px; }

.pres-panel__badge {
  position: absolute;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 20px;
  border-radius: var(--radius-pill);
  background: rgba(8, 12, 24, 0.75);
  border: 1px solid rgba(120, 160, 255, 0.4);
  color: var(--text-heading);
  font-weight: 700;
  letter-spacing: 0.04em;
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.pres-panel__badge svg { color: var(--accent-light); }

/* Draggable 360-style panorama panel */
.pres-panel--pano {
  overflow: hidden;
  cursor: grab;
  touch-action: pan-y;
}
.pres-panel--pano.is-dragging { cursor: grabbing; }
.pres-panel--pano img {
  position: absolute;
  inset: 0;
  width: 175%;
  max-width: none;
  height: 100%;
  object-fit: cover;
  will-change: translate;
}
.pres-panel--pano.is-auto img {
  animation: pano-sweep 26s ease-in-out infinite;
}
@keyframes pano-sweep {
  0%, 100% { translate: 0 0; }
  50% { translate: -42.8% 0; }
}
.pres-panel--pano .pres-panel__badge {
  top: 14px;
  left: auto;
  right: 14px;
  translate: 0 0;
  padding: 7px 14px;
  font-size: 0.8rem;
}
.pres-panel__open {
  position: absolute;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 22px;
  border-radius: var(--radius-pill);
  background: rgba(44, 107, 255, 0.9);
  border: 1px solid rgba(143, 194, 255, 0.4);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 10px 30px -10px rgba(3, 8, 24, 0.8);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  transition: background var(--transition);
}
.pres-panel__open:hover { background: var(--accent-soft); }

.pano__hint {
  position: absolute;
  bottom: 14px;
  left: 50%;
  translate: -50% 0;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border-radius: var(--radius-pill);
  background: rgba(8, 12, 24, 0.75);
  border: 1px solid rgba(120, 160, 255, 0.4);
  color: var(--text-heading);
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
  pointer-events: none;
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  transition: opacity 0.4s ease;
}
.pano__hint svg { color: var(--accent-light); }
.pano__hint.is-hidden { opacity: 0; }
/* in the hero window the overlap cards cover the bottom edge — lift the hint */
.pres-window .pano__hint { bottom: 72px; }

/* Branded invite banner (replaces the fake "map" placeholder in the Lokalizacja tab) */
.pres-panel--invite { background: var(--surface); }
.pres-panel--invite a {
  display: block;
  width: 100%;
  height: 100%;
}
.pres-panel--invite img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: scale 0.4s ease;
}
.pres-panel--invite a:hover img { scale: 1.02; }

.pres-panel--placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 24px;
  text-align: center;
  background:
    radial-gradient(ellipse 70% 60% at 50% 30%, rgba(44, 107, 255, 0.14), transparent 70%),
    var(--surface);
}
.pres-panel--placeholder svg { color: var(--accent-light); }
.pres-panel--placeholder p { font-weight: 700; color: var(--text-heading); }
.pres-panel--placeholder span { font-size: 0.85rem; color: var(--text-caption); max-width: 40ch; }

/* Overlapping cards under the window */
.hero__overlap {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(0, 0.95fr) auto;
  gap: 18px;
  align-items: end;
  margin-top: -48px;
  padding-inline: 12px;
}
.hero__overlap > * { min-width: 0; }

.hero__plan3d,
.hero__plan2d {
  border-radius: var(--radius-card);
  overflow: hidden;
  border: 1px solid var(--surface-border);
  box-shadow: var(--shadow-card);
}
.hero__plan3d { aspect-ratio: 16 / 9; }
.hero__plan3d img { width: 100%; height: 100%; object-fit: cover; }
.hero__plan2d { background: #fff; }
.hero__plan2d img { width: 100%; height: 160px; object-fit: contain; padding: 8px; }

.hero__qr {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: 132px;
}
.hero__qr img {
  width: 108px;
  height: auto;
  border-radius: 10px;
  background: #fff;
  padding: 6px;
  border: 1px solid var(--surface-border);
  box-shadow: var(--shadow-glow);
}
.hero__qr figcaption {
  font-size: 0.72rem;
  color: var(--text-caption);
  text-align: center;
  line-height: 1.4;
}

/* ============ Section shell: heading column left, content right ============ */
main > .section { border-top: 1px solid rgba(120, 160, 255, 0.08); }

.section__split {
  display: grid;
  grid-template-columns: 250px minmax(0, 1fr);
  gap: clamp(32px, 4.5vw, 72px);
  align-items: start;
}
.section__title {
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--text-heading);
}
.section__desc {
  margin-top: 14px;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--text-body);
}

/* ============ Offer: 7 icon cards ============ */
.offer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 10px;
}
.offer-card {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 56px;
  padding: 12px 18px;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  transition: border-color var(--transition), background var(--transition);
}
.offer-card:hover {
  border-color: rgba(120, 160, 255, 0.35);
  background: rgba(44, 107, 255, 0.05);
}
.offer-card__icon {
  display: grid;
  place-items: center;
  flex-shrink: 0;
  color: var(--accent-light);
}
.offer-card__label {
  font-size: 0.85rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--text-body);
}

/* ============ Steps: 4 circles joined by arrows ============ */
.steps {
  display: grid;
  grid-template-columns: 1fr auto 1fr auto 1fr auto 1fr;
  gap: 10px;
  align-items: start;
}
.step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}
.step__icon {
  display: grid;
  place-items: center;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  color: var(--accent-light);
  border: 1px solid rgba(120, 160, 255, 0.3);
}
.step__title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-heading);
}
.step__desc {
  font-size: 0.8rem;
  line-height: 1.55;
  color: var(--text-caption);
  max-width: 24ch;
}
.steps__arrow {
  color: var(--accent-light);
  padding-top: 18px;
  opacity: 0.45;
}

/* ============ Demo: example presentation with horizontal tabs ============ */
.demo {
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  padding: 18px;
  box-shadow: var(--shadow-card);
}
.demo__tabbar {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.demo-tab {
  padding: 9px 16px;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  background: none;
  color: var(--text-caption);
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: color var(--transition), background var(--transition), border-color var(--transition);
}
.demo-tab:hover { color: var(--text-heading); background: rgba(44, 107, 255, 0.1); }
.demo-tab[aria-selected="true"] {
  color: var(--text-heading);
  background: rgba(44, 107, 255, 0.14);
  border-color: rgba(120, 160, 255, 0.3);
}
.demo__stage {
  position: relative;
  margin-top: 16px;
  aspect-ratio: 16 / 9;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--surface-border);
}
.demo__meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 16px;
}
.demo__name {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-heading);
}
.demo__location {
  margin-top: 2px;
  font-size: 0.85rem;
  color: var(--text-caption);
}
.demo__stats {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.demo__stats li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--surface-border);
  background: rgba(44, 107, 255, 0.07);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-body);
}
.demo__stats svg { color: var(--accent-light); }

/* ============ Client properties ============ */
.client-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.client-card {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  overflow: hidden;
  transition: border-color var(--transition);
}
.client-card:hover { border-color: rgba(120, 160, 255, 0.35); }
.client-card__media {
  position: relative;
  display: block;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}
.client-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: scale 0.4s ease;
}
.client-card:hover .client-card__media img { scale: 1.04; }
.client-card__media--light { background: #fff; }
.client-card__media--light img { object-fit: contain; padding: 10px; }
.client-card__badge {
  position: absolute;
  top: 10px;
  left: 10px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  background: rgba(8, 12, 24, 0.72);
  border: 1px solid rgba(120, 160, 255, 0.3);
  color: var(--text-heading);
  font-size: 0.7rem;
  font-weight: 600;
  pointer-events: none;
}
.client-card__badge svg { color: var(--accent-light); }
.client-card__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 16px 18px 18px;
}
.client-card__title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-heading);
  /* belt-and-suspenders: neutralize iOS Safari's automatic address detection
     (format-detection meta tag in <head> is the primary fix) */
  -webkit-text-decoration: none;
  text-decoration: none;
}
.client-card__title a { color: inherit; text-decoration: inherit; pointer-events: none; }
.client-card__meta {
  margin-top: 4px;
  margin-bottom: 16px;
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--text-caption);
}
.client-card__cta {
  margin-top: auto;
  align-self: flex-start;
  padding: 8px 14px;
  font-size: 0.85rem;
}

/* ============ Before / after sliders ============ */
.ba-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.ba {
  --pos: 50%;
  position: relative;
  aspect-ratio: 16 / 11;
  border-radius: var(--radius-card);
  overflow: hidden;
  border: 1px solid var(--surface-border);
  box-shadow: var(--shadow-card);
  cursor: ew-resize;
  touch-action: pan-y;
}
.ba__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.ba__img--after { clip-path: inset(0 0 0 var(--pos)); }
.ba__label {
  position: absolute;
  top: 12px;
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  background: rgba(8, 12, 24, 0.72);
  border: 1px solid rgba(120, 160, 255, 0.3);
  color: var(--text-heading);
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  pointer-events: none;
}
.ba__label--before { left: 12px; }
.ba__label--after { right: 12px; }
.ba__handle {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--pos);
  translate: -50% 0;
  width: 36px;
  display: grid;
  place-items: center;
  cursor: ew-resize;
}
.ba__handle::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  translate: -50% 0;
  width: 2px;
  background: rgba(242, 246, 255, 0.9);
}
.ba__grip {
  position: relative;
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  color: #fff;
  background: var(--accent);
  border: 2px solid rgba(242, 246, 255, 0.85);
  box-shadow: 0 4px 18px -4px rgba(3, 8, 24, 0.8);
}

/* ============ Why VIZUS3D: 4 cards ============ */
.why-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.why-card {
  padding: 24px 20px;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  transition: border-color var(--transition), background var(--transition);
}
.why-card:hover {
  border-color: rgba(120, 160, 255, 0.35);
  background: rgba(44, 107, 255, 0.05);
}
.why-card__icon {
  display: grid;
  place-items: center;
  width: 24px;
  height: 24px;
  color: var(--accent-light);
}
.why-card__title {
  margin-top: 18px;
  font-size: 0.98rem;
  font-weight: 700;
  color: var(--text-heading);
}
.why-card__desc {
  margin-top: 8px;
  font-size: 0.84rem;
  line-height: 1.6;
  color: var(--text-caption);
}

/* ============ Pricing ============ */
.price-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  align-items: stretch;
}
.price-card {
  display: flex;
  flex-direction: column;
  padding: 26px 24px;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 16px;
  transition: border-color var(--transition), box-shadow var(--transition);
}
.price-card--featured {
  border-color: rgba(120, 160, 255, 0.45);
  background: linear-gradient(180deg, rgba(44, 107, 255, 0.07), rgba(14, 20, 37, 0.4)), var(--surface);
  box-shadow: var(--shadow-card);
}
.price-card__num { color: var(--accent-light); margin-right: 8px; }
.price-card__title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-heading);
}
.price-card__price {
  margin-top: 10px;
  font-size: 0.95rem;
  color: var(--text-caption);
}
.price-card__price strong {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-heading);
  margin-left: 6px;
}
.price-card__head { padding-bottom: 18px; border-bottom: 1px solid var(--surface-border); }
.price-card__list { display: grid; gap: 10px; padding-top: 18px; margin-bottom: 20px; }
.price-card__list li {
  display: flex;
  align-items: baseline;
  gap: 10px;
  font-size: 0.88rem;
  color: var(--text-body);
}
.price-card__list svg { flex-shrink: 0; color: var(--accent-light); translate: 0 2px; }
.price-card__cta { margin-top: auto; align-self: start; }

/* ============ CTA strip / contact ============ */
.cta-strip {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1.25fr) auto;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-card);
}
.cta-strip__media { position: relative; min-height: 240px; }
.cta-strip__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.cta-strip__content {
  padding: clamp(28px, 4vw, 44px);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 16px;
}
.cta-strip__title {
  font-size: clamp(1.4rem, 2.4vw, 1.9rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
  color: var(--text-heading);
}
.cta-strip__desc {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--text-body);
}
.cta-strip__contacts {
  display: grid;
  gap: 20px;
  align-content: center;
  padding: clamp(28px, 4vw, 44px);
  border-left: 1px solid var(--surface-border);
}
.cta-strip__contacts a {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-heading);
  white-space: nowrap;
  transition: color var(--transition);
}
.cta-strip__contacts a:hover { color: var(--accent-light); }
.contact-icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  color: var(--accent-light);
  border: 1px solid rgba(120, 160, 255, 0.25);
}

/* ============ FAQ ============ */
.faq-list { display: grid; gap: 12px; }
.faq-item {
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  padding-inline: 20px;
  transition: border-color var(--transition), background var(--transition);
}
.faq-item:hover { border-color: rgba(120, 160, 255, 0.35); }
.faq-item[open] { background: rgba(44, 107, 255, 0.05); }
.faq-item__q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-block: 18px;
  cursor: pointer;
  list-style: none;
}
.faq-item__q::-webkit-details-marker { display: none; }
.faq-item__q::after {
  content: "";
  flex-shrink: 0;
  width: 9px;
  height: 9px;
  border-right: 2px solid var(--accent-light);
  border-bottom: 2px solid var(--accent-light);
  transform: rotate(45deg);
  transition: transform var(--transition);
}
.faq-item[open] > .faq-item__q::after { transform: rotate(-135deg); }
.faq-item__qtext {
  font-size: 0.98rem;
  font-weight: 700;
  letter-spacing: normal;
  color: var(--text-heading);
}
.faq-item__a {
  padding-bottom: 18px;
  font-size: 0.88rem;
  line-height: 1.65;
  color: var(--text-body);
  max-width: 62ch;
}

/* ============ Preloader ============ */
.preloader {
  position: fixed;
  inset: 0;
  z-index: 999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 26px;
  /* near-black, matching the logo tile so its square edge disappears */
  background: #04070f;
  transition: opacity 0.45s ease, visibility 0.45s ease;
}
.preloader.is-done {
  opacity: 0;
  visibility: hidden;
}
.preloader__logo {
  width: clamp(140px, 24vw, 220px);
  height: auto;
  /* the logo sits on pure black — screen blending melts it into the navy bg */
  mix-blend-mode: screen;
  /* fade out the tile edges so the square never shows */
  -webkit-mask-image: radial-gradient(circle, #000 52%, transparent 72%);
  mask-image: radial-gradient(circle, #000 52%, transparent 72%);
  animation: preloader-pulse 1.8s ease-in-out infinite;
}
.preloader__bar {
  width: clamp(120px, 20vw, 180px);
  height: 3px;
  border-radius: var(--radius-pill);
  background: rgba(120, 160, 255, 0.15);
  overflow: hidden;
  position: relative;
}
.preloader__bar::before {
  content: "";
  position: absolute;
  inset: 0;
  width: 40%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--accent), var(--accent-light));
  animation: preloader-slide 1.1s ease-in-out infinite;
}
@keyframes preloader-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(0.94); opacity: 0.82; }
}
@keyframes preloader-slide {
  0% { translate: -110% 0; }
  100% { translate: 260% 0; }
}

/* ============ Scroll reveal ============ */
.reveal {
  opacity: 0;
  translate: 0 16px;
  transition: opacity 0.55s ease var(--reveal-delay, 0s), translate 0.55s ease var(--reveal-delay, 0s);
}
.reveal.is-visible {
  opacity: 1;
  translate: 0 0;
}

/* ============ Lightbox ============ */
.lightbox-btn {
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
}
.pres-panel__play,
.pres-panel__badge { pointer-events: none; }

.lightbox {
  margin: auto; /* restore centering removed by the global margin reset */
  padding: 0;
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  background: var(--surface);
  box-shadow: 0 30px 90px -20px rgba(3, 8, 24, 0.9);
  max-width: min(92vw, 1100px);
  max-height: 88vh;
}
.lightbox::backdrop {
  background: rgba(4, 7, 16, 0.82);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}
.lightbox__img {
  display: block;
  max-width: min(92vw, 1100px);
  max-height: 88vh;
  object-fit: contain;
}
.lightbox__close {
  position: absolute;
  top: 10px;
  right: 10px;
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 1px solid rgba(120, 160, 255, 0.3);
  background: rgba(8, 12, 24, 0.75);
  color: var(--text-heading);
  cursor: pointer;
  transition: background var(--transition);
}
.lightbox__close:hover { background: rgba(44, 107, 255, 0.4); }

/* ============ Footer ============ */
.site-footer {
  border-top: 1px solid var(--surface-border);
  padding-block: 28px;
}
.site-footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 0.85rem;
  color: var(--text-caption);
}
.nav__logo-text--sm { font-size: 1rem; }
.site-footer__links { display: flex; gap: 6px; flex-wrap: wrap; }
.site-footer__links a {
  padding: 6px 10px;
  border-radius: var(--radius-btn);
  color: var(--text-caption);
  transition: color var(--transition);
}
.site-footer__links a:hover { color: var(--text-heading); }
.site-footer__copy { text-align: right; }

/* ============ Cookie banner ============ */
.cookie-banner {
  position: fixed;
  left: 16px;
  bottom: 16px;
  z-index: 998;
  max-width: 400px;
  padding: 20px;
  background: var(--surface);
  border: 1px solid var(--surface-border);
  border-radius: var(--radius-card);
  box-shadow: var(--shadow-card);
  opacity: 0;
  translate: 0 12px;
  transition: opacity 0.35s ease, translate 0.35s ease;
}
.cookie-banner.is-visible {
  opacity: 1;
  translate: 0 0;
}
.cookie-banner__text {
  font-size: 0.85rem;
  line-height: 1.55;
  color: var(--text-body);
  margin-bottom: 14px;
}
.cookie-banner__actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.cookie-banner__btn {
  padding: 9px 16px;
  font-size: 0.85rem;
}
@media (max-width: 480px) {
  .cookie-banner {
    left: 10px;
    right: 10px;
    bottom: 10px;
    max-width: none;
  }
  .cookie-banner .btn { width: auto; flex: 1; }
}

/* ============ Breakpoints ============ */
@media (min-width: 1200px) {
  /* larger before/after tiles on desktop only (client request 16.5) — taller
     aspect-ratio; source images (min. 594px wide) comfortably support this,
     no upscaling. Label column left untouched to avoid overflowing its heading. */
  #potencjal .ba-grid { gap: 24px; }
  #potencjal .ba { aspect-ratio: 4 / 3; }
}

@media (max-width: 1200px) {
  .hero__grid { gap: 32px; }
}

@media (max-width: 992px) {
  .nav__links, .nav__cta { display: none; }
  .nav__toggle { display: inline-flex; }

  .hero__grid { grid-template-columns: minmax(0, 1fr); }
  .hero__content { max-width: 60ch; }
  .hero__overlap { margin-top: -32px; }

  .section__split { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .section__head { max-width: 60ch; }
  .why-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cta-strip { grid-template-columns: minmax(0, 1fr); }
  .cta-strip__media { min-height: 220px; }
  .cta-strip__contacts { border-left: 0; border-top: 1px solid var(--surface-border); }
}

@media (max-width: 768px) {
  .hero__overlap {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    align-items: stretch;
  }
  .hero__qr {
    grid-column: 1 / -1;
    flex-direction: row;
    width: auto;
    justify-content: center;
  }
  .hero__qr figcaption { text-align: left; max-width: 20ch; }

  /* steps become a left-aligned vertical timeline */
  .steps { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .steps__arrow { display: none; }
  .step {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr);
    column-gap: 16px;
    row-gap: 4px;
    align-items: start;
    text-align: left;
    position: relative;
    padding-bottom: 28px;
  }
  .step:last-child { padding-bottom: 0; }
  .step:not(:last-child)::after {
    content: "";
    position: absolute;
    left: 22px;
    top: 48px;
    bottom: 4px;
    width: 1px;
    background: rgba(120, 160, 255, 0.18);
  }
  .step__icon { grid-row: 1 / span 2; width: 44px; height: 44px; }
  .step__icon svg { width: 20px; height: 20px; }
  .step__title { align-self: center; }
  .step__desc { max-width: none; }
  .ba-grid { grid-template-columns: minmax(0, 1fr); }
  .client-grid { grid-template-columns: minmax(0, 1fr); }
  .ba { aspect-ratio: 16 / 10; }
  .price-grid { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 480px) {
  .pres-window__body { grid-template-columns: 72px minmax(0, 1fr); }
  .rail-tab span { font-size: 0.56rem; }
  .hero__overlap { grid-template-columns: minmax(0, 1fr); padding-inline: 4px; }
  .hero__plan2d img { height: 200px; }
  .btn { width: 100%; }
  .hero__actions { flex-direction: column; align-items: stretch; }

  .why-grid { grid-template-columns: minmax(0, 1fr); }
  /* compact "why" cards: icon beside the title */
  .why-card {
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    column-gap: 14px;
    padding: 18px 16px;
  }
  .why-card__icon { margin-top: 1px; }
  .why-card__title { margin-top: 0; grid-column: 2; }
  .why-card__desc { grid-column: 2; }
  .demo { padding: 12px; }
  .demo__stage { aspect-ratio: 4 / 3; }
  .price-card__cta { width: 100%; text-align: center; }
}

/* ============ Reduced motion ============ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
