/* Basic styling for the plugin */
.ws-store-map-wrapper {
  width: 100%;
}

.ws-store-controls {
  gap: 8px;
  background: #fff;
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 10px;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}
.ws-store-controls input[type="text"] {
  border: 1px solid #d0d0d0;
  border-radius: 6px;
  padding: 8px 10px;
}
.ws-store-controls .button {
  padding: 8px 12px;
  border-radius: 6px;
}

/* Prevent global theme CSS from stretching Leaflet/Google images */
.ws-store-map-wrapper img {
  max-width: none !important;
  height: auto !important;
}

.ws-infowindow h4 {
  margin: 0 0 6px 0;
  font-size: 16px;
}
.ws-infowindow div {
  font-size: 14px;
}

/* Minimal popup primary action button */
.ws-infowindow .ws-directions,
.ws-infowindow .ws-directions-ext {
  display: inline-block;
  padding: 8px 12px;
  border-radius: 6px;
  background: #1976d2;
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}
.ws-infowindow .ws-directions:hover,
.ws-infowindow .ws-directions-ext:hover {
  background: #1565c0;
}

/* Leaflet container tweaks */
#ws-store-map {
  border-radius: 6px;
}
.leaflet-popup-content h4 {
  margin: 0 0 6px 0;
  font-size: 16px;
}
.leaflet-popup-content div {
  font-size: 14px;
}

/* Ensure Google Places dropdown overlays UI */
.pac-container {
  z-index: 2000 !important;
}

/* Sidebar layout */
.ws-store-layout {
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 12px;
}
.ws-store-sidebar {
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 8px;
  max-height: 100%;
  overflow: auto;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}
.ws-store-item {
  border: 1px solid #f0f0f0;
  border-radius: 8px;
  padding: 12px 10px;
  cursor: pointer;
  margin-bottom: 10px;
  background: #fff;
  transition: box-shadow 0.15s ease, border-color 0.15s ease;
}
.ws-store-item:hover {
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  border-color: #e0e0e0;
}
.ws-store-item.selected {
  border-color: #1976d2;
  box-shadow: 0 0 0 2px rgba(25, 118, 210, 0.18) inset;
  background: #eef6ff;
}
.ws-store-item.selected .ws-store-title {
  color: #0d47a1;
}
.ws-store-item:last-child {
  border-bottom: none;
}
.ws-store-title {
  font-weight: 600;
  margin-bottom: 6px;
}
.ws-store-address,
.ws-store-hours {
  color: #555;
  font-size: 13px;
  margin: 4px 0;
}
.ws-store-contact {
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 13px;
  color: #333;
}
.ws-contact-item a {
  color: #1976d2;
  text-decoration: none;
}
.ws-contact-item a:hover {
  text-decoration: underline;
}
.ws-store-actions {
  margin-top: 6px;
}
.ws-store-actions .button {
  padding: 6px 10px;
}

/* Services chips */
.ws-store-services {
  margin-top: 6px;
}
.ws-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  line-height: 18px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  color: #333;
  margin: 2px 6px 2px 0;
}

/* Sectioned lists for products/services */
.ws-accordion {
  margin-top: 8px;
  border-top: 1px solid #eee;
}
.ws-acc-section {
  border-bottom: 1px solid #eee;
}
.ws-acc-toggle {
  width: 100%;
  text-align: left;
  background: none;
  border: 0;
  padding: 10px 6px;
  font-weight: 600;
  cursor: pointer;
  position: relative;
  color: #1f2937;
  font-size: 14px;
  line-height: 1.4;
}
.ws-acc-toggle::after {
  content: "\25BC";
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%) rotate(0deg);
  transition: transform 0.15s ease;
  font-size: 12px;
  color: #666;
}
.ws-acc-toggle[aria-expanded="true"]::after {
  transform: translateY(-50%) rotate(180deg);
}
.ws-acc-panel {
  display: none;
  padding: 0 6px 10px 6px;
}
.ws-acc-panel.open {
  display: block;
}
.ws-section-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.ws-section-list li {
  margin: 4px 0;
  display: flex;
  align-items: center;
  gap: 6px;
}
.ws-hours-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.ws-hours-list li {
  display: flex;
  justify-content: space-between;
  padding: 2px 0;
}
.ws-day {
  color: #333;
}
.ws-time {
  color: #555;
}
.ws-list-icon {
  width: 16px;
  height: 16px;
  object-fit: contain;
  display: block;
}

@media (max-width: 900px) {
  .ws-store-layout {
    grid-template-columns: 1fr;
  }
  .ws-store-sidebar {
    max-height: 280px;
  }
}
