/* =============================================
   CARD.CSS — все стили карточек
   Редактируй только здесь, не в styles.css
   ============================================= */


/* ===== КАРТОЧКА (обёртка) ===== */
.card {
  border-radius: 9px;
  background: var(--fz-row);
  display: flex;
  flex-direction: column;
  width: 240px;
  flex: 0 0 240px;
  cursor: pointer;
  position: relative;
  isolation: isolate;
  border: 0.1px solid #ffee0080;
}

/* ===== СВЕЧЕНИЕ ЗА КАРТОЧКОЙ ===== */
.card::before {
  content: "";
  position: absolute;
  inset: -3px -13px 40px -12px; /* top right bottom left*/
  border-radius: 8px;
  z-index: 1000000;
  background: radial-gradient(
    ellipse 60% 80% at 15% 50%,
    var(--glow-left, transparent) 0%,
    transparent 70%
  ),
  radial-gradient(
    ellipse 60% 80% at 85% 50%,
    var(--glow-right, transparent) 0%,
    transparent 70%
  );
  opacity: 0;
  filter: blur(18px);
  transition: opacity 0.6s ease;
  pointer-events: none;
}

.card.card--glow-ready::before {
  opacity: 0.7;
}


/* ===== КАРТИНКА ===== */
.card__media--image {
  border-radius: 9px;
  height: 126px;
  flex: 0 0 126px;
  background-repeat: no-repeat;
  background-position: 50% 18%;
  background-size: cover;
  background-color: rgba(0, 0, 0, .2);
  position: relative;
}

/* Затемнение снизу картинки */
.card__media--image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0) 55%,
    rgba(0, 0, 0, .4) 100%
  );
}

/* ===== ЗАГЛУШКА: постера нет ни у источника, ни в TheSportsDB ===== */
.card__media--fallback {
  overflow: hidden;
  background-color: #0f0f16;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Размытый фон: пятна вместо плоской заливки, чтобы карточка не выглядела дырой */
.card__media--fallback::before {
  content: "";
  position: absolute;
  inset: -35%;
  background:
    radial-gradient(38% 55% at 22% 28%, rgba(255, 214, 0, .55), transparent 70%),
    radial-gradient(42% 60% at 80% 72%, rgba(255, 138, 0, .35), transparent 70%),
    radial-gradient(70% 90% at 50% 50%, rgba(38, 38, 56, .92), #0f0f16 78%);
  filter: blur(24px);
  transform: scale(1.1);
  pointer-events: none;
}

.card__media-logo {
  position: relative;
  z-index: 1;
  width: 58px;
  height: 58px;
  object-fit: contain;
  opacity: .95;
  filter: drop-shadow(0 3px 10px rgba(0, 0, 0, .6));
  user-select: none;
  pointer-events: none;
}


/* ===== ФУТЕР (нижняя часть с текстом) ===== */
.card__footer {
  flex: 0 0 auto;
  padding: 10px 11px 8px 14px;
  background: transparent;

  display: flex;
  flex-direction: column;
  gap: 5px;
}

.card__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
  flex-shrink: 0;
}

/* ===== ЗАГОЛОВОК ===== */
.card__footer .card__title {
  font-size: 15px;
  font-weight: 550;
  font-family: 'Mozilla Text', sans-serif;
  line-height: 1.25;
  margin: 0;
  color: #ffffff;

  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;

  /* фиксированный резерв под 2 строки — высота карточки не прыгает */
  min-height: calc(15px * 1.25 * 2);
}


/* ===== META (строка дата + таймер) ===== */
.card__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: var(--muted);
  flex-shrink: 0;
  margin-top: auto;
}

/* Левая часть мета (badge + тег) */
.card__left {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  overflow: hidden;
}

/* Правая часть мета (дата + таймер) */
.card__right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  flex: 0 0 auto;
}

.liveBadge {
  display: inline-flex;
  align-items: center;
  background: var(--fz-live);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .01em;
  padding: 4px 7px;
  border-radius: 4px;
  line-height: 1;
  margin-left: 0px;
}


/* ===== ДАТА ===== */
.card__date {
  font-size: 12px;
  white-space: nowrap;
}


/* ===== ТАЙМЕР ===== */
.card__timer {
  font-family: 'Mozilla Text', sans-serif;
  font-size: 12px;
  font-weight: 500;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  color: white;
}

/* ===== LIVE — точка и счётчик ===== */
.liveDotSmall {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--fz-live);
  margin-right: 5px;
  animation: livePulse 1.2s ease-in-out infinite;
}

@keyframes livePulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%       { opacity: 0.4; transform: scale(0.8); }
}

.live-num {
  color: #fff;
  font-weight: 800;
  text-shadow: 0 0 6px rgba(255, 255, 255, 0.4);
  font-size: 14px;
}

/* Кнопки ▲▼ для админа */
.live-arrow {
  border: 1px solid rgba(255, 255, 255, .15);
  background: rgba(255, 255, 255, .06);
  color: #fff;
  border-radius: 8px;
  width: 26px;
  height: 22px;
  line-height: 20px;
  cursor: pointer;
  margin: 0 6px;
  padding: 0;
  user-select: none;
}
.live-arrow:active { transform: translateY(1px); }


/* ===== PIN BUTTON ===== */
.card__pin-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.5);
  padding: 0;
  line-height: 1;
  display: flex;
  align-items: center;
  transition: color .2s ease, transform .15s ease;
}

.card__pin-btn:hover {
  color: rgba(255, 255, 255, 0.9);
  transform: scale(1.1);
}

.card__pin-btn.is-pinned {
  color: #FFD700;
}


/* ===== КОНТЕЙНЕР КАРТОЧЕК ===== */
.cards {
  display: grid;
  gap: 16px;
  overflow-x: auto;
  scrollbar-width: none;
}
.cards::-webkit-scrollbar { display: none; }

.cards--1-wide {
  display: flex;
  gap: 13px;
  justify-content: flex-start;
  align-items: flex-start;
  flex-wrap: nowrap;
  overflow-x: auto;
  overflow-y: visible;
  scrollbar-width: none;
  padding: 40px 150px;
  margin: -20px 0;
}

.cards--1-wide::-webkit-scrollbar { display: none; }


/* ===== ОБЁРТКА С ТУМАНОМ ===== */
.cards-wrap {
  position: relative;
  overflow: visible;
  scroll-margin-top: 120px;
}

/* Туман (скрыт по умолчанию) */
.cards-wrap::before,
.cards-wrap::after {
  content: "";
  position: absolute;
  top: 0;
  width: 56px;
  height: 100%;
  pointer-events: none;
  z-index: 5;
  opacity: 0;
  transition: opacity .2s ease;
}

.cards-wrap::before {
  left: 0;
  background: linear-gradient(to right, rgba(14,14,14,.95) 0%, rgba(14,14,14,.6) 35%, rgba(14,14,14,0) 100%);
}

.cards-wrap::after {
  right: 0;
  background: linear-gradient(to left, rgba(14,14,14,.95) 0%, rgba(14,14,14,.6) 35%, rgba(14,14,14,0) 100%);
}

.cards-wrap.has-left-fade::before { opacity: 1; }
.cards-wrap.has-right-fade::after  { opacity: 1; }


/* ===== СЕКЦИЯ — HEADER И СТРЕЛКИ ===== */
.section__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 2px;
  padding: 0 6px;
}

.section__header .section__title {
  margin-bottom: 0;
  text-align: left;
  color: #ffffff;
}

.section__arrows {
  display: flex;
  gap: 4px;
  flex: 0 0 auto;
  margin-right: 24px;
  visibility: hidden;
}
.section__title-wrap {
  flex: 1;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 10px;
}

.section__arrow {
  background: transparent;
  border: none;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.7);
  padding: 0;
  display: flex;
  align-items: center;
  transition: color .2s ease, transform .15s ease;
}

.section__arrow:hover {
  color: #fff;
  transform: scale(1.1);
}


/* ===== МОБИЛЬНЫЕ СТИЛИ (≤768px) ===== */
@media (max-width: 768px) {

  .cards--1-wide {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: start;
  overflow-x: visible;
  padding-left: 0;
  gap:12px;
  padding: 0 12px;
  }
  .card {
    flex-direction: column;
    width: 100%;
    flex: 0 0 auto;
    height: auto;
  }

  .card__media--image {
  width: 100%;
  min-width: 0;
  max-width: 100%;
  height: 110px;
  flex: 0 0 110px;
  background-size: cover;
  background-position: center;
 }

  .card__media--image::after {
    background: linear-gradient(
      to bottom,
      rgba(0, 0, 0, 0) 55%,
      rgba(0, 0, 0, .4) 100%
    );
  }

  .card__media-logo {
    width: 48px;
    height: 48px;
  }

  .card__footer {
    flex: 0 0 auto;
    height: auto;
    padding: 10px 14px;
    gap: 2px;
  }

  .card__footer .card__title {
    font-size: 15px;
    line-height: 1.3;
    margin: 0;
    min-height: calc(15px * 1.3 * 2);
  }

  .card__meta {
    font-size: 11px;
  }

  .card__date,
  .card__timer {
    font-size: 11px;
    line-height: 1.2;
    white-space: nowrap;
  }

  .cards-wrap::before,
  .cards-wrap::after { display: none; }

  .section__arrows { display: none; }

  .section__header {
  padding-top: 34px;
  padding-bottom: 30px;
  }

  .card__section-label {
    display: none;
  }

  .card__section-sep,
  .card__section-label {
    display: none;
  }

  .card__section-sep:has(+ .card__section-label--live),
  .card__section-label--live {
    display: inline;
  }

}

.auth-btn--login {
  border: none;
  background: transparent;
  font-family: 'Mozilla Text', sans-serif;
  color: #fff;
}

.auth-btn--logout {
  border: none;
  background: transparent;
  font-family: 'Mozilla Text', sans-serif;
  color: #fff;
}

.auth-btn--register {
  border: none;
  background: transparent;
  color: #fff;
}

/* ===== JUMP TO SECTION ===== */
.jump-nav {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
  padding: 20px 20px 20px; 
}

@media (min-width: 769px) {
  .jump-nav {
    margin-left: 0;
  }
}

.jump-nav__item {
  display: inline-flex;
  align-items: center;
  gap: 0;
  border-radius: 8px;
  border: .5px solid var(--fz-stroke);
  overflow: hidden;
  cursor: pointer;
  text-decoration: none;
  transition: border-color .15s;
  user-select: none;
  height: 35px;
}

.jump-nav__item:hover {
  border-color: rgba(255,255,255,.3);
}

.jump-nav__count {
  padding: 9px 12px;
  font-size: 12.5px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  background: var(--fz-row);
  color: rgb(255, 255, 255);
  border-left: .5px solid #ff0000a9;
  line-height: 1;
  display: flex;
  align-items: center;
}

.jump-nav__label {
  padding: 9px 15px;
  font-size: 13px;
  font-weight: 500;
  color: rgba(255,255,255,.8);
  background: var(--fz-row);
  line-height: 1;
  white-space: nowrap;
  font-family: 'Mozilla Text', sans-serif;
  padding-left: 8px
}

.jump-nav__count--live {
  background: rgba(255,59,59,.1);
  border-right-color: rgba(255,59,59,.2);
}

.jump-nav__item:hover .jump-nav__label {
  color: #fff;
}

.card__section-sep {
  color: rgba(255, 255, 255, 0.342);
  font-size: 13px;
  margin: 0 2px;
}

.card__section-label {
  font-size: 10px;
  color: rgba(255, 255, 255, 0.829);
  font-family: 'Mozilla Text', sans-serif;
  text-transform: uppercase;
  letter-spacing: .0em;
  flex: 1;
  padding-top: 0px;
}

/* ===== VIEW ALL / EXPANDED GRID ===== */

.section__view-all {
  display: none;
  margin-bottom: 5px;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.45);
  font-size: 13px;
  font-weight: 500;
  font-family: 'Mozilla Text', sans-serif;
  cursor: pointer;
  transition: color .2s ease;
  white-space: nowrap;
  align-self: flex-end; 
}

.section__view-all:hover {
  color: rgba(255, 255, 255, 0.85);
}

@media (min-width: 769px) {
  .section__view-all { display: block; visibility: hidden; }
  .cards--expanded {
    flex-wrap: wrap;
    overflow-x: visible;
    padding-left: 159px;
    padding-right: 24px;
    align-items: flex-end;
  }
}

/* =====================================================================
   РЯДЫ СОБЫТИЙ
   Список во всю ширину вместо горизонтальной ленты карточек.
   Блок стоит в конце файла намеренно: он перекрывает старые правила
   сеток, включая мобильные — их не трогаем, чтобы можно было откатиться.
   ===================================================================== */

.cards--1-wide,
.cards--1-wide.cards--expanded {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: 8px;
  /* справа поле шире левого: там стоит колонка Discord (260px + 20px
     от края) и между ней и рядами остаётся 28px зазора */
  padding: 6px 308px 10px 60px;
  margin: 0;
  overflow: visible;
}

/* Списку не нужны ни стрелки, ни туман по краям */
.section__arrows { display: none !important; }
.cards-wrap::before,
.cards-wrap::after { display: none; }

/* ── сам ряд ── */
.erow {
  display: grid;
  grid-template-columns: 78px 1fr 190px;
  align-items: center;
  gap: 14px;
  padding: 11px 14px;
  background: var(--fz-row);
  border: 1px solid var(--fz-stroke);
  border-left: 3px solid #3b4356;
  border-radius: 8px;
  cursor: pointer;
  transition: border-color .15s ease, background .15s ease;
}

/* Подсветку на наведении делаем внутренней тенью, а не заливкой:
   иначе она затирала бы фоновую картинку секции. */
.erow:hover {
  border-color: #ffee0080;
  box-shadow: inset 0 0 0 999px rgba(255, 255, 255, .04);
}

/* Статус читается по левому ребру: эфир, ближайший час, позже */
.erow--live {
  border-left-color: var(--fz-live);
  /* Красное только у левого края: раньше растяжка до 38% ширины
     заливала полряда и спорила с фоном секции. */
  background: linear-gradient(90deg, rgba(255, 90, 106, .14), rgba(27, 31, 42, 0) 14%), var(--fz-row);
}
.erow--soon { border-left-color: #ffee00; }

/* ── фоны секций ──
   Картинку кладём в ::before, а не в background самого ряда: так её можно
   кадрировать через cover без искажения пропорций и не воевать с фоном
   .erow--live. Класс ряду выдаёт EventCard по секции события. */
.erow--football,
.erow--americanfootball,
.erow--baseball {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background: var(--fz-row);
}

.erow--football::before,
.erow--americanfootball::before,
.erow--baseball::before {
  content: "";
  position: absolute;
  /* Картинка занимает не всю ширину, а середину: по 20% с каждой стороны
     остаётся чистый фон ряда. Заодно растягивать её приходится в полтора
     раза меньше — деталей видно больше. */
  inset: 0 20%;
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  filter: saturate(.85);

  /* Края растворяются в фоне, чтобы не было видно, где картинка кончается */
  -webkit-mask-image: linear-gradient(90deg,
    transparent 0%, #000 16%, #000 84%, transparent 100%);
  mask-image: linear-gradient(90deg,
    transparent 0%, #000 16%, #000 84%, transparent 100%);
}

/* Кадрирование зашито в сами файлы: из каждой фотографии вырезана полоса
   вокруг линии горизонта, поэтому здесь везде простой center — сверху небо
   и трибуны, снизу поле. Заодно втрое меньше вес: лишние пиксели, которые
   ряд всё равно обрезал бы, в файле не лежат. */
.erow--football::before  { background-image: url('/football-row.webp'); }
.erow--americanfootball::before { background-image: url('/amfootball-row.webp'); }
.erow--baseball::before  { background-image: url('/baseball-row.webp'); }

/* Затемнение неравномерное: к центру плотнее, чтобы читались названия
   команд, по краям светлее — там поле и остаётся видно. */
/* Затемнение перевёрнуто по сравнению с прежним: картинка теперь в середине,
   поэтому центр светлее, а к краям плотнее — там она и так растворяется. */
.erow--football::after,
.erow--americanfootball::after,
.erow--baseball::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
    rgba(27, 31, 42, .9) 0%,
    rgba(27, 31, 42, .76) 26%,
    rgba(27, 31, 42, .76) 74%,
    rgba(27, 31, 42, .9) 100%);
}

/* Красную подсветку живого ряда подмешиваем сюда же */
.erow--football.erow--live::after,
.erow--americanfootball.erow--live::after,
.erow--baseball.erow--live::after {
  background:
    linear-gradient(90deg, rgba(255, 90, 106, .28), rgba(27, 31, 42, 0) 14%),
    linear-gradient(90deg,
      rgba(27, 31, 42, .9) 0%,
      rgba(27, 31, 42, .76) 26%,
      rgba(27, 31, 42, .76) 74%,
      rgba(27, 31, 42, .9) 100%);
}

/* ── фотография места проведения (трасса Формулы-1) ──
   Кадрируется как фоны секций: cover по середине ряда, края растворяются,
   сверху то же неравномерное затемнение. Отличие от .erow--show в том,
   что это панорама — её нужно резать, а не показывать целиком. */
.erow--photo {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background: var(--fz-row);
}

.erow--photo::before {
  content: "";
  position: absolute;
  inset: 0 20%;
  background-image: var(--show-bg);
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  filter: saturate(.85);

  -webkit-mask-image: linear-gradient(90deg,
    transparent 0%, #000 16%, #000 84%, transparent 100%);
  mask-image: linear-gradient(90deg,
    transparent 0%, #000 16%, #000 84%, transparent 100%);
}

.erow--photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
    rgba(27, 31, 42, .9) 0%,
    rgba(27, 31, 42, .76) 26%,
    rgba(27, 31, 42, .76) 74%,
    rgba(27, 31, 42, .9) 100%);
}

.erow--photo.erow--live::after {
  background:
    linear-gradient(90deg, rgba(255, 90, 106, .28), rgba(27, 31, 42, 0) 14%),
    linear-gradient(90deg,
      rgba(27, 31, 42, .9) 0%,
      rgba(27, 31, 42, .76) 26%,
      rgba(27, 31, 42, .76) 74%,
      rgba(27, 31, 42, .9) 100%);
}

/* ── фон отдельного шоу (реслинг) ──
   Картинку сюда передаёт компонент через --show-bg: у каждого шоу своя,
   секцией её не задать. Это леттеринг, а не панорама, поэтому размер
   не cover, а по высоте — логотип виден целиком и не режется. */
.erow--show::before {
  content: "";
  position: absolute;
  inset: 0 20%;
  background-image: var(--show-bg);
  background-repeat: no-repeat;
  background-position: center;
  /* По высоте ряда, а не больше него: на 165% логотип обрезался сверху
     и снизу. 72% оставляют поля и логотип виден целиком. */
  background-size: auto 72%;
  opacity: .5;

  -webkit-mask-image: linear-gradient(90deg,
    transparent 0%, #000 16%, #000 84%, transparent 100%);
  mask-image: linear-gradient(90deg,
    transparent 0%, #000 16%, #000 84%, transparent 100%);
}

.erow--show::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg,
    rgba(27, 31, 42, .84) 0%,
    rgba(27, 31, 42, .55) 26%,
    rgba(27, 31, 42, .55) 74%,
    rgba(27, 31, 42, .84) 100%);
}

.erow--show.erow--live::after {
  background:
    linear-gradient(90deg, rgba(255, 90, 106, .28), rgba(27, 31, 42, 0) 14%),
    linear-gradient(90deg,
      rgba(27, 31, 42, .84) 0%,
      rgba(27, 31, 42, .55) 26%,
      rgba(27, 31, 42, .55) 74%,
      rgba(27, 31, 42, .84) 100%);
}

.erow--show {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

/* Содержимое ряда — поверх картинки и затемнения.
   Без этого ::before и ::after (они позиционированы) рисуются выше
   обычного текста, и название с временем оказываются под затемнением. */
.erow--football > *,
.erow--americanfootball > *,
.erow--baseball > *,
.erow--photo > *,
.erow--show > * { position: relative; z-index: 1; }

/* ── левая колонка: время ── */
.erow__when { min-width: 0; }

.erow__time {
  display: block;
  font-family: 'Bebas Neue', 'Mozilla Text', sans-serif;
  font-size: 24px;
  line-height: 1;
  letter-spacing: .03em;
  color: #fff;
  font-variant-numeric: tabular-nums;
}
.erow__time.is-live { color: var(--fz-live); }

.erow__cap {
  display: block;
  margin-top: 3px;
  font-family: 'Mozilla Text', sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .45);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

/* ── центр: противостояние ── */
.erow__match {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.erow__side { display: flex; align-items: center; gap: 9px; min-width: 0; }
.erow__side--home { justify-content: flex-end; text-align: right; }
.erow__side--away { justify-content: flex-start; }

.erow__team {
  font-family: 'Mozilla Text', sans-serif;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  text-shadow: 0 1px 6px rgba(0, 0, 0, .75);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.erow__vs {
  font-family: 'Bebas Neue', 'Mozilla Text', sans-serif;
  font-size: 16px;
  line-height: 1;
  letter-spacing: .06em;
  color: #ffee00;
}

.erow__badge {
  width: 34px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 50%;
  overflow: hidden;
  display: grid;
  place-items: center;
  font-family: 'Mozilla Text', sans-serif;
  font-weight: 700;
  font-size: 12px;
  letter-spacing: .02em;
  color: #fff;
  background: #39415f;
  border: 2px solid rgba(255, 255, 255, .85);
}

/* Эмблемы TheSportsDB — прозрачные PNG, поэтому подкладываем белое */
.erow__badge img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 2px;
  background: #fff;
}

/* ── событие без пары команд: UFC, реслинг, каналы ── */
/* Слева, а не по центру: у моторспорта, реслинга и единоборств названия
   длинные и по центру читались хуже. */
.erow__single { display: flex; align-items: center; gap: 11px; min-width: 0; }

.erow__badge--logo { background: #141420; border-color: rgba(255, 255, 255, .3); }
.erow__badge--logo img { background: transparent; padding: 4px; }

/* ── правая колонка ── */
.erow__meta { display: flex; align-items: center; justify-content: flex-end; gap: 11px; }

.erow__cat {
  font-family: 'Mozilla Text', sans-serif;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  /* Mozilla Text шире Barlow: прежняя разрядка растягивала слово */
  letter-spacing: .01em;
  color: rgba(255, 255, 255, .55);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 130px;
}

.erow__eye {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 600;
  color: rgba(255, 255, 255, .75);
  font-variant-numeric: tabular-nums;
}
.erow__eye svg { width: 14px; height: 14px; }

/* У живого ряда категория идёт перед счётчиком и не должна
   перетягивать на себя внимание */
.erow--live .erow__cat { color: rgba(255, 255, 255, .45); }

.erow__pin {
  background: transparent;
  border: 0;
  padding: 0;
  line-height: 1;
  display: flex;
  color: rgba(255, 255, 255, .45);
  cursor: pointer;
  transition: color .2s ease, transform .15s ease;
}
.erow__pin:hover { color: rgba(255, 255, 255, .9); transform: scale(1.1); }
.erow__pin.is-pinned { color: #FFD700; }

/* ── планшет: убираем огромные поля ── */
@media (max-width: 1200px) {
  .cards--1-wide,
  .cards--1-wide.cards--expanded { padding: 6px 24px 10px; }
}

/* ── телефон: ряд ломается на два этажа ── */
@media (max-width: 768px) {
  .cards--1-wide,
  .cards--1-wide.cards--expanded {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 0 12px;
  }

  .erow {
    grid-template-columns: auto 1fr;
    grid-template-areas:
      "match match"
      "when  meta";
    gap: 9px 10px;
    padding: 12px 13px;
  }

  .erow__match,
  .erow__single { grid-area: match; }

  .erow__when {
    grid-area: when;
    display: flex;
    align-items: baseline;
    gap: 7px;
    border-top: 1px solid rgba(255, 255, 255, .08);
    padding-top: 9px;
  }

  .erow__meta {
    grid-area: meta;
    border-top: 1px solid rgba(255, 255, 255, .08);
    padding-top: 9px;
  }

  .erow__time { font-size: 18px; }
  .erow__cap { margin-top: 0; }
  .erow__team { font-size: 14px; }
  .erow__badge { width: 30px; height: 30px; font-size: 11px; }
}


/* =====================================================================
   КОЛОНКА DISCORD
   Стоит справа от списка событий, в поле, которое и так пустует
   на широких экранах. Фон — скриншот участников, заблюренный заранее
   в самом файле: CSS-фильтр на такой большой площади стоит кадров.
   ===================================================================== */

.djoin {
  position: fixed;
  right: 20px;
  top: 120px;
  bottom: 20px;
  width: 260px;
  z-index: 40;

  display: block;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--fz-stroke);
  /* фон рисуем по внутреннему краю рамки, иначе он вылезает
     из-под неё на скруглениях */
  background: var(--fz-row-2) padding-box;
  text-decoration: none;
  transition: border-color .2s ease;
}

.djoin::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: url('/discord-bg.webp') center / cover no-repeat;
}

/* Затемнение: сверху легче, книзу плотнее — текст стоит по центру */
.djoin::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(10, 10, 16, .5), rgba(10, 10, 16, .72));
  transition: background .2s ease;
}

.djoin__inner {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 20px 14px;
}

.djoin__mark {
  width: 62px;
  height: auto;
  filter: drop-shadow(0 2px 10px rgba(0, 0, 0, .7));
}

.djoin__text {
  font-family: 'Bebas Neue', 'Mozilla Text', sans-serif;
  font-size: 30px;
  line-height: 1;
  letter-spacing: .045em;
  text-align: center;
  color: #fff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, .8);
}

.djoin:hover { border-color: #ffee0080; }
.djoin:hover::after {
  background: linear-gradient(180deg, rgba(10, 10, 16, .42), rgba(10, 10, 16, .68));
}

.djoin:focus-visible {
  outline: 2px solid #ffee00;
  outline-offset: 3px;
}

/* Узкие экраны: поля у списка исчезают, колонке негде стоять */
@media (max-width: 1200px) {
  .djoin { display: none; }
}


/* =====================================================================
   ЗАГОЛОВКИ СЕКЦИЙ И ТОЧКА LIVE
   ===================================================================== */

/* Поля те же, что у рядов: заголовок центруется по списку событий,
   а не по всей ширине страницы — иначе он уезжает вправо на ширину
   колонки Discord. */
/* Ровно те же поля, что у рядов, и никакого flex: заголовок центруется
   по списку событий. Стрелки и «View all» скрыты, растягивать под них
   контейнер больше не нужно — а именно он и сбивал ось. */
.section__header {
  display: block;
  padding: 0 308px 0 60px;
  text-align: center;
}

.section__title-wrap { display: block; }

.section__header .section__title { text-align: center; }

/* Кнопка "View all" на десктопе и так была visibility:hidden, но место
   занимала — и сдвигала заголовок влево от центра. Список теперь
   вертикальный и всегда раскрыт, кнопка не нужна вовсе. */
.section__view-all { display: none; }

@media (max-width: 1200px) {
  .section__header { padding: 0 24px; }
}

@media (max-width: 768px) {
  .section__header { padding: 34px 12px 30px; }
}

/* Точка эфира вместо эмодзи 🔴: размер и пульсацию у эмодзи не задать */
.section__live-dot {
  display: inline-block;
  width: 13px;
  height: 13px;
  margin-right: 11px;
  border-radius: 50%;
  background: var(--fz-live);
  vertical-align: middle;
  animation: fzLiveDot 2.4s ease-in-out infinite;
}

@keyframes fzLiveDot {
  0%, 100% { opacity: 1;   box-shadow: 0 0 0 0 rgba(255, 90, 106, .5); }
  50%      { opacity: .5;  box-shadow: 0 0 0 7px rgba(255, 90, 106, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .section__live-dot { animation: none; }
}


/* =====================================================================
   JUMP NAV — размер, центровка и отдельный вид у LIVE
   Поля те же, что у .cards--1-wide и заголовков секций (60px слева,
   308px справа под колонку Discord), поэтому все три блока центруются
   по одной оси — по списку событий, а не по ширине страницы.
   ===================================================================== */

.jump-nav {
  gap: 10px;
  padding: 24px 308px 22px 60px;
}

.jump-nav__item {
  height: 40px;
  border-radius: 10px;
  align-items: stretch;
}

/* Половинки плашки центруют содержимое сами: раньше выравнивание держалось
   на подобранных paddings, и эмодзи с разной высотой сбивали текст с оси. */
.jump-nav__label,
.jump-nav__count {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 0 15px;
  line-height: 1;
}

.jump-nav__label { font-size: 14px; }
.jump-nav__count { font-size: 13.5px; }

/* ── LIVE: не плашка со счётчиком, а отдельная кнопка ── */
.jump-nav__item--live {
  border-color: rgba(255, 90, 106, .55);
  background: linear-gradient(180deg, rgba(255, 90, 106, .2), rgba(255, 90, 106, .07));
  transition: border-color .15s ease, box-shadow .15s ease;
}

.jump-nav__item--live:hover {
  border-color: var(--fz-live);
  box-shadow: 0 0 0 3px rgba(255, 90, 106, .14);
}

/* Убираем разделитель и фон у левой половины — внутри только точка */
.jump-nav__item--live .jump-nav__count--live {
  border: 0;
  background: transparent;
  padding: 0 0 0 15px;
}

.jump-nav__item--live .jump-nav__label {
  background: transparent;
  padding: 0 16px 0 9px;
  color: #ff7676;
  font-weight: 700;
  letter-spacing: .1em;
}

.jump-nav .liveDotSmall { width: 8px; height: 8px; margin: 0; }

@media (max-width: 1200px) {
  .jump-nav { padding: 22px 24px; }
}

@media (max-width: 768px) {
  .jump-nav { gap: 8px; padding: 18px 12px; }
  .jump-nav__item { height: 36px; }
  .jump-nav__label { font-size: 13px; padding: 0 12px; }
  .jump-nav__count { font-size: 12.5px; padding: 0 12px; }
  .jump-nav__item--live .jump-nav__count--live { padding-left: 12px; }
  .jump-nav__item--live .jump-nav__label { padding: 0 13px 0 8px; }
}


/* =====================================================================
   ШИРИНА РЯДОВ
   Поля контейнера не трогаем — по ним центруются заголовки секций
   и навигация. Ограничиваем сами ряды и центруем их в той же коробке,
   поэтому общая ось не съезжает. Меняется одним числом.
   ===================================================================== */

.cards--1-wide,
.cards--1-wide.cards--expanded { align-items: center; }

.erow {
  width: 100%;
  max-width: 1200px;
}

@media (max-width: 1200px) {
  .erow { max-width: none; }
}


/* =====================================================================
   ЛЕВАЯ КОЛОНКА — ПИЛЮЛЯ
   Время лежит в плашке, а у живого события на её месте стоит бейдж LIVE:
   он переехал сюда из правой части ряда. Ширина у них одинаковая,
   поэтому в момент начала матча колонка не дёргается.
   ===================================================================== */

/* Только на десктопе: на телефоне ряд живёт по grid-template-areas,
   и безусловное правило перебивало их — середина сжималась до буквы. */
@media (min-width: 769px) {
  .erow { grid-template-columns: 74px 1fr 190px; }
}

/* Колонкой, чтобы дата встала над пилюлей и не толкала её вбок */
.erow__when {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
}

.erow__day {
  /* Ширина как у пилюли и текст по центру: иначе короткая дата
     («Fri 11») и длинная («Sun 14») висели бы по-разному. */
  min-width: 66px;
  text-align: center;
  font-size: 10px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: .01em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, .5);
  white-space: nowrap;
}

.erow__time,
.erow__when .liveBadge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 66px;
  height: 27px;
  padding: 0 10px;
  border-radius: 7px;
  line-height: 1;
}

.erow__time {
  background: rgba(255, 255, 255, .07);
  font-family: 'Barlow', 'Mozilla Text', sans-serif;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  font-variant-numeric: tabular-nums;
}

.erow__when .liveBadge {
  margin: 0;
  font-size: 12px;
  letter-spacing: .01em;
}

/* Подпись с отсчётом больше не выводится */
.erow__cap { display: none; }

@media (max-width: 768px) {
  /* На телефоне место в строку, поэтому дата идёт рядом с временем */
  .erow__when {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 7px;
  }

  /* В строке ширина пилюли ни к чему — она бы отодвинула время */
  .erow__day { min-width: 0; }
  .erow__time,
  .erow__when .liveBadge { min-width: 60px; height: 25px; font-size: 13px; }
}
