* {
  box-sizing: border-box;
  /* Prevent padding from breaking the layout */
}
main {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 1fr;
  gap: 30px;
  padding: 25px 40px;
  width: 100%;
  max-width: none;
  margin: 0;
  justify-content: center;
}

main>h1 {
  grid-column: 1/ -1;
  text-align: center;
  margin-bottom: 10px;
}

.mascota-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: rgba(40, 25, 15, 0.25);
  border: 3px solid #6B4423;
  border-radius: 4px;
  padding: 20px;
  gap: 15px;
  box-shadow:
    inset 0 0 15px rgba(0, 0, 0, 0.4),
    0 4px 8px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  position: relative;
}

.mascota-card:hover {
  transform: translateY(-5px);
  border-color: #D4AF37;
  box-shadow:
    inset 0 0 20px rgba(0, 0, 0, 0.5),
    0 8px 16px rgba(0, 0, 0, 0.4),
    0 0 15px rgba(212, 175, 55, 0.3);
}

.mascota-card::before {
  content: '';
  position: absolute;
  top: -2px;
  left: -2px;
  right: -2px;
  bottom: -2px;
  background: linear-gradient(45deg, #8B4513, #6B4423);
  border-radius: 4px;
  z-index: -1;
}


.mascota-img {
  width: 160px;
  height: 160px;
  object-fit: cover;
  border-radius: 2px;
  border: 4px solid #4A3018;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
  background: #2A1F15;
}

.mascota-card article {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.mascota-card h2 {
  margin: 0;
  color: #D4AF37;
  font-size: 24px;
  text-shadow: 2px 2px 4px #000;
  letter-spacing: 1px;

}

.mascota-card .parrafo p {
  font-size: 14px;
  text-align: justify;
  line-height: 1.6;
  color: #2A1F15;
  margin: 0;
}


/* Responsive for tablet */
@media (max-width: 1200px) {
  main {
    grid-template-columns: repeat(2, 1fr);
    padding: 20px 30px;
  }
}

/* Responsive for móvil */
@media (max-width: 768px) {
  main {
    grid-template-columns: 1fr;
    gap: 30px;
    padding: 15px 20px;
  }

  .mascota-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 20px;
    padding: 20px;
  }

  .mascota-img {
    width: 140px;
    height: 140px;
  }

  .mascota-card h2 {
    font-size: 22px;
  }

  .mascota-card .parrafo p {
    font-size: 15px;
    text-align: left;
  }
}