/* WilhelmSK brand palette — mirrors wilhelmsk.com. Exact colors sampled by David
   with Digital Color Meter in sRGB: dark teal-black title bar #081E20 (rgb 8,30,32)
   over a deep-brown body #382A23 (rgb 56,42,35), white text, and a brass accent
   #AB9567 (rgb 171,149,103). (These match the site's underlying Wix theme tokens.)
   Applied to Material's two schemes (slate = dark default, default = light) via
   `primary/accent: custom` in mkdocs.yml. */
:root {
  --wsk-body:        #382a23;  /* deep brown — main content background */
  --wsk-body-raised: #443429;  /* slightly lifted brown — cards, admonitions */
  --wsk-header:      #081e20;  /* dark teal-black — title bar */
  --wsk-header-light:#123233;  /* lifted header — nav hover */
  --wsk-header-dark: #051315;  /* deepest header shade */
  --wsk-brass:       #ab9567;  /* brass accent — links/wordmark on dark */
  --wsk-brass-dark:  #7e6e4c;  /* darker brass — readable links on light scheme */
}

/* Dark scheme — the default: dark teal-black title bar over a deep-brown body */
[data-md-color-scheme="slate"] {
  --md-default-bg-color:        var(--wsk-body);
  --md-default-bg-color--light: var(--wsk-body-raised);
  --md-code-bg-color:           var(--wsk-header);         /* code blocks share the title-bar dark */
  --md-primary-fg-color:        var(--wsk-header);         /* header / title bar */
  --md-primary-fg-color--light: var(--wsk-header-light);
  --md-primary-fg-color--dark:  var(--wsk-header-dark);
  --md-primary-bg-color:        #ffffff;                   /* header text/icons */
  --md-primary-bg-color--light: rgba(255,255,255,0.7);
  --md-accent-fg-color:         var(--wsk-brass);           /* hovered links, active nav */
  --md-typeset-a-color:         var(--wsk-brass);           /* body links */
}

/* Light scheme — same title-bar dark + brass accents, so the toggle stays on-brand */
[data-md-color-scheme="default"] {
  --md-primary-fg-color:        var(--wsk-header);
  --md-primary-fg-color--light: var(--wsk-header-light);
  --md-primary-fg-color--dark:  var(--wsk-header-dark);
  --md-primary-bg-color:        #ffffff;
  --md-primary-bg-color--light: rgba(255,255,255,0.7);
  --md-accent-fg-color:         var(--wsk-brass-dark);
  --md-typeset-a-color:         var(--wsk-brass-dark);
}

/* Wordmark in brass. Targets only the site-title topic (first .md-header__topic),
   so the brass picks out the "WilhelmSK Documentation" wordmark while the search
   box, tab labels, icons, and the page-title that appears on scroll stay white. */
.md-header__topic:first-child .md-ellipsis {
  color: var(--wsk-brass);
  font-weight: 700;
}

/* Gauge Reference path tables.
   These three-column tables (Gauge | Displays | SignalK Path) are wrapped in
   <div class="gauge-ref" markdown> in user-guide.md. A fixed layout with
   explicit column widths lets the Displays column absorb the wrapping so the
   SignalK paths stay on as few lines as possible, and keeps each path name from
   breaking mid-token. Scoped to .gauge-ref so other tables are unaffected. */
.md-typeset .gauge-ref table {
  table-layout: fixed;
  width: 100%;
}

.md-typeset .gauge-ref th:nth-child(1),
.md-typeset .gauge-ref td:nth-child(1) {
  width: 15%;
}

.md-typeset .gauge-ref th:nth-child(2),
.md-typeset .gauge-ref td:nth-child(2) {
  width: 52%;
}

.md-typeset .gauge-ref th:nth-child(3),
.md-typeset .gauge-ref td:nth-child(3) {
  width: 33%;
}

/* Never break a single SignalK path mid-name; multi-path cells still wrap
   between the separate paths. */
.md-typeset .gauge-ref td code {
  white-space: nowrap;
}
