.hx-announce-head {
  position: relative;
  padding-right: 48px;
}

.hx-announce-close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 5px;
  color: #777;
  background: #151515;
  cursor: pointer;
  transition: border-color 0.18s ease, color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.hx-announce-close:hover,
.hx-announce-close:focus-visible {
  border-color: rgba(248, 231, 28, 0.45);
  color: #f8e71c;
  background: #191919;
  outline: 0;
  transform: translateY(-1px);
}

#dropdown.hx-announce {
  --hx-announcement-anchor-x: calc(100% - 28px);
  position: fixed !important;
  inset: auto;
  width: min(520px, calc(100vw - 24px));
  height: min(620px, calc(100dvh - 24px));
}

#dropdown.hx-announce .hx-announce-anchor {
  position: absolute;
  z-index: 8;
  top: 0;
  left: var(--hx-announcement-anchor-x);
  width: 34px;
  height: 3px;
  border-radius: 0 0 999px 999px;
  background: #f8e71c;
  box-shadow: 0 0 14px rgba(248, 231, 28, 0.42);
  pointer-events: none;
  transform: translateX(-50%);
}

#dropdown.hx-announce.is-above-trigger .hx-announce-anchor {
  top: auto;
  bottom: 0;
  border-radius: 999px 999px 0 0;
}

#dropdown.hx-announce .hx-announce-head {
  grid-template:
    "heading close" auto
    "tools tools" auto /
    minmax(0, 1fr) 34px;
  gap: 10px 12px;
  padding: 16px 18px 12px !important;
}

#dropdown.hx-announce .hx-announce-heading {
  grid-area: heading;
  gap: 5px;
}

#dropdown.hx-announce .hx-announce-close {
  position: static;
  grid-area: close;
  align-self: start;
}

#dropdown.hx-announce .hx-announce-tools {
  display: flex;
  min-width: 0;
  grid-area: tools;
  align-items: stretch;
  gap: 8px;
}

#dropdown.hx-announce .hx-announce-status {
  display: flex;
  min-height: 32px;
  min-width: 0;
  flex: 1 1 auto;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  padding: 6px 9px;
  text-align: left;
}

#dropdown.hx-announce .hx-announce-status > span {
  min-width: 0;
  margin-right: auto;
  white-space: nowrap;
}

#dropdown.hx-announce .hx-announce-status > strong {
  flex: 0 0 auto;
  margin: 0;
  font-size: 13px;
}

#dropdown.hx-announce .hx-announce-status > small {
  flex: 0 0 auto;
  margin: 0;
  white-space: nowrap;
}

#dropdown.hx-announce .hx-announce-read-all {
  display: flex;
  width: auto;
  min-height: 32px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 6px 10px;
  border: 1px solid rgba(248, 231, 28, 0.2);
  border-radius: 4px;
  color: #a69d3e;
  background: rgba(248, 231, 28, 0.045);
  font-family: "JetBrains Mono", "Courier New", monospace;
  font-size: 6px;
  font-weight: 850;
  letter-spacing: 0.055em;
  line-height: 1.25;
  text-align: center;
  text-transform: uppercase;
  transition: border-color 0.18s ease, color 0.18s ease, background 0.18s ease;
}

#dropdown.hx-announce .hx-announce-read-all:hover:not(:disabled),
#dropdown.hx-announce .hx-announce-read-all:focus-visible {
  border-color: rgba(248, 231, 28, 0.55);
  color: #f8e71c;
  background: rgba(248, 231, 28, 0.1);
  outline: 0;
}

#dropdown.hx-announce .hx-announce-read-all:disabled {
  cursor: default;
  opacity: 0.38;
}

#dropdown.hx-announce .hx-announce-read-all.is-loading i {
  animation: hxAnnouncementPulse 0.8s ease-in-out infinite;
}

#dropdown.hx-announce .hx-announce-body {
  display: block;
  min-height: 0;
  padding-bottom: 16px;
  overflow-x: hidden;
  overflow-y: auto !important;
  overscroll-behavior: contain;
  touch-action: pan-y;
}

#dropdown.hx-announce .hx-note,
#dropdown.hx-announce .hx-note-content,
#dropdown.hx-announce .hx-note-body {
  max-height: none !important;
}

#dropdown.hx-announce .hx-note {
  display: grid;
  width: 100%;
  height: auto !important;
  min-height: max-content;
  grid-template-columns: 30px minmax(0, 1fr);
  align-items: stretch;
  margin-bottom: 8px;
  overflow: visible !important;
}

#dropdown.hx-announce .hx-note:last-child {
  margin-bottom: 0;
}

#dropdown.hx-announce .hx-note-content {
  display: flex;
  width: 100%;
  height: auto !important;
  min-width: 0;
  flex-direction: column;
  align-items: stretch;
  gap: 5px;
  overflow: visible;
}

#dropdown.hx-announce .hx-note-content > * {
  width: 100%;
  height: auto !important;
  max-height: none !important;
  flex: 0 0 auto;
  overflow: visible !important;
  clip: auto !important;
}

#dropdown.hx-announce .hx-note-meta {
  display: grid;
  width: 100%;
  min-width: 0;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 5px 12px;
}

#dropdown.hx-announce .hx-note-meta em,
#dropdown.hx-announce .hx-note-meta time,
#dropdown.hx-announce .hx-note-title,
#dropdown.hx-announce .hx-note-body,
#dropdown.hx-announce .hx-note-state {
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: normal;
}

#dropdown.hx-announce .hx-note-meta em {
  white-space: normal;
}

#dropdown.hx-announce .hx-note-meta time {
  white-space: nowrap;
  text-align: right;
}

#dropdown.hx-announce .hx-note-title,
#dropdown.hx-announce .hx-note-body {
  display: block !important;
  width: 100%;
  height: auto !important;
  overflow: visible !important;
  white-space: pre-wrap;
  -webkit-line-clamp: unset !important;
  line-clamp: unset !important;
}

#dropdown.hx-announce .hx-note-title {
  padding: 1px 0;
  line-height: 1.45;
  white-space: normal;
}

#dropdown.hx-announce .hx-note-body {
  padding: 1px 0;
  line-height: 1.6;
}

#dropdown.hx-announce .hx-note-state {
  display: flex;
  width: 100%;
  flex-wrap: wrap;
  row-gap: 4px;
  line-height: 1.35;
}

#dropdown.hx-announce .hx-note-state small {
  flex: 0 0 auto;
  white-space: nowrap;
}

@media (max-width: 460px) {
  #dropdown.hx-announce {
    width: calc(100vw - 20px);
  }

  #dropdown.hx-announce .hx-announce-head {
    padding: 14px 14px 11px !important;
  }

  #dropdown.hx-announce .hx-announce-tools {
    gap: 6px;
  }

  #dropdown.hx-announce .hx-announce-status {
    gap: 6px;
    padding-right: 7px;
    padding-left: 7px;
  }

  #dropdown.hx-announce .hx-announce-status > small {
    display: none;
  }

  #dropdown.hx-announce .hx-announce-read-all {
    padding-right: 8px;
    padding-left: 8px;
  }

  #dropdown.hx-announce .hx-note-meta {
    grid-template-columns: minmax(0, 1fr);
    gap: 3px;
  }

  #dropdown.hx-announce .hx-note-meta time {
    text-align: left;
    white-space: normal;
  }
}

@media (max-width: 1023px) {
  .nx-headerbar,
  body.navbar-collapsed .nx-header-menu {
    background: #101010 !important;
  }

  body.navbar-collapsed::before {
    display: none !important;
  }

  body.navbar-collapsed .nx-header-menu {
    position: absolute !important;
    top: 81px !important;
    right: auto !important;
    left: 50% !important;
    display: grid !important;
    width: 100vw !important;
    grid-template-columns: minmax(0, 1fr) !important;
    align-content: start !important;
    gap: 16px !important;
    padding: 29px 16px 20px !important;
    box-shadow: none;
    transform: translateX(-50%);
  }

  body.navbar-collapsed .nx-header-account {
    width: 282px !important;
    max-width: 100%;
    margin-top: 10px;
    justify-self: center;
    justify-content: center !important;
    gap: 12px !important;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  }

  body.navbar-collapsed .nx-header-account--empty {
    display: none !important;
  }

  body.navbar-collapsed .nx-header-actions {
    display: grid !important;
    grid-template-columns: repeat(5, 42px) !important;
    width: 246px !important;
    max-width: 100%;
    justify-self: center;
    justify-content: center !important;
    align-items: center !important;
    column-gap: 9px !important;
    row-gap: 14px !important;
  }

  body.navbar-collapsed .nx-header-actions > div,
  body.navbar-collapsed .nx-header-actions > a {
    display: flex !important;
    justify-content: center !important;
    margin: 0 !important;
  }

  body.navbar-collapsed .nx-header-actions--logged {
    grid-template-columns: repeat(6, 42px) !important;
    width: 302px !important;
    column-gap: 10px !important;
  }

  body.navbar-collapsed #loggedHeaderActions {
    display: grid !important;
    width: 302px !important;
    max-width: 302px !important;
    grid-template-columns: repeat(6, 42px) !important;
    column-gap: 10px !important;
    justify-self: center !important;
    margin-right: auto !important;
    margin-left: auto !important;
  }

  body.navbar-collapsed #loggedHeaderActions > .nx-header-signout {
    grid-column: 6 !important;
    grid-row: 1 !important;
  }

  body.navbar-collapsed #loggedHeaderActions > .nx-header-balance--logged {
    grid-column: 1 / -1 !important;
    grid-row: 2 !important;
  }

  body.navbar-collapsed .nx-header-actions--logged > :not(.nx-header-balance--logged) {
    order: 1;
  }

  body.navbar-collapsed .nx-header-actions > .balance-badge-wrap {
    grid-column: span 2 !important;
  }

  body.navbar-collapsed .nx-header-actions > .nx-header-balance--logged {
    order: 2;
    grid-column: 2 / 6 !important;
    width: 100% !important;
  }

  body.navbar-collapsed .nx-header-actions--guest > .nx-header-guest-balance {
    display: none !important;
  }

  body.navbar-collapsed .nx-header-actions > .nx-header-signout {
    order: 1;
    grid-column: span 1 !important;
    width: 42px !important;
  }

  body.navbar-collapsed .nx-header-actions > .balance-badge-wrap + .down,
  body.navbar-collapsed .nx-header-actions > .balance-badge-wrap + a {
    grid-column: span 3 !important;
    width: 100% !important;
  }

  body.navbar-collapsed .nx-header-actions > .nx-header-balance--logged + .nx-header-signout {
    order: 1;
    grid-column: span 1 !important;
    width: 42px !important;
  }

  body.navbar-collapsed .nx-header-actions > .balance-badge-wrap + .down form,
  body.navbar-collapsed .nx-header-actions > .balance-badge-wrap + .down button,
  body.navbar-collapsed .nx-header-actions > .balance-badge-wrap + a,
  body.navbar-collapsed .nx-header-actions .balance-badge {
    width: 100% !important;
  }

  body.navbar-collapsed .nx-header-actions > .nx-header-signout form,
  body.navbar-collapsed .nx-header-actions > .nx-header-signout button {
    width: 42px !important;
  }

  body.navbar-collapsed .nx-header-actions .balance-badge {
    justify-content: center;
  }

  body.navbar-collapsed .nx-header-actions--logged > .nx-header-balance--logged {
    grid-column: 1 / -1 !important;
    width: 100% !important;
  }

  body.navbar-collapsed .nx-header-login-wrap > .nx-header-login {
    display: flex !important;
    width: 100% !important;
    align-items: center;
    justify-content: center !important;
    text-align: center;
  }

  body.navbar-collapsed #guestHeaderActions {
    display: grid !important;
    width: 258px !important;
    max-width: 258px !important;
    grid-template-columns: repeat(5, 42px) !important;
    column-gap: 12px !important;
    justify-self: center !important;
    margin-right: auto !important;
    margin-left: auto !important;
  }

  body.navbar-collapsed #guestHeaderActions > .nx-header-login-wrap {
    grid-column: 1 / -1 !important;
    width: 100% !important;
  }

  #dropdown.hx-announce .hx-announce-head {
    grid-template-columns: minmax(0, 1fr) 34px;
    padding: 14px 14px 11px !important;
  }

  body .viewas-wrap .viewas-menu {
    position: fixed !important;
    z-index: 10000 !important;
    top: 92px !important;
    right: 12px !important;
    left: 12px !important;
    width: auto !important;
    min-width: 0 !important;
    max-width: none !important;
    max-height: calc(100dvh - 108px);
    overflow-y: auto;
    transform: translateY(-6px) !important;
  }

  body .viewas-wrap.is-open .viewas-menu {
    transform: translateY(0) !important;
  }

  body .viewas-wrap .viewas-menu form {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto;
  }

  body .viewas-wrap .viewas-menu input {
    min-width: 0 !important;
    width: 100%;
  }
}

@media (max-width: 360px) {
  body.navbar-collapsed .nx-header-actions {
    grid-template-columns: repeat(5, 38px) !important;
    width: 214px !important;
    column-gap: 6px !important;
  }

  body.navbar-collapsed .nx-header-actions--logged {
    grid-template-columns: repeat(6, 38px) !important;
    width: 268px !important;
  }

  body.navbar-collapsed #loggedHeaderActions {
    width: 268px !important;
    max-width: 268px !important;
    grid-template-columns: repeat(6, 38px) !important;
    column-gap: 8px !important;
  }

  body.navbar-collapsed .nx-header-account {
    width: 258px !important;
  }

  body.navbar-collapsed .nx-header-actions .hx-btn {
    width: 38px !important;
    min-width: 38px !important;
    height: 38px !important;
    padding: 0 !important;
  }

  body.navbar-collapsed .nx-header-actions > .nx-header-signout,
  body.navbar-collapsed .nx-header-actions > .nx-header-signout form,
  body.navbar-collapsed .nx-header-actions > .nx-header-signout button {
    width: 38px !important;
  }

  body.navbar-collapsed #guestHeaderActions {
    width: 222px !important;
    max-width: 222px !important;
    grid-template-columns: repeat(5, 38px) !important;
    column-gap: 8px !important;
  }
}
