/* Shared typography, navigation, and interaction polish for account dashboard pages. */

.sidebar-logo,
.topbar-title,
.content h1,
.content h2,
.content h3,
.auth-title,
.prompt-card h1 {
  font-family: var(--font-body, "Newsreader", Georgia, "Times New Roman", serif);
  letter-spacing: -.012em;
}

.nav-item {
  border-radius: 8px;
  transition: color .15s, background .15s;
}

.nav-item.active {
  box-shadow: inset 2px 0 0 var(--accent);
}

.sidebar-user {
  display: flex;
  align-items: center;
  gap: 9px;
  color: inherit;
  text-decoration: none;
  cursor: pointer;
  transition: background .15s, color .15s;
}

.sidebar-user:hover {
  background: var(--surface2);
}

.sidebar-user:hover .sidebar-email {
  color: var(--text);
}

.sidebar-user:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.sidebar-avatar {
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  overflow: hidden;
  border-radius: 50%;
  background: var(--accent);
  color: var(--accent-ink);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.sidebar-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.sidebar-account-copy {
  min-width: 0;
}

.sidebar-account-label {
  margin-top: 1px;
  color: var(--muted);
  font-size: 10.5px;
}

.nav-item[type="button"] {
  width: 100%;
  border: 0;
  background: transparent;
  text-align: left;
  font: inherit;
}

.account-mobile-menu,
.account-sidebar-backdrop {
  display: none;
}

@media (max-width: 768px) {
  body.ax-account-nav-open {
    overflow: hidden;
  }

  .account-mobile-menu {
    display: inline-grid;
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    place-items: center;
    border: 1px solid var(--border2);
    border-radius: 7px;
    background: var(--surface2);
    color: var(--text);
    cursor: pointer;
  }

  .sidebar.account-mobile-drawer {
    display: flex !important;
    position: fixed !important;
    inset: 0 auto 0 0;
    z-index: 180;
    width: min(284px, calc(100vw - 48px));
    height: 100dvh;
    transform: translateX(-105%);
    transition: transform .2s ease;
    box-shadow: 18px 0 44px rgba(0, 0, 0, .35);
  }

  body.ax-account-nav-open .sidebar.account-mobile-drawer {
    transform: translateX(0);
  }

  .account-sidebar-backdrop {
    position: fixed;
    inset: 0;
    z-index: 170;
    border: 0;
    background: rgba(0, 0, 0, .58);
    cursor: pointer;
  }

  body.ax-account-nav-open .account-sidebar-backdrop {
    display: block;
  }
}
