/* =========================================================
   blocks-stats.min.css — блок «Цифры-достижения» (.c-stats).
   Стиль сайта: квадратные углы, акцент #b00a27, плавные переходы.
   Эффекты при hover: выезжающая полоса сверху + подъём + тень.
   ========================================================= */

.c-stats { margin: 56px 0; }

/* ---------- Шапка ---------- */
.c-stats__head {
  margin: 0 0 40px;
  max-width: 780px;
}
.c-stats__title {
  margin: 0 0 10px;
  font-size: clamp(22px, 2.4vw, 30px);
  line-height: 1.2;
  font-weight: 700;
  color: var(--c-text);
  position: relative;
  padding-left: 18px;
}
/* Красная засечка перед заголовком */
.c-stats__title::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.18em;
  bottom: 0.18em;
  width: 4px;
  background: var(--c-accent);
}
.c-stats__lead { margin: 10px 0 0; font-size: 16px; line-height: 1.6; color: var(--c-text-mute); }

/* ---------- Сетка ---------- */
.c-stats__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1px;
  background: var(--c-border);
  border: 1px solid var(--c-border);
}
.c-stats--cols-2 .c-stats__list { grid-template-columns: repeat(2, 1fr); }
.c-stats--cols-3 .c-stats__list { grid-template-columns: repeat(3, 1fr); }
.c-stats--cols-4 .c-stats__list { grid-template-columns: repeat(4, 1fr); }

/* ---------- Ячейка ---------- */
.c-stats__item {
  position: relative;
  background: var(--c-bg);
  padding: 36px 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow: hidden;
  transition:
    background-color var(--c-transition),
    transform var(--c-transition);
}

/* Выезжающая полоса сверху при hover (как в .c-card--line-top) */
.c-stats__item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: var(--c-accent);
  transition: width 0.4s cubic-bezier(0.22, 0.61, 0.36, 1);
}
.c-stats__item:hover::before {
  width: 100%;
}

/* Лёгкий фоновый градиент при hover */
.c-stats__item::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 100% 0%, rgba(176, 10, 39, 0.05), transparent 60%);
  opacity: 0;
  transition: opacity 0.35s ease;
  pointer-events: none;
  z-index: 0;
}
.c-stats__item:hover::after {
  opacity: 1;
}

/* ---------- Значение ---------- */
.c-stats__value {
  display: flex;
  align-items: baseline;
  gap: 2px;
  font-size: clamp(34px, 4.6vw, 52px);
  line-height: 1;
  font-weight: 700;
  color: var(--c-accent);
  font-variant-numeric: tabular-nums;
  position: relative;
  z-index: 1;
}
.c-stats__prefix,
.c-stats__suffix,
.c-stats__trail {
  font-size: 0.55em;
  font-weight: 700;
  color: var(--c-accent);
}
.c-stats__suffix {
  margin-left: 4px;
  font-weight: 600;
  opacity: 0.85;
}

/* ---------- Подпись ---------- */
.c-stats__label {
  font-size: 14px;
  line-height: 1.55;
  color: var(--c-text-mute);
  position: relative;
  z-index: 1;
  transition: color var(--c-transition);
}
.c-stats__item:hover .c-stats__label {
  color: var(--c-text);
}

/* =========================================================
   Вариант "dark" — тёмный фон, светлый текст
   ========================================================= */
.c-stats--dark .c-stats__list {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.08);
}
.c-stats--dark .c-stats__item {
  background: var(--c-bg-dark);
}
.c-stats--dark .c-stats__title { color: #ffffff; }
.c-stats--dark 
.c-stats--dark .c-stats__label { color: rgba(255, 255, 255, 0.7); }
.c-stats--dark .c-stats__value,
.c-stats--dark .c-stats__prefix,
.c-stats--dark .c-stats__suffix,
.c-stats--dark .c-stats__trail {
  color: #ffffff;
}
.c-stats--dark .c-stats__item::after {
  background: radial-gradient(circle at 100% 0%, rgba(176, 10, 39, 0.28), transparent 60%);
}
.c-stats--dark .c-stats__item:hover .c-stats__label {
  color: #ffffff;
}

/* =========================================================
   Адаптив
   ========================================================= */
@media (max-width: 900px) {
  .c-stats { margin: 40px 0; }
  .c-stats--cols-4 .c-stats__list { grid-template-columns: repeat(2, 1fr); }
  .c-stats--cols-3 .c-stats__list { grid-template-columns: repeat(2, 1fr); }
  .c-stats__item { padding: 28px 22px; }
}
@media (max-width: 480px) {
  .c-stats--cols-2 .c-stats__list,
  .c-stats--cols-3 .c-stats__list,
  .c-stats--cols-4 .c-stats__list { grid-template-columns: 1fr; }
  .c-stats { margin: 32px 0; }
  .c-stats__value { font-size: 34px; }
  .c-stats__item { padding: 24px 20px; }
}