### Bug description

# Problem

I'm trying to customize the category labels in blog posts and on the listings page via a custom theme. This theme is defined via a file `theme.scss` and contains the following content:

```
/*-- scss:defaults --*/

$primary: #06436e  !default;
$white: #fff  !default;

/*-- scss:rules --*/
// This works and changes the tag appearance on the listing page
div.quarto-post .listing-categories .listing-category {
  background-color: $primary;
  color: $white;
  font-size: 14px;
  font-weight: 600;
  text-transform: none;
  border-radius: 0.25cm;
}

// This does not work: The output contains a opacity less than 1.
.quarto-title .quarto-categories .quarto-category {
  opacity: 1;
  color: $white;
  background-color: $primary;
}
```

The first rule works nicely and the tag labels on the listing pages change. However, the second rule does not work and the tags are not displayed properly in the blog posts. This is because in the rendered file `bootstrap.min.css`, I can find both my code and a few lines further down

```
.quarto-title .quarto-categories .quarto-category {
 padding:.25em .75em;
 font-size:.65em;
 text-transform:uppercase;
 border:solid 1px;
 border-radius:.25rem;
 opacity:.6
}
```

I suspect that this is some default bootstrap setting and these overwrite the changes that I want to make. A workaround is to create an additional CSS file and include it in the blog via `_quarto.yml`.  

Related problem: My initial workaround was to include the CSS file in each blog post with `include-in-header` in `posts/_metadata.yml`. Unfortunately, this incorporated the CSS file as text into the blog post instead of into the header.

# Reprex

Can be found at https://github.com/AlbertRapp/bootstrap_quarto_blog

# System Information


```
[✓] Checking Quarto installation......OK
      Version: 0.9.385
      Path: /opt/quarto/bin

[✓] Checking basic markdown render....OK

[✓] Checking Python 3 installation....OK
      Version: 3.8.10
      Path: /usr/bin/python3
      Jupyter: (None)

      Jupyter is not available in this Python installation.
      Install with python3 -m pip install jupyter

[✓] Checking R installation...........OK
      Version: 4.2.0
      Path: /usr/lib/R
      LibPaths:
        - /home/albert/R/x86_64-pc-linux-gnu-library/4.2
        - /usr/local/lib/R/site-library
        - /usr/lib/R/site-library
        - /usr/lib/R/library
      rmarkdown: 2.14

[✓] Checking Knitr engine render......OK

RStudio
2022.02.3 Build 492
© 2009-2022 RStudio, PBC

No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 20.04.4 LTS
Release:	20.04
Codename:	focal
```


### Checklist

- [X] [formatted your issue](https://yihui.org/issue/#please-format-your-issue-correctly) so it is easier for us to read?
- [X] included a minimal, self-contained, and reproducible example?
- [X] documented the quarto version you're running, by providing the output produced by `quarto check` in a terminal in your issue?
- [X] documented the RStudio IDE version you're running (if applicable), by providing the value displayed in the "About RStudio" main menu dialog?
- [X] documented which operating system you're running? If on Linux, please provide the specific distribution as well.
- [ ] upgraded to the latest version, including your versions of R, the RStudio IDE, and relevant R packages?
dragonstyle
2022-06-25T14:22:58Z
AlbertRapp
bug
1.0
closed
Bootstrap changes get overwritten in blog posts
https://github.com/quarto-dev/quarto-cli/issues/1223