/* Shared navigation across the new pages and preserved supporting content. */
:root {
  --ha-header-height: 80px;
}
html {
  scroll-padding-top: calc(var(--ha-header-height) + 20px);
}
body .site-header {
  box-sizing: border-box;
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 80px;
  height: auto;
  padding: 14px clamp(22px, 5.5vw, 88px);
  background: var(--ha-ink);
  color: var(--ha-paper);
  border: 0;
  border-bottom: 1px solid color-mix(in srgb, var(--ha-paper) 8%, transparent);
  font-family: Manrope, system-ui, sans-serif;
}
body .site-header .brand,
body .ha-footer .brand {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 0;
  margin: 0;
  width: max-content;
  max-width: 100%;
  font:
    500 29px/1.2 Manrope,
    system-ui,
    sans-serif;
  letter-spacing: -0.04em;
  text-decoration: none;
  white-space: nowrap;
  color: var(--ha-bloom);
}
body .site-header .brand img,
body .ha-footer .brand img {
  display: block;
  width: 28px;
  height: 28px;
}
body .site-header .brand strong,
body .ha-footer .brand strong {
  font-weight: 800;
}
body .site-header .brand sup,
body .ha-footer .brand sup {
  position: relative;
  top: -1em;
  font-size: 8px;
  letter-spacing: 0;
  margin-left: 3px;
}
body .site-header nav.desktop-navigation {
  display: flex;
  align-items: center;
  gap: clamp(18px, 2.7vw, 40px);
  font-size: 14px;
}
body .site-header nav a {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 0;
  color: var(--ha-paper);
  text-decoration: none;
  font-weight: 500;
  border-bottom: 2px solid transparent;
  box-sizing: border-box;
}
body .site-header nav a:hover,
body .site-header nav a[aria-current="page"] {
  border-bottom-color: var(--ha-bloom);
  text-decoration: none;
}
body .site-header nav a[aria-current="page"] {
  font-weight: 750;
}
body .site-header nav a.nav-portal {
  clip-path: none;
  border-radius: 0;
  background: none;
  color: var(--ha-soft-on-dark);
  font-weight: 500;
  transform: none;
  font-size: 13px;
  padding: 8px 0;
}
body .site-header nav a.nav-portal:after {
  display: none;
}
body .site-header .mobile-navigation {
  display: none;
}
body .site-header :focus-visible {
  outline: 3px solid var(--ha-bloom);
  outline-offset: 4px;
}
body .ha-footer {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 36px;
  margin: 0;
  padding: 60px clamp(22px, 5.5vw, 88px) 120px;
  background: var(--ha-ink);
  color: var(--ha-paper);
  font:
    14px/1.65 Manrope,
    system-ui,
    sans-serif;
  border-top: 1px solid color-mix(in srgb, var(--ha-paper) 13%, transparent);
}
.ha-footer a {
  color: inherit;
}
.ha-footer p {
  margin: 18px 0 0;
  max-width: 75ch;
}
.ha-footer nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 28px;
}
.ha-footer nav a {
  display: flex;
  align-items: center;
  min-height: 44px;
  text-underline-offset: 4px;
  text-decoration-color: color-mix(in srgb, var(--ha-paper) 35%, transparent);
}
.ha-footer .footer-email {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-size: 16px;
}
.ha-footer .footer-legal {
  grid-column: 1/-1;
  color: var(--ha-soft-on-dark);
  font-size: 12px;
}
.ha-footer :focus-visible {
  outline: 3px solid var(--ha-bloom);
  outline-offset: 4px;
}
.menu-open {
  display: none;
}
@media (max-width: 900px) {
  :root {
    --ha-header-height: 70px;
  }
  body .site-header {
    min-height: 70px;
    padding: 12px 22px;
    gap: 12px;
  }
  body .site-header .brand {
    font-size: 26px;
    gap: 8px;
  }
  body .site-header .brand img {
    width: 24px;
    height: 24px;
  }
  body .site-header nav.desktop-navigation {
    display: none;
  }
  body .site-header .mobile-navigation {
    display: block;
    position: static;
    padding: 0;
    margin: 0;
    background: none;
  }
  body .site-header .mobile-navigation summary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-width: 80px;
    min-height: 44px;
    list-style: none;
    font:
      500 15px/1.2 Manrope,
      sans-serif;
    padding: 8px 0;
    border: 0;
    border-radius: 0;
    color: var(--ha-paper);
    background: transparent;
    cursor: pointer;
  }
  body .site-header .mobile-navigation summary::-webkit-details-marker {
    display: none;
  }
  .menu-glyph {
    display: block;
    width: 18px;
    height: 14px;
    background:
      linear-gradient(currentColor, currentColor) 0 0/100% 1px no-repeat,
      linear-gradient(currentColor, currentColor) 0 50%/100% 1px no-repeat,
      linear-gradient(currentColor, currentColor) 0 100%/100% 1px no-repeat;
  }
  .menu-glyph:before,
  .menu-glyph:after {
    display: none !important;
  }
  .mobile-navigation[open] .menu-closed {
    display: none;
  }
  .mobile-navigation[open] .menu-open {
    display: inline;
  }
  .mobile-navigation[open] .menu-glyph {
    background:
      linear-gradient(
        45deg,
        transparent 46%,
        currentColor 48% 52%,
        transparent 54%
      ),
      linear-gradient(
        -45deg,
        transparent 46%,
        currentColor 48% 52%,
        transparent 54%
      );
  }
  body .site-header .mobile-navigation nav {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    top: 100%;
    left: 0;
    right: 0;
    max-height: calc(100dvh - var(--ha-header-height));
    overflow: auto;
    padding: 16px 22px 24px;
    background: var(--ha-ink);
    border: 0;
    border-radius: 0;
    box-shadow: 0 16px 30px rgba(var(--ha-ink-rgb), 0.15);
    animation: none;
  }
  body .site-header .mobile-navigation nav a {
    padding: 12px 8px;
    min-height: 48px;
    font-size: 17px;
  }
  body .site-header .mobile-navigation nav a.nav-portal {
    margin-top: 8px;
    font-size: 15px;
  }
}
@media (max-width: 600px) {
  body .ha-footer {
    grid-template-columns: 1fr;
    padding-bottom: 120px;
  }
  .ha-footer .footer-legal {
    grid-column: 1;
  }
  .ha-footer .brand {
    font-size: 27px;
  }
  .ha-footer nav {
    grid-template-columns: 1fr 1fr;
  }
  body .site-header {
    padding-inline: 18px;
  }
  body .site-header .brand {
    font-size: 23px;
  }
  .ha-footer .footer-email {
    font-size: 15px;
  }
}

/* Restore the portal's folded HumanAmp label. */
body .site-header nav a.nav-portal {
  position: relative;
  padding: 10px 22px 10px 15px;
  background: var(--ha-ink-raised);
  color: var(--ha-paper);
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 12px), calc(100% - 12px) 100%, 0 100%);
  border-bottom: 0;
}
body .site-header nav a.nav-portal:after {
  content: "";
  display: block;
  position: absolute;
  right: 0;
  bottom: 0;
  width: 12px;
  height: 12px;
  background: var(--ha-bloom);
  clip-path: polygon(0 0, 100% 0, 0 100%);
}
