body {
  background: #f3ede6;
}
.entete-page {
  margin: 2.5em 0 1em 0;
  text-align: center;
}
.documents-content {
  max-width: 1100px;
  margin: 0 auto 40px auto;
  padding: 0 1em;
}
.section-title {
  margin: 2em 0 1em;
  font-size: 1.25em;
  font-weight: 700;
  display: flex;
  align-items: center;
  color: #492a15;
}
.icon {
  font-size: 1.2em;
  margin-right: 0.5em;
}
.search-bar {
  margin: 1.5em auto 2em;
  width: 100%;
  max-width: 430px;
  display: flex;
}
.search-bar input {
  flex: 1;
  padding: 0.7em 1em;
  border-radius: 0.7em 0 0 0.7em;
  border: 1px solid #ded5cc;
  font-size: 1em;
}
.search-bar button {
  padding: 0.7em 1.1em;
  border-radius: 0 0.7em 0.7em 0;
  border: none;
  background: #492a15;
  color: #fff;
  font-size: 1em;
  font-weight: bold;
  cursor: pointer;
}
.doc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}
.doc-card {
  background: #fff;
  border-radius: 1em;
  box-shadow: 0 2px 8px #0001;
  padding: 1.1em 1.3em 1.2em 1.3em;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  transition: box-shadow 0.2s;
}
.doc-card:hover {
  box-shadow: 0 8px 18px #0003;
}
.doc-title {
  font-size: 1.07em;
  font-weight: 600;
  margin-bottom: 0.3em;
  color: #472817;
}
.doc-desc {
  font-size: 0.97em;
  color: #745c4a;
  margin-bottom: 0.8em;
}
.download-btn,
.locked-btn {
  border: none;
  padding: 0.3em 0.7em;     /* moitié moins */
  border-radius: 0.5em;
  background: #603b23;
  color: #fff;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s, box-shadow 0.15s;
  font-size: 0.8em;
  margin-top: auto;
}
.download-btn:hover,
.locked-btn:hover {
  background: #492a15;
  box-shadow: 0 2px 8px #0002;
}
.locked-btn {
  background: #b2a398;
  color: #fff;
  cursor: pointer;
}
.locked-btn:after {
  content: "🔒";
  margin-left: 0.6em;
}
.devis-lock .locked-btn {
  background: #b2a398;
}
.modal-bg {
  position: fixed;
  left: 0; top: 0;
  width: 100vw; height: 100vh;
  background: #0009;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99;
}
.modal {
  background: #fff;
  padding: 2.2em 2.7em 1.9em 2.7em;
  border-radius: 1.3em;
  max-width: 95vw;
  box-shadow: 0 8px 30px #0005;
  text-align: center;
}
.modal input[type="password"],
.modal input[type="text"] {
  font-size: 1.05em;
  padding: 0.65em 1em;
  border-radius: 0.7em;
  border: 1px solid #ccc;
  margin-bottom: 1.2em;
  width: 90%;
  margin-top: 0.5em;
}

}
.accordion-btn {
  background: #f4f4f4;
  border: none;
  outline: none;
  width: 100%;
  text-align: left;
  padding: 1em;
  font-size: 1em;
  cursor: pointer;
  font-weight: bold;
  border-bottom: 1px solid #e0e0e0;
  transition: background 0.2s;
}
.accordion-btn:hover {
  background: #e0e0e0;
}
.accordion-panel {
  display: none;
  padding: 0 1em 1em 2em;
  background: #fafafa;
  word-break: break-word;
  white-space: normal;
}
.accordion-group {
  width: 100%;
}
.accordion-panel {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}
.accordion-panel.open {
  display: block;
  max-height: 600px; /* ajuster selon contenu */
}
.accordion-panel a.download-btn {
  margin-bottom: 0.4em;
  margin-right: 0.4em;
  display: inline-block;
  min-width: 180px;
  text-align: center;
}
#modal-password {
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
  font-size: 1em;
}
#toggle-pwd {
  min-width: 32px;
  min-height: 32px;
  padding: 0;
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}
#eye-icon {
  font-size: 1.3em;
  pointer-events: none;
}
.modal .flex-row {
  display: flex;
  align-items: center;
  gap: 0.5em;
}
.modal {
  max-width: 340px;
  width: 90vw;
  padding: 2em 1em 1em 1em;
  box-sizing: border-box;
  background: #fff;
  border-radius: 14px;
  margin: auto;
  transition: max-width 0.2s;
}
.modal-btns {
  display: flex;
  justify-content: center;
  gap: 1em;
  margin-bottom: 0.5em;
}
.modal-btns button {
  min-width: 90px;
  padding: 0.6em 1.3em;
  border-radius: 0.7em;
  background: #603b23;
  color: #fff;
  font-weight: 700;
  border: none;
  cursor: pointer;
  font-size: 1em;
  transition: background 0.15s, box-shadow 0.15s;
}
.modal-btns button:hover {
  background: #492a15;
  box-shadow: 0 2px 8px #0002;
}



@media (max-width: 700px) {
  .doc-grid { grid-template-columns: 1fr; }
  .modal { padding: 1.5em 0.9em; }
  .section-title { font-size: 1.07em; }
}
footer {
  text-align: center;
  margin-top: 2em;
  color: #a7917d;
  padding: 2em 0 1em 0;
  font-size: 1em;
}
