/* NCS · «Se siente bien al tocar» — reglas comunes del sitio, el panel, el POS y la bodega.
   Basado en los principios de interfaces fluidas de Apple: respuesta inmediata, sin hover pegado, accesibilidad. */

/* 1 · Respuesta al toque: el botón reacciona al presionar, no al soltar */
:where(button, [role="button"], a.btn, .btn, [class*="btn-"], [class*="-btn"], [class*="cta"], .add, .chip, .tab):not(:disabled):active {
  transform: scale(.97);
  transition-duration: 90ms;
}
:where(button, a, [role="button"], summary, label, select) { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }

/* 2 · Campos: 16 px en pantallas táctiles para que el iPhone no agrande la página al tocarlos */
@media (pointer: coarse) {
  input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="color"]),
  select, textarea { font-size: 16px !important; }
}

/* 3 · Zonas de toque cómodas (44 px) en pantallas táctiles */
@media (pointer: coarse) {
  :where(.cat a, .footer-links a, .tab, .chip) { min-height: 44px; display: inline-flex; align-items: center; }
  :where(.m-dd-t, .mobile-menu a, .mc .add, .seg button, .snav-back) { min-height: 44px; }
  .snav-back { min-width: 44px; }
}

/* 4 · Tipografía por tamaño: títulos grandes más juntos (solo si la página no define el suyo) */
:where(h1, h2) { letter-spacing: -.015em; }
:where(h3, h4) { letter-spacing: -.005em; }
:where(h1, h2, h3) { text-wrap: balance; }


/* 6 · Respeta «reducir movimiento»: sin deslizamientos ni bucles; se conservan los cambios de color y opacidad */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important; animation-iteration-count: 1 !important; animation-delay: 0s !important;
    scroll-behavior: auto !important;
    transition-property: opacity, color, background-color, border-color, box-shadow, visibility !important;
    transition-duration: .15s !important; transition-delay: 0s !important;
  }
  :active { transform: none !important; }
  .hero-bg-video { display: none !important; }
}

/* 7 · Respeta «reducir transparencia»: superficies sólidas, sin desenfoque */
@media (prefers-reduced-transparency: reduce) {
  *, *::before, *::after { backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
  nav, .nav-links .dd:before, .mobile-menu, .ncs-agent, #ncsChat { background: #0c1e36 !important; }
}

/* 8 · Respeta «alto contraste»: bordes definidos */
@media (prefers-contrast: more) {
  :where(input, select, textarea, button, .btn) { border-color: currentColor; }
  :where(a) { text-decoration: underline; }
}
