/* Landing (site/index.html). Spec: docs/landing/SPEC.md. Mobile-first: układ telefonu bazowy,
   tablet od 640 px, komputer od 1024 px. Podstrony prawne mają własny, prostszy style.css. */

:root {
  --bg: #121212;
  --card: #1e1e1e;
  --text: #f4f4f4;
  --muted: #a0a0a0;
  --border: #333333;
  --accent: #e31c23;
  --phone: #000000;
  --shadow: rgba(0, 0, 0, 0.45);
  --radius: 16px;
  --radius-btn: 14px;
  --gutter: 20px;
  color-scheme: dark light;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #ffffff;
    --card: #f6f6f6;
    --text: #1a1a1a;
    --muted: #6b6b6b;
    --border: #e2e2e2;
    --shadow: rgba(0, 0, 0, 0.18);
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.5 system-ui, Roboto, "Segoe UI", sans-serif;
  overflow-wrap: break-word;
}

h1,
h2,
h3,
p,
ul,
figure {
  margin: 0;
}

ul {
  padding: 0;
  list-style: none;
}

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

a {
  color: inherit;
}

a:focus-visible,
.strip-scroll:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
  border-radius: 6px;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* Wersje treści: telefon i tablet dostają skróty, komputer pełne opisy. display: none, więc czytnik ekranu czyta jedną. */
@media (max-width: 1023.98px) {
  .only-desktop {
    display: none !important;
  }
}

@media (min-width: 1024px) {
  .only-mobile {
    display: none !important;
  }
}

.ico {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: var(--accent);
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ---------- Nagłówek ---------- */

.top-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 60px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 800;
  font-size: 19px;
  letter-spacing: -0.02em;
}

.logo-mark {
  width: 32px;
  height: 32px;
}

.top-nav {
  display: none;
}

/* ---------- Hero ---------- */

.hero {
  padding: 8px 0 16px;
}

.hero h1 {
  font-size: clamp(34px, 3.2vw + 26px, 76px);
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.hero-lead {
  margin-top: 12px;
  font-size: 17px;
  line-height: 1.45;
  color: var(--muted);
}

.stores {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 20px;
}

.store {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 56px;
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-btn);
  background: var(--card);
  cursor: default;
  line-height: 1.15;
}

.store-small {
  font-size: 12px;
  color: var(--muted);
}

.store-big {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.pill {
  display: inline-block;
  margin-bottom: 22px;
  padding: 5px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  color: var(--muted);
}

.traits {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin-top: 22px;
  color: var(--muted);
  font-size: 15px;
}

.traits li + li::before {
  content: "·" / "";
  margin-right: 12px;
}

/* ---------- Ramka telefonu (bez obrazków ramek i fałszywego paska statusu) ---------- */

.phone {
  padding: 8px;
  border-radius: 36px;
  background: var(--phone);
  box-shadow: 0 24px 60px var(--shadow);
}

.phone img {
  width: 100%;
  border-radius: 28px;
}

/* ---------- Trzy główne funkcje ---------- */

.features {
  padding: 4px 0 8px;
}

.feature-grid {
  display: grid;
  gap: 10px;
}

.feature {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
}

.feature-body {
  display: flex;
  gap: 12px;
  padding: 14px 16px;
}

.feature-ico {
  margin-top: 1px;
}

.feature h3 {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.01em;
  line-height: 1.3;
}

.feature p {
  margin-top: 2px;
  font-size: 14px;
  line-height: 1.45;
  color: var(--muted);
}

/* Numer w kolorze akcentu: 19 px pogrubione to „duży tekst” w WCAG, więc wystarcza kontrast 3:1. */
.feature .num {
  margin: 0 0 4px;
  font-size: 19px;
  font-weight: 800;
  color: var(--accent);
}

/* ---------- Pasek zrzutów (telefon i tablet) ---------- */

.strip {
  padding: 28px 0 8px;
}

.strip-scroll {
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding: 0 var(--gutter);
  padding: 8px 0 28px;
}

/* Szerokość według treści i margines auto: gdy telefony się mieszczą, są wyśrodkowane, a gdy nie, przewija się tylko ta sekcja. */
.strip-list {
  display: flex;
  gap: 14px;
  width: max-content;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.strip-list li {
  scroll-snap-align: start;
}

.phone-strip {
  width: 230px;
}

.strip figcaption {
  width: 230px;
  margin-top: 10px;
  font-size: 13px;
  color: var(--muted);
}

/* ---------- Kafelki ---------- */

.tiles {
  padding: 16px 0 8px;
}

.tile-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.tile {
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
}

.tile .ico {
  width: 22px;
  height: 22px;
}

.tile h3 {
  margin-top: 10px;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.01em;
}

.tile p {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--muted);
}

/* ---------- Za darmo i Premium ---------- */

.plans {
  padding: 28px 0 8px;
}

.plan-grid {
  display: grid;
  gap: 12px;
}

.plan {
  padding: 20px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
}

.plan-premium {
  border: 2px solid var(--accent);
}

.plan h3 {
  font-size: 24px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.checks {
  margin-top: 12px;
}

.checks li {
  position: relative;
  padding-left: 22px;
  margin-top: 8px;
  font-size: 15px;
  line-height: 1.45;
}

.checks li::before {
  content: "✓" / "";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 800;
}

.pluses li::before {
  content: "+" / "";
}

/* ---------- Na start i mniejsze funkcje ---------- */

.start {
  padding: 32px 0 0;
}

.start h2 {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.start .stores {
  margin-top: 14px;
}

.extras {
  padding: 20px 0 32px;
}

.extras-list {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 0;
  font-size: 13px;
  line-height: 1.5;
  color: var(--muted);
}

.extras-list li:not(:last-child)::after {
  content: "·" / "";
  margin: 0 8px;
}

/* ---------- Stopka ---------- */

.foot {
  border-top: 1px solid var(--border);
  padding: 12px 0 28px;
  font-size: 14px;
  color: var(--muted);
}

.foot-inner {
  display: flex;
  flex-direction: column-reverse;
  gap: 8px;
}

.foot-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

/* Cel dotyku co najmniej 44 px wysokości. */
.foot-links a,
.foot-mail {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 0 4px;
}

.foot-links a {
  text-decoration: none;
}

.foot-links a:hover {
  color: var(--text);
  text-decoration: underline;
}

/* ---------- Tablet ---------- */

@media (min-width: 640px) {
  :root {
    --gutter: 32px;
  }

  .hero {
    padding: 24px 0 24px;
  }

  .hero-lead {
    font-size: 19px;
    max-width: 560px;
  }

  .stores {
    grid-template-columns: repeat(2, minmax(0, 220px));
  }

  .tile-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .plan-grid {
    grid-template-columns: 1fr 1fr;
  }

  .foot-links {
    grid-template-columns: repeat(4, auto);
    justify-content: start;
    gap: 0 16px;
  }
}

/* ---------- Komputer ---------- */

@media (min-width: 1024px) {
  .top-inner {
    min-height: 88px;
  }

  .logo {
    font-size: 22px;
  }

  .logo-mark {
    width: 40px;
    height: 40px;
  }

  .top-nav {
    display: flex;
    gap: 28px;
    font-size: 15px;
  }

  .top-nav a {
    color: var(--muted);
    text-decoration: none;
  }

  .top-nav a:hover {
    color: var(--text);
  }

  .hero {
    padding: 16px 0 48px;
  }

  .hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
    align-items: center;
    gap: 48px;
  }

  .hero-lead {
    margin-top: 20px;
    font-size: 22px;
    max-width: 520px;
  }

  .stores {
    margin-top: 32px;
    grid-template-columns: repeat(2, 200px);
  }

  /* Dwa telefony: główny na wierzchu, drugi obrócony i przyciemniony za nim. */
  .hero-phones {
    position: relative;
    height: 640px;
  }

  .phone-front {
    position: absolute;
    right: 20px;
    top: 0;
    width: 310px;
    padding: 10px;
    border-radius: 46px;
    box-shadow: 0 40px 90px var(--shadow);
  }

  .phone-front img {
    border-radius: 36px;
  }

  /* Tylny telefon od lewej krawędzi kolumny (nie od prawej), żeby przy 1024 px nie wchodził na tekst. */
  .phone-back {
    position: absolute;
    left: max(0px, calc(100% - 490px));
    top: 56px;
    width: 260px;
    padding: 9px;
    border-radius: 40px;
    opacity: 0.55;
    transform: rotate(-6deg);
  }

  .phone-back img {
    border-radius: 32px;
  }

  .features {
    padding: 0 0 56px;
  }

  .feature-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
  }

  .feature {
    display: flex;
    flex-direction: column;
    overflow: hidden;
  }

  .feature-shot {
    display: flex;
    justify-content: center;
    padding: 24px 0;
    border-bottom: 1px solid var(--border);
  }

  .phone-sm {
    width: 200px;
    border-radius: 32px;
  }

  .phone-sm img {
    border-radius: 25px;
  }

  .feature-body {
    padding: 24px 26px 28px;
  }

  .feature-body .feature-ico {
    display: none;
  }

  .feature h3 {
    font-size: 26px;
    letter-spacing: -0.02em;
  }

  .feature p {
    margin-top: 8px;
    font-size: 16px;
  }

  .tiles {
    padding: 0 0 56px;
  }

  .tile-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 24px;
  }

  .tile {
    padding: 0;
    border: 0;
    background: none;
  }

  .tile h3 {
    font-size: 17px;
  }

  .tile p {
    font-size: 14px;
  }

  .plans {
    padding: 0 0 48px;
  }

  .plan-grid {
    gap: 22px;
  }

  .plan {
    padding: 28px 30px;
  }

  .plan h3 {
    font-size: 28px;
  }

  .checks li {
    font-size: 16px;
  }

  .extras {
    padding: 0 0 40px;
  }

  .extras-list {
    justify-content: center;
    gap: 8px 28px;
    font-size: 14px;
  }

  .extras-list li:not(:last-child)::after {
    content: none;
  }

  .foot {
    padding: 20px 0;
  }

  .foot-inner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
