html {
  -webkit-text-size-adjust: 100%;
  overflow-x: clip;
}

body {
  min-width: 0;
  overflow-x: clip;
}

body.nav-open {
  overflow: hidden;
}

main,
section,
.container,
.navigation-wrapper,
.primary-navigation,
.footer-grid,
.contact-layout,
.form-panel {
  min-width: 0;
}

img,
video,
iframe,
svg {
  max-width: 100%;
}

img {
  height: auto;
}

h1,
h2,
h3,
p,
a,
li,
dd {
  overflow-wrap: anywhere;
}

button,
input,
select,
textarea {
  max-width: 100%;
}

.navigation-wrapper {
  position: relative;
}

.mobile-menu-button {
  padding: 0;
  place-items: center;
  cursor: pointer;
}

.mobile-menu-button {
  position: relative;
}

.mobile-menu-button span {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 22px;
  height: 1.5px;
  margin: 0;
  background: var(--navy-900);
  transition: transform .22s ease, opacity .22s ease;
}

.mobile-menu-button span:nth-child(1) {
  transform: translate(-50%, -7px);
}

.mobile-menu-button span:nth-child(2) {
  transform: translate(-50%, 0);
}

.mobile-menu-button span:nth-child(3) {
  transform: translate(-50%, 7px);
}

.mobile-menu-button[aria-expanded="true"] span:nth-child(1) {
  transform: translate(-50%, 0) rotate(45deg);
}

.mobile-menu-button[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-button[aria-expanded="true"] span:nth-child(3) {
  transform: translate(-50%, 0) rotate(-45deg);
}

.button,
.primary-navigation a,
.nav-dropdown-toggle,
.form-tab,
.site-footer a {
  touch-action: manipulation;
}

@media (max-width: 1120px) {
  .navigation-wrapper {
    grid-template-columns: minmax(0, 1fr) auto;
    min-height: 88px;
    gap: 14px;
  }

  .site-header .brand-image img {
    height: 64px;
    width: auto;
  }

  .navigation-cta {
    display: none;
  }

  .mobile-menu-button {
    display: grid;
    width: 46px;
    height: 46px;
    background: rgba(255, 255, 255, .72);
    border: 1px solid var(--line-strong);
    border-radius: 12px;
  }

  .primary-navigation {
    position: absolute;
    top: calc(100% + 1px);
    left: 0;
    right: 0;
    z-index: 100;
    display: none;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    max-height: calc(100dvh - 104px);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 14px;
    text-align: left;
    background: var(--white);
    border: 1px solid var(--line);
    border-top: 0;
    border-radius: 0 0 18px 18px;
    box-shadow: var(--shadow-lg);
  }

  .primary-navigation.active {
    display: flex;
  }

  .primary-navigation > a,
  .nav-dropdown-toggle {
    display: flex;
    align-items: center;
    width: 100%;
    min-height: 48px;
    padding: 12px 14px;
    border-radius: 10px;
  }

  .primary-navigation > a:hover,
  .primary-navigation > a:focus-visible,
  .nav-dropdown-toggle:hover,
  .nav-dropdown-toggle:focus-visible {
    background: var(--navy-light);
  }

  .primary-navigation > a::after,
  .nav-dropdown-toggle::after {
    display: none;
  }

  .nav-item-dropdown {
    display: block;
    width: 100%;
  }

  .nav-dropdown-toggle {
    justify-content: space-between;
  }

  .nav-dropdown-menu {
    position: static;
    width: 100%;
    margin: 4px 0 8px;
    padding: 9px;
    display: none;
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
    transform: none;
    background: var(--cream);
    border-radius: 12px;
    box-shadow: none;
  }

  .nav-dropdown-menu::before {
    display: none;
  }

  .nav-item-dropdown:hover .nav-dropdown-menu,
  .nav-item-dropdown:focus-within .nav-dropdown-menu {
    display: none;
    transform: none;
  }

  .nav-item-dropdown.open .nav-dropdown-menu {
    display: block;
    transform: none;
  }

  .nav-dropdown-links {
    grid-template-columns: 1fr;
  }

  .nav-dropdown-links a:last-child:nth-child(odd) {
    grid-column: auto;
  }
}

@media (max-width: 900px) {
  .section {
    padding: 76px 0;
  }

  .page-hero {
    padding: 82px 0 68px;
  }

  .page-hero h1,
  .services-page-hero h1,
  .service-detail-hero h1 {
    font-size: clamp(2.45rem, 7vw, 3.8rem);
  }

  .hero-section-image {
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: var(--cream);
  }

  .hero-section-image .hero-layout {
    order: 1;
    min-height: 0;
  }

  .hero-section-image .hero-content {
    width: 100%;
    max-width: 680px;
    padding: 58px 0 46px;
  }

  .hero-section-image .hero-heading,
  .hero-section-image .hero-description {
    max-width: 100%;
  }

  .hero-section-image .hero-media {
    position: relative;
    inset: auto;
    order: 2;
    width: 100%;
    aspect-ratio: 16 / 9;
  }

  .hero-section-image .hero-media img {
    object-fit: cover;
    object-position: center;
  }

  .hero-section-image .hero-media-overlay {
    background: linear-gradient(180deg, rgba(245, 242, 237, .12), rgba(10, 22, 40, .05));
  }

  .feature-panel,
  .callout,
  .services-context-card,
  .service-audience-card,
  .service-regulatory-box,
  .service-note-box {
    border-radius: 22px;
  }

  .contact-details {
    position: static;
  }
}

@media (max-width: 768px) {
  .container {
    width: min(calc(100% - 28px), var(--container));
  }

  .section {
    padding: 64px 0;
  }

  .page-hero,
  .services-page-hero,
  .service-detail-hero {
    padding: 68px 0 58px;
  }

  .page-hero h1,
  .services-page-hero h1,
  .service-detail-hero h1 {
    font-size: clamp(2.2rem, 10vw, 3.2rem);
    line-height: 1.04;
  }

  .page-hero p:last-child,
  .services-page-hero .container > div > p:not(.eyebrow-label),
  .service-detail-hero-copy > p:not(.eyebrow-label) {
    font-size: 1rem;
    line-height: 1.7;
  }

  .feature-panel,
  .callout,
  .contact-shell {
    padding: 30px 24px;
  }

  .callout {
    align-items: stretch;
  }

  .callout .button,
  .service-cta-section .button {
    width: 100%;
  }

  .hero-actions,
  .service-hero-actions {
    align-items: stretch;
    flex-direction: column;
    gap: 16px;
  }

  .hero-actions .button,
  .service-hero-actions .button {
    width: 100%;
  }

  .hero-actions .text-link,
  .service-hero-actions .text-link {
    width: fit-content;
  }

  .service-card,
  .service-directory-card,
  .about-value-card,
  .business-pressure-grid article,
  .service-offering-card,
  .info-card,
  .industry-grid article,
  .partner-grid article {
    padding: 26px 22px;
  }

  .service-directory-card h2 {
    font-size: 1.65rem;
  }

  .service-directory-link {
    width: fit-content;
    max-width: 100%;
  }

  .service-detail-intro,
  .strategic-intro {
    position: static;
  }

  .service-challenge-card,
  .strategic-principles li {
    grid-template-columns: 40px minmax(0, 1fr);
    gap: 14px;
    padding: 20px 18px;
  }

  .service-challenge-card > span,
  .strategic-principles li::before {
    width: 38px;
    height: 38px;
  }

  .service-deliverables-section li {
    padding: 16px 16px 16px 40px;
  }

  .tax-services-heading {
    max-width: 100%;
    margin-bottom: 32px;
    text-align: left;
  }

  .tax-service-card {
    min-height: 0;
    padding: 30px 24px;
  }

  .footer-grid {
    gap: 34px;
  }

  .footer-bottom {
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(calc(100% - 24px), var(--container));
  }

  .site-header .brand-image img {
    height: 52px;
  }

  .navigation-wrapper {
    min-height: 76px;
  }

  .primary-navigation {
    max-height: calc(100dvh - 88px);
    padding: 10px;
  }

  .section {
    padding: 56px 0;
  }

  .page-hero,
  .services-page-hero,
  .service-detail-hero {
    padding: 58px 0 50px;
  }

  .page-hero h1,
  .services-page-hero h1,
  .service-detail-hero h1 {
    font-size: clamp(2.05rem, 11vw, 2.85rem);
  }

  .feature-panel h2,
  .section-intro h2,
  .callout h2,
  .contact-copy h2,
  .content-grid h2,
  .service-detail-list h2,
  .strategic-intro h2,
  .service-detail-intro h2,
  .service-regulatory-box h2,
  .service-note-box h2,
  .service-deliverables-section h2 {
    font-size: clamp(1.85rem, 8vw, 2.45rem);
  }

  .hero-section-image .hero-content {
    padding: 46px 0 36px;
  }

  .hero-section-image .hero-heading {
    font-size: clamp(2rem, 10vw, 2.65rem);
  }

  .hero-section-image .hero-media {
    aspect-ratio: 4 / 3;
  }

  .feature-panel,
  .callout,
  .contact-shell,
  .services-context-card,
  .service-audience-card,
  .service-regulatory-box,
  .service-note-box {
    padding: 26px 20px;
  }

  .service-directory-card,
  .about-value-card,
  .service-offering-card,
  .info-card,
  .industry-grid article,
  .partner-grid article,
  .business-pressure-grid article {
    padding: 24px 20px;
  }

  .service-audience-card li {
    padding: 13px 12px 13px 34px;
  }

  .related-service-links a {
    padding: 18px;
  }

  .site-footer {
    padding: 58px 0 24px;
  }

  .footer-logo-link {
    width: min(100%, 270px);
    max-width: 270px;
  }

  .footer-brand p {
    font-size: .94rem;
  }

  .footer-bottom {
    margin-top: 38px;
    padding-top: 20px;
  }

  .contact-hero {
    padding: 58px 0 48px;
  }

  .contact-section {
    padding: 48px 0 64px;
  }

  .contact-detail-list {
    margin: 30px 0;
    padding: 24px 0;
  }

  .form-panel {
    border-radius: 16px;
  }

  .form-tab-panel {
    padding: 26px 20px;
  }

  .form-heading {
    margin-bottom: 26px;
  }

  .form-heading h2 {
    font-size: clamp(1.85rem, 9vw, 2.45rem);
  }

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

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

@media (max-width: 480px) {
  .container {
    width: min(calc(100% - 20px), var(--container));
  }

  .site-header .brand-image img {
    height: 47px;
  }

  .navigation-wrapper {
    min-height: 72px;
  }

  .mobile-menu-button {
    width: 44px;
    height: 44px;
  }

  .primary-navigation {
    top: 100%;
    max-height: calc(100dvh - 80px);
    border-radius: 0 0 16px 16px;
  }

  .primary-navigation > a,
  .nav-dropdown-toggle {
    min-height: 46px;
    padding: 11px 12px;
  }

  .nav-dropdown-links span {
    display: none;
  }

  .nav-dropdown-overview strong,
  .nav-dropdown-links strong {
    font-size: .82rem;
  }

  .page-hero,
  .services-page-hero,
  .service-detail-hero {
    padding: 50px 0 44px;
  }

  .page-hero h1,
  .services-page-hero h1,
  .service-detail-hero h1 {
    font-size: clamp(1.95rem, 11.5vw, 2.55rem);
  }

  .hero-section-image .hero-content {
    padding: 40px 0 32px;
  }

  .hero-section-image .hero-heading {
    font-size: clamp(1.9rem, 10.5vw, 2.4rem);
  }

  .button {
    min-height: 50px;
    padding: 0 20px;
  }

  .service-card,
  .tax-service-card {
    padding: 24px 20px;
  }

  .tax-service-icon {
    width: 60px;
    height: 60px;
    margin-bottom: 16px;
  }

  .tax-service-icon svg {
    width: 50px;
    height: 50px;
  }

  .form-tabs {
    grid-template-columns: 1fr;
  }

  .form-tab {
    min-height: 54px;
    padding: 13px 14px;
    text-align: left;
  }

  .form-tab + .form-tab {
    border-left: 0;
    border-top: 1px solid rgba(15, 37, 64, .12);
  }

  .footer-logo-link {
    width: min(100%, 245px);
    max-width: 245px;
  }
}

@media (max-width: 360px) {
  .site-header .brand-image img {
    height: 43px;
  }

  .navigation-wrapper {
    min-height: 68px;
    gap: 8px;
  }

  .mobile-menu-button {
    width: 42px;
    height: 42px;
  }

  .page-hero h1,
  .services-page-hero h1,
  .service-detail-hero h1,
  .hero-section-image .hero-heading {
    font-size: 1.9rem;
  }

  .eyebrow,
  .eyebrow-label {
    letter-spacing: .1em;
  }
}

@media (max-height: 560px) and (max-width: 1120px) {
  .primary-navigation {
    max-height: calc(100dvh - 78px);
  }
}

@media (hover: none) {
  .service-card:hover,
  .tax-service-card:hover,
  .strategic-principles li:hover,
  .button-dark:hover,
  .button-light:hover {
    transform: none;
  }
}
