.account-view {
  color: #191b20;
}

.account-shell {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: 34px 0 72px;
}

.account-page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.account-eyebrow {
  margin: 0 0 7px;
  color: #bf0101;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: 0;
  text-transform: uppercase;
}

.account-page-head h1 {
  margin: 0;
  color: #191b20;
  font-size: 32px;
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: 0;
}

.account-brand-logo {
  width: 154px;
  height: 50px;
  object-fit: contain;
  border: 1px solid #e7e7ea;
  border-radius: 6px;
  background: #fffdfa;
  padding: 7px 11px;
}

.account-identity {
  min-height: 94px;
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  align-items: center;
  gap: 20px;
  padding: 17px 22px;
  border: 1px solid #dedee2;
  border-radius: 8px;
  background: #fffdfa;
}

.account-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  object-position: 67% 43%;
  background: #12151b;
}

.account-identity-copy {
  min-width: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 16px;
}

.account-identity-name {
  min-width: 0;
  margin: 0;
  color: #191b20;
  font-size: 24px;
  font-weight: 800;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.account-identity-phone {
  color: #555860;
  font-size: 14px;
}

.account-identity-phone[hidden] {
  display: none;
}

.account-role {
  display: inline-flex;
  min-height: 24px;
  align-items: center;
  padding: 2px 8px;
  border: 1px solid #d8d8dc;
  border-radius: 4px;
  color: #555860;
  background: #f9f8f5;
  font-size: 12px;
  font-weight: 700;
}

.account-text-button,
.account-outline-button,
.account-primary-button,
.account-icon-button {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 6px;
  font: inherit;
  font-size: 14px;
  font-weight: 750;
  cursor: pointer;
}

.account-text-button {
  border: 0;
  background: transparent;
  color: #303238;
  padding: 0 8px;
}

.account-outline-button {
  padding: 0 16px;
  border: 1px solid #d5d5da;
  background: #fffdfa;
  color: #25272d;
}

.account-primary-button {
  padding: 0 18px;
  border: 1px solid #bf0101;
  background: #bf0101;
  color: #fff;
}

.account-text-button:hover,
.account-outline-button:hover {
  border-color: #bf0101;
  color: #bf0101;
  background: #fff8f7;
}

.account-primary-button:hover {
  border-color: #9f0000;
  background: #9f0000;
}

.account-text-button:focus-visible,
.account-outline-button:focus-visible,
.account-primary-button:focus-visible,
.account-icon-button:focus-visible,
.account-workspace-tab:focus-visible,
.account-row-button:focus-visible {
  outline: 2px solid #bf0101;
  outline-offset: 2px;
}

.account-workspace-tabs {
  min-height: 58px;
  display: flex;
  align-items: flex-end;
  gap: 8px;
  margin: 6px 0 26px;
  border-bottom: 1px solid #dedee2;
  overflow-x: auto;
  overflow-y: hidden;
}

.account-workspace-tab {
  position: relative;
  min-width: 130px;
  min-height: 52px;
  border: 0;
  background: transparent;
  color: #666870;
  padding: 0 14px;
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  cursor: pointer;
}

.account-workspace-tab::after {
  content: '';
  position: absolute;
  right: 8px;
  bottom: -1px;
  left: 8px;
  height: 2px;
  background: transparent;
}

.account-workspace-tab.active {
  color: #bf0101;
}

.account-workspace-tab.active::after {
  background: #bf0101;
}

.account-workspace-toast {
  position: fixed;
  top: max(20px, env(safe-area-inset-top));
  left: 50%;
  z-index: 1200;
  min-height: 48px;
  display: flex;
  align-items: center;
  gap: 10px;
  max-width: min(calc(100vw - 32px), 360px);
  padding: 12px 16px;
  border: 1px solid rgba(191, 1, 1, .18);
  border-radius: 8px;
  background: rgba(255, 253, 250, .96);
  box-shadow: 0 12px 32px rgba(18, 21, 27, .16);
  color: #202228;
  font-size: 14px;
  font-weight: 750;
  line-height: 1.35;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -10px) scale(.98);
  transition: opacity 180ms ease, transform 220ms cubic-bezier(.2, .8, .2, 1);
}

.account-workspace-toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0) scale(1);
}

.account-workspace-toast .lucide {
  width: 19px;
  height: 19px;
  flex: 0 0 auto;
  color: #bf0101;
}

.account-workspace-toast span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.account-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.72fr) minmax(280px, .78fr);
  gap: 20px;
  align-items: stretch;
}

.account-main-column {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.account-panel {
  min-width: 0;
  border: 1px solid #dedee2;
  border-radius: 8px;
  background: #fffdfa;
  overflow: hidden;
}

#accountOwnerBalancePanel:not([hidden]) {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
}

#accountPersonalBalancePanel:not([hidden]) {
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
}

.account-panel-head {
  min-height: 66px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 18px;
}

.account-panel-head h2 {
  margin: 0;
  color: #202228;
  font-size: 18px;
  font-weight: 800;
  line-height: 1.3;
}

.account-panel-note {
  color: #777982;
  font-size: 12px;
}

.account-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  padding: 2px 18px 20px;
}

.account-metric {
  min-width: 0;
  padding: 8px 20px;
  border-left: 1px solid #e3e3e7;
}

.account-metric:first-child {
  padding-left: 0;
  border-left: 0;
}

.account-metric span {
  display: block;
  margin-bottom: 6px;
  color: #777982;
  font-size: 12px;
}

.account-metric strong {
  display: block;
  color: #191b20;
  font-size: 24px;
  font-weight: 800;
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.account-high-balance {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  margin: 0 18px;
  border-top: 1px solid #e4e4e8;
}

#accountHighBalanceMembers {
  min-height: 0;
  flex: 1 1 auto;
  display: grid;
  grid-template-rows: repeat(3, minmax(52px, 1fr));
}

.account-high-balance-more {
  width: 100%;
  height: 18px;
  flex: 0 0 18px;
  display: grid;
  place-items: center start;
  padding: 0;
  border: 0;
  background: transparent;
  color: #9b9ca1;
  cursor: pointer;
}

.account-high-balance-more:hover {
  color: #bf0101;
  background: #fff8f7;
}

.account-high-balance-more:focus-visible {
  outline: 2px solid #bf0101;
  outline-offset: -2px;
}

.account-high-balance-more .lucide {
  width: 16px;
  height: 16px;
}

.account-high-balance-row {
  min-height: 52px;
  display: grid;
  grid-template-columns: 26px minmax(0, 1fr) minmax(112px, .78fr) minmax(88px, .56fr);
  align-items: center;
  gap: 10px;
  border-top: 1px solid #ededf0;
}

.account-high-balance-rank {
  color: #bf0101;
  font-size: 13px;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}

.account-high-balance-member {
  min-width: 0;
  display: grid;
  gap: 1px;
}

.account-high-balance-member strong,
.account-high-balance-member span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-high-balance-member strong {
  color: #303238;
  font-size: 13px;
}

.account-high-balance-member span,
.account-high-balance-units span,
.account-high-balance-usage span {
  color: #858790;
  font-size: 11px;
}

.account-high-balance-units {
  display: flex;
  align-items: baseline;
  gap: 7px;
  white-space: nowrap;
}

.account-high-balance-mode {
  align-items: center;
}

.account-high-balance-usage {
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 7px;
  white-space: nowrap;
}

.account-high-balance-units strong,
.account-high-balance-usage strong {
  color: #202228;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

.account-high-balance-placeholder .account-high-balance-rank,
.account-high-balance-placeholder .account-high-balance-member strong {
  color: #a3a4aa;
  font-weight: 600;
}

.account-member-table {
  margin: 0 18px 18px;
  border: 1px solid #e0e0e4;
  border-radius: 6px;
  overflow: hidden;
}

.account-member-row {
  min-height: 52px;
  display: grid;
  grid-template-columns: minmax(150px, 1.3fr) minmax(110px, .8fr) 88px;
  align-items: center;
  gap: 16px;
  padding: 10px 14px;
  border-top: 1px solid #e7e7ea;
}

.account-member-row:first-child {
  border-top: 0;
}

.account-member-row.account-member-head {
  min-height: 42px;
  background: #faf9f6;
  color: #666870;
  font-size: 12px;
  font-weight: 700;
}

.account-member-name {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.account-member-name strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #25272d;
  font-size: 14px;
}

.account-member-name span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #858790;
  font-size: 11px;
}

.account-member-units {
  color: #303238;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

.account-member-units strong,
.account-member-units span {
  display: block;
}

.account-member-units strong {
  font-size: 13px;
  font-weight: 650;
}

.account-member-units span {
  margin-top: 2px;
  color: #858790;
  font-size: 11px;
}

.account-member-actions {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
}

.account-icon-button {
  width: 36px;
  min-height: 36px;
  padding: 0;
  border: 1px solid transparent;
  background: transparent;
  color: #45474e;
}

.account-icon-button:hover {
  border-color: #d8d8dc;
  color: #bf0101;
  background: #fff8f7;
}

.account-icon-button .lucide,
.account-text-button .lucide,
.account-row-button .lucide,
.account-usage-disabled .lucide {
  width: 18px;
  height: 18px;
}

.account-empty {
  padding: 36px 18px;
  color: #777982;
  text-align: center;
  font-size: 14px;
}

.account-member-summary {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1px;
  background: #e7e7ea;
  border-top: 1px solid #e7e7ea;
}

.account-member-summary > div {
  min-height: 112px;
  display: grid;
  align-content: center;
  gap: 6px;
  padding: 20px;
  background: #fffdfa;
}

.account-member-summary span {
  color: #777982;
  font-size: 12px;
}

.account-member-summary strong {
  font-size: 28px;
  font-variant-numeric: tabular-nums;
}

.account-personal-overview {
  flex: 1 1 auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid #e7e7ea;
}

.account-personal-stat {
  min-width: 0;
  min-height: 168px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  padding: 24px;
  border-left: 1px solid #e7e7ea;
}

.account-personal-stat:first-child {
  border-left: 0;
}

.account-personal-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #666870;
  font-size: 13px;
  font-weight: 700;
}

.account-personal-label .lucide {
  width: 17px;
  height: 17px;
  color: #bf0101;
}

.account-personal-stat strong {
  color: #191b20;
  font-size: 32px;
  font-weight: 800;
  line-height: 1.2;
  font-variant-numeric: tabular-nums;
  overflow-wrap: anywhere;
}

.account-personal-stat small {
  color: #8a8b92;
  font-size: 12px;
}

.account-personal-recharge .account-primary-button {
  width: 100%;
  max-width: 150px;
  min-height: 42px;
  margin-top: 2px;
}

.account-side-panel h2 {
  padding: 18px;
  margin: 0;
  border-bottom: 1px solid #e4e4e8;
  font-size: 18px;
}

.account-row-button,
.account-row {
  width: 100%;
  min-height: 70px;
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 12px 18px;
  border: 0;
  border-top: 1px solid #e4e4e8;
  background: #fffdfa;
  color: #2c2e34;
  text-align: left;
  font: inherit;
}

.account-side-panel h2 + .account-row-button,
.account-side-panel h2 + .account-row {
  border-top: 0;
}

.account-row-button {
  cursor: pointer;
}

.account-row-button:hover {
  background: #faf9f6;
}

.account-row-copy {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.account-row-copy strong {
  color: #303238;
  font-size: 14px;
  font-weight: 700;
}

.account-row-copy span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #858790;
  font-size: 12px;
}

.account-row-button.danger .account-row-copy strong {
  color: #a80000;
}

.account-row-button:disabled {
  color: #a4a5aa;
  cursor: not-allowed;
}

.account-usage-disabled {
  margin-top: auto;
  min-height: 54px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border: 1px solid #e0e0e4;
  border-radius: 8px;
  background: #faf9f6;
  color: #9b9ca1;
  font-size: 13px;
}

.account-usage-disabled span:last-child {
  margin-left: auto;
}

.account-status {
  min-height: 22px;
  margin: 12px 0 0;
  color: #5d5f66;
  font-size: 13px;
}

.account-status.error {
  color: #b00000;
}

.account-dialog {
  width: min(480px, calc(100vw - 28px));
  max-height: calc(100vh - 40px);
  padding: 0;
  border: 1px solid #d8d8dc;
  border-radius: 8px;
  background: #fffdfa;
  color: #191b20;
  box-shadow: 0 20px 60px rgba(18, 21, 27, .2);
  overflow: auto;
}

.account-transfer-dialog {
  width: min(720px, calc(100vw - 28px));
}

.account-transfer-dialog.account-transfer-detail-open {
  width: min(1060px, calc(100vw - 28px));
}

.account-transfer-workspace {
  min-width: 0;
}

.account-transfer-detail-open .account-transfer-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 344px);
  align-items: stretch;
}

.account-transfer-detail-open .account-transfer-overview {
  min-width: 0;
  border-right: 1px solid #e4e4e8;
}

.account-transfer-metrics {
  padding: 18px 22px;
  border-bottom: 1px solid #e4e4e8;
}

.account-transfer-dialog .account-member-table {
  margin: 18px 22px;
}

.account-transfer-dialog #accountMemberRows {
  max-height: 398px;
  overflow-y: auto;
  overscroll-behavior: contain;
}

.account-transfer-dialog .account-dialog-form {
  border-top: 1px solid #e4e4e8;
}

.account-transfer-detail-open .account-dialog-form {
  min-height: 100%;
  display: flex;
  flex-direction: column;
  gap: 0;
  padding: 0;
  border-top: 0;
  background: #fbfbfc;
}

.account-transfer-usage {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  padding: 18px 22px;
  border-bottom: 1px solid #e4e4e8;
}

.account-transfer-usage > div {
  min-width: 0;
  display: grid;
  align-content: start;
  padding: 8px 0;
}

.account-transfer-usage span {
  display: block;
  margin-bottom: 6px;
  color: #777982;
  font-size: 12px;
}

.account-transfer-usage strong {
  display: block;
  color: #202228;
  font-size: 24px;
  font-variant-numeric: tabular-nums;
  line-height: 1.2;
}

.account-transfer-selected-member {
  display: grid;
  gap: 5px;
  margin: 0 24px;
  padding: 20px 0 18px;
  border-bottom: 1px solid #e4e4e8;
}

.account-transfer-selected-member span {
  color: #777982;
  font-size: 12px;
  font-weight: 650;
}

.account-transfer-selected-member strong {
  min-width: 0;
  color: #191b20;
  font-size: 17px;
  font-weight: 700;
  line-height: 1.35;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-transfer-detail-open .account-dialog-form > .account-field {
  margin: 20px 24px 0;
}

.account-transfer-detail-open .account-dialog-form > .account-status {
  margin: 12px 24px 0;
}

.account-transfer-detail-open .account-dialog-actions {
  margin-top: auto;
  padding: 18px 24px;
  border-top: 1px solid #e4e4e8;
  background: #fff;
}

.account-transfer-detail-open .account-dialog-actions .account-outline-button {
  min-width: 76px;
}

.account-transfer-detail-open .account-dialog-actions .account-primary-button {
  min-width: 112px;
}

.account-transfer-mode {
  min-inline-size: 0;
  border: 0;
  padding: 0;
}

.account-transfer-mode legend {
  margin-bottom: 10px;
  padding: 0;
  color: #34363c;
  font-size: 13px;
  font-weight: 700;
}

.account-segmented-control {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.account-segmented-control label {
  position: relative;
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  min-height: 58px;
  gap: 9px;
  padding: 9px 10px;
  border: 1px solid #d8d8dc;
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
  transition: border-color .16s ease, background-color .16s ease, box-shadow .16s ease;
}

.account-segmented-control label + label {
  border-left: 1px solid #d8d8dc;
}

.account-transfer-mode .account-segmented-control input {
  width: 16px;
  height: 16px;
  min-height: 16px !important;
  margin: 0;
  padding: 0;
  border: 0;
  accent-color: #b40005;
}

.account-transfer-mode .account-segmented-control input:focus,
.account-transfer-mode .account-segmented-control input:focus-visible {
  border-color: initial;
  outline: 0 !important;
  box-shadow: none;
}

.account-segmented-control label > span {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.account-segmented-control label strong {
  color: #34363c;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.25;
}

.account-segmented-control label small {
  color: #858790;
  font-size: 11px;
  line-height: 1.25;
}

.account-segmented-control label:has(input:checked) {
  border-color: #c51a1f;
  background: #fff7f6;
  box-shadow: 0 0 0 1px rgba(197, 26, 31, .08);
}

.account-segmented-control label:has(input:checked) strong {
  color: #a10000;
}

.account-segmented-control label:hover {
  border-color: #b9bac0;
}

.account-segmented-control label:has(input:focus-visible) {
  outline: 2px solid rgba(191, 1, 1, .2);
  outline-offset: 2px;
}

@media (max-width: 900px) {
  .account-transfer-dialog.account-transfer-detail-open {
    width: min(720px, calc(100vw - 28px));
  }

  .account-transfer-detail-open .account-transfer-workspace {
    grid-template-columns: minmax(0, 1fr);
  }

  .account-transfer-detail-open .account-transfer-overview {
    border-right: 0;
  }

  .account-transfer-detail-open .account-dialog-form {
    min-height: 0;
    border-top: 1px solid #e4e4e8;
  }
}

.account-dialog::backdrop {
  background: rgba(18, 21, 27, .62);
  backdrop-filter: blur(3px);
}

.account-dialog-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  padding: 20px 22px 16px;
  border-bottom: 1px solid #e4e4e8;
}

.account-dialog-head h2 {
  margin: 0;
  font-size: 20px;
}

.account-dialog-head p {
  margin: 5px 0 0;
  color: #777982;
  font-size: 13px;
}

.account-dialog-close {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border: 1px solid #dedee2;
  border-radius: 6px;
  background: #fffdfa;
  color: #45474e;
  cursor: pointer;
}

.account-dialog-form {
  display: grid;
  gap: 16px;
  padding: 20px 22px 22px;
}

.account-profile-avatar-editor {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  padding: 2px 0 4px;
}

.account-profile-avatar-editor img {
  width: 72px;
  height: 72px;
  border: 1px solid #dedee2;
  border-radius: 50%;
  background: #12151b;
  object-fit: cover;
}

.account-profile-avatar-editor > div {
  min-width: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
}

.account-profile-avatar-editor > div > strong,
.account-profile-avatar-editor small {
  width: 100%;
}

.account-profile-avatar-editor .account-outline-button {
  min-height: 38px;
  cursor: pointer;
}

.account-avatar-input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.account-field {
  display: grid;
  gap: 7px;
}

.account-field label {
  color: #34363c;
  font-size: 13px;
  font-weight: 700;
}

.account-field input,
.account-field select {
  width: 100%;
  min-height: 44px;
  padding: 9px 11px;
  border: 1px solid #cfd0d5;
  border-radius: 6px;
  background: #fff;
  color: #191b20;
  font: inherit;
  font-size: 14px;
}

.account-field input:focus,
.account-field select:focus {
  outline: 2px solid rgba(191, 1, 1, .16);
  border-color: #bf0101;
}

.account-dialog-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding-top: 4px;
}

.account-loading {
  min-height: 360px;
  display: grid;
  place-items: center;
  color: #777982;
}

.sidebar-account.workspace-pill.active {
  border-color: rgba(191, 1, 1, .55) !important;
  background: rgba(191, 1, 1, .12) !important;
}

.team-management-head {
  align-items: center;
}

.team-management-heading {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 14px;
}

.team-back-button {
  flex: 0 0 auto;
  border-color: #d8d8dc;
  background: #fffdfa;
}

.team-current-role.captain,
.team-role-badge.captain {
  border-color: #bf0101;
  color: #9f0000;
  background: #fff4f2;
}

.team-current-role.admin,
.team-role-badge.admin {
  border-color: #b9a878;
  color: #5e4a14;
  background: #fffaf0;
}

.team-overview {
  min-height: 104px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin: 4px 0 22px;
  padding: 18px 4px 20px;
  border-top: 1px solid #dedee2;
  border-bottom: 1px solid #dedee2;
}

.team-overview-main {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 16px;
}

.team-overview-mark {
  width: 54px;
  height: 54px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: #12151b;
  color: #fff;
}

.team-overview-mark .lucide {
  width: 25px;
  height: 25px;
}

.team-overview-main span,
.team-overview-main p {
  color: #777982;
  font-size: 12px;
}

.team-overview-main h2 {
  margin: 3px 0;
  color: #191b20;
  font-size: 24px;
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.team-overview-main p {
  margin: 0;
}

.team-management-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 330px);
  gap: 20px;
  align-items: start;
}

.team-management-side {
  min-width: 0;
  display: grid;
  gap: 16px;
}

.team-roster-panel {
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.team-member-table {
  min-height: 0;
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  border-top: 1px solid #e4e4e8;
  overflow: hidden;
}

#teamMemberRows {
  min-height: 0;
  flex: 1 1 auto;
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.team-member-ellipsis {
  flex: 0 0 auto;
  min-height: 64px;
  display: grid;
  place-items: center;
  color: #a5a6ac;
  font-size: 34px;
  font-weight: 800;
  letter-spacing: 0;
  line-height: .75;
}

.team-roster-has-overflow .team-member-ellipsis {
  display: none;
}

.team-member-row {
  min-height: 70px;
  display: grid;
  grid-template-columns: minmax(190px, 1.4fr) minmax(130px, 1fr) 88px 98px;
  align-items: center;
  gap: 14px;
  padding: 10px 18px;
  border-top: 1px solid #e7e7ea;
}

.team-member-row:first-child,
.team-member-head + #teamMemberRows > .team-member-row:first-child {
  border-top: 0;
}

.team-member-row.team-member-head {
  min-height: 42px;
  border-top: 0;
  background: #faf9f6;
  color: #666870;
  font-size: 12px;
  font-weight: 700;
}

.team-member-person {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 11px;
}

.team-member-person img {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border: 1px solid #dedee2;
  border-radius: 50%;
  background: #12151b;
  object-fit: cover;
}

.team-member-person span {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.team-member-person strong,
.team-member-person small,
.team-member-username {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.team-member-person strong {
  color: #25272d;
  font-size: 14px;
}

.team-member-person small,
.team-member-username {
  color: #858790;
  font-size: 12px;
}

.team-role-badge {
  min-height: 24px;
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border: 1px solid #d8d8dc;
  border-radius: 4px;
  color: #555860;
  background: #f9f8f5;
  font-size: 12px;
  font-weight: 700;
}

.team-member-actions {
  min-height: 36px;
  display: flex;
  justify-content: flex-end;
  gap: 4px;
}

.team-member-remove {
  color: #9f0000;
}

.team-member-remove:hover {
  border-color: rgba(191, 1, 1, .35);
  background: #fff4f2;
}

.team-member-locked {
  min-height: 36px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #999aa0;
  font-size: 12px;
}

.team-member-locked .lucide {
  width: 15px;
  height: 15px;
}

.team-permission-list {
  border-top: 1px solid #e4e4e8;
}

.team-permission-row {
  min-height: 66px;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 11px 18px;
  border-top: 1px solid #e7e7ea;
  color: #96979d;
}

.team-permission-row:first-child {
  border-top: 0;
}

.team-permission-row.allowed {
  color: #2f6b45;
}

.team-permission-row .lucide {
  width: 18px;
  height: 18px;
}

.team-permission-row span {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.team-permission-row strong {
  color: #303238;
  font-size: 13px;
}

.team-permission-row small {
  color: #858790;
  font-size: 11px;
  line-height: 1.45;
}

.team-coming-panel .account-panel-head {
  border-bottom: 1px solid #e4e4e8;
}

.team-coming-row {
  min-height: 66px;
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 11px 18px;
  border-top: 1px solid #e7e7ea;
  color: #9b9ca1;
}

.team-coming-panel .account-panel-head + .team-coming-row {
  border-top: 0;
}

.team-coming-row > span {
  min-width: 0;
  display: grid;
  gap: 3px;
}

.team-coming-row strong {
  color: #55575e;
  font-size: 13px;
}

.team-coming-row small {
  color: #929399;
  font-size: 11px;
}

.team-coming-row em {
  color: #8b8c92;
  font-size: 11px;
  font-style: normal;
}

.team-avatar-editor {
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr);
  align-items: center;
  gap: 16px;
  padding-bottom: 4px;
}

.team-avatar-editor img {
  width: 72px;
  height: 72px;
  border: 1px solid #dedee2;
  border-radius: 50%;
  background: #12151b;
  object-fit: cover;
}

.team-avatar-editor > div {
  min-width: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 12px;
}

.team-avatar-editor > div > strong {
  width: 100%;
  font-size: 13px;
}

.team-avatar-editor .account-outline-button {
  min-height: 38px;
  cursor: pointer;
}

.team-avatar-input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.account-field small {
  color: #858790;
  font-size: 11px;
  line-height: 1.45;
}

.team-reset-summary {
  display: grid;
  grid-template-columns: 92px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid #e0e0e4;
  border-radius: 6px;
  background: #faf9f6;
}

.team-reset-summary span {
  color: #777982;
  font-size: 12px;
}

.team-reset-summary code {
  min-width: 0;
  overflow-wrap: anywhere;
  color: #9f0000;
  font-family: Consolas, monospace;
  font-size: 14px;
  font-weight: 700;
}

@media (max-width: 760px) {
  body .sidebar .nav {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    padding-right: 62px;
  }

  body .sidebar-account-slot {
    position: fixed;
    right: 8px;
    bottom: calc(7px + env(safe-area-inset-bottom));
    z-index: 1002;
    display: block !important;
    width: 54px;
    margin: 0;
    padding: 0;
    border-top: 0;
  }

  body .sidebar-account.workspace-pill,
  body.sidebar-collapsed .sidebar-account.workspace-pill {
    width: 54px;
    height: 54px;
    min-height: 54px;
    display: grid;
    grid-template-columns: 36px;
    justify-content: center;
    padding: 8px;
    border-radius: 8px;
  }

  body .sidebar-account .workspace-pill-text,
  body .sidebar-account .sidebar-account-chevron {
    display: none !important;
  }
}

@media (max-width: 900px) {
  .account-shell {
    padding: 24px 0 100px;
  }

  .account-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .account-side-panel {
    order: -1;
  }

  .team-management-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .team-roster-panel {
    height: auto !important;
  }

  .team-management-side {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .account-shell {
    padding: 18px 2px 104px;
  }

  .account-page-head h1 {
    font-size: 26px;
  }

  .account-brand-logo {
    display: none;
  }

  .account-identity {
    grid-template-columns: 52px minmax(0, 1fr);
    gap: 13px;
    padding: 14px;
  }

  .account-avatar {
    width: 52px;
    height: 52px;
  }

  .account-identity-copy {
    gap: 5px 10px;
  }

  .account-identity-name {
    width: 100%;
    font-size: 20px;
  }

  .account-identity > .account-text-button {
    grid-column: 1 / -1;
    justify-self: stretch;
    border-top: 1px solid #e7e7ea;
    padding-top: 10px;
  }

  .account-workspace-tabs {
    margin-bottom: 16px;
  }

  .account-panel-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .account-panel-head .account-primary-button {
    width: 100%;
  }

  .account-metrics {
    grid-template-columns: 1fr;
    padding: 0 14px 14px;
  }

  .account-metric,
  .account-metric:first-child {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 12px 0;
    border-top: 1px solid #e7e7ea;
    border-left: 0;
  }

  .account-metric strong {
    font-size: 20px;
  }

  .account-member-table {
    margin: 0 12px 12px;
  }

  .account-member-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    padding: 10px;
  }

  .account-member-row > :nth-child(2) {
    text-align: right;
  }

  .account-member-row > :nth-child(3) {
    grid-column: 1 / -1;
  }

  .account-member-row.account-member-head > :nth-child(3) {
    display: none;
  }

  .account-member-actions {
    justify-content: flex-start;
  }

  .account-member-summary {
    grid-template-columns: 1fr;
  }

  .account-personal-overview {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .account-personal-stat {
    min-height: 116px;
    padding: 16px;
    border-left: 1px solid #e7e7ea;
  }

  .account-personal-stat:first-child {
    border-left: 0;
  }

  .account-personal-recharge {
    min-height: 92px;
    grid-column: 1 / -1;
    border-top: 1px solid #e7e7ea;
    border-left: 0;
  }

  .account-personal-recharge .account-primary-button {
    max-width: none;
  }

  .account-dialog-actions {
    flex-direction: column-reverse;
  }

  .account-dialog-actions button {
    width: 100%;
  }

  .team-overview {
    align-items: stretch;
    flex-direction: column;
  }

  .team-overview > .account-outline-button {
    width: 100%;
  }

  .team-management-side {
    grid-template-columns: minmax(0, 1fr);
  }

  .team-member-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px 12px;
    padding: 11px 13px;
  }

  .team-member-row > :nth-child(2) {
    grid-column: 1;
    padding-left: 53px;
  }

  .team-member-row > :nth-child(3) {
    grid-column: 2;
    grid-row: 1;
  }

  .team-member-row > :nth-child(4) {
    grid-column: 1 / -1;
  }

  .team-member-row.team-member-head {
    display: none;
  }

  .team-member-ellipsis {
    min-height: 50px;
    font-size: 28px;
  }

  .team-member-actions {
    justify-content: flex-start;
    padding-left: 49px;
  }

  .team-current-role {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .account-view *,
  .account-dialog *,
  .account-workspace-toast {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}
