/* ── Touch-action: prevents 300ms tap delay and accidental double-tap zoom ── */
button,
a,
[role="button"],
.mud-button-root,
.mud-icon-button,
.mud-fab,
.mud-nav-link,
.mud-tab,
.mud-chip {
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
}

/* ── Minimum touch target size (WCAG 2.5.5: 44×44 px) ───────────────────── */
/* Applied to icon buttons that might be rendered smaller than the minimum.   */
/* MudSwitch internals also use mud-icon-button — exclude them to avoid       */
/* shifting the switch thumb out of its track.                                */
.mud-icon-button {
    min-width: 44px;
    min-height: 44px;
}
.mud-switch .mud-icon-button,
.mud-switch-base {
    min-width: unset;
    min-height: unset;
}

/* ── Qty-buttons in CashierPage (inline Size.Small buttons) ──────────────── */
.cashier-qty-btn {
    min-width: 44px !important;
    min-height: 44px !important;
    padding: 0 8px !important;
}

/* ── Kitchen action buttons ─────────────────────────────────────────────── */
.kitchen-action-btn {
    min-height: 44px !important;
}

/* ── Safe-area insets (iPhone notch / home indicator) ───────────────────── */
.safe-area-bottom {
    padding-bottom: calc(12px + env(safe-area-inset-bottom));
}

.safe-area-top {
    padding-top: env(safe-area-inset-top);
}

/* ── Bottom navigation bar ───────────────────────────────────────────────── */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 1100;
    display: flex;
    background: var(--mud-palette-surface);
    box-shadow: 0 -2px 8px rgba(0, 0, 0, 0.12);
    padding-bottom: env(safe-area-inset-bottom);
    border-top: 1px solid var(--mud-palette-divider);
}

.bottom-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8px 4px;
    gap: 2px;
    cursor: pointer;
    text-decoration: none;
    color: var(--mud-palette-text-secondary);
    font-size: 0.65rem;
    font-family: inherit;
    background: none;
    border: none;
    touch-action: manipulation;
    -webkit-tap-highlight-color: transparent;
    transition: color 0.15s;
    min-height: 56px;
}

.bottom-nav-item.active {
    color: var(--mud-palette-primary);
}

.bottom-nav-item .mud-icon-root {
    font-size: 1.5rem;
}

/* ── When bottom-nav is shown, add padding to main content ───────────────── */
.has-bottom-nav .mud-main-content {
    padding-bottom: calc(64px + env(safe-area-inset-bottom));
}

/* ── Side panels: stop above bottom-nav on mobile so the nav stays visible ── */
@media (max-width: 959.95px) {
    .side-panel,
    .side-panel-backdrop {
        bottom: calc(56px + env(safe-area-inset-bottom)) !important;
    }
}

/* ── Order-Ready Toast ── */
.isp-order-toast {
    position: fixed;
    top: 16px;
    left: 50%;
    transform: translateX(-50%) translateY(-16px);
    background: #2e7d32;
    color: #fff;
    padding: 12px 22px;
    border-radius: 8px;
    font-family: Roboto, sans-serif;
    font-size: 15px;
    font-weight: 500;
    white-space: nowrap;
    box-shadow: 0 4px 16px rgba(0,0,0,.35);
    z-index: 10000;
    opacity: 0;
    transition: opacity .25s ease, transform .25s ease;
    pointer-events: none;
}
.isp-order-toast--visible {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
.isp-order-toast-icon {
    display: inline-block;
    margin-right: 6px;
    font-size: 17px;
}
