/* Emoji are inline text, even inside cards whose other images are full-width artwork. */
body img.twemoji {
  width: 1em !important;
  height: 1em !important;
  max-width: none !important;
  margin: 0 0.05em !important;
  display: inline-block !important;
  vertical-align: -0.1em;
  object-fit: contain;
  border: 0;
  border-radius: 0;
}

.developer-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  font-size: 20px;
  margin-left: 4px;
  vertical-align: middle;
}

body .developer-badge img.twemoji {
  width: 100% !important;
  height: 100% !important;
  margin: 0 !important;
}

.navbar .developer-badge {
  width: 16px;
  height: 16px;
  font-size: 16px;
}

.automation-badge {
  display: inline-flex;
  align-items: center;
  vertical-align: middle;
  margin-left: 4px;
}
.automation-badge .twemoji {
  width: 1em;
  height: 1em;
}

/* Badges explain themselves in a popup when clicked (scripts/utils/emoji.js). */
img[src$='verified.png']:not(.notif-pfp):not(.toast-icon),
[data-badge] {
  cursor: pointer;
}

.badge-popup {
  position: absolute;
  z-index: 1450;
  box-sizing: border-box;
  width: max-content;
  max-width: min(300px, calc(100vw - 16px));
  padding: 10px 12px;
  background: white;
  border: 1px solid #ccc;
  border-radius: 3px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  color: #222;
  font-family: Arial, Helvetica, sans-serif;
  font-size: 0.85rem;
  font-weight: normal;
  line-height: 1.4;
  text-align: left;
  white-space: normal;
}

.badge-popup p {
  margin: 0;
}

.badge-popup p + p {
  margin-top: 6px;
}

.badge-popup a {
  color: inherit;
  font-weight: bold;
}
