/* ============================
   Conteneur principal
============================= */
.legal-page-container {
  width: 100%;
  max-width: 1063px;
  margin: 0px auto;
  box-sizing: border-box;
  background-color: var(--bg-color);
  border-radius: 20px;
  max-height: 466px;
  position: relative;
  top: 50px;
}
/* ============================
   Section Titre + Logo
============================= */

.legal-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.legal-logo {
  max-width: 82px;
  height: auto;
  position: relative;
  left: 15px;
}

.legal-title {
  font-size: 1.8rem;
  font-weight: bold;
  color: #f29c38; /* Orange */
  margin-top: 12px;
}

/* ============================
   Grille des blocs (2 par ligne)
============================= */
.legal-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-auto-rows: 1fr;
  gap: 5px;
  justify-content: center;
  align-items: stretch;
}

.legal-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 73%;
  background-color: var(--bg-color);
  padding: 15px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  border: 1px solid #f29c38; /* Orange */
  text-align: center;
}

/* ============================
   Titres et textes
============================= */
.legal-card h2 {
  font-size: 1.4rem;
  color: var(--text-color);
}

.legal-card p {
  font-size: 1rem;
  color: var(--text-color);;
  line-height: 1.5;
}

/* ============================
   Liens
============================= */
.legal-card a {
  color: #f29c38;
  text-decoration: none;
  font-weight: bold;
}

.legal-card a:hover {
  text-decoration: underline;
}

/* ============================
   Responsive Tablette
============================= */
@media (min-width: 769px) and (max-width: 992px) {
  .legal-page-container {
    width: 94%;
    max-width: 746px;
    box-sizing: border-box;
    background-color: var(--bg-color);
    border-radius: 20px;
    max-height: 512px;
    position: relative;
    top: 27px;
  }

  .legal-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
  }

  .legal-card h2 {
    font-size: 1rem;
  }

  .legal-card p {
    font-size: 0.8rem;
  }

  .legal-logo {
    max-width: 65px;
    left: 15px;
  }

  .legal-title {
    font-size: 1rem;
    font-weight: bold;
    color: #f29c38;
  }

  .legal-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: auto;
    gap: 3px;
  }

  .legal-card:nth-child(1),
  .legal-card:nth-child(2) {
    grid-column: auto;
  }

  .legal-card:nth-child(n+3) {
    grid-column: span 2;
  }
  .legal-card:nth-child(1),
.legal-card:nth-child(2) {
  font-size: 0.85rem;
}
.legal-card:nth-child(1) h2,
.legal-card:nth-child(2) h2 {
  font-size: 1rem;
}
.legal-card:nth-child(4) {
  margin-top: 8px;
}
}

/* ============================
   Responsive Mobile (1 bloc par ligne)
============================= */
@media (max-width: 768px) {
  .legal-page-container {
    width: 84%;
    max-width: 446px;
    box-sizing: border-box;
    background-color: var(--bg-color);
    border-radius: 20px;
    max-height: 512px;
    position: relative;
    top: 27px;
  }

  .legal-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
  }

  .legal-card h2 {
    font-size: 0.9rem;
  }

  .legal-card p {
    font-size: 0.8rem;
  }

  .legal-logo {
    max-width: 65px;
    left: 15px;
  }

  .legal-title {
    font-size: 1rem;
    font-weight: bold;
    color: #f29c38;
  }

  .legal-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: auto;
    gap: 3px;
  }

  .legal-card:nth-child(1),
  .legal-card:nth-child(2) {
    grid-column: auto;
  }

  .legal-card:nth-child(n+3) {
    grid-column: span 2;
  }
  .legal-card:nth-child(1),
.legal-card:nth-child(2) {
  font-size: 0.85rem;
}
.legal-card:nth-child(1) h2,
.legal-card:nth-child(2) h2 {
  font-size: 1rem;
}
.legal-card:nth-child(4) {
  margin-top: 8px;
}
}