/* =========================================================================
   SmartTicket.City — main stylesheet
   Layout widths mirror the original design: 1160px content column
   (1200px with gutters). Breakpoints: 1199 / 959 / 767 / 639 / 479.
   ========================================================================= */

/* ---------- Tokens ---------- */
:root {
  --c-black: #000;
  --c-white: #fff;
  --c-yellow: #ffc750;
  --c-yellow-strong: #ffc000;
  --c-blue: #0070c0;
  --c-red: #ff0000;
  --c-accent: #ff5252;      /* menu hover / active */
  --c-link-hover: #219fff;  /* footer link hover */
  --c-line: #e6e6e6;

  --font-main: "Roboto", Arial, sans-serif;
  --font-alt: Arial, "Helvetica Neue", Helvetica, sans-serif;

  --container: 1160px;
  --gutter: 20px;
  --header-h: 70px;

  --edge-shadow: 0 0 40px rgba(0, 0, 0, .3);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
}

body {
  margin: 0;
  font-family: var(--font-main);
  font-size: 18px;
  line-height: 1.55;
  color: var(--c-black);
  background: var(--c-white);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }

/* ---------- Layout helpers ---------- */
.container {
  width: 100%;
  max-width: calc(var(--container) + 2 * var(--gutter));
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section-title {
  font-family: var(--font-alt);
  font-size: 40px;
  font-weight: 700;
  line-height: 1.55;
  text-align: center;
}

/* Soft "seam" shadows between sections, as in the original design.
   A pseudo element sits just outside the section and only its shadow
   (clipped by overflow:hidden) is visible inside. */
.edge-shadow-top,
.edge-shadow-bottom { position: relative; overflow: hidden; }

.edge-shadow-top::before,
.edge-shadow-bottom::after {
  content: "";
  position: absolute;
  left: -50px;
  right: -50px;
  height: 50px;
  box-shadow: var(--edge-shadow);
  z-index: 5;
  pointer-events: none;
}
.edge-shadow-top::before { bottom: 100%; }
.edge-shadow-bottom::after { top: 100%; }

/* =========================================================================
   HEADER
   ========================================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--c-white);
}

.site-header__inner {
  display: flex;
  align-items: center;
  gap: 40px;
  height: var(--header-h);
  padding: 0 40px;
}

.site-header__logo { flex: none; }
.site-header__logo img { width: 120px; }

.site-header__brand { display: none; }

.main-nav { margin-left: auto; }

.main-nav ul {
  display: flex;
  align-items: center;
  gap: 24px;
}

.main-nav a {
  display: block;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.2;
  white-space: nowrap;
  transition: color .3s ease-in-out;
}

.main-nav a:hover,
.main-nav a.is-active { color: var(--c-accent); }

.burger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 28px;
  height: 20px;
  margin-left: auto;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
}

.burger span {
  display: block;
  height: 3px;
  background: currentColor;
  transition: transform .25s, opacity .25s;
}

.site-header.is-open .burger span:nth-child(1) { transform: translateY(8.5px) rotate(45deg); }
.site-header.is-open .burger span:nth-child(2) { opacity: 0; }
.site-header.is-open .burger span:nth-child(3) { transform: translateY(-8.5px) rotate(-45deg); }

/* =========================================================================
   HERO
   ========================================================================= */
.hero {
  --hero-h: 590px;
  height: var(--hero-h);
  background: var(--c-white);
}

.hero__photo {
  position: absolute;
  top: -33px;
  left: calc(50% - 1330px);
  width: 1460px;
  max-width: none;
}

.hero__panel {
  position: absolute;
  inset: 0;
  background: var(--c-yellow);
  clip-path: polygon(calc(50% - 83px) 0, 100% 0, 100% 100%, calc(50% + 127px) 100%);
}

.hero__content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  justify-content: center;
  height: 100%;
  padding-bottom: 24px;
  text-align: right;
}

.hero__title {
  font-family: var(--font-alt);
  font-size: 40px;
  font-weight: 700;
  line-height: 1.15;
}

.hero__subtitle {
  margin-top: 36px;
  font-family: var(--font-alt);
  font-size: 24px;
  line-height: 1.5;
}

/* =========================================================================
   LED TICKER
   ========================================================================= */
.led {
  --led-h: 212px;
  position: relative;
  height: var(--led-h);
  overflow: hidden;
  background: #111 url("../img/led-panel.webp") center / auto 141% no-repeat;
}

.led__text {
  position: absolute;
  top: 50%;
  left: 100%;
  width: auto;
  max-width: none;
  height: 59%;
  animation: led-run 13.2s linear infinite;
  will-change: transform;
}

@keyframes led-run {
  0%   { transform: translate(0, -50%); opacity: 1; }
  92%  { transform: translate(calc(-100vw - 100%), -50%); opacity: 1; }
  93%  { transform: translate(calc(-100vw - 100%), -50%); opacity: 0; }
  99%  { transform: translate(0, -50%); opacity: 0; }
  100% { transform: translate(0, -50%); opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .led__text { animation: none; left: 0; transform: translateY(-50%); }
}

/* =========================================================================
   HOW TO USE
   ========================================================================= */
.how-to {
  --how-w: 1541px;
  height: calc(var(--how-w) * .489);
}

.how-to__image {
  position: absolute;
  top: 0;
  left: 50%;
  width: var(--how-w);
  max-width: none;
  transform: translateX(-50%);
}

.how-to__content { position: relative; z-index: 1; }

.how-to__title {
  max-width: 600px;
  padding: 100px 0 0 30px;
  font-size: 40px;
  font-weight: 700;
  line-height: 1.55;
}

/* ---------- Steps ---------- */
.steps { padding: 25px 0 85px; }

.steps__list {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  counter-reset: step;
}

/* connecting line through the numbered circles */
.steps__list::before {
  content: "";
  position: absolute;
  top: 16px;
  left: 18px;
  right: calc((100% - 80px) / 3 - 26px);
  height: 2px;
  background: var(--c-line);
}

.step {
  position: relative;
  font-family: var(--font-alt);
  font-size: 18px;
  line-height: 1.5;
}

.step::before {
  counter-increment: step;
  content: counter(step);
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 35px;
  height: 35px;
  margin-bottom: 18px;
  border: 1px solid var(--c-white);
  border-radius: 50%;
  font-size: 16px;
  font-weight: 700;
  color: var(--c-white);
  background: var(--step-color);
}

.step--red    { --step-color: var(--c-red); }
.step--blue   { --step-color: var(--c-blue); }
.step--yellow { --step-color: var(--c-yellow-strong); }

.step__title {
  min-height: 3.1em;          /* two lines – keeps texts aligned across columns */
  margin-bottom: 13px;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.55;
}

.step p + p { margin-top: 1.5em; }

/* =========================================================================
   CITY CARD PROMO
   ========================================================================= */
.card-promo {
  height: 550px;
  background: var(--c-blue);
}

.card-promo__photo {
  position: absolute;
  top: 0;
  left: calc(50% - 960px);
  width: 993px;
  height: 100%;
  max-width: none;
  object-fit: cover;
}

.card-promo__panel {
  position: absolute;
  inset: 0;
  background: var(--c-blue);
  clip-path: polygon(calc(50% + 15px) 0, 100% 0, 100% 100%, calc(50% - 165px) 100%);
}

.card-promo__inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr 510px;
  align-items: center;
  gap: 40px;
  height: 100%;
}

.card-promo__card { padding-left: 54px; }
.card-promo__card img { width: 510px; }

.card-promo__text {
  color: var(--c-white);
  font-size: 20px;
  line-height: 1.55;
}

.card-promo__title {
  font-size: 32px;
  font-weight: 700;
  line-height: 1.55;
}

/* =========================================================================
   ABOUT
   ========================================================================= */
.about {
  padding: 85px 0 110px;
  color: var(--c-white);
  background: var(--c-blue);
}

.about__title {
  max-width: 1104px;
  margin: 0 auto;
  padding: 14px 20px;
  border: 5px solid var(--c-white);
  font-size: 40px;
  font-weight: 700;
  line-height: 1.55;
  text-align: center;
}

.about__cols {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
  margin-top: 55px;
}

.about__subtitle {
  min-height: 3.1em;          /* two lines – aligns both lists */
  margin-bottom: 39px;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.55;
}

.about__col { font-size: 20px; line-height: 1.55; }
.about__col > .dot-list { max-width: 500px; }

.about__groups > li {
  position: relative;
  padding-left: 30px;
}

.about__groups > li + li { margin-top: 32px; }

.about__groups > li::before {        /* yellow square marker */
  content: "";
  position: absolute;
  top: 8px;
  left: 2px;
  width: 14px;
  height: 14px;
  background: var(--c-yellow-strong);
}

.about__groups strong { display: block; font-weight: 700; }

.about__groups .dot-list { margin-top: 14px; padding-left: 30px; }

.dot-list > li::before { content: "• "; }
.dot-list--spaced > li + li { margin-top: 1.55em; }

/* =========================================================================
   MOBILE APP
   ========================================================================= */
.app {
  padding: 80px 0 100px;
  background: var(--c-white);
}

.app__panel {
  position: absolute;
  inset: 0;
  background: var(--c-yellow);
  clip-path: polygon(calc(50% + 60px) 0, 100% 0, 100% 100%, calc(50% - 82px) 100%);
}

.app .container { position: relative; z-index: 1; }

.app__body {
  display: grid;
  grid-template-columns: 600px 1fr;
  align-items: center;
  margin-top: 80px;
}

.features {
  display: grid;
  gap: 43px;
  font-family: var(--font-alt);
}

.feature {
  display: grid;
  grid-template-columns: 65px 1fr;
  gap: 30px;
  align-items: start;
  max-width: 560px;
}

.feature__icon { width: 65px; margin-top: 6px; }

.feature__title {
  margin-bottom: 10px;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.55;
}

.feature p { font-size: 16px; line-height: 1.55; }

.app__phone { justify-self: center; }
.app__phone img { width: 245px; }

/* =========================================================================
   HARDWARE
   ========================================================================= */
.hardware { padding: 67px 0 120px; }


.hardware__body {
  display: grid;
  grid-template-columns: 706px 400px;
  justify-content: space-between;
  align-items: center;
  margin-top: 60px;
}

.hardware__grid {
  display: grid;
  grid-template-columns: repeat(3, 200px);
  justify-content: space-between;
  row-gap: 20px;
}

.device {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.55;
  text-align: center;
}

.device img { width: 200px; }
.device span,
.device figcaption { margin-top: -6px; }

.device--scheme img { width: 400px; }
.device--scheme figcaption { max-width: 240px; margin-top: 0; }

/* =========================================================================
   PARTNERS
   ========================================================================= */
.partners { padding: 150px 0 110px; }

.partners__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-auto-rows: minmax(132px, auto);
  gap: 16px;
  margin-top: 60px;
}

/* card */
.partner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  min-width: 0;
  padding: 22px 26px;
  overflow: hidden;
  border: 1px solid rgba(184, 198, 213, .78);
  border-radius: 8px;
  background: var(--c-white);
  box-shadow: 0 1px 2px rgba(15, 23, 42, .06);
  transition: border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.partner::before {                    /* blue → yellow accent line */
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 3px;
  background: linear-gradient(90deg, var(--c-blue), var(--c-yellow-strong));
  opacity: .72;
}

.partner:hover {
  border-color: rgba(0, 112, 192, .28);
  box-shadow: 0 16px 36px rgba(15, 23, 42, .09);
  transform: translateY(-2px);
}

.partner img { width: auto; object-fit: contain; }

.partner__logo--voznesensk { max-width: 178px; max-height: 96px; }
.partner__logo--renome     { max-width: 246px; max-height: 64px; }
.partner__logo--visa       { max-width: 278px; max-height: 64px; }
.partner__logo--kyivstar   { max-width: 196px; max-height: 48px; }

.partner__emblem { flex: none; }
.partner__emblem--cherkasy { width: 56px; height: 56px; }
.partner__emblem--lviv     { max-width: 58px; max-height: 76px; }

.partner__name {
  min-width: 0;
  max-width: 230px;
  font-size: clamp(17px, 1.55vw, 22px);
  font-weight: 700;
  line-height: 1.16;
  color: #111827;
}

.partner__name--small {
  max-width: 238px;
  font-size: clamp(14px, 1.18vw, 17px);
  line-height: 1.22;
}

@media (prefers-reduced-motion: reduce) {
  .partner, .partner:hover { transition: none; transform: none; }
}

/* =========================================================================
   CERTIFICATES
   ========================================================================= */
.certificates { padding: 130px 0 95px; }

.certificates__grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 20px;
  margin-top: 90px;
}

.certificates__grid a {
  display: block;
  cursor: zoom-in;
  transition: transform .2s ease;
}

.certificates__grid a:hover { transform: scale(1.03); }

/* lightbox (created by js/main.js) */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px;
  background: rgba(255, 255, 255, .95);
  cursor: zoom-out;
}

.lightbox img {
  max-height: 100%;
  width: auto;
  box-shadow: 0 10px 40px rgba(0, 0, 0, .2);
}

.lightbox[hidden] { display: none; }

/* =========================================================================
   NEXT STEP
   ========================================================================= */
.next-step {
  color: var(--c-white);
  background: var(--c-blue);
}

.next-step__inner {
  display: grid;
  grid-template-columns: minmax(0, 667px) minmax(0, 500px);
  justify-content: space-between;
  align-items: center;
  min-height: 546px;
  padding-top: 30px;
  padding-bottom: 30px;
}

.next-step__image { width: calc(100% + 20px); margin-left: -20px; }

.next-step__text { font-size: 28px; line-height: 1.55; }

.next-step__title {
  margin-bottom: 15px;
  font-size: 32px;
  font-weight: 700;
  line-height: 1.55;
}

/* =========================================================================
   SUPPORT / CONTACTS
   ========================================================================= */
.support { background: var(--c-white); }

.support__inner {
  display: grid;
  grid-template-columns: 578px 1fr;
  min-height: 497px;
}

.support__text {
  align-self: center;
  padding: 40px 0;
  font-size: 20px;
  line-height: 1.55;
}

.support__title {
  margin-bottom: 16px;
  font-size: 40px;
  font-weight: 700;
  line-height: 1.55;
}

.support__contacts { margin-top: 16px; }
.support__contacts dt { font-weight: 700; }
.support__contacts dd { margin-top: 6px; font-weight: 700; }
.support__contacts dd + dt { margin-top: 20px; }
.support__contacts a { color: var(--c-blue); }
.support__contacts a:hover { text-decoration: underline; }

.support__photo {
  align-self: end;
  width: 602px;
}

/* =========================================================================
   FOOTER
   ========================================================================= */
.site-footer {
  padding: 60px 0 50px;
  color: var(--c-white);
  background: var(--c-black);
}

.site-footer__cols {
  display: grid;
  grid-template-columns: repeat(3, 300px) 1fr;
  align-items: start;
}

.site-footer h3 {
  margin-bottom: 26px;
  font-size: 24px;
  font-weight: 700;
  line-height: 1.55;
}

.site-footer a { transition: color .2s; }
.site-footer a:hover { color: var(--c-link-hover); }

.site-footer__nav ul {
  display: grid;
  gap: 20px;
  font-size: 16px;
  line-height: 1.25;
}

.site-footer dl { font-size: 18px; line-height: 1.25; }
.site-footer dt { font-weight: 700; }
.site-footer dd { margin-top: 9px; }
.site-footer dd + dt { margin-top: 18px; }

.site-footer__docs {
  display: grid;
  gap: 14px;
  margin-top: 26px;
  font-family: var(--font-alt);
  font-size: 18px;
  line-height: 1.25;
}

.site-footer__logo {
  justify-self: end;
  align-self: end;
  margin-bottom: 12px;
}
.site-footer__logo img { width: 260px; }

.site-footer__copy {
  margin-top: 70px;
  font-size: 18px;
  line-height: 1.5;
  text-align: center;
  opacity: .6;
}

/* =========================================================================
   RESPONSIVE
   ========================================================================= */

/* ---- compact desktop menu ---- */
@media (max-width: 1365px) {
  .site-header__inner { gap: 24px; padding: 0 30px; }
  .main-nav ul { gap: 16px; }
  .main-nav a { font-size: 15px; }
}

/* ---- burger menu ---- */
@media (max-width: 1279px) {
  .burger { display: flex; }

  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    padding: 10px 0 20px;
    background: var(--c-white);
    box-shadow: 0 10px 20px rgba(0, 0, 0, .08);
  }

  .site-header.is-open .main-nav { display: block; }

  .main-nav ul { flex-direction: column; gap: 0; }
  .main-nav a { padding: 10px 20px; font-size: 16px; text-align: center; white-space: normal; }
}

@media (max-width: 1199px) {
  .hero { --hero-h: 521px; }
  .hero__photo { top: -17px; left: calc(50% - 1090px); width: 1290px; }
  .hero__panel { clip-path: polygon(calc(50% - 53px) 0, 100% 0, 100% 100%, calc(50% + 132px) 100%); }
  .hero__title { font-size: 32px; line-height: 1.17; }
  .hero__subtitle { margin-top: 30px; font-size: 22px; }

  .led { --led-h: 125px; background-size: auto 144%; }
  .led__text { height: 60%; }

  .how-to { --how-w: 1331px; }
  .how-to__title { font-size: 32px; }

  .card-promo { height: 480px; }
  .card-promo__inner { grid-template-columns: 1fr 440px; }
  .card-promo__card { padding-left: 0; }
  .card-promo__card img { width: 440px; }
  .card-promo__title { font-size: 24px; }
  .card-promo__text { font-size: 18px; }

  .about__title { font-size: 32px; }
  .about__subtitle { font-size: 23px; }
  .about__col { font-size: 18px; }

  .section-title { font-size: 32px; }
  .app__panel { clip-path: polygon(58% 0, 100% 0, 100% 100%, 50% 100%); }
  .app__body { grid-template-columns: 50% 50%; }
  .feature { padding-right: 20px; }
  .feature__title { font-size: 24px; }

  .hardware__body { grid-template-columns: minmax(0, 1fr) 320px; gap: 40px; }
  .hardware__grid { grid-template-columns: repeat(3, minmax(0, 170px)); }
  .device img { width: 100%; max-width: 170px; }
  .device--scheme img { width: 320px; max-width: 100%; }

  .next-step__text { font-size: 24px; }

  .support__inner { grid-template-columns: 1fr 480px; }
  .support__title { font-size: 32px; }
  .support__photo { width: 480px; }

  .site-footer__cols { grid-template-columns: repeat(3, 1fr); gap: 30px; }
  .site-footer__logo { grid-column: 1 / -1; margin-top: 10px; }
}

/* ---- tablet: mobile header bar (as in the original) ---- */
@media (max-width: 959px) {
  :root { --header-h: 62px; }

  .site-header { color: var(--c-white); background: #111; }
  .site-header__inner { height: var(--header-h); padding: 0 20px; }
  .site-header__logo { display: none; }
  .site-header__brand {
    display: block;
    font-size: 16px;
    font-weight: 700;
    text-transform: uppercase;
  }
  .main-nav { color: var(--c-black); }

  .hero { --hero-h: 400px; }
  .hero__photo { top: -40px; left: calc(50% - 1040px); width: 1153px; }
  .hero__panel { clip-path: polygon(calc(50% - 40px) 0, 100% 0, 100% 100%, calc(50% + 105px) 100%); }
  .hero__title { font-size: 24px; }
  .hero__subtitle { margin-top: 22px; font-size: 20px; }

  .led { --led-h: 60px; background-size: auto 163%; }
  .led__text { height: 68%; }

  .how-to { --how-w: 931px; }
  .how-to__title { max-width: 360px; padding: 60px 0 0 20px; font-size: 24px; }

  .card-promo__inner { grid-template-columns: 1fr 1fr; gap: 30px; }
  .card-promo__card img { width: 100%; }
  .card-promo__panel { clip-path: polygon(calc(50% + 35px) 0, 100% 0, 100% 100%, calc(50% - 100px) 100%); }

  .about__title { font-size: 24px; }
  .about__subtitle { font-size: 20px; }
  .about__col { font-size: 16px; }
  .about__groups > li::before { top: 5px; }

  .section-title { font-size: 24px; }
  .app { padding-top: 60px; }
  .app__body { margin-top: 60px; }
  .app__phone img { width: 200px; }
  .feature { gap: 20px; grid-template-columns: 50px 1fr; }
  .feature__icon { width: 50px; }
  .feature__title { font-size: 20px; line-height: 1.45; }

  .hardware__body { grid-template-columns: minmax(0, 1fr) 260px; gap: 24px; }
  .device--scheme img { width: 260px; max-width: 100%; }
  .device { font-size: 17px; }

  .partners { padding: 110px 0 90px; }
  .partners__grid { margin-top: 50px; }

  .certificates { padding: 100px 0 80px; }
  .certificates__grid { margin-top: 60px; gap: 12px; }

  .next-step__inner { grid-template-columns: 1fr 1fr; gap: 30px; min-height: 0; padding-top: 60px; padding-bottom: 60px; }
  .next-step__image { width: 100%; margin-left: 0; }
  .next-step__title { font-size: 26px; }
  .next-step__text { font-size: 20px; }

  .support__inner { grid-template-columns: 1fr 340px; }
  .support__title { font-size: 26px; }
  .support__text { font-size: 18px; }
  .support__photo { width: 340px; }

}

@media (max-width: 767px) {
  /* steps → vertical timeline */
  .steps { padding: 40px 0 60px; }
  .steps__list { grid-template-columns: 1fr; gap: 36px; }
  .steps__list::before { top: 18px; bottom: 60px; left: 17px; right: auto; width: 2px; height: auto; }
  .step { padding-left: 55px; font-size: 16px; }
  .step::before { position: absolute; top: 0; left: 0; }
  .step__title { min-height: 0; margin-bottom: 10px; font-size: 18px; }

  /* card promo → photo on top, text below */
  .card-promo { height: auto; }
  .card-promo__photo { left: 0; width: 100%; height: 260px; }
  .card-promo__panel { top: 200px; clip-path: none; }
  .card-promo__inner { grid-template-columns: 1fr; gap: 32px; padding-top: 40px; padding-bottom: 44px; }
  .card-promo__card { max-width: 360px; justify-self: center; }

  .about { padding: 50px 0 60px; }
  .about__cols { grid-template-columns: 1fr; gap: 50px; margin-top: 40px; }
  .about__subtitle { min-height: 0; margin-bottom: 24px; }

  /* app → yellow band with title + phone, features below */
  .app { padding: 0 0 60px; }
  .app__panel { bottom: auto; height: 220px; clip-path: polygon(0 0, 100% 0, 100% 82%, 0 100%); }
  .app .container { display: grid; grid-template-columns: 1fr 120px; }
  .app__title { align-self: center; padding: 30px 0; text-align: left; }
  .app__body { display: contents; }
  .app__phone { grid-row: 1; grid-column: 2; align-self: center; padding-top: 20px; }
  .app__phone img { width: 110px; }
  .features { grid-column: 1 / -1; margin-top: 50px; gap: 32px; }

  .hardware { padding: 50px 0 80px; }
  .hardware__body { grid-template-columns: 1fr; justify-items: center; gap: 30px; }
  .hardware__grid { grid-template-columns: repeat(2, minmax(0, 200px)); justify-content: center; column-gap: 20px; }
  .device img { width: 100%; max-width: 200px; }
  .device--scheme img { width: 100%; max-width: 340px; }

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

  .certificates__grid { display: flex; flex-wrap: wrap; justify-content: center; }
  .certificates__grid li { width: calc((100% - 40px) / 3); max-width: 140px; }

  .next-step__inner { grid-template-columns: 1fr; gap: 30px; text-align: center; }
  .next-step__text { order: -1; }

  .support__inner { grid-template-columns: 1fr; }
  .support__text { padding: 50px 0 10px; }
  .support__photo { justify-self: center; width: 100%; max-width: 400px; }

  .site-footer__cols { grid-template-columns: 1fr; gap: 36px; }
  .site-footer__nav ul { grid-template-rows: repeat(4, auto); grid-auto-flow: column; gap: 14px 20px; }
  .site-footer__logo img { width: 180px; }
  .site-footer__copy { margin-top: 40px; font-size: 14px; }
}

/* ---- phones: hero and how-to stack ---- */
@media (max-width: 639px) {
  .hero { height: auto; padding-top: 196px; }
  .hero__photo { top: -51px; left: calc(50% - 430px); width: 633px; }
  .hero__panel { top: 196px; clip-path: none; }
  .hero__content { align-items: center; padding: 40px 20px 46px; text-align: center; }
  .hero__subtitle { margin-top: 36px; font-size: 16px; }

  .how-to { --how-w: 710px; }
  .how-to__content { padding: 0; max-width: none; }
  .how-to__title {
    max-width: none;
    padding: 10px 20px;
    font-size: 22px;
    text-align: center;
    background: rgba(255, 255, 255, .9);
  }

  .card-promo__title { font-size: 20px; }
}

@media (max-width: 479px) {
  .how-to { --how-w: 553px; }
  .how-to__title { font-size: 20px; }

  .about__title { font-size: 20px; padding: 12px 14px; }
  .section-title { font-size: 22px; }
  .partners__grid { grid-template-columns: 1fr; grid-auto-rows: minmax(98px, auto); gap: 12px; }
  .partner { padding: 16px 18px; }
  .partner--official { justify-content: flex-start; }
  .partner__logo--voznesensk { max-height: 76px; }
  .partner__logo--renome,
  .partner__logo--visa { max-width: 238px; max-height: 54px; }
  .partner__logo--kyivstar { max-height: 40px; }
  .partner__emblem--cherkasy { width: 48px; height: 48px; }
  .partner__emblem--lviv { max-width: 48px; max-height: 62px; }
  .partner__name { max-width: none; font-size: 17px; }
  .partner__name--small { font-size: 14px; }
}
