0% · #30c2d8
L 0.75 · C 0.12 · H 210
Neptune
A linear gradient sweeping from light cyan to dark indigo, interpolated in OKLCH across 3 stops so the midpoint stays vivid instead of greying out.
- Type
- Linear
- Stops
- 3
- Space
- OKLCH
- Direction
- 180deg
The stops behind Neptune
Endpoints sit closest to darkturquoise and midnightblue.
50% · #0060a4
L 0.45 · C 0.18 · H 230
100% · #001340
L 0.2 · C 0.1 · H 250
Create Neptune in PHP
Build a linear gradient from the catalog stops, then let PHPColor assign their positions.
<?php
use PhpColor\Color\Gradient\Gradient;
$gradient = Gradient::linear(
180,
'oklch(0.75 0.12 210)',
'oklch(0.45 0.18 230)',
'oklch(0.20 0.10 250)',
);
use PhpColor\Color\Gradient\Gradient;
$gradient = Gradient::linear(
180,
'oklch(0.75 0.12 210)',
'oklch(0.45 0.18 230)',
'oklch(0.20 0.10 250)',
);
Inspect and convert its stops
Each stop remains a color object, ready for conversion, contrast checks, or further manipulation.
<?php
foreach ($gradient->getStops() as $stop) {
echo $stop->color->to('oklch')->toCss();
}
foreach ($gradient->getStops() as $stop) {
echo $stop->color->to('oklch')->toCss();
}
Format Neptune for CSS
Serialize the gradient directly, or choose a wide-gamut notation for every stop.
<?php
$css = $gradient->toCss();
$p3 = $gradient->toCss('display-p3');
$css = $gradient->toCss();
$p3 = $gradient->toCss('display-p3');
background: linear-gradient(180deg, oklch(0.75 0.12 210), oklch(0.45 0.18 230), oklch(0.20 0.10 250));
background: linear-gradient(180deg, oklch(0.75 0.12 210), oklch(0.45 0.18 230), oklch(0.20 0.10 250));