/* ==========================================================================
   ERDI UI polish r10 -- 2026-10-18
   Scope: touch/press feedback, tap hygiene, mobile touch targets.
   Purely additive: new pseudo-states + mobile hit-area sizing only.
   Loads last (dep: erdi-design26-inner) so :active states win the cascade.
   ========================================================================== */

/* --- A. Tap hygiene ------------------------------------------------------ */
html {
  -webkit-tap-highlight-color: transparent;
}
a,
button,
[role="button"],
summary,
label,
input[type="checkbox"],
input[type="radio"],
input[type="submit"] {
  touch-action: manipulation;
}

/* Keep pressed links from flashing the UA :active default (-webkit-activelink
   red). Zero specificity: any authored link color still wins during press. */
:where(a):active {
  color: inherit;
}

/* --- B. Buttons: press-in feedback --------------------------------------- */
.rd26-button:active,
.ox-button:active,
.xr-button:active,
.sp-button:active,
.op-button:active,
.erdi-btn:active,
.erdi-model__primary:active,
.erdi-model__secondary:active,
.erdi-inquiry__actions button:active {
  transform: translateY(1px) scale(.98) !important;
  transition-duration: .1s !important;
}
.rd26-button--dark:active,
.rd26-button--signal:active,
.ox-button--line:active {
  transform: translateY(1px) scale(.98) !important;
  transition-duration: .1s !important;
}

/* --- C. Header / nav controls -------------------------------------------- */
.ox-menu-toggle:active,
.ox-nav-search:active,
.ox-menu-head button:active,
.ox-story-controls button:active,
.rd26-studio-controls button:active {
  transform: scale(.94) !important;
  transition-duration: .1s !important;
}
.ox-nav-center > a:active,
.ox-nav-drop > summary:active,
.xr-desktop-nav > a:active,
.xr-dropdown > summary:active {
  background: color-mix(in srgb, var(--e-olive-400) 24%, transparent);
}
body .ox-header .ox-nav-center > a:active {
  background: #d3ecf0;
}
.ox-nav-sales:active,
.xr-nav-contact:active {
  background: #39cedd;
  border-color: #39cedd;
}
.ox-mega-links > a:active,
.xr-mega-links a:active,
.ox-menu .ox-menu-body details a:active {
  color: #00636b;
}

/* --- D. Cards & media tiles: press-in ------------------------------------ */
.rd26-card-image:active img {
  transform: scale(1.03) !important;
}
.ox-showcase-media:active > img {
  transform: scale(1.1) !important;
}
.ox-feature:active > img {
  transform: scale(1.02) !important;
}
.ox-film-card:active img {
  transform: scale(1.03) !important;
}
.ox-mg-card:active .ox-mg-media img {
  transform: scale(1.02) !important;
}
.ed-catalog-card:active img,
.ed-solution__media:active img,
.xr-family:active img,
.cx-card__visual:active img {
  transform: scale(1.02) !important;
}
.rd26-card-image:active,
.ox-showcase-media:active,
.ox-film-card:active,
.xr-family:active,
.cx-card__visual:active {
  opacity: .94;
}

/* --- E. Text links & small controls -------------------------------------- */
.rd26-textbutton:active,
.rd26-link:active,
.rd26-card-docs:active,
.rd26-finder-bottom a:active,
.op-text-link:active,
.ox-link:active,
.xr-text-link:active,
.sp-textlink:active,
.rd26-feature-links a:active,
.cx-text-button:active,
.erdi-product-gallery__open-3d:active,
.ed-about-paths__email:active,
.ox-search-overlay__hit:active,
.ox-search-overlay__chip:active,
.ox-footer :is(a, button):active,
.xr-footer :is(a, button):active {
  opacity: .62;
}
.rd26-home a:active .rd26-icon {
  transform: translate(4px, -4px);
}
body .ox-footer :is(a, button):active > .ox-icon,
body .ox-header .ox-mega a:active .ox-icon {
  transform: translateX(5px);
}
.erdi-source-viewer__start:active,
.oc-reset:active {
  transform: scale(.96) !important;
  transition-duration: .1s !important;
}

/* --- F. Touch targets on small screens ----------------------------------- */
@media (max-width: 900px) {
  .sp-breadcrumbs a,
  .ox-nav-drop > summary,
  .erdi-model-index-nav a,
  .rd26-feature-links a,
  .sp-textlink,
  .erdi-product-gallery__open-3d {
    min-height: 44px;
  }
  /* main.erdi-model .op-text-link (0,2,1) sets min-height:28px */
  .op-text-link {
    min-height: 44px !important;
  }
  .sp-breadcrumbs a,
  .erdi-model-index-nav a,
  .rd26-feature-links a,
  .op-text-link,
  .sp-textlink {
    display: inline-flex;
    align-items: center;
  }
  .ox-nav-drop > summary {
    display: flex;
    align-items: center;
  }
  input[type="checkbox"] {
    min-width: 22px;
    min-height: 22px;
  }
}
