/**
 * Golcam Video Cards Component
 * Part of the Golcam redesign system
 * This file contains styles for video cards used throughout the site
 * Designed to work with the main home-layout.css design system
 */

/* Video Card Grid - Mobile First Design */
.gc-video-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;
  margin-bottom: 20px;
}

/* Tablet: 2 cards per row */
@media (min-width: 768px) {
  .gc-video-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 25px;
  }
}

/* Desktop: 3 cards per row */
@media (min-width: 992px) {
  .gc-video-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
  }
}

/* Animation keyframes */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Video Card Component */
.gc-video-card {
  background-color: var(--gc-card-bg, #ffffff);
  border-radius: var(--gc-border-radius, 8px);
  box-shadow: 0 2px 16px rgb(0 0 0 / 17%);
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  position: relative;
  height: 100%;
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
  animation-play-state: paused;
}

.gc-video-card.visible {
  animation-play-state: running;
}

.gc-video-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 20px rgba(0, 0, 0, 0.12);
}

/* Card Tag Badges */
.gc-tag {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--gc-primary-color, #2a5298);
  color: white;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  z-index: 5;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.gc-tag-category {
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--gc-accent-color, #e74c3c);
  color: white;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  z-index: 5;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

/* Card Media Section */
.gc-card-media {
  position: relative;
  aspect-ratio: 16/9;
  background-color: #f5f5f5;
  overflow: hidden;
}

.gc-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.gc-video-card:hover .gc-card-media img {
  transform: scale(1.05);
}

/* Play Button Overlay */
.gc-play-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.9);
  width: 60px;
  height: 60px;
  background-color: rgba(0, 0, 0, 0.7);
  border-radius: 50%;
  opacity: 0;
  transition: all 0.3s ease;
  z-index: 5;
}

.gc-play-button::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 53%;
  transform: translate(-50%, -50%);
  width: 0;
  height: 0;
  border-top: 15px solid transparent;
  border-bottom: 15px solid transparent;
  border-left: 22px solid white;
}

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

/* User Avatar */
.gc-user-avatar {
  position: absolute;
  bottom: -20px;
  left: 20px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 3px solid white;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  z-index: 5;
  background-color: white;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.gc-user-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gc-user-avatar i {
  color: #999;
  font-size: 20px;
}

/* Watched Badge */
.gc-watched-badge {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background-color: rgba(46, 204, 113, 0.9);
  color: white;
  font-size: 12px;
  font-weight: 500;
  padding: 4px 10px;
  border-radius: 20px;
  z-index: 5;
  display: flex;
  align-items: center;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.gc-watched-badge i {
  margin-right: 5px;
}

/* Duration Badge */
.gc-duration-badge {
  position: absolute;
  bottom: 12px;
  left: 12px;
  background-color: rgba(0, 0, 0, 0.7);
  color: white;
  font-size: 12px;
  font-weight: 500;
  padding: 4px 8px;
  border-radius: 4px;
  z-index: 5;
}

/* Card Content Section */
.gc-card-content {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  position: relative;
  background: #fff;
  box-shadow: 0 2px 16px rgb(0 0 0 / 17%);
}

/* Video Title */
.gc-video-title {
  font-size: 16px;
  font-weight: 600;
  margin: 10px 0;
  line-height: 1.4;
  color: var(--gc-text-color, #2c3e50);
  padding-right: 30px;
}

.gc-video-title a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

.gc-video-title a:hover {
  color: var(--gc-primary-color, #3498db);
}

/* User Info */
.gc-user-info {
  display: flex;
  align-items: center;
  margin-bottom: 10px;
}

.gc-user-info a {
  color: var(--gc-primary-color, #3498db);
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s ease;
}

.gc-user-info a:hover {
  color: var(--gc-primary-dark, #2980b9);
  text-decoration: underline;
}

.gc-user-info p {
  margin: 0 0 0 5px;
  font-size: 13px;
  color: var(--gc-text-muted, #7f8c8d);
}

/* Like Button */
.gc-like-button {
  position: absolute;
  top: 20px;
  right: 20px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  transition: transform 0.2s ease;
}

.gc-like-button i {
  font-size: 22px;
  color: #e0e0e0;
  transition: all 0.3s ease;
}

.gc-like-button:hover i {
  color: var(--gc-accent-color, #e74c3c);
  transform: scale(1.1);
}

.gc-like-button.liked i {
  color: var(--gc-accent-color, #e74c3c);
}

/* Card Meta */
.gc-card-meta {
  margin-top: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 15px;
  border-top: 1px solid var(--gc-border-color, #f0f0f0);
}

.gc-meta-item {
  display: flex;
  align-items: center;
  font-size: 13px;
  color: var(--gc-text-muted, #7f8c8d);
}

.gc-meta-item i {
  font-size: 14px;
  margin-right: 5px;
  color: var(--gc-text-muted, #95a5a6);
}

/* Edit Controls */
.gc-edit-controls {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 15px;
}

.gc-edit-controls .gc-btn {
  background-color: #f8f9fa;
  border: 1px solid #e0e0e0;
  border-radius: 20px;
  padding: 5px 12px;
  font-size: 13px;
  color: #5a6268;
  cursor: pointer;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
}

.gc-edit-controls .gc-btn i {
  margin-right: 5px;
}

.gc-edit-controls .gc-btn-edit {
  background-color: #e8f4fd;
  color: var(--gc-primary-color, #3498db);
  border-color: #cee5f7;
}

.gc-edit-controls .gc-btn-edit:hover {
  background-color: #d1e7fc;
  color: var(--gc-primary-dark, #2980b9);
}

.gc-edit-controls .gc-btn-delete {
  background-color: #feecec;
  color: var(--gc-accent-color, #e74c3c);
  border-color: #facdcd;
}

.gc-edit-controls .gc-btn-delete:hover {
  background-color: #fdd9d7;
  color: var(--gc-accent-dark, #c0392b);
}

/* Owner Highlight */
.gc-video-card.gc-owner-video {
  border: 2px solid rgba(241, 196, 15, 0.3);
}

.gc-video-card.gc-owner-video::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 0 30px 30px 0;
  border-color: transparent #f1c40f transparent transparent;
  z-index: 10;
}

/* Gallery Header */
.gc-gallery-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--gc-primary-gradient, linear-gradient(90deg, #1e3c72 0%, #2a5298 100%));
  color: white;
  padding: 15px 20px;
  border-radius: var(--gc-border-radius, 8px) var(--gc-border-radius, 8px) 0 0;
  position: relative;
  margin-bottom: 0;
}

.gc-gallery-header::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--gc-accent-gradient, linear-gradient(90deg, #e74c3c 0%, #f39c12 100%));
}

.gc-gallery-header .gc-header-title {
  display: flex;
  align-items: center;
}

.gc-gallery-header .gc-header-title i {
  font-size: 20px;
  margin-right: 10px;
  color: var(--gc-accent-light, #f39c12);
}

.gc-gallery-header .gc-header-title h3 {
  font-size: 18px;
  font-weight: 600;
  margin: 0;
  letter-spacing: 0.5px;
}

.gc-gallery-header .gc-header-actions a {
  background-color: rgba(255,255,255,0.1);
  color: white;
  padding: 6px 12px;
  border-radius: 50px;
  font-size: 14px;
  text-decoration: none;
  transition: all 0.3s ease;
  display: inline-flex;
  align-items: center;
}

.gc-gallery-header .gc-header-actions a:hover {
  background-color: rgba(255,255,255,0.2);
  transform: translateY(-2px);
}

.gc-gallery-header .gc-header-actions i {
  margin-right: 5px;
}

/* Search Component */
.gc-search-container {
  background-color: white;
  padding: 15px 20px;
  border-bottom: 1px solid var(--gc-border-color, #eee);
  display: flex;
  align-items: center;
}

.gc-search-box {
  position: relative;
  width: 100%;
}

.gc-search-box input {
  width: 100%;
  padding: 12px 20px 12px 45px;
  font-size: 15px;
  border: 1px solid #ddd;
  border-radius: 30px;
  background-color: #f8f9fa;
  transition: all 0.3s ease;
}

.gc-search-box input:focus {
  outline: none;
  border-color: var(--gc-primary-color, #3498db);
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2);
  background-color: white;
}

.gc-search-box i {
  position: absolute;
  left: 18px;
  top: 50%;
  transform: translateY(-50%);
  color: #aaa;
  font-size: 18px;
  transition: color 0.3s ease;
}

.gc-search-box input:focus + i {
  color: var(--gc-primary-color, #3498db);
}

/* Empty Content State */
.gc-empty-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  text-align: center;
  color: var(--gc-text-muted, #7f8c8d);
  background-color: white;
  border-radius: 0 0 var(--gc-border-radius, 8px) var(--gc-border-radius, 8px);
}

.gc-empty-content i {
  font-size: 60px;
  color: #ecf0f1;
  margin-bottom: 20px;
}

.gc-empty-content p {
  font-size: 16px;
  margin: 0;
}

/* Infinite Scroll Loading States */
.gc-page-load-status {
  margin-top: 20px;
}

.gc-infinite-scroll-request {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 30px 0;
}

.gc-infinite-scroll-request p {
  margin-top: 15px;
  color: var(--gc-text-muted, #7f8c8d);
}

.gc-infinite-scroll-last {
  text-align: center;
  padding: 30px 0;
  color: var(--gc-text-muted, #7f8c8d);
  font-weight: 500;
}

/* Modal Styles */
.gc-modal-content {
  border-radius: var(--gc-border-radius, 12px);
  overflow: hidden;
  border: none;
  box-shadow: 0 15px 35px rgba(0,0,0,0.2);
}

.gc-modal-header {
  background: var(--gc-primary-gradient, linear-gradient(90deg, #1e3c72 0%, #2a5298 100%));
  color: white;
  padding: 15px 20px;
  border-bottom: none;
}

.gc-modal-header h4 {
  font-weight: 600;
  margin: 0;
}

.gc-modal-body {
  padding: 20px;
}

.gc-modal-footer {
  border-top: 1px solid var(--gc-border-color, #eee);
  padding: 15px 20px;
}

.gc-modal-footer .gc-btn {
  padding: 8px 16px;
  border-radius: 50px;
  font-weight: 500;
}

/* Delete confirmation modal */
.gc-delete-modal .gc-modal-header {
  background: var(--gc-accent-gradient, linear-gradient(90deg, #cb2d3e 0%, #ef473a 100%));
}

.gc-delete-modal .gc-warning-icon {
  font-size: 60px;
  color: var(--gc-accent-color, #e74c3c);
  margin-bottom: 20px;
  display: block;
  text-align: center;
}

.gc-delete-modal .gc-modal-body {
  text-align: center;
}

.gc-delete-modal h3 {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 15px;
  color: var(--gc-text-color, #2c3e50);
}

.gc-delete-modal p {
  font-size: 15px;
  color: var(--gc-text-muted, #7f8c8d);
  margin-bottom: 20px;
}

/* Responsive Adjustments - already built in from initial mobile-first approach */
@media (max-width: 576px) {
  .gc-gallery-header {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .gc-gallery-header .gc-header-actions {
    width: 100%;
    display: flex;
    justify-content: flex-end;
  }
  
  .gc-search-container {
    padding: 12px 15px;
  }
  
  .gc-card-content {
    padding: 15px;
  }
  
  .gc-video-title {
    font-size: 15px;
  }
  
  .gc-play-button {
    width: 50px;
    height: 50px;
    opacity: 0.8;
    transform: translate(-50%, -50%) scale(1);
  }
}

/* Pagination Styles */
.gc-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin-top: 2rem;
  padding: 1rem;
}

.gc-pagination-item {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 2.5rem;
  height: 2.5rem;
  padding: 0 0.75rem;
  border-radius: 0.5rem;
  background: #fff;
  color: var(--gc-primary-color, #2a5298);
  font-weight: 500;
  text-decoration: none;
  transition: all 0.3s ease;
  border: 1px solid #e0e0e0;
}

.gc-pagination-item:hover {
  background: var(--gc-primary-color, #2a5298);
  color: #fff;
  border-color: var(--gc-primary-color, #2a5298);
  transform: translateY(-2px);
}

.gc-pagination-item.active {
  background: var(--gc-primary-color, #2a5298);
  color: #fff;
  border-color: var(--gc-primary-color, #2a5298);
  pointer-events: none;
}

.gc-pagination-item.disabled {
  opacity: 0.5;
  pointer-events: none;
}

.gc-pagination-item i {
  font-size: 1.1rem;
}

@media (max-width: 576px) {
  .gc-pagination {
    flex-wrap: wrap;
    gap: 0.3rem;
  }
  
  .gc-pagination-item {
    min-width: 2.2rem;
    height: 2.2rem;
    padding: 0 0.5rem;
    font-size: 0.9rem;
  }
}