/* Video.js transport with Gonwatch's borderless, in-picture presentation. */
#player {
  padding: 0; border: 0; border-radius: 0; box-shadow: none; background: #000;
  --menu-surface: #191b20fa; --menu-selected: #ffffff18; --menu-hover: #ffffff28;
  --menu-shadow: 0 6px 30px #0008; --menu-radius: 8px;
}
#gonwatch-video.video-js {
  width: 100%; height: auto; aspect-ratio: 16 / 9; max-height: 80dvh;
  font-family: inherit; color: #fff; background: #000;
}
#gonwatch-video.video-js video {
  width: 100%; height: 100%; max-height: none; min-height: 0;
  aspect-ratio: auto; object-fit: contain;
}
#gonwatch-video.vjs-fullscreen { height: 100%; max-height: none; aspect-ratio: auto; }
#gonwatch-video .player-heading {
  z-index: 5; padding: 18px 22px 40px; font-size: 14px;
  background: linear-gradient(#000b, transparent);
}
#gonwatch-video .player-heading h2 { font-size: 18px; line-height: 1.4; }
#gonwatch-video .player-bottom {
  inset: auto 20px 82px; display: block; padding: 0; background: none;
  pointer-events: none; border: 0; z-index: 4;
}
#gonwatch-video #player-status, #gonwatch-video #subtitle-status {
  font-size: 12px; color: #eee; text-shadow: 0 1px 4px #000;
  margin: 0; max-width: 100%;
}
#gonwatch-video #subtitle-status:empty { display: none; }
#gonwatch-video .vjs-control-bar {
  display: flex;
  height: 58px; padding: 6px 14px; align-items: center;
  background: linear-gradient(transparent, #000e 35%);
  z-index: 5;
}
#gonwatch-video .vjs-control { height: 44px; min-width: 40px; }
#gonwatch-video button { box-shadow: none; border: 0; border-radius: 6px; }
#gonwatch-video .vjs-button { padding: 0; background: transparent; }
#gonwatch-video .vjs-icon-placeholder::before { line-height: 44px; font-size: 23px; }
#gonwatch-video button:focus-visible, #gonwatch-video select:focus-visible {
  outline: 2px solid #fff; outline-offset: -3px;
}
#gonwatch-video .vjs-progress-control {
  position: absolute; left: 20px; right: 20px; top: -14px;
  width: auto; height: 24px; min-height: 24px;
}
#gonwatch-video .vjs-progress-holder { margin: 0; height: 3px; background: #ffffff45; }
#gonwatch-video .vjs-play-progress { background: #fff; }
#gonwatch-video .vjs-volume-level { background: #fff; }
#gonwatch-video .vjs-volume-panel { position: relative; z-index: 6; }
/* Attach the popup to the button instead of Video.js's em-based offset.
   The entire area from button to slider remains a single pointer target. */
#gonwatch-video .vjs-volume-panel .vjs-volume-control.vjs-volume-vertical {
  position: absolute; bottom: 100%; left: 0; width: 44px; height: 120px;
  margin: 0; padding: 0; border-radius: 8px 8px 0 0;
  background: var(--menu-surface); box-shadow: var(--menu-shadow);
  visibility: hidden; opacity: 0; pointer-events: none; transition: none;
}
#gonwatch-video .vjs-volume-panel:is(:hover, :focus-within, .vjs-slider-active) .vjs-volume-control.vjs-volume-vertical {
  visibility: visible; opacity: 1; pointer-events: auto;
}
#gonwatch-video .vjs-volume-panel[data-menu-dismissed] .vjs-volume-control.vjs-volume-vertical {
  visibility: hidden; opacity: 0; pointer-events: none;
}
#gonwatch-video .vjs-subs-caps-button[data-menu-dismissed] .vjs-menu { display: none; }
#gonwatch-video .vjs-volume-bar.vjs-slider-vertical { height: 84px; margin: 18px auto; }
#gonwatch-video:has(.vjs-volume-panel:is(:hover, :focus-within, .vjs-slider-active)) .vjs-control-bar {
  opacity: 1; visibility: visible; pointer-events: auto;
}
#gonwatch-video .vjs-time-control { font-size: 12px; line-height: 44px; padding: 0 4px; min-width: 0; }
#gonwatch-video .vjs-current-time, #gonwatch-video .vjs-time-divider, #gonwatch-video .vjs-duration { display: block; }
#gonwatch-video .vjs-duration { margin-right: auto; }
#gonwatch-video .vjs-live-control { margin-right: auto; }
#gonwatch-video .vjs-menu-button-popup .vjs-menu {
  bottom: 44px; margin-bottom: 0; font-size: 12px;
}
#gonwatch-video .vjs-menu-content {
  background: var(--menu-surface); border-radius: var(--menu-radius); padding: 6px;
  max-height: min(280px, var(--player-menu-height, 40dvh)); box-shadow: var(--menu-shadow);
}
#gonwatch-video .vjs-menu li { padding: 10px 12px; text-transform: none; border-radius: 4px; }
#gonwatch-video .vjs-menu li.vjs-selected { color: #fff; background: var(--menu-selected); }
#gonwatch-video .vjs-menu li:focus, #gonwatch-video .vjs-menu li:hover { color: #fff; background: var(--menu-hover); }
#gonwatch-video .vjs-subs-caps-button { z-index: 6; }
#gonwatch-video .vjs-subs-caps-button .vjs-menu {
  left: 50%; right: auto; transform: translateX(-50%); bottom: 100%; width: 220px; height: auto;
  max-width: 70vw; padding: 0 0 8px; margin: 0; border: 0;
}
#gonwatch-video .vjs-subs-caps-button .vjs-menu-content {
  position: static; width: 100%; max-height: min(280px, var(--player-menu-height, 40dvh));
  padding: 6px; background: var(--menu-surface); text-align: left;
  overscroll-behavior: contain;
}
#gonwatch-video .vjs-subs-caps-button .vjs-menu-item {
  position: relative; min-height: 44px; padding: 13px 32px 13px 12px;
  font-size: 13px; line-height: 18px; text-align: left;
  justify-content: flex-start;
}
#gonwatch-video .vjs-subs-caps-button .vjs-selected::after {
  content: "✓"; position: absolute; right: 12px; font-weight: 600;
}
#gonwatch-video .vjs-texttrack-settings { font-size: 11px; color: #b8bcc5; }
@media (hover: hover) {
  #gonwatch-video .vjs-subs-caps-button:not([data-menu-dismissed]):hover .vjs-menu { display: block; }
  #gonwatch-video:has(.vjs-subs-caps-button:hover) .vjs-control-bar {
    opacity: 1; visibility: visible; pointer-events: auto;
  }
}
#gonwatch-video #quality-control { gap: 0; font-size: 0; margin: 0 4px; }
#gonwatch-video #quality-control[hidden] { display: none; }
#gonwatch-video #player-quality {
  width: 80px; min-height: 44px; padding: 6px; font-size: 12px;
  border: 0; background: transparent; color: #fff; border-radius: 6px;
  font-variant-numeric: tabular-nums;
}
#gonwatch-video #other-source {
  flex: 0 0 60px; min-height: 44px; margin: 0 4px; padding: 0;
  font-size: 0; background: transparent; color: #fff;
}
#gonwatch-video #other-source::after { content: "Sources"; font-size: 12px; }
#player .player-menu {
  position: absolute; right: 16px; bottom: 72px; z-index: 7;
  width: min(240px, calc(100% - 32px)); max-height: min(280px, calc(100% - 110px));
  overflow: auto; padding: 6px; background: var(--menu-surface);
  border: 0; border-radius: var(--menu-radius); box-shadow: var(--menu-shadow);
  overscroll-behavior: contain;
}
#player .player-menu h3 { font-size: 12px; margin: 8px 12px; color: #c6c9ce; font-weight: 600; }
#player .player-menu p { font-size: 12px; color: #c6c9ce; margin: 0 12px 8px; line-height: 1.5; }
#player .player-menu button {
  position: relative; display: block; width: 100%; min-height: 44px; padding: 13px 32px 13px 12px;
  text-align: left; font-size: 13px; line-height: 18px; background: transparent; color: #fff;
  border-radius: 4px; overflow-wrap: anywhere;
}
#player .player-menu h4 { font-size: 11px; margin: 12px 12px 4px; color: var(--accent); font-weight: 600; letter-spacing: .04em; }
#player .player-menu button small { display: block; font-size: 12px; color: #c6c9ce; }
#player .player-menu button[aria-checked="true"] { background: var(--menu-selected); }
#player .player-menu button[aria-checked="true"]::after { content: "✓"; position: absolute; right: 12px; font-weight: 600; }
#player .player-menu button:has(small)::after { top: 13px; }
#player .player-menu button:hover,
#player .player-menu button:focus-visible { background: var(--menu-hover); }
#gonwatch-video :is(#player-quality, #other-source):is(:hover, [aria-expanded="true"]) { background: var(--menu-selected); }
#gonwatch-video:has(.player-menu:not([hidden])) .vjs-control-bar { opacity: 1; visibility: visible; pointer-events: auto; }
/* Skip Recap, Skip Intro and the credits' Next Episode: above the seek bar,
   under every menu, and beside an open one rather than behind it. */
#gonwatch-video #player-skip {
  position: absolute; right: 20px; bottom: 82px; z-index: 4;
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 16px;
  font-size: 13px; font-weight: 600; white-space: nowrap; color: #fff;
  background: var(--menu-surface); box-shadow: var(--menu-shadow);
}
#gonwatch-video #player-skip[hidden] { display: none; }
#gonwatch-video #player-skip:hover { background: linear-gradient(var(--menu-hover), var(--menu-hover)), var(--menu-surface); }
#gonwatch-video #player-skip svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
#gonwatch-video:has(.player-menu:not([hidden])) #player-skip { right: calc(min(240px, 100% - 32px) + 28px); }
#gonwatch-video .vjs-text-track-display { inset: 0 5% 88px !important; pointer-events: none; z-index: 4; }
#gonwatch-video .vjs-text-track-display > div { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; }
#gonwatch-video .vjs-text-track-cue {
  position: relative !important; inset: auto !important; width: auto !important;
  height: auto !important; max-width: 100%; text-align: center !important;
  font: 500 clamp(16px, 2vw, 28px)/1.35 sans-serif !important;
}
#gonwatch-video .vjs-text-track-cue > div { padding: 2px 6px; }
#gonwatch-video.vjs-user-inactive.vjs-playing .player-heading,
#gonwatch-video.vjs-user-inactive.vjs-playing .player-bottom { opacity: 0; pointer-events: none; }
#gonwatch-video:has(:focus-visible) .player-heading,
#gonwatch-video:has(:focus-visible) .player-bottom,
#gonwatch-video:has(:focus-visible) .vjs-control-bar { opacity: 1; pointer-events: auto; visibility: visible; }
#gonwatch-video .vjs-big-play-button { border: 0; border-radius: 50%; width: 64px; height: 64px; line-height: 64px; top: 50%; left: 50%; margin: -32px 0 0 -32px; background: #0009; }
#source-progress { z-index: 3; border: 0; border-radius: 0; padding: 70px 24px 100px; font-size: 14px; }
#source-progress p { line-height: 1.6; }
#gonwatch-video #pause-info { z-index: 2; inset: 0; padding: 80px 5% 120px; }
@media (max-width: 600px) {
  #gonwatch-video.video-js { min-height: 300px; }
  #gonwatch-video .player-heading { padding: 12px 12px 30px; }
  #gonwatch-video .player-heading h2 { font-size: 14px; }
  #gonwatch-video .vjs-control-bar { padding-inline: 6px; }
  #gonwatch-video .vjs-time-control { display: none; }
  #gonwatch-video .vjs-volume-panel { margin-right: auto; }
  #gonwatch-video .vjs-progress-control { left: 14px; right: 14px; }
  #gonwatch-video .player-bottom { left: 14px; right: 14px; }
  #gonwatch-video #player-skip { right: 14px; }
  /* No room beside a menu at this width: the menu has the corner while it is open. */
  #gonwatch-video:has(.player-menu:not([hidden])) #player-skip { display: none; }
  #gonwatch-video #player-quality { width: 66px; }
  #gonwatch-video #other-source { flex-basis: 52px; margin: 0; }
  #gonwatch-video #pause-info { padding: 65px 14px 125px; }
  #gonwatch-video #pause-copy { max-width: 100%; }
  #gonwatch-video #pause-copy .pause-logo { max-height: 32px; }
  #gonwatch-video #pause-copy .pause-meta { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
}
@media (max-height: 500px) and (min-width: 601px) {
  #gonwatch-video #pause-info { padding: 65px 4% 100px; }
  #gonwatch-video #pause-copy .pause-logo { max-height: 42px; margin: 4px 0; }
  #gonwatch-video #pause-copy h3 { font-size: 24px; margin: 4px 0; }
  #gonwatch-video #pause-copy .eyebrow { font-size: 9px; margin: 0; }
  #gonwatch-video #pause-copy .pause-meta { font-size: 10px; margin: 4px 0; }
  #gonwatch-video #pause-copy .pause-plot { font-size: 12px; margin: 4px 0; -webkit-line-clamp: 2; }
}
#gonwatch-video .player-heading > div:first-child { min-width: 0; }
#gonwatch-video .player-heading h2 { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#gonwatch-video .player-window-actions { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
#gonwatch-video .player-window-actions button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 12px; color: #fff; background: #ffffff0c; font-size: 12px; white-space: nowrap; transition: background-color 150ms ease; }
#gonwatch-video .player-window-actions button[hidden] { display: none; }
#gonwatch-video .player-window-actions button:hover,
#gonwatch-video .player-window-actions button[aria-expanded="true"] { background: #ffffff24; }
#gonwatch-video #close-player { min-width: 44px; padding: 0; font-size: 26px; }
#gonwatch-video .vjs-control-bar :is(#player-next-episode, #player-episodes-toggle) { flex: 0 0 auto; display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 44px; min-width: 44px; padding: 0 10px; color: #fff; background: transparent; font-size: 12px; }
#gonwatch-video .vjs-control-bar :is(#player-next-episode, #player-episodes-toggle)[hidden] { display: none; }
#gonwatch-video .vjs-control-bar :is(#player-next-episode, #player-episodes-toggle):is(:hover, [aria-expanded="true"]) { background: var(--menu-selected); }
#gonwatch-video .vjs-control-bar :is(#player-next-episode, #player-episodes-toggle) svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
#gonwatch-video #player-next-episode span { display: none; }
#player #player-episodes { position: absolute; z-index: 8; inset: 12px 12px 76px auto; width: min(410px, calc(100% - 24px)); display: flex; flex-direction: column; overflow: hidden; border: 1px solid #ffffff1c; border-radius: 12px; background: #121419f7; box-shadow: 0 8px 36px #0008; backdrop-filter: blur(16px); text-align: left; }
#player #player-episodes[hidden] { display: none; }
#player .player-episodes-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 12px 8px 16px; flex-shrink: 0; }
#player .player-episodes-heading div { min-width: 0; }
#player .player-episodes-heading h3 { margin: 0; font-size: 17px; font-weight: 650; }
#player #player-episodes-show { margin: 4px 0 0; color: #aeb5bf; font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#player #close-player-episodes { flex: 0 0 44px; height: 44px; padding: 0; font-size: 26px; background: transparent; color: #cbd0d8; }
#player #close-player-episodes:hover { background: #ffffff16; color: #fff; }
#player .player-season-field { display: flex; align-items: center; gap: 16px; margin: 0 16px 10px; color: #aeb5bf; font-size: 12px; }
#player .player-season-field select { min-width: 0; flex: 1; height: 40px; padding: 0 10px; color: #fff; background: #ffffff0d; border: 1px solid #ffffff18; border-radius: 6px; font: inherit; font-size: 13px; }
#player .player-season-field select option { background: #17191e; }
#player #player-episode-list { min-height: 0; flex: 1; overflow: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #ffffff40 transparent; padding: 0 6px 6px; }
#player .player-episode-row { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 80px; padding: 10px; margin: 0 0 3px; border-radius: 7px; text-align: left; background: transparent; color: #fff; transition: background-color 150ms ease; }
#player .player-episode-row:hover { background: #ffffff0e; }
#player .player-episode-row[aria-current="true"] { background: #d4ef8612; box-shadow: inset 3px 0 var(--accent); }
#player .player-episode-row[aria-current="true"] .player-episode-meta { color: var(--accent); }
#player .player-episode-row:disabled { opacity: .45; cursor: default; }
#player .player-episode-art { position: relative; display: grid; place-items: center; width: 96px; aspect-ratio: 16/9; flex: 0 0 96px; overflow: hidden; border-radius: 5px; background: #242830; box-shadow: inset 0 0 0 1px #ffffff0c; }
#player .player-episode-art img { width: 100%; height: 100%; object-fit: cover; }
#player .player-episode-number { position: absolute; left: 5px; bottom: 5px; background: #000b; border-radius: 3px; padding: 2px 5px; font-size: 11px; font-variant-numeric: tabular-nums; }
#player .player-episode-watched-seal { position: absolute; top: 5px; right: 5px; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: #c9ed93; color: #16220e; font-size: 14px; font-weight: 750; box-shadow: 0 1px 5px #0008; }
#player .player-episode-row.is-watched .player-episode-meta { color: #c9ed93; }
#player .player-episode-art progress { position: absolute; inset: auto 0 0; width: 100%; height: 3px; border: 0; border-radius: 0; }
#player .player-episode-copy { display: flex; flex-direction: column; min-width: 0; gap: 4px; }
#player .player-episode-copy strong { font-size: 13px; line-height: 1.35; font-weight: 600; text-wrap: pretty; }
#player .player-episode-meta { font-size: 11px; line-height: 1.4; color: #b4bdc8; font-variant-numeric: tabular-nums; }
#player .player-episode-synopsis { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 11px; line-height: 1.45; color: #a0a8b3; }
#player #player-episode-status { margin: 0; padding: 10px 16px; flex-shrink: 0; color: #d5dbe4; font-size: 12px; line-height: 1.45; border-top: 1px solid #ffffff12; }
#player #player-episode-status:empty { display: none; }
#player #player-episode-list .content-state { padding: 16px; }
#player #player-episode-list .skeleton-grid { display: block; }
#gonwatch-video:has(#player-episodes:not([hidden])) .player-heading,
#gonwatch-video:has(#player-episodes:not([hidden])) .vjs-control-bar { opacity: 1; visibility: visible; pointer-events: auto; }
@media (max-width: 700px) {
  #gonwatch-video .player-window-actions { gap: 2px; }
  #gonwatch-video .player-window-actions button { padding-inline: 10px; }
  #gonwatch-video .player-heading { gap: 8px; }
  #player #player-episodes { inset: 0; width: 100%; border-radius: 0; border: 0; background: #121419fc; }
  #player .player-episode-synopsis { -webkit-line-clamp: 1; }
}
@media (max-width: 600px) {
  #gonwatch-video .vjs-control-bar :is(#player-next-episode, #player-episodes-toggle) { flex-basis: 40px; min-width: 40px; padding: 0; }
  #gonwatch-video #player-episodes-toggle span { display: none; }
  #gonwatch-video #player-quality { width: 44px; padding-inline: 2px; }
  #gonwatch-video #quality-control { margin: 0; }
  #gonwatch-video #other-source { flex-basis: 44px; }
  #gonwatch-video #other-source::after { font-size: 11px; }
}
@media (prefers-reduced-motion: reduce) {
  #gonwatch-video *, #gonwatch-video *::before { transition: none !important; }
}
.keyboard-help { margin-top: 18px; font-size: .72rem; opacity: .65; line-height: 1.7; }
@media (pointer: coarse) { .keyboard-help { display: none; } }
