.housing-results {
    font-family: var(--font-family-main);
}

.housing-results h3 {
    padding: 10px;
    border-radius: var(--border-radius-small);
    color: var(--color-text-primary);
    margin-bottom: 1rem;
    font-size: 1.2em;
}

.housing-info {
    background: var(--color-foreground);
    border-radius: var(--border-radius-medium);
    padding: var(--padding-card);
    margin-top: 1rem;
}

.housing-info p {
    color: var(--color-text-secondary);
    margin: 0.5rem 0;
    font-size: 0.9em;
}

.location-info {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.housing-structure {
    border-radius: var(--border-radius-medium);
}

.housing-structure h4 {
    padding-bottom: 30px;
    border-radius: var(--border-radius-small);
}

.housing-structure p {
    padding: 8px;
    margin: 5px 0;
    border-radius: var(--border-radius-small);
}

.districts-container {
    background: var(--color-foreground);
    border-radius: var(--border-radius-medium);
    padding: 5px;
    margin-bottom: 10px;
    position: relative;
}

.districts-container::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 0;
    right: 0;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 1.5px;
}

.districts-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.district-item {
    padding: 0px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.district-name {
    color: var(--color-text-secondary);
    font-size: var(--font-size-xs);
    max-width: 60%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-weight: 500;
}

.district-price {
    color: var(--color-text-secondary);
    font-size: var(--font-size-xs);
    font-weight: 500;
}

.chart-container {
    padding-top: 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto;  /* Center horizontally */
}

.ownership-legend {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 10px;
    padding: 0 10px;
    margin-bottom: 10px;
    position: relative;
}

.ownership-legend::after {
    content: '';
    position: absolute;
    bottom: -20px;
    left: 0;
    right: 0;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 1.5px;
}

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

.legend-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.legend-label {
    color: var(--color-text-secondary);
    font-size: var(--font-size-xs);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

table {
    width: 100%;
    border-radius: var(--border-radius-small);
    font-size: var(--font-size-xs);
}

tr {
    height: 28px;
}

tr th {
    text-align: left;
    color: var(--color-text-secondary);
}

tr td {
    color: var(--color-text-secondary);
    font-weight: 500;
}

tr td:last-child {
    color: var(--color-text-secondary);
    font-weight: 500;
}