/**
 * YouTube Theme Styles for Ethical Hacking Co
 * @CyberSecurityCourse Integration
 *
 * Features:
 * - Permanent dark theme optimized for video content
 * - Mobile-first responsive design
 * - Video player optimization
 * - CTA styling
 *
 * @version 2.1.3
 */

/* ==========================================================================
   CSS VARIABLES
   ========================================================================== */
:root {
  /* Brand Colors */
  --ehc-youtube-red: #dc2626;
  --ehc-youtube-dark: #282828;
  --ehc-youtube-white: #ffffff;

  /* Theme Colors - Dark Mode Default */
  --ehc-bg-primary: #0a0a0f;
  --ehc-bg-secondary: #1e293b;
  --ehc-bg-tertiary: #334155;
  --ehc-bg-card: rgba(30, 41, 59, 0.8);

  --ehc-text-primary: #f8fafc;
  --ehc-text-secondary: #e4e4e7;
  --ehc-text-muted: #9ca3af;

  --ehc-accent: #6366f1;
  --ehc-accent-light: #818cf8;
  --ehc-success: #22c55e;
  --ehc-warning: #fbbf24;
  --ehc-danger: #ef4444;

  --ehc-border: rgba(148, 163, 184, 0.15);
  --ehc-border-accent: rgba(99, 102, 241, 0.3);
  --ehc-line: rgba(148, 163, 184, 0.12);
  --ehc-surface-1: rgba(12, 14, 22, 0.9);
  --ehc-surface-2: rgba(16, 20, 30, 0.92);
  --ehc-glow-green: rgba(0, 255, 136, 0.35);
  --ehc-glow-blue: rgba(59, 130, 246, 0.35);

  /* Spacing */
  --ehc-spacing-xs: 4px;
  --ehc-spacing-sm: 8px;
  --ehc-spacing-md: 16px;
  --ehc-spacing-lg: 24px;
  --ehc-spacing-xl: 32px;
  --ehc-spacing-2xl: 48px;

  /* Border Radius */
  --ehc-radius-sm: 4px;
  --ehc-radius-md: 8px;
  --ehc-radius-lg: 12px;
  --ehc-radius-xl: 16px;
  --ehc-radius-full: 9999px;

  /* Shadows */
  --ehc-shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --ehc-shadow-md: 0 4px 6px rgba(0, 0, 0, 0.4);
  --ehc-shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.5);

  /* Transitions */
  --ehc-transition-fast: 150ms ease;
  --ehc-transition-base: 200ms ease;
  --ehc-transition-slow: 300ms ease;
}

/* Dark Mode Only - Light mode removed for consistent brand experience */

/* ==========================================================================
   HEADER + NAVIGATION SYSTEM
   ========================================================================== */

/* Header Spacer Element (dynamically created by JS for fixed headers) */
.ehc-header-spacer {
  display: none; /* Only shown when header is position:fixed */
  width: 100%;
  background: transparent;
  pointer-events: none;
}

/* Main sticky header */
.kb-site-header,
header.wp-block-group.kb-site-header {
  background: rgba(8, 10, 15, 0.98);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--ehc-line);
  /* Sticky positioning handled in mobile-responsive.css for proper breakpoint support */
}

.kb-top-bar {
  background: linear-gradient(90deg, rgba(0, 255, 136, 0.08), rgba(59, 130, 246, 0.08));
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.kb-main-header {
  background: linear-gradient(135deg, var(--ehc-surface-1), var(--ehc-surface-2));
  /* Ensure proper flex layout to prevent element overlap */
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.kb-main-nav .wp-block-navigation__container {
  gap: 0.25rem;
  padding: 0.25rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--ehc-line);
}

.kb-main-nav .wp-block-navigation-item__content {
  padding: 0.45rem 0.9rem;
  border-radius: 999px;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.kb-main-nav .wp-block-navigation-item__content:hover,
.kb-main-nav .wp-block-navigation-item__content:focus {
  background: rgba(0, 255, 136, 0.12);
  color: #00ff88;
}

.kb-main-nav .current-menu-item > .wp-block-navigation-item__content,
.kb-main-nav .current-menu-ancestor > .wp-block-navigation-item__content,
.kb-main-nav .current-page-ancestor > .wp-block-navigation-item__content {
  background: linear-gradient(135deg, rgba(0, 255, 136, 0.2), rgba(59, 130, 246, 0.16));
  border: 1px solid rgba(0, 255, 136, 0.35);
  color: #00ff88;
}

.kb-header-search .wp-block-search__inside-wrapper {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--ehc-line);
  border-radius: 999px;
  padding: 0.15rem 0.5rem;
}

.kb-header-search input[type="search"] {
  background: transparent;
  color: var(--ehc-text-primary);
}

.kb-header-search .wp-block-search__button {
  background: rgba(0, 255, 136, 0.18);
  border: 1px solid rgba(0, 255, 136, 0.35);
  color: #00ff88;
}

.kb-header-subscribe .wp-block-button__link {
  background: linear-gradient(135deg, #00ff88 0%, #3b82f6 100%);
  color: #0a0a0f;
  border: 1px solid rgba(0, 255, 136, 0.35);
  box-shadow: 0 8px 24px rgba(0, 255, 136, 0.2);
}

/* ==========================================================================
   LANDING PAGE AESTHETIC UPGRADES
   ========================================================================== */
main.kb-homepage {
  position: relative;
  background:
    radial-gradient(circle at 15% 10%, rgba(0, 255, 136, 0.08), transparent 55%),
    radial-gradient(circle at 80% 0%, rgba(59, 130, 246, 0.1), transparent 55%),
    linear-gradient(180deg, rgba(10, 10, 15, 0.95) 0%, rgba(12, 16, 24, 0.95) 100%);
}

main.kb-homepage::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
  background-size: 48px 48px;
  opacity: 0.35;
  pointer-events: none;
}

main.kb-homepage > * {
  position: relative;
  z-index: 1;
}

.kb-hero-section {
  position: relative;
  overflow: hidden;
}

.kb-hero-section p[style*="text-transform:uppercase"] {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: rgba(0, 255, 136, 0.12);
  border: 1px solid rgba(0, 255, 136, 0.35);
  box-shadow: 0 6px 16px rgba(0, 255, 136, 0.12);
}

.kb-hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(0, 255, 136, 0.2), transparent 45%),
    radial-gradient(circle at 80% 10%, rgba(59, 130, 246, 0.2), transparent 50%);
  opacity: 0.8;
  pointer-events: none;
}

.kb-hero-section::after {
  content: '';
  position: absolute;
  width: 480px;
  height: 480px;
  right: -160px;
  top: -200px;
  background: radial-gradient(circle, var(--ehc-glow-green), transparent 65%);
  filter: blur(30px);
  pointer-events: none;
}

.kb-hero-section .wp-block-cover__inner-container {
  position: relative;
  z-index: 1;
}

.kb-hero-section h1 {
  text-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
}

.kb-hero-section .kb-pulse-btn .wp-block-button__link {
  background: linear-gradient(135deg, #00ff88 0%, #3b82f6 100%);
  color: #0a0a0f !important;
  border: 1px solid rgba(0, 255, 136, 0.45);
  box-shadow: 0 12px 30px rgba(0, 255, 136, 0.25);
}

.kb-hero-section .wp-block-button.is-style-outline .wp-block-button__link {
  background: rgba(15, 23, 42, 0.5) !important;
  border: 1px solid rgba(59, 130, 246, 0.5) !important;
  color: #e2e8f0 !important;
}

.kb-section {
  position: relative;
  overflow: hidden;
}

.kb-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(0, 255, 136, 0.05), transparent 35%),
    linear-gradient(180deg, transparent 70%, rgba(59, 130, 246, 0.06));
  opacity: 0.6;
  pointer-events: none;
}

.kb-section > * {
  position: relative;
  z-index: 1;
}

.kb-feature-card {
  background: linear-gradient(160deg, rgba(18, 22, 32, 0.95), rgba(10, 12, 18, 0.95));
  border: 1px solid rgba(0, 255, 136, 0.12);
  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.45),
    inset 0 0 0 1px rgba(255, 255, 255, 0.02);
  transition: transform var(--ehc-transition-slow), box-shadow var(--ehc-transition-slow), border-color var(--ehc-transition-base);
}

.kb-feature-card:hover {
  transform: translateY(-6px);
  border-color: rgba(0, 255, 136, 0.4);
  box-shadow:
    0 20px 40px rgba(0, 0, 0, 0.5),
    0 0 24px rgba(0, 255, 136, 0.18);
}

/* ==========================================================================
   WHY LEARN WITH US - TABLED FEATURE GRID
   ========================================================================== */
.kb-features-section h2 {
  letter-spacing: -0.01em;
}

.kb-features-section > p {
  max-width: 560px;
  margin-left: auto;
  margin-right: auto;
  color: rgba(226, 232, 240, 0.78);
}

@media screen and (min-width: 992px) {
  .kb-features-table {
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid rgba(148, 163, 184, 0.15);
    background: rgba(8, 12, 20, 0.9);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.45);
  }

  .kb-features-table table {
    width: 100%;
    border-collapse: collapse;
  }

  .kb-features-table thead th {
    text-align: left;
    padding: 1.5rem 2rem;
    font-size: 0.85rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: rgba(148, 163, 184, 0.9);
    background: rgba(15, 23, 42, 0.7);
    border-bottom: 1px solid rgba(148, 163, 184, 0.16);
  }

  .kb-features-table tbody th,
  .kb-features-table tbody td {
    padding: 1.75rem 2rem;
    border-bottom: 1px solid rgba(148, 163, 184, 0.12);
    vertical-align: top;
  }

  .kb-features-table tbody tr:last-child th,
  .kb-features-table tbody tr:last-child td {
    border-bottom: 0;
  }

  .kb-features-table tbody th {
    width: 32%;
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    color: #f8fafc;
  }

  .kb-features-table tbody td {
    color: rgba(226, 232, 240, 0.78);
    font-size: 0.98rem;
    line-height: 1.6;
  }

  .kb-features-table tbody tr {
    transition: background var(--ehc-transition-base);
  }

  .kb-features-table tbody tr:hover {
    background: rgba(0, 255, 136, 0.06);
  }
}

/* ==========================================================================
   VIDEO PLAYER STYLES
   ========================================================================== */
.ehc-video-wrapper {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  height: 0;
  overflow: hidden;
  background: var(--ehc-bg-secondary);
  border-radius: var(--ehc-radius-lg);
  margin: var(--ehc-spacing-lg) 0;
  box-shadow: var(--ehc-shadow-md);
}

.ehc-video-wrapper iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
  border-radius: var(--ehc-radius-lg);
}

/* Video thumbnail with play button */
.ehc-video-thumbnail {
  position: relative;
  cursor: pointer;
  border-radius: var(--ehc-radius-lg);
  overflow: hidden;
}

.ehc-video-thumbnail img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform var(--ehc-transition-slow);
}

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

.ehc-play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0.9;
  transition: opacity var(--ehc-transition-fast), transform var(--ehc-transition-fast);
}

.ehc-video-thumbnail:hover .ehc-play-button {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.1);
}

.ehc-play-bg {
  fill: var(--ehc-youtube-red);
}

/* ==========================================================================
   BUTTON STYLES
   ========================================================================== */
.ehc-btn {
  display: inline-flex;
  align-items: center;
  gap: var(--ehc-spacing-sm);
  padding: var(--ehc-spacing-sm) var(--ehc-spacing-md);
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  border-radius: var(--ehc-radius-md);
  transition: all var(--ehc-transition-fast);
  cursor: pointer;
  border: none;
}

.ehc-btn-youtube {
  background: var(--ehc-youtube-red);
  color: var(--ehc-youtube-white);
}

.ehc-btn-youtube:hover {
  background: #b91c1c;
  transform: translateY(-1px);
  box-shadow: var(--ehc-shadow-md);
}

.ehc-btn-outline {
  background: transparent;
  color: var(--ehc-text-primary);
  border: 1px solid var(--ehc-border-accent);
}

.ehc-btn-outline:hover {
  background: var(--ehc-bg-secondary);
  border-color: var(--ehc-accent);
}

.ehc-btn-sm {
  padding: var(--ehc-spacing-xs) var(--ehc-spacing-sm);
  font-size: 12px;
}

.ehc-btn-lg {
  padding: var(--ehc-spacing-md) var(--ehc-spacing-lg);
  font-size: 16px;
}

/* ==========================================================================
   HEADER BANNER CTA
   ========================================================================== */
.ehc-header-banner {
  background: linear-gradient(90deg, var(--ehc-youtube-red), #b91c1c);
  padding: var(--ehc-spacing-sm) var(--ehc-spacing-md);
  text-align: center;
  margin-bottom: var(--ehc-spacing-lg);
  border-radius: var(--ehc-radius-md);
}

.ehc-header-banner a {
  display: inline-flex;
  align-items: center;
  gap: var(--ehc-spacing-sm);
  color: var(--ehc-youtube-white);
  text-decoration: none;
  font-weight: 500;
  font-size: 14px;
}

.ehc-header-banner a:hover {
  text-decoration: underline;
}

.ehc-header-banner .ehc-yt-icon {
  flex-shrink: 0;
}

.ehc-header-banner .ehc-arrow {
  animation: bounce-right 1s infinite;
}

@keyframes bounce-right {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(4px); }
}

/* ==========================================================================
   FOOTER CTA
   ========================================================================== */
.ehc-footer-cta {
  background: linear-gradient(135deg, var(--ehc-bg-secondary), var(--ehc-bg-tertiary));
  border: 1px solid var(--ehc-border-accent);
  border-radius: var(--ehc-radius-xl);
  padding: var(--ehc-spacing-xl);
  margin: var(--ehc-spacing-2xl) 0;
  text-align: center;
}

.ehc-footer-cta-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--ehc-spacing-md);
  margin-bottom: var(--ehc-spacing-lg);
}

.ehc-footer-cta-icon svg {
  filter: drop-shadow(0 4px 6px rgba(255, 0, 0, 0.3));
}

.ehc-footer-cta h3 {
  color: var(--ehc-text-primary);
  font-size: 20px;
  margin: 0;
}

.ehc-footer-cta p {
  color: var(--ehc-text-secondary);
  font-size: 16px;
  margin: 0;
  max-width: 500px;
}

.ehc-footer-cta-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: var(--ehc-spacing-md);
}

/* ==========================================================================
   INLINE CTAs
   ========================================================================== */
.ehc-inline-cta,
.ehc-mid-cta {
  background: var(--ehc-bg-secondary);
  border-left: 4px solid var(--ehc-youtube-red);
  border-radius: 0 var(--ehc-radius-md) var(--ehc-radius-md) 0;
  padding: var(--ehc-spacing-md);
  margin: var(--ehc-spacing-lg) 0;
}

.ehc-inline-cta p,
.ehc-mid-cta p {
  display: flex;
  align-items: center;
  gap: var(--ehc-spacing-sm);
  margin: 0;
  color: var(--ehc-text-secondary);
  font-size: 14px;
}

.ehc-inline-cta a,
.ehc-mid-cta a {
  color: var(--ehc-youtube-red);
  font-weight: 600;
}

.ehc-inline-cta a:hover,
.ehc-mid-cta a:hover {
  text-decoration: underline;
}

/* Inline video CTA */
.ehc-inline-video-cta {
  margin: var(--ehc-spacing-lg) 0;
}

.ehc-video-caption {
  text-align: center;
  margin-top: var(--ehc-spacing-sm);
  font-size: 14px;
}

.ehc-video-caption a {
  color: var(--ehc-accent-light);
}

/* ==========================================================================
   FLOATING CTA
   ========================================================================== */
.ehc-floating-cta {
  position: fixed;
  bottom: var(--ehc-spacing-lg);
  right: var(--ehc-spacing-lg);
  z-index: 9999;
  display: none;
  animation: slide-up 0.3s ease;
}

.ehc-floating-cta.ehc-fade-in {
  display: flex;
}

.ehc-floating-cta a {
  display: flex;
  align-items: center;
  gap: var(--ehc-spacing-sm);
  background: var(--ehc-youtube-red);
  color: var(--ehc-youtube-white);
  padding: var(--ehc-spacing-sm) var(--ehc-spacing-md);
  border-radius: var(--ehc-radius-full);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  box-shadow: var(--ehc-shadow-lg);
  transition: all var(--ehc-transition-fast);
}

.ehc-floating-cta a:hover {
  background: #b91c1c;
  transform: scale(1.05);
}

.ehc-floating-cta span {
  display: none;
}

@keyframes slide-up {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ==========================================================================
   VIDEO GRID
   ========================================================================== */
.ehc-video-grid,
.ehc-playlist-grid {
  display: grid;
  gap: var(--ehc-spacing-lg);
  margin: var(--ehc-spacing-lg) 0;
}

.ehc-cols-2 { grid-template-columns: repeat(2, 1fr); }
.ehc-cols-3 { grid-template-columns: repeat(3, 1fr); }
.ehc-cols-4 { grid-template-columns: repeat(4, 1fr); }

.ehc-video-card,
.ehc-playlist-item {
  background: var(--ehc-bg-card);
  border-radius: var(--ehc-radius-lg);
  overflow: hidden;
  transition: transform var(--ehc-transition-fast), box-shadow var(--ehc-transition-fast);
}

.ehc-video-card:hover,
.ehc-playlist-item:hover {
  transform: translateY(-4px);
  box-shadow: var(--ehc-shadow-lg);
}

.ehc-video-card a,
.ehc-playlist-item a {
  text-decoration: none;
  color: inherit;
}

.ehc-thumbnail,
.ehc-thumbnail-wrapper {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

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

.ehc-video-card:hover .ehc-thumbnail img,
.ehc-playlist-item:hover .ehc-thumbnail-wrapper img {
  transform: scale(1.05);
}

.ehc-play-btn,
.ehc-play-overlay {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 48px;
  height: 48px;
  background: rgba(0, 0, 0, 0.7);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 20px;
  opacity: 0.9;
  transition: all var(--ehc-transition-fast);
}

.ehc-video-card:hover .ehc-play-btn,
.ehc-playlist-item:hover .ehc-play-overlay {
  opacity: 1;
  background: var(--ehc-youtube-red);
  transform: translate(-50%, -50%) scale(1.1);
}

.ehc-duration {
  position: absolute;
  bottom: var(--ehc-spacing-sm);
  right: var(--ehc-spacing-sm);
  background: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 2px 6px;
  border-radius: var(--ehc-radius-sm);
  font-size: 12px;
  font-weight: 500;
}

.ehc-video-title {
  padding: var(--ehc-spacing-md);
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--ehc-text-primary);
  line-height: 1.4;
}

.ehc-video-meta,
.ehc-video-date {
  padding: 0 var(--ehc-spacing-md) var(--ehc-spacing-md);
  font-size: 12px;
  color: var(--ehc-text-muted);
}

.ehc-video-desc {
  padding: 0 var(--ehc-spacing-md) var(--ehc-spacing-md);
  font-size: 13px;
  color: var(--ehc-text-secondary);
  line-height: 1.5;
}

/* Section title */
.ehc-section-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--ehc-text-primary);
  margin-bottom: var(--ehc-spacing-lg);
}

/* View more link */
.ehc-view-more {
  text-align: center;
  margin-top: var(--ehc-spacing-lg);
}

/* ==========================================================================
   CHANNEL STATS
   ========================================================================== */
.ehc-channel-stats {
  display: flex;
  gap: var(--ehc-spacing-lg);
}

.ehc-stats-inline {
  flex-direction: row;
  justify-content: center;
}

.ehc-stats-cards {
  flex-wrap: wrap;
}

.ehc-stat {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--ehc-spacing-xs);
}

.ehc-stats-cards .ehc-stat {
  background: var(--ehc-bg-card);
  padding: var(--ehc-spacing-lg);
  border-radius: var(--ehc-radius-lg);
  min-width: 120px;
}

.ehc-stat-value {
  font-size: 24px;
  font-weight: 700;
  color: var(--ehc-text-primary);
}

.ehc-stat-label {
  font-size: 12px;
  color: var(--ehc-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* ==========================================================================
   CHANNEL LINK
   ========================================================================== */
.ehc-channel-link {
  display: inline-flex;
  align-items: center;
  gap: var(--ehc-spacing-xs);
  color: var(--ehc-youtube-red);
  font-weight: 600;
  text-decoration: none;
}

.ehc-channel-link:hover {
  text-decoration: underline;
}

.ehc-channel-link .ehc-yt-icon {
  flex-shrink: 0;
}

/* Subscribe link */
.ehc-subscribe-link {
  color: var(--ehc-youtube-red);
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: var(--ehc-spacing-xs);
}

.ehc-subscribe-link:hover {
  text-decoration: underline;
}

/* ==========================================================================
   MOBILE RESPONSIVE
   ========================================================================== */
@media screen and (max-width: 767px) {
  /* Single column grids on mobile */
  .ehc-video-grid,
  .ehc-playlist-grid,
  .ehc-cols-2,
  .ehc-cols-3,
  .ehc-cols-4 {
    grid-template-columns: 1fr;
  }

  /* Smaller padding */
  .ehc-footer-cta {
    padding: var(--ehc-spacing-lg);
  }

  .ehc-footer-cta h3 {
    font-size: 18px;
  }

  .ehc-footer-cta p {
    font-size: 14px;
  }

  /* Stack buttons */
  .ehc-footer-cta-buttons {
    flex-direction: column;
    width: 100%;
  }

  .ehc-footer-cta-buttons .ehc-btn {
    width: 100%;
    justify-content: center;
  }

  /* Floating CTA - icon only on mobile */
  .ehc-floating-cta a {
    padding: var(--ehc-spacing-sm);
    border-radius: 50%;
  }

  .ehc-floating-cta svg {
    width: 28px;
    height: 28px;
  }

  /* Video cards */
  .ehc-video-title {
    font-size: 16px;
  }

  /* Header banner */
  .ehc-header-banner {
    padding: var(--ehc-spacing-sm);
  }

  .ehc-header-banner a {
    font-size: 13px;
  }
}

@media screen and (min-width: 768px) {
  /* Show text on floating CTA */
  .ehc-floating-cta span {
    display: inline;
  }

  /* Two columns on tablet */
  .ehc-cols-3,
  .ehc-cols-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media screen and (min-width: 1024px) {
  /* Full columns on desktop */
  .ehc-cols-3 {
    grid-template-columns: repeat(3, 1fr);
  }

  .ehc-cols-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* ==========================================================================
   LATEST VIDEOS SECTION
   ========================================================================== */
.ehc-latest-videos {
  background: var(--ehc-bg-secondary);
  border-radius: var(--ehc-radius-xl);
  padding: var(--ehc-spacing-xl);
  margin: var(--ehc-spacing-2xl) 0;
}

.ehc-latest-videos .ehc-section-title {
  display: flex;
  align-items: center;
  gap: var(--ehc-spacing-sm);
}

.ehc-latest-videos .ehc-section-title::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 24px;
  background: var(--ehc-youtube-red);
  mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z'/%3E%3C/svg%3E");
  mask-size: contain;
  -webkit-mask-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z'/%3E%3C/svg%3E");
  -webkit-mask-size: contain;
}

/* ==========================================================================
   COURSES ARCHIVE GRID
   ========================================================================== */
.ehc-courses-archive {
  background: var(--ehc-bg-primary);
}

.ehc-courses-hero {
  text-align: center;
}

.ehc-courses-grid {
  display: grid;
  gap: var(--ehc-spacing-xl);
}

.ehc-courses-grid.ehc-cols-1 {
  grid-template-columns: 1fr;
}

.ehc-courses-grid.ehc-cols-2 {
  grid-template-columns: repeat(2, 1fr);
}

.ehc-courses-grid.ehc-cols-3 {
  grid-template-columns: repeat(3, 1fr);
}

.ehc-courses-grid.ehc-cols-4 {
  grid-template-columns: repeat(4, 1fr);
}

/* Course Card */
.ehc-course-card {
  display: flex;
  flex-direction: column;
  background: var(--ehc-bg-card);
  border-radius: var(--ehc-radius-lg);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform var(--ehc-transition-base), box-shadow var(--ehc-transition-base);
  border: 1px solid var(--ehc-border);
}

.ehc-course-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--ehc-shadow-lg);
  border-color: var(--ehc-border-accent);
}

.ehc-course-card:focus {
  outline: 2px solid var(--ehc-accent);
  outline-offset: 2px;
}

/* Course Thumbnail */
.ehc-course-thumbnail {
  position: relative;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--ehc-bg-secondary);
}

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

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

.ehc-course-play-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 64px;
  height: 64px;
  background: rgba(0, 0, 0, 0.7);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  color: white;
  opacity: 0;
  transition: opacity var(--ehc-transition-base);
}

.ehc-course-card:hover .ehc-course-play-icon {
  opacity: 1;
}

/* Level Badges */
.ehc-level-badge {
  position: absolute;
  top: var(--ehc-spacing-sm);
  left: var(--ehc-spacing-sm);
  padding: 4px 10px;
  border-radius: var(--ehc-radius-sm);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.ehc-level-beginner {
  background: #10b981;
  color: white;
}

.ehc-level-intermediate {
  background: #f59e0b;
  color: #1e293b;
}

.ehc-level-advanced {
  background: #ef4444;
  color: white;
}

.ehc-level-all {
  background: #6366f1;
  color: white;
}

/* Course Content */
.ehc-course-content {
  padding: var(--ehc-spacing-lg);
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.ehc-course-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--ehc-text-primary);
  margin: 0 0 var(--ehc-spacing-sm);
  line-height: 1.3;
}

.ehc-course-description {
  font-size: 14px;
  color: var(--ehc-text-muted);
  margin: 0 0 var(--ehc-spacing-md);
  line-height: 1.5;
  flex-grow: 1;
}

.ehc-course-meta {
  display: flex;
  align-items: center;
  gap: var(--ehc-spacing-md);
  margin-top: auto;
  padding-top: var(--ehc-spacing-md);
  border-top: 1px solid var(--ehc-border);
}

.ehc-course-video-count {
  font-size: 13px;
  color: var(--ehc-text-secondary);
  display: flex;
  align-items: center;
  gap: var(--ehc-spacing-xs);
}

/* Responsive Courses Grid */
@media screen and (max-width: 767px) {
  .ehc-courses-grid,
  .ehc-courses-grid.ehc-cols-2,
  .ehc-courses-grid.ehc-cols-3,
  .ehc-courses-grid.ehc-cols-4 {
    grid-template-columns: 1fr;
  }

  .ehc-course-title {
    font-size: 16px;
  }
}

@media screen and (min-width: 768px) and (max-width: 1023px) {
  .ehc-courses-grid.ehc-cols-3,
  .ehc-courses-grid.ehc-cols-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* ==========================================================================
   EMAIL COURSE SIGNUP
   ========================================================================== */
.ehc-email-course-form {
  display: grid;
  gap: 1rem;
}

.ehc-email-course-fields {
  display: grid;
  gap: 0.75rem;
}

.ehc-email-course-form input {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(148, 163, 184, 0.25);
  background: rgba(15, 23, 42, 0.65);
  color: var(--ehc-text-primary);
  padding: 0.85rem 1rem;
  font-size: 0.95rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.ehc-email-course-form input::placeholder {
  color: rgba(148, 163, 184, 0.8);
}

.ehc-email-course-form input:focus {
  outline: none;
  border-color: var(--ehc-accent-light);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.25);
}

.ehc-email-course-submit {
  border: none;
  border-radius: 12px;
  padding: 0.95rem 1.25rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: #081018;
  background: linear-gradient(135deg, #22c55e 0%, #38bdf8 100%);
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.ehc-email-course-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 24px rgba(34, 197, 94, 0.25);
}

.ehc-email-course-note {
  margin: 0;
  font-size: 0.85rem;
  color: var(--ehc-text-muted);
}

.ehc-email-course-message {
  padding: 0.75rem 1rem;
  border-radius: 12px;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.ehc-email-course-success {
  background: rgba(34, 197, 94, 0.15);
  border: 1px solid rgba(34, 197, 94, 0.35);
  color: #86efac;
}

.ehc-email-course-error {
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid rgba(239, 68, 68, 0.35);
  color: #fca5a5;
}

/* ==========================================================================
   ANIMATED FEATURE PILLS - New-Age Micro-Animations
   ========================================================================== */
.kb-feature-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.kb-pill {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 1rem;
  background: linear-gradient(135deg, rgba(30, 41, 59, 0.9), rgba(15, 23, 42, 0.95));
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 9999px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--ehc-text-secondary);
  cursor: default;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  animation: pillFadeIn 0.6s ease-out both;
}

/* Staggered entrance animation */
.kb-pill-1 { animation-delay: 0s; }
.kb-pill-2 { animation-delay: 0.1s; }
.kb-pill-3 { animation-delay: 0.2s; }
.kb-pill-4 { animation-delay: 0.3s; }

@keyframes pillFadeIn {
  0% {
    opacity: 0;
    transform: translateY(10px) scale(0.95);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Icon with subtle pulse */
.kb-pill-icon {
  font-size: 0.875rem;
  filter: drop-shadow(0 0 4px currentColor);
  animation: iconFloat 3s ease-in-out infinite;
}

@keyframes iconFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-2px); }
}

/* Text styling */
.kb-pill-text {
  letter-spacing: 0.02em;
}

/* Animated glow effect */
.kb-pill-glow {
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.08),
    transparent
  );
  animation: shimmer 4s ease-in-out infinite;
}

@keyframes shimmer {
  0%, 100% { left: -100%; }
  50% { left: 100%; }
}

/* Hover micro-interactions */
.kb-pill:hover {
  transform: translateY(-2px) scale(1.02);
  border-color: rgba(99, 102, 241, 0.4);
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.3),
    0 0 20px rgba(99, 102, 241, 0.15);
}

.kb-pill:hover .kb-pill-icon {
  animation: iconBounce 0.5s ease;
}

@keyframes iconBounce {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.2); }
}

/* Individual pill accent colors - softer, more sophisticated */
.kb-pill-1 {
  border-color: rgba(239, 68, 68, 0.2);
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.08), rgba(30, 41, 59, 0.95));
}
.kb-pill-1:hover {
  border-color: rgba(239, 68, 68, 0.4);
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.3),
    0 0 20px rgba(239, 68, 68, 0.12);
}
.kb-pill-1 .kb-pill-icon {
  filter: drop-shadow(0 0 6px rgba(239, 68, 68, 0.4));
}

.kb-pill-2 {
  border-color: rgba(59, 130, 246, 0.2);
  background: linear-gradient(135deg, rgba(59, 130, 246, 0.08), rgba(30, 41, 59, 0.95));
}
.kb-pill-2:hover {
  border-color: rgba(59, 130, 246, 0.4);
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.3),
    0 0 20px rgba(59, 130, 246, 0.12);
}
.kb-pill-2 .kb-pill-icon {
  filter: drop-shadow(0 0 6px rgba(59, 130, 246, 0.4));
}

.kb-pill-3 {
  border-color: rgba(251, 191, 36, 0.2);
  background: linear-gradient(135deg, rgba(251, 191, 36, 0.08), rgba(30, 41, 59, 0.95));
}
.kb-pill-3:hover {
  border-color: rgba(251, 191, 36, 0.4);
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.3),
    0 0 20px rgba(251, 191, 36, 0.1);
}
.kb-pill-3 .kb-pill-icon {
  filter: drop-shadow(0 0 6px rgba(251, 191, 36, 0.4));
}

.kb-pill-4 {
  border-color: rgba(34, 197, 94, 0.2);
  background: linear-gradient(135deg, rgba(34, 197, 94, 0.08), rgba(30, 41, 59, 0.95));
}
.kb-pill-4:hover {
  border-color: rgba(34, 197, 94, 0.4);
  box-shadow:
    0 4px 12px rgba(0, 0, 0, 0.3),
    0 0 20px rgba(34, 197, 94, 0.12);
}
.kb-pill-4 .kb-pill-icon {
  filter: drop-shadow(0 0 6px rgba(34, 197, 94, 0.4));
}

/* Pill breathing animation for attention */
.kb-pill::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, transparent, rgba(255, 255, 255, 0.1), transparent);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.kb-pill:hover::before {
  opacity: 1;
}

/* Mobile responsive */
@media (max-width: 768px) {
  .kb-feature-pills {
    justify-content: center;
    gap: 0.5rem;
  }

  .kb-pill {
    padding: 0.5rem 0.875rem;
    font-size: 0.75rem;
  }

  .kb-pill-icon {
    font-size: 0.8125rem;
  }
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  .kb-pill,
  .kb-pill-icon,
  .kb-pill-glow {
    animation: none;
  }

  .kb-pill:hover {
    transform: none;
  }
}

/* ==========================================================================
   PRINT STYLES
   ========================================================================== */
@media print {
  .ehc-header-banner,
  .ehc-footer-cta,
  .ehc-floating-cta,
  .ehc-inline-cta,
  .ehc-mid-cta {
    display: none !important;
  }

  .ehc-video-wrapper {
    page-break-inside: avoid;
  }
}
