/*
 * Leaflet.SimpleLocate v1.0.5-v11 - 2025-03-23
 *
 * Source:
 * git@github.com:mfhsieh/leaflet-simple-locate.git
 *
 */

body {
    --primary-rgb-simple-loc: 255, 168, 0;
}

@-moz-document url-prefix() {
    .leaflet-simple-locate .fa,
    .leaflet-simple-locate .fab,
    .leaflet-simple-locate .far,
    .leaflet-simple-locate .fas {
        margin-top: .05rem;
        margin-bottom: -.05rem;
    }
}

.leaflet-simple-locate {
    width: 40px!important;
    height: 40px!important;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--viervoet-locate-color, #ff9800);
    border: none;
    border-radius: 50%;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.3) !important;
    cursor: pointer;
    position: relative;
    margin-right: 10px!important;
}

.leaflet-simple-locate .viervoet-material-symbols,
.leaflet-simple-locate .viervoet-material-symbols-filled {
    color: white;
    font-size: 24px;
}

.leaflet-simple-locate .rotate-30 {
    transform: rotate(30deg);
}

.leaflet-simple-locate--active::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(var(--viervoet-locate-color-rgb), 0.6);
    animation: viervoet-locate-pulse 2s infinite;
}

@keyframes viervoet-locate-pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(var(--viervoet-locate-color-rgb), 0.6);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(var(--viervoet-locate-color-rgb), 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(var(--viervoet-locate-color-rgb), 0);
    }
}

.leaflet-simple-locate-spinner {
    fill: white;
    width: 24px;
    height: 24px;
}

.1leaflet-simple-locate.button-locate {
    position: absolute;
    margin: 0 !important;
    left: .5rem;
    top: calc(var(--vh, 1vh) * 50);
    transform: translateY(-50%);
}

.1leaflet-simple-locate.button-locate {
    margin: 5px !important;
}

.leaflet-simple-locate-icon {
    fill: rgba(var(--primary-rgb-simple-loc), 1);
    pointer-events: none !important;
    cursor: grab;
}

.leaflet-simple-locate-icon stop {
    stop-color: rgba(var(--primary-rgb-simple-loc), 1);
}

.leaflet-simple-locate-icon .orientation {
    transform: rotate(calc(-1 * var(--leaflet-simple-locate-orientation, 0deg)));
}

.leaflet-simple-locate-circle {
    display: var(--leaflet-simple-locate-circle-display);
    fill: rgba(var(--primary-rgb-simple-loc), 1);
    fill-opacity: .1;
    stroke: rgba(var(--primary-rgb-simple-loc), 1);
    stroke-width: 1;
    stroke-opacity: .3;
    pointer-events: none !important;
    cursor: grab;
}


#leaflet-simple-locate-icon-spot {
    pointer-events: auto;
    cursor: pointer;
}

/* Modal styling */
.viervoet-locate-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 910000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  font-family: system-ui, sans-serif;
}

.viervoet-locate-modal__content {
  background: #fff;
  padding: 1rem 1.25rem;
  border-radius: 18px;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.25);
  width: 100%;
  max-width: 500px;
  animation: viervoet-slideUp 0.3s ease-out;
  box-sizing: border-box;
}

@keyframes viervoet-slideUp {
  from { transform: translateY(30px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}

.viervoet-locate-modal__header h2 {
  margin: 0 0 4px 0;
  font-size: 16px;
  font-weight: 700;
  color: #333;
}

.viervoet-locate-modal__header p {
  margin: 0 0 12px 0;
  font-size: 12px;
  color: #777;
}

.viervoet-locate-modal__options {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.viervoet-locate-modal__option {
  background: #f7f7f7;
  border-radius: 14px;
  padding: 10px 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
  transition: background 0.2s, box-shadow 0.2s;
  border: 2px solid transparent;
}

.viervoet-locate-modal__option:hover {
  background: #eee;
}

.viervoet-locate-modal__option--disabled {
  opacity: 0.4;
  cursor: not-allowed;
  pointer-events: none;
}

.viervoet-locate-modal__option--active {
  border-color: #ffa000;
  background: #fff8e1;
  box-shadow: 0 0 0 2px rgba(255, 168, 0, 0.3);
}

.viervoet-locate-modal__icon {
  flex-shrink: 0;
  width: 40px;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
  background: #ccc;
  display: flex;
  align-items: center;
  justify-content: center;
}

.viervoet-locate-modal__icon .viervoet-material-symbols {
  font-size: 24px;
  color: white;
}

.viervoet-locate-modal__icon--nav { background: #ff9800; }
.viervoet-locate-modal__icon--follow { background: #2196f3; }
.viervoet-locate-modal__icon--free { background: #4caf50; }
.viervoet-locate-modal__icon--marker { background: #607d8b; }
.viervoet-locate-modal__icon--off { background: #9e9e9e; }

.viervoet-locate-modal__text {
  flex: 1;
  min-width: 0;
  line-height: 1;
  display: flex;
  align-items: flex-start;
  flex-direction: column;
}

.viervoet-locate-modal__text strong {
  font-size: 16px;
  display: block;
  color: #222;
  margin-bottom: 6px;
}

.viervoet-locate-modal__text small {
    font-size: 13px;
    color: #555;
    word-break: break-word;
    display: inline-block;
    line-height: 1.1;
}

.viervoet-locate-modal__hint {
    margin-top: 6px;
    font-size: 12px;
    line-height: 1.2;
    color: #2e7d32;
    background: rgba(76, 175, 80, 0.1);
    padding: 4px 6px;
    border-radius: 6px;
}

.viervoet-locate-modal__badge {
  font-size: 11px;
  background: #eee;
  color: #666;
  padding: 0px 5px;
  border-radius: 6px;
  position: absolute;
  top: 6px;
  right: 10px;
}

.viervoet-locate-modal__badge--active {
  background: #ffa000;
  color: white;
}

@media (max-width: 500px) {
  .viervoet-locate-modal__content {
    padding: 0.75rem 1rem;
  }

  .viervoet-locate-modal__option {
    padding: 8px 10px;
    gap: 8px;
  }

  .viervoet-locate-modal__icon {
    width: 32px;
    aspect-ratio: 1 / 1;
  }

  .viervoet-locate-modal__icon .viervoet-material-symbols {
    font-size: 20px;
  }

  .viervoet-locate-modal__text strong {
    font-size: 15px;
  }

  .viervoet-locate-modal__text small {
    font-size: 12px;
  }

  .viervoet-locate-modal__badge {
    font-size: 10px;
    padding: 0px 5px;
  }
}