/* Keep existing colours, typography, content and desktop composition. */
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 100px; }
img, video, canvas, iframe { max-width: 100%; }
input, select, textarea, button { box-sizing: border-box; max-width: 100%; }
textarea { resize: vertical; }
.grid > *, .row > *, .form-row > *, .page-head > *, .ela-toolbar > *,
.cart-info, .cart-details, .product-info, .main { min-width: 0; }
.ela-device-table { max-width: 100%; overflow-x: auto; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; }
.ela-device-table:focus-visible { outline: 2px solid currentColor; outline-offset: 2px; }
.menu-panel { max-width: calc(100vw - 24px); }
@media (max-width: 980px) {
  .page-head, .ela-toolbar, .form-row { flex-wrap: wrap; }
  .modal, .modal-content, .tag-modal, .tag-dialog { max-width: calc(100vw - 24px); }
}
@media (max-width: 600px) {
  .afterglow-col { min-width: 0 !important; flex-basis: 100% !important; padding: 24px !important; }
  input:not([type="checkbox"]):not([type="radio"]):not([type="range"]):not([type="hidden"]),
  select, textarea { font-size: max(16px, 1em); }
  .form-row .form-group { min-width: 0; flex-basis: 100%; }
  .cart-info, .cart-details, .product-info, .ela-dno, .page-sub { overflow-wrap: anywhere; }
  .cta, .btn-inquire, .ela-actions button { white-space: normal; height: auto; min-height: 44px; }
  .tag-head, .tag-foot { flex-wrap: wrap; gap: 10px; }
  .tag-dialog, .modal-content { max-height: 90dvh; overflow-y: auto; }
}
@media (max-width: 380px) {
  .nav { gap: 6px; padding-left: 8px; padding-right: 8px; }
  .nav-right { gap: 4px; }
  .brand { min-width: 0; }
  .brand-ela { font-size: 20px; letter-spacing: 2px; }
  .brand-sub { letter-spacing: .5px; }
  .stats-row, .ela-grid, .ela-loading { grid-template-columns: repeat(auto-fit, minmax(min(142px, 100%), 1fr)); }
  .bar-cta > div[style], .afterglow-col { min-width: 0 !important; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto !important; }
  .reveal, .stagger-1, .stagger-2 { transition-duration: .01ms !important; }
}
@media print { .ela-device-table { overflow: visible; } }
