# Utility Classes & Vars

With the flexibility of Core Framework, we offer options where you can create utility classes from variables.&#x20;

In this example, the Spacing section allows you to generate 3 different sets of utility classes ranging from gap, margin, and padding:

<figure><img src="/files/RRmOZyw6kZGRxlCLwpeE" alt=""><figcaption><p>Options to create utility classes</p></figcaption></figure>

This will automatically create utility classes using all of the variables created from the section above it. In the CSS, you will see that many new classes have been generated.&#x20;

For example, `.gap-m` will now have a value of `var(--space-m)` applied to it. Very powerful stuff! 🔥

## Creating new Groups

### Create a selector group

Creating a new group is very simple. At the bottom of the section you're in, simply click on the "Create a selector group" button. Enter a name for your group and then start adding your selectors along with the properties and values!

{% hint style="info" %}
You may notice that adding values will bring up a list of your existing variables! 🔥
{% endhint %}

<figure><img src="/files/T7ddfvqOvb7ACpsxRUa6" alt=""><figcaption><p>Adding new selectors</p></figcaption></figure>

### Create a variable group

To create a new variable group, simply click on the "Create a variable group" button at the bottom right. Then, give the group a name and start adding your variables. You'll notice that your variables will always be prefixed with --.

<figure><img src="/files/MDiKkef0ZhkfgDxGGAS1" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.coreframework.com/navigating-the-ui/utility-classes-and-vars.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
