/* Code Remediation workflow: matches the WCAG Audits mobile sequence. */
@media screen and (max-width: 767px) {
  /* Workflow — the same pinned mobile card sequence used on the Home page. */
  html body.code-remediation-page .section.v3-process-section {
    height: auto !important;
    min-height: 0 !important;
    padding-top: 2.75rem !important;
    padding-bottom: 2.2rem !important;
    overflow: visible !important;
  }

  html body.code-remediation-page .v3-process-main-div {
    position: static !important;
    top: auto !important;
    width: 100% !important;
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    transform: none !important;
  }

  html body.code-remediation-page .v3-process-section .common-heading-div.margin-bottom {
    width: 100% !important;
    max-width: 34rem !important;
    margin: 0 0 1.4rem !important;
    text-align: left !important;
  }

  html body.code-remediation-page .v3-process-section .large-paragraph.black-500-text {
    margin: 0 0 0.55rem !important;
    color: #006039 !important;
    font-size: 0.75rem !important;
    font-weight: 700 !important;
    line-height: 1.35 !important;
    letter-spacing: 0.1em !important;
    text-transform: uppercase !important;
  }

  html body.code-remediation-page .v3-process-heading-div h2 {
    margin: 0 !important;
    font-size: clamp(1.78rem, 8vw, 2.05rem) !important;
    line-height: 1.08 !important;
    text-align: left !important;
  }

  html body.code-remediation-page .v3-process-paragraph {
    width: 100% !important;
    max-width: 32rem !important;
    margin: 0.75rem 0 0 !important;
    font-size: 0.92rem !important;
    line-height: 1.56 !important;
    text-align: left !important;
  }

  html body.code-remediation-page .v3-process-wrapper {
    width: 100% !important;
    max-width: none !important;
    margin: 0 !important;
    padding: 0 !important;
    transform: none !important;
  }

  html body.code-remediation-page .tdl-wcag-process-track .v3-process-grid {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: clamp(8.5rem, 23svh, 12rem) minmax(0, 1fr) !important;
    grid-auto-flow: unset !important;
    flex: 0 0 auto !important;
    gap: 0 !important;
    width: min(86vw, 22rem) !important;
    min-width: 0 !important;
    max-width: none !important;
    height: min(calc(100svh - 10rem), 36rem) !important;
    min-height: 0 !important;
    max-height: 36rem !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    border: 1px solid rgba(37, 34, 42, 0.11) !important;
    border-radius: 1.5rem !important;
    background: linear-gradient(180deg, #f8fcfa 0%, #fff 62%) !important;
    box-shadow: 0 18px 44px -24px rgba(25, 25, 34, 0.3) !important;
    opacity: 0.42 !important;
    filter: saturate(0.82);
    transform: scale(0.94) !important;
    transition:
      opacity 0.45s ease,
      transform 0.45s cubic-bezier(0.22, 1, 0.36, 1),
      box-shadow 0.45s ease,
      filter 0.45s ease !important;
    box-sizing: border-box !important;
  }

  html body.code-remediation-page .tdl-wcag-process-track .v3-process-grid.is-active {
    box-shadow: 0 28px 64px -28px rgba(0, 96, 57, 0.38) !important;
    opacity: 1 !important;
    filter: saturate(1);
    transform: scale(1) !important;
  }

  html body.code-remediation-page .tdl-wcag-process-track .v3-process-grid > .v3-process-div {
    width: auto !important;
    min-width: 0 !important;
    height: auto !important;
    min-height: 0 !important;
    margin: 0 !important;
  }

  html body.code-remediation-page .tdl-wcag-process-track .v3-process-grid > .v3-process-div:nth-child(1),
  html body.code-remediation-page .tdl-wcag-process-track .v3-process-grid > .v3-process-div:nth-child(3) {
    grid-column: 1 !important;
  }

  html body.code-remediation-page .tdl-wcag-process-track .v3-process-grid > .v3-process-div:nth-child(3n + 1) {
    grid-row: 1 !important;
    align-self: stretch !important;
    height: 100% !important;
  }

  html body.code-remediation-page .tdl-wcag-process-track .v3-process-grid > .v3-process-div:nth-child(3n + 2) {
    display: none !important;
  }

  html body.code-remediation-page .tdl-wcag-process-track .v3-process-grid > .v3-process-div:nth-child(3n) {
    grid-row: 2 !important;
    min-height: 0 !important;
  }

  html body.code-remediation-page .v3-process-image-div {
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
    overflow: hidden !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: #073326 !important;
    box-sizing: border-box !important;
  }

  html body.code-remediation-page .v3-process-image {
    display: block !important;
    width: 100% !important;
    height: 100% !important;
    min-height: 0 !important;
    object-fit: cover !important;
    object-position: center !important;
  }

  html body.code-remediation-page .v3-process-detail-wrapper,
  html body.code-remediation-page .v3-process-detail-wrapper.bottom {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0.8rem !important;
    width: 100% !important;
    min-height: 0 !important;
    padding: 1rem !important;
    overflow: hidden !important;
    border: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    box-sizing: border-box !important;
  }

  html body.code-remediation-page .v3-process-detail-div > .paragraph:first-child {
    margin: 0 0 0.28rem !important;
    color: #006039 !important;
    font-size: 0.68rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.1em !important;
  }

  html body.code-remediation-page .v3-process-detail-div .h6-heading {
    margin: 0 !important;
    color: #19191d !important;
    font-size: 1.08rem !important;
    line-height: 1.2 !important;
  }

  html body.code-remediation-page .v3-process-text {
    margin: 0.42rem 0 0 !important;
    color: #5f665f !important;
    font-size: 0.8rem !important;
    line-height: 1.5 !important;
  }

  html body.code-remediation-page .v3-process-list-wrapper {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 0.45rem 0.7rem !important;
    margin: 0 !important;
  }

  html body.code-remediation-page .v3-process-list-div {
    align-items: flex-start !important;
    gap: 0.35rem !important;
    min-width: 0 !important;
  }

  html body.code-remediation-page .v3-process-list-div > .paragraph {
    min-width: 0 !important;
    font-size: 0.75rem !important;
    line-height: 1.4 !important;
    overflow-wrap: anywhere !important;
  }

  html body.code-remediation-page .v3-process-list-icon {
    flex: 0 0 auto !important;
    width: 0.9rem !important;
    height: 0.9rem !important;
    margin-top: 0.05rem !important;
    color: #006039 !important;
  }

  html body.code-remediation-page .tdl-wcag-process-progress {
    position: absolute;
    z-index: 3;
    bottom: 1rem;
    left: 50%;
    display: none;
    align-items: center;
    gap: 0.45rem;
    padding: 0.5rem 0.7rem;
    border: 1px solid rgba(25, 25, 29, 0.09);
    border-radius: 9999px;
    background: rgba(255, 255, 255, 0.88);
    box-shadow: 0 10px 30px rgba(25, 25, 34, 0.08);
    transform: translateX(-50%);
    backdrop-filter: blur(10px);
  }

  html body.code-remediation-page .tdl-wcag-process-progress span {
    width: 6px;
    height: 6px;
    border-radius: 9999px;
    background: rgba(25, 25, 34, 0.18);
    transition: width 0.4s cubic-bezier(0.22, 1, 0.36, 1), background 0.4s ease;
  }

  html body.code-remediation-page .tdl-wcag-process-progress span.is-active {
    width: 24px;
    background: linear-gradient(90deg, #006039, #16865a);
  }

}

/* Match the Home page's mobile pinned-card geometry and timing surface. */
@media screen and (max-width: 767px) and (min-height: 600px) {
  html body.code-remediation-page .v3-process-section.is-mobile-scroll-lock-active {
    --tdl-wcag-process-card-gap: 1rem;
  }

  html body.code-remediation-page .v3-process-section.is-mobile-scroll-lock-active .v3-process-wrapper {
    position: relative !important;
    display: block !important;
    width: 100% !important;
    height: 380svh !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: visible !important;
    background: transparent !important;
    transform: none !important;
  }

  html body.code-remediation-page .v3-process-section.is-mobile-scroll-lock-active .tdl-wcag-process-stage {
    position: sticky !important;
    top: 4.25rem !important;
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    width: 100% !important;
    height: calc(100svh - 4.25rem) !important;
    overflow: hidden !important;
  }

  html body.code-remediation-page .v3-process-section.is-mobile-scroll-lock-active .tdl-wcag-process-stage::before,
  html body.code-remediation-page .v3-process-section.is-mobile-scroll-lock-active .tdl-wcag-process-stage::after {
    /* White edge fades formed visible rails against the gray section. */
    content: none;
  }

  html body.code-remediation-page .v3-process-section.is-mobile-scroll-lock-active .tdl-wcag-process-track {
    display: flex !important;
    flex-wrap: nowrap !important;
    align-items: center !important;
    gap: var(--tdl-wcag-process-card-gap) !important;
    width: max-content !important;
    padding-right: var(--tdl-wcag-process-edge-space, 0.5rem) !important;
    padding-left: var(--tdl-wcag-process-edge-space, 0.5rem) !important;
    transform: translate3d(var(--tdl-wcag-process-x, 0px), 0, 0) !important;
    will-change: transform;
  }

  html body.code-remediation-page .v3-process-section.is-mobile-scroll-lock-active .tdl-wcag-process-progress {
    display: flex;
  }
}

/* Home-page accessibility fallback: keep every workflow card in document flow
   when motion is reduced, paused, enlarged, or the viewport is too short. */
@media screen and (max-width: 767px) {
  html body.code-remediation-page .v3-process-section.is-mobile-process-expanded .v3-process-wrapper {
    position: static !important;
    display: block !important;
    width: 100% !important;
    height: auto !important;
    overflow: visible !important;
    transform: none !important;
  }

  html body.code-remediation-page .v3-process-section.is-mobile-process-expanded .tdl-wcag-process-stage {
    position: static !important;
    display: block !important;
    width: 100% !important;
    height: auto !important;
    overflow: visible !important;
  }

  html body.code-remediation-page .v3-process-section.is-mobile-process-expanded .tdl-wcag-process-stage::before,
  html body.code-remediation-page .v3-process-section.is-mobile-process-expanded .tdl-wcag-process-stage::after,
  html body.code-remediation-page .v3-process-section.is-mobile-process-expanded .tdl-wcag-process-progress {
    display: none !important;
  }

  html body.code-remediation-page .v3-process-section.is-mobile-process-expanded .tdl-wcag-process-track {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 0.75rem !important;
    width: auto !important;
    padding: 0 !important;
    transform: none !important;
    will-change: auto !important;
  }

  html body.code-remediation-page .v3-process-section.is-mobile-process-expanded .tdl-wcag-process-track .v3-process-grid {
    grid-template-rows: 9rem auto !important;
    width: 100% !important;
    height: auto !important;
    max-height: none !important;
    opacity: 1 !important;
    filter: none !important;
    transform: none !important;
    transition: none !important;
  }
}


@media screen and (max-width: 767px) {
  html body.code-remediation-page .v3-process-main-div > .container {
    width: 100% !important;
    max-width: 100% !important;
    padding-inline: 20px !important;
    box-sizing: border-box !important;
  }
}

@media screen and (max-width: 359px) {
  html body.code-remediation-page .v3-process-main-div > .container {
    padding-inline: 16px !important;
  }
}
