/* Reset and Base Styles */
body {
  margin: 0;
  padding: 0;
  font-family: "Bai Jamjuree", Arial, sans-serif;
  color: #111;
  background: #fff;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-weight: 400;
  overflow-x: hidden;
}

body a {
  color: #111;
  text-decoration: none;
}

/* Container */
.form-item {
  position: relative;
  margin: 15px 0 15px 0;
}

.form-item .dropdown-menu {
  left: 0;
  bottom: 0;
  min-height: 400px;
}

.input-container {
  position: relative;
}

.btn {
  border-radius: 0;
}

/* Dropdown Icon */
.input-container span.fa {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #666;
  font-size: 14px;
  pointer-events: none;
  transition: color 0.3s ease;
}

/* Header Section */
.header-section {
  background: #fff;
  position: relative;
}

.map-logo-container {
  text-align: center;
  margin-bottom: 10px;
}

.map-logo {
  width: auto;
  height: 120px;
  max-width: 200px;
}

.language-container {
  position: absolute;
  top: 15px;
  right: 20px;
}

.language-link {
  font-size: 18px;
  font-weight: bold;
  color: #111;
  padding: 5px 10px;
  border-radius: 0px;
  transition: background-color 0.3s ease;
}

.language-link:hover {
  background-color: #f5f5f5;
  color: #111;
}

/* Floor Selection Section */
.floor-section {
  background: #fff;
  padding: 20px;
  border-bottom: 1px solid #e0e0e0;
}

.floor-title-container {
  margin-bottom: 20px;
}

.floor-title {
  font-size: 24px;
  font-weight: bold;
  color: #111;
  margin: 0 0 8px 0;
  line-height: 1.2;
}

.floor-subtitle {
  font-size: 14px;
  color: #666;
  margin: 0;
  display: none;
}

.floor-buttons-container {
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  /* Hide scrollbar for Chrome, Safari and Opera */
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* Internet Explorer 10+ */
}

.floor-buttons-container::-webkit-scrollbar {
  display: none; /* Chrome, Safari and Opera */
}

.floor-scroll-wrapper {
  display: flex;
  gap: 8px;
  min-width: max-content;
  padding-bottom: 5px;
}

.floor-button {
  background: #fff;
  border: 1px solid #111;
  color: #111;
  padding: 10px 16px;
  border-radius: 0;
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.3s ease;
  min-width: 80px;
  text-align: center;
}

.floor-button:hover {
  background: #f5f5f5;
}

.floor-button.active {
  background: #111;
  color: #fff;
  box-shadow: 0 5px 10px 0 rgba(0, 0, 0, 0.3);
}

/* Search Section */
.search-section {
  background: #fff;
  padding: 15px 20px;
  border-bottom: 1px solid #e0e0e0;
}

.search-container {
  display: flex;
  gap: 15px;
  align-items: center;
}

.search-input-wrapper {
  flex: 1;
  position: relative;
}

.search-input {
  width: 100%;
  padding: 12px 40px 12px 15px;
  border: 1px solid #ddd;
  border-radius: 0px;
  font-size: 14px;
  background: #f9f9f9;
  box-sizing: border-box;
}

.search-input:focus {
  outline: none;
  border-color: #111;
  background: #fff;
}

.search-icon {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #666;
  font-size: 16px;
}

.filter-dropdown {
  flex-shrink: 0;
}

.filter-button {
  background: #fff;
  border: 1px solid #111;
  color: #111;
  padding: 12px 20px;
  border-radius: 0px;
  font-size: 14px;
  font-weight: 500;
  min-width: 150px;
  text-align: left;
  position: relative;
}

.filter-button:hover,
.filter-button:focus {
  background: #f5f5f5;
  color: #111;
  border-color: #111;
}


.custom-dropdown-menu {
  right: 0;
  left: unset;
  background: #111;
  border: none;
  border-radius: 0px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  max-height: 300px;
  overflow-y: scroll;
  min-width: 200px;
}

.custom-dropdown-menu.full-size {
  left: 0;
}

.custom-dropdown-menu li,
.custom-dropdown-menu li a {
  color: #fff;
  padding: 10px 15px;
  font-size: 14px;
  transition: background-color 0.3s ease;
  cursor: pointer;
}

.custom-dropdown-menu li:hover,
.custom-dropdown-menu li a:hover {
  background: #333;
  color: #fff;
}

.custom-dropdown-menu .divider {
  background: #333;
  height: 1px;
  margin: 5px 0;
}

/* Map Section */
.map-section {
  background: #fff;
  padding: 0;
}

.mechanic-map-container {
  position: relative;
  width: 100%;
  min-height: 400px;
}

#svg-map {
  width: 100%;
  height: 100%;
}

/* Responsive Design */
@media (max-width: 768px) {
  .map-logo {
    height: 80px;
  }

  .language-container {
    top: 10px;
    right: 15px;
  }

  .language-link {
    font-size: 16px;
  }

  .floor-section {
    padding: 15px;
  }

  .floor-title {
    font-size: 20px;
  }

  .floor-subtitle {
    display: block;
  }

  .search-section {
    padding: 10px 15px;
  }

  .search-container {
    flex-direction: row;
    gap: 10px;
  }

  .search-input-wrapper {
    flex: 1;
  }

  .filter-button {
    min-width: 120px;
    flex-shrink: 0;
  }
}

@media (max-width: 480px) {
  .map-logo {
    height: 50px;
  }

  .language-link {
    font-size: 14px;
    padding: 3px 8px;
  }

  .floor-section {
    padding: 10px;
  }

  .floor-title {
    font-size: 18px;
  }

  .floor-subtitle {
    font-size: 12px;
  }

  .floor-button {
    padding: 8px 12px;
    font-size: 12px;
    min-width: 70px;
  }

  .search-section {
    padding: 8px 10px;
  }

  .search-input {
    padding: 10px 35px 10px 12px;
    font-size: 13px;
  }

  .search-icon {
    right: 12px;
    font-size: 14px;
  }

  .filter-button {
    padding: 10px 15px;
    font-size: 13px;
  }
}

/* ============================================
   Navigation Modal Styles
   ============================================ */
#navigation-modal .modal-content {
  border-radius: 0px;
  border: none;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

#navigation-modal .modal-header {
  background: #111;
  color: #fff;
  border-bottom: 1px solid #333;
  border-radius: 0;
}

#navigation-modal .modal-title {
  font-weight: bold;
  font-size: 18px;
}

#navigation-modal .close {
  color: #fff;
  opacity: 0.8;
}

#navigation-modal .close:hover {
  opacity: 1;
}

#navigation-modal .modal-body {
  padding: 25px;
}

/* Search Input Styles */
#navigation-modal .direction-search-input {
  border: 1px solid #ddd;
  border-radius: 0;
  padding: 12px 40px 12px 15px;
  font-size: 14px;
  background: #f9f9f9;
  transition: all 0.3s ease;
  cursor: pointer;
}

#navigation-modal .direction-search-input:focus {
  outline: none;
  border-color: #111;
  background: #fff;
  box-shadow: 0 0 0 2px rgba(17, 17, 17, 0.1);
}

#navigation-modal .direction-search-input[readonly] {
  cursor: pointer;
}

#navigation-modal .direction-search-input[readonly]:focus {
  cursor: pointer;
}

/* Dropdown Icon */
#navigation-modal .direction-dropdown-icon {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #666;
  font-size: 14px;
  pointer-events: none;
  transition: color 0.3s ease;
}

/* Transportation Mode Radio Group */
#navigation-modal .transportation-mode {
  margin-top: 25px;
}

#navigation-modal .transportation-mode > label {
  font-weight: bold;
  color: #111;
  font-size: 16px;
}

#navigation-modal .radio-group {
  display: flex;
  gap: 20px;
  margin-top: 15px;
}

#navigation-modal .radio-item {
  display: flex;
  align-items: center;
  gap: 8px;
}

#navigation-modal .radio-item input[type="radio"] {
  width: 18px;
  height: 18px;
  margin: 0;
  cursor: pointer;
}

#navigation-modal .radio-item label {
  font-size: 14px;
  color: #111;
  cursor: pointer;
  margin: 0;
  font-weight: normal;
}

#navigation-modal .radio-item input[type="radio"]:checked + label {
  font-weight: bold;
  color: #111;
}

/* Modal Footer */
.modal-footer {
  border-top: 1px solid #eee;
  padding: 20px 25px;
  background: #f9f9f9;
  border-radius: 0 0 8px 8px;
}

.modal-footer .btn {
  padding: 10px 20px;
  border-radius: 4px;
  font-weight: 500;
}

.modal-footer .btn-default {
  background: #fff;
  border: 1px solid #ddd;
  color: #111;
}

.modal-footer .btn-default:hover {
  background: #f5f5f5;
  border-color: #111;
}

.modal-footer .btn-primary {
  background: #111;
  border: 1px solid #111;
  color: #fff;
}

.modal-footer .btn-primary:hover {
  background: #333;
  border-color: #333;
}

/* Responsive Modal */
@media (max-width: 768px) {
  .modal-dialog {
    margin: 10px;
    max-width: calc(100% - 20px);
  }

  .modal-body {
    padding: 20px;
  }

  .radio-group {
    flex-direction: column;
    gap: 15px;
  }

  .modal-footer {
    padding: 15px 20px;
  }
}

@media (max-width: 480px) {
  .modal-dialog {
    margin: 5px;
    max-width: calc(100% - 10px);
  }

  .modal-body {
    padding: 15px;
  }

  .modal-footer {
    padding: 10px 15px;
  }

  .modal-footer .btn {
    padding: 8px 16px;
    font-size: 13px;
  }
}

/* ============================================
   End Navigation Modal Styles
   ============================================ */

/* ============================================
   Navigation Popup Styles
   ============================================ */

.navigation-popup {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  background: #ffffff;
  border-radius: 0;
  padding: 15px 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
  animation: slideUpIn 0.3s ease-out;
}

@keyframes slideUpIn {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
  }
}

.navigation-popup-content {
  display: flex;
  align-items: center;
  gap: 20px;
}

.navigation-info {
  flex: 1;
}

.navigation-text {
  color: #000000;
  font-size: 14px;
  line-height: 1.4;
}

.navigation-text strong {
  color: #000000;
  font-weight: bold;
}

.navigation-buttons {
  display: flex;
  gap: 15px;
}

.nav-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  background: none;
  color: #000000;
  cursor: pointer;
  border-radius: 0;
  background: #fff;
  border: 1px solid #000000;
  padding: 8px 12px;
  transition: all 0.3s ease;
}

.nav-btn:hover {
  background: #f5f5f5;
}

.nav-btn .fa {
  font-size: 18px;
}

/* Responsive Navigation Popup */
@media (max-width: 768px) {
  .navigation-popup {
    bottom: 10px;
    left: 10px;
    right: 10px;
    transform: none;
    padding: 12px 15px;
  }
}

@media (max-width: 480px) {
  .navigation-popup {
    bottom: 5px;
    left: 5px;
    right: 5px;
    padding: 10px 12px;
  }
}

/* ============================================
   End Navigation Popup Styles
   ============================================ */
