/* Лэндинг Piligrimun. Язык оформления — самого приложения (shared/design/tokens.json):
   бумага page, чернила ink, янтарь amber, линии line; Unbounded в заголовках, Golos Text
   в тексте, JetBrains Mono в подписях. Земля под пилигримами — карта приложения в стиле
   «Атлас». Одна поверхность сверху донизу. */

:root {
  --page: #F4F2EC; --ink: #14161E; --muted: #6E6A60; --line: #E2DED3; --amber: #F7A81B;
  --card: #FFFFFF; --gap: 20px; --pad: 40px; --r: 28px;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--page); color: var(--ink); font: 400 18px/1.5 "Golos Text", system-ui, sans-serif; }
img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
.wrap { max-width: 1360px; margin: 0 auto; padding: 0 var(--pad); }

.h1, .h2, .h3 { font-family: "Unbounded", system-ui, sans-serif; font-weight: 600; letter-spacing: -0.02em; margin: 0; }
.h1 { font-size: clamp(34px, 4.4vw, 64px); line-height: 1.04; text-wrap: balance; }
.h2 { font-size: clamp(28px, 3vw, 44px); line-height: 1.08; max-width: 16ch; text-wrap: balance; }
.h3 { font-family: "Golos Text", system-ui, sans-serif; font-size: 22px; line-height: 1.25; letter-spacing: -0.01em; }
.lead { font-size: 19px; color: #3A3A40; margin: 0; max-width: 38ch; text-wrap: pretty; }
figcaption, .soon { font: 500 13px/1.45 "JetBrains Mono", ui-monospace, monospace; letter-spacing: 0.02em; color: var(--muted); }

/* Шапка */
.top__in { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.top__brand { display: flex; align-items: center; gap: 10px; font: 600 18px "Unbounded", sans-serif; text-decoration: none; }
.top__brand img { border-radius: 8px; }
.top__home { font-size: 15px; text-decoration: none; }
.top__home:hover, .links a:hover, .foot a:hover { text-decoration: underline; }

/* Первый экран */
.hero__text { display: grid; grid-template-columns: 1.25fr 1fr; gap: 56px; align-items: end; padding-top: 32px; }
.hero__side .lead { margin-bottom: 24px; }
.hero__side .meta { margin: 14px 0 0; font-size: 15px; color: var(--muted); }
.soon { margin: 0 0 10px; }
.badges { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.store-badge--soon { cursor: default; }
.store-badge--soon:hover { transform: none; }

.road { position: relative; height: 430px; margin-top: 8px; }
.road::before {
  content: ""; position: absolute; inset: 0; background: var(--atlas) center / cover;
  -webkit-mask: linear-gradient(transparent, #000 32%, #000 80%, transparent);
  mask: linear-gradient(transparent, #000 32%, #000 80%, transparent);
}
.road__line { position: absolute; left: 0; right: 0; bottom: 64px; border-top: 5px dashed var(--amber); }
.road__row { position: relative; max-width: 1360px; height: 100%; margin: 0 auto; display: grid; grid-template-columns: repeat(4, 1fr); }
.pil { width: 100%; height: 100%; display: block; cursor: grab; outline: none; }
.pil:active { cursor: grabbing; }
.chips { display: none; }

/* Дорога через страницу: пунктир под содержимым, плитки его закрывают, штампы стоят на нём. */
main { position: relative; }
.route { position: absolute; left: 0; top: 0; pointer-events: none; overflow: visible; }
.route path { fill: none; stroke: var(--amber); stroke-width: 5; stroke-dasharray: 15 10; }
.hero, .sec { position: relative; }
.sec__head { position: relative; }
.stamp {
  position: absolute; z-index: 1; width: 124px; height: 124px; border-radius: 50%; background: var(--page);
  left: calc((100% - 56px) * 0.5556 - 150px); top: 50%; transform: translateY(-50%);
}
.stamp--dream { width: 161px; height: 161px; left: calc((100% - 56px) * 0.5556 - 170px); }
.sec__head .h2 { max-width: min(16ch, calc(100% - 170px)); }
.sec--end .sec__head .h2 { max-width: min(16ch, calc(100% - 190px)); }

/* Разделы */
.sec { padding: 120px 0 0; }
.sec__head { display: grid; grid-template-columns: 1.25fr 1fr; gap: 56px; align-items: start; margin-bottom: 40px; }
.sec__head .lead { padding-top: 6px; }
.bento { display: grid; grid-template-columns: repeat(12, 1fr); gap: var(--gap); }
.tile { margin: 0; background: var(--page); border: 1px solid var(--line); border-radius: var(--r); padding: 32px; min-width: 0; }
.tile figcaption, .tile p { margin: 16px 0 0; }
.tile p { color: #3A3A40; }
.tile .h3 + p { margin-top: 10px; max-width: 46ch; }

.tile--phone { display: grid; place-items: center; padding: 48px 24px; }
.tile--map { background: var(--atlas-narrow) center / cover; border-color: transparent; }
.phone { width: min(100%, 292px); background: #16171C; padding: 9px; border-radius: 50px; box-shadow: 0 28px 50px -28px rgba(20, 24, 40, 0.45); }
.phone__screen { overflow: hidden; border-radius: 41px; aspect-ratio: 1320 / 2868; background: var(--page); }
.phone__screen img { width: 100%; height: 100%; object-fit: cover; }
.phone--android { border-radius: 34px; padding: 8px; }
.phone--android .phone__screen { border-radius: 26px; aspect-ratio: 1080 / 2400; }

.bento--pick .tile--phone { grid-column: span 5; }
.tile--born { grid-column: span 7; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.tile--born video { width: min(100%, 640px); aspect-ratio: 1; mix-blend-mode: multiply; }

.bento--send > * { grid-column: span 6; }

.tile--lenses { grid-column: span 12; }
.lenses { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 16px 14px; margin-top: 24px; }
.lens { margin: 0; }
.lens__img, .lens__letters { width: 100%; height: auto; aspect-ratio: 3 / 4; border-radius: 10px; image-rendering: pixelated; }
.lens figcaption { margin-top: 8px; }
.lens__letters {
  margin: 0; overflow: hidden; background: var(--page); color: var(--ink); display: grid; place-content: center;
  font: 500 var(--fs, 6px)/1 "JetBrains Mono", monospace; letter-spacing: 0; white-space: pre;
}

.bento--road { align-items: center; }
.bento--road .tile--phone { grid-column: span 4; }
.tile--ticket { grid-column: span 8; display: grid; place-items: center; background: #F4F3EC; }
.tile--ticket img { width: min(100%, 860px); border-radius: 22px; box-shadow: 0 24px 50px -30px rgba(20, 24, 40, 0.4); }

.bento--work .tile--phone { grid-column: span 4; }
.tile--shoes { grid-column: span 8; display: flex; flex-direction: column; }
.shoes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 20px; margin: auto 0; padding-top: 24px; }
.shoe { margin: 0; text-align: center; }
.shoe img { width: 100%; mix-blend-mode: multiply; }
.shoe figcaption { margin-top: 2px; }

/* Конец: фильм и магазины */
.end { display: grid; grid-template-columns: 5fr 7fr; gap: var(--gap); align-items: center; }
.film { margin: 0; border-radius: var(--r); overflow: hidden; background: #16171C; aspect-ratio: 9 / 16; max-height: 820px; justify-self: start; width: 100%; max-width: 461px; }
.film video { width: 100%; height: 100%; object-fit: cover; }
.end__text { padding: 0 0 0 40px; }
.end__icon { border-radius: 16px; margin-bottom: 20px; }
.end__cta .h3 { font-size: 28px; margin-bottom: 20px; }
.facts { list-style: none; padding: 0; margin: 36px 0 0; display: grid; gap: 10px; font-size: 16px; color: #3A3A40; max-width: 52ch; }
.facts li { padding-left: 22px; position: relative; }
.facts li::before { content: ""; position: absolute; left: 0; top: 0.62em; width: 10px; border-top: 3px dashed var(--amber); }
.links { display: flex; gap: 24px; margin: 28px 0 0; font-size: 15px; }
.sec--end { padding-bottom: 96px; }

.foot { border-top: 1px solid var(--line); }
.foot__row { display: flex; justify-content: space-between; gap: 16px; padding-top: 28px; padding-bottom: 28px; font-size: 14px; color: var(--muted); }
.foot a { text-decoration: none; }

@media (max-width: 1100px) {
  .lenses { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .bento--road .tile--phone, .bento--work .tile--phone { grid-column: span 5; }
  .tile--ticket, .tile--shoes { grid-column: span 7; }
  .end__text { padding-left: 16px; }
}

@media (max-width: 820px) {
  :root { --pad: 16px; --r: 22px; }
  body { font-size: 17px; }
  .top__in { height: 60px; }
  .hero { display: flex; flex-direction: column; }
  .hero__text { display: contents; }
  .hero .h1 { order: 1; padding: 4px var(--pad) 0; }
  .road { order: 2; height: min(52vh, 420px); margin-top: 0; }
  .road::before { background-image: var(--atlas-narrow); }
  .road__row { grid-template-columns: 1fr; }
  .road__row .pil:not(:first-child) { display: none; }
  .road__line { bottom: 13%; }
  .chips { order: 3; display: flex; justify-content: center; gap: 6px; margin: 6px var(--pad) 0; flex-wrap: wrap; }
  .chips button { font: 500 13px "JetBrains Mono", monospace; letter-spacing: 0.02em; border: 1px solid var(--line); background: var(--card); color: var(--ink); border-radius: 99px; padding: 9px 13px; cursor: pointer; }
  .chips button[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }
  .hero__side { order: 4; padding: 24px var(--pad) 0; }
  .lead { font-size: 17px; }

  .sec { padding-top: 80px; }
  .sec__head { grid-template-columns: 1fr; gap: 14px; margin-bottom: 24px; }
  .stamp { width: 74px; height: 74px; left: auto; right: 0; top: -80px; transform: none; }
  .stamp--dream { width: 96px; height: 96px; top: -102px; }
  .sec--end { padding-top: 112px; }
  .sec__head .h2, .sec--end .sec__head .h2 { max-width: none; }
  .route { display: none; }  /* на узком экране линия шла бы по тексту: остаются одни штампы */
  .bento > *, .bento--send > *, .bento .tile { grid-column: span 12; }
  .tile { padding: 24px; }
  .tile--phone { padding: 36px 16px; }
  .phone { width: min(100%, 280px); border-radius: 46px; padding: 8px; }
  .phone__screen { border-radius: 36px; }
  .phone--android { border-radius: 30px; }
  .phone--android .phone__screen { border-radius: 23px; }
  .lenses { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 10px; }
  .end { grid-template-columns: 1fr; }
  .film { max-width: 360px; justify-self: center; }
  .end__text { padding: 24px 0 0; }
  .foot__row { flex-direction: column; }
}

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