/* ═══════════════════════════════════════════════════════════════
   ChromaStage Studio v3.0 — Render Progress & Results
   ═══════════════════════════════════════════════════════════════ */

.render-progress {
  padding: 26px;
  background: rgba(10, 15, 27, 0.6);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  text-align: center;
  margin: 10px 0;
}

.render-progress .progress-bar {
  height: 11px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 99px;
  overflow: hidden;
  margin-bottom: 12px;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.5);
}

.render-progress .progress-fill {
  background: linear-gradient(90deg, #6d6df8, #d946ef, #22d3ee, #34d399);
  background-size: 200% 100%;
  animation: shimmer 2s linear infinite;
  height: 100%;
  border-radius: 99px;
  transition: width 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 0 16px rgba(109, 109, 248, 0.5);
}

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

.progress-text {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 12px;
}

.render-progress-actions {
  display: flex;
  justify-content: center;
  gap: 10px;
}

/* ═══ Results ═══ */
.render-result {
  display: flex;
  flex-direction: column;
  gap: 16px;
  animation: resultPop 0.45s cubic-bezier(0.34, 1.4, 0.64, 1) both;
}

@keyframes resultPop {
  from { opacity: 0; transform: scale(0.94) translateY(10px); }
  to { opacity: 1; transform: none; }
}

.result-celebrate {
  font-size: 19px;
  font-weight: 800;
  color: var(--success);
  text-align: center;
  text-shadow: 0 0 22px rgba(52, 211, 153, 0.4);
}

.video-wrapper {
  position: relative;
  width: 100%;
  aspect-ratio: 16/9;
  background: #000;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow), 0 0 40px -8px rgba(99, 102, 241, 0.25);
}

.video-wrapper video {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.result-actions {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.result-stats {
  text-align: center;
  font-size: 13px;
  color: var(--muted);
  background: rgba(10, 15, 27, 0.5);
  padding: 9px 16px;
  border-radius: 10px;
  border: 1px solid var(--line);
  font-variant-numeric: tabular-nums;
}

/* Images Result Grid */
.result-images-toolbar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.result-images-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 12px;
  max-height: 380px;
  overflow-y: auto;
  padding: 4px;
}

.result-img-card {
  position: relative;
  aspect-ratio: 16/9;
  background: #070b14;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.16s, border-color 0.16s, box-shadow 0.16s;
  animation: stepReveal 0.4s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.result-img-card:hover {
  transform: translateY(-3px);
  border-color: var(--primary-hover);
  box-shadow: 0 8px 22px -6px rgba(0, 0, 0, 0.55), 0 0 16px -4px rgba(99, 102, 241, 0.4);
}

.result-img-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.result-img-dl {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 25px;
  height: 25px;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.72);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.15);
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.15s, transform 0.15s;
}

.result-img-dl:hover {
  background: var(--primary);
  transform: scale(1.12);
}

.result-img-meta {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2px 6px;
  background: linear-gradient(transparent, rgba(0, 0, 0, 0.85));
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  color: #fff;
  font-variant-numeric: tabular-nums;
}
