name: Bug report
description: Report a bug or unexpected behavior
labels: ["bug"]
body:
  - type: markdown
    attributes:
      value: |
        Thanks for reporting a bug!

  - type: textarea
    id: description
    attributes:
      label: Description
      description: What happened?
    validations:
      required: true

  - type: textarea
    id: expected-behavior
    attributes:
      label: Expected behavior
      description: What should have happened instead?
    validations:
      required: true

  - type: textarea
    id: steps-to-reproduce
    attributes:
      label: Steps to reproduce
      description: How can we reproduce the issue?
      placeholder: |
        1. Go to ...
        2. Click on ...
        3. See error
    validations:
      required: true

  - type: dropdown
    id: scope
    attributes:
      label: Scope
      options:
        - Frontend
        - Backend
        - Infra / CI
        - Full-stack
    validations:
      required: true

  - type: dropdown
    id: severity
    attributes:
      label: Severity
      options:
        - Critical (app crash / data loss)
        - Major (feature broken)
        - Minor (cosmetic / workaround exists)
    validations:
      required: true

  - type: textarea
    id: environment
    attributes:
      label: Environment
      description: Browser, OS, deployment mode (Docker remote/local, dev), version
      placeholder: "Chrome 124, macOS, Docker remote, v0.3.0"
    validations:
      required: false
