/* Arbre généalogique en accolade (inc/elevage/_pedigree_tree.php). */
.ped-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; padding: 2px 2px 8px; }
.ped { display: grid; grid-template-columns: repeat(var(--cols), minmax(132px, 1fr));
       grid-template-rows: auto repeat(var(--rows), minmax(24px, auto)); column-gap: 18px; row-gap: 3px;
       min-width: calc(var(--cols) * 150px); }
.ped-h { grid-row: 1; font-size: .68rem; letter-spacing: .06em; text-transform: uppercase; color: #8a8f99; padding: 0 2px 6px; }
.ped-c { position: relative; align-self: center; background: #fff; border: 1px solid #E6DED0; border-radius: 10px;
         padding: 6px 9px; font-size: .84rem; line-height: 1.25; min-width: 0; overflow-wrap: anywhere;
         box-shadow: 0 1px 0 rgba(23,38,64,.04); animation: pedIn .35s ease both; }
.ped-c.g1 { animation-delay: .04s } .ped-c.g2 { animation-delay: .08s } .ped-c.g3 { animation-delay: .12s }
.ped-c.g4 { animation-delay: .16s } .ped-c.g5, .ped-c.g6, .ped-c.g7 { animation-delay: .2s }
@keyframes pedIn { from { opacity: 0; transform: translateX(-6px); } to { opacity: 1; transform: none; } }
.ped-c a, .ped-c b { color: #172640; font-weight: 600; text-decoration: none; }
.ped-c a:hover { text-decoration: underline; }
.ped-c em { display: block; font-style: normal; font-size: .72rem; color: #8a8f99; margin-top: 1px; }
.ped-c.sire { border-left: 3px solid #3E6DA8; }
.ped-c.dam  { border-left: 3px solid #B0662F; }
.ped-c.root { background: #172640; border-color: #172640; padding: 10px 12px; }
.ped-c.root a, .ped-c.root b { color: #fff; font-family: Fraunces, Georgia, serif; font-size: 1rem; }
.ped-c.root em { color: #C8A04A; }
.ped-c.ghost { background: #FBF7EF; border-style: dashed; }
.ped-c.empty { background: transparent; border: 1px dashed #DDD5C6; color: #b5b9c0; text-align: center; padding: 2px 4px; font-size: .74rem; box-shadow: none; }
/* Trait vers l'enfant (à gauche) */
.ped-c:not(.root)::before { content: ""; position: absolute; left: -19px; top: 50%; width: 18px; border-top: 1px solid #D9CFBE; }
.ped-add { border: 0; background: none; color: #9C6F2A; font: inherit; font-size: .8rem; font-weight: 600; cursor: pointer; padding: 2px 4px; border-radius: 6px; }
.ped-add:hover { background: #FBF1DD; }
.ped-add.sm { display: block; margin-top: 3px; font-size: .72rem; padding: 0; }
.ped-legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: .78rem; color: #6b7280; margin-top: 8px; }
.ped-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
@media (prefers-reduced-motion: reduce) { .ped-c { animation: none; } }
