/* Mode édition — crayons + barre d'enregistrement */

body.is-editing {
  padding-top: 72px;
}

.edit-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 0.85rem 1.25rem;
  background: var(--brown-title);
  color: var(--white);
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
}

.edit-bar__info {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.edit-bar__info strong {
  font-size: 0.95rem;
}

.edit-bar__info span {
  font-size: 0.8rem;
  opacity: 0.8;
}

.edit-bar__actions {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.edit-bar .btn--secondary {
  border-color: rgba(255, 255, 255, 0.45);
  color: var(--white);
  text-decoration: none;
}

.edit-bar .btn--secondary:hover {
  background: var(--white);
  color: var(--brown-title);
}

.edit-bar .btn--primary {
  background: var(--aqua);
}

.edit-bar .btn--primary:hover {
  background: var(--aqua-dark);
}

.is-editable {
  position: relative;
  transition: outline 0.2s ease, background 0.2s ease;
}

.is-editable.is-editing-field {
  outline: 2px dashed var(--aqua);
  outline-offset: 6px;
  background: rgba(216, 235, 228, 0.4);
  border-radius: 4px;
  padding-right: 2rem;
}

.edit-pencil {
  position: absolute;
  top: -8px;
  right: -8px;
  z-index: 30;
  width: 28px;
  height: 28px;
  border: none;
  border-radius: 50%;
  background: var(--aqua);
  color: var(--white);
  font-size: 0.9rem;
  line-height: 1;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(79, 125, 110, 0.4);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.edit-pencil:hover {
  background: var(--aqua-dark);
  transform: scale(1.08);
}

.faq__question-text.is-editable {
  flex: 1;
  text-align: left;
  padding-right: 1.75rem;
  display: block;
  position: relative;
}

.faq__head {
  position: relative;
}

.faq__answer .is-editable {
  display: block;
  position: relative;
}

body.is-editing .faq__item {
  overflow: visible;
}

.edit-toast {
  position: fixed;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10001;
  padding: 0.85rem 1.4rem;
  background: var(--aqua-dark);
  color: var(--white);
  border-radius: 50px;
  font-weight: 600;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.2);
}

@media (max-width: 700px) {
  body.is-editing {
    padding-top: 120px;
  }
}
