/* =========================================================
   Settings directory — separate rounded category cards
   ========================================================= */
.settings-category-list {
  display: grid;
  gap: 10px;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.settings-category {
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
}

.settings-category:last-child {
  border-bottom: 1px solid var(--border);
}

.settings-category:active,
.settings-category:hover {
  border-color: color-mix(in srgb, var(--purple, #2585ed) 38%, var(--border));
}


/* Settings categories: keep original row size, separate rounded outlines,
   left-aligned labels and chevrons pinned to the right edge. */
.settings-category-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  overflow: visible;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.settings-category {
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  width: 100%;
  min-height: 68px;
  box-sizing: border-box;
  padding: 0 18px;
  gap: 16px;
  text-align: left;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
}

.settings-category:last-child {
  border-bottom: 1px solid var(--border);
}

.settings-category > svg:first-child {
  flex: 0 0 23px;
}

.settings-category span {
  flex: 1 1 auto;
  min-width: 0;
  text-align: left;
}

.settings-category .settings-chevron {
  flex: 0 0 19px;
  margin-left: auto;
}


/* Restore the Settings search field to the original integrated search-bar
   treatment; keep this independent from the category-row styling. */
.settings-search {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 44px;
  box-sizing: border-box;
  margin: 0 0 16px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--muted);
}

.settings-search:focus-within {
  border-color: var(--purple);
}

.settings-search > svg {
  flex: 0 0 20px;
  width: 20px;
  height: 20px;
}

.settings-search input {
  flex: 1 1 auto;
  min-width: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  outline: 0;
  box-shadow: none;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 15px;
}

.settings-search input:focus {
  border: 0;
  outline: 0;
  box-shadow: none;
}


/* Search chats: remove the nested input outline and keep the outer border neutral. */
.sidebar-search input,
.sidebar-search input:focus,
.sidebar-search input:focus-visible {
  border: 0 !important;
  outline: 0 !important;
  box-shadow: none !important;
  background: transparent !important;
}

.sidebar-search:focus-within {
  border-color: var(--border) !important;
  box-shadow: none !important;
}

/* Use regular-weight typography throughout AXON, including headings and rich text. */
body * {
  font-weight: 400 !important;
}


/* Sidebar profile heading */
.sidebar-section-label {
  margin: 2px 9px 6px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
  font-weight: 400;
  letter-spacing: .02em;
}


/* Profile editor — distinct, quiet fields with simple typography. */
.sidebar-account { cursor: pointer; }
.profile-editor {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.profile-editor-avatar {
  display: flex;
  justify-content: center;
  padding: 8px 0 2px;
}
.profile-editor-avatar .account-avatar {
  width: 76px;
  height: 76px;
}
.profile-field-group {
  gap: 10px;
}
.profile-field-group h3,
.profile-field-group .field-label {
  font-size: 14px;
  font-weight: 400;
  color: var(--text);
}
.profile-field-group input,
.profile-field-group textarea {
  width: 100%;
  box-sizing: border-box;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface-2);
  padding: 11px 12px;
  color: var(--text);
  font: inherit;
  font-size: 14px;
  outline: none;
}
.profile-field-group textarea {
  min-height: 100px;
  resize: vertical;
  line-height: 1.5;
}
.profile-field-group input:focus,
.profile-field-group textarea:focus {
  border-color: var(--border-strong);
  box-shadow: none;
}
.profile-editor-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.account-access-content {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.account-access-content .setting-group h3 {
  font-weight: 400;
}
.account-action-row {
  width: 100%;
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  text-align: left;
  font: inherit;
  font-size: 14px;
  font-weight: 400;
}
.account-action-row svg {
  width: 18px;
  height: 18px;
}
.account-action-row.danger { color: var(--danger, #c44); }


/* Settings screens: clean, regular-weight typography and compact spacing. */
#settingsPage,
#settingsPage * {
  font-weight: 400 !important;
  letter-spacing: normal;
}

#settingsPage .page-header h2,
#settingsPage .settings-detail-header h2,
#settingsPage .setting-group h3 {
  font-size: 15px;
  font-weight: 400 !important;
}

#settingsPage .setting-group {
  gap: 10px;
  padding: 14px;
}

#settingsPage .setting-group > p,
#settingsPage .settings-empty,
#settingsPage .settings-no-results {
  display: none !important;
}

#settingsPage .field-label,
#settingsPage label,
#settingsPage select,
#settingsPage button,
#settingsPage input {
  font-size: 14px;
  font-weight: 400 !important;
}

#settingsPage .settings-category {
  font-weight: 400 !important;
}


/* Settings search: keep the outline neutral, including while focused. */
.settings-search,
.settings-search:focus-within {
  border-color: var(--border) !important;
  outline: none !important;
  box-shadow: none !important;
}

/* Sidebar brand: static lockup with a black AXON wordmark. */
.brand-btn {
  cursor: default;
}
.brand-btn:hover {
  background: transparent;
}
.brand {
  background: none !important;
  color: #111111 !important;
  -webkit-text-fill-color: #111111 !important;
}
body.dark .brand {
  color: #ffffff !important;
  -webkit-text-fill-color: #ffffff !important;
}
