/* «Ярус» — вся страница в стиле плаката-коллажа (как история с Моной Лизой).
   Жёлтый #fbd530, графит #17181c, газетная бумага #efe9d8. Растр, бумажные вырезки, стекло, крупная типографика.
   Без «наплывов»: блоки не появляются из прозрачности, движение ведёт прокрутка (poster.js). Подключается последним. */

:root {
  --pz-sun: #fbd530;
  --pz-ink: #17181c;
  --pz-news: #efe9d8;
  --pz-paper: #f6f0de;
}

/* ---------- никаких наплывов */
.v3-reveal, .v3-reveal.is-visible { opacity: 1 !important; transform: none !important; transition: none !important; }

/* ---------- фон разделов: жёлтый / графит / газета по очереди */
main > section#call,
main > section#ticket,
main > section#connect,
main > section#price { background: var(--pz-sun) !important; color: var(--pz-ink) !important; }
main > section#desk,
main > section#resident,
main > section#faq { background: var(--pz-ink) !important; color: #fbfaf6 !important; }
main > section#master,
main > section#modes,
main > section#start { background: var(--pz-news) !important; color: var(--pz-ink) !important; }

/* растр поверх цветных разделов */
main > section:is(#call, #ticket, #connect, #price, #master, #modes, #start, #desk, #resident, #faq) { position: relative; isolation: isolate; }
main > section:is(#call, #ticket, #connect, #price, #master, #modes, #start, #desk, #resident, #faq)::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image: radial-gradient(circle, rgb(0 0 0 / 16%) 0 1px, transparent 1.5px);
  background-size: 6px 6px;
}
main > section:is(#desk, #resident, #faq)::after { background-image: radial-gradient(circle, rgb(251 250 246 / 7%) 0 1px, transparent 1.5px); }

/* ---------- заголовки-плакаты */
main > section:not(.hero):not(.story) h2 {
  font-family: "Onest", system-ui, sans-serif !important;
  font-weight: 900 !important;
  font-size: clamp(40px, 5.6vw, 96px) !important;
  line-height: .92 !important;
  letter-spacing: -.05em !important;
  text-transform: none;
  max-width: 14ch;
  color: inherit !important;
}
main > section:is(#desk, #resident, #faq) h2 { color: #fbfaf6 !important; }
main > section:is(#desk, #resident, #faq) h2 .muted,
main > section h2 .muted { color: transparent !important; -webkit-text-stroke: 1.5px currentColor; }
main > section#desk h2 { max-width: 16ch; }
/* номер раздела, как на постерах: маленькая подпись над заголовком */
main { counter-reset: pz; }
main > section:not(.hero):not(.story):not(.tiles) { counter-increment: pz; }
main > section:not(.hero):not(.story):not(.tiles) h2::before {
  content: "№ " counter(pz, decimal-leading-zero);
  display: block;
  margin-bottom: 18px;
  font: 700 13px/1 ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  letter-spacing: .18em;
  -webkit-text-stroke: 0;
  color: currentColor;
  opacity: .7;
}

/* ---------- кнопки на жёлтом: чёрные */
main > section:is(#call, #ticket, #connect, #price) .btn--primary {
  background: var(--pz-ink) !important;
  color: var(--pz-sun) !important;
  border-color: var(--pz-ink) !important;
}
main > section:is(#call, #ticket, #connect, #price) .btn--secondary { border-color: var(--pz-ink) !important; color: var(--pz-ink) !important; background: transparent !important; }

/* ---------- бумага и стекло */
.pz-paper,
main > section#call .st,
main > section#ticket .step-card,
main > section#faq .faq__item,
main > section#start .form-box,
main > section#price .calc,
main > section#price .leave {
  background: var(--pz-paper) !important;
  color: var(--pz-ink) !important;
  border: 0 !important;
  border-radius: 4px !important;
  box-shadow: 0 18px 30px -18px rgb(0 0 0 / 45%), 0 2px 0 rgb(0 0 0 / 6%) !important;
  clip-path: polygon(0 1.5%, 3% 0, 47% 1%, 52% 0, 97% .8%, 100% 2.5%, 99.4% 50%, 100% 97%, 96% 100%, 50% 99.2%, 3% 100%, 0 98%, .6% 50%);
}
main > section#faq .faq__item h3,
main > section#faq .faq__item p { color: var(--pz-ink) !important; }
main > section#ticket .step-card:nth-child(odd) { rotate: -1.4deg; }
main > section#ticket .step-card:nth-child(even) { rotate: 1.2deg; }
main > section#faq .faq__item:nth-child(3n+1) { rotate: -.8deg; }
main > section#faq .faq__item:nth-child(3n+2) { rotate: .7deg; }
main > section#call .st:nth-child(2) { rotate: .8deg; }
main > section#call .st:nth-child(3) { rotate: -.7deg; }

/* стеклянные плашки на тёмном: экраны программы, платёжка */
main > section#desk .desk-frame,
main > section#resident .resident-frame,
main > section#call .call-frame {
  background: rgb(251 250 246 / 8%) !important;
  border: 1px solid rgb(251 250 246 / 18%) !important;
  -webkit-backdrop-filter: blur(16px) saturate(130%);
  backdrop-filter: blur(16px) saturate(130%);
  border-radius: 22px !important;
}
main > section#call .call-frame { background: var(--pz-ink) !important; }

/* ---------- скотч на углах бумажных карточек */
main > section#start .form-box,
main > section#price .calc { position: relative; overflow: visible !important; }
main > section#start .form-box::before,
main > section#price .calc::before {
  content: "";
  position: absolute;
  top: -12px;
  left: 50%;
  width: 120px;
  height: 28px;
  margin-left: -60px;
  rotate: -3deg;
  background: rgb(251 213 48 / 78%);
  box-shadow: 0 2px 6px rgb(0 0 0 / 12%);
  clip-path: polygon(2% 0, 98% 6%, 100% 100%, 0 94%);
}

/* ---------- вырезки людей вместо фото в рамке */
.pz-cut { background: transparent !important; border: 0 !important; box-shadow: none !important; overflow: visible !important; aspect-ratio: auto !important; height: auto !important; }
.pz-cut img { position: static !important; width: 100% !important; height: auto !important; object-fit: contain !important; filter: drop-shadow(0 26px 30px rgb(0 0 0 / 28%)); }
main > section#master .pz-cut img { rotate: 2.5deg; }
main > section#modes .pz-cut img { rotate: -2deg; }

/* ---------- 3D-ноутбук в разделе диспетчера */
.pz-3d { position: relative; width: 100%; aspect-ratio: 16 / 10; margin: 8px 0 32px; }
.pz-3d canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.pz-3d.no-webgl { display: none; }

/* ---------- плитки обзора: плакатные */
main > section.tiles .tile__title { font-weight: 900 !important; letter-spacing: -.045em !important; }
main > section.tiles .tile--light { background: var(--pz-sun) !important; }
main > section.tiles .tile--light .tile__link { color: var(--pz-ink) !important; font-weight: 700; }
main > section.tiles .tile .tile__pic--photo img { object-fit: contain !important; object-position: 50% 100% !important; }

/* ---------- цены: крупно */
main > section#price .rows__value { font-weight: 900 !important; font-size: clamp(34px, 3.4vw, 56px) !important; letter-spacing: -.04em !important; color: var(--pz-ink) !important; line-height: 1 !important; }
main > section#price, main > section#price * { --v3-paper: var(--pz-ink); }
main > section#price :is(.rows__name, .rows li p, .price-note, .price-guilt, .price-new) { color: var(--pz-ink) !important; }
main > section#price .price-free { background: var(--pz-ink) !important; color: var(--pz-sun) !important; border: 0 !important; }
main > section#price .price-free b { color: var(--pz-sun) !important; }
main > section#price .rows > li { border-bottom-color: rgb(23 24 28 / 22%) !important; }

/* подвал */
footer.closing h2 { font-weight: 900 !important; letter-spacing: -.05em !important; font-size: clamp(44px, 6vw, 104px) !important; line-height: .92 !important; }

@media (max-width: 760px) {
  main > section:not(.hero):not(.story) h2 { font-size: clamp(36px, 10.5vw, 52px) !important; }
  main > section#ticket .step-card,
  main > section#faq .faq__item { rotate: 0deg !important; }
}

/* тёмные разделы: весь текст светлый (кроме бумажных карточек и экранов) */
main > section:is(#desk, #resident, #faq) :is(.resident-text, .desk-head, .faq-head) :is(p, li, span, a, b, small, .rows__name) { color: rgb(251 250 246 / 84%) !important; }
main > section:is(#desk, #resident, #faq) :is(.resident-text, .desk-head, .faq-head) .rows__name { color: #fbfaf6 !important; font-weight: 700; }
main > section#resident .resident-text .link { color: var(--pz-sun) !important; }

/* ================================================================ ПЕРВЫЙ ЭКРАН — плакат */
main > section.pz-hero {
  position: relative;
  height: auto !important;
  min-height: 100vh;
  min-height: 100svh;
  padding: calc(var(--v3-nav, 72px) + 4vh) 0 4vh !important;
  background: var(--pz-sun) !important;
  color: var(--pz-ink) !important;
  overflow: clip;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  isolation: isolate;
}
.pz-hero__dots {
  position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image: radial-gradient(circle, rgb(0 0 0 / 15%) 0 1px, transparent 1.5px);
  background-size: 6px 6px;
}
main > section.pz-hero > .wrap { height: auto !important; display: grid !important; }
.pz-hero__grid { grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); align-items: center; gap: 24px; flex: 1 0 auto; }
.pz-hero__text { display: grid; gap: 22px; justify-items: start; }
.pz-hero__meta { display: flex; gap: 22px; margin: 0; font: 700 13px/1 ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace; letter-spacing: .18em; text-transform: uppercase; }
.pz-hero__meta span + span::before { content: "/"; margin-right: 22px; opacity: .5; }
main > section.pz-hero .hero-notice { margin: 0; font: 600 18px/1.35 "Onest", system-ui, sans-serif; color: var(--pz-ink) !important; max-width: 34ch; }
main > section.pz-hero h1 {
  margin: 0;
  font-family: "Onest", system-ui, sans-serif !important;
  font-weight: 900 !important;
  font-size: clamp(52px, 7.6vw, 138px) !important;
  line-height: .88 !important;
  letter-spacing: -.055em !important;
  color: var(--pz-ink) !important;
  max-width: 11ch;
}
.pz-hero__lead {
  margin: 0;
  max-width: 50ch;
  padding: 16px 20px;
  font: 500 17px/1.5 "Onest", system-ui, sans-serif !important;
  color: var(--pz-ink) !important;
  background: var(--pz-paper);
  box-shadow: 0 16px 26px -18px rgb(0 0 0 / 45%);
  rotate: -.6deg;
  clip-path: polygon(0 3%, 2% 0, 50% 2%, 98% 0, 100% 4%, 99.5% 50%, 100% 96%, 97% 100%, 50% 98%, 2% 100%, 0 96%, .5% 50%);
}
main > section.pz-hero .btn--primary { background: var(--pz-ink) !important; color: var(--pz-sun) !important; border-color: var(--pz-ink) !important; }
main > section.pz-hero .btn--secondary { background: transparent !important; color: var(--pz-ink) !important; border: 1.5px solid var(--pz-ink) !important; }

.pz-hero__art { position: relative; height: min(74vh, 720px); min-height: 420px; }
.pz-hero__phone { position: absolute; inset: 0; }
.pz-hero__phone canvas, .pz-nokia canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.pz-hero__ring {
  position: absolute; left: 50%; top: 50%; width: 78%; aspect-ratio: 1; translate: -50% -50%;
  border: 2px solid var(--pz-ink); border-radius: 50%; opacity: .5;
}
.pz-hero__ring + .pz-hero__ring { width: 98%; opacity: .25; border-style: dashed; }
@media (prefers-reduced-motion: no-preference) {
  .pz-hero__ring { animation: pz-ring 2.6s cubic-bezier(.2, .7, .3, 1) infinite; }
  .pz-hero__ring + .pz-hero__ring { animation-delay: 1.3s; }
  @keyframes pz-ring { 0% { scale: .78; opacity: .55; } 100% { scale: 1.12; opacity: 0; } }
}
.pz-hero__tag {
  position: absolute; right: 0; bottom: 6%; margin: 0; max-width: 16ch;
  padding: 10px 14px; background: var(--pz-ink); color: var(--pz-sun);
  font: 800 16px/1.2 "Onest", system-ui, sans-serif; rotate: 3deg;
}
.pz-nokia.no-webgl canvas { display: none; }

/* три входа — бумажные полоски */
main > section.pz-hero .fit-strip { display: grid !important; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 22px; position: static !important; }
main > section.pz-hero a.fit {
  background: var(--pz-paper) !important; color: var(--pz-ink) !important; border: 0 !important; border-radius: 3px !important;
  box-shadow: 0 14px 22px -16px rgb(0 0 0 / 45%);
  clip-path: polygon(0 4%, 3% 0, 97% 2%, 100% 6%, 99% 94%, 96% 100%, 3% 98%, 0 94%);
}
main > section.pz-hero a.fit:nth-child(2) { rotate: .8deg; }
main > section.pz-hero a.fit:nth-child(3) { rotate: -.6deg; }
main > section.pz-hero a.fit b { color: var(--pz-ink) !important; }
main > section.pz-hero a.fit b::after { color: var(--pz-ink) !important; }
main > section.pz-hero a.fit span { color: rgb(23 24 28 / 72%) !important; }
main > section.pz-hero a.fit:hover { background: #fff !important; }

/* чертёж модема */
.tile__pic--bp { margin: 0; inset: auto 6% 6% 6% !important; height: auto !important; }
.tile__pic--bp img { width: 100%; height: auto !important; object-fit: contain !important; box-shadow: 0 20px 34px -20px rgb(0 0 0 / 60%); rotate: -1.5deg; }
.tile--dark .tile__pic--bp::before { display: none; }
.pz-bp { background: var(--pz-news) !important; padding: 0 !important; min-height: 0 !important; }
.pz-bp img { position: static !important; width: 100% !important; height: auto !important; object-fit: contain !important; }

@media (max-width: 900px) {
  .pz-hero__grid { grid-template-columns: 1fr; }
  .pz-hero__art { height: 62vh; min-height: 360px; order: 2; }
  main > section.pz-hero .fit-strip { grid-template-columns: 1fr; }
  main > section.pz-hero a.fit span { display: none !important; }
}
@media (max-width: 640px) {
  main > section.pz-hero h1 { font-size: clamp(44px, 13vw, 64px) !important; }
  .pz-hero__lead { font-size: 15px !important; }
  .pz-hero__art { height: 52vh; min-height: 320px; }
  .pz-hero__tag { font-size: 14px; bottom: 2%; }
}
/* чертёж в плитке — в потоке, под текстом, не поверх */
main > section.tiles .tile .tile__pic--bp { position: relative !important; inset: auto !important; margin: auto 0 34px; width: 92%; height: auto !important; z-index: 1; }
/* съезжающие сбоку карточки не должны раздвигать страницу */
main > section { overflow-x: clip; }
