/* Import du CSS de base */
@import url('index.css');
@import url('global.css');

/* Styles spécifiques aux pages légales */
.hero {
    padding: 120px 0 60px;
    background: var(--gradient-primary);
    color: white;
    text-align: center;
}

.hero-content h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.hero-content p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 700px;
    margin: 0 auto 2rem;
    line-height: 1.7;
}

.last-update {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.1);
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    font-size: 0.95rem;
    opacity: 0.9;
}

.last-update i {
    font-size: 1rem;
}

/* Navigation rapide */
.quick-nav {
    padding: 2rem 0;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
}

.nav-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.nav-link-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 25px;
    text-decoration: none;
    color: var(--text-primary);
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-link-item:hover {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.nav-link-item i {
    font-size: 1rem;
}

/* Contenu principal */
.main-content {
    padding: 3rem 0;
    background: var(--bg-primary);
}

.content-wrapper {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 3rem;
    align-items: start;
}

/* Sidebar avec sommaire */
.sidebar {
    position: sticky;
    top: 2rem;
}

.toc {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
}

.toc h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 0.5rem;
}

.toc ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.toc li {
    margin-bottom: 0.75rem;
}

.toc a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
    line-height: 1.5;
    transition: color 0.3s ease;
    display: block;
    padding: 0.25rem 0;
}

.toc a:hover {
    color: var(--primary-color);
}

/* Articles */
.articles {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

.legal-article {
    background: white;
    padding: 2.5rem;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
    scroll-margin-top: 2rem;
}

.legal-article h2 {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--primary-color);
}

.legal-article h3 {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 2rem 0 1rem;
}

.legal-article h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 1.5rem 0 0.75rem;
}

.article-content p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1rem;
}

.article-content ul,
.article-content ol {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 1rem;
    padding-left: 1.5rem;
}

.article-content li {
    margin-bottom: 0.5rem;
}

.article-content strong {
    color: var(--text-primary);
    font-weight: 600;
}

.article-content a {
    color: var(--primary-color);
    text-decoration: underline;
}

.article-content a:hover {
    color: var(--secondary-color);
}

/* Boîtes d'information */
.info-box {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-left: 4px solid var(--primary-color);
    padding: 1.5rem;
    border-radius: 8px;
    margin: 1.5rem 0;
}

.info-box ul {
    margin: 0;
}

/* Base légale */
.legal-basis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.basis-item {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    text-align: center;
}

.basis-item h4 {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.75rem;
}

.basis-item i {
    font-size: 1.2rem;
}

.basis-item p {
    font-size: 0.9rem;
    margin: 0;
}

/* Tableau de conservation */
.retention-table {
    overflow-x: auto;
    margin: 2rem 0;
}

.retention-table table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
}

.retention-table th,
.retention-table td {
    padding: 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.retention-table th {
    background: var(--primary-color);
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
}

.retention-table td {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.retention-table tr:last-child td {
    border-bottom: none;
}

/* Types de cookies */
.cookies-types {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin: 2rem 0;
}

.cookie-type {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    position: relative;
}

.cookie-type h4 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.75rem;
}

.cookie-type i {
    font-size: 1.2rem;
}

.cookie-type p {
    margin-bottom: 0.5rem;
}

.cookie-duration {
    display: inline-block;
    background: var(--primary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.cookie-settings {
    text-align: center;
    margin: 2rem 0;
}

/* Grille des droits */
.rights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin: 2rem 0;
}

.right-item {
    background: var(--bg-secondary);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    text-align: center;
}

.right-item h4 {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 0.75rem;
}

.right-item i {
    font-size: 1.2rem;
}

.right-item p {
    font-size: 0.9rem;
    margin: 0;
}

/* Informations de contact */
.contact-info {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 1.5rem 0;
}

.contact-method {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
    background: var(--bg-secondary);
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.contact-method i {
    color: var(--primary-color);
    font-size: 1.2rem;
    margin-top: 0.25rem;
    flex-shrink: 0;
}

.contact-method div {
    flex: 1;
}

.contact-method strong {
    display: block;
    margin-bottom: 0.25rem;
}

.contact-method a {
    color: var(--primary-color);
    text-decoration: none;
}

.contact-method a:hover {
    text-decoration: underline;
}

/* CTA Section */
.cta {
    padding: 80px 0;
    background: var(--gradient-primary);
    color: white;
}

.cta-content {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.cta h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.cta p {
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    opacity: 0.9;
    line-height: 1.7;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.cta .btn-outline {
    border-color: white;
    color: white;
}

.cta .btn-outline:hover {
    background: white;
    color: var(--primary-color);
}

/* Responsive Design */
@media (max-width: 1024px) {
    .content-wrapper {
        grid-template-columns: 200px 1fr;
        gap: 2rem;
    }

    .toc {
        padding: 1.5rem;
    }

    .legal-article {
        padding: 2rem;
    }
}

@media (max-width: 768px) {
    .hero-content h1 {
        font-size: 2.5rem;
    }

    .nav-links {
        gap: 0.5rem;
    }

    .nav-link-item {
        padding: 0.5rem 1rem;
        font-size: 0.8rem;
    }

    .content-wrapper {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .sidebar {
        order: 2;
        position: static;
    }

    .toc {
        padding: 1.5rem;
    }

    .legal-article {
        padding: 1.5rem;
    }

    .legal-article h2 {
        font-size: 1.5rem;
    }

    .legal-basis {
        grid-template-columns: 1fr;
    }

    .rights-grid {
        grid-template-columns: 1fr;
    }

    .retention-table {
        font-size: 0.8rem;
    }

    .retention-table th,
    .retention-table td {
        padding: 0.75rem 0.5rem;
    }

    .cta h2 {
        font-size: 2rem;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 100px 0 40px;
    }

    .hero-content h1 {
        font-size: 2rem;
    }

    .nav-link-item {
        padding: 0.5rem 0.75rem;
        font-size: 0.75rem;
    }

    .nav-link-item span {
        display: none;
    }

    .legal-article {
        padding: 1rem;
    }

    .legal-article h2 {
        font-size: 1.3rem;
    }

    .legal-article h3 {
        font-size: 1.1rem;
    }

    .toc {
        padding: 1rem;
    }

    .basis-item,
    .right-item,
    .cookie-type {
        padding: 1rem;
    }

    .contact-method {
        flex-direction: column;
        text-align: center;
    }
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.legal-article {
    animation: fadeInUp 0.6s ease forwards;
}

.legal-article:nth-child(1) { animation-delay: 0.1s; }
.legal-article:nth-child(2) { animation-delay: 0.2s; }
.legal-article:nth-child(3) { animation-delay: 0.3s; }
.legal-article:nth-child(4) { animation-delay: 0.4s; }
.legal-article:nth-child(5) { animation-delay: 0.5s; }

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Focus pour l'accessibilité */
.nav-link-item:focus,
.toc a:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .header,
    .quick-nav,
    .cta,
    .footer {
        display: none;
    }

    .content-wrapper {
        grid-template-columns: 1fr;
    }

    .sidebar {
        display: none;
    }

    .legal-article {
        box-shadow: none;
        border: 1px solid #ddd;
        page-break-inside: avoid;
        margin-bottom: 2rem;
    }
}

