/* geolocations.css */

/* General styles */
.geoloc-wrap { 
  margin: 0; 
  padding: 20px 0;
}

/* Map styles */
#map { 
  width: 100%; 
  height: 70vh; 
  min-height: 480px;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Details panel */
.panel-details { 
  max-height: 70vh; 
  overflow: auto;
  background: linear-gradient(135deg, #f5f7fa 0%, #e8f5e9 100%);
  border-left: 4px solid #2e7d32;
}

.panel-details h5 {
  color: #1b5e20;
  border-bottom: 2px solid #2e7d32;
  padding-bottom: 12px;
  margin-bottom: 20px;
}

/* Controls styles */
.map-controls { 
  font-size: 14px;
  background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
  border: 1px solid #ddd;
  gap: 20px;
}

.control-item { 
  flex: 1 1 auto; 
  min-width: 150px;
}

.control-item .form-select,
.control-item .form-control {
  border: 2px solid #2e7d32;
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 14px;
  transition: all 0.3s ease;
}

.control-item .form-select:focus,
.control-item .form-control:focus {
  border-color: #1b5e20;
  box-shadow: 0 0 0 0.2rem rgba(46, 125, 50, 0.25);
}

.control-item .form-label {
  font-weight: 600;
  color: #1b5e20;
  font-size: 14px;
}

#reset-filter {
  border: 2px solid #d32f2f;
  color: #d32f2f;
  font-weight: 600;
  padding: 8px 20px;
  transition: all 0.3s ease;
}

#reset-filter:hover {
  background-color: #d32f2f;
  color: white;
}

/* Lab info styles */
.lab-title {
  font-size: 18px;
  font-weight: 700;
  color: #1b5e20;
  margin-bottom: 15px;
  padding-bottom: 10px;
  border-bottom: 2px solid #2e7d32;
}

.lab-info {
  font-size: 14px;
  padding: 8px 0;
  color: #333;
  border-bottom: 1px solid #e0e0e0;
}

.lab-info strong {
  color: #2e7d32;
  font-weight: 600;
}

/* Title section styles */
.title-icon {
  font-size: 28px;
  color: #2e7d32;
}

.title-main {
  color: #1b5e20;
  font-weight: 700;
}

.title-icon-details {
  color: #2e7d32;
}

.info-icon {
  font-size: 32px;
  color: #ccc;
}

/* Popup and link styles */
.lab-popup {
  font-size: 13px;
  min-width: 220px;
}

.lab-popup-name {
  color: #1b5e20;
  font-size: 14px;
}

.lab-popup-info {
  color: #666;
}

.phone-link {
  color: #2e7d32;
  text-decoration: none;
}

.phone-link:hover {
  text-decoration: underline;
}

/* Image section styles */
.lab-image-section {
  margin-top: 1.5rem;
  text-align: center;
  padding: 15px;
  background: white;
  border-radius: 8px;
  border: 1px solid #e0e0e0;
}

.image-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: #1b5e20;
  margin-bottom: 0.5rem;
}

.lab-director-img {
  width: 80px;
  height: 106px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  display: block;
  margin: 0 auto;
  border: 1px solid #e0e0e0;
}

.lab-img {
  width: 100px;
  height: 75px;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  display: block;
  margin: 0 auto;
  border: 1px solid #e0e0e0;
}

/* Info placeholder */
#info {
  color: #666;
  font-size: 14px;
  padding: 20px;
  text-align: center;
  background: #f9f9f9;
  border-radius: 6px;
  border: 1px dashed #ccc;
}

/* Leaflet popup styling */
.leaflet-popup-content-wrapper {
  background-color: #f5f7fa;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.leaflet-popup-content {
  font-size: 13px;
  color: #333;
  margin: 8px 0;
}

.leaflet-popup-content strong {
  color: #2e7d32;
}

.leaflet-popup-close-button {
  color: #d32f2f;
}

/* Marker cluster styling */
.marker-cluster {
  background-clip: padding-box;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  color: white;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.marker-cluster:hover {
  filter: brightness(1.1);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  transform: scale(1.05);
}

.marker-cluster-content {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-weight: bold;
  font-size: 16px;
  text-shadow: 1px 1px 2px rgba(0,0,0,0.3);
}

.marker-cluster-small {
  background-color: rgba(46, 125, 50, 0.7);
  font-size: 14px;
  width: 40px;
  height: 40px;
}

.marker-cluster-medium {
  background-color: rgba(46, 125, 50, 0.8);
  font-size: 15px;
  width: 50px;
  height: 50px;
}

.marker-cluster-large {
  background-color: rgba(27, 94, 32, 0.9);
  font-size: 16px;
  width: 60px;
  height: 60px;
}

/* GeoJSON layer styling */
.leaflet-geojson-layer {
  cursor: pointer;
  transition: all 0.2s ease;
}

.leaflet-geojson-layer:hover {
  stroke-width: 3px;
}

/* Region name tooltip */
.region-tooltip {
  background-color: rgba(27, 94, 32, 0.95);
  color: white;
  padding: 8px 12px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 13px;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Responsive adjustments */
@media (max-width: 767px) {
  #map { 
    height: 55vh; 
    min-height: 380px; 
  }
  
  .panel-details { 
    max-height: 40vh; 
    margin-top: 12px; 
  }
  
  .map-controls { 
    flex-direction: column; 
    align-items: stretch; 
    gap: 2rem; 
    padding: 1rem; 
  }
  
  .control-item { 
    min-width: auto; 
    margin-bottom: 1rem; 
  }
  
  .control-item:last-child { 
    margin-bottom: 0; 
  }
  
  .form-select, .form-control, .btn { 
    font-size: 0.9rem; 
  }

  /* Rasm o'lchamlari mobil uchun kichraytiriladi */
  .lab-director-img {
    width: 60px;
    height: 80px;
  }
  
  .lab-img {
    width: 80px;
    height: 60px;
  }
  
  .image-title {
    font-size: 0.85rem;
  }
}

@media (min-width: 768px) {
  .map-controls { 
    flex-direction: row; 
  }
}