# Resize category banners

**URL:** <https://meta.discourse.org/t/resize-category-banners/216641>\
**Category:** Product Support\
**Created:** [January 31, 2022, 10:34pm UTC](https://meta.discourse.org/t/resize-category-banners/216641 "2022-01-31T22:34:54Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![Don](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/don/32/228726_2.png) [@Don](https://meta.discourse.org/u/Don)\
**Post date:** [February 8, 2022, 9:37am UTC](https://meta.discourse.org/t/resize-category-banners/216641/3 "2022-02-08T09:37:56Z")

</div>

Hello,

I think it cause this css

```scss
.category-logo.aspect-image {
  width: calc(var(--max-height) * var(--aspect-ratio));
}

```

Here the max-height is 150px and the aspect ratio depending by the image. It means if you have an image with aspect ratio 6… then it will be 150 x 6 = 900px width image. So it depending the image aspect ratio.

But you can overwrite this calculation…_(not this but it will affect it)_ with the following.  
Add a fix max-width to the image. So the image cannot be wider than this value.  
Add the following to mobile css section.

```scss
.category-list .category-logo.aspect-image {
  max-width: 250px;
}

```

* * *

Or you can try something like this on mobile. It will calculate the viewport max width and align the image to this.

```scss
.category-list .category-logo.aspect-image {
  max-width: calc(100vw - 2.5em);
}

```

---

_[View the full topic](https://meta.discourse.org/t/resize-category-banners/216641)._
