/* Responsive, touch and accessibility refinements */
:root {
  --header-height: 96px;
}

html {
  scroll-padding-top: calc(var(--header-height) + 20px);
}

body {
  overflow-x: hidden;
}

main,
section,
article,
div {
  min-width: 0;
}

a,
button,
input,
textarea,
select {
  touch-action: manipulation;
}

a,
button {
  -webkit-tap-highlight-color: rgba(221, 194, 126, 0.22);
}

:focus-visible {
  outline: 2px solid var(--gold-light);
  outline-offset: 4px;
}

.skip-link {
  position: fixed;
  z-index: 200;
  top: 12px;
  left: 12px;
  color: var(--midnight);
  background: var(--gold-light);
  padding: 12px 18px;
  font-size: 13px;
  font-weight: 700;
  transform: translateY(-160%);
  transition: transform 0.2s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header {
  position: sticky;
  top: 0;
}

.site-header .brand {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

.site-header nav a,
.header-action,
.button,
.text-link,
.footer-nav a,
.footer-contact a {
  min-height: 44px;
}

.site-header nav a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
}

.site-header nav a[aria-current="page"] {
  color: var(--gold-light);
  border-bottom-color: var(--gold);
}

.nav-toggle,
.site-header nav .mobile-nav-action {
  display: none;
}

.footer-contact a,
.contact-details dd,
.contact-details a {
  overflow-wrap: anywhere;
}

.executive-portrait {
  position: relative;
  isolation: isolate;
  width: 100%;
  max-width: 560px;
  aspect-ratio: 4 / 5;
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(184, 148, 80, 0.66);
  background: var(--midnight);
  box-shadow: 0 28px 70px rgba(3, 17, 31, 0.2);
}

.executive-portrait::before {
  content: "";
  position: absolute;
  z-index: 2;
  inset: 14px;
  border: 1px solid rgba(221, 194, 126, 0.25);
  pointer-events: none;
}

.executive-portrait::after {
  content: "";
  position: absolute;
  z-index: 1;
  inset: 48% 0 0;
  background: linear-gradient(to bottom, transparent, rgba(3, 17, 31, 0.88));
  pointer-events: none;
}

.executive-portrait picture,
.executive-portrait img {
  width: 100%;
  height: 100%;
  display: block;
}

.executive-portrait img {
  object-fit: cover;
  object-position: center 24%;
}

.executive-portrait figcaption {
  position: absolute;
  z-index: 3;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  padding: 30px 32px;
  color: var(--ivory);
}

.executive-portrait figcaption strong {
  font-family: var(--serif);
  font-size: clamp(25px, 2.3vw, 34px);
  font-weight: 400;
  line-height: 1;
}

.executive-portrait figcaption span {
  color: var(--gold-light);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 9px;
  font-weight: 700;
  white-space: nowrap;
}

.leadership-preview .executive-portrait,
.leadership-detail .executive-portrait {
  justify-self: start;
}

.field input,
.field textarea {
  font-size: 16px;
}

.field input {
  min-height: 48px;
}

.field textarea {
  min-height: 160px;
}

@media (width <= 1180px) {
  .header-action {
    display: none;
  }

  .site-header {
    gap: 24px;
  }

  .site-header nav {
    gap: clamp(16px, 2vw, 28px);
  }
}

@media (width <= 800px) {
  :root {
    --header-height: 80px;
  }

  body.menu-open {
    overflow: hidden;
  }

  .site-header {
    z-index: 100;
    display: flex;
    align-items: center;
    min-height: var(--header-height);
    height: var(--header-height);
    padding: 0 max(24px, env(safe-area-inset-right)) 0 max(24px, env(safe-area-inset-left));
  }

  .site-header .brand {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }

  .site-header .wordmark {
    font-size: clamp(14px, 2.6vw, 17px);
  }

  .nav-toggle {
    display: flex;
    min-width: 88px;
    min-height: 44px;
    margin-left: auto;
    padding: 0 13px;
    border: 1px solid rgba(184, 148, 80, 0.72);
    color: var(--gold-light);
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    cursor: pointer;
  }

  .nav-toggle-label {
    text-transform: uppercase;
    letter-spacing: 0.14em;
    font-size: 9px;
    font-weight: 700;
  }

  .nav-toggle-icon {
    position: relative;
    width: 18px;
    height: 12px;
  }

  .nav-toggle-icon i {
    position: absolute;
    left: 0;
    width: 18px;
    height: 1px;
    background: currentColor;
    transition: transform 0.2s ease, top 0.2s ease;
  }

  .nav-toggle-icon i:first-child {
    top: 2px;
  }

  .nav-toggle-icon i:last-child {
    top: 9px;
  }

  .nav-open .nav-toggle-icon i:first-child {
    top: 6px;
    transform: rotate(45deg);
  }

  .nav-open .nav-toggle-icon i:last-child {
    top: 6px;
    transform: rotate(-45deg);
  }

  .site-header nav {
    position: absolute;
    top: 100%;
    right: 0;
    left: 0;
    order: initial;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    width: 100%;
    max-height: calc(100svh - var(--header-height));
    margin: 0;
    padding: 8px max(24px, env(safe-area-inset-right)) calc(24px + env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left));
    gap: 0;
    overflow-x: visible;
    overflow-y: auto;
    border-top: 1px solid rgba(184, 148, 80, 0.32);
    background: rgba(3, 17, 31, 0.985);
    box-shadow: 0 28px 46px rgba(0, 0, 0, 0.28);
  }

  .site-header.nav-enhanced:not(.nav-open) nav {
    display: none;
  }

  .site-header nav > a:not(.mobile-nav-action) {
    width: 100%;
    min-height: 52px;
    padding: 0 4px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.11);
    font-size: 13px;
  }

  .site-header nav > a[aria-current="page"] {
    border-bottom-color: rgba(184, 148, 80, 0.7);
  }

  .site-header nav .mobile-nav-action {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    min-height: 54px;
    margin-top: 18px;
    padding: 0 17px;
    border: 1px solid var(--gold);
    color: var(--gold-light);
    text-transform: uppercase;
    letter-spacing: 0.11em;
    font-size: 9px;
    font-weight: 700;
  }

  .home-hero {
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;
    min-height: calc(100svh - var(--header-height));
    padding-top: clamp(64px, 10vw, 90px);
    padding-bottom: 52px;
  }

  .hero-content h1,
  .page-hero h1 {
    font-size: clamp(48px, 9.6vw, 72px);
  }

  .hero-foot {
    position: relative;
    right: auto;
    bottom: auto;
    left: auto;
    width: 100%;
    margin-top: 62px;
  }

  .page-hero {
    min-height: 470px;
  }

  .executive-portrait {
    max-width: 540px;
  }

  .leadership-preview .executive-portrait,
  .leadership-detail .executive-portrait {
    justify-self: stretch;
  }

  .service-row,
  .industry-list a,
  .method-steps li {
    min-height: 64px;
  }

  .contact-form {
    width: 100%;
  }
}

@media (width <= 560px) {
  :root {
    --header-height: 76px;
  }

  .site-header {
    padding-right: max(20px, env(safe-area-inset-right));
    padding-left: max(20px, env(safe-area-inset-left));
  }

  .site-header nav {
    padding-right: max(20px, env(safe-area-inset-right));
    padding-left: max(20px, env(safe-area-inset-left));
  }

  .nav-toggle {
    min-width: 76px;
    padding: 0 10px;
  }

  .home-hero {
    min-height: calc(100svh - var(--header-height));
    padding: 58px 20px 48px;
  }

  .hero-content h1,
  .page-hero h1 {
    font-size: clamp(43px, 13vw, 57px);
    line-height: 1.01;
  }

  .hero-content > p:not(.eyebrow),
  .page-intro {
    font-size: 16px;
    line-height: 1.62;
  }

  .hero-foot {
    flex-wrap: wrap;
    white-space: normal;
    gap: 10px 20px;
    overflow: visible;
  }

  .content-section,
  .split-section,
  .outcomes,
  .industry-preview,
  .leadership-preview,
  .contact-band,
  .dark-section,
  .leadership-detail,
  .contact-page {
    padding: 66px 20px;
  }

  .page-hero {
    min-height: 430px;
    padding: 62px 20px 86px;
  }

  .page-index {
    left: 20px;
  }

  .split-section h2,
  .section-top h2,
  .method h2,
  .leadership-preview h2,
  .dark-section h2,
  .contact-band h2,
  .contact-details h2 {
    font-size: clamp(39px, 11.5vw, 49px);
  }

  .executive-portrait figcaption {
    flex-direction: column;
    align-items: flex-start;
    gap: 9px;
    padding: 24px;
  }

  .executive-portrait figcaption strong {
    font-size: 28px;
  }

  .industry-card,
  .service-detail {
    padding: 44px 0;
  }

  .service-row {
    padding: 24px 0;
  }

  .contact-form {
    padding: 30px 20px;
  }

  .footer-nav a,
  .footer-contact a {
    display: flex;
    align-items: center;
  }
}

@media (width <= 360px) {
  .site-header .wordmark {
    font-size: 13px;
    letter-spacing: 0.14em;
  }

  .nav-toggle-label {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
  }

  .nav-toggle {
    min-width: 48px;
    justify-content: center;
  }
}

@media (width <= 800px) and (height <= 520px) {
  .home-hero,
  .page-hero {
    min-height: auto;
  }

  .home-hero {
    padding-top: 52px;
  }
}

@media (hover: none) {
  .button.gold:hover {
    transform: none;
    box-shadow: none;
  }

  .service-row:hover,
  .industry-list a:hover {
    padding-left: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .skip-link,
  .nav-toggle-icon i {
    transition: none;
  }
}
