/* Mobile nav — full-screen takeover (design handoff option 2a, Aug 2026).
   Mobile only: replaces the Webflow hamburger + dropdown below 992px.
   Markup is injected by qcs-mobile-nav.js. */

@media screen and (max-width: 991px) {
  /* Webflow hamburger out, our text toggle in */
  .w-nav[data-collapse="medium"] .navbar6_menu-button {
    display: none;
  }

  /* Hamburger toggle, same geometry as the old Webflow icon (48px box, 24x2 lines) */
  .qcsm-toggle {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 48px;
    height: 48px;
    margin-right: -0.5rem;
    background: none;
    border: 0;
    padding: 0;
    cursor: pointer;
  }

  .qcsm-toggle i {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--base-color-neutral--black, #111);
    transition: transform 0.3s ease, opacity 0.2s ease;
  }

  .qcsm-toggle i + i {
    margin-top: 6px;
  }

  html.qcsm-open .qcsm-toggle i:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
  }

  html.qcsm-open .qcsm-toggle i:nth-child(2) {
    opacity: 0;
  }

  html.qcsm-open .qcsm-toggle i:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
  }

  html.qcsm-open,
  html.qcsm-open body {
    overflow: hidden;
  }

  /* Pin the header over the overlay (clears the announcement banner)
     and tint it to the overlay surface */
  html.qcsm-open .navbar6_component {
    background-color: #efede8;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
  }

  /* Logo PNG has a baked-in white background; multiply hides it on the tint */
  html.qcsm-open .navbar6_logo {
    mix-blend-mode: multiply;
  }

  .qcsm-overlay {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 998;
    background: #efede8;
    padding-top: var(--qcsm-header-h, 72px);
  }

  html.qcsm-open .qcsm-overlay {
    display: flex;
    flex-direction: column;
  }

  .qcsm-scroll {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    padding: 26px 22px 18px;
  }

  /* --- Nav links --- */
  .qcsm-nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
  }

  .qcsm-link,
  .qcsm-trigger {
    font-family: Suisse Intl, sans-serif;
    font-size: 34px;
    line-height: 1.16;
    font-weight: 500;
    letter-spacing: -0.02em;
    color: #111;
    text-decoration: none;
    /* pad to a >=44px tap target, negative margin keeps the visual 4px pitch */
    padding: 3px 0;
    margin: -3px 0;
  }

  .qcsm-link:hover,
  .qcsm-link:focus-visible {
    color: #ff5b14;
  }

  .qcsm-trigger {
    display: flex;
    align-items: baseline;
    gap: 12px;
    width: 100%;
    text-align: left;
    background: none;
    border: 0;
    cursor: pointer;
  }

  .qcsm-glyph {
    margin-left: auto;
    font-family: Suisse Intl, sans-serif;
    font-size: 22px;
    font-weight: 400;
    color: rgba(0, 0, 0, 0.4);
  }

  .qcsm-panel {
    display: flex;
    flex-direction: column;
    /* spec 6px 0 8px, widened to absorb the sub-links' tap-target margins */
    padding: 13px 0 15px;
  }

  .qcsm-panel[hidden] {
    display: none;
  }

  .qcsm-sub {
    font-family: Suisse Intl, sans-serif;
    font-size: 17px;
    line-height: 1.3;
    font-weight: 500;
    letter-spacing: -0.01em;
    color: rgba(17, 17, 17, 0.5);
    text-decoration: none;
    /* 44px tap target at the spec's 30px visual pitch */
    display: flex;
    align-items: center;
    min-height: 44px;
    margin: -7px 0;
  }

  .qcsm-sub:hover,
  .qcsm-sub:focus-visible {
    color: #111;
  }

  .qcsm-spacer {
    flex: 1;
    min-height: 18px;
  }

  /* --- Bottom block --- */
  .qcsm-bottom {
    display: flex;
    flex-direction: column;
    gap: 12px;
  }

  .qcsm-label {
    font-family: Suisse Intl, sans-serif;
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: rgba(0, 0, 0, 0.4);
    margin-bottom: 5px;
  }

  .qcsm-contact {
    font-family: Suisse Intl, sans-serif;
    font-size: 14px;
    line-height: 1.6;
    font-weight: 400;
    color: #111;
  }

  .qcsm-contact a {
    color: #111;
    text-decoration: none;
  }

  .qcsm-social {
    display: flex;
    gap: 10px;
    margin-top: 2px;
  }

  .qcsm-social a {
    width: 34px;
    height: 34px;
    background: #111;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
  }

  .qcsm-cta {
    background: #111;
    padding: 16px;
    margin-top: 6px;
  }

  .qcsm-cta-title {
    font-family: Suisse Intl, sans-serif;
    font-size: 10.5px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: #fff;
    margin-bottom: 4px;
  }

  .qcsm-cta-sub {
    font-family: Suisse Intl, sans-serif;
    font-size: 13px;
    line-height: 1.45;
    font-weight: 400;
    color: rgba(255, 255, 255, 0.65);
    margin-bottom: 12px;
  }

  .qcsm-cta-btn {
    display: inline-block;
    background: #fff;
    color: #111;
    font-family: Suisse Intl, sans-serif;
    font-size: 12px;
    font-weight: 400;
    padding: 14px 28px;
    text-decoration: none;
  }

  .qcsm-stats {
    display: flex;
    border: 1px solid rgba(0, 0, 0, 0.15);
  }

  .qcsm-stat {
    flex: 1;
    padding: 10px 18px;
  }

  .qcsm-rule {
    width: 1px;
    background: rgba(0, 0, 0, 0.15);
  }

  .qcsm-fig {
    font-family: Suisse Intl, sans-serif;
    font-size: 12px;
    line-height: 1;
    font-weight: 500;
    letter-spacing: -0.01em;
    color: #111;
  }

  .qcsm-cap {
    font-family: Suisse Intl, sans-serif;
    font-size: 7.5px;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(0, 0, 0, 0.45);
    margin-top: 4px;
  }

  /* --- Staggered entrance (restarts each open via display:none -> flex) --- */
  @keyframes qcsmIn {
    from { opacity: 0; transform: translateY(18px); }
    to { opacity: 1; transform: translateY(0); }
  }

  @keyframes qcsmFade {
    from { opacity: 0; }
    to { opacity: 1; }
  }

  html.qcsm-open .qcsm-nav > * {
    animation: qcsmIn 0.45s ease-out both;
  }
  html.qcsm-open .qcsm-nav > :nth-child(1) { animation-delay: 0.02s; }
  html.qcsm-open .qcsm-nav > :nth-child(2) { animation-delay: 0.05s; }
  html.qcsm-open .qcsm-nav > :nth-child(3) { animation-delay: 0.08s; }
  html.qcsm-open .qcsm-nav > :nth-child(4) { animation-delay: 0.14s; }
  html.qcsm-open .qcsm-nav > :nth-child(5) { animation-delay: 0.2s; }

  html.qcsm-open .qcsm-bottom {
    animation: qcsmFade 0.5s ease-out 0.4s both;
  }

  .qcsm-panel:not([hidden]) .qcsm-sub {
    animation: qcsmIn 0.35s ease-out both;
  }
  .qcsm-panel .qcsm-sub:nth-child(1) { animation-delay: 0.05s; }
  .qcsm-panel .qcsm-sub:nth-child(2) { animation-delay: 0.1s; }
  .qcsm-panel .qcsm-sub:nth-child(3) { animation-delay: 0.15s; }
  .qcsm-panel .qcsm-sub:nth-child(4) { animation-delay: 0.2s; }
  .qcsm-panel .qcsm-sub:nth-child(5) { animation-delay: 0.25s; }
  .qcsm-panel .qcsm-sub:nth-child(6) { animation-delay: 0.3s; }

  @media (prefers-reduced-motion: reduce) {
    html.qcsm-open .qcsm-nav > *,
    html.qcsm-open .qcsm-bottom,
    .qcsm-panel:not([hidden]) .qcsm-sub {
      animation: qcsmFade 0.2s ease-out both;
    }

    .qcsm-toggle i {
      transition: none;
    }
  }
}

@media screen and (min-width: 992px) {
  .qcsm-toggle,
  .qcsm-overlay {
    display: none !important;
  }
}
