/**
 * Soy Ağacı Sayfası Özel Stilleri
 */

/* ===== TREE PAGE LAYOUT ===== */
.tree-page {
    padding: 0 !important;
    display: flex;
    flex-direction: column;
    height: 100vh;
}

/* ===== ÜST KONTROL PANELİ ===== */
.tree-controls {
    background: var(--glass-bg);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-bottom: 1px solid var(--glass-border);
    padding: 15px 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    z-index: 100;
}

.control-left,
.control-center,
.control-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.current-person-name {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

.current-person-name i {
    color: var(--accent-color);
}

/* Görünüm Seviyesi Seçici */
.view-level-selector {
    display: flex;
    gap: 8px;
    background: rgba(255, 255, 255, 0.03);
    padding: 5px;
    border-radius: 12px;
    border: 1px solid var(--glass-border);
}

.level-btn {
    padding: 10px 18px;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.level-btn:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
}

.level-btn.active {
    background: rgba(255, 255, 255, 0.15);
    color: var(--text-primary);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.1);
}

/* Kontrol Butonları */
.control-btn {
    width: 45px;
    height: 45px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: var(--text-primary);
    font-size: 1.1rem;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.control-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(255, 255, 255, 0.1);
}

/* ===== SOY AĞACI CONTAINER ===== */
.tree-container {
    flex: 1;
    position: relative;
    overflow: hidden;
    background: transparent;
}

#treeSvg {
    width: 100%;
    height: 100%;
    cursor: grab;
}

#treeSvg:active {
    cursor: grabbing;
}

/* Loading */
.tree-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 10;
}

.tree-loading.hidden {
    display: none;
}

.tree-loading p {
    margin-top: 15px;
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* ===== KİŞİ NODE'LARI ===== */
.person-node {
    cursor: pointer;
    transition: var(--transition);
}

.person-circle {
    fill: var(--glass-bg);
    stroke: var(--glass-border);
    stroke-width: 2;
    filter: drop-shadow(0 4px 10px rgba(255, 255, 255, 0.1));
    transition: var(--transition);
}

.person-node:hover .person-circle {
    fill: rgba(255, 255, 255, 0.15);
    stroke: var(--primary-color);
    stroke-width: 3;
    filter: drop-shadow(0 8px 20px rgba(255, 255, 255, 0.3));
}

.person-image {
    clip-path: circle(50%);
    pointer-events: none;
}

.person-name {
    fill: var(--text-primary);
    font-size: 14px;
    font-weight: 600;
    text-anchor: middle;
    pointer-events: none;
}

.person-dates {
    fill: var(--text-muted);
    font-size: 11px;
    text-anchor: middle;
    pointer-events: none;
}

/* Bağlantı Çizgileri */
.link-line {
    fill: none;
    stroke: rgba(255, 255, 255, 0.2);
    stroke-width: 2;
    transition: var(--transition);
}

.link-line:hover {
    stroke: rgba(255, 255, 255, 0.5);
    stroke-width: 3;
}

/* ===== MİNİ HARITA ===== */
.minimap {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 200px;
    background: var(--glass-bg);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 10px;
    z-index: 200;
    box-shadow: var(--glass-shadow);
}

.minimap-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--glass-border);
}

.minimap-header span {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.minimap-close {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1rem;
    transition: var(--transition);
}

.minimap-close:hover {
    color: var(--danger-color);
}

#minimapCanvas {
    width: 100%;
    height: 150px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.02);
}

/* ===== BİYOGRAFİ MODAL ===== */
.biography-modal {
    max-width: 700px;
}

.bio-header {
    display: flex;
    align-items: center;
    gap: 25px;
    margin-bottom: 30px;
    padding-bottom: 25px;
    border-bottom: 1px solid var(--glass-border);
}

.bio-image {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--glass-border);
    box-shadow: 0 0 30px rgba(255, 255, 255, 0.2);
}

.bio-info h2 {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.bio-dates {
    color: var(--text-muted);
    font-size: 1rem;
    margin-bottom: 10px;
}

.bio-section {
    margin-bottom: 25px;
}

.bio-section h3 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.bio-section h3 i {
    color: var(--accent-color);
}

.bio-text {
    color: var(--text-secondary);
    line-height: 1.8;
    font-size: 1rem;
}

.family-member {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 15px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    margin-right: 10px;
    margin-bottom: 10px;
    color: var(--text-primary);
    text-decoration: none;
    transition: var(--transition);
}

.family-member:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.family-member i {
    color: var(--accent-color);
}

/* ===== RESPONSIVE - MOBILE ===== */
@media (max-width: 768px) {
    .tree-controls {
        padding: 10px 15px;
        flex-direction: column;
        align-items: stretch;
    }
    
    .control-left,
    .control-center,
    .control-right {
        width: 100%;
        justify-content: center;
    }
    
    .current-person-name {
        font-size: 1.1rem;
        justify-content: center;
    }
    
    .view-level-selector {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .level-btn {
        padding: 8px 12px;
        font-size: 0.8rem;
    }
    
    .level-btn span {
        display: none;
    }
    
    .minimap {
        bottom: 90px;
        right: 15px;
        width: 150px;
    }
    
    #minimapCanvas {
        height: 100px;
    }
    
    .biography-modal {
        max-width: 95%;
        padding: 25px;
    }
    
    .bio-header {
        flex-direction: column;
        text-align: center;
    }
    
    .bio-info h2 {
        font-size: 1.5rem;
    }
}

/* ===== REPORT MODAL ===== */
.report-modal {
    max-width: 500px;
}