.aurum-topbar {
  position: fixed;
  z-index: 80;
  top: 0;
  right: 0;
  left: var(--aurum-sidebar-width);

  min-height: var(--aurum-topbar-height);
  padding: 0 clamp(22px, 3vw, 48px);

  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;

  background: rgba(7, 9, 13, .76);
  border-bottom: 1px solid rgba(215, 177, 91, .08);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .018);

  backdrop-filter: blur(18px) saturate(130%);
  -webkit-backdrop-filter: blur(18px) saturate(130%);

  transition:
    left 220ms ease,
    background 180ms ease,
    border-color 180ms ease,
    box-shadow 180ms ease;
}

.aurum-topbar.is-scrolled {
  background: rgba(7, 9, 13, .9);
  border-bottom-color: rgba(215, 177, 91, .14);
  box-shadow:
    0 10px 32px rgba(0, 0, 0, .18),
    0 1px 0 rgba(215, 177, 91, .025);
}

html[data-theme="light"] .aurum-topbar {
  background: rgba(241, 242, 244, .8);
  border-bottom-color: rgba(156, 116, 37, .09);
}

html[data-theme="light"] .aurum-topbar.is-scrolled {
  background: rgba(241, 242, 244, .93);
  border-bottom-color: rgba(156, 116, 37, .15);
  box-shadow:
    0 10px 30px rgba(25, 28, 35, .09),
    0 1px 0 rgba(156, 116, 37, .035);
}

body.aurum-sidebar-collapsed .aurum-topbar {
  left: var(--aurum-sidebar-collapsed-width);
}

.aurum-topbar__heading {
  min-width: 0;

  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
}

.aurum-topbar__heading strong {
  overflow: hidden;

  color: var(--aurum-text);
  font-size: 20px;
  font-weight: 760;
  letter-spacing: -.025em;
  line-height: 1.15;

  text-overflow: ellipsis;
  white-space: nowrap;
}

.aurum-topbar__heading span {
  overflow: hidden;

  color: var(--aurum-muted);
  font-size: 11.5px;
  font-weight: 500;
  line-height: 1.3;

  text-overflow: ellipsis;
  white-space: nowrap;
}

.aurum-topbar__actions {
  flex: 0 0 auto;

  display: flex;
  align-items: center;
  gap: 9px;
}

.aurum-topbar__icon-button {
  width: 40px !important;
  min-width: 40px !important;
  height: 40px !important;
  min-height: 40px !important;

  border-radius: 50% !important;
}

.aurum-topbar__icon-button:hover {
  color: var(--aurum-gold-bright) !important;
  background: var(--aurum-gold-soft) !important;
  border-color: var(--aurum-border-strong) !important;
  box-shadow: 0 8px 22px rgba(0, 0, 0, .12) !important;
  transform: translateY(-1px) !important;
}

.aurum-topbar-profile {
  min-width: 0;
  padding: 5px 12px 5px 6px;

  display: flex;
  align-items: center;
  gap: 10px;

  color: var(--aurum-text);
  background:
    linear-gradient(145deg, rgba(255, 255, 255, .018), transparent 70%),
    var(--aurum-panel);
  border: 1px solid var(--aurum-border);
  border-radius: 999px;
  box-shadow: 0 7px 22px rgba(0, 0, 0, .08);

  transition:
    background var(--aurum-transition),
    border-color var(--aurum-transition),
    transform var(--aurum-transition),
    box-shadow var(--aurum-transition);
}

.aurum-topbar-profile:hover {
  background: var(--aurum-panel-raised);
  border-color: var(--aurum-border-strong);
  box-shadow: 0 9px 26px rgba(0, 0, 0, .12);
  transform: translateY(-1px);
}

.aurum-topbar-profile .aurum-avatar {
  width: 32px;
  height: 32px;
  flex-basis: 32px;
}

.aurum-topbar-profile__text {
  min-width: 0;

  display: flex;
  flex-direction: column;
  justify-content: center;
}

.aurum-topbar-profile__text strong {
  max-width: 150px;
  overflow: hidden;

  color: var(--aurum-text);
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.2;

  text-overflow: ellipsis;
  white-space: nowrap;
}

.aurum-topbar-profile__text span {
  color: var(--aurum-muted);
  font-size: 10px;
  line-height: 1.25;
  text-transform: capitalize;
}

.aurum-logout {
  margin: 0;
}

.aurum-theme-icon {
  width: 18px;
  height: 18px;

  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

html[data-theme="dark"] .aurum-theme-icon--moon,
html[data-theme="light"] .aurum-theme-icon--sun {
  display: none;
}

@media (max-width: 900px) {
  .aurum-topbar,
  body.aurum-sidebar-collapsed .aurum-topbar {
    top: 62px;
    left: 0;

    min-height: 44px;
    padding: 0 14px;
    gap: 12px;
  }

  .aurum-topbar__heading {
    gap: 0;
  }

  .aurum-topbar__heading strong {
    font-size: 13px;
  }

  .aurum-topbar__heading span {
    display: none;
  }

  .aurum-topbar-profile {
    display: none;
  }

  .aurum-topbar__actions {
    gap: 6px;
  }

  .aurum-topbar__icon-button {
    width: 34px !important;
    min-width: 34px !important;
    height: 34px !important;
    min-height: 34px !important;
  }
}

@media (max-width: 480px) {
  .aurum-topbar__heading strong {
    max-width: 44vw;
  }
}
