/* Site menu, shared by every public page.
 * Everything is scoped under .site-topbar with its own tokens, so the older page stylesheet (style.css)
 * cannot restyle it and it cannot restyle the page. Markup lives in each page; behaviour in site-toolbar.js.
 */

@font-face { font-family: "Be Vietnam Pro"; font-style: normal; font-weight: 400; font-display: swap; src: url("/assets/fonts/be-vietnam-pro/be-vietnam-pro-vietnamese-400-normal.woff2") format("woff2"); unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "Be Vietnam Pro"; font-style: normal; font-weight: 400; font-display: swap; src: url("/assets/fonts/be-vietnam-pro/be-vietnam-pro-latin-400-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Be Vietnam Pro"; font-style: normal; font-weight: 500; font-display: swap; src: url("/assets/fonts/be-vietnam-pro/be-vietnam-pro-vietnamese-500-normal.woff2") format("woff2"); unicode-range: U+0102-0103, U+0110-0111, U+0128-0129, U+0168-0169, U+01A0-01A1, U+01AF-01B0, U+0300-0301, U+0303-0304, U+0308-0309, U+0323, U+0329, U+1EA0-1EF9, U+20AB; }
@font-face { font-family: "Be Vietnam Pro"; font-style: normal; font-weight: 500; font-display: swap; src: url("/assets/fonts/be-vietnam-pro/be-vietnam-pro-latin-500-normal.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

.site-topbar {
  --st-frame: #ffffff;
  --st-ink: #17171a;
  --st-line: #dadad6;
  --st-hover: #efefec;
  --st-focus: #2f6bff;
  --st-accent: #7a1020;
  --st-accent-hover: #5f0c18;
  --st-on-accent: #ffffff;
  --st-shadow: 0 2px 8px rgba(23, 23, 26, 0.08);
  --st-font: "Be Vietnam Pro", -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;

  position: sticky;
  top: 0;
  z-index: 40;
  display: block;
  height: auto;
  margin: 0;
  padding: 16px 0 0;
  border: 0;
  background: none;
  box-shadow: none;
  font-family: var(--st-font);
  font-size: 15px;
  line-height: 1.4;
  letter-spacing: normal;
  text-transform: none;
  -webkit-font-smoothing: antialiased;
}
@media (prefers-color-scheme: dark) {
  .site-topbar {
    --st-frame: #2a2a2e;
    --st-ink: #f2f2ef;
    --st-line: #3d3d42;
    --st-hover: #36363b;
    --st-focus: #5b8cff;
    --st-accent: #8f1628;
    --st-accent-hover: #a41c31;
    --st-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
  }
  /* The maroon logo disappears on the dark bar, so it is shown in light ink. */
  .site-topbar .site-toolbar__brand img { filter: brightness(0) invert(0.93); }
}

/* Pages built on the older layout already leave room for a fixed header, so there the bar floats over the page. */
.site-topbar.site-topbar--fixed { position: fixed; left: 0; right: 0; z-index: 1000; pointer-events: none; }
.site-topbar.site-topbar--fixed .site-toolbar { pointer-events: auto; }

.site-topbar *,
.site-topbar *::before,
.site-topbar *::after { box-sizing: border-box; }

/* style.css forces Roboto on every element with !important. The id outranks that rule, so the menu keeps its font. */
#site-topbar,
#site-topbar * { font-family: var(--st-font) !important; }

.site-topbar .site-toolbar {
  position: relative;
  display: flex;
  align-items: center;
  gap: 16px;
  width: min(1240px, 100% - 2 * clamp(20px, 6.9vw, 100px));
  min-height: 60px;
  margin: 0 auto;
  padding: 0 10px 0 16px;
  border: 1px solid var(--st-line);
  border-radius: 14px;
  background: var(--st-frame);
  box-shadow: var(--st-shadow);
  color: var(--st-ink);
}

.site-topbar .site-toolbar__brand { display: flex; align-items: center; margin: 0 auto 0 0; padding: 0; background: none; }
.site-topbar .site-toolbar__brand img { display: block; width: auto; max-width: none; height: 32px; margin: 0; }

.site-topbar .site-toolbar__nav { display: flex; gap: 4px; margin: 0 auto 0 0; padding: 0; list-style: none; }
.site-topbar .site-toolbar__nav li { margin: 0; padding: 0; list-style: none; }
.site-topbar .site-toolbar__nav a {
  display: block;
  padding: 7px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--st-ink);
  font-family: var(--st-font);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.4;
  letter-spacing: normal;
  text-decoration: none;
  text-transform: none;
  transition: background-color 0.15s ease;
}
.site-topbar .site-toolbar__nav a:hover { background: var(--st-hover); color: var(--st-ink); }
.site-topbar .site-toolbar__nav a[aria-current] { background: var(--st-hover); font-weight: 500; }

.site-topbar .site-toolbar__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  margin: 0;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: var(--st-accent);
  color: var(--st-on-accent);
  font-family: var(--st-font);
  font-size: 14px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: normal;
  text-decoration: none;
  text-transform: none;
  white-space: nowrap;
  transition: background-color 0.15s ease;
}
.site-topbar .site-toolbar__cta:hover { background: var(--st-accent-hover); color: var(--st-on-accent); }

/* "Get in touch" inside the menu: only on small screens, where the menu replaces the bar's links and button */
.site-topbar .site-toolbar__nav li.site-toolbar__nav-cta { display: none; }

.site-topbar .site-toolbar__menu {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin: 0;
  padding: 0;
  border: 1px solid var(--st-line);
  border-radius: 9px;
  background: var(--st-frame);
  color: var(--st-ink);
  cursor: pointer;
}
.site-topbar .site-toolbar__menu svg { display: block; }

.site-topbar a:focus-visible,
.site-topbar button:focus-visible { outline: 2px solid var(--st-focus); outline-offset: 2px; }

.site-topbar .site-toolbar__sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

@media (max-width: 900px) {
  .site-topbar .site-toolbar__nav {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    gap: 2px;
    margin: 0;
    padding: 8px;
    border: 1px solid var(--st-line);
    border-radius: 14px;
    background: var(--st-frame);
    box-shadow: var(--st-shadow);
  }
  .site-topbar .site-toolbar__nav.is-open { display: flex; }
  .site-topbar .site-toolbar__nav a { padding: 12px; font-size: 16px; }
  .site-topbar .site-toolbar__menu { display: inline-flex; }
  /* The bar keeps only the logo and the menu button; "Get in touch" moves to the end of the menu. */
  .site-topbar .site-toolbar__cta { display: none; }
  .site-topbar .site-toolbar__nav li.site-toolbar__nav-cta { display: block; margin-top: 6px; padding-top: 10px; border-top: 1px solid var(--st-line); }
  .site-topbar .site-toolbar__nav .site-toolbar__nav-cta a {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    border-radius: 10px;
    background: var(--st-accent);
    color: var(--st-on-accent);
    font-weight: 500;
  }
  .site-topbar .site-toolbar__nav .site-toolbar__nav-cta a:hover { background: var(--st-accent-hover); color: var(--st-on-accent); }
}
@media (max-width: 640px) {
  .site-topbar .site-toolbar { gap: 8px; padding: 0 8px 0 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .site-topbar .site-toolbar__nav a,
  .site-topbar .site-toolbar__cta { transition: none; }
}

/* The project case-study pages start close to the top of the window. Give their first section room for the floating menu. */
.project-case-hero.project-case-hero--snapshot { padding-top: clamp(112px, 9vw, 140px); }
