.text-black {
    color: black;
}

.text-white {
    color: white;
}

.text-blue {
    color: blue;
}

#loader {
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 9999;
}

/* --------  fonts -------------*/

.lato-thin {
    font-family: "Lato", sans-serif;
    font-weight: 100;
    font-style: normal;
}

.lato-light {
    font-family: "Lato", sans-serif;
    font-weight: 300;
    font-style: normal;
}

.lato-regular {
    font-family: "Lato", sans-serif;
    font-weight: 400;
    font-style: normal;
}

.lato-bold {
    font-family: "Lato", sans-serif;
    font-weight: 700;
    font-style: normal;
}

.lato-black {
    font-family: "Lato", sans-serif;
    font-weight: 900;
    font-style: normal;
}

.lato-thin-italic {
    font-family: "Lato", sans-serif;
    font-weight: 100;
    font-style: italic;
}

.lato-light-italic {
    font-family: "Lato", sans-serif;
    font-weight: 300;
    font-style: italic;
}

.lato-regular-italic {
    font-family: "Lato", sans-serif;
    font-weight: 400;
    font-style: italic;
}

.lato-bold-italic {
    font-family: "Lato", sans-serif;
    font-weight: 700;
    font-style: italic;
}

.lato-black-italic {
    font-family: "Lato", sans-serif;
    font-weight: 900;
    font-style: italic;
}

h1, h2, h3, h4, h5, h6, p, a, label {
    font-family: "Federo", sans-serif;
    font-weight: 400;
    font-style: normal;
}

.person-label {
    font-family: Arial, sans-serif;
    font-weight: 700;
}

.person-card-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    object-position: center;
}

.person-child-image {
    width: 100%;
    height: 150px;
    object-fit: cover;
    object-position: center;
}

.a-peronne-details {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.a-peronne-details:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
}


#personnes .card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

#personnes .card:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
}

.card-img {
    transition: all 0.3s ease;
    cursor: pointer;
}

.card-img:hover {
    transform: scale(1.05);
    z-index: 10;
}

.card-img a:hover,
#personnes a:hover {
    color: darkblue;
}

.section-title {
    padding-bottom: 5px;
}

.section-title h2 {
    font-size: 14px;
    font-weight: 500;
    padding: 0;
    line-height: 1px;
    margin: 0 0 5px 0;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #aaaaaa;
    font-family: "Poppins", sans-serif;
}

.section-title h2::after {
    content: "";
    width: 120px;
    height: 1px;
    display: inline-block;
    background: #1acc8d;
    margin: 4px 10px;
}

.section-title p {
    margin: 0;
    font-size: 36px;
    font-weight: 700;
    text-transform: uppercase;
    font-family: "Poppins", sans-serif;
    color: #010483;
}

strong p {
    font-weight: 700 !important;
}

/* =========================================================
   PAGE D'ACCUEIL GÉNÉALOGIE
========================================================= */

:root {
    --genealogy-primary: #527853;
    --genealogy-primary-dark: #304d30;
    --genealogy-secondary: #739072;
    --genealogy-light: #f3f7f2;
    --genealogy-cream: #f7f1e5;
    --genealogy-text: #263328;
}


/* Section principale */

.genealogy-hero {
    position: relative;
    overflow: hidden;
    background: radial-gradient(
            circle at top right,
            rgba(115, 144, 114, 0.25),
            transparent 40%
    ),
    linear-gradient(
            135deg,
            #f7f1e5 0%,
            #f3f7f2 50%,
            #ffffff 100%
    );
}

.genealogy-hero::before {
    position: absolute;
    top: -130px;
    left: -130px;
    width: 320px;
    height: 320px;
    content: "";
    border-radius: 50%;
    background: rgba(82, 120, 83, 0.08);
}

.min-vh-50 {
    min-height: 50vh;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    padding: 8px 18px;
    color: var(--genealogy-primary-dark);
    font-weight: 600;
    border: 1px solid rgba(82, 120, 83, 0.25);
    border-radius: 50px;
    background-color: rgba(255, 255, 255, 0.75);
}

.text-genealogy {
    color: var(--genealogy-primary);
}


/* Logo */

.hero-logo-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 420px;
    max-width: 100%;
    min-height: 420px;
    padding: 40px;
    border: 1px solid rgba(82, 120, 83, 0.15);
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.75);
    box-shadow: 0 25px 60px rgba(48, 77, 48, 0.15);
}

.hero-logo {
    width: 300px;
    max-width: 100%;
    height: auto;
    transition: transform 0.4s ease;
}

.hero-logo-wrapper:hover .hero-logo {
    transform: scale(1.05);
}


/* Boutons */

.btn-genealogy {
    color: #ffffff !important;
    border: 2px solid var(--genealogy-primary) !important;
    background: linear-gradient(135deg, var(--navbar-green-light), var(--navbar-green-dark));
    box-shadow: 0 8px 20px rgba(82, 120, 83, 0.2) !important;
    transition: all 0.3s ease !important;
}

.btn-genealogy:hover,
.btn-genealogy:focus {
    color: #ffffff !important;
    border-color: var(--genealogy-primary-dark) !important;
    background: linear-gradient(135deg, var(--navbar-green-dark)), var(--navbar-green-light);
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(48, 77, 48, 0.25);
}

.btn-genealogy-white {
    color: #ffffff !important;
    border: 1px solid #ffffff !important;
    background: linear-gradient(135deg, var(--navbar-green-light), var(--navbar-green-dark));
    box-shadow: 0 8px 20px rgba(82, 120, 83, 0.2) !important;
    transition: all 0.3s ease !important;
}

.btn-genealogy-white:hover,
.btn-genealogy-white:focus {
    color: #ffffff !important;
    border: 1px solid #ffffff !important;
    background: linear-gradient(135deg, var(--navbar-green-dark)), var(--navbar-green-light);
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(48, 77, 48, 0.25);
}


.btn-outline-genealogy {
    color: var(--genealogy-primary-dark) !important;
    border: 2px solid var(--genealogy-primary) !important;
    background-color: transparent !important;
    transition: all 0.3s ease !important
}

.btn-outline-genealogy:hover,
.btn-outline-genealogy:focus {
    color: #ffffff !important;
    border-color: var(--genealogy-primary) !important;
    background: linear-gradient(135deg, var(--navbar-green-light), var(--navbar-green-dark));
    transform: translateY(-2px) !important;
}


.btn-outline-genealogy-white {
    color: #ffffff !important;
    border: 2px solid var(--genealogy-primary) !important;
    background-color: transparent !important;
    transition: all 0.3s ease !important
}

.btn-outline-genealogy-white:hover,
.btn-outline-genealogy-white:focus {
    color: #ffffff !important;
    border-color: var(--genealogy-primary) !important;
    background: linear-gradient(135deg, var(--navbar-green-light), var(--navbar-green-dark));
    transform: translateY(-2px) !important;
}

.btn-outline-danger{
    background: white !important;
}

.btn-outline-danger:hover,
.btn-outline-danger:focus {
    background: linear-gradient(135deg, var(--navbar-green-light), var(--navbar-green-dark)) !important;
}




/* Message de bienvenue */

.welcome-section {
    background-color: #ffffff;
}

.welcome-card {
    padding: 30px;
    border-radius: 22px;
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 60%
    );
}

.welcome-avatar {
    width: 95px;
    height: 95px;
    padding: 4px;
    border: 3px solid var(--genealogy-secondary);
    border-radius: 50%;
    object-fit: cover;
    background-color: #ffffff;
}


/* Titres de sections */

.section-subtitle {
    margin-bottom: 8px;
    color: var(--genealogy-primary);
    font-size: 0.95rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.section-description {
    max-width: 700px;
}


/* Fonctionnalités */

.features-section {
    background-color: var(--genealogy-light);
}

.feature-card {
    position: relative;
    padding: 35px 30px;
    overflow: hidden;
    border-radius: 22px;
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 60%
    );
    transition: all 0.3s ease;
}

.feature-card:hover {
    border-color: rgba(82, 120, 83, 0.3);
    transform: translateY(-8px);
    box-shadow: 0 20px 40px rgba(48, 77, 48, 0.12) !important;
}

.feature-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 70px;
    height: 70px;
    margin-bottom: 25px;
    color: var(--genealogy-primary);
    font-size: 2rem;
    border-radius: 18px;
    background-color: rgba(82, 120, 83, 0.12);
}

.feature-link {
     color: var(--genealogy-primary-dark);
    font-weight: 700;
    text-decoration: none;
}

.feature-link:hover {
    color: green;
}


/* Étapes */

.steps-section {
    background-color: #ffffff;
}

.step-card {
    padding: 30px;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.step-card:hover {
    background-color: var(--genealogy-light);
    transform: translateY(-5px);
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 65px;
    height: 65px;
    color: #ffffff;
    font-size: 1.5rem;
    font-weight: 700;
    border-radius: 50%;
    background: linear-gradient(
            135deg,
            var(--genealogy-secondary),
            var(--genealogy-primary-dark)
    );
    box-shadow: 0 10px 25px rgba(48, 77, 48, 0.2);
}


/* Responsive */

@media screen and (max-width: 991px) {

    .genealogy-hero {
        text-align: center;
    }

    .min-vh-50 {
        min-height: auto;
    }

    .hero-logo-wrapper {
        width: 330px;
        min-height: 330px;
        padding: 30px;
    }

    .hero-logo {
        width: 230px;
    }
}

@media screen and (max-width: 576px) {

    .genealogy-hero .display-3 {
        font-size: 2.3rem;
    }

    .hero-logo-wrapper {
        width: 270px;
        min-height: 270px;
        padding: 25px;
    }

    .hero-logo {
        width: 190px;
    }

    .welcome-card {
        padding: 25px 18px;
    }

    .feature-card {
        padding: 28px 22px;
    }
}


/* ========================================================= PAGE PERSONNES / ESPACE FAMILIAL ========================================================= */
:root {
    --family-primary: #527853;
    --family-primary-dark: #304d30;
    --family-secondary: #739072;
    --family-light: #f3f7f2;
    --family-cream: #f7f1e5;
    --family-white: #ffffff;
    --family-text: #263328;
    --family-muted: #6c757d;
    --family-danger: #a63d40;
    --family-border: rgba(82, 120, 83, 0.16);
}

/* ========================================================= EN-TÊTE ========================================================= */
.family-header {
    position: relative;
    overflow: hidden;
    background: radial-gradient(circle at top right, rgba(115, 144, 114, 0.25), transparent 38%), linear-gradient(135deg, var(--family-cream), var(--family-light), #ffffff);
}

.family-header-badge {
    display: inline-flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 8px 18px;
    color: var(--family-primary-dark);
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.3px;
    border: 1px solid rgba(82, 120, 83, 0.2);
    border-radius: 50px;
    background-color: rgba(255, 255, 255, 0.75);
}

.family-header-title {
    color: var(--family-primary-dark);
}

.family-logo-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 250px;
    height: 250px;
    padding: 25px;
    border: 1px solid var(--family-border);
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.85);
    box-shadow: 0 25px 55px rgba(48, 77, 48, 0.16);
}

.family-logo {
    width: 190px;
    height: 190px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.family-logo-wrapper:hover .family-logo {
    transform: scale(1.05);
}

/* ========================================================= TITRES DE SECTION ========================================================= */
.family-section-eyebrow {
    color: var(--family-primary);
    font-size: 0.88rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1.2px;
}

.family-section-description {
    max-width: 700px;
}

/* ========================================================= BOUTONS ========================================================= */
.btn-family-primary {
    padding: 10px 21px;
    color: #ffffff;
    font-weight: 650;
    border: 2px solid var(--family-primary);
    border-radius: 12px;
    background-color: var(--family-primary);
    box-shadow: 0 8px 20px rgba(82, 120, 83, 0.18);
    transition: all 0.25s ease;
}

.btn-family-primary:hover, .btn-family-primary:focus {
    color: #ffffff;
    border-color: var(--family-primary-dark);
    background-color: var(--family-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(48, 77, 48, 0.22);
}

.btn-outline-family {
    padding: 10px 21px;
    color: var(--family-primary-dark);
    font-weight: 650;
    border: 2px solid var(--family-primary);
    border-radius: 12px;
    background-color: transparent;
    transition: all 0.25s ease;
}

.btn-outline-family:hover {
    color: #ffffff;
    background-color: var(--family-primary);
}

/* ========================================================= MESSAGE DE BIENVENUE ========================================================= */
.family-help-section {
    background-color: #ffffff;
}

.family-welcome-card {
    padding: 30px;
    border: 1px solid var(--family-border);
    border-radius: 22px;
    background: linear-gradient(135deg, rgba(247, 241, 229, 0.75), rgba(243, 247, 242, 0.85));
}

.family-profile-image {
    width: 95px;
    height: 95px;
    padding: 4px;
    border: 3px solid var(--family-secondary);
    border-radius: 50%;
    object-fit: cover;
    background-color: #ffffff;
}

/* ========================================================= CARTES D'AIDE ========================================================= */
.family-help-card {
    padding: 30px;
    border: 1px solid var(--family-border);
    border-radius: 20px;
    background-color: #ffffff;
    transition: all 0.3s ease;
}

.family-help-card:hover {
    border-color: rgba(82, 120, 83, 0.35);
    transform: translateY(-6px);
    box-shadow: 0 18px 35px rgba(48, 77, 48, 0.12) !important;
}

.family-help-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 65px;
    height: 65px;
    margin-bottom: 22px;
    color: var(--family-primary);
    font-size: 1.8rem;
    border-radius: 18px;
    background-color: rgba(82, 120, 83, 0.12);
}

.family-help-button {
    padding: 8px 14px;
    color: var(--family-primary);
    font-weight: 650;
    border: 1px solid rgba(82, 120, 83, 0.25);
    border-radius: 10px;
    background-color: var(--family-light);
}

.family-help-button:hover {
    color: #ffffff;
    border-color: var(--family-primary);
    background-color: var(--family-primary);
}

.family-help-content {
    padding: 18px;
    color: var(--family-text);
    line-height: 1.65;
    border-radius: 14px;
    background-color: var(--family-light);
}

/* ========================================================= COMPLÉTION DU PROFIL ========================================================= */
.profile-completion-section {
    background: linear-gradient(135deg, var(--family-light), #ffffff);
}

.profile-completion-layout {
    overflow: hidden;
    border: 1px solid var(--family-border);
    border-radius: 28px;
    background-color: #ffffff;
}

.profile-completion-intro {
    display: flex;
    align-items: center;
    min-height: 630px;
    padding: 45px 35px;
    color: #ffffff;
    background: linear-gradient(145deg, var(--family-primary-dark), var(--family-primary));
}

.profile-completion-intro p {
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.7;
}

.profile-completion-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 78px;
    height: 78px;
    margin-bottom: 30px;
    font-size: 2.2rem;
    border-radius: 22px;
    background-color: rgba(255, 255, 255, 0.12);
}

.profile-completion-form {
    min-height: 630px;
    padding: 45px;
}

.profile-photo-block {
    padding: 24px;
    border: 1px solid var(--family-border);
    border-radius: 18px;
    background-color: var(--family-light);
}

.profile-photo-preview {
    width: 145px;
    height: 145px;
    padding: 4px;
    border: 3px solid var(--family-secondary);
    border-radius: 50%;
    object-fit: cover;
    background-color: #ffffff;
}

.profile-completion-form .form-control, .profile-completion-form input:not([type="checkbox"]) {
    width: 100%;
    min-height: 50px;
    padding: 11px 15px;
    border: 1px solid rgba(82, 120, 83, 0.25);
    border-radius: 13px;
    background-color: #fbfdfb;
    box-shadow: none;
}

.profile-completion-form .form-control:focus, .profile-completion-form input:not([type="checkbox"]):focus {
    border-color: var(--family-primary);
    box-shadow: 0 0 0 0.25rem rgba(82, 120, 83, 0.13);
}

.profile-policy-block {
    padding: 18px;
    border: 1px solid var(--family-border);
    border-radius: 14px;
    background-color: var(--family-light);
}

.profile-policy-block a {
    color: var(--family-primary);
    font-weight: 650;
}

.profile-policy-block .form-check-input:checked {
    border-color: var(--family-primary);
    background-color: var(--family-primary);
}

.family-field-error {
    display: block;
    margin-top: 7px;
    color: var(--family-danger);
    font-size: 0.85rem;
    font-weight: 600;
}

/* ========================================================= SECTION PERSONNES ========================================================= */
.family-persons-section {
    background-color: var(--family-light);
}

.family-search-form .input-group {
    overflow: hidden;
    border: 1px solid rgba(82, 120, 83, 0.22);
    border-radius: 13px;
    background-color: #ffffff;
}

.family-search-form .input-group-text {
    color: var(--family-primary);
    border: 0;
    background-color: #ffffff;
}

.family-search-form .form-control {
    min-height: 50px;
    border: 0;
    box-shadow: none;
}

.family-search-form .btn {
    border-radius: 0;
}

.family-actions-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 18px 22px;
    border: 1px solid var(--family-border);
    border-radius: 16px;
    background-color: #ffffff;
}

/* ========================================================= CARTES PERSONNES ========================================================= */
.family-person-card {
    overflow: hidden;
    border-radius: 20px;
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #8bb473 90%,
        rgba(16, 56, 4, 0.75) 60%
    );
    transition: all 0.3s ease;
}

.family-person-card:hover {
    border-color: rgba(82, 120, 83, 0.35);
    transform: translateY(-7px);
    box-shadow: 0 20px 40px rgba(48, 77, 48, 0.14) !important;
}

.family-person-image-link {
    position: relative;
    display: block;
    height: 280px;
    overflow: hidden;
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        rgba(16, 56, 4, 0.75) 100%
    );
}

.family-person-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.4s ease;
}

.family-person-card:hover .family-person-image {
    transform: scale(1.06);
}

.family-person-overlay {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px;
    color: #ffffff;
    font-weight: 650;
    background: linear-gradient(transparent, rgba(48, 77, 48, 0.92));
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.family-person-card:hover .family-person-overlay {
    transform: translateY(0);
}

.family-person-content {
    padding: 22px;
}

.family-person-status {
    margin-bottom: 13px;
}

.family-status-badge {
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
    font-size: 0.75rem;
    font-weight: 700;
    border-radius: 50px;
}

.family-status-living {
    color: #356c3d;
    background-color: rgba(82, 120, 83, 0.14);
}

.family-status-deceased {
    color: #6a4d4d;
    background-color: rgba(108, 90, 90, 0.12);
}

.family-person-name {
    color: var(--family-primary-dark);
    text-decoration: none;
}

.family-person-name:hover {
    color: var(--family-primary);
}

.family-person-birth-name {
    margin-bottom: 14px;
    color: var(--family-muted);
    font-size: 0.88rem;
    font-style: italic;
}

.family-person-meta {
    margin-bottom: 17px;
    color: var(--family-muted);
    font-size: 0.9rem;
}

.family-person-meta p {
    margin-bottom: 7px;
}

.family-person-meta i {
    color: var(--family-primary);
}

.family-person-details-link {
    color: var(--family-primary);
    font-weight: 700;
    text-decoration: none;
}

.family-person-details-link:hover {
    color: var(--family-primary-dark);
}

/* ========================================================= ÉTAT VIDE ========================================================= */
.family-empty-state {
    padding: 60px 25px;
    border: 2px dashed rgba(82, 120, 83, 0.25);
    border-radius: 22px;
    background-color: #ffffff;
}

.family-empty-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 90px;
    height: 90px;
    margin-bottom: 25px;
    color: var(--family-primary);
    font-size: 2.7rem;
    border-radius: 50%;
    background-color: rgba(82, 120, 83, 0.12);
}

/* ========================================================= PAGINATION ========================================================= */
.family-pagination .page-link {
    min-width: 42px;
    color: var(--family-primary-dark);
    text-align: center;
    border-color: rgba(82, 120, 83, 0.2);
    background-color: #ffffff;
}

.family-pagination .page-link:hover {
    color: #ffffff;
    border-color: var(--family-primary);
    background-color: var(--family-primary);
}

.family-pagination .page-item.active .page-link {
    color: #ffffff;
    border-color: var(--family-primary);
    background-color: var(--family-primary);
}

/* ========================================================= RESPONSIVE ========================================================= */
@media screen and (max-width: 991px) {
    .family-header {
        text-align: center;
    }

    .profile-completion-intro {
        min-height: auto;
        text-align: center;
    }

    .profile-completion-icon {
        margin-right: auto;
        margin-left: auto;
    }

    .profile-completion-form {
        min-height: auto;
    }
}

@media screen and (max-width: 767px) {
    .family-actions-bar {
        align-items: stretch;
        flex-direction: column;
    }

    .family-actions-bar .btn {
        width: 100%;
    }

    .family-person-image-link {
        height: 320px;
    }
}

@media screen and (max-width: 576px) {
    .family-logo-wrapper {
        width: 210px;
        height: 210px;
    }

    .family-logo {
        width: 155px;
        height: 155px;
    }

    .family-welcome-card {
        padding: 24px 18px;
        text-align: center;
    }

    .family-profile-image {
        width: 85px;
        height: 85px;
    }

    .family-help-card {
        padding: 24px 20px;
    }

    .profile-completion-layout {
        border-radius: 20px;
    }

    .profile-completion-intro {
        padding: 35px 22px;
    }

    .profile-completion-form {
        padding: 35px 22px;
    }

    .profile-completion-form .btn {
        width: 100%;
    }

    .family-search-form .input-group {
        flex-wrap: wrap;
    }

    .family-search-form .input-group-text {
        display: none;
    }

    .family-search-form .form-control {
        width: 100%;
        flex: 1 0 100%;
        border-bottom: 1px solid var(--family-border);
    }

    .family-search-form .btn-family-primary {
        flex-grow: 1;
    }

    .family-person-image-link {
        height: 290px;
    }
}

/* ========================================================= PAGE MON PROFIL ========================================================= */
:root {
    --profile-primary: #527853;
    --profile-primary-dark: #304d30;
    --profile-secondary: #739072;
    --profile-light: #f3f7f2;
    --profile-cream: #f7f1e5;
    --profile-white: #ffffff;
    --profile-text: #263328;
    --profile-muted: #6c757d;
    --profile-danger: #a63d40;
    --profile-warning: #c88b26;
    --profile-border: rgba(82, 120, 83, 0.16);
}

/* ========================================================= EN-TÊTE ========================================================= */
.profile-page-header {
    position: relative;
    overflow: hidden;
    background: radial-gradient(circle at top right, rgba(115, 144, 114, 0.25), transparent 38%), linear-gradient(135deg, var(--profile-cream), var(--profile-light), #ffffff);
}

.profile-page-decoration {
    position: absolute;
    pointer-events: none;
    border-radius: 50%;
}

.profile-page-decoration-left {
    bottom: -180px;
    left: -150px;
    width: 430px;
    height: 430px;
    background-color: rgba(82, 120, 83, 0.07);
}

.profile-page-decoration-right {
    top: -130px;
    right: -100px;
    width: 340px;
    height: 340px;
    border: 45px solid rgba(82, 120, 83, 0.06);
}

.profile-page-badge {
    display: inline-flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 8px 18px;
    color: var(--profile-primary-dark);
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.3px;
    border: 1px solid rgba(82, 120, 83, 0.2);
    border-radius: 50px;
    background-color: rgba(255, 255, 255, 0.75);
}

.profile-page-title {
    color: var(--profile-primary-dark);
}

.profile-page-logo-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 230px;
    height: 230px;
    padding: 25px;
    border: 1px solid var(--profile-border);
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.85);
    box-shadow: 0 25px 55px rgba(48, 77, 48, 0.16);
}

.profile-page-logo {
    width: 175px;
    height: 175px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.profile-page-logo-wrapper:hover .profile-page-logo {
    transform: scale(1.05);
}

/* ========================================================= CONTENU GÉNÉRAL ========================================================= */
.profile-page-content {
    min-height: 70vh;
    background-color: var(--profile-light);
}

.profile-section-eyebrow {
    color: var(--profile-primary);
    font-size: 0.85rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1.1px;
}

/* ========================================================= BOUTONS ========================================================= */
.btn-profile-primary {
    padding: 10px 21px;
    color: #ffffff;
    font-weight: 650;
    border: 2px solid var(--profile-primary);
    border-radius: 12px;
    background-color: var(--profile-primary);
    box-shadow: 0 8px 20px rgba(82, 120, 83, 0.18);
    transition: all 0.25s ease;
}

.btn-profile-primary:hover, .btn-profile-primary:focus {
    color: #ffffff;
    border-color: var(--profile-primary-dark);
    background-color: var(--profile-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(48, 77, 48, 0.22);
}

.btn-profile-outline {
    padding: 10px 21px;
    color: var(--profile-primary-dark);
    font-weight: 650;
    border: 2px solid var(--profile-primary);
    border-radius: 12px;
    background-color: transparent;
    transition: all 0.25s ease;
}

.btn-profile-outline:hover {
    color: #ffffff;
    border-color: var(--profile-primary);
    background-color: var(--profile-primary);
}

/* ========================================================= CARTE DU PROFIL ========================================================= */
.profile-main-card, .profile-secondary-card, .tree-summary-card {
    overflow: hidden;
    border-radius: 22px;
    background-color: #ffffff;
}

.profile-main-card {
    padding: 30px;
}

.profile-card-heading, .profile-secondary-heading {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 28px;
}

.profile-heading-icon, .profile-secondary-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    color: var(--profile-primary);
    font-size: 1.55rem;
    border-radius: 16px;
    background-color: rgba(82, 120, 83, 0.12);
}

/* ========================================================= PHOTO DU PROFIL ========================================================= */
.profile-photo-section {
    padding: 24px;
    text-align: center;
    border: 1px solid var(--profile-border);
    border-radius: 18px;
    background-color: var(--profile-light);
}

.profile-photo-container {
    position: relative;
    display: inline-block;
    margin-bottom: 18px;
}

.profile-user-photo {
    width: 170px;
    height: 170px;
    padding: 5px;
    border: 3px solid var(--profile-secondary);
    border-radius: 50%;
    object-fit: cover;
    background-color: #ffffff;
}

.profile-photo-badge {
    position: absolute;
    right: 8px;
    bottom: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 43px;
    height: 43px;
    color: #ffffff;
    border: 4px solid var(--profile-light);
    border-radius: 50%;
    background-color: var(--profile-primary);
}

.profile-photo-field {
    text-align: left;
}

/* ========================================================= CHAMPS ========================================================= */
.profile-update-form .form-control, .profile-update-form input:not([type="checkbox"]), .profile-update-form select, .tree-share-form .form-control, .tree-share-form input, .tree-share-form select {
    width: 100%;
    min-height: 50px;
    padding: 11px 15px;
    color: var(--profile-text);
    border: 1px solid rgba(82, 120, 83, 0.25);
    border-radius: 13px;
    background-color: #fbfdfb;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.profile-update-form .form-control:focus, .profile-update-form input:not([type="checkbox"]):focus, .profile-update-form select:focus, .tree-share-form .form-control:focus, .tree-share-form input:focus, .tree-share-form select:focus {
    border-color: var(--profile-primary);
    background-color: #ffffff;
    box-shadow: 0 0 0 0.25rem rgba(82, 120, 83, 0.13);
    outline: none;
}

.profile-field-error {
    display: block;
    margin-top: 7px;
    color: var(--profile-danger);
    font-size: 0.85rem;
    font-weight: 600;
}

/* ========================================================= EMAIL ET RGPD ========================================================= */
.profile-email-block {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px;
    border: 1px solid var(--profile-border);
    border-radius: 14px;
    background-color: var(--profile-light);
}

.profile-email-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 43px;
    height: 43px;
    color: var(--profile-primary);
    border-radius: 12px;
    background-color: rgba(82, 120, 83, 0.12);
}

.profile-email-label, .profile-email-value {
    display: block;
}

.profile-email-label {
    color: var(--profile-muted);
    font-size: 0.8rem;
}

.profile-email-value {
    overflow-wrap: anywhere;
}

.profile-policy-block {
    padding: 18px;
    border: 1px solid var(--profile-border);
    border-radius: 14px;
    background-color: var(--profile-light);
}

.profile-policy-block a {
    color: var(--profile-primary);
    font-weight: 650;
}

.profile-policy-block .form-check-input:checked {
    border-color: var(--profile-primary);
    background-color: var(--profile-primary);
}

.profile-form-actions {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 28px;
}

/* ========================================================= RÉSUMÉ DE L'ARBRE ========================================================= */
.tree-summary-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 24px;
    background: linear-gradient(135deg, rgba(247, 241, 229, 0.75), rgba(243, 247, 242, 0.95));
}

.tree-summary-content {
    display: flex;
    align-items: center;
    gap: 18px;
}

.tree-summary-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 68px;
    height: 68px;
    color: #ffffff;
    font-size: 1.9rem;
    border-radius: 18px;
    background: linear-gradient(135deg, var(--profile-primary), var(--profile-primary-dark));
    box-shadow: 0 10px 25px rgba(48, 77, 48, 0.2);
}

.tree-permission-badge, .tree-role-badge {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    padding: 7px 11px;
    font-size: 0.78rem;
    font-weight: 700;
    border-radius: 50px;
}

.tree-permission-admin {
    color: #356c3d;
    background-color: rgba(82, 120, 83, 0.14);
}

.tree-permission-read {
    color: #53606d;
    background-color: rgba(108, 117, 125, 0.13);
}

/* ========================================================= CARTES SECONDAIRES ========================================================= */
.profile-secondary-card {
    padding: 26px;
}

.profile-secondary-icon-warning {
    color: var(--profile-warning);
    background-color: rgba(200, 139, 38, 0.13);
}

.profile-info-message {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    padding: 17px;
    color: #305572;
    border: 1px solid rgba(48, 85, 114, 0.15);
    border-radius: 14px;
    background-color: rgba(48, 85, 114, 0.07);
}

.profile-info-message i {
    margin-top: 3px;
}

/* ========================================================= LISTE DES MEMBRES ========================================================= */
.tree-access-list, .tree-invitation-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tree-access-member, .tree-invitation {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 15px;
    border: 1px solid var(--profile-border);
    border-radius: 15px;
    background-color: var(--profile-light);
    transition: all 0.2s ease;
}

.tree-access-member:hover, .tree-invitation:hover {
    border-color: rgba(82, 120, 83, 0.3);
    background-color: #ffffff;
    transform: translateX(3px);
}

.tree-member-avatar, .tree-invitation-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    color: var(--profile-primary);
    font-size: 1.15rem;
    border-radius: 14px;
    background-color: rgba(82, 120, 83, 0.12);
}

.tree-member-information, .tree-invitation-information {
    min-width: 0;
    flex-grow: 1;
}

.tree-member-information strong, .tree-member-information span, .tree-invitation-information strong, .tree-invitation-information span {
    display: block;
    overflow-wrap: anywhere;
}

.tree-member-information span, .tree-invitation-information span {
    color: var(--profile-muted);
    font-size: 0.83rem;
}

.tree-role-owner {
    color: #4d4414;
    background-color: rgba(212, 175, 55, 0.18);
}

.tree-role-admin {
    color: #356c3d;
    background-color: rgba(82, 120, 83, 0.15);
}

.tree-role-reader {
    color: #53606d;
    background-color: rgba(108, 117, 125, 0.14);
}

.tree-role-pending {
    color: #805919;
    background-color: rgba(200, 139, 38, 0.16);
}

.tree-access-empty {
    padding: 28px 18px;
    color: var(--profile-muted);
    text-align: center;
    border: 2px dashed rgba(82, 120, 83, 0.22);
    border-radius: 15px;
}

.tree-access-empty i {
    display: block;
    margin-bottom: 10px;
    color: var(--profile-primary);
    font-size: 2rem;
}

/* ========================================================= AUCUN ARBRE / CONNEXION ========================================================= */
.profile-no-tree, .profile-login-required {
    padding: 60px 30px;
    border: 1px solid var(--profile-border);
    border-radius: 22px;
    background-color: #ffffff;
}

.profile-no-tree {
    text-align: center;
}

.profile-no-tree-icon, .profile-login-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 90px;
    height: 90px;
    margin-bottom: 24px;
    color: var(--profile-primary);
    font-size: 2.6rem;
    border-radius: 50%;
    background-color: rgba(82, 120, 83, 0.12);
}

/* ========================================================= RESPONSIVE ========================================================= */
@media screen and (max-width: 1199px) {
    .tree-share-form .btn {
        min-height: 50px;
    }
}

@media screen and (max-width: 991px) {
    .profile-page-header {
        text-align: center;
    }

    .profile-main-card {
        padding: 26px;
    }

    .tree-summary-card {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media screen and (max-width: 767px) {
    .profile-form-actions {
        flex-direction: column-reverse;
    }

    .profile-form-actions .btn {
        width: 100%;
    }

    .tree-access-member, .tree-invitation {
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .tree-role-badge {
        margin-left: 60px;
    }
}

@media screen and (max-width: 576px) {
    .profile-page-logo-wrapper {
        width: 200px;
        height: 200px;
    }

    .profile-page-logo {
        width: 150px;
        height: 150px;
    }

    .profile-main-card, .profile-secondary-card {
        padding: 22px 18px;
        border-radius: 18px;
    }

    .profile-card-heading, .profile-secondary-heading {
        align-items: center;
    }

    .profile-heading-icon, .profile-secondary-icon {
        width: 50px;
        height: 50px;
    }

    .profile-user-photo {
        width: 145px;
        height: 145px;
    }

    .tree-summary-content {
        align-items: flex-start;
    }

    .tree-summary-icon {
        width: 55px;
        height: 55px;
    }

    .tree-role-badge {
        width: 100%;
        margin-left: 0;
        justify-content: center;
    }

    .profile-no-tree, .profile-login-required {
        padding: 45px 20px;
    }
}


/* ========================================================= PAGE DÉTAIL D'UNE PERSONNE ========================================================= */
:root {
    --person-detail-primary: #527853;
    --person-detail-primary-dark: #304d30;
    --person-detail-secondary: #739072;
    --person-detail-light: #f3f7f2;
    --person-detail-cream: #f7f1e5;
    --person-detail-white: #ffffff;
    --person-detail-text: #263328;
    --person-detail-muted: #6c757d;
    --person-detail-danger: #a63d40;
    --person-detail-warning: #c88b26;
    --person-detail-border: rgba(82, 120, 83, 0.16);
}

/* ========================================================= EN-TÊTE ========================================================= */
.person-detail-main-photo-link {
    position: relative;
    display: inline-block;
}

.person-detail-main-photo {
    width: 220px;
    height: 220px;
    padding: 6px;
    border: 4px solid var(--person-detail-secondary);
    border-radius: 28px;
    object-fit: cover;
    background-color: #ffffff;
    box-shadow: 0 20px 45px rgba(48, 77, 48, 0.18);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.person-detail-main-photo-link:hover .person-detail-main-photo {
    transform: scale(1.025);
    box-shadow: 0 25px 55px rgba(48, 77, 48, 0.24);
}

.person-detail-photo-edit {
    position: absolute;
    right: -7px;
    bottom: -7px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    color: #ffffff;
    border: 5px solid var(--person-detail-light);
    border-radius: 50%;
    background-color: var(--person-detail-primary);
}

.person-detail-badge {
    display: inline-flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 8px 18px;
    color: var(--person-detail-primary-dark);
    font-size: 0.88rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    border: 1px solid rgba(82, 120, 83, 0.2);
    border-radius: 50px;
    background-color: rgba(255, 255, 255, 0.75);
}

.person-detail-title {
    color: var(--person-detail-primary-dark);
}

.person-detail-birth-name {
    margin-bottom: 18px;
    color: var(--person-detail-muted);
    font-size: 1.1rem;
    font-style: italic;
}

.person-detail-status-list {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
}

.person-detail-status {
    display: inline-flex;
    align-items: center;
    padding: 7px 12px;
    font-size: 0.82rem;
    font-weight: 700;
    border-radius: 50px;
}

.person-detail-status-living {
    color: #356c3d;
    background-color: rgba(82, 120, 83, 0.14);
}

.person-detail-status-deceased {
    color: #70494a;
    background-color: rgba(166, 61, 64, 0.12);
}

.person-detail-status-neutral {
    color: #53606d;
    background-color: rgba(108, 117, 125, 0.12);
}

.person-detail-header-actions {
    display: flex;
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
}

/* ========================================================= BOUTONS ========================================================= */
.btn-person-detail-primary, .btn-person-detail-outline, .btn-person-detail-danger, .btn-person-detail-danger-outline {
    padding: 10px 19px;
    font-weight: 650;
    border-width: 2px;
    border-style: solid;
    border-radius: 12px;
    transition: all 0.25s ease;
}

.btn-person-detail-primary {
    color: #ffffff;
    border-color: var(--person-detail-primary);
    background-color: var(--person-detail-primary);
    box-shadow: 0 8px 20px rgba(82, 120, 83, 0.18);
}

.btn-person-detail-primary:hover, .btn-person-detail-primary:focus {
    color: #ffffff;
    border-color: var(--person-detail-primary-dark);
    background-color: var(--person-detail-primary-dark);
    transform: translateY(-2px);
}

.btn-person-detail-outline {
    color: var(--person-detail-primary-dark);
    border-color: var(--person-detail-primary);
    background-color: transparent;
}

.btn-person-detail-outline:hover {
    color: #ffffff;
    border-color: var(--person-detail-primary);
    background-color: var(--person-detail-primary);
}

.btn-person-detail-danger {
    color: #ffffff;
    border-color: var(--person-detail-danger);
    background-color: var(--person-detail-danger);
}

.btn-person-detail-danger:hover {
    color: #ffffff;
    border-color: #7d2e31;
    background-color: #7d2e31;
    transform: translateY(-2px);
}

.btn-person-detail-danger-outline {
    color: var(--person-detail-danger);
    border-color: rgba(166, 61, 64, 0.55);
    background-color: transparent;
}

.btn-person-detail-danger-outline:hover {
    color: #ffffff;
    border-color: var(--person-detail-danger);
    background-color: var(--person-detail-danger);
}

/* ========================================================= CONTENU ET CARTES ========================================================= */
.person-detail-content {
    min-height: 75vh;
    background-color: var(--person-detail-light);
}

.person-detail-card {
    padding: 28px;
    border-radius: 22px;
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 100%
    );
}

.person-detail-card-heading {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 27px;
}

.person-detail-card-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 58px;
    height: 58px;
    color: var(--person-detail-primary);
    font-size: 1.55rem;
    border-radius: 16px;
    background-color: rgba(82, 120, 83, 0.12);
}

.person-detail-card-icon-union {
    color: #a84b5a;
    background-color: rgba(168, 75, 90, 0.12);
}

.person-detail-card-icon-old-union {
    color: var(--person-detail-warning);
    background-color: rgba(200, 139, 38, 0.13);
}

.person-detail-eyebrow {
    color: var(--person-detail-primary);
    font-size: 0.82rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1.1px;
}

/* ========================================================= CONJOINTS ========================================================= */
.person-relative-card {
    overflow: hidden;
    border: 1px solid var(--person-detail-border);
    border-radius: 18px;
    background-color: var(--person-detail-light);
    transition: all 0.25s ease;
}

.person-relative-card:hover {
    border-color: rgba(82, 120, 83, 0.35);
    background-color: #ffffff;
    transform: translateY(-4px);
    box-shadow: 0 14px 30px rgba(48, 77, 48, 0.1);
}

.person-relative-image-link {
    display: block;
    height: 210px;
    overflow: hidden;
}

.person-relative-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.35s ease;
}

.person-relative-card:hover .person-relative-image {
    transform: scale(1.05);
}

.person-relative-content {
    padding: 19px;
}

.person-relative-type {
    display: block;
    margin-bottom: 4px;
    color: var(--person-detail-primary);
    font-size: 0.76rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 0.9px;
}

.person-relative-name {
    display: block;
    margin-bottom: 13px;
    color: var(--person-detail-primary-dark);
    font-size: 1.15rem;
    font-weight: 750;
    text-decoration: none;
}

.person-relative-name:hover {
    color: var(--person-detail-primary);
}

.person-union-information {
    color: var(--person-detail-muted);
    font-size: 0.88rem;
}

.person-union-information p {
    margin-bottom: 6px;
}

.person-union-information i {
    color: var(--person-detail-primary);
}

.person-relative-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
}

/* ========================================================= PARENTS ========================================================= */
.person-parent-card {
    padding: 24px;
    text-align: center;
    border: 1px solid var(--person-detail-border);
    border-radius: 18px;
    background-color: var(--person-detail-light);
}

.person-parent-title {
    margin-bottom: 18px;
    color: var(--person-detail-primary-dark);
    font-size: 0.9rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.person-parent-image-link {
    display: inline-block;
    margin-bottom: 13px;
}

.person-parent-image {
    width: 145px;
    height: 145px;
    padding: 4px;
    border: 3px solid rgba(82, 120, 83, 0.3);
    border-radius: 50%;
    object-fit: cover;
    background-color: #ffffff;
    transition: transform 0.25s ease;
}

.person-parent-image-link:hover .person-parent-image {
    transform: scale(1.04);
}

.person-parent-name {
    display: block;
    color: var(--person-detail-primary-dark);
    font-size: 1.05rem;
    font-weight: 750;
    text-decoration: none;
}

.person-parent-name:hover {
    color: var(--person-detail-primary);
}

.person-parent-empty {
    padding: 20px 10px;
    color: var(--person-detail-muted);
}

.person-parent-empty > i {
    display: block;
    margin-bottom: 14px;
    color: var(--person-detail-primary);
    font-size: 2.5rem;
}

/* ========================================================= ENFANTS ========================================================= */
.person-child-card {
    padding: 18px;
    text-align: center;
    border: 1px solid var(--person-detail-border);
    border-radius: 17px;
    background-color: var(--person-detail-light);
    transition: all 0.25s ease;
}

.person-child-card:hover {
    border-color: rgba(82, 120, 83, 0.35);
    background-color: #ffffff;
    transform: translateY(-4px);
}

.person-child-image-link {
    display: inline-block;
    margin-bottom: 12px;
}

.person-child-image {
    width: 125px;
    height: 125px;
    padding: 3px;
    border: 3px solid rgba(82, 120, 83, 0.25);
    border-radius: 50%;
    object-fit: cover;
    background-color: #ffffff;
}

.person-child-name {
    display: block;
    color: var(--person-detail-primary-dark);
    font-weight: 750;
    text-decoration: none;
}

.person-child-name:hover {
    color: var(--person-detail-primary);
}

.person-child-relationship {
    display: inline-block;
    margin-top: 6px;
    padding: 4px 9px;
    color: var(--person-detail-muted);
    font-size: 0.72rem;
    border-radius: 50px;
    background-color: rgba(108, 117, 125, 0.1);
}

/* ========================================================= INFORMATIONS ========================================================= */
.person-information-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.person-information-row {
    display: flex;
    align-items: center;
    gap: 13px;
    padding: 14px;
    border: 1px solid var(--person-detail-border);
    border-radius: 14px;
    background-color: var(--person-detail-light);
}

.person-information-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    color: var(--person-detail-primary);
    border-radius: 12px;
    background-color: rgba(82, 120, 83, 0.12);
}

.person-information-label, .person-information-row strong {
    display: block;
}

.person-information-label {
    color: var(--person-detail-muted);
    font-size: 0.78rem;
}

/* ========================================================= CHRONOLOGIE ========================================================= */
.person-timeline {
    position: relative;
    padding-left: 12px;
}

.person-timeline::before {
    position: absolute;
    top: 12px;
    bottom: 12px;
    left: 21px;
    width: 2px;
    content: "";
    background-color: rgba(82, 120, 83, 0.2);
}

.person-timeline-item {
    position: relative;
    display: flex;
    gap: 18px;
    padding: 12px 0;
}

.person-timeline-dot {
    position: relative;
    z-index: 2;
    flex: 0 0 auto;
    width: 20px;
    height: 20px;
    margin-top: 5px;
    border: 5px solid #ffffff;
    border-radius: 50%;
    background-color: var(--person-detail-primary);
    box-shadow: 0 0 0 2px rgba(82, 120, 83, 0.25);
}

.person-timeline-dot-death {
    background-color: var(--person-detail-danger);
}

.person-timeline-content {
    display: flex;
    flex-direction: column;
}

.person-timeline-title {
    color: var(--person-detail-primary);
    font-size: 0.78rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 0.9px;
}

.person-timeline-note, .person-timeline-place {
    color: var(--person-detail-muted);
    font-size: 0.84rem;
}

/* ========================================================= PROFESSION ========================================================= */
.person-occupation {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px;
    color: var(--person-detail-text);
    border: 1px solid var(--person-detail-border);
    border-radius: 15px;
    background-color: var(--person-detail-light);
}

.person-occupation > i {
    color: var(--person-detail-primary);
    font-size: 1.5rem;
}

/* ========================================================= ANCIENNES UNIONS ========================================================= */
.person-old-union {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px;
    border: 1px solid var(--person-detail-border);
    border-radius: 16px;
    background-color: var(--person-detail-light);
}

.person-old-union-image {
    width: 90px;
    height: 90px;
    border-radius: 14px;
    object-fit: cover;
}

.person-old-union-content {
    min-width: 0;
    flex-grow: 1;
}

.person-old-union-name {
    display: block;
    margin-bottom: 5px;
    color: var(--person-detail-primary-dark);
    font-size: 1.05rem;
    font-weight: 750;
    text-decoration: none;
}

.person-old-union-content p {
    margin-bottom: 3px;
    color: var(--person-detail-muted);
    font-size: 0.85rem;
}

/* ========================================================= BIOGRAPHIE ========================================================= */
.person-biography {
    color: var(--person-detail-text);
    background: #ffffff;
    line-height: 1.75;
    padding: 10px;
    border-radius: 16px;
}

.person-biography img {
    max-width: 100%;
    height: auto;
    border-radius: 12px;
}

.person-biography p:last-child {
    margin-bottom: 0;
}

/* ========================================================= ÉTAT VIDE ========================================================= */
.person-detail-empty-state {
    padding: 32px 20px;
    color: var(--person-detail-muted);
    text-align: center;
    border: 2px dashed rgba(82, 120, 83, 0.22);
    border-radius: 17px;
    background-color: rgba(243, 247, 242, 0.65);
}

.person-detail-empty-state > i {
    display: block;
    margin-bottom: 12px;
    color: var(--person-detail-primary);
    font-size: 2.2rem;
}

/* ========================================================= MODALES ========================================================= */
.person-detail-modal {
    overflow: hidden;
    border: 0;
    border-radius: 20px;
}

.person-detail-modal .modal-header {
    border-bottom-color: var(--person-detail-border);
    background-color: var(--person-detail-light);
}

.person-detail-modal .modal-footer {
    border-top-color: var(--person-detail-border);
}

.person-delete-summary {
    display: flex;
    flex-direction: column;
    gap: 9px;
    padding: 16px;
    border: 1px solid var(--person-detail-border);
    border-radius: 14px;
    background-color: var(--person-detail-light);
}

.person-delete-summary div {
    display: flex;
    align-items: center;
    gap: 10px;
}

.person-delete-summary i {
    color: var(--person-detail-primary);
}

/* ========================================================= RESPONSIVE ========================================================= */
@media screen and (max-width: 1199px) {
    .person-detail-header-actions {
        flex-direction: row;
        flex-wrap: wrap;
    }
}

@media screen and (max-width: 991px) {
    .person-detail-header {
        text-align: center;
    }

    .person-detail-status-list {
        justify-content: center;
    }

    .person-detail-header-actions {
        justify-content: center;
    }

    .person-detail-card-heading {
        flex-wrap: wrap;
    }

    .person-detail-card-heading .ms-lg-auto {
        width: 100%;
        margin-left: 0 !important;
    }
}

@media screen and (max-width: 767px) {
    .person-detail-main-photo {
        width: 190px;
        height: 190px;
    }

    .person-detail-card {
        padding: 23px 19px;
        border-radius: 18px;
    }

    .person-detail-header-actions {
        flex-direction: column;
    }

    .person-detail-header-actions .btn {
        width: 100%;
    }

    .person-detail-card-heading {
        align-items: center;
    }

    .person-relative-actions {
        flex-direction: column;
    }

    .person-relative-actions .btn {
        width: 100%;
    }
}

@media screen and (max-width: 576px) {
    .person-detail-title {
        font-size: 2.2rem;
    }

    .person-detail-status-list {
        flex-direction: column;
    }

    .person-detail-status {
        justify-content: center;
        width: 100%;
    }

    .person-detail-card-icon {
        width: 50px;
        height: 50px;
    }

    .person-parent-image {
        width: 125px;
        height: 125px;
    }

    .person-old-union {
        align-items: flex-start;
        flex-direction: column;
    }

    .person-old-union-image {
        width: 100%;
        height: 190px;
    }

    .person-detail-modal .modal-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .person-detail-modal .modal-footer form, .person-detail-modal .modal-footer button {
        width: 100%;
    }
}

/* ========================================================= FORMULAIRE LIEN PARENT-ENFANT ========================================================= */
:root {
    --relationship-primary: #527853;
    --relationship-primary-dark: #304d30;
    --relationship-secondary: #739072;
    --relationship-light: #f3f7f2;
    --relationship-cream: #f7f1e5;
    --relationship-white: #ffffff;
    --relationship-text: #263328;
    --relationship-muted: #6c757d;
    --relationship-danger: #a63d40;
    --relationship-border: rgba(82, 120, 83, 0.16);
}

/* ========================================================= EN-TÊTE ========================================================= */

.relationship-page-badge {
    display: inline-flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 8px 18px;
    color: var(--relationship-primary-dark);
    font-size: 0.88rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    border: 1px solid rgba(82, 120, 83, 0.2);
    border-radius: 50px;
    background-color: rgba(255, 255, 255, 0.75);
}

.relationship-page-title {
    color: var(--relationship-primary-dark);
}

.relationship-logo-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 220px;
    height: 220px;
    padding: 24px;
    border: 1px solid var(--relationship-border);
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.85);
    box-shadow: 0 25px 55px rgba(48, 77, 48, 0.16);
}

.relationship-logo {
    width: 165px;
    height: 165px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.relationship-logo-wrapper:hover .relationship-logo {
    transform: scale(1.05);
}

/* ========================================================= CONTENU ========================================================= */
.relationship-page-content {
    min-height: 70vh;
    background-color: var(--relationship-light);
}

.relationship-layout {
    overflow: hidden;
    border: 1px solid var(--relationship-border);
    border-radius: 28px;
    background-color: var(--relationship-white);
}

/* ========================================================= PANNEAU DE PRÉSENTATION ========================================================= */
.relationship-intro-panel {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 720px;
    padding: 48px 34px;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(145deg, var(--relationship-primary-dark), var(--relationship-primary));
}

.relationship-intro-panel::before {
    position: absolute;
    top: -95px;
    right: -90px;
    width: 240px;
    height: 240px;
    content: "";
    border: 35px solid rgba(255, 255, 255, 0.06);
    border-radius: 50%;
}

.relationship-intro-panel::after {
    position: absolute;
    bottom: -110px;
    left: -110px;
    width: 270px;
    height: 270px;
    content: "";
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.05);
}

.relationship-intro-content {
    position: relative;
    z-index: 2;
}

.relationship-intro-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 78px;
    height: 78px;
    margin-bottom: 28px;
    font-size: 2.1rem;
    border-radius: 22px;
    background-color: rgba(255, 255, 255, 0.13);
}

.relationship-intro-eyebrow {
    margin-bottom: 8px;
    color: rgba(255, 255, 255, 0.72);
    font-size: 0.82rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1.2px;
}

.relationship-intro-text {
    margin-bottom: 32px;
    color: rgba(255, 255, 255, 0.82);
    line-height: 1.7;
}

.relationship-help-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.relationship-help-item {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: 15px;
    background-color: rgba(255, 255, 255, 0.07);
}

.relationship-help-item > span {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    color: #ffffff;
    border-radius: 12px;
    background-color: rgba(255, 255, 255, 0.12);
}

.relationship-help-item p {
    margin: 0;
    color: rgba(255, 255, 255, 0.78);
    font-size: 0.88rem;
    line-height: 1.5;
}

.relationship-help-item strong {
    display: block;
    color: #ffffff;
}

/* ========================================================= PANNEAU DU FORMULAIRE ========================================================= */
.relationship-form-panel {
    min-height: 720px;
    padding: 48px;
    background-color: #ffffff;
}

.relationship-form-heading {
    margin-bottom: 32px;
}

.relationship-form-eyebrow {
    margin-bottom: 7px;
    color: var(--relationship-primary);
    font-size: 0.85rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1.1px;
}

/* ========================================================= ERREURS ========================================================= */
.relationship-alert-error {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    margin-bottom: 25px;
    padding: 17px;
    color: #7d2e31;
    border: 1px solid rgba(166, 61, 64, 0.2);
    border-radius: 15px;
    background-color: rgba(166, 61, 64, 0.08);
}

.relationship-alert-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    color: var(--relationship-danger);
    border-radius: 12px;
    background-color: rgba(166, 61, 64, 0.12);
}

.relationship-alert-error p {
    margin-top: 3px;
    font-size: 0.9rem;
}

.relationship-field-error {
    display: block;
    margin-top: 7px;
    color: var(--relationship-danger);
    font-size: 0.85rem;
    font-weight: 600;
}

.relationship-col-2 {
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 100%
    );
}

/* ========================================================= CARTES PARENT ET ENFANT ========================================================= */
.relationship-field-card {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    height: 100%;
    padding: 18px;
    border: 1px solid var(--relationship-border);
    border-radius: 17px;
    background-color: var(--relationship-light);
}

.relationship-field-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 47px;
    height: 47px;
    color: var(--relationship-primary);
    font-size: 1.2rem;
    border-radius: 14px;
    background-color: rgba(82, 120, 83, 0.12);
}

.relationship-field-content {
    min-width: 0;
    flex-grow: 1;
}

/* ========================================================= CHAMPS ========================================================= */
.relationship-form .form-label {
    margin-bottom: 8px;
    color: var(--relationship-text);
    font-weight: 650;
}

.relationship-form .form-control, .relationship-form input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]), .relationship-form select, .relationship-form textarea {
    width: 100%;
    min-height: 50px;
    padding: 11px 15px;
    color: var(--relationship-text);
    border: 1px solid rgba(82, 120, 83, 0.25);
    border-radius: 13px;
    background-color: #fbfdfb;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.relationship-form textarea {
    min-height: 135px;
    resize: vertical;
}

.relationship-form .form-control:focus, .relationship-form input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]):focus, .relationship-form select:focus, .relationship-form textarea:focus {
    border-color: var(--relationship-primary);
    background-color: #ffffff;
    box-shadow: 0 0 0 0.25rem rgba(82, 120, 83, 0.13);
    outline: none;
}

.relationship-form-group {
    margin-top: 25px;
}

.relationship-help-text {
    margin-top: 7px;
    color: var(--relationship-muted);
    font-size: 0.82rem;
    line-height: 1.5;
}

/* ========================================================= REPRÉSENTATION VISUELLE ========================================================= */
.relationship-visual-separator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    margin: 30px 0 5px;
    padding: 16px;
    border: 1px dashed rgba(82, 120, 83, 0.25);
    border-radius: 16px;
    background-color: rgba(243, 247, 242, 0.65);
}

.relationship-visual-person {
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 4px;
    color: var(--relationship-primary-dark);
    font-size: 0.76rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.7px;
}

.relationship-visual-person i {
    font-size: 1.6rem;
}

.relationship-visual-line {
    display: flex;
    align-items: center;
    gap: 6px;
    color: var(--relationship-primary);
}

.relationship-visual-line span {
    width: 45px;
    height: 2px;
    background-color: rgba(82, 120, 83, 0.35);
}

/* ========================================================= ACTIONS ========================================================= */
.relationship-form-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 13px;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--relationship-border);
}

.btn-relationship-primary, .btn-relationship-outline {
    padding: 10px 21px;
    font-weight: 650;
    border-width: 2px;
    border-style: solid;
    border-radius: 12px;
    transition: all 0.25s ease;
}

.btn-relationship-primary {
    color: #ffffff;
    border-color: var(--relationship-primary);
    background-color: var(--relationship-primary);
    box-shadow: 0 8px 20px rgba(82, 120, 83, 0.18);
}

.btn-relationship-primary:hover, .btn-relationship-primary:focus {
    color: #ffffff;
    border-color: var(--relationship-primary-dark);
    background-color: var(--relationship-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(48, 77, 48, 0.22);
}

.btn-relationship-outline {
    color: var(--relationship-primary-dark);
    border-color: var(--relationship-primary);
    background-color: transparent;
}

.btn-relationship-outline:hover, .btn-relationship-outline:focus {
    color: #ffffff;
    border-color: var(--relationship-primary);
    background-color: var(--relationship-primary);
}

/* ========================================================= RESPONSIVE ========================================================= */
@media screen and (max-width: 991px) {
    .relationship-page-header {
        text-align: center;
    }

    .relationship-intro-panel {
        min-height: auto;
        padding: 42px 35px;
    }

    .relationship-intro-content {
        width: 100%;
    }

    .relationship-intro-icon {
        margin-right: auto;
        margin-left: auto;
    }

    .relationship-intro-eyebrow, .relationship-intro-content h2, .relationship-intro-text {
        text-align: center;
    }

    .relationship-form-panel {
        min-height: auto;
    }
}

@media screen and (max-width: 767px) {
    .relationship-form-panel {
        padding: 36px 25px;
    }

    .relationship-form-actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .relationship-form-actions .btn {
        width: 100%;
    }
}

@media screen and (max-width: 576px) {
    .relationship-logo-wrapper {
        width: 195px;
        height: 195px;
    }

    .relationship-logo {
        width: 145px;
        height: 145px;
    }

    .relationship-layout {
        border-radius: 20px;
    }

    .relationship-intro-panel {
        padding: 35px 21px;
    }

    .relationship-form-panel {
        padding: 32px 20px;
    }

    .relationship-field-card {
        flex-direction: column;
    }

    .relationship-field-icon {
        margin-right: auto;
        margin-left: auto;
    }

    .relationship-field-content {
        width: 100%;
    }

    .relationship-visual-separator {
        gap: 10px;
    }

    .relationship-visual-line span {
        width: 22px;
    }
}

/* ========================================================= FORMULAIRE PERSONNE ========================================================= */
:root {
    --person-form-primary: #527853;
    --person-form-primary-dark: #304d30;
    --person-form-secondary: #739072;
    --person-form-light: #f3f7f2;
    --person-form-cream: #f7f1e5;
    --person-form-white: #ffffff;
    --person-form-text: #263328;
    --person-form-muted: #6c757d;
    --person-form-danger: #a63d40;
    --person-form-warning: #c88b26;
    --person-form-border: rgba(82, 120, 83, 0.16);
}

/* ========================================================= EN-TÊTE ========================================================= */
.person-form-page-badge {
    display: inline-flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 8px 18px;
    color: var(--person-form-primary-dark);
    font-size: 0.88rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    border: 1px solid rgba(82, 120, 83, 0.2);
    border-radius: 50px;
    background-color: rgba(255, 255, 255, 0.75);
}

.person-form-page-title {
    color: var(--person-form-primary-dark);
}

.person-form-logo-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 220px;
    height: 220px;
    padding: 24px;
    border: 1px solid var(--person-form-border);
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.85);
    box-shadow: 0 25px 55px rgba(48, 77, 48, 0.16);
}

.person-form-logo {
    width: 165px;
    height: 165px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.person-form-logo-wrapper:hover .person-form-logo {
    transform: scale(1.05);
}

/* ========================================================= CONTENU ========================================================= */
.person-form-content {
    min-height: 75vh;
    background-color: var(--person-form-light);
}

.person-form-photo-card, .person-form-main-card, .person-form-biography-card {
    padding: 28px;
    border-radius: 22px;
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 100%
    );
}

.person-form-section-heading {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 27px;
}

.person-form-section-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    color: var(--person-form-primary);
    font-size: 1.5rem;
    border-radius: 16px;
    background-color: rgba(82, 120, 83, 0.12);
}

.person-form-eyebrow {
    color: var(--person-form-primary);
    font-size: 0.82rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1.1px;
}

/* ========================================================= PHOTO ========================================================= */
.person-form-photo-preview {
    position: relative;
    display: table;
    margin: 0 auto 25px;
}

.person-form-current-photo {
    width: 235px;
    height: 280px;
    padding: 5px;
    border: 3px solid rgba(82, 120, 83, 0.35);
    border-radius: 20px;
    object-fit: cover;
    background-color: #ffffff;
    box-shadow: 0 14px 30px rgba(48, 77, 48, 0.13);
}

.person-form-photo-badge {
    position: absolute;
    right: -8px;
    bottom: -8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 47px;
    height: 47px;
    color: #ffffff;
    border: 5px solid #ffffff;
    border-radius: 50%;
    background-color: var(--person-form-primary);
}

.person-form-photo-information {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    margin-top: 20px;
    padding: 15px;
    color: var(--person-form-muted);
    border: 1px solid var(--person-form-border);
    border-radius: 14px;
    background-color: var(--person-form-light);
    font-size: 0.85rem;
    line-height: 1.5;
}

.person-form-photo-information i {
    margin-top: 2px;
    color: var(--person-form-warning);
}

/* ========================================================= CHAMPS ========================================================= */
.person-form .form-label {
    margin-bottom: 8px;
    color: var(--person-form-text);
    font-weight: 650;
}

.person-form .form-control, .person-form input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]), .person-form select, .person-form textarea {
    width: 100%;
    min-height: 50px;
    padding: 11px 15px;
    color: var(--person-form-text);
    border: 1px solid rgba(82, 120, 83, 0.25);
    border-radius: 13px;
    background-color: #fbfdfb;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.person-form input[type="file"] {
    padding: 9px;
}

.person-form .form-control:focus, .person-form input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]):focus, .person-form select:focus, .person-form textarea:focus {
    border-color: var(--person-form-primary);
    background-color: #ffffff;
    box-shadow: 0 0 0 0.25rem rgba(82, 120, 83, 0.13);
    outline: none;
}

.person-form-field {
    height: 100%;
}

.person-form-required {
    color: var(--person-form-danger);
}

.person-form-help-text {
    margin-top: 7px;
    color: var(--person-form-muted);
    font-size: 0.82rem;
    line-height: 1.5;
}

.person-form-field-error {
    display: block;
    margin-top: 7px;
    color: var(--person-form-danger);
    font-size: 0.85rem;
    font-weight: 600;
}

/* ========================================================= CASES À COCHER ========================================================= */
.person-form-checkbox-card {
    padding: 17px;
    border: 1px solid var(--person-form-border);
    border-radius: 14px;
    background-color: var(--person-form-light);
}

.person-form-checkbox-card .form-check {
    display: flex;
    align-items: center;
    gap: 11px;
    min-height: 32px;
    padding-left: 0;
}

.person-form-checkbox-card .form-check-input {
    width: 46px;
    height: 24px;
    margin: 0;
    cursor: pointer;
}

.person-form-checkbox-card .form-check-input:checked {
    border-color: var(--person-form-primary);
    background-color: var(--person-form-primary);
}

.person-form-checkbox-card .form-check-input:focus {
    border-color: var(--person-form-primary);
    box-shadow: 0 0 0 0.25rem rgba(82, 120, 83, 0.13);
}

.person-form-checkbox-card .form-check-label {
    color: var(--person-form-text);
    font-weight: 650;
    cursor: pointer;
}

/* ========================================================= BIOGRAPHIE ET CKEDITOR ========================================================= */
.person-form-biography-card {
    overflow: visible;
}

.person-form-biography-field {
    width: 100%;
}

.person-form-biography-field .django-ckeditor-widget {
    width: 100%;
}

.person-form-biography-field .ck-editor {
    width: 100%;
}

.person-form-biography-field .ck-editor__editable {
    min-height: 320px;
    color: var(--person-form-text);
    border-color: rgba(82, 120, 83, 0.25) !important;
    background-color: #fbfdfb;
}

.person-form-biography-field .ck.ck-editor__main > .ck-editor__editable:focus {
    border-color: var(--person-form-primary) !important;
    box-shadow: 0 0 0 0.25rem rgba(82, 120, 83, 0.13);
}

.person-form-biography-field .ck.ck-toolbar {
    border-color: rgba(82, 120, 83, 0.25);
    border-radius: 13px 13px 0 0;
    background-color: var(--person-form-light);
}

.person-form-biography-field .ck.ck-editor__main > .ck-editor__editable {
    border-radius: 0 0 13px 13px;
}

/* ========================================================= ERREURS GÉNÉRALES ========================================================= */
.person-form-alert-error {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    margin-bottom: 25px;
    padding: 17px;
    color: #7d2e31;
    border: 1px solid rgba(166, 61, 64, 0.2);
    border-radius: 15px;
    background-color: rgba(166, 61, 64, 0.08);
}

.person-form-alert-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    color: var(--person-form-danger);
    border-radius: 12px;
    background-color: rgba(166, 61, 64, 0.12);
}

.person-form-alert-error p {
    margin-top: 3px;
    font-size: 0.9rem;
}

/* ========================================================= ACTIONS ========================================================= */
.person-form-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 30px;
    padding: 25px 28px;
    border: 1px solid var(--person-form-border);
    border-radius: 18px;
    background-color: #ffffff;
    box-shadow: 0 8px 24px rgba(48, 77, 48, 0.08);
}

.btn-person-form-primary, .btn-person-form-outline {
    padding: 11px 23px;
    font-weight: 650;
    border-width: 2px;
    border-style: solid;
    border-radius: 12px;
    transition: all 0.25s ease;
}

.btn-person-form-primary {
    color: #ffffff;
    border-color: var(--person-form-primary);
    background-color: var(--person-form-primary);
    box-shadow: 0 8px 20px rgba(82, 120, 83, 0.18);
}

.btn-person-form-primary:hover, .btn-person-form-primary:focus {
    color: #ffffff;
    border-color: var(--person-form-primary-dark);
    background-color: var(--person-form-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(48, 77, 48, 0.22);
}

.btn-person-form-outline {
    color: var(--person-form-primary-dark);
    border-color: var(--person-form-primary);
    background-color: transparent;
}

.btn-person-form-outline:hover, .btn-person-form-outline:focus {
    color: #ffffff;
    border-color: var(--person-form-primary);
    background-color: var(--person-form-primary);
}

/* ========================================================= RESPONSIVE ========================================================= */
@media screen and (max-width: 991px) {
    .person-form-header {
        text-align: center;
    }

    .person-form-current-photo {
        width: 220px;
        height: 260px;
    }
}

@media screen and (max-width: 767px) {
    .person-form-photo-card, .person-form-main-card, .person-form-biography-card {
        padding: 23px 19px;
        border-radius: 18px;
    }

    .person-form-section-heading {
        align-items: center;
    }

    .person-form-actions {
        align-items: stretch;
        flex-direction: column-reverse;
        padding: 22px 18px;
    }

    .person-form-actions .btn {
        width: 100%;
    }
}

@media screen and (max-width: 576px) {
    .person-form-logo-wrapper {
        width: 195px;
        height: 195px;
    }

    .person-form-logo {
        width: 145px;
        height: 145px;
    }

    .person-form-page-title {
        font-size: 2.2rem;
    }

    .person-form-current-photo {
        width: 190px;
        height: 230px;
    }

    .person-form-section-icon {
        width: 49px;
        height: 49px;
    }

    .person-form-biography-field .ck-editor__editable {
        min-height: 260px;
    }
}

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

:root {
    --contact-primary: #527853;
    --contact-primary-dark: #304d30;
    --contact-secondary: #739072;
    --contact-light: #f3f7f2;
    --contact-cream: #f7f1e5;
    --contact-white: #ffffff;
    --contact-text: #263328;
    --contact-muted: #6c757d;
    --contact-danger: #a63d40;
    --contact-border: rgba(82, 120, 83, 0.16);
}


/* Section générale */

/* =====================================================
   EN-TÊTE STANDARD DE L'APPLICATION
===================================================== */

.app-page-header {
    position: relative;
    overflow: hidden;
    isolation: isolate;

    background:
        radial-gradient(
            circle at top right,
            rgba(115, 144, 114, 0.25),
            transparent 38%
        ),
        linear-gradient(
            135deg,
            var(--profile-cream),
            var(--profile-light),
            #ffffff
        );
}

.app-page-decoration {
    position: absolute;
    pointer-events: none;
    border-radius: 50%;
    z-index: 0;
}

.app-page-decoration-left {
    top: -230px;
    left: -200px;
    width: 430px;
    height: 430px;
    background: rgba(82, 120, 83, 0.07);
}

.app-page-decoration-right {
    top: -130px;
    right: -100px;
    width: 340px;
    height: 340px;
    border: 45px solid rgba(82, 120, 83, 0.06);
}

.app-page-header > .container {
    position: relative;
    z-index: 1;
}


/* Titre */

.contact-subtitle {
    display: inline-flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 8px 18px;
    color: var(--contact-primary-dark);
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.3px;
    border: 1px solid rgba(82, 120, 83, 0.2);
    border-radius: 50px;
    background-color: rgba(255, 255, 255, 0.75);
}

.contact-title {
    color: var(--contact-primary-dark);
}


/* Conteneur */

.contact-layout {
    position: relative;
    z-index: 2;
    overflow: hidden;
    border: 1px solid var(--contact-border);
    border-radius: 30px;
    background-color: var(--contact-white);
}


/* Panneau de gauche */

.contact-info-panel {
    position: relative;
    display: flex;
    align-items: center;
    min-height: 720px;
    padding: 50px 38px;
    overflow: hidden;
    color: #ffffff;
    background: linear-gradient(
            145deg,
            rgba(48, 77, 48, 0.98),
            rgba(82, 120, 83, 0.94)
    );
}

.contact-info-panel::before {
    position: absolute;
    top: -90px;
    right: -90px;
    width: 250px;
    height: 250px;
    content: "";
    border: 35px solid rgba(255, 255, 255, 0.06);
    border-radius: 50%;
}

.contact-info-panel::after {
    position: absolute;
    bottom: -100px;
    left: -100px;
    width: 260px;
    height: 260px;
    content: "";
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.05);
}

.contact-info-content {
    position: relative;
    z-index: 2;
    width: 100%;
}

.contact-logo-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 135px;
    height: 135px;
    margin-bottom: 35px;
    padding: 14px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.94);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.2);
}

.contact-logo {
    width: 105px;
    height: 105px;
    object-fit: contain;
}

.contact-info-intro {
    margin-bottom: 35px;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.7;
}


/* Coordonnées */

.contact-details {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.contact-detail {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    color: #ffffff;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 16px;
    background-color: rgba(255, 255, 255, 0.08);
    transition: transform 0.25s ease,
    background-color 0.25s ease;
}

.contact-detail:hover {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.15);
    transform: translateX(5px);
}

.contact-detail-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 46px;
    height: 46px;
    font-size: 1.2rem;
    border-radius: 14px;
    background-color: rgba(255, 255, 255, 0.14);
}

.contact-detail-text {
    display: flex;
    min-width: 0;
    flex-direction: column;
}

.contact-detail-text small {
    color: rgba(255, 255, 255, 0.7);
}

.contact-detail-text strong {
    overflow-wrap: anywhere;
}

.contact-help-box {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-top: 35px;
    padding: 18px;
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.9rem;
    line-height: 1.6;
    border-radius: 16px;
    background-color: rgba(255, 255, 255, 0.08);
}

.contact-help-box i {
    margin-top: 3px;
}


/* Panneau du formulaire */
.contact-form-panel {
    min-height: 720px;
    padding: 50px;
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 100%
    );
}

.contact-form-heading {
    margin-bottom: 35px;
}

.contact-form-eyebrow {
    margin-bottom: 7px;
    color: var(--contact-primary);
    font-size: 0.85rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1.2px;
}


/* Champs */

.contact-form .form-label {
    margin-bottom: 8px;
    color: var(--contact-text);
    font-weight: 650;
}

.contact-form .form-control,
.contact-form input:not([type="checkbox"]):not([type="radio"]),
.contact-form select,
.contact-form textarea {
    width: 100%;
    min-height: 50px;
    padding: 11px 15px;
    color: var(--contact-text);
    border: 1px solid rgba(82, 120, 83, 0.25);
    border-radius: 13px;
    background-color: #fbfdfb;
    box-shadow: none;
    transition: border-color 0.2s ease,
    box-shadow 0.2s ease,
    background-color 0.2s ease;
}

.contact-form textarea {
    min-height: 150px;
    resize: vertical;
}

.contact-form .form-control:focus,
.contact-form input:not([type="checkbox"]):not([type="radio"]):focus,
.contact-form select:focus,
.contact-form textarea:focus {
    border-color: var(--contact-primary);
    background-color: #ffffff;
    box-shadow: 0 0 0 0.25rem rgba(82, 120, 83, 0.13);
    outline: none;
}

.contact-field-error {
    display: block;
    margin-top: 7px;
    color: var(--contact-danger);
    font-size: 0.85rem;
    font-weight: 600;
}


/* Captcha */

.contact-captcha {
    padding: 22px;
    border: 1px solid var(--contact-border);
    border-radius: 16px;
    background-color: var(--contact-light);
}

.contact-captcha-title {
    margin-bottom: 5px;
    color: var(--contact-primary-dark);
    font-weight: 700;
}

.contact-captcha-field {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.contact-captcha-field img {
    max-width: 100%;
    border: 1px solid var(--contact-border);
    border-radius: 8px;
}

.contact-captcha-field input {
    flex: 1;
    min-width: 180px;
}

.contact-privacy-text {
    color: var(--contact-muted);
    font-size: 0.85rem;
}


/* Responsive */

@media screen and (max-width: 991px) {

    .contact-layout {
        max-width: 760px;
        margin-right: auto;
        margin-left: auto;
    }

    .contact-info-panel {
        min-height: auto;
        padding: 45px 35px;
        text-align: center;
    }

    .contact-logo-wrapper {
        margin-right: auto;
        margin-left: auto;
    }

    .contact-info-intro {
        max-width: 600px;
        margin-right: auto;
        margin-left: auto;
    }

    .contact-details {
        max-width: 500px;
        margin-right: auto;
        margin-left: auto;
        text-align: left;
    }

    .contact-help-box {
        max-width: 500px;
        margin-right: auto;
        margin-left: auto;
        text-align: left;
    }

    .contact-form-panel {
        min-height: auto;
    }
}

@media screen and (max-width: 576px) {

    .contact-page .container {
        padding-right: 14px;
        padding-left: 14px;
    }

    .contact-layout {
        border-radius: 22px;
    }

    .contact-info-panel {
        padding: 38px 22px;
    }

    .contact-form-panel {
        padding: 35px 22px;
    }

    .contact-captcha-field {
        align-items: stretch;
        flex-direction: column;
    }

    .contact-captcha-field input {
        width: 100%;
        min-width: 0;
    }

    .btn-contact {
        width: 100%;
    }

    .contact-privacy-text {
        width: 100%;
        text-align: center;
    }
}

/* ========================================================= VARIABLES DE LA PAGE ARBRE ========================================================= */
:root {
    --tree-primary: #527853;
    --tree-primary-dark: #304d30;
    --tree-secondary: #739072;
    --tree-light: #f3f7f2;
    --tree-cream: #f7f1e5;
    --tree-white: #ffffff;
    --tree-text: #263328;
    --tree-muted: #6c757d;
    --tree-danger: #a63d40;
    --tree-warning: #c88b26;
    --tree-border: rgba(82, 120, 83, 0.17);
    --tree-line: rgba(82, 120, 83, 0.52);
    --tree-line-soft: rgba(82, 120, 83, 0.32);
    --tree-union: #b56b82;
    --tree-union-soft: rgba(181, 107, 130, 0.14);
}

/* ========================================================= EN-TÊTE DE LA PAGE ========================================================= */
.tree-page-badge {
    display: inline-flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 8px 18px;
    color: var(--tree-primary-dark);
    font-size: 0.88rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    border: 1px solid rgba(82, 120, 83, 0.2);
    border-radius: 50px;
    background-color: rgba(255, 255, 255, 0.75);
}

.tree-page-title {
    color: var(--tree-primary-dark);
}

.tree-root-person-name {
    color: var(--tree-primary-dark);
}

.tree-page-logo-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 220px;
    height: 220px;
    padding: 24px;
    border: 1px solid var(--tree-border);
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.85);
    box-shadow: 0 25px 55px rgba(48, 77, 48, 0.16);
}

.tree-page-logo {
    width: 165px;
    height: 165px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.tree-page-logo-wrapper:hover .tree-page-logo {
    transform: scale(1.05);
}

/* ========================================================= BARRE D'ACTIONS ========================================================= */
.tree-actions-section {
    background-color: var(--tree-light);
}

.tree-actions-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 25px;
    padding: 22px 25px;
    border: 1px solid var(--tree-border);
    border-radius: 20px;
    background-color: #ffffff;
    box-shadow: 0 10px 28px rgba(48, 77, 48, 0.08);
}

.tree-actions-information {
    display: flex;
    align-items: center;
    gap: 15px;
}

.tree-actions-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 55px;
    height: 55px;
    color: var(--tree-primary);
    font-size: 1.45rem;
    border-radius: 16px;
    background-color: rgba(82, 120, 83, 0.12);
}

.tree-actions-eyebrow, .tree-content-eyebrow {
    color: var(--tree-primary);
    font-size: 0.8rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1.1px;
}

.tree-actions-buttons {
    display: flex;
    align-items: center;
    flex: 0 0 auto;
    gap: 12px;
}

.btn-tree-primary, .btn-tree-outline {
    padding: 10px 20px;
    font-weight: 650;
    border-width: 2px;
    border-style: solid;
    border-radius: 12px;
    transition: color 0.25s ease, background-color 0.25s ease, border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

.btn-tree-primary {
    color: #ffffff;
    border-color: var(--tree-primary);
    background-color: var(--tree-primary);
    box-shadow: 0 8px 20px rgba(82, 120, 83, 0.18);
}

.btn-tree-primary:hover, .btn-tree-primary:focus {
    color: #ffffff;
    border-color: var(--tree-primary-dark);
    background-color: var(--tree-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(48, 77, 48, 0.22);
}

.btn-tree-outline {
    color: var(--tree-primary-dark);
    border-color: var(--tree-primary);
    background-color: transparent;
}

.btn-tree-outline:hover, .btn-tree-outline:focus {
    color: #ffffff;
    border-color: var(--tree-primary);
    background-color: var(--tree-primary);
}

/* ========================================================= CONTENU PRINCIPAL ========================================================= */
.tree-page-content {
    min-height: 65vh;
    background-color: var(--tree-light);
}

.tree-content-card {
    position: relative;
    overflow: hidden;
    padding: 28px;
    border: 1px solid var(--tree-border);
    border-radius: 24px;
    background: linear-gradient(rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.96)), radial-gradient(circle, rgba(82, 120, 83, 0.08) 1px, transparent 1px);
    background-size: auto, 24px 24px;
    box-shadow: 0 16px 40px rgba(48, 77, 48, 0.1);
}

.tree-content-heading {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 24px;
}

.tree-content-heading-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    color: var(--tree-primary);
    font-size: 1.55rem;
    border-radius: 16px;
    background-color: rgba(82, 120, 83, 0.12);
}

/* ========================================================= AIDE AU DÉFILEMENT ========================================================= */
.tree-scroll-help {
    display: none;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    padding: 12px 15px;
    color: var(--tree-primary-dark);
    border: 1px solid var(--tree-border);
    border-radius: 13px;
    background-color: var(--tree-light);
    font-size: 0.86rem;
}

.tree-scroll-help i {
    color: var(--tree-primary);
    font-size: 1.15rem;
}

/* =========================================================
   CONTENEUR GLOBAL DE L'ARBRE
========================================================= */

.genealogy-tree-page {
    width: 100%;
    min-height: 100vh;
    overflow-x: hidden;
}

.genealogy-tree-scroll {
    position: relative;

    width: 100%;
    max-width: 100%;
    min-height: 470px;

    padding: 40px 30px 100px;

    /* Défilement horizontal */
    overflow-x: auto;
    overflow-y: visible;

    /* Déplacement à la souris */
    cursor: grab;

    user-select: none;
    -webkit-user-select: none;

    scroll-behavior: auto;

    scrollbar-width: thin;
    scrollbar-color: var(--tree-secondary) var(--tree-light);

    -webkit-overflow-scrolling: touch;
}

/* Souris maintenue */
.genealogy-tree-scroll.is-dragging {
    cursor: grabbing;
}

/* Empêche la sélection pendant le déplacement */
.genealogy-tree-scroll.is-dragging,
.genealogy-tree-scroll.is-dragging * {
    user-select: none !important;
    -webkit-user-select: none !important;
}

/* Empêche les images de se déplacer nativement */
.genealogy-tree-scroll img {
    -webkit-user-drag: none;
    user-drag: none;
}

/* Scrollbar */
.genealogy-tree-scroll::-webkit-scrollbar {
    height: 12px;
}

.genealogy-tree-scroll::-webkit-scrollbar-track {
    border-radius: 20px;
    background-color: var(--tree-light);
}

.genealogy-tree-scroll::-webkit-scrollbar-thumb {
    border: 3px solid var(--tree-light);
    border-radius: 20px;
    background-color: var(--tree-secondary);
}

.genealogy-tree-scroll::-webkit-scrollbar-thumb:hover {
    background-color: var(--tree-primary);
}


/* =========================================================
   ARBRE
========================================================= */

.genealogy-tree {
    display: block;

    width: max-content;
    min-width: 100%;

    padding: 20px 60px;

    text-align: center;
}

.tree-root {
    display: flex;
    justify-content: center;

    width: max-content;
    min-width: 100%;

    margin: 0 auto;
    padding: 0;
}

/* ========================================================= LISTES ET NŒUDS DE L'ARBRE ========================================================= */
.genealogy-tree ul {
    margin: 0;
    padding-left: 0;
    list-style: none;
}

.tree-node {
    position: relative;
    display: flex;
    justify-content: center;
    min-width: max-content;
}

.tree-node-content {
    position: relative;
    display: flex;
    align-items: center;
    flex-direction: column;
}

/* ========================================================= CARTE PERSONNE ========================================================= */
.tree-person-card {
    position: relative;
    z-index: 5;
    width: 180px;
    min-height: 225px;
    overflow: hidden;
    border: 1px solid var(--tree-border);
    border-radius: 17px;
    background-color: var(--tree-white);
    box-shadow: 0 8px 22px rgba(48, 77, 48, 0.11);
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.tree-person-card:hover {
    z-index: 20;
    border-color: rgba(82, 120, 83, 0.5);
    transform: translateY(-5px);
    box-shadow: 0 15px 32px rgba(48, 77, 48, 0.18);
}

.tree-person-card:focus-within {
    border-color: var(--tree-primary);
    box-shadow: 0 15px 32px rgba(48, 77, 48, 0.18), 0 0 0 4px rgba(82, 120, 83, 0.12);
}

.tree-person-link {
    display: block;
    height: 100%;
    padding: 15px 13px;
    color: var(--tree-text);
    text-decoration: none;
}

.tree-person-link:hover, .tree-person-link:focus {
    color: var(--tree-text);
}

.tree-person-photo-wrapper {
    display: flex;
    justify-content: center;
}

.tree-person-photo {
    width: 96px;
    height: 96px;
    border: 4px solid rgba(82, 120, 83, 0.17);
    border-radius: 50%;
    object-fit: cover;
    object-position: center;
    background-color: var(--tree-light);
    box-shadow: 0 7px 17px rgba(48, 77, 48, 0.1);
}

.tree-person-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--tree-secondary);
    font-size: 2.5rem;
    background: linear-gradient(145deg, var(--tree-light), var(--tree-cream));
}

.tree-person-content {
    margin-top: 11px;
}

.tree-person-name {
    margin: 0;
    color: var(--tree-primary-dark);
    font-size: 0.98rem;
    font-weight: 700;
    line-height: 1.3;
}

.tree-person-birth-name {
    margin-top: 4px;
    color: var(--tree-muted);
    font-size: 0.75rem;
    line-height: 1.35;
}

.tree-person-dates {
    margin-top: 8px;
    color: var(--tree-muted);
    font-size: 0.78rem;
    line-height: 1.5;
}

.tree-date-symbol {
    display: inline-block;
    min-width: 14px;
    color: var(--tree-primary);
    font-weight: 700;
}

/* =========================================================
   IMPRESSION DE L'ARBRE
========================================================= */

@media print {

    /* Format paysage */
    @page {
        size: A4 landscape;
        margin: 10mm;
    }

    /* Cache les éléments inutiles */
    header,
    footer,
    .genealogy-navbar-wrapper,
    .tree-actions-section,
    .tree-scroll-help,
    .tree-content-heading {
        display: none !important;
    }

    /* Page */
    html,
    body {
        width: auto !important;
        height: auto !important;

        margin: 0 !important;
        padding: 0 !important;

        background: #ffffff !important;
    }

    /* Section principale */
    .tree-page-content {
        min-height: 0 !important;

        margin: 0 !important;
        padding: 0 !important;

        background: #ffffff !important;
    }

    .tree-page-content .container-fluid {
        width: auto !important;
        max-width: none !important;

        margin: 0 !important;
        padding: 0 !important;
    }

    /* Carte */
    .tree-content-card {
        width: auto !important;

        margin: 0 !important;
        padding: 0 !important;

        overflow: visible !important;

        border: 0 !important;
        border-radius: 0 !important;

        background: #ffffff !important;

        box-shadow: none !important;
    }

    /* Zone scrollable */
    .genealogy-tree-scroll {
        width: max-content !important;
        max-width: none !important;
        min-height: 0 !important;

        margin: 0 !important;
        padding: 10mm !important;

        overflow: visible !important;

        cursor: default !important;
    }

    /* Arbre complet */
    .genealogy-tree {
        width: max-content !important;
        min-width: 0 !important;

        margin: 0 auto !important;
        padding: 0 !important;
    }

    .tree-root {
        width: max-content !important;
        min-width: 0 !important;

        margin: 0 auto !important;
    }

}

/* ========================================================= PERSONNE PRINCIPALE ========================================================= */
.tree-main-person {
    position: relative;
    display: flex;
    align-items: center;
    flex-direction: column;
}

.tree-main-person > .tree-person-card {
    border-color: rgba(82, 120, 83, 0.42);
    box-shadow: 0 12px 28px rgba(48, 77, 48, 0.15), 0 0 0 5px rgba(82, 120, 83, 0.07);
}

.tree-main-person > .tree-person-card::before {
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 5px;
    content: "";
    background: linear-gradient(90deg, var(--tree-primary), var(--tree-secondary));
}

.tree-stop-indicator {
    margin-top: 9px;
    padding: 5px 10px;
    color: #74520b;
    font-size: 0.72rem;
    font-weight: 600;
    border: 1px solid rgba(200, 139, 38, 0.2);
    border-radius: 8px;
    background-color: rgba(255, 193, 7, 0.15);
}

/* ========================================================= FAMILLES ========================================================= */
.tree-families {
    position: relative;
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 55px;
    margin-top: 45px;
}

.tree-families::before {
    position: absolute;
    top: -45px;
    left: 50%;
    height: 45px;
    content: "";
    border-left: 2px solid var(--tree-line);
}

.tree-family {
    position: relative;
    display: flex;
    align-items: center;
    flex-direction: column;
    min-width: max-content;
    padding-top: 25px;
}

.tree-family::before {
    position: absolute;
    top: 0;
    left: 50%;
    height: 25px;
    content: "";
    border-left: 2px solid var(--tree-line);
}

.tree-family::after {
    position: absolute;
    top: 0;
    right: -27.5px;
    left: -27.5px;
    content: "";
    border-top: 2px solid var(--tree-line);
}

.tree-family:first-child::after {
    left: 50%;
}

.tree-family:last-child::after {
    right: 50%;
}

.tree-family:only-child::after {
    display: none;
}

/* ========================================================= COUPLE ET UNION ========================================================= */
.tree-couple-row {
    display: flex;
    align-items: center;
    justify-content: center;
}

.tree-current-person-reference {
    display: none;
}

.tree-union-connector {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 85px;
}

.tree-union-line {
    width: 28px;
    border-top: 2px solid var(--tree-union);
}

.tree-union-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 31px;
    height: 31px;
    color: var(--tree-union);
    font-size: 0.9rem;
    border: 1px solid rgba(181, 107, 130, 0.35);
    border-radius: 50%;
    background-color: var(--tree-white);
    box-shadow: 0 4px 10px rgba(181, 107, 130, 0.12);
}

.tree-unknown-parent {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    width: 160px;
    min-height: 115px;
    margin-left: 45px;
    padding: 12px;
    color: var(--tree-muted);
    font-size: 0.8rem;
    border: 1px dashed rgba(82, 120, 83, 0.42);
    border-radius: 14px;
    background-color: var(--tree-light);
}

.tree-unknown-parent i {
    margin-bottom: 6px;
    color: var(--tree-secondary);
    font-size: 1.5rem;
}

/* ========================================================= INFORMATIONS SUR L'UNION ========================================================= */
.tree-union-details {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px 14px;
    max-width: 370px;
    margin-top: 11px;
    padding: 7px 11px;
    color: var(--tree-muted);
    font-size: 0.72rem;
    border: 1px solid rgba(181, 107, 130, 0.14);
    border-radius: 9px;
    background-color: var(--tree-union-soft);
}

.tree-union-details i {
    color: var(--tree-union);
}

/* ========================================================= DESCENDANCE ET ENFANTS ========================================================= */
.tree-descent-line {
    height: 35px;
    margin-top: 10px;
    border-left: 2px solid var(--tree-line);
}

.tree-children {
    position: relative;
    display: flex;
    justify-content: center;
    gap: 38px;
    padding-top: 35px !important;
}

.tree-children::before {
    position: absolute;
    top: 0;
    left: 50%;
    height: 35px;
    content: "";
    border-left: 2px solid var(--tree-line);
}

.tree-children > .tree-node {
    padding-top: 35px;
}

.tree-children > .tree-node::before, .tree-children > .tree-node::after {
    position: absolute;
    top: 0;
    width: 50%;
    height: 35px;
    content: "";
    border-top: 2px solid var(--tree-line);
}

.tree-children > .tree-node::before {
    right: 50%;
}

.tree-children > .tree-node::after {
    left: 50%;
    border-left: 2px solid var(--tree-line);
}

.tree-children > .tree-node:first-child::before {
    border-top: 0;
}

.tree-children > .tree-node:last-child::after {
    border-top: 0;
}

.tree-children > .tree-node:only-child::before, .tree-children > .tree-node:only-child::after {
    display: none;
}

.tree-children > .tree-node:only-child {
    padding-top: 0;
}

.tree-no-child {
    margin-top: 14px;
    color: var(--tree-muted);
    font-size: 0.75rem;
    font-style: italic;
}

/* ========================================================= AMÉLIORATION DES LIGNES DANS LES ANGLES ========================================================= */
.tree-family:first-child::after, .tree-children > .tree-node:first-child::after {
    border-radius: 8px 0 0 0;
}

.tree-family:last-child::before, .tree-children > .tree-node:last-child::before {
    border-radius: 0 8px 0 0;
}

/* ========================================================= RESPONSIVE TABLETTE ========================================================= */
@media screen and (max-width: 991px) {
    .tree-page-header {
        text-align: center;
    }

    .tree-actions-card {
        align-items: stretch;
        flex-direction: column;
    }

    .tree-actions-buttons {
        justify-content: center;
    }

    .tree-scroll-help {
        display: flex;
    }

    .tree-content-card {
        padding-right: 18px;
        padding-left: 18px;
    }
}

/* ========================================================= RESPONSIVE MOBILE ========================================================= */
@media screen and (max-width: 768px) {
    .tree-content-card {
        padding: 22px 10px;
        border-radius: 18px;
    }

    .tree-content-heading {
        padding-right: 10px;
        padding-left: 10px;
    }

    .tree-actions-information {
        align-items: flex-start;
    }

    .tree-actions-buttons {
        align-items: stretch;
        flex-direction: column;
    }

    .tree-actions-buttons .btn {
        width: 100%;
    }

    .genealogy-tree-scroll {
        min-height: 420px;
        padding-right: 5px;
        padding-left: 5px;
    }

    .genealogy-tree {
        padding-right: 25px;
        padding-left: 25px;
    }

    .tree-person-card {
        width: 150px;
        min-height: 195px;
        border-radius: 14px;
    }

    .tree-person-link {
        padding: 12px 10px;
    }

    .tree-person-photo {
        width: 76px;
        height: 76px;
    }

    .tree-person-name {
        font-size: 0.9rem;
    }

    .tree-person-birth-name, .tree-person-dates {
        font-size: 0.7rem;
    }

    .tree-families {
        gap: 30px;
    }

    .tree-family::after {
        right: -15px;
        left: -15px;
    }

    .tree-family:first-child::after {
        left: 50%;
    }

    .tree-family:last-child::after {
        right: 50%;
    }

    .tree-union-connector {
        min-width: 58px;
    }

    .tree-union-line {
        width: 14px;
    }

    .tree-union-icon {
        width: 28px;
        height: 28px;
        font-size: 0.78rem;
    }

    .tree-children {
        gap: 22px;
    }

    .tree-unknown-parent {
        width: 135px;
        min-height: 100px;
        margin-left: 25px;
    }
}

/* ========================================================= TRÈS PETITS ÉCRANS ========================================================= */
@media screen and (max-width: 576px) {
    .tree-page-logo-wrapper {
        width: 195px;
        height: 195px;
    }

    .tree-page-logo {
        width: 145px;
        height: 145px;
    }

    .tree-page-title {
        font-size: 2.2rem;
    }

    .tree-actions-card {
        padding: 20px 17px;
    }

    .tree-actions-information {
        flex-direction: column;
    }

    .tree-content-heading {
        align-items: flex-start;
    }

    .tree-content-heading-icon {
        width: 49px;
        height: 49px;
        font-size: 1.35rem;
    }

    .genealogy-tree {
        padding-right: 18px;
        padding-left: 18px;
    }

    .tree-person-card {
        width: 140px;
        min-height: 188px;
    }

    .tree-person-photo {
        width: 70px;
        height: 70px;
    }

    .tree-families {
        gap: 24px;
    }

    .tree-children {
        gap: 18px;
    }

    .tree-union-connector {
        min-width: 48px;
    }

    .tree-union-line {
        width: 10px;
    }

    .tree-unknown-parent {
        width: 125px;
        margin-left: 18px;
    }
}

/* ========================================================= MODE SOMBRE BOOTSTRAP ========================================================= */
[data-bs-theme="dark"] .tree-content-card, [data-bs-theme="dark"] .tree-actions-card, [data-bs-theme="dark"] .tree-person-card, [data-bs-theme="dark"] .tree-union-icon {
    background-color: var(--bs-body-bg);
}

[data-bs-theme="dark"] .tree-content-card {
    background: linear-gradient(rgba(33, 37, 41, 0.96), rgba(33, 37, 41, 0.96)), radial-gradient(circle, rgba(115, 144, 114, 0.12) 1px, transparent 1px);
    background-size: auto, 24px 24px;
}

[data-bs-theme="dark"] .tree-person-name, [data-bs-theme="dark"] .tree-person-link {
    color: var(--bs-body-color);
}

[data-bs-theme="dark"] .tree-unknown-parent {
    background-color: var(--bs-tertiary-bg);
}

[data-bs-theme="dark"] .tree-union-details {
    background-color: rgba(181, 107, 130, 0.12);
}


/* ========================================================= VARIABLES ========================================================= */
:root {
    --union-form-primary: #527853;
    --union-form-primary-dark: #304d30;
    --union-form-secondary: #739072;
    --union-form-light: #f3f7f2;
    --union-form-cream: #f7f1e5;
    --union-form-white: #ffffff;
    --union-form-text: #263328;
    --union-form-muted: #6c757d;
    --union-form-danger: #a63d40;
    --union-form-pink: #b56b82;
    --union-form-pink-light: rgba(181, 107, 130, 0.12);
    --union-form-border: rgba(82, 120, 83, 0.17);
}

/* ========================================================= EN-TÊTE ========================================================= */

.union-form-page-badge {
    display: inline-flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 8px 18px;
    color: var(--union-form-primary-dark);
    font-size: 0.88rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    border: 1px solid rgba(82, 120, 83, 0.2);
    border-radius: 50px;
    background-color: rgba(255, 255, 255, 0.75);
}

.union-form-page-badge i {
    color: var(--union-form-pink);
}

.union-form-page-title {
    color: var(--union-form-primary-dark);
}

.union-form-logo-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 220px;
    height: 220px;
    padding: 24px;
    border: 1px solid var(--union-form-border);
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.85);
    box-shadow: 0 25px 55px rgba(48, 77, 48, 0.16);
}

.union-form-logo {
    width: 165px;
    height: 165px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.union-form-logo-wrapper:hover .union-form-logo {
    transform: scale(1.05);
}

/* ========================================================= CONTENU ========================================================= */
.union-form-content {
    min-height: 75vh;
    background-color: var(--union-form-light);
}

.union-form-information-card, .union-form-card {
    padding: 28px;
    border-radius: 22px;
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 100%
    );
}

.union-form-information-card {
    position: sticky;
    top: 100px;
}

.union-form-information-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 95px;
    height: 95px;
    margin: 0 auto;
    color: var(--union-form-pink);
    font-size: 2.6rem;
    border: 1px solid rgba(181, 107, 130, 0.2);
    border-radius: 50%;
    background: linear-gradient(145deg, var(--union-form-pink-light), rgba(82, 120, 83, 0.08));
}

/* ========================================================= PANNEAU D'AIDE ========================================================= */
.union-form-help-list {
    display: flex;
    flex-direction: column;
    gap: 13px;
    margin-top: 25px;
}

.union-form-help-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 15px;
    border: 1px solid var(--union-form-border);
    border-radius: 14px;
    background-color: var(--union-form-light);
}

.union-form-help-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    color: var(--union-form-primary);
    font-size: 1.1rem;
    border-radius: 12px;
    background-color: rgba(82, 120, 83, 0.12);
}

.union-form-help-item strong {
    display: block;
    margin-bottom: 3px;
    color: var(--union-form-primary-dark);
    font-size: 0.92rem;
}

.union-form-help-item p {
    color: var(--union-form-muted);
    font-size: 0.82rem;
    line-height: 1.5;
}

/* ========================================================= SECTIONS DU FORMULAIRE ========================================================= */
.union-form-section {
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid var(--union-form-border);
}

.union-form-section-heading {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 25px;
}

.union-form-section-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 55px;
    height: 55px;
    color: var(--union-form-primary);
    font-size: 1.45rem;
    border-radius: 16px;
    background-color: rgba(82, 120, 83, 0.12);
}

.union-form-section-icon-muted {
    color: var(--union-form-muted);
    background-color: rgba(108, 117, 125, 0.11);
}

.union-form-eyebrow {
    color: var(--union-form-primary);
    font-size: 0.8rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1.1px;
}

/* ========================================================= PARTENAIRES ========================================================= */
.union-form-partners {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    align-items: end;
    gap: 15px;
}

.union-form-partner-field {
    min-width: 0;
}

.union-form-partner-connector {
    display: flex;
    align-items: center;
    justify-content: center;
    padding-bottom: 12px;
}

.union-form-connector-line {
    width: 20px;
    border-top: 2px solid var(--union-form-pink);
}

.union-form-connector-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 37px;
    height: 37px;
    color: var(--union-form-pink);
    font-size: 1rem;
    border: 1px solid rgba(181, 107, 130, 0.3);
    border-radius: 50%;
    background-color: var(--union-form-white);
    box-shadow: 0 5px 12px rgba(181, 107, 130, 0.12);
}

/* ========================================================= CHAMPS ========================================================= */
.union-form-card .form-label {
    margin-bottom: 8px;
    color: var(--union-form-text);
    font-weight: 650;
}

.union-form-card .form-control, .union-form-card .form-select, .union-form-card input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]), .union-form-card select, .union-form-card textarea {
    width: 100%;
    min-height: 50px;
    padding: 11px 15px;
    color: var(--union-form-text);
    border: 1px solid rgba(82, 120, 83, 0.25);
    border-radius: 13px;
    background-color: #fbfdfb;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.union-form-card .form-control:focus, .union-form-card .form-select:focus, .union-form-card input:not([type="hidden"]):not([type="checkbox"]):not([type="radio"]):focus, .union-form-card select:focus, .union-form-card textarea:focus {
    border-color: var(--union-form-primary);
    background-color: var(--union-form-white);
    box-shadow: 0 0 0 0.25rem rgba(82, 120, 83, 0.13);
    outline: none;
}

.union-form-required {
    color: var(--union-form-danger);
}

.union-form-help-text {
    margin-top: 7px;
    color: var(--union-form-muted);
    font-size: 0.82rem;
    line-height: 1.5;
}

.union-form-field-error {
    display: block;
    margin-top: 7px;
    color: var(--union-form-danger);
    font-size: 0.85rem;
    font-weight: 600;
}

/* ========================================================= ICÔNES DANS LES CHAMPS ========================================================= */
.union-form-input-icon {
    position: relative;
}

.union-form-input-icon > i {
    position: absolute;
    top: 50%;
    left: 15px;
    z-index: 3;
    color: var(--union-form-secondary);
    pointer-events: none;
    transform: translateY(-50%);
}

.union-form-input-icon input {
    padding-left: 43px !important;
}

/* ========================================================= NOTES ET CKEDITOR ========================================================= */
.union-form-notes-field {
    width: 100%;
}

.union-form-notes-field .django-ckeditor-widget {
    width: 100%;
}

.union-form-notes-field .ck-editor {
    width: 100%;
}

.union-form-notes-field .ck-editor__editable {
    min-height: 260px;
    color: var(--union-form-text);
    border-color: rgba(82, 120, 83, 0.25) !important;
    background-color: #fbfdfb;
}

.union-form-notes-field .ck.ck-toolbar {
    border-color: rgba(82, 120, 83, 0.25);
    border-radius: 13px 13px 0 0;
    background-color: var(--union-form-light);
}

.union-form-notes-field .ck.ck-editor__main > .ck-editor__editable {
    border-radius: 0 0 13px 13px;
}

.union-form-notes-field .ck.ck-editor__main > .ck-editor__editable:focus {
    border-color: var(--union-form-primary) !important;
    box-shadow: 0 0 0 0.25rem rgba(82, 120, 83, 0.13);
}

/* ========================================================= ERREURS GÉNÉRALES ========================================================= */
.union-form-alert-error {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    margin-bottom: 26px;
    padding: 17px;
    color: #7d2e31;
    border: 1px solid rgba(166, 61, 64, 0.2);
    border-radius: 15px;
    background-color: rgba(166, 61, 64, 0.08);
}

.union-form-alert-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    color: var(--union-form-danger);
    border-radius: 12px;
    background-color: rgba(166, 61, 64, 0.12);
}

.union-form-alert-error p {
    margin-top: 3px;
    font-size: 0.9rem;
}

/* ========================================================= ACTIONS ========================================================= */
.union-form-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid var(--union-form-border);
}

.btn-union-form-primary, .btn-union-form-outline {
    padding: 11px 23px;
    font-weight: 650;
    border-width: 2px;
    border-style: solid;
    border-radius: 12px;
    transition: color 0.25s ease, background-color 0.25s ease, border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

.btn-union-form-primary {
    color: var(--union-form-white);
    border-color: var(--union-form-primary);
    background-color: var(--union-form-primary);
    box-shadow: 0 8px 20px rgba(82, 120, 83, 0.18);
}

.btn-union-form-primary:hover, .btn-union-form-primary:focus {
    color: var(--union-form-white);
    border-color: var(--union-form-primary-dark);
    background-color: var(--union-form-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(48, 77, 48, 0.22);
}

.btn-union-form-outline {
    color: var(--union-form-primary-dark);
    border-color: var(--union-form-primary);
    background-color: transparent;
}

.btn-union-form-outline:hover, .btn-union-form-outline:focus {
    color: var(--union-form-white);
    border-color: var(--union-form-primary);
    background-color: var(--union-form-primary);
}

/* ========================================================= RESPONSIVE ========================================================= */
@media screen and (max-width: 991px) {
    .union-form-header {
        text-align: center;
    }

    .union-form-information-card {
        position: static;
    }
}

@media screen and (max-width: 767px) {
    .union-form-information-card, .union-form-card {
        padding: 23px 19px;
        border-radius: 18px;
    }

    .union-form-partners {
        grid-template-columns: 1fr;
        align-items: stretch;
    }

    .union-form-partner-connector {
        padding: 0;
        transform: rotate(90deg);
    }

    .union-form-section-heading {
        align-items: center;
    }

    .union-form-actions {
        align-items: stretch;
        flex-direction: column-reverse;
    }

    .union-form-actions .btn {
        width: 100%;
    }
}

@media screen and (max-width: 576px) {
    .union-form-logo-wrapper {
        width: 195px;
        height: 195px;
    }

    .union-form-logo {
        width: 145px;
        height: 145px;
    }

    .union-form-page-title {
        font-size: 2.2rem;
    }

    .union-form-information-icon {
        width: 82px;
        height: 82px;
        font-size: 2.2rem;
    }

    .union-form-section-icon {
        width: 49px;
        height: 49px;
        font-size: 1.3rem;
    }

    .union-form-notes-field .ck-editor__editable {
        min-height: 230px;
    }
}

/* ========================================================= PAGE DE CONFIRMATION ========================================================= */
:root {
    --confirmation-primary: #527853;
    --confirmation-primary-dark: #304d30;
    --confirmation-secondary: #739072;
    --confirmation-light: #f3f7f2;
    --confirmation-cream: #f7f1e5;
    --confirmation-white: #ffffff;
    --confirmation-text: #263328;
    --confirmation-muted: #6c757d;
    --confirmation-border: rgba(82, 120, 83, 0.18);
}

.confirmation-page {
    position: relative;
    min-height: 100vh;
    overflow: hidden;
    background: radial-gradient(circle at top right, rgba(115, 144, 114, 0.24), transparent 38%), linear-gradient(135deg, var(--confirmation-cream), var(--confirmation-light), #ffffff);
}

.confirmation-decoration {
    position: absolute;
    pointer-events: none;
    border-radius: 50%;
}

.confirmation-decoration-left {
    bottom: -180px;
    left: -150px;
    width: 430px;
    height: 430px;
    background-color: rgba(82, 120, 83, 0.07);
}

.confirmation-decoration-right {
    top: -130px;
    right: -100px;
    width: 340px;
    height: 340px;
    border: 45px solid rgba(82, 120, 83, 0.06);
}

.confirmation-card {
    position: relative;
    z-index: 2;
    padding: 45px 38px 38px;
    text-align: center;
    border: 1px solid var(--confirmation-border);
    border-radius: 26px;
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 60%
    );
    box-shadow: 0 24px 55px rgba(48, 77, 48, 0.15);
}

.confirmation-icon-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 22px;
}

.confirmation-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 92px;
    height: 92px;
    color: var(--confirmation-white);
    font-size: 2.8rem;
    border: 8px solid rgba(82, 120, 83, 0.12);
    border-radius: 50%;
    background: linear-gradient(145deg, var(--confirmation-secondary), var(--confirmation-primary-dark));
    box-shadow: 0 14px 30px rgba(48, 77, 48, 0.22);
}

.confirmation-badge {
    display: inline-flex;
    align-items: center;
    margin-bottom: 16px;
    padding: 8px 17px;
    color: var(--confirmation-primary-dark);
    font-size: 0.82rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: 1px solid var(--confirmation-border);
    border-radius: 50px;
    background-color: var(--confirmation-light);
}

.confirmation-title {
    margin-bottom: 12px;
    color: var(--confirmation-primary-dark);
    font-size: 2.5rem;
    font-weight: 750;
}

.confirmation-lead {
    margin-bottom: 24px;
    color: var(--confirmation-text);
    font-size: 1.15rem;
    font-weight: 600;
}

.confirmation-message {
    margin-bottom: 30px;
    padding: 20px;
    color: var(--confirmation-muted);
    line-height: 1.7;
    border: 1px solid var(--confirmation-border);
    border-radius: 16px;
    background-color: var(--confirmation-light);
}

.confirmation-message p {
    margin-bottom: 8px;
}

.confirmation-actions {
    display: flex;
    justify-content: center;
}

.btn-confirmation-primary {
    padding: 11px 24px;
    color: var(--confirmation-white);
    font-weight: 650;
    border: 2px solid var(--confirmation-primary);
    border-radius: 12px;
    background-color: var(--confirmation-primary);
    box-shadow: 0 8px 20px rgba(82, 120, 83, 0.18);
    transition: color 0.25s ease, background-color 0.25s ease, border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
}

.btn-confirmation-primary:hover, .btn-confirmation-primary:focus {
    color: var(--confirmation-white);
    border-color: var(--confirmation-primary-dark);
    background-color: var(--confirmation-primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(48, 77, 48, 0.23);
}

@media screen and (max-width: 767px) {
    .confirmation-card {
        padding: 38px 22px 30px;
        border-radius: 20px;
    }

    .confirmation-icon {
        width: 80px;
        height: 80px;
        font-size: 2.3rem;
    }

    .confirmation-title {
        font-size: 2rem;
    }

    .confirmation-lead {
        font-size: 1.05rem;
    }

    .btn-confirmation-primary {
        width: 100%;
    }
}

@media screen and (max-width: 576px) {
    .confirmation-card {
        padding-right: 18px;
        padding-left: 18px;
    }

    .confirmation-title {
        font-size: 1.8rem;
    }

    .confirmation-message {
        padding: 17px 14px;
    }
}


/* ========================================================= VARIABLES ========================================================= */
:root {
    --footer-primary: #527853;
    --footer-primary-dark: #304d30;
    --footer-secondary: #739072;
    --footer-light: #f3f7f2;
    --footer-cream: #f7f1e5;
    --footer-white: #ffffff;
    --footer-text: #eef4ed;
    --footer-muted: rgba(238, 244, 237, 0.72);
    --footer-border: rgba(255, 255, 255, 0.14);
}

/* ========================================================= STRUCTURE GÉNÉRALE ========================================================= */
.genealogy-footer {
    position: relative;
    overflow: hidden;
    color: var(--footer-text);
    background: radial-gradient(circle at top right, rgba(115, 144, 114, 0.45), transparent 34%), linear-gradient(135deg, #253c29, var(--footer-primary-dark), #1e3022);
}

.genealogy-footer::before {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--footer-secondary), var(--footer-cream), var(--footer-secondary));
}

.genealogy-footer-decoration {
    position: absolute;
    pointer-events: none;
    border-radius: 50%;
}

.genealogy-footer-decoration-left {
    bottom: -220px;
    left: -170px;
    width: 470px;
    height: 470px;
    border: 65px solid rgba(255, 255, 255, 0.035);
}

.genealogy-footer-decoration-right {
    top: -190px;
    right: -130px;
    width: 420px;
    height: 420px;
    background-color: rgba(255, 255, 255, 0.025);
}

/* ========================================================= IDENTITÉ DU SITE ========================================================= */
.genealogy-footer-brand {
    display: flex;
    align-items: flex-start;
    gap: 20px;
}

.genealogy-footer-logo-link {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 115px;
    height: 115px;
    padding: 13px;
    border: 1px solid var(--footer-border);
    border-radius: 24px;
    background-color: rgba(255, 255, 255, 0.92);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.18);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.genealogy-footer-logo-link:hover {
    transform: translateY(-4px);
    box-shadow: 0 19px 42px rgba(0, 0, 0, 0.24);
}

.genealogy-footer-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.genealogy-footer-brand-title {
    margin-bottom: 11px;
    color: var(--footer-white);
    font-size: 1.45rem;
    font-weight: 750;
}

.genealogy-footer-brand-text {
    max-width: 300px;
    margin-bottom: 0;
    color: var(--footer-muted);
    font-size: 0.92rem;
    line-height: 1.7;
}

.genealogy-footer-brand-newsletter {
    max-width: 400px;
    margin-bottom: 0;
    color: var(--footer-muted);
    font-size: 0.92rem;
    line-height: 1.7;
}

/* ========================================================= TITRES ET LIENS ========================================================= */
.genealogy-footer-section {
    height: 100%;
}

.genealogy-footer-title {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
    color: var(--footer-white);
    font-size: 1rem;
    font-weight: 750;
    letter-spacing: 0.2px;
}

.genealogy-footer-title i {
    color: #b8d2b6;
}

.genealogy-footer-links {
    display: flex;
    flex-direction: column;
    gap: 11px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.genealogy-footer-links a, .genealogy-footer-link-button {
    display: inline-flex;
    align-items: flex-start;
    gap: 5px;
    padding: 0;
    color: var(--footer-muted);
    font-size: 0.91rem;
    line-height: 1.55;
    text-align: left;
    text-decoration: none;
    border: 0;
    background: transparent;
    transition: color 0.2s ease, transform 0.2s ease;
}

.genealogy-footer-links a i, .genealogy-footer-link-button i {
    margin-top: 4px;
    color: #a9c4a7;
    font-size: 0.72rem;
    transition: transform 0.2s ease;
}

.genealogy-footer-links a:hover, .genealogy-footer-links a:focus, .genealogy-footer-link-button:hover, .genealogy-footer-link-button:focus {
    color: var(--footer-white);
    transform: translateX(4px);
}

.genealogy-footer-links a:hover i, .genealogy-footer-link-button:hover i {
    transform: translateX(2px);
}

/* ========================================================= ENCADRÉ CONFIDENTIALITÉ ========================================================= */
.genealogy-footer-security {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    margin-top: 23px;
    padding: 14px;
    color: var(--footer-muted);
    font-size: 0.8rem;
    line-height: 1.5;
    border: 1px solid var(--footer-border);
    border-radius: 14px;
    background-color: rgba(255, 255, 255, 0.055);
}

.genealogy-footer-security-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    color: #c4d8c2;
    border-radius: 10px;
    background-color: rgba(255, 255, 255, 0.09);
}

/* ========================================================= BAS DU FOOTER ========================================================= */
.genealogy-footer-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 42px;
    padding-top: 24px;
    color: var(--footer-muted);
    font-size: 0.84rem;
    border-top: 1px solid var(--footer-border);
}

.genealogy-footer-credit {
    text-align: right;
}

.genealogy-footer-credit a {
    color: #d7e7d5;
    font-weight: 650;
    text-decoration: none;
}

.genealogy-footer-credit a:hover {
    color: var(--footer-white);
    text-decoration: underline;
}

/* ========================================================= MODAL RGPD ========================================================= */
.genealogy-policy-modal .modal-content {
    overflow: hidden;
    border: 1px solid rgba(82, 120, 83, 0.2);
    border-radius: 22px;
    box-shadow: 0 28px 70px rgba(34, 52, 36, 0.25);
}

.genealogy-policy-modal .modal-header {
    padding: 22px 25px;
    border-bottom: 1px solid rgba(82, 120, 83, 0.15);
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 60%
    );;
}

.genealogy-policy-modal .modal-title {
    color: var(--footer-primary-dark);
    font-weight: 750;
}

.genealogy-policy-modal-icon {
    display: inline-flex;
    flex: 0 0 auto;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    color: var(--footer-white);
    font-size: 1.35rem;
    border-radius: 15px;
    background: linear-gradient(145deg, var(--footer-secondary), var(--footer-primary-dark));
    box-shadow: 0 8px 18px rgba(48, 77, 48, 0.18);
}

.genealogy-policy-modal-eyebrow {
    color: var(--footer-primary);
    font-size: 0.74rem;
    font-weight: 750;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.genealogy-policy-modal .modal-body {
    padding: 28px;
    color: #2d382f;
    background: linear-gradient(
        80deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 100%
    );
}

.genealogy-policy-content {
    line-height: 1.75;
}

.genealogy-policy-content h1, .genealogy-policy-content h2, .genealogy-policy-content h3, .genealogy-policy-content h4 {
    margin-top: 1.5rem;
    margin-bottom: 0.8rem;
    color: var(--footer-primary-dark);
}

.genealogy-policy-content a {
    color: var(--footer-primary);
    font-weight: 650;
}

.genealogy-policy-content ul, .genealogy-policy-content ol {
    padding-left: 1.4rem;
}

.genealogy-policy-empty {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px;
    color: #5d6c60;
    border: 1px solid rgba(82, 120, 83, 0.18);
    border-radius: 14px;
    background-color: var(--footer-light);
}

.genealogy-policy-empty i {
    color: var(--footer-primary);
    font-size: 1.4rem;
}

.genealogy-policy-modal .modal-footer {
    padding: 18px 25px;
    border-top: 1px solid rgba(82, 120, 83, 0.15);
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 60%
    );;
}

.genealogy-policy-date {
    color: #69766b;
    font-size: 0.82rem;
}

.btn-footer-modal-close {
    padding: 10px 21px;
    color: var(--footer-white);
    font-weight: 650;
    border: 2px solid var(--footer-primary);
    border-radius: 11px;
    background-color: var(--footer-primary);
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.btn-footer-modal-close:hover, .btn-footer-modal-close:focus {
    color: var(--footer-white);
    border-color: var(--footer-primary-dark);
    background-color: var(--footer-primary-dark);
    transform: translateY(-1px);
}


/* =============================================== Page ajouter Arbre ========================================= */
.genealogy-page-wrapper {
	background:
		linear-gradient(
			180deg,
			rgba(243, 248, 244, 0.95) 0%,
			rgba(255, 255, 255, 1) 45%
		);
}

.genealogy-page-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 76px;
	height: 76px;
	border-radius: 50%;
	background: rgba(45, 108, 70, 0.12);
	color: #2d6c46;
	font-size: 2rem;
	box-shadow: 0 10px 30px rgba(45, 108, 70, 0.12);
}

.genealogy-page-kicker {
	color: #2d6c46;
	font-size: 0.82rem;
	font-weight: 700;
	letter-spacing: 0.12em;
	text-transform: uppercase;
}

.genealogy-page-title {
	color: #23362b;
	font-size: clamp(2rem, 4vw, 3rem);
	font-weight: 700;
}

.genealogy-page-description {
	max-width: 650px;
	color: #6c757d;
	font-size: 1rem;
	line-height: 1.7;
}

.genealogy-form-card {
	border-radius: 22px;
	overflow: hidden;
	background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 100%
    );
}

.genealogy-form-card-header {
	padding: 1.5rem 2rem;
	background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 60%
    );
	border-bottom: 1px solid rgba(45, 108, 70, 0.12);
}

.genealogy-form-card-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 50px;
	height: 50px;
	flex-shrink: 0;
	border-radius: 14px;
	background: #2d6c46;
	color: #ffffff;
	font-size: 1.4rem;
	box-shadow: 0 8px 20px rgba(45, 108, 70, 0.2);
}

.genealogy-form-card .form-control,
.genealogy-form-card .form-select {
	min-height: 48px;
	border: 1px solid #dfe6e1;
	border-radius: 12px;
	background-color: #fbfcfb;
	padding: 0.75rem 1rem;
	transition:
		border-color 0.2s ease,
		box-shadow 0.2s ease,
		background-color 0.2s ease;
}

.genealogy-form-card textarea.form-control {
	min-height: 140px;
	resize: vertical;
}

.genealogy-form-card .form-control:focus,
.genealogy-form-card .form-select:focus {
	border-color: #4b8b63;
	background-color: #ffffff;
	box-shadow: 0 0 0 0.2rem rgba(45, 108, 70, 0.14);
}

.genealogy-form-info {
	padding: 1rem 1.1rem;
	border: 1px solid rgba(45, 108, 70, 0.15);
	border-radius: 14px;
	background: rgba(45, 108, 70, 0.05);
}

.genealogy-form-info-icon {
	color: #2d6c46;
	font-size: 1.25rem;
}

.genealogy-primary-button,
.genealogy-secondary-button {
	min-height: 46px;
	border-radius: 12px;
	padding: 0.65rem 1.25rem;
	font-weight: 600;
}

.genealogy-primary-button {
	border-color: #2d6c46;
	background-color: #2d6c46;
	box-shadow: 0 8px 18px rgba(45, 108, 70, 0.18);
}

.genealogy-primary-button:hover,
.genealogy-primary-button:focus {
	border-color: #24593a;
	background-color: #24593a;
	transform: translateY(-1px);
}

.genealogy-secondary-button {
	border-color: #cbd5cf;
	color: #526158;
}

.genealogy-secondary-button:hover {
	border-color: #526158;
	background-color: #526158;
	color: #ffffff;
}

@media (max-width: 575.98px) {
	.genealogy-form-card-header {
		padding: 1.25rem;
	}

	.genealogy-form-card .card-body {
		padding: 1.5rem !important;
	}

	.genealogy-primary-button,
	.genealogy-secondary-button {
		width: 100%;
	}
}

/* =====================================================
   PAGE DE LISTE DES ARBRES
===================================================== */

.genealogy-tree-summary {
	display: inline-flex;
	padding: 1rem 1.25rem;
	border-radius: 16px;
	background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 60%
    );
	box-shadow: 0 8px 25px rgba(35, 54, 43, 0.06);
}

.genealogy-tree-summary-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	border-radius: 16px;
	background: rgba(45, 108, 70, 0.11);
	color: #2d6c46;
	font-size: 1.25rem;
}

.genealogy-tree-card {
	position: relative;
	overflow: hidden;
	border-radius: 14px !important;
	background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 100%
    );
	transition:
		transform 0.25s ease,
		box-shadow 0.25s ease;
}

.genealogy-tree-card:hover {
	transform: translateY(-5px);
	box-shadow: 0 18px 40px rgba(35, 54, 43, 0.12) !important;
}

.genealogy-tree-card-header {
	min-height: 105px;
	padding: 1.5rem;
	background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 60%
    );
	border-bottom: 1px solid rgba(45, 108, 70, 0.1);
}

.genealogy-tree-card-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 58px;
	height: 58px;
	border-radius: 17px;
	background: #2d6c46;
	color: #ffffff;
	font-size: 1.6rem;
	box-shadow: 0 10px 24px rgba(45, 108, 70, 0.23);
}

.genealogy-tree-active-badge {
	display: inline-flex;
	align-items: center;
	padding: 0.42rem 0.75rem;
	border-radius: 999px;
	background: #ffffff;
	color: #2d6c46;
	font-size: 0.76rem;
	font-weight: 700;
	box-shadow: 0 5px 15px rgba(35, 54, 43, 0.1);
}

.genealogy-tree-card-title {
	color: #23362b;
	font-size: 1.35rem;
	font-weight: 700;
}

.genealogy-tree-description {
	min-height: 50px;
	line-height: 1.6;
}

.genealogy-tree-metadata {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 0.75rem;
}

.genealogy-tree-metadata-item {
	display: flex;
	align-items: center;
	gap: 0.7rem;
	padding: 0.8rem;
	border-radius: 13px;
	background: #f7faf8;
}

.genealogy-tree-metadata-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 35px;
	height: 35px;
	flex-shrink: 0;
	border-radius: 10px;
	background: rgba(45, 108, 70, 0.1);
	color: #2d6c46;
}

.genealogy-tree-metadata-item small,
.genealogy-tree-metadata-item strong {
	display: block;
}

.genealogy-tree-metadata-item small {
	color: #7a867e;
	font-size: 0.7rem;
}

.genealogy-tree-metadata-item strong {
	color: #33483b;
	font-size: 0.86rem;
}

.genealogy-tree-open-button,
.genealogy-tree-switch-button {
	min-height: 45px;
	border-radius: 12px;
	font-weight: 600;
}

.genealogy-tree-open-button {
	border-color: #2d6c46;
	background-color: #2d6c46;
}

.genealogy-tree-open-button:hover {
	border-color: #24593a;
	background-color: #24593a;
}

.genealogy-tree-switch-button {
	border-color: #d1d9d4;
	color: #526158;
}

.genealogy-tree-switch-button:hover {
	border-color: #526158;
	background: #526158;
	color: #ffffff;
}

.genealogy-empty-state {
	border-radius: 24px;
	background:
		linear-gradient(
			145deg,
			#ffffff,
			#f7faf8
		);
}

.genealogy-empty-state .card-body {
	max-width: 720px;
	margin: 0 auto;
}

.genealogy-empty-state-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100px;
	height: 100px;
	border-radius: 50%;
	background: rgba(45, 108, 70, 0.11);
	color: #2d6c46;
	font-size: 2.75rem;
	box-shadow: 0 12px 32px rgba(45, 108, 70, 0.13);
}

.genealogy-empty-state p.text-muted {
	max-width: 570px;
	line-height: 1.7;
}

@media (max-width: 767.98px) {
	.genealogy-tree-summary {
		display: flex;
		width: 100%;
	}

	.genealogy-tree-description {
		min-height: auto;
	}
}

@media (max-width: 575.98px) {
	.genealogy-tree-metadata {
		grid-template-columns: 1fr;
	}

	.genealogy-page-heading .genealogy-primary-button {
		width: 100%;
	}
}

/* =========================================================
   MENU DÉROULANT DES ARBRES
========================================================= */

.genealogy-tree-dropdown {
	position: relative;
}

.genealogy-tree-nav-label {
	display: inline-block;
	max-width: 135px;
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
	vertical-align: bottom;
}


/* Menu principal */

.genealogy-tree-menu {
	width: 305px;
	max-width: calc(100vw - 2rem);
	margin-top: 12px !important;
	padding: 9px;
	overflow: hidden;
	border: 1px solid var(--navbar-border);
	border-radius: 17px;
	background-color: #ffffff;
	box-shadow: 0 20px 45px rgba(38, 55, 40, 0.15);
}


/* Titre */

.genealogy-tree-menu-title {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 8px 9px;
	color: var(--navbar-green-dark);
	font-size: 0.89rem;
	font-weight: 750;
}

.genealogy-tree-menu-title > span:first-child {
	display: inline-flex;
	align-items: center;
	gap: 8px;
}

.genealogy-tree-menu-title i {
	color: var(--navbar-green);
	font-size: 1rem;
}

.genealogy-tree-menu-total {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 25px;
	height: 25px;
	padding: 0 7px;
	border-radius: 999px;
	background-color: rgba(82, 120, 83, 0.1);
	color: var(--navbar-green-dark);
	font-size: 0.72rem;
	font-weight: 700;
}


/* Séparateur */

.genealogy-tree-divider {
	margin: 6px 4px;
	border-color: var(--navbar-border);
	opacity: 1;
}


/* Liste */

.genealogy-tree-list {
	display: grid;
	gap: 3px;
	max-height: 285px;
	overflow-y: auto;
	scrollbar-width: thin;
	scrollbar-color:
		rgba(82, 120, 83, 0.35)
		transparent;
}

.genealogy-tree-list::-webkit-scrollbar {
	width: 5px;
}

.genealogy-tree-list::-webkit-scrollbar-track {
	background: transparent;
}

.genealogy-tree-list::-webkit-scrollbar-thumb {
	border-radius: 999px;
	background-color: rgba(82, 120, 83, 0.35);
}


/* Ligne d’un arbre */

.genealogy-tree-item {
	display: flex;
	align-items: center;
	gap: 10px;
	min-width: 0;
	padding: 9px 10px;
	color: var(--navbar-text);
	border-radius: 12px;
	transition:
		color 0.2s ease,
		background-color 0.2s ease;
}

.genealogy-tree-item:hover,
.genealogy-tree-item:focus {
	color: var(--navbar-green-dark);
	background-color: var(--navbar-hover);
}


/* Icône */

.genealogy-tree-item-icon {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 34px;
	height: 34px;
	color: var(--navbar-green);
	font-size: 0.98rem;
	border-radius: 10px;
	background-color: rgba(82, 120, 83, 0.09);
}

.genealogy-tree-item:hover .genealogy-tree-item-icon,
.genealogy-tree-item:focus .genealogy-tree-item-icon {
	color: var(--navbar-green-dark);
	background-color: rgba(82, 120, 83, 0.14);
}


/* Texte */

.genealogy-tree-item-content {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	min-width: 0;
}

.genealogy-tree-item-name {
	overflow: hidden;
	color: inherit;
	font-size: 0.85rem;
	font-weight: 700;
	line-height: 1.25;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.genealogy-tree-item-meta {
	display: flex;
	align-items: center;
	gap: 7px;
	margin-top: 3px;
	color: var(--navbar-muted);
	font-size: 0.68rem;
	line-height: 1.2;
}

.genealogy-tree-active-text {
	position: relative;
	padding-left: 8px;
	color: var(--navbar-green);
	font-weight: 700;
}

.genealogy-tree-active-text::before {
	content: "";
	position: absolute;
	top: 50%;
	left: 0;
	width: 3px;
	height: 3px;
	border-radius: 50%;
	background-color: var(--navbar-green);
	transform: translateY(-50%);
}


/* Arbre actif */

.genealogy-tree-item-active {
	color: var(--navbar-green-dark);
	background-color: rgba(82, 120, 83, 0.1);
}

.genealogy-tree-item-active .genealogy-tree-item-icon {
	color: #ffffff;
	background-color: var(--navbar-green);
}

.genealogy-tree-item-check {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 23px;
	height: 23px;
	color: #ffffff;
	font-size: 0.76rem;
	border-radius: 50%;
	background-color: var(--navbar-green);
}

.genealogy-tree-item-arrow {
	flex: 0 0 auto;
	color: #a3ada5;
	font-size: 0.67rem;
}


/* Aucun arbre */

.genealogy-tree-empty {
	display: flex;
	align-items: center;
	gap: 11px;
	padding: 13px 10px;
	color: var(--navbar-text);
}

.genealogy-tree-empty-icon {
	display: inline-flex;
	flex: 0 0 auto;
	align-items: center;
	justify-content: center;
	width: 38px;
	height: 38px;
	color: var(--navbar-green);
	font-size: 1.05rem;
	border-radius: 11px;
	background-color: rgba(82, 120, 83, 0.09);
}

.genealogy-tree-empty div {
	display: flex;
	flex-direction: column;
}

.genealogy-tree-empty strong {
	font-size: 0.83rem;
}

.genealogy-tree-empty small {
	margin-top: 2px;
	color: var(--navbar-muted);
	font-size: 0.69rem;
}


/* Actions */

.genealogy-tree-actions {
	display: grid;
	gap: 3px;
}

.genealogy-tree-action {
	display: flex;
	align-items: center;
	gap: 10px;
	padding: 9px 10px;
	color: var(--navbar-text);
	font-size: 0.81rem;
	font-weight: 650;
	border-radius: 11px;
	transition:
		color 0.2s ease,
		background-color 0.2s ease;
}

.genealogy-tree-action i {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 30px;
	height: 30px;
	color: var(--navbar-green);
	font-size: 0.91rem;
	border-radius: 9px;
	background-color: rgba(82, 120, 83, 0.09);
}

.genealogy-tree-action:hover,
.genealogy-tree-action:focus {
	color: var(--navbar-green-dark);
	background-color: var(--navbar-hover);
}

.genealogy-tree-action:hover i,
.genealogy-tree-action:focus i {
	color: #ffffff;
	background-color: var(--navbar-green);
}


/* Animation d’ouverture */

.genealogy-tree-menu.show {
	animation: genealogyTreeMenuOpen 0.16s ease-out;
}

@keyframes genealogyTreeMenuOpen {
	from {
		opacity: 0;
		transform: translateY(-5px);
	}

	to {
		opacity: 1;
		transform: translateY(0);
	}
}


/* =========================================================
   VERSION MOBILE
========================================================= */

@media screen and (max-width: 991px) {
	.genealogy-tree-menu {
		position: static !important;
		width: 100%;
		max-width: none;
		margin-top: 6px !important;
		transform: none !important;
		border-radius: 14px;
		background-color: rgba(82, 120, 83, 0.04);
		box-shadow: none;
	}

	.genealogy-tree-nav-label {
		max-width: none;
	}

	.genealogy-tree-list {
		max-height: 240px;
	}
}

/* ========================================================= RESPONSIVE ========================================================= */
@media screen and (max-width: 991px) {
    .genealogy-footer-brand {
        max-width: 620px;
    }

    .genealogy-footer-bottom {
        align-items: flex-start;
        flex-direction: column;
    }

    .genealogy-footer-credit {
        text-align: left;
    }
}

@media screen and (max-width: 767px) {
    .genealogy-footer {
        text-align: center;
    }

    .genealogy-footer-brand {
        align-items: center;
        flex-direction: column;
    }

    .genealogy-footer-brand-text {
        margin-right: auto;
        margin-left: auto;
    }

    .genealogy-footer-title {
        justify-content: center;
    }

    .genealogy-footer-links {
        align-items: center;
    }

    .genealogy-footer-links a, .genealogy-footer-link-button {
        text-align: center;
    }

    .genealogy-footer-security {
        max-width: 400px;
        margin-right: auto;
        margin-left: auto;
        text-align: left;
    }

    .genealogy-footer-bottom {
        align-items: center;
        text-align: center;
    }

    .genealogy-footer-credit {
        text-align: center;
    }

    .genealogy-policy-modal .modal-footer {
        align-items: stretch;
        flex-direction: column;
    }

    .genealogy-policy-date {
        margin-right: 0 !important;
        text-align: center;
    }

    .btn-footer-modal-close {
        width: 100%;
    }
}

@media screen and (max-width: 576px) {
    .genealogy-footer-logo-link {
        width: 105px;
        height: 105px;
    }

    .genealogy-footer-brand-title {
        font-size: 1.3rem;
    }

    .genealogy-policy-modal .modal-header {
        align-items: flex-start;
        padding: 19px;
    }

    .genealogy-policy-modal-icon {
        width: 46px;
        height: 46px;
    }

    .genealogy-policy-modal .modal-body {
        padding: 21px 18px;
    }

    .genealogy-policy-modal .modal-footer {
        padding: 17px 18px;
    }
}


/* =========================================================
   PAGE DE PARTAGE D’UN ARBRE
========================================================= */

.genealogy-share-page {
	min-height: 100vh;
	background:
		linear-gradient(
			180deg,
			rgba(247, 241, 229, 0.45) 0%,
			#ffffff 38%
		);
}

.genealogy-share-header {
	position: relative;
	overflow: hidden;
	border-bottom: 1px solid rgba(82, 120, 83, 0.12);
	background:
		linear-gradient(
			135deg,
			rgba(237, 244, 235, 0.92),
			rgba(255, 255, 255, 0.97)
		);
}

.genealogy-share-decoration {
	position: absolute;
	border-radius: 50%;
	background: rgba(82, 120, 83, 0.08);
	pointer-events: none;
}

.genealogy-share-decoration-left {
	top: -90px;
	left: -80px;
	width: 230px;
	height: 230px;
}

.genealogy-share-decoration-right {
	right: -100px;
	bottom: -130px;
	width: 300px;
	height: 300px;
}

.genealogy-share-title {
	color: var(--navbar-green-dark, #304d30);
}

.genealogy-share-logo-wrapper {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 150px;
	height: 150px;
	padding: 17px;
	border: 1px solid rgba(82, 120, 83, 0.15);
	border-radius: 50%;
	background: #ffffff;
	box-shadow: 0 18px 45px rgba(48, 77, 48, 0.13);
}

.genealogy-share-logo {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.genealogy-share-tree-summary,
.genealogy-share-card,
.genealogy-share-no-tree {
	border-radius: 22px;
	background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 60%
    );
}

.genealogy-share-tree-summary {
	padding: 1.5rem;
}

.genealogy-share-tree-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 62px;
	height: 62px;
	flex-shrink: 0;
	border-radius: 18px;
	background:
		linear-gradient(
			135deg,
			var(--navbar-green-light, #739072),
			var(--navbar-green-dark, #304d30)
		);
	color: #ffffff;
	font-size: 1.55rem;
	box-shadow: 0 10px 25px rgba(48, 77, 48, 0.2);
}

.genealogy-share-permission {
	display: inline-flex;
	align-items: center;
	padding: 0.55rem 0.85rem;
	border-radius: 999px;
	font-size: 0.75rem;
	font-weight: 700;
}

.genealogy-share-permission-admin {
	color: #9ae1b2;
	background: rgba(82, 120, 83, 0.12);
}

.genealogy-share-permission-reader {
	color: #657181;
	background: rgba(83, 99, 120, 0.1);
}

.genealogy-share-card {
	overflow: hidden;
}

.genealogy-share-card-heading {
	display: flex;
	align-items: center;
	gap: 1rem;
	padding: 1.4rem 1.5rem;
	border-bottom: 1px solid rgba(82, 120, 83, 0.1);
	background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 60%
    );
}

.genealogy-share-card-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 50px;
	height: 50px;
	flex-shrink: 0;
	border-radius: 15px;
	background: var(--navbar-green, #527853);
	color: #ffffff;
	font-size: 1.2rem;
	box-shadow: 0 8px 20px rgba(48, 77, 48, 0.18);
}

.genealogy-share-card-icon-warning {
	background: #b8872f;
}

.genealogy-share-card-body {
	padding: 1.5rem;
}

.genealogy-share-form .form-control,
.genealogy-share-form .form-select {
	min-height: 48px;
	border: 1px solid #dce4de;
	border-radius: 12px;
	background-color: #fbfcfb;
	padding: 0.72rem 0.9rem;
}

.genealogy-share-form .form-control:focus,
.genealogy-share-form .form-select:focus {
	border-color: var(--navbar-green, #527853);
	background-color: #ffffff;
	box-shadow: 0 0 0 0.2rem rgba(82, 120, 83, 0.14);
}

.genealogy-share-role-help {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 0.75rem;
}

.genealogy-share-role-item {
	display: flex;
	align-items: flex-start;
	gap: 0.75rem;
	padding: 0.9rem;
	border-radius: 14px;
	background: #f7faf8;
}

.genealogy-share-role-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 36px;
	height: 36px;
	flex-shrink: 0;
	border-radius: 10px;
	background: rgba(82, 120, 83, 0.11);
	color: var(--navbar-green, #527853);
}

.genealogy-share-role-item strong,
.genealogy-share-role-item small {
	display: block;
}

.genealogy-share-role-item strong {
	color: #34483a;
	font-size: 0.83rem;
}

.genealogy-share-role-item small {
	margin-top: 0.2rem;
	color: #78847b;
	font-size: 0.7rem;
	line-height: 1.4;
}

.genealogy-share-primary-button,
.genealogy-share-secondary-button {
	min-height: 46px;
	padding: 0.65rem 1.2rem;
	border-radius: 12px;
	font-weight: 650;
}

.genealogy-share-information {
	display: flex;
	align-items: flex-start;
	gap: 1rem;
	padding: 1rem;
	border: 1px solid rgba(82, 120, 83, 0.13);
	border-radius: 14px;
	background: rgba(82, 120, 83, 0.05);
}

.genealogy-share-information-icon {
	color: var(--navbar-green, #527853);
	font-size: 1.25rem;
}

.genealogy-share-member-list,
.genealogy-share-invitation-list {
	display: grid;
	gap: 0.75rem;
}

.genealogy-share-member,
.genealogy-share-invitation {
	display: flex;
	align-items: center;
	gap: 0.75rem;
	padding: 0.85rem;
	border: 1px solid rgba(82, 120, 83, 0.09);
	border-radius: 14px;
	background: #fbfcfb;
}

.genealogy-share-member-avatar,
.genealogy-share-invitation-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 42px;
	height: 42px;
	flex-shrink: 0;
	border-radius: 12px;
	background: rgba(82, 120, 83, 0.11);
	color: var(--navbar-green, #527853);
}

.genealogy-share-member-content,
.genealogy-share-invitation-content {
	display: flex;
	flex: 1;
	flex-direction: column;
	min-width: 0;
}

.genealogy-share-member-content strong,
.genealogy-share-invitation-content strong {
	overflow: hidden;
	color: #34483a;
	font-size: 0.84rem;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.genealogy-share-member-content span,
.genealogy-share-invitation-content span {
	overflow: hidden;
	margin-top: 0.12rem;
	color: #7a867e;
	font-size: 0.68rem;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.genealogy-share-role-badge {
	display: inline-flex;
	align-items: center;
	flex-shrink: 0;
	padding: 0.4rem 0.62rem;
	border-radius: 999px;
	font-size: 0.66rem;
	font-weight: 700;
}

.genealogy-share-role-owner {
	color: #8a6720;
	background: rgba(184, 135, 47, 0.13);
}

.genealogy-share-role-admin {
	color: #2f6a43;
	background: rgba(82, 120, 83, 0.13);
}

.genealogy-share-role-reader {
	color: #536378;
	background: rgba(83, 99, 120, 0.1);
}

.genealogy-share-role-pending {
	color: #8a6720;
	background: rgba(184, 135, 47, 0.13);
}

.genealogy-share-empty {
	display: flex;
	align-items: center;
	gap: 1rem;
	padding: 1rem;
	border-radius: 14px;
	background: #f8faf8;
}

.genealogy-share-empty-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	flex-shrink: 0;
	border-radius: 13px;
	background: rgba(82, 120, 83, 0.1);
	color: var(--navbar-green, #527853);
	font-size: 1.2rem;
}

.genealogy-share-empty strong {
	display: block;
	color: #34483a;
	font-size: 0.86rem;
}

.genealogy-share-empty p {
	margin-top: 0.2rem;
	font-size: 0.72rem;
	line-height: 1.5;
}

.genealogy-share-no-tree {
	max-width: 720px;
	margin: 0 auto;
	padding: 3rem 2rem;
	text-align: center;
}

.genealogy-share-no-tree-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 92px;
	height: 92px;
	margin: 0 auto 1.25rem;
	border-radius: 50%;
	background: rgba(82, 120, 83, 0.1);
	color: var(--navbar-green, #527853);
	font-size: 2.4rem;
}

.genealogy-share-no-tree > p.text-secondary {
	max-width: 560px;
}

@media screen and (max-width: 767px) {
	.genealogy-share-role-help {
		grid-template-columns: 1fr;
	}

	.genealogy-share-member,
	.genealogy-share-invitation {
		align-items: flex-start;
		flex-wrap: wrap;
	}

	.genealogy-share-role-badge {
		margin-left: 52px;
	}

	.genealogy-share-logo-wrapper {
		width: 120px;
		height: 120px;
	}
}

@media screen and (max-width: 575px) {
	.genealogy-share-card-heading,
	.genealogy-share-card-body,
	.genealogy-share-tree-summary {
		padding: 1.2rem;
	}

	.genealogy-share-primary-button,
	.genealogy-share-secondary-button {
		width: 100%;
	}
}

/* =========================================================
   PAGE DE DÉTAIL D’UN ARBRE
========================================================= */



.genealogy-tree-details-header .container {
	position: relative;
	z-index: 1;
}

.genealogy-tree-details-main-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 76px;
	height: 76px;
	flex-shrink: 0;
	border-radius: 22px;
	background:
		linear-gradient(
			135deg,
			var(--navbar-green-light, #739072),
			var(--navbar-green-dark, #304d30)
		);
	color: #ffffff;
	font-size: 2rem;
	box-shadow: 0 14px 32px rgba(48, 77, 48, 0.22);
}

.genealogy-tree-details-title {
	color: var(--navbar-green-dark, #304d30);
}

.genealogy-tree-details-information {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem 1.25rem;
	color: #6f7d73;
	font-size: 0.82rem;
}

.genealogy-tree-details-information span {
	display: inline-flex;
	align-items: center;
	gap: 0.4rem;
}

.genealogy-tree-details-information i {
	color: var(--navbar-green, #527853);
}

.genealogy-tree-details-information strong {
	color: #455549;
}

.genealogy-tree-details-primary-button,
.genealogy-tree-details-secondary-button {
	min-height: 40px;
	padding: 0.65rem 1.15rem;
	border-radius: 12px;
	font-weight: 650;
}

@media screen and (max-width: 767px) {
	.genealogy-tree-details-main-icon {
		width: 62px;
		height: 62px;
		border-radius: 18px;
		font-size: 1.55rem;
	}

	.genealogy-tree-details-information {
		flex-direction: column;
		gap: 0.45rem;
	}
}

@media screen and (max-width: 575px) {
	.genealogy-tree-details-header .d-flex.align-items-start {
		flex-direction: column;
	}

	.genealogy-tree-details-primary-button,
	.genealogy-tree-details-secondary-button {
		width: 100%;
	}
}

/* =========================================================
   EN-TÊTE DE LA LISTE DES ARBRES
========================================================= */

.genealogy-tree-list-page {
	min-height: 100vh;
	background:
		linear-gradient(
			180deg,
			rgba(247, 241, 229, 0.42) 0%,
			#ffffff 38%
		);
}

.genealogy-tree-list-main-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 76px;
	height: 76px;
	flex-shrink: 0;
	border-radius: 22px;
	background:
		linear-gradient(
			135deg,
			var(--navbar-green-light, #739072),
			var(--navbar-green-dark, #304d30)
		);
	color: #ffffff;
	font-size: 2rem;
	box-shadow: 0 14px 32px rgba(48, 77, 48, 0.22);
}

.genealogy-tree-list-title {
	color: var(--navbar-green-dark, #304d30);
}

.genealogy-tree-list-primary-button {
	min-height: 46px;
	padding: 0.65rem 1.2rem;
	border-color: var(--navbar-green, #527853);
	border-radius: 12px;
	background-color: var(--navbar-green, #527853);
	font-weight: 650;
	box-shadow: 0 8px 20px rgba(48, 77, 48, 0.18);
}

.genealogy-tree-list-primary-button:hover,
.genealogy-tree-list-primary-button:focus {
	border-color: var(--navbar-green-dark, #304d30);
	background-color: var(--navbar-green-dark, #304d30);
	transform: translateY(-1px);
}

@media screen and (max-width: 767px) {
	.genealogy-tree-list-main-icon {
		width: 62px;
		height: 62px;
		border-radius: 18px;
		font-size: 1.55rem;
	}
}

@media screen and (max-width: 575px) {
	.genealogy-tree-list-header .d-flex.align-items-start {
		flex-direction: column;
	}

	.genealogy-tree-list-primary-button {
		width: 100%;
	}
}

/* =========================================================
   PAGE DE CRÉATION D’UN ARBRE
========================================================= */

.genealogy-tree-form-page {
	min-height: 100vh;
	background:
		linear-gradient(
			180deg,
			rgba(247, 241, 229, 0.42) 0%,
			#ffffff 38%
		);
}

.genealogy-tree-form-main-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 76px;
	height: 76px;
	border-radius: 22px;
	background:
		linear-gradient(
			135deg,
			var(--navbar-green-light, #739072),
			var(--navbar-green-dark, #304d30)
		);
	color: #ffffff;
	font-size: 2rem;
	box-shadow: 0 14px 32px rgba(48, 77, 48, 0.22);
}

.genealogy-tree-form-title {
	color: var(--navbar-green-dark, #304d30);
}

.genealogy-tree-form-description {
	max-width: 680px;
	line-height: 1.7;
}

@media screen and (max-width: 767px) {
	.genealogy-tree-form-main-icon {
		width: 62px;
		height: 62px;
		border-radius: 18px;
		font-size: 1.55rem;
	}
}

/* =========================================================
   DOCUMENTS GÉNÉALOGIQUES
========================================================= */

.genealogy-document-page {
    color: var(--tree-text);
}


/* =========================================================
   CARTE PRINCIPALE
========================================================= */

.genealogy-document-card {
    overflow: hidden;

    border: 1px solid var(--tree-border);
    border-radius: 24px;

    background:
        linear-gradient(
            145deg,
            #ffffff 0%,
            var(--tree-light) 100%
        );

    box-shadow:
        0 12px 35px rgba(48, 77, 48, 0.08);
}


/* =========================================================
   HEADER
========================================================= */

.genealogy-document-card-header {
    display: flex;
    align-items: center;
    gap: 18px;

    padding: 28px 32px;

    border-bottom: 1px solid var(--tree-border);

    background:
        linear-gradient(
            135deg,
            rgba(82, 120, 83, 0.12),
            rgba(115, 144, 114, 0.05)
        );
}


.genealogy-document-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    width: 56px;
    height: 56px;

    border-radius: 16px;

    background-color: var(--tree-primary);
    color: #ffffff;

    font-size: 1.6rem;

    box-shadow:
        0 8px 18px rgba(82, 120, 83, 0.20);
}


.genealogy-document-title {
    margin: 0 0 4px;

    color: var(--tree-primary-dark);

    font-size: 1.45rem;
    font-weight: 700;
}


.genealogy-document-subtitle {
    color: var(--tree-muted);
    font-size: 0.95rem;
}


/* =========================================================
   SECTIONS
========================================================= */

.genealogy-document-section {
    padding: 28px 32px;

    border-bottom: 1px solid var(--tree-border);
}


.genealogy-document-section:last-of-type {
    border-bottom: none;
}


.genealogy-document-section-title {
    display: flex;
    align-items: center;

    margin-bottom: 22px;

    color: var(--tree-primary-dark);

    font-size: 1.05rem;
    font-weight: 700;
}


/* =========================================================
   FORMULAIRE
========================================================= */

.genealogy-document-card .form-label {
    margin-bottom: 7px;

    color: var(--tree-text);

    font-weight: 600;
}


.genealogy-document-card .form-control,
.genealogy-document-card .form-select {
    min-height: 46px;

    border: 1px solid rgba(82, 120, 83, 0.24);
    border-radius: 12px;

    background-color: rgba(255, 255, 255, 0.94);
}


.genealogy-document-card textarea.form-control {
    min-height: auto;
}


.genealogy-document-card .form-control:focus,
.genealogy-document-card .form-select:focus {
    border-color: var(--tree-primary);

    box-shadow:
        0 0 0 0.2rem rgba(82, 120, 83, 0.12);
}


.genealogy-document-card .input-group-text {
    border-color: rgba(82, 120, 83, 0.24);
    border-radius: 12px 0 0 12px;

    background-color: var(--tree-light);
    color: var(--tree-primary);
}


.genealogy-document-card .input-group .form-control {
    border-radius: 0 12px 12px 0;
}


.genealogy-document-card .form-check-input:checked {
    border-color: var(--tree-primary);
    background-color: var(--tree-primary);
}


.genealogy-document-card .form-text {
    margin-top: 7px;

    color: var(--tree-muted);

    font-size: 0.84rem;
}


/* =========================================================
   ACTIONS
========================================================= */

.genealogy-document-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 15px;

    padding: 25px 32px;

    background-color: rgba(247, 241, 229, 0.35);
}


.genealogy-document-submit {
    border-color: var(--tree-primary);

    background-color: var(--tree-primary);
    color: #ffffff;

    font-weight: 600;
}


.genealogy-document-submit:hover,
.genealogy-document-submit:focus {
    border-color: var(--tree-primary-dark);

    background-color: var(--tree-primary-dark);
    color: #ffffff;
}


/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 767.98px) {

    .genealogy-document-card-header {
        padding: 22px 20px;
    }


    .genealogy-document-section {
        padding: 24px 20px;
    }


    .genealogy-document-actions {
        flex-direction: column-reverse;

        padding: 22px 20px;
    }


    .genealogy-document-actions .btn {
        width: 100%;
    }

}


/* ------------------------------------------------------------
    delete document
---------------------------------------------------------------*/
.genealogy-document-delete-card {
    padding: 35px;
    border-radius: 16px;
    min-height: 400px;
    background: linear-gradient(
        135deg,
        rgba(223, 241, 214, 0.75) 0%,
        #598340 80%,
        rgba(16, 56, 4, 0.75) 100%
    );
	transition:
		transform 0.25s ease,
		box-shadow 0.25s ease;

    text-align: center;

    box-shadow:
        0 12px 35px rgba(48, 77, 48, 0.08);
}


.genealogy-document-delete-card h1 {
    margin-bottom: 15px;

    color: var(--tree-primary-dark);

    font-size: 1.5rem;
    font-weight: 700;
}


.genealogy-document-delete-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 66px;
    height: 66px;

    margin: 0 auto 20px;

    border-radius: 50%;

    background-color: rgba(166, 61, 64, 0.10);
    color: var(--tree-danger);

    font-size: 1.6rem;
}


.genealogy-document-delete-warning {
    padding: 12px 15px;
    min-height: 30px;
    border-radius: 12px;

    background-color: yellowgreen;
    color: #8a611d;

    font-size: 0.9rem;
}

.genealogy-union-document-content,
.genealogy-document-item-content {
    background: #ffffff;
    padding: 10px;
    border-radius: 16px;
}

.genealogy-union-document-icon {
    color: red;
}

.genealogy-union-status {
    color: #356c3d;
    background-color: rgba(82, 120, 83, 0.12); !important;
}


input.form-check-input.person-match-checkbox {
    width: 1.5rem !important;
    height: 1.5rem !important;
    min-width: 1.5rem !important;
    min-height: 1.5rem !important;
    margin: 0 !important;
    cursor: pointer !important;
    border: 2px solid #527853 !important;
    opacity: 1 !important;
}

input.form-check-input.customer-match-checkbox {
    width: 1.5rem !important;
    height: 1.5rem !important;
    min-width: 1.5rem !important;
    min-height: 1.5rem !important;
    margin: 0 0.75rem 0 0 !important;
    cursor: pointer !important;
    border: 2px solid #527853 !important;
    opacity: 1 !important;
}


input.form-check-input.person-match-checkbox:checked {
    background-color: #527853 !important;
    border-color: #527853 !important;
}

input.form-check-input.person-match-checkbox:focus {
    border-color: #304d30 !important;
    box-shadow: 0 0 0 0.25rem rgba(82, 120, 83, 0.20) !important;
}

/* =========================================================
   BANDEAU COOKIES
========================================================= */

.genealogy-cookie-banner {
    position: fixed;

    left: 50%;
    bottom: 24px;

    width: calc(100% - 40px);
    max-width: 920px;

    z-index: 9999;

    opacity: 0;
    visibility: hidden;

    transform: translate(-50%, 30px);

    transition:
        opacity 0.35s ease,
        transform 0.35s ease,
        visibility 0.35s ease;
}


/* =========================================================
   BANDEAU VISIBLE
========================================================= */

.genealogy-cookie-banner.show {
    opacity: 1;
    visibility: visible;

    transform: translate(-50%, 0);
}


/* =========================================================
   CONTENU
========================================================= */

.genealogy-cookie-content {
    display: flex;
    align-items: center;
    gap: 20px;

    padding: 20px 24px;

    background:
        linear-gradient(
            135deg,
            #ffffff 0%,
            var(--tree-light) 100%
        );

    border: 1px solid var(--tree-border);
    border-radius: 20px;

    box-shadow:
        0 12px 35px rgba(48, 77, 48, 0.18);
}


/* =========================================================
   ICÔNE
========================================================= */

.genealogy-cookie-icon {
    flex-shrink: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 52px;
    height: 52px;

    border-radius: 50%;

    background: rgba(82, 120, 83, 0.12);

    color: var(--tree-primary);

    font-size: 25px;
}


/* =========================================================
   TEXTE
========================================================= */

.genealogy-cookie-text {
    flex: 1;
}


.genealogy-cookie-title {
    margin: 0 0 6px 0;

    color: var(--tree-primary-dark);

    font-size: 1.05rem;
    font-weight: 700;
}


.genealogy-cookie-text p {
    margin: 0;

    color: var(--tree-text);

    font-size: 0.9rem;
    line-height: 1.55;
}


.genealogy-cookie-text small {
    display: block;

    margin-top: 4px;

    color: var(--tree-muted);

    font-size: 0.78rem;
}


/* =========================================================
   BOUTON
========================================================= */

.genealogy-cookie-action {
    flex-shrink: 0;
}


.genealogy-cookie-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;

    padding: 10px 18px;

    border: none;
    border-radius: 12px;

    background:
        linear-gradient(
            135deg,
            var(--tree-primary),
            var(--tree-primary-dark)
        );

    color: #ffffff;

    font-size: 0.9rem;
    font-weight: 600;

    cursor: pointer;

    box-shadow:
        0 5px 15px rgba(48, 77, 48, 0.20);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}


.genealogy-cookie-button:hover {
    transform: translateY(-2px);

    box-shadow:
        0 8px 20px rgba(48, 77, 48, 0.28);
}


.genealogy-cookie-button:active {
    transform: translateY(0);
}


/* =========================================================
   VERSION MOBILE
========================================================= */

@media (max-width: 767px) {

    .genealogy-cookie-banner {
        width: calc(100% - 24px);
        bottom: 12px;
    }


    .genealogy-cookie-content {
        align-items: flex-start;
        flex-direction: column;

        gap: 12px;

        padding: 18px;
    }


    .genealogy-cookie-icon {
        width: 44px;
        height: 44px;

        font-size: 21px;
    }


    .genealogy-cookie-action {
        width: 100%;
    }


    .genealogy-cookie-button {
        width: 100%;
    }

}

/* =========================================================
   PAGE AIDE
========================================================= */

.help-page {
    min-height: 80vh;

    background:
        linear-gradient(
            180deg,
            var(--tree-light) 0%,
            #ffffff 45%
        );
}


.help-header-icon {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 70px;
    height: 70px;

    margin: 0 auto 18px;

    border-radius: 50%;

    background: rgba(82, 120, 83, 0.12);

    color: var(--tree-primary);

    font-size: 32px;
}


.help-header h1 {
    color: var(--tree-primary-dark);

    font-weight: 700;
}


.help-header p {
    max-width: 650px;

    margin: 10px auto 0;

    color: var(--tree-muted);

    line-height: 1.7;
}


/* =========================================================
   RECHERCHE AIDE
========================================================= */

.help-search-wrapper {
    max-width: 720px;

    margin-left: auto;
    margin-right: auto;
}


.help-search {
    position: relative;
}


.help-search > .bi-search {
    position: absolute;

    top: 50%;
    left: 18px;

    transform: translateY(-50%);

    color: var(--tree-primary);

    font-size: 18px;

    pointer-events: none;
}


.help-search input {
    width: 100%;

    padding: 15px 52px 15px 50px;

    border: 1px solid var(--tree-border);
    border-radius: 16px;

    background: #ffffff;

    color: var(--tree-text);

    box-shadow:
        0 5px 20px rgba(48, 77, 48, 0.08);

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}


.help-search input:focus {
    border-color: var(--tree-primary);

    outline: none;

    box-shadow:
        0 0 0 4px rgba(82, 120, 83, 0.12);
}


.help-search input::placeholder {
    color: var(--tree-muted);
}


/* Bouton X */

.help-search-clear {
    display: none;

    position: absolute;

    top: 50%;
    right: 14px;

    width: 34px;
    height: 34px;

    transform: translateY(-50%);

    align-items: center;
    justify-content: center;

    border: none;
    border-radius: 50%;

    background: rgba(82, 120, 83, 0.10);

    color: var(--tree-primary-dark);

    cursor: pointer;
}


.help-search-clear.show {
    display: flex;
}


.help-search-clear:hover {
    background: rgba(82, 120, 83, 0.18);
}


/* Nombre de résultats */

.help-search-count {
    min-height: 24px;
    margin-top: 10px;
    text-align: center;
    color: var(--tree-muted);
    font-size: 0.85rem;
}

/* =========================================================
   ACCORDÉON
========================================================= */

.help-accordion {
    max-width: 900px;
    margin: auto;
}


.help-accordion .accordion-item {
    overflow: hidden;
    margin-bottom: 16px;
    border-radius: 18px;
    background: linear-gradient(
        135deg,
        #ffffff 0%,
        #f3f7f2 55%,
        #e4eee1 100%
    );

    box-shadow:
        0 5px 20px rgba(48, 77, 48, 0.08);

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        border-color 0.25s ease;
}


.help-accordion .accordion-item:hover {
    transform: translateY(-2px);
    border-color: rgba(82, 120, 83, 0.32);
    box-shadow:
        0 9px 28px rgba(48, 77, 48, 0.13);
}

.help-accordion .accordion-button {
    gap: 14px;
    padding: 20px;
    color: var(--tree-text);
    background: #ffffff;
    font-weight: 600;
}


.help-accordion .accordion-button:not(.collapsed) {
    color: var(--tree-primary-dark);
    background:
        rgba(82, 120, 83, 0.06);
    box-shadow: none;
}


.help-accordion .accordion-button:focus {
    box-shadow: none;
}


.help-question-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    flex-shrink: 0;
    border-radius: 10px;
    background:
        rgba(82, 120, 83, 0.12);
    color: var(--tree-primary);
    font-size: 18px;
}


.help-accordion .accordion-body {
    padding: 22px 24px;
    color: var(--tree-text);
    line-height: 1.7;
}

/* =========================================================
   ABONNEMENT
========================================================= */

.profile-subscription-card {
    overflow: hidden;
}

.subscription-plan-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;

    margin-top: 24px;
    padding: 20px;

    border: 1px solid var(--tree-border);
    border-radius: 16px;

    background: linear-gradient(
        135deg,
        rgba(243, 247, 242, 0.95),
        rgba(247, 241, 229, 0.75)
    );
}

.subscription-plan-label {
    display: block;

    margin-bottom: 3px;

    color: var(--tree-muted);

    font-size: 0.78rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.subscription-plan-name {
    color: var(--tree-primary-dark);

    font-size: 1.45rem;
    font-weight: 700;
}


/* =========================================================
   BADGE STATUT
========================================================= */

.subscription-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;

    padding: 7px 11px;

    border-radius: 50rem;

    background-color: #f1f3f2;

    color: var(--tree-muted);

    font-size: 0.82rem;
    font-weight: 600;
}

.subscription-status-badge.active {
    background-color: rgba(82, 120, 83, 0.12);

    color: var(--tree-primary-dark);
}


/* =========================================================
   INFORMATIONS
========================================================= */

.subscription-info-list {
    display: flex;
    flex-direction: column;

    margin-top: 22px;
}

.subscription-info-row {
    display: flex;
    align-items: center;
    gap: 14px;

    padding: 15px 2px;

    border-bottom: 1px solid var(--tree-border);
}

.subscription-info-row:last-child {
    border-bottom: 0;
}

.subscription-info-icon {
    display: flex;
    flex: 0 0 42px;
    align-items: center;
    justify-content: center;

    width: 42px;
    height: 42px;

    border-radius: 12px;

    background-color: var(--tree-light);

    color: var(--tree-primary);

    font-size: 1.1rem;
}

.subscription-info-label {
    display: block;

    margin-bottom: 2px;

    color: var(--tree-muted);

    font-size: 0.8rem;
}


/* =========================================================
   RÉSILIATION
========================================================= */

.subscription-cancel-notice {
    display: flex;
    gap: 13px;

    margin-top: 20px;
    padding: 16px;

    border: 1px solid rgba(208, 170, 107, 0.25);
    border-radius: 14px;

    background-color: rgba(210, 204, 195, 0.81);

    color: var(--tree-text);
}

.subscription-cancel-icon {
    flex-shrink: 0;

    color: var(--tree-warning);

    font-size: 1.3rem;
}

.subscription-cancel-notice p {
    margin-top: 4px;

    color: var(--tree-muted);

    font-size: 0.88rem;
    line-height: 1.5;
}


/* =========================================================
   ACTIONS
========================================================= */

.subscription-actions {
    margin-top: 24px;

    text-align: center;
}

.subscription-secure-text {
    display: block;

    margin-top: 10px;

    color: var(--tree-muted);

    font-size: 0.75rem;
}

.premium-nav-badge {
    padding: 0.35rem 0.55rem;

    border: 1px solid rgba(82, 120, 83, 0.25);
    border-radius: 50rem;

    background: rgba(82, 120, 83, 0.12);

    color: #304d30;

    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

/* =========================================================
   RESPONSIVE
========================================================= */

@media (max-width: 991.98px) {

    .profile-subscription-card {
        margin-top: 0;
    }

}

@media (max-width: 575.98px) {

    .subscription-plan-header {
        align-items: flex-start;
        flex-direction: column;
    }

}