:root {
  color-scheme: light;
  --bg: #f5f5f7;
  --bg-alt: #ffffff;
  --text: #1d1d1f;
  --muted: #6e6e73;
  --line: rgba(0, 0, 0, 0.08);
  --accent: #0a84ff;
  --accent-dark: #0060df;
  --pill: rgba(10, 132, 255, 0.1);
  --shadow: 0 30px 80px rgba(0, 0, 0, 0.08);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --page-gutter: clamp(20px, 4vw, 48px);
  --section-y: clamp(72px, 10vw, 140px);
  --container: min(1120px, 100% - var(--page-gutter) * 2);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "SF Pro Display", "SF Pro Text", "Helvetica Neue", Helvetica,
    "Nimbus Sans L", "Liberation Sans", sans-serif;
  background: radial-gradient(circle at top, #ffffff 0%, #f5f5f7 48%, #eef0f4 100%);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

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

a {
  text-decoration: none;
  color: inherit;
}

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

ul {
  list-style: none;
}

:root[data-lang="en"] [data-lang="ru"],
:root[data-lang="ru"] [data-lang="en"] {
  display: none;
}

.container {
  width: var(--container);
  margin: 0 auto;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 12px;
  padding: 10px 16px;
  background: var(--accent);
  color: #fff;
  border-radius: 999px;
  z-index: 10;
}

.skip-link:focus {
  left: 12px;
}

.site-header {
  position: sticky;
  top: 0;
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  background: rgba(245, 245, 247, 0.8);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  z-index: 5;
}

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

.logo {
  font-weight: 600;
  letter-spacing: -0.02em;
  font-size: 1.05rem;
}

.nav {
  display: flex;
  gap: clamp(12px, 2vw, 28px);
  color: var(--muted);
  font-size: 0.95rem;
  flex-wrap: wrap;
  justify-content: center;
}

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

.nav a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
  border-radius: 6px;
}

.lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
}

.lang-button {
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.lang-button.is-active {
  background: var(--text);
  color: #fff;
  transform: translateY(-1px);
}

.lang-button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 500;
  border: 1px solid transparent;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease,
    border-color 0.2s ease, color 0.2s ease;
}

.button--primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 12px 30px rgba(10, 132, 255, 0.3);
}

.button--primary:hover {
  transform: translateY(-1px);
  background: var(--accent-dark);
}

.button--ghost {
  border-color: var(--line);
  color: var(--text);
  background: rgba(255, 255, 255, 0.6);
}

.button--ghost:hover {
  transform: translateY(-1px);
  background: #fff;
  border-color: rgba(0, 0, 0, 0.14);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.08);
}

.button--ghost:active {
  transform: translateY(0);
}

.button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.hero {
  padding: var(--section-y) 0 0;
}

.hero-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: clamp(24px, 5vw, 72px);
  align-items: center;
}

.hero-copy h1 {
  font-size: clamp(2.4rem, 4.6vw, 4.2rem);
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.24em;
  font-size: 0.7rem;
  color: var(--muted);
  margin-bottom: 12px;
  display: inline-block;
}

.lead {
  font-size: clamp(1.05rem, 1.6vw, 1.25rem);
  color: var(--muted);
  max-width: 34ch;
}

.hero-actions {
  margin: 28px 0 32px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.hero-metrics {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
}

.metric span {
  font-size: 1.5rem;
  font-weight: 600;
  display: block;
}

.metric p {
  color: var(--muted);
  font-size: 0.95rem;
}

.hero-help {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 4vw, 34px);
  box-shadow: var(--shadow);
  display: grid;
  gap: 8px;
}

.hero-help-list {
  display: grid;
}

.hero-help-item {
  display: grid;
  grid-template-columns: auto 1fr;
  align-items: start;
  gap: 14px;
  padding: 14px 0;
}

.hero-help-item + .hero-help-item {
  border-top: 1px solid var(--line);
}

.hero-help-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 26px;
  border-radius: 999px;
  background: rgba(10, 132, 255, 0.12);
  color: var(--accent-dark);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
}

.hero-help-item h3 {
  font-size: 1.05rem;
  letter-spacing: -0.01em;
}

.hero-help-item p {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.95rem;
}

.modal-open {
  overflow: hidden;
}

.help-modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  z-index: 60;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.24s ease, visibility 0s linear 0.24s;
}

.help-modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity 0.24s ease;
}

.help-modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(12, 17, 29, 0.52);
  z-index: 0;
  opacity: 0;
  transition: opacity 0.18s ease;
  will-change: opacity;
}

.help-modal__content {
  position: relative;
  width: min(680px, 100%);
  max-height: min(88vh, 860px);
  overflow-y: auto;
  z-index: 1;
  opacity: 0;
  transform: translateY(8px) scale(0.985);
  transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.22s ease;
}

.help-modal__content.hero-help {
  background: #fff;
}

.help-modal.is-open .help-modal__overlay {
  opacity: 1;
}

.help-modal.is-open .help-modal__content {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.help-modal__title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  line-height: 1.2;
  letter-spacing: -0.02em;
}

.help-modal__close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1px solid rgba(0, 0, 0, 0.12);
  background: rgba(255, 255, 255, 0.8);
  color: #1d1d1f;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}

.help-modal__close:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.section {
  padding: var(--section-y) 0;
}

.section.alt {
  background: var(--bg-alt);
  border-top: 1px solid rgba(0, 0, 0, 0.04);
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.section-heading {
  display: grid;
  gap: 12px;
  margin-bottom: clamp(28px, 4vw, 48px);
  max-width: 640px;
}

.section-heading h2 {
  font-size: clamp(1.8rem, 3vw, 2.6rem);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.subtext {
  color: var(--muted);
}

.grid {
  display: grid;
  gap: clamp(20px, 4vw, 36px);
}

.cards {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.card {
  padding: clamp(20px, 3vw, 32px);
  background: #fff;
  border-radius: var(--radius-md);
  border: 1px solid rgba(0, 0, 0, 0.05);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.06);
  display: grid;
  gap: 12px;
}

.card h3 {
  font-size: 1.2rem;
  letter-spacing: -0.01em;
}

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

.card ul {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.95rem;
}

.showcase {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.case {
  background: #fff;
  border-radius: var(--radius-md);
  border: 1px solid rgba(0, 0, 0, 0.05);
  overflow: hidden;
  display: grid;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.06);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.case:hover {
  transform: translateY(-4px);
  box-shadow: 0 26px 58px rgba(0, 0, 0, 0.08);
}

.case-image {
  height: clamp(180px, 20vw, 220px);
  background: linear-gradient(120deg, rgba(10, 132, 255, 0.2), rgba(0, 0, 0, 0.05));
  display: flex;
  align-items: end;
  padding: 18px;
}

.case:nth-child(1) .case-image {
  background: linear-gradient(135deg, rgba(74, 144, 226, 0.25), rgba(209, 232, 255, 0.75));
}

.case:nth-child(2) .case-image {
  background: linear-gradient(135deg, rgba(35, 93, 71, 0.26), rgba(193, 231, 216, 0.78));
}

.case:nth-child(3) .case-image {
  background: linear-gradient(135deg, rgba(84, 58, 138, 0.24), rgba(223, 214, 247, 0.74));
}

.case-image-label {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.76);
  border: 1px solid rgba(0, 0, 0, 0.08);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #202124;
  font-weight: 600;
}

.case-body {
  padding: 24px;
  display: grid;
  gap: 8px;
}

.case-body span {
  font-size: 0.9rem;
  color: var(--muted);
}

.case-links {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}

.case-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 9px 14px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  background: rgba(255, 255, 255, 0.82);
  font-size: 0.86rem;
  color: var(--text);
  transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.case-links a:hover {
  background: #fff;
  border-color: rgba(0, 0, 0, 0.18);
  transform: translateY(-1px);
}

.case-links a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.steps {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
}

.step {
  padding: 24px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.7);
}

.step span {
  color: var(--accent);
  font-weight: 600;
  font-size: 1.05rem;
}

.split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(24px, 5vw, 60px);
  align-items: start;
}

.pill-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}

.pill-row span {
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--pill);
  color: var(--accent-dark);
  font-size: 0.9rem;
}

.about-panel {
  padding: 32px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(0, 0, 0, 0.06);
  background: #fff;
  box-shadow: var(--shadow);
}

.about-panel ul {
  margin-top: 16px;
  display: grid;
  gap: 10px;
  color: var(--muted);
}

.testimonials {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.quote {
  padding: 24px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--line);
  display: grid;
  gap: 16px;
}

.quote span {
  color: var(--muted);
}

.cta {
  padding-bottom: clamp(90px, 12vw, 160px);
}

.cta-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(24px, 4vw, 48px);
  align-items: center;
}

.cta-panel {
  background: #fff;
  border-radius: var(--radius-lg);
  padding: clamp(24px, 4vw, 40px);
  border: 1px solid rgba(0, 0, 0, 0.06);
  box-shadow: var(--shadow);
  display: grid;
  gap: 16px;
}

.cta-row span {
  color: var(--muted);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.16em;
}

.cta-row p {
  font-size: 1.05rem;
}

.cta-row a {
  color: var(--accent-dark);
}

.site-footer {
  padding: 48px 0 28px;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
  background: #fff;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 24px;
  margin-bottom: 28px;
}

.footer-grid h4 {
  margin-bottom: 12px;
  font-size: 0.95rem;
}

.footer-grid a,
.footer-grid span,
.footer-grid p {
  color: var(--muted);
  font-size: 0.95rem;
  display: block;
  margin-bottom: 8px;
}

.footer-bottom {
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (prefers-reduced-motion: no-preference) {
  .fade-in {
    opacity: 0;
    transform: translateY(14px);
    animation: fadeUp 0.8s ease forwards;
    animation-delay: var(--delay, 0s);
  }

  .delay-1 {
    --delay: 0.05s;
  }

  .delay-2 {
    --delay: 0.15s;
  }

  .delay-3 {
    --delay: 0.25s;
  }

  .stagger > * {
    opacity: 0;
    transform: translateY(12px);
    animation: fadeUp 0.7s ease forwards;
  }

  .stagger > *:nth-child(1) {
    animation-delay: 0.05s;
  }

  .stagger > *:nth-child(2) {
    animation-delay: 0.12s;
  }

  .stagger > *:nth-child(3) {
    animation-delay: 0.2s;
  }

  .stagger > *:nth-child(4) {
    animation-delay: 0.28s;
  }
}

@media (max-width: 900px) {
  .header-inner {
    justify-content: center;
  }

  .nav {
    order: 4;
    width: 100%;
  }

  .button--primary {
    order: 2;
  }

  .lang-toggle {
    order: 3;
  }

  .help-modal {
    padding: 16px;
  }

  .help-modal__content {
    max-height: 92vh;
  }
}

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