> For the complete documentation index, see [llms.txt](https://design-packs.gitbook.io/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://design-packs.gitbook.io/docs/fundamentals/global-section-settings/understanding-inner-padding-and-outer-margin-settings.md).

# Understanding Inner Padding & Outer Margin Settings

Learn how to control section spacing using Inner padding, Outer margin, and custom CSS for more precise control.

### Basic Settings

#### Inner Padding

* Controls space inside the section
* Affects distance between content and section edges
* Single value applies to both top and bottom

#### Outer Margin

* Controls space outside the section
* Affects distance between sections
* Single value applies to both top and bottom

### Using Custom CSS

#### Inner Padding Custom CSS

To set different values for top and bottom padding:

```
/* CSS field */
.dsgn-pck__sizer {
  padding-top: 60px;
  padding-bottom: 40px;
}

/* Mobile CSS field */
.dsgn-pck__sizer {
  padding-top: 40px;
  padding-bottom: 20px;
}
```

#### Outer Margin Custom CSS

To set different values for top and bottom margin:

```
/* CSS field */
{
  margin-top: 80px;
  margin-bottom: 40px;
}

/* Mobile CSS field */
{
  margin-top: 40px;
  margin-bottom: 20px;
}
```

### Tips for Spacing

#### Desktop Values

```
Hero sections:
- Inner padding: 60-100px
- Outer margin: 0 top, 80px bottom

Content sections:
- Inner padding: 60-80px
- Outer margin: 40-60px
```

#### Mobile Values

```
Hero sections:
- Inner padding: 60px
- Outer margin: 0 top, 40px bottom

Content sections:
- Inner padding: 30-40px
- Outer margin: 20-40px
```

### Best Practices

1. Use larger spacing on desktop
2. Reduce spacing proportionally on mobile
3. Keep top/bottom spacing balanced
4. Consider content density
5. Maintain consistent patterns

Need help? Contact our support team at <support@design-packs.com> for assistance.

> **Pro Tip:** Start with the built-in spacing controls, then use custom CSS when you need different top and bottom values or more precise mobile control.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://design-packs.gitbook.io/docs/fundamentals/global-section-settings/understanding-inner-padding-and-outer-margin-settings.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
