/* General styling */
body {
    background-color: white;
    position: relative; /* Ensures z-index works correctly down the line */
}
h2, h3, h4, h5, div {
    color: black;
}

/* Main page styling */

/* Heading styling */
#heading_container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

#heading_background_container {
    height: 400px;
    width: 100vw;
    overflow: hidden;
    display: flex;
    align-items: center;
}
#heading_background {
    width: 100%;
}

#heading_text {
    position: relative;
    top: -220px;
    font-size: 52px;
    text-shadow: 0 0 8px rgba(0, 0, 0, 0.5); /* Add text shadow to make it more legible */
}
@media (max-width: 700px) {
    #heading_text {
        top: -150px;
        font-size: 28px;
    }
    #heading_background_container {
        height: 375px;
    }
    #heading_background {
        width: 150%;
    }
}

.heading_underline {
  position: relative;
  display: inline-block;
}

.heading_underline::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  transform: translateX(12%); /* Adjust for alignment */
  width: 80%;
  height: 4px;
  background-color: red;
  transition: width 0.3s;
}

/* Deposit note styling */
#deposit_note_container {
    display: flex;
    justify-content: center;
}

#deposit_note {
    width: 80vw;
    color: black;
}

/* Booking system elements */
#booking_container {
    width: 100vw;
    padding: 100px 0px;
    display: flex;
    justify-content: center;
    align-items: center;
}
#appointment_booking_date_container {
    height: 550px;
    width: 350px;
    margin-right: 100px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
#payment_container {
    height: 550px;
    width: 350px;
    margin-left: 100px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
@media (max-width: 900px) {
    #booking_container {
        flex-direction: column;
    }
    #appointment_booking_date_container {
        height: auto;
        width: 350px;
        margin-right: 0px;
    }
    #payment_container {
        height: auto;
        width: 350px;
        margin-top: 50px;
        margin-left: 0px;
    }
}

.template_date_payment_heading_container {
    height: 50px;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}
.template_date_payment_heading_text {
    font-size: 28px;
}

/* Calendar styling */
#calendar_month_year_container {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

#calendar_month_year {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
#calendar_month, #calendar_year {
    margin: 10px;
    font-size: 18px;
    font-family: 'nunito', sans-serif;
    font-weight: 600;
}

.template_calendar_month_controls {
    height: 24px;
    width: 24px;
    cursor: pointer;
}
.template_calendar_month_controls:hover {
    opacity: 50%;
}

#calendar_container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
#calendar_grid {
    display: grid;
    grid-template-columns: repeat(7, 50px);
    grid-template-rows: repeat(7, 50px);
    background-color: white;
    /* border: solid 2px black; */
}

.template_calendar_cells {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: white;
    cursor: pointer;
}
.template_calendar_cells:hover {
    background-color: rgb(185, 185, 185);
}
.template_calendar_cells_clicked {
    background-color: rgb(130, 130, 130);
}
.template_calendar_cells_clicked:hover {
    background-color: rgb(130, 130, 130);
}

.template_calendar_cells_empty {
    background-color: white;
}

.template_calendar_headings {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: white;
    color: rgb(117, 117, 117);
    border-bottom: 2px solid rgb(100, 100, 100);
}

/* Timeslot styling */
#apointment_times_container {
    width: 350px;
}
#pick_timeslot {
    width: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
#timeslot_selection {
    text-align: center;
    width: 100%;
}
#selected_time, #dropdown_options {
    text-align: center;
    width: 100%;
    border: solid 2px black;
}

/* Hide dropdown by default */
#dropdown_options {
    height: 260px;
    width: 350px;
    z-index: 100;
    position: absolute;
    top: 45px;
    /* visibility: visible; */
    display: none;
    overflow-y: scroll; /* Vertical scrollbar only */
    overflow-x: hidden; /* No horizontal scrollbar */
    border-top: 0px;
}

#selected_time {
    height: 21px;
    padding-top: 10px;
    padding-bottom: 10px;
    cursor: pointer;
    /* Disables text selection for the dropdown button */
    user-select: none;
    -webkit-user-select: none; /* For Safari */
    -ms-user-select: none; /* For IE/Edge */
}
#selected_time:hover {
    background-color: rgb(185, 185, 185);
}

.template_timeslot_selection_options {
    width: 100%;
    padding-top: 5px;
    padding-bottom: 5px;
    background-color: white;
}
.template_timeslot_selection_options:hover {
    background-color: rgb(185, 185, 185);
    cursor: pointer;
}

.unavailable {
    color: rgb(180, 180, 180);
    background-color: rgb(255, 255, 255);
    /* background: repeating-linear-gradient(
        45deg, white, white 5px,rgb(100, 100, 100) 5px, rgb(100, 100, 100) 10px
    ); */
    cursor: not-allowed;
}
.unavailable:hover {
    background-color: white;
    cursor: not-allowed;
}

/* Payment form styling */
#payment_form_container {
    height: 475px;
    width: 350px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.template_payment_user_info_input {
    padding: 20px 0px;
    font-size: 20px;
}

#payment_recipt_container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}
#payment_cost_price_container {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
#payment_cost_total_container {
    width: 100%;
    margin-top: 10px;
    border-top: 2px solid #991009;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#payment_form {
    height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
#card_container {
    height: 137.4px;
}
#pay_button {
    height: 44.2px;
    width: 100%;
    border-radius: 5px;
    border: solid 2px rgb(175, 0, 0);
    font-size: 20px;
}
#pay_button:hover {
    cursor: pointer;
    background-color: rgb(175, 0, 0);
}

/* Payment loading styling */
#main_body_graying_out {
    display: block;
}
#page_loading_spinner_container {
    display: none; /* initially hidden */
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    width: 100vw;
    background-color: rgba(0, 0, 0, 0.6); /* dark gray tint */
    justify-content: center;
    align-items: center;
    z-index: 99;
}
#page_loading_spinner {
    width: 50px;
    height: 50px;
    border: 6px solid #f3f3f3;
    border-top: 6px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}