/* Smooth scrolling for anchor links */
html {
    scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

/* Stretch chart to fill container width */
.mermaid {
    width: 100%;
}

.mermaid svg {
    display: block;
    width: 100%;
    height: auto;
    min-height: 320px;
}

/* Legend styling */
.chart-legend {
    display: flex;
    justify-content: center;
    gap: 1.5em;
    font-size: 0.8rem;
    opacity: 0.8;
    margin-top: -0.5em;
    margin-bottom: 1.5em;
}

.chart-legend-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35em;
}

.chart-legend-swatch {
    display: inline-block;
    width: 0.75em;
    height: 0.75em;
    border-radius: 2px;
}

.chart-legend-swatch--cov {
    background: #4caf50;
}

.chart-legend-swatch--strict {
    background: #fb8c00;
}

/* Symbol kind badges (mkdocstrings-style) */
.md-typeset code.sym-attr,
.md-typeset code.sym-func,
.md-typeset code.sym-meth,
.md-typeset code.sym-class,
.md-typeset code.sym-param,
.md-typeset code.sym-return {
    background-color: #3e4451;
}

.md-typeset code.sym-attr {
    color: #c678dd;
}

.md-typeset code.sym-func,
.md-typeset code.sym-meth {
    color: #61afef;
}

.md-typeset code.sym-class {
    color: #e5c07b;
}

.md-typeset code.sym-param,
.md-typeset code.sym-return {
    color: #98c379;
}
