/* =========================================================
   Mood Setup Studio — design tokens
   ---------------------------------------------------------
   Every colour, font and size used on the site is defined
   here. The look is built from the shop's own material:
     - the logo's teal and red-orange blocks
     - the black grid desk mat seen in the studio photos
     - true white / true black, like the two studio desks
   Change a value here and it updates across the whole site.
   ========================================================= */

/* ---------- Fonts (self-hosted, no external requests) ---------- */
@font-face { font-family: "Barlow"; src: url("../fonts/barlow-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: block; }
@font-face { font-family: "Barlow"; src: url("../fonts/barlow-500.woff2") format("woff2"); font-weight: 500; font-style: normal; font-display: block; }
@font-face { font-family: "Barlow"; src: url("../fonts/barlow-600.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: block; }
@font-face { font-family: "Barlow Condensed"; src: url("../fonts/barlow-condensed-600.woff2") format("woff2"); font-weight: 600; font-style: normal; font-display: block; }
@font-face { font-family: "Barlow Condensed"; src: url("../fonts/barlow-condensed-700.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: block; }

/* Khmer letters. The browser only downloads these when a page actually shows Khmer text. */
@font-face { font-family: "Kantumruy Pro"; src: url("../fonts/kantumruy-pro-khmer-400.woff2") format("woff2"); font-weight: 400; font-style: normal; font-display: block; unicode-range: U+1780-17FF, U+19E0-19FF, U+200C-200D, U+25CC; }
@font-face { font-family: "Kantumruy Pro"; src: url("../fonts/kantumruy-pro-khmer-600.woff2") format("woff2"); font-weight: 500 600; font-style: normal; font-display: block; unicode-range: U+1780-17FF, U+19E0-19FF, U+200C-200D, U+25CC; }
@font-face { font-family: "Kantumruy Pro"; src: url("../fonts/kantumruy-pro-khmer-700.woff2") format("woff2"); font-weight: 700; font-style: normal; font-display: block; unicode-range: U+1780-17FF, U+19E0-19FF, U+200C-200D, U+25CC; }

/* ---------- Light theme (default) — the white desk ---------- */
:root {
  color-scheme: light;

  /* Brand — straight from the logo */
  --teal-deep: #004c4c;
  --teal: #006565;
  --red: #cc322f;
  --orange: #ef5f43;
  --grad-warm: linear-gradient(90deg, #cc322f, #ef5f43);
  --grad-teal: linear-gradient(90deg, #004c4c, #006565);

  /* Surfaces */
  --bg: #ffffff;
  --bg-2: #f4f4f1;
  --surface: #ffffff;
  --surface-2: #f0f0ed;
  --surface-3: #e5e5e1;
  --line: #e2e2dd;
  --line-strong: #c4c4be;
  --media-bg: #ffffff;                 /* behind product photos */
  --header-bg: rgba(255, 255, 255, 0.9);
  --overlay: rgba(8, 9, 9, 0.6);

  /* Empty photo slot: a pale cutting-mat grid */
  --ph-bg: #f1f1ee;
  --ph-minor: rgba(11, 12, 12, 0.055);
  --ph-major: rgba(11, 12, 12, 0.12);

  /* Text */
  --text: #0b0c0c;
  --text-2: #454848;
  --text-3: #686c6b;

  /* Interactive */
  --brand: #005a5a;
  --brand-hover: #003e3e;
  --brand-soft: #e2efed;
  --on-brand: #ffffff;
  --accent: #c42f2c;
  --focus: #006565;

  /* Availability */
  --ok: #08754f;
  --wait: #9a5600;
  --off: #686c6b;

  /* Ambient glow behind the hero (the wall wash in the studio photos) */
  --glow-a: rgba(0, 101, 101, 0.13);
  --glow-b: rgba(239, 95, 67, 0.12);

  --shadow-pop: 0 28px 70px -24px rgba(8, 9, 9, 0.45);

  /* Type */
  --font-display: "Barlow Condensed", "Kantumruy Pro", "Noto Sans Khmer", "Leelawadee UI", "Khmer UI", "Arial Narrow", sans-serif;
  --font-body: "Barlow", "Kantumruy Pro", "Noto Sans Khmer", "Leelawadee UI", "Khmer UI", "Segoe UI", system-ui, -apple-system, Roboto, Arial, sans-serif;

  /* Shape — softly rounded (buttons, fields, cards) */
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;

  /* Layout */
  --container: 1240px;
  --gutter: 20px;
  --header-h: 64px;
  --dock-h: 70px;
  --section-y: clamp(52px, 6.5vw, 96px);

  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

@media (min-width: 640px) {
  :root { --gutter: 28px; }
}
@media (min-width: 1024px) {
  :root { --gutter: 40px; --header-h: 72px; }
}

/* ---------- Dark theme — the black desk ---------- */
:root[data-theme="dark"] {
  color-scheme: dark;

  --grad-warm: linear-gradient(90deg, #e2463a, #ff7a5c);
  --grad-teal: linear-gradient(90deg, #0f8f88, #37d4c8);

  --bg: #090a0a;
  --bg-2: #0f1111;
  --surface: #121414;
  --surface-2: #191c1c;
  --surface-3: #232727;
  --line: #222626;
  --line-strong: #373d3c;
  --media-bg: #eceeed;
  --header-bg: rgba(9, 10, 10, 0.86);
  --overlay: rgba(0, 0, 0, 0.72);

  --ph-bg: #111313;
  --ph-minor: rgba(255, 255, 255, 0.05);
  --ph-major: rgba(255, 255, 255, 0.11);

  --text: #f3f4f2;
  --text-2: #b7bdbb;
  --text-3: #8b9290;

  --brand: #37d4c8;
  --brand-hover: #74e4dc;
  --brand-soft: #0d2a28;
  --on-brand: #031413;
  --accent: #ff7458;
  --focus: #37d4c8;

  --ok: #3ddc97;
  --wait: #ffb454;
  --off: #8b9290;

  --glow-a: rgba(55, 212, 200, 0.2);
  --glow-b: rgba(255, 116, 88, 0.13);

  --shadow-pop: 0 28px 70px -24px rgba(0, 0, 0, 0.9);
}

/* ---------- The mat ----------
   A grid surface, like the studio's desk mat. It follows the theme:
   a pale grid on the white desk (light), a black grid on the black
   desk (dark), so it always matches the rest of the page. */
.mat {
  --mat-bg: var(--bg-2);
  --mat-major: rgba(11, 12, 12, 0.08);
  --mat-minor: rgba(11, 12, 12, 0.035);
  --mat-cell: rgba(255, 255, 255, 0.7);
  --mat-hover: rgba(0, 101, 101, 0.08);
  --mat-press: rgba(0, 101, 101, 0.14);
  --line: rgba(11, 12, 12, 0.1);
  --line-strong: rgba(11, 12, 12, 0.16);

  color: var(--text);
  background-color: var(--mat-bg);
  background-image:
    linear-gradient(var(--mat-major) 1px, transparent 1px),
    linear-gradient(90deg, var(--mat-major) 1px, transparent 1px),
    linear-gradient(var(--mat-minor) 1px, transparent 1px),
    linear-gradient(90deg, var(--mat-minor) 1px, transparent 1px);
  background-size: 96px 96px, 96px 96px, 24px 24px, 24px 24px;
  background-position: center top;
  transition: background-color 0.3s var(--ease);
}
:root[data-theme="dark"] .mat {
  --mat-bg: #0a0b0b;
  --mat-major: rgba(255, 255, 255, 0.1);
  --mat-minor: rgba(255, 255, 255, 0.04);
  --mat-cell: rgba(10, 11, 11, 0.55);
  --mat-hover: rgba(55, 212, 200, 0.12);
  --mat-press: rgba(55, 212, 200, 0.2);
  --line: rgba(255, 255, 255, 0.14);
  --line-strong: rgba(255, 255, 255, 0.3);
  --surface: rgba(255, 255, 255, 0.04);
  --surface-2: rgba(255, 255, 255, 0.09);
}
