/* Shared public website navigation */
:root { --tw-header-height: 60px; }
.tw-site-header { position: fixed; inset: 0 0 auto; width: 100%; height: var(--tw-header-height); z-index: 1000; background: #0c174d; color: #fff; border-bottom: 1px solid #ffffff1f; font-family: Cairo,Tahoma,sans-serif; direction: rtl; box-sizing: border-box; }
.tw-site-header *, .tw-site-header *::before, .tw-site-header *::after { box-sizing: border-box; }
.tw-header-inner { width: min(calc(100% - 32px),1160px); height: 100%; margin-inline: auto; display: flex; justify-content: center; align-items: center; gap: 24px; }
.tw-header-logo, .tw-header-cert { display: grid; place-items: center; flex: 0 0 40px; min-height: 44px; text-decoration: none; }
.tw-header-logo img, .tw-header-cert img { width: 32px; height: 32px; object-fit: contain; display: block; }
.tw-header-links { list-style: none; display: flex; align-items: stretch; gap: 26px; height: 100%; padding: 0; margin: 0; }
.tw-header-links li { display: flex; min-width: 0; margin: 0; padding: 0; }
.tw-header-links a { position: relative; display: grid; place-items: center; color: #fff; font-size: 15px; font-weight: 700; line-height: 1.4; text-decoration: none; white-space: nowrap; min-height: 44px; padding: 0 4px; }
.tw-header-links a[aria-current] { color: #ffcc00; }
.tw-header-links a[aria-current]::after { content: ""; position: absolute; inset-inline: 3px; bottom: 4px; height: 2px; border-radius: 2px; background: #ffcc00; }
.tw-header-logo[aria-current] { border-bottom: 2px solid #ffcc00; }
.tw-site-header a:focus-visible { outline: 2px solid #ffcc00; outline-offset: -2px; border-radius: 5px; }
@media (hover:hover) { .tw-header-links a:hover { color: #ffcc00; } }
.tw-site-header[data-layout="blog"] ~ main { padding-top: var(--tw-header-height); }
.tw-site-header ~ main { scroll-margin-top: var(--tw-header-height); }
@media (max-width:768px) {
 :root { --tw-header-height: 54px; }
 .tw-header-inner { width: calc(100% - 16px); gap: 4px; }
 .tw-header-logo, .tw-header-cert { flex-basis: 34px; }
 .tw-header-logo img,.tw-header-cert img { width: 27px; height: 27px; }
 .tw-header-links { flex: 0 1 330px; display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 0; min-width: 0; }
 .tw-header-links li { justify-content: stretch; }
 .tw-header-links a { width: 100%; font-size: clamp(11px,3.1vw,13px); padding: 0 1px; }
 .tw-header-links a[aria-current]::after { inset-inline: 4px; }
}
@media (max-width:340px) {
 .tw-header-inner { width: calc(100% - 8px); gap: 2px; }
 .tw-header-logo,.tw-header-cert { flex-basis: 29px; }
 .tw-header-logo img,.tw-header-cert img { width: 24px; height: 24px; }
}
/* Keep gallery video controls beneath the common navigation. */
body:has(.tw-site-header + .gallery-hud) { --hud-h: calc(var(--tw-header-height) + 40px); }
.tw-site-header + .gallery-hud { top: var(--tw-header-height); height: 40px; }
.tw-site-header + .gallery-hud .hud-home { visibility: hidden; }
