/* ===========================================
   Videos · Video Theater | Angel City FC
   HubSpot self-contained landing page
   =========================================== */

:root {
  --sol-rosa: #f1b1a5;
  --sol-rosa-dark: #e0a094;
  --sol-rosa-soft: rgba(241, 177, 165, 0.18);
  --sol-rosa-glow: rgba(241, 177, 165, 0.30);

  --rnw-dark: #111111;
  --rnw-dark-mid: #1a1a1a;
  --rnw-card-dark: #242424;
  --rnw-card-dark-border: rgba(255, 255, 255, 0.10);

  --rnw-surface: #fafaf8;
  --rnw-surface-warm: #f6f4f1;
  --rnw-panel: #ffffff;
  --rnw-panel-edge: #e8e6e3;
  --rnw-ink: #121416;

  --asphalt: #1c1c1c;
  --armour: #6b7280;
  --line-white: #ffffff;
  --pitch-black: #000000;

  --shadow-e1: 0 1px 2px rgba(28, 20, 16, 0.05), 0 1px 3px rgba(28, 20, 16, 0.04);
  --shadow-e2: 0 8px 28px rgba(28, 20, 16, 0.10), 0 2px 6px rgba(28, 20, 16, 0.05);
  --shadow-e3: 0 22px 60px rgba(28, 20, 16, 0.18), 0 4px 12px rgba(28, 20, 16, 0.07);
  --shadow-e3-rosa: 0 22px 60px rgba(28, 20, 16, 0.18), 0 0 0 1px rgba(241, 177, 165, 0.28);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-full: 9999px;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --transition: all 0.3s var(--ease-out);

  /* Height of the HubSpot site header that sits above this page */
  --wt-scroll-offset: 90px;
  --wt-queue-width: 400px;
}

/* Theme surfaces */
[data-theme="dark"] {
  --wt-bg: var(--rnw-dark);
  --wt-bg-alt: #0c0c0c;
  --wt-surface: var(--rnw-dark-mid);
  --wt-card: var(--rnw-card-dark);
  --wt-border: var(--rnw-card-dark-border);
  --wt-text: #f5f5f4;
  --wt-muted: rgba(255, 255, 255, 0.62);
  --wt-faint: rgba(255, 255, 255, 0.08);
  --wt-accent-text: var(--sol-rosa);
  --wt-underline: var(--line-white);
  --wt-ambient-opacity: 0.5;
  --wt-card-shadow-hover: 0 22px 60px rgba(0, 0, 0, 0.5), 0 0 0 1px rgba(241, 177, 165, 0.35);
  color-scheme: dark;
}

[data-theme="light"] {
  --wt-bg: var(--rnw-surface);
  --wt-bg-alt: var(--rnw-surface-warm);
  --wt-surface: var(--rnw-panel);
  --wt-card: var(--rnw-panel);
  --wt-border: var(--rnw-panel-edge);
  --wt-text: var(--rnw-ink);
  --wt-muted: var(--armour);
  --wt-faint: rgba(28, 28, 28, 0.06);
  --wt-accent-text: var(--sol-rosa);
  --wt-underline: var(--pitch-black);
  --wt-ambient-opacity: 0.4;
  --wt-card-shadow-hover: var(--shadow-e3-rosa);
  color-scheme: light;
}

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

html { scroll-padding-top: var(--wt-scroll-offset); }
html:has(.acfc-wt-app) { overflow-x: hidden; }

body {
  margin: 0;
  font-family: 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, 'Roboto', sans-serif;
  color: var(--wt-text);
  background: var(--wt-bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body.acfc-wt-lock { overflow: hidden; }

.acfc-wt-app {
  position: relative;
  isolation: isolate;
  background: var(--wt-bg);
  color: var(--wt-text);
  min-height: 100vh;
  overflow: clip;
}

.acfc-wt-app img { max-width: 100%; display: block; }
.acfc-wt-app a { color: inherit; }
.acfc-wt-app button { font-family: inherit; }

/* The HubSpot theme styles bare headings (color, font, highlight); keep ours on-brand */
.acfc-wt-app.acfc-wt-app :is(h1, h2, h3) {
  font-family: 'Inter', 'Segoe UI', -apple-system, BlinkMacSystemFont, 'Roboto', sans-serif;
  color: var(--wt-text);
  -webkit-text-fill-color: currentColor;
  background: none;
  text-shadow: none;
  -webkit-text-stroke: 0;
}

.acfc-wt-app.acfc-wt-app :is(h1, h2, h3) em {
  color: var(--wt-accent-text);
  -webkit-text-fill-color: currentColor;
  background: none;
}

/* Sol Rosa is too light for small text on light surfaces; small accents use ink there */
[data-theme="light"] .acfc-wt-details-eyebrow { color: var(--wt-text); }
[data-theme="light"] .acfc-wt-desc a {
  color: var(--wt-text);
  text-decoration-color: var(--sol-rosa);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}
[data-theme="light"] .acfc-wt-desc-toggle:hover,
[data-theme="light"] .acfc-wt-card:hover .acfc-wt-card-title { color: var(--wt-text); }

.acfc-wt-app :focus-visible {
  outline: 2px solid var(--sol-rosa);
  outline-offset: 3px;
}

[hidden] { display: none !important; }

.acfc-wt-visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.acfc-wt-wide {
  position: relative;
  max-width: 1680px;
  margin: 0 auto;
  padding-left: max(24px, env(safe-area-inset-left, 0px));
  padding-right: max(24px, env(safe-area-inset-right, 0px));
}

@media (max-width: 600px) {
  .acfc-wt-wide {
    padding-left: max(16px, env(safe-area-inset-left, 0px));
    padding-right: max(16px, env(safe-area-inset-right, 0px));
  }
}

/* ---------- Shared brand buttons (matches 2027Renewals) ---------- */

.angelcity2026-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 46px;
  padding: 0.75rem 1.6rem;
  border: 2px solid transparent;
  border-radius: var(--radius-full);
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  font-weight: 800;
  letter-spacing: 0.015em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: var(--transition);
}

.angelcity2026-btn-primary {
  background: var(--sol-rosa);
  color: var(--pitch-black);
  border-color: var(--sol-rosa);
}

a.angelcity2026-btn.angelcity2026-btn-primary { color: var(--pitch-black); }

.angelcity2026-btn-primary:hover,
.angelcity2026-btn-primary:focus-visible {
  background: var(--sol-rosa-dark);
  border-color: var(--sol-rosa-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 28px var(--sol-rosa-glow);
}

.angelcity2026-btn-secondary {
  background: transparent;
  color: var(--wt-text);
  border-color: color-mix(in srgb, var(--wt-text) 40%, transparent);
}

.angelcity2026-btn-secondary:hover,
.angelcity2026-btn-secondary:focus-visible {
  border-color: var(--sol-rosa);
  background: var(--sol-rosa-soft);
}

/* ---------- Typography ---------- */

.acfc-wt-section-title {
  font-size: clamp(1.6rem, 3.4vw, 2.4rem);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: -0.02em;
  line-height: 1.05;
  margin: 0;
}

.acfc-wt-section-title em,
.acfc-wt-head-title em {
  font-style: normal;
  font-weight: 900;
  color: var(--wt-accent-text);
}

/* ---------- Scroll reveal ---------- */

.acfc-wt-reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.65s var(--ease-out), transform 0.65s var(--ease-out);
}

.acfc-wt-reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* ---------- Header strip ---------- */

.acfc-wt-head {
  position: relative;
  z-index: 2;
  padding: clamp(20px, 3vw, 36px) 0 clamp(14px, 2vw, 22px);
}

.acfc-wt-head-inner {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.acfc-wt-head-title {
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: -0.035em;
  line-height: 0.92;
  margin: 0;
}

/* Sized in em so it scales with the title at every breakpoint */
.acfc-wt-app.acfc-wt-app .acfc-wt-head-title em {
  text-decoration: none !important;
  /* Stroke sits mostly below the baseline so it only grazes the letters and they stay legible */
  background: linear-gradient(to top, transparent 0.06em, var(--wt-underline) 0.06em, var(--wt-underline) 0.29em, transparent 0.29em) !important;
  padding: 0 0.06em;
  margin: 0 -0.06em;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

.acfc-wt-head-side {
  display: flex;
  align-items: center;
  gap: 18px;
}

.acfc-wt-head-count {
  margin: 0;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--wt-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.acfc-wt-subscribe { min-height: 42px; padding: 0.6rem 1.25rem; }

/* ---------- Theater section ---------- */

.acfc-wt-theater {
  position: relative;
  padding-bottom: clamp(40px, 6vw, 72px);
}

.acfc-wt-ambient {
  position: absolute;
  inset: 0 0 auto;
  height: min(1100px, 120vh);
  overflow: hidden;
  pointer-events: none;
  z-index: 0;
  -webkit-mask-image: linear-gradient(to bottom, #000 30%, transparent 95%);
  mask-image: linear-gradient(to bottom, #000 30%, transparent 95%);
}

.acfc-wt-ambient::after {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(60% 55% at 50% 30%, var(--sol-rosa-glow) 0%, transparent 70%);
  opacity: 0.6;
}

.acfc-wt-ambient-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(90px) saturate(1.4);
  transform: scale(1.25);
  opacity: 0;
  transition: opacity 1.2s ease;
}

.acfc-wt-ambient-img.is-loaded { opacity: var(--wt-ambient-opacity); }

/* Thumbnails are mostly dark, so on light surfaces they are lifted and washed out
   to tint the page with the video's colors rather than darken it. */
[data-theme="light"] .acfc-wt-ambient-img {
  filter: blur(90px) saturate(2.2) contrast(0.25) brightness(1.9);
}

.acfc-wt-layout {
  position: relative;
  z-index: 1;
  display: grid;
  gap: clamp(20px, 2.4vw, 32px);
  grid-template-columns: minmax(0, 1fr) var(--wt-queue-width);
  grid-template-areas:
    "stage queue"
    "details queue";
  align-items: start;
}

.acfc-wt-stage { grid-area: stage; }
.acfc-wt-details { grid-area: details; }
.acfc-wt-queue { grid-area: queue; }

/* ---------- Stage & player ---------- */

.acfc-wt-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-lg);
  background: #000;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255, 255, 255, 0.06);
  scroll-margin-top: calc(var(--wt-scroll-offset) + 16px);
}

[data-theme="light"] .acfc-wt-stage {
  box-shadow: 0 18px 48px rgba(28, 20, 16, 0.16), 0 2px 8px rgba(28, 20, 16, 0.06);
}

.acfc-wt-player {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: inherit;
  background: #000;
  color: #fff;
  isolation: isolate;
  user-select: none;
  -webkit-user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.acfc-wt-player:focus { outline: none; }

/* The iframe is oversized vertically so YouTube's title bar, "More videos"
   strip and watermark (all pinned to the iframe edges) fall outside the
   clipped player while the 16:9 video still fits it exactly. */
.acfc-wt-player {
  --wt-rw: 16;
  --wt-rh: 9;
  --wt-overscan: 160px;
  container-type: size;
}

/* Shorts embeds add a like button above their bottom bar, so hide twice as much edge.
   Shorts are width-fitted, so the extra height never crops the video. */
.acfc-wt-app.is-shorts .acfc-wt-player {
  --wt-rw: 9;
  --wt-rh: 16;
  --wt-overscan: 320px;
}

.acfc-wt-player-frame {
  position: absolute;
  inset: calc(var(--wt-overscan) / -2) 0;
}

@supports (width: 1cqw) {
  .acfc-wt-player-frame {
    inset: auto;
    top: 50%;
    left: 50%;
    width: min(100cqw, 100cqh * var(--wt-rw) / var(--wt-rh));
    height: calc(min(100cqw, 100cqh * var(--wt-rw) / var(--wt-rh)) * var(--wt-rh) / var(--wt-rw) + var(--wt-overscan));
    translate: -50% -50%;
  }
}

/* YouTube draws captions along the iframe's bottom edge, so drop the oversize
   while they're on or they land in the clipped strip */
@supports not (width: 1cqw) {
  .acfc-wt-player.is-cc .acfc-wt-player-frame { inset: 0; }
}

@supports (width: 1cqw) {
  .acfc-wt-player.is-cc .acfc-wt-player-frame {
    height: calc(min(100cqw, 100cqh * var(--wt-rw) / var(--wt-rh)) * var(--wt-rh) / var(--wt-rw));
  }
}

.acfc-wt-player-frame iframe,
.acfc-wt-mount {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Desktop HD: setSize(1280×720) hints the stream; no CSS scale (causes a seam above the controls). */
.acfc-wt-player.is-hq-embed {
  overflow: hidden;
  background: #000;
}


.acfc-wt-poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 1;
  transition: opacity 0.5s ease;
}

.acfc-wt-player.is-started .acfc-wt-poster { opacity: 0; pointer-events: none; }

.acfc-wt-shield {
  position: absolute;
  inset: 0;
  z-index: 2;
  cursor: pointer;
}

.acfc-wt-player.is-idle .acfc-wt-shield { cursor: none; }

.acfc-wt-scrim {
  position: absolute;
  inset: auto 0 0;
  height: 45%;
  z-index: 3;
  pointer-events: none;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.82) 0%, rgba(0, 0, 0, 0.35) 55%, transparent 100%);
  transition: opacity 0.35s ease;
}

.acfc-wt-player:not(.is-started) .acfc-wt-scrim {
  height: 100%;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.15), rgba(0, 0, 0, 0.55));
}

/* Big play */
.acfc-wt-bigplay {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 5;
  display: grid;
  place-items: center;
  width: clamp(64px, 8vw, 92px);
  aspect-ratio: 1;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--sol-rosa);
  color: var(--pitch-black);
  cursor: pointer;
  translate: -50% -50%;
  box-shadow: 0 0 0 10px rgba(241, 177, 165, 0.22), 0 20px 50px rgba(0, 0, 0, 0.5);
  transition: scale 0.3s var(--ease-out), box-shadow 0.3s var(--ease-out), opacity 0.3s ease;
}

/* The play path is drawn 2.5 units right of its 24-unit viewBox center */
.acfc-wt-bigplay svg { translate: -7.5% 0; }
.acfc-wt-bigplay:hover { scale: 1.07; box-shadow: 0 0 0 16px rgba(241, 177, 165, 0.25), 0 20px 50px rgba(0, 0, 0, 0.5); }
.acfc-wt-player.is-started .acfc-wt-bigplay { opacity: 0; pointer-events: none; scale: 0.8; }

/* Spinner */
.acfc-wt-spinner {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 4;
  width: 56px;
  height: 56px;
  margin: -28px 0 0 -28px;
  border-radius: 50%;
  border: 3px solid rgba(255, 255, 255, 0.18);
  border-top-color: var(--sol-rosa);
  opacity: 0;
  pointer-events: none;
  animation: acfc-wt-spin 0.9s linear infinite;
  transition: opacity 0.2s ease;
}

.acfc-wt-player.is-started.is-buffering .acfc-wt-spinner { opacity: 1; transition-delay: 0.25s; }

@keyframes acfc-wt-spin { to { transform: rotate(360deg); } }

@keyframes acfc-wt-pop {
  from { opacity: 0; transform: translateY(-6px) scale(0.96); }
  to { opacity: 1; transform: none; }
}

/* Center flash feedback */
.acfc-wt-flash {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 5;
  min-width: 72px;
  padding: 14px 18px;
  border-radius: var(--radius-full);
  background: rgba(0, 0, 0, 0.62);
  color: #fff;
  font-size: 0.95rem;
  font-weight: 800;
  text-align: center;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  translate: -50% -50%;
  backdrop-filter: blur(6px);
}

.acfc-wt-flash.is-show { animation: acfc-wt-flash 0.75s var(--ease-out); }

@keyframes acfc-wt-flash {
  0% { opacity: 0; scale: 0.85; }
  20% { opacity: 1; scale: 1; }
  70% { opacity: 1; }
  100% { opacity: 0; scale: 1.08; }
}

/* Message (empty / error) */
.acfc-wt-message {
  position: absolute;
  inset: 0;
  z-index: 7;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 18px;
  padding: 24px;
  text-align: center;
  background: radial-gradient(circle at center, #1d1d1d, #050505);
}

.acfc-wt-message-text {
  margin: 0;
  font-size: clamp(1rem, 2vw, 1.25rem);
  font-weight: 700;
}

/* End card */
.acfc-wt-endcard {
  position: absolute;
  inset: 0;
  z-index: 7;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: blur(10px);
  animation: acfc-wt-fade 0.4s ease;
}

@keyframes acfc-wt-fade { from { opacity: 0; } to { opacity: 1; } }

.acfc-wt-endcard-inner {
  display: grid;
  justify-items: center;
  gap: clamp(12px, 2vw, 20px);
  width: min(520px, 100%);
  text-align: center;
}

.acfc-wt-endcard-label {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--sol-rosa);
}

.acfc-wt-endcard-next { display: grid; justify-items: center; gap: 12px; }

.acfc-wt-endcard-thumb {
  position: relative;
  display: block;
  width: clamp(180px, 30vw, 300px);
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 0 0 2px rgba(241, 177, 165, 0.6), 0 20px 50px rgba(0, 0, 0, 0.5);
}

.acfc-wt-endcard-thumb img { width: 100%; height: 100%; object-fit: cover; }

.acfc-wt-endcard-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 64px;
  height: 64px;
  translate: -50% -50%;
  rotate: -90deg;
  fill: rgba(0, 0, 0, 0.55);
  stroke: var(--sol-rosa);
  stroke-width: 3;
  stroke-dasharray: 100;
  stroke-dashoffset: 0;
  stroke-linecap: round;
}

.acfc-wt-endcard-ring circle { transition: none; }

.acfc-wt-endcard.is-counting .acfc-wt-endcard-ring circle {
  animation: acfc-wt-ring var(--wt-countdown, 8s) linear forwards;
}

@keyframes acfc-wt-ring { from { stroke-dashoffset: 100; } to { stroke-dashoffset: 0; } }

.acfc-wt-endcard:not(.is-counting) .acfc-wt-endcard-ring,
.acfc-wt-endcard:not(.is-counting) .acfc-wt-endcard-count { display: none; }

.acfc-wt-endcard-count {
  position: absolute;
  top: 50%;
  left: 50%;
  translate: -50% -50%;
  font-size: 1.4rem;
  font-weight: 900;
}

.acfc-wt-endcard-title {
  margin: 0;
  font-size: clamp(0.95rem, 1.8vw, 1.15rem);
  font-weight: 700;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.acfc-wt-endcard-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.acfc-wt-endcard .angelcity2026-btn-secondary {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.45);
}

/* ---------- Controls ---------- */

.acfc-wt-controls {
  position: absolute;
  inset: auto 0 0;
  z-index: 6;
  padding: 0 clamp(10px, 1.6vw, 20px) clamp(6px, 1vw, 12px);
  transition: opacity 0.3s ease, transform 0.3s var(--ease-out);
}

.acfc-wt-player:not(.is-started) .acfc-wt-controls,
.acfc-wt-player.is-idle .acfc-wt-controls,
.acfc-wt-player.is-idle .acfc-wt-scrim {
  opacity: 0;
  pointer-events: none;
}

.acfc-wt-player.is-idle .acfc-wt-controls { transform: translateY(8px); }

.acfc-wt-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.acfc-wt-bar-group {
  display: flex;
  align-items: center;
  gap: 2px;
  min-width: 0;
}

.acfc-wt-ctrl {
  position: relative;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-full);
  background: transparent;
  color: #fff;
  cursor: pointer;
  opacity: 0.92;
  transition: background 0.2s ease, opacity 0.2s ease, color 0.2s ease;
}

.acfc-wt-ctrl:hover { background: rgba(255, 255, 255, 0.12); opacity: 1; }
.acfc-wt-ctrl svg { filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.4)); }

.acfc-wt-ctrl[aria-pressed="true"] { color: var(--sol-rosa); }

.acfc-wt-ctrl[data-wt-cc][aria-pressed="true"]::after {
  content: '';
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 7px;
  height: 2px;
  border-radius: 2px;
  background: var(--sol-rosa);
}

/* Play / pause / replay icon states */
.acfc-wt-ctrl--play .acfc-wt-i-pause,
.acfc-wt-ctrl--play .acfc-wt-i-replay { display: none; }
.acfc-wt-player.is-playing .acfc-wt-ctrl--play .acfc-wt-i-play { display: none; }
.acfc-wt-player.is-playing .acfc-wt-ctrl--play .acfc-wt-i-pause { display: block; }
.acfc-wt-player.is-ended .acfc-wt-ctrl--play .acfc-wt-i-play { display: none; }
.acfc-wt-player.is-ended .acfc-wt-ctrl--play .acfc-wt-i-replay { display: block; }

.acfc-wt-i-muted { display: none; }
.acfc-wt-player.is-muted .acfc-wt-i-vol { display: none; }
.acfc-wt-player.is-muted .acfc-wt-i-muted { display: block; }

.acfc-wt-i-fs-exit { display: none; }
.acfc-wt-player.is-fullscreen .acfc-wt-i-fs { display: none; }
.acfc-wt-player.is-fullscreen .acfc-wt-i-fs-exit { display: block; }

/* Volume */
.acfc-wt-volume {
  display: flex;
  align-items: center;
}

.acfc-wt-volume-range {
  --wt-vol: 100%;
  width: 0;
  height: 18px;
  margin: 0;
  opacity: 0;
  background: transparent;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  transition: width 0.3s var(--ease-out), opacity 0.2s ease, margin 0.3s var(--ease-out);
}

.acfc-wt-volume:hover .acfc-wt-volume-range,
.acfc-wt-volume:focus-within .acfc-wt-volume-range {
  width: 84px;
  margin: 0 10px 0 4px;
  opacity: 1;
}

/* The HubSpot theme gives every input a white box; strip it from the slider */
.acfc-wt-app .acfc-wt-volume .acfc-wt-volume-range {
  -webkit-appearance: none !important;
  appearance: none !important;
  width: 0 !important;
  min-width: 0 !important;
  max-width: none !important;
  height: 18px !important;
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.acfc-wt-app .acfc-wt-volume:hover .acfc-wt-volume-range,
.acfc-wt-app .acfc-wt-volume:focus-within .acfc-wt-volume-range { width: 84px !important; }

.acfc-wt-app .acfc-wt-volume .acfc-wt-volume-range:focus:not(:focus-visible) { outline: none; }

.acfc-wt-volume-range::-webkit-slider-runnable-track {
  height: 4px;
  border-radius: 4px;
  background: linear-gradient(to right, #fff var(--wt-vol), rgba(255, 255, 255, 0.3) var(--wt-vol));
}

.acfc-wt-volume-range::-moz-range-track {
  height: 4px;
  border-radius: 4px;
  background: linear-gradient(to right, #fff var(--wt-vol), rgba(255, 255, 255, 0.3) var(--wt-vol));
}

.acfc-wt-volume-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 13px;
  height: 13px;
  margin-top: -4.5px;
  border: 0;
  border-radius: 50%;
  background: #fff;
}

.acfc-wt-volume-range::-moz-range-thumb {
  width: 13px;
  height: 13px;
  border: 0;
  border-radius: 50%;
  background: #fff;
}

.acfc-wt-volume-range:focus-visible { outline-offset: 2px; }

.acfc-wt-time {
  margin: 0 0 0 8px;
  font-size: 0.85rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}

.acfc-wt-time-sep { margin: 0 4px; opacity: 0.6; }
.acfc-wt-time [data-wt-time-total] { opacity: 0.75; }

/* Scrub bar */
.acfc-wt-scrub {
  position: relative;
  height: 20px;
  margin: 0 4px 2px;
  cursor: pointer;
  touch-action: none;
  display: flex;
  align-items: center;
}

.acfc-wt-scrub:focus-visible { outline-offset: 0; border-radius: 4px; }

.acfc-wt-scrub-track {
  position: relative;
  width: 100%;
  height: 4px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.22);
  overflow: hidden;
  transition: height 0.18s var(--ease-out);
}

.acfc-wt-scrub:hover .acfc-wt-scrub-track,
.acfc-wt-player.is-scrubbing .acfc-wt-scrub-track,
.acfc-wt-scrub:focus-visible .acfc-wt-scrub-track { height: 6px; }

.acfc-wt-scrub-buffered,
.acfc-wt-scrub-hover,
.acfc-wt-scrub-played {
  position: absolute;
  inset: 0 auto 0 0;
  width: 0;
  border-radius: inherit;
}

.acfc-wt-scrub-buffered { background: rgba(255, 255, 255, 0.38); }
.acfc-wt-scrub-hover { background: rgba(255, 255, 255, 0.28); opacity: 0; }
.acfc-wt-scrub:hover .acfc-wt-scrub-hover { opacity: 1; }
.acfc-wt-scrub-played {
  background: linear-gradient(90deg, var(--sol-rosa-dark), var(--sol-rosa));
  box-shadow: 0 0 12px var(--sol-rosa-glow);
}

.acfc-wt-scrub-handle {
  position: absolute;
  top: 50%;
  left: 0;
  width: 15px;
  height: 15px;
  margin: -7.5px 0 0 -7.5px;
  border-radius: 50%;
  background: var(--sol-rosa);
  box-shadow: 0 0 0 4px rgba(241, 177, 165, 0.25), 0 2px 6px rgba(0, 0, 0, 0.4);
  scale: 0;
  transition: scale 0.18s var(--ease-out);
  pointer-events: none;
}

.acfc-wt-scrub:hover .acfc-wt-scrub-handle,
.acfc-wt-player.is-scrubbing .acfc-wt-scrub-handle,
.acfc-wt-scrub:focus-visible .acfc-wt-scrub-handle { scale: 1; }

.acfc-wt-scrub-tip {
  position: absolute;
  bottom: 24px;
  left: 0;
  padding: 5px 9px;
  border-radius: var(--radius-sm);
  background: rgba(10, 10, 10, 0.9);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  translate: -50% 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s ease;
}

.acfc-wt-scrub:hover .acfc-wt-scrub-tip,
.acfc-wt-player.is-scrubbing .acfc-wt-scrub-tip { opacity: 1; }

/* Autoplay switch */
.acfc-wt-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 44px;
  padding: 0 10px;
  border: 0;
  border-radius: var(--radius-full);
  background: transparent;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
}

.acfc-wt-switch:hover { background: rgba(255, 255, 255, 0.1); }

.acfc-wt-switch-track {
  position: relative;
  width: 34px;
  height: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.3);
  transition: background 0.25s ease;
}

.acfc-wt-switch-thumb {
  position: absolute;
  top: 50%;
  left: -2px;
  width: 20px;
  height: 20px;
  margin-top: -10px;
  border-radius: 50%;
  background: #d4d4d4;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
  transition: translate 0.25s var(--ease-out), background 0.25s ease;
}

.acfc-wt-switch[aria-checked="true"] .acfc-wt-switch-track { background: rgba(241, 177, 165, 0.5); }
.acfc-wt-switch[aria-checked="true"] .acfc-wt-switch-thumb { translate: 18px 0; background: var(--sol-rosa); }

/* Settings menu */
.acfc-wt-settings { position: relative; }

.acfc-wt-ctrl--gear svg { transition: rotate 0.4s var(--ease-out); }
.acfc-wt-ctrl--gear[aria-expanded="true"] svg { rotate: 60deg; }

.acfc-wt-menu {
  position: absolute;
  right: 0;
  bottom: calc(100% + 10px);
  z-index: 10;
  width: 240px;
  max-height: min(340px, 70vh);
  overflow-x: hidden;
  overflow-y: auto;
  padding: 10px 8px 12px;
  border-radius: var(--radius-md);
  background: rgba(18, 18, 18, 0.94);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(14px);
  animation: acfc-wt-pop 0.25s var(--ease-out);
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.28) transparent;
  scroll-padding-block: 8px;
  -webkit-overflow-scrolling: touch;
}

.acfc-wt-menu::-webkit-scrollbar { width: 6px; }
.acfc-wt-menu::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
}

.acfc-wt-menu-heading {
  margin: 6px 10px 4px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.5);
}

.acfc-wt-menu-sep { height: 1px; margin: 8px 4px; background: rgba(255, 255, 255, 0.1); }

.acfc-wt-menu-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 9px 10px;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: #fff;
  font-size: 0.88rem;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.acfc-wt-menu-item:hover,
.acfc-wt-menu-item:focus-visible { background: rgba(255, 255, 255, 0.1); outline: none; }

.acfc-wt-menu-item::after {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: transparent;
}

.acfc-wt-menu-item[aria-checked="true"] { color: var(--sol-rosa); }
.acfc-wt-menu-item[aria-checked="true"]::after { background: var(--sol-rosa); box-shadow: 0 0 0 3px var(--sol-rosa-soft); }

/* ---------- Mini player ---------- */

.acfc-wt-mini-bar {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 8;
  display: none;
  gap: 4px;
}

.acfc-wt-mini-btn {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  cursor: pointer;
  backdrop-filter: blur(6px);
}

.acfc-wt-mini-btn:hover { background: rgba(0, 0, 0, 0.85); color: var(--sol-rosa); }

.acfc-wt-player.is-mini {
  position: fixed;
  inset: auto max(16px, env(safe-area-inset-right, 0px)) calc(88px + env(safe-area-inset-bottom, 0px)) auto;
  z-index: 2147483000;
  width: min(420px, calc(100vw - 32px));
  height: auto;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-md);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(241, 177, 165, 0.35);
  animation: acfc-wt-mini-in 0.4s var(--ease-out);
}

@keyframes acfc-wt-mini-in {
  from { opacity: 0; transform: translateY(20px) scale(0.94); }
  to { opacity: 1; transform: none; }
}

.acfc-wt-player.is-mini .acfc-wt-mini-bar { display: flex; }
.acfc-wt-player.is-mini .acfc-wt-time { display: none !important; }
.acfc-wt-player.is-mini .acfc-wt-volume-range,
.acfc-wt-player.is-mini .acfc-wt-switch,
.acfc-wt-player.is-mini [data-wt-cc],
.acfc-wt-player.is-mini .acfc-wt-settings,
.acfc-wt-player.is-mini .acfc-wt-ctrl { width: 38px; height: 38px; }
.acfc-wt-player.is-mini .acfc-wt-endcard-thumb { width: 140px; }
.acfc-wt-player.is-mini .acfc-wt-endcard-title,
.acfc-wt-player.is-mini .acfc-wt-endcard-label { display: none; }

/* Placeholder left behind in the stage while the player floats */
.acfc-wt-stage.has-mini::before {
  content: 'Playing in mini player';
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  border-radius: inherit;
  background: radial-gradient(circle at center, #1f1f1f, #050505);
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* ---------- Fullscreen ---------- */

.acfc-wt-player.is-fullscreen,
.acfc-wt-player:fullscreen {
  border-radius: 0;
  width: 100%;
  height: 100%;
}

.acfc-wt-player.is-pseudo-fs {
  position: fixed;
  inset: 0;
  z-index: 2147483600;
  width: 100vw;
  height: 100dvh;
  border-radius: 0;
}

.acfc-wt-player.is-fullscreen .acfc-wt-poster { object-fit: contain; }

/* ---------- Now playing details ---------- */

.acfc-wt-details { min-width: 0; }

.acfc-wt-details-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 10px;
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--wt-accent-text);
}

.acfc-wt-eq {
  display: inline-flex;
  align-items: flex-end;
  gap: 2px;
  height: 12px;
}

.acfc-wt-eq i {
  width: 3px;
  height: 100%;
  border-radius: 2px;
  background: currentColor;
  transform-origin: bottom;
  transform: scaleY(0.35);
}

.acfc-wt-app.is-playing .acfc-wt-eq i { animation: acfc-wt-eq 0.9s ease-in-out infinite; }
.acfc-wt-app.is-playing .acfc-wt-eq i:nth-child(2) { animation-delay: -0.3s; }
.acfc-wt-app.is-playing .acfc-wt-eq i:nth-child(3) { animation-delay: -0.6s; }

@keyframes acfc-wt-eq {
  0%, 100% { transform: scaleY(0.3); }
  50% { transform: scaleY(1); }
}

.acfc-wt-details-title {
  margin: 0;
  font-size: clamp(1.3rem, 2.4vw, 1.9rem);
  font-weight: 800;
  letter-spacing: -0.015em;
  line-height: 1.2;
  text-wrap: balance;
}

.acfc-wt-details-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 14px;
  margin: 10px 0 0;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--wt-muted);
}

.acfc-wt-details-meta:empty { display: none; }

.acfc-wt-details-meta span + span::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 4px;
  margin-right: 14px;
  border-radius: 50%;
  background: currentColor;
  vertical-align: middle;
  opacity: 0.6;
}

.acfc-wt-details-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.acfc-wt-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid var(--wt-border);
  border-radius: var(--radius-full);
  background: var(--wt-faint);
  color: var(--wt-text);
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.acfc-wt-pill:hover {
  border-color: var(--sol-rosa);
  background: var(--sol-rosa-soft);
}

/* The theme recolors links on hover and focus */
.acfc-wt-app .acfc-wt-pill,
.acfc-wt-app .acfc-wt-pill:link,
.acfc-wt-app .acfc-wt-pill:visited,
.acfc-wt-app .acfc-wt-pill:hover,
.acfc-wt-app .acfc-wt-pill:focus,
.acfc-wt-app .acfc-wt-pill:active {
  color: var(--wt-text) !important;
  text-decoration: none !important;
}

.acfc-wt-desc-wrap {
  margin-top: 20px;
  padding: 16px 18px;
  border-radius: var(--radius-md);
  background: var(--wt-faint);
  border: 1px solid var(--wt-border);
}

.acfc-wt-desc {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.65;
  white-space: pre-line;
  overflow-wrap: anywhere;
  color: color-mix(in srgb, var(--wt-text) 86%, transparent);
}

.acfc-wt-desc.is-clamped {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.acfc-wt-desc a { color: var(--wt-accent-text); font-weight: 600; }

.acfc-wt-desc-toggle {
  margin-top: 8px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--wt-text);
  font-size: 0.85rem;
  font-weight: 800;
  cursor: pointer;
}

.acfc-wt-desc-toggle:hover { color: var(--wt-accent-text); }

/* ---------- Up next queue ---------- */

.acfc-wt-queue {
  min-width: 0;
  padding: 18px;
  border-radius: var(--radius-lg);
  background: color-mix(in srgb, var(--wt-surface) 82%, transparent);
  border: 1px solid var(--wt-border);
  backdrop-filter: blur(12px);
}

/* The queue fills the right column beside the video and details and scrolls
   inside; size containment stops its 500 items from stretching the rows. */
.acfc-wt-layout .acfc-wt-queue {
  align-self: stretch;
  display: flex;
  flex-direction: column;
  contain: size;
}

.acfc-wt-layout .acfc-wt-queue-list {
  flex: 1 1 auto;
  min-height: 0;
  max-height: none;
}

.acfc-wt-queue-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.acfc-wt-queue-title {
  margin: 0;
  font-size: 1rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.acfc-wt-queue-count {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--wt-muted);
}

.acfc-wt-queue-list {
  display: grid;
  gap: 4px;
  margin: 0;
  padding: 0;
  list-style: none;
  max-height: min(520px, calc(100vh - var(--wt-scroll-offset) - 120px));
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--wt-border) transparent;
  margin-right: -8px;
  padding-right: 8px;
}

.acfc-wt-qitem {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  gap: 12px;
  width: 100%;
  padding: 6px;
  border: 0;
  border-radius: var(--radius-md);
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  transition: background 0.2s ease;
}

.acfc-wt-qitem:hover { background: var(--wt-faint); }

.acfc-wt-qitem:hover .acfc-wt-thumb img { scale: 1.05; }

.acfc-wt-qitem-body { display: grid; align-content: start; gap: 4px; min-width: 0; padding-top: 2px; }

.acfc-wt-qitem-title {
  font-size: 0.88rem;
  font-weight: 700;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.acfc-wt-qitem-meta { font-size: 0.76rem; color: var(--wt-muted); font-weight: 500; }

/* Shared thumbnail */
.acfc-wt-thumb {
  position: relative;
  display: block;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--wt-card);
}

.acfc-wt-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: scale 0.5s var(--ease-out);
}

.acfc-wt-duration {
  position: absolute;
  right: 6px;
  bottom: 6px;
  padding: 2px 6px;
  border-radius: 5px;
  background: rgba(0, 0, 0, 0.82);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.02em;
}

.acfc-wt-duration.is-live { background: #d93025; text-transform: uppercase; letter-spacing: 0.08em; }

/* ---------- Library ---------- */

.acfc-wt-library {
  position: relative;
  padding: clamp(48px, 7vw, 88px) 0 clamp(32px, 4vw, 56px);
  background: var(--wt-bg-alt);
  border-top: 1px solid var(--wt-border);
}

.acfc-wt-library-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px;
  margin-bottom: 12px;
}

.acfc-wt-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.acfc-wt-search,
.acfc-wt-sort {
  position: relative;
  display: flex;
  align-items: center;
  height: 46px;
  border-radius: var(--radius-full);
  border: 1px solid var(--wt-border);
  background: var(--wt-surface);
  color: var(--wt-muted);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.acfc-wt-search:focus-within,
.acfc-wt-sort:focus-within {
  border-color: color-mix(in srgb, var(--sol-rosa) 70%, var(--wt-border));
  color: var(--wt-text);
}

.acfc-wt-search { width: 340px; max-width: 100%; padding-left: 16px; cursor: text; }

/* The HubSpot theme styles every form field with high-specificity rules, so
   the reset has to be !important to hold in all states. */
.acfc-wt-app .acfc-wt-search input,
.acfc-wt-app .acfc-wt-search input:hover,
.acfc-wt-app .acfc-wt-search input:focus,
.acfc-wt-app .acfc-wt-search input:focus-visible,
.acfc-wt-app .acfc-wt-search input:active {
  -webkit-appearance: none !important;
  appearance: none !important;
  flex: 1 1 auto !important;
  min-width: 0 !important;
  max-width: none !important;
  width: auto !important;
  height: 100% !important;
  min-height: 0 !important;
  margin: 0 !important;
  padding: 0 16px 0 10px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  outline: none !important;
  color: var(--wt-text) !important;
  font-family: inherit !important;
  font-size: 0.92rem !important;
  font-weight: 500 !important;
  line-height: normal !important;
  transition: none !important;
}

.acfc-wt-app .acfc-wt-sort select,
.acfc-wt-app .acfc-wt-sort select:hover,
.acfc-wt-app .acfc-wt-sort select:focus,
.acfc-wt-app .acfc-wt-sort select:focus-visible {
  border: 0 !important;
  background-color: transparent !important;
  box-shadow: none !important;
  outline: none !important;
}

.acfc-wt-search input::placeholder { color: var(--wt-muted); opacity: 1; }

.acfc-wt-search input::-webkit-search-decoration { -webkit-appearance: none; }

.acfc-wt-search input::-webkit-search-cancel-button {
  -webkit-appearance: none;
  width: 16px;
  height: 16px;
  margin-left: 8px;
  background: currentColor;
  opacity: 0.55;
  cursor: pointer;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M6 6l12 12M18 6 6 18'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round'%3E%3Cpath d='M6 6l12 12M18 6 6 18'/%3E%3C/svg%3E") center / contain no-repeat;
}

.acfc-wt-search input::-webkit-search-cancel-button:hover { opacity: 1; }

.acfc-wt-sort select {
  height: 100%;
  padding: 0 42px 0 18px;
  border: 0;
  border-radius: inherit;
  background: transparent;
  color: var(--wt-text);
  font: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  outline: none;
  -webkit-appearance: none;
  appearance: none;
}

.acfc-wt-sort select option { color: #111; }
.acfc-wt-sort svg { position: absolute; right: 18px; pointer-events: none; }

/* Themed sort menu (script.js swaps it in for the native option list) */
.acfc-wt-sort.is-enhanced select { display: none !important; }

.acfc-wt-app .acfc-wt-sort-btn,
.acfc-wt-app .acfc-wt-sort-btn:hover,
.acfc-wt-app .acfc-wt-sort-btn:focus {
  display: flex;
  align-items: center;
  gap: 10px;
  height: 100%;
  min-width: 150px;
  margin: 0;
  padding: 0 42px 0 18px;
  border: 0 !important;
  border-radius: inherit;
  background: transparent !important;
  box-shadow: none !important;
  color: var(--wt-text) !important;
  font: inherit;
  font-size: 0.88rem;
  font-weight: 700;
  text-transform: none;
  letter-spacing: normal;
  line-height: 1;
  cursor: pointer;
  outline: none;
}

.acfc-wt-app .acfc-wt-sort-btn:focus-visible { outline: 2px solid var(--sol-rosa) !important; outline-offset: 2px; }

.acfc-wt-sort-btn::before {
  content: 'Sort';
  color: var(--wt-muted);
  font-weight: 600;
}

.acfc-wt-sort-btn svg { transition: rotate 0.25s var(--ease-out); }
.acfc-wt-sort.is-open .acfc-wt-sort-btn svg { rotate: 180deg; }
.acfc-wt-sort.is-open { border-color: color-mix(in srgb, var(--sol-rosa) 70%, var(--wt-border)); }

.acfc-wt-sort-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 20;
  min-width: max(100%, 210px);
  padding: 6px;
  border: 1px solid var(--wt-border);
  border-radius: var(--radius-md);
  background: var(--wt-surface);
  box-shadow: var(--shadow-e3);
  animation: acfc-wt-pop 0.22s var(--ease-out);
  transform-origin: top right;
}

.acfc-wt-sort-menu[hidden] { display: none; }

[data-theme="dark"] .acfc-wt-sort-menu {
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.04);
}

.acfc-wt-sort-heading {
  margin: 8px 12px 6px;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--wt-muted);
}

.acfc-wt-app .acfc-wt-sort-option,
.acfc-wt-app .acfc-wt-sort-option:hover,
.acfc-wt-app .acfc-wt-sort-option:focus {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  margin: 0;
  padding: 10px 12px;
  border: 0 !important;
  border-radius: var(--radius-sm);
  background: transparent !important;
  box-shadow: none !important;
  color: var(--wt-text) !important;
  font: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  text-align: left;
  text-transform: none;
  letter-spacing: normal;
  line-height: 1.2;
  cursor: pointer;
  outline: none;
}

.acfc-wt-app .acfc-wt-sort-option[hidden] { display: none; }

.acfc-wt-app .acfc-wt-sort-option:hover,
.acfc-wt-app .acfc-wt-sort-option:focus-visible { background: var(--wt-faint) !important; }

.acfc-wt-sort-option::after {
  content: '';
  flex: none;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: transparent;
}

.acfc-wt-app .acfc-wt-sort-option[aria-selected="true"] { color: var(--wt-accent-text) !important; }
.acfc-wt-sort-option[aria-selected="true"]::after { background: var(--sol-rosa); box-shadow: 0 0 0 3px var(--sol-rosa-soft); }

[data-theme="light"] .acfc-wt-app .acfc-wt-sort-option[aria-selected="true"] { color: var(--wt-text) !important; }

.acfc-wt-library-count {
  margin: 0 0 24px;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--wt-muted);
}

.acfc-wt-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(18px, 2vw, 28px) clamp(14px, 1.6vw, 24px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.acfc-wt-card {
  display: grid;
  gap: 12px;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
  border-radius: var(--radius-md);
  animation: acfc-wt-card-in 0.5s var(--ease-out) both;
}

@keyframes acfc-wt-card-in {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

.acfc-wt-card .acfc-wt-thumb {
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-e1);
  transition: translate 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}

.acfc-wt-card:hover .acfc-wt-thumb,
.acfc-wt-card:focus-visible .acfc-wt-thumb {
  translate: 0 -3px;
  box-shadow: var(--wt-card-shadow-hover);
}

.acfc-wt-card:hover .acfc-wt-thumb img { scale: 1.05; }

.acfc-wt-card-play {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: rgba(0, 0, 0, 0.28);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.acfc-wt-card-play span {
  display: grid;
  place-items: center;
  width: 54px;
  height: 54px;
  padding-left: 3px;
  border-radius: 50%;
  background: var(--sol-rosa);
  color: var(--pitch-black);
  scale: 0.8;
  transition: scale 0.35s var(--ease-out);
}

.acfc-wt-card:hover .acfc-wt-card-play,
.acfc-wt-card:focus-visible .acfc-wt-card-play { opacity: 1; }
.acfc-wt-card:hover .acfc-wt-card-play span { scale: 1; }

.acfc-wt-now {
  position: absolute;
  left: 8px;
  top: 8px;
  display: none;
  align-items: center;
  gap: 7px;
  padding: 5px 10px;
  border-radius: var(--radius-full);
  background: var(--sol-rosa);
  color: var(--pitch-black);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.acfc-wt-card.is-active .acfc-wt-now { display: inline-flex; }
.acfc-wt-card.is-active .acfc-wt-thumb { box-shadow: 0 0 0 2px var(--sol-rosa), var(--wt-card-shadow-hover); }

.acfc-wt-card-title {
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  transition: color 0.2s ease;
}

.acfc-wt-card:hover .acfc-wt-card-title { color: var(--wt-accent-text); }

.acfc-wt-card-meta {
  display: block;
  margin-top: 4px;
  font-size: 0.8rem;
  color: var(--wt-muted);
  font-weight: 500;
}

.acfc-wt-card.is-unavailable { opacity: 0.45; }

.acfc-wt-empty {
  display: grid;
  justify-items: center;
  gap: 16px;
  padding: 56px 20px;
  text-align: center;
  border: 1px dashed var(--wt-border);
  border-radius: var(--radius-lg);
}

.acfc-wt-empty-title { margin: 0; font-weight: 700; font-size: 1.05rem; }

.acfc-wt-more-wrap { display: flex; justify-content: center; margin-top: clamp(32px, 4vw, 48px); }
.acfc-wt-more-wrap.is-auto { height: 1px; margin-top: 0; overflow: hidden; }
.acfc-wt-more-wrap.is-auto [data-wt-more] { display: none !important; }

/* ---------- Skeletons ---------- */

.acfc-wt-skel {
  position: relative;
  overflow: hidden;
  background: var(--wt-faint);
  border-radius: var(--radius-sm);
}

.acfc-wt-skel::after {
  content: '';
  position: absolute;
  inset: 0;
  translate: -100% 0;
  background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--wt-text) 7%, transparent), transparent);
  animation: acfc-wt-shimmer 1.4s ease-in-out infinite;
}

@keyframes acfc-wt-shimmer { to { translate: 100% 0; } }

.acfc-wt-skel-thumb { aspect-ratio: 16 / 9; }
.acfc-wt-skel-line { height: 12px; margin-top: 10px; }
.acfc-wt-skel-line--short { width: 55%; }

.acfc-wt-skel-qitem {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 12px;
  padding: 6px;
}

.acfc-wt-skel-qitem .acfc-wt-skel-line:first-child { margin-top: 2px; }

/* ---------- Toast ---------- */

.acfc-wt-toast {
  position: fixed;
  left: 50%;
  bottom: calc(28px + env(safe-area-inset-bottom, 0px));
  z-index: 2147483646;
  padding: 12px 20px;
  border-radius: var(--radius-full);
  background: var(--sol-rosa);
  color: var(--pitch-black);
  font-size: 0.88rem;
  font-weight: 800;
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.35);
  translate: -50% 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, translate 0.3s var(--ease-out);
}

.acfc-wt-toast.is-show { opacity: 1; translate: -50% 0; }

/* ---------- Format tabs (Videos / Shorts) ---------- */

.acfc-wt-tabs {
  display: inline-flex;
  padding: 4px;
  border-radius: var(--radius-full);
  background: var(--wt-faint);
  border: 1px solid var(--wt-border);
}

.acfc-wt-tab {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 36px;
  padding: 0 16px;
  border: 0;
  border-radius: var(--radius-full);
  background: transparent;
  color: var(--wt-muted);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.25s var(--ease-out), color 0.2s ease, box-shadow 0.25s ease;
}

.acfc-wt-tab:hover { color: var(--wt-text); }

.acfc-wt-tab[aria-selected="true"] {
  background: var(--sol-rosa);
  color: var(--pitch-black);
  box-shadow: 0 6px 18px var(--sol-rosa-glow);
}

/* ---------- Shorts mode ---------- */

.acfc-wt-shorts-nav { display: none; }

.acfc-wt-app.is-shorts {
  /* Tallest 9:16 player that keeps its controls on screen */
  --wt-short-w: clamp(280px, calc((100svh - var(--wt-scroll-offset) - 150px) * 9 / 16), 460px);
}

.acfc-wt-app.is-shorts .acfc-wt-layout {
  grid-template-columns: var(--wt-short-w) minmax(0, 760px);
  grid-template-areas:
    "stage details"
    "stage queue";
  grid-template-rows: auto 1fr;
  justify-content: center;
  column-gap: clamp(72px, 7vw, 112px);
}

.acfc-wt-app.is-shorts .acfc-wt-stage {
  aspect-ratio: 9 / 16;
  width: var(--wt-short-w);
  max-width: none;
  margin-inline: 0;
}

.acfc-wt-app.is-shorts .acfc-wt-shorts-nav {
  position: absolute;
  top: 50%;
  left: calc(100% + clamp(14px, 1.6vw, 28px));
  display: flex;
  flex-direction: column;
  gap: 14px;
  translate: 0 -50%;
}

.acfc-wt-shorts-btn {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  padding: 0;
  border: 1px solid var(--wt-border);
  border-radius: 50%;
  background: var(--wt-surface);
  color: var(--wt-text);
  cursor: pointer;
  box-shadow: var(--shadow-e1);
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, translate 0.25s var(--ease-out);
}

.acfc-wt-shorts-btn:hover {
  background: var(--sol-rosa);
  border-color: var(--sol-rosa);
  color: var(--pitch-black);
}

.acfc-wt-shorts-btn[data-wt-short-prev]:hover { translate: 0 -2px; }
.acfc-wt-shorts-btn[data-wt-short-next]:hover { translate: 0 2px; }

/* Up/down drags on the player scroll the page; sideways swipes step through Shorts */
.acfc-wt-app.is-shorts .acfc-wt-shield { touch-action: pan-y; }

.acfc-wt-app.is-shorts .acfc-wt-switch-label { display: none; }
.acfc-wt-app.is-shorts .acfc-wt-time { font-size: 0.78rem; }
.acfc-wt-app.is-shorts .acfc-wt-ctrl { width: 38px; height: 38px; }
.acfc-wt-app.is-shorts .acfc-wt-controls { padding-inline: 8px; }

.acfc-wt-app.is-shorts .acfc-wt-player.is-mini {
  width: min(220px, calc(100vw - 32px));
  aspect-ratio: 9 / 16;
}

.acfc-wt-app.is-shorts .acfc-wt-player.is-mini [data-wt-prev],
.acfc-wt-app.is-shorts .acfc-wt-player.is-mini [data-wt-next] { display: none; }

.acfc-wt-app.is-shorts .acfc-wt-thumb,
.acfc-wt-app.is-shorts .acfc-wt-skel-thumb { aspect-ratio: 9 / 16; }

/* Queue: a row of vertical tiles beside the player */
.acfc-wt-app.is-shorts .acfc-wt-layout .acfc-wt-queue {
  display: block;
  align-self: start;
  contain: none;
}

/* One row of four Shorts beside the player that scrolls sideways for more */
.acfc-wt-app.is-shorts .acfc-wt-layout .acfc-wt-queue-list {
  --wt-q-gap: 14px;
  display: flex;
  gap: var(--wt-q-gap);
  max-height: none;
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: 0;
  margin: 0;
  padding: 0 0 4px;
  scrollbar-width: none;
}

.acfc-wt-app.is-shorts .acfc-wt-layout .acfc-wt-queue-list::-webkit-scrollbar { display: none; }

.acfc-wt-app.is-shorts .acfc-wt-layout .acfc-wt-queue-list > li {
  flex: 0 0 calc((100% - 3 * var(--wt-q-gap)) / 4);
  min-width: 0;
  scroll-snap-align: start;
}

/* Only Shorts on desktop wrap the queue in a visible panel; elsewhere it adds no box */
.acfc-wt-queue-panel { display: contents; }

/* Desktop Shorts: the queue column spans the height left under the details and its
   panel sits on the player's base, so Up Next always ends level with the video.
   Tiles are a quarter of the row, narrower when the player is short (laptops), and
   never below --wt-q-min; past that the thumbnail gets shorter instead of overflowing. */
@media (min-width: 821px) {
  @supports (width: 1cqh) {
    .acfc-wt-app.is-shorts .acfc-wt-layout .acfc-wt-queue {
      --wt-q-pad: 18px;
      --wt-q-head: 48px;
      --wt-q-text: 4.6rem;
      --wt-q-min: 118px;
      --wt-q-avail: calc(100cqh - 2 * var(--wt-q-pad) - 2px - var(--wt-q-head) - 4px - var(--wt-q-text));
      display: flex;
      flex-direction: column;
      justify-content: flex-end;
      align-self: stretch;
      min-height: 0;
      padding: 0;
      border: 0;
      background: none;
      backdrop-filter: none;
      container-type: size;
    }

    .acfc-wt-app.is-shorts .acfc-wt-queue-panel {
      display: flex;
      flex-direction: column;
      min-height: 0;
      padding: var(--wt-q-pad);
      border-radius: var(--radius-lg);
      background: color-mix(in srgb, var(--wt-surface) 82%, transparent);
      border: 1px solid var(--wt-border);
      backdrop-filter: blur(12px);
    }

    .acfc-wt-app.is-shorts .acfc-wt-layout .acfc-wt-queue-list > li {
      --wt-q-w: max(var(--wt-q-min), min(calc((100cqw - 2 * var(--wt-q-pad) - 2px - 3 * var(--wt-q-gap)) / 4), calc(var(--wt-q-avail) * 9 / 16)));
      flex: 0 0 var(--wt-q-w);
    }

    .acfc-wt-app.is-shorts .acfc-wt-layout .acfc-wt-queue-list .acfc-wt-thumb {
      aspect-ratio: auto;
      height: min(calc(var(--wt-q-w) * 16 / 9), var(--wt-q-avail));
    }

    .acfc-wt-app.is-shorts .acfc-wt-layout .acfc-wt-queue-list .acfc-wt-qitem-meta {
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
    }
  }
}

.acfc-wt-app.is-shorts .acfc-wt-desc-wrap { display: none !important; }

/* Queue paging arrows (Shorts on desktop only) */
.acfc-wt-queue-nav { display: none; }

.acfc-wt-app.is-shorts .acfc-wt-queue-head { align-items: center; }
.acfc-wt-app.is-shorts .acfc-wt-queue-count { margin-left: auto; }

.acfc-wt-app.is-shorts .acfc-wt-queue-nav {
  display: flex;
  gap: 8px;
}

.acfc-wt-queue-btn {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1px solid var(--wt-border);
  border-radius: 50%;
  background: var(--wt-surface);
  color: var(--wt-text);
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, opacity 0.2s ease;
}

.acfc-wt-queue-btn:hover:not(:disabled) {
  background: var(--sol-rosa);
  border-color: var(--sol-rosa);
  color: var(--pitch-black);
}

.acfc-wt-queue-btn:disabled { opacity: 0.35; cursor: default; }

.acfc-wt-app.is-shorts .acfc-wt-qitem,
.acfc-wt-app.is-shorts .acfc-wt-skel-qitem {
  grid-template-columns: 1fr;
  gap: 8px;
  padding: 0;
}

.acfc-wt-app.is-shorts .acfc-wt-qitem:hover { background: none; }
.acfc-wt-app.is-shorts .acfc-wt-qitem .acfc-wt-thumb { border-radius: var(--radius-md); }
.acfc-wt-app.is-shorts .acfc-wt-qitem-title { font-size: 0.82rem; -webkit-line-clamp: 3; }

.acfc-wt-app.is-shorts .acfc-wt-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.acfc-wt-app.is-shorts .acfc-wt-card-title { font-size: 0.9rem; }

/* ---------- Theme toggle (matches 2027Renewals) ---------- */

.acfc-wt-theme-toggle {
  position: fixed;
  bottom: calc(clamp(14px, 2.4vw, 24px) + env(safe-area-inset-bottom, 0px));
  right: clamp(14px, 2.4vw, 24px);
  z-index: 2147483647;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border-radius: var(--radius-full);
  border: none;
  background: var(--pitch-black);
  color: var(--sol-rosa);
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.28);
  transition: transform 0.25s var(--ease-out), box-shadow 0.25s ease;
}

.acfc-wt-theme-toggle:hover { transform: translateY(-2px) scale(1.05); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4); }
.acfc-wt-theme-toggle:focus-visible { outline: 2px solid var(--sol-rosa); outline-offset: 3px; }
.acfc-wt-theme-toggle .acfc-wt-icon-sun { display: none; }

[data-theme="dark"] .acfc-wt-theme-toggle {
  background: var(--sol-rosa);
  color: var(--pitch-black);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.45), 0 0 0 4px rgba(0, 0, 0, 0.55);
}

[data-theme="dark"] .acfc-wt-theme-toggle .acfc-wt-icon-sun { display: block; }
[data-theme="dark"] .acfc-wt-theme-toggle .acfc-wt-icon-moon { display: none; }

/* ---------- Responsive ---------- */

@media (max-width: 1400px) {
  :root { --wt-queue-width: 360px; }
  .acfc-wt-qitem,
  .acfc-wt-skel-qitem { grid-template-columns: 140px minmax(0, 1fr); }
}

@media (max-width: 1280px) {
  .acfc-wt-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .acfc-wt-app.is-shorts .acfc-wt-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}

/* Small laptops and landscape tablets keep the queue beside the video */
@media (max-width: 1200px) {
  :root { --wt-queue-width: 320px; }
  .acfc-wt-layout { gap: 20px; }
  .acfc-wt-qitem,
  .acfc-wt-skel-qitem { grid-template-columns: 124px minmax(0, 1fr); gap: 10px; }
  .acfc-wt-qitem-title { font-size: 0.84rem; }
  .acfc-wt-app.is-shorts .acfc-wt-layout { column-gap: 56px; }
}

@media (max-width: 1000px) {
  :root { --wt-queue-width: 280px; }
  .acfc-wt-qitem,
  .acfc-wt-skel-qitem { grid-template-columns: 112px minmax(0, 1fr); }
  .acfc-wt-qitem-meta { font-size: 0.74rem; }
}

/* Single column: queue becomes a horizontal rail */
@media (max-width: 820px) {
  /* Escape the player's overflow:hidden; position is set in script from the gear button */
  .acfc-wt-menu:not([hidden]) {
    position: fixed;
    bottom: auto;
    left: auto;
    z-index: 2147483645;
    width: min(260px, calc(100vw - 24px));
    max-height: min(300px, 46vh);
  }

  .acfc-wt-layout {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "stage"
      "details"
      "queue";
  }


  .acfc-wt-queue {
    padding: 18px 0 0;
    border: 0;
    border-top: 1px solid var(--wt-border);
    border-radius: 0;
    background: none;
    backdrop-filter: none;
  }

  .acfc-wt-layout .acfc-wt-queue {
    display: block;
    align-self: start;
    contain: none;
  }

  .acfc-wt-layout .acfc-wt-queue-list {
    display: flex;
    gap: 14px;
    max-height: none;
    overflow-x: auto;
    overflow-y: hidden;
    scroll-snap-type: x mandatory;
    margin: 0 calc(-1 * max(24px, env(safe-area-inset-right, 0px))) 0 0;
    padding: 0 max(24px, env(safe-area-inset-right, 0px)) 8px 0;
    scrollbar-width: none;
  }

  .acfc-wt-queue-list::-webkit-scrollbar { display: none; }
  .acfc-wt-queue-list > li { flex: 0 0 min(260px, 72vw); scroll-snap-align: start; }

  .acfc-wt-qitem,
  .acfc-wt-skel-qitem {
    grid-template-columns: 1fr;
    gap: 10px;
    padding: 0;
  }

  .acfc-wt-qitem:hover { background: none; }
  .acfc-wt-qitem-title { -webkit-line-clamp: 3; }

  /* Shorts: centered vertical player, queue as a rail of tiles */
  .acfc-wt-app.is-shorts .acfc-wt-layout {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "stage"
      "details"
      "queue";
    grid-template-rows: none;
  }

  .acfc-wt-app.is-shorts .acfc-wt-stage { margin-inline: auto; }

  .acfc-wt-app.is-shorts .acfc-wt-layout .acfc-wt-queue-list {
    display: flex;
    overflow-x: auto;
    margin-right: calc(-1 * max(24px, env(safe-area-inset-right, 0px)));
    padding-right: max(24px, env(safe-area-inset-right, 0px));
  }

  .acfc-wt-app.is-shorts .acfc-wt-layout .acfc-wt-queue-list > li { flex: 0 0 150px; }
}

@media (max-width: 900px) {
  .acfc-wt-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .acfc-wt-app.is-shorts .acfc-wt-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 720px) {
  .acfc-wt-head-inner { align-items: flex-start; flex-direction: column; }
  .acfc-wt-head-side { width: 100%; justify-content: space-between; }

  /* Edge-to-edge player on phones */
  .acfc-wt-theater .acfc-wt-wide { padding-left: 0; padding-right: 0; }
  .acfc-wt-stage { border-radius: 0; box-shadow: none; }
  .acfc-wt-app.is-shorts .acfc-wt-stage { border-radius: var(--radius-lg); }
  .acfc-wt-head-side { gap: 10px; }
  .acfc-wt-head-count { display: none; }
  .acfc-wt-tab { padding: 0 14px; }
  .acfc-wt-tab svg { display: none; }
  .acfc-wt-subscribe { min-height: 44px; padding: 0.5rem 1rem; font-size: 0.8rem; }
  .acfc-wt-details,
  .acfc-wt-queue { padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
  .acfc-wt-layout .acfc-wt-queue-list { margin-right: calc(-1 * max(16px, env(safe-area-inset-right, 0px))); padding-right: max(16px, env(safe-area-inset-right, 0px)); }

  .acfc-wt-switch-label,
  .acfc-wt-volume-range { display: none; }
  .acfc-wt-ctrl { width: 40px; height: 40px; }
  .acfc-wt-time { font-size: 0.78rem; margin-left: 4px; }
  .acfc-wt-toolbar { width: 100%; flex-wrap: nowrap; }
  .acfc-wt-search { flex: 1 1 0; width: auto; min-width: 0; }
  .acfc-wt-search input { min-width: 0; }
  .acfc-wt-sort { flex: none; }

  /* Compact header so the player starts higher on the screen */
  .acfc-wt-head { padding: 16px 0 14px; }
  .acfc-wt-head-inner { gap: 14px; }
  .acfc-wt-head-title { font-size: clamp(1.6rem, 8vw, 2.6rem); }

  /* Controls keep their size; the time readout gives way first */
  .acfc-wt-ctrl,
  .acfc-wt-switch { flex: none; }
  .acfc-wt-time { min-width: 0; overflow: hidden; text-overflow: clip; }
  .acfc-wt-controls { padding-inline: 6px; }

  .acfc-wt-desc-wrap { margin-top: 16px; padding: 14px 16px; }
  .acfc-wt-details-actions { margin-top: 14px; }
  .acfc-wt-library-head { gap: 14px; }

  .acfc-wt-theme-toggle { width: 42px; height: 42px; }
}

@media (max-width: 560px) {
  .acfc-wt-grid { grid-template-columns: minmax(0, 1fr); }
  .acfc-wt-app.is-shorts .acfc-wt-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .acfc-wt-app.is-shorts .acfc-wt-shorts-nav { display: none; }
  [data-wt-prev],
  [data-wt-next] { display: none; }
  .acfc-wt-player.is-mini { width: min(300px, calc(100vw - 32px)); }

  /* Shorts fill the phone width like the YouTube app */
  /* Fits the whole Short under the site header + schedule nav, with a side gutter */
  .acfc-wt-app.is-shorts {
    --wt-mobile-chrome: 150px;
    --wt-short-w: max(220px, min(calc(100vw - 64px), 420px, calc((100svh - var(--wt-mobile-chrome)) * 9 / 16)));
  }
  .acfc-wt-app.is-shorts .acfc-wt-ctrl { width: 40px; height: 40px; }
  .acfc-wt-app.is-shorts .acfc-wt-controls { padding-inline: 4px; }
  .acfc-wt-app.is-shorts .acfc-wt-switch { padding: 0 6px; }

  .acfc-wt-head-side { gap: 8px; }
  .acfc-wt-subscribe { padding: 0.5rem 0.9rem; }
}

@media (max-width: 380px) {
  /* Narrowest phones: drop the total time and keep the elapsed time */
  .acfc-wt-time-sep,
  .acfc-wt-time [data-wt-time-total] { display: none; }
  .acfc-wt-tab { padding: 0 12px; letter-spacing: 0.04em; }
  .acfc-wt-subscribe svg { display: none; }
  .acfc-wt-app .acfc-wt-sort-btn,
  .acfc-wt-app .acfc-wt-sort-btn:hover,
  .acfc-wt-app .acfc-wt-sort-btn:focus { min-width: 0; padding: 0 36px 0 14px; }
  .acfc-wt-sort svg { right: 14px; }
  .acfc-wt-sort-btn::before { display: none; }
}

/* Phones held sideways: fit the whole video (and its controls) on screen */
@media (orientation: landscape) and (max-height: 520px) {
  :root { --wt-scroll-offset: 56px; }
  .acfc-wt-head { padding: 10px 0 10px; }
  .acfc-wt-head-count { display: none; }
  .acfc-wt-head-inner { flex-direction: row; align-items: center; }
  .acfc-wt-head-side { width: auto; }
  .acfc-wt-head-title { font-size: 1.6rem; }

  .acfc-wt-stage {
    max-width: calc((100svh - 16px) * 16 / 9);
    margin-inline: auto;
    border-radius: var(--radius-md);
  }

  .acfc-wt-app.is-shorts { --wt-short-w: calc((100svh - 16px) * 9 / 16); }
  .acfc-wt-app.is-shorts .acfc-wt-stage { max-width: none; }
  .acfc-wt-app.is-shorts .acfc-wt-switch,
  .acfc-wt-app.is-shorts .acfc-wt-time,
  .acfc-wt-app.is-shorts [data-wt-prev],
  .acfc-wt-app.is-shorts [data-wt-next],
  .acfc-wt-app.is-shorts [data-wt-cc] { display: none; }
  .acfc-wt-app.is-shorts .acfc-wt-ctrl { flex: none; }
}

/* Comfortable touch targets */
@media (pointer: coarse) {
  .acfc-wt-tab { height: 44px; }
  .acfc-wt-desc-toggle { min-height: 40px; padding: 8px 0; margin-top: 0; }
}

@media (hover: none) {
  .acfc-wt-volume-range { display: none; }
  .acfc-wt-scrub-handle { scale: 1; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .acfc-wt-reveal { opacity: 1 !important; transform: none !important; }
  .acfc-wt-endcard.is-counting .acfc-wt-endcard-ring circle { animation: none; stroke-dashoffset: 0; }
}

/* Shorts drop the elapsed / total time readout outside fullscreen */
.acfc-wt-app.is-shorts .acfc-wt-player:not(.is-fullscreen) .acfc-wt-time { display: none; }

/* Shorts thumbnails drop their length badge on desktop */
@media (min-width: 821px) {
  .acfc-wt-app.is-shorts .acfc-wt-duration { display: none; }
}

/* Views, posted date and length are hidden everywhere: under the player title,
   on library cards and in the Up Next list */
.acfc-wt-app .acfc-wt-details-meta,
.acfc-wt-app .acfc-wt-card-meta,
.acfc-wt-app .acfc-wt-qitem-meta { display: none !important; }

/* Position ("1 / 304") above Up Next and "Showing 12 of 747" above the library are hidden */
.acfc-wt-app .acfc-wt-queue-count,
.acfc-wt-app .acfc-wt-library-count { display: none !important; }
