# Customizing Theme Colors & Fonts

## Customizing Theme Colors & Fonts

**Files:** `src/styles/theme.css`, `src/config/fonts.json` · **Skill level:** Beginner

Colors and fonts stay in these files in all three editions, because the site reads them when it builds. The Tina and Sanity editors don't change them.

The Stella theme uses CSS variables in `src/styles/theme.css` for colors and typography. Update these values to match your brand.

```css
/* src/styles/theme.css */
@theme inline {
  /* Configure font families in `src/config/fonts.json` */
  --leading-body: 1.8;
  --leading-inherit: inherit;

  /* Colors */
  --color-primary: #6B1AFF;
  --color-accent: #630FFD;
  --color-body: #fff;
  --color-border-light: #ECEEF1;
  --color-theme-light: #F8F8F8;
  --color-theme-dark: #372D3F;
  
  --color-text-default: #3B3B3B;
  --color-dark: #322B2B; /* Heading colors */
  --color-light: #fff6f6;

}
```

### Customizing Colors
- Adjust the `--color-*` variables to match your brand palette.
- Update `--color-text-default` to refine text contrast.

---

### Typography Settings
Fonts are configured in `src/config/fonts.json` and loaded automatically.

```json
[
  {
    "name": "Figtree",
    "variants": [
      {
        "style": "normal",
        "weight": "400"
      },
      {
        "style": "normal",
        "weight": "500"
      }
    ],
    "preload": false,
    "display": "swap",
    "cssVariable": "--font-primary",
    "provider": "google",
    "subsets": [
      "latin"
    ],
    "fallback": "sans-serif"
  },
  {
    "name": "Instrument Serif",
    "variants": [
      {
        "style": "normal",
        "weight": "400"
      }
    ],
    "preload": false,
    "display": "swap",
    "cssVariable": "--font-secondary",
    "provider": "google",
    "subsets": [
      "latin"
    ],
    "fallback": "sans-serif"
  },
  {
    "name": "IBM Plex Sans Arabic",
    "variants": [
      {
        "style": "normal",
        "weight": "400"
      },
      {
        "style": "normal",
        "weight": "500"
      },
      {
        "style": "normal",
        "weight": "600"
      }
    ],
    "preload": false,
    "display": "swap",
    "cssVariable": "--font-arabic",
    "provider": "google",
    "subsets": [
      "arabic"
    ],
    "fallback": false,
    "languages": [
      "ar"
    ]
  }
]
```

#### Font Customization
- Update `name` and `variants` (each with a `style` and `weight`) to match your brand.
- Keep `cssVariable` in sync with theme styles that reference it.
- `languages` loads a font only for those languages. Stella uses this for its Arabic font, IBM Plex Sans Arabic. See [RTL & Arabic](../../features/rtl-arabic/).
- For local fonts, set `provider` to `local`, and ensure the paths in `variants` exist and are committed.