:root {
  color-scheme: light;
  --ink: #101728;
  --ink-soft: #263047;
  --muted: #667085;
  --paper: #f5f7fa;
  --white: #ffffff;
  --line: #dfe3ea;
  --line-strong: #c9ced8;
  --yellow: #ffd64a;
  --blue: #275ee8;
  --red: #e95d48;
  --green: #16836f;
  --violet: #7357c8;
  --max: 1380px;
  --header-height: 70px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Aptos, "Segoe UI", Arial, sans-serif;
  line-height: 1.5;
}

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

button,
input {
  font: inherit;
}

button {
  cursor: pointer;
}

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

svg {
  width: 1.15rem;
  height: 1.15rem;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.9;
}

.icon-sprite,
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

#start,
#instrukcje,
#filmy,
#aplikacje,
#epodreczniki {
  scroll-margin-top: calc(var(--header-height) + 18px);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: minmax(220px, 1fr) auto minmax(220px, 1fr);
  align-items: center;
  min-height: var(--header-height);
  padding: 0 clamp(1rem, 3vw, 2.6rem);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(14px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  width: fit-content;
}

.brand-symbol {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 2px solid var(--ink);
  background: var(--yellow);
  font-family: Georgia, serif;
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1;
}

.brand-copy {
  display: grid;
  gap: 0.05rem;
  line-height: 1.1;
}

.brand-copy strong {
  font-size: 0.94rem;
  font-weight: 800;
}

.brand-copy small {
  color: var(--muted);
  font-size: 0.72rem;
}

.main-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.35rem;
}

.main-nav a {
  position: relative;
  padding: 0.55rem 0;
  color: var(--ink-soft);
  font-size: 0.9rem;
  font-weight: 700;
}

.main-nav a::after {
  content: "";
  position: absolute;
  right: 0;
  bottom: 0.25rem;
  left: 0;
  height: 2px;
  background: var(--blue);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 160ms ease;
}

.main-nav a:hover::after,
.main-nav a:focus-visible::after {
  transform: scaleX(1);
}

.header-home {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  justify-self: end;
  gap: 0.45rem;
  min-height: 40px;
  padding: 0 0.85rem;
  border: 1px solid var(--ink);
  border-radius: 4px;
  background: var(--ink);
  color: var(--white);
  font-size: 0.86rem;
  font-weight: 750;
}

.header-home:hover,
.header-home:focus-visible {
  border-color: var(--blue);
  background: var(--blue);
  outline: none;
}

.hero {
  position: relative;
  isolation: isolate;
  min-height: 555px;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  background: #eef2f6;
}

.hero::after {
  content: "";
  position: absolute;
  z-index: -1;
  inset: 0 49% 0 0;
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(1px);
}

.hero-image {
  position: absolute;
  z-index: -2;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-content {
  width: min(var(--max), calc(100% - 2rem));
  min-height: 555px;
  margin: 0 auto;
  padding: clamp(3.4rem, 7vw, 6rem) 0 3.4rem;
}

.hero-content > * {
  max-width: 610px;
}

.hero-kicker,
.section-kicker {
  margin: 0;
  color: var(--blue);
  font-size: 0.73rem;
  font-weight: 850;
  text-transform: uppercase;
}

.hero-kicker {
  display: flex;
  align-items: center;
  gap: 0.55rem;
}

.hero-kicker span {
  width: 28px;
  height: 3px;
  background: var(--red);
}

.hero h1 {
  margin: 1rem 0 0;
  font-size: 5.9rem;
  font-weight: 850;
  line-height: 0.86;
}

.hero-lead {
  max-width: 530px;
  margin: 1.5rem 0 0;
  color: var(--ink-soft);
  font-size: 1.18rem;
}

.hero-search {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  min-height: 58px;
  margin-top: 2rem;
  border: 2px solid var(--ink);
  background: var(--white);
  box-shadow: 7px 7px 0 var(--yellow);
}

.hero-search > svg {
  width: 1.25rem;
  height: 1.25rem;
  margin-left: 1rem;
  color: var(--blue);
}

.hero-search input {
  width: 100%;
  min-width: 0;
  height: 54px;
  padding: 0 0.8rem;
  border: 0;
  background: transparent;
  color: var(--ink);
  outline: none;
}

.hero-search input::placeholder {
  color: #8a93a5;
}

.hero-search a {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  border-left: 1px solid var(--line);
  background: var(--ink);
  color: var(--white);
}

.hero-search a:hover,
.hero-search a:focus-visible {
  background: var(--blue);
  outline: none;
}

.hero-stats {
  display: flex;
  gap: 2rem;
  margin-top: 2rem;
}

.hero-stats div {
  display: grid;
  gap: 0.05rem;
}

.hero-stats strong {
  font-size: 1.3rem;
  line-height: 1;
}

.hero-stats span {
  color: var(--muted);
  font-size: 0.78rem;
}

.collection-bar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  max-width: var(--max);
  margin: 0 auto;
  border-right: 1px solid var(--line);
  border-left: 1px solid var(--line);
  background: var(--white);
}

.collection-bar > div,
.collection-bar > a {
  display: grid;
  gap: 0.2rem;
  min-height: 92px;
  padding: 1.25rem clamp(1rem, 3vw, 2rem);
  border-right: 1px solid var(--line);
}

.collection-bar > :last-child {
  border-right: 0;
}

.collection-bar > a:hover,
.collection-bar > a:focus-visible {
  background: #eef2ff;
  outline: none;
}

.collection-label {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.collection-bar strong {
  font-size: 0.94rem;
}

.collection-bar strong span {
  color: var(--blue);
  font-size: 1.2rem;
}

.lab-section {
  width: min(var(--max), calc(100% - 2rem));
  margin: 0 auto;
  padding: clamp(3.5rem, 7vw, 6rem) 0;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.section-heading h2,
.section-intro h2 {
  margin: 0.3rem 0 0;
  font-size: 2.55rem;
  line-height: 1.02;
}

.section-intro p:last-child {
  max-width: 460px;
  margin: 1rem 0 0;
  color: var(--muted);
}

.search {
  display: grid;
  gap: 0.35rem;
  width: min(340px, 100%);
  color: var(--muted);
  font-size: 0.71rem;
  font-weight: 800;
  text-transform: uppercase;
}

.input-shell {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 0.5rem;
  min-height: 42px;
  padding: 0 0.7rem;
  border: 1px solid var(--line-strong);
  border-radius: 3px;
  background: var(--white);
  color: var(--blue);
}

.input-shell input {
  width: 100%;
  min-width: 0;
  height: 40px;
  border: 0;
  background: transparent;
  color: var(--ink);
  outline: none;
}

.input-shell:focus-within {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(39, 94, 232, 0.13);
}

.instruction-grid,
.video-grid,
.app-grid {
  display: grid;
  gap: 0.9rem;
}

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

.instruction-card {
  --accent: var(--blue);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.9rem;
  min-height: 104px;
  padding: 1rem;
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 4px;
  background: var(--white);
  transition: border-color 140ms ease, box-shadow 140ms ease, transform 140ms ease;
}

.instruction-card:nth-child(3n + 2) {
  --accent: var(--green);
}

.instruction-card:nth-child(3n) {
  --accent: var(--red);
}

.instruction-card:hover {
  border-color: var(--line-strong);
  box-shadow: 0 10px 28px rgba(16, 23, 40, 0.08);
  transform: translateY(-1px);
}

.instruction-card.is-hidden {
  display: none;
}

.card-icon,
.icon-button {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 4px;
}

.card-icon {
  background: #eef2ff;
  color: var(--accent);
}

.icon-button {
  border: 1px solid var(--line-strong);
  background: var(--white);
  color: var(--ink);
}

.icon-button:hover,
.icon-button:focus-visible {
  border-color: var(--blue);
  background: var(--blue);
  color: var(--white);
  outline: none;
}

.instruction-card h3,
.video-card h3 {
  margin: 0;
  color: var(--ink);
  font-size: 1.05rem;
}

.instruction-card p,
.video-card p {
  margin: 0.2rem 0 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.blue-band {
  width: 100%;
  max-width: none;
  padding-right: max(1rem, calc((100vw - var(--max)) / 2));
  padding-left: max(1rem, calc((100vw - var(--max)) / 2));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: #e9edf4;
}

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

.video-card {
  min-height: 324px;
  overflow: hidden;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  background: var(--white);
}

.video-frame {
  display: grid;
  place-items: center;
  gap: 0.6rem;
  aspect-ratio: 16 / 9;
  background:
    linear-gradient(135deg, rgba(16, 23, 40, 0.95), rgba(39, 94, 232, 0.78)),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.16) 0 1px, transparent 1px 18px);
  color: var(--white);
  font-weight: 850;
}

.video-frame svg {
  width: 3.1rem;
  height: 3.1rem;
  padding: 0.75rem;
  border: 2px solid rgba(255, 255, 255, 0.86);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
}

.video-card h3,
.video-card p {
  padding-right: 1rem;
  padding-left: 1rem;
}

.video-card h3 {
  margin-top: 1rem;
}

.video-card p {
  padding-bottom: 1.25rem;
}

.two-column {
  display: grid;
  grid-template-columns: 0.85fr 1.5fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: start;
}

.section-intro {
  position: sticky;
  top: calc(var(--header-height) + 24px);
}

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

.app-card,
.link-list a {
  border: 1px solid var(--line);
  border-radius: 4px;
  background: var(--white);
  box-shadow: 0 10px 26px rgba(16, 23, 40, 0.055);
}

.app-card {
  display: grid;
  gap: 0.45rem;
  min-height: 146px;
  padding: 1rem;
}

.app-card svg {
  color: var(--blue);
}

.app-card span {
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 820;
}

.app-card small {
  color: var(--muted);
  font-size: 0.88rem;
}

.app-card:hover,
.app-card:focus-visible,
.link-list a:hover,
.link-list a:focus-visible {
  border-color: var(--blue);
  box-shadow: 0 16px 36px rgba(16, 23, 40, 0.12);
  outline: none;
  transform: translateY(-1px);
}

.link-list {
  display: grid;
  gap: 0.8rem;
}

.link-list a {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  min-height: 64px;
  padding: 1rem 1.1rem;
  color: var(--ink);
  font-weight: 760;
}

.link-list svg {
  color: var(--blue);
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem max(1rem, calc((100vw - var(--max)) / 2));
  border-top: 1px solid #30394e;
  background: var(--ink);
  color: #9fa9bc;
  font-size: 0.8rem;
}

.footer-brand {
  color: var(--white);
  font-weight: 800;
}

.footer-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.55rem;
}

.footer-meta a {
  color: var(--white);
  font-weight: 750;
}

.footer-meta a:hover,
.footer-meta a:focus-visible {
  color: var(--yellow);
  outline: none;
}

.footer-separator {
  color: #566178;
}

@media (max-width: 1180px) {
  .hero h1 {
    font-size: 5.1rem;
  }

  .instruction-grid,
  .video-grid,
  .app-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 940px) {
  :root {
    --header-height: 64px;
  }

  .site-header {
    grid-template-columns: 1fr auto;
  }

  .main-nav {
    display: none;
  }

  .hero,
  .hero-content {
    min-height: 520px;
  }

  .hero::after {
    inset: 0 34% 0 0;
    background: rgba(255, 255, 255, 0.78);
  }

  .hero-image {
    object-position: 58% center;
  }

  .two-column {
    grid-template-columns: 1fr;
  }

  .section-intro {
    position: static;
  }
}

@media (max-width: 720px) {
  .site-header {
    padding: 0 0.8rem;
  }

  .brand-copy small {
    display: none;
  }

  .header-home span {
    display: none;
  }

  .header-home {
    width: 42px;
    padding: 0;
  }

  .hero,
  .hero-content {
    min-height: 590px;
  }

  .hero::after {
    inset: 0;
    background: rgba(255, 255, 255, 0.8);
  }

  .hero-image {
    object-position: 68% center;
  }

  .hero-content {
    width: min(100% - 1.5rem, var(--max));
    padding-top: 3rem;
  }

  .hero h1 {
    font-size: 4.05rem;
  }

  .hero-search {
    box-shadow: 5px 5px 0 var(--yellow);
  }

  .hero-search input {
    font-size: 0.88rem;
  }

  .hero-stats {
    gap: 1rem;
  }

  .collection-bar,
  .instruction-grid,
  .video-grid,
  .app-grid {
    grid-template-columns: 1fr;
  }

  .collection-bar {
    width: 100%;
    border-right: 0;
    border-left: 0;
  }

  .collection-bar > div,
  .collection-bar > a {
    min-height: 72px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .section-heading,
  .footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .search {
    width: 100%;
  }

  .footer-meta {
    justify-content: flex-start;
  }
}

@media (max-width: 470px) {
  .brand-copy strong {
    max-width: 140px;
    font-size: 0.82rem;
  }

  .hero h1 {
    font-size: 3.15rem;
  }

  .hero-lead {
    font-size: 1rem;
  }

  .section-heading h2,
  .section-intro h2 {
    font-size: 2rem;
  }

  .instruction-card {
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .icon-button {
    grid-column: 2;
    justify-self: start;
  }
}
