.category {
  position: relative;
  overflow: hidden;
  background: var(--paper);
}

.category::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("../../img/category-paper-texture.webp") center / cover no-repeat;
  filter: var(--paper-texture-filter);
  mix-blend-mode: var(--paper-texture-blend-mode);
  opacity: 0;
  pointer-events: none;
}

.category__banner {
  position: relative;
  overflow: hidden;
  background: var(--red);
}

.category__banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  background-image: url("../../img/category-banner-texture.webp");
  mix-blend-mode: overlay;
  opacity: 0.9;
}

.category__banner-inner {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  padding: 4rem 1rem 3rem;
}

.category__hero {
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(100%, 24rem);
  height: clamp(10rem, 32vw, 14rem);
  margin-inline: auto;
}

.category__hero img {
  display: block;
  width: auto;
  height: 100%;
  max-width: 100%;
  object-fit: contain;
  object-position: center;
  margin-inline: auto;
}

.category__inner {
  padding-top: 3rem;
  padding-bottom: 4.5rem;
}

.category__grid {
  display: grid;
  gap: 2rem;
}

@media (min-width: 48rem) {
  .category::before {
    opacity: calc(var(--paper-texture-opacity) * 0.45);
  }

  .category__banner-inner {
    flex-direction: row;
    padding: 5rem 1.5rem 4rem;
  }

  .category--reverse .category__banner-inner {
    flex-direction: row-reverse;
  }

  .category__hero {
    width: min(32vw, 25rem);
    height: clamp(12rem, 18vw, 16rem);
  }

  .category--foreign .category__hero,
  .category--democracy .category__hero {
    width: min(40vw, 34rem);
    height: clamp(14rem, 22vw, 20rem);
  }

  .category__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4rem;
    align-items: start;
  }

  .demand-card--wide {
    grid-column: 1 / span 2;
    width: min(100%, 34rem);
    margin-inline: auto;
  }
}
@media (min-width: 64rem) {
  .category__hero {
    width: min(30vw, 26rem);
    height: clamp(13rem, 17vw, 17rem);
  }

  .category--foreign .category__hero,
  .category--democracy .category__hero {
    width: min(42vw, 36rem);
    height: clamp(15rem, 20vw, 21rem);
  }
}
