/* Guest & guardian mobile layout helpers */

@media (max-width: 639px) {
    /* Prevent horizontal page scroll on small screens */
    #root {
        overflow-x: hidden;
    }

    /* Guest / blank public forms: full-width action buttons */
    .container.relative .mt-4.flex.justify-end.space-x-4 {
        flex-direction: column-reverse;
        gap: 0.5rem;
    }

    .container.relative .mt-4.flex.justify-end.space-x-4 > * {
        width: 100%;
        margin-left: 0 !important;
    }

    /* Page header action buttons (guardian fee pages, etc.) */
    .mt-4.flex.shrink-0.justify-end {
        flex-wrap: wrap;
        gap: 0.5rem;
        justify-content: flex-start;
    }

    /* Data tables: smoother touch scrolling */
    .scroller-thin-x {
        -webkit-overflow-scrolling: touch;
        max-width: 100%;
    }

    /* Stack page header title + actions */
    .mt-2.md\:flex.md\:items-center.md\:justify-between {
        gap: 0.75rem;
    }

    /* Modal panels: use available width */
    .inline-block.w-full.transform {
        max-width: calc(100vw - 2rem);
    }
}

@media (max-width: 1023px) {
    /* Guardian app: secondary header row (period/team selectors) */
    .dark\:bg-dark-header.relative.flex.shrink-0.justify-between.bg-black .flex.w-full.justify-end.gap-2 {
        flex-wrap: wrap;
    }
}
