.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-2) var(--space-4);
  min-height: 36px;
  font-size: var(--font-size-sm);
  font-weight: 500;
  line-height: 1;
  color: var(--text);
  background: var(--surface);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  transition: background-color 120ms ease, border-color 120ms ease, color 120ms ease;
  white-space: nowrap;
}

.btn:hover {
  background: var(--surface-muted);
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn--primary {
  background: var(--primary);
  border-color: var(--primary);
  color: var(--primary-contrast);
}

.btn--primary:hover {
  background: var(--primary-hover);
  border-color: var(--primary-hover);
}

.btn--danger {
  background: var(--danger);
  border-color: var(--danger);
  color: var(--primary-contrast);
}

.btn--danger:hover {
  background: var(--danger-hover);
  border-color: var(--danger-hover);
}

.btn--active {
  color: var(--primary);
  border-color: var(--primary);
  background: rgba(9, 105, 218, 0.08);
}

.btn--active:hover {
  background: rgba(9, 105, 218, 0.14);
}

.btn--primary.btn--active {
  color: var(--primary-contrast);
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.35);
}

.btn svg {
  flex-shrink: 0;
}

.toast-root {
  position: fixed;
  top: calc(var(--header-height) + var(--space-3));
  right: var(--space-4);
  left: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  z-index: var(--z-toast);
  max-width: calc(100vw - var(--space-6));
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  min-width: 240px;
  max-width: 360px;
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border-strong);
  box-shadow: var(--shadow-md);
  font-size: var(--font-size-sm);
  animation: toast-in 160ms ease-out;
  cursor: pointer;
}

.toast--success {
  border-color: var(--success);
  border-left: 4px solid var(--success);
}

.toast--error {
  border-color: var(--danger);
  border-left: 4px solid var(--danger);
}

.toast--info {
  border-color: var(--primary);
  border-left: 4px solid var(--primary);
}

.toast--leaving {
  animation: toast-out 180ms ease-in forwards;
}

@keyframes toast-in {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes toast-out {
  from {
    opacity: 1;
    transform: translateY(0);
  }
  to {
    opacity: 0;
    transform: translateY(-6px);
  }
}

.scaffold {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  padding: var(--space-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.scaffold__lead {
  color: var(--text-muted);
  max-width: 60ch;
}

.scaffold__actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.scaffold__meta {
  font-size: var(--font-size-sm);
  color: var(--text-muted);
}

.scaffold__meta code {
  background: var(--surface-muted);
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  font-size: 0.9em;
}

.auth-card {
  max-width: 400px;
  margin: var(--space-6) auto;
  padding: var(--space-5);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.auth-card__lead {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.auth-form__field {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.auth-form__label {
  font-size: var(--font-size-sm);
  color: var(--text-muted);
  font-weight: 500;
}

.auth-form__input {
  padding: var(--space-2) var(--space-3);
  min-height: 38px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: var(--font-size-md);
  transition: border-color 120ms ease, box-shadow 120ms ease;
}

.auth-form__input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(9, 105, 218, 0.18);
}

.auth-form__submit {
  margin-top: var(--space-2);
  align-self: stretch;
  justify-content: center;
  min-height: 40px;
}

.auth-form__actions {
  margin-top: var(--space-2);
  display: flex;
  gap: var(--space-2);
  justify-content: flex-end;
}

.auth-form__actions .btn {
  min-height: 40px;
}

.auth-form__actions .btn--primary {
  flex: 1;
  justify-content: center;
}

.profiles-view {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.profiles-view__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  flex-wrap: wrap;
}

.profiles-view__title {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.profiles-view__count {
  margin: 0;
  font-size: var(--font-size-sm);
  color: var(--text-muted);
  min-height: 1em;
}

.profiles-view__controls {
  display: flex;
  align-items: flex-end;
  gap: var(--space-2);
  flex-wrap: wrap;
}

@media (min-width: 641px) {
  .profiles-view__controls {
    flex-wrap: nowrap;
  }
}

.profiles-view__order-field {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.profiles-view__order-label {
  font-size: var(--font-size-xs);
  color: var(--text-muted);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.profiles-view__order {
  padding: var(--space-2) var(--space-3);
  min-height: 36px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: var(--font-size-sm);
  color: var(--text);
  cursor: pointer;
}

.profiles-view__search-field {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  flex: 1 1 220px;
  min-width: 0;
}

.profiles-view__search {
  padding: var(--space-2) var(--space-3);
  min-height: 36px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  font-size: var(--font-size-sm);
  color: var(--text);
  width: 100%;
}

.profiles-view__search:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(9, 105, 218, 0.18);
}

.profiles-view__reverse {
  align-self: flex-end;
}

.profiles-view__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-3);
}

@media (min-width: 641px) {
  .profiles-view__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

.profile-card {
  display: flex;
  gap: var(--space-4);
  padding: var(--space-4);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  color: var(--text);
  text-decoration: none;
  transition: transform 120ms ease, box-shadow 120ms ease, border-color 120ms ease;
  min-width: 0;
  overflow: hidden;
}

.profile-card:hover {
  text-decoration: none;
  border-color: var(--border-strong);
  box-shadow: var(--shadow-md);
  transform: translateY(-1px);
}

.profile-card--purging {
  opacity: 0.55;
  pointer-events: none;
}

.profile-card__purging-badge {
  display: inline-block;
  margin-top: var(--space-1);
  font-size: var(--font-size-xs);
  font-weight: 600;
  color: var(--warning);
  background: rgba(191, 135, 0, 0.08);
  padding: 1px 6px;
  border-radius: var(--radius-sm);
  border: 1px solid currentColor;
}

.profile-card__avatar {
  flex: 0 0 64px;
  width: 64px;
  height: 64px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--surface-muted);
  display: flex;
  align-items: center;
  justify-content: center;
}

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

.profile-card__avatar--fallback {
  color: var(--text-muted);
}

.profile-card__content {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.profile-card__body {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.profile-card__name {
  font-weight: 600;
  font-size: var(--font-size-md);
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-card__handle {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-card__footer {
  display: flex;
  gap: var(--space-3);
  margin-top: auto;
  flex-wrap: wrap;
}

.profile-card__stat {
  display: flex;
  flex-direction: column;
  line-height: 1.1;
  min-width: 0;
}

.profile-card__stat-value {
  color: var(--text);
  font-weight: 600;
  font-size: var(--font-size-sm);
}

.profile-card__stat-label {
  color: var(--text-muted);
  font-size: var(--font-size-xs);
}

@keyframes shimmer {
  0% {
    background-position: -200px 0;
  }
  100% {
    background-position: calc(200px + 100%) 0;
  }
}

.skeleton {
  background: linear-gradient(
    90deg,
    var(--surface-muted) 0%,
    var(--border) 50%,
    var(--surface-muted) 100%
  );
  background-size: 200px 100%;
  background-repeat: no-repeat;
  animation: shimmer 1.2s ease-in-out infinite;
  border-radius: var(--radius-sm);
}

.skeleton--line {
  height: 12px;
  margin-bottom: var(--space-2);
}

.skeleton--line:last-child {
  margin-bottom: 0;
}

.profile-card--skeleton {
  cursor: default;
  pointer-events: none;
}

.profile-card--skeleton .profile-card__body .skeleton--line:nth-child(1) {
  width: 60%;
}
.profile-card--skeleton .profile-card__body .skeleton--line:nth-child(2) {
  width: 40%;
}
.profile-card--skeleton .profile-card__body .skeleton--line:nth-child(3) {
  width: 80%;
}

.empty-state {
  text-align: center;
  padding: var(--space-6) var(--space-4);
  color: var(--text-muted);
  background: var(--surface);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-3);
}

.empty-state h2 {
  color: var(--text);
}

@media (max-width: 640px) {
  .profiles-view__header {
    flex-direction: column;
    align-items: stretch;
  }
  .profiles-view__controls {
    flex-direction: column;
    align-items: stretch;
  }
  .profiles-view__search-field,
  .profiles-view__order-field {
    width: 100%;
    flex: 0 0 auto;
  }
  .profiles-view__reverse {
    align-self: stretch;
    justify-content: center;
  }
  .profile-card {
    padding: var(--space-3);
    gap: var(--space-3);
  }
  .profile-card__avatar {
    flex: 0 0 56px;
    width: 56px;
    height: 56px;
  }
  .profile-card__footer {
    flex-wrap: wrap;
    gap: var(--space-3);
  }
}

.profile-detail {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
}

.random-view {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  align-items: center;
}

.random-view__header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-1);
  text-align: center;
}

.random-view__hint {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

.random-view__hint kbd {
  display: inline-block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: var(--font-size-xs);
  background: var(--surface-muted);
  border: 1px solid var(--border-strong);
  border-bottom-width: 2px;
  border-radius: 4px;
  padding: 0 6px;
  margin: 0 2px;
  color: var(--text);
  font-weight: 600;
}

.random-view__stage {
  width: 100%;
  display: flex;
  justify-content: center;
  margin-top: var(--space-2);
}

.random-view__media-box {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 720px;
  background: #000;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
}

.random-view__media-box--skeleton {
  background: var(--surface-muted);
  aspect-ratio: 3 / 4;
  max-width: 420px;
}

.random-view__media {
  display: block;
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
}

.random-view__unknown {
  color: white;
  padding: var(--space-5);
  font-size: var(--font-size-sm);
}

.random-view__meta {
  width: 100%;
  display: flex;
  justify-content: center;
}

.random-view__meta-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-1);
  font-size: var(--font-size-sm);
  color: var(--text-muted);
}

.random-view__meta-top {
  display: flex;
  align-items: center;
  gap: var(--space-3);
}

.random-view__chips {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  flex-wrap: wrap;
}

.random-view__chip {
  font-size: var(--font-size-xs);
  font-weight: 500;
  padding: 2px var(--space-2);
  border-radius: var(--radius-sm);
  background: var(--surface-muted);
  color: var(--text-muted);
  white-space: nowrap;
}

.random-view__chip--keep    { color: var(--success); background: rgba(26, 127, 55, 0.08); }
.random-view__chip--remove  { color: var(--danger);  background: rgba(209, 36, 47, 0.08); }
.random-view__chip--pending { color: var(--warning); background: rgba(191, 135, 0, 0.08); }
.random-view__chip--reason  { color: var(--danger); background: rgba(209, 36, 47, 0.10); font-weight: 500; }

.random-view__profile-link {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  color: var(--text);
  font-weight: 500;
}

.random-view__avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
}

.random-view__sep {
  opacity: 0.5;
}

.random-view__actions {
  display: flex;
  gap: var(--space-3);
  justify-content: center;
  margin-top: var(--space-2);
}

.random-view__actions .btn {
  min-height: 44px;
  padding: var(--space-2) var(--space-4);
}

.random-view__keep {
  background: var(--success);
  border-color: var(--success);
  color: var(--primary-contrast);
}

.random-view__keep:hover:not(:disabled) {
  background: #166e2f;
  border-color: #166e2f;
}

.random-view__actions .btn kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 11px;
  background: rgba(255, 255, 255, 0.22);
  color: currentColor;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 4px;
  padding: 0 6px;
  min-width: 18px;
  font-weight: 700;
  margin-left: var(--space-2);
}

.profile-detail__back {
  align-self: flex-start;
  color: var(--text);
}

.profile-detail__header {
  display: flex;
  gap: var(--space-6);
  align-items: flex-start;
  padding: var(--space-6);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.profile-detail__avatar {
  flex: 0 0 96px;
  width: 96px;
  height: 96px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--surface-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
}

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

.profile-detail__info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.profile-detail__name {
  font-size: var(--font-size-xl);
  font-weight: 600;
  line-height: 1.2;
  word-break: break-word;
}

.profile-detail__handle {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

.profile-detail__bio {
  color: var(--text);
  font-size: var(--font-size-sm);
  white-space: pre-wrap;
  margin-top: var(--space-1);
}

.profile-detail__counts {
  display: flex;
  gap: var(--space-5);
  flex-wrap: wrap;
  margin-top: var(--space-3);
}

.profile-detail__count {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.profile-detail__count-value {
  font-weight: 600;
  font-size: var(--font-size-md);
}

.profile-detail__count-label {
  color: var(--text-muted);
  font-size: var(--font-size-xs);
}

.profile-detail__actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  flex-shrink: 0;
}

.profile-detail__actions .btn {
  min-height: 40px;
  justify-content: center;
}

.profile-detail__back {
  color: var(--text);
}

.is-spinning svg {
  animation: spin 0.8s linear infinite;
}

.profile-detail__danger-zone {
  padding: var(--space-4);
  border: 1px dashed var(--danger);
  border-radius: var(--radius-md);
}

.profile-detail__danger-title {
  margin: 0 0 var(--space-2) 0;
  font-size: var(--font-size-xs);
  font-weight: 700;
  color: var(--danger);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.profile-detail__danger-desc {
  margin: 0 0 var(--space-3) 0;
  font-size: var(--font-size-sm);
  color: var(--text-muted);
}

@keyframes spin {
  from {
    transform: rotate(0);
  }
  to {
    transform: rotate(360deg);
  }
}

.media-grid {
  display: grid;
  column-gap: var(--space-2);
  row-gap: var(--space-6);
  grid-template-columns: repeat(2, 1fr);
}

@media (min-width: 961px) {
  .media-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.media-grid__item {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.media-grid__item--deleted {
  opacity: 0.35;
  filter: grayscale(0.5);
}

.media-grid__item--deleted .media-grid__thumb {
  cursor: not-allowed;
}

.media-grid__item--deleted .media-grid__delete {
  cursor: not-allowed;
}

.media-grid__thumb {
  position: relative;
  aspect-ratio: 3 / 4;
  width: 100%;
  border: none;
  padding: 0;
  background: var(--surface-muted);
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  transition: transform 120ms ease, box-shadow 120ms ease;
}

.media-grid__thumb:hover {
  transform: scale(1.01);
  box-shadow: var(--shadow-md);
}

.media-grid__meta {
  font-size: var(--font-size-xs);
  color: var(--text-muted);
  text-align: center;
  padding: 2px var(--space-1);
  line-height: 1.2;
}

.media-grid__chip-state {
  position: absolute;
  top: var(--space-1);
  right: var(--space-1);
  min-width: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.4;
  padding: 1px 5px;
  border-radius: var(--radius-sm);
  color: #fff;
  pointer-events: none;
}

.media-grid__chip-state--keep    { background: rgba(26, 127, 55, 0.85); }
.media-grid__chip-state--remove  { background: rgba(209, 36, 47, 0.85); }
.media-grid__chip-state--pending { background: rgba(191, 135, 0, 0.85); }

.media-grid__state-line {
  display: block;
  padding: 2px var(--space-1);
  font-size: var(--font-size-xs);
  font-weight: 600;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  line-height: 1.2;
}

.media-grid__state-line--keep    { color: var(--success); }
.media-grid__state-line--pending { color: var(--warning); }

.media-grid__reasons {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
  justify-content: center;
  padding: 2px var(--space-1);
}

.media-grid__reason {
  font-size: 10.5px;
  font-weight: 500;
  padding: 1px 5px;
  border-radius: var(--radius-sm);
  background: rgba(209, 36, 47, 0.10);
  color: var(--danger);
  line-height: 1.3;
  white-space: nowrap;
}

.media-grid__delete {
  width: 100%;
  padding: var(--space-1) var(--space-2);
  min-height: 30px;
  font-size: var(--font-size-xs);
  color: var(--text-muted);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
  transition: color 120ms ease, background-color 120ms ease, border-color 120ms ease;
}

.media-grid__delete:hover {
  color: var(--danger);
  border-color: var(--danger);
  background: var(--surface);
}

.media-grid__delete:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.media-grid__keep {
  width: 100%;
  padding: var(--space-1) var(--space-2);
  min-height: 30px;
  font-size: var(--font-size-xs);
  color: var(--text-muted);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  cursor: pointer;
  transition: color 120ms ease, background-color 120ms ease, border-color 120ms ease;
}

.media-grid__keep:hover {
  color: var(--success);
  border-color: var(--success);
  background: var(--surface);
}

.media-grid__keep:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.media-grid__image,
.media-grid__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  background: #000;
}

.media-grid__video-placeholder,
.media-grid__unknown {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.media-grid__video-placeholder {
  background: linear-gradient(135deg, #2a2a2a, #4a4a4a);
  color: rgba(255, 255, 255, 0.55);
}

.media-grid__unknown {
  color: var(--text-muted);
}

.media-grid__play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(0, 0, 0, 0.55);
  color: white;
  border-radius: 50%;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
}

.media-grid__badge {
  position: absolute;
  bottom: var(--space-2);
  left: var(--space-2);
  background: rgba(0, 0, 0, 0.65);
  color: white;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  font-size: var(--font-size-xs);
  font-weight: 500;
  pointer-events: none;
}

.media-grid__sentinel {
  height: 1px;
}

.media-grid__loader {
  text-align: center;
  padding: var(--space-3);
  color: var(--text-muted);
  font-size: var(--font-size-sm);
  min-height: 24px;
}

body.lightbox-open,
body.confirm-open {
  overflow: hidden;
}

.confirm-dialog {
  position: fixed;
  inset: 0;
  z-index: 1100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-4);
}

.confirm-dialog__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.confirm-dialog__box {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 400px;
  background: var(--surface);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  animation: confirm-in 140ms ease-out;
}

@keyframes confirm-in {
  from {
    opacity: 0;
    transform: translateY(-4px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.confirm-dialog__title {
  font-size: var(--font-size-lg);
  font-weight: 600;
}

.confirm-dialog__message {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

.confirm-dialog__hint {
  color: var(--text-muted);
  font-size: var(--font-size-xs);
  margin-top: calc(-1 * var(--space-1));
}

.confirm-dialog__actions {
  display: flex;
  gap: var(--space-2);
  justify-content: flex-end;
  margin-top: var(--space-2);
}

.confirm-dialog__actions .btn {
  min-height: 40px;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.88);
  cursor: zoom-out;
}

.lightbox__content {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: var(--space-6) var(--space-5);
}

.lightbox__media-box {
  position: relative;
  max-width: 100%;
  max-height: calc(100vh - 140px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1;
}

.lightbox__media {
  max-width: 90vw;
  max-height: calc(100vh - 140px);
  object-fit: contain;
  border-radius: var(--radius-sm);
  background: #000;
}

.lightbox__unknown {
  color: white;
  padding: var(--space-5);
  background: rgba(255, 255, 255, 0.08);
  border-radius: var(--radius-sm);
}

.lightbox__toolbar {
  position: absolute;
  top: var(--space-4);
  left: var(--space-4);
  right: var(--space-4);
  display: flex;
  align-items: center;
  gap: var(--space-2);
  z-index: 3;
}

.lightbox__counter {
  color: white;
  font-size: var(--font-size-sm);
  padding: var(--space-2) var(--space-3);
  background: rgba(0, 0, 0, 0.55);
  border-radius: var(--radius-sm);
  margin-right: auto;
}

.lightbox__extra {
  display: flex;
  gap: var(--space-2);
}

.lightbox__meta-chips {
  display: flex;
  align-items: center;
  gap: var(--space-1);
  flex-wrap: wrap;
}

.lightbox__chip {
  font-size: var(--font-size-xs);
  font-weight: 500;
  padding: 2px var(--space-2);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.12);
  color: rgba(255, 255, 255, 0.80);
  white-space: nowrap;
}

.lightbox__chip--keep    { color: #4ade80; }
.lightbox__chip--remove  { color: #f87171; }
.lightbox__chip--pending { color: #fbbf24; }
.lightbox__chip--reason  { background: rgba(248, 113, 113, 0.18); color: #fca5a5; font-weight: 500; }

.lightbox__extra .btn {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
  color: white;
}

.lightbox__extra .btn:hover {
  background: rgba(255, 255, 255, 0.2);
}

.lightbox__toolbar .btn {
  min-height: 40px;
  padding: var(--space-2) var(--space-3);
}

.lightbox__keep {
  background: rgba(74, 222, 128, 0.18);
  border-color: rgba(74, 222, 128, 0.35);
  color: #4ade80;
}

.lightbox__keep:hover:not(:disabled) {
  background: rgba(74, 222, 128, 0.30);
  border-color: rgba(74, 222, 128, 0.55);
}

.lightbox__close {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.2);
  color: white;
  width: 40px;
  padding: 0;
}

.lightbox__close:hover {
  background: rgba(255, 255, 255, 0.2);
}

.lightbox__nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: white;
  border-radius: 50%;
  width: 44px;
  height: 44px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 3;
  transition: background-color 120ms ease;
}

.lightbox__nav:hover {
  background: rgba(0, 0, 0, 0.85);
}

.lightbox__nav:disabled {
  opacity: 0.25;
  cursor: not-allowed;
}

.lightbox__nav--prev {
  left: var(--space-3);
}

.lightbox__nav--next {
  right: var(--space-3);
}

@media (max-width: 640px) {
  .profile-detail__header {
    flex-direction: column;
    align-items: stretch;
    gap: var(--space-3);
    padding: var(--space-4);
  }
  .profile-detail__avatar {
    align-self: center;
  }
  .profile-detail__actions {
    flex-direction: row;
  }
  .profile-detail__actions .btn {
    flex: 1;
  }
  .lightbox__content {
    padding: var(--space-4) var(--space-2);
  }
  .lightbox__toolbar {
    top: var(--space-2);
    left: var(--space-2);
    right: var(--space-2);
  }
  .lightbox__nav {
    width: 36px;
    height: 36px;
  }
}
