@font-face {
  font-family: "Abril Fatface";
  src: url("./assets/fonts/AbrilFatface-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Instrument Sans";
  src: url("./assets/fonts/InstrumentSans.woff2") format("woff2");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #fffdf7;
  --ink: #2438c2;
  --ink-deep: #1a288f;
  --muted: #4b4d58;
  --orange: #f26a1b;
  --green: #0f9d58;
  --green-btn: #0b7f47;
  --magenta: #e0218a;
  --magenta-text: #b8126c;
  --yellow: #ffc400;
  --pink: #f7b9c8;
  --sand: #f1e8d3;
  --sand-dark: #dfd4bc;

  --display: "Abril Fatface", Georgia, serif;
  --sans: "Instrument Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --max: 1160px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --spring: cubic-bezier(0.18, 1.12, 0.32, 1);
}

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

html {
  scroll-behavior: smooth;
  background: var(--paper);
  color: var(--ink);
}

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.58;
  color: var(--muted);
  background: var(--paper);
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
  position: relative;
}

/* Subtelna faktura papieru czerpanego */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  opacity: 0.028;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='0.9'/%3E%3C/svg%3E");
}

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

a {
  color: var(--ink);
  text-decoration: none;
}

button {
  font: inherit;
  border: 0;
  background: none;
  cursor: pointer;
}

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

/* Wycinanki Plissé — zarezerwowane dla głównych powierzchni papierowych (stała głębokość w px na dużych kartach) */
.cut-0 {
  clip-path: polygon(1.4% 2%, 98.8% 0%, 100% 97.8%, 0.5% 100%);
}
.cut-1 {
  clip-path: polygon(0% 0.4%, 98.8% 2.2%, 98.4% 100%, 1.8% 97.8%);
}
.cut-2 {
  clip-path: polygon(1% 2.4%, 100% 0.5%, 99% 98.6%, 0% 96.8%);
}
.cut-3 {
  clip-path: polygon(1.6% 0%, 99.4% 1.8%, 98.2% 98.4%, 0% 100%);
}
.cut-lg-0 {
  clip-path: polygon(6px 5px, calc(100% - 5px) 0px, 100% calc(100% - 6px), 3px 100%);
}
.cut-lg-1 {
  clip-path: polygon(0px 3px, calc(100% - 5px) 7px, calc(100% - 6px) 100%, 6px calc(100% - 5px));
}
.cut-lg-2 {
  clip-path: polygon(5px 6px, 100% 2px, calc(100% - 5px) calc(100% - 4px), 0px calc(100% - 7px));
}

/* Liście Matisse'a zakotwiczone wyłącznie w kompozycji otwarcia — reszta strony ma czyste marginesy */
.fronds {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 820px;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.frond {
  position: absolute;
  width: clamp(160px, 17vw, 250px);
  height: auto;
}

.frond-top {
  top: -26px;
  right: -52px;
  fill: var(--green);
  opacity: 0.13;
  transform: rotate(24deg);
}

.frond-bottom {
  bottom: 24px;
  left: -56px;
  fill: var(--pink);
  opacity: 0.3;
  transform: rotate(18deg);
}

.wrap {
  position: relative;
  z-index: 1;
  width: min(100% - 44px, var(--max));
  margin-inline: auto;
}

/* Delikatne wejścia bez ukrywania sekcji w pustce */
@keyframes paperIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.hero-anim {
  animation: paperIn 0.55s var(--ease) both;
}
.hero-anim-2 {
  animation: paperIn 0.62s var(--ease) 0.06s both;
}
.hero-anim-3 {
  animation: paperIn 0.68s var(--ease) 0.12s both;
}

.js .reveal {
  opacity: 0.96;
  transform: translateY(10px);
  transition:
    opacity 0.5s var(--ease),
    transform 0.55s var(--ease);
}

.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* Nawigacja */
.topbar {
  position: relative;
  z-index: 10;
  padding: 20px 0;
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  transition: transform 0.2s var(--ease);
}

.brand:hover {
  transform: translateY(-1px);
}

.brand-icon {
  width: 42px;
  height: 42px;
  object-fit: cover;
}

.brand-name {
  font-family: var(--display);
  font-size: 27px;
  line-height: 1;
  letter-spacing: -0.01em;
}

.nav {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}

.nav-link {
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  padding: 8px 12px;
  border-radius: 6px;
  transition: background-color 0.16s var(--ease);
}

.nav-link:hover {
  background: var(--sand);
}

.lang-select-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  background: var(--sand);
  border-radius: 7px;
  transition: background-color 0.16s var(--ease);
}

.lang-select-wrap:hover {
  background: var(--sand-dark);
}

.lang-select {
  appearance: none;
  -webkit-appearance: none;
  border: 0;
  background: transparent;
  color: var(--ink);
  font-family: var(--sans);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  padding: 8px 30px 8px 12px;
  cursor: pointer;
}

.lang-chevron {
  position: absolute;
  right: 10px;
  width: 10px;
  height: 7px;
  color: var(--ink);
  pointer-events: none;
}

.nav-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  background: transparent;
  border: 1.5px solid var(--sand-dark);
  border-radius: 7px;
  padding: 7px 12px;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

/* Przyciski */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--sans);
  font-weight: 700;
  font-size: 16px;
  line-height: 1.15;
  padding: 15px 26px;
  transition: transform 0.2s var(--spring), background-color 0.16s var(--ease);
  white-space: nowrap;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: scale(0.98);
}

.btn-primary {
  background: var(--green-btn);
  color: var(--paper);
}

.btn-primary:hover {
  background: #096f3e;
}

.btn-secondary {
  background: var(--sand);
  color: var(--ink);
}

.btn-secondary:hover {
  background: var(--sand-dark);
}

.btn-yellow {
  background: var(--yellow);
  color: var(--ink);
}

.btn-yellow:hover {
  background: #f2ba00;
}

.btn-sm {
  font-size: 14px;
  padding: 10px 18px;
}

.appstore-pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 11px 15px;
  border-radius: 8px;
  border: 1.5px solid var(--sand-dark);
  background: var(--paper);
  color: var(--ink);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
}

.appstore-soon {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.01em;
  background: var(--yellow);
  color: var(--ink);
  padding: 3px 8px;
  border-radius: 4px;
}

.apple-ico {
  width: 16px;
  height: 16px;
  fill: currentColor;
  flex: 0 0 auto;
  margin-top: -2px;
}

/* Typografia sekcji */
.kicker {
  display: inline-block;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--magenta-text);
  margin: 0 0 12px;
}

h1,
h2,
h3 {
  color: var(--ink);
  margin: 0;
}

h1 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(44px, 5.6vw, 72px);
  line-height: 1.08;
  letter-spacing: -0.018em;
  text-wrap: balance;
}

h1 .hl {
  display: inline-block;
  background: var(--yellow);
  color: var(--ink);
  padding: 0 14px 5px;
  margin-left: 2px;
  clip-path: polygon(1.5% 3%, 99% 0%, 98.5% 98%, 0.5% 100%);
}

h2 {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(32px, 4vw, 50px);
  line-height: 1.08;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

h3 {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 20px;
  line-height: 1.28;
}

/* HERO + INTERAKTYWNY PODGLĄD ZGIĘCIA */
.hero {
  padding: 20px 0 72px;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.94fr) minmax(0, 1.06fr);
  gap: clamp(32px, 4.8vw, 64px);
  align-items: center;
}

.hero-lead {
  font-size: clamp(17.5px, 1.8vw, 19.5px);
  line-height: 1.6;
  color: var(--muted);
  margin: 22px 0 28px;
  max-width: 44ch;
  text-wrap: pretty;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 12px 14px;
  flex-wrap: wrap;
}

.hero-meta {
  margin: 20px 0 0;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.01em;
}

/* Pojedyncza papierowa ramka podglądu 3D — bez udawanego paska stanu iOS ani naklejek zasłaniających model */
.hero-demo-wrap {
  position: relative;
}

.hero-demo-mat {
  background: var(--yellow);
  padding: 16px;
}

.demo-frame {
  background: var(--paper);
  border: 2px solid var(--ink);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.demo-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 12px 16px;
  background: var(--paper);
  border-bottom: 1px solid var(--sand-dark);
}

.demo-tabs {
  display: inline-flex;
  gap: 6px;
  flex-wrap: wrap;
}

.demo-tab {
  font-size: 13px;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: 6px;
  background: var(--sand);
  color: var(--ink);
  transition: background-color 0.16s var(--ease), color 0.16s var(--ease);
}

.demo-tab:hover {
  background: var(--sand-dark);
}

.demo-tab[aria-pressed="true"] {
  background: var(--ink);
  color: var(--paper);
}

.demo-note {
  margin: 0;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--muted);
  line-height: 1.3;
}

.demo-canvas-box {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 0.82;
  background: var(--orange);
  overflow: hidden;
  transition: background-color 0.35s var(--ease);
}

.demo-fallback {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 42%;
  opacity: 0.92;
  transition: opacity 0.4s var(--ease);
}

.demo-canvas-box.is-ready .demo-fallback {
  opacity: 0;
  pointer-events: none;
}

.demo-iframe {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  opacity: 0;
  transition: opacity 0.4s var(--ease);
}

.demo-canvas-box.is-ready .demo-iframe {
  opacity: 1;
}

.demo-bar {
  background: var(--paper);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  border-top: 1px solid var(--sand-dark);
  min-height: 76px;
}

.demo-caption {
  min-width: 0;
  flex: 1 1 180px;
}

.demo-counter {
  font-size: 12.5px;
  font-weight: 700;
  color: var(--magenta-text);
  margin: 0 0 3px;
}

.demo-step-title {
  font-size: 15.5px;
  font-weight: 700;
  color: var(--ink);
  margin: 0;
  line-height: 1.28;
}

.demo-controls {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
}

.demo-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 40px;
  padding: 0 14px;
  border-radius: 7px;
  font-size: 14px;
  font-weight: 700;
  transition: transform 0.16s var(--spring), background-color 0.16s var(--ease);
}

.demo-btn:hover:not(:disabled) {
  transform: translateY(-1px);
}

.demo-btn:active:not(:disabled) {
  transform: scale(0.96);
}

.demo-btn:disabled {
  opacity: 0.35;
  cursor: default;
}

.demo-btn-prev {
  background: var(--sand);
  color: var(--ink);
  width: 40px;
  padding: 0;
}

.demo-btn-replay {
  background: var(--yellow);
  color: var(--ink);
  width: 40px;
  padding: 0;
}

.demo-btn-next {
  background: var(--green-btn);
  color: var(--paper);
  padding: 0 18px;
  border-radius: 0;
}

/* Sekcje ogólne */
.section {
  padding: clamp(56px, 7vw, 96px) 0;
}

.section-head {
  max-width: 680px;
  margin-bottom: 36px;
}

.section-head > p:not(.kicker) {
  margin: 14px 0 0;
  font-size: 18px;
  line-height: 1.58;
  color: var(--muted);
  text-wrap: pretty;
}

/* 3 kroki — równa, redakcyjna sekwencja 01 / 02 / 03 */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
  align-items: stretch;
}

.step-card {
  padding: 28px 28px 30px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.step-card.sand {
  background: var(--sand);
}

.step-card.yellow {
  background: var(--yellow);
}

.step-card.pink {
  background: var(--pink);
}

.step-media {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.step-num {
  font-family: var(--display);
  font-size: 32px;
  line-height: 1;
  color: var(--ink);
  opacity: 0.28;
}

.step-thumb {
  width: 84px;
  height: 84px;
  object-fit: contain;
}

.step-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.step-card p {
  margin: 0;
  color: var(--ink-deep);
  font-size: 15.5px;
  line-height: 1.56;
}

.step-card.sand p {
  color: var(--muted);
}

/* Galeria 30 modeli — zrównoważona siatka 5×3 (15 darmowych) i 5×6 (30 wszystkich) */
.models-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px 18px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}

.filters {
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
}

.filter-btn {
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
  background: var(--sand);
  padding: 9px 15px;
  border-radius: 7px;
  transition: background-color 0.16s var(--ease), color 0.16s var(--ease);
}

.filter-btn:hover {
  background: var(--sand-dark);
}

.filter-btn[aria-pressed="true"] {
  background: var(--ink);
  color: var(--paper);
}

.models-note {
  margin: 0 0 26px;
  font-size: 15.5px;
  color: var(--muted);
  max-width: 66ch;
}

.models-note strong {
  color: var(--ink);
}

.models-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 16px;
}

.model-tile {
  position: relative;
  padding: 18px 14px 14px;
  background: var(--stage, var(--sand));
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.model-tile[hidden] {
  display: none;
}

.model-tile img {
  width: 108px;
  height: 108px;
  object-fit: contain;
}

.model-label {
  width: 100%;
  background: var(--paper);
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  text-align: center;
  padding: 7px 10px;
  border-radius: 5px;
  line-height: 1.22;
}

.model-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.01em;
  padding: 3px 8px;
  border-radius: 4px;
}

.model-badge-plus {
  background: var(--ink);
  color: var(--paper);
}

/* Sekcja iPad w poziomie + 3×3 próbki lektora */
.split-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}

.ipad-figure {
  margin: 0;
}

.ipad-stage {
  background: var(--sand);
  padding: clamp(18px, 2.5vw, 28px);
}

.ipad-frame {
  background: var(--ink);
  padding: 9px;
  border-radius: 22px;
  width: 100%;
}

.ipad-frame img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 14px;
  display: block;
  background: var(--paper);
}

.device-caption {
  margin: 12px 0 0;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--muted);
  text-align: center;
  letter-spacing: 0.01em;
}

.split-lead {
  margin: 14px 0 0;
  font-size: 17px;
  line-height: 1.58;
}

.points-list {
  margin: 24px 0 0;
  display: grid;
  gap: 18px;
}

.point-item h3 {
  font-size: 17px;
  line-height: 1.3;
  margin-bottom: 4px;
}

.point-item p {
  margin: 0;
  font-size: 15.5px;
  line-height: 1.55;
}

/* Odsłuch lektora — symetryczna siatka 3×3 */
.voice-box {
  margin-top: 26px;
  padding: 20px;
  background: var(--sand);
}

.voice-prompt {
  margin: 0 0 12px;
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
}

.voice-chips {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.voice-chip {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  background: var(--paper);
  color: var(--ink);
  font-size: 13.5px;
  font-weight: 700;
  padding: 9px 11px;
  border-radius: 6px;
  border: 1.5px solid transparent;
  transition:
    background-color 0.16s var(--ease),
    color 0.16s var(--ease),
    border-color 0.16s var(--ease);
  min-width: 0;
}

.voice-chip > span:last-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.voice-chip.is-current {
  border-color: rgba(36, 56, 194, 0.32);
}

.voice-chip:hover {
  background: var(--yellow);
  border-color: transparent;
}

.voice-chip.is-playing {
  background: var(--green-btn);
  color: var(--paper);
  border-color: transparent;
}

.voice-ico {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 13px;
  height: 12px;
  flex-shrink: 0;
}

.voice-play {
  width: 9px;
  height: 11px;
  display: block;
}

.voice-bars {
  display: none;
  align-items: flex-end;
  gap: 2px;
  height: 12px;
  width: 12px;
}

.voice-chip.is-playing .voice-play {
  display: none;
}

.voice-chip.is-playing .voice-bars {
  display: inline-flex;
}

.voice-bars i {
  display: block;
  width: 2.5px;
  height: 5px;
  background: currentColor;
  animation: eqBar 0.65s ease-in-out infinite alternate;
}

.voice-bars i:nth-child(2) {
  height: 10px;
  animation-delay: 0.18s;
}

.voice-bars i:nth-child(3) {
  height: 7px;
  animation-delay: 0.34s;
}

@keyframes eqBar {
  from {
    height: 3px;
  }
  to {
    height: 12px;
  }
}

/* Plakat dla rodzica */
.parent-poster {
  background: var(--ink);
  color: var(--paper);
  padding: clamp(36px, 5.2vw, 60px);
}

.parent-poster .kicker {
  color: var(--yellow);
}

.parent-poster h2 {
  color: var(--paper);
  max-width: 18ch;
}

.parent-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px 44px;
  margin: 34px 0 38px;
}

.parent-item {
  padding-top: 16px;
  border-top: 1px solid rgba(255, 253, 247, 0.18);
}

.parent-item h3 {
  color: var(--yellow);
  font-size: 18.5px;
  margin-bottom: 6px;
}

.parent-item p {
  margin: 0;
  color: rgba(255, 253, 247, 0.9);
  font-size: 15.5px;
  line-height: 1.58;
  max-width: 42ch;
}

.parent-cta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  padding-top: 24px;
  border-top: 1px solid rgba(255, 253, 247, 0.2);
}

.parent-cta p {
  margin: 0;
  font-size: 15.5px;
  color: rgba(255, 253, 247, 0.88);
}

.parent-cta-links {
  display: inline-flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
}

.parent-privacy-link {
  color: var(--paper);
  font-size: 15px;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-color: rgba(255, 253, 247, 0.45);
}

.parent-privacy-link:hover {
  color: var(--yellow);
  text-decoration-color: var(--yellow);
}

/* Stopka — na tle papieru z subtelną linią oddzielającą, bez odcięcia przy dolnym pasku Safari na iOS */
.footer {
  margin-top: 40px;
  background: var(--paper);
  border-top: 1px solid var(--sand-dark);
  padding: 36px 0 calc(40px + env(safe-area-inset-bottom, 0px));
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px 24px;
  flex-wrap: wrap;
}

.footer-links {
  display: flex;
  align-items: center;
  gap: 10px 22px;
  flex-wrap: wrap;
  font-size: 15px;
  font-weight: 600;
}

.footer-links a:hover {
  color: var(--magenta-text);
}

.footer-langs {
  margin: 20px 0 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  align-items: center;
}

.footer-langs a {
  color: var(--ink);
}

.footer-langs a:hover {
  color: var(--magenta-text);
}

.footer-langs a[aria-current="page"] {
  color: var(--magenta-text);
  text-decoration: underline;
  text-underline-offset: 4px;
}

.footer-meta {
  font-size: 13.5px;
  color: var(--muted);
  margin: 14px 0 0;
}

/* Podstrony prawne i pomoc — spokojny arkusz referencyjny */
.doc-wrap {
  width: min(100% - 44px, 780px);
  margin: 16px auto 64px;
  position: relative;
  z-index: 1;
}

.doc-card {
  background: var(--sand);
  padding: clamp(28px, 4.5vw, 52px);
}

.doc-card h1 {
  font-size: clamp(34px, 4.5vw, 48px);
  margin-bottom: 10px;
}

.doc-updated {
  font-size: 14px;
  font-weight: 600;
  color: var(--magenta-text);
  margin: 0 0 28px;
}

.doc-card h2 {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 20px;
  line-height: 1.3;
  margin: 28px 0 8px;
}

.doc-card p,
.doc-card li {
  color: #323442;
  font-size: 16px;
  line-height: 1.68;
}

.doc-card ul {
  padding-left: 20px;
  margin: 8px 0 14px;
}

.doc-card a {
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 600;
}

.faq-list {
  background: var(--paper);
  border-radius: 10px;
  padding: 6px 26px;
}

.faq-item {
  padding: 20px 0;
  border-bottom: 1px solid var(--sand-dark);
}

.faq-item:last-child {
  border-bottom: 0;
}

.faq-item h2 {
  margin: 0 0 8px;
  font-size: 18px;
  line-height: 1.35;
}

.faq-item p {
  margin: 0;
}

.doc-outro {
  margin: 24px 0 0;
}

.back-home {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 14.5px;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 7px;
  background: var(--sand);
  color: var(--ink);
  transition: background-color 0.16s var(--ease);
}

.back-home:hover {
  background: var(--sand-dark);
}

/* Responsywność */
@media (max-width: 1080px) {
  .models-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  .hero-grid,
  .split-grid,
  .steps-grid,
  .parent-grid {
    grid-template-columns: 1fr;
  }

  .hero {
    padding: 12px 0 52px;
  }

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

@media (max-width: 680px) {
  .step-card {
    flex-direction: row;
    align-items: center;
    padding: 20px 20px;
    gap: 18px;
  }

  .step-media {
    flex-direction: column-reverse;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
  }

  .step-num {
    font-size: 20px;
  }

  .step-thumb {
    width: 68px;
    height: 68px;
  }
}

@media (max-width: 560px) {
  .wrap,
  .doc-wrap {
    width: min(100% - 44px, var(--max));
  }

  .fronds {
    height: 560px;
  }

  .topbar {
    padding: 20px 0 18px;
  }

  .topbar-inner {
    gap: 12px;
  }

  .brand-icon {
    width: 38px;
    height: 38px;
  }

  .brand-name {
    font-size: 25px;
  }

  .nav {
    display: contents;
  }

  .nav-links {
    display: none;
  }

  .lang-select-wrap {
    order: 2;
    margin-left: auto;
  }

  .lang-select {
    font-size: 13.5px;
    padding: 8px 28px 8px 12px;
  }

  .nav-status {
    display: none;
  }

  .hero {
    padding: 22px 0 56px;
  }

  .hero-grid {
    gap: 0;
  }

  .hero-copy {
    display: contents;
  }

  .hero-copy .kicker {
    display: none;
  }

  .hero-copy h1 {
    order: 1;
    font-size: clamp(40px, 10.6vw, 48px);
    line-height: 1.1;
    margin-bottom: 20px;
  }

  .hero-lead {
    order: 2;
    margin: 0 0 28px;
    font-size: 16.5px;
    line-height: 1.62;
  }

  .hero-actions {
    order: 3;
    gap: 14px;
    margin: 0 0 40px;
  }

  .hero-demo-wrap {
    order: 4;
  }

  .hero-meta {
    order: 5;
    margin: 18px 0 0;
    font-size: 13.5px;
    line-height: 1.5;
    text-align: center;
  }

  .btn {
    white-space: normal;
    text-align: center;
    max-width: 100%;
    padding: 14px 24px;
    font-size: 15.5px;
  }

  .appstore-pill {
    font-size: 13.5px;
    padding: 10px 14px;
    gap: 8px;
  }

  .hero-demo-mat {
    padding: 14px;
  }

  .demo-top {
    padding: 12px 14px;
    gap: 10px;
  }

  .demo-bar {
    padding: 14px;
    flex-wrap: wrap;
    gap: 12px;
    min-height: 0;
  }

  .demo-canvas-box {
    aspect-ratio: 1 / 0.86;
  }

  .section {
    padding: 64px 0;
  }

  .section-head {
    margin-bottom: 32px;
  }

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

  .voice-chips {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .faq-list {
    padding: 8px 20px;
  }

  .footer {
    margin-top: 28px;
    padding: 32px 0 calc(48px + env(safe-area-inset-bottom, 0px));
  }

  .footer-mail {
    flex-basis: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
  .js .reveal {
    opacity: 1 !important;
    transform: none !important;
  }
}

/* Typografia CJK (JA / KO / ZH): pogrubione nagłówki marketingowe, wygodniejsza interlinia i łamanie słów */
html:lang(ja) {
  --sans: "Instrument Sans", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic UI", "Yu Gothic", "Noto Sans JP", sans-serif;
}

html:lang(ko) {
  --sans: "Instrument Sans", "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", sans-serif;
  word-break: keep-all;
  overflow-wrap: break-word;
}

html:lang(zh-Hans) {
  --sans: "Instrument Sans", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
}

html:lang(zh-Hant) {
  --sans: "Instrument Sans", "PingFang TC", "Hiragino Sans CNS", "Microsoft JhengHei", "Noto Sans TC", sans-serif;
}

html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) body {
  line-height: 1.72;
}

html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) :is(h1, .section-head h2, .split-grid h2, .parent-poster h2) {
  font-family: var(--sans);
  font-weight: 800;
  letter-spacing: 0;
}

html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) h1 {
  font-size: clamp(32px, 4.4vw, 54px);
  line-height: 1.26;
}

html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) h1 .hl {
  padding: 2px 12px 4px;
  margin-left: 0;
}

html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) :is(.section-head h2, .split-grid h2, .parent-poster h2) {
  font-size: clamp(28px, 3.4vw, 42px);
  line-height: 1.28;
}

html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) .doc-card h1 {
  font-size: clamp(28px, 3.8vw, 40px);
  line-height: 1.28;
}

html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) .doc-card p,
html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) .doc-card li {
  line-height: 1.8;
}

html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) .hero-lead {
  line-height: 1.72;
}

html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) .kicker {
  letter-spacing: 0.08em;
}

html:is(:lang(ja), :lang(ko), :lang(zh-Hans), :lang(zh-Hant)) .parent-poster h2 {
  max-width: 24ch;
}

html:lang(ja) :is(h1, h2, h3, .hero-lead, .section-head > p) {
  word-break: auto-phrase;
}
