:root {
  color-scheme: light;
  --itsy-page: #f5f7fb;
  --itsy-surface: #fff;
  --itsy-soft: #edf2fa;
  --itsy-ink: #152340;
  --itsy-muted: #52627a;
  --itsy-line: #cbd6e6;
  --itsy-link: #2457d5;
  --itsy-focus: #5278e8;
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --itsy-page: #101827;
  --itsy-surface: #182438;
  --itsy-soft: #213149;
  --itsy-ink: #e7edf7;
  --itsy-muted: #b2c0d4;
  --itsy-line: #445571;
  --itsy-link: #a3bfff;
  --itsy-focus: #b5cdff;
}
html { background: var(--itsy-page); color: var(--itsy-ink); }
.unified-header.common-header {
  direction: inherit;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 10px 20px;
  height: auto;
  min-height: 0;
  padding: 18px 0 0;
  border-bottom: 1px solid var(--itsy-line);
}
.common-header .brand.hub-link {
  justify-self: start;
  display: inline-flex;
  gap: 9px;
  width: max-content;
  color: var(--itsy-ink);
  font-size: 1.2rem;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
}
.common-header .brand-mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  border: 0;
  border-radius: 10px;
  background: #152340;
  color: #a9eede;
  font-size: 1.35rem;
  font-style: italic;
  transform: none;
}
.common-header .brand-mark::before,
.common-header .brand-mark::after { content: none; }
.common-header .brand-dot { color: var(--itsy-link); }
.common-header .layout-controls {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.common-header .language-control {
  display: block;
  width: 172px;
  min-width: 0;
  margin: 0;
}
.common-header .language-control select {
  display: block;
  width: 100%;
  min-width: 0;
  max-width: none;
  height: 44px;
  margin: 0;
  padding: 0 10px;
  border: 1px solid var(--itsy-line);
  border-radius: 9px;
  background: var(--itsy-surface);
  color: var(--itsy-ink);
  font-size: .9375rem;
  cursor: pointer;
}
.theme-toggle {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex: 0 0 44px;
  padding: 10px;
  border: 1px solid var(--itsy-line);
  border-radius: 9px;
  background: var(--itsy-surface);
  color: var(--itsy-ink);
  cursor: pointer;
}
.theme-toggle svg { display: block; width: 22px; height: 22px; }
.theme-toggle .sun { display: none; }
[data-theme="dark"] .theme-toggle .sun { display: block; }
[data-theme="dark"] .theme-toggle .moon { display: none; }
.theme-toggle:hover { background: var(--itsy-soft); }
.common-header .common-navigation {
  grid-column: 1 / -1;
  position: relative;
  z-index: 100;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0 28px;
  min-width: 0;
  margin: 0;
  padding: 0;
}
.common-header .navigation-menu { margin: 0; padding: 0; min-width: 0; }
.common-header .navigation-menu > summary {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  margin: 0;
  padding: 8px 0 12px;
  border-bottom: 3px solid transparent;
  color: var(--itsy-muted);
  font-size: .9375rem;
  font-weight: 650;
  line-height: 1.35;
  text-decoration: none;
  overflow-wrap: anywhere;
  cursor: pointer;
  list-style: none;
}
.common-header .navigation-menu > summary::-webkit-details-marker { display: none; }
.common-header .navigation-menu > summary::after { content: none; }
.common-header .navigation-menu > summary:hover,
.common-header .navigation-menu > summary[data-tools-current],
.common-header .navigation-menu > summary[data-guides-current],
.common-header .navigation-menu[open] > summary {
  color: var(--itsy-link);
  border-bottom-color: var(--itsy-link);
}
.common-header .submenu-links {
  position: absolute;
  inset-inline-start: 0;
  top: 100%;
  z-index: 100;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px 12px;
  box-sizing: border-box;
  width: min(36rem, 100%);
  max-height: 65vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  margin: 0;
  padding: 12px;
  border: 1px solid var(--itsy-line);
  border-radius: 0 0 12px 12px;
  background: var(--itsy-surface);
  box-shadow: 0 12px 24px #0002;
}
.common-header .navigation-menu:not([open]) .submenu-links { display: none; }
.common-header .submenu-links a {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  max-width: 100%;
  padding: 10px;
  border: 0;
  border-radius: 7px;
  color: var(--itsy-muted);
  font-size: .9375rem;
  font-weight: 650;
  line-height: 1.35;
  text-decoration: none;
  overflow-wrap: anywhere;
}
.common-header .submenu-links a:hover,
.common-header .submenu-links a[aria-current] {
  color: var(--itsy-link);
  background: var(--itsy-soft);
}
.common-header .guide-links .guide-index-link {
  grid-column: 1 / -1;
  border-bottom: 1px solid var(--itsy-line);
  border-radius: 0;
  font-weight: 750;
}
.common-header :focus-visible { outline: 3px solid var(--itsy-focus); outline-offset: 3px; }
@media (max-width: 700px) {
  .unified-header.common-header { padding-top: 12px; gap: 6px 12px; }
  .common-header .brand.hub-link { font-size: 1.1rem; }
  .common-header .language-control { width: 140px; }
}
@media (max-width: 480px) {
  .common-header .layout-controls { gap: 6px; }
  .common-header .language-control { width: 104px; }
  .common-header .language-control select { padding: 0 5px; font-size: .875rem; }
  .common-header .brand.hub-link { font-size: 1.0625rem; gap: 7px; }
  .common-header .brand-mark { width: 30px; height: 30px; flex-basis: 30px; }
  .common-header .submenu-links { grid-template-columns: minmax(0, 1fr); }
}
@media print {
  :root, :root[data-theme="dark"] { color-scheme: light; background: #fff; color: #152340; }
  .common-header { display: none !important; }
}
