Pit Viper

v1.90.0

Pit Viper

v1.90.0
v1 / v2

  • Home
  • Utilities
  • Spacing

Spacing

Spacing utilities allow you to adjust the padding and/or margins of an element or group of elements. Refer to Spacing in Visual Style to learn more about the naming conventions used below.

Margin

Use margin utilities to adjust the spacing between elements.

Stack

Stack adds margin to the bottom on an element. You can append a value to the class itself to set the size in pixels based on Pit Viper’s spacing values.

Class Margin Value
.pv-stack-0 0px
.pv-stack-4 4px
.pv-stack-8 8px
.pv-stack-12 12px
.pv-stack, .pv-stack-16 16px
.pv-stack-20 20px
.pv-stack-24 24px
.pv-stack-32 32px
.pv-stack-64 64px
.pv-stack-128 128px

Alternatively, you can override the default value (16px) of pv-stack with the custom property --stack-size. Only use this method when the above classes aren’t sufficient.

Custom Property Default Value Description
--stack-size 16px Bottom margin value

Example
A heading with bottom margin followed by a paragraph of text.

You can put a price on healthcare.

Just like you wouldn’t buy a car, rent an apartment, or even order food without knowing the cost, you shouldn’t just pay for healthcare.

HTML
<p class="pv-heading-5 pv-stack">You can put a price on healthcare.</p>
<p>Just like you wouldn’t buy a car, rent an apartment, or even order food without knowing the cost, you shouldn’t just pay for healthcare.</p>

Stack Responsive

Add -responsive to a stack utility to reduce the spacing by half below the medium breakpoint.

Class Value below breakpoint Value above breakpoint
.pv-stack-8-responsive 4px 8px
.pv-stack-16-responsive 8px 16px
.pv-stack-24-responsive 12px 24px
.pv-stack-32-responsive 16px 32px
.pv-stack-64-responsive 32px 64px
.pv-stack-128-responsive 64px 128px

Example
A container with 32px of bottom margin on large screens and 16px of bottom margin on small screens.

This container has half as much bottom margin on small screens.

Another container.

HTML
<div class="pv-surface pv-inset-square pv-stack-32-responsive">
<p>This container has half as much bottom margin on small screens.</p>
</div>
<div class="pv-surface pv-inset-square">
<p>Another container.</p>
</div>

Flow

Flow adds margin to the bottom of all direct children of an element. Use this instead of applying multiple stack classes to each child element. The last child element will not include a bottom margin to avoid adding unwanted addition space to the bottom of a container.

Class Margin Value
.pv-flow-8 8px
.pv-flow, .pv-flow-16 16px
.pv-flow-24 24px

You can use the custom property --flow-size to override the default value of 16px.

Custom Property Default Value Description
--flow-size 16px Bottom margin value

You can also use the stack class inside of a flow block to override the margin value for an individual child element.

Example
A heading with a bottom margin of 8px followed by several paragraphs of text, with equal bottom margins of 16px.

Bundled together with care.

Standard Service Packages gather all medical services, materials, and fees associated with a healthcare procedure and represent them as a single code.

Created by industry experts and a team of A-list engineers, Standard Service Packages are neatly bundled, aptly categorized, and accurately tagged to meet the needs of patients, providers, and payers.

We're simplifying the world of healthcare billing.

HTML
<div class="pv-flow">
<p class="pv-heading-5 pv-stack-8">Bundled together with care.</p>
<p>Standard Service Packages gather all medical services, materials, and fees associated with a healthcare procedure and represent them as a single code.</p>
<p>Created by industry experts and a team of A-list engineers, Standard Service Packages are neatly bundled, aptly categorized, and accurately tagged to meet the needs of patients, providers, and payers.</p>
<p>We're simplifying the world of healthcare billing.</p>
</div>

Padding

Use padding utilities to add spacing inside of an element.

Inset Square

Inset Square adds equal padding to all sides of an element. You can append a value to the class itself to set the size in pixels based on Pit Viper’s spacing values.

Class Margin Value
.pv-inset-square-8 8px
.pv-inset-square-12 12px
.pv-inset-square, .pv-inset-square-16 16px
.pv-inset-square-20 24px
.pv-inset-square-24 24px
.pv-inset-square-48 48px

Alternatively, you can override the default value (16px) of pv-inset-square with the custom property --inset-size. Only use this method when the above classes aren’t sufficient.

Custom Property Default Value Description
--inset-size 16px Padding value

Example
A heading and paragraph inside of a container with 16px of padding on all sides.

Shop healthcare just like anything else.

It's your right to know the cost of healthcare. Take advantage of hospital price transparency by comparing the costs of services and providers near you.

HTML
<div class="pv-inset-square pv-surface">
<p class="pv-heading-4 pv-stack">Shop healthcare just like anything else.</p>
<p>It's your right to know the cost of healthcare. Take advantage of hospital price transparency by comparing the costs of services and providers near you.</p>
</div>

Inset Square Responsive

Add -responsive to an inset-square utility to reduce the spacing by half below the medium breakpoint.

Class Value below breakpoint Value above breakpoint
.pv-inset-square-16-responsive 8px 16px
.pv-inset-square-24-responsive 12px 24px
.pv-inset-square-32-responsive 16px 32px
.pv-inset-square-48-responsive 24px 48px

Example
A container with 32px of padding on large screens and 16px of padding on small screens.

This container has half as much padding on small screens.

HTML
<div class="pv-surface pv-inset-square-32-responsive">
<p>This container has half as much padding on small screens.</p>
</div>

Inset Squish

Inset Squish adds more padding to the sides of an element than the top and bottom.

Class Padding Value
.pv-inset-squish-8 8px 16px
.pv-inset-squish-12 12px 16px
.pv-inset-squish, .pv-inset-squish-16 16px 32px

Alternatively, you can override the default value (12px 16px) of pv-inset-squish with the custom property --inset-size, which takes two space-separated values: block (top/bottom) and inline(left/right) padding. Only use this method when the above classes aren’t sufficient.

Custom Property Default Value Description
--inset-size 12px 16px Padding value

Example
A heading and paragraph inside of a container with 12px of padding on the top and bottom and 16px of padding on the left and right.

Shop healthcare just like anything else.

It's your right to know the cost of healthcare. Take advantage of hospital price transparency by comparing the costs of services and providers near you.

HTML
<div class="pv-inset-squish-12 pv-surface">
<p class="pv-heading-4 pv-stack">Shop healthcare just like anything else.</p>
<p>It's your right to know the cost of healthcare. Take advantage of hospital price transparency by comparing the costs of services and providers near you.</p>
</div>

Inset Inline

Inset Inline adds padding only to the sides of an element.

Class Padding Value
.pv-inset-inline, .pv-inset-inline-16 16px
.pv-inset-inline-20 20px
.pv-inset-inline-24 24px
.pv-inset-inline-32 32px

Alternatively, you can override the default value (16px) of pv-inset-inline with the custom property --inset-size. Only use this method when the above classes aren’t sufficient.

Custom Property Default Value Description
--inset-size 16px Padding value

Example
A heading and paragraph inside of a container with 16px of padding on the left and right.

Shop healthcare just like anything else.

It's your right to know the cost of healthcare. Take advantage of hospital price transparency by comparing the costs of services and providers near you.

HTML
<div class="pv-inset-inline-16 pv-surface">
<p class="pv-heading-4 pv-stack">Shop healthcare just like anything else.</p>
<p>It's your right to know the cost of healthcare. Take advantage of hospital price transparency by comparing the costs of services and providers near you.</p>
</div>

Inset Block

Inset Block adds padding only to the top and bottom of an element.

Class Padding Value
.pv-inset-block, .pv-inset-block-16 16px
.pv-inset-block-20 20px
.pv-inset-block-24 24px
.pv-inset-block-32 32px

Alternatively, you can override the default value (16px) of pv-inset-block with the custom property --inset-size. Only use this method when the above classes aren’t sufficient.

Custom Property Default Value Description
--inset-size 16px Padding value

Example
A heading and paragraph inside of a container with 16px of padding on the top and bottom.

Shop healthcare just like anything else.

It's your right to know the cost of healthcare. Take advantage of hospital price transparency by comparing the costs of services and providers near you.

HTML
<div class="pv-inset-block-16 pv-surface">
<p class="pv-heading-4 pv-stack">Shop healthcare just like anything else.</p>
<p>It's your right to know the cost of healthcare. Take advantage of hospital price transparency by comparing the costs of services and providers near you.</p>
</div>

Inset Block Responsive

Add -responsive to an inset-block utility to reduce the top and bottom padding by half below the medium breakpoint.

Class Value below breakpoint Value above breakpoint
.pv-inset-block-8-responsive 4px 8px
.pv-inset-block-16-responsive 8px 16px
.pv-inset-block-24-responsive 12px 24px
.pv-inset-block-32-responsive 16px 32px

Example
A container with 32px of top and bottom padding on large screens and 16px of top and bottom padding on small screens.

This container has half as much top and bottom padding on small screens.

HTML
<div class="pv-surface pv-inset-block-32-responsive">
<p>This container has half as much top and bottom padding on small screens.</p>
</div>

Resources