/* ===== CSS Variables ===== */
:root {
  --orange-bg: #E8723C;
  --cream: #FCFCF9;
  --cream-dark: #EAE7E0;
  --teal: #1A7A6E;
  --teal-light: #20A090;
  --text-primary: #1F2937;
  --text-secondary: #6B7280;
  --text-muted: #9CA3AF;
  --border-color: #E5E7EB;
  --white: #FFFFFF;
  --sidebar-bg: #FAFAF9;
  --step-dot: #1A7A6E;
  --pill-bg: #F2F3EE;
  --source-hover: #F9FAFB;
  
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1), 0 10px 10px -5px rgba(0,0,0,0.04);
  
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-xl: 20px;
}

/* ===== Reset & Base ===== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

html, body {
  height: 100%;
  overflow: hidden;
}

body {
  font-family: var(--font-sans);
  background: var(--orange-bg);
  color: var(--text-primary);
  line-height: 1.5;
}

/* ===== Proto Wrapper ===== */
.proto-wrapper {
  display: flex;
  height: 100vh;
  padding: 24px;
  gap: 24px;
  overflow: hidden;
}

/* ===== Version Tabs ===== */
.version-tabs {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 32px 0;
  min-width: 80px;
  height: 100%;
}

.version-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 12px 16px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0);
  border-radius: var(--radius-md);
  color: rgba(255,255,255,0.7);
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
}

.version-tab:hover {
  background: rgba(255,255,255,0.15);
  color: var(--white);
}

.version-tab.active {
  background: rgba(255,255,255,0.25);
  border-color: rgba(255,255,255,0.4);
  color: var(--white);
  font-weight: 500;
}

.version-tab .version-tag {
  font-size: 16px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.version-tab .version-desc {
  font-size: 12px;
  opacity: 1;
  white-space: nowrap;
}

.version-divider {
  width: 100%;
  height: 1px;
  background: rgba(255,255,255,0.2);
  margin: 12px 0;
}

/* Version Data Points */
.version-data {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 12px 16px;
  width: 100%;
  margin-top: auto;
}

.data-point {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

.data-value {
  font-size: 20px;
  font-weight: 700;
  color: var(--white);
  text-align: center;
}

.data-label {
  font-size: 12px;
  color: rgba(255,255,255,0.7);
  text-align: center;
  line-height: 1.3;
}

/* Replay Button in Version Panel */
.replay-btn-panel {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 12px;
  background: rgba(255,255,255,0.15);
  border: none;
  border-radius: var(--radius-md);
  color: var(--white);
  cursor: pointer;
  transition: all 0.2s ease;
  width: 100%;
}

.replay-btn-panel:hover {
  background: rgba(255,255,255,0.25);
}

.replay-btn-panel svg {
  width: 20px;
  height: 20px;
}

.replay-btn-panel span {
  font-size: 10px;
  font-weight: 500;
  white-space: nowrap;
}

/* ===== Perplexity Window ===== */
.perplexity-window {
  flex: 1;
  display: flex;
  background: var(--cream);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-xl);
  max-width: 1400px;
  max-height: calc(100vh - 48px);
}

/* ===== Sidebar ===== */
.sidebar {
  width: 64px;
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border-color);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 12px 8px;
}

.sidebar-top {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 16px;
}

.sidebar-bottom {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.sidebar-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 10px 4px;
  background: transparent;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  color: var(--text-secondary);
  transition: all 0.15s ease;
}

.sidebar-btn span {
  font-size: 10px;
  font-weight: 500;
}

.sidebar-btn:hover {
  background: var(--cream-dark);
  color: var(--text-primary);
}

.sidebar-btn.active {
  background: var(--cream-dark);
  color: var(--teal);
}

.sidebar-btn.logo-btn {
  color: var(--teal);
  padding: 12px 4px;
}

.sidebar-btn.logo-btn svg {
  width: 24px;
  height: 24px;
}

.account-btn .account-icon {
  width: 24px;
  height: 24px;
  background: var(--teal);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 9px;
  font-weight: 600;
}

.upgrade-btn {
  position: relative;
}

.upgrade-dot {
  position: absolute;
  top: 8px;
  right: 10px;
  width: 6px;
  height: 6px;
  background: #EF4444;
  border-radius: 50%;
}

/* ===== Main Content ===== */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}

/* ===== Top Header ===== */
.top-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 24px;
  border-bottom: 1px solid var(--border-color);
  background: var(--cream);
}

.header-tabs {
  display: flex;
  gap: 8px;
}

.tab-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  background: transparent;
  border: none;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.15s ease;
}

.tab-btn:hover {
  background: var(--cream-dark);
  color: var(--text-primary);
}

.tab-btn.active {
  color: var(--text-primary);
  border-bottom: 2px solid var(--teal);
  border-radius: 0;
  padding-bottom: 6px;
  margin-bottom: -12px;
}

.download-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--teal);
  color: var(--white);
  border: none;
  border-radius: var(--radius-lg);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
}

.download-btn:hover {
  background: var(--teal-light);
}

/* ===== Content Wrapper ===== */
.content-wrapper {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}

/* ===== Content Area ===== */
.content-area {
  flex: 1;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 24px 48px;
  padding-bottom: 40px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  scroll-behavior: smooth;
}

.content-area > * {
  max-width: 800px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}

/* Custom scrollbar for content area */
.content-area::-webkit-scrollbar {
  width: 8px;
}

.content-area::-webkit-scrollbar-track {
  background: transparent;
}

.content-area::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 4px;
}

.content-area::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}

/* ===== Query Card ===== */
.query-card {
  background: var(--pill-bg);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
}

.query-text {
  font-size: 15px;
  line-height: 1.6;
  color: var(--text-primary);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.show-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  margin-top: 12px;
  padding: 0;
  background: transparent;
  border: none;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.15s ease;
}

.show-more-btn:hover {
  color: var(--text-primary);
}

/* ===== Loading Container ===== */
.loading-container {
  display: flex;
  flex-direction: column;
  gap: 0;
}

/* ===== Loading Block Animation ===== */
.loading-block {
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  max-height: 0;
  overflow: hidden;
}

.loading-block.visible {
  opacity: 1;
  transform: translateY(0);
  max-height: 2000px;
}

.loading-block.collapsed {
  opacity: 0;
  max-height: 0;
  margin: 0;
  padding: 0;
}

/* ===== Working Header ===== */
.working-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0 16px;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
}

.working-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 18px;
  width: 18px;
  color: var(--text-secondary);
  opacity: 0.75;
  perspective: 100px;
}

.working-icon .pplx-loader {
  height: 100%;
  width: auto;
  animation: pplx-spin-3d 1.5s ease-in-out infinite;
  transform-style: preserve-3d;
  will-change: transform;
}

@keyframes pplx-spin-3d {
  0% {
    transform: rotateY(0deg);
  }
  
  100% {
    transform: rotateY(360deg);
  }
  
}

/* Working text shimmer */
.working-header span {
  position: relative;
  background: linear-gradient(
    90deg,
    var(--text-secondary) 0%,
    var(--text-secondary) 30%,
    rgba(255, 255, 255, 0.95) 50%,
    var(--text-secondary) 70%,
    var(--text-secondary) 100%
  );
  background-size: 300% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: working-text-shimmer 1.5s ease-in-out infinite;
}

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

/* ===== Step Block ===== */
.step-block {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  position: relative;
}

.step-indicator {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 6px;
  position: relative;
  overflow: visible; /* Add this */

}

.step-dot {
  width: 10px;
  height: 10px;
  background: var(--step-dot);
  border-radius: 50%;
  position: relative;
  z-index: 2;
  flex-shrink: 0;
}

.step-dot.pulsing {
  animation: pulse-dot 1s ease-in-out infinite;
}

@keyframes pulse-dot {
  0% {
    box-shadow: 0 0 0 0 rgba(26, 122, 110, 0.4);
  }
  100% {
    box-shadow: 0 0 0 6px rgba(26, 122, 110, 0);
  }
}

/* Connecting line */
.step-line {
  width: 2px;
  background: var(--border-color);
  flex-grow: 1;
  margin-top: 4px;
  transform-origin: top;
  transform: scaleY(0);
  transition: transform 0.8s ease-out;
}

.step-line.growing {
  transform: scaleY(0.3);
}

.step-line.half {
  transform: scaleY(0.6);
}

.step-line.visible {
  transform: scaleY(1);
}

.step-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

.step-text {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-primary);
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.3s ease;
}

.step-text.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Searching Section ===== */
.searching-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.3s ease;
}

.searching-section.visible {
  opacity: 1;
  transform: translateY(0);
}

.searching-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  position: relative;
  display: inline-block;
  width: fit-content;
}

/* Shimmer effect using background-clip for text-only highlight */
.searching-label.shimmer,
.sources-label.shimmer,
.searching-label.shimmer-2,
.sources-label.shimmer-2 {
  background: linear-gradient(
    90deg,
    currentColor 0%,
    currentColor 35%,
    rgba(78, 205, 196, 0.9) 45%,
    rgba(78, 205, 196, 0.95) 50%,
    rgba(78, 205, 196, 0.9) 55%,
    currentColor 65%,
    currentColor 100%
  );
  background-size: 250% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmer-text 0.5s ease-in-out forwards;
}

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

.search-pills {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.search-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--pill-bg);
  border-radius: var(--radius-md);
  font-size: 13px;
  color: var(--text-primary);
  width: fit-content;
  opacity: 0;
  transform: translateX(-8px);
  transition: all 0.25s ease;
}

.searching-section.visible .search-pill {
  opacity: 1;
  transform: translateX(0);
}

.searching-section.visible .search-pill:nth-child(1) {
  transition-delay: 0s;
}

.searching-section.visible .search-pill:nth-child(2) {
  transition-delay: 0.1s;
}

.searching-section.visible .search-pill:nth-child(3) {
  transition-delay: 0.2s;
}

.search-pill svg {
  color: var(--text-muted);
  flex-shrink: 0;
}

/* ===== Sources Section ===== */
.sources-section {
  display: flex;
  flex-direction: column;
  gap: 8px;
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.3s ease;
}

.sources-section.visible {
  opacity: 1;
  transform: translateY(0);
}

.sources-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  position: relative;
  display: inline-block;
  width: fit-content;
  overflow: hidden;
}


.source-count {
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.sources-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: var(--white);
  border-radius: var(--radius-md);
  padding: 4px;
  border: 1px solid var(--border-color);
  opacity: 0;
  transform: translateY(8px);
  transition: all 0.3s ease 0.1s;
}

.sources-section.visible .sources-list {
  opacity: 1;
  transform: translateY(0);
}

.source-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.2s ease, transform 0.2s ease, background 0.15s ease;
}

.sources-section.visible .source-card {
  opacity: 1;
  transform: translateY(0);
}

.sources-section.visible .source-card:nth-child(1) { transition-delay: 0.05s; }
.sources-section.visible .source-card:nth-child(2) { transition-delay: 0.1s; }
.sources-section.visible .source-card:nth-child(3) { transition-delay: 0.15s; }
.sources-section.visible .source-card:nth-child(4) { transition-delay: 0.2s; }
.sources-section.visible .source-card:nth-child(5) { transition-delay: 0.25s; }
.sources-section.visible .source-card:nth-child(6) { transition-delay: 0.3s; }
.sources-section.visible .source-card:nth-child(7) { transition-delay: 0.35s; }

.source-card:hover {
  background: var(--source-hover);
}

.source-icon {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--text-muted);
}

.source-icon.globe {
  color: var(--text-secondary);
}

.source-title {
  flex: 1;
  font-size: 14px;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.source-domain {
  font-size: 12px;
  color: var(--text-muted);
  flex-shrink: 0;
}

/* ===== Completed Section ===== */
.completed-section {
  padding: 8px 0;
}

.steps-completed-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 0;
  background: transparent;
  border: none;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-secondary);
  cursor: pointer;
  transition: color 0.15s ease;
}

.steps-completed-btn:hover {
  color: var(--text-primary);
}

/* ===== Answer Section ===== */
.answer-section {
  padding: 8px 0 24px;
}

.answer-text {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-primary);
  margin-bottom: 20px;
}

/* Word-by-word animation */
.answer-text .word,
.answer-heading .word,
.answer-list .word {
  opacity: 0;
  display: inline;
  transition: opacity 0.05s ease;
}

.answer-text .word.visible,
.answer-heading .word.visible,
.answer-list .word.visible {
  opacity: 1;
}

.citation {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  background: var(--pill-bg);
  border-radius: var(--radius-sm);
  font-size: 11px;
  font-weight: 500;
  color: var(--text-secondary);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
}

.answer-heading {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 16px;
}

.answer-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding-left: 20px;
}

.answer-list li {
  font-size: 15px;
  line-height: 1.7;
  color: var(--text-primary);
}

.answer-list li::marker {
  color: var(--text-muted);
}

.answer-list strong {
  font-weight: 600;
}

.answer-list em {
  font-style: italic;
}

/* ===== Follow-up Input ===== */
.followup-input {
  flex-shrink: 0;
  /* background: var(--cream); */
  padding: 16px 48px 20px;
  /* border-top: 1px solid var(--border-color); */
  position: relative;
}

.followup-input-inner {
  max-width: 800px;
  margin: 0 auto;
  position: relative;
}

.followup-input input {
  width: 100%;
  padding: 16px 20px;
  padding-right: 280px;
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  font-size: 15px;
  color: var(--text-primary);
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.followup-input input::placeholder {
  color: var(--text-muted);
}

.followup-input input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(26, 122, 110, 0.1);
}

.input-actions {
  position: absolute;
  right: 8px;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px;
}

.action-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  background: transparent;
  border: none;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.15s ease;
}

.action-btn:hover {
  background: var(--pill-bg);
  color: var(--text-secondary);
}

.send-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--teal);
  border: none;
  border-radius: var(--radius-md);
  color: var(--white);
  cursor: pointer;
  transition: background 0.15s ease;
}

.send-btn:hover {
  background: var(--teal-light);
}

/* ===== Version-specific Animation Variants ===== */

/* V2: No micro-animations */
[data-version="v2"] .working-icon .pplx-loader {
  animation: none !important;
}

[data-version="v2"] .working-header span {
  animation: none !important;
  background: none !important;
  -webkit-text-fill-color: inherit !important;
  color: var(--text-secondary) !important;
}

[data-version="v2"] .step-dot.pulsing {
  animation: none !important;
}

[data-version="v2"] .searching-label.shimmer,
[data-version="v2"] .sources-label.shimmer,
[data-version="v2"] .searching-label.shimmer-2,
[data-version="v2"] .sources-label.shimmer-2 {
  animation: none !important;
  background: none !important;
  -webkit-text-fill-color: inherit !important;
}

[data-version="v2"] .searching-label {
  color: var(--text-secondary) !important;
}

[data-version="v2"] .sources-label {
  color: var(--text-secondary) !important;
}

/* V3: Slower animations (2x duration) */
[data-version="v3"] .working-icon .pplx-loader {
  animation-duration: 3s !important;
}

[data-version="v3"] .working-header span {
  animation-duration: 3s !important;
}

[data-version="v3"] .step-dot.pulsing {
  animation-duration: 2s !important;
}

[data-version="v3"] .loading-block {
  transition-duration: 0.8s !important;
}

[data-version="v3"] .step-text {
  transition-duration: 0.6s !important;
  display: none !important;
}

[data-version="v3"] .searching-section {
  display: none !important;
}

[data-version="v3"] .sources-section {
  transition-duration: 0.6s !important;
}

[data-version="v3"] .step-indicator {
  display: none !important;
}

[data-version="v3"] .step-block {
  padding: 0 !important;
}

[data-version="v3"] .step-content {
  width: 100%;
}

[data-version="v3"] .sources-section {
  margin-top: 0 !important;
}

[data-version="v3"] .search-pill {
  transition-duration: 0.5s !important;
}

[data-version="v3"] .source-card {
  transition-duration: 0.4s !important;
}

[data-version="v3"] .step-line {
  transition-duration: 1.2s !important;
}

/* V5: Single source box with no counter */
[data-version="v5"] .working-icon .pplx-loader {
  animation-duration: 2.5s !important;
}

[data-version="v5"] .working-header span {
  animation-duration: 2.5s !important;
}

/* Hide regular step blocks for v5 */
[data-version="v5"] .step-block[data-step="1"],
[data-version="v5"] .step-block[data-step="2"],
[data-version="v5"] .step-block[data-step="3"] {
  display: none !important;
}

/* Show v5 sources box only for v5 */
[data-version="v5"] .v5-sources-box {
  display: block !important;
}

.v5-sources-box {
  margin-bottom: 24px;
  display: none; /* Hidden by default */
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.4s ease, transform 0.4s ease, max-height 0.5s ease;
}

.v5-sources-box.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Hide counter in v5 label - remove the " · " and count */
.sources-label.v5-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
}

[data-version="v5"] .source-card {
  transition: opacity 0.3s ease, transform 0.3s ease;
}

/* V4: Hide v1-v3 steps, show combined */
[data-version="v4"] .step-block:not(.v4-only) {
  display: none !important;
}

[data-version="v4"] .v4-only {
  display: flex !important;
}

/* V4: Slower working text shimmer */
[data-version="v4"] .working-header span {
  animation-duration: 2.5s !important;
}

/* Hide v4-only for v1-v3, v5 */
[data-version="v1"] .v4-only,
[data-version="v2"] .v4-only,
[data-version="v3"] .v4-only,
[data-version="v5"] .v4-only {
  display: none !important;
}

/* Hide v5-sources-box for v1-v4 */
[data-version="v1"] .v5-sources-box,
[data-version="v2"] .v5-sources-box,
[data-version="v3"] .v5-sources-box,
[data-version="v4"] .v5-sources-box {
  display: none !important;
}

/* ===== Responsive ===== */
@media (max-width: 1200px) {
  .proto-wrapper {
    padding: 16px;
    gap: 16px;
  }
  
  .content-area {
    padding: 24px;
  }
}

@media (max-width: 900px) {
  .version-label {
    min-width: 40px;
  }
  
  .version-tag {
    font-size: 18px;
  }
  
  .sidebar {
    width: 56px;
  }
  
  .sidebar-btn span {
    display: none;
  }
}

