/* Hero split-window before/after demo — flat surfaces, no glow / gradient chrome */

.hero-demo {
  width: 100%;
  max-width: 680px;
  margin-left: auto;
  padding: 0;
  border-radius: 12px;
  background: transparent;
  box-shadow: none;
}

.hero-demo .demo-window {
  border: none;
  border-radius: 12px;
  max-width: none;
  margin-left: 0;
  box-shadow: none;
}

.demo-window {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  overflow: hidden;
  width: 100%;
  max-width: 640px;
  margin-left: auto;
  user-select: none;
}

.demo-chrome {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  background: var(--color-surface-2);
  border-bottom: 1px solid var(--color-border);
}

.demo-dots {
  display: flex;
  gap: 5px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.dot-red { background: #ff5f57; }
.dot-yellow { background: #ffbd2e; }
.dot-green { background: #28c840; }

.demo-url {
  flex: 1;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 11px;
  color: var(--color-text-secondary);
  display: flex;
  align-items: center;
  gap: 5px;
}

.demo-ext-badge {
  font-size: 10px;
  font-weight: 600;
  background: var(--color-accent-light);
  border: 1px solid color-mix(in srgb, var(--color-accent) 30%, transparent);
  color: var(--color-accent);
  border-radius: 20px;
  padding: 3px 8px;
  white-space: nowrap;
}

.demo-viewport {
  position: relative;
  height: 420px;
  overflow: hidden;
  display: flex;
  --divider-pos: 50%;
}

.demo-side {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 100%;
  display: flex;
  overflow: hidden;
}

.demo-dirty {
  left: 0;
  clip-path: inset(0 calc(100% - var(--divider-pos)) 0 0);
}

.demo-clean {
  right: 0;
  clip-path: inset(0 0 0 var(--divider-pos));
}

.demo-sidebar {
  width: 88px;
  flex-shrink: 0;
  background: var(--color-surface);
  border-right: 1px solid var(--color-border);
  padding: 12px 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.clean-sidebar {
  background: var(--color-surface-2);
}

.sidebar-item {
  font-size: 10px;
  color: var(--color-text-muted);
  padding: 6px 8px;
  border-radius: 6px;
  cursor: default;
}

.sidebar-item.active {
  background: var(--color-accent-light);
  color: var(--color-accent);
  font-weight: 600;
}

.demo-chat {
  flex: 1;
  padding: 12px;
  position: relative;
  background: var(--color-bg);
  overflow: hidden;
}

.demo-label-strip {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-align: center;
  padding: 4px 8px;
  border-radius: 4px;
  margin-bottom: 10px;
}

.dirty-strip {
  background: var(--color-danger-subtle);
  color: var(--color-danger);
  border: 1px solid color-mix(in srgb, var(--color-accent) 25%, transparent);
}

.clean-strip {
  background: var(--color-success-subtle);
  color: var(--color-success);
  border: 1px solid var(--color-success-border);
}

.chat-msg {
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
  align-items: flex-start;
}

.msg-avatar {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  flex-shrink: 0;
}

.user-av {
  background: var(--color-surface-2);
  color: var(--color-text-secondary);
}

.ai-av {
  background: var(--color-surface-2);
  color: var(--color-text-primary);
}

.clean-av {
  background: var(--color-success-subtle);
  color: var(--color-success);
}

.msg-bubble {
  font-size: 11px;
  line-height: 1.45;
  padding: 8px 10px;
  border-radius: 10px;
  max-width: calc(100% - 40px);
}

.user-bubble {
  background: var(--color-surface-2);
  color: var(--color-text-primary);
  border: 1px solid var(--color-border);
}

.ai-bubble {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  color: var(--color-text-secondary);
}

.clean-bubble {
  border-color: var(--color-success-border);
}

.sponsored-badge {
  display: inline-block;
  font-size: 9px;
  font-weight: 700;
  color: var(--color-danger);
  margin-bottom: 4px;
}

.sponsored-text {
  color: var(--color-text-muted);
  font-size: 10px;
}

.clean-badge {
  display: inline-block;
  font-size: 9px;
  font-weight: 700;
  color: var(--color-success);
  margin-bottom: 4px;
}

.upgrade-modal {
  position: absolute;
  inset: 0;
  background: rgba(7, 6, 8, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 5;
  padding: 12px;
}

.upgrade-inner {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  padding: 14px;
  max-width: 220px;
  text-align: center;
}

.upgrade-title {
  font-size: 12px;
  font-weight: 700;
  color: var(--color-text-primary);
  margin-bottom: 6px;
}

.upgrade-sub {
  font-size: 10px;
  color: var(--color-text-muted);
  margin-bottom: 10px;
  line-height: 1.4;
}

.upgrade-btn {
  background: var(--color-accent);
  color: var(--color-accent-text);
  font-size: 10px;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 8px;
  margin-bottom: 6px;
}

.upgrade-skip {
  font-size: 9px;
  color: var(--color-text-muted);
}

.tracking-bar,
.blocked-bar {
  position: absolute;
  bottom: 8px;
  left: 8px;
  right: 8px;
  font-size: 10px;
  padding: 5px 10px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.tracking-bar {
  background: var(--color-danger-subtle);
  border: 1px solid color-mix(in srgb, var(--color-accent) 22%, transparent);
  color: var(--color-danger);
}

.blocked-bar {
  background: var(--color-success-subtle);
  border: 1px solid var(--color-success-border);
  color: var(--color-success);
}

.demo-divider {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--divider-pos, 50%);
  transform: translateX(-50%);
  width: 3px;
  background: var(--color-accent);
  box-shadow: none;
  cursor: col-resize;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: center;
}

.divider-handle {
  width: 36px;
  height: 36px;
  background: var(--color-accent);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent-text);
  box-shadow: none;
  flex-shrink: 0;
}

.divider-handle svg {
  width: 18px;
  height: 18px;
}

@media (max-width: 767px) {
  .hero-demo {
    max-width: 100%;
    margin-left: 0;
  }

  .hero-demo .demo-window {
    border-radius: 12px;
  }

  .demo-window {
    max-width: 100%;
    margin-left: 0;
  }

  .demo-viewport {
    height: 340px;
  }

  .demo-sidebar {
    width: 76px;
    padding: 10px 5px;
  }

  .sidebar-item {
    font-size: 9px;
    padding: 4px 6px;
  }

  .divider-handle {
    width: 32px;
    height: 32px;
  }

  .divider-handle svg {
    width: 16px;
    height: 16px;
  }
}
