/* Interactive Neo4j Knowledge Graph Styles */

body {
    margin: 0;
    padding: 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f8f9fa;
}

.graph-container {
    background: white;
    border-radius: 10px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    padding: 20px;
    margin: 20px auto;
    max-width: 840px;
    text-align: center;
}

.graph-title {
    text-align: center;
    font-size: 24px;
    font-weight: bold;
    color: #2c3e50;
    margin-bottom: 10px;
}

.graph-subtitle {
    text-align: center;
    font-size: 14px;
    color: #666;
    margin-bottom: 20px;
}

#graph-svg {
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    background: #fafafa;
    display: block;
    margin: 0 auto;
}

.node {
    cursor: pointer;
    stroke-width: 2px;
}

.node.class {
    fill: #ff69b4;
    stroke: #e91e63;
}

.node.method {
    fill: #4fc3f7;
    stroke: #03a9f4;
}

.node.variable {
    fill: #ff9800;
    stroke: #f57c00;
}

.node:hover {
    stroke-width: 3px;
    filter: brightness(1.2);
}

.node-label {
    font-family: 'Courier New', monospace;
    font-size: 12px;
    font-weight: bold;
    fill: white;
    text-anchor: middle;
    dominant-baseline: middle;
    pointer-events: none;
}

.link {
    stroke: #999;
    stroke-width: 1.5;
    fill: none;
    marker-end: url(#arrowhead);
}

.link-label {
    font-size: 10px;
    fill: #666;
    text-anchor: middle;
    pointer-events: none;
    font-family: monospace;
}

.controls {
    text-align: center;
    margin: 20px 0;
}

.control-btn {
    background: #3498db;
    color: white;
    border: none;
    padding: 10px 20px;
    margin: 0 5px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
}

.control-btn:hover {
    background: #2980b9;
}

.legend {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin: 20px 0;
    flex-wrap: wrap;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
}

.legend-color {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid;
}

.tooltip {
    position: absolute;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    pointer-events: none;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.2s;
}