/* ========================================================================== */
/* Mur de la mémoire — formulaire privé de proposition et de correction       */
/* ========================================================================== */

.memory-wall-private-form-page {
  --memory-form-base: #f4efe7;
  --memory-form-paper: #fffdf9;
  --memory-form-ink: #20191f;
  --memory-form-muted: #6f666a;
  --memory-form-rule: #d8cec3;
  --memory-form-dark: #1d151c;
  --memory-form-on-dark: #f8f3eb;
  --memory-form-accent: var(--accent-on-light, #76571f);
  --memory-form-accent-hover: var(--accent-on-light-hover, #5e4419);
  background: var(--memory-form-base);
  color: var(--memory-form-ink);
}

.memory-wall-private-form-page :is(h1, h2, p, li, dt, dd, label, legend, summary) {
  color: inherit;
}

.memory-wall-private-form-page :is(a, button, input, select, textarea, summary):focus-visible {
  outline: 3px solid var(--memory-form-accent);
  outline-offset: 3px;
}

.memory-wall-form-hero .container,
.memory-wall-private-form .container,
.memory-wall-form-assurance .container {
  width: 100%;
  max-width: 1240px;
  padding-right: 24px;
  padding-left: 24px;
}

/* Le hero reste transactionnel : il identifie l'action sans retarder le formulaire. */
.memory-wall-form-hero {
  display: flex;
  min-height: 360px;
  align-items: center;
  padding: 44px 0 48px;
  background: var(--memory-form-dark);
  color: var(--memory-form-on-dark);
}

.memory-wall-form-hero__back {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 38px;
  color: var(--memory-form-on-dark);
  font-size: 13px;
  font-weight: 600;
  line-height: 20px;
  text-decoration: none;
}

.memory-wall-form-hero__back:hover {
  color: var(--accent-on-dark, #cbae72);
}

.memory-wall-eyebrow {
  margin: 0 0 14px;
  color: var(--memory-form-accent);
  font-size: 11px;
  font-weight: 800;
  line-height: 18px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.memory-wall-form-hero .memory-wall-eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  color: var(--accent-on-dark, #cbae72);
}

.memory-wall-form-hero h1 {
  margin: 0;
  font-family: var(--font-editorial);
  font-size: 58px;
  font-weight: 500;
  line-height: 64px;
  letter-spacing: -1px;
}

.memory-wall-form-hero p:last-child {
  max-width: 720px;
  margin: 18px 0 0;
  color: rgba(248, 243, 235, 0.78);
  font-size: 17px;
  line-height: 28px;
}

/* La zone de travail adopte une grille 3/9 ou 4/8 sans hauteur réservée. */
.memory-wall-private-form {
  padding: 56px 0 64px;
  background: var(--memory-form-base);
}

.memory-wall-private-form__layout {
  --bs-gutter-x: 32px;
  --bs-gutter-y: 32px;
  align-items: flex-start;
}

.memory-wall-private-form__guide-panel {
  position: sticky;
  top: 112px;
  padding: 24px;
  border: 1px solid var(--memory-form-rule);
  background: rgba(255, 253, 249, 0.68);
}

.memory-wall-private-form__guide h2 {
  margin: 0;
  font-family: var(--font-editorial);
  font-size: 27px;
  font-weight: 500;
  line-height: 33px;
}

.memory-wall-private-form__guide ul {
  margin: 24px 0 0;
  padding: 0;
  border-top: 1px solid var(--memory-form-rule);
  list-style: none;
}

.memory-wall-private-form__guide li {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 11px;
  padding: 14px 0;
  border-bottom: 1px solid var(--memory-form-rule);
  color: var(--memory-form-muted);
  font-size: 13px;
  line-height: 20px;
}

.memory-wall-private-form__guide li i {
  margin-top: 3px;
  color: var(--memory-form-accent);
  text-align: center;
}

.memory-wall-private-form__guide details {
  border-bottom: 1px solid var(--memory-form-rule);
}

.memory-wall-private-form__guide summary {
  padding: 15px 0;
  color: var(--memory-form-accent);
  cursor: pointer;
  font-size: 13px;
  font-weight: 800;
  line-height: 20px;
}

.memory-wall-private-form__guide details p {
  margin: 0 0 15px;
  color: var(--memory-form-muted);
  font-size: 12px;
  line-height: 20px;
}

.memory-wall-private-form__help {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  color: var(--memory-form-accent);
  font-size: 12px;
  font-weight: 800;
  line-height: 19px;
  text-decoration: none;
}

.memory-wall-form {
  position: relative;
  padding: 32px;
  border: 1px solid var(--memory-form-rule);
  background: var(--memory-form-paper);
}

.memory-wall-form__required,
.memory-wall-form-step__intro {
  color: var(--memory-form-muted);
  font-size: 13px;
  line-height: 21px;
}

.memory-wall-form__required {
  margin: 0 0 26px;
  text-align: right;
}

.memory-wall-form__required span {
  color: var(--memory-form-accent);
  font-weight: 800;
}

.memory-wall-form-step__intro {
  margin: 0;
}

.memory-wall-form-progress {
  position: relative;
  margin: 0 0 32px;
}

.memory-wall-form-progress ol {
  position: relative;
  z-index: 2;
  justify-content: space-between;
  margin: 0;
  padding: 0;
  list-style: none;
}

.memory-wall-form-progress li {
  display: flex;
  width: 20%;
  flex-direction: column;
  gap: 7px;
  color: var(--memory-form-muted);
  font-size: 10px;
  line-height: 15px;
}

.memory-wall-form-progress li:not(:first-child):not(:last-child) {
  align-items: center;
  text-align: center;
}

.memory-wall-form-progress li:last-child {
  align-items: flex-end;
  text-align: right;
}

.memory-wall-form-progress li span {
  display: flex;
  width: 30px;
  height: 30px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--memory-form-rule);
  border-radius: 50%;
  background: var(--memory-form-paper);
}

.memory-wall-form-progress li.is-current,
.memory-wall-form-progress li.is-complete {
  color: var(--memory-form-ink);
}

.memory-wall-form-progress li.is-current span,
.memory-wall-form-progress li.is-complete span {
  border-color: var(--memory-form-accent);
  background: var(--memory-form-accent);
  color: #ffffff;
}

.memory-wall-form-progress__line {
  position: absolute;
  top: 14px;
  right: 15px;
  left: 15px;
  z-index: 1;
  height: 1px;
  background: var(--memory-form-rule);
}

.memory-wall-form-progress__line i {
  display: block;
  width: 0;
  height: 1px;
  background: var(--memory-form-accent);
  transition: width 220ms ease;
}

.memory-wall-form > fieldset {
  margin: 0;
  padding: 0;
  border: 0;
}

.memory-wall-form > fieldset > legend {
  float: none;
  width: 100%;
  margin: 0 0 14px;
  padding: 0 0 14px;
  border-bottom: 1px solid var(--memory-form-ink);
  font-family: var(--font-editorial);
  font-size: 30px;
  font-weight: 500;
  line-height: 36px;
}

/* Une étape inactive ne conserve aucune hauteur après l'initialisation. */
.memory-wall-form[data-memory-wall-form-enhanced="true"] [data-memory-wall-form-step][hidden] {
  display: none;
}

.memory-wall-choice-list {
  --bs-gutter-x: 12px;
  --bs-gutter-y: 12px;
  margin-top: 24px;
}

.memory-wall-choice-list.row > [class*="col-"] {
  display: flex;
}

.memory-wall-choice-list label {
  position: relative;
  display: flex;
  min-height: 68px;
  width: 100%;
  height: 100%;
  align-items: center;
  gap: 12px;
  padding: 13px 15px;
  border: 1px solid var(--memory-form-rule);
  background: #ffffff;
  cursor: pointer;
  font-size: 14px;
  line-height: 21px;
  word-break: normal;
  overflow-wrap: normal;
  hyphens: none;
}

.memory-wall-private-form-page .memory-wall-choice-list label > span:not(.gcf-field-support) {
  min-width: 0;
  flex: 1 1 auto;
  word-break: normal;
  overflow-wrap: normal;
  hyphens: none;
}

/* Le système de formulaires réserve son retour sans réduire la largeur du libellé. */
.memory-wall-private-form-page .memory-wall-choice-list label > .gcf-field-support {
  position: absolute;
  right: 15px;
  bottom: 4px;
  left: 55px;
  width: auto;
  min-height: 0;
}

.memory-wall-private-form-page .memory-wall-choice-list label:has(.gcf-field-feedback:not(:empty)) {
  padding-bottom: 34px;
}

.memory-wall-choice-list label:has(input:checked) {
  border-color: var(--memory-form-accent);
}

.memory-wall-choice-list input {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  accent-color: var(--memory-form-accent);
}

.memory-wall-field {
  margin-bottom: 20px;
}

.memory-wall-field label,
.memory-wall-nested-fieldset legend {
  display: block;
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 800;
  line-height: 20px;
}

.memory-wall-field :is(input, select, textarea) {
  width: 100%;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid var(--memory-form-rule);
  border-radius: 0;
  background: #ffffff;
  color: var(--memory-form-ink);
  font-size: 14px;
  line-height: 22px;
}

.memory-wall-field textarea {
  min-height: 122px;
  resize: vertical;
}

.memory-wall-field p {
  margin: 7px 0 0;
  color: var(--memory-form-muted);
  font-size: 12px;
  line-height: 19px;
}

.memory-wall-nested-fieldset {
  margin: 18px 0 22px;
  padding: 20px;
  border: 1px solid var(--memory-form-rule);
}

.memory-wall-nested-fieldset legend {
  float: none;
  width: auto;
  padding: 0 6px;
}

.memory-wall-nested-fieldset .memory-wall-choice-list {
  margin-top: 8px;
}

.memory-wall-consent {
  display: flex;
  align-items: flex-start;
  gap: 11px;
  margin: 0 0 12px;
  padding: 15px;
  border: 1px solid var(--memory-form-rule);
  background: #ffffff;
  font-size: 13px;
  line-height: 21px;
}

.memory-wall-consent input {
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  margin-top: 2px;
  accent-color: var(--memory-form-accent);
}

.memory-wall-private-form-page .button {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  padding: 10px 17px;
  border: 1px solid var(--memory-form-accent);
  border-radius: 0;
  background: var(--memory-form-accent);
  color: #ffffff;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  line-height: 20px;
  text-align: center;
  text-decoration: none;
  transition: border-color 180ms ease, background-color 180ms ease, color 180ms ease;
}

.memory-wall-private-form-page .button:hover {
  border-color: var(--memory-form-accent-hover);
  background: var(--memory-form-accent-hover);
  color: #ffffff;
}

.memory-wall-private-form-page .button--outline {
  background: transparent;
  color: var(--memory-form-accent);
}

.memory-wall-private-form-page .button--text {
  padding-right: 4px;
  padding-left: 4px;
  border-color: transparent;
  background: transparent;
  color: var(--memory-form-accent);
}

.memory-wall-private-form-page .button--outline:hover,
.memory-wall-private-form-page .button--text:hover {
  border-color: var(--memory-form-accent);
  background: rgba(118, 87, 31, 0.08);
  color: var(--memory-form-accent-hover);
}

.memory-wall-form-navigation {
  display: grid;
  grid-template-columns: auto minmax(190px, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  margin-top: 30px;
  padding-top: 20px;
  border-top: 1px solid var(--memory-form-rule);
}

.memory-wall-form-navigation__counter {
  color: var(--memory-form-muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 19px;
  white-space: nowrap;
}

.memory-wall-form-draft-status {
  min-height: 20px;
  margin: -20px 0 12px;
  color: var(--memory-form-muted);
  font-size: 12px;
  line-height: 20px;
  text-align: right;
}

.memory-wall-file-preview {
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.memory-wall-file-preview li {
  display: flex;
  min-height: 64px;
  align-items: center;
  gap: 14px;
  padding: 9px 0;
  border-bottom: 1px solid var(--memory-form-rule);
  color: var(--memory-form-muted);
  font-size: 13px;
  line-height: 20px;
}

.memory-wall-file-preview img {
  width: 72px;
  height: 54px;
  flex: 0 0 72px;
  object-fit: cover;
}

.memory-wall-upload-progress {
  margin-top: 20px;
}

.memory-wall-upload-progress progress {
  width: 100%;
  height: 8px;
  border: 0;
  border-radius: 0;
  accent-color: var(--memory-form-accent);
}

.memory-wall-upload-progress p {
  margin: 7px 0 0;
  color: var(--memory-form-muted);
  font-size: 12px;
  line-height: 20px;
}

.memory-wall-form-feedback {
  margin: 0 0 24px;
  padding: 20px;
  border: 1px solid var(--memory-form-rule);
  background: var(--memory-form-paper);
}

.memory-wall-form-feedback.is-success {
  border-left: 4px solid var(--memory-form-accent);
}

.memory-wall-form-feedback.is-error {
  border-left: 4px solid #8c283a;
}

.memory-wall-form-feedback h2 {
  margin: 0 0 8px;
  font-family: var(--font-editorial);
  font-size: 24px;
  font-weight: 500;
  line-height: 30px;
}

.memory-wall-form-feedback p,
.memory-wall-form-feedback li {
  font-size: 14px;
  line-height: 22px;
}

.memory-wall-honeypot {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
}

/* Le bandeau rassemble les garanties sans réintroduire un développement éditorial. */
.memory-wall-form-assurance {
  padding: 32px 0;
  background: var(--memory-form-dark);
  color: var(--memory-form-on-dark);
}

.memory-wall-form-assurance .container {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 44px;
  align-items: center;
}

.memory-wall-form-assurance .memory-wall-eyebrow {
  color: var(--accent-on-dark, #cbae72);
}

.memory-wall-form-assurance h2 {
  margin: 0;
  font-family: var(--font-editorial);
  font-size: 25px;
  font-weight: 500;
  line-height: 31px;
}

.memory-wall-form-assurance dl {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  margin: 0;
}

.memory-wall-form-assurance dl div {
  min-height: 92px;
  padding: 7px 18px;
  border-left: 1px solid rgba(248, 243, 235, 0.22);
}

.memory-wall-form-assurance dt {
  margin-bottom: 7px;
  color: var(--accent-on-dark, #cbae72);
  font-size: 12px;
  font-weight: 800;
  line-height: 19px;
}

.memory-wall-form-assurance dd {
  margin: 0;
  color: rgba(248, 243, 235, 0.72);
  font-size: 12px;
  line-height: 19px;
}

/* Cette page aboutit directement au footer système, sans parcours illustré. */
body[data-page="mur-de-la-memoire-contribution"] .site-footer__journeys,
body[data-page="mur-de-la-memoire-correction"] .site-footer__journeys,
body[data-page="mur-de-la-memoire-contribution"] .site-footer__background,
body[data-page="mur-de-la-memoire-correction"] .site-footer__background,
body[data-page="mur-de-la-memoire-contribution"] .site-footer__opening,
body[data-page="mur-de-la-memoire-correction"] .site-footer__opening {
  display: none;
}

@media (max-width: 1199px) {
  .memory-wall-form-hero {
    min-height: 300px;
    padding-top: 38px;
    padding-bottom: 40px;
  }

  .memory-wall-form-hero__back {
    margin-bottom: 30px;
  }

  .memory-wall-form-hero h1 {
    font-size: 50px;
    line-height: 56px;
  }

  .memory-wall-private-form {
    padding-top: 48px;
    padding-bottom: 56px;
  }

  .memory-wall-form {
    padding: 28px;
  }

  .memory-wall-form-navigation {
    grid-template-columns: auto minmax(170px, 1fr) auto;
  }

  .memory-wall-form-navigation__counter {
    grid-column: 1 / -1;
    grid-row: 1;
    text-align: right;
  }

  .memory-wall-form-assurance .container {
    grid-template-columns: 230px minmax(0, 1fr);
    gap: 28px;
  }
}

@media (max-width: 991px) {
  .memory-wall-form-assurance {
    padding-top: 22px;
    padding-bottom: 22px;
  }

  .memory-wall-private-form__workspace {
    order: 1;
  }

  .memory-wall-private-form__guide {
    order: 2;
  }

  .memory-wall-private-form__guide-panel {
    position: static;
  }

  .memory-wall-private-form__guide ul {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 24px;
  }

}

@media (max-width: 767px) {
  .memory-wall-form-hero {
    min-height: 260px;
    padding: 32px 0 34px;
  }

  .memory-wall-form-hero__back {
    margin-bottom: 25px;
  }

  .memory-wall-form-hero h1 {
    font-size: 42px;
    line-height: 47px;
    letter-spacing: -0.5px;
  }

  .memory-wall-form-hero p:last-child {
    margin-top: 14px;
    font-size: 15px;
    line-height: 24px;
  }

  .memory-wall-private-form {
    padding: 36px 0 44px;
  }

  .memory-wall-private-form__guide-panel,
  .memory-wall-form {
    padding: 22px;
  }

  .memory-wall-private-form__guide h2 {
    font-size: 25px;
    line-height: 31px;
  }

  .memory-wall-form__required {
    margin-bottom: 22px;
    text-align: left;
  }

  .memory-wall-form-progress li strong {
    display: none;
  }

  .memory-wall-form > fieldset > legend {
    font-size: 27px;
    line-height: 33px;
  }

  .memory-wall-form-assurance .container {
    display: block;
  }

  .memory-wall-form-assurance__intro {
    max-width: 620px;
    margin-bottom: 24px;
  }

  .memory-wall-form-assurance dl {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .memory-wall-form-assurance dl div {
    border-bottom: 1px solid rgba(248, 243, 235, 0.18);
  }
}

@media (max-width: 575px) {
  .memory-wall-form-hero .container,
  .memory-wall-private-form .container,
  .memory-wall-form-assurance .container {
    padding-right: 18px;
    padding-left: 18px;
  }

  .memory-wall-form-hero h1 {
    font-size: 39px;
    line-height: 44px;
  }

  .memory-wall-private-form__guide ul {
    display: block;
  }

  .memory-wall-private-form__guide-panel,
  .memory-wall-form {
    padding: 18px;
  }

  .memory-wall-form-progress {
    margin-bottom: 26px;
  }

  .memory-wall-form-progress li {
    width: 20%;
  }

  .memory-wall-form-progress li span {
    width: 28px;
    height: 28px;
  }

  .memory-wall-form-progress__line {
    top: 13px;
    right: 14px;
    left: 14px;
  }

  .memory-wall-choice-list label {
    min-height: 58px;
    padding: 11px 13px;
  }

  .memory-wall-form-navigation {
    grid-template-columns: 1fr;
    gap: 9px;
    margin-top: 24px;
    padding-top: 17px;
  }

  .memory-wall-form-navigation__counter {
    grid-column: auto;
    grid-row: auto;
    order: -2;
    text-align: center;
  }

  .memory-wall-form-navigation .button {
    width: 100%;
  }

  .memory-wall-form-navigation .button--text {
    order: -1;
  }

  .memory-wall-form-draft-status {
    margin-top: -16px;
    text-align: left;
  }

  .memory-wall-form-assurance {
    padding-top: 28px;
    padding-bottom: 28px;
  }

  .memory-wall-form-assurance dl div {
    min-height: 0;
    padding: 13px 10px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .memory-wall-private-form-page *,
  .memory-wall-private-form-page *::before,
  .memory-wall-private-form-page *::after {
    scroll-behavior: auto;
    transition-duration: 0.01ms;
  }
}
