.card3d-container {
  width: 70%;
  margin: 50px auto;
  display: flex;
  justify-content: center;
  padding: 40px;
  font-family: sans-serif;
  flex-wrap: wrap;
}

.card3d-box {
  margin: 20px;
  width: 150px;
  text-decoration: none;
  perspective: 1000px;
}

.card3d {
  background: #fafafa;
  border-radius: 16px;
  padding: 15px;
  border: 1px solid rgba(0,0,0,0.1);
  transition: transform 0.2s ease-out;
  transform-style: preserve-3d;

  display: flex;
  flex-direction: column;
  align-items: center;
}

.card3d-image-wrapper {
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 12px;
  margin-bottom: 10px;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: transform 0.2s ease-out;
}

.card3d-image {
  max-width: 100%;
  max-height: 100%;
  object-fit: cover;
  border-radius: 12px
}

.card3d-title {
  text-align: center;
  font-weight: bold;
  color: #333;
  font-size: 1rem;
  margin: 5px 0;
  word-wrap: break-word;
}

.card3d-id {
  text-align: center;
  font-size: 0.85rem;
  color: #555;
  margin-bottom: 6px;
}

.card3d-text {
  font-size: 0.9rem;
  padding: 5px;
  color: rgb(75 85 99);
  text-align: center;
}

.cert-container {
  width: 90%;
  margin: 40px auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 20px;
  font-family: sans-serif;
}

.cert-box {
  width: 200px !important;
  text-decoration: none;
  perspective: 1000px;
}

.cert {
  background: #fafafa;
  border-radius: 16px;
  padding: 15px;
  border: 1px solid rgba(0,0,0,0.1);
  transition: transform 0.2s ease-out;
  transform-style: preserve-3d;

  /* 💡 Hauteur uniforme pour toutes les cartes */
  height: 270px;

  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start; /* important */
}
