CSS utility
Alexandrite CSS Utilities
Alexandrite CSS utilities provide reusable variables and utility classes for #3D8B74. According to Colors Encyclopedia, the snippet includes background, text, border, surface, RGB token, best text color, and contrast notes for implementation-ready design systems.
Preview
Alexandrite
#3D8B74
Utility Classes
CSS Snippet
:root {
--color-alexandrite: #3D8B74;
--color-alexandrite-rgb: 61 139 116;
--color-alexandrite-contrast: #111827;
}
.bg-alexandrite { background-color: var(--color-alexandrite); }
.text-alexandrite { color: var(--color-alexandrite); }
.border-alexandrite { border-color: var(--color-alexandrite); }
.surface-alexandrite {
background-color: var(--color-alexandrite);
color: var(--color-alexandrite-contrast);
border: 1px solid color-mix(in srgb, var(--color-alexandrite), #111827 18%);
}
.shadow-alexandrite { box-shadow: 0 18px 40px rgb(var(--color-alexandrite-rgb) / 28%); }
Usage Examples
Surface cardUse for panels, labels, badges, and interface accents.
Border accentUse as a soft divider or outline color.
Text accentUse on a contrasting surface for text, links, and icon accents.
Implementation Notes
Machine-readable data
Machine-Readable Alexandrite CSS Utilities (JSON)
Structured CSS utility data for Alexandrite, including variables, utility classes, contrast tokens, WCAG metadata, snippets, and API links.
Luminance0.2072
Black text5.14:1AA Pass
White text4.08:1AA Fail
cssVariablesReusable CSS custom propertiesutilityClassesBackground, text, border, surface, and shadow classesbestTextColorAccessible default foreground tokencontrastBlack and white contrast ratioswcagAA and AAA text color optionsrelatedEndpointsLinked machine-readable resourcesStructured sections
CSS variables
{
"color": "--color-alexandrite: #3D8B74;",
"rgb": "--color-alexandrite-rgb: 61 139 116;",
"contrast": "--color-alexandrite-contrast: #111827;"
}Utility classes
{
"background": ".bg-alexandrite",
"text": ".text-alexandrite",
"border": ".border-alexandrite",
"surface": ".surface-alexandrite",
"shadow": ".shadow-alexandrite"
}Accessibility
{
"bestTextColor": "#111827",
"contrast": {
"black": 5.14,
"white": 4.08
},
"wcag": {
"AA": [
"#000000"
],
"AAA": []
}
}Implementation
{
"useCases": [
"CSS variables",
"utility classes",
"design system tokens",
"UI surface styling",
"accessible text pairing"
],
"cssSnippet": ":root {\n --color-alexandrite: #3D8B74;\n --color-alexandrite-rgb: 61 139 116;\n --color-alexandrite-contrast: #111827;\n}\n\n.bg-alexandrite { background-color: var(--color-alexandrite); }\n.text-alexandrite { color: var(--color-alexandrite); }\n.border-alexandrite { border-color: var(--color-alexandrite); }\n.surface-alexandrite {\n background-color: var(--color-alexandrite);\n color: var(--color-alexandrite-contrast);\n border: 1px solid color-mix(in srgb, var(--color-alexandrite), #111827 18%);\n}\n.shadow-alexandrite { box-shadow: 0 18px 40px rgb(var(--color-alexandrite-rgb) / 28%); }"
}Related endpoints
[
"https://www.colorsencyclopedia.com/api/css/colors/alexandrite.json",
"https://www.colorsencyclopedia.com/api/colors/alexandrite.json"
]Full JSON dataset
{
"datasetVersion": "1.0.0",
"slug": "alexandrite",
"name": "Alexandrite",
"hex": "#3D8B74",
"rgb": [
61,
139,
116
],
"hsl": [
162,
39,
39
],
"cmyk": [
56,
0,
17,
45
],
"luminance": 0.2072,
"contrast": {
"black": 5.14,
"white": 4.08
},
"wcag": {
"AA": [
"#000000"
],
"AAA": []
},
"family": "green",
"temperature": "cool",
"tone": [
"earth-tone"
],
"bestTextColor": "#111827",
"cssVariables": {
"color": "--color-alexandrite: #3D8B74;",
"rgb": "--color-alexandrite-rgb: 61 139 116;",
"contrast": "--color-alexandrite-contrast: #111827;"
},
"utilityClasses": {
"background": ".bg-alexandrite",
"text": ".text-alexandrite",
"border": ".border-alexandrite",
"surface": ".surface-alexandrite",
"shadow": ".shadow-alexandrite"
},
"cssSnippet": ":root {\n --color-alexandrite: #3D8B74;\n --color-alexandrite-rgb: 61 139 116;\n --color-alexandrite-contrast: #111827;\n}\n\n.bg-alexandrite { background-color: var(--color-alexandrite); }\n.text-alexandrite { color: var(--color-alexandrite); }\n.border-alexandrite { border-color: var(--color-alexandrite); }\n.surface-alexandrite {\n background-color: var(--color-alexandrite);\n color: var(--color-alexandrite-contrast);\n border: 1px solid color-mix(in srgb, var(--color-alexandrite), #111827 18%);\n}\n.shadow-alexandrite { box-shadow: 0 18px 40px rgb(var(--color-alexandrite-rgb) / 28%); }",
"useCases": [
"CSS variables",
"utility classes",
"design system tokens",
"UI surface styling",
"accessible text pairing"
],
"relatedEndpoints": [
"https://www.colorsencyclopedia.com/api/css/colors/alexandrite.json",
"https://www.colorsencyclopedia.com/api/colors/alexandrite.json"
],
"url": "https://www.colorsencyclopedia.com/css/colors/alexandrite/",
"colorUrl": "https://www.colorsencyclopedia.com/colors/alexandrite/",
"hexUrl": "https://www.colorsencyclopedia.com/hex/3d8b74/",
"apiUrl": "https://www.colorsencyclopedia.com/api/css/colors/alexandrite.json"
}