/* Shared ClubAdmin, LeagueAdmin, AppAdmin and Jazz Bantam phone treatment, loaded after tenant/workspace themes. */
.club-mobile-toggle, .club-mobile-sort { display: none; }
/* Bootstrap display utilities must never reveal conditionally hidden data. */
body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table [hidden] { display: none !important; }
@media (max-width: 991.98px) {
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main { min-width: 0; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main h1 { font-size: 1.65rem; line-height: 1.2; overflow-wrap: break-word; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .le-eyebrow { font-size: .75rem; letter-spacing: .04em; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .card-body { padding: 1rem; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main :is(.btn, .form-control, .form-select) { min-height: 44px; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main :is(.form-control, .form-select) { font-size: 16px; min-width: 0; max-width: 100%; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .badge { white-space: normal; overflow-wrap: break-word; }
    /* Keep a long label inside the screen without stretching every button. */
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .btn { max-width: 100%; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main :is(.btn, .form-label) { font-size: .875rem; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main :is(.card, .card-body, .row > *, .d-flex > *) { min-width: 0; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main :is(.d-flex, .le-page-header__actions, .le-next-event__actions) > :is(.btn, .dropdown, form) {
        flex: 0 0 auto;
        min-width: min(100%, max-content);
        max-width: 100%;
    }
    /* Page header: title block on the left, its actions on the right; the actions
       only drop below when the title leaves no room (or the More menu is open). */
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-heading {
        flex-direction: row !important;
        flex-wrap: wrap;
        justify-content: space-between !important;
        gap: .5rem .75rem;
        align-items: center !important;
    }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-heading > :first-child { flex: 1 1 9rem; min-width: 0; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-heading > .d-flex { flex-wrap: wrap; flex: 0 1 auto; justify-content: flex-end; gap: .4rem !important; margin-left: auto; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-heading > .club-mobile-actions.club-mobile-open { flex-basis: 100%; justify-content: flex-start; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-heading > .d-flex .btn { padding-inline: .75rem; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-heading h1 { font-size: 1.5rem; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main :is(.nav-tabs, .nav-pills) { flex-wrap: wrap; gap: .25rem; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .pagination { flex-wrap: wrap; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main :is(p, dd, .alert) { overflow-wrap: break-word; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main :is(.le-cal-toolbar, .le-cal-legend) { flex-wrap: wrap; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-toggle { display: inline-flex; align-items: center; justify-content: center; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-toggle::after { content: '+'; margin-left: .5rem; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-toggle[aria-expanded="true"]::after { content: '−'; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-actions { flex-wrap: wrap; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-actions:not(.club-mobile-open) > :not(.club-mobile-primary-action):not(.club-mobile-actions-toggle) { display: none !important; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-actions > :is(.club-mobile-primary-action, .club-mobile-actions-toggle, form) {
        flex: 0 0 auto;
        width: auto;
        max-width: 100%;
        min-width: min(100%, max-content);
    }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-actions .btn {
        width: max-content;
        max-width: 100%;
    }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-actions > form { max-width: 100%; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-filter-toggle { margin-bottom: .75rem; width: auto; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-filters:not(.club-mobile-open) .club-mobile-filter-secondary { display: none; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-sort { display: flex; align-items: center; gap: .5rem; margin-bottom: .75rem; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-sort label { font-size: .8rem; color: var(--le-text-muted); }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-sort select { width: auto; max-width: calc(100% - 3rem); }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table-surface { overflow: visible; background: transparent; border: 0; box-shadow: none; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table { display: block; width: 100%; min-width: 0 !important; table-layout: auto; line-height: 1.5; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > :is(tbody, tfoot) { display: block; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > thead { display: block; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > thead > tr { display: flex; flex-wrap: wrap; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > thead > tr > th { display: none; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > thead > tr > .club-mobile-header-control { display: block; padding: .5rem; background: transparent; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > :is(tbody, tfoot) > tr {
        display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .75rem 1rem;
        padding: 1rem; margin-bottom: .75rem; border: 1px solid var(--le-border);
        border-radius: 14px; background: var(--le-surface);
    }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > :is(tbody, tfoot) > tr > :is(td, th) {
        display: block; min-width: 0 !important; width: auto !important; max-width: 100%;
        padding: 0; border: 0; background: transparent; box-shadow: none;
        white-space: normal !important; overflow-wrap: break-word; text-align: left !important; font-size: .875rem;
    }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > :is(tbody, tfoot) > tr > .club-mobile-wide { grid-column: 1 / -1; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > :is(tbody, tfoot) > tr > :first-child { font-size: 1rem; font-weight: 600; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > :is(tbody, tfoot) > tr > :not(:first-child)::before {
        content: attr(data-mobile-label); display: block; font-size: .75rem; font-weight: 400;
        line-height: 1.35; color: var(--le-text-muted); margin-bottom: .25rem;
    }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > :is(tbody, tfoot) > tr > [data-mobile-label=""]::before { display: none; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table .club-mobile-row-toggle { display: flex; margin-top: .5rem; font-size: .8rem; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table tr:not(.club-mobile-open) > .club-mobile-detail { display: none !important; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table :is(.text-nowrap, .le-player-email) { white-space: normal !important; max-width: 100%; overflow: visible; text-overflow: clip; overflow-wrap: break-word; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table .badge { font-size: .75rem; line-height: 1.3; }
    /* Rostered-player cards keep one icon menu on the name row. */
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .le-players-table.club-mobile-table > tbody > tr { position: relative; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .le-players-table.club-mobile-table > tbody > tr > :first-child { padding-right: 3.25rem; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .le-players-table .le-player-row-actions {
        position: absolute; top: .65rem; right: .65rem; z-index: 2;
        width: auto !important; margin: 0;
    }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .le-players-table .le-player-row-actions::before { display: none !important; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .le-player-card-menu-btn {
        width: 44px; height: 44px; min-width: 44px; padding: 0;
        display: inline-flex; align-items: center; justify-content: center;
    }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .le-player-card-menu-btn.dropdown-toggle::after { content: none; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .le-player-roster-menu {
        width: min(22rem, calc(100vw - 2rem));
    }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main :is(.le-player-roster-menu, .le-player-card-menu) .dropdown-item {
        min-height: 44px; display: flex; align-items: center; white-space: normal;
    }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table :is(.d-flex, .d-inline-flex) { flex-wrap: wrap !important; justify-content: flex-start !important; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table .le-avatar { flex-shrink: 0; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table :is(input, select, textarea) { max-width: 100%; min-width: 0 !important; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table :is(td, th) > form { max-width: 100%; }
    /* Responsive desktop-only fields remain available in labelled phone cards.
       Explicit hidden attributes and JS-filtered rows always take precedence. */
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table td.d-none:is(.d-md-table-cell, .d-lg-table-cell, .d-xl-table-cell) { display: block !important; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table [hidden],
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table tr[hidden] { display: none !important; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table tr:not(.club-mobile-open) > .club-mobile-detail.d-none { display: none !important; }
    body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table td.d-none[hidden] { display: none !important; }
    @media (max-width: 359.98px) {
        body:is(.le-club-shell, .le-jazz-views, .le-mobile-cards) main .club-mobile-table > :is(tbody, tfoot) > tr { grid-template-columns: minmax(0, 1fr); }
    }
}
