/* Bleend design tokens: the one place colours, type and spacing are defined.
   Dark is the studio console default. Light serves sunlit phones, clients and site workers.
   Pages pick a theme with <html data-theme="dark|light">; without it the device preference wins. */

:root {
  color-scheme: dark;

  /* Surfaces: a night-drawing green-black taken from the studio's own ink, not a neutral black. */
  --ground: #0b1211;
  --panel: #121b1a;
  --panel-2: #17211f;

  --text: #edf1ec;
  --text-2: #a9b6af;
  --text-3: #7f8e87;

  /* Hairlines carry the structure; there are no shadows. */
  --hair: rgba(226, 236, 230, 0.12);
  --line: rgba(226, 236, 230, 0.26);

  /* Clay means "this needs you". Mint is money in hand. Brass is money not yet settled. */
  --accent: #e0654c;
  --accent-text: #ee8870;
  --accent-ink: #0b1211;
  --in: #7ccba2;
  --pending: #e7b45a;

  --btn: #edf1ec;
  --btn-ink: #0b1211;
  --btn-hover: #ffffff;
  --btn-2: #1c2725;
  --btn-2-hover: #25322f;

  --mark: url("/assets/monogram-white.png");

  --wordmark: url("/assets/wordmark-white.png");

  --sans: Manrope, "Bleend Indic", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "DM Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;

  --radius: 3px;
  --rail: 232px;
  --gutter: clamp(16px, 3vw, 36px);
  --unit: 8px;
  --measure: 1180px;

  /* Names the older page stylesheets use, so shared pieces such as the inbox follow the theme. */
  --paper: var(--ground);
  --surface: var(--panel);
  --ink: var(--text);
  --body: var(--text-2);
  --muted: var(--text-3);
  --line-strong: var(--line);
  --clay: var(--accent);
  --clay-soft: rgba(224, 101, 76, 0.16);
  --mist: var(--panel-2);
  --display: var(--sans);
}

/* The light values appear twice because plain CSS cannot share a block between
   "the device prefers light" and "the person chose light". Keep both in step. */
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    color-scheme: light;
    --ground: #f1f2ed;
    --panel: #fbfbf8;
    --panel-2: #e7ebe5;
    --text: #173331;
    --text-2: #344846;
    --text-3: #536863;
    --hair: rgba(23, 51, 49, 0.14);
    --line: rgba(23, 51, 49, 0.34);
    --accent: #d75a43;
    --accent-text: #b2422d;
    --accent-ink: #ffffff;
    --in: #1f7a54;
    --pending: #8a5a00;
    --btn: #173331;
    --btn-ink: #fbfbf8;
    --btn-hover: #0f2423;
    --btn-2: #e7ebe5;
    --btn-2-hover: #dbe1da;
    --mark: url("/assets/monogram-black.png");
    --wordmark: url("/assets/wordmark-black.png");
    --clay-soft: #f4ded8;
  }
}

:root[data-theme="light"] {
  color-scheme: light;
  --ground: #f1f2ed;
  --panel: #fbfbf8;
  --panel-2: #e7ebe5;
  --text: #173331;
  --text-2: #344846;
  --text-3: #536863;
  --hair: rgba(23, 51, 49, 0.14);
  --line: rgba(23, 51, 49, 0.34);
  --accent: #d75a43;
  --accent-text: #b2422d;
  --accent-ink: #ffffff;
  --in: #1f7a54;
  --pending: #8a5a00;
  --btn: #173331;
  --btn-ink: #fbfbf8;
  --btn-hover: #0f2423;
  --btn-2: #e7ebe5;
  --btn-2-hover: #dbe1da;
  --mark: url("/assets/monogram-black.png");
  --wordmark: url("/assets/wordmark-black.png");
  --clay-soft: #f4ded8;
}
