.global-header {
  position: sticky;
  z-index: 20;
  top: 0;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  width: 100%;
  min-height: 76px;
  margin: 0;
  padding: 12px max(24px, calc((100vw - 1180px) / 2));
  border-bottom: 1px solid rgba(31, 43, 61, 0.08);
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(16px);
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

.global-header.scrolled {
  border-color: #e9edf2;
  box-shadow: 0 8px 24px rgba(28, 39, 56, 0.06);
}

.global-brand {
  display: inline-flex;
  align-items: center;
  justify-self: start;
  gap: 10px;
  width: max-content;
  color: #111827;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.025em;
  text-decoration: none;
}

.global-brand img {
  display: block;
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.global-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.global-nav a {
  color: #4b5563;
  font-size: 15px;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  transition: color 160ms ease;
}

.global-nav a:hover,
.global-nav a.active {
  color: #2468ee;
}

.global-nav a.active {
  color: #1f5fd8;
  font-weight: 650;
}

.global-action {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  justify-self: end;
  padding: 0 16px;
  border: 1px solid #cfd7e3;
  border-radius: 10px;
  color: #293548;
  background: #fff;
  font-size: 14px;
  font-weight: 620;
  text-decoration: none;
  transition: border-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.global-actions {
  display: flex;
  align-items: center;
  justify-self: end;
  gap: 10px;
}

.global-actions [hidden] { display: none !important; }

.global-login {
  display: inline-flex;
  min-height: 42px;
  align-items: center;
  justify-content: center;
  padding: 0 17px;
  border: 1px solid #2468ee;
  border-radius: 8px;
  background: #2468ee;
  color: #fff;
  font-size: 14px;
  font-weight: 620;
  text-decoration: none;
}

.global-login:hover { background: #1958d0; }

.global-account { position: relative; flex: none; }
.global-account summary {
  display: grid;
  width: 42px;
  height: 42px;
  place-items: center;
  border: 1px solid #bfd2f8;
  border-radius: 50%;
  background: #e8f0ff;
  color: #1f5bd6;
  cursor: pointer;
  font-size: 15px;
  font-weight: 720;
  list-style: none;
}
.global-account summary::-webkit-details-marker { display: none; }
.global-account summary:hover { border-color: #2468ee; }
.global-account-menu {
  position: absolute;
  top: calc(100% + 12px);
  right: 0;
  z-index: 30;
  display: grid;
  width: min(280px, calc(100vw - 24px));
  gap: 4px;
  padding: 16px;
  border: 1px solid #dce4ef;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 30px rgba(24, 39, 62, .12);
  color: #273142;
}
.global-account-menu strong,
.global-account-menu span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.global-account-menu strong { font-size: 14px; }
.global-account-menu span { margin-bottom: 10px; color: #647084; font-size: 12px; }
.global-account-menu a,
.global-account-menu button {
  width: 100%;
  padding: 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #354154;
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  text-align: left;
  text-decoration: none;
}
.global-account-menu a:hover,
.global-account-menu button:hover { background: #f1f5fb; }
.global-action:focus-visible,
.global-login:focus-visible,
.global-account summary:focus-visible,
.global-account-menu :focus-visible { outline: 2px solid #2468ee; outline-offset: 3px; }

.locale-switch {
  display: inline-flex;
  align-items: center;
  padding: 3px;
  border: 1px solid #d8e0ea;
  border-radius: 9px;
  background: #f3f6fa;
}

.locale-switch button {
  min-width: 34px;
  height: 30px;
  padding: 0 8px;
  border: 0;
  border-radius: 6px;
  color: #667085;
  background: transparent;
  cursor: pointer;
  font: inherit;
  font-size: 13px;
  font-weight: 620;
}

.locale-switch button.active {
  color: #1f56bf;
  background: #fff;
  box-shadow: 0 1px 3px rgba(24, 39, 62, 0.1);
}

.locale-switch button:focus-visible {
  outline: 2px solid #2468ee;
  outline-offset: 1px;
}

.global-action:hover {
  border-color: #9dacbf;
  color: #2468ee;
  transform: translateY(-1px);
}

@media (max-width: 860px) {
  .global-header { grid-template-columns: 1fr auto; }
  .global-nav { display: none; }
}

@media (max-width: 760px) {
  .global-header {
    min-height: 64px;
    padding: 10px 18px;
  }

  .global-brand img {
    width: 29px;
    height: 29px;
  }

  .global-action {
    min-height: 40px;
    padding: 0 12px;
  }

  .global-actions { gap: 7px; }
  .locale-switch button { min-width: 31px; padding: 0 6px; }
}

@media (max-width: 400px) {
  .global-header { padding-inline: 12px; }
  .global-actions { gap: 6px; }
  .global-action { padding-inline: 9px; }
  .global-account summary { width: 38px; height: 38px; }
}

@media (max-width: 350px) {
  .global-brand span { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .global-header,
  .global-action,
  .global-nav a {
    transition-duration: 0.01ms !important;
  }
}
