body {
  margin: 0;
  padding: 0;
  height: 100vh;
  font-family: 'Rubik', sans-serif;
  background: linear-gradient(to right, #2c2c2c, #1a1a1a);
  color: white;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
}

.container {
  position: relative;
  width: 90%;
  max-width: 700px;
  height: 400px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.card {
  position: absolute;
  width: 100%;
  background: #333;
  border-radius: 20px;
  padding: 40px;
  text-align: center;
  box-shadow: 0 12px 30px rgba(0,0,0,0.5);
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.5s ease, transform 0.5s ease;
  z-index: 0;
}

.card.active {
  opacity: 1;
  transform: translateY(0);
  z-index: 1;
}

.card h2 {
  font-size: 2em;
  margin-bottom: 20px;
  color: #ff4444;
}

.card p {
  font-size: 1.5em;
  color: #eee;
}

.nav {
  position: fixed; /* из absolute → fixed, чтобы быть на уровне всей страницы */
  top: 50%;
  transform: translateY(-50%);
  font-size: 4em; /* больше размер */
  color: #ff4444;
  cursor: pointer;
  user-select: none;
  transition: color 0.3s, transform 0.3s;
  z-index: 1000;
  padding: 10px;
}

.nav:hover {
  color: #ff7777;
  transform: translateY(-50%) scale(1.1);
}

.nav.left {
  left: 20px; /* небольшой отступ от края */
}

.nav.right {
  right: 20px;
}

@media (max-width: 600px) {
  .card {
    padding: 30px 20px;
  }

  .nav.left {
    left: 10px;
  }

  .nav.right {
    right: 10px;
  }
}