@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&family=Space+Grotesk:wght@600;700&display=swap');

/* ==========================================================================
   STREAMHUB - FREEVIDEO-INSPIRED ULTRA-PREMIUM VIDEO PLATFORM
   Dark OLED, Purple Glow (#6d5cf0), Space Grotesk + Poppins, 120fps UI
   ========================================================================== */

:root {
  /* System default color scheme support */
  color-scheme: light dark;

  /* Explicit override mapping from <meta name="color-scheme"> */
  &:has(> head > meta[name="color-scheme"][content="dark"]) {
    color-scheme: dark;
  }

  &:has(> head > meta[name="color-scheme"][content="light"]) {
    color-scheme: light;
  }

  /* FreeVideo Light Palette */
  --bg-light: #f7f8fb;
  --surface-light: #ffffff;
  --surface-subtle-light: #f1f3f7;
  --surface-hover-light: #e5e8ee;
  --border-light: #e5e8ee;
  --border-focus-light: #6d5cf0;
  --text-main-light: #1a1d24;
  --text-muted-light: #565c68;
  --text-subtle-light: #8b91a0;
  --brand-light: #6d5cf0;
  --brand-hover-light: #5b48e0;
  --brand-subtle-light: rgba(109, 92, 240, 0.1);
  --accent-light: #f43f5e;
  --success-light: #22b07d;
  --glass-bg-light: rgba(255, 255, 255, 0.92);
  --glass-border-light: rgba(229, 232, 238, 0.85);
  --shadow-sm-light: 0 1px 3px rgba(20, 23, 33, 0.06);
  --shadow-md-light: 0 12px 30px rgba(20, 23, 33, 0.1);
  --shadow-lg-light: 0 18px 45px rgba(20, 23, 33, 0.15);

  /* FreeVideo Dark Palette (OLED Slate & Purple Glow) */
  --bg-dark: #090b10;
  --surface-dark: #12151c;
  --surface-subtle-dark: #171b23;
  --surface-hover-dark: #222834;
  --border-dark: #232935;
  --border-focus-dark: #8b7cff;
  --text-main-dark: #e9ebef;
  --text-muted-dark: #9aa2af;
  --text-subtle-dark: #6c7482;
  --brand-dark: #6d5cf0;
  --brand-hover-dark: #8b7cff;
  --brand-subtle-dark: rgba(109, 92, 240, 0.18);
  --accent-dark: #f43f5e;
  --success-dark: #22b07d;
  --glass-bg-dark: rgba(18, 21, 28, 0.92);
  --glass-border-dark: rgba(35, 41, 53, 0.85);
  --shadow-sm-dark: 0 1px 3px rgba(0, 0, 0, 0.45);
  --shadow-md-dark: 0 12px 30px rgba(0, 0, 0, 0.55);
  --shadow-lg-dark: 0 18px 50px rgba(0, 0, 0, 0.75);

  /* Adaptive Variables */
  --bg-page: light-dark(var(--bg-light), var(--bg-dark));
  --surface: light-dark(var(--surface-light), var(--surface-dark));
  --surface-subtle: light-dark(var(--surface-subtle-light), var(--surface-subtle-dark));
  --surface-hover: light-dark(var(--surface-hover-light), var(--surface-hover-dark));
  --border-color: light-dark(var(--border-light), var(--border-dark));
  --border-focus: light-dark(var(--border-focus-light), var(--border-focus-dark));
  --text-main: light-dark(var(--text-main-light), var(--text-main-dark));
  --text-muted: light-dark(var(--text-muted-light), var(--text-muted-dark));
  --text-subtle: light-dark(var(--text-subtle-light), var(--text-subtle-dark));
  --brand: light-dark(var(--brand-light), var(--brand-dark));
  --brand-hover: light-dark(var(--brand-hover-light), var(--brand-hover-dark));
  --brand-subtle: light-dark(var(--brand-subtle-light), var(--brand-subtle-dark));
  --accent: light-dark(var(--accent-light), var(--accent-dark));
  --success: light-dark(var(--success-light), var(--success-dark));
  --glass-bg: light-dark(var(--glass-bg-light), var(--glass-bg-dark));
  --glass-border: light-dark(var(--glass-border-light), var(--glass-border-dark));
  --shadow-sm: light-dark(var(--shadow-sm-light), var(--shadow-sm-dark));
  --shadow-md: light-dark(var(--shadow-md-light), var(--shadow-md-dark));
  --shadow-lg: light-dark(var(--shadow-lg-light), var(--shadow-lg-dark));

  /* Sizing & Typography */
  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-full: 9999px;
  --font-family: 'Poppins',
  system-ui,
  -apple-system,
  sans-serif;
  --font-display: 'Space Grotesk',
  sans-serif;
  --max-content-width: 1440px;

  accent-color: var(--brand);
}

/* Fallbacks for explicit data-theme */
[data-theme="light"] {
  color-scheme: light;
  --bg-page: var(--bg-light);
  --surface: var(--surface-light);
  --surface-subtle: var(--surface-subtle-light);
  --surface-hover: var(--surface-hover-light);
  --border-color: var(--border-light);
  --border-focus: var(--border-focus-light);
  --text-main: var(--text-main-light);
  --text-muted: var(--text-muted-light);
  --text-subtle: var(--text-subtle-light);
  --brand: var(--brand-light);
  --brand-hover: var(--brand-hover-light);
  --brand-subtle: var(--brand-subtle-light);
  --accent: var(--accent-light);
  --success: var(--success-light);
  --glass-bg: var(--glass-bg-light);
  --glass-border: var(--glass-border-light);
  --shadow-sm: var(--shadow-sm-light);
  --shadow-md: var(--shadow-md-light);
  --shadow-lg: var(--shadow-lg-light);
}

[data-theme="dark"] {
  color-scheme: dark;
  --bg-page: var(--bg-dark);
  --surface: var(--surface-dark);
  --surface-subtle: var(--surface-subtle-dark);
  --surface-hover: var(--surface-hover-dark);
  --border-color: var(--border-dark);
  --border-focus: var(--border-focus-dark);
  --text-main: var(--text-main-dark);
  --text-muted: var(--text-muted-dark);
  --text-subtle: var(--text-subtle-dark);
  --brand: var(--brand-dark);
  --brand-hover: var(--brand-hover-dark);
  --brand-subtle: var(--brand-subtle-dark);
  --accent: var(--accent-dark);
  --success: var(--success-dark);
  --glass-bg: var(--glass-bg-dark);
  --glass-border: var(--glass-border-dark);
  --shadow-sm: var(--shadow-sm-dark);
  --shadow-md: var(--shadow-md-dark);
  --shadow-lg: var(--shadow-lg-dark);
}

/* Base Resets */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  min-height: 100%;
  overflow-x: hidden;
  max-width: 100vw;
  width: 100%;
  position: relative;
  font-family: var(--font-family);
  background: radial-gradient(1000px 500px at 82% -12%, rgba(109, 92, 240, 0.08), transparent 60%), var(--bg-page);
  background-attachment: fixed;
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.25s cubic-bezier(0.4, 0, 0.2, 1), color 0.25s ease;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  outline: none;
}

/* Modern SVG Icons Framework */
.svg-icon {
  width: 18px;
  height: 18px;
  display: inline-block;
  vertical-align: middle;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.svg-icon.sm {
  width: 14px;
  height: 14px;
  stroke-width: 2.2;
}

.svg-icon.md {
  width: 20px;
  height: 20px;
  stroke-width: 2;
}

.svg-icon.lg {
  width: 26px;
  height: 26px;
  stroke-width: 1.8;
}

/* App Container */
.app-container {
  width: 100%;
  max-width: var(--max-content-width);
  margin: 0 auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  box-sizing: border-box;
}

/* Glassmorphic Sticky Header (FreeVideo Modern Header) */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--glass-border);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  box-shadow: var(--shadow-sm);
  width: 100%;
  box-sizing: border-box;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.5px;
  color: var(--text-main);
  flex-shrink: 0;
  user-select: none;
}

.brand-logo .logo-icon-box {
  width: 35px;
  height: 35px;
  background: linear-gradient(135deg, #6d5cf0 0%, #a855f7 100%);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  box-shadow: 0 4px 14px rgba(109, 92, 240, 0.45);
  flex-shrink: 0;
}

.brand-logo .logo-text {
  display: flex;
  align-items: baseline;
  gap: 2px;
}

.brand-logo .brand-accent {
  color: #6d5cf0;
}

.brand-logo .brand-main {
  color: var(--text-main);
}

.brand-logo .brand-tld {
  font-size: 0.70rem;
  color: #8b7cff;
  font-weight: 600;
  padding: 1px 5px;
  background: rgba(109, 92, 240, 0.15);
  border-radius: 4px;
  margin-left: 2px;
}

.brand-logo .logo-text span {
  color: #6d5cf0;
}

/* FreeVideo Centered Pill Search Bar */
.search-wrapper {
  flex: 1;
  position: relative;
  max-width: 500px;
  margin: 0 auto;
}

.search-input {
  width: 100%;
  height: 42px;
  padding: 0 38px 0 42px;
  background-color: var(--surface-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  color: var(--text-main);
  font-size: 0.88rem;
  font-family: var(--font-family);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.search-input:focus {
  outline: none;
  border-color: var(--border-focus);
  background-color: var(--surface);
  box-shadow: 0 0 0 3px var(--brand-subtle);
}

.search-icon-slot {
  position: absolute;
  left: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  pointer-events: none;
  display: flex;
}

.search-clear-btn {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  cursor: pointer;
  display: none;
  padding: 4px;
  border-radius: 50%;
}

.search-clear-btn:hover {
  color: var(--text-main);
}

/* Header Action Buttons */
.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.icon-btn {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-main);
  background-color: var(--surface-subtle);
  border: 1px solid var(--border-color);
  transition: all 0.2s ease;
}

.icon-btn:hover,
.icon-btn:active {
  background-color: var(--surface-hover);
  border-color: var(--brand);
  transform: translateY(-1px);
}

.theme-toggle-btn {
  border-radius: var(--radius-full);
}

/* Mobile Header Buttons */
.mobile-header-btn {
  display: none;
  width: 38px;
  height: 38px;
  border-radius: var(--radius-full);
  align-items: center;
  justify-content: center;
  background: var(--surface-subtle);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.mobile-header-btn:hover,
.mobile-header-btn:active {
  background: var(--surface-hover);
  border-color: var(--brand);
  color: var(--brand);
}

/* Mobile Expandable Search Bar */
.mobile-search-expand {
  display: none;
  width: 100%;
  background: var(--surface);
  border-bottom: 1px solid var(--border-color);
  padding: 8px 12px;
  box-sizing: border-box;
  position: relative;
  z-index: 90;
  animation: mobileSearchSlideDown 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-search-expand.active {
  display: block !important;
}

@keyframes mobileSearchSlideDown {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.mobile-search-expand form {
  display: flex;
  align-items: center;
  background: var(--surface-subtle);
  border: 1px solid var(--border-focus);
  border-radius: var(--radius-full);
  padding: 4px 6px 4px 14px;
  width: 100%;
  box-sizing: border-box;
  gap: 8px;
}

.mobile-search-expand input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-main);
  font-size: 0.90rem;
  font-family: inherit;
  padding: 4px 0;
}

.mobile-search-expand input::placeholder {
  color: var(--text-subtle);
}

.mobile-search-expand button {
  background: var(--brand);
  border: none;
  color: #fff;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.mobile-search-expand button:hover {
  transform: scale(1.08);
}

/* Slide-out Mobile Navigation Drawer */
.mobile-nav-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9998;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}

.mobile-nav-overlay.open {
  opacity: 1 !important;
  pointer-events: auto !important;
}

.mobile-nav-drawer {
  position: fixed;
  top: 0;
  right: -320px;
  width: 290px;
  max-width: 85vw;
  height: 100vh;
  background: var(--surface);
  border-left: 1px solid var(--border-color);
  z-index: 9999;
  box-shadow: -10px 0 35px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  overflow-y: auto;
  box-sizing: border-box;
}

.mobile-nav-drawer.open {
  transform: translateX(-320px) !important;
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-color);
  background: var(--surface-subtle);
  position: sticky;
  top: 0;
  z-index: 10;
}

.drawer-close-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  transition: all 0.2s ease;
}

.drawer-close-btn:hover {
  color: var(--text-main);
  background: var(--surface-hover);
}

.drawer-search-wrap {
  padding: 12px 14px 6px 14px;
}

.drawer-search-form {
  display: flex;
  align-items: center;
  background: var(--surface-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  padding: 4px 8px 4px 12px;
  gap: 8px;
}

.drawer-search-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-main);
  font-size: 0.84rem;
  font-family: inherit;
  padding: 4px 0;
}

.drawer-search-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.drawer-menu-list {
  list-style: none;
  padding: 10px 8px;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.drawer-menu-item a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-main);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.90rem;
  transition: all 0.2s ease;
}

.drawer-menu-item a:hover,
.drawer-menu-item a.active {
  background: var(--surface-hover);
  color: var(--brand);
}

.drawer-menu-item a .drawer-icon {
  font-size: 1.15rem;
  width: 24px;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.drawer-divider {
  height: 1px;
  background: var(--border-color);
  margin: 8px 14px;
}

.drawer-section-title {
  font-size: 0.72rem;
  text-transform: uppercase;
  color: var(--text-subtle);
  font-weight: 700;
  letter-spacing: 0.8px;
  padding: 8px 14px 4px 14px;
}

.drawer-footer {
  padding: 16px;
  border-top: 1px solid var(--border-color);
  margin-top: auto;
  font-size: 0.75rem;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.5;
}

/* Fixed Mobile Bottom Navigation Bar */
.mobile-bottom-bar {
  display: none;
}

@media (max-width: 768px) {
  body {
    padding-bottom: 64px !important;
  }

  .mobile-bottom-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100vw;
    height: 58px;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--glass-border);
    display: flex !important;
    align-items: center;
    justify-content: space-around;
    z-index: 900;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.4);
    box-sizing: border-box;
    padding: 0 4px;
  }

  .bottom-bar-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: var(--text-muted);
    font-size: 0.68rem;
    font-weight: 500;
    gap: 3px;
    flex: 1;
    padding: 6px 0;
    transition: color 0.2s ease, transform 0.2s ease;
    user-select: none;
  }

  .bottom-bar-item svg {
    width: 20px;
    height: 20px;
    stroke: currentColor;
    fill: none;
  }

  .bottom-bar-item:hover,
  .bottom-bar-item.active {
    color: var(--brand);
  }

  .bottom-bar-item.active svg {
    stroke: var(--brand);
  }
}

/* Header Responsive Breakpoints */
@media (max-width: 860px) {
  .site-header {
    padding: 8px 12px !important;
    gap: 8px !important;
  }

  .brand-logo .logo-icon-box {
    width: 32px !important;
    height: 32px !important;
  }

  .brand-logo .brand-accent {
    font-size: 1.15rem !important;
  }

  .brand-logo .brand-tld {
    font-size: 0.65rem !important;
    padding: 1px 4px !important;
  }

  /* Hide desktop search bar on mobile/tablet */
  .header-search-bar {
    display: none !important;
  }

  /* Hide desktop text links and admin pill in header */
  .header-actions .nav-text-link,
  .header-actions .admin-pill-btn {
    display: none !important;
  }

  /* Show mobile header buttons */
  .mobile-header-btn {
    display: inline-flex !important;
  }

  .header-actions {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    margin-left: auto !important;
  }

  .theme-toggle-btn {
    width: 36px !important;
    height: 36px !important;
  }
}

/* Extra small mobile screens: <= 360px (e.g. 288px) */
@media (max-width: 360px) {
  .site-header {
    padding: 6px 8px !important;
    gap: 4px !important;
  }

  .brand-logo {
    gap: 6px !important;
  }

  .brand-logo .logo-icon-box {
    width: 28px !important;
    height: 28px !important;
  }

  .brand-logo .brand-accent {
    font-size: 0.98rem !important;
  }

  .brand-logo .brand-tld {
    display: none !important;
  }

  .header-actions {
    gap: 4px !important;
  }

  .mobile-header-btn,
  .theme-toggle-btn {
    width: 32px !important;
    height: 32px !important;
    padding: 4px !important;
  }

  .mobile-header-btn svg,
  .theme-toggle-btn svg {
    width: 16px !important;
    height: 16px !important;
  }
}

/* Admin Header Mobile Responsiveness */
@media (max-width: 480px) {
  .admin-header {
    padding: 8px 12px !important;
    gap: 8px !important;
  }
  .admin-header .brand-logo {
    gap: 6px !important;
    font-size: 1rem !important;
  }
  .admin-header .logo-icon-box {
    width: 28px !important;
    height: 28px !important;
  }
  .admin-header .logo-text {
    font-size: 0.92rem !important;
  }
  .admin-header .header-actions {
    gap: 6px !important;
  }
  .admin-header .icon-btn {
    width: 32px !important;
    height: 32px !important;
  }
}

.admin-pill-btn {
  font-size: 0.82rem;
  font-weight: 600;
  font-family: var(--font-display);
  padding: 7px 15px;
  border-radius: var(--radius-full);
  background: var(--brand-subtle);
  border: 1px solid rgba(109, 92, 240, 0.35);
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
}

.admin-pill-btn:hover {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
  box-shadow: 0 4px 14px rgba(109, 92, 240, 0.45);
  transform: translateY(-1px);
}

/* ==========================================================================
   Horizontal Chips Bar (FreeVideo Category Navigation)
   ========================================================================== */
.chips-bar-wrapper {
  width: 100%;
  background-color: var(--surface);
  border-bottom: 1px solid var(--border-color);
  padding: 10px 16px;
  overflow: hidden;
}

.chips-track {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -ms-overflow-style: none;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 2px;
}

.chips-track::-webkit-scrollbar {
  display: none;
}

.chip-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  border-radius: var(--radius-full);
  background-color: var(--surface-subtle);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 500;
  font-family: var(--font-family);
  white-space: nowrap;
  cursor: pointer;
  flex-shrink: 0;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  user-select: none;
}

.chip-item:hover {
  color: var(--text-main);
  border-color: var(--border-focus);
  background-color: var(--surface-hover);
  transform: translateY(-1px);
}

.chip-item.active {
  background: linear-gradient(135deg, #6d5cf0 0%, #8b7cff 100%);
  color: #ffffff;
  font-weight: 600;
  border-color: transparent;
  box-shadow: 0 4px 16px rgba(109, 92, 240, 0.45);
}

.chip-icon {
  font-size: 0.88rem;
  line-height: 1;
}

.chip-label {
  line-height: 1;
}

/* Feed Section Title & Stats Bar */
.feed-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 14px;
  padding: 2px 2px;
}

.feed-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
}

.feed-pulse-dot {
  width: 8px;
  height: 8px;
  background: #6d5cf0;
  border-radius: 50%;
  box-shadow: 0 0 10px #6d5cf0;
  animation: pulseGlow 1.8s infinite alternate;
}

@keyframes pulseGlow {
  from {
    opacity: 0.5;
    transform: scale(0.85);
    box-shadow: 0 0 4px #6d5cf0;
  }

  to {
    opacity: 1;
    transform: scale(1.15);
    box-shadow: 0 0 14px #6d5cf0;
  }
}

.feed-heading {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.3px;
  color: var(--text-main);
}

.feed-meta-count {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-muted);
  padding: 4px 11px;
  border-radius: var(--radius-full);
  background: var(--surface-subtle);
  border: 1px solid var(--border-color);
}

/* Mobile-First 2-Column Video Grid */
.main-content {
  flex: 1;
  padding: 14px 12px;
}

.video-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  /* Strictly 2 columns on mobile */
  gap: 12px;
}

@media (min-width: 768px) {
  .video-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }
}

@media (min-width: 1024px) {
  .video-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 18px;
  }
}

/* ==========================================================================
   Video Card Aesthetics (FreeVideo High-Density Cards)
   ========================================================================== */
.video-card {
  display: flex;
  flex-direction: column;
  background-color: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform 0.22s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.22s ease, border-color 0.22s ease;
  box-shadow: var(--shadow-sm);
  position: relative;
}

.video-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5), 0 0 18px rgba(109, 92, 240, 0.16);
  border-color: rgba(109, 92, 240, 0.45);
}

.video-card:active {
  transform: scale(0.98);
}

.card-thumb-link {
  display: block;
  width: 100%;
}

.card-thumbnail-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: #000000;
  overflow: hidden;
}

.card-thumbnail {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background-color: #000000;
  transition: transform 0.35s ease;
  display: block;
}

.video-card:hover .card-thumbnail {
  transform: scale(1.05);
}

.card-play-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s ease;
  z-index: 3;
}

.video-card:hover .card-play-overlay {
  opacity: 1;
}

.play-circle-icon {
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #0f172a;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
}

/* Category Pill Badge (Top-Left) */
.card-category-tag {
  position: absolute;
  top: 6px;
  left: 6px;
  font-size: 0.62rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: 5px;
  background: rgba(10, 12, 18, 0.75);
  color: #e2e8f0;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.12);
  text-transform: uppercase;
  letter-spacing: 0.4px;
  z-index: 4;
}

/* HD / 1080p Badge (Top-Right) */
.card-hd-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  font-size: 0.60rem;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(34, 197, 94, 0.20);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.45);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  letter-spacing: 0.4px;
  z-index: 4;
}

/* Duration Badge (Bottom-Right) */
.card-duration-badge {
  position: absolute;
  bottom: 6px;
  right: 6px;
  font-size: 0.68rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 5px;
  background: rgba(0, 0, 0, 0.85);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  font-family: var(--font-display), monospace;
  letter-spacing: 0.3px;
  z-index: 4;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

/* 10-Second Hover Video Preview Layer */
.card-preview-layer {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.22s ease;
  pointer-events: none;
  z-index: 2;
  overflow: hidden;
  background: #000;
}

.card-preview-layer.active {
  opacity: 1;
}

.card-hover-video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background-color: #000;
  display: block;
  pointer-events: none;
}

.card-hover-iframe {
  width: 100%;
  height: 100%;
  border: none;
  pointer-events: none;
  object-fit: contain;
  background-color: #000;
}

/* Multi-Clip Preview Progress Bar & Badge */
.preview-progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: rgba(255, 255, 255, 0.25);
  z-index: 5;
  opacity: 0;
  transition: opacity 0.18s ease;
  pointer-events: none;
}

.preview-progress-bar.active {
  opacity: 1;
}

.preview-progress-fill {
  height: 100%;
  width: 0%;
  background: var(--brand);
  box-shadow: 0 0 6px var(--brand);
}

.preview-indicator-pill {
  position: absolute;
  top: 6px;
  right: 6px;
  background: rgba(109, 92, 240, 0.95);
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  letter-spacing: 0.3px;
  z-index: 5;
  opacity: 0;
  transition: opacity 0.18s ease;
  pointer-events: none;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.preview-indicator-pill.active {
  opacity: 1;
}

.preview-time-badge {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  background: rgba(0, 0, 0, 0.35);
  padding: 1px 4px;
  border-radius: 3px;
  font-size: 0.62rem;
}

.preview-dot {
  width: 5px;
  height: 5px;
  background: #ffffff;
  border-radius: 50%;
  animation: previewPulse 1s infinite alternate;
}

@keyframes previewPulse {
  from {
    opacity: 0.4;
    transform: scale(0.85);
  }

  to {
    opacity: 1;
    transform: scale(1.2);
  }
}

/* Card Body & Title */
.card-body {
  padding: 9px 10px 11px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.card-title-link {
  display: block;
}

.card-title {
  font-family: var(--font-family);
  font-size: 0.84rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--text-main);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 6px;
  min-height: 2.3em;
  transition: color 0.2s ease;
}

.video-card:hover .card-title {
  color: #8b7cff;
}

/* Card Metadata Row */
.card-meta {
  margin-top: auto;
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.72rem;
  color: var(--text-muted);
  flex-wrap: wrap;
}

.meta-views,
.meta-time {
  font-weight: 500;
}

.meta-dot {
  color: var(--text-subtle);
  font-weight: bold;
}

.meta-res-badge {
  font-size: 0.60rem;
  font-weight: 700;
  color: #8b7cff;
  background: rgba(109, 92, 240, 0.12);
  border: 1px solid rgba(109, 92, 240, 0.25);
  padding: 1px 4px;
  border-radius: 3px;
}

/* Skeleton Loading State */
.skeleton-card {
  border-radius: var(--radius-md);
  overflow: hidden;
  background-color: var(--surface);
  border: 1px solid var(--border-color);
}

.skeleton-thumb {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: linear-gradient(90deg, var(--surface-subtle) 25%, var(--surface-hover) 50%, var(--surface-subtle) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

.skeleton-text {
  height: 12px;
  margin: 8px 10px;
  border-radius: 4px;
  background: linear-gradient(90deg, var(--surface-subtle) 25%, var(--surface-hover) 50%, var(--surface-subtle) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

.skeleton-text.short {
  width: 50%;
}

@keyframes shimmer {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}

/* Empty State */
.empty-state {
  grid-column: 1 / -1;
  text-align: center;
  padding: 50px 20px;
  color: var(--text-muted);
}

.empty-icon {
  margin-bottom: 12px;
  color: var(--text-subtle);
}

/* Pagination Controls */
.pagination-container {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 24px 16px;
  margin-top: 10px;
}

.page-btn {
  min-width: 38px;
  height: 38px;
  padding: 0 10px;
  border-radius: var(--radius-sm);
  background-color: var(--surface);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  font-size: 0.85rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.page-btn:hover:not(:disabled) {
  background-color: var(--surface-hover);
  border-color: var(--brand);
}

.page-btn.active {
  background-color: var(--brand);
  color: #fff;
  border-color: var(--brand);
  box-shadow: 0 2px 6px rgba(99, 102, 241, 0.3);
}

.page-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* ==========================================================================
   SITE FOOTER (FreeVideo Multi-Column Navigation & Legal)
   ========================================================================== */
.site-footer {
  margin-top: 40px;
  border-top: 1px solid var(--border-color);
  background: var(--surface);
  padding: 40px 20px 24px 20px;
  color: var(--text-muted);
  font-size: 0.84rem;
}

.footer-inner-container {
  max-width: 1200px;
  margin: 0 auto;
}

.footer-columns-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 50px;
  max-width: 800px;
  margin: 0 auto 32px auto;
}

@media (max-width: 520px) {
  .footer-columns-grid {
    grid-template-columns: 1fr;
    gap: 24px;
    margin-bottom: 24px;
  }
}

.footer-col-title {
  font-family: var(--font-display);
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.footer-col-title::before {
  content: '';
  display: inline-block;
  width: 3px;
  height: 14px;
  background: var(--brand);
  border-radius: 2px;
}

.footer-links-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-links-list li a {
  color: var(--text-muted);
  text-decoration: none;
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.84rem;
}

.footer-links-list li a:hover {
  color: var(--brand);
  transform: translateX(3px);
}

.footer-badge-count {
  font-size: 0.70rem;
  background: var(--surface-subtle);
  border: 1px solid var(--border-color);
  padding: 1px 6px;
  border-radius: var(--radius-full);
  color: var(--text-subtle);
}

.footer-warning-banner {
  background: rgba(239, 68, 68, 0.06);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  margin-bottom: 24px;
  font-size: 0.80rem;
  line-height: 1.5;
  color: #f87171;
  text-align: center;
}

.footer-bottom-bar {
  border-top: 1px solid var(--border-color);
  padding-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.80rem;
}

.footer-brand-meta {
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: rgba(34, 197, 94, 0.1);
  color: #4ade80;
  border: 1px solid rgba(34, 197, 94, 0.25);
  font-size: 0.72rem;
  font-weight: 600;
}

.footer-status-dot {
  width: 6px;
  height: 6px;
  background: #22c55e;
  border-radius: 50%;
  animation: pulseGlow 1.5s infinite alternate;
}

/* ==========================================================================
   GENERAL CONTENT PAGE STYLES (About, Contact, DMCA, Privacy, Terms, Help, App)
   ========================================================================== */
.content-page-wrapper {
  max-width: 900px;
  margin: 20px auto 40px auto;
  padding: 0 16px;
}

.content-card-box {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 32px 28px;
  box-shadow: var(--shadow-sm);
}

@media (max-width: 600px) {
  .content-card-box {
    padding: 20px 16px;
  }
}

.content-header-title {
  font-family: var(--font-display);
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.5px;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.content-header-subtitle {
  color: var(--text-muted);
  font-size: 0.92rem;
  margin-bottom: 24px;
  line-height: 1.5;
}

.content-body-prose {
  color: var(--text-main);
  font-size: 0.92rem;
  line-height: 1.7;
}

.content-body-prose h2,
.content-body-prose h3 {
  font-family: var(--font-display);
  color: var(--text-main);
  margin-top: 26px;
  margin-bottom: 12px;
  font-weight: 700;
}

.content-body-prose h2 {
  font-size: 1.25rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 8px;
}

.content-body-prose p {
  margin-bottom: 16px;
  color: var(--text-muted);
}

.content-body-prose ul,
.content-body-prose ol {
  margin-left: 20px;
  margin-bottom: 18px;
  color: var(--text-muted);
}

.content-body-prose li {
  margin-bottom: 8px;
}

.highlight-box-info {
  background: rgba(109, 92, 240, 0.08);
  border: 1px solid rgba(109, 92, 240, 0.22);
  border-left: 4px solid var(--brand);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  margin: 18px 0;
  color: var(--text-main);
  font-size: 0.88rem;
}

/* Contact Form Grid */
.contact-form-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 18px;
}

@media (max-width: 650px) {
  .contact-form-layout {
    grid-template-columns: 1fr;
  }
}

.contact-form-layout .full-span {
  grid-column: 1 / -1;
}

/* Categories & Gallery Large Cards Grid */
.directory-grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 16px;
  margin-top: 20px;
}

.category-showcase-card {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  text-decoration: none;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  overflow: hidden;
}

.category-showcase-card:hover {
  background: var(--surface-hover);
  border-color: var(--brand);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(109, 92, 240, 0.18);
}

.category-card-emoji {
  font-size: 2.2rem;
  margin-bottom: 12px;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.3));
}

.category-card-name {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
}

.category-card-count {
  font-size: 0.76rem;
  color: #8b7cff;
  background: rgba(109, 92, 240, 0.12);
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-weight: 600;
  margin-top: 6px;
}

/* Photo Gallery Album Cards */
.gallery-album-card {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  text-decoration: none;
  transition: all 0.25s ease;
  display: flex;
  flex-direction: column;
}

.gallery-album-card:hover {
  border-color: var(--brand);
  transform: translateY(-3px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.4);
}

.album-cover-box {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: #000;
  overflow: hidden;
  position: relative;
}

.album-cover-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.gallery-album-card:hover .album-cover-img {
  transform: scale(1.05);
}

.album-photos-badge {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 4px;
}

.album-info-box {
  padding: 14px;
}

.album-title {
  font-family: var(--font-display);
  font-size: 0.96rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
  line-height: 1.35;
}

.album-category-tag {
  font-size: 0.74rem;
  color: var(--text-muted);
}

/* Models / Actors Directory */
.model-profile-card {
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px 16px;
  text-align: center;
  text-decoration: none;
  transition: all 0.25s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.model-profile-card:hover {
  border-color: var(--brand);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(109, 92, 240, 0.2);
}

.model-avatar {
  width: 90px;
  height: 90px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--brand);
  margin-bottom: 12px;
  box-shadow: 0 4px 12px rgba(109, 92, 240, 0.3);
}

.model-name {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 4px;
}

.model-meta-stats {
  display: flex;
  gap: 8px;
  font-size: 0.76rem;
  color: var(--text-muted);
  margin-top: 6px;
}

.model-stat-pill {
  background: var(--surface-subtle);
  padding: 2px 8px;
  border-radius: var(--radius-full);
}

/* Top Searches Tag Cloud */
.top-search-item-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border-bottom: 1px solid var(--border-color);
  text-decoration: none;
  color: var(--text-main);
  transition: all 0.2s ease;
}

.top-search-item-row:hover {
  background: var(--surface-subtle);
  padding-left: 20px;
}

.search-rank-number {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
  color: var(--brand);
  width: 32px;
}

.search-term-title {
  font-weight: 600;
  font-size: 0.92rem;
  flex: 1;
}

.search-trend-indicator {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.76rem;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: rgba(34, 197, 94, 0.1);
  color: #4ade80;
  font-weight: 600;
}

/* App Download Landing Section */
.app-download-hero {
  background: linear-gradient(145deg, rgba(109, 92, 240, 0.15) 0%, rgba(9, 11, 16, 0.8) 100%);
  border: 1px solid rgba(109, 92, 240, 0.3);
  border-radius: var(--radius-lg);
  padding: 36px 30px;
  text-align: center;
  margin-bottom: 30px;
}

.app-version-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--brand);
  color: #fff;
  font-size: 0.76rem;
  font-weight: 700;
  padding: 3px 12px;
  border-radius: var(--radius-full);
  margin-bottom: 16px;
}

.app-big-download-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 14px 32px;
  background: linear-gradient(135deg, #6d5cf0 0%, #8b7cff 100%);
  color: #ffffff;
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  border-radius: var(--radius-full);
  text-decoration: none;
  box-shadow: 0 8px 24px rgba(109, 92, 240, 0.4);
  transition: all 0.25s ease;
  margin-top: 14px;
}

.app-big-download-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(109, 92, 240, 0.55);
}

/* Playback Help Accordion/List */
.help-faq-card {
  background: var(--surface-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 16px 20px;
  margin-bottom: 12px;
}

.help-faq-question {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.help-faq-answer {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.6;
}

/* ==========================================================================
   VIDEO DETAIL PAGE STYLES (FreeVideo Theater Layout)
   ========================================================================== */
.player-page-container {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Header Search Form on Video Page */
.header-search-bar {
  display: flex;
  align-items: center;
  background: var(--surface-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-full);
  padding: 4px 6px 4px 14px;
  max-width: 440px;
  width: 100%;
  margin: 0 16px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.header-search-bar:focus-within {
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(109, 92, 240, 0.2);
  background: var(--surface);
}

.header-search-input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text-main);
  font-size: 0.85rem;
  width: 100%;
  font-family: inherit;
}

.header-search-input::placeholder {
  color: var(--text-subtle);
}

.header-search-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px;
  border-radius: 50%;
  transition: color 0.2s ease, transform 0.2s ease;
}

.header-search-btn:hover {
  color: var(--brand);
  transform: scale(1.08);
}

.nav-text-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  font-size: 0.84rem;
  font-weight: 600;
  text-decoration: none;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
}

.nav-text-link:hover {
  color: var(--text-main);
  background: var(--surface-subtle);
}

/* Notice / Daily Update Banner (Screenshot 2) */
.site-notice-banner {
  background: rgba(109, 92, 240, 0.08);
  border-bottom: 1px solid rgba(109, 92, 240, 0.16);
  padding: 9px 18px;
  font-size: 0.82rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  text-align: center;
  letter-spacing: -0.1px;
}

.site-notice-banner strong {
  color: var(--text-main);
}

.notice-icon {
  font-size: 0.95rem;
}

/* 1. Video Headline Section (Placed Above Video Player - Screenshot 2) */
.video-headline-section {
  margin-top: 8px;
  margin-bottom: 4px;
}

.video-headline-title {
  font-family: var(--font-display);
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.3px;
  line-height: 1.35;
  margin-bottom: 8px;
}

.video-headline-meta {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 0.82rem;
  color: var(--text-muted);
}

.video-headline-meta .meta-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-weight: 500;
}

.meta-category-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #8b7cff;
  background: rgba(109, 92, 240, 0.12);
  border: 1px solid rgba(109, 92, 240, 0.25);
  padding: 3px 12px;
  border-radius: var(--radius-full);
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.meta-category-badge:hover {
  background: var(--brand);
  color: #ffffff;
  border-color: var(--brand);
}

/* 2. Video Player Frame Box (Hero Splash + Contain Black Letterboxing) */
.video-player-frame-box {
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: #000000;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.65);
}

.video-player-frame-box iframe,
.video-player-frame-box video {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
  object-fit: contain !important;
  background-color: #000000;
}

/* 3. Action Buttons Bar (Directly Below Player - Screenshot 1) */
.video-actions-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 4px 0 2px 0;
}

.actions-left,
.actions-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.action-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 16px;
  border-radius: var(--radius-sm);
  background-color: var(--surface-subtle);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  font-size: 0.84rem;
  font-weight: 600;
  font-family: var(--font-display);
  cursor: pointer;
  text-decoration: none;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.action-btn:hover {
  background-color: var(--surface-hover);
  border-color: var(--brand);
  transform: translateY(-1px);
}

.action-btn.like-pill-btn.liked {
  color: #f43f5e;
  background-color: rgba(244, 63, 94, 0.15);
  border-color: rgba(244, 63, 94, 0.45);
  box-shadow: 0 2px 10px rgba(244, 63, 94, 0.25);
}

.action-btn.like-pill-btn.liked .heart-icon {
  fill: #f43f5e;
  stroke: #f43f5e;
  animation: heartBeat 0.35s ease;
}

/* 4. FreeVideo Technical Specifications Bar (Screenshot 1) */
.video-specs-bar {
  background-color: var(--surface-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 12px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 4px;
  margin-bottom: 6px;
}

.spec-stat-item {
  display: flex;
  align-items: baseline;
  gap: 6px;
  font-size: 0.82rem;
}

.spec-label {
  color: var(--text-muted);
  font-size: 0.74rem;
  font-weight: 500;
  text-transform: capitalize;
}

.spec-value {
  color: var(--text-main);
  font-weight: 700;
  font-family: var(--font-display), monospace;
  font-size: 0.84rem;
}

/* 5. FreeVideo "You may also like" Tags Bar (Screenshot 1) */
.video-tags-bar {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  background-color: rgba(109, 92, 240, 0.06);
  border: 1px solid rgba(109, 92, 240, 0.18);
  border-left: 4px solid var(--brand);
  border-radius: var(--radius-sm);
  padding: 10px 16px;
  margin-bottom: 8px;
}

.tags-bar-title {
  color: var(--text-main);
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
  font-family: var(--font-display);
}

.tags-pills-container {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.tag-pill-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  background: var(--surface);
  border: 1px solid rgba(109, 92, 240, 0.25);
  color: #8b7cff;
  font-size: 0.78rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}

.tag-pill-btn:hover {
  background: var(--brand);
  color: #ffffff;
  border-color: var(--brand);
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(109, 92, 240, 0.35);
}

.tag-pill-count {
  font-size: 0.68rem;
  color: var(--text-muted);
  background: rgba(255, 255, 255, 0.08);
  padding: 1px 6px;
  border-radius: var(--radius-full);
  font-weight: 500;
}

.tag-pill-btn:hover .tag-pill-count {
  color: #ffffff;
  background: rgba(0, 0, 0, 0.35);
}

/* 6. Video Description Box */
.video-description-box {
  background-color: var(--surface-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  font-size: 0.88rem;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--text-main);
}

/* 7. Related Videos Section (Screenshot 1: | ☷ Related Videos) */
.suggested-videos-section {
  margin-top: 20px;
}

.section-title-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
}

.title-accent-bar {
  width: 4px;
  height: 18px;
  background: var(--brand);
  border-radius: 2px;
}

.grid-icon {
  stroke: var(--brand);
  width: 18px;
  height: 18px;
}

.section-title-text {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-main);
  letter-spacing: -0.2px;
}

.player-icon-btn.active {
  color: var(--brand) !important;
  background-color: rgba(109, 92, 240, 0.25) !important;
}

/* ==========================================================================
   ADMIN PANEL & ANALYTICS DASHBOARD
   ========================================================================== */
.admin-card {
  background-color: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 22px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 24px;
}

/* ==========================================================================
   Admin Navigation Header & Layout
   ========================================================================== */
.admin-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  padding: 12px 20px;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: 16px;
  box-shadow: var(--shadow-sm);
}

.admin-header .brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.admin-header .header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto !important;
}

.admin-header-title {
  font-size: 1.25rem;
  font-weight: 800;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* Admin Subnavigation Tabs */
.admin-subnav {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background-color: var(--surface);
  border-bottom: 1px solid var(--border-color);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.subnav-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  background-color: var(--surface-subtle);
  border: 1px solid var(--border-color);
  white-space: nowrap;
  transition: all 0.2s ease;
}

.subnav-link:hover {
  color: var(--text-main);
  background-color: var(--surface-hover);
  border-color: var(--brand);
}

.subnav-link.active {
  background-color: var(--brand);
  color: #ffffff;
  border-color: var(--brand);
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

/* Analytics Stats Grid */
.analytics-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}

@media (min-width: 768px) {
  .analytics-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
  }
}

.stat-card {
  background-color: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s ease, border-color 0.2s ease;
}

.stat-card:hover {
  transform: translateY(-2px);
  border-color: var(--brand);
}

.stat-card-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.stat-card-icon.blue {
  background: rgba(99, 102, 241, 0.12);
  color: var(--brand);
}

.stat-card-icon.green {
  background: rgba(16, 185, 129, 0.12);
  color: var(--success);
}

.stat-card-icon.rose {
  background: rgba(244, 63, 94, 0.12);
  color: var(--accent);
}

.stat-card-icon.purple {
  background: rgba(168, 85, 247, 0.12);
  color: #a855f7;
}

.stat-card-info {
  display: flex;
  flex-direction: column;
}

.stat-card-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: var(--text-muted);
}

.stat-card-value {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
  margin-top: 2px;
}

/* Forms */
.form-group {
  margin-bottom: 16px;
}

.form-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 6px;
}

.input-with-icon {
  position: relative;
  width: 100%;
}

.input-with-icon .input-icon-slot {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  display: flex;
  pointer-events: none;
}

.input-with-icon .form-input {
  padding-left: 42px;
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: 10px 14px;
  background-color: var(--surface-subtle);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-main);
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--border-focus);
  background-color: var(--surface);
  box-shadow: 0 0 0 3px var(--brand-subtle);
}

.form-textarea {
  resize: vertical;
  min-height: 80px;
}

/* Live Video Preview Box */
.live-preview-box {
  margin-top: 12px;
  border: 1.5px dashed var(--brand);
  border-radius: var(--radius-md);
  padding: 12px;
  background-color: var(--surface-subtle);
  display: none;
}

.live-preview-box.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

.preview-badge {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--brand);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
}

.preview-player-wrapper {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: #000;
}

.preview-player-wrapper iframe,
.preview-player-wrapper video {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

/* Scraped JSON Upload / Import Dropzone */
.json-import-box {
  background: var(--surface-subtle);
  border: 2px dashed rgba(109, 92, 240, 0.45);
  border-radius: var(--radius-md);
  padding: 14px 18px;
  margin-bottom: 22px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
}

.json-import-box:hover,
.json-import-box.dragover {
  border-color: #6d5cf0;
  background: rgba(109, 92, 240, 0.08);
  box-shadow: 0 4px 18px rgba(109, 92, 240, 0.16);
}

.json-import-content {
  display: flex;
  align-items: center;
  gap: 14px;
}

.json-icon-box {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  background: rgba(109, 92, 240, 0.14);
  border: 1px solid rgba(109, 92, 240, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #6d5cf0;
  flex-shrink: 0;
}

.json-import-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.json-import-text strong {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--text-main);
}

.json-import-text span {
  font-size: 0.74rem;
  color: var(--text-muted);
}

.btn-import-pill {
  padding: 8px 16px;
  border-radius: var(--radius-full);
  background: #6d5cf0;
  color: #ffffff;
  font-size: 0.80rem;
  font-weight: 600;
  font-family: var(--font-display);
  border: none;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(109, 92, 240, 0.35);
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.btn-import-pill:hover {
  background: #8b7cff;
  transform: translateY(-1px);
}

/* Thumbnail Dropzone */
.upload-dropzone {
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-md);
  padding: 24px;
  text-align: center;
  cursor: pointer;
  background-color: var(--surface-subtle);
  transition: all 0.2s ease;
}

.upload-dropzone:hover {
  border-color: var(--brand);
  background-color: var(--surface);
}

.thumb-preview-img {
  max-width: 100%;
  max-height: 180px;
  border-radius: var(--radius-sm);
  margin-top: 10px;
  display: none;
  object-fit: contain;
  background-color: #000;
  box-shadow: var(--shadow-sm);
}

.primary-btn {
  width: 100%;
  padding: 12px 20px;
  background: linear-gradient(135deg, var(--brand), #4338ca);
  color: #ffffff;
  font-weight: 700;
  font-size: 0.92rem;
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.primary-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(99, 102, 241, 0.45);
}

.primary-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Admin Table */
.video-table-wrapper {
  overflow-x: auto;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
}

.video-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  text-align: left;
}

.video-table th {
  background-color: var(--surface-subtle);
  padding: 12px 14px;
  font-weight: 700;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-color);
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.video-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border-color);
  vertical-align: middle;
}

.video-table tr:last-child td {
  border-bottom: none;
}

.video-table tr:hover td {
  background-color: var(--surface-hover);
}

.table-thumb {
  width: 58px;
  height: 36px;
  object-fit: contain;
  background-color: #000;
  border-radius: var(--radius-xs);
  display: block;
}

.table-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.action-btn-sm {
  padding: 5px 10px;
  border-radius: var(--radius-xs);
  font-size: 0.78rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  border: 1px solid transparent;
  transition: all 0.15s ease;
}

.action-btn-sm.view {
  background: var(--surface-subtle);
  color: var(--text-main);
  border-color: var(--border-color);
}

.action-btn-sm.view:hover {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}

.action-btn-sm.delete {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
  border-color: rgba(239, 68, 68, 0.25);
}

.action-btn-sm.delete:hover {
  background: #ef4444;
  color: #fff;
}

/* Toast Container */
.toast-container {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 100;
  display: flex;
  flex-direction: column;
  gap: 8px;
  pointer-events: none;
}

.toast {
  padding: 10px 18px;
  border-radius: var(--radius-full);
  background: var(--surface);
  color: var(--text-main);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
  font-size: 0.85rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  animation: toastIn 0.25s ease forwards;
  pointer-events: auto;
}

.toast.success {
  border-color: var(--success);
  color: var(--success);
}

.toast.error {
  border-color: var(--accent);
  color: var(--accent);
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

/* ==========================================================================
   ADVANCED CUSTOM VIDEO PLAYER STYLES
   Double-tap 10s seek, ripple animations, time counter, and speed controller
   ========================================================================== */

.custom-player-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background-color: #000;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  user-select: none;
}

.custom-player-video,
.custom-player-wrapper iframe {
  width: 100%;
  height: 100%;
  display: block;
  border: none;
  object-fit: contain;
}

/* Hero Thumbnail Poster Splash Overlay */
.player-poster-splash {
  position: absolute;
  inset: 0;
  background-size: contain;
  background-position: center;
  background-repeat: no-repeat;
  background-color: #000000;
  z-index: 30;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.35s ease, transform 0.35s ease;
}

.player-poster-splash::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: inherit;
  background-size: cover;
  background-position: center;
  filter: blur(28px) brightness(0.35);
  opacity: 0.55;
  z-index: 1;
}

.player-poster-splash.fade-out {
  opacity: 0;
  pointer-events: none;
  transform: scale(1.03);
}

.poster-backdrop-gradient {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at center, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.65) 100%);
  z-index: 2;
}

.poster-hero-content {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
  padding: 20px;
}

.hero-play-pulse-btn {
  width: 74px;
  height: 74px;
  background: var(--brand);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.7), 0 8px 24px rgba(0, 0, 0, 0.5);
  animation: heroPulseGlow 2s infinite;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), background-color 0.2s ease;
}

.hero-play-pulse-btn svg {
  width: 32px;
  height: 32px;
  margin-left: 4px;
  fill: currentColor;
  stroke: none;
}

.player-poster-splash:hover .hero-play-pulse-btn {
  transform: scale(1.12);
  background: var(--brand-hover);
}

@keyframes heroPulseGlow {
  0% {
    box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.7), 0 8px 24px rgba(0, 0, 0, 0.5);
  }

  70% {
    box-shadow: 0 0 0 18px rgba(99, 102, 241, 0), 0 8px 24px rgba(0, 0, 0, 0.5);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(99, 102, 241, 0), 0 8px 24px rgba(0, 0, 0, 0.5);
  }
}

.poster-video-title {
  color: #ffffff;
  font-size: 1.15rem;
  font-weight: 700;
  max-width: 480px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.poster-meta-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  background: rgba(15, 23, 42, 0.75);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #e2e8f0;
  font-size: 0.78rem;
  font-weight: 600;
  backdrop-filter: blur(6px);
}

.poster-meta-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--brand);
}

/* Scrubber Hover Tooltip with Frame Preview */
.scrubber-hover-tooltip {
  position: absolute;
  bottom: 22px;
  transform: translateX(-50%) translateY(4px);
  background: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius-sm);
  padding: 5px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.15s ease, transform 0.15s ease;
  z-index: 35;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.scrubber-hover-tooltip.visible {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

.scrubber-preview-frame {
  width: 120px;
  aspect-ratio: 16 / 9;
  border-radius: 4px;
  overflow: hidden;
  background: #000;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.scrubber-preview-frame img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background-color: #000;
  display: block;
}

.scrubber-hover-time-bubble {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.72rem;
  font-weight: 700;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  color: #ffffff;
}

.scrubber-hover-time-bubble svg {
  color: var(--brand);
}

/* Auto-hide controls bar when user is idle */
.custom-player-wrapper.controls-idle .player-controls-overlay {
  opacity: 0;
  pointer-events: none;
}

.custom-player-wrapper.controls-idle {
  cursor: none;
}

/* Double-Click Gesture Touch Zones */
.gesture-zone-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  pointer-events: auto;
  z-index: 10;
}

.gesture-zone {
  flex: 1;
  height: 100%;
  cursor: pointer;
  position: relative;
}

.gesture-zone.left {
  cursor: default;
}

.gesture-zone.center {
  flex: 0.8;
}

.gesture-zone.right {
  cursor: default;
}

/* Double Click / Tap Ripple Indicators */
.seek-ripple-indicator {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: rgba(17, 24, 39, 0.85);
  backdrop-filter: blur(8px);
  border: 1.5px solid rgba(255, 255, 255, 0.2);
  color: #ffffff;
  padding: 18px 24px;
  border-radius: 50%;
  width: 90px;
  height: 90px;
  opacity: 0;
  pointer-events: none;
  transition: transform 0.2s ease, opacity 0.2s ease;
  z-index: 20;
}

.seek-ripple-indicator.left {
  left: 12%;
}

.seek-ripple-indicator.right {
  right: 12%;
}

.seek-ripple-indicator.active {
  opacity: 1;
  animation: seekPulse 0.5s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.seek-ripple-text {
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.5px;
}

@keyframes seekPulse {
  0% {
    transform: translateY(-50%) scale(0.6);
    opacity: 0;
  }

  50% {
    transform: translateY(-50%) scale(1.1);
    opacity: 1;
  }

  100% {
    transform: translateY(-50%) scale(1);
    opacity: 0;
  }
}

/* Custom Controls Bar */
.player-controls-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px 14px 10px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.9) 0%, rgba(0, 0, 0, 0.4) 60%, transparent 100%);
  z-index: 25;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: opacity 0.3s ease;
}

.custom-player-wrapper:hover .player-controls-overlay,
.player-controls-overlay.active {
  opacity: 1;
}

/* Scrubbable Progress Bar */
.progress-bar-container {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.25);
  border-radius: 4px;
  cursor: pointer;
  position: relative;
  transition: height 0.15s ease;
}

.progress-bar-container:hover {
  height: 8px;
}

.progress-buffered-bar {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  background: rgba(255, 255, 255, 0.4);
  border-radius: 4px;
  width: 0%;
}

.progress-current-bar {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  background: var(--brand);
  border-radius: 4px;
  width: 0%;
  transition: width 0.05s linear;
}

.progress-thumb-scrubber {
  position: absolute;
  right: -5px;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  background: #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 6px rgba(0, 0, 0, 0.5);
}

/* Controls Buttons Row */
.controls-buttons-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.controls-left-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.controls-right-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.player-icon-btn {
  color: #ffffff;
  cursor: pointer;
  padding: 4px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.15s ease, color 0.15s ease;
  background: transparent;
  border: none;
}

.player-icon-btn:hover {
  transform: scale(1.15);
  color: var(--brand);
}

/* Time Counter Display */
.player-time-counter {
  font-size: 0.82rem;
  font-weight: 700;
  color: #e2e8f0;
  font-family: monospace;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  gap: 3px;
}

/* Playback Speed Controller */
.speed-control-wrapper {
  position: relative;
}

.speed-badge-btn {
  padding: 3px 8px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.3);
  color: #ffffff;
  border-radius: var(--radius-xs);
  font-size: 0.75rem;
  font-weight: 800;
  cursor: pointer;
  transition: all 0.15s ease;
}

.speed-badge-btn:hover {
  background: var(--brand);
  border-color: var(--brand);
}

.speed-options-menu {
  position: absolute;
  bottom: 30px;
  right: 0;
  background: #111827;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: var(--radius-sm);
  padding: 6px;
  display: none;
  flex-direction: column;
  gap: 4px;
  box-shadow: var(--shadow-lg);
  z-index: 30;
  min-width: 90px;
}

.speed-options-menu.open {
  display: flex;
  animation: fadeIn 0.15s ease;
}

.speed-opt-btn {
  padding: 5px 8px;
  font-size: 0.75rem;
  font-weight: 700;
  color: #e2e8f0;
  border-radius: 4px;
  text-align: left;
  background: transparent;
  border: none;
  cursor: pointer;
}

.speed-opt-btn:hover,
.speed-opt-btn.active {
  background: var(--brand);
  color: #ffffff;
}

/* Volume Slider */
.volume-control-box {
  display: flex;
  align-items: center;
  gap: 6px;
}

.volume-slider {
  width: 60px;
  height: 4px;
  accent-color: var(--brand);
  cursor: pointer;
}

/* ==========================================================================
   Admin Edit Video Modal & Actions
   ========================================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.68);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1050;
  padding: 16px;
  animation: modalFadeIn 0.2s ease-out;
}

@keyframes modalFadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

.modal-card {
  width: 100%;
  max-width: 580px;
  max-height: 90vh;
  overflow-y: auto;
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  animation: modalSlideUp 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalSlideUp {
  from {
    transform: translateY(20px) scale(0.97);
    opacity: 0;
  }

  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

.modal-header {
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.action-btn-sm.edit {
  background: rgba(245, 158, 11, 0.12);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.25);
}

.action-btn-sm.edit:hover {
  background: #f59e0b;
  color: #ffffff;
}

/* ==========================================================================
   ADMIN LOGIN OVERLAY & STRICT AUTH GUARD
   ========================================================================== */
.admin-login-overlay {
  position: fixed;
  inset: 0;
  background: var(--bg-page);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  padding: 20px;
}

.admin-login-box {
  width: 100%;
  max-width: 420px;
  background: var(--surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 36px 30px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.7);
  text-align: center;
  animation: modalSlideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.admin-login-title {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 6px;
}

.admin-login-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 24px;
  line-height: 1.5;
}

/* Strict Admin Locked state: Disallows viewing admin layout without login */
html.admin-locked .admin-layout,
html.admin-locked .app-container {
  display: none !important;
}

.admin-layout.unverified {
  display: none !important;
}
