/**
 * Videos Page Styles
 * Apple-inspired design with blue accents
 */

/* Channel Info */
.channel-info {
  max-width: 1400px;
  margin: 0 auto 48px;
  padding: 0 24px;
}

.channel-banner {
  display: flex;
  align-items: center;
  gap: 24px;
  padding: 32px;
  background: rgba(28,28,30,0.6);
  border: 1.5px solid rgba(0,122,255,0.2);
  border-radius: 16px;
  backdrop-filter: saturate(180%) blur(20px);
}

.channel-banner img {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 3px solid var(--blue);
  object-fit: cover;
}

.channel-details {
  flex: 1;
}

.channel-details h2 {
  font-family: 'Inter', sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.channel-details p {
  font-size: 14px;
  color: rgba(255,255,255,0.6);
  margin-bottom: 16px;
  letter-spacing: -0.01em;
}

/* Videos Grid */
.videos-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 24px;
}

.video-card {
  background: rgba(28,28,30,0.6);
  border: 1.5px solid rgba(255,255,255,0.1);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.3s ease;
  backdrop-filter: saturate(180%) blur(20px);
}

.video-card:hover {
  transform: translateY(-4px);
  border-color: var(--blue-light);
  box-shadow: 0 8px 24px rgba(0,122,255,0.3);
}

.video-thumbnail {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 aspect ratio */
  background: #000;
  overflow: hidden;
}

.video-thumbnail img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.video-card:hover .video-thumbnail img {
  transform: scale(1.08);
}

.video-duration {
  position: absolute;
  bottom: 8px;
  right: 8px;
  background: rgba(0,0,0,0.85);
  color: var(--white);
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.video-play-icon {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 64px;
  height: 64px;
  background: rgba(0,122,255,0.9);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: all 0.3s ease;
  backdrop-filter: saturate(180%) blur(10px);
}

.video-card:hover .video-play-icon {
  opacity: 1;
  transform: translate(-50%, -50%) scale(1.1);
}

.video-play-icon svg {
  width: 28px;
  height: 28px;
  fill: var(--white);
  margin-left: 4px; /* Visual centering */
}

.video-info {
  padding: 16px;
}

.video-title {
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: var(--white);
  margin-bottom: 8px;
  line-height: 1.4;
  letter-spacing: -0.01em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.video-stats {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 13px;
  color: rgba(255,255,255,0.5);
  letter-spacing: -0.01em;
}

.video-stats span {
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Video Player Modal */
.video-modal-box {
  background: rgba(18,18,20,0.98);
  border: 1.5px solid rgba(0,122,255,0.3);
  border-radius: 20px;
  width: 90vw;
  max-width: 1200px;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  backdrop-filter: saturate(180%) blur(20px);
}

.video-player-container {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 aspect ratio */
  background: #000;
  border-radius: 20px 20px 0 0;
  overflow: hidden;
}

.video-player-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.video-modal-info {
  padding: 24px;
}

.video-modal-info h3 {
  font-family: 'Inter', sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.video-modal-info p {
  font-size: 14px;
  color: rgba(255,255,255,0.7);
  line-height: 1.6;
  margin-bottom: 16px;
  letter-spacing: -0.01em;
}

.video-modal-stats {
  display: flex;
  gap: 20px;
  font-size: 13px;
  color: rgba(255,255,255,0.5);
  letter-spacing: -0.01em;
}

/* Loading Animation */
@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Responsive */
@media (max-width: 768px) {
  .channel-banner {
    flex-direction: column;
    text-align: center;
    padding: 24px;
  }
  
  .channel-banner img {
    width: 80px;
    height: 80px;
  }
  
  .channel-details h2 {
    font-size: 22px;
  }
  
  .videos-grid {
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 0 16px;
  }
  
  .video-modal-box {
    width: 95vw;
  }
  
  .video-modal-info {
    padding: 16px;
  }
  
  .video-modal-info h3 {
    font-size: 18px;
  }
}
