/* A-Pro Academy Landing — minimal SaaS, red & white */

:root {
  --color-bg: #ffffff;
  --color-text: #1a1a1a;
  --color-text-muted: #5c5c5c;
  --color-accent: #c41e3a;
  --color-accent-hover: #a01830;
  --color-border: #e8e8e8;
  --color-card-bg: #fafafa;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --container: 1280px;
  --container-narrow: 960px;
  --header-height: 72px;
  --radius: 8px;
  --shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
  --shadow-modal: 0 20px 60px rgba(0, 0, 0, 0.15);
}

* {
  box-sizing: border-box;
}

/* Stable layout across languages (e.g. Kazakh vs Russian/English) */
html {
  font-size: 18px;
  -webkit-text-size-adjust: 100%;
}

/* Decorative icons on the sides — mobile: hidden; desktop: in flow, see @media (min-width: 769px) */
.lp-deco-icons {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}

.lp-deco-icon {
  position: absolute;
  width: 56px;
  height: 56px;
  color: rgba(196, 30, 58, 0.18);
}

.lp-deco-icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

.lp-deco-icon--1 { left: 4%; top: 18%; transform: rotate(-14deg); }
.lp-deco-icon--2 { right: 5%; top: 28%; transform: rotate(10deg) scaleX(-1); }
.lp-deco-icon--3 { left: 3%; top: 58%; transform: rotate(6deg) scaleX(-1); }
.lp-deco-icon--4 { right: 4%; bottom: 28%; transform: rotate(-9deg); }
.lp-deco-icon--5 { left: 6%; top: 42%; transform: rotate(12deg) scaleX(-1); }
.lp-deco-icon--6 { right: 3%; top: 48%; transform: rotate(-5deg); }
.lp-deco-icon--7 { left: 5%; bottom: 22%; transform: rotate(8deg); }
.lp-deco-icon--8 { right: 6%; top: 12%; transform: rotate(-16deg) scaleX(-1); }
.lp-deco-icon--9 { right: 4%; bottom: 45%; transform: rotate(4deg) scaleX(-1); }
.lp-deco-icon--10 { left: 5%; top: 8%; transform: rotate(-8deg); }
.lp-deco-icon--11 { right: 6%; top: 38%; transform: rotate(6deg) scaleX(-1); }
.lp-deco-icon--12 { left: 4%; top: 72%; transform: rotate(10deg) scaleX(-1); }
.lp-deco-icon--13 { right: 5%; top: 58%; transform: rotate(-12deg); }
.lp-deco-icon--14 { left: 6%; top: 92%; transform: rotate(-5deg); }
.lp-deco-icon--15 { right: 4%; top: 78%; transform: rotate(8deg) scaleX(-1); }
.lp-deco-icon--16 { left: 3%; top: 32%; transform: rotate(4deg); }
.lp-deco-icon--17 { right: 5%; bottom: 18%; transform: rotate(-7deg) scaleX(-1); }
.lp-deco-icon--18 { left: 5%; top: 52%; transform: rotate(14deg) scaleX(-1); }

/* Desktop: deco icons flow with content (not fixed), full-width layout */
@media (min-width: 769px) {
  :root {
    --container: 100%;
  }

  .lp-page-wrap {
    position: relative;
  }

  .lp-deco-icons {
    position: absolute;
    inset: 0;
  }

  .lp-header__inner,
  .lp-hero__inner,
  .lp-section-wrap .lp-section__inner,
  .lp-section .lp-section__inner,
  .lp-partners__inner,
  .lp-clients__inner,
  .lp-footer__inner {
    padding-left: 48px;
    padding-right: 48px;
  }

  .lp-header {
    padding-left: 0;
    padding-right: 0;
  }
}

body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.65;
  background: var(--color-bg);
  color: var(--color-text);
}

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

a:hover {
  text-decoration: underline;
}

/* ----- Header ----- */
.lp-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  max-width: 100%;
}

.lp-header__inner {
  max-width: var(--container);
  width: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 24px;
  min-width: 0;
}

.lp-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.lp-logo img {
  max-height: 40px;
  width: auto;
}

.lp-logo span {
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--color-text);
}

.lp-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 32px;
  flex: 1;
  min-width: 0;
}

.lp-nav a {
  color: var(--color-text);
  font-size: 1.0625rem;
  text-decoration: none;
  white-space: nowrap;
}

.lp-nav a:hover {
  color: var(--color-accent);
}

.lp-header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
  margin-left: auto;
}

/* Language switcher */
.lp-lang {
  display: flex;
  gap: 4px;
}

.lp-lang form {
  display: inline;
}

.lp-lang button {
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px 10px;
  min-width: 40px;
  font-size: 1rem;
  color: var(--color-text-muted);
  border-radius: var(--radius);
}

.lp-lang button:hover {
  color: var(--color-accent);
  background: rgba(196, 30, 58, 0.06);
}

.lp-lang button.is-active {
  color: var(--color-accent);
  font-weight: 600;
}

/* CTA button */
.lp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  min-width: 150px;
  font-size: 1.0625rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.lp-btn--primary {
  background: var(--color-accent);
  color: white;
}

.lp-btn--primary:hover {
  background: var(--color-accent-hover);
}

/* Иконка «Оставить заявку» — только на мобильных, в десктопе скрыта */
.lp-request-icon {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  background: var(--color-accent);
  color: white;
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  flex-shrink: 0;
  transition: background 0.2s;
}

.lp-request-icon:hover {
  background: var(--color-accent-hover);
}

.lp-request-icon svg {
  width: 24px;
  height: 24px;
  display: block;
}

/* Full-width section wrapper (background stretches, content stays in container) */
.lp-section-wrap {
  width: 100%;
}

.lp-section-wrap .lp-section__inner,
.lp-hero__inner {
  max-width: var(--container);
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* ----- Hero ----- (full-width with subtle background) */
.lp-hero {
  width: 100%;
  padding: 80px 0 100px;
  text-align: center;
  min-height: 320px;
  background: linear-gradient(180deg, rgba(196, 30, 58, 0.04) 0%, var(--color-bg) 35%);
}

.lp-hero__inner {
  padding-top: 0;
  padding-bottom: 0;
}

.lp-hero h1 {
  font-size: clamp(2.1rem, 5vw, 3.25rem);
  font-weight: 700;
  line-height: 1.25;
  color: var(--color-text);
  margin: 0 auto 20px;
  max-width: 18em;
}

.lp-hero p {
  font-size: 1.25rem;
  line-height: 1.65;
  color: var(--color-text-muted);
  max-width: 560px;
  margin: 0 auto 36px;
}

/* ----- Sections common ----- */
.lp-section {
  padding: 64px 0;
  width: 100%;
}

.lp-section .lp-section__inner {
  max-width: var(--container);
  margin: 0 auto;
  padding-left: 24px;
  padding-right: 24px;
}

/* Alternate section backgrounds for visual width */
.lp-section-wrap--alt {
  background: var(--color-card-bg);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

/* Partners strip — горизонтальная прокрутка логотипов */
.lp-partners {
  padding: 48px 0;
  background: var(--color-bg);
  border-top: 1px solid var(--color-border);
  overflow: hidden;
}

.lp-partners__inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.lp-partners__title {
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--color-text-muted);
  text-align: center;
  margin: 0 0 28px;
}

.lp-partners__track-wrap {
  overflow: hidden;
  mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
}

.lp-partners__track {
  display: flex;
  width: max-content;
  animation: lp-partners-scroll 25s linear infinite;
}

.lp-partners__row {
  display: flex;
  align-items: center;
  gap: 64px;
  padding: 0 48px;
  flex-shrink: 0;
}

.lp-partners__logo {
  height: 48px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
}

.lp-partners__logo.lp-logo--large {
  height: 72px;
  max-width: 200px;
}

.lp-partners__logo.lp-logo--xlarge {
  height: 144px;
  max-width: 400px;
}

.lp-partners__logo.lp-logo--xxlarge {
  height: 432px;
  max-width: 1000px;
}

.lp-partners__logo.lp-logo--small {
  height: 36px;
  max-width: 100px;
}

.lp-partners__logo.lp-logo--dark {
  background: #1a1a1a;
  padding: 10px 14px;
  border-radius: 6px;
  box-sizing: content-box;
}

@keyframes lp-partners-scroll {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Clients strip — горизонтальная прокрутка логотипов клиентов */
.lp-clients {
  padding: 48px 0;
  background: var(--color-bg);
  border-top: 1px solid var(--color-border);
  overflow: hidden;
}

.lp-clients__inner {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.lp-clients__title {
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--color-text-muted);
  text-align: center;
  margin: 0 0 28px;
}

.lp-clients__track-wrap {
  overflow: hidden;
  mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
  -webkit-mask-image: linear-gradient(to right, transparent, black 8%, black 92%, transparent);
}

.lp-clients__track {
  display: flex;
  width: max-content;
  animation: lp-partners-scroll 25s linear infinite;
}

.lp-clients__row {
  display: flex;
  align-items: center;
  gap: 64px;
  padding: 0 48px;
  flex-shrink: 0;
}

.lp-clients__logo {
  height: 48px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
}

.lp-clients__logo.lp-logo--large {
  height: 72px;
  max-width: 200px;
}

.lp-clients__logo.lp-logo--xlarge {
  height: 144px;
  max-width: 400px;
}

.lp-clients__logo.lp-logo--xxlarge {
  height: 432px;
  max-width: 1000px;
}

.lp-clients__logo.lp-logo--small {
  height: 36px;
  max-width: 100px;
}

.lp-clients__logo.lp-logo--dark {
  background: #1a1a1a;
  padding: 10px 14px;
  border-radius: 6px;
  box-sizing: content-box;
}

.lp-section__title {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.3;
  color: var(--color-text);
  margin: 0 0 40px;
  text-align: center;
}

.lp-section__title + * {
  margin-top: 0;
}

/* Benefits cards — 2 columns on desktop, larger cards */
.lp-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 28px;
}

@media (min-width: 900px) {
  .lp-cards {
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
  }
}

.lp-card {
  background: var(--color-card-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: 36px 32px;
  min-height: 260px;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s, border-color 0.2s;
}

.lp-card__icon {
  display: block;
  width: 40px;
  height: 40px;
  color: var(--color-accent);
  margin-bottom: 16px;
}

.lp-card__icon svg {
  width: 100%;
  height: 100%;
  display: block;
}

.lp-card:hover {
  box-shadow: var(--shadow);
  border-color: rgba(196, 30, 58, 0.2);
}

.lp-card h3 {
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--color-accent);
  margin: 0 0 10px;
}

.lp-card p {
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--color-text-muted);
  margin: 0;
  flex: 1;
}

/* How we work — steps (4 columns on wide screens) */
.lp-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 32px;
  counter-reset: step;
}

@media (min-width: 900px) {
  .lp-steps {
    grid-template-columns: repeat(4, 1fr);
    gap: 40px;
  }
}

.lp-step {
  text-align: center;
  position: relative;
  min-height: 160px;
}

.lp-step::before {
  counter-increment: step;
  content: counter(step);
  display: block;
  width: 48px;
  height: 48px;
  margin: 0 auto 16px;
  background: var(--color-accent);
  color: white;
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 48px;
  border-radius: 50%;
}

.lp-step h3 {
  font-size: 1.125rem;
  font-weight: 600;
  margin: 0 0 8px;
}

.lp-step p {
  font-size: 1rem;
  line-height: 1.55;
  color: var(--color-text-muted);
  margin: 0;
}

/* About — legal */
.lp-about {
  background: var(--color-card-bg);
  border-radius: var(--radius);
  padding: 40px;
  border: 1px solid var(--color-border);
}

.lp-about p {
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--color-text-muted);
  margin: 0 0 12px;
}

.lp-about p:last-child {
  margin-bottom: 0;
}

/* CTA block — full-width with stronger background */
.lp-cta-block {
  text-align: center;
  padding: 64px 0;
  width: 100%;
  background: linear-gradient(180deg, var(--color-card-bg) 0%, rgba(196, 30, 58, 0.06) 50%, var(--color-bg) 100%);
  border-top: 1px solid var(--color-border);
}

.lp-cta-block .lp-section__inner {
  padding-top: 0;
  padding-bottom: 0;
}

.lp-cta-block h2 {
  font-size: 1.65rem;
  font-weight: 700;
  line-height: 1.3;
  margin: 0 0 12px;
}

.lp-cta-block p {
  font-size: 1.125rem;
  line-height: 1.55;
  color: var(--color-text-muted);
  margin: 0 0 24px;
}

/* ----- Modal ----- */
.lp-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.lp-modal-overlay.is-open {
  display: flex;
}

.lp-modal {
  background: var(--color-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow-modal);
  max-width: 440px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

.lp-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--color-border);
}

.lp-modal__header h2 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
  line-height: 1.3;
}

.lp-modal__close {
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
  color: var(--color-text-muted);
  font-size: 1.5rem;
  line-height: 1;
}

.lp-modal__close:hover {
  color: var(--color-accent);
}

.lp-modal__body {
  padding: 24px;
}

.lp-form .lp-form-group {
  margin-bottom: 16px;
}

.lp-form label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  line-height: 1.4;
  margin-bottom: 6px;
  color: var(--color-text);
}

.lp-form input,
.lp-form textarea {
  width: 100%;
  padding: 10px 12px;
  font-size: 1rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  font-family: inherit;
}

.lp-form input:focus,
.lp-form textarea:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(196, 30, 58, 0.1);
}

.lp-form textarea {
  resize: vertical;
  min-height: 100px;
}

.lp-form .lp-form-error {
  font-size: 0.8125rem;
  color: var(--color-accent);
  margin-top: 4px;
}

.lp-form .lp-form-success {
  font-size: 0.9375rem;
  color: #0d8050;
  margin-bottom: 12px;
}

.lp-modal__body button[type="submit"] {
  width: 100%;
  margin-top: 8px;
}

/* ----- Footer ----- */
.lp-footer {
  background: var(--color-text);
  color: #9ca3af;
  padding: 40px 24px 24px;
  margin-top: 48px;
  width: 100%;
  box-sizing: border-box;
}

.lp-footer__inner {
  max-width: var(--container);
  margin: 0 auto;
  text-align: center;
}

.lp-footer p {
  font-size: 0.875rem;
  margin: 0 0 8px;
}

.lp-footer a {
  color: #d1d5db;
}

.lp-footer a:hover {
  color: white;
}

/* ----- Mobile menu (burger) — hidden on desktop ----- */
.lp-burger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-text);
  border-radius: var(--radius);
  transition: background 0.2s;
}

.lp-burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: currentColor;
  border-radius: 1px;
  transition: transform 0.2s, opacity 0.2s;
}

.lp-burger[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.lp-burger[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.lp-burger[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.lp-mobile-menu {
  display: none;
  position: fixed;
  inset: 0;
  top: var(--header-height);
  z-index: 99;
  background: var(--color-bg);
  padding: 24px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.lp-mobile-menu.is-open {
  display: block;
}

.lp-mobile-menu__nav {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 16px;
}

.lp-mobile-menu__nav a {
  display: block;
  padding: 14px 0;
  font-size: 1.125rem;
  font-weight: 500;
  line-height: 1.4;
  color: var(--color-text);
  text-decoration: none;
  border-bottom: 1px solid var(--color-border);
}

.lp-mobile-menu__nav a:hover {
  color: var(--color-accent);
}

.lp-mobile-menu__actions {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-top: 24px;
  margin-top: 16px;
  border-top: 1px solid var(--color-border);
}

.lp-mobile-menu__lang {
  justify-content: flex-start;
}

.lp-mobile-menu__lang button {
  min-width: 48px;
  min-height: 44px;
}

.lp-mobile-menu__cta {
  width: 100%;
  max-width: 100%;
  min-height: 48px;
  font-size: 1.0625rem;
}

/* ----- Mobile & small screens ----- */
@media (max-width: 768px) {
  html {
    font-size: 15px;
    overflow-x: hidden;
  }

  body {
    overflow-x: hidden;
    max-width: 100vw;
  }

  .lp-deco-icons {
    display: none;
  }

  .lp-nav {
    display: none;
  }

  .lp-burger {
    display: flex;
    margin-left: auto;
    margin-right: 6px;
  }

  .lp-header {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  .lp-header__inner {
    gap: 6px;
  }

  .lp-logo {
    min-width: 0;
    overflow: hidden;
  }

  .lp-logo span {
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .lp-logo img {
    max-height: 32px;
    flex-shrink: 0;
  }

  .lp-header-actions {
    flex-shrink: 0;
    gap: 6px;
  }

  .lp-header-cta {
    display: none !important;
  }

  .lp-request-icon {
    display: none !important;
  }

  .lp-header-actions .lp-btn {
    padding: 10px 12px;
    min-height: 40px;
    font-size: 0.875rem;
    white-space: nowrap;
  }

  .lp-lang button {
    padding: 6px 8px;
    min-width: 40px;
    min-height: 40px;
    font-size: 0.875rem;
  }

  .lp-mobile-menu {
    padding-left: max(20px, env(safe-area-inset-left));
    padding-right: max(20px, env(safe-area-inset-right));
    padding-bottom: max(20px, env(safe-area-inset-bottom));
  }

  .lp-mobile-menu__nav a {
    font-size: 1rem;
    padding: 12px 0;
  }

  .lp-hero {
    padding: 24px 0 40px;
  }

  .lp-hero__inner {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  .lp-hero h1 {
    font-size: clamp(1.35rem, 5.5vw, 2rem);
  }

  .lp-hero p {
    font-size: 0.95rem;
    margin-bottom: 22px;
  }

  .lp-hero .lp-btn {
    width: 100%;
    max-width: 260px;
    padding: 12px 18px;
    min-height: 44px;
    font-size: 0.9375rem;
  }

  .lp-section {
    padding: 28px 0;
  }

  .lp-section .lp-section__inner {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  .lp-section__title {
    font-size: 1.4rem;
    margin-bottom: 22px;
  }

  .lp-cards {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .lp-card {
    padding: 20px 18px;
    min-height: 180px;
  }

  .lp-card__icon {
    width: 32px;
    height: 32px;
  }

  .lp-card h3 {
    font-size: 1.05rem;
  }

  .lp-card p {
    font-size: 0.9rem;
  }

  /* Partners / Clients strips */
  .lp-partners,
  .lp-clients {
    padding: 24px 0;
  }

  .lp-partners__inner,
  .lp-clients__inner {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  .lp-partners__title,
  .lp-clients__title {
    font-size: 1.05rem;
    margin-bottom: 16px;
  }

  .lp-partners__row,
  .lp-clients__row {
    gap: 28px;
    padding: 0 16px;
  }

  .lp-partners__logo,
  .lp-clients__logo {
    height: 34px;
    max-width: 100px;
  }

  .lp-partners__logo.lp-logo--large,
  .lp-clients__logo.lp-logo--large {
    height: 44px;
    max-width: 120px;
  }

  .lp-partners__logo.lp-logo--xlarge,
  .lp-clients__logo.lp-logo--xlarge {
    height: 64px;
    max-width: 180px;
  }

  .lp-partners__logo.lp-logo--xxlarge,
  .lp-clients__logo.lp-logo--xxlarge {
    height: 120px;
    max-width: 260px;
  }

  .lp-partners__logo.lp-logo--small,
  .lp-clients__logo.lp-logo--small {
    height: 28px;
    max-width: 64px;
  }

  .lp-steps {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .lp-step {
    min-height: 120px;
  }

  .lp-step::before {
    width: 40px;
    height: 40px;
    font-size: 1rem;
    line-height: 40px;
  }

  .lp-step h3 {
    font-size: 1rem;
  }

  .lp-step p {
    font-size: 0.875rem;
  }

  .lp-about {
    padding: 20px 16px;
  }

  .lp-about p {
    font-size: 0.9rem;
  }

  .lp-cta-block {
    padding: 28px 0;
  }

  .lp-cta-block h2 {
    font-size: 1.2rem;
  }

  .lp-cta-block p {
    font-size: 0.9rem;
  }

  .lp-cta-block .lp-btn {
    width: 100%;
    max-width: 260px;
    padding: 12px 18px;
    min-height: 44px;
    font-size: 0.9375rem;
  }

  .lp-footer {
    width: 100%;
    max-width: 100vw;
    margin-left: 0;
    padding: 24px 12px 20px;
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
    padding-bottom: max(20px, env(safe-area-inset-bottom));
    margin-top: 24px;
    box-sizing: border-box;
  }

  .lp-footer p {
    font-size: 0.8125rem;
  }

  /* Модалка заявки — уже и компактнее на телефоне */
  .lp-modal-overlay {
    padding: 0;
    align-items: stretch;
    justify-content: flex-end;
  }

  .lp-modal {
    width: min(92vw, 300px);
    max-width: 300px;
    height: 100%;
    max-height: none;
    margin: 0;
    border-radius: var(--radius) 0 0 var(--radius);
    transform: translateX(100%);
    transition: transform 0.3s ease-out;
    display: flex;
    flex-direction: column;
  }

  .lp-modal-overlay.is-open .lp-modal {
    transform: translateX(0);
  }

  .lp-modal__header {
    padding: 14px 12px 14px max(14px, env(safe-area-inset-right));
  }

  .lp-modal__header h2 {
    font-size: 1.1rem;
  }

  .lp-modal__body {
    padding: 14px 12px;
    padding-right: max(14px, env(safe-area-inset-right));
    overflow-y: auto;
    flex: 1;
  }

  .lp-modal__close {
    min-width: 40px;
    min-height: 40px;
    font-size: 1.35rem;
  }

  .lp-form .lp-form-group {
    margin-bottom: 12px;
  }

  .lp-form label {
    font-size: 0.8125rem;
  }

  .lp-form button[type="submit"] {
    min-height: 44px;
    width: 100%;
    font-size: 0.9375rem;
  }

  .lp-form input,
  .lp-form textarea {
    font-size: 16px; /* prevents zoom on focus on iOS */
    min-height: 44px;
    padding: 8px 10px;
  }

  .lp-form textarea {
    min-height: 96px;
  }
}

/* Very small phones */
@media (max-width: 380px) {
  .lp-logo span {
    font-size: 0.9375rem;
  }

  .lp-header-actions .lp-btn {
    padding: 8px 10px;
    font-size: 0.8125rem;
  }

  .lp-hero .lp-btn,
  .lp-cta-block .lp-btn {
    max-width: none;
  }
}

/* Extra narrow: hide logo text so CTA button fits */
@media (max-width: 340px) {
  .lp-logo span {
    display: none;
  }

  .lp-logo {
    gap: 0;
  }
}

/* Safe area for notched devices */
@supports (padding: env(safe-area-inset-bottom)) {
  .lp-footer {
    padding-bottom: calc(24px + env(safe-area-inset-bottom));
  }

  .lp-modal {
    padding-bottom: env(safe-area-inset-bottom);
  }
}
