/* Homepage instrument palette; keep other pages and compass behaviour unchanged. */
:root .template-page-home {
  color-scheme: dark;
  --bimav-bg: #142226;
  --bimav-surface: #1a2a2e;
  --bimav-raised: #22363b;
  --bimav-text: #e6e2d8;
  --bimav-heading: #e6e2d8;
  --bimav-muted: #9aa6a8;
  --bimav-border: #2c3f44;
  --bimav-accent: #c8a46a;
  --bimav-on-accent: #142226;
  --bimav-brand: #142226;
  --bimav-brand-deep: #13201f;
  --bimav-brand-end: #1b2e33;
  --bimav-footer: #0f1a1d;
  color: var(--bimav-text);
  background: var(--bimav-bg);
}

.bimav-compass-hero {
  --compass-bg: #142226;
  --compass-brass: #c8a46a;
  --compass-ivory: #e6e2d8;
  --compass-grey: #9aa6a8;
  color: var(--compass-ivory);
  background: radial-gradient(ellipse at 75% 48%, #1b2e33 0%, var(--compass-bg) 48%, #0f1a1d 100%);
  padding: 76px 0;
}

.bimav-compass-hero .bimav-compass-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  align-items: center;
  gap: clamp(32px, 6vw, 96px);
}

.bimav-compass-hero .bimav-compass-eyebrow {
  margin: 0 0 22px;
  padding: 0;
  color: var(--compass-brass);
  font: 11px/1.6 ui-monospace, "Courier New", monospace;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.bimav-compass-hero h2 {
  margin: 0 0 24px;
  padding: 0;
  color: var(--compass-ivory);
  font: 400 clamp(36px, 4.5vw, 58px)/1.12 Georgia, "Times New Roman", serif;
  letter-spacing: -.025em;
  text-transform: none;
}

.bimav-compass-hero .bimav-compass-intro {
  max-width: 390px;
  padding: 0;
  margin: 0 0 28px;
  color: var(--compass-grey);
  font-size: 15px;
  line-height: 1.8;
}

.bimav-compass-services {
  display: flex;
  flex-direction: column;
  max-width: 355px;
  border-top: 1px solid #2c3f44;
  background: #1a2a2e;
}

.bimav-compass-hero .bimav-compass-services a {
  display: flex;
  gap: 16px;
  align-items: center;
  min-height: 48px;
  padding: 4px 8px;
  border-bottom: 1px solid #2c3f44;
  color: var(--compass-ivory);
  text-decoration: none;
  font-size: 14px;
  transition: color 180ms ease, background-color 180ms ease;
}

.bimav-compass-services a > span:first-child {
  width: 28px;
  color: var(--compass-brass);
  font: 20px/1 Georgia, "Times New Roman", serif;
}

.bimav-compass-services a > span:last-child {
  margin-left: auto;
  color: var(--compass-brass);
}

.bimav-compass-hero .bimav-compass-services a:is(:hover, .is-selected) {
  color: var(--compass-brass);
  background: #22363b;
}

:root .bimav-compass-hero .bimav-compass-services a:focus-visible {
  outline: 2px solid var(--compass-ivory);
  outline-offset: 3px;
}

.bimav-compass-hero .bimav-compass-status {
  min-height: 2.8em;
  margin: 20px 0 0;
  padding: 0;
  color: var(--compass-grey);
  font: 11px/1.6 ui-monospace, "Courier New", monospace;
}

.bimav-compass-figure {
  width: 400px;
  max-width: 100%;
  margin: 0;
  justify-self: end;
}

.bimav-compass-dial {
  display: block;
  width: 100%;
  height: auto;
  overflow: visible;
  user-select: none;
  -webkit-user-select: none;
}

.bimav-compass-housing,
.bimav-compass-glass,
.bimav-compass-needle-detail {
  pointer-events: none;
}

.bimav-compass-case {
  fill: url(#bimav-compass-case-metal);
  stroke: #62645b;
  stroke-width: 1;
}

.bimav-compass-case-edge {
  fill: none;
  stroke: #080e10;
  stroke-width: 1;
}

.bimav-compass-screw-seat {
  fill: #0d1314;
  stroke: #64665c;
  stroke-width: .6;
}

.bimav-compass-screw {
  fill: url(#bimav-compass-bezel-metal);
  stroke: #929387;
  stroke-width: .5;
}

.bimav-compass-screw-slot {
  fill: none;
  stroke: #0a1012;
  stroke-width: 1.6;
  stroke-linecap: round;
}

.bimav-compass-bezel-shadow {
  fill: #080c0d;
}

.bimav-compass-bezel {
  fill: #23292b;
  stroke: #4a5559;
  stroke-width: .75;
}

.bimav-compass-bezel-edge {
  fill: none;
  stroke: #d0c8b2;
  stroke-opacity: .25;
  stroke-width: .6;
}

.bimav-compass-gasket {
  fill: #080f12;
  stroke: #090d0e;
  stroke-width: 3;
}

.bimav-compass-rim {
  fill: url(#bimav-compass-face);
  stroke: #9c957d;
  stroke-width: 1.2;
}

.bimav-compass-inner-edge {
  fill: none;
  stroke: #02080b;
  stroke-width: 3;
}

.bimav-compass-minutes,
.bimav-compass-hours,
.bimav-compass-guides {
  fill: none;
  stroke: #a2ada4;
  stroke-width: .8;
}

.bimav-compass-hours {
  stroke: #e8e4cc;
  stroke-width: 2;
}

.bimav-compass-guides {
  stroke: #9baea1;
  stroke-opacity: .17;
  stroke-width: .6;
}

.bimav-compass-rose-light {
  fill: #8a9d90;
  fill-opacity: .23;
  stroke: #aab6a0;
  stroke-opacity: .15;
  stroke-width: .5;
}

.bimav-compass-rose-dark {
  fill: #070f13;
  fill-opacity: .45;
  stroke: #aab6a0;
  stroke-opacity: .12;
  stroke-width: .5;
}

.bimav-compass-dial text {
  fill: #e8e8d3;
  text-anchor: middle;
  pointer-events: none;
}

/* Intentionally low contrast: decorative engraving, not an operating scale.
   A separate outer track keeps labels clear of the degree scale and screws. */
.bimav-compass-tachymeter {
  pointer-events: none;
}

.bimav-compass-tachymeter text {
  fill: #3b4549;
  font: 8.5px Arial, Helvetica, sans-serif;
  letter-spacing: 0;
}

.bimav-compass-tachymeter path {
  fill: none;
  stroke: #3b4549;
  stroke-width: .65;
}

.bimav-compass-tachymeter .bimav-compass-tachymeter-caption {
  font-size: 8px;
  letter-spacing: 1.1px;
}

.bimav-compass-degrees {
  font: 10px ui-monospace, "Courier New", monospace;
  dominant-baseline: central;
  letter-spacing: .6px;
}

.bimav-compass-cardinals {
  font: 600 21px/1 Arial, Helvetica, sans-serif;
}

.bimav-compass-dial .bimav-compass-north {
  fill: #ee8c73;
}

.bimav-compass-face-print {
  font: 600 8px Arial, Helvetica, sans-serif;
  letter-spacing: 1.8px;
}

.bimav-compass-dial .bimav-compass-face-caption {
  fill: #a6b1a5;
  font: 6px ui-monospace, "Courier New", monospace;
  letter-spacing: 1.2px;
}

.bimav-compass-lubber-line {
  fill: #d67258;
  stroke: #edb397;
  stroke-width: .6;
}

.bimav-compass-register {
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.bimav-compass-register-bezel {
  fill: url(#bimav-compass-bezel-metal);
  stroke: #080e11;
  stroke-width: 2;
}

.bimav-compass-register-ring {
  fill: url(#bimav-compass-register-face);
  stroke: #788478;
  stroke-width: .8;
  transition: stroke 180ms ease, stroke-width 180ms ease;
}

.bimav-compass-register-ticks {
  fill: none;
  stroke: #91a092;
  stroke-opacity: .45;
  stroke-width: .7;
  pointer-events: none;
}

.bimav-compass-register-light {
  fill: #647568;
  stroke: #060e10;
  stroke-width: 1;
  pointer-events: none;
}

.bimav-compass-dial .bimav-compass-numeral {
  fill: var(--compass-brass);
  font: 27px Georgia, "Times New Roman", serif;
}

.bimav-compass-dial .bimav-compass-register-label {
  fill: #c2caba;
  font: 7px ui-monospace, "Courier New", monospace;
  letter-spacing: .65px;
}

.bimav-compass-register:is(:hover, [aria-current="true"]) .bimav-compass-register-ring {
  stroke: var(--compass-brass);
  stroke-width: 1.8;
}

.bimav-compass-register[aria-current="true"] .bimav-compass-numeral,
.bimav-compass-register[aria-current="true"] .bimav-compass-register-light {
  fill: var(--compass-brass);
}

.bimav-compass-register:is(:hover, :focus-visible) .bimav-compass-numeral {
  fill: var(--compass-brass);
  filter: drop-shadow(0 0 3px var(--compass-brass));
}

.bimav-compass-register-tooltip {
  visibility: hidden;
  pointer-events: none;
}

.bimav-compass-register-tooltip rect {
  fill: var(--compass-bg);
  stroke: var(--compass-brass);
  stroke-width: .7;
}

.bimav-compass-dial .bimav-compass-register-tooltip text {
  fill: var(--compass-brass);
  font: 9px ui-monospace, "Courier New", monospace;
  letter-spacing: 0;
}

.bimav-compass-register:is(:hover, :focus-visible) .bimav-compass-register-tooltip {
  visibility: visible;
}

.bimav-compass-register:focus-visible,
.bimav-compass-needle:focus-visible {
  outline: none;
}

.bimav-compass-register:focus-visible .bimav-compass-register-ring {
  stroke: var(--compass-ivory);
  stroke-width: 2.5;
}

.bimav-compass-needle {
  cursor: grab;
  touch-action: none;
}

.bimav-compass-needle.is-dragging {
  cursor: grabbing;
}

.bimav-compass-needle-hit {
  fill: none;
  stroke: transparent;
  stroke-width: 28;
  pointer-events: stroke;
}

.bimav-compass-needle-shape {
  fill: #a34031;
  stroke: #f69a7d;
  stroke-width: .4;
}

.bimav-compass-needle-facet {
  fill: #f08a6b;
}

.bimav-compass-needle-tail {
  fill: #c8d0be;
  stroke: #f0f0d9;
  stroke-width: .4;
}

.bimav-compass-counterweight {
  fill: #263536;
  stroke: #bcc6b1;
  stroke-width: 1.5;
}

.bimav-compass-hub-rim {
  fill: #0b1416;
  stroke: #bbb394;
  stroke-width: .8;
}

.bimav-compass-hub {
  fill: url(#bimav-compass-pivot-metal);
  stroke: #e5d1a1;
  stroke-width: .6;
}

.bimav-compass-hub-dot {
  fill: #172226;
  stroke: #e7d7af;
  stroke-width: .5;
}

.bimav-compass-hub-hit {
  fill: transparent;
  pointer-events: all;
  cursor: pointer;
}

.bimav-compass-needle:focus-visible .bimav-compass-needle-hit {
  stroke: #e8e2d633;
}

.bimav-compass-needle:focus-visible .bimav-compass-hub-rim {
  stroke: var(--compass-ivory);
  stroke-width: 2.5;
}

.bimav-compass-glass {
  fill: url(#bimav-compass-glass-sheen);
}

.bimav-compass-glass-edge {
  fill: none;
  stroke: #dae5d4;
  stroke-opacity: .15;
  stroke-width: .75;
}

.bimav-compass-figure figcaption {
  padding-top: 15px;
  color: var(--compass-grey);
  text-align: center;
  font: 11px/1.6 ui-monospace, "Courier New", monospace;
}

/* The same readable palette in both saved theme modes, scoped to this page. */
:root .template-page-home :is(h2, h3, h4, h5, h6, h2 a, h3 a, h4 a, h5 a, h6 a) {
  color: var(--bimav-heading);
}

:root .template-page-home .template-content p {
  color: var(--bimav-text);
}

:root .template-page-home :is(.template-background-color-1, .template-background-color-2,
  .template-component-blockquote) {
  background-color: var(--bimav-surface);
}

:root .template-page-home .template-background-image-5 {
  background-color: var(--bimav-bg);
}

:root .template-page-home :is(.template-component-header-subheader > span,
  .template-component-italic) {
  color: var(--bimav-muted);
}

:root .template-page-home :is([class^="template-icon-feature-"],
  [class*=" template-icon-feature-"], .template-component-list li > span) {
  color: var(--bimav-accent);
}

:root .template-page-home :is(.template-component-divider,
  .template-component-header-subheader > div) {
  background-color: var(--bimav-border);
}

:root .template-page-home .template-component-process-list > ul > li > span {
  color: var(--bimav-heading);
  border-color: var(--bimav-border);
}

:root .template-page-home .template-content a:not(.template-component-button) {
  color: var(--bimav-accent);
}

:root .template-page-home :is(input:not([type="submit"]), textarea, select) {
  color: var(--bimav-text);
  background-color: var(--bimav-surface);
  border-color: var(--bimav-border);
}

:root .template-page-home .template-component-form-field label {
  color: var(--bimav-muted);
}

:root .template-page-home .template-header .template-header-top {
  background: linear-gradient(110deg, #13201f, #142226);
  border-color: var(--bimav-border);
}

:root .template-page-home .template-header .template-header-top .template-component-menu-default > .sf-menu a,
:root .template-page-home .template-header .template-header-top .template-header-top-icon-list :is(a, button),
:root .template-page-home .template-header .template-header-top .template-icon-meta-menu:before,
:root .template-page-home .flexnav li a {
  color: var(--bimav-text);
}

:root .template-page-home .template-header .template-header-top .template-component-menu-default > .sf-menu a:is(:hover, .template-state-selected),
:root .template-page-home .template-header .template-header-top .template-header-top-icon-list a:hover,
:root .template-page-home .flexnav li a:is(:hover, .template-state-selected) {
  color: var(--bimav-accent);
}

:root .template-page-home :is(.template-component-menu-default > .sf-menu > li ul,
  .template-component-menu-default > .sf-menu > li > ul:before,
  .template-component-menu-responsive > ul, .flexnav li a,
  .flexnav li ul li a, .flexnav li.item-with-ul ul, .flexnav .touch-button) {
  background-color: var(--bimav-bg);
  border-color: var(--bimav-border);
}

/* Use the logo made for dark backgrounds also when the saved mode is light. */
:root .template-page-home .template-header .template-header-top .template-header-top-logo a .template-logo {
  display: inline-block;
}

:root .template-page-home .template-header .template-header-top .template-header-top-logo a .template-logo-sticky {
  display: none;
}

:root .template-page-home .template-footer,
:root .template-page-home .template-footer a {
  color: var(--bimav-muted);
}

:root .template-page-home .template-footer a:hover {
  color: var(--bimav-heading);
}

:root .template-page-home .template-footer .template-footer-bottom {
  border-color: var(--bimav-border);
}

/* Buttons and their states share one dark fill and a thin brass edge. */
:root .template-page-home .template-component-button,
:root .template-page-home .bimav-relocation-notice .bimav-relocation-booking,
:root .template-page-home .template-component-go-to-top {
  color: var(--bimav-text);
  background-color: var(--bimav-surface);
  background-image: none;
  border: 1px solid var(--bimav-accent);
}

:root .template-page-home .template-component-button:hover,
:root .template-page-home .bimav-relocation-notice .bimav-relocation-booking:hover,
:root .template-page-home .template-component-go-to-top:hover {
  color: var(--bimav-text);
  background-color: var(--bimav-raised);
}

:root .template-page-home .template-component-button:focus-visible,
:root .template-page-home .bimav-relocation-notice .bimav-relocation-booking:focus-visible,
:root .template-page-home .template-component-go-to-top:focus-visible {
  outline: 2px solid var(--bimav-accent);
  outline-offset: 3px;
}

@media (max-width: 800px) {
  .bimav-compass-hero {
    background: radial-gradient(ellipse at 50% 75%, #1b2e33 0%, var(--compass-bg) 48%, #0f1a1d 100%);
    padding: 48px 0;
  }

  .bimav-compass-hero .bimav-compass-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .bimav-compass-copy {
    text-align: center;
  }

  .bimav-compass-hero .bimav-compass-intro,
  .bimav-compass-services {
    margin-left: auto;
    margin-right: auto;
  }

  .bimav-compass-figure {
    justify-self: center;
  }
}

@media (prefers-reduced-motion: reduce) {
  .bimav-compass-hero a,
  .bimav-compass-register-ring {
    transition: none;
  }
}
