/* ============================================================================
   FTD CORE — общий слой для ftd.pro / ftd.global / ftd.team
   Всё в этом файле взято с живого ftd.pro без изменений. Блок должен быть
   ОДИНАКОВЫМ на всех трёх сайтах: правится здесь — применяется везде.
   Ниже ядра каждый сайт добавляет только свою тему (цвет, земля, секции).
   ============================================================================ */

:root {
  /* базовая палитра */
  --ink: #0C0C0C;
  --ink-60: rgba(12, 12, 12, .60);
  --ink-20: rgba(12, 12, 12, .20);
  --ink-08: rgba(12, 12, 12, .08);
  --paper: #FCFCFC;
  --paper-60: rgba(252, 252, 252, .60);
  --paper-20: rgba(252, 252, 252, .20);
  --paper-12: rgba(252, 252, 252, .12);
  --grey: #969696;

  /* цвета суббрендов (Брендбук 2.0, стр. 8) */
  --sapphire: #2288EE;
  --cyan: #00E1FF;
  --cyan-deep: #007F90;
  --indigo: #8B7CFF;
  --indigo-deep: #7164CF;

  /* шкала радиусов */
  --r-s: 8px;
  --r-m: 12px;
  --r-l: 16px;
  --r-xl: 36px;

  /* ритм */
  --gap: 20px;
  --section: 80px;
  --ease: cubic-bezier(.16, 1, .3, 1);

  /* волосяные линии с градиентным затуханием — подпись всех трёх сайтов */
  --rule-dark: linear-gradient(270deg, rgba(12, 12, 12, 0) 0%, rgba(12, 12, 12, .2) 50%, rgba(12, 12, 12, 0) 100%);
  --rule-light: linear-gradient(270deg, rgba(252, 252, 252, 0) 0%, rgba(252, 252, 252, .25) 50%, rgba(252, 252, 252, 0) 100%);
  --rule-v-light: linear-gradient(180deg, rgba(252, 252, 252, 0) 0%, rgba(252, 252, 252, .25) 50%, rgba(252, 252, 252, 0) 100%);
}

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

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

body {
  font-family: "Geologica", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-weight: 300;
  font-size: 19px;
  line-height: 100%;
  letter-spacing: -0.03em;
  min-width: 320px;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, p { margin: 0; font-weight: 300; }
ul { list-style: none; }
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; letter-spacing: inherit; color: inherit; background: none; border: none; cursor: pointer; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* ---------------------------------------------------------------- сетка */

.container {
  max-width: 1380px;
  margin: 0 auto;
  padding: 0 10px;
}

section[id] { scroll-margin-top: 84px; }

.sr-only {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

/* ------------------------------------------------- волосяная линия */

.rule-b {
  border-bottom: 1px solid;
  border-image-slice: 1;
  border-image-source: var(--rule-light);
}
.rule-t {
  border-top: 1px solid;
  border-image-slice: 1;
  border-image-source: var(--rule-light);
}

/* ------------------------------------------------- бейдж над H1 */

.badge {
  display: inline-block;
  margin-bottom: 8px;
  padding: 10px 16px 14px;
  font-size: 24px;
  line-height: 120%;
}

/* ------------------------------------------------- заголовки */

.h1 { font-size: 72px; line-height: 100%; }
.h2 { font-size: 57px; line-height: 100%; }
.h3 { font-size: 43px; line-height: 100%; }
.h4 { font-size: 28px; line-height: 100%; }
.lead { font-size: 24px; line-height: 120%; }
.body { font-size: 19px; line-height: 120%; }
.small { font-size: 16px; line-height: 120%; }

/* ------------------------------------------------- кнопки */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-width: 172px;
  min-height: 63px;
  padding: 18px 28px 22px;
  font-size: 19px;
  font-weight: 400;
  line-height: 120%;
  text-align: center;
  border: 1px solid transparent;
  border-radius: var(--r-s);
  cursor: pointer;
  transition: all .35s var(--ease);
  -webkit-tap-highlight-color: transparent;
}
.btn--sm { min-width: 79px; min-height: 39px; padding: 8px 18px 10px; font-size: 16px; }

/* Заливка фирменной плашкой. Цвет текста задаётся темой сайта:
   на #00E1FF — только тёмный, на #8B7CFF и #2288EE — белый. */
.btn--fill {
  background: var(--accent);
  color: var(--on-accent);
  box-shadow: 0 8px 24px 0 var(--accent-glow);
}
.btn--fill:hover, .btn--fill:focus {
  background: var(--accent-deep);
  color: var(--paper);
  box-shadow: none;
}
.btn--ghost { background: transparent; color: var(--paper); border-color: var(--paper-20); }
.btn--ghost:hover, .btn--ghost:focus { border-color: var(--accent); background: var(--accent-wash); }

/* ------------------------------------------------- стекло */

.glass { position: relative; z-index: 1; }
.glass::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  border-radius: inherit;
  backdrop-filter: blur(60px);
  -webkit-backdrop-filter: blur(60px);
  background: var(--glass-bg);
  border: 1px solid var(--glass-border, transparent);
}

/* --------------------------------- текстура: одно изображение, свой свет
   Тёмная «текучая 3D» фактура общая для .global и .team. Холдинг оставляет
   её ахроматичной, продукт подсвечивает своим цветом: mix-blend-mode: color
   берёт тон у верхнего слоя, светимость — у фотографии. */

.tex {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  isolation: isolate;
  pointer-events: none;
}
.tex img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: var(--tex-pos, center);
}
/* затемняющий слой: снимок один, а плотность света у каждого блока своя */
.tex::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--tex-scrim, transparent);
}
.tex::after {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--tex-tint, transparent);
  mix-blend-mode: color;
  opacity: var(--tex-tint-a, 0);
}

/* ------------------------------------------------- соцкнопки */

.social { display: flex; gap: 4px; }
.social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  border-radius: 10px;
  background: var(--accent-wash);
  color: var(--paper);
  transition: all .3s ease;
}
.social a svg { width: 26px; height: 26px; fill: currentColor; }
.social a:hover { background: var(--accent); color: var(--on-accent); }

/* ------------------------------------------------- переключатель языка */

.lang {
  display: flex;
  padding: 2px;
  border: 1px solid var(--paper-12);
  border-radius: var(--r-s);
  backdrop-filter: blur(30px);
}
.lang button {
  width: 44px;
  padding: 7px 9px 9px;
  border-radius: 6px;
  font-size: 16px;
  line-height: 120%;
  color: var(--paper-60);
  transition: all .25s ease;
}
.lang button:hover { background: rgba(252, 252, 252, .08); }
.lang button.on { background: var(--paper-12); color: var(--paper); }

/* ------------------------------------------------- логотип */

.logo svg, .logo img { display: block; width: 76px; height: 44px; }

/* ------------------------------------------------- адаптив ядра */

@media screen and (max-width: 1439.98px) {
  .container { max-width: 1140px; }
  body { font-size: 16px; }
  .badge { font-size: 16px; }
  .h1 { font-size: 60px; }
  .h2 { font-size: 48px; }
  .h3 { font-size: 36px; }
  .h4 { font-size: 24px; }
  .lead { font-size: 20px; }
  .body { font-size: 16px; }
  .small { font-size: 14px; }
  .btn { min-height: 59px; font-size: 16px; padding: 17px 26px 21px; }
  .btn--sm { min-height: 35px; font-size: 14px; }
  .logo svg, .logo img { width: 66px; height: 38px; }
}

@media screen and (max-width: 1199.98px) { .container { max-width: 932px; } }
@media screen and (max-width: 991.98px)  { .container { max-width: 708px; } .h1 { font-size: 44px; } }
@media screen and (max-width: 767.98px)  { .container { max-width: 556px; } }

@media screen and (max-width: 575.98px) {
  .container { max-width: 100%; padding: 0 20px; }
  .h1 { font-size: 32px; }
  .h2 { font-size: 30px; }
  .h3 { font-size: 26px; }
  .lead { font-size: 17px; }
  .social a { width: 52px; height: 52px; }
}

/* 320 px: «инфраструктура,» одним словом шире колонки — снимаем кегль */
@media screen and (max-width: 359.98px) {
  .h1 { font-size: 27px; }
  .h2 { font-size: 26px; }
  .h3 { font-size: 23px; }
  .lead { font-size: 16px; }
}

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