/* ===== THEME COMPONENTS ===== */

/* Header & Navigation */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: var(--z-sticky);
  transition: all var(--transition-base);
  padding: var(--space-4) 0;
}

.header-scrolled {
  background: rgba(11, 12, 16, 0.9);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  font-family: var(--font-display);
  font-size: var(--font-size-2xl);
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.02em;
}

.nav-brand .accent {
  color: var(--brand);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: var(--space-8);
  list-style: none;
}

.nav-link {
  color: var(--text-muted);
  text-decoration: none;
  font-weight: 500;
  transition: color var(--transition-fast);
  position: relative;
}

.nav-link:hover {
  color: var(--brand);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--brand);
  transition: width var(--transition-base);
}

.nav-link:hover::after {
  width: 100%;
}

/* Mobile Menu */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text);
  cursor: pointer;
  padding: var(--space-2);
}

.mobile-menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
  transform: translateY(-100%);
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
}

.mobile-menu.active {
  transform: translateY(0);
  opacity: 1;
  visibility: visible;
}

.mobile-nav-links {
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
  }
  
  .mobile-menu-toggle {
    display: block;
  }
}

/* Hero Section */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

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

.hero-video {
  position: absolute;
  top: 50%;
  left: 50%;
  min-width: 100%;
  min-height: 100%;
  width: auto;
  height: auto;
  transform: translate(-50%, -50%);
  object-fit: cover;
  z-index: -1;
}

.hero-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    rgba(11, 12, 16, 0.8) 0%,
    rgba(11, 12, 16, 0.6) 50%,
    rgba(11, 12, 16, 0.8) 100%
  );
  z-index: -1;
}

.hero-content {
  max-width: 800px;
  padding: 0 var(--space-6);
}

.hero-title {
  margin-bottom: var(--space-6);
  background: linear-gradient(135deg, var(--text), var(--brand));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: clamp(1.125rem, 2.5vw, 1.375rem);
  color: var(--text-muted);
  margin-bottom: var(--space-8);
  line-height: 1.6;
}

.hero-cta {
  margin-bottom: var(--space-12);
}

.hero-scroll-indicator {
  position: absolute;
  bottom: var(--space-8);
  left: 50%;
  transform: translateX(-50%);
  color: var(--text-muted);
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%, 20%, 53%, 80%, 100% {
    transform: translateX(-50%) translateY(0);
  }
  40%, 43% {
    transform: translateX(-50%) translateY(-10px);
  }
  70% {
    transform: translateX(-50%) translateY(-5px);
  }
  90% {
    transform: translateX(-50%) translateY(-2px);
  }
}

/* Video Showcase */
.video-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: var(--space-8);
  margin-top: var(--space-12);
}

.video-card {
  position: relative;
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition-base);
  background: var(--surface);
  border: 1px solid var(--line);
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.6s ease-out forwards;
}

.video-card:nth-child(1) { animation-delay: 0.1s; }
.video-card:nth-child(2) { animation-delay: 0.2s; }
.video-card:nth-child(3) { animation-delay: 0.3s; }
.video-card:nth-child(4) { animation-delay: 0.4s; }
.video-card:nth-child(5) { animation-delay: 0.5s; }
.video-card:nth-child(6) { animation-delay: 0.6s; }

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

.video-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-glow);
  border-color: var(--brand);
}

.video-thumbnail {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
}

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

.video-thumbnail .video-preview {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
  pointer-events: none;
  background: var(--surface);
}

.video-thumbnail .video-preview[data-loading="true"] {
  background: linear-gradient(45deg, 
    var(--surface) 25%, 
    rgba(140, 243, 255, 0.1) 25%, 
    rgba(140, 243, 255, 0.1) 50%, 
    var(--surface) 50%, 
    var(--surface) 75%, 
    rgba(140, 243, 255, 0.1) 75%, 
    rgba(140, 243, 255, 0.1));
  background-size: 20px 20px;
  animation: loading-shimmer 1.5s ease-in-out infinite;
}

@keyframes loading-shimmer {
  0% { background-position: -20px 0; }
  100% { background-position: 20px 0; }
}

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

.video-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  transition: opacity var(--transition-base);
  pointer-events: none;
}

.video-card:hover .video-overlay {
  opacity: 0.8;
  background: rgba(0, 0, 0, 0.5);
}

.play-button {
  width: 80px;
  height: 80px;
  background: rgba(140, 243, 255, 0.9);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: scale(0.8);
  transition: all var(--transition-fast);
  box-shadow: 0 4px 20px rgba(140, 243, 255, 0.4);
  pointer-events: auto;
  cursor: pointer;
  backdrop-filter: blur(10px);
}

.video-card:hover .play-button {
  transform: scale(1);
  background: var(--brand);
  box-shadow: 0 8px 30px rgba(140, 243, 255, 0.6);
}

.play-button svg {
  margin-left: 3px; /* Center the play arrow visually */
  color: var(--bg);
}

.video-info {
  padding: var(--space-6);
}

.video-title {
  font-size: var(--font-size-lg);
  font-weight: 600;
  margin-bottom: var(--space-2);
  color: var(--text);
}

.video-description {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
  line-height: 1.5;
  margin-bottom: var(--space-3);
}

.video-meta {
  display: flex;
  justify-content: between;
  align-items: center;
  gap: var(--space-3);
  font-size: var(--font-size-xs);
  color: var(--text-subtle);
}

.video-category {
  background: var(--surface-elevated);
  padding: var(--space-1) var(--space-3);
  border-radius: var(--border-radius);
  font-weight: 500;
  color: var(--brand);
}

.video-duration {
  margin-left: auto;
}

/* Category Filter */
.filter-tabs {
  display: flex;
  justify-content: center;
  gap: var(--space-2);
  margin-bottom: var(--space-12);
  flex-wrap: wrap;
}

.filter-tab {
  padding: var(--space-3) var(--space-6);
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--border-radius-lg);
  color: var(--text-muted);
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-tab:hover {
  border-color: var(--brand);
  color: var(--brand);
}

.filter-tab.active {
  background: var(--brand);
  border-color: var(--brand);
  color: var(--bg);
}

/* Video Modal */
.video-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.95);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: var(--z-modal);
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
  padding: var(--space-6);
  backdrop-filter: blur(10px);
}

.video-modal.active {
  opacity: 1;
  visibility: visible;
}

.video-modal-content {
  position: relative;
  width: 100%;
  max-width: 1200px;
  aspect-ratio: 16 / 9;
  background: var(--surface);
  border-radius: var(--border-radius-lg);
  overflow: hidden;
  transform: scale(0.9);
  transition: transform var(--transition-base);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.video-modal.active .video-modal-content {
  transform: scale(1);
}

.video-modal video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Re-enable pointer events for controls */
.video-modal video::-webkit-media-controls-panel {
  pointer-events: auto;
}

.video-modal video::-webkit-media-controls {
  pointer-events: auto;
}

/* Video Protection - Disable text selection and dragging */
.video-modal video {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
  /* Disable highlighting */
  -webkit-touch-callout: none;
  -webkit-tap-highlight-color: transparent;
}

/* Disable right-click on video cards */
.video-card {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}

.video-thumbnail img {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
  pointer-events: none;
}

.video-thumbnail .video-preview {
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
  pointer-events: none;
}

/* Video protection overlay */
.video-protection-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: transparent;
  z-index: 10;
  pointer-events: none;
}

/* Watermark overlay for videos */
.video-watermark {
  position: absolute;
  bottom: 20px;
  right: 20px;
  background: rgba(0, 0, 0, 0.7);
  color: var(--brand);
  padding: var(--space-2) var(--space-3);
  border-radius: var(--border-radius);
  font-size: var(--font-size-sm);
  font-weight: 600;
  z-index: 15;
  pointer-events: none;
  user-select: none;
}

.modal-close {
  position: absolute;
  top: -var(--space-12);
  right: 0;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 50%;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.modal-close:hover {
  background: var(--brand);
  color: var(--bg);
}

/* Stats Section */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-8);
  margin-top: var(--space-12);
}

.stat-item {
  text-align: center;
  padding: var(--space-6);
}

.stat-number {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 4vw, 3.5rem);
  font-weight: 700;
  color: var(--brand);
  margin-bottom: var(--space-2);
  line-height: 1;
}

.stat-label {
  color: var(--text-muted);
  font-weight: 500;
}

/* Process Timeline */
.process-timeline {
  position: relative;
  padding: var(--space-12) 0;
}

.timeline-line {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: var(--line);
  transform: translateX(-50%);
}

.timeline-item {
  display: flex;
  align-items: center;
  margin-bottom: var(--space-16);
  position: relative;
}

.timeline-item:nth-child(even) {
  flex-direction: row-reverse;
}

.timeline-content {
  flex: 1;
  max-width: 400px;
  padding: var(--space-8);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--border-radius-lg);
  position: relative;
}

.timeline-item:nth-child(odd) .timeline-content {
  margin-right: var(--space-12);
}

.timeline-item:nth-child(even) .timeline-content {
  margin-left: var(--space-12);
}

.timeline-marker {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 16px;
  height: 16px;
  background: var(--brand);
  border: 4px solid var(--bg);
  border-radius: 50%;
  z-index: 2;
}

.timeline-step {
  color: var(--brand);
  font-weight: 700;
  margin-bottom: var(--space-2);
}

.timeline-title {
  font-size: var(--font-size-xl);
  font-weight: 600;
  margin-bottom: var(--space-3);
}

.timeline-description {
  color: var(--text-muted);
  line-height: 1.6;
}

@media (max-width: 768px) {
  .timeline-line {
    left: var(--space-6);
  }
  
  .timeline-item {
    flex-direction: row !important;
    padding-left: var(--space-12);
  }
  
  .timeline-content {
    margin: 0 !important;
  }
  
  .timeline-marker {
    left: var(--space-6);
  }
}

/* Testimonials */
.testimonials-slider {
  margin-top: var(--space-12);
}

.testimonial-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--border-radius-lg);
  padding: var(--space-8);
  text-align: center;
  margin: 0 var(--space-4);
}

.testimonial-quote {
  font-size: var(--font-size-lg);
  line-height: 1.6;
  margin-bottom: var(--space-6);
  color: var(--text);
  font-style: italic;
}

.testimonial-author {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-4);
}

.testimonial-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.testimonial-info h4 {
  font-size: var(--font-size-base);
  font-weight: 600;
  margin-bottom: var(--space-1);
}

.testimonial-role {
  color: var(--text-muted);
  font-size: var(--font-size-sm);
}

/* Contact Form */
.contact-form {
  max-width: 600px;
  margin: 0 auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--border-radius-lg);
  padding: var(--space-8);
}

.form-group {
  margin-bottom: var(--space-6);
}

.form-label {
  display: block;
  margin-bottom: var(--space-2);
  font-weight: 500;
  color: var(--text);
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: var(--space-4);
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--border-radius);
  color: var(--text);
  font-family: var(--font-body);
  font-size: var(--font-size-base);
  transition: border-color var(--transition-fast);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(140, 243, 255, 0.1);
}

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

.form-submit {
  width: 100%;
  margin-top: var(--space-4);
}

/* Footer */
.footer {
  background: var(--surface);
  border-top: 1px solid var(--line);
  padding: var(--space-12) 0 var(--space-8);
  margin-top: var(--space-20);
}

.footer-content {
  text-align: center;
  color: var(--text-muted);
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: var(--space-6);
  margin-bottom: var(--space-6);
  flex-wrap: wrap;
}

.footer-link {
  color: var(--text-muted);
  text-decoration: none;
  transition: color var(--transition-fast);
}

.footer-link:hover {
  color: var(--brand);
}

/* Floating Contact Button */
.floating-contact {
  position: fixed;
  bottom: var(--space-6);
  right: var(--space-6);
  z-index: var(--z-fixed);
  background: linear-gradient(135deg, var(--brand), var(--brand-2));
  color: var(--bg);
  border: none;
  border-radius: 50%;
  width: 64px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(140, 243, 255, 0.4);
  transition: all var(--transition-base);
}

.floating-contact:hover {
  transform: scale(1.1);
  box-shadow: 0 6px 25px rgba(140, 243, 255, 0.6);
}

/* Responsive Design */
@media (max-width: 480px) {
  .container {
    padding: 0 var(--space-4);
  }
  
  .section {
    padding: var(--space-16) 0;
  }
  
  .video-grid {
    grid-template-columns: 1fr;
    gap: var(--space-6);
  }
  
  .hero-video {
    /* On mobile, focus on the center of the video */
    object-position: center center;
  }
  
  .hero-overlay {
    background: linear-gradient(
      135deg,
      rgba(11, 12, 16, 0.9) 0%,
      rgba(11, 12, 16, 0.7) 50%,
      rgba(11, 12, 16, 0.9) 100%
    );
  }
  
  .video-modal {
    padding: var(--space-4);
  }
  
  .video-modal-content {
    max-width: 100%;
    height: auto;
  }
  
  .play-button {
    width: 60px;
    height: 60px;
  }
  
  .hero-content {
    padding: 0 var(--space-4);
  }
  
  .filter-tabs {
    gap: var(--space-1);
  }
  
  .filter-tab {
    padding: var(--space-2) var(--space-4);
    font-size: var(--font-size-sm);
  }
  
  .floating-contact {
    bottom: var(--space-4);
    right: var(--space-4);
    width: 56px;
    height: 56px;
  }
}
