/*
 * Teachings Page v2 - Apple Music/Radio Inspired Design
 * Premium UI with JSON-driven content
 * Hadassa Ebenezer Ministries
 */

/* ============================================
   CSS CUSTOM PROPERTIES
   ============================================ */

:root {
  /* Typography */
  --font-display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", system-ui, sans-serif;
  --font-text: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", system-ui, sans-serif;

  /* Colors - Light Theme */
  --bg-primary: #FFFFFF;
  --bg-secondary: #F5F5F7;
  --bg-tertiary: #E8E8ED;
  --bg-elevated: #FFFFFF;

  --text-primary: #000000;
  --text-secondary: #6E6E73;
  --text-tertiary: #86868B;

  /* Accent Colors */
  --accent-primary: #ff0d00;
  /* Apple Music Red */
  --accent-secondary: #FF9500;
  /* Orange */
  --accent-gold: #FFD60A;
  /* Gold */
  --accent-blue: #0A84FF;
  /* Blue */

  /* Brand Colors */
  --brand-primary: #004799;
  --brand-secondary: #ffbf00;

  /* Gradients */
  --gradient-hero: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 0, 0, 0.8) 100%);
  --gradient-card: linear-gradient(180deg, rgba(0, 0, 0, 0.2) 0%, rgba(0, 0, 0, 0.9) 100%);

  /* Spacing */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 16px;
  --space-lg: 24px;
  --space-xl: 32px;
  --space-2xl: 48px;
  --space-3xl: 64px;

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 16px 48px rgba(0, 0, 0, 0.6);

  /* Transitions */
  --transition-fast: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.5s cubic-bezier(0.4, 0, 0.2, 1);

  /* Layout */
  --container-max: 1440px;
  --sidebar-width: 240px;
}

/* ============================================
   BASE STYLES
   ============================================ */

body.teachings-page {
  background-color: var(--bg-primary);
  color: var(--text-primary);
  font-family: var(--font-text);
  line-height: 1.6;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
}

html {
  overflow-x: hidden;
  width: 100%;
}

/* ============================================
   HERO SECTION - Large Featured Content
   ============================================ */

.hero-v2 {
  position: relative;
  height: clamp(500px, 80vh, 800px);
  overflow: hidden;
  border-radius: 0;
}

.hero-v2-background {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.hero-v2-background img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.7);
}

.hero-v2-gradient {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--gradient-hero);
  z-index: 2;
}

.hero-v2-content {
  position: relative;
  z-index: 3;
  height: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-2xl);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding-bottom: var(--space-3xl);
}

.hero-v2-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-xs) var(--space-md);
  background: var(--accent-primary);
  color: var(--bg-primary);
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: var(--space-md);
  width: fit-content;
}

.hero-v2-badge i {
  font-size: 0.6rem;
  animation: pulse 2s infinite;
}

.hero-v2-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 6vw, 5rem);
  color: var(--bg-primary);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: var(--space-md);
  letter-spacing: -0.03em;
  max-width: 900px;
}

.hero-v2-meta {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: var(--space-lg);
  flex-wrap: wrap;
}

.hero-v2-meta-item {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
}

.hero-v2-description {
  font-size: clamp(1rem, 1.5vw, 1.25rem);
  line-height: 1.5;
  color: var(--bg-tertiary);
  max-width: 700px;
  margin-bottom: var(--space-xl);
}

.hero-v2-actions {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.btn-primary-v2 {
  display: inline-flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-xl);
  background-color: var(--text-primary);
  color: var(--bg-primary);
  font-size: 1rem;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-xl);
  cursor: pointer;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-md);
}

.btn-primary-v2:hover {
  transform: scale(1.05);
  box-shadow: var(--shadow-lg);
}

.btn-secondary-v2 {
  display: inline-flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-xl);
  background-color: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(20px);
  color: var(--text-primary);
  font-size: 1rem;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-xl);
  cursor: pointer;
  transition: all var(--transition-base);
}

.btn-secondary-v2:hover {
  background-color: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.4);
}

/* ============================================
   LIVE BANNER
   ============================================ */

.live-banner-v2 {
  background: linear-gradient(145deg, #ff0000 40%, #ffffff 100%);
  padding: var(--space-lg);
  margin: var(--space-2xl) auto;
  max-width: var(--container-max);
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: space-between;
  box-shadow: var(--shadow-sm);
  cursor: pointer;
  transition: transform var(--transition-base);
}

.live-banner-v2:hover {
  transform: translateY(-4px);
}

.live-banner-info {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.live-pulse {
  width: 12px;
  height: 12px;
  background-color: white;
  border-radius: 50%;
  animation: pulse 2s infinite;
}

.live-banner-text h3 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 var(--space-xs) 0;
}

.live-banner-text p {
  margin: 0;
  opacity: 0.9;
}

.live-banner-action {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  background-color: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-md);
  font-weight: 600;
}

/* ============================================
   SECTION HEADERS
   ============================================ */

.section-v2 {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: var(--space-3xl) var(--space-2xl);
  overflow: hidden;
  width: 100%;
  box-sizing: border-box;
}

.section-header-v2 {
  margin-bottom: var(--space-xl);
}

.section-title-v2 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 700;
  margin-bottom: var(--space-sm);
  letter-spacing: -0.02em;
}

.section-subtitle-v2 {
  font-size: 1.125rem;
  color: var(--text-tertiary);
  font-weight: 400;
}

/* ============================================
   LARGE CARDS - Featured Style
   ============================================ */

.large-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(400px, 100%), 1fr));
  gap: var(--space-xl);
  width: 100%;
}

.large-card {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-lg);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-md);
}

.large-card:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-xl);
}

.large-card-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.large-card:hover .large-card-image {
  transform: scale(1.05);
}

.large-card-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: var(--gradient-card);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--space-lg);
  opacity: 1;
  transition: opacity var(--transition-base);
}

.large-card-badge {
  position: absolute;
  top: var(--space-md);
  right: var(--space-md);
  padding: var(--space-xs) var(--space-md);
  color: var(--bg-primary);
  background-color: var(--accent-primary);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.large-card-title {
  color: #ffffff00;
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  font-weight: 700;
  margin-bottom: var(--space-sm);
  line-height: 1.3;
}

.large-card-meta {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  font-size: 0.875rem;
  color: #00000000;
  margin-bottom: var(--space-sm);
}

.large-card-description {
  font-size: 0.95rem;
  color: #00000000;
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.large-card-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  background-color: rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-lg);
}

.large-card:hover .large-card-play {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.1);
}

.large-card-play i {
  color: var(--text-primary);
  font-size: 2rem;
  margin-left: 4px;
}

/* ============================================
   MEDIUM CARDS - Carousel Style
   ============================================ */

.carousel-v2 {
  position: relative;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

.carousel-v2-track {
  display: flex;
  gap: var(--space-lg);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  scroll-behavior: smooth;
  padding-bottom: var(--space-md);
}

.carousel-v2-track::-webkit-scrollbar {
  display: none;
}

.medium-card {
  flex: 0 0 clamp(280px, 30vw, 380px);
  scroll-snap-align: start;
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition-base);
  background-color: var(--bg-secondary);
}

.medium-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
}

.medium-card-thumbnail {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  position: relative;
}

.medium-card-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.medium-card:hover .medium-card-thumbnail img {
  transform: scale(1.08);
}

.medium-card-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  background-color: rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: all var(--transition-base);
}

.medium-card:hover .medium-card-play {
  opacity: 1;
}

.medium-card-play i {
  color: var(--bg-primary);
  font-size: 1.5rem;
  margin-left: 3px;
}

.medium-card-content {
  padding: var(--space-md);
}

.medium-card-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.medium-card-meta {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  font-size: 0.875rem;
  color: var(--text-tertiary);
}

/* ============================================
   COMPACT LIST - Minimal Style
   ============================================ */

.compact-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.compact-item {
  display: flex;
  align-items: center;
  gap: var(--space-lg);
  padding: var(--space-md);
  background-color: var(--bg-secondary);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-base);
}

.compact-item:hover {
  background-color: var(--bg-tertiary);
  transform: translateX(8px);
}

.compact-item-thumbnail {
  flex-shrink: 0;
  width: 120px;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-sm);
  overflow: hidden;
  position: relative;
}

.compact-item-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.compact-item-play {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 40px;
  height: 40px;
  background-color: rgba(255, 255, 255, 0.95);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-base);
}

.compact-item:hover .compact-item-play {
  opacity: 1;
}

.compact-item-play i {
  color: var(--bg-primary);
  font-size: 1rem;
  margin-left: 2px;
}

.compact-item-info {
  flex-grow: 1;
}

.compact-item-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
}

.compact-item-meta {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  font-size: 0.875rem;
  color: var(--text-tertiary);
}

.compact-item-duration {
  flex-shrink: 0;
  font-size: 0.875rem;
  color: var(--text-tertiary);
  font-weight: 500;
}

/* ============================================
   GRID LAYOUT - All Content
   ============================================ */

.grid-v2 {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(280px, 100%), 1fr));
  gap: var(--space-xl);
  width: 100%;
}

.grid-card {
  background-color: var(--bg-secondary);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition-base);
}

.grid-card:hover {
  background-color: var(--bg-tertiary);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.grid-card-thumbnail {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  position: relative;
}

.grid-card-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

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

.grid-card-content {
  padding: var(--space-md);
}

.grid-card-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.grid-card-meta {
  font-size: 0.875rem;
  color: var(--text-tertiary);
}

/* ============================================
   VIDEO MODAL - Improved
   ============================================ */

.modal-v2 {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.95);
  backdrop-filter: blur(20px);
  z-index: 10000;
  padding: var(--space-2xl);
}

.modal-v2.active {
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.3s ease-out;
}

.modal-v2-content {
  position: relative;
  width: 100%;
  max-width: 1400px;
  aspect-ratio: 16 / 9;
  animation: slideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-v2-close {
  position: absolute;
  top: -60px;
  right: 0;
  width: 44px;
  height: 44px;
  background-color: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border: none;
  border-radius: 50%;
  color: white;
  font-size: 1.25rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
}

.modal-v2-close:hover {
  background-color: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

.modal-v2-iframe {
  width: 100%;
  height: 100%;
  border: none;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
}

/* ============================================
   LOADING SKELETON
   ============================================ */

.skeleton-v2 {
  background: linear-gradient(90deg,
      var(--bg-secondary) 25%,
      var(--bg-tertiary) 50%,
      var(--bg-secondary) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-md);
}

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

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

/* ============================================
   ANIMATIONS
   ============================================ */

@keyframes fadeIn {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(40px) scale(0.95);
  }

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

@keyframes pulse {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.5;
    transform: scale(1.2);
  }
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 1024px) {
  .hero-v2 {
    height: clamp(400px, 60vh, 600px);
  }

  .large-cards-grid {
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  }

  .section-v2 {
    padding: var(--space-2xl) var(--space-lg);
  }
}

@media (max-width: 768px) {
  .hero-v2 {
    margin-top: 50px;
    height: 500px;
  }

  .hero-v2-content {
    padding: 0 var(--space-lg);
    padding-bottom: var(--space-2xl);
  }

  .hero-v2-title {
    font-size: 2rem;
  }

  .large-cards-grid {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }

  .grid-v2 {
    grid-template-columns: 1fr;
    gap: var(--space-lg);
  }

  .compact-item {
    flex-direction: column;
    align-items: flex-start;
  }

  .compact-item-thumbnail {
    width: 100%;
  }

  .modal-v2 {
    padding: var(--space-lg);
  }

  .modal-v2-close {
    top: -50px;
    width: 40px;
    height: 40px;
  }

  .live-banner-v2 {
    flex-direction: column;
    text-align: center;
    gap: var(--space-lg);
    margin: var(--space-lg) var(--space-md);
  }

  .section-v2 {
    padding: var(--space-2xl) var(--space-md);
  }

  .carousel-v2-track {
    padding-right: var(--space-md);
  }
}

@media (max-width: 480px) {
  .section-v2 {
    padding: var(--space-xl) var(--space-md);
  }

  .hero-v2-actions {
    flex-direction: column;
    width: 100%;
  }

  .btn-primary-v2,
  .btn-secondary-v2 {
    width: 100%;
    justify-content: center;
  }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */

*:focus-visible {
  outline: 2px solid var(--accent-blue);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* ============================================
   SEARCH & FILTER BAR - Apple Style
   ============================================ */

.search-filter-bar {
  position: sticky;
  top: 80px;
  z-index: 100;
  background: rgba(255, 255, 255, 0.8);
  backdrop-filter: blur(20px) saturate(180%);
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  padding: var(--space-md) 0;
  margin-bottom: var(--space-xl);
  animation: slideDown 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }

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

.search-filter-container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-2xl);
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: var(--space-md);
  flex-wrap: wrap;
}

.search-box {
  position: relative;
  max-width: 320px;
  min-width: 240px;
  flex: 0 0 auto;
}

.search-icon {
  position: absolute;
  left: var(--space-sm);
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  font-size: 1rem;
  pointer-events: none;
  transition: color var(--transition-base);
}

.search-input {
  width: 100%;
  padding: var(--space-sm) var(--space-md) var(--space-sm) 40px;
  background-color: var(--bg-secondary);
  border: 2px solid transparent;
  border-radius: var(--radius-xl);
  font-size: 0.9rem;
  font-family: var(--font-text);
  color: var(--text-primary);
  transition: all var(--transition-base);
}

.search-input:focus {
  outline: none;
  background-color: var(--bg-primary);
  border-color: var(--brand-primary);
  box-shadow: 0 0 0 4px rgba(0, 71, 153, 0.1);
}

.search-input:focus+.search-icon {
  color: var(--brand-primary);
}

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

.search-clear {
  position: absolute;
  right: var(--space-xs);
  top: 50%;
  transform: translateY(-50%);
  width: 24px;
  height: 24px;
  background-color: var(--text-tertiary);
  border: none;
  border-radius: 50%;
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-base);
  opacity: 0;
  animation: fadeIn 0.2s ease-out forwards;
  font-size: 0.75rem;
}

.search-clear:hover {
  background-color: var(--text-primary);
  transform: translateY(-50%) scale(1.1);
}

.filter-buttons {
  display: flex;
  gap: var(--space-xs);
  flex-wrap: wrap;
  flex: 1;
  align-items: center;
}

.filter-btn {
  padding: var(--space-xs) var(--space-md);
  background-color: var(--bg-secondary);
  border: 2px solid transparent;
  border-radius: var(--radius-lg);
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  transition: all var(--transition-base);
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  white-space: nowrap;
}

.filter-btn:hover {
  background-color: var(--bg-tertiary);
  transform: translateY(-2px);
}

.filter-btn.active {
  background-color: var(--brand-primary);
  color: white;
  border-color: var(--brand-primary);
}

.filter-btn i {
  font-size: 0.875rem;
}

/* ============================================
   CONTINUE WATCHING - Netflix Style
   ============================================ */

.continue-watching-section {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: var(--space-2xl) var(--space-2xl) 0;
  animation: fadeInUp 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

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

.continue-watching-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-xl);
}

.continue-watching-title {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.continue-watching-title i {
  color: var(--brand-primary);
  font-size: 0.9em;
}

.clear-history-btn {
  padding: var(--space-sm) var(--space-md);
  background-color: transparent;
  border: 1px solid var(--text-tertiary);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-size: 0.875rem;
  cursor: pointer;
  transition: all var(--transition-base);
}

.clear-history-btn:hover {
  background-color: var(--bg-secondary);
  border-color: var(--text-primary);
  color: var(--text-primary);
}

.continue-watching-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr));
  gap: var(--space-lg);
}

.continue-card {
  position: relative;
  background-color: var(--bg-secondary);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition-base);
}

.continue-card:hover {
  background-color: var(--bg-tertiary);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.continue-card-thumbnail {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

.continue-card-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

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

.continue-progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background-color: rgba(0, 0, 0, 0.3);
}

.continue-progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--brand-primary), var(--brand-secondary));
  transition: width var(--transition-base);
}

.continue-card-content {
  padding: var(--space-md);
}

.continue-card-title {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: var(--space-xs);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.continue-card-meta {
  font-size: 0.875rem;
  color: var(--text-tertiary);
}

/* ============================================
   ENHANCED ANIMATIONS & MICRO-INTERACTIONS
   ============================================ */

/* Ripple effect on button clicks */
.btn-primary-v2,
.btn-secondary-v2,
.filter-btn {
  position: relative;
  overflow: hidden;
}

.btn-primary-v2::after,
.btn-secondary-v2::after,
.filter-btn::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition: width 0.6s, height 0.6s;
}

.btn-primary-v2:active::after,
.btn-secondary-v2:active::after,
.filter-btn:active::after {
  width: 300px;
  height: 300px;
}

/* Smooth card entrance animations */
.large-card,
.medium-card,
.grid-card,
.compact-item,
.continue-card {
  animation: cardEntrance 0.4s cubic-bezier(0.4, 0, 0.2, 1) backwards;
}

@keyframes cardEntrance {
  from {
    opacity: 0;
    transform: translateY(20px);
  }

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

/* Stagger animation delay for cards */
.large-card:nth-child(1),
.medium-card:nth-child(1),
.grid-card:nth-child(1) {
  animation-delay: 0.05s;
}

.large-card:nth-child(2),
.medium-card:nth-child(2),
.grid-card:nth-child(2) {
  animation-delay: 0.1s;
}

.large-card:nth-child(3),
.medium-card:nth-child(3),
.grid-card:nth-child(3) {
  animation-delay: 0.15s;
}

.large-card:nth-child(4),
.medium-card:nth-child(4),
.grid-card:nth-child(4) {
  animation-delay: 0.2s;
}

.large-card:nth-child(5),
.medium-card:nth-child(5),
.grid-card:nth-child(5) {
  animation-delay: 0.25s;
}

.large-card:nth-child(6),
.medium-card:nth-child(6),
.grid-card:nth-child(6) {
  animation-delay: 0.3s;
}

/* Hover lift effect with shadow */
.large-card:hover,
.medium-card:hover,
.grid-card:hover,
.continue-card:hover {
  z-index: 10;
}

/* Play button pulse animation */
.large-card-play,
.medium-card-play,
.compact-item-play {
  animation: playButtonPulse 2s infinite;
}

@keyframes playButtonPulse {

  0%,
  100% {
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7);
  }

  50% {
    box-shadow: 0 0 0 10px rgba(255, 255, 255, 0);
  }
}

/* ============================================
   SKELETON LOADING STATES - Enhanced
   ============================================ */

.skeleton-hero {
  height: clamp(500px, 80vh, 800px);
  background: linear-gradient(90deg,
      var(--bg-secondary) 0%,
      var(--bg-tertiary) 50%,
      var(--bg-secondary) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: 0;
}

.skeleton-card {
  background-color: var(--bg-secondary);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.skeleton-card-image {
  aspect-ratio: 16 / 9;
  background: linear-gradient(90deg,
      var(--bg-secondary) 0%,
      var(--bg-tertiary) 50%,
      var(--bg-secondary) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

.skeleton-card-content {
  padding: var(--space-md);
}

.skeleton-text {
  height: 16px;
  background: linear-gradient(90deg,
      var(--bg-secondary) 0%,
      var(--bg-tertiary) 50%,
      var(--bg-secondary) 100%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-sm);
  margin-bottom: var(--space-sm);
}

.skeleton-text.title {
  width: 80%;
  height: 20px;
}

.skeleton-text.subtitle {
  width: 60%;
  height: 14px;
}

/* Empty state */
.empty-state {
  text-align: center;
  padding: var(--space-3xl) var(--space-2xl);
  animation: fadeIn 0.5s ease-out;
}

.empty-state-icon {
  font-size: 4rem;
  color: var(--text-tertiary);
  margin-bottom: var(--space-lg);
  opacity: 0.5;
}

.empty-state-title {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: var(--space-sm);
  color: var(--text-primary);
}

.empty-state-text {
  font-size: 1rem;
  color: var(--text-tertiary);
}

/* ============================================
   RESPONSIVE - Search & Continue Watching
   ============================================ */

@media (max-width: 768px) {
  .search-filter-bar {
    top: 60px;
    padding: var(--space-md) 0;
  }

  .search-filter-container {
    padding: 0 var(--space-md);
  }

  .search-box {
    max-width: 100%;
  }

  .filter-buttons {
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    padding-bottom: var(--space-sm);
  }

  .filter-buttons::-webkit-scrollbar {
    display: none;
  }

  .continue-watching-section {
    padding: var(--space-xl) var(--space-md) 0;
  }

  .continue-watching-header {
    flex-direction: column;
    align-items: flex-start;
    gap: var(--space-md);
  }

  .continue-watching-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.container-v2 {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-2xl);
}

.text-gradient {
  background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.badge-live {
  background-color: var(--accent-primary);
}

.badge-new {
  background-color: var(--accent-secondary);
}

.badge-popular {
  background-color: var(--accent-gold);
  color: var(--bg-primary);
}

.hidden {
  display: none !important;
}

.fade-out {
  animation: fadeOut 0.3s ease-out forwards;
}

@keyframes fadeOut {
  from {
    opacity: 1;
  }

  to {
    opacity: 0;
  }
}