# Huawei gradient

Gradients derived from Huawei's published colour tokens (nominative use; no brand assets). Deterministic: the same values are served as `--brand-gradient*` in the brand's brand.css.

- Page: https://brandsweets.com/gradients/brands/huawei-com
- Brand colors: https://brandsweets.com/colors/brands/huawei-com · Brand page: https://brandsweets.com/b/huawei-com
- Palette: primary #cf0a2c, secondary #c7000b
- Source: https://huawei.com (extracted 2026-09-05)

## Brand gradient

ΔE_OK 0.028 < 0.15 between #cf0a2c and #c7000b — a 2-stop would read as a flat fill, so this is a tonal ramp of #cf0a2c.

- CSS: `linear-gradient(135deg in oklch shorter hue, #ff6768 0%, #cf0a2c 50%, #7e000b 100%)`
- Tailwind: `bg-linear-to-br/oklch from-[#ff6768] via-[#cf0a2c] to-[#7e000b]`
- Contrast (worst point): white 2.84:1 fail · black 1.89:1 fail · banding high
- Maker: https://brandsweets.com/gradients/new/v1.ff6768-cf0a2c-7e000b?a=135&in=oklch&hue=shorter

## Hero background

Chroma ×0.35 so it can carry text; ink white (inkFor at the midpoint). L shifted −0.14 until the ink passes AA at the worst point (4.63:1).

- CSS: `linear-gradient(135deg in oklch shorter hue, #9c6764 0%, #6c3330 50%, #301213 100%)`
- Tailwind: `bg-linear-to-br/oklch from-[#9c6764] via-[#6c3330] to-[#301213]`
- Contrast (worst point): white 4.63:1 AA · black 1.22:1 fail · banding high · ink #ffffff
- Maker: https://brandsweets.com/gradients/new/v1.9c6764-6c3330-301213?a=135&in=oklch&hue=shorter

## Button / CTA

ΔL 0.08 top→bottom in the primary's hue (a lit surface, not a rainbow); hover L +0.03, active L −0.03. L shifted −0.02 so white ink passes AA on the surface and both states (worst 4.55:1).

- CSS: `linear-gradient(180deg in oklch shorter hue, #d61a32 0%, #b9001a 100%)`
- Tailwind: `bg-linear-to-b/oklch from-[#d61a32] to-[#b9001a]`
- Contrast (worst point): white 5.18:1 AA · black 3.08:1 AA-large · banding high · ink #ffffff
- Maker: https://brandsweets.com/gradients/new/v1.d61a32-b9001a?a=180&in=oklch&hue=shorter
- Hover: `linear-gradient(180deg in oklch shorter hue, #e12b3b 0%, #c40023 100%)`
- Active: `linear-gradient(180deg in oklch shorter hue, #cb0029 0%, #aa0016 100%)`

## Tonal ramp

- CSS: `linear-gradient(135deg in oklch shorter hue, #ff6768 0%, #cf0a2c 50%, #7e000b 100%)`
- Tailwind: `bg-linear-to-br/oklch from-[#ff6768] via-[#cf0a2c] to-[#7e000b]`
- Contrast (worst point): white 2.84:1 fail · black 1.89:1 fail · banding high
- Maker: https://brandsweets.com/gradients/new/v1.ff6768-cf0a2c-7e000b?a=135&in=oklch&hue=shorter

## Analogous

Partner hue from the analogous rule at the source colour's lightness.

- CSS: `linear-gradient(135deg in oklab, #cf0a2c 0%, #c5097a 100%)`
- Tailwind: `bg-linear-to-br/oklab from-[#cf0a2c] to-[#c5097a]`
- Contrast (worst point): white 5.61:1 AA · black 3.68:1 AA-large · banding high
- Maker: https://brandsweets.com/gradients/new/v1.cf0a2c-c5097a?a=135

## Complementary

Partner hue from the complementary rule at the source colour's lightness. ΔH 180° > 140° — interpolating in oklch (shorter hue) keeps the midpoint saturated.

- CSS: `linear-gradient(135deg in oklch shorter hue, #cf0a2c 0%, #087e86 100%)`
- Tailwind: `bg-linear-to-br/oklch from-[#cf0a2c] to-[#087e86]`
- Contrast (worst point): white 4.68:1 AA · black 3.73:1 AA-large · banding medium
- Maker: https://brandsweets.com/gradients/new/v1.cf0a2c-087e86?a=135&in=oklch&hue=shorter

## Triadic

Partner hue from the triadic rule at the source colour's lightness.

- CSS: `linear-gradient(135deg in oklab, #cf0a2c 0%, #088710 100%)`
- Tailwind: `bg-linear-to-br/oklab from-[#cf0a2c] to-[#088710]`
- Contrast (worst point): white 4.67:1 AA · black 3.72:1 AA-large · banding medium
- Maker: https://brandsweets.com/gradients/new/v1.cf0a2c-088710?a=135

## CSS custom properties (brand.css)

```css
:root {
  /* Brand gradient (derived) */
  /* worst-case contrast: white 2.84:1, black 1.89:1 */
  --brand-gradient: linear-gradient(135deg in oklch shorter hue, #ff6768 0%, #cf0a2c 50%, #7e000b 100%);
  /* hero — worst-case contrast: white 4.63:1 AA, black 1.22:1; ink passes AA at the worst point */
  --brand-gradient-hero: linear-gradient(135deg in oklch shorter hue, #9c6764 0%, #6c3330 50%, #301213 100%);
  --brand-gradient-hero-ink: #ffffff;
  /* button — worst-case contrast: white 5.18:1 AA, black 3.08:1 AA-large */
  --brand-gradient-button: linear-gradient(180deg in oklch shorter hue, #d61a32 0%, #b9001a 100%);
  --brand-gradient-button-hover: linear-gradient(180deg in oklch shorter hue, #e12b3b 0%, #c40023 100%);
  --brand-gradient-button-active: linear-gradient(180deg in oklch shorter hue, #cb0029 0%, #aa0016 100%);
  --brand-gradient-button-ink: #ffffff;
}
```

## Gradient maker

Every maker URL is the gradient's state: `/gradients/new/v1.<hex>-<hex>[_pos]?a=135&in=oklch&hue=shorter&e=soft&g=8`. Hand one to a human, let them refine, and read the link they return.

## Connect an agent

Point any MCP client at the BrandSweets gradients endpoint for the same engine and corpus:

- Endpoint: https://mcp.brandsweets.com/gradients/mcp
- Tools: `make_gradient` (2–5 colours → CSS with the interpolation space, Tailwind v4, SVG, PNG URL, DTCG token + the contrast/banding/gamut report), `brand_gradients` (brand slug or palette → brand gradient, hero, button, variants).
- Resource: `gradients://corpus` — the whole bundled corpus as JSON.
