body {
  font-family: Arial, sans-serif;
  background-color: #f4f4f4;
  margin: 0;
  padding: 0;
}

header {
  background-color: #772537;
  color: white;
  text-align: center;
  padding: 20px;
}

h1 {
  margin: 0;
}

h2 {
  text-align: center;
}

#searchBar {
  padding: 10px;
  width: 80%;
  margin-top: 10px;
}

#filters {
  background-color: #fff;
  padding: 20px;
  margin: 20px auto;
  width: 90%;
  border-radius: 5px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

#filters select {
  margin: 10px 0;
  padding: 10px;
  width: 100%;
}

#restaurants {
  padding: 20px;
  margin: 20px auto;
  background-color: #fff;
  width: 90%;
  border-radius: 5px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 20px;
  min-height: 80vh;
}

/* ========================= */
/* CARD */
/* ========================= */
.restaurant {
  position: relative;               /* 🔥 CLAVE */
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 10px;
  background-color: #fff;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  border-radius: 5px;
  max-height: 670px;
  overflow: hidden;
  cursor: pointer;                  /* 🔥 CLAVE */
}

/* CAPA INVISIBLE PARA EL CLICK */
.restaurant::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
}

/* Eleva botones y links */
.restaurant a,
.restaurant button {
  position: relative;
  z-index: 2;
}

.restaurant p {
  font-size: 14px;
  margin: 10px 0;
  line-height: 1.6;
}

/* ========================= */
/* IMAGEN */
/* ========================= */
.restaurant-img {
  width: 100%;
  max-height: 200px;
  object-fit: contain;
  margin-top: 10px;
  border-radius: 5px;
}

/* ========================= */
/* DETALLES */
/* ========================= */
.restaurant-details {
  max-height: 200px;
  overflow-y: auto;
  padding-right: 10px;
}

.restaurant-details p {
  margin-bottom: 10px;
}

/* ========================= */
/* LINKS */
/* ========================= */
a {
  text-decoration: none;
  display: block;
  width: 100%;
  margin-top: 10px;
}

a button {
  background-color: #772537;
  color: white;
  border: none;
  padding: 10px 20px;
  font-size: 16px;
  font-weight: bold;
  border-radius: 5px;
  cursor: pointer;
  width: 100%;
}

a button:hover {
  background-color: #9e2a47;
}

/* ========================= */
/* BOTÓN DESCUENTO */
/* ========================= */
.descuento {
  background-color: #772537;
  color: white;
  border: none;
  padding: 10px 20px;
  font-size: 16px;
  border-radius: 5px;
  cursor: pointer;
  margin: 5px;
  font-weight: bold;
}

.descuento:hover {
  background-color: #a23454;
}

/* ========================= */
/* BOTÓN CERRAR */
/* ========================= */
#Cerrar {
  display: inline-block;
  background-color: #a23454;
  color: white;
  padding: 10px 20px;
  border-radius: 5px;
  font-size: 16px;
  font-weight: bold;
  text-align: center;
}

#Cerrar:hover {
  transform: scale(1.05);
}

#Cerrar:active {
  transform: scale(1);
}
