/*
 * Shared site header for ville.dev and the blog.
 * Markup comes from scripts/site_header.py; keep this file self-contained so
 * the header renders identically regardless of each page's own styles.
 */
html {
    scrollbar-gutter: stable;
}
.site-header {
    position: sticky;
    top: 0;
    z-index: 100;
    background-color: rgba(253, 253, 253, 0.92);
    -webkit-backdrop-filter: saturate(180%) blur(8px);
    backdrop-filter: saturate(180%) blur(8px);
    border-bottom: 1px solid #e8e8e8;
    color: #333;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 16px;
    line-height: 1.4;
    text-align: left;
}
.site-header *,
.site-header *::before,
.site-header *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}
.site-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    max-width: 1000px;
    height: 60px;
    margin: 0 auto;
    padding: 0 20px;
}
.site-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: #333;
    font-size: 17px;
    font-weight: bold;
    text-decoration: none;
    white-space: nowrap;
}
.site-brand:hover {
    text-decoration: none;
}
.site-brand-mark {
    display: block;
    width: 24px;
    height: 24px;
    transition: transform 0.3s ease;
}
.site-brand:hover .site-brand-mark {
    transform: rotate(90deg);
}
.site-nav {
    display: flex;
    gap: 4px 18px;
    font-size: 15px;
    font-weight: bold;
}
.site-nav a {
    color: #333;
    text-decoration: none;
    white-space: nowrap;
}
.site-nav a:hover {
    text-decoration: underline;
}
.site-nav a[aria-current="page"] {
    text-decoration: underline;
    text-decoration-thickness: 2px;
    text-underline-offset: 5px;
}
.site-header a:focus-visible {
    outline: 3px solid #777;
    outline-offset: 4px;
    border-radius: 2px;
}
@media (max-width: 640px) {
    .site-header-inner {
        flex-wrap: wrap;
        row-gap: 8px;
        height: auto;
        padding: 12px 16px;
    }
    .site-nav {
        width: 100%;
        justify-content: space-between;
        font-size: 14px;
    }
}
@media (prefers-reduced-motion: reduce) {
    .site-brand-mark {
        transition: none;
    }
}
