﻿/* TreeView Navigation Styles */
/* Compact, hierarchical navigation with expand/collapse */

/* Tree container */
.tree-container {
    margin: 20px 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

/* Remove default list styling */
.tree, .tree ul {
    list-style-type: none;
    padding-left: 0;
    margin: 0;
}

/* Tree items */
.tree li {
    margin: 5px 0;
    padding-left: 20px;
    position: relative;
}

/* Nested items indentation */
.tree .tree-children {
    padding-left: 25px;
}

/* Toggle button */
.tree-toggle {
    display: inline-block;
    width: 20px;
    cursor: pointer;
    user-select: none;
    transition: transform 0.2s;
}

.tree-toggle.expanded {
    transform: rotate(90deg);
}

/* Projects have no toggle (not expandable) */
.tree-project .tree-toggle {
    display: none;
}

/* Tree icons */
.tree-icon {
    display: inline-block;
    width: 20px;
    text-align: center;
    margin-right: 5px;
}

/* Links */
.tree a {
    text-decoration: none;
    color: #0d6efd;
}

.tree a:hover {
    text-decoration: underline;
    color: #0a58ca;
}

/* Folder styling */
.tree-folder > a {
    font-weight: 500;
    color: #0dcaf0;
}

/* Project styling */
.tree-project > a {
    font-weight: normal;
    color: #198754;
}

/* Hidden children */
.tree-children[style*="display: none"] {
    display: none !important;
}

/* Visible children */
.tree-children[style*="display: block"] {
    display: block !important;
}

/* Connecting lines (optional enhancement) */
.tree li::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 1px;
    height: 100%;
    background: #dee2e6;
}

.tree li::after {
    content: "";
    position: absolute;
    top: 12px;
    left: 0;
    width: 15px;
    height: 1px;
    background: #dee2e6;
}

/* Remove line for root items */
.tree > li::before {
    display: none;
}
