/* InsertVideo.css */

/* Page Wrapper */
.insert-video-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  box-sizing: border-box;
}

/* Container */
.insert-video-container {
  direction: rtl;
  width: 100%;
  max-width: 500px;
  padding: 24px;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

/* Title */
.insert-video-title {
  color: #fff;
  margin-bottom: 20px;
  font-size: 1.25rem;
  font-weight: 600;
  text-align: center;
}

/* Drop Zone */
.drop-zone {
  border: 2px dashed rgba(102, 126, 234, 0.5);
  border-radius: 12px;
  padding: 40px 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  background: rgba(102, 126, 234, 0.1);
}

.drop-zone:hover {
  border-color: #667eea;
  background: rgba(102, 126, 234, 0.15);
  transform: translateY(-2px);
}

.drop-zone-active {
  border-color: #667eea;
  background: rgba(102, 126, 234, 0.25);
  transform: scale(1.02);
}

/* Hidden Input */
.hidden-input {
  display: none;
}

/* Drop Content */
.drop-content {
  pointer-events: none;
}

.upload-icon {
  font-size: 48px;
  display: block;
  margin-bottom: 12px;
  animation: bounce 2s infinite;
}

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

.drop-text {
  color: #fff;
  margin: 0 0 8px 0;
  font-size: 1rem;
  line-height: 1.6;
}

.drop-sub-text {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
}

.file-info {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.8rem;
  margin: 0;
  margin-top: 8px;
}

/* Error Message */
.error-message {
  color: #ff6b6b;
  font-size: 0.9rem;
  margin-top: 12px;
  padding: 10px 14px;
  background: rgba(255, 107, 107, 0.15);
  border-radius: 8px;
  border: 1px solid rgba(255, 107, 107, 0.3);
  text-align: center;
}

/* File Details */
.file-details {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 16px;
  padding: 12px 16px;
  background: rgba(102, 126, 234, 0.15);
  border-radius: 10px;
  border: 1px solid rgba(102, 126, 234, 0.3);
}

.file-name {
  color: #fff;
  font-size: 0.9rem;
  max-width: 70%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.file-size {
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.85rem;
  background: rgba(255, 255, 255, 0.1);
  padding: 4px 10px;
  border-radius: 6px;
}

/* Preview Container */
.preview-container {
  margin-top: 20px;
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.video-preview {
  width: 100%;
  max-height: 300px;
  display: block;
  background: #000;
}

.clear-btn {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(255, 59, 48, 0.9);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 8px 14px;
  cursor: pointer;
  font-size: 0.85rem;
  font-family: inherit;
  transition: all 0.3s ease;
  backdrop-filter: blur(4px);
}

.clear-btn:hover {
  background: rgba(255, 59, 48, 1);
  transform: scale(1.05);
}

/* Progress Container */
.progress-container {
  margin-top: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.progress-bar {
  flex: 1;
  height: 10px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 5px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #667eea, #764ba2);
  border-radius: 5px;
  transition: width 0.3s ease;
  position: relative;
}

.progress-fill::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

.progress-text {
  color: #fff;
  font-size: 0.9rem;
  min-width: 45px;
  text-align: left;
  font-weight: 600;
}

/* Upload Button */
.upload-btn {
  width: 100%;
  margin-top: 20px;
  padding: 14px 20px;
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: #fff;
  border: none;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.upload-btn:hover:not(.upload-btn-disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
}

.upload-btn:active:not(.upload-btn-disabled) {
  transform: translateY(0);
}

.upload-btn-disabled {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: none;
}

/* Spinner */
.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Responsive */
@media (max-width: 576px) {
  .insert-video-container {
    padding: 16px;
    margin: 0 10px;
  }

  .drop-zone {
    padding: 30px 15px;
  }

  .upload-icon {
    font-size: 36px;
  }

  .drop-text {
    font-size: 0.9rem;
  }

  .file-details {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }

  .file-name {
    max-width: 100%;
  }
}
