.ahangar-videocast,
.ahangar-videocast *,
.ahangar-videocast *::before,
.ahangar-videocast *::after {
  box-sizing: border-box;
}

.ahangar-videocast {
  width: 100%;
}

.ahangar-videocast__button {
  position: relative;
  display: block;
  width: 100%;
  min-height: 80px;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 8px;
  background: #111827;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.ahangar-videocast__button[disabled] {
  cursor: default;
}

.ahangar-videocast__button:focus-visible {
  outline: 3px solid #1d4ed8;
  outline-offset: 3px;
}

.ahangar-videocast__image {
  display: block;
  width: 100%;
  height: 100% !important;
  max-width: none;
  object-fit: cover;
  transition: transform 220ms ease;
}

.ahangar-videocast__button:not([disabled]):hover .ahangar-videocast__image,
.ahangar-videocast__button:not([disabled]):focus-visible .ahangar-videocast__image {
  transform: scale(1.035);
}

.ahangar-videocast__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.32));
  pointer-events: none;
}

.ahangar-videocast__play {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.58);
  border-radius: 999px;
  transform: translate(-50%, -50%);
  transition: transform 180ms ease, background-color 180ms ease;
}

.ahangar-videocast__button:not([disabled]):hover .ahangar-videocast__play,
.ahangar-videocast__button:not([disabled]):focus-visible .ahangar-videocast__play {
  transform: translate(-50%, -50%) scale(1.06);
}

.ahangar-videocast__play svg {
  display: block;
  width: 25px;
  height: 25px;
  margin-left: 3px;
  fill: currentColor;
}

.ahangar-videocast__time {
  position: absolute;
  right: 12px;
  bottom: 12px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  max-width: calc(100% - 24px);
  min-height: 28px;
  padding: 3px 10px;
  color: #ffffff;
  background: rgba(0, 0, 0, 0.66);
  border-radius: 6px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.4;
  white-space: nowrap;
}

.ahangar-videocast-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.ahangar-videocast-modal[hidden] {
  display: none;
}

.ahangar-videocast-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 8, 16, 0.78);
}

.ahangar-videocast-modal__panel {
  position: relative;
  z-index: 1;
  width: min(960px, 100%);
  max-height: calc(100vh - 48px);
  overflow: hidden;
  background: #05070c;
  border-radius: 8px;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.38);
}

.ahangar-videocast-modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 14px;
  color: #ffffff;
}

.ahangar-videocast-modal__title {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  color: inherit;
  font-size: 16px;
  font-weight: 700;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.ahangar-videocast-modal__close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  padding: 0;
  color: #ffffff;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  cursor: pointer;
  font-size: 30px;
  line-height: 1;
}

.ahangar-videocast-modal__close:hover,
.ahangar-videocast-modal__close:focus-visible {
  background: rgba(255, 255, 255, 0.12);
}

.ahangar-videocast-modal__close:focus-visible {
  outline: 3px solid #ffffff;
  outline-offset: 2px;
}

.ahangar-videocast-modal__video {
  display: block;
  width: 100%;
  max-height: calc(100vh - 132px);
  background: #000000;
  aspect-ratio: 16 / 9;
}

.ahangar-videocast__noscript {
  display: inline-block;
  margin-top: 8px;
}

body.ahangar-videocast-modal-open {
  overflow: hidden;
}

@media (max-width: 767px) {
  .ahangar-videocast-modal {
    align-items: center;
    padding: 12px;
  }

  .ahangar-videocast-modal__panel {
    max-height: calc(100vh - 24px);
    border-radius: 6px;
  }

  .ahangar-videocast-modal__header {
    padding: 10px;
  }

  .ahangar-videocast-modal__title {
    font-size: 14px;
  }

  .ahangar-videocast-modal__video {
    max-height: calc(100vh - 104px);
  }

  .ahangar-videocast__play {
    width: 48px;
    height: 48px;
  }
}
