/* =========================================
   NEXUS LÉGAL (Design High-Fidelity)
   ========================================= */

/* FOND : Force le passage au premier plan */
.legal-screen-container {
  position: fixed; /* Force le plein écran par dessus tout le reste */
  inset: 0;
  width: 100vw;
  height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-top: 60px;
  background: radial-gradient(circle at 50% 120%, #1a0f16 0%, #050505 60%, #000 100%);
  overflow-y: auto; /* Permet le scroll si l'écran est petit */
  z-index: 200; /* Z-Index très élevé pour éviter l'écran noir */
}

/* HEADER */
.legal-header {
  text-align: center;
  margin-bottom: 5vh;
  z-index: 10;
  flex-shrink: 0;
}
.legal-overline {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.4em;
  color: #fda4af;
  opacity: 0.9;
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  text-shadow: 0 0 15px rgba(253, 164, 175, 0.4);
}
.legal-header .system-title {
  font-size: 3.5rem;
  font-weight: 200;
  color: #fff;
  margin: 0;
  letter-spacing: -0.03em;
  background: linear-gradient(180deg, #fff 20%, #a5a5a5 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.legal-header .system-subtitle {
  color: rgba(255, 255, 255, 0.4);
  font-size: 1rem;
  margin-top: 1rem;
  font-weight: 300;
  letter-spacing: 0.05em;
}

/* GRILLE */
.legal-grid {
  display: flex;
  gap: 2rem;
  justify-content: center;
  align-items: stretch;
  width: 100%;
  max-width: 1100px;
  padding: 0 2rem;
  z-index: 10;
  flex-shrink: 0;
}

/* CARTE */
.legal-card {
  flex: 1;
  height: 320px;
  position: relative;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 24px;
  text-decoration: none;
  overflow: hidden;
  transition: all 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
  backdrop-filter: blur(12px);
}

.legal-card-content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.legal-card-glow {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: radial-gradient(circle at center, rgba(253, 164, 175, 0.15) 0%, transparent 60%);
  opacity: 0;
  transition: opacity 0.6s ease;
  z-index: 1;
}

/* ICONES */
.legal-icon-box {
  width: 64px;
  height: 64px;
  margin-bottom: 2.5rem;
  color: rgba(255, 255, 255, 0.6);
  transition: all 0.5s ease;
}
.legal-icon-box svg {
  width: 100%;
  height: 100%;
  transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* TEXTES */
.legal-info { text-align: center; }
.legal-info h3 {
  color: #fff;
  font-size: 1.25rem;
  font-weight: 500;
  margin: 0 0 0.5rem 0;
  letter-spacing: 0.02em;
}
.legal-info span {
  color: rgba(255, 255, 255, 0.3);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
  transition: color 0.3s ease;
}

/* HOVER */
.legal-card:hover {
  transform: translateY(-10px) scale(1.02);
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(253, 164, 175, 0.3);
  box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.6);
}
.legal-card:hover .legal-card-glow { opacity: 1; }
.legal-card:hover .legal-icon-box { color: #fda4af; }
.legal-card:hover .legal-icon-box svg {
  transform: scale(1.1);
  filter: drop-shadow(0 0 12px rgba(253, 164, 175, 0.6));
}
.legal-card:hover .legal-info span { color: rgba(253, 164, 175, 0.8); }

/* FOOTER */
#legal-footer-zone {
  margin-top: auto;
  width: 100%;
  padding-bottom: 30px;
  opacity: 0.5;
  transition: opacity 0.3s;
  flex-shrink: 0;
}
#legal-footer-zone:hover { opacity: 1; }

/* MOBILE */
@media (max-width: 900px) {
  .legal-grid {
    flex-direction: column;
    height: auto;
    margin-bottom: 40px;
  }
  .legal-card {
    width: 100%;
    height: 100px;
    flex: none; /* Important sur mobile pour ne pas écraser */
  }
  .legal-card-content {
    flex-direction: row;
    justify-content: flex-start;
    padding: 0 1.5rem;
    gap: 1.5rem;
  }
  .legal-icon-box {
    width: 32px;
    height: 32px;
    margin-bottom: 0;
  }
  .legal-info { text-align: left; }
}
