.story-viewer {
  display: grid;
  gap: 1rem;
  padding: 1rem;
  max-width: min(960px, 100%);
  margin: 0 auto;
}

.story-toolbar {
  margin: 0;
}

.story-viewer__title {
  margin: 0;
  text-align: left;
}

.story-viewer__description,
.story-viewer__progress {
  color: #475569;
}

.story-viewer__scene {
  background: #f8fafc;
  border: 1px solid #dbe4ee;
  border-radius: 12px;
  padding: 1rem;
}

.story-viewer__scene h3 {
  margin-top: 0;
}

.story-viewer__choices {
  display: grid;
  gap: 0.75rem;
}

.story-choice {
  border: 0;
  box-shadow: inset 0 0 0 1px rgba(99, 102, 241, 0.26);
  background: #fff;
  border-radius: 0.9rem;
  padding: 0.95rem 1rem;
  text-align: left;
  cursor: pointer;
  color: var(--book-accent, #6366f1);
  font: inherit;
  font-weight: 600;
  transition: background 0.15s ease, color 0.15s ease, transform 0.12s ease, box-shadow 0.15s ease;
}

.story-choice:hover,
.story-choice:focus-visible {
  background: rgba(99, 102, 241, 0.14);
  box-shadow: 0 12px 30px rgba(99, 102, 241, 0.22);
  color: var(--book-accent, #6366f1);
  transform: translateY(-1px);
  outline: none;
}

.story-viewer--error {
  border-left: 4px solid #dc2626;
}

@media (max-width: 760px) {
  .story-viewer__progress {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
  }

  .story-viewer {
    padding: 0.75rem;
  }
}
