/* Pages juridiques et bandeau de consentement.
   Feuille 05 sur 08 : les pages les chargent dans l’ordre des numéros, qui est celui
   de la cascade. Une règle peut corriger une feuille précédente, jamais une suivante. */

/* Pages juridiques : lecture longue, sans perdre la sobriété de l’application. */
.account-entry {
  display: grid;
  place-items: center;
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  margin-left: auto;
  border: 1px solid rgba(255, 255, 255, 0.42);
  border-radius: 50%;
  color: var(--ink);
  text-decoration: none;
}
.account-entry svg {
  width: 21px;
  height: 21px;
}
.account-entry:hover,
.account-entry:focus-visible {
  border-color: var(--coral);
  color: var(--coral);
}
.save-search {
  min-height: 42px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--paper);
  color: var(--ink);
  font: 700 12px var(--sans);
  cursor: pointer;
}
.save-search:hover,
.save-search:focus-visible {
  border-color: var(--coral);
  color: var(--coral);
}
.auth-dialog {
  width: min(440px, calc(100% - 28px));
  padding: 28px;
  border: 0;
  border-radius: var(--r-lg);
  color: var(--ink);
  box-shadow: 0 24px 70px rgba(16, 42, 67, 0.3);
}
.auth-dialog::backdrop {
  background: rgba(16, 42, 67, 0.52);
}
.auth-dialog h2 {
  max-width: 340px;
  margin: 7px 0 10px;
  font-size: 27px;
}
.auth-dialog > p:not(.eyebrow):not(.auth-note):not(.auth-status) {
  color: var(--muted);
  line-height: 1.5;
}
.auth-providers {
  display: grid;
  gap: 10px;
  margin: 22px 0 16px;
}
.auth-providers button,
#email-auth-form button {
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--paper);
  color: var(--ink);
  font: 700 14px var(--sans);
  cursor: pointer;
}
.auth-providers button:hover {
  background: var(--mint);
  border-color: var(--lagoon);
}
.auth-separator {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 12px;
}
.auth-separator::before,
.auth-separator::after {
  content: '';
  height: 1px;
  flex: 1;
  background: var(--line);
}
#email-auth-form {
  display: grid;
  gap: 8px;
  margin-top: 14px;
}
#email-auth-form label {
  font-size: 12px;
  font-weight: 700;
}
#email-auth-form input {
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  padding: 0 12px;
  font: inherit;
}
#email-auth-form button {
  margin-top: 4px;
  background: var(--ink);
  color: white;
}
.auth-note {
  margin: 15px 0 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}
.auth-status {
  min-height: 1em;
  color: var(--lagoon);
  font-size: 12px;
  font-weight: 700;
}
@media (max-width: 700px) {
  .account-entry {
    flex-basis: 40px;
    width: 40px;
    height: 40px;
  }
  .save-search {
    width: 100%;
  }
  .auth-dialog {
    padding: 23px;
  }
  .auth-dialog h2 {
    font-size: 23px;
  }
}

.legal-main {
  width: min(860px, calc(100% - 48px));
  margin: 46px auto 72px;
}
.legal-main > h1 {
  margin-bottom: 27px;
}
.legal-section {
  padding: 25px 0;
  border-top: 1px solid var(--line);
}
.legal-section h2 {
  margin: 0 0 12px;
  font-size: 21px;
}
.legal-section p {
  max-width: 760px;
  margin: 0 0 12px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.62;
}
.legal-section p:last-child {
  margin-bottom: 0;
}
.legal-section a {
  color: var(--lagoon);
  font-weight: 700;
  text-underline-offset: 3px;
}
.legal-draft-notice {
  margin: 0 0 27px;
  padding: 17px 18px;
  border: 1px solid #efb69e;
  border-radius: var(--r-md);
  background: #fff6ee;
  color: #7d3d2b;
}
.legal-draft-notice strong {
  display: block;
  font-size: 14px;
}
.legal-draft-notice p {
  margin: 6px 0 0;
  font-size: 13px;
  line-height: 1.45;
}
.legal-draft-notice code {
  padding: 1px 4px;
  border-radius: var(--r-xs);
  background: rgba(255, 255, 255, 0.75);
  font-family: var(--sans);
  font-size: 12px;
}
.legal-list {
  margin: 0;
}
.legal-list > div {
  display: grid;
  grid-template-columns: 190px minmax(0, 1fr);
  gap: 22px;
  padding: 10px 0;
  border-top: 1px solid rgba(215, 225, 232, 0.65);
}
.legal-list > div:first-child {
  border-top: 0;
}
.legal-list dt {
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
}
.legal-list dd {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}
.legal-note,
.legal-updated {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}
.legal-table-wrap {
  overflow-x: auto;
  margin: 0 0 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-md);
}
.legal-table {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
  background: var(--paper);
}
.legal-table th,
.legal-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  text-align: left;
  vertical-align: top;
  font-size: 13px;
  line-height: 1.45;
}
.legal-table th {
  background: #f7fbfd;
  color: var(--ink);
  font-weight: 700;
}
.legal-table td {
  color: var(--muted);
}
.legal-table tr:last-child td {
  border-bottom: 0;
}
@media (max-width: 700px) {
  .legal-main {
    width: calc(100% - 32px);
    margin: 29px auto 48px;
  }
  .legal-main > h1 {
    margin-bottom: 22px;
  }
  .legal-section {
    padding: 21px 0;
  }
  .legal-section h2 {
    font-size: 19px;
  }
  .legal-section p {
    font-size: 14px;
  }
  .legal-list > div {
    grid-template-columns: 1fr;
    gap: 4px;
  }
  .legal-draft-notice {
    padding: 15px;
  }
}
.legal-value-pending {
  font-weight: 800 !important;
  color: #8a3f22 !important;
  background: #fff0e8;
  border-radius: var(--r-xs);
  padding: 1px 4px;
}
.legal-value-pending::after {
  content: ' \270E';
  display: inline-block;
  margin-left: 3px;
  color: #ff6a13;
  font-size: 0.9em;
}

/* --- Bannière de consentement --- */
.consent-banner {
  position: fixed;
  z-index: 1000;
  left: 16px;
  right: 16px;
  bottom: 16px;
  margin: 0 auto;
  max-width: 760px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 22px;
  padding: 18px 20px;
  border-radius: var(--r-lg);
  background: var(--ink);
  color: #eef4fa;
  box-shadow: 0 18px 44px rgba(16, 42, 67, 0.28);
  animation: consent-rise 0.28s ease-out;
}
@keyframes consent-rise {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.consent-banner__text {
  flex: 1 1 320px;
  min-width: 0;
}
.consent-banner__text strong {
  display: block;
  font-size: 14px;
  margin-bottom: 4px;
}
.consent-banner__text p {
  margin: 0;
  font-size: 12.5px;
  line-height: 1.5;
  color: #c6d5e4;
}
.consent-banner__text a {
  color: #fff;
  font-weight: 700;
  text-underline-offset: 3px;
}
.consent-banner__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  flex: 0 0 auto;
}
.consent-btn {
  border: 0;
  border-radius: var(--r-md);
  padding: 11px 18px;
  font: inherit;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition:
    transform 0.12s ease,
    background 0.12s ease,
    border-color 0.12s ease;
}
.consent-btn:active {
  transform: translateY(1px);
}
.consent-btn--primary {
  background: var(--coral);
  color: #fff;
}
.consent-btn--primary:hover {
  background: #ff7d31;
}
.consent-btn--ghost {
  background: transparent;
  color: #dbe6f1;
  border: 1px solid rgba(219, 230, 241, 0.4);
}
.consent-btn--ghost:hover {
  border-color: rgba(219, 230, 241, 0.8);
  background: rgba(255, 255, 255, 0.06);
}
.consent-btn:focus-visible {
  outline: 2px solid #ffb98a;
  outline-offset: 2px;
}
@media (max-width: 560px) {
  .consent-banner {
    left: 10px;
    right: 10px;
    bottom: 10px;
    padding: 16px;
  }
  .consent-banner__actions {
    width: 100%;
  }
  .consent-btn {
    flex: 1 1 auto;
  }
}
