/* Styles pour l'animation de flip des cartes */
.card-container {
  perspective: 1000px;
  width: 240px;
  height: 320px;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 9999;
}

.card-flip {
  width: 100%;
  height: 100%;
  transform-style: preserve-3d;
  transition: transform 0.8s;
  position: relative;
}

.card-flip.flipped {
  transform: rotateY(180deg);
}

.card-front,
.card-back {
  width: 100%;
  height: 100%;
  position: absolute;
  backface-visibility: hidden;
  border-radius: 15px;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3);
}

.card-front {
  background-color: #1e3799;
  display: flex;
  justify-content: center;
  align-items: center;
  color: white;
  transform: rotateY(0deg);
}

.card-back {
  background-color: white;
  transform: rotateY(180deg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.card-back-icon {
  width: 60px;
  height: 60px;
  margin: 0 auto;
  margin-top: 30px;
}

.card-logo {
  width: 100px;
  height: 100px;
  margin: 0 auto;
}

.card-title {
  font-family: 'Press Start 2P', cursive;
  font-size: 16px;
  text-align: center;
  margin-top: 15px;
  padding: 0 20px;
}

.card-type {
  font-size: 18px;
  font-weight: bold;
  text-align: center;
  margin-top: 15px;
}

/* Card back designs per type */
.card-back.bonus {
  background: linear-gradient(135deg, #4a69bd, #1e3799);
  color: white;
}

.card-back.facture {
  background: linear-gradient(135deg, #e55039, #b71540);
  color: white;
}

.card-back.biens {
  background: linear-gradient(135deg, #78e08f, #38ada9);
  color: white;
}

.card-back.pdb {
  background: linear-gradient(135deg, #f6b93b, #e58e26);
  color: white;
}

.card-back.interaction {
  background: linear-gradient(135deg, #5758BB, #6F1E51);
  color: white;
}

.card-back.property {
  background: linear-gradient(135deg, #2980b9, #1c345a);
  color: white;
}

.card-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 9998;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Animation pour faire apparaître la carte */
@keyframes cardAppear {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.5);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
  }
}

.card-container {
  animation: cardAppear 0.3s ease-out forwards;
}
