/* Utilities — shared cross-module helpers (used by 2+ modules). */


/* ── .rw-nav — Redwood nav spacing, shared by the header and footer menu modules ──
   Figma: 52px between items at 1728, no per-link padding, logo flush.
   The gap scales linearly from 16px at a 1440px viewport to 52px at 1728px:
     slope     = (52 − 16) / (1728 − 1440) = 0.125   → 12.5vw
     intercept = 16 − 0.125 × 1440 = −164px          → −10.25rem
   clamp() pins it to 1rem (16px) below 1440 and 3.25rem (52px) above 1728.
   (Below 1440 the header nav is a hamburger, so the 1rem floor only shows in the footer.) */
.rw-nav .et_pb_menu__logo { margin-right: 0 !important; }
.rw-nav .et-menu { column-gap: clamp(1rem, 12.5vw - 10.25rem, 3.25rem); }
.rw-nav .et-menu > li { padding-left: 0 !important; padding-right: 0 !important; }
.rw-nav .et-menu > li > a { padding-top: 0 !important; padding-bottom: 0 !important; }


/* ── Keyboard focus — toggle title buttons and carousel arrows (made operable by js/a11y.js).
      A visible ring on keyboard focus only; mouse clicks stay unchanged. ── */
.eos-toggle-btn:focus-visible,
.et_pb_group_carousel [role="button"]:focus-visible {
  outline: 2px solid var(--main-red);
  outline-offset: 3px;
  border-radius: 0.25rem;
}


/* ── Carousel mouse drag — js/carousel-drag.js adds .rw-carousel-drag to every Divi
      Group Carousel. Grab cursor on mouse devices only; no text selection mid-drag. ── */
@media (hover: hover) and (pointer: fine) {
  .rw-carousel-drag .et_pb_group_carousel_track { cursor: grab; }
  .rw-carousel-drag.is-dragging .et_pb_group_carousel_track { cursor: grabbing; }
}
.rw-carousel-drag.is-dragging { user-select: none; }
