/*
 * THE BULK-SELECT BAR, pinned bottom-centre while a selection is live.
 *
 * The WRAPPER spans its positioned ancestor and lets presses fall through
 * everywhere except the bar, which takes its own back — otherwise the invisible
 * full-width box swallows every click on the rows underneath it.
 *
 * The gutter is the ROW's, not the surface's: `Card` zeroes its own padding at
 * `.lotics-card[data-padding="none"]`, a class and an attribute, so a padding
 * stated on the same box loses on specificity.
 *
 * `state` and `acts` are each a nowrap row, so the only break available is the
 * boundary between them: the line splits where the meaning does, never
 * mid-ladder.
 *
 * The bar's own z-index is an IN-PAGE rung, never compared with an overlay's
 * (§2.3): a dialog opened FROM the bar paints over it. It takes the TOP of that
 * ladder because it floats over the whole scroller.
 */
@layer theme, base, lotics, components, utilities;
@layer lotics.tokens, lotics.reset, lotics.components;

@layer lotics.components {
  .lotics-selection-bar {
    display: flex;
    flex-direction: column;
    align-items: center;
    position: absolute;
    inset: auto 0 var(--lotics-space-16) 0;
    /* With the bar's own `max-width`, this is what bounds it to the viewport on
       a phone — and what keeps it off the screen edges at any width. */
    padding-inline: var(--lotics-space-16);
    z-index: var(--lotics-z-floating-bar);
    pointer-events: none;
  }

  .lotics-selection-bar__bar {
    max-width: 100%;
    pointer-events: auto;
  }

  .lotics-selection-bar__row {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    min-width: 0;
    gap: var(--lotics-space-16);
    padding-block: var(--lotics-space-10);
    padding-inline: var(--lotics-space-16);
  }

  .lotics-selection-bar__state,
  .lotics-selection-bar__acts {
    display: flex;
    flex-direction: row;
    align-items: center;
    flex-wrap: nowrap;
    gap: var(--lotics-space-8);
  }
}
