.profile-card {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: var(--space-lg);
}

.profile-banner {
  position: relative;
  height: 128px;
  background: linear-gradient(115deg, #200000 0%, var(--color-brand-hover) 60%, var(--color-brand) 100%);
  overflow: hidden;
}

.profile-banner--editable {
  display: block;
  cursor: pointer;
}

.profile-banner__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-banner__input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}

.profile-banner__edit-badge {
  position: absolute;
  top: var(--space-sm);
  right: var(--space-sm);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0.45);
  color: #ffffff;
  transition: background-color 0.15s ease;
}

.profile-banner--editable:hover .profile-banner__edit-badge {
  background-color: rgba(0, 0, 0, 0.65);
}

.profile-header {
  padding: 0 var(--space-lg) var(--space-lg);
}

.profile-header__top {
  display: flex;
  align-items: flex-end;
  margin-top: -40px;
}

.profile-header__public-link {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-sm);
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--color-text);
}

.profile-header__public-link svg {
  width: 16px;
  height: 16px;
}

.profile-header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-top: var(--space-sm);
  flex-wrap: wrap;
}

.profile-header__follow-form {
  display: contents;
}

.pill-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0.5rem 1rem;
  font-size: 0.8125rem;
  font-weight: 700;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.pill-btn--solid {
  background-color: var(--color-text);
  color: #ffffff;
}

.pill-btn--solid:hover {
  background-color: #333333;
}

.pill-btn--outline {
  background-color: transparent;
  border-color: var(--color-border);
  color: var(--color-text);
}

.pill-btn--outline:hover {
  border-color: var(--color-danger-text);
  color: var(--color-danger-text);
}

.pill-btn--hoverswap .pill-btn__hover {
  display: none;
}

.pill-btn--hoverswap:hover .pill-btn__default {
  display: none;
}

.pill-btn--hoverswap:hover .pill-btn__hover {
  display: inline;
}

.profile-avatar-wrap {
  position: relative;
  flex-shrink: 0;
}

.profile-avatar-wrap--editable {
  cursor: pointer;
}

.profile-avatar {
  position: relative;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  border: 4px solid var(--color-surface);
  background: linear-gradient(135deg, var(--color-brand), var(--color-brand-hover));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 700;
  font-size: 1.625rem;
  flex-shrink: 0;
  overflow: hidden;
}

.profile-avatar__img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-avatar__input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
}

.profile-avatar__edit-badge {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--color-text);
  color: #ffffff;
  border: 2px solid var(--color-surface);
}

.profile-name-row {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-top: var(--space-md);
  flex-wrap: wrap;
}

.profile-name {
  font-size: 1.375rem;
  font-weight: 700;
  color: var(--color-text);
  margin: 0;
}

.profile-meta {
  color: var(--color-text-muted);
  font-size: 0.9375rem;
  margin-top: 2px;
}

.profile-stats {
  display: flex;
  gap: var(--space-lg);
  margin-top: var(--space-md);
  padding-top: var(--space-md);
  border-top: 1px solid var(--color-border);
}

.profile-stat__value {
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--color-text);
}

.profile-stat__label {
  font-size: 0.8125rem;
  color: var(--color-text-muted);
}

.profile-section {
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  margin-bottom: var(--space-lg);
}

.profile-section__title {
  font-size: 1rem;
  font-weight: 700;
  margin: 0 0 var(--space-md);
}

.profile-tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
}

.profile-tag {
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 0.375rem 0.75rem;
  border-radius: var(--radius-sm);
  background-color: var(--color-bg);
  border: 1px solid var(--color-border);
  color: var(--color-text);
}

.profile-list-item {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-sm) 0;
  border-bottom: 1px solid var(--color-border);
  color: inherit;
}

.profile-list-item--row {
  justify-content: space-between;
}

.profile-list-item__link {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  color: inherit;
  min-width: 0;
}

.profile-list-item__actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex-shrink: 0;
}

.profile-list-item__actions form {
  display: contents;
}

.profile-list-item:hover .profile-list-item__title {
  color: var(--color-brand);
}

.profile-list-item:last-child {
  border-bottom: none;
}

.profile-list-item__logo {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--color-brand), var(--color-brand-hover));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 700;
  font-size: 0.9375rem;
  flex-shrink: 0;
}

.profile-list-item__title {
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--color-text);
}

.profile-list-item__subtitle {
  font-size: 0.8125rem;
  color: var(--color-text-muted);
}

.profile-contact-row {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 0.9375rem;
  color: var(--color-text);
  margin-bottom: var(--space-sm);
}

.profile-contact-row:last-child {
  margin-bottom: 0;
}

.profile-contact-row svg {
  flex-shrink: 0;
  color: var(--color-text-muted);
}

.mini-profile-card {
  display: block;
  overflow: hidden;
  margin-bottom: var(--space-md);
  color: inherit;
}

.mini-profile-card__banner {
  height: 48px;
  background: linear-gradient(115deg, #200000 0%, var(--color-brand-hover) 60%, var(--color-brand) 100%);
  overflow: hidden;
}

.mini-profile-card__banner-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mini-profile-card__body {
  padding: 0 var(--space-md) var(--space-md);
  text-align: center;
}

.mini-profile-card__avatar {
  width: 56px;
  height: 56px;
  margin: -28px auto 0;
  border-radius: 50%;
  border: 3px solid var(--color-surface);
  background: linear-gradient(135deg, var(--color-brand), var(--color-brand-hover));
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-weight: 700;
  font-size: 1.0625rem;
  overflow: hidden;
}

.mini-profile-card__avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.mini-profile-card__name {
  margin-top: var(--space-sm);
  font-weight: 700;
  font-size: 0.9375rem;
  color: var(--color-text);
}

.mini-profile-card__handle,
.mini-profile-card__location {
  font-size: 0.8125rem;
  color: var(--color-text-muted);
}

@media (max-width: 991px) {
  .profile-card,
  .profile-section {
    border-radius: 0;
    border-left: none;
    border-right: none;
  }
}
