/* rens-graph.css — 3-column layout + all styling for RENS D3 graph */

/* Main 3-column container */
.rens-graph-layout {
    display: flex;
    flex-direction: column;
    height: 100%;
    overflow: hidden;
}

.rens-graph-body {
    display: flex;
    flex: 1;
    min-height: 0;
    overflow: hidden;
}

/* ── Left sidebar: Filters ── */
.rens-filters-sidebar {
    width: 220px;
    min-width: 180px;
    flex-shrink: 0;
    border-right: 1px solid #e0e0e0;
    background: #fafafa;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    padding: 0.5rem;
    font-size: 0.78rem;
}

.rens-filters-sidebar h4 {
    margin: 0 0 0.4rem;
    font-size: 0.8rem;
    color: #1a2a6c;
}

.rens-filter-group {
    margin-bottom: 0.6rem;
}

.rens-filter-group label {
    display: flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.15rem 0;
    cursor: pointer;
    white-space: nowrap;
}

.rens-filter-group label:hover {
    background: #e8eaf6;
    border-radius: 3px;
}

.rens-filter-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 2px;
    flex-shrink: 0;
}

.rens-filter-line {
    display: inline-block;
    width: 16px;
    height: 3px;
    flex-shrink: 0;
}

.rens-filter-search {
    width: 100%;
    padding: 0.3rem 0.5rem;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 0.78rem;
    margin-bottom: 0.5rem;
    box-sizing: border-box;
}

.rens-filter-actions {
    display: flex;
    gap: 0.3rem;
    margin-bottom: 0.5rem;
}

.rens-filter-actions button {
    flex: 1;
    padding: 0.2rem 0.3rem;
    font-size: 0.7rem;
    border: 1px solid #ccc;
    background: #fff;
    border-radius: 3px;
    cursor: pointer;
}

.rens-filter-actions button:hover {
    background: #e8eaf6;
}

/* ── Center: Graph container ── */
.rens-graph-center {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#rens-d3-container {
    flex: 1;
    min-height: 200px;
    background: #fafafa;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    position: relative;
    overflow: hidden;
}

/* ── Right sidebar: Detail panel ── */
#rens-detail-panel {
    width: 0;
    overflow: hidden;
    flex-shrink: 0;
    background: #f5f5f5;
    border-left: 1px solid #e0e0e0;
    transition: width 0.2s ease;
    font-size: 0.8rem;
    padding: 0;
}

#rens-detail-panel.rens-detail-visible {
    width: 240px;
    padding: 0.6rem;
    overflow-y: auto;
}

.rens-detail-header {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 0.5rem;
    word-break: break-word;
}

.rens-detail-dot {
    width: 12px;
    height: 12px;
    border-radius: 3px;
    flex-shrink: 0;
}

.rens-detail-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 0.5rem;
}

.rens-detail-table td {
    padding: 0.2rem 0.3rem;
    border-bottom: 1px solid #e0e0e0;
    vertical-align: top;
}

.rens-detail-table td:first-child {
    color: #888;
    font-size: 0.75rem;
    width: 60px;
}

.rens-detail-uuid {
    font-family: monospace;
    font-size: 0.7rem;
    word-break: break-all;
}

.rens-detail-connections {
    font-size: 0.75rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.rens-detail-info-btn {
    width: 100%;
    padding: 0.35rem 0.5rem;
    background: #1a2a6c;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 0.78rem;
    cursor: pointer;
}

.rens-detail-info-btn:hover {
    background: #2d4373;
}

/* ── Toolbar ── */
.rens-toolbar {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    flex-wrap: wrap;
    flex-shrink: 0;
    padding: 0.4rem 0.5rem;
    border-bottom: 1px solid #e0e0e0;
    background: #fff;
}

.rens-toolbar button {
    padding: 0.3rem 0.65rem;
    background: #1a2a6c;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 0.78rem;
    cursor: pointer;
}

.rens-toolbar button:hover {
    background: #2d4373;
}

.rens-toolbar .rens-node-count {
    font-size: 0.75rem;
    color: #888;
    margin-left: auto;
}

.rens-toolbar .rens-mode-badge {
    font-size: 0.7rem;
    padding: 0.15rem 0.4rem;
    background: #e8eaf6;
    color: #1a2a6c;
    border-radius: 10px;
    font-weight: 600;
}

/* ── Legend bar ── */
.rens-legend-bar {
    display: flex;
    gap: 0.75rem;
    font-size: 0.7rem;
    color: #555;
    flex-wrap: wrap;
    flex-shrink: 0;
    padding: 0.3rem 0.5rem;
    border-top: 1px solid #e0e0e0;
    background: #fff;
}
