:root{
  --teal: #2ec1ac;
  --teal_hover: #279e8c;
}
*{font-family: 'Poppins', sans-serif;
}
.h-font{
    font-family:'Merienda', cursive;
}
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
input[type=number] {
  appearance: textfield; /* Standard */
  -webkit-appearance: textfield; /* For Safari and Chrome */
  -moz-appearance: textfield; /* For Firefox */
}
.custom-bg{
  background-color: var(--teal);
  border: 1px solid var(--teal);
}
.custom-bg:hover{
  background-color: var(--teal_hover);
  border-color: var(--teal_hover);
}
.availability-form{
    margin-top: -50px;
    z-index: 2;
    position: relative;
  }
  @media screen and (max-width: 575px){
    .availability-form{
      margin-top: 25px;
      padding: 0 35px;
    }
} 

.text-line{
  width: 150px;
  margin: 10px auto;
  height: 5px;
}

.custom-alert{
  position: fixed;
  top: 80px;
  right: 25px;
  z-index: 1000;
}

h3{
  color: #333;
  font-family: Georgia, 'Times New Roman', Times, serif;
  margin-left: 2px;
  size: 15px;
}
.buttons-container {
  display: flex;
  justify-content: flex-start; /* Align buttons with header */
  margin-bottom: 20px;
}
.buttons {
  display: flex;
  flex-direction: column; /* Stack buttons vertically */
}
.buttons button {
  background-color: #007BFF;
  color: white;
  border: none;
  padding: 10px 20px;
  margin: 5px 0; /* Adjust margin for vertical stacking */
  cursor: pointer;
  border-radius: 5px;
  width: 175px; /* Decrease the length of the button */
  transition: background-color 0.3s, color 0.3s, border 0.3s; /* Smooth transition */
}
.buttons button:hover {
  background-color: white;
  color: #007BFF;
  border: 1px solid #007BFF;
}
.buttons button.active {
  background-color: white; /* White background for selected button */
  color: #007BFF; /* Blue font for selected button */
  border: 1px solid #007BFF; /* Blue border for selected button */
}
.section {
  display: none;
}
.section.active {
  display: block;
}
.calendar-container {
  display: flex;
  justify-content: flex-start;  /* Align calendar with availability section */
  align-items: center;
  width: 100%;
  max-width: 800px;  /* Increased width for better centering */
  margin: 100px;  /* Decrease space between button and calendar */
  padding: 5px 0;  /* Decrease space above & below */
  text-align: left; /* Align calendar with availability section */
  background-color: transparent; /* Ensure no background color */
  margin-top: 5px;
  margin-bottom: 5px;
}
#calendar {
  background-color: #a1956a; /* Change background color of calendar */
}
.guest-selection h3 {
  text-align: left; /* Ensure "Who's checking in?" is not centered */
}
.guest-selection {
  margin-top: 20px;
  display: none; /* Initially hidden */
  text-align: center; /* Center align the guest selection */
}
.guest-selection select {
  padding: 10px;
  margin: 5px;
  border-radius: 5px;
  border: 1px solid #ccc;
}
.guest-selection p {
  text-align: left; /* Align description to the left */
  margin-left: 10px; /* Add margin to the left */
  font-size: 1.0em; /* Smaller font size */
}
.meal-transport-selection p {
  text-align: left; /* Align description to the left */
  margin-left: 10px; /* Add margin to the left */
  font-size: 1.0em; /* Smaller font size */
}
.meal-transport-selection {
  margin-top: 20px;
  display: none; /* Initially hidden */
}
.meal-transport-selection table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}
.meal-transport-selection th, .meal-transport-selection td {
  border: 1px solid #ccc;
  padding: 10px;
  text-align: center;
}
.meal-transport-selection th {
  background-color: #f4f4f4;
}
.meal-transport-selection input[type="number"], .motorcycle-selection input[type="number"] {
  width: 60px; /* Decrease input field size */
  padding: 5px;
  text-align: center;
}
.boat-transport-selection {
  margin-top: 20px;
  display: none; /* Initially hidden */
}
.boat-transport-selection table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}
.boat-transport-selection th, .boat-transport-selection td {
  border: 1px solid #ccc;
  padding: 10px;
  text-align: center;
}
.boat-transport-selection th {
  background-color: #f4f4f4;
}
.motorcycle-selection {
  margin-top: 20px;
  display: none; /* Initially hidden */
}
.motorcycle-selection table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}
.motorcycle-selection th, .motorcycle-selection td {
  border: 1px solid #ccc;
  padding: 10px;
  text-align: center;
}
.motorcycle-selection th {
  background-color: #f4f4f4;
}
.content {
  display: flex;
}
.content .main-content {
  flex: 1;
  padding-left: 20px;
}
.legend {
  margin-top: 13px;
  display: flex;
  /* justify-content: center; */
  margin-left: 190px;
  margin-bottom: 5px;
}
.legend div {
  margin-top: 13px;
  margin:  13px;
  display: flex;
  align-items: center;
  }
.legend div span {
  display: inline-block;
  width: 20px;
  height: 20px;
  margin-right: 10px;
  margin-left: 10px; /* Add small margin between spans */
}
.legend .selected span {
  background-color: #007bff;
  
}
.legend .unavailable span {
  background-color: #d9534f;
}
/* .legend .disabled span {
  background-color: #686463;
} */
.legend .today span{
  background-color: #686463;
  border: 2px solid #000000; /* Add black border to today span */
}
.flatpickr-day.today {
  border: 2px solid #000000; /* Circle today's date in black */
  color: #000000; /* Change color to black */
}
.flatpickr-day.flatpickr-disabled {
  color: #686463; /* Change color of disabled dates to #686463 */
}
.availability-section {
  text-align: left; /* Align text and description a little bit to the left */
  margin-left: 35px; /* Add margin to the left */
}
.small-font {
  font-size: 0.8em; /* Smaller font size */
  margin-top: 5px; /* Add margin-top */
  margin-left: 35px; /* Add margin-left */
}
.summary-table {
  margin-top: 20px;
  display: none; /* Initially hidden */
}
.summary-table table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
}
.summary-table th, .summary-table td {
  border: 1px solid #ccc;
  padding: 10px;
  text-align: center;
}
.summary-table th {
  background-color: #f4f4f4;
}
.summary-buttons {
  display: flex;
  justify-content: space-between;
  margin-top: 20px;
}
.summary-buttons button {
  background-color: #007BFF;
  color: white;
  border: none;
  padding: 10px 20px;
  cursor: pointer;
  border-radius: 5px;
  transition: background-color 0.3s, color 0.3s, border 0.3s;
}
.summary-buttons button:hover {
  background-color: white;
  color: #007BFF;
  border: 1px solid #007BFF;
}
.scroll-to-top {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background-color: #007BFF;
  border: none;
  cursor: pointer;
  display: none; /* Hidden by default */
  transition: transform 0.3s;
  border-radius: 50%;
  padding: 10px;
}
.scroll-to-top img {
  width: 30px;
  height: 30px;
}
.scroll-to-top:hover {
  transform: scale(1.1);
}

.activity-img {
  width: 100%;
  height: 200px; /* Set the desired height */
  object-fit: cover; /* Ensure the image covers the entire area */
}

/* Responsive styles */
@media (max-width: 768px) {
  .container {
    padding: 0 15px;
  }

  /* Stack content vertically on mobile - buttons above calendar */
  .content {
    display: flex;
    flex-direction: column;
  }

  .buttons-container {
    display: flex;
    justify-content: center;
    width: 100%;
    margin-bottom: 20px;
  }

  /* Make buttons horizontal on mobile */
  .buttons {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 10px;
    width: 100%;
  }

  .buttons button {
    width: auto;
    min-width: 120px;
    flex: 1 1 auto;
    margin: 5px;
    padding: 10px 15px;
  }

  .main-content {
    padding: 0;
    width: 100%;
  }

  /* Fix calendar container positioning on mobile - center it and stack below legend */
  .calendar-container {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 auto !important;
        margin-left: auto !important;
        margin-right: auto !important;
        margin-top: 10px !important;
        padding: 10px 15px !important;
        justify-content: center !important;
        align-items: center !important;
        display: flex !important;
        text-align: center !important;
        /* Remove or change this line: */
        overflow-x: auto !important; /* Changed from hidden to visible */
    }

  /* Center the calendar itself */
  .calendar-container #calendar {
    margin: 0 auto !important;
    width: 100% !important;
    max-width: 100% !important;
    display: block !important;
  }

  /* Center flatpickr calendar wrapper */
  .calendar-container .flatpickr-calendar {
    margin: 0 auto !important;
    left: auto !important;
    right: auto !important;
    position: relative !important;
    width: 100% !important;
    max-width: 100% !important;
    transform: none !important;
  }

  /* Fix flatpickr month container */
  .calendar-container .flatpickr-calendar .flatpickr-months {
    width: 100% !important;
    max-width: 100% !important;
  }

  /* Fix flatpickr days container */
  .calendar-container .flatpickr-calendar .flatpickr-days {
    width: 100% !important;
    max-width: 100% !important;
  }

  /* Center flatpickr wrapper if it exists */
  .calendar-container .flatpickr-wrapper {
    margin: 0 auto !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  /* Ensure calendar div inside container is centered */
  .calendar-container > div {
    margin: 0 auto !important;
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
  }

  /* Fix availability section margins on mobile */
  .availability-section {
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding: 0 15px !important;
    width: 100% !important;
    text-align: center !important;
  }

  .availability-section h2 {
    text-align: center !important;
  }

  .availability-section p {
    text-align: center !important;
  }

  /* Fix legend positioning on mobile - center horizontally */
  .legend {
    margin-left: auto !important;
    margin-right: auto !important;
    justify-content: center !important;
    align-items: center !important;
    flex-direction: row !important; /* Keep horizontal layout */
    flex-wrap: wrap !important; /* Allow wrapping if needed */
    margin-bottom: 20px !important; /* Add more space before calendar */
    margin-top: 20px !important; /* Add space after description */
    width: 100% !important;
    max-width: 100% !important;
    text-align: center !important;
    display: flex !important;
    gap: 15px !important;
    float: none !important;
    padding: 0 !important;
  }

  .legend div {
    margin: 5px 0 !important; /* Vertical spacing only */
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: auto !important; /* Let content determine width */
    margin-left: 0 !important;
    margin-right: 0 !important;
    text-align: center !important;
    float: none !important;
  }

  /* Ensure text inside legend items is centered */
  .legend div span {
    margin-left: 0 !important;
    margin-right: 8px !important;
  }

  /* Fix small font margin on mobile */
  .small-font {
    margin-left: 0 !important;
    padding: 0 15px !important;
    text-align: center !important;
  }

  table {
    width: 100%;
    overflow-x: auto;
    display: block;
  }

  table th, table td {
    padding: 10px;
    text-align: left;
    font-size: 0.9em;
  }

  .summary-buttons {
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .summary-buttons button {
    width: 100%;
    margin-bottom: 10px;
  }

  /* Fix Info and Facilities sections on mobile */
  #info, #facilities {
    margin-left: 0;
    padding: 0 10px;
  }
}

/* Extra small phones (390px and below) */
@media (max-width: 480px) {
  .buttons {
    flex-direction: column;
    align-items: stretch;
  }

  .buttons button {
    width: 100%;
    margin: 5px 0;
  }

  .calendar-container {
    padding: 5px 0;
    width: 100% !important;
    max-width: 100% !important;
    margin: 10px auto !important;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    text-align: center !important;
    overflow-x: auto !important; /* Changed from hidden to visible */
  }
  
  /* Force calendar to be centered and fit within screen */
  .calendar-container #calendar {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 auto !important;
    display: block !important;
  }

  /* Fix flatpickr calendar positioning and sizing */
  .calendar-container .flatpickr-calendar {
    margin: 0 auto !important;
    left: auto !important;
    right: auto !important;
    position: relative !important;
    width: 100% !important;
    max-width: 100% !important;
    transform: none !important;
  }

  /* Fix flatpickr month container */
  .calendar-container .flatpickr-calendar .flatpickr-months {
    width: 100% !important;
    max-width: 100% !important;
  }

  /* Fix flatpickr days container */
  .calendar-container .flatpickr-calendar .flatpickr-days {
    width: 100% !important;
    max-width: 100% !important;
  }

  /* Ensure flatpickr day cells fit within container */
  .calendar-container .flatpickr-calendar .flatpickr-day {
    max-width: calc(100% / 7) !important;
    box-sizing: border-box !important;
  }

  /* Fix flatpickr table to be responsive */
  .calendar-container .flatpickr-calendar .flatpickr-days .flatpickr-dayContainer {
    width: 100% !important;
    max-width: 100% !important;
    min-width: 0 !important;
  }

  /* Ensure table layout doesn't overflow */
  .calendar-container .flatpickr-calendar table {
    width: 100% !important;
    max-width: 100% !important;
    table-layout: fixed !important;
  }

  .availability-section {
    text-align: center !important;
    margin-left: 0 !important;
    padding: 0 15px !important;
    width: 100% !important;
  }

  .availability-section h2 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    text-align: center !important;
  }

  .availability-section p {
    font-size: 0.9em;
    text-align: center !important;
  }

  .legend {
    justify-content: center !important;
    align-items: center !important;
    flex-direction: row !important; /* Keep horizontal on small screens but centered */
    flex-wrap: wrap !important; /* Allow wrapping if needed */
    margin-left: auto !important;
    margin-right: auto !important;
    margin-bottom: 15px !important; /* Space before calendar */
    margin-top: 15px !important;
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
    display: flex !important;
    gap: 15px !important;
  }

  .legend div {
    margin: 5px 0 !important; /* Vertical spacing */
    margin-left: 0 !important;
    margin-right: 0 !important;
    font-size: 0.85em;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    width: auto !important; /* Let content determine width for proper centering */
    text-align: center !important;
  }

  .legend div span {
    margin-left: 0;
    margin-right: 8px;
    width: 16px;
    height: 16px;
  }

  .small-font {
    text-align: center !important;
    margin-left: 0 !important;
    padding: 0 15px !important;
  }
}