/* Shuffle Cache Refresh Demo Styles */

.shuffle-cache-refresh-demo {
  max-width: 800px;
  margin: 0 auto;
  padding: 20px;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

.demo-header {
  text-align: center;
  margin-bottom: 30px;
}

.demo-header h2 {
  color: #333;
  margin-bottom: 10px;
  font-size: 24px;
}

.demo-header p {
  color: #666;
  font-size: 16px;
  margin: 0;
}

/* Shuffle Control */
.shuffle-control {
  display: flex;
  gap: 15px;
  justify-content: center;
  margin-bottom: 30px;
  flex-wrap: wrap;
}

.shuffle-button {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border: 2px solid #007AFF;
  border-radius: 8px;
  background: white;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 16px;
  font-weight: 500;
}

.shuffle-button.enabled {
  background: #007AFF;
  color: white;
}

.shuffle-button.disabled {
  background: white;
  color: #007AFF;
}

.shuffle-button:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0, 122, 255, 0.3);
}

.shuffle-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.manual-refresh-button {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border: 2px solid #34C759;
  border-radius: 8px;
  background: white;
  color: #34C759;
  cursor: pointer;
  transition: all 0.2s ease;
  font-size: 16px;
  font-weight: 500;
}

.manual-refresh-button:hover:not(:disabled) {
  background: #34C759;
  color: white;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(52, 199, 89, 0.3);
}

.manual-refresh-button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Cache Refresh Status */
.cache-refresh-status {
  background: #f8f9fa;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 30px;
  border: 1px solid #e9ecef;
}

.cache-refresh-status h3 {
  margin: 0 0 15px 0;
  color: #333;
  font-size: 18px;
}

/* Error Message */
.error-message {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: #ffebee;
  border: 1px solid #ffcdd2;
  border-radius: 8px;
  margin-bottom: 15px;
}

.error-icon {
  font-size: 18px;
}

.error-text {
  flex: 1;
  color: #c62828;
  font-weight: 500;
}

.clear-error-button {
  padding: 4px 12px;
  background: #f44336;
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 12px;
}

.clear-error-button:hover {
  background: #d32f2f;
}

/* Refresh Progress */
.refresh-progress {
  background: white;
  border-radius: 8px;
  padding: 16px;
  border: 1px solid #e3f2fd;
}

.progress-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.progress-icon {
  font-size: 18px;
  animation: spin 1s linear infinite;
}

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

.progress-title {
  font-weight: 600;
  color: #1976d2;
}

.progress-bar {
  width: 100%;
  height: 8px;
  background: #e3f2fd;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 12px;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, #1976d2, #42a5f5);
  border-radius: 4px;
  transition: width 0.3s ease;
}

.progress-details {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 14px;
  color: #666;
  margin-bottom: 8px;
}

.progress-percentage {
  font-weight: 600;
  color: #1976d2;
}

.progress-status {
  font-size: 12px;
  color: #888;
  font-style: italic;
}

/* Refresh Complete */
.refresh-complete {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: #e8f5e8;
  border: 1px solid #c8e6c9;
  border-radius: 8px;
  color: #2e7d32;
  font-weight: 500;
}

.complete-icon {
  font-size: 18px;
}

/* Refresh Idle */
.refresh-idle {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: #f3f4f6;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  color: #6b7280;
}

.idle-icon {
  font-size: 18px;
}

/* Offline Indicator Section */
.offline-indicator-section {
  background: #f8f9fa;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 30px;
  border: 1px solid #e9ecef;
}

.offline-indicator-section h3 {
  margin: 0 0 15px 0;
  color: #333;
  font-size: 18px;
}

/* Feature Description */
.feature-description {
  background: #f8f9fa;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 30px;
  border: 1px solid #e9ecef;
}

.feature-description h3 {
  margin: 0 0 15px 0;
  color: #333;
  font-size: 18px;
}

.feature-description ul {
  margin: 0;
  padding-left: 20px;
}

.feature-description li {
  margin-bottom: 8px;
  color: #555;
  line-height: 1.5;
}

.feature-description strong {
  color: #333;
}

/* Requirements Mapping */
.requirements-mapping {
  background: #e3f2fd;
  border-radius: 12px;
  padding: 20px;
  border: 1px solid #bbdefb;
}

.requirements-mapping h3 {
  margin: 0 0 15px 0;
  color: #1565c0;
  font-size: 18px;
}

.requirements-mapping ul {
  margin: 0;
  padding-left: 20px;
}

.requirements-mapping li {
  margin-bottom: 8px;
  color: #1976d2;
  line-height: 1.5;
}

.requirements-mapping strong {
  color: #0d47a1;
}

/* Responsive Design */
@media (max-width: 768px) {
  .shuffle-cache-refresh-demo {
    padding: 15px;
  }
  
  .shuffle-control {
    flex-direction: column;
    align-items: center;
  }
  
  .shuffle-button,
  .manual-refresh-button {
    width: 100%;
    max-width: 300px;
    justify-content: center;
  }
  
  .progress-details {
    flex-direction: column;
    gap: 4px;
    align-items: flex-start;
  }
}