Mordoc

Buttons

Style the primary and secondary button variants used on landing pages and in the header.

1 MIN READ

Button renders wherever the {% button %} tag is used. See Landing Pages for the Markdown syntax. It has two variants, primary and secondary, each with its own tokens.

Open the override file

Text
config/styles/button.css

Shared shape

TokenWhat it controls
--button-heightHeight of the button, both variants.
--button-paddingHorizontal padding, both variants.
--button-font-sizeFont size, both variants.
--button-radiusCorner radius, both variants.
--button-shadowDrop shadow at rest. none by default; set it for a theme whose button color is close to its background, so the button still reads as a distinct shape.
--button-shadow-hoverDrop shadow on hover.

Primary variant

TokenWhat it controls
--button-primary-bgBackground. Defaults to --accent.
--button-primary-borderBorder color. Defaults to --accent.
--button-primary-fgText color. White by default.
--button-primary-hover-bgBackground on hover.
--button-primary-hover-borderBorder color on hover.

Secondary variant

TokenWhat it controls
--button-secondary-fgText color. Defaults to --accent.
--button-secondary-hover-bgBackground on hover.
Header Links reuses these same tokens

A header link configured as a button (see Header Links) renders through this same component, just at a smaller height/padding/font-size set locally by that file. Changing the colors here changes both places at once.

Example button.css

A config/styles/button.css that sets every token on this page, for both light and dark mode:

Css
:root {
  --button-height: 2.625rem;
  --button-padding: 1.375rem;
  --button-font-size: 0.9375rem;
  --button-radius: 999px;
  --button-shadow: none;
  --button-shadow-hover: none;

  --button-primary-bg: #0d9488;
  --button-primary-border: #0d9488;
  --button-primary-fg: #ffffff;
  --button-primary-hover-bg: #0f766e;
  --button-primary-hover-border: #0f766e;

  --button-secondary-fg: #0d9488;
  --button-secondary-hover-bg: #f0fdfa;
}

.dark {
  --button-primary-bg: #2dd4bf;
  --button-primary-border: #2dd4bf;
  --button-primary-fg: #0f172a;
  --button-primary-hover-bg: #5eead4;
  --button-primary-hover-border: #5eead4;

  --button-secondary-fg: #2dd4bf;
  --button-secondary-hover-bg: #0f2e2b;
}

You've now covered every part of Mordoc's UI. From here, get your site live:

Next step

© 2026 MordocPowered by Mordoc