# Styles

> Learn how to speed up your work with styles


Styles are sets of predefined properties (fills, effects) that you can use to speed up your design workflow and ensure a consistent look throughout your projects. When you edit a style, all associated layers update automatically.

Lunacy supports the following style types:

- **Color styles** — for fills and borders

- **Effect styles** — for shadows and blurs

- **Text styles** — for fonts, sizes, line spacing, and other text properties

- **Layout grid styles** — for layout guides applied to frames

You can manage and organize styles in the **Styles** tab.

<embed type="image/svg+xml" alt="styles_tab" src="https://cdn-eu.icons8.com/docs/Dko8QE6mZ06fz2gAGGUBbA/B4vRzcgloEGqyUB7hUGTFg.svg" /> 


### Creating styles

There are two ways of creating styles.

**Way 1.**

1. Select a layer with the properties you're likely to reuse.
2. Go to the **Styles** tab and click `+` next to the type of style you're going to create.
3. Type the new new style name and press `Enter` or click anywhere over the canvas.

**Way 2.** Click `+` in the **Styles** list and define all the required properties.

<video autoplay="" muted="" loop="" playsinline="" width="100%" poster="/public/creating_stylesv12.png" height="auto"><source src="/public/creating_styles_v12.mp4" type="video/mp4"></video>



### Applying styles

Select the required layer or several layers, then choose the style you want to apply from the right panel.

<video autoplay="" muted="" loop="" playsinline="" width="100%" poster="/public/applying_styles_v12_ph.png" height="auto"><source src="/public/applying_styles_v12.mp4" type="video/mp4"></video>


### Modifying a style

1. Switch to the **Styles** tab, hover over the style you want to modify, then click <embed type="image/svg+xml" alt="Edit_icon" src="https://cdn-eu.icons8.com/docs/Dko8QE6mZ06fz2gAGGUBbA/ois3SsbaIE-VPWPJ6_gN-w.svg" />. 
2. In the displayed panel, make the required changes.
3. Close the panel to apply changes.


<video autoplay="" muted="" loop="" playsinline="" width="100%" poster="/public/editing_styles_v12_ph.png" height="auto"><source src="/public/editing_styles_v12.mp4" type="video/mp4"></video>



### Detaching a style

Select the required layer and click the **Detach style** button shown below.

<embed type="image/svg+xml" alt="detaching_styles" src="https://cdn-eu.icons8.com/docs/Dko8QE6mZ06fz2gAGGUBbA/k5f7tarviE6PmC2qMV4jig.svg" /> 


The appearance of the layer remains the same, but it is no longer associated with the style and further changes to the style will not affect the layer.

### Organizing styles

It is a good practice to organize styles into groups similar to those shown in the figure below.

<embed type="image/svg+xml" alt="organizing_stylesv12" src="https://cdn-eu.icons8.com/docs/Dko8QE6mZ06fz2gAGGUBbA/J2FHVidH90CQnS6vHLPreA.svg" /> 


To organize your styles into groups, consider the following format of style names:

`Group name / Subgroup name / Style name`  

For example, to organize your styles of backgrounds, you can give them the following names:

* Backgrounds / Light
* Backgrounds / Dark
* etc.

The number of nesting levels for subgroups is not limited.

Another way of organizing styles:

1. Holding down `Shift`, select styles in the left panel.
2. Right-click.
3. On the context menu, click **Group**.
4. Rename the group to the desired name.  

To rename a style or a style group:

1. Double-click over the style/group.
2. Type the new name and press `Enter`.

Style groups and styles appear in the A-Z order in the left panel.

### Duplicating styles

You can duplicate your existing styles and quickly create new ones based on their parents.

To duplicate a style:

* Click the style in the list and press `Ctrl + D`.

    OR
* Right-click the style in the list and select **Duplicate** on the displayed menu.

Also, you can select and duplicate several styles at a time.

### Copying styles between documents

To copy styles between documents:

1. Select one or several styles in the source document (hold down `Ctrl` or `Shift` to select multiple items).
2. Right-click and select **Copy style** on the displayed menu.
3. Switch to the target document.
4. Open the **Styles** tab.
5. Right-click over the left panel and select **Paste style** on the displayed menu.

Also, if you're working with a cloud document, you can consider <a href="https://lunacy.docs.icons8.com/raw/sharedlibraries.md" target="_blank">sharing styles</a>.

