/* bh.css — the one header every bulatapps site wears (hub + every product site). Same file, byte for
   byte, in every repo: edit it ONLY in safabulat.github.io/tools/shared/ and run sync-header.py.
   It reads each site's own palette (--bg, --ink, --ink-soft, --ink-faint, --line), so the header is the
   same shape everywhere and takes its colour from the page it sits on. */
header.bh {
    padding: 18px 0;
    border-bottom: 1px solid var(--line);
    position: sticky; top: 0; z-index: 10;
    background: color-mix(in srgb, var(--bg) 88%, transparent);
    -webkit-backdrop-filter: saturate(160%) blur(12px);
    backdrop-filter: saturate(160%) blur(12px);
    font: 14px/1.4 -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, system-ui, sans-serif;
}
header.bh .wrap { display: flex; align-items: center; gap: 12px; height: 32px;
                  max-width: var(--page, 1080px); margin: 0 auto; padding: 0 24px; }
header.bh .wordmark { display: flex; align-items: center; gap: 10px; flex: none;
                      font-size: 17px; font-weight: 650; letter-spacing: -0.01em; color: var(--ink); text-decoration: none; }
header.bh .wordmark img, header.bh .wordmark svg { width: 27px; height: 27px; border-radius: 7px; flex: none; }
header.bh nav { margin-left: auto; display: flex; gap: 22px; font-size: 14px; }
header.bh nav a, header.bh .hub { color: var(--ink-soft); text-decoration: none; white-space: nowrap;
                                  padding: 0; border: 0; font-weight: 400; }
header.bh nav a:hover, header.bh .hub:hover { color: var(--ink); text-decoration: none; }

/* Hub link, language and theme: their own group after a hairline, and the part that stays on a phone. */
header.bh .tools { display: flex; align-items: center; gap: 10px; margin-left: 22px; padding-left: 22px;
                   border-left: 1px solid var(--line); }
header.bh .hub { margin-right: 6px; }

header.bh .ctl { display: inline-flex; align-items: center; height: 30px; border: 1px solid var(--line);
                 border-radius: 8px; background: none; color: var(--ink-soft); padding: 0; cursor: pointer;
                 font: inherit; }
header.bh .ctl:hover { color: var(--ink); }

/* Language: a two-cell switch, TR | EN. Both are plain links to the same page in the other language,
   so it works without JavaScript; the current one is filled. */
header.bh .langsw { padding: 2px; gap: 2px; }
header.bh .langsw a { display: grid; place-items: center; height: 24px; min-width: 28px; padding: 0 5px; border-radius: 6px;
                      font-size: 11.5px; font-weight: 650; letter-spacing: .04em; color: var(--ink-faint, var(--ink-soft));
                      text-decoration: none; }
header.bh .langsw a:hover { color: var(--ink); }
header.bh .langsw a[aria-current] { background: color-mix(in srgb, var(--ink) 13%, transparent); color: var(--ink); }

header.bh .theme-btn { width: 30px; justify-content: center; }
header.bh .theme-btn svg { width: 16px; height: 16px; }
header.bh .theme-btn .moon { display: none; }
:root[data-theme="light"] header.bh .theme-btn .sun { display: none; }
:root[data-theme="light"] header.bh .theme-btn .moon { display: block; }
@media (prefers-color-scheme: light) {
    :root:not([data-theme="dark"]) header.bh .theme-btn .sun { display: none; }
    :root:not([data-theme="dark"]) header.bh .theme-btn .moon { display: block; }
}

@media (max-width: 760px) {
    header.bh nav { display: none; }
    header.bh .tools { margin-left: auto; padding-left: 0; border-left: 0; }
}
@media (max-width: 420px) {
    header.bh .wrap { padding: 0 16px; }
    header.bh .hub { display: none; }   /* the footer carries it on a narrow phone */
}
header.bh .langsw a[aria-disabled] { opacity: .35; cursor: default; }
