/* =========================================================
   PAGES LÉGALES — 5e Groupe Scout SJSR
   Fichier : assets/css/legal-pages.css
   Objectif : look uniforme pour mentions légales + confidentialité
   ========================================================= */

:root {
  --legal-bg: #f6f1e8;
  --legal-surface: #fffaf1;
  --legal-surface-strong: #ffffff;
  --legal-ink: #1f2a24;
  --legal-muted: #5c665f;
  --legal-border: rgba(31, 42, 36, 0.14);

  --legal-brand: #183d2f;
  --legal-brand-2: #245841;
  --legal-accent: #c89b3c;
  --legal-accent-soft: rgba(200, 155, 60, 0.16);

  --legal-radius-lg: 26px;
  --legal-radius-md: 18px;
  --legal-shadow: 0 22px 55px rgba(31, 42, 36, 0.12);
  --legal-shadow-soft: 0 12px 34px rgba(31, 42, 36, 0.08);

  --legal-container: 1060px;
}

/* Base */
.legal-page {
  margin: 0;
  min-height: 100vh;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.65;
  color: var(--legal-ink);
  background:
    radial-gradient(circle at top left, rgba(200, 155, 60, 0.18), transparent 35%),
    linear-gradient(180deg, #fffaf1 0%, var(--legal-bg) 48%, #eee4d5 100%);
}

.legal-page *,
.legal-page *::before,
.legal-page *::after {
  box-sizing: border-box;
}

.legal-page a {
  color: var(--legal-brand-2);
  text-underline-offset: 0.22em;
}

.legal-page a:hover,
.legal-page a:focus-visible {
  color: var(--legal-brand);
}

.legal-shell {
  width: min(var(--legal-container), calc(100% - 32px));
  margin: 0 auto;
}

/* Header */
.legal-hero {
  position: relative;
  padding: 34px 0 26px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(24, 61, 47, 0.98), rgba(36, 88, 65, 0.95)),
    radial-gradient(circle at 80% 10%, rgba(200, 155, 60, 0.32), transparent 34%);
  box-shadow: var(--legal-shadow-soft);
  overflow: hidden;
}

.legal-hero::after {
  content: "";
  position: absolute;
  inset: auto -60px -100px auto;
  width: 280px;
  height: 280px;
  border-radius: 999px;
  background: rgba(200, 155, 60, 0.18);
  pointer-events: none;
}

.legal-nav {
  position: relative;
  z-index: 2;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 28px;
}

.legal-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  text-decoration: none;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.legal-brand__mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 15px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.22);
  font-size: 1.25rem;
}

.legal-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.legal-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 0.95rem;
  font-weight: 760;
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease, border-color 160ms ease;
}

.legal-btn:hover,
.legal-btn:focus-visible {
  transform: translateY(-1px);
}

.legal-btn--light {
  color: var(--legal-brand);
  background: #fffaf1;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.16);
}

.legal-btn--ghost {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.35);
  background: rgba(255, 255, 255, 0.08);
}

.legal-btn--ghost:hover,
.legal-btn--ghost:focus-visible {
  background: rgba(255, 255, 255, 0.16);
}

.legal-title-wrap {
  position: relative;
  z-index: 2;
  max-width: 850px;
}

.legal-kicker {
  display: inline-flex;
  margin: 0 0 12px;
  padding: 6px 12px;
  border-radius: 999px;
  color: #fff6dc;
  background: rgba(200, 155, 60, 0.22);
  border: 1px solid rgba(255, 255, 255, 0.16);
  font-weight: 760;
  font-size: 0.9rem;
}

.legal-title-wrap h1 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 4rem);
  line-height: 1.04;
  letter-spacing: -0.045em;
}

.legal-lead {
  max-width: 760px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(1rem, 2vw, 1.18rem);
}

/* Main content */
.legal-main {
  padding: 34px 0 54px;
}

.legal-card {
  background: rgba(255, 250, 241, 0.92);
  border: 1px solid var(--legal-border);
  border-radius: var(--legal-radius-lg);
  box-shadow: var(--legal-shadow);
  overflow: hidden;
}

.legal-card__inner {
  padding: clamp(22px, 4vw, 44px);
}

.legal-updated {
  display: inline-flex;
  margin: 0 0 22px;
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--legal-brand);
  background: var(--legal-accent-soft);
  font-weight: 760;
  font-size: 0.92rem;
}

.legal-section {
  padding: 22px 0;
  border-top: 1px solid var(--legal-border);
}

.legal-section:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.legal-section h2 {
  margin: 0 0 12px;
  color: var(--legal-brand);
  font-size: clamp(1.35rem, 2.4vw, 1.85rem);
  line-height: 1.18;
  letter-spacing: -0.02em;
}

.legal-section h3 {
  margin: 18px 0 8px;
  color: var(--legal-ink);
  font-size: 1.08rem;
  line-height: 1.25;
}

.legal-section p {
  margin: 0 0 12px;
}

.legal-section p:last-child {
  margin-bottom: 0;
}

.legal-list {
  margin: 12px 0 0;
  padding-left: 1.25rem;
}

.legal-list li {
  margin: 7px 0;
}

.legal-note {
  margin: 18px 0 0;
  padding: 16px 18px;
  border-radius: var(--legal-radius-md);
  background: #fff;
  border: 1px solid var(--legal-border);
  box-shadow: 0 8px 22px rgba(31, 42, 36, 0.06);
}

.legal-note strong {
  color: var(--legal-brand);
}

.legal-contact-box {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  padding: 18px;
  border-radius: var(--legal-radius-md);
  background:
    linear-gradient(135deg, rgba(24, 61, 47, 0.07), rgba(200, 155, 60, 0.12)),
    #fff;
  border: 1px solid var(--legal-border);
}

.legal-contact-box p {
  margin: 0;
}

.legal-todo {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  color: #6f3d00;
  background: rgba(255, 170, 0, 0.18);
  font-weight: 800;
}

/* Footer */
.site-footer {
  color: rgba(255, 255, 255, 0.86);
  background: var(--legal-brand);
  border-top: 5px solid var(--legal-accent);
}

.site-footer__inner {
  width: min(var(--legal-container), calc(100% - 32px));
  margin: 0 auto;
  padding: 26px 0;
  display: grid;
  gap: 14px;
}

.site-footer__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.site-footer__brand {
  margin: 0;
  color: #fff;
  font-weight: 850;
  font-size: 1.05rem;
}

.site-footer__links {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.site-footer__links a {
  color: rgba(255, 255, 255, 0.88);
  text-decoration: none;
  font-weight: 720;
}

.site-footer__links a:hover,
.site-footer__links a:focus-visible {
  color: #fff;
  text-decoration: underline;
}

.site-footer__copy {
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.92rem;
}

/* Mobile */
@media (max-width: 720px) {
  .legal-shell,
  .site-footer__inner {
    width: min(100% - 22px, var(--legal-container));
  }

  .legal-hero {
    padding-top: 22px;
  }

  .legal-nav,
  .site-footer__top {
    align-items: stretch;
  }

  .legal-actions,
  .site-footer__links {
    width: 100%;
  }

  .legal-btn,
  .site-footer__links a {
    flex: 1 1 auto;
  }

  .legal-card {
    border-radius: 20px;
  }

  .legal-card__inner {
    padding: 20px;
  }
}

@media print {
  .legal-hero,
  .site-footer {
    background: #fff !important;
    color: #000 !important;
    box-shadow: none !important;
  }

  .legal-actions {
    display: none;
  }

  .legal-card {
    box-shadow: none;
  }
}
