/**
 * Legal CSS — Stage Découverte
 * Styles partagés pour les pages légales, contact et charte
 */

/* ========= BASE ========= */
body {
    /*font-family: 'Outfit', 'Poppins', system-ui, sans-serif;*/
    background: #F5F0E6;
    color: #1C2826;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* ========= POLICY PAGES (CGU, confidentialité, mentions) ========= */

.policy-wrapper {
    padding: 3rem 1rem 4rem;
}

.policy-card {
    background: #FBF8F2;
    border-radius: 24px;
    box-shadow: 0 2px 4px rgba(28,40,38,0.06), 0 20px 60px rgba(28,40,38,0.1);
    border: 1px solid rgba(28,40,38,0.06);
    padding: 3rem;
    max-width: 860px;
    margin: 0 auto;
}

.policy-brand {
    text-align: center;
    margin-bottom: 2.5rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid rgba(28,40,38,0.1);
}

.policy-brand a {
    text-decoration: none;
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-size: 1.5rem;
    font-weight: 400;
    color: #0F3B36;
    letter-spacing: -0.01em;
}

.policy-brand .update-badge {
    display: inline-block;
    margin-top: 0.75rem;
    background: rgba(15,59,54,0.08);
    color: #0F3B36;
    font-size: 0.8rem;
    font-weight: 500;
    padding: 0.25rem 0.85rem;
    border-radius: 50px;
}

h1 {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-size: 2rem;
    font-weight: 400;
    color: #1C2826;
    margin-bottom: 0.4rem;
    letter-spacing: -0.02em;
}

.policy-intro {
    color: #3A4845;
    font-size: 0.95rem;
    margin-bottom: 2rem;
    line-height: 1.7;
}

/* Table des matières */
.toc {
    background: rgba(15,59,54,0.05);
    border-left: 4px solid #0F3B36;
    border-radius: 0 14px 14px 0;
    padding: 1.5rem 1.75rem;
    margin-bottom: 2.5rem;
}

.toc h2 {
    /*font-family: 'Outfit', sans-serif;*/
    font-size: 0.85rem;
    font-weight: 600;
    color: #0F3B36;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.toc ol {
    margin: 0;
    padding-left: 1.25rem;
}

.toc li {
    font-size: 0.88rem;
    color: #3A4845;
    margin-bottom: 0.3rem;
}

.toc a {
    color: #3A4845;
    text-decoration: none;
    transition: color 0.2s;
}

.toc a:hover {
    color: #0F3B36;
}

/* Sections */
.policy-section {
    margin-bottom: 2.75rem;
    scroll-margin-top: 80px;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.1rem;
    padding-bottom: 0.6rem;
    border-bottom: 1px solid rgba(28,40,38,0.08);
}

.section-number {
    background: #0F3B36;
    color: #F5F0E6;
    font-size: 0.8rem;
    font-weight: 700;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-family: 'Outfit', sans-serif;
}

h2.section-title {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-size: 1.2rem;
    font-weight: 400;
    color: #1C2826;
    margin: 0;
    letter-spacing: -0.015em;
}

h3.sub-title {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-size: 1.05rem;
    font-weight: 400;
    color: #1C2826;
    margin: 1.5rem 0 0.6rem;
    letter-spacing: -0.01em;
}

p, li {
    font-size: 0.93rem;
    color: #3A4845;
    line-height: 1.75;
}

ul, ol {
    padding-left: 1.4rem;
}

li {
    margin-bottom: 0.35rem;
}

a {
    color: #0F3B36;
}

a:hover {
    color: #1B6258;
}

/* Boîtes highlight */
.highlight-box {
    background: rgba(217,120,66,0.08);
    border-left: 4px solid #D97842;
    border-radius: 0 12px 12px 0;
    padding: 1rem 1.25rem;
    margin: 1.25rem 0;
    font-size: 0.9rem;
    color: #3A4845;
}

.highlight-box.info {
    background: rgba(15,59,54,0.06);
    border-left-color: #0F3B36;
    color: #1C2826;
}

/* Contact card (dans les légaux) */
.contact-info {
    background: rgba(15,59,54,0.06);
    border-radius: 14px;
    padding: 1.25rem 1.5rem;
    margin: 1rem 0;
}

.contact-info p {
    margin: 0;
    font-size: 0.9rem;
    color: #1C2826;
}

.contact-info p + p {
    margin-top: 0.3rem;
}

/* Definitions */
.def-item {
    border-bottom: 1px solid rgba(28,40,38,0.08);
    padding: 0.75rem 0;
}

.def-item:last-child {
    border-bottom: none;
}

.def-term {
    font-weight: 600;
    color: #1C2826;
    font-size: 0.93rem;
}

.def-desc {
    color: #3A4845;
    font-size: 0.9rem;
    margin: 0.2rem 0 0;
}

/* Lien retour */
.back-link {
    text-align: center;
    margin-top: 2.5rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(28,40,38,0.08);
}

.back-link a {
    color: #0F3B36;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 500;
}

.back-link a:hover {
    color: #1B6258;
    text-decoration: underline;
}

.legal-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.25rem;
    margin-top: 0.75rem;
}

.legal-links a {
    color: #3A4845;
    font-size: 0.85rem;
    text-decoration: none;
    transition: color 0.2s;
}

.legal-links a:hover { color: #0F3B36; }

.legal-links span { color: rgba(28,40,38,0.2); }

@media (max-width: 600px) {
    .policy-card { padding: 2rem 1.25rem; }
}

/* ========= POLITIQUE DE CONFIDENTIALITÉ extras ========= */

.badge-todo {
    display: inline-block;
    background: rgba(217,120,66,0.1);
    color: #D97842;
    border: 1px solid rgba(217,120,66,0.3);
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.15rem 0.6rem;
    border-radius: 6px;
    font-family: monospace;
}

.rights-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin: 1.25rem 0;
}

.right-item {
    background: rgba(15,59,54,0.05);
    border-radius: 12px;
    padding: 1rem 1.25rem;
    border: 1px solid rgba(15,59,54,0.08);
}

.right-icon {
    font-size: 1.2rem;
    color: #0F3B36;
    margin-bottom: 0.5rem;
}

.right-title {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-size: 1rem;
    font-weight: 400;
    color: #1C2826;
    margin-bottom: 0.25rem;
    letter-spacing: -0.01em;
}

.right-desc {
    font-size: 0.82rem;
    color: #3A4845;
    margin: 0;
}

@media (max-width: 600px) {
    .rights-grid { grid-template-columns: 1fr; }
}

/* ========= CONTACT PAGE ========= */

body.contact-page {
    display: flex;
    flex-direction: column;
}

.contact-wrapper {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
}

.contact-card {
    background: #FBF8F2;
    border-radius: 24px;
    box-shadow: 0 2px 4px rgba(28,40,38,0.06), 0 20px 60px rgba(28,40,38,0.1);
    border: 1px solid rgba(28,40,38,0.06);
    padding: 3rem 2.5rem;
    width: 100%;
    max-width: 560px;
}

.contact-brand {
    text-align: center;
    margin-bottom: 2rem;
}

.contact-brand a {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-weight: 400;
    font-size: 1.5rem;
    color: #0F3B36;
    text-decoration: none;
    letter-spacing: -0.01em;
}

.contact-brand p {
    color: #3A4845;
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

.contact-card h4 {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-weight: 400;
    text-align: center;
    margin-bottom: 0.5rem;
    letter-spacing: -0.015em;
    color: #1C2826;
    font-size: 1.4rem;
}

.contact-card .subtitle {
    text-align: center;
    color: #3A4845;
    font-size: 0.9rem;
    margin-bottom: 2rem;
}

.contact-info-box {
    background: rgba(15,59,54,0.06);
    border-radius: 14px;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
}

.contact-info-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.contact-info-item:last-child {
    margin-bottom: 0;
}

.contact-info-item i {
    font-size: 1.2rem;
    color: #0F3B36;
    width: 24px;
    text-align: center;
}

.contact-info-item span {
    color: #3A4845;
    font-size: 0.9rem;
}

.btn-primary-custom {
    background: #0F3B36;
    border: none;
    border-radius: 999px;
    padding: 0.85rem;
    font-weight: 500;
    font-size: 1rem;
    color: #F5F0E6;
    width: 100%;
    transition: background 0.2s, transform 0.2s;
    /*font-family: 'Outfit', sans-serif;*/
}

.btn-primary-custom:hover {
    background: #0A2825;
    transform: translateY(-1px);
    color: #F5F0E6;
}

.btn-primary-custom:disabled {
    opacity: 0.6;
    transform: none;
}

.footer-links {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(28,40,38,0.08);
}

.footer-links a {
    color: #3A4845;
    text-decoration: none;
    font-size: 0.85rem;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #0F3B36;
}

.recaptcha-notice {
    font-size: 0.75rem;
    color: #3A4845;
    opacity: 0.6;
    text-align: center;
    margin-top: 1rem;
}

.recaptcha-notice a {
    color: #0F3B36;
}

/* Carte utilisateur connecté */
.user-info-card {
    background: rgba(15,59,54,0.06);
    border-radius: 14px;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(15,59,54,0.12);
}

.user-info-card .user-badge {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.user-info-card .user-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0F3B36, #1B6258);
    color: #F5F0E6;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    font-size: 1rem;
}

.user-info-card .user-details {
    flex: 1;
}

.user-info-card .user-name {
    font-weight: 600;
    color: #1C2826;
    font-size: 0.95rem;
}

.user-info-card .user-email {
    color: #3A4845;
    font-size: 0.8rem;
}

.user-info-card .user-type {
    display: inline-block;
    background: #0F3B36;
    color: #F5F0E6;
    font-size: 0.7rem;
    padding: 0.15rem 0.5rem;
    border-radius: 10px;
    margin-top: 0.25rem;
}

.user-info-card .user-type.child {
    background: #1B6258;
}

.logged-in-notice {
    font-size: 0.8rem;
    color: #3A4845;
    text-align: center;
    margin-top: 0.75rem;
    padding-top: 0.75rem;
    border-top: 1px solid rgba(28,40,38,0.08);
}

.logged-in-notice i {
    color: #1B6258;
}

/* ========= CHARTE MINEURS (legal-navbar layout) ========= */

body.legal-page {
    display: flex;
    flex-direction: column;
    background: #F5F0E6;
}

.legal-navbar {
    background: #0A2825;
}

.legal-navbar .navbar-brand {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-weight: 400;
    color: #F5F0E6;
    font-size: 1.2rem;
    letter-spacing: -0.01em;
}

.legal-navbar .navbar-brand:hover {
    color: #F5F0E6;
}

.legal-navbar .nav-link {
    color: rgba(245,240,230,0.7);
    font-size: 0.88rem;
    font-weight: 500;
    transition: color 0.2s;
}

.legal-navbar .nav-link:hover,
.legal-navbar .nav-link.active {
    color: #F5F0E6;
}

.legal-navbar .navbar-toggler-icon {
    filter: invert(1);
}

.legal-content {
    flex: 1;
}

.legal-card {
    background: #FBF8F2;
    border-radius: 18px;
    padding: 2.5rem;
    box-shadow: 0 1px 2px rgba(28,40,38,0.04), 0 8px 24px rgba(28,40,38,0.06);
    border: 1px solid rgba(28,40,38,0.06);
}

.legal-card h1 {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-weight: 400;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    color: #1C2826;
    letter-spacing: -0.02em;
}

.legal-card h2 {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-weight: 400;
    font-size: 1.2rem;
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    color: #1C2826;
    letter-spacing: -0.015em;
}

.legal-card h3 {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-weight: 400;
    font-size: 1.05rem;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
    color: #3A4845;
}

.legal-card p,
.legal-card li {
    font-size: 0.92rem;
    color: #3A4845;
    line-height: 1.7;
}

.legal-loading {
    text-align: center;
    padding: 3rem 0;
}

.legal-footer {
    background: #0A2825;
    color: rgba(245,240,230,0.65);
    padding: 2rem 0;
    margin-top: 3rem;
}

.legal-footer a {
    color: rgba(245,240,230,0.7);
    text-decoration: none;
    font-size: 0.85rem;
    transition: color 0.2s;
}

.legal-footer a:hover {
    color: #F5F0E6;
}

.legal-footer .footer-brand {
    /*font-family: 'Instrument Serif', Georgia, serif;*/
    font-weight: 400;
    color: #F5F0E6;
    font-size: 1.1rem;
    letter-spacing: -0.01em;
}
