/* === WRAPPER PRINCIPAL === */
.admin-fiche-wrapper {
  border-radius: 12px;
  padding: 30px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.05);
  text-align: center;
}

.admin-fiche-wrapper a {
  text-decoration: none;
  color: inherit;
}

.admin-fiche-wrapper #fiche-container {
  padding-top: 0px;
}

/* === SECTIONS === */
.admin-section {
  margin: 50px;
}

.admin-section h3 {
  font-size: 1.3em;
  padding: 15px;
  background-color: var(--section-bg);
  border-radius:20px 20px 0 0;
  cursor: pointer;
}

.admin-content {
  max-height: 0;
  overflow: hidden;
  overflow-y: auto;
  transition: max-height 0.4s ease, opacity 0.3s ease;
  opacity: 0;
  border: 1px solid #777777;
  padding: 5px;
}

.admin-content h5
{
	margin: 5px;
}

.admin-section.open .admin-content {
  max-height: 2000px; /* suffisamment grand pour tout afficher */
  opacity: 1;
}
.admin-section h3 {
  cursor: pointer;
  position: relative;
}
.admin-section h3::after {
  content: "▼";
  position: absolute;
  right: 10px;
  font-size: 0.8em;
  transition: transform 0.3s ease;
}
.admin-section.open h3::after {
  transform: rotate(180deg);
}


/* === CHAMPS === */
.admin-field {
  margin-bottom: 18px;
}
.admin-field-search label {
  display: inline-block;
  width: 160px;
  font-weight: bold;
}

.admin-field label {
  display: inline-block;
  width: 160px;
  font-weight: bold;
}
.remplissagerecherchetemp
{
	border-bottom: 1px solid #ccc;
	cursor: pointer;
}

.prompt_area {
  border: 1px solid #ccc;
  border-radius: 6px;
  padding: 6px;
  font-size: 0.95em;
  max-width: 80%;
  width: 250px;
	margin:5px;
}

.prompt_area:focus {
  border-color: #2e8b57;
  outline: none;
}

.line-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  margin:4px;
  background: var(--section-bg);
  border-radius: 6px;
}

#importance_fiche
{
	width: 200px;
}

/* === ACTIONS === */
button
{
	padding: 15px;
	min-width: 50px;
	background: var(--section-bg);
	border-radius: 6px;
	cursor: pointer;
	color: var(--text-color);
}

.admin-actions {
  gap: 20px;
  align-items: center;
  margin-top: 30px;
}

#fillautomatiquetemp {
  position: absolute;
  background: var(--bg-color);
  border: 1px solid #ccc;
  border-radius: 6px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  z-index: 1000;
  width: 250px;
  visibility: hidden;
  transition: opacity 0.2s ease;
}

.suggestion-item {
  padding: 4px 10px;
  font-size: 14px;
  height: 25px;
  line-height: 25px;
  cursor: pointer;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: background-color 0.2s ease;
  display: flex;
  align-items: center;
  border-bottom: 1px solid #ccc;
}

.suggestion-item:hover,
.suggestion-item.selected {
  background-color: #e6f4ea;
  color: #2e8b57;
}

/* === LIENS === */
.btn-link {
  font-weight: bold;
  text-decoration: none;
  margin-right: 15px;
}

.btn-link:hover {
  text-decoration: underline;
}

.gestion-links-admin {
  margin-top: 20px;
}

h4
{
	margin:5px;
}

.link-row {
  display: flex;
  gap: 10px;
  margin-bottom: 10px;
  margin-left: 25px;
  align-items: center;
}

.link-row input[type="text"],
.link-row input[type="number"] {
  width: 200px;
  padding: 4px;
}

.link-row label {
  font-size: 0.9em;
}

.btn-edit-link,
.btn-delete-link {
  cursor: pointer;
  padding: 4px 8px;
}

/* === PHOTOS === */
.photo-block {
	display: inline-block;
	padding: 10px;
	border-radius: 12px;
	box-shadow: 0 2px 6px rgba(0,0,0,0.5);
	width: 250px;
	margin: 20px;
}

.photo-image {
  max-width: 200px;
  max-height: 280px;
  border-radius: 8px;
  margin-bottom: 10px;
}

.photo-actions {
  gap: 15px;
  margin-bottom: 10px;
}

.photo-warning {
  font-weight: bold;
}

.photo-comment {
  font-style: italic;
}

/* === AJOUT PHOTO === */
.photo-ajout-popup {
  position: fixed;
  border: 1px solid #ccc;
  padding: 20px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  z-index: 10000;
  width: 300px;
  top: 15%;
  left: 50%;
  transform: translateX(-50%);
}

.photo-ajout-popup h5 {
  margin: 10px 0 5px;
}

/* === BOUTONS D'ACTIONS === */
.edit-action,
.delete-action,
.add-button,
.btn-validate,
.btn-return {
	margin: 15px auto;
	cursor: pointer;
	font-weight: bold;
	align-items: center;
	text-align: center;
	padding: 10px;
	border-radius: 6px;
	transition: background-color 0.2s ease;
	box-shadow: 0 4px 12px rgba(0,0,0,0.1);
	background-color: gray;
	text-transform: uppercase;
	width: 30%;
	max-width: 250px;
	min-width: 150px;
	color: var(--text-color);
	text-decoration:none;
}

.edit-action:hover,
.delete-action:hover,
.btn-validate:hover,
.btn-return:hover,
.add-button:hover {
  background-color: lightgrey;
}

.edit-label {
  font-size: 0.9em;
}

.question-button {
  display: inline-block;
  width: 20px;
  height: 20px;
  line-height: 20px;
  text-align: center;
  font-weight: bold;
  font-size: 16px;
  color: #2e8b57;
  background-color: #f0f0f0;
  border-radius: 50%;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.question-button:hover {
  background-color: #e0e0e0;
}

.admin-add-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 10px;
  padding: 10px;
  background-color: #f7f7f7;
  border-radius: 8px;
  border: 1px solid #ccc;
}

.prompt-area {
  padding: 6px 10px;
  font-size: 14px;
  border: 1px solid #aaa;
  border-radius: 4px;
  width: 250px;
}

.btn-validate {
  align-self: flex-start;
  padding: 8px 16px;
  font-weight: bold;
  font-size: 14px;
  background-color: grey;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

.btn-validate:hover {
  background-color: lightgrey;
}

.search-results-temp {
	display:inline-block;
  border: 1px solid #ccc;
  width: 250px;
  z-index: 5000;
  visibility: hidden;
  padding: 5px;
}

.info-texte
{
	width: 250px;
	height: 50px;
}