body {
  font-family: sans-serif;
  background: #f9f9f9;
  margin: 0;
  text-align: center;
}

header h1 {
  text-align: center;
  color: rgb(238, 225, 182);           
  font-family: 'Arial Black', sans-serif;
  font-size: 2.5rem;
  margin: 20px 0;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.3); 
}


.contenedores {
  display: flex;
  flex-direction: row;
  justify-content: center;
  flex-wrap: wrap;
  gap: 30px;
  margin-bottom: 20px;
}

.contenedor {
  width: 150px;
  padding: 0px;
  background-color: #eee;
  border-radius: 10px;
  overflow: hidden;
  text-align: center;
  border-top: 4px solid #4CAF50;
  margin-top: 10px;
  cursor: pointer; 
  transition: transform 0.2s, box-shadow 0.2s;
  
}

.contenedor.seleccionado {
  transform: scale(1.1);
  box-shadow: 0 0 10px #4CAF50;
}

/* Contenedor para imágenes con tamaño fijo */
.img-wrapper {
  width: 100px;
  height: 100px;
  margin: 0 auto 10px auto;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  border-radius: 10px;
}

.img-wrapper img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  object-fit: cover;
  display: block;
}

.basura {
  display: flex;
  justify-content: center;
  gap: 20px;
}

.item {
  background: white;
  padding: 10px 15px;
  border-radius: 8px;
  box-shadow: 0 0 5px #aaa;
  cursor: grab;
}

.zona-juego {
  position: relative;
  width: 100%;
  height: 400px;
  border: 2px dashed #ccc;
  margin-bottom: 0px;
  overflow: hidden;
  background: #e0f7fa;
}

#zona-basura-cayendo {
  position: relative;
  width: 100%;
  height: 100%;
}

.item-cayendo {
  position: absolute;
  top: 0;
  font-size: clamp(3rem, 6vw, 5rem);
  cursor: grab;
  user-select: none;
  transition: transform 0.2s, opacity 0.3s;
  touch-action: none;
}

.item-cayendo:hover {
  transform: scale(1.3);
  z-index: 10;
}

.item-cayendo.dragging {
  opacity: 0.5;
  transform: scale(1.1);
}

/* Botón reiniciar juego */
.boton-reiniciar {
  position: fixed;      
  bottom: 20px;
  right: 20px;
  background-color: #4CAF50; 
  color: white;
  font-size: 1rem;
  font-weight: bold;
  border: none;
  border-radius: 12px;
  padding: 12px 20px;
  cursor: pointer;
  box-shadow: 0 4px 6px rgba(0,0,0,0.2);
  transition: all 0.2s ease-in-out;
  z-index: 1000; 
}

.boton-reiniciar:hover {
  background-color: #45a049;
  transform: translateY(-2px);
  box-shadow: 0 6px 8px rgba(0,0,0,0.3);
}

.boton-reiniciar:active {
  transform: translateY(0);
  box-shadow: 0 3px 5px rgba(0,0,0,0.2);
}

.zona-mensaje {
  background-color: #e8f5e9; 
  border: 2px solid #4CAF50; 
  border-radius: 12px;
  padding: 15px 20px;
  margin: 20px auto; 
  max-width: 400px;
  max-height: 200px; 
  text-align: center;
  box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.zona-mensaje #mensaje-juego {
  font-weight: bold;
  font-size: 1rem;
  color: #2e7d32; 
  margin-bottom: 0px;
}

.mensaje-acierto {
  color: white;
  background-color: green;
  padding: 8px 12px;
  border-radius: 8px;
  display: inline-block;
  font-weight: bold;
}

.mensaje-fallo {
  color: white;
  background-color: red;
  padding: 8px 12px;
  border-radius: 8px;
  display: inline-block;
  font-weight: bold;
}


.aprende-reciclar {
  background-color: #e8f5e9; /* verde claro */
  border: 2px solid #4CAF50;
  border-radius: 12px;
  padding: 40px 20px;
  margin: 50px auto;
  text-align: center;
  max-width: 800px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.aprende-reciclar h2 {
  color: #2e7d32;
  font-size: 2rem;
  margin-bottom: 15px;
}

.aprende-reciclar p {
  font-size: 1.1rem;
  margin-bottom: 25px;
  color: #333;
}

.boton-juego {
  background-color: #4CAF50;
  color: white;
  text-decoration: none;
  padding: 12px 25px;
  border-radius: 8px;
  font-weight: bold;
  transition: all 0.3s ease;
  box-shadow: 0 3px 6px rgba(0,0,0,0.2);
}

.boton-juego:hover {
  background-color: #45a049;
  transform: scale(1.05);
}

.beneficios {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 40px;
  flex-wrap: wrap;
  padding: 40px;
}

.tarjeta {
  width: 280px;
  height: 350px;
  perspective: 1000px;
  position: relative;

  
}

.cara {
  width: 100%;
  height: 100%;
  border-radius: 15px;
  position: absolute;
  backface-visibility: hidden;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  overflow: hidden;
  padding: 0;
}

.cara-frontal {
  background-color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.cara-frontal img {
  width: 100%;
  height: 75%;
  object-fit: cover;
}

.cara-frontal h3 {
  margin: 10px 0;
  color: #2e7d32;
}

.cara-trasera {
  background-color: #4CAF50;
  color: white;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 0px;
  transform: rotateY(180deg);
}


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

.tarjeta:hover .tarjeta-inner {
  transform: rotateY(180deg);
}

.info-adicional {
  max-width: 900px;
  margin: 60px auto;
  padding: 30px;
  background: #ffffff;
  border-radius: 15px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  text-align: center;
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s ease;
}

.info-adicional.visible {
  opacity: 1;
  transform: translateY(0);
}

.info-adicional h3 {
  color: #2e7d32;
  margin-bottom: 30px;
}

.tarjetas-info {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.tarjeta-info {
  background-color: #e8f5e9;
  border-left: 5px solid #4CAF50;
  padding: 20px;
  border-radius: 12px;
  font-size: 1.05rem;
  line-height: 1.5;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.6s ease;
}

.tarjeta-info.visible {
  opacity: 1;
  transform: translateY(0);
}

.icono-girar {
  width: 24px !important;
  height: 24px !important;
  margin-top: 10px;
  display: inline-block;
}

.contacto {
  max-width: 600px;
  margin: 50px auto;
  padding: 0 20px;
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333;
}

.contacto h2, .contacto h3 {
  color: #4CAF50;
  margin-bottom: 15px;
}

.contacto p {
  margin-bottom: 20px;
}

.contacto .email {
  font-weight: bold;
  color: #000;
}

.contacto section {
  background-color: #f9f9f9;
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 3px 8px rgba(0,0,0,0.1);
  margin-bottom: 30px;
}






