* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  display: flex;
  height: 100vh;
  font-family: 'Segoe UI', sans-serif;
  background-color: #fdf6ee;
  overflow: hidden;
}

.currentLocationSpan{
  background-color: white;
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 10px;
  border: 2px solid #ccc;

}

/* Sidebar */
.destinations {
  width: 35%;
  background-color: #fff8f0;
  padding: 24px;
  overflow-y: auto;
  border-right: 1px solid #ddd;
}

.destinations h2 {
  margin-bottom: 20px;
  font-size: 20px;
  color: #333;
}

.search-box {
  position: relative;
}

input {
  width: 100%;
  padding: 10px 12px;
  font-size: 16px;
  border: 2px solid #ccc;
  border-radius: 8px;
  transition: border-color 0.2s ease;
  font-weight: bold;
}

input:focus {
  border-color: #46a5e5;
  background-color: #f0faff;
  outline: none;
}

/* Result box */
.result-box {
  position: absolute;
  width: 100%;
  z-index: 10;
  background-color: white;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  max-height: 200px;
  overflow-y: auto;
}

.result-box ul {
  list-style: none;
}

.result-box li {
  padding: 10px;
  cursor: pointer;
  border-bottom: 1px solid #eee;
}

.result-box li:hover {
  background-color: #f1f1f1;
}

/* Buttons */
.button-group {
  display: flex;
  gap: 10px;
}

button {
  background-color: #46a5e5;
  color: white;
  padding: 10px 16px;
  font-weight: bold;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

button:hover {
  background-color: #1f78b4;
}

/* Destination list */
#destination-list li {
  list-style: none;
  background-color: white;
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 10px;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}
.map {
  flex-grow: 1;
  height: 100vh;
}
#map {
  width: 100%;
  height: 100%;
}
.search-controls {
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
}

.search-row {
  display: flex;
  flex-direction: row;
  gap: 8px;
}

input {
  flex: 1;
  min-width: 0;
}
.result-box {
  position: relative; /* Or static, just not absolute */
  z-index: 1;
}

.result-list {
  background: #fff;
  border-radius: 8px;
  max-height: 200px;
  overflow-y: auto;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  border: 1px solid #ccc;
}

.result-list li {
  padding: 10px;
  cursor: pointer;
}

.result-list li:hover {
  background-color: #eee;
}
.destinationListItem{
  display: flex;
  flex-direction: row;
  background-color: #fff;
  border: 2px solid #ccc;
  border-radius: 8px;
}
.destinationListItem p {
  margin: auto;
}

.control-btns button{
  display: flex;
  flex-direction: column;
  width: fit-content;
}

.fixed-button {
  position: fixed;
  top: 10px;   /* distance from the top */
  right: 10px;  /* distance from the right */
  padding: 10px 20px;
  background: #46A5E5;
  color: white;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 4px 6px rgba(0,0,0,0.2);
  font-size: 16px;
  z-index: 9999; /* make sure it stays above other elements */
}
.side-bar-btn{
  visibility: hidden;
}

@keyframes slide-in {
  0% {
    opacity: 0;
    left: -1000px;
  }
  100%{
    opacity: 1;
    left: 0px;
  }
}
@keyframes slide-out {
  0% {
    opacity: 1;
    left: 0px;
  }
  100%{
    opacity: 0;
    left: -1000px;
  }
}
@media screen and (max-width: 768px) {
  .destinations{
    width: 100%;
    z-index: 1;
    position: absolute;
    height: 100%;
  }
  .search-row{
    flex-direction: column;
  }
  .map{
    width: 100%;
    position: absolute;
    z-index: 0;
  }
  .open {
    animation: slide-in 0.5s normal forwards;
  }
  
  .close {
    animation: slide-out 0.5s normal forwards;
  } 
  .side-bar-btn{
    visibility: visible;
  }
  
}

