.availability-bar {
  --line: #e4e9ee;
  --header-blue: #2870cb;
  min-height: 47px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 9px 24px;
  border-bottom: 1px solid #e2edf0;
  background: #eff8fa;
  color: #586b77;
  font-size: 13px;
}

.availability-bar p {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 5px;
  margin: 0;
}

.availability-bar strong {
  color: #21695f;
  font-weight: 700;
}

.availability-bar > a {
  color: var(--header-blue);
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: #b7cdea;
  text-underline-offset: 3px;
  white-space: nowrap;
}

.availability-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 8px;
  border-radius: 50%;
  background: #2aa982;
  box-shadow: 0 0 0 4px rgb(42 169 130 / 12%);
}

.site-header {
  --ink: #172534;
  --line: #e4e9ee;
  --muted: #596675;
  --header-blue: #2870cb;
  width: 100%;
  max-width: none;
  min-height: 0;
  display: block;
  margin: 0;
  padding: 0;
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: rgb(255 255 255 / 96%);
  backdrop-filter: blur(14px);
}

.header-inner {
  width: min(100% - 68px, 1240px);
  min-height: 72px;
  display: flex;
  align-items: center;
  gap: 30px;
  margin: 0 auto;
}

.site-header .brand {
  flex: 0 0 auto;
  padding: 0;
  border: 0;
  background: none;
  color: var(--ink);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.7px;
}

.site-header a {
  color: inherit;
  text-decoration: none;
}

.site-header button {
  font: inherit;
}

.theme-toggle {
  width: 38px;
  height: 38px;
  display: grid;
  flex: 0 0 38px;
  place-items: center;
  padding: 0;
  border: 1px solid #e2e7ec;
  border-radius: 50%;
  background: #fff;
  color: #2870cb;
  cursor: pointer;
  font-size: 19px;
  line-height: 1;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease;
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
  border-color: #b9cce6;
  background: #f4f8ff;
  color: #1d5cae;
}

.theme-toggle:disabled {
  cursor: wait;
}

.primary-navigation {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: clamp(18px, 2.2vw, 32px);
  margin-left: auto;
}

.primary-navigation > a {
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  transition: color 160ms ease;
}

.primary-navigation > a:hover,
.primary-navigation > a:focus-visible {
  color: var(--header-blue);
}

.primary-navigation .resume-link {
  padding: 10px 19px;
  border: 1px solid #d9e0e7;
  border-radius: 999px;
  color: var(--ink);
  font-weight: 700;
  transition: border-color 160ms ease, background 160ms ease, color 160ms ease;
}

.primary-navigation .resume-link:hover,
.primary-navigation .resume-link:focus-visible {
  border-color: #c3d5eb;
  background: #f5f9fe;
  color: var(--header-blue);
}

.language-switcher {
  display: flex;
  flex: 0 0 auto;
  gap: 3px;
  padding: 4px;
  border: 1px solid #e2e7ec;
  border-radius: 999px;
  background: #f3f5f7;
}

.language-switcher button {
  min-width: 39px;
  min-height: 29px;
  padding: 4px 8px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #75808a;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  transition: background 160ms ease, color 160ms ease, box-shadow 160ms ease;
}

.language-switcher button[aria-pressed="true"] {
  background: #fff;
  color: var(--header-blue);
  box-shadow: 0 1px 4px rgb(22 39 55 / 12%);
}

.menu-toggle {
  display: none;
}

.site-header :focus-visible,
.availability-bar a:focus-visible {
  outline: 3px solid #78a8e4;
  outline-offset: 3px;
}

@media (max-width: 850px) {
  .header-inner {
    width: min(100% - 40px, 1240px);
    gap: 20px;
  }

  .primary-navigation {
    gap: 17px;
  }

  .primary-navigation > a {
    font-size: 13px;
  }
}

@media (max-width: 700px) {
  .availability-bar {
    gap: 7px;
    padding: 9px 14px;
    font-size: 12px;
  }

  .header-inner {
    min-height: 66px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto auto;
    gap: 12px;
  }

  .site-header .brand {
    font-size: 17px;
  }

  .menu-toggle {
    width: 38px;
    height: 38px;
    display: flex;
    grid-column: 2;
    grid-row: 1;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
  }

  .menu-toggle span {
    width: 15px;
    height: 1.5px;
    background: var(--ink);
    transition: transform 160ms ease;
  }

  .site-header[data-menu-open="true"] .menu-toggle span:first-child {
    transform: translateY(3.25px) rotate(45deg);
  }

  .site-header[data-menu-open="true"] .menu-toggle span:last-child {
    transform: translateY(-3.25px) rotate(-45deg);
  }

  .language-switcher {
    grid-column: 4;
    grid-row: 1;
  }

  .theme-toggle {
    grid-column: 3;
    grid-row: 1;
  }

  .primary-navigation {
    display: none;
    grid-column: 1 / -1;
    grid-row: 2;
    align-items: stretch;
    gap: 0;
    margin: 0;
    padding: 4px 0 16px;
  }

  .site-header[data-menu-open="true"] .primary-navigation {
    display: flex;
    flex-direction: column;
  }

  .primary-navigation > a {
    padding: 12px 4px;
    border-top: 1px solid #edf0f3;
    font-size: 14px;
  }

  .primary-navigation .resume-link {
    align-self: flex-start;
    margin-top: 10px;
    padding: 9px 18px;
    border: 1px solid #d9e0e7;
  }
}

@media (max-width: 420px) {
  .availability-bar {
    flex-wrap: wrap;
  }

  .header-inner {
    width: calc(100% - 28px);
    gap: 8px;
  }

  .language-switcher {
    gap: 1px;
    padding: 3px;
  }

  .language-switcher button {
    min-width: 34px;
    padding: 4px 6px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
