.acces-refuse {
  max-width: 480px;
  margin: 100px auto;
  text-align: center;
  font-size: 1.1rem;
}

.outil-trace {
  display: flex;
  flex-direction: column;
  height: 100vh;
}

.outil-trace[hidden] {
  display: none;
}

.entete-outil {
  padding: 12px 20px;
  border-bottom: 1px solid #ddd;
  background: #fff;
}

.entete-outil h1 {
  font-size: 1.2rem;
  margin: 0 0 8px 0;
}

.controles-entete {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.controles-entete select,
.controles-entete button {
  padding: 6px 12px;
  border-radius: 4px;
  border: 1px solid #ccc;
  font-size: 0.9rem;
  cursor: pointer;
  background: #fff;
}

.bouton-principal {
  background: #2563eb !important;
  color: #fff;
  border: none !important;
}

.bouton-principal:hover {
  background: #1d4ed8 !important;
}

.bouton-secondaire {
  background: #fff;
  color: #444;
}

.bouton-danger {
  background: #fdecea !important;
  color: #c0392b;
  border: 1px solid #c0392b !important;
}

.bouton-danger:hover {
  background: #f8d7da !important;
}

.instruction-trace {
  margin: 10px 0 0 0;
  padding: 10px;
  background: #fff8e1;
  border: 1px solid #f0c14b;
  border-radius: 6px;
  font-size: 0.9rem;
}

.instruction-trace button {
  margin-left: 10px;
  padding: 4px 10px;
  border-radius: 4px;
  cursor: pointer;
}

.corps-outil {
  flex: 1;
  display: flex;
  overflow: hidden;
}

.zone-plan {
  flex: 1;
  overflow: auto;
  background: #eee;
  position: relative;
}

.conteneur-image-plan {
  position: relative;
  display: inline-block;
}

#image-plan {
  display: block;
  width: 1600px; /* largeur de base, ajustee par le zoom via JS */
  max-width: none;
}

#svg-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.polygone-lot {
  fill: rgba(37, 99, 235, 0);
  stroke: #2563eb;
  stroke-width: 0.15;
  cursor: pointer;
  pointer-events: auto;
  transition: fill 0.12s ease;
}

.polygone-lot:hover {
  fill: rgba(37, 99, 235, 0.15);
}

.polygone-lot.en-edition {
  fill: rgba(230, 126, 34, 0.15);
  stroke: #e67e22;
}

.trace-en-cours {
  fill: rgba(46, 204, 113, 0.25);
  stroke: #27ae60;
  stroke-width: 0.15;
}

.sommet {
  fill: #fff;
  stroke: #2563eb;
  stroke-width: 0.15;
  cursor: grab;
  pointer-events: auto;
}

.sommet.en-edition {
  stroke: #e67e22;
}

.etiquette-lot {
  font-size: 1.6px;
  fill: #1d3557;
  pointer-events: none;
  font-weight: bold;
  opacity: 0;
  transition: opacity 0.12s ease;
}

.lot-groupe:hover .etiquette-lot {
  opacity: 1;
}

.colonne-laterale {
  width: 320px;
  border-left: 1px solid #ddd;
  background: #fafafa;
  padding: 16px;
  overflow-y: auto;
}

.colonne-laterale h2 {
  font-size: 1rem;
  margin-top: 0;
}

.liste-lots {
  list-style: none;
  padding: 0;
  margin: 0 0 16px 0;
}

.liste-lots li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 8px;
  border-radius: 4px;
  margin-bottom: 4px;
  cursor: pointer;
  font-size: 0.9rem;
}

.liste-lots li:hover {
  background: #eef4ff;
}

.liste-lots li.selectionne {
  background: #dbe9ff;
  font-weight: bold;
}

.formulaire-lot {
  border-bottom: 1px solid #ddd;
  padding-bottom: 16px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
}

.formulaire-lot[hidden] {
  display: none;
}

.formulaire-lot h3 {
  margin-top: 0;
  font-size: 1rem;
}

.formulaire-lot label {
  font-size: 0.85rem;
  margin-top: 10px;
  margin-bottom: 4px;
}

.formulaire-lot input {
  padding: 6px 8px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 0.9rem;
}

.boutons-formulaire-lot {
  display: flex;
  gap: 8px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.boutons-formulaire-lot button {
  padding: 6px 12px;
  border-radius: 4px;
  cursor: pointer;
  border: 1px solid #ccc;
  background: #fff;
}
