.rel-item-slot-td {
  position: relative;
  padding: 2px 5px;
  cursor: default;
}

.rel-item-slot-td[role="button"] {
  cursor: pointer;
}

.rel-item-slot-td::before {
  content: '';
  position: absolute;
  inset: 1px;
  background-color: var(--rel-slot-fill, transparent);
  pointer-events: none;
  z-index: 0;
}

.rel-item-slot__icon {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rel-item-slot__icon img {
  display: block;
}

.rel-item-tooltip {
  position: absolute;
  z-index: 9999;
  min-width: 260px;
  max-width: 340px;
  pointer-events: none;
  opacity: 0;
  transform: translate3d(0, 12px, 0) scale(0.96);
  transition: opacity 160ms cubic-bezier(0.4, 0, 0.2, 1),
    transform 160ms cubic-bezier(0.4, 0, 0.2, 1);
}

.rel-item-tooltip__content {
  position: relative;
  z-index: 0;
  /* Dark medieval background */
  background-image:
    /* radial-gradient(ellipse at top left, rgba(var(--rarity-rgb, 255, 255, 255), 0.25) 0%, rgba(0, 0, 0, 0.00) 25%), */
    linear-gradient(to bottom, rgba(var(--rarity-rgb, 255, 255, 255), 0.1) 0%, rgba(0, 0, 0, 0.00) 200%),
    url('../../theme-canary/themes/canary/images/themeboxes/box_bg_no_border.png');
  background-repeat: repeat-y;
  background-position: center top;
  background-size: 100% auto;
  color: #d5c3af;
  font-family: Verdana, Arial, sans-serif;
  font-size: 13px;
  line-height: 1.5;
  padding: 16px 18px;
  text-align: center;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
  margin: 4px 3px;
}

/* Border frame edges (corners) */
.rel-tooltip-edge {
  position: absolute;
  width: 5px;
  height: 5px;
  background-image: url('../../theme-canary/themes/canary/images/global/content/box-frame-edge.gif');
  background-repeat: no-repeat;
  z-index: 1;
}

.rel-tooltip-edge--left-top {
  top: 0;
  left: 0;
  background-position: top left;
}

.rel-tooltip-edge--right-top {
  top: 0;
  right: 0;
  background-position: top right;
}

.rel-tooltip-edge--left-bottom {
  bottom: 0;
  left: 0;
  background-position: bottom left;
}

.rel-tooltip-edge--right-bottom {
  bottom: 0;
  right: 0;
  background-position: bottom right;
}

/* Border frame sides */
.rel-tooltip-border {
  position: absolute;
  z-index: 1;
}

.rel-tooltip-border--top,
.rel-tooltip-border--bottom {
  left: 5px;
  right: 5px;
  height: 4px;
  background-image: url('../../theme-canary/themes/canary/images/global/content/table-headline-border.gif');
  background-repeat: repeat-x;
}

.rel-tooltip-border--top {
  top: 0;
}

.rel-tooltip-border--bottom {
  bottom: 0;
}

.rel-tooltip-border--left,
.rel-tooltip-border--right {
  top: 5px;
  bottom: 5px;
  width: 3px;
  background-image: url('../../theme-canary/themes/canary/images/global/content/box-frame-vertical.gif');
  background-repeat: repeat-y;
}

.rel-tooltip-border--left {
  left: 0;
}

.rel-tooltip-border--right {
  right: 0;
}

.rel-item-tooltip.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0) scale(1);
}

.rel-item-tooltip__header {
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: none;
  position: relative;
  background:
    linear-gradient(to right, rgba(139, 115, 85, 0.5) 0, rgba(139, 115, 85, 0.5) 100%) left bottom / calc(50% - 8px) 1px no-repeat,
    linear-gradient(to right, rgba(139, 115, 85, 0.5) 0, rgba(139, 115, 85, 0.5) 100%) right bottom / calc(50% - 8px) 1px no-repeat;
}

.rel-item-tooltip__header::after {
  content: '◆';
  position: absolute;
  bottom: -5px;
  left: 50%;
  transform: translateX(-50%);
  color: #8b7355;
  font-size: 11px;
}

.rel-item-tooltip__name {
  font-family: Verdana, Arial, sans-serif;
  font-size: 15px;
  font-weight: normal;
  margin-bottom: 4px;
  line-height: 1.3;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.rel-item-tooltip__icon {
  position: relative;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 12px;
  /* background: radial-gradient(circle, rgba(var(--rarity-rgb, 255, 255, 255), 0.4) 0%, rgba(0, 0, 0, 0) 70%); */
}

.rel-item-tooltip__icon img {
  display: block;
  width: 32px;
  height: 32px;
  image-rendering: pixelated;
  image-rendering: -moz-crisp-edges;
  image-rendering: crisp-edges;
}

.rel-item-tooltip__name-text {
  flex-shrink: 0;
}

.rel-item-tooltip__section {
  padding-top: 0;
  margin-top: 0;
  border-top: none;
}

.rel-item-tooltip__desc {
  margin: 0;
  color: #9d8fff;
  text-align: center;
  font-style: italic;
  font-size: 13px;
  line-height: 1.5;
}

.rel-item-tooltip__section.has-divider,
.rel-item-tooltip__footer.has-divider {
  border-top: none;
  padding-top: 12px;
  margin-top: 12px;
  position: relative;
  background:
    linear-gradient(to right, rgba(139, 115, 85, 0.5) 0, rgba(139, 115, 85, 0.5) 100%) left top / calc(50% - 8px) 1px no-repeat,
    linear-gradient(to right, rgba(139, 115, 85, 0.5) 0, rgba(139, 115, 85, 0.5) 100%) right top / calc(50% - 8px) 1px no-repeat;
}

.rel-item-tooltip__section.has-divider::before,
.rel-item-tooltip__footer.has-divider::before {
  content: '◆';
  position: absolute;
  top: -9px;
  left: 50%;
  transform: translateX(-50%);
  color: #8b7355;
  font-size: 11px;
}

.rel-item-tooltip__list {
  list-style: none;
  margin: 0;
  padding: 0;
  color: #3a2f24;
  text-align: center;
}

.rel-item-tooltip__list li {
  margin-bottom: 3px;
  color: #3a2f24;
  display: block;
  font-size: 13px;
}

.rel-item-tooltip__footer {
  border-top: none;
  padding-top: 0;
  margin-top: 0;
  font-size: 12px;
  color: #6b5d4f;
  text-align: center;
  font-style: italic;
}

.rel-item-tooltip__badge {
  display: inline-block;
  padding: 2px 8px;
  font-size: 11px;
  margin-left: 6px;
  background: rgba(92, 74, 52, 0.2);
  border: 1px solid rgba(92, 74, 52, 0.4);
  border-radius: 3px;
}

.rel-item-tooltip__list li.is-upgrade {
  color: #9f9dfd;
}

.rel-item-tooltip__stat-label {
  color: #b7a38e;
  font-size: 13px;
  text-transform: none;
}

.rel-item-tooltip__stat-value {
  color: #d5c3af;
}

.rel-item-tooltip__stat-value--upgrade {
  color: #9f9dfd;
}

.rel-item-tooltip__stat-extra {
  color: #a89886;
  opacity: 0.85;
  font-size: 12px;
  margin-left: 4px;
  font-style: italic;
}