.header-user-control {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 3px 6px;
  border: 0;
  background: transparent;
  border-radius: 9px;
  color: var(--text);
  min-width: 0;
  box-shadow: none;
}
.header-user-control:hover {
  background: var(--surface-soft);
}
.sidebar-profile[role="button"] {
  cursor: pointer;
}
.sidebar-profile:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: -2px;
}
.shell main > section[data-page="profile"] {
  max-width: 1050px;
  margin-inline: auto;
}
.profile-layout {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  align-items: start;
  gap: 20px;
}
.profile-layout .card {
  margin: 0;
  border-radius: 12px;
  padding: 24px;
}
.profile-identity {
  text-align: center;
  overflow-wrap: anywhere;
}
.profile-identity .avatar {
  display: inline-flex;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  font-size: 22px;
  margin-bottom: 14px;
}
.profile-identity h2 {
  font-size: 17px;
  margin: 0 0 6px;
}
.profile-identity p {
  font-size: 12px;
  margin: 0 0 12px;
}
.profile-role {
  display: inline-block;
  background: var(--brand-soft);
  color: var(--brand);
  border-radius: 6px;
  padding: 4px 8px;
  font-size: 11px;
}
.profile-identity dl {
  margin: 20px 0 0;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  text-align: left;
  font-size: 12px;
}
.profile-identity dt {
  color: var(--text-secondary);
  margin-bottom: 6px;
}
.profile-identity dd {
  margin: 0;
  font-weight: 550;
}
.profile-forms {
  display: grid;
  gap: 18px;
  min-width: 0;
}
.profile-section-heading {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  margin-bottom: 20px;
}
.profile-section-heading > i {
  font-size: 22px;
  color: var(--brand);
  background: var(--brand-soft);
  padding: 8px;
  border-radius: 9px;
}
.profile-section-heading h2 {
  margin: 0 0 4px;
  font-size: 15px;
}
.profile-section-heading p {
  margin: 0;
  font-size: 12px;
}
.profile-form .mt-field {
  margin-bottom: 16px;
}
.profile-form input {
  min-height: 42px;
  border-radius: 8px;
  font-size: 13px;
}
.profile-form input[readonly] {
  background: var(--surface-soft);
  color: var(--text-secondary);
}
#profile-security-form .account-password input,
#platform-user-form .account-password input {
  padding-right: 46px;
}
.profile-form .small {
  font-size: 12px;
  line-height: 1.6;
  margin: 4px 0 16px;
}
.profile-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 16px;
}
.profile-actions button {
  min-height: 38px;
  font-size: 12px;
  padding: 8px 14px;
}
.profile-feedback {
  margin: 10px 0;
  padding: 10px 12px;
  border-radius: 8px;
  background: var(--success-bg);
  color: var(--success);
  font-size: 12px;
  line-height: 1.6;
}
.profile-feedback.error {
  color: #d83249;
  background: color-mix(in srgb, #e34858 9%, var(--surface));
}
#platform-user-form-dialog {
  width: min(480px, calc(100vw - 24px));
}
#platform-user-form > .muted {
  font-size: 12px;
  line-height: 1.6;
}
#platform-user-form .check {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 12px;
}
#platform-user-form .check input {
  width: 16px;
  height: 16px;
  min-height: 0;
}
.platform-user-identity strong,
.platform-user-identity small {
  display: block;
}
.platform-user-identity small {
  color: var(--text-secondary);
  margin-top: 4px;
  font-size: 11px;
}
@media (max-width: 767px) {
  .profile-layout {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .profile-layout .card {
    padding: 18px;
  }
  .profile-identity {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 4px 12px;
    text-align: left;
  }
  .profile-identity .avatar {
    width: 48px;
    height: 48px;
    grid-row: span 3;
    font-size: 18px;
    margin: 0;
  }
  .profile-identity h2 {
    font-size: 16px;
  }
  .profile-identity p {
    margin: 0;
  }
  .profile-identity .profile-role {
    justify-self: start;
  }
  .profile-identity dl {
    grid-column: 1/-1;
    width: 100%;
    margin-top: 10px;
    padding-top: 10px;
  }
  .profile-actions button {
    width: 100%;
  }
  .header-user-control {
    padding: 2px;
  }
}
#platform-content .billing-status + small {
  display: block;
  margin-top: 5px;
  font-size: 11px;
}
.platform-list-toolbar:has(#platform-role:not([hidden])) {
  flex-wrap: wrap;
}
.platform-list-toolbar:has(#platform-role:not([hidden])) .platform-search {
  flex: 1 1 260px;
}
@media (max-width: 900px) {
  .header-user-control {
    width: 40px;
    height: 40px;
    min-height: 40px;
    padding: 4px;
    flex-shrink: 0;
    justify-content: center;
  }
  .header-user-control .header-user-avatar {
    display: inline-flex;
    width: 30px;
    height: 30px;
    font-size: 11px;
  }
}
