body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f0f4f8;
    margin: 0;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.container {
    background-color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    max-width: 900px;
    width: 100%;
}

h1 {
    text-align: center;
    color: #2c3e50;
}

.controls {
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;
    margin-bottom: 20px;
    flex-wrap: wrap;
    gap: 10px;
}

.pathology-group {
    display: flex;
    gap: 8px;
}

.pathology-btn {
    background-color: #8e44ad;
}

.pathology-btn:hover {
    background-color: #732d91;
}

.pathology-btn.active {
    background-color: #d35400;
    box-shadow: 0 0 0 2px rgba(211,84,0,0.3);
}

button {
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 5px;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #2980b9;
}

.legend {
    display: flex;
    gap: 15px;
    font-size: 14px;
}

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

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    display: inline-block;
}

.water { background-color: #3498db; }
.salt { background-color: #e74c3c; }
.urea { background-color: #f1c40f; }
.protein { background-color: #9b59b6; }
.glucose { background-color: #2ecc71; }

.visualization {
    border: 1px solid #ddd;
    border-radius: 5px;
    overflow: hidden;
    background-color: #fff;
}

#nephron-svg {
    width: 100%;
    height: auto;
    background-color: #fafafa;
}

.info-panel {
    margin-top: 20px;
    padding: 15px;
    background-color: #e8f6f3;
    border-left: 5px solid #1abc9c;
    border-radius: 3px;
}

#info-text {
    margin: 0;
    font-size: 16px;
    color: #2c3e50;
}

/* SVG Styles */
.tubule {
    fill: none;
    stroke: #e67e22;
    stroke-width: 40;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0.3;
}

.tubule-outline {
    fill: none;
    stroke: #d35400;
    stroke-width: 42;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.glomerulus {
    fill: #c0392b;
    opacity: 0.6;
}

.bowman-capsule {
    fill: none;
    stroke: #e67e22;
    stroke-width: 40;
    stroke-linecap: round;
    stroke-linejoin: round;
    opacity: 0.3;
}

.capillary {
    fill: none;
    stroke: #e74c3c;
    stroke-width: 15;
    opacity: 0.4;
}

.particle {
    transition: transform 0.1s linear;
    pointer-events: none;
}

.label-text {
    font-size: 14px;
    font-weight: bold;
    fill: #34495e;
    pointer-events: none;
}

/* Interactive regions */
.interactive-region {
    fill: rgba(52, 152, 219, 0.1);
    stroke: rgba(52, 152, 219, 0.3);
    stroke-width: 2;
    transition: all 0.3s ease;
    pointer-events: all;
}

.interactive-region:hover,
.interactive-region.region-hover {
    fill: rgba(52, 152, 219, 0.25);
    stroke: rgba(52, 152, 219, 0.6);
    stroke-width: 3;
}

.info-panel {
    transition: all 0.3s ease;
}

/* Floating tooltip */
.floating-tooltip {
    position: absolute;
    background-color: white;
    border: 2px solid #1abc9c;
    border-radius: 8px;
    padding: 12px 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-width: 250px;
    z-index: 1000;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.floating-tooltip.visible {
    opacity: 1;
}

.floating-tooltip.always-show {
    opacity: 0.9;
    display: block !important;
}

.tooltip-content {
    font-size: 14px;
    line-height: 1.6;
    color: #2c3e50;
}

.tooltip-content strong {
    display: block;
    margin-bottom: 6px;
    color: #1abc9c;
    font-size: 15px;
}

/* Particle labels */
.particle-label {
    pointer-events: none;
    user-select: none;
}
