:root {
  --bg-color: #0f0f0f;
  --card-color: #1f1f1f;
  --surface-color: #202020;
  --surface-hover-color: #292929;
  --text-color: #ffffff;
  --muted-text-color: #aaa;
  --border-color: #333;
  --input-bg: #141414;
  --accent-color: #00c896;
  --button-bg: #00c896;
  --button-text: #ffffff;
  --shadow-color: rgba(0, 0, 0, 0.42);
  --soft-border-color: color-mix(in srgb, var(--border-color), transparent 45%);
  --accent-soft: color-mix(in srgb, var(--accent-color), transparent 78%);
  --accent-faint: color-mix(in srgb, var(--accent-color), transparent 90%);
  --icon-bg: rgba(255, 255, 255, 0.08);
  --icon-border: rgba(255, 255, 255, 0.12);
  --icon-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 5px 12px rgba(0, 0, 0, 0.14);
  --icon-contrast-dark-bg: rgba(5, 7, 11, 0.86);
  --icon-contrast-dark-border: rgba(255, 255, 255, 0.2);
  --icon-contrast-light-bg: rgba(255, 255, 255, 0.92);
  --icon-contrast-light-border: rgba(15, 23, 42, 0.18);
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: var(--bg-color);
  color: var(--text-color);
  text-align: center;
  transition: background 0.2s ease, color 0.2s ease;
}

.container {
  padding: 20px;
  max-width: 400px;
  margin: auto;
  margin-top: 40px;
}

/* Profile Header */
#profileHeader {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 20px;
}

#name {
  margin: 10px 0 5px;
  font-size: 20px;
  font-weight: 600;
  min-height: 28px;
}

#bio {
  margin: 0;
  font-size: 14px;
  color: var(--muted-text-color);
  min-height: 20px;
  max-width: 320px;
  line-height: 1.45;
}

.editable-profile-text {
  position: relative;
  border-radius: 10px;
  cursor: pointer;
  padding: 3px 8px;
  text-decoration: underline;
  text-decoration-style: dotted;
  text-decoration-thickness: 1px;
  text-decoration-color: color-mix(in srgb, var(--text-color), transparent 82%);
  text-underline-offset: 5px;
  transition: background 0.18s ease, box-shadow 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.editable-profile-text:hover {
  background: color-mix(in srgb, var(--surface-hover-color), transparent 50%);
  box-shadow: 0 0 0 1px var(--accent-soft);
  text-decoration-color: var(--accent-color);
  transform: scale(1.01);
}

@media (hover: hover) and (pointer: fine) {
  .editable-profile-text::after {
    content: "Click to edit";
    position: absolute;
    left: 50%;
    bottom: calc(100% + 8px);
    transform: translate(-50%, 4px) scale(0.96);
    padding: 5px 8px;
    border: 1px solid var(--soft-border-color);
    border-radius: 8px;
    background: var(--card-color);
    box-shadow: 0 10px 24px var(--shadow-color);
    color: var(--text-color);
    font-size: 11px;
    font-weight: 500;
    line-height: 1;
    opacity: 0;
    pointer-events: none;
    white-space: nowrap;
    transition: opacity 0.16s ease, transform 0.16s ease;
    z-index: 20;
  }

  .editable-profile-text:hover::after {
    opacity: 1;
    transform: translate(-50%, 0) scale(1);
  }
}

.editable-profile-text.empty {
  color: var(--muted-text-color);
}

.editable-profile-text.inline-editing {
  background: var(--accent-faint);
  box-shadow: 0 0 0 1px var(--accent-soft);
  cursor: text;
  text-decoration-color: transparent;
  width: min(90%, 320px);
}

.editable-profile-text.inline-editing::after {
  display: none;
}

.inline-profile-editor {
  box-sizing: border-box;
  width: 100%;
  border: 0;
  outline: none;
  resize: none;
  background: transparent;
  color: var(--text-color);
  font: inherit;
  text-align: center;
}

.inline-profile-editor.name-editor {
  font-weight: 600;
}

.inline-profile-editor.bio-editor {
  color: var(--text-color);
  line-height: 1.45;
}

.edit-mode-hint {
  position: fixed;
  left: 50%;
  bottom: 22px;
  transform: translate(-50%, 14px) scale(0.98);
  max-width: calc(100vw - 32px);
  padding: 10px 14px;
  border: 1px solid var(--accent-soft);
  border-radius: 999px;
  background: color-mix(in srgb, var(--card-color), transparent 4%);
  box-shadow: 0 14px 34px var(--shadow-color);
  color: var(--text-color);
  font-size: 13px;
  line-height: 1;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.24s ease, transform 0.24s ease;
  z-index: 2400;
}

.edit-mode-hint.show {
  opacity: 1;
  transform: translate(-50%, 0) scale(1);
}

/* Avatar */
#avatarContainer img {
  border: 2px solid var(--border-color);
}

button,
input,
.link,
.edit-icon,
.avatar-frame,
.avatar-menu-item,
.floating-menu button {
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

#menuPopup div,
#addMenu div {
  -webkit-tap-highlight-color: transparent;
  touch-action: manipulation;
}

.avatar-frame {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.avatar-frame.editable {
  cursor: pointer;
  transition: filter 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.avatar-frame.editable:hover {
  filter: brightness(1.12);
  transform: scale(1.03);
  box-shadow: 0 0 0 4px var(--accent-faint);
}

.avatar-placeholder {
  align-items: center;
  background: var(--input-bg);
  border: 2px dashed var(--border-color);
  border-radius: 50%;
  box-sizing: border-box;
  color: var(--muted-text-color);
  display: flex;
  font-size: 34px;
  height: 90px;
  justify-content: center;
  line-height: 1;
  width: 90px;
}

.avatar-camera-badge {
  position: absolute;
  right: -2px;
  bottom: -2px;
  width: 30px;
  height: 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--card-color);
  border: 1px solid var(--soft-border-color);
  box-shadow: 0 8px 20px var(--shadow-color);
  color: var(--accent-color);
  transition: transform 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.avatar-frame.editable:hover .avatar-camera-badge {
  background: var(--surface-hover-color);
  color: var(--text-color);
  transform: scale(1.06);
}

.avatar-camera-badge svg {
  width: 16px;
  height: 16px;
}

.avatar-actions-menu {
  position: fixed;
  background: var(--card-color);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  box-shadow: 0 12px 30px var(--shadow-color);
  display: none;
  flex-direction: column;
  min-width: 150px;
  overflow: hidden;
  transform: scale(0.96);
  transform-origin: top left;
  z-index: 1200;
  pointer-events: none;
}

.avatar-actions-menu.open {
  display: flex;
  animation: menuPop 0.14s ease forwards;
  pointer-events: auto;
}

.avatar-menu-item {
  background: transparent;
  border: none;
  color: var(--text-color);
  cursor: pointer;
  font-size: 14px;
  padding: 11px 12px;
  text-align: left;
}

.avatar-menu-item:hover {
  background: var(--surface-hover-color);
}

.avatar-menu-item.danger {
  color: #ff8b8b;
}

@keyframes menuPop {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(-2px);
  }

  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* Links */
#links {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.link {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;

  margin: 0 auto;
  padding: 10px 12px;

  max-width: 320px;
  width: 90%;

  background: var(--surface-color);
  border: 1px solid var(--soft-border-color);
  border-radius: 10px;
  box-shadow: inset 0 1px 0 color-mix(in srgb, var(--text-color), transparent 96%);

  text-decoration: none;
  color: var(--text-color);

  font-size: 15px;
  min-height: 46px;

  transition: all 0.2s ease;
}

#links .link + .link::before {
  content: "";
  position: absolute;
  top: -5px;
  left: 18px;
  right: 18px;
  height: 1px;
  background: linear-gradient(
    to right,
    transparent,
    color-mix(in srgb, var(--text-color), transparent 86%),
    transparent
  );
}

.link:hover {
  background: var(--surface-hover-color);
  border-color: var(--accent-soft);
  transform: translateY(-1px) scale(1.02);
}

.link:active {
  transform: scale(0.97);
}

.link-main {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 12px;
}

.link-icon {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: 9px;
  background: var(--icon-bg);
  border: 1px solid var(--icon-border);
  box-shadow: var(--icon-shadow);
  color: var(--muted-text-color);
  transition: background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

:root[data-theme-mode="light"] .link-icon {
  background: rgba(0, 0, 0, 0.1);
  border-color: rgba(0, 0, 0, 0.16);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.22), 0 4px 10px rgba(15, 23, 42, 0.08);
}

.link-icon.brand-icon {
  background: var(--icon-bg);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

:root[data-theme-mode="light"] .link-icon.brand-icon {
  background: rgba(0, 0, 0, 0.12);
  border-color: rgba(0, 0, 0, 0.18);
}

.link-icon.icon-contrast-dark {
  background: var(--icon-contrast-dark-bg);
  border-color: var(--icon-contrast-dark-border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16), 0 7px 16px rgba(0, 0, 0, 0.24), 0 0 0 1px rgba(0, 0, 0, 0.16);
}

:root[data-theme-mode="light"] .link-icon.icon-contrast-dark {
  background: rgba(0, 0, 0, 0.18);
  border-color: rgba(0, 0, 0, 0.22);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 5px 12px rgba(15, 23, 42, 0.12);
}

.link-icon.icon-contrast-light {
  background: var(--icon-contrast-light-bg);
  border-color: var(--icon-contrast-light-border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.86), 0 7px 16px rgba(15, 23, 42, 0.12), 0 0 0 1px rgba(255, 255, 255, 0.36);
}

.link-icon img {
  width: 22px;
  height: 22px;
  display: block;
  object-fit: contain;
  border-radius: 5px;
}

.link-icon.brand-icon img {
  width: 20px;
  height: 20px;
  border-radius: 0;
}

.link-icon.custom-link-icon img {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  object-fit: cover;
}

.link-icon.system-icon {
  color: var(--accent-color);
  background: color-mix(in srgb, var(--accent-color), transparent 86%);
  border-color: color-mix(in srgb, var(--accent-color), transparent 70%);
}

.link-icon svg {
  width: 21px;
  height: 21px;
  display: block;
}

.link-icon-hidden {
  display: none;
}

.link-title {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  opacity: 1;
}

/* Text inside link */
.link span:first-child {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.link span:last-child {
  font-size: 16px;
  opacity: 0.6;
}

.link .link-icon,
.link .link-main .link-title {
  font-size: 15px;
  opacity: 1;
}

.link div {
  display: flex;
  align-items: center;
  gap: 12px;
}

.link-edit-panel {
  align-items: stretch;
  flex-direction: column;
  gap: 10px;
  cursor: default;
}

.link-edit-fields {
  display: flex;
  flex-direction: column;
  gap: 8px;
  width: 100%;
}

.link .link-edit-fields {
  align-items: stretch;
  gap: 8px;
}

.theme-input {
  box-sizing: border-box;
  width: 100%;
  background: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-color);
  font-size: 14px;
  outline: none;
  padding: 10px 12px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.theme-input:focus {
  border-color: var(--accent-color);
  box-shadow: 0 0 0 3px var(--accent-faint);
}

.form-actions {
  display: flex;
  gap: 8px;
  justify-content: flex-end;
  width: 100%;
}

.link .form-actions {
  align-items: center;
  gap: 8px;
  justify-content: flex-end;
}

.ui-btn {
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  min-height: 40px;
  padding: 9px 12px;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.ui-btn:hover {
  transform: translateY(-1px);
}

.ui-btn.primary {
  background: var(--button-bg);
  color: var(--button-text);
  font-weight: 600;
}

.ui-btn.secondary {
  background: var(--surface-hover-color);
  border-color: var(--border-color);
  color: var(--text-color);
}

.modal-card {
  background: var(--card-color);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: 0 16px 50px var(--shadow-color);
  padding: 20px;
  width: 90%;
  max-width: 320px;
}

.modal-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 14px;
  text-align: left;
}

.smart-modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: color-mix(in srgb, var(--bg-color), transparent 28%);
  z-index: 2200;
}

.smart-link-card {
  width: min(92vw, 420px);
  max-width: 420px;
  max-height: min(86vh, 680px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.smart-link-card .smart-add-options {
  margin-right: -4px;
  overflow-y: auto;
  padding-bottom: 88px;
  padding-right: 4px;
}

.appearance-card {
  width: min(92vw, 430px);
  max-width: 430px;
  max-height: min(88vh, 720px);
  overflow-y: auto;
}

.appearance-section {
  margin-top: 16px;
  text-align: left;
}

.appearance-label {
  color: var(--text-color);
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 8px;
}

.appearance-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.appearance-chip,
.appearance-preset {
  border: 1px solid var(--soft-border-color);
  border-radius: 10px;
  background: var(--surface-color);
  color: var(--text-color);
  cursor: pointer;
  font: inherit;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.appearance-chip {
  min-height: 38px;
  padding: 8px 12px;
}

.appearance-chip.active,
.appearance-preset.active {
  border-color: var(--accent-color);
  box-shadow: 0 0 0 3px var(--accent-faint);
}

.appearance-chip:hover,
.appearance-preset:hover {
  background: var(--surface-hover-color);
  transform: translateY(-1px);
}

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

.appearance-preset {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px;
  text-align: left;
}

.appearance-swatch {
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 34px;
  border: 1px solid;
  border-radius: 10px;
}

.appearance-swatch span {
  width: 18px;
  height: 18px;
  display: block;
  border-radius: 6px;
}

.accent-row {
  align-items: center;
}

.accent-swatch {
  width: 34px;
  height: 34px;
  border: 2px solid var(--soft-border-color);
  border-radius: 50%;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.accent-swatch.active {
  border-color: var(--text-color);
  box-shadow: 0 0 0 3px var(--accent-faint);
  transform: scale(1.05);
}

.color-input {
  margin-top: 10px;
  height: 42px;
  padding: 6px;
}

.appearance-preview {
  margin: 16px 0 14px;
  padding: 12px;
  border: 1px solid var(--soft-border-color);
  border-radius: 10px;
  background: var(--surface-color);
  color: var(--text-color);
}

.smart-add-subtitle {
  color: var(--muted-text-color);
  font-size: 13px;
  line-height: 1.45;
  text-align: left;
  margin: -4px 0 16px;
}

.smart-add-section {
  margin-top: 14px;
}

.smart-add-section-title {
  color: var(--text-color);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0;
  text-align: left;
  margin-bottom: 8px;
}

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

.smart-add-option {
  min-width: 0;
  min-height: 48px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px;
  border: 1px solid var(--soft-border-color);
  border-radius: 10px;
  background: var(--surface-color);
  color: var(--text-color);
  font: inherit;
  font-size: 13px;
  text-align: left;
  cursor: pointer;
  touch-action: manipulation;
  transition: all 0.18s ease;
}

.smart-add-option span:last-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.smart-add-option:hover {
  background: var(--surface-hover-color);
  border-color: var(--accent-soft);
  transform: translateY(-1px);
}

.smart-link-form {
  display: none;
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--soft-border-color);
}

.smart-add-cancel {
  position: sticky;
  bottom: 0;
  justify-content: stretch;
  margin: 14px -18px -18px;
  padding: 12px 18px 18px;
  background: linear-gradient(
    to top,
    var(--card-color) 72%,
    color-mix(in srgb, var(--card-color), transparent 18%)
  );
  border-top: 1px solid var(--soft-border-color);
  z-index: 2;
}

.smart-add-cancel .ui-btn {
  width: 100%;
}

.edit-icon-section {
  background: var(--input-bg);
  border: 1px solid var(--soft-border-color);
  border-radius: 10px;
  padding: 10px;
}

.edit-icon-label {
  color: var(--muted-text-color);
  font-size: 12px;
  margin-bottom: 8px;
  text-align: left;
}

.edit-icon-controls {
  align-items: center;
  display: flex;
  gap: 8px;
}

.edit-icon-preview {
  align-items: center;
  display: inline-flex;
  flex: 0 0 auto;
}

.edit-icon-message {
  color: #ff8b8b;
  font-size: 12px;
  margin-top: 8px;
  min-height: 16px;
  text-align: left;
}

.edit-icon-controls .ui-btn {
  padding: 9px 10px;
}

@media (max-width: 420px) {
  .smart-add-cancel .ui-btn,
  .smart-link-form .form-actions .ui-btn,
  .edit-icon-controls .ui-btn {
    flex: 1;
  }

  .edit-icon-controls {
    flex-wrap: wrap;
  }

  .edit-icon-preview {
    flex-basis: 100%;
  }
}

.smart-link-preview {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  border: 1px solid var(--soft-border-color);
  border-radius: 10px;
  background: var(--input-bg);
  color: var(--muted-text-color);
  font-size: 12px;
  line-height: 1.35;
  text-align: left;
  overflow: hidden;
}

.smart-link-preview span:last-child {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (max-width: 420px) {
  .smart-add-grid {
    grid-template-columns: 1fr;
  }
}

.admin-header {
  align-items: center;
  display: flex;
  justify-content: space-between;
  margin-bottom: 18px;
}

.admin-title {
  font-size: 22px;
  font-weight: 700;
  margin: 0;
}

.admin-list {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.admin-row-name {
  font-weight: 600;
}

.admin-row-meta {
  color: var(--muted-text-color);
  font-size: 12px;
  margin-left: 8px;
}

.floating-menu {
  background: var(--card-color);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  box-shadow: 0 12px 30px var(--shadow-color);
  display: none;
  flex-direction: column;
  min-width: 150px;
  max-width: calc(100vw - 24px);
  max-height: calc(100vh - 24px);
  overflow: hidden;
  position: fixed;
  z-index: 2300;
  pointer-events: auto;
}

.floating-menu button {
  background: transparent;
  border: none;
  color: var(--text-color);
  cursor: pointer;
  font-size: 14px;
  min-height: 42px;
  padding: 11px 12px;
  text-align: left;
  white-space: nowrap;
}

.admin-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.confirm-card {
  width: min(90vw, 340px);
}

#menuPopup {
  background: var(--card-color) !important;
  border-color: var(--border-color) !important;
  max-width: calc(100vw - 24px);
  max-height: calc(100vh - 24px);
  overflow: hidden;
  box-shadow: 0 12px 30px var(--shadow-color);
  z-index: 2300 !important;
}

#menuPopup div {
  min-height: 42px;
  box-sizing: border-box;
  color: var(--text-color);
  white-space: nowrap;
}

#menuPopup div:hover {
  background: var(--surface-hover-color);
}

@media (max-width: 420px) {
  .admin-header {
    align-items: stretch;
    flex-direction: column;
    gap: 10px;
  }

  .admin-actions {
    width: 100%;
  }

  .admin-actions .ui-btn {
    flex: 1;
  }
}

.floating-menu button:hover {
  background: var(--surface-hover-color);
}

.floating-menu button.danger {
  color: #ff8b8b;
}

.admin-message {
  color: var(--muted-text-color);
  font-size: 13px;
  min-height: 18px;
  margin-bottom: 12px;
  text-align: left;
}

#card {
  background: var(--card-color);
  border-radius: 12px;
  padding: 15px;
  margin-top: 20px;
}

#tabs {
  display: flex;
  justify-content: space-around;
  margin-bottom: 15px;
  border-bottom: 1px solid var(--border-color);
}

#tabs button {
  background: none;
  border: none;
  color: var(--muted-text-color);
  padding: 10px;
  cursor: pointer;
  font-size: 14px;
}

#tabs button.active {
  color: var(--text-color);
  border-bottom: 2px solid var(--accent-color);
}

/* edit icon */
.edit-icon {
  margin-left: 6px;
  cursor: pointer;
  display: inline-block;
  font-size: 14px;
  color: var(--muted-text-color);

  transition: transform 0.2s ease, color 0.2s ease;
  transform-origin: center;
}

.edit-icon:hover {
  transform: scale(1.6) rotate(-20deg);
  color: var(--accent-color);
}

@keyframes editShake {
  0% {
    transform: rotate(0deg) scale(1);
  }

  18% {
    transform: rotate(-14deg) scale(1.18);
  }

  36% {
    transform: rotate(12deg) scale(1.18);
  }

  54% {
    transform: rotate(-9deg) scale(1.12);
  }

  72% {
    transform: rotate(7deg) scale(1.08);
  }

  100% {
    transform: rotate(0deg) scale(1);
  }
}

@keyframes editRowWake {
  0% {
    transform: translateX(0);
  }

  30% {
    transform: translateX(-2px);
  }

  60% {
    transform: translateX(2px);
  }

  100% {
    transform: translateX(0);
  }
}

.avatar-edit-icon {
  margin-left: 0;
  color: var(--text-color);
  background: var(--card-color);
  box-shadow: 0 0 0 2px var(--accent-faint);
}

.edit-menu-btn {
  margin-left: 0;
}

.edit-icon.edit-active {
  animation: editShake 0.75s ease both;
  animation-delay: var(--edit-delay, 0ms);
}

.link.edit-active {
  animation: editRowWake 0.35s ease both;
  animation-delay: var(--edit-delay, 0ms);
}

@media (prefers-reduced-motion: reduce) {
  .edit-icon.edit-active,
  .link.edit-active {
    animation: none;
  }
}
