/* ==========================================================================
   BRG Creative Group — site.css
   Shared design system for every page. One file, no build step.

   World: a consulting firm's printed prospectus brought to the screen.
   Paper ground, ink type, a single deep-marine field color for the
   sections that need weight. Flat color only: no gradients, no glow,
   no glass. Archivo carries headings and interface, Source Serif 4
   carries reading text.
   ========================================================================== */

/* Self-hosted fonts (no third-party requests, no layout shift on slow networks) */
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 400; font-display: swap; src: url('/assets/fonts/archivo-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 500; font-display: swap; src: url('/assets/fonts/archivo-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 600; font-display: swap; src: url('/assets/fonts/archivo-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Archivo'; font-style: normal; font-weight: 700; font-display: swap; src: url('/assets/fonts/archivo-latin-700-normal.woff2') format('woff2'); }
@font-face { font-family: 'Source Serif 4'; font-style: normal; font-weight: 400; font-display: swap; src: url('/assets/fonts/source-serif-4-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Source Serif 4'; font-style: italic; font-weight: 400; font-display: swap; src: url('/assets/fonts/source-serif-4-latin-400-italic.woff2') format('woff2'); }
@font-face { font-family: 'Source Serif 4'; font-style: normal; font-weight: 600; font-display: swap; src: url('/assets/fonts/source-serif-4-latin-600-normal.woff2') format('woff2'); }

:root {
  --paper: #f4f2ec;
  --paper-2: #ffffff;
  --ink: #141412;
  --ink-2: #4a4843;
  --ink-3: #6f6c64;
  --rule: #d8d5cc;
  --rule-strong: #141412;
  --field: #0f2233;
  --field-2: #142b40;
  --field-ink: #f4f2ec;
  --field-mute: #a9b8c4;
  --field-rule: #2a4257;
  --brass: #9a7a35;

  --sans: 'Archivo', 'Helvetica Neue', Arial, sans-serif;
  --serif: 'Source Serif 4', Georgia, 'Times New Roman', serif;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --ease-in-out: cubic-bezier(0.77, 0, 0.175, 1);

  --nav-h: 72px;
  --gutter: 48px;
  --max: 1360px;
  --section: 128px;
}

/* --------------------------------------------------------------------------
   Reset & base
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, video, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ul, ol { list-style: none; }
strong { font-weight: 600; }

::selection { background: var(--field); color: var(--field-ink); }
:focus-visible { outline: 2px solid var(--field); outline-offset: 3px; }
.field :focus-visible { outline-color: var(--field-ink); }

.skip {
  position: absolute; left: 16px; top: -60px;
  padding: 10px 14px; background: var(--ink); color: var(--paper);
  font-size: 13px; z-index: 200;
}
.skip:focus { top: 16px; }

/* --------------------------------------------------------------------------
   Layout
   -------------------------------------------------------------------------- */
.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter);
}

.section { padding: var(--section) 0; }
.section.rule { border-top: 1px solid var(--rule); }
.section.white { background: var(--paper-2); }

.field { background: var(--field); color: var(--field-ink); }
.field .muted { color: var(--field-mute); }

/* Section heads: a small sans line, then the heading that does the talking */
.head {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 48px;
  align-items: end;
  margin-bottom: 72px;
}
.head h1, .head h2 { grid-column: 1 / -1; }
.head .lead { grid-column: 2; }
.head.single { grid-template-columns: 1fr; }
.head.single .lead { grid-column: 1; max-width: 60ch; }

/* --------------------------------------------------------------------------
   Typography
   -------------------------------------------------------------------------- */
h1, h2, h3, h4 {
  font-family: var(--sans);
  font-weight: 600;
  line-height: 1.05;
  letter-spacing: -0.025em;
  text-wrap: balance;
}
h1 { font-size: clamp(42px, 5.8vw, 84px); font-weight: 700; letter-spacing: -0.035em; line-height: 0.98; }
h2 { font-size: clamp(34px, 4.2vw, 60px); }
h3 { font-size: clamp(22px, 2vw, 28px); letter-spacing: -0.02em; }
h4 { font-size: 18px; letter-spacing: -0.01em; }

.lead {
  font-family: var(--serif);
  font-size: clamp(18px, 1.5vw, 22px);
  line-height: 1.55;
  color: var(--ink-2);
  text-wrap: pretty;
}
.field .lead { color: var(--field-mute); }

.prose, .prose p {
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.6;
  color: var(--ink-2);
  text-wrap: pretty;
}
.field .prose, .field .prose p { color: var(--field-mute); }

.label {
  font-family: var(--sans);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.field .label { color: var(--field-mute); }

.muted { color: var(--ink-3); }
.num { font-variant-numeric: tabular-nums lining-nums; }

/* --------------------------------------------------------------------------
   Buttons & links
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  height: 52px;
  padding: 0 22px 0 26px;
  background: var(--ink);
  color: var(--paper);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  border-radius: 2px;
  white-space: nowrap;
  transition: background-color 200ms var(--ease-out), transform 160ms var(--ease-out), color 200ms var(--ease-out);
}
.btn svg { width: 16px; height: 16px; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; transition: transform 240ms var(--ease-out); }
.btn:active { transform: scale(0.98); }
@media (hover: hover) and (pointer: fine) {
  .btn:hover { background: var(--field); }
  .btn:hover svg { transform: translate(2px, -2px); }
}
.btn.ghost {
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--rule-strong);
}
@media (hover: hover) and (pointer: fine) {
  .btn.ghost:hover { background: var(--ink); color: var(--paper); }
}
.field .btn { background: var(--field-ink); color: var(--field); }
.field .btn.ghost { background: transparent; color: var(--field-ink); box-shadow: inset 0 0 0 1px var(--field-ink); }
@media (hover: hover) and (pointer: fine) {
  .field .btn:hover { background: #ffffff; }
  .field .btn.ghost:hover { background: var(--field-ink); color: var(--field); }
}

.link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink);
  border-bottom: 1px solid var(--rule-strong);
  padding-bottom: 2px;
  transition: color 200ms var(--ease-out), border-color 200ms var(--ease-out);
}
.link svg { width: 14px; height: 14px; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; transition: transform 240ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) {
  .link:hover { color: var(--field); border-color: var(--field); }
  .link:hover svg { transform: translate(2px, -2px); }
}
.field .link { color: var(--field-ink); border-color: var(--field-ink); }

.text-link { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; text-decoration-color: var(--rule); transition: text-decoration-color 200ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .text-link:hover { text-decoration-color: currentColor; } }

/* --------------------------------------------------------------------------
   Navigation
   -------------------------------------------------------------------------- */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  background: var(--paper);
  border-bottom: 1px solid transparent;
  transition: border-color 240ms var(--ease-out), background-color 240ms var(--ease-out);
}
.nav.scrolled { border-bottom-color: var(--rule); }
/* Over a dark hero the bar is transparent and its type goes light */
.nav.on-dark:not(.menu-open) { background: transparent; border-bottom-color: transparent; color: var(--field-ink); }
.nav.on-dark:not(.menu-open) .brand,
.nav.on-dark:not(.menu-open) .nav-links > li > a,
.nav.on-dark:not(.menu-open) .nav-links > li > button { color: var(--field-ink); }
.nav.on-dark:not(.menu-open) .nav-links .cta .btn { background: var(--field-ink); color: var(--field); }
.nav.on-dark:not(.menu-open) .nav-toggle span { background: var(--field-ink); }
.nav.menu-open { background: var(--paper); border-bottom-color: var(--rule); }
.nav .wrap {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 600;
  font-size: 15px;
  letter-spacing: -0.01em;
  color: var(--ink);
}
.brand .brand-mark { display: block; flex: none; height: 18px; width: auto; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}
.nav-links > li > a,
.nav-links > li > button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-2);
  padding: 8px 0;
  transition: color 160ms var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .nav-links > li > a:hover,
  .nav-links > li > button:hover { color: var(--ink); }
}
.nav-links > li > a[aria-current="page"] { color: var(--ink); }
.nav-links .cta { margin-left: 8px; }
.nav-links .cta .btn { height: 42px; padding: 0 16px 0 18px; font-size: 13px; color: var(--paper); }

/* Resources dropdown */
.dd { position: relative; }
.dd > button svg { width: 12px; height: 12px; stroke: currentColor; fill: none; stroke-width: 1.6; stroke-linecap: round; transition: transform 200ms var(--ease-out); }
.dd[data-open="true"] > button svg { transform: rotate(180deg); }
.dd-menu {
  position: absolute;
  top: calc(100% + 10px);
  left: -16px;
  min-width: 200px;
  background: var(--paper-2);
  border: 1px solid var(--rule);
  box-shadow: 0 12px 32px -12px rgba(20, 20, 18, 0.25);
  padding: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px) scale(0.98);
  transform-origin: top left;
  transition: opacity 180ms var(--ease-out), transform 180ms var(--ease-out), visibility 180ms;
}
.dd[data-open="true"] .dd-menu,
.dd:hover .dd-menu,
.dd:focus-within .dd-menu { opacity: 1; visibility: visible; transform: none; }
.dd-menu::before { content: ''; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }
.dd-menu a {
  display: block;
  padding: 10px 12px;
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-2);
  border-radius: 2px;
  transition: background-color 160ms var(--ease-out), color 160ms var(--ease-out);
}
.dd-menu a small { display: block; font-family: var(--serif); font-size: 13px; font-weight: 400; color: var(--ink-3); margin-top: 2px; }
@media (hover: hover) and (pointer: fine) {
  .dd-menu a:hover { background: var(--paper); color: var(--ink); }
}

/* Mobile toggle (hamburger morphs to X) */
.nav-toggle {
  display: none;
  position: relative;
  width: 44px; height: 44px;
  margin-right: -10px;
}
.nav-toggle span {
  position: absolute;
  left: 12px; right: 12px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 260ms var(--ease-out), opacity 160ms var(--ease-out);
}
.nav-toggle span:nth-child(1) { top: 17px; }
.nav-toggle span:nth-child(2) { top: 26px; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(4.5px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { transform: translateY(-4.5px) rotate(-45deg); }

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */
.footer {
  border-top: 1px solid var(--rule-strong);
  padding: 64px 0 40px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px;
}
.footer .brand { margin-bottom: 20px; }
.footer .tag { font-family: var(--serif); font-size: 16px; color: var(--ink-2); max-width: 32ch; line-height: 1.5; }
.footer h4 { font-size: 12px; font-weight: 500; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); margin-bottom: 18px; }
.footer li + li { margin-top: 10px; }
.footer li a { font-size: 15px; color: var(--ink-2); transition: color 160ms var(--ease-out); }
@media (hover: hover) and (pointer: fine) { .footer li a:hover { color: var(--ink); } }
.footer-base {
  margin-top: 56px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--ink-3);
}

/* --------------------------------------------------------------------------
   Media
   -------------------------------------------------------------------------- */
.media {
  position: relative;
  overflow: hidden;
  background: var(--ink);
}
.media video, .media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* Poster image sits under the video; the video fades in once it is actually playing */
.media video[data-src] { opacity: 0; transition: opacity 500ms var(--ease-out); }
.media video[data-src].is-playing { opacity: 1; }
.media.r-16-9 { aspect-ratio: 16 / 9; }
.media.r-21-9 { aspect-ratio: 21 / 9; }
.media.r-9-16 { aspect-ratio: 9 / 16; }
.media.r-4-5 { aspect-ratio: 4 / 5; }

/* --------------------------------------------------------------------------
   Ledger rows (services, insights, contact directory)
   -------------------------------------------------------------------------- */
.ledger { border-top: 1px solid var(--rule-strong); }
.ledger-row {
  display: grid;
  grid-template-columns: minmax(0, 3fr) minmax(0, 4fr) minmax(0, 5fr);
  gap: 40px;
  padding: 40px 0;
  border-bottom: 1px solid var(--rule);
  align-items: start;
}
.ledger-row .label { padding-top: 6px; }

/* --------------------------------------------------------------------------
   Scroll reveal (one grammar, used sparingly)
   -------------------------------------------------------------------------- */
.js .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 700ms var(--ease-out), transform 700ms var(--ease-out);
}
.js .reveal.is-in { opacity: 1; transform: none; }
.js .reveal[data-delay="1"] { transition-delay: 80ms; }
.js .reveal[data-delay="2"] { transition-delay: 160ms; }
.js .reveal[data-delay="3"] { transition-delay: 240ms; }

/* --------------------------------------------------------------------------
   Article (Read mode)
   -------------------------------------------------------------------------- */
.article-head {
  padding: calc(var(--nav-h) + 72px) 0 56px;
  border-bottom: 1px solid var(--rule-strong);
}
.article-head .eyebrow { font-size: 13px; font-weight: 500; color: var(--ink-3); margin-bottom: 28px; }
.article-head .eyebrow a { color: var(--ink-2); }
.article-head .eyebrow a:hover { color: var(--ink); }
.article-head h1 { font-size: clamp(36px, 4.6vw, 64px); max-width: 20ch; }
.article-head .byline { margin-top: 28px; font-size: 14px; color: var(--ink-3); }

.article-body {
  max-width: 720px;
  padding: 64px 0 96px;
}
.article-body > * + * { margin-top: 1.4em; }
.article-body p, .article-body li {
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.65;
  color: var(--ink-2);
  text-wrap: pretty;
}
.article-body p.lede {
  font-size: 23px;
  line-height: 1.5;
  color: var(--ink);
}
.article-body h2 {
  font-size: clamp(26px, 2.6vw, 34px);
  margin-top: 2.2em;
  margin-bottom: 0.6em;
  color: var(--ink);
}
.article-body h3 { font-size: 21px; margin-top: 1.8em; margin-bottom: 0.4em; }
.article-body ul, .article-body ol { padding-left: 24px; }
.article-body ul { list-style: disc; }
.article-body ol { list-style: decimal; }
.article-body li + li { margin-top: 0.7em; }
.article-body li strong { color: var(--ink); font-weight: 600; }
.article-body a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; text-decoration-color: var(--rule); transition: text-decoration-color 200ms var(--ease-out); }
.article-body a:hover { text-decoration-color: currentColor; }
.article-body .callout {
  background: var(--paper-2);
  border: 1px solid var(--rule);
  padding: 32px 36px;
  margin-top: 2.2em;
}
.article-body .callout p { font-size: 21px; line-height: 1.5; color: var(--ink); }
.article-body .faq h3 { margin-top: 1.6em; }
.article-body .faq h3:first-child { margin-top: 0; }
.article-body .faq p { font-size: 18px; }
.article-body .cta-block {
  margin-top: 4em;
  background: var(--field);
  color: var(--field-ink);
  padding: 48px;
}
.article-body .cta-block h3 { font-size: 28px; margin: 0 0 12px; color: var(--field-ink); }
.article-body .cta-block p { color: var(--field-mute); font-size: 18px; margin-bottom: 28px; }
.article-body .cta-btn {
  display: inline-flex; align-items: center; height: 52px; padding: 0 26px;
  background: var(--field-ink); color: var(--field);
  font-family: var(--sans); font-size: 14px; font-weight: 500; text-decoration: none;
  border-radius: 2px;
  transition: background-color 200ms var(--ease-out), transform 160ms var(--ease-out);
}
.article-body .cta-btn:hover { background: #ffffff; text-decoration: none; }
.article-body .cta-btn:active { transform: scale(0.98); }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */
@media (max-width: 1100px) {
  :root { --gutter: 32px; --section: 96px; }
  .footer-grid { grid-template-columns: 1.5fr 1fr 1fr; }
  .footer-grid > :first-child { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  :root { --gutter: 24px; --section: 80px; --nav-h: 64px; }

  .head { grid-template-columns: 1fr; gap: 20px; margin-bottom: 48px; }
  .head .lead { grid-column: 1; }

  .ledger-row { grid-template-columns: 1fr; gap: 12px; padding: 28px 0; }
  .ledger-row .label { padding-top: 0; }

  .nav-toggle { display: block; }
  .nav-links {
    position: fixed;
    top: var(--nav-h); left: 0; right: 0; bottom: 0;
    background: var(--paper);
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    padding: 24px var(--gutter) 40px;
    overflow-y: auto;
    visibility: hidden;
    opacity: 0;
    transition: opacity 200ms var(--ease-out), visibility 200ms;
  }
  .nav-links.open { visibility: visible; opacity: 1; }
  .nav-links > li {
    border-bottom: 1px solid var(--rule);
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 320ms var(--ease-out), transform 320ms var(--ease-out);
  }
  .nav-links.open > li { opacity: 1; transform: none; }
  .nav-links.open > li:nth-child(1) { transition-delay: 40ms; }
  .nav-links.open > li:nth-child(2) { transition-delay: 80ms; }
  .nav-links.open > li:nth-child(3) { transition-delay: 120ms; }
  .nav-links.open > li:nth-child(4) { transition-delay: 160ms; }
  .nav-links.open > li:nth-child(5) { transition-delay: 200ms; }
  .nav-links.open > li:nth-child(6) { transition-delay: 240ms; }
  .nav-links.open > li:nth-child(7) { transition-delay: 280ms; }
  .nav-links > li > a,
  .nav-links > li > button {
    display: flex; width: 100%;
    padding: 18px 0;
    font-size: 24px;
    font-weight: 600;
    letter-spacing: -0.02em;
    color: var(--ink);
  }
  .nav-links > li > button svg { display: none; }
  .dd-menu {
    position: static;
    opacity: 1; visibility: visible; transform: none;
    background: none; border: 0; box-shadow: none;
    padding: 0 0 12px;
    min-width: 0;
  }
  .dd-menu a { padding: 8px 0; font-size: 17px; }
  .dd-menu a small { display: none; }
  .nav-links .cta { margin: 24px 0 0; border-bottom: 0; }
  .nav-links .cta .btn { height: 52px; width: 100%; justify-content: center; font-size: 15px; }

  .footer { padding: 48px 0 32px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px 24px; }
  .footer-grid > :first-child { grid-column: 1 / -1; }
  .footer-base { margin-top: 40px; }

  .article-head { padding: calc(var(--nav-h) + 40px) 0 36px; }
  .article-body { padding: 40px 0 72px; }
  .article-body p, .article-body li { font-size: 17px; }
  .article-body p.lede { font-size: 20px; }
  .article-body .callout { padding: 24px; }
  .article-body .callout p { font-size: 19px; }
  .article-body .cta-block { padding: 32px 24px; }
}

@media (max-width: 480px) {
  :root { --gutter: 20px; --section: 64px; }
  .industries-cta .btn { width: 100%; justify-content: center; }
  .btn { height: 48px; padding: 0 18px 0 20px; font-size: 13px; }
}

/* --------------------------------------------------------------------------
   Reduced motion: keep fades, remove movement
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal { transform: none; transition: opacity 300ms ease; }
  .nav-links > li { transform: none; }
  .btn:active, .article-body .cta-btn:active { transform: none; }
  .btn svg, .link svg { transition: none; }
}
