/* Базовые стили: reset, типографика, контейнер, кнопки, лейблы, иконки, анимации */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--text-dark);
  background: var(--black);
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}

body.is-locked { overflow: hidden; }

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; padding: 0; }
input, textarea { font: inherit; color: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }
[hidden] { display: none !important; }
h1, h2, h3, h4, p { margin: 0; }

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

.section { padding-block: var(--section-y); }
.section--dark { background: var(--black); color: var(--white); }
.section--light { background: var(--light-bg); color: var(--text-dark); }

/* Заголовки */
.h1, .h2 {
  font-weight: 800;
  line-height: var(--lh-tight);
  letter-spacing: -0.02em;
}
.h1 { font-size: var(--fs-h1); }
.h2 { font-size: var(--fs-h2); }
.h3 { font-size: var(--fs-h3); font-weight: 700; line-height: 1.25; }
.accent { color: var(--red); }

/* Лейбл секции: тонкая красная линия + uppercase */
.label {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  font-size: var(--fs-label);
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.label::before {
  content: "";
  width: 32px;
  height: 2px;
  background: var(--red);
}
.section--dark .label { color: var(--text-muted-on-dark); }

.lead { color: var(--text-muted); font-size: var(--fs-body); }
.section--dark .lead { color: var(--text-muted-on-dark); }

/* Кнопки */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  height: var(--btn-h);
  padding-inline: 28px;
  border-radius: var(--radius-btn);
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
  transition: background var(--t-fast), border-color var(--t-fast), color var(--t-fast), transform var(--t-fast);
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn .icon { width: 18px; height: 18px; transition: transform var(--t-fast); }
.btn:hover .icon--arrow { transform: translateX(4px); }

.btn--primary { background: var(--red); color: var(--white); }
.btn--primary:hover { background: var(--red-hover); }
.btn--primary:active { background: var(--red-dark); }

.btn--ghost { background: transparent; color: var(--white); border: 1px solid var(--border-dark); }
.btn--ghost:hover { border-color: rgba(255, 255, 255, 0.4); background: rgba(255, 255, 255, 0.04); }

.btn--dark { background: var(--text-dark); color: var(--white); }
.btn--dark:hover { background: var(--black); }

.btn--sm { height: 46px; padding-inline: 20px; font-size: 14px; }

/* Текстовая ссылка со стрелкой */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  font-weight: 600;
  color: var(--red);
}
.link-arrow .icon { width: 18px; height: 18px; transition: transform var(--t-fast); }
.link-arrow:hover .icon { transform: translateX(4px); }

/* Иконки: единый line-стиль, stroke 1.8–2 */
.icon {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
.icon--red { color: var(--red); }

/* Логотип: знак вырезан из оригинального logadv.jpg (белый фон удалён, файл не перерисовывался).
   Ставится без подложки, выравнивается по центру строки с названием. */
.logo {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--white);
}
.logo__mark {
  width: auto;
  height: 46px;
  flex-shrink: 0;
}
.logo__text { display: flex; flex-direction: column; gap: 2px; line-height: 1.1; }
.logo__name { font-size: 18px; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; }
.logo__sub { font-size: 10px; font-weight: 600; letter-spacing: 0.18em; color: var(--text-muted-on-dark); text-transform: uppercase; }

/* Доступность */
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }
.visually-hidden {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

/* Появление секций при скролле */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity var(--t-slow), transform var(--t-slow); }
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
