---
name: cosmosluminosity-site
description: Use when Margarita asks to publish, change, rewrite, or remove content on www.cosmosluminosity.com — posts, pages, images, site title/description. The site runs Ghost CMS on this server and is managed with the `cosmos` command-line tool. Also use when she sends a cosmosluminosity.com link and asks to fix or update that page.
---

# Cosmos Luminosity website

The public site `https://www.cosmosluminosity.com` runs **Ghost CMS**. All
content changes go through the `cosmos` CLI, which is already authenticated.
Act directly — never ask Margarita to log into an admin panel or to paste the
page text back to you.

## Trigger

Use this skill when Margarita asks to:

- publish a new article, post, chapter, or announcement;
- change/rewrite/correct text already on the site;
- add or replace an image;
- rename the site, change its description, or edit a page like "About";
- remove something from the site.

A `cosmosluminosity.com` URL in her message identifies the target: the last
path segment is the **slug** (`https://www.cosmosluminosity.com/tochka/` →
slug `tochka`).

## The `cosmos` tool

Run it as the normal shell user (no sudo). It talks to Ghost over loopback, so
it keeps working even if DNS or the certificate ever break.

```bash
cosmos status                      # site title, Ghost version, content counts
cosmos post list                   # recent posts (drafts included)
cosmos page list
cosmos post get <slug>             # full text of a post, as HTML
cosmos post get <slug> --field html
```

Posts are dated articles; pages are standing pages (About, Contacts). Both
take the same subcommands: `list`, `get`, `create`, `update`, `delete`.

### Creating

Body text is **Markdown by default** — headings, bold, lists, quotes, tables
and Cyrillic all work. Prefer `--file` over `--body` for anything longer than
one sentence.

```bash
cosmos post create "Точка за горизонтом" --file /tmp/article.md
cosmos post create "Черновик" --file /tmp/draft.md --draft
cosmos post create "Статья" --file /tmp/a.md \
    --tag "эссе" --excerpt "Короткое описание для анонса"
cosmos page create "О проекте" --file /tmp/about.md
```

`--draft` creates it unpublished. Without it the post goes live immediately.

### Updating

Read the current text first, then write a complete new body — do not paste
Margarita's instruction in as the body.

```bash
cosmos post get tochka-za-gorizontom --field html > /tmp/current.html
# ... compose the revised Markdown into /tmp/new.md ...
cosmos post update tochka-za-gorizontom --file /tmp/new.md
cosmos post update tochka-za-gorizontom --title "Новое название"
cosmos post update chernovik --publish      # publish a draft
cosmos post update tochka --draft           # unpublish
```

### Images

Upload first, then reference the returned URL.

```bash
URL=$(cosmos image upload /path/to/photo.jpg)
cosmos post update tochka --feature-image "$URL"
```

Inside Markdown bodies, use the uploaded URL directly:
`![подпись](https://www.cosmosluminosity.com/content/images/...)`.

### Site settings (read-only from the CLI)

```bash
cosmos settings          # list title, description, theme, fonts, ...
```

Ghost refuses settings **writes** from API integrations — that endpoint needs
a staff login. So the site title, description/tagline, logo, navigation menu
and theme can only be changed by a human in the admin UI at
`https://www.cosmosluminosity.com/ghost/settings/`.

If Margarita asks to change the site tagline, navigation or theme, tell her it
has to be done in the admin panel and give her that link — do not attempt it
with `cosmos`.

## The site is a blank canvas

The active theme is **`clean`** — a deliberately empty template. There is no
header, no navigation menu, no sidebar, no footer, no subscribe or sign-in UI,
and no Ghost branding.

That means:

- the **home page shows nothing except the posts that exist** — each new post
  becomes one more element on it, newest first;
- each new **page** becomes a standalone child page at
  `https://www.cosmosluminosity.com/<slug>/`, not linked from anywhere;
- there is no navigation until it is implemented in the theme or content.

Do not assume theme features that are not there. Colours, fonts, layout,
navigation, home-page composition and header imagery are **theme work** in
`/opt/cosmosluminosity/content/themes/clean/`. When Margarita explicitly asks
for a site design or turnkey implementation, inspect and edit the theme rather
than reducing the task to Ghost posts/pages. Follow the deployment gate below.

## Theme redesign and deployment gate

A theme file being written on disk does **not** prove that Ghost has loaded it.
Ghost may keep the active theme cached until it is re-uploaded/reactivated or
the Ghost service is restarted.

For visual/site-wide work:

1. Read `default.hbs`, `index.hbs`, `page.hbs`, `post.hbs`, `package.json`,
   existing assets, and the current public HTML before designing.
2. Separate approved public positioning from source drafts and research notes.
   Never promote unresolved positioning, product mechanics, prices, credentials,
   clinical claims, or private client details into public copy merely because
   they exist in the Portal.
3. Back up the current theme before editing. Prefer a versioned theme directory
   or zip over destructive in-place work when practical.
4. Add real assets under `assets/`; include accurate alt text and do not invent
   titles, dates, credentials, links, or product availability.
5. Validate `package.json`, archive integrity, Handlebars structure, responsive
   behavior, accessibility basics, and reduced-motion behavior.
6. Deploy through a supported Ghost path: upload/activate the theme through the
   Ghost Admin API or admin UI, or restart Ghost when authorized. Do not assume
   direct filesystem edits are hot-reloaded.
7. Fetch the public homepage and verify a unique marker from the new design,
   asset HTTP responses, status code, title/meta, and destination links. Then
   inspect desktop and mobile screenshots plus the browser console.
8. If deployment requires authorization, report the artifact as **prepared but
   not live** and give the exact remaining operation. Never say “разместила”,
   “опубликовано”, or “готово на сайте” before public verification succeeds.
9. Keep rollback available until the live visual and functional checks pass.

When using a server restart, request/obtain authorization before relying on it;
a timed-out approval or password prompt is not evidence that the deployment is
complete. If restart access is unavailable, prefer the authenticated Ghost theme
upload/activation route rather than stopping after an in-place edit.
should make. Say so rather than attempting it.

## Rules

1. **Never delete without explicit confirmation.** `cosmos post delete` and
   `cosmos page delete` require `--yes`, and you should only pass it when
   Margarita has clearly asked for that specific item to be removed. Prefer
   `--draft` (unpublish) over deletion — it is reversible.
2. **Read before you write.** Always `cosmos post get <slug>` first on an
   update, so you preserve facts, headings and links she did not ask to change.
3. **Keep changes surgical.** Touch only the item she named.
4. **Preserve the voice.** Cosmos Luminosity tone: clear, symbolic, grounded,
   living-encyclopedia style. Keep Russian content in Russian.
5. **Long or risky rewrites:** create as `--draft` first, send her the draft
   URL, and publish only once she agrees.

## Custom theme builds and bilingual pages

For a full homepage/landing-page redesign, RU/EN switching, theme deployment without a container restart, reveal-animation safeguards, and browser QA, use `references/custom-theme-bilingual-deployment.md`.

Important corrections to the older blank-canvas assumptions above:

- The `clean` theme may now contain a complete bespoke homepage, navigation and footer; inspect the current theme files and live site before describing it as blank.
- Theme edits are allowed when Margarita explicitly asks for a site design/build and the files are writable. Back up first, then deploy through Ghost’s Admin API theme-upload endpoint rather than stopping after editing files on disk.
- Editing the mounted theme directory does not prove the live site changed. Upload the theme ZIP, verify the response says the theme is active, and inspect the public URL.
- A bilingual request means translating the full reader-facing experience, not only adding a language toggle.
- Core page content must remain visible when reveal JavaScript fails or an observer does not fire.

## Verification

After every change, confirm the live site actually reflects it:

```bash
cosmos post get <slug>
curl -s -o /dev/null -w '%{http_code}\n' https://www.cosmosluminosity.com/<slug>/
```

A published post must return `200`. For content edits, also verify a distinctive
text fragment in the response body; `200` alone can be a generic Coming Soon or
fallback page. For theme work, verify a distinctive new marker and the expected
asset URLs, then inspect desktop/mobile screenshots and browser console output.
Report the live URL only after those checks pass.

If `cosmos` itself errors, check the CMS is up:

```bash
cosmos status
systemctl is-active nginx
docker ps --filter name=cosmos- --format '{{.Names}} {{.Status}}'
```

## Human admin access

Margarita can also edit in the browser at
`https://www.cosmosluminosity.com/ghost/` — owner account
`rudomanovapro@gmail.com`. If she has lost the password, tell her it is stored
on the server at `/opt/cosmosluminosity/.env` (root-only) and that the
operator can read it out; do not try to read that file yourself.

## Reference

- Ghost stack: `/opt/cosmosluminosity/docker-compose.yml` (containers
  `cosmos-ghost`, `cosmos-mysql`)
- Uploaded media: `/opt/cosmosluminosity/content/images/`
- Active theme: `/opt/cosmosluminosity/content/themes/clean/`
- API credentials used by `cosmos`: `~/.cosmos/credentials`
- nginx vhost: `/etc/nginx/sites-available/cosmosluminosity-com.conf`
