/* Shared with the main site's assets/site-header.css. Keep both copies identical. */
.dystopian-header {
  --header-ink: #0d2442;
  --header-accent: #17487b;
  --header-warm: #a84e14;
  --header-bg: #fff3e6;
  --header-menu: #fffaf1;
  --header-control: #fff8ee;
  --header-line: rgba(12, 38, 70, .16);
  --header-selected: rgba(38, 108, 179, .1);
  display: grid; grid-template-columns: minmax(180px, 1fr) auto auto;
  align-items: center; min-height: 112px;
  background: var(--header-bg); color: var(--header-ink);
  border-bottom: 1px solid var(--header-line);
  border-radius: inherit; border-bottom-left-radius: 0; border-bottom-right-radius: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: normal;
}
.dystopian-header .top-divider { display: none; }
.dystopian-header .brand {
  display: flex; align-items: center; padding: 18px 24px; margin: 0;
  min-width: 0; width: fit-content; text-decoration: none;
}
.dystopian-header .brand-logo { display: grid; place-items: center; width: 96px; height: 86px; }
.dystopian-header .brand-logo img { display: block; width: 92px; height: 86px; object-fit: contain; }
.dystopian-header .tagline { display: grid; gap: 8px; justify-self: end; padding: 0 34px; text-align: right; color: inherit; }
.dystopian-header .tagline strong { font-size: .98rem; font-weight: 700; }
.dystopian-header .tagline span { color: var(--header-warm); font-size: .78rem; font-weight: 900; letter-spacing: 0; text-transform: uppercase; }
.dystopian-header .menu-wrap { position: relative; display: flex; align-items: center; gap: 8px; justify-self: end; margin: 0 26px 0 0; }
.dystopian-header .menu-btn, .dystopian-header .theme-toggle {
  display: grid; place-items: center; flex: 0 0 44px; width: 44px; height: 44px;
  min-height: 44px; padding: 0; margin: 0; border: 1px solid var(--header-line);
  border-radius: 8px; color: var(--header-accent); background: var(--header-control);
  box-shadow: none; cursor: pointer;
}
.dystopian-header .menu-btn svg { display: block; width: 22px; height: 22px; }
.dystopian-header .theme-toggle svg { display: block; width: 21px; height: 21px; }
.dystopian-header .menu-btn:hover, .dystopian-header .theme-toggle:hover { background: var(--header-selected); }
.dystopian-header .site-menu {
  position: absolute; z-index: 20; right: 0; top: 52px;
  width: 220px; min-width: 0; max-width: calc(100vw - 48px);
  max-height: calc(100dvh - 110px); overflow-y: auto;
  display: none; gap: 5px; padding: 12px;
  border: 1px solid var(--header-line); border-radius: 10px;
  background: var(--header-menu); box-shadow: 0 16px 32px rgb(0 0 0 / 16%);
}
.dystopian-header .menu-wrap.menu-open .site-menu { display: grid; }
.dystopian-header .site-menu a {
  display: flex; align-items: center; min-height: 44px; padding: 10px 11px;
  border-radius: 7px; color: var(--header-ink); font-size: .875rem;
  font-weight: 900; line-height: 1.4; text-decoration: none;
}
.dystopian-header .site-menu a:hover, .dystopian-header .site-menu a.active { background: var(--header-selected); color: var(--header-accent); }
.dystopian-header .menu-section { display: grid; gap: 3px; }
.dystopian-header .menu-heading { padding: 8px 11px; color: var(--header-warm); font-size: .75rem; font-weight: 950; line-height: 1.4; letter-spacing: 0; text-transform: uppercase; }
.dystopian-header .site-menu a.subitem { padding-left: 22px; }
.dystopian-header .menu-divider { width: 100%; height: 0; margin: 5px 0; border: 0; border-top: 1px solid var(--header-line); }
.dystopian-header .host-link { justify-content: space-between; gap: 12px; }
.dystopian-header .host-link svg { width: 18px; height: 18px; flex-shrink: 0; }
.dystopian-header :is(a, button):focus-visible { outline: 3px solid var(--header-accent); outline-offset: 2px; }
[data-theme="dark"] .dystopian-header {
  --header-ink: #f5efe7; --header-accent: #93c7fa; --header-warm: #e9bb88;
  --header-bg: #202429; --header-menu: #24282d; --header-control: #30353b;
  --header-line: #636e7b; --header-selected: #203c57;
}
@media (max-width: 980px) {
  .dystopian-header { grid-template-columns: 1fr auto; min-height: 0; }
  .dystopian-header .brand { padding: 14px; }
  .dystopian-header .brand-logo { width: 64px; height: 54px; }
  .dystopian-header .brand-logo img { width: 62px; height: 54px; }
  .dystopian-header .tagline { grid-column: 1 / -1; justify-self: start; text-align: left; padding: 0 14px 14px; }
  .dystopian-header .tagline strong { font-size: .82rem; }
  .dystopian-header .menu-wrap { grid-column: 2; grid-row: 1; margin: 14px 14px 0 0; }
  .dystopian-header .site-menu { top: 48px; }
}
