/* ==========================================================================
   Base / Reset
   Source: globals.css + resets
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
}

html, body {
  overflow-x: hidden;
  max-width: 100%;
}

body {
  font-family: var(--font-body);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background 0.3s ease, color 0.3s ease;
}

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

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

ul, ol {
  list-style: none;
}

button {
  font-family: inherit;
}

/* ==========================================================================
   Reveal Animations
   ========================================================================== */

.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-left {
  opacity: 0;
  transform: translateX(-40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-right {
  opacity: 0;
  transform: translateX(40px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal.visible,
.reveal-left.visible,
.reveal-right.visible {
  opacity: 1;
  transform: translate(0, 0);
}

/* Cascade child reveals when parent has .stagger */
.stagger > .reveal:nth-child(1) { transition-delay: 0s; }
.stagger > .reveal:nth-child(2) { transition-delay: 0.08s; }
.stagger > .reveal:nth-child(3) { transition-delay: 0.16s; }
.stagger > .reveal:nth-child(4) { transition-delay: 0.24s; }
.stagger > .reveal:nth-child(5) { transition-delay: 0.32s; }
.stagger > .reveal:nth-child(6) { transition-delay: 0.40s; }

/* ==========================================================================
   Layout primitives
   ========================================================================== */

.itb-container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: clamp(20px, 10vw, var(--container-pad));
}

/* Вертикальный ритм секций */
.itb-section {
  padding-block: var(--section-py);
}

.itb-section--alt {
  background: var(--bg-secondary);
}

/* ==========================================================================
   Заголовок секции
   ========================================================================== */

.itb-section__header {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 48px;
  max-width: 720px;
}

.itb-section__eyebrow {
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 12px;
  letter-spacing: 1.68px;
  text-transform: uppercase;
  color: var(--text-secondary);
}

.itb-section__title {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.08;
  letter-spacing: -1px;
  color: var(--text-primary);
}

.itb-section__subtitle {
  font-size: 17px;
  line-height: 1.55;
  color: var(--text-secondary);
}

/* ==========================================================================
   Кнопки
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-heading);
  font-weight: 600;
  font-size: 15.5px;
  line-height: 1;
  padding: 16px 28px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
  white-space: nowrap;
}

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

.btn--ghost {
  background: var(--surface-2);
  color: var(--text-primary);
  border-color: var(--border-color);
}
.btn--ghost:hover {
  background: var(--surface-2-hover);
}

.btn--circle {
  padding: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: transparent;
  border-color: var(--border-color);
  color: var(--text-secondary);
}
.btn--circle:hover {
  color: var(--text-primary);
  border-color: var(--border-tag);
}

/* ==========================================================================
   Тег / метка
   ========================================================================== */

.itb-tag {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-mono);
  font-weight: 700;
  font-size: 11px;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  color: var(--text-secondary);
  background: var(--accent-bg);
  border: 1px solid var(--border-tag);
  border-radius: var(--radius-sm);
  padding: 6px 12px;
}
