html, body {
  height: 100%;
  margin: 0;
  padding: 0;
  background: #f9f9f9;
  overflow: hidden;
  -webkit-overflow-scrolling: touch;
}

body {
  font-family: 'Apple SD Gothic Neo', sans-serif;
  padding: 20px;
  box-sizing: border-box;
}

h2 {
  font-size: 20px;
  margin-bottom: 12px;
}

.input-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}

input[type="text"] {
  flex: 1;
  min-width: 200px;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 16px;
}

button {
  padding: 10px 16px;
  border: none;
  border-radius: 6px;
  background-color: #3478ff;
  color: white;
  font-size: 16px;
  cursor: pointer;
  transition: background 0.3s;
}

button:hover {
  background-color: #265ed4;
}

.map-container {
  display: flex;
  gap: 20px;
  margin-top: 20px;
  flex-wrap: wrap;
}

#map {
  flex: 1;
  height: 500px;
  min-width: 60%;
  border-radius: 10px;
  overflow: hidden;
}

.result-wrapper {
  width: 35%;
  display: flex;
  flex-direction: column;
}

.result-title {
  font-weight: bold;
  font-size: 18px;
  margin-bottom: 10px;
  opacity: 0;
  height: 0;
  transition: opacity 0.5s ease, height 0.5s ease;
  overflow: hidden;
}

.result-title.visible {
  opacity: 1;
  height: 24px;
}

#resultList {
  overflow-y: auto;
  max-height: 480px;
  border-top: 1px solid #ddd;
  padding-top: 10px;
}

.item {
  background: white;
  border-radius: 8px;
  padding: 12px;
  border: 1px solid #eee;
  margin-bottom: 10px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
  cursor: pointer;
  font-size: 14px;
}

.item:hover {
  background: #f1f1f1;
}

@media (max-width: 768px) {
  body {
    padding: 12px;
    overflow: overlay;
  }

  .input-wrapper {
    flex-direction: column;
  }

  button {
    width: 100%;
  }

  .map-container {
    flex-direction: column;
  }

  #map {
    flex: none;
    width: 100%;
    height: 200px;
  }

  .result-wrapper {
    width: 100%;
    margin-top: 10px;
  }

  .result-title {
    font-size: 16px;
  }

  .item {
    padding: 8px;
    margin-bottom: 4px;
  }
}
