/* Shared media presentation. One responsive size for every toplist media type. */
.vp .vp-card-media {
  --vp-media-ratio: 16 / 9;
  grid-area: media;
  width: 100%;
  max-width: 720px;
  min-width: 0;
  justify-self: center;
}

.vp .vp-image-frame {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  width: 100%;
  min-height: 100px;
  margin: 0;
  overflow: hidden;
  border-radius: 10px;
  background: #091c12;
  box-shadow: 0 0 0 1px #bfd19e22;
}

.vp .vp-server-art {
  display: block;
  width: 100%;
  height: auto;
  max-height: 340px;
  object-fit: contain;
  object-position: center;
}

/* Reserve the area before loading and retain it on error or retry. */
.vp .vp-card-media .vp-image-frame {
  aspect-ratio: var(--vp-media-ratio);
  min-height: 0;
}
.vp .vp-card-media .vp-server-art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  max-height: none;
}
.vp .vp-card-media .vp-media-error {
  position: absolute;
  inset: 0;
  overflow: auto;
  align-content: center;
}

.vp .vp-video-frame { width: 100%; min-width: 0; text-align: center; }
.vp .vp-video-frame iframe {
  display: block;
  width: 100%;
  aspect-ratio: var(--vp-media-ratio, 16 / 9);
  border: 0;
  border-radius: 10px;
  background: #091c12;
  box-shadow: 0 0 0 1px #bfd19e22;
}

/* Identical footer space for images and video links. */
.vp .vp-media-caption {
  display: block;
  margin-top: 10px;
  font-size: 12px;
  line-height: 20px;
  text-align: center;
}
.vp span.vp-media-caption { color: #9aaf94; }
.vp .vp-media-error { padding: 16px; text-align: center; font-size: 12px; color: #d7dcb6; }
.vp .vp-media-error button { display: block; margin: 12px auto 0; }
.vp .vp-profile-media { display: grid; gap: 22px; width: 100%; max-width: 800px; margin: 24px auto; }
.vp .vp-profile-media:empty { display: none; }
