/* Aviemore brand pass. Linked after /_astro/Page.DfL2kBJG.css on every page.
   Source: Aviemore Brand Guidelines, p.08 (color) and p.03-07 (logo). */

:root {
  /* Brand palette */
  --black-bedrock: #1C2023;
  --blue-current:  #1C2C37;
  --copper-vein:   #B05830;
  --gray-strata:   #74797F;
  --white-quartz:  #F5F4F0;

  /* Remap the site's existing tokens onto the palette */
  --paper:   var(--white-quartz);  /* was #fff. Page background is White Quartz */
  --paper-2: #ECEAE3;              /* was #f5f4f0. One shade under Quartz so alternating bands still separate */
  --ink:     var(--black-bedrock); /* same value as before */
  --granite: var(--blue-current);  /* same value as before */
  --russet:  var(--copper-vein);   /* same value; was defined but never used */
  --blue:    #9A4A26;              /* misnamed: a darker Copper Vein, 5.6:1 on Quartz, for small link text */
  --ink-3:   #62676D;              /* was #686e74. Nudged darker so captions and form labels pass 4.5:1 on --paper-2 */

  /* --ink-2 (#545a61) stays. Gray Strata itself is 3.99:1 on White Quartz, under the 4.5:1
     needed for body-size text, so use it for rules and large secondary text only. */
}

body { background: var(--paper); }

/* Brand typeface: Neue Haas Grotesk from Aviemore's Adobe Fonts kit (imv4btk), linked in each
   page head. Text cut for body copy, Display cut for large headings and figures. Schibsted
   Grotesk stays in the stack as the fallback if Adobe Fonts doesn't load. */
:root { --f: "neue-haas-grotesk-text", "Schibsted Grotesk", system-ui, -apple-system, sans-serif; }
h1, h2, .field p, .figs .n { font-family: "neue-haas-grotesk-display", var(--f); }
h1, .figs .n { font-weight: 700; }         /* the kit has no 800; Bold is the brand's heaviest listed weight */
/* The site's tracking was tuned for Schibsted. Neue Haas Display is already tight and its word
   space is narrow, so loosen both or "Smaller form" reads as one word at 128px. */
h1 { letter-spacing: -0.02em; word-spacing: 0.06em; }
h1.mega { letter-spacing: -0.02em; word-spacing: 0.08em; }
h2 { letter-spacing: -0.01em; }
.field p { letter-spacing: -0.02em; word-spacing: 0.06em; }
.field p span::before { content: " "; }   /* markup has no space between "flow." and "No seals." */
.figs .n { letter-spacing: -0.03em; }

/* Headings in Blue Current on light sections. Dark bands keep their light heading color. */
main :is(h1, h2, h3):not(.plate-data *, .field *, .notice *) {
  color: var(--blue-current);
}

/* Primary actions in Copper Vein. White text, not Quartz: #fff on copper is 4.9:1, Quartz is 4.45:1 */
.acts a.p,
form[data-netlify] button[type="submit"] {
  background: var(--copper-vein);
  color: #fff;
}
.acts a.p:hover,
form[data-netlify] button[type="submit"]:hover {
  background: var(--blue);
}

/* Secondary action keeps the outline style, in Blue Current */
.acts a.s {
  color: var(--blue-current);
  background: transparent;
  box-shadow: inset 0 0 0 1px var(--gray-strata);
}
.acts a.s:hover { box-shadow: inset 0 0 0 1px var(--blue-current); }

/* Dark spec panels (Rack CDU, Row & Facility, OEM): an opened "What this means" showed
   dark gray text on Blue Current (about 2:1). The panel rules meant to prevent that are
   outranked by the details component's scoped styles, so these selectors are one step
   more specific. */
dl.plate-inset .row details p { color: var(--on-granite-2); }
dl.plate-inset .row details[open] .cue { color: var(--on-granite-2); }

/* Official logo in the header. Clear space = height of the "A" = 0.52 x logo height.
   Minimum height 16px. The header shows the logo alone (Ben, Nov 10: "just Aviemore"),
   so the span rules below only apply if "Motion Technologies" text is ever added back. */
.wordmark { --logo-h: 28px; display: inline-flex; align-items: flex-end; gap: calc(var(--logo-h) * 0.52); }
.wordmark img { height: var(--logo-h); width: auto; display: block; flex: none; }
/* Sit "Motion Technologies" on the same baseline as the "Aviemore" wordmark (82.5% down the logo) */
.wordmark span { line-height: 1; margin-bottom: calc(var(--logo-h) * 0.175 - 2px); }
@media (max-width: 359px) { .wordmark span { display: none; } }
