/* ===== Booking Hero Section ===== */
.booking-hero {
  position: relative;
  width: 100%;
  height: 50vh;
  min-height: 320px;
  background-image: url("../images/booking_banner.jpg");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Optional overlay (for better text contrast) */
.booking-hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

/* Hero Content */
.booking-hero-content {
  position: relative;
  color: #fff;
  text-align: center;
  z-index: 2;
  padding: 0 1rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.booking-hero-content h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.booking-hero-content p {
  font-size: 1.1rem;
  font-weight: 400;
}

/* ===== Responsive Design ===== */
@media (max-width: 992px) {
  .booking-hero {
    height: 50vh;
  }

  .booking-hero-content h1 {
    font-size: 2rem;
  }

  .booking-hero-content p {
    font-size: 1rem;
  }
}

@media (max-width: 600px) {
  .booking-hero {
    height: 45vh;
    background-position: center top; /* keeps focus area visible */
  }

  .booking-hero-content h1 {
    font-size: 1.7rem;
  }

  .booking-hero-content p {
    font-size: 0.95rem;
  }
}


/* ======== booking days ==============*/
.booking_days {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  padding: 1.5rem 1.5rem;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 3px 11.2px rgba(0, 0, 0, 0.25);
  width: fit-content;
  margin: 2rem auto;
  font-family: "Inter", sans-serif;
}

/* Arrows */
.booking_days__next {
  color: #777;
  cursor: pointer;
  font-size: 1rem;
  transition: color 0.2s ease;
}
.booking_days__next:hover {
  color: #000;
}

/* Days container */
.booking_days__days {
  display: grid;
  grid-auto-flow: column;
  gap: 1.5rem;
  justify-content: center;
  align-items: center;
}

/* Each day */
.booking_days__day {
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
}
.booking_days__day-name {
  display: block;
  font-size: 0.9rem;
  color: #222;
  font-weight: 500;
}
.booking_days__day-date {
  display: block;
  font-size: 1rem;
  color: #333;
  margin-top: 4px;
  padding: 6px 10px;
  border-radius: 8px;
  transition: background 0.2s ease, color 0.2s ease;
}

/* Active day */
.booking_days__day--active .booking_days__day-date {
  background: #1d336c;
  color: #fff;
}

/* Court selector */
.booking_days__select {
  grid-column: 1 / -1;
  justify-self: center;
  margin-top: 0.8rem;
  padding: 0.6rem 1rem;
  font-size: 0.95rem;
  border: 1px solid #ccc;
  border-radius: 8px;
  background: #f4f4f4;
  color: #333;
  width: 100%;
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #555 50%),
    linear-gradient(135deg, #555 50%, transparent 50%);
  background-position: calc(100% - 20px) calc(1em + 2px),
    calc(100% - 15px) calc(1em + 2px);
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  cursor: pointer;
}
.booking_days__select:focus {
  border-color: #1d336c;
  outline: none;
}

/* ===== Responsive design ===== */
@media (max-width: 600px) {
  .booking_days {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 0.8rem;
    padding: 1rem;
    width: 94%;
  }

  .booking_days__next {
    justify-self: center;
    font-size: 1.2rem;
  }

  .booking_days__days {
    grid-auto-flow: row;
    grid-template-columns: repeat(auto-fit, minmax(40px, 1fr));
    gap: 0.5rem;
  }

  .booking_days__day-name {
    font-size: 0.8rem;
  }

  .booking_days__day-date {
    font-size: 0.9rem;
    padding: 5px 8px;
  }

  .booking_days__select {
    width: 100%;
    margin-top: 0.5rem;
  }
}

/* ================ court booking =========================*/
.court-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin: 2rem auto;
  max-width: 950px;
  padding: 0 1rem;
  font-family: "Inter", sans-serif;
}

/* ===== Each Court Card ===== */
.court {
  display: grid;
  grid-template-columns: 1fr 100px; /* left content + image */
  align-items: center;
  background: #F4F4F4;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 3px 11.2px 2px rgba(0, 0, 0, 0.25);
  /* gap: 1.5rem; */
}

/* Court Title */
.court h3 {
  grid-column: 1 / 2;
  font-size: 1.05rem;
  font-weight: 600;
  color: #222;
  margin-bottom: 0.8rem;
}

/* Time Slots Grid */
.time-slots {
  grid-column: 1 / 2;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(65px, 1fr));
  gap: 0.5rem;
}

.time-slot {
  background: #e6e6e6;
  color: #000;
  text-align: center;
  padding: 6px 0;
  border-radius: 6px;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
  user-select: none;
}

.time-slot:hover {
  background: #d4d4d4;
}

/* Active & Booked */
.time-slot.active {
  background: #1d336c;
  color: #fff;
}
.time-slot.booked {
  background: #f1b3b3a6;
  color: #a80000;
  cursor: not-allowed;
  opacity: 0.8;
}

/* Separator Line */
.line-seperator {
  grid-column: 1 / 2;
  height: 1px;
  background: #ccc;
  margin: 1rem 0 0.8rem;
}

/* Book Button */
.book-court {
  grid-column: 1 / 2;
  justify-self: start;
  padding: 0.5rem 1rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  background: #fff;
  color: #333;
  font-weight: 500;
  font-size: 0.95rem;
  cursor: pointer;
  transition: all 0.2s ease;
  list-style: none;
  text-decoration: none;
}

.book-court:hover {
  background: #fff;
  border-color: #999;
}

/* Court Image */
.court img {
  grid-column: 2 / 3;
  grid-row: 1 / span 4;
  justify-self: end;
  align-self: center;
  width: 90px;
  height: 90px;
  object-fit: contain;
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .court {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 1rem;
    /* gap: 1rem; */
  }

  .court img {
    grid-column: 1;
    grid-row: unset;
    justify-self: center;
    width: 70px;
    height: 70px;
    margin-top: 0.5rem;
  }

  .court h3 {
    margin-bottom: 1rem;
  }

  .time-slots {
    grid-template-columns: repeat(auto-fill, minmax(75px, 1fr));
    justify-content: center;
  }

  .line-seperator {
    margin: 1rem auto;
    width: 90%;
  }

  .book-court {
    justify-self: center;
    width: 100%;
    max-width: 280px;
  }
}

@media (max-width: 480px) {
  .time-slots {
    grid-template-columns: repeat(3, 1fr);
  }

  .time-slot {
    font-size: 0.8rem;
    padding: 5px 0;
  }

  .book-court {
    font-size: 0.9rem;
  }
}
