/* Custom student / preview audio player chrome (look only — logic stays on the <audio> element) */

#inline-video {
  position: relative;
  width: 640px;
  height: 360px;
  background: url("https://scdn.realestateschool.org/img/podcasters.jpg") no-repeat center center;
  background-size: cover;
  max-width: 100%;
}

#inline-video audio.res-audio-native {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

#inline-video .res-audio-player {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 12px;
  width: auto;
  max-width: none;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.18);
}

#audio-player {
  margin: 0 0 1.25rem;
}

audio.res-audio-native {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  pointer-events: none !important;
  clip: rect(0, 0, 0, 0);
}

.res-audio-shell {
  position: relative;
  width: 100%;
}

.res-audio-player {
  --res-ap-bg: #f4f4f4;
  --res-ap-play: #1f4d2e;
  --res-ap-progress: #4f9a3a;
  --res-ap-track: #cfcfcf;
  --res-ap-muted: #9a9a9a;
  --res-ap-speed-border: #1f4d2e;
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 10px 24px 10px 18px;
  background: var(--res-ap-bg);
  border-radius: 999px;
  box-sizing: border-box;
}

.res-ap-play {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  border: none;
  border-radius: 50%;
  background: var(--res-ap-play);
  color: #fff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  line-height: 0;
  transition: transform 0.15s ease, background-color 0.15s ease;
}

.res-ap-play:hover {
  background: #163b23;
}

.res-ap-play:active {
  transform: scale(0.96);
}

.res-ap-play svg {
  width: 18px;
  height: 18px;
  display: block;
}

.res-ap-play .res-ap-icon-pause {
  display: none;
}

.res-audio-player.is-playing .res-ap-play .res-ap-icon-play {
  display: none;
}

.res-audio-player.is-playing .res-ap-play .res-ap-icon-pause {
  display: block;
}

.res-ap-time {
  flex: 0 0 auto;
  font-size: 13px;
  line-height: 1;
  color: var(--res-ap-muted);
  font-variant-numeric: tabular-nums;
  min-width: 2.5em;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.res-ap-progress-wrap {
  flex: 1 1 auto;
  position: relative;
  height: 24px;
  display: flex;
  align-items: center;
  min-width: 0;
}

.res-ap-progress {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  border-radius: 999px;
  background: linear-gradient(to right, var(--res-ap-progress) 0%, var(--res-ap-progress) var(--res-ap-pct, 0%), var(--res-ap-track) var(--res-ap-pct, 0%), var(--res-ap-track) 100%);
  outline: none;
  cursor: pointer;
  margin: 0;
}

.res-ap-progress::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--res-ap-play);
  border: 3px solid #fff;
  box-shadow: 0 0 0 1px rgba(31, 77, 46, 0.25);
  cursor: pointer;
}

.res-ap-progress::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--res-ap-play);
  border: 3px solid #fff;
  box-shadow: 0 0 0 1px rgba(31, 77, 46, 0.25);
  cursor: pointer;
}

.res-ap-progress::-moz-range-track {
  height: 4px;
  border-radius: 999px;
  background: transparent;
}

.res-ap-volume,
.res-ap-speed {
  flex: 0 0 auto;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  line-height: 0;
}

.res-ap-volume {
  color: var(--res-ap-muted);
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.res-ap-volume svg {
  width: 20px;
  height: 20px;
  display: block;
}

.res-ap-volume .res-ap-icon-muted {
  display: none;
}

.res-audio-player.is-muted .res-ap-volume .res-ap-icon-volume {
  display: none;
}

.res-audio-player.is-muted .res-ap-volume .res-ap-icon-muted {
  display: block;
}

.res-ap-speed {
  box-sizing: border-box;
  width: 3.5rem;
  min-width: 3.5rem;
  height: 32px;
  padding: 0;
  border-radius: 999px;
  border: 1.5px solid var(--res-ap-speed-border);
  background: var(--res-ap-bg);
  color: var(--res-ap-speed-border);
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

.res-ap-speed:hover {
  background: #e8eae5;
}

.res-audio-player.is-inactive {
  opacity: 0.55;
  pointer-events: none;
}

.res-audio-player.is-inactive .res-ap-play {
  background: #8a8a8a;
  cursor: default;
}

.res-audio-player.is-inactive .res-ap-play:hover {
  background: #8a8a8a;
}

.res-audio-player.is-inactive .res-ap-progress {
  cursor: default;
}

.res-audio-player.is-inactive .res-ap-speed {
  color: #8a8a8a;
  border-color: #8a8a8a;
}

@media screen and (max-width: 640px) {
  .res-audio-player {
    gap: 8px;
    padding: 8px 18px 8px 12px;
  }

  .res-ap-play {
    width: 42px;
    height: 42px;
  }

  .res-ap-play svg {
    width: 16px;
    height: 16px;
  }

  .res-ap-time {
    display: none;
  }

  .res-ap-speed {
    width: 3.25rem;
    min-width: 3.25rem;
    height: 28px;
    font-size: 12px;
  }

  #inline-video {
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
  }
}
