@media (max-width: 900px) {
  .projects-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .trust-strip {
    grid-template-columns: repeat(3, 1fr);
  }

  .trust-item:nth-child(3) {
    border-right: 0;
  }

  .trust-item:nth-child(n+4) {
    border-top: 1px solid var(--border-soft);
  }

  .split-grid,
  .contact-grid,
  .contact-premium-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .kpi-grid .metric:nth-child(2n) {
    border-right: 0;
  }

  .kpi-grid .metric:nth-child(n+3) {
    border-top: 1px solid var(--border-soft);
  }

  .site-footer::after {
    width: 300px;
  }
}

@media (max-width: 900px) {
  :root {
    --section-x: clamp(1.25rem, 4vw, 2.5rem);
  }

  .sidebar {
    display: none;
  }

  .main {
    margin-left: 0;
    width: 100%;
  }

  main.main {
    padding-top: 68px;
  }

  [id] {
    scroll-margin-top: 84px;
  }

  .mobile-header {
    position: fixed;
    inset: 0 0 auto;
    z-index: 120;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 68px;
    padding: 0 1.25rem;
    background: rgba(255,255,255,.92);
    border-bottom: 1px solid var(--border-soft);
    backdrop-filter: blur(16px);
  }

  .mobile-toggle {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    color: var(--navy);
    background: #fff;
    border: 1px solid var(--border-soft);
    border-radius: 6px;
  }

  .mobile-menu {
    position: fixed;
    inset: 68px 0 auto;
    z-index: 110;
    display: block;
    padding: 1rem 1.25rem 1.25rem;
    background: rgba(255,255,255,.98);
    border-bottom: 1px solid var(--border-soft);
    box-shadow: var(--shadow-soft);
    transform: translateY(-120%);
    transition: transform .3s var(--ease-out);
  }

  .mobile-menu.is-open {
    transform: translateY(0);
  }

  .mobile-menu ul {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: .5rem;
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .mobile-menu a {
    display: block;
    padding: .8rem;
    background: var(--bg-soft);
    border: 1px solid var(--border-soft);
    border-radius: 6px;
    font-weight: 700;
  }

  .hero,
  .hero .section-inner {
    min-height: auto;
  }

  .hero .section-inner {
    grid-template-columns: 1fr;
    padding-top: 0;
    padding-right: var(--content-edge-gap);
    padding-bottom: 0;
    padding-left: var(--content-edge-gap);
  }

  .hero-brand,
  .hero-brand-text {
    left: var(--content-edge-gap);
  }

  .hero-brand-text {
    top: 1.25rem;
  }

  .hero-copy {
    max-width: 100%;
    padding-top: 4rem;
    padding-bottom: 2.5rem;
  }

  .hero-visual {
    min-height: 360px;
    margin-right: calc(var(--content-edge-gap) * -1);
    margin-left: calc(var(--content-edge-gap) * -1);
  }

  .hero-visual img {
    clip-path: none;
  }

  .cookie-banner {
    left: clamp(.75rem, 3vw, 1.25rem);
  }

  .trust {
    margin-top: -1.5rem;
  }

  .service-cards {
    grid-template-columns: repeat(2, 1fr);
  }

  .service-card,
  .service-card:first-child,
  .service-card:last-child {
    border: 1px solid var(--border-soft);
    border-radius: 7px;
  }

  .about-card,
  .careers-card,
  .approach-layout,
  .legal-page .subpage-hero .section-inner,
  .legal-layout,
  .subpage-hero .section-inner,
  .project-detail-hero .section-inner,
  .detail-grid,
  .specialties-involved {
    grid-template-columns: 1fr;
  }

  .areas-strip {
    grid-template-columns: repeat(4, 1fr);
  }

  .area-item:nth-child(4n) {
    border-right: 0;
  }

  .area-item:nth-child(n+5) {
    border-top: 1px solid var(--border-soft);
  }

  .about-card::after {
    width: 70%;
  }

  .metrics-grid {
    border-left: 0;
    border-top: 1px solid var(--border-soft);
  }

  .project-info {
    position: static;
  }

  .specialty-tabs-shell {
    margin-right: calc(var(--content-edge-gap) * -1);
    margin-left: calc(var(--content-edge-gap) * -1);
    padding-right: var(--content-edge-gap);
    padding-left: var(--content-edge-gap);
    overflow: hidden;
  }

  .specialty-tabs-shell::after {
    position: absolute;
    top: 0;
    right: 0;
    bottom: .75rem;
    z-index: 2;
    width: 4rem;
    background: linear-gradient(90deg, rgba(247,248,248,0), var(--bg-page) 58%);
    content: "";
    pointer-events: none;
  }

  .specialty-list {
    grid-template-columns: repeat(9, minmax(128px, 1fr));
    overflow-x: auto;
    padding-right: 3.4rem;
    padding-bottom: .75rem;
    scroll-padding-inline: var(--content-edge-gap);
    scrollbar-width: thin;
    -webkit-overflow-scrolling: touch;
  }

  .specialty-scroll-indicator {
    position: absolute;
    top: 50%;
    right: .65rem;
    z-index: 3;
    display: grid;
    width: 34px;
    height: 34px;
    padding: 0;
    place-items: center;
    color: var(--navy);
    background: rgba(255,255,255,.94);
    border: 1px solid var(--border-soft);
    border-radius: 999px;
    box-shadow: 0 10px 26px rgba(3,23,56,.12);
    font-weight: 900;
    cursor: pointer;
    transform: translateY(-50%);
    transition: background .2s var(--ease-out), transform .2s var(--ease-out), box-shadow .2s var(--ease-out);
  }

  .specialty-scroll-indicator:hover,
  .specialty-scroll-indicator:focus-visible {
    background: #fff;
    box-shadow: 0 14px 32px rgba(3,23,56,.16);
    transform: translateY(-50%) translateX(2px);
  }

  .specialty-scroll-indicator.is-at-end {
    transform: translateY(-50%) rotate(180deg);
  }

  .specialty-card {
    grid-template-columns: 1fr;
  }

  .specialty-visual {
    min-height: 280px;
  }

  .specialty-visual img {
    height: 300px;
  }
}

@media (max-width: 768px) {
  .main {
    margin-left: 0;
    width: 100%;
  }

  body {
    font-size: 15px;
  }

  .section-header {
    display: grid;
    align-items: start;
  }

  .hero h1 {
    margin-top: 0;
    font-size: clamp(2.55rem, 11.2vw, 3.55rem);
    line-height: 1.02;
    overflow-wrap: anywhere;
  }

  .hero .eyebrow {
    position: relative;
    z-index: 4;
    display: block;
    margin-bottom: clamp(1.05rem, 4.5vw, 1.65rem);
    line-height: 1.35;
  }

  .hero-title-line,
  .hero-heading-line {
    white-space: normal;
  }

  .final-cta .section-inner,
  .footer-bottom {
    align-items: stretch;
    flex-direction: column;
  }

  .hero-actions {
    width: min(100%, 390px);
    margin-right: auto;
    margin-left: auto;
    align-items: stretch;
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  .cookie-form,
  .cookie-options {
    align-items: stretch;
    flex-direction: column;
  }

  .cookie-form .btn {
    margin-left: 0;
  }

  .trust-strip,
  .projects-grid,
  .service-cards,
  .specialty-points,
  .contact-grid,
  .card-grid,
  .areas-list {
    grid-template-columns: 1fr;
  }

  .trust-item,
  .trust-item:nth-child(3),
  .trust-item:nth-child(n+4) {
    border-right: 0;
    border-top: 1px solid var(--border-soft);
  }

  .trust-item:first-child {
    border-top: 0;
  }

  .project-card {
    min-height: auto;
  }

  .project-media {
    aspect-ratio: 1.55 / 1;
  }

  .specialties-intro {
    margin-bottom: 1.35rem;
  }

  .specialties-title {
    font-size: clamp(2rem, 11vw, 2.85rem);
  }

  .specialty-card {
    min-height: auto;
    padding: 1.15rem;
  }

  .specialty-card h3 {
    font-size: clamp(1.55rem, 7vw, 2rem);
    line-height: 1.08;
  }

  .specialty-points li {
    min-height: 48px;
  }

  .specialty-visual {
    min-height: 220px;
  }

  .specialty-visual img {
    height: 240px;
    min-height: 220px;
  }

  .areas-strip {
    grid-template-columns: repeat(2, 1fr);
  }

  .area-item,
  .area-item:nth-child(4n),
  .area-item:nth-child(n+5) {
    border-right: 1px solid var(--border-soft);
    border-top: 1px solid var(--border-soft);
  }

  .area-item:nth-child(odd) {
    border-left: 0;
  }

  .area-item:nth-child(even) {
    border-right: 0;
  }

  .area-item:nth-child(-n+2) {
    border-top: 0;
  }

  .timeline {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding-top: 0;
  }

  .timeline::before {
    top: 1.25rem;
    bottom: 1.25rem;
    left: 21px;
    width: 2px;
    height: auto;
  }

  .timeline-step {
    display: grid;
    grid-template-columns: 42px 1fr;
    gap: 1rem;
    text-align: left;
  }

  .timeline-number {
    margin: 0;
  }

  .careers-image {
    min-height: 220px;
  }

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

  .mobile-menu ul {
    grid-template-columns: 1fr;
  }

  .project-detail-hero .section-inner {
    gap: 1rem;
    padding-top: 1rem;
  }

  .gallery-main {
    aspect-ratio: 1.25 / 1;
  }

  .gallery-controls {
    right: .75rem;
    bottom: .75rem;
  }

  .gallery-control {
    width: 40px;
    height: 40px;
  }

  .thumbnails {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: .45rem;
  }
}

@media (max-width: 480px) {
  .kpi-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .section-inner {
    width: min(100% - 2rem, var(--page-max));
    padding-right: 0;
    padding-left: 0;
  }

  .logo-wordmark {
    font-size: .82rem;
  }

  .hero-visual {
    min-height: 280px;
  }

  .hero h1 {
    font-size: clamp(2.35rem, 10.5vw, 3.05rem);
  }

  .hero-actions {
    width: min(100%, 372px);
  }

  .hero-subtitle {
    max-width: 36ch;
    margin-top: 1.45rem;
    font-size: .95rem;
  }

  .specialty-tabs-shell {
    margin-right: -1rem;
    margin-left: -1rem;
    padding-right: 1rem;
    padding-left: 1rem;
  }

  .specialty-list {
    grid-template-columns: repeat(9, minmax(126px, 1fr));
  }

  .specialties-title {
    font-size: clamp(2rem, 10vw, 2.55rem);
  }

  .technical-note {
    display: none;
  }

  .panel-head,
  .about-copy,
  .careers-copy,
  .contact-info,
  .form-card,
  .project-info {
    padding: 1rem;
  }

  .areas-strip {
    grid-template-columns: 1fr;
  }

  .area-item,
  .area-item:nth-child(even),
  .area-item:nth-child(-n+2) {
    border-right: 0;
    border-top: 1px solid var(--border-soft);
  }

  .area-item:first-child {
    border-top: 0;
  }
}
