/* Shared phone tokens: edge-to-edge artwork, quiet graphite chrome and white actions. */
:root {
  --phone-chrome: rgba(16, 16, 16, 0.86);
  --phone-edge: 20px;
  --video-ratio: 16/9;
}
.bottom-nav {
  direction: rtl;
}
#homeHero {
  touch-action: pan-y;
  user-select: none;
  -webkit-user-select: none;
}
#homeHero img {
  -webkit-user-drag: none;
}
.controls-hidden .player-panel,
.controls-hidden .player-top {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.18s;
}
.controls-hidden .player-top .icon-button {
  pointer-events: none;
}
.player-top,
.player-panel {
  transition: opacity 0.18s;
}
.watch-publisher[hidden] {
  display: block;
  visibility: hidden;
  pointer-events: none;
}
html {
  scroll-padding-top: 120px;
}
.topbar {
  position: fixed;
  inset: 0 0 auto;
  z-index: 40;
  background: linear-gradient(#000c, #0005, transparent);
  border: 0;
  backdrop-filter: none;
  padding-top: max(14px, env(safe-area-inset-top));
  height: 82px;
}
.top-actions {
  direction: ltr;
  gap: 8px;
}
.top-actions .icon-button {
  background: #17171755;
  backdrop-filter: blur(16px);
}
#connection {
  display: none !important;
}
.view {
  padding-top: 105px;
}
.home-page .view {
  padding-top: 0;
}
.platform-strip {
  position: absolute;
  z-index: 20;
  top: 84px;
  inset-inline: 0;
  display: flex;
  gap: 8px;
  padding: 4px 20px 12px;
  overflow: auto;
  scrollbar-width: none;
  direction: ltr;
  background: linear-gradient(#0005, transparent);
}
.platform-tab {
  padding: 9px 14px;
  white-space: nowrap;
  flex: none;
  background: #16161666;
  border: 1px solid #ffffff30;
  border-radius: 30px;
  font-size: 12px;
  backdrop-filter: blur(14px);
}
.platform-tab.active {
  background: white;
  color: black;
  border-color: white;
  font-weight: 700;
}
.home-page #homeHero {
  margin: 0 -22px;
}
.home-page .hero {
  height: min(64svh, 620px);
  min-height: 440px;
  margin: 0;
  border-radius: 0;
}
.home-page .hero > img {
  object-position: center 28%;
}
.home-page .hero:after {
  background:
    linear-gradient(0deg, #111 0%, #111e 7%, transparent 72%),
    linear-gradient(#0006, transparent 30%);
}
.hero-copy {
  padding: 36px 25px 28px;
}
.hero h1 {
  font-size: clamp(32px, 7vw, 52px);
  line-height: 1.12;
  margin: 12px 0;
  text-wrap: balance;
}
.hero-label {
  border: 0;
  background: #ffffff16;
}
.hero .actions {
  margin-top: 18px;
}
.hero .primary {
  min-width: 160px;
}
.hero-dots {
  margin-top: -7px;
  position: relative;
  z-index: 2;
}
.home-page .skeleton-hero {
  height: 64svh;
  margin: 0 -22px;
  border-radius: 0;
}
.card.person,
.card.brand-card {
  pointer-events: auto;
}
.view > .searchbar,
#tvContent > .searchbar {
  display: none;
}
.youtube-feed {
  display: grid;
  grid-template-columns: 1fr;
  gap: 25px;
}
.youtube-feed .card {
  width: 100%;
  max-width: none;
}
.youtube-feed .card .art {
  aspect-ratio: 16/9;
}
.youtube-feed .card strong {
  font-size: 15px;
}
.youtube-banner {
  margin: 0 -22px;
  height: 150px;
  background: #222;
  overflow: hidden;
  border-radius: 0 0 20px 20px;
}
.youtube-banner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.youtube-profile {
  padding: 22px 0;
}
.youtube-profile > img {
  width: 82px;
  height: 82px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 16px;
}
.youtube-profile h1 {
  font-size: 27px;
}
.youtube-profile details {
  margin-top: 12px;
  font-size: 12px;
}
.entity-profile {
  padding: 15px 0 25px;
}
.entity-profile > img {
  display: block;
  width: 130px;
  max-height: 180px;
  object-fit: contain;
  border-radius: 18px;
  margin: 20px 0;
}
.entity-profile h1 {
  font-size: 30px;
}
.entity-profile details {
  margin-top: 18px;
}
.remote-nav {
  align-items: center;
  justify-items: center;
}
.remote-nav .icon-button {
  width: 100%;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.remote-nav svg {
  display: block;
  margin: 0;
}
.remote-playback {
  padding: 18px;
  background: #202020;
  border-radius: 20px;
  margin: 20px 0;
}
.remote-playback[hidden] {
  display: none;
}
.remote-playback-head {
  display: flex;
  align-items: center;
  gap: 12px;
}
.remote-playback-head strong {
  flex: 1;
  font-size: 13px;
}
.remote-timeline {
  display: flex;
  gap: 12px;
  align-items: center;
  direction: ltr;
}
.remote-timeline input {
  flex: 1;
  min-width: 0;
  accent-color: #fff;
}
.remote-timeline .icon-button {
  width: 36px;
  height: 36px;
}
.remote-time {
  direction: ltr;
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: #aaa;
}
body.playing {
  overflow: hidden;
}
.playing .bottom-nav {
  display: none;
}
.player {
  display: block;
  overflow-y: auto;
  overscroll-behavior: contain;
  background: #111;
  padding-bottom: env(safe-area-inset-bottom);
}
.player-stage {
  position: sticky;
  top: 0;
  width: 100%;
  aspect-ratio: var(--video-ratio);
  height: auto;
  min-height: 0;
  flex: none;
  z-index: 4;
  display: block;
  overflow: hidden;
}
.player video {
  display: block;
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
}
.player-top {
  position: absolute;
  top: 0;
  inset-inline: 0;
  background: linear-gradient(#000a, transparent);
  padding: 10px 12px;
  z-index: 8;
  pointer-events: none;
}
.player-top .icon-button {
  pointer-events: auto;
  width: 35px;
  height: 35px;
  background: #0007;
  backdrop-filter: blur(12px);
}
.player-top h2 {
  opacity: 0;
}
.player-panel {
  position: absolute;
  bottom: 0;
  inset-inline: 0;
  z-index: 6;
  background: linear-gradient(transparent, #000c);
  padding: 28px 12px 7px;
}
.player-buttons {
  margin-top: 0;
  gap: 18px;
}
.player-buttons .play-toggle {
  height: 40px;
  width: 40px;
}
.player-buttons button {
  min-height: 32px;
  padding: 4px;
}
.player-progress {
  margin: 3px 0;
}
.player-times {
  font-size: 9px;
}
.player-cover {
  z-index: 5;
}
.player-info {
  padding: 20px var(--phone-edge) 40px;
  max-width: 920px;
  margin: auto;
}
.watch-title {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  text-align: start;
  font-weight: 750;
  font-size: 20px;
  line-height: 1.5;
  padding: 0;
}
.watch-title span {
  flex: 1;
}
.watch-title svg {
  width: 20px;
  flex: none;
}
.watch-description {
  background: #202020;
  border-radius: 15px;
  padding: 15px;
  margin: 14px 0;
}
.watch-description p {
  white-space: pre-wrap;
  font-size: 13px;
  line-height: 1.8;
  color: #ccc;
}
.watch-publisher-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 13px 0;
  border-bottom: 1px solid #ffffff14;
}
.watch-publisher {
  display: flex;
  align-items: center;
  gap: 9px;
  flex: 1;
  min-width: 0;
  text-align: start;
  font-size: 12px;
  font-weight: 600;
}
.watch-publisher img {
  width: 35px;
  height: 35px;
  object-fit: contain;
  border-radius: 50%;
  background: #252525;
}
.watch-publisher-row > .icon-button {
  width: 37px;
  height: 37px;
  background: #272727;
  flex: none;
}
.watch-publisher-row > .icon-button svg {
  width: 18px;
  height: 18px;
}
.watch-related .card.wide {
  width: 100%;
  flex-basis: 100%;
}
.watch-related .row-scroll {
  display: grid;
  gap: 25px;
  overflow: visible;
}
.watch-related .card strong {
  font-size: 15px;
}
.player-info .seasons {
  direction: ltr;
}
.skip-intro {
  position: absolute;
  z-index: 8;
  bottom: 120px;
  inset-inline-end: 14px;
  background: white;
  color: black;
  padding: 9px 14px;
  border-radius: 20px;
  font-weight: 700;
  font-size: 11px;
}
.skip-intro[hidden] {
  display: none;
}
.caption-overlay {
  position: absolute;
  inset-inline: 12px;
  bottom: 105px;
  z-index: 7;
  pointer-events: none;
  text-align: center;
  white-space: pre-line;
  line-height: 1.5;
  font-size: 22px;
}
.caption-overlay .secondary-caption {
  font-size: 0.72em;
}
.subtitle-options {
  display: grid;
  gap: 15px;
  margin-top: 18px;
}
.subtitle-options label {
  display: grid;
  gap: 8px;
  font-size: 12px;
}
.subtitle-options input[type="range"] {
  accent-color: white;
  width: 100%;
}
.subtitle-options select {
  padding: 9px;
}
.review {
  background: #202020;
  border-radius: 15px;
  padding: 17px;
  margin: 13px 0;
  font-size: 12px;
  line-height: 1.8;
}
.review strong {
  display: block;
  margin-bottom: 8px;
}
.review p {
  white-space: pre-wrap;
}
.player-channel-list {
  position: fixed;
  top: 80px;
  bottom: 90px;
}
.floating-keys {
  position: fixed;
  bottom: 100px;
}
.watch-channel-groups {
  direction: ltr;
}
.player-stage:fullscreen {
  width: 100vw;
  height: 100dvh;
  aspect-ratio: auto;
  position: fixed;
}
.player-stage:fullscreen video {
  object-fit: contain;
}
.player-stage:-webkit-full-screen {
  width: 100vw;
  height: 100vh;
}
.playing .toast {
  z-index: 110;
}
.player-info button:focus-visible {
  outline: 2px solid white;
  outline-offset: 3px;
}
.watch-meta {
  font-size: 11px;
  color: #aaa;
  line-height: 1.8;
  margin: 8px 0 4px;
}
.player-stage iframe {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  border: 0;
}
@media (min-width: 600px) {
  .home-page #homeHero,
  .home-page .skeleton-hero {
    margin-inline: -32px;
  }
  .home-page .hero {
    height: min(64svh, 650px);
    min-height: 460px;
  }
  .hero-copy {
    padding-inline: 40px;
  }
  .player-stage {
    max-width: 920px;
    margin: auto;
  }
  .youtube-feed {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .platform-strip {
    justify-content: flex-start;
    padding-inline: max(32px, calc((100vw - 920px) / 2 + 32px));
  }
}
@media (max-width: 360px) {
  .home-page #homeHero,
  .home-page .skeleton-hero {
    margin-inline: -16px;
  }
  .home-page .hero {
    min-height: 420px;
  }
  .hero-copy {
    padding-inline: 20px;
  }
  .watch-publisher-row {
    gap: 5px;
  }
}
@media (orientation: landscape) and (max-height: 600px) {
  .player-stage {
    position: relative;
    inset: auto;
    max-width: 680px;
  }
  .player-top {
    position: absolute;
  }
  .player-panel {
    position: absolute;
    bottom: 0;
  }
  .player-info {
    max-width: 680px;
  }
}

/* One continuous shade originates in the header; artwork has only its lower fade. */
.topbar {
  direction: ltr;
  background: none;
  isolation: isolate;
}
.topbar:before {
  content: "";
  position: absolute;
  inset: 0 0 -110px;
  z-index: -1;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    #000e 0%,
    #000a 34%,
    #0004 68%,
    transparent 100%
  );
}
.platform-strip {
  background: none;
}
.home-page .hero:after {
  background: linear-gradient(0deg, #111 0%, #111e 7%, transparent 72%);
}
.topbar.search-active {
  background: #111;
}
.topbar.search-active:before {
  bottom: 0;
  background: #111;
}
.topbar.search-active .brand,
.topbar.search-active .top-actions {
  display: none;
}
.header-search {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  background: #252525;
  border-radius: 24px;
  padding: 5px 12px;
  direction: ltr;
}
.header-search input {
  width: 100%;
  min-width: 0;
  min-height: 38px;
  background: none;
  border: 0;
  outline: none;
  font-size: 16px;
}
.header-search button {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  flex: none;
}
.header-search svg {
  width: 20px;
  height: 20px;
  flex: none;
}
input,
textarea,
select,
.searchbar input,
.field {
  font-size: max(16px, 1em);
}
.search-results .view {
  padding-top: 110px;
}
.search-results .page-head {
  margin-top: 0;
}
.entity-profile {
  display: grid;
  grid-template-columns: minmax(85px, 30%) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
  direction: ltr;
}
.entity-profile .entity-portrait img {
  width: 100%;
  height: auto;
  max-height: 240px;
  object-fit: cover;
  border-radius: 16px;
}
.entity-profile .entity-bio {
  min-width: 0;
  direction: rtl;
}
.entity-bio h1 {
  font-size: 24px;
}
.entity-bio .overview {
  font-size: 12px;
  line-height: 1.85;
  margin-top: 10px;
}
.work-logo {
  width: auto;
  max-width: min(100%, 310px);
  max-height: 88px;
  object-fit: contain;
  filter: drop-shadow(0 2px 7px #0006);
}
.work-info .work-logo {
  max-height: 100px;
}
.watch-title .work-logo {
  max-height: 58px;
  max-width: 230px;
}
.has-work-logo {
  line-height: 1;
  min-height: 30px;
}
.watch-publisher-row > .icon-button.saved {
  background: white;
  color: #111;
}
.watch-description[hidden] {
  display: none;
}
.watch-title {
  touch-action: manipulation;
}
.player-stage {
  touch-action: manipulation;
}
.player-top {
  direction: ltr;
  gap: 9px;
  padding: 8px 10px;
}
.player-top h2 {
  flex: 1;
  min-width: 0;
}
.player-top .icon-button {
  background: none;
  backdrop-filter: none;
  width: 30px;
  height: 34px;
}
.player-top svg {
  width: 23px;
  height: 23px;
}
#playerToggle {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  z-index: 7;
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  padding: 8px;
  border-radius: 0;
  background: transparent;
  color: white;
  filter: drop-shadow(0 2px 5px #0008);
}
#playerToggle svg {
  width: 43px;
  height: 43px;
}
.controls-hidden #playerToggle {
  opacity: 0;
  pointer-events: none;
}
.player-panel {
  padding: 0;
  background: none;
  bottom: 0;
  height: 49px;
  pointer-events: none;
}
.player-progress {
  position: absolute;
  inset: auto 0 -5px;
  width: 100%;
  height: 14px;
  margin: 0;
  border-radius: 0;
  pointer-events: auto;
}
.player-times {
  position: absolute;
  bottom: 16px;
  left: 12px;
  right: auto;
  display: flex;
  gap: 5px;
  background: #0005;
  padding: 3px 7px;
  border-radius: 6px;
  font-size: 10px;
  color: white;
}
.player-times span + span:before {
  content: "/";
  margin-right: 5px;
}
#fullscreen {
  position: absolute;
  right: 10px;
  bottom: 16px;
  z-index: 8;
  background: none;
  padding: 0;
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  filter: drop-shadow(0 1px 4px #000);
}
.controls-hidden #fullscreen {
  opacity: 0;
  pointer-events: none;
}
.player-buttons {
  pointer-events: auto;
  position: absolute;
  bottom: 45px;
  left: 10px;
  margin: 0;
  gap: 10px;
}
.player-buttons .icon-button {
  width: 30px;
  height: 30px;
  background: #0005;
  border-radius: 8px;
}
.player-buttons [hidden] {
  display: none;
}
.caption-overlay {
  bottom: 55px;
}
.skip-intro {
  bottom: 52px;
}
.seek-feedback {
  position: absolute;
  inset: 40% 30%;
  z-index: 9;
  border-radius: 30px;
  background: #0007;
  display: grid;
  place-items: center;
  pointer-events: none;
  font-size: 22px;
  font-weight: 700;
  direction: ltr;
}
.seek-feedback[hidden] {
  display: none;
}
.mini-actions {
  display: none;
}
.player.mini-player {
  inset: auto 12px calc(86px + var(--safe)) auto;
  width: min(55vw, 220px);
  height: auto;
  overflow: hidden;
  border-radius: 13px;
  box-shadow: 0 5px 28px #0008;
  z-index: 60;
  padding: 0;
  touch-action: none;
  cursor: grab;
}
.player.mini-player:active {
  cursor: grabbing;
}
.mini-player .player-stage {
  position: relative;
  max-width: none;
  aspect-ratio: 16/9;
}
.mini-player .player-info,
.mini-player .player-top,
.mini-player .player-panel,
.mini-player #playerToggle,
.mini-player #fullscreen,
.mini-player .skip-intro,
.mini-player .caption-overlay,
.mini-player .seek-feedback {
  display: none !important;
}
.mini-player .mini-actions {
  position: absolute;
  inset: 4px 4px auto;
  display: flex;
  justify-content: space-between;
  z-index: 20;
}
.mini-actions .icon-button {
  width: 26px;
  height: 26px;
  background: #0007;
}
.mini-actions svg {
  width: 16px;
  height: 16px;
}
/* Keep the timeline thumb above the following page and claim only video gestures. */
.player-stage {
  overflow: visible;
  touch-action: none;
}
.player-panel {
  z-index: 12;
}
.player-progress {
  bottom: -10px;
  height: 20px;
  z-index: 13;
}
.player-info {
  position: relative;
  z-index: 1;
}
.source-waiting #playerToggle,
.has-player-error #playerToggle {
  display: none;
}
.player.expanded-video .player-stage {
  position: fixed;
  inset: 0;
  height: 100dvh;
  aspect-ratio: auto;
  z-index: 30;
  background: black;
}
.player.expanded-video .player-info {
  display: none;
}
.player.expanded-video .player-progress {
  bottom: 0;
}
.player-buffer-ring {
  display: none;
  position: absolute;
  width: 96px;
  height: 96px;
  left: 50%;
  top: 50%;
  margin: -48px 0 0 -48px;
  border: 3px solid #ffffff38;
  border-top-color: white;
  border-radius: 50%;
  pointer-events: none;
  z-index: 8;
}
.buffering .player-buffer-ring {
  display: block;
  animation: player-buffer-spin 0.85s linear infinite;
}
.buffering:not(.has-player-error) #playerToggle {
  display: grid;
  z-index: 9;
  opacity: 1;
}
.buffering .player-cover {
  background: #0003;
  pointer-events: none;
}
.buffering .player-status {
  position: absolute;
  top: calc(50% + 59px);
  left: 10%;
  width: 80%;
  font-size: 12px;
}
.buffering .player-status .spinner {
  display: none;
}
.mini-player .player-buffer-ring {
  width: 44px;
  height: 44px;
  margin: -22px 0 0 -22px;
}
.mini-player .mini-actions .icon-button {
  width: 36px;
  height: 36px;
  border-radius: 50%;
}
.player.minimizing {
  will-change: transform;
  transform-origin: top left;
}
.minimizing .mini-actions {
  opacity: 0;
  pointer-events: none;
}
@keyframes player-buffer-spin {
  to {
    transform: rotate(360deg);
  }
}
@media (prefers-reduced-motion: reduce) {
  .buffering .player-buffer-ring {
    animation-duration: 1.8s;
  }
}
