/**
 * Block type frontend style definition.
 * It will be enqueued both in the editor and when viewing
 * the content on the front of the site.
 */
/* stylelint-disable declaration-property-unit-allowed-list */
/* stylelint-enable declaration-property-unit-allowed-list */
@keyframes twitch-loading-spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}
.wp-block-xwp-twitch-player__title {
  font-family: var(--evolve-media-theme--typography--font-family--heading);
  font-size: var(--evolve-media-theme--typography--font-size--h4);
  font-weight: var(--evolve-media-theme--typography--font-weight--h4);
  line-height: var(--evolve-media-theme--typography--line-height--small);
  letter-spacing: var(--evolve-media-theme--typography--letter-spacing--none);
  font-weight: var(--evolve-media-theme--typography--font-weight--bold);
  margin-bottom: var(--evolve-media-theme--spacing--tiny);
}
@media (min-width: 782px) {
  .wp-block-xwp-twitch-player__title {
    margin-bottom: var(--evolve-media-theme--spacing--small);
  }
}

.wp-block-xwp-twitch-player__media {
  color: #fff;
  background-color: #000;
  display: grid;
  grid-template: auto/auto;
  position: relative;
}

.wp-block-xwp-twitch-player__media > * {
  grid-column: 1/-1;
  grid-row: 1/-1;
  position: relative;
  transition: opacity 0.3s ease;
}

.wp-block-xwp-twitch-player__player {
  aspect-ratio: 16/9;
  background-color: #000;
  display: none;
}

.wp-block-xwp-twitch-player.is-online.is-ready .wp-block-xwp-twitch-player__player {
  display: flex;
}

.wp-block-xwp-twitch-player__player > * {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
}

.wp-block-xwp-twitch-player__offline {
  display: none;
  flex-direction: column;
  gap: var(--evolve-media-theme--spacing--tiny);
  padding: var(--evolve-media-theme--spacing--small);
  text-decoration: none;
  color: inherit;
}

.wp-block-xwp-twitch-player__offline:hover {
  color: inherit;
}

.wp-block-xwp-twitch-player.is-offline.is-ready .wp-block-xwp-twitch-player__offline {
  display: flex;
}

.wp-block-xwp-twitch-player__offline-logo {
  height: 20px;
  width: 100%;
  object-fit: contain;
  object-position: left center;
}

.wp-block-xwp-twitch-player__offline-title {
  font-family: var(--evolve-media-theme--typography--font-family--heading);
  font-size: var(--evolve-media-theme--typography--font-size--h2);
  font-weight: var(--evolve-media-theme--typography--font-weight--h2);
  line-height: var(--evolve-media-theme--typography--line-height--tiny);
  letter-spacing: var(--evolve-media-theme--typography--letter-spacing--none);
  margin-top: 0;
  margin-bottom: 0;
}

.wp-block-xwp-twitch-player__loading {
  display: flex;
  align-items: center;
  justify-content: center;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  background-color: inherit;
  transition: visibility 0.4s ease, opacity 0.4s ease;
  aspect-ratio: 16/9;
}

.wp-block-xwp-twitch-player.is-ready .wp-block-xwp-twitch-player__loading {
  visibility: hidden;
  opacity: 0;
}

.wp-block-xwp-twitch-player__loading::after {
  content: "";
  display: block;
  border: 8px solid rgba(255, 255, 255, 0.2);
  border-top-color: #9146ff;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: twitch-loading-spin 4s linear infinite;
}

.wp-block-xwp-twitch-player__button {
  display: flex;
  background-color: #9146ff;
  color: #fff;
  text-align: center;
  margin-top: var(--evolve-media-theme--spacing--small);
  text-decoration: none;
  line-height: 1;
  padding: 1em;
  gap: 10px;
  align-items: center;
  justify-content: center;
  transition: background-color 0.3s ease;
}

.wp-block-xwp-twitch-player__button:hover {
  text-decoration: none;
  color: #fff;
  background-color: #5c16c5;
}