/* Houseguests Page Styles */

.page-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin: 1.5rem 0 2rem;
  color: var(--text-black);
  text-align: center;
  position: relative;
  padding-bottom: 1rem;
}

.page-title::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100px;
  height: 4px;
  background: linear-gradient(to right, var(--deep-orange), var(--bright-orange));
  border-radius: 2px;
}

.houseguest-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}

/* Order houseguests with ribbons to the top */
.houseguest-card.has-ribbon {
  order: -1;
  width: 100%;
  max-width: 350px;
  margin: 0 1rem 2rem;
}

/* Add a subtle highlight to cards with ribbons */
.houseguest-card.has-ribbon {
  border-left: 4px solid #ff0000;
  box-shadow: 0 8px 25px rgba(255, 0, 0, 0.15);
}

/* Nominated houseguests */
.houseguest-card.nominated {
  order: 0; /* After HOH but before regular houseguests */
  border-left: 4px solid #000000;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* POV houseguests */
.houseguest-card.has-pov {
  order: 0; /* Same priority as nominated */
  border-right: 4px solid #FFD700;
  box-shadow: 0 8px 25px rgba(255, 215, 0, 0.15);
}

/* Saved houseguests */
.houseguest-card.saved {
  order: 0; /* Same priority as nominated */
  border-left: 4px solid #A9A9A9;
  box-shadow: 0 8px 25px rgba(169, 169, 169, 0.15);
}

/* BB Save houseguests */
.houseguest-card.bbsave {
  order: 0; /* Same priority as nominated */
  border-left: 4px solid #6699CC;
  box-shadow: 0 8px 25px rgba(102, 153, 204, 0.15);
}

/* Evicted houseguests */
.houseguest-card.evicted {
  order: 1; /* Lower priority than others */
  border-left: 4px solid #FF8C00;
  box-shadow: 0 8px 25px rgba(255, 140, 0, 0.15);
  opacity: 0.8;
}

.houseguest-card.evicted img {
  filter: grayscale(100%);
}

/* Regular cards */
.houseguest-card {
  width: 100%;
  max-width: 350px;
  margin: 0 1rem 2rem;
  background-color: var(--white);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 20px var(--shadow-color);
  transition: all 0.3s ease;
  border-left: 4px solid var(--deep-orange);
}

.houseguest-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.12);
}

.houseguest-card-image {
  width: 100%;
  height: 300px;
  overflow: hidden;
  position: relative;
  background: linear-gradient(to right, var(--deep-orange), var(--bright-orange));
}

/* HOH Ribbon on houseguest cards */
.houseguest-card .hoh-ribbon {
  position: absolute;
  top: 0;
  left: 0;
  background-color: #ff0000;
  color: white;
  padding: 5px 12px;
  font-size: 14px;
  font-weight: bold;
  border-top-left-radius: 12px;
  border-bottom-right-radius: 12px;
  z-index: 5;
  box-shadow: 2px 2px 5px rgba(0,0,0,0.3);
}

/* POV Ribbon on houseguest cards */
.houseguest-card .pov-ribbon {
  position: absolute;
  top: 0;
  right: 0;
  background-color: #FFD700;
  color: black;
  padding: 5px 12px;
  font-size: 14px;
  font-weight: bold;
  border-top-right-radius: 12px;
  border-bottom-left-radius: 12px;
  z-index: 5;
  box-shadow: -2px 2px 5px rgba(0,0,0,0.3);
}

/* Saved Ribbon on houseguest cards */
.houseguest-card .saved-ribbon {
  position: absolute;
  top: 0;
  left: 0;
  background-color: #A9A9A9;
  color: white;
  padding: 5px 12px;
  font-size: 14px;
  font-weight: bold;
  border-top-left-radius: 12px;
  border-bottom-right-radius: 12px;
  z-index: 5;
  box-shadow: 2px 2px 5px rgba(0,0,0,0.3);
}

/* BB Save Ribbon on houseguest cards */
.houseguest-card .bbsave-ribbon {
  position: absolute;
  top: 0;
  left: 0;
  background-color: #6699CC;
  color: white;
  padding: 5px 12px;
  font-size: 14px;
  font-weight: bold;
  border-top-left-radius: 12px;
  border-bottom-right-radius: 12px;
  z-index: 5;
  box-shadow: 2px 2px 5px rgba(0,0,0,0.3);
}

/* Evicted Ribbon on houseguest cards */
.houseguest-card .evicted-ribbon {
  position: absolute;
  top: 0;
  left: 0;
  background-color: #FF8C00;
  color: white;
  padding: 5px 12px;
  font-size: 14px;
  font-weight: bold;
  border-top-left-radius: 12px;
  border-bottom-right-radius: 12px;
  z-index: 5;
  box-shadow: 2px 2px 5px rgba(0,0,0,0.3);
}

/* Nominated Ribbon on houseguest cards */
.houseguest-card .nominated-ribbon {
  position: absolute;
  top: 0;
  left: 0;
  background-color: #000000;
  color: white;
  padding: 5px 12px;
  font-size: 14px;
  font-weight: bold;
  border-top-left-radius: 12px;
  border-bottom-right-radius: 12px;
  z-index: 5;
  box-shadow: 2px 2px 5px rgba(0,0,0,0.3);
}

.houseguest-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.houseguest-card:hover .houseguest-card-image img {
  transform: scale(1.05);
}

.houseguest-card-content {
  padding: 1.5rem;
}

.houseguest-card-content h2 {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--deep-orange);
}

.houseguest-bio {
  color: #444;
  margin-bottom: 1.25rem;
  line-height: 1.5;
}

.houseguest-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
  font-size: 0.9rem;
}

.houseguest-stats span {
  display: inline-block;
  background: linear-gradient(to right, var(--deep-orange), var(--bright-orange));
  color: var(--white);
  padding: 0.4rem 1rem;
  border-radius: 30px;
  font-weight: 600;
}

/* Active nav link style */
nav a.active {
  background: var(--gold-yellow);
  color: var(--deep-orange);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

/* Responsive styles */
@media (max-width: 900px) {
  .houseguest-cards {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
  }
  
  .houseguest-card-image {
    height: 250px;
  }
  
  .houseguest-card-content h2 {
    font-size: 1.5rem;
  }
}

@media (max-width: 500px) {
  .houseguest-cards {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  
  .page-title {
    font-size: 2rem;
    margin: 1rem 0 1.5rem;
  }
}
