/* ==========================================================================
   Trackx branding overrides (Phoenix theme).
   Loaded last, after theme.min.css. Rebrands via CSS vars so we never touch
   the 1 MB compiled theme. Palette: Primair #C5B5A5 · Secundair #5382A4 ·
   Tekst #333333 · Accent #854243. Interactive = Secundair blue.
   ========================================================================== */

/* Brand colours + font — theme-agnostic, apply in light AND dark. */
:root {
  /* Trackx blue (#0274be, from trackx.eu) — the action/interactive colour */
  --phoenix-primary: #0274be;
  --phoenix-primary-rgb: 2, 116, 190;

  /* Primair — beige, used for muted surfaces/badges */
  --phoenix-secondary: #c5b5a5;
  --phoenix-secondary-rgb: 197, 181, 165;

  /* Accent — deep red */
  --phoenix-danger: #854243;
  --phoenix-danger-rgb: 133, 66, 67;

  --phoenix-link-color: #0274be;
  --phoenix-link-color-rgb: 2, 116, 190;
  --phoenix-link-hover-color: #0263a2;

  --phoenix-font-sans-serif: "Montserrat", -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --phoenix-body-font-family: var(--phoenix-font-sans-serif);
}

/* Light-tuned bits — NOT applied in dark theme, so dark keeps its own dark
   surfaces. `:not([data-bs-theme=dark])` = light/default (dark sets the attr). */
:root:not([data-bs-theme="dark"]) {
  --phoenix-primary-text-emphasis: #015185;
  --phoenix-primary-bg-subtle: #e0f0f9;
  --phoenix-primary-border-subtle: #99cae5;

  --phoenix-body-color: #333333;
  --phoenix-body-color-rgb: 51, 51, 51;
  --phoenix-body-bg: #f7f4ed;
  --phoenix-body-bg-rgb: 247, 244, 237;
}

body {
  font-family: var(--phoenix-font-sans-serif);
}

/* App-wide background: Trackx tint + brand image behind the UI — LIGHT ONLY.
   ponytail: no background-attachment:fixed — it repaints badly on mobile
   Safari (this is a PWA). Colour is the guarantee; image is decorative. */
:root:not([data-bs-theme="dark"]) body {
  background-color: #f7f4ed;
  background-image: url("../TRACKX/background.png");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
}

/* .btn-primary/.btn-danger bake literal hex (not vars) in the compiled theme,
   so remap their button-token set to the brand colours. */
.btn-primary {
  --phoenix-btn-bg: #0274be;
  --phoenix-btn-border-color: #0274be;
  --phoenix-btn-hover-bg: #0263a2;
  --phoenix-btn-hover-border-color: #0263a2;
  --phoenix-btn-active-bg: #015185;
  --phoenix-btn-active-border-color: #015185;
  --phoenix-btn-disabled-bg: #0274be;
  --phoenix-btn-disabled-border-color: #0274be;
}

.btn-outline-primary {
  --phoenix-btn-color: #0274be;
  --phoenix-btn-border-color: #0274be;
  --phoenix-btn-hover-bg: #0274be;
  --phoenix-btn-hover-border-color: #0274be;
  --phoenix-btn-active-bg: #0274be;
  --phoenix-btn-active-border-color: #0274be;
}

.btn-danger {
  --phoenix-btn-bg: #854243;
  --phoenix-btn-border-color: #854243;
  --phoenix-btn-hover-bg: #6e3536;
  --phoenix-btn-hover-border-color: #6e3536;
  --phoenix-btn-active-bg: #6e3536;
  --phoenix-btn-active-border-color: #6e3536;
}
