@font-face {
  font-family: 'SF Pro Display';
  src: url('hui.ttf') format('truetype');
  font-weight: 900;
  font-style: italic;
}

* {
  box-sizing: border-box;
}
/* Общие стили для контейнера */
.logos2 {
  display: flex; /* Для центровки изображения */
  justify-content: center;
  align-items: center;
  max-width: 300px; /* Максимальная ширина контейнера */
  margin: 0 auto; /* Центровка по горизонтали */
  padding: 0px; /* Отступы вокруг изображения */
  border: none; /* Убираем границу */
  border-radius: 0; /* Убираем скругленные углы */
  background-color: transparent; /* Убираем белый фон */
}

/* Стили для изображения */
.logos2 img {
  width: 100%; /* Изображение занимает всю ширину контейнера */
  max-width: 300px; /* Ограничение максимальной ширины */
  height: auto; /* Сохраняет пропорции изображения */
  object-fit: contain; /* Гарантирует корректное отображение */
}

/* Адаптивные стили */
@media (max-width: 768px) {
  .logos2 {
      max-width: 500px; /* Уменьшаем ширину контейнера на мобильных устройствах */
      margin-top: 100px;
  }

  .logos2 img {
      max-width: 500px; /* Уменьшаем изображение для мобильных */
  }
}

@media (min-width: 769px) {
  .logos2 {
      max-width: 900px; /* Увеличиваем ширину контейнера на больших экранах */
  }

  .logos2 img {
      max-width: 900px; /* Увеличиваем изображение для ПК */
  }
}



.logo {
  position: absolute;
  top: -80px;
  left: 20px;
  z-index: 100;
}

.mode-switch {
  position: absolute;
  top: -90px;
  right: 10px;
  z-index: 1000;
}

.logo img {
  width: 100px;
  height: auto;
  opacity: 0.8;
}

.flex {
  display: flex;
  background: radial-gradient(50% 50% at 50% 50%, #151b2e 0, rgba(21, 27, 46, 0) 100%);
  margin-top: 100px;
}

.justify-center {
  justify-content: center;
}

.align-middle {
  vertical-align: middle;
}

.cells-board-wrapper {
  margin: 20px auto;
  position: relative;
  width: min(320px, 90vw);
}

.cells-board-wrapper::before {
  content: url('img/before.svg');
  position: absolute;
  top: 20%;
  left: -18%;
  z-index: -1;
  transform: translateX(10%);
}

.cells-board-wrapper::after {
  content: url('img/after.svg');
  position: absolute;
  top: 0%;
  left: 101%;
  z-index: -1;
  transform: translateX(-10%);
}

@media (min-width: 768px) {
  .cells-board-wrapper {
    margin: 30px auto;
  }
}/* Общие стили для контейнера */
.logos2 {
  display: flex; /* Для центровки изображения */
  justify-content: center;
  align-items: center;
  max-width: 300px; /* Максимальная ширина контейнера */
  margin: 0 auto; /* Центровка по горизонтали */
  padding: 0px; /* Отступы вокруг изображения */
  border: none; /* Убираем границу */
  border-radius: 0; /* Убираем скругленные углы */
  background-color: transparent; /* Убираем белый фон */
}

/* Стили для изображения */
.logos2 img {
  width: 100%; /* Изображение занимает всю ширину контейнера */
  max-width: 300px; /* Ограничение максимальной ширины */
  height: auto; /* Сохраняет пропорции изображения */
  object-fit: contain; /* Гарантирует корректное отображение */
}

/* Адаптивные стили */
@media (max-width: 768px) {
  .logos2 {
      max-width: 500px; /* Уменьшаем ширину контейнера на мобильных устройствах */
      margin-top: 100px;
  }

  .logos2 img {
      max-width: 500px; /* Уменьшаем изображение для мобильных */
  }
}

@media (min-width: 769px) {
  .logos2 {
      max-width: 900px; /* Увеличиваем ширину контейнера на больших экранах */
  }

  .logos2 img {
      max-width: 900px; /* Увеличиваем изображение для ПК */
  }
}



.logo {
  position: absolute;
  top: 0px;
  left: 20px;
  z-index: 120;
}

.mode-switch {
  position: absolute;
  top: -90px;
  right: 10px;
  z-index: 1000;
}

.logo img {
  width: 100px;
  height: auto;
  opacity: 0.8;
}

.flex {
  display: flex;
  background: radial-gradient(50% 50% at 50% 50%, #151b2e 0, rgba(21, 27, 46, 0) 100%);
  margin-top: 100px;
}

.justify-center {
  justify-content: center;
}

.align-middle {
  vertical-align: middle;
}

.cells-board-wrapper {
  margin: 20px auto;
  position: relative;
  width: min(320px, 90vw);
}

.cells-board-wrapper::before {
  content: url('img/before.svg');
  position: absolute;
  top: 20%;
  left: -18%;
  z-index: -1;
  transform: translateX(10%);
}

.cells-board-wrapper::after {
  content: url('img/after.svg');
  position: absolute;
  top: 0%;
  left: 101%;
  z-index: -1;
  transform: translateX(-10%);
}

@media (min-width: 768px) {
  .cells-board-wrapper {
    margin: 30px auto;
  }
}
body {
  background-color: #0a0f1d;
  margin: 0;
  font-family: 'SF Pro Display', sans-serif;
  overflow-x: hidden;
  min-height: 100vh;
}

.flex {
  display: flex;
  background: radial-gradient(50% 50% at 50% 50%, #151b2e 0, rgba(21, 27, 46, 0) 100%);
}

.justify-center {
  justify-content: center;
}

.align-middle {
  vertical-align: middle;
}

.cells-board-wrapper {
  margin: 20px auto;
  position: relative;
  width: min(320px, 90vw);
}

@media (min-width: 768px) {
  .cells-board-wrapper {
    margin: 30px auto;
  }
}

.cells-board {
  background-color: #0a0f1d;
  background-image: url('img/cellsFrame.png');
  background-position: 50%;
  background-repeat: no-repeat;
  background-size: 100%;
  border-radius: 25px;
  box-shadow: 0 -2px 20px rgba(42, 49, 69, .4), 0 4px 54px rgba(42, 49, 69, .2);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: repeat(5, 1fr);
  gap: 4px;
  padding: 10px;
  position: relative;
  width: min(320px, 90vw);
  height: min(320px, 90vw);
  margin: 0 auto;
}

.cell {
  background: transparent;
  border: none;
  align-items: center;
  display: flex;
  justify-content: center;
  z-index: 1;
  width: 100%;
  height: 100%;
  padding: 0;
  position: relative;
}

.cell img {
  width: 85%;
  height: 85%;
  display: block;
  object-fit: contain;
}

.cells-board-mask {
  height: 100%;
  width: 100%;
  left: 0;
  -webkit-mask-clip: border-box;
  mask-clip: border-box;
  -webkit-mask-image: url('img/cells-mask.svg');
  mask-image: url('img/cells-mask.svg');
  -webkit-mask-size: 100% 100%;
  mask-size: 100% 100%;
  position: absolute;
  top: 0;
  z-index: 2;
  pointer-events: none;
}

.status-bar {
  background: #151b2e;
  border-radius: 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1rem;
  position: relative;
  z-index: 4;
  width: min(320px, 90vw);
  margin: 20px auto;
}

.status-bar__select-traps {
  background-color: rgb(10 15 30);
  border-radius: .5rem;
  flex: 1;
  height: 2.75rem;
  padding: .75rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.select-traps {
  align-items: center;
  display: flex;
  justify-content: space-between;
  background: none;
  width: 100%;
}

.select-traps__content {
  align-items: center;
  display: flex;
  flex-direction: column;
  width: 5rem;
}

.select-traps__traps_amount {
  color: #f3f3f3;
  font-size: 16px;
  font-weight: 500;
  line-height: 18px;
}

.select-traps__title {
  color: #97a3cb;
  font-size: 12px;
  font-weight: 400;
  line-height: 15px;
}

#prev_preset_btn,
#next_preset_btn {
  background: none;
  border: none;
  cursor: pointer;
  padding: 0 10px;
  min-width: 44px;
  min-height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.select-traps__arrow-icon {
  fill: #97a3cb;
  height: 1.25rem;
  width: .75rem;
}

.select-traps__arrow-icon_prev {
  transform: rotate(180deg);
}

#playButton {
  background: linear-gradient(93.73deg, #108de7, #0855c4);
  border: none;
  border-radius: 8px;
  color: white;
  font-size: 14px;
  font-weight: 500;
  height: 42px;
  width: 200px;
  cursor: pointer;
}

#playButton:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.hidden {
  display: none !important;
}

.popup {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.popup-content {
  background-color: white;
  padding: 20px;
  border-radius: 8px;
  text-align: center;
  width: min(320px, 90vw);
  margin: 20px;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.fade-in {
  animation: fadeIn 0.5s forwards;
}

@keyframes fadeIn {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0);
  }
  100% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

@keyframes fadeOut {
  0% {
    opacity: 1;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(0);
  }
}

.cell-fade-out {
  animation: fadeOut 0.5s ease forwards;
}

.star-animation {
  position: absolute !important;
  width: 58px !important;
  height: 58px !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
}

.star-animation.fade-in {
  animation: fadeIn 0.5s ease forwards;
}

@media (max-width: 767px) {
  .cells-board {
    grid-template-columns: repeat(5, 1fr);
    grid-template-rows: repeat(5, 1fr);
  }
}

.no-select {
  -webkit-user-select: none;
  user-select: none;
}

@media (hover: none) {
  #prev_preset_btn,
  #next_preset_btn,
  #playButton {
    -webkit-tap-highlight-color: transparent;
  }
}