/* Mobile menu: a restrained, pointer-only response that keeps touch behavior intact. */
@media (max-width: 850px) {
  .menu-toggle {
    border-radius: 50%;
    transition: background-color .3s ease, color .3s ease, transform .3s ease;
  }

  .menu-toggle > span:not(.sr-only) {
    transition: transform .35s cubic-bezier(.22, 1, .36, 1), width .35s ease, background-color .3s ease;
  }
}

@media (max-width: 850px) and (hover: hover) and (pointer: fine) {
  .menu-toggle:hover {
    background-color: rgba(181, 103, 66, .2);
    color: #d78b65;
    transform: rotate(8deg);
  }

  .menu-toggle:hover > span:first-child {
    transform: translateX(5px);
  }

  .menu-toggle:hover > span:nth-child(2) {
    transform: translateX(-5px);
  }
}

@media (prefers-reduced-motion: reduce) {
  .menu-toggle,
  .menu-toggle > span:not(.sr-only) {
    transition: none;
  }
}

/* Keep the header clear of the WordPress toolbar while signed in. */
body.admin-bar .site-header,
body.admin-bar .site-header.is-scrolled {
  top: 32px;
}

/* The imported landing page is still a draft and may be previewed outside
   WordPress's static-front-page template. Keep that preview legible. */
body:has(#page-content .hero) .site-header {
  background: #172026;
}

#page-content > article:has(.hero) > h1 {
  display: none;
}

/* WordPress wpautop inserts an empty paragraph after the number and wraps
   the arrow link in another paragraph. Pin the intended three grid items. */
.service-item > p:empty {
  display: none;
}

.service-item > .service-no {
  grid-column: 1;
  grid-row: 1;
}

.service-item > div {
  grid-column: 2;
  grid-row: 1;
  min-width: 0;
}

.service-item > p:last-child {
  grid-column: 3;
  grid-row: 1;
  margin: 0;
}

@media (max-width: 782px) {
  body.admin-bar .site-header,
  body.admin-bar .site-header.is-scrolled {
    top: 46px;
  }
}

@media (max-width: 600px) {
  body.admin-bar .site-header.is-scrolled {
    top: 0;
  }
}
