# CSS and @import

**URL:** <https://discourse.gohugo.io/t/css-and-import/42901>\
**Category:** support\
**Created:** [February 10, 2023, 9:03pm UTC](https://discourse.gohugo.io/t/css-and-import/42901 "2023-02-10T21:03:25Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![jmooring](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.gohugo.io/jmooring/32/4214_2.png) [@jmooring](https://discourse.gohugo.io/u/jmooring)\
**Post date:** [February 10, 2023, 9:51pm UTC](https://discourse.gohugo.io/t/css-and-import/42901/4 "2023-02-10T21:51:51Z")

</div>

Assuming that I understand your objective…

@import in a CSS file reference the other files, it does not import them in the same way that Sass does during transpilation.

So I think you would need to:

1) Name your CSS files so that when sorted they are concatenated in the correct order:

```plaintext
01_main.css
02_reset.css
03_vars.css
04_layout.css

```

2) Use `resources.Match "*.css"` to get all of them.

3) Sort them (`resources.Match` may already do that… I don’t remember).

4) Concatenate them with `resources.Concat`.

---

_[View the full topic](https://discourse.gohugo.io/t/css-and-import/42901)._
