/* Setel margin dan padding ke 0 untuk body dan html */
html,
body {
  margin: 0;
  padding: 0;
  height: 100%;
  width: 100%;
  color: white;
  /* hapus tes */
  overflow: hidden;
  /* Menghindari scroll bar yang tidak diinginkan */
  box-sizing: border-box;
  /* Pastikan padding dan border tidak mempengaruhi ukuran elemen */
}

:root {
  --primary-color: #5f8670;
  --secondary-color: #9ec8b9;

  --button-active-color: #5c8374;

  --progress-value-color: #9ec8b9;

  --primary-text-color: #527853;
  --secondary-text-color: #112929;

  /* #5F8670, 1B4242, 5C8374, 9EC8B9, 527853, 88AB8E */
}

/* Peta harus memenuhi 100% tinggi dan lebar layar */
#map {
  height: 100vh;
  width: 75%;
  float: right;
  transition: width 0.3s ease;
}

/* Sidebar tetap pada posisi tetap dengan tinggi 100vh */
#sidebar {
  width: 25%;
  height: 100vh;
  padding: 20px;
  overflow-y: auto;
  /* Scroll jika konten lebih banyak dari ukuran sidebar */
  background: linear-gradient(135deg, #2C6D31, #4CAF50);

  border: 1px solid #ddd;
  transition: transform 0.3s ease, width 0.3s ease;
  transform: translateX(100%);
}

#sidebar.open {
  transform: translateX(0);
  /* Sidebar muncul */
  width: 30%;
}

/* Info Gedung muncul di atas peta */
#gedung-info {
  width: 25%;
  height: 100vh;
  position: fixed;
  top: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  overflow-y: auto;
  z-index: 1000;
  padding: 20px;
  display: none;
  transition: transform 0.3s ease;
}

#gedung-info h5 {
  color: #fff;
}

#gedung-info img {
  max-width: 250px;
}

#search-area {
  display: flex;
  align-items: center;
  /* Vertically align the input and button */
  justify-content: space-between;
  /* Push the button to the right */
  margin-bottom: 20px;
}

#search-button {
  padding: 6px 20px;
  border: 2px solid #00000022;
  border-radius: 6px;
  background-color: var(--primary-color);
  color: #fff;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

#search-button:hover {
  background-color: var(--secondary-color);
}

#search-button:active {
  background-color: var(--button-active-color);
}

.judul-sidebar {
  color: #ddd;
}

#dropArea {
  margin-block-end: 16px;
  padding: 20px;

  border: 2px dashed #cccccc;
  border-radius: 12px;
}

#dropArea.highlight {
  border-color: purple;
}

#skinFile {
  display: none;
}

#skinFileLabel {
  margin-block: 8px;
  padding-inline: 16px;

  display: inline-block;

  font-size: smaller;
}

#previewImg {
  margin-block-start: 8px;
}

#previewImg img {
  width: 100%;
}

.submit-form {
  display: flex;

  justify-content: end;
}

.btn {
  padding: 8px 24px;
  border: 2px solid #00000022;
  border-radius: 6px;

  display: block;
  background-color: var(--primary-color);

  font-size: 16px;
  font-weight: 500;
  color: #fff;

  transition: 150ms ease-in-out;
  cursor: pointer;
}

.btn:hover {
  background-color: var(--secondary-color);
}

.btn:active {
  background-color: var(--button-active-color);

  outline: 2px solid #00000077;
}

.container-checkbox {
  display: block;
  position: relative;
  padding-left: 35px;
  margin-bottom: 12px;
  cursor: pointer;
  font-size: 17px;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  color: white;
}

/* Hide the browser's default checkbox */
.container-checkbox input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

/* Create a custom checkbox */
.checkmark {
  position: absolute;
  top: 0;
  left: 0;
  height: 25px;
  width: 25px;
  background-color: #eee;
}

/* On mouse-over, add a grey background color */
.container-checkbox:hover input~.checkmark {
  background-color: #ccc;
}

/* When the checkbox is checked, add a blue background */
.container-checkbox input:checked~.checkmark {
  background-color: #2196F3;
}

/* Create the checkmark/indicator (hidden when not checked) */
.checkmark:after {
  content: "";
  position: absolute;
  display: none;
}

/* Show the checkmark when checked */
.container-checkbox input:checked~.checkmark:after {
  display: block;
}

/* Style the checkmark/indicator */
.container-checkbox .checkmark:after {
  left: 9px;
  top: 5px;
  width: 5px;
  height: 10px;
  border: solid white;
  border-width: 0 3px 3px 0;
  -webkit-transform: rotate(45deg);
  -ms-transform: rotate(45deg);
  transform: rotate(45deg);
}

#full-image-container img {
  object-fit: contain;
  margin-top: 20px;
}

.ket-gedung {
  margin-top: 30px;
  font-size: 20px;
}





/* Jika ukuran layar kecil, sesuaikan ukuran sidebar */
@media (max-width: 768px) {
  #sidebar.open {
    width: 70%;
    /* Sidebar akan mengambil 70% layar di perangkat kecil */
  }
}

/* Button untuk toggle sidebar */
.toggle-btn {
  position: absolute;
  top: 20px;
  left: 20px;
  z-index: 1000;
  background-color: #007bff;
  color: white;
  border: none;
  padding: 10px;
  cursor: pointer;
  font-size: 20px;
  border-radius: 10%;
  transition: transform 0.3s ease;
}

.toggle-btn:hover {
  transform: scale(1.2);
}

.toggle-btn:active {
  transform: scale(0.9);
}

.toggle-btn.open {
  transform: rotate(180deg);
  /* Efek rotasi tombol saat dibuka */
}

/* Agar peta tetap terlihat di layar penuh */
.leaflet-container {
  cursor: arrow;
}

/* Menyembunyikan tombol ketika sidebar terbuka */
#sidebar.open~#toggle-btn {
  opacity: 0;
  pointer-events: none;
  /* Menghindari interaksi saat tombol tidak terlihat */
  transition: opacity 0.3s ease;
}