/*
 * Visual feedback where the Vibration API is missing (iOS), PLAN.md §11.4: platform/haptics.ts sets
 * html[data-flash] for 400ms. Colours are the main app's signal tokens.
 */

html[data-flash] .app-shell::after {
    content: '';
    position: fixed;
    inset: 0;
    z-index: var(--zindex-notification);
    pointer-events: none;
    animation: capture-flash 0.4s ease-out forwards;
}

html[data-flash='success'] .app-shell::after {
    box-shadow: inset 0 0 0 4px rgb(var(--icon-success));
}

html[data-flash='error'] .app-shell::after,
html[data-flash='failure'] .app-shell::after {
    box-shadow: inset 0 0 0 4px rgb(var(--icon-error));
}

@keyframes capture-flash {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

@media (prefers-reduced-motion: reduce) {
    html[data-flash] .app-shell::after {
        animation-duration: 0.4s;
        animation-timing-function: steps(1, end);
    }
}
