/* One motion owner; route changes never animate a page just because a modal closed. */
html { scroll-behavior: auto; scrollbar-gutter: stable; }
.page { animation: none; }
.shop-overlay-open { overflow: hidden; }
[data-motion-phase="closing"] { pointer-events: none; }
:is(.donation-modal,.product-detail-modal,.legal-modal,.confirm-modal) { backdrop-filter: none; -webkit-backdrop-filter: none; }
.donation-modal { align-items: flex-end; padding: 12px 0 0; background: rgba(0,0,0,.64); }
.donation-sheet { width: min(100%,480px); max-height: calc(100dvh - 12px); padding: 22px 20px calc(24px + env(safe-area-inset-bottom)); border-radius: 20px 20px 0 0; border-bottom: 0; overscroll-behavior: contain; }
.donation-header h2 { font-size: 24px; }
.donation-close { flex-basis: 44px; width: 44px; height: 44px; }
.donation-feedback { display: grid; margin: 12px 0; }
.donation-feedback > p { grid-area: 1 / 1; }
.donation-sync { min-height: 20px; margin: 0; color: #b1b8c3; font-size: 13px; line-height: 20px; }
#donation-form-error { min-height: 20px; margin: 0; }
#donation-form-error:empty { display: block; }
.order-detail-sheet-header { display: none; }
#page-order-detail.is-reward-sheet { position: fixed; z-index: 200; inset: 0; min-height: 0; align-items: flex-end; justify-content: center; padding-top: max(16px,env(safe-area-inset-top)); background: rgba(0,0,0,.64); }
.is-reward-sheet .order-detail-sheet { display: flex; flex-direction: column; width: min(620px,100%); max-height: calc(100dvh - max(16px,env(safe-area-inset-top))); background: #111318; border: 1px solid #333840; border-bottom: 0; border-radius: 20px 20px 0 0; overflow: hidden; }
.is-reward-sheet .order-detail-sheet-header { display: flex; flex: none; align-items: center; justify-content: space-between; padding: 8px 12px 0 20px; }
.order-detail-sheet-header > span { width: 36px; height: 4px; border-radius: 2px; background: #535a65; }
.order-detail-sheet-close { display: grid; place-items: center; width: 44px; height: 44px; border: 0; border-radius: 50%; background: #20242c; color: #f5f7fa; cursor: pointer; }
.order-detail-sheet-close svg { width: 20px; height: 20px; }
.order-detail-sheet-close:focus-visible { outline: 2px solid #ffcc32; outline-offset: 2px; }
.is-reward-sheet #order-detail-content { overflow: auto; overscroll-behavior: contain; padding: 0 18px calc(12px + env(safe-area-inset-bottom)); scrollbar-width: thin; scrollbar-color: #535a65 #111318; }
.is-reward-sheet .order-back { display: none; }
.is-reward-sheet .rf-reward { padding-top: 0; }
.is-reward-sheet .rf-reward h1 { margin-top: 0; }
.is-reward-sheet .rf-claim-bar { position: sticky; z-index: 1; left: auto; bottom: calc(-12px - env(safe-area-inset-bottom)); transform: none; width: auto; margin: 0 -2px; padding: 12px 2px calc(12px + env(safe-area-inset-bottom)); background: #111318; }
.is-reward-sheet .reward-flow { --rf-panel: #171a20; }
.has-reward-sheet .app-shell { padding-bottom: var(--sheet-base-padding, 100px); }
.has-reward-sheet .bottom-nav,.has-reward-sheet .donation-nudge { pointer-events: none; }
.reward-card [aria-busy="true"] { cursor: progress; }
.rf-progress > span[role="alert"] { white-space: normal; }
.rf-step[data-state="syncing"] .rf-step-count { color: var(--rf-muted); }
.rf-link-icon:disabled,.rf-upload:has(input:disabled) { opacity: .55; cursor: wait; }
@media (min-width: 700px) {
    .donation-modal { align-items: center; padding: 24px; }
    .donation-sheet { border-bottom: 1px solid #303238; border-radius: 20px; max-height: calc(100dvh - 48px); }
}
@media (prefers-reduced-motion: reduce) {
    .page,.rf-step { animation: none; transition: none; }
}
