/* Links to a section (e.g. #contact) land just below the sticky header */
html { scroll-padding-top: 100px; }
@media (max-width: 760px) { html { scroll-padding-top: 86px; } }

/* Shared site header (corporate page + both divisions).
   Every selector is prefixed .mdh so older page styles cannot reach it,
   and it uses role="banner"/role="navigation" instead of <header>/<nav>.
   Menu: desktop = Our Divisions panel (both divisions side by side) + About + Contact + button;
         phones/tablets = hamburger listing the divisions first, current division expanded. */

.mdh {
  --mdh-bg: #141210;
  --mdh-ink: #141210;
  --mdh-fg: #F0E7DE;
  --mdh-dim: #CFC4B8;
  --mdh-accent: #D49A6A;
  --mdh-line: rgba(212,154,106,.18);
  --mdh-panel: #1C1916;
  --mdh-panel-hover: #2A241F;
  --mdh-panel-border: rgba(212,154,106,.35);
  --mdh-rule: rgba(240,231,222,.12);
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 60;
  background: var(--mdh-bg) url("../img/topo-lines.png") repeat;
  background-size: 900px auto;
  border-bottom: 1px solid var(--mdh-line);
  color: var(--mdh-fg);
  font-family: 'Montserrat', Arial, sans-serif;
  line-height: 1.4;
}
/* Light version for the corporate landing page */
.mdh-light {
  --mdh-bg: #F7F4EF;
  --mdh-fg: #1F1F1F;
  --mdh-dim: #5E5850;
  --mdh-accent: #946F48;
  --mdh-line: #DCD3C8;
  --mdh-panel: #FFFFFF;
  --mdh-panel-hover: #F4F0EA;
  --mdh-panel-border: #DCD3C8;
  --mdh-rule: #E6DED4;
  background-image: none;
}
.mdh *, .mdh *::before, .mdh *::after { box-sizing: border-box; }
.mdh a { color: inherit; text-decoration: none; }
.mdh ul { list-style: none; margin: 0; padding: 0; }
.mdh svg { display: block; }
.mdh button { font: inherit; color: inherit; }
.mdh a, .mdh button { -webkit-tap-highlight-color: transparent; }
.mdh button:focus:not(:focus-visible) { outline: none; background-color: transparent; }
.mdh :focus-visible { outline: 2px solid var(--mdh-accent); outline-offset: 3px; }

.mdh-inner {
  position: relative; width: 100%; max-width: 1240px; margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 40px);
  min-height: 86px; display: flex; align-items: center; justify-content: space-between; gap: 24px;
}

/* Division brand lockup: MD mark + traced wordmark + division name between rules */
.mdh-brand { display: inline-flex; align-items: center; gap: 10px; flex: none; }
.mdh-mark { width: 92px; height: 34px; color: var(--mdh-accent); }
.mdh-brand-text { display: flex; flex-direction: column; gap: 7px; }
.mdh-wordmark { width: 196px; height: 22px; color: var(--mdh-fg); }
.mdh-division { display: flex; align-items: center; gap: 8px; font-size: 9px; font-weight: 500; letter-spacing: .4em; text-transform: uppercase; color: var(--mdh-dim); white-space: nowrap; }
.mdh-division::before, .mdh-division::after { content: ""; flex: 1; min-width: 10px; height: 1px; background: currentColor; opacity: .7; }
/* Corporate brand lockup: mountain mark + serif name + tagline */
.mdh-corp-tag { font-size: 8.5px; letter-spacing: .32em; text-transform: uppercase; color: var(--mdh-dim); }

/* Top-level items */
.mdh-nav { display: flex; align-items: center; gap: clamp(20px, 3.4vw, 48px); }
.mdh-list { display: flex; align-items: center; gap: clamp(18px, 2.8vw, 40px); }
.mdh-link, .mdh-trigger {
  position: relative; display: inline-flex; align-items: center; gap: 7px; min-height: 44px;
  padding: 0; margin: 0; background: none; border: 0; cursor: pointer;
  font: 500 14px/1 'Montserrat', Arial, sans-serif; letter-spacing: 0; text-transform: none; color: var(--mdh-fg);
}
.mdh-link:hover, .mdh-trigger:hover, .mdh-trigger[aria-expanded="true"] { color: var(--mdh-accent); }
.mdh-chev { width: 9px; height: 6px; transition: transform .2s ease; }
.mdh-trigger[aria-expanded="true"] .mdh-chev { transform: rotate(180deg); }
.mdh-cta {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 44px; padding: 12px 22px;
  border: 1.5px solid var(--mdh-accent); border-radius: 2px; color: var(--mdh-fg);
  font: 600 12px/1 'Montserrat', Arial, sans-serif; letter-spacing: .14em; text-transform: uppercase; white-space: nowrap;
}
.mdh-cta:hover { background: rgba(212,154,106,.14); }
.mdh-light .mdh-cta { background: #946F48; border-color: #946F48; color: #fff; }
.mdh-light .mdh-cta:hover { background: #7f5e3c; }

/* Our Divisions panel (desktop) */
.mdh-divisions { position: static; }
.mdh-mega {
  display: none; position: absolute; top: calc(100% - 6px); left: 50%; transform: translateX(-50%);
  width: min(880px, calc(100vw - 32px)); padding: 24px 28px 20px;
  background: var(--mdh-panel); border: 1px solid var(--mdh-panel-border); box-shadow: 0 22px 44px rgba(0,0,0,.35);
}
.mdh-mega.is-open { display: block; }
.mdh-groups { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; align-items: start; }
.mdh-group-head { display: flex; flex-direction: column; gap: 4px; padding: 8px 10px 12px; margin: 0 -10px; }
.mdh-group-head:hover .mdh-group-title, .mdh-group-head:focus-visible .mdh-group-title, .mdh-group-head[aria-current="page"] .mdh-group-title { color: var(--mdh-accent); }
.mdh-group-head:hover { background: var(--mdh-panel-hover); }
.mdh-group-current .mdh-group-head { border-bottom: 1px solid var(--mdh-rule); margin-bottom: 8px; }
.mdh-group-title { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 22px; font-weight: 500; line-height: 1.15; color: var(--mdh-fg); }
.mdh-group-sub { font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--mdh-dim); }
.mdh .mdh-phone-only { display: none; }
.mdh .mdh-group-chev { display: none; width: 12px; height: 8px; flex: none; }
.mdh-group-links a { display: block; padding: 9px 10px; margin: 0 -10px; font-size: 14px; color: var(--mdh-fg); }
.mdh-group-links a:hover, .mdh-group-links a:focus-visible { background: var(--mdh-panel-hover); color: var(--mdh-accent); }
.mdh-group-links a[aria-current="page"] { color: var(--mdh-accent); }
.mdh-group-links a[aria-current="page"]::before { content: ""; display: inline-block; width: 14px; height: 1.5px; margin: 0 8px 4px 0; background: currentColor; vertical-align: middle; }
.mdh-link[aria-current="page"] { color: var(--mdh-accent); }

.mdh-toggle { display: none; }
.mdh-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Phones and tablets: hamburger; divisions listed first as an accordion */
@media (max-width: 1080px) {
  .mdh-toggle { display: inline-grid; place-items: center; width: 44px; height: 44px; margin: 0; padding: 0; background: none; border: 0; cursor: pointer; color: var(--mdh-fg); }
  .mdh-bars, .mdh-bars::before, .mdh-bars::after { display: block; width: 24px; height: 2px; background: currentColor; transition: transform .2s ease; }
  .mdh-bars { position: relative; }
  .mdh-bars::before, .mdh-bars::after { content: ""; position: absolute; left: 0; }
  .mdh-bars::before { top: -7px; }
  .mdh-bars::after { top: 7px; }
  .mdh-toggle[aria-expanded="true"] .mdh-bars { background: transparent; }
  .mdh-toggle[aria-expanded="true"] .mdh-bars::before { transform: translateY(7px) rotate(45deg); }
  .mdh-toggle[aria-expanded="true"] .mdh-bars::after { transform: translateY(-7px) rotate(-45deg); }

  .mdh-nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    max-height: calc(100vh - 86px); overflow-y: auto; -webkit-overflow-scrolling: touch;
    padding: 6px clamp(16px, 4vw, 40px) 24px;
    background: var(--mdh-panel); border-bottom: 1px solid var(--mdh-panel-border); box-shadow: 0 18px 30px rgba(0,0,0,.35);
  }
  .mdh-light .mdh-nav { background: #F7F4EF; }
  .mdh:not(.mdh-light) .mdh-nav { background: #141210; }
  .mdh-nav.is-open { display: flex; }
  .mdh-list { flex-direction: column; align-items: stretch; gap: 0; }
  .mdh-list > li { border-bottom: 1px solid var(--mdh-rule); }
  .mdh-link { width: 100%; min-height: 52px; font-size: 15px; }

  /* "Our Divisions" becomes a section label and its panel is always shown */
  .mdh-divisions > .mdh-trigger { width: 100%; min-height: 40px; cursor: default; pointer-events: none; font-size: 10px; font-weight: 600; letter-spacing: .26em; text-transform: uppercase; color: var(--mdh-accent); padding-top: 10px; }
  .mdh-divisions > .mdh-trigger .mdh-chev { display: none; }
  .mdh-mega, .mdh-mega.is-open { display: block; position: static; transform: none; width: auto; padding: 0 0 12px; background: transparent; border: 0; box-shadow: none; }
  .mdh-groups { grid-template-columns: 1fr; gap: 0; }
  .mdh-group { border-top: 1px solid var(--mdh-rule); }
  .mdh .mdh-desktop-only { display: none; }
  .mdh .mdh-phone-only { display: flex; }
  .mdh-group-head, .mdh-group-toggle { min-height: 60px; padding: 10px 0; margin: 0; justify-content: center; }
  .mdh-group-head:hover { background: transparent; }
  .mdh-group-toggle { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: space-between; column-gap: 12px; width: 100%; background: none; border: 0; text-align: left; cursor: pointer; }
  .mdh-group-title { font-size: 21px; }
  .mdh-group-toggle .mdh-group-sub { order: 3; flex-basis: 100%; }
  .mdh .mdh-group-chev { display: block; color: var(--mdh-accent); transition: transform .2s ease; }
  .mdh-group-toggle[aria-expanded="true"] .mdh-group-chev { transform: rotate(180deg); }
  .mdh-group-links { display: none; padding: 0 0 12px; }
  .mdh-group-links.is-open { display: block; }
  .mdh-group-links a { margin: 2px 0; padding: 11px 0 11px 14px; border-left: 2px solid var(--mdh-accent); font-size: 15px; }
  .mdh-group-links a[aria-current="page"]::before { display: none; }
  .mdh-cta { margin-top: 18px; }
}
@media (max-width: 760px) {
  .mdh-inner { min-height: 74px; }
  .mdh-nav { max-height: calc(100vh - 74px); }
  .mdh-mark { width: 64px; height: 26px; }
  .mdh-wordmark { width: 150px; height: 17px; }
  .mdh-division { font-size: 7.5px; letter-spacing: .3em; }
  .mdh-corp-tag { font-size: 7px; letter-spacing: .26em; }
}
@media (prefers-reduced-motion: reduce) { .mdh * { transition: none !important; } }

/* ===================== Site footers (company pages and Field Services) ===================== */
.fs-footer { background: #141210 url("../img/topo-lines.png") repeat; background-size: 900px auto; color: #F0E7DE; padding-block: 28px 18px; }
.fs-footer a { text-decoration: none; }
.fs-footer-top { display: flex; align-items: center; justify-content: space-between; gap: 28px; flex-wrap: wrap; padding-bottom: 22px; border-bottom: 1px solid rgba(240,231,222,.14); }
.fs-footer-brand { display: inline-flex; align-items: center; gap: 10px; color: #F0E7DE; }
.fs-footer-mark { width: 92px; height: 34px; color: #D49A6A; }
.fs-footer-text { display: flex; flex-direction: column; gap: 7px; }
.fs-footer-wordmark { width: 196px; height: 22px; color: #F0E7DE; }
.fs-footer-division { display: flex; align-items: center; gap: 8px; font-size: 9px; font-weight: 500; letter-spacing: .4em; text-transform: uppercase; color: #CFC4B8; }
.fs-footer-division::before, .fs-footer-division::after { content: ""; flex: 1; min-width: 10px; height: 1px; background: currentColor; opacity: .7; }
.fs-footer-nav { display: flex; flex-wrap: wrap; gap: clamp(14px, 2.4vw, 32px); }
.fs-footer-nav a { font-size: 14px; padding-block: 10px; }
.fs-footer-nav a:hover { color: #D49A6A; }
.fs-social { display: flex; gap: 22px; padding-left: 30px; border-left: 1.5px solid #D49A6A; }
.fs-social a { display: inline-grid; place-items: center; width: 44px; height: 44px; margin: -10px; color: #F0E7DE; }
.fs-social svg { width: 22px; height: 22px; }
.fs-social a:hover { color: #D49A6A; }
.fs-footer-tagline { font-size: 14px; line-height: 1.5; text-align: right; color: #D49A6A; letter-spacing: .06em; }
.fs-footer-bottom { display: flex; justify-content: space-between; gap: 12px 20px; flex-wrap: wrap; padding-top: 16px; font-size: 12px; color: #CFC4B8; }
.fs-footer-legal { display: flex; flex-wrap: wrap; gap: 20px; }
.fs-footer-legal a:hover { text-decoration: underline; }

.fs-footer { font-family: 'Montserrat', Arial, sans-serif; }
.fs-footer p { margin: 0; }
.fs-footer svg { display: block; }
.fs-footer :focus-visible { outline: 2px solid #D49A6A; outline-offset: 3px; }
.fs-wrap { width: 100%; max-width: 1240px; margin: 0 auto; padding-left: clamp(16px, 4vw, 40px); padding-right: clamp(16px, 4vw, 40px); }
/* Company footer brand: mountain mark + serif name + tagline */
.fs-footer-corp-tag { font-size: 8.5px; letter-spacing: .32em; text-transform: uppercase; color: #CFC4B8; }
@media (max-width: 760px) {
  .fs-footer-top { flex-direction: column; align-items: flex-start; }
  .fs-social { padding-left: 0; border-left: 0; }
  .fs-footer-tagline { text-align: left; }
  .fs-footer-mark { width: 64px; height: 26px; }
  .fs-footer-wordmark { width: 150px; height: 17px; }
}

/* ---------- Division hero (MD Field Services), laid out like the Strategic Operations hero ---------- */
.dvh {
  position: relative; overflow: hidden; isolation: isolate;
  background: #141210; color: #F0E7DE; font-family: 'Montserrat', Arial, sans-serif;
  padding-block: clamp(44px, 5vw, 64px) clamp(48px, 5.5vw, 72px);
}
.dvh *, .dvh *::before, .dvh *::after { box-sizing: border-box; }
.dvh p, .dvh h1, .dvh ul { margin: 0; padding: 0; }
.dvh ul { list-style: none; }
.dvh a { text-decoration: none; }
.dvh-photo { position: absolute; z-index: -2; top: 0; right: 0; width: 82%; height: 100%; object-fit: cover; object-position: 70% center; display: block; max-width: none; }
.dvh::before { content: ""; position: absolute; z-index: -1; inset: 0; background: linear-gradient(90deg, #141210 0%, #141210 18%, rgba(20,18,16,.82) 34%, rgba(20,18,16,.25) 58%, rgba(20,18,16,.05) 100%); }
.dvh-inner { width: 100%; max-width: 1240px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 40px); display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; }
.dvh-copy { max-width: 540px; }
.dvh-eyebrow { font-size: 11px; font-weight: 500; letter-spacing: .36em; text-transform: uppercase; color: #CFC4B8; }
.dvh-title { margin-top: 16px !important; font-family: 'Cormorant Garamond', 'Times New Roman', serif; font-weight: 500; font-size: clamp(48px, 6.4vw, 80px); line-height: .98; letter-spacing: 0; text-transform: none; color: #F7F1EA; text-wrap: balance; }
.dvh-kicker { margin-top: 18px !important; font-size: clamp(11px, 1.2vw, 14px); font-weight: 500; letter-spacing: .26em; text-transform: uppercase; }
.dvh-rule { display: block; width: 48px; height: 2px; margin: 20px 0 16px; background: #D49A6A; }
.dvh-tagline { font-family: 'Cormorant Garamond', 'Times New Roman', serif; font-size: clamp(28px, 3.2vw, 40px); line-height: 1.1; color: #D49A6A; }
.dvh-sub { margin-top: 10px !important; font-size: clamp(16px, 1.5vw, 19px); line-height: 1.45; max-width: 26em; }
.dvh-buttons { display: flex; flex-wrap: wrap; gap: 16px; margin-top: 24px; }
.dvh-btn { display: inline-flex; align-items: center; justify-content: center; gap: 12px; min-height: 46px; padding: 12px 28px; border: 1.5px solid transparent; border-radius: 2px; font: 600 12px/1 'Montserrat', Arial, sans-serif; letter-spacing: .14em; text-transform: uppercase; }
.dvh-btn svg { width: 16px; height: 10px; }
.dvh-btn-bronze { background: linear-gradient(180deg, #E0AE80 0%, #C98F5E 100%); color: #141210; }
.dvh-btn-bronze:hover { background: linear-gradient(180deg, #E8BB90 0%, #D29A69 100%); }
.dvh-btn-outline { border-color: #D49A6A; color: #F0E7DE; background: rgba(20,18,16,.35); }
.dvh-btn-outline:hover { background: rgba(212,154,106,.14); }
.dvh-focus { margin-top: 8px !important; padding: 16px 22px 16px 20px !important; border-left: 1.5px solid #D49A6A; display: grid; gap: 14px; background: linear-gradient(90deg, rgba(20,18,16,.62), rgba(20,18,16,.38)); }
.dvh-focus a { font-size: 12px; font-weight: 500; letter-spacing: .3em; text-transform: uppercase; color: #F2E8DE; text-shadow: 0 1px 8px rgba(0,0,0,.7); }
.dvh-focus a:hover { color: #D49A6A; }
.dvh :focus-visible { outline: 2px solid #D49A6A; outline-offset: 3px; }

@media (max-width: 760px) {
  .dvh-photo { width: 100%; object-position: 62% center; }
  .dvh::before { background: linear-gradient(180deg, rgba(20,18,16,.55) 0%, rgba(20,18,16,.82) 45%, #141210 100%); }
  .dvh-inner { flex-direction: column; gap: 28px; }
  .dvh-buttons .dvh-btn { flex: 1 1 100%; }
  .dvh-focus { grid-template-columns: 1fr 1fr; column-gap: 20px; padding: 0 0 0 20px !important; background: none; }
}

/* Social icons are hidden until real profile URLs exist */
.social[hidden], .fs-social[hidden] { display: none !important; }
