/* ============================================================
   LEGAL.CSS — GuideON
   Pages légales (CGU/CGV, politique de confidentialité, mentions
   légales) : même esprit visuel que la page d'accueil (welcome.css)
   et la boutique (boutique.css) — palette bleu/cyan/vert, hero avec
   .text-gradient, cartes « glass » à bordure/ombre douce, dégradé
   sombre en arrière-plan.

   Remplace conditions_utilisation.css et politique_confidentialite.css
   (classes HTML inchangées dans les 3 vues, uniquement la couleur,
   la typographie et les espacements sont unifiés ici).
   ============================================================ */

:root {
    --legal-bg: #0f111a;
    --legal-primary: #00d2ff;
    --legal-secondary: #3a7bd5;
    --legal-accent: #4ade80;
    --legal-link: #7fe3ff;
    --legal-text: #ffffff;
    --legal-text-muted: #a0aec0;
    --legal-text-dim: #64748b;
    --legal-border: rgba(255, 255, 255, 0.08);
    --legal-glass: rgba(255, 255, 255, 0.03);
    --legal-radius: 28px;
    --legal-transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    background-color: var(--legal-bg) !important;
    color: var(--legal-text) !important;
    margin: 0;
}

.privacy-wrapper {
    position: relative;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

/* --- Halo global, même esprit que body::before de welcome.css --- */
.privacy-wrapper::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    background: radial-gradient(
        ellipse 1200px 800px at 50% 0%,
        rgba(0, 210, 255, 0.14) 0%,
        rgba(0, 210, 255, 0.06) 35%,
        rgba(15, 17, 26, 0) 75%
    );
}

/* --- Orbes décoratifs --- */
.orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(120px);
    pointer-events: none;
    z-index: 0;
    opacity: 0.16;
}

.orb-1 {
    top: -10%;
    right: -5%;
    width: 600px;
    height: 600px;
    background: var(--legal-secondary);
    animation: legal-orb-float 20s ease-in-out infinite alternate;
}

.orb-2 {
    bottom: 5%;
    left: -10%;
    width: 500px;
    height: 500px;
    background: var(--legal-accent);
    animation: legal-orb-float 25s ease-in-out infinite alternate-reverse;
}

@keyframes legal-orb-float {
    from { transform: translate(0, 0) scale(1); }
    to { transform: translate(40px, -60px) scale(1.1); }
}

.grid-pattern {
    position: fixed;
    inset: 0;
    background-image: radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 50px 50px;
    mask-image: radial-gradient(circle at 50% 0%, black, transparent 85%);
    z-index: 1;
}

/* --- Mise en page générale --- */
main.page-offset {
    flex: 1;
    position: relative;
    z-index: 10;
    max-width: 960px;
    margin: 0 auto;
    width: 90%;
    padding-top: clamp(100px, 15vh, 160px);
    padding-bottom: 100px;
}

/* --- En-tête / hero --- */
.privacy-header {
    text-align: center;
    margin-bottom: 70px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(0, 210, 255, 0.1);
    color: var(--legal-link);
    border: 1px solid rgba(0, 210, 255, 0.25);
    padding: 8px 20px;
    border-radius: 100px;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.eyebrow::before {
    content: '';
    width: 8px;
    height: 8px;
    background: var(--legal-accent);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--legal-accent);
    animation: legal-pulse-dot 2s infinite;
}

@keyframes legal-pulse-dot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.8); }
}

.privacy-header h1 {
    font-size: clamp(2.2rem, 7vw, 4.2rem);
    font-weight: 900;
    margin: 25px 0;
    letter-spacing: -2px;
    line-height: 1.1;
    overflow-wrap: break-word;
}

/* Même dégradé que le titre de l'accueil (welcome.css) et de la
   boutique (boutique.css), repris ici pour les titres des pages
   légales et réutilisable dans le texte des sections. */
.privacy-header h1 span,
.text-gradient {
    background: linear-gradient(
        90deg,
        var(--legal-primary),
        var(--legal-secondary),
        var(--legal-accent),
        var(--legal-primary)
    );
    background-size: 300% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: legal-flow-colors 5s linear infinite;
}

@keyframes legal-flow-colors {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.privacy-header p {
    color: var(--legal-text-muted);
    max-width: 560px;
    margin: 0 auto;
    font-size: 1.1rem;
    font-weight: 400;
    line-height: 1.7;
}

/* --- Carte de contenu « glass » --- */
.privacy-content.glass {
    background: rgba(15, 17, 26, 0.6);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--legal-border);
    border-radius: var(--legal-radius);
    padding: clamp(2rem, 5vw, 4rem);
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.4);
    position: relative;
}

.privacy-content.glass::before {
    content: '';
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--legal-primary), var(--legal-accent), transparent);
}

.last-updated {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--legal-link);
    background: rgba(0, 210, 255, 0.08);
    padding: 10px 18px;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 35px;
}

.intro-text p {
    color: var(--legal-text-muted);
    line-height: 1.8;
    margin: 0 0 40px;
}

/* --- Sections --- */
.legal-section {
    margin-top: 50px;
    border-top: 1px solid var(--legal-border);
    padding-top: 40px;
}

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

.legal-section h2 {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
}

.legal-section h2 i {
    flex-shrink: 0;
    color: var(--legal-link);
    background: rgba(0, 210, 255, 0.1);
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    font-size: 1.2rem;
    transition: var(--legal-transition);
}

.legal-section:hover h2 i {
    transform: rotate(-10deg) scale(1.08);
    background: rgba(0, 210, 255, 0.2);
}

.legal-section p {
    color: var(--legal-text-muted);
    line-height: 1.8;
    font-weight: 400;
}

.legal-section p + p {
    margin-top: 14px;
}

.legal-section a {
    color: var(--legal-link);
    text-decoration: underline;
    text-decoration-color: rgba(127, 227, 255, 0.4);
}

.legal-section a:hover {
    text-decoration-color: var(--legal-link);
}

.sub-section {
    margin-top: 28px;
}

.sub-section:first-child {
    margin-top: 0;
}

.sub-section h3 {
    color: #e2e8f0;
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0 0 12px;
}

/* --- Listes --- */
.styled-list {
    list-style: none;
    padding: 0;
    margin-top: 20px;
}

.styled-list li {
    position: relative;
    padding: 12px 15px 12px 40px;
    color: var(--legal-text-muted);
    line-height: 1.6;
    border-radius: 12px;
    transition: 0.3s;
}

.styled-list li::before {
    content: '→';
    position: absolute;
    left: 15px;
    color: var(--legal-accent);
    font-weight: 800;
}

.styled-list li:hover {
    background: rgba(255, 255, 255, 0.02);
    color: #fff;
    transform: translateX(8px);
}

/* --- Encart d'information --- */
.alert-box {
    background: linear-gradient(90deg, rgba(0, 210, 255, 0.1), transparent);
    border-left: 4px solid var(--legal-primary);
    padding: 25px;
    border-radius: 16px;
    display: flex;
    gap: 20px;
    margin: 30px 0;
    align-items: flex-start;
}

.alert-box i {
    flex-shrink: 0;
    margin-top: 2px;
    font-size: 1.4rem;
    color: var(--legal-primary);
}

.alert-box span {
    color: var(--legal-text-muted);
    line-height: 1.7;
}

.alert-box strong {
    color: #fff;
}

/* --- Bouton vers l'espace compte --- */
.btn-account-link {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin-top: 20px;
    background: linear-gradient(90deg, #3b82f6, #2dd4bf);
    padding: 14px 28px;
    border-radius: 14px;
    text-decoration: none;
    color: #fff !important;
    font-weight: 700;
    box-shadow: 0 10px 25px rgba(59, 130, 246, 0.3);
    transition: var(--legal-transition);
}

.btn-account-link:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(59, 130, 246, 0.45);
    filter: brightness(1.08);
}

/* --- Carte de contact --- */
.contact-card {
    margin-top: 60px;
    padding: 40px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 24px;
    border: 1px solid var(--legal-border);
}

.contact-header h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.3rem;
    font-weight: 800;
    margin: 0 0 8px;
}

.contact-header h3 i {
    color: var(--legal-primary);
}

.contact-header p {
    color: var(--legal-text-muted);
    margin: 0;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-top: 30px;
}

.contact-item {
    background: rgba(0, 0, 0, 0.3);
    padding: 20px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    gap: 15px;
    text-decoration: none;
    border: 1px solid transparent;
    transition: 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.contact-item:hover {
    background: var(--legal-glass);
    border-color: var(--legal-primary);
    transform: translateY(-5px);
}

.contact-item i {
    font-size: 1.5rem;
    color: var(--legal-primary);
}

.contact-item span {
    display: block;
    color: #fff;
    font-weight: 700;
}

.contact-item small,
.contact-item div small {
    color: var(--legal-text-dim);
}

/* --- Animation de révélation au scroll --- */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }

    .orb,
    .eyebrow::before,
    .text-gradient,
    .privacy-header h1 span {
        animation: none;
    }
}

/* ============================================================
   RESPONSIVE MOBILE — pages légales
   Ces pages sont longues à lire : on garde un texte confortable
   et on évite tout débordement horizontal.
   ============================================================ */
@media (max-width: 768px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .privacy-content.glass {
        padding: 28px 22px;
        border-radius: 22px;
    }

    .privacy-header h1 {
        font-size: 2.4rem;
    }
}

@media (max-width: 600px) {
    main.page-offset {
        width: 94%;
        padding-top: clamp(90px, 12vh, 120px);
    }

    .privacy-header {
        margin-bottom: 44px;
    }

    .privacy-header p {
        font-size: 1rem;
    }

    .legal-section {
        margin-top: 36px;
        padding-top: 28px;
    }

    .legal-section h2 {
        font-size: 1.2rem;
        gap: 12px;
    }

    .legal-section h2 i {
        width: 38px;
        height: 38px;
        font-size: 1.05rem;
    }

    .legal-section p,
    .styled-list li,
    .alert-box span {
        font-size: 0.95rem;
        line-height: 1.7;
    }

    .sub-section h3 {
        font-size: 1rem;
    }

    .contact-card {
        padding: 28px 20px;
    }

    .btn-account-link {
        width: 100%;
        justify-content: center;
        text-align: center;
    }
}

@media (max-width: 360px) {
    .privacy-content.glass {
        padding: 22px 16px;
    }

    .legal-section h2 {
        font-size: 1.1rem;
    }

    .privacy-header h1 {
        letter-spacing: -1px;
    }
}
