body {
  margin: 0;
  padding: 0;
  background: #111;
  font-family: sans-serif;
}

html, body {
  width: 100%;
  overflow-x: hidden;
}

h1, p {
  margin: 0;
}

p {
 color: gray !important;
}

/* Scroll container */
.card-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 20px;
}

/* Card */
.card {
  width: 220px;
  height: 320px;
  perspective: 1000px;
}

/* Flip system */
.card-inner {
  width: 100%;
  height: 100%;
  transition: transform 0.6s;
  transform-style: preserve-3d;
  position: relative;
}

.card.flipped .card-inner {
  transform: rotateY(180deg);
}

/* Front & Back */
.card-front,
.card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 12px;
  overflow: hidden;
  backface-visibility: hidden;
}

/* Make front a positioning context */
.card-front {
  border-radius: 12px;
  overflow: hidden;
}

/* Image */
.card-front img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Title overlay */
.card-title {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;

  padding: 10px;
  color: white;
  font-weight: bold;
  font-size: 16px;

  /* Gradient for readability */
  background: linear-gradient(to bottom, rgba(0,0,0,0.7), transparent);
}

/* Back */
.card-back {
  background: #000000;
  color: white;
  display: flex;
  justify-content: center;
  align-items: center;
  transform: rotateY(180deg);
  padding-inline: 10px;
}

/* Optional: subtle layered feel */
.card {
  transform: scale(0.98);
  transition: transform 0.2s;
  background: transparent;
}

.card:active {
  transform: scale(1);
}
