/* Mobile-first base, then layered up for tablet (600px) and desktop (960px) further down.
   Breakpoints match MudBlazor: xs < 600 <= sm < 960 <= md. */
:root {
    --ss-bottom-nav-h: 64px;
    --ss-safe-bottom: env(safe-area-inset-bottom, 0px);
    --ss-sticky-cta-h: 72px;
    --ss-radius: 16px;
}

html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    overflow-x: hidden;
    overflow-x: clip; /* clip (not hidden) so position: sticky keeps working */
    width: 100%;
    position: relative;
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    -webkit-tap-highlight-color: transparent;
}

/* No 300ms tap delay, no double-tap zoom on controls. */
a, button, .mud-button-root, .mud-icon-button, [role="button"] { touch-action: manipulation; }

img, video { max-width: 100%; }

/* Full-width page sections: keep decorative glows and MudGrid's negative gutters inside the screen. */
.ss-main section { overflow-x: clip; }


a, .btn-link {
    color: #006bb7;
}

.btn-primary {
    color: #fff;
    background-color: #1b6ec2;
    border-color: #1861ac;
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

.content {
    padding-top: 1.1rem;
}

h1:focus {
    outline: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid #26b050;
}

.invalid {
    outline: 1px solid #e50000;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45NjMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.darker-border-checkbox.form-check-input {
    border-color: #929292;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
    color: var(--bs-secondary-color);
    text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
    text-align: start;
}
/* --- Phone typography & alignment ------------------------------------------------------
   Marketing copy (home, about, gallery…) centres on phones. Shopping screens (product, cart,
   checkout, forms) opt out with .ss-left: left-aligned text is faster to scan there. */
@media (max-width: 599.98px) {
    .ss-main :is(.mud-typography, p, h1, h2, h3, h4, h5, h6):not(.ss-left, .ss-left *, .mud-input-control *, .mud-table *, .mud-alert *) {
        text-align: center;
    }
    .ss-main .mud-grid { justify-content: center; }
}

/* Headlines scale down with the screen instead of overflowing it (desktop sizes unchanged). */
.ss-main .mud-typography-h1 { font-size: clamp(2.25rem, 10vw, var(--mud-typography-h1-size, 6rem)); }
.ss-main .mud-typography-h2 { font-size: clamp(2rem, 8.5vw, var(--mud-typography-h2-size, 3.75rem)); }
.ss-main .mud-typography-h3 { font-size: clamp(1.6rem, 7vw, var(--mud-typography-h3-size, 3rem)); line-height: 1.2; }
.ss-main .mud-typography-h4 { font-size: clamp(1.4rem, 6vw, var(--mud-typography-h4-size, 2.125rem)); line-height: 1.25; }
.ss-main .mud-typography-h5 { font-size: clamp(1.2rem, 5vw, var(--mud-typography-h5-size, 1.5rem)); }

/* --- Header ------------------------------------------------------------------------------ */
.mud-main-content {
    padding-top: var(--mud-appbar-height) !important;
    min-height: 100vh;
    min-height: 100dvh;
}
.ss-appbar .mud-toolbar { gap: 4px; }
.ss-brand { min-width: 0; flex-shrink: 1; }
.ss-brand .store-wordmark {
    display: block;
    font-family: var(--mud-typography-h1-family, inherit);
    font-size: clamp(1.15rem, 5vw, 1.45rem);
    font-weight: 600;
    letter-spacing: .02em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.ss-brand-logo { max-width: 56vw; }
@media (max-width: 599.98px) {
    .ss-brand-logo { height: 40px !important; }
}

/* --- Bottom tab bar (phones + tablets) ---------------------------------------------------- */
.ss-bottom-nav {
    position: fixed;
    left: 0; right: 0; bottom: 0;
    z-index: 1290; /* above page + stickers, below the open drawer's overlay */
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    height: calc(var(--ss-bottom-nav-h) + var(--ss-safe-bottom));
    padding-bottom: var(--ss-safe-bottom);
    background: var(--mud-palette-surface);
    background: color-mix(in srgb, var(--mud-palette-surface) 88%, transparent);
    -webkit-backdrop-filter: saturate(180%) blur(18px);
    backdrop-filter: saturate(180%) blur(18px);
    border-top: 1px solid var(--mud-palette-lines-default);
    box-shadow: 0 -6px 24px rgba(0, 0, 0, .07);
}
.ss-tab {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    min-height: 48px;
    padding: 6px 0 4px;
    border: 0;
    background: none;
    font: inherit;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .02em;
    color: var(--mud-palette-text-secondary);
    text-decoration: none !important;
    cursor: pointer;
    transition: color .2s ease;
}
.ss-tab .mud-icon-root { font-size: 1.5rem; transition: transform .18s cubic-bezier(.2, 1.4, .4, 1); }
.ss-tab:active .mud-icon-root { transform: scale(.85); }
.ss-tab.active { color: var(--mud-palette-primary); }
.ss-tab.active::before {
    content: "";
    position: absolute;
    top: 0; left: 32%; right: 32%;
    height: 3px;
    border-radius: 0 0 4px 4px;
    background: var(--mud-palette-primary);
    animation: ss-tab-in .25s ease-out;
}
.ss-tab:focus-visible { outline: 2px solid var(--mud-palette-primary); outline-offset: -4px; border-radius: 12px; }
.ss-tab-icon { position: relative; display: inline-flex; }
.ss-tab-badge {
    position: absolute;
    top: -5px; right: -11px;
    min-width: 18px; height: 18px;
    padding: 0 5px;
    border-radius: 9px;
    background: var(--mud-palette-secondary);
    color: var(--mud-palette-secondary-text, #fff);
    font-size: 11px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
    box-shadow: 0 0 0 2px var(--mud-palette-surface);
    animation: ss-pop .4s cubic-bezier(.2, 1.6, .4, 1);
}
@keyframes ss-pop { 0% { transform: scale(.3); } 100% { transform: scale(1); } }
@keyframes ss-tab-in { from { transform: scaleX(0); } to { transform: scaleX(1); } }

@media (max-width: 959.98px) {
    /* Keep the last bit of every page clear of the tab bar. */
    .ss-has-bottom-nav .ss-main { padding-bottom: calc(var(--ss-bottom-nav-h) + var(--ss-safe-bottom)); }
    /* Admin editor focus bar sits above the tab bar. */
    .ss-has-bottom-nav .global-admin-toolbar { bottom: calc(var(--ss-bottom-nav-h) + var(--ss-safe-bottom) + 12px) !important; }
}

/* Copy of the tab bar inside the admin's phone/tablet preview frame. */
.device-frame-shell { display: flex; flex-direction: column; }
.device-frame-shell .device-screen-scrollable { flex: 1; min-height: 0; }
.ss-bottom-nav--frame { position: relative; flex: 0 0 var(--ss-bottom-nav-h); height: var(--ss-bottom-nav-h); padding-bottom: 0; z-index: 60; }

/* --- Drawer (menu sheet on phones) ------------------------------------------------------- */
.ss-drawer-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: calc(10px + env(safe-area-inset-top, 0px)) 8px 10px 20px;
    border-bottom: 1px solid var(--mud-palette-lines-default);
}
.ss-drawer-title {
    font-family: var(--mud-typography-h1-family, inherit);
    font-size: 1.2rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.ss-drawer-extras { border-top: 1px solid var(--mud-palette-lines-default); padding: 8px 16px calc(24px + var(--ss-safe-bottom)); }
.ss-drawer-row { display: flex; align-items: center; gap: 14px; min-height: 52px; font-size: .95rem; }
.ss-drawer-admin { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding-top: 12px; }
.ss-drawer-caption { font-size: .72rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; opacity: .6; }
@media (max-width: 959.98px) {
    .ss-drawer .mud-nav-link { min-height: 48px; font-size: 1rem; }
}

/* --- Sticky buy bar (product page, cart) ------------------------------------------------- */
.ss-sticky-cta {
    display: none;
    align-items: center;
    gap: 12px;
    z-index: 1280;
    min-height: var(--ss-sticky-cta-h);
    padding: 10px 16px;
    background: var(--mud-palette-surface);
    background: color-mix(in srgb, var(--mud-palette-surface) 92%, transparent);
    -webkit-backdrop-filter: saturate(180%) blur(18px);
    backdrop-filter: saturate(180%) blur(18px);
    border-top: 1px solid var(--mud-palette-lines-default);
    box-shadow: 0 -8px 28px rgba(0, 0, 0, .08);
    animation: ss-slide-up .35s cubic-bezier(.2, .8, .2, 1);
}
@media (max-width: 959.98px) {
    .ss-sticky-cta {
        display: flex;
        position: fixed;
        left: 0; right: 0;
        bottom: calc(var(--ss-bottom-nav-h) + var(--ss-safe-bottom));
    }
    .ss-has-sticky-cta { padding-bottom: calc(var(--ss-sticky-cta-h) + 16px); }
    .ss-shell:not(.ss-has-bottom-nav) .ss-sticky-cta { bottom: 0; padding-bottom: calc(10px + var(--ss-safe-bottom)); }
}
/* Inside the admin preview frame the page scrolls in its own box, so stick to that instead. */
.device-frame-shell .ss-sticky-cta { display: flex; position: sticky; bottom: 0; margin: 16px -16px 0; }
.device-frame-shell .ss-has-sticky-cta { padding-bottom: 0; }
.ss-sticky-cta-info { display: flex; flex-direction: column; min-width: 0; flex: 1; line-height: 1.25; }
.ss-sticky-cta-label { font-size: .78rem; color: var(--mud-palette-text-secondary); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ss-sticky-cta-price { font-size: 1.15rem; font-weight: 700; color: var(--mud-palette-text-primary); }
.ss-sticky-cta .mud-button-root { flex: 0 0 auto; min-height: 48px; padding-left: 22px; padding-right: 22px; border-radius: 999px; font-weight: 700; }
.ss-checkout-back { display: inline-flex; align-items: center; gap: 2px; margin: 0 0 8px -6px; padding: 6px 10px 6px 4px; font-weight: 600; font-size: .9rem; color: var(--mud-palette-text-secondary); text-decoration: none; }
@keyframes ss-slide-up { from { transform: translateY(100%); opacity: 0; } to { transform: none; opacity: 1; } }

/* --- Touch ergonomics -------------------------------------------------------------------- */
@media (max-width: 959.98px), (hover: none) {
    /* iOS Safari can't do fixed (parallax) backgrounds and renders them huge and blurry. */
    .parallax-wrapper, .parallax-section, .ss-main [style*="background-attachment: fixed"] { background-attachment: scroll !important; }
}
@media (max-width: 959.98px) {
    /* 16px stops iOS Safari zooming the page when a field gets focus. */
    input, select, textarea, .mud-input-slot { font-size: 16px !important; }
    .ss-main .mud-button-root.mud-button-size-medium:not(.mud-icon-button) { min-height: 44px; }
    .ss-main .mud-button-root.mud-button-size-large:not(.mud-icon-button) { min-height: 50px; }
}

/* Dialogs become bottom sheets on phones: easier to reach, never wider than the screen. */
@media (max-width: 599.98px) {
    .mud-dialog-container { align-items: flex-end !important; }
    .mud-dialog-container .mud-dialog:not(.mud-dialog-fullscreen) {
        margin: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        max-height: calc(100dvh - 32px) !important;
        border-radius: 20px 20px 0 0 !important;
        padding-bottom: var(--ss-safe-bottom);
        animation: ss-slide-up .3s cubic-bezier(.2, .8, .2, 1);
    }
    .mud-dialog-container .mud-dialog .mud-dialog-content { overflow-y: auto; }
}

/* --- Installable app: "Get the app" invitation + menu row --------------------------------- */
.ss-app-sheet {
    position: fixed;
    z-index: 1350; /* above the tab bar / sticky buy bar, below dialogs and snackbars */
    left: 12px; right: 12px;
    bottom: calc(var(--ss-bottom-nav-h) + var(--ss-safe-bottom) + 12px);
    max-width: 440px;
    margin: 0 auto;
    padding: 20px 20px 16px;
    border-radius: 24px;
    color: var(--mud-palette-text-primary);
    background: var(--mud-palette-surface);
    background:
        radial-gradient(120% 90% at 0% 0%, color-mix(in srgb, var(--mud-palette-primary) 16%, transparent), transparent 60%),
        color-mix(in srgb, var(--mud-palette-surface) 96%, transparent);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    backdrop-filter: saturate(180%) blur(20px);
    box-shadow: 0 28px 70px -18px rgba(0, 0, 0, .5), 0 0 0 1px color-mix(in srgb, var(--mud-palette-text-primary) 10%, transparent);
    text-align: left;
    animation: ss-sheet-in .5s cubic-bezier(.2, .9, .25, 1.1) both;
}
.ss-shell:not(.ss-has-bottom-nav) .ss-app-sheet { bottom: calc(var(--ss-safe-bottom) + 12px); }
@media (min-width: 960px) {
    .ss-app-sheet { left: auto; right: 24px; bottom: 24px; width: 400px; }
}
.ss-app-sheet-close {
    position: absolute; top: 10px; right: 10px;
    display: grid; place-items: center;
    width: 36px; height: 36px; border: 0; border-radius: 50%;
    color: inherit; background: color-mix(in srgb, var(--mud-palette-text-primary) 8%, transparent);
    cursor: pointer;
}
.ss-app-sheet-head { display: flex; align-items: center; gap: 16px; padding-right: 36px; }
.ss-app-sheet-icon {
    flex: 0 0 auto; width: 64px; height: 64px; border-radius: 16px; object-fit: cover;
    box-shadow: 0 10px 24px -6px rgba(0, 0, 0, .35), 0 0 0 1px rgba(0, 0, 0, .06);
    animation: ss-icon-pop .6s .15s cubic-bezier(.3, 1.6, .5, 1) both;
}
.ss-app-sheet-titles h2 { margin: 0; font-size: 1.12rem; font-weight: 700; line-height: 1.25; letter-spacing: 0; }
.ss-app-sheet-titles p { margin: 4px 0 0; font-size: .9rem; color: var(--mud-palette-text-secondary); }
.ss-app-perks, .ss-app-steps { list-style: none; margin: 16px 0 4px; padding: 0; display: grid; gap: 10px; }
.ss-app-perks li { display: flex; align-items: center; gap: 12px; font-size: .92rem; }
.ss-app-perks .mud-icon-root { color: var(--mud-palette-primary); }
.ss-app-steps li { display: flex; align-items: center; gap: 12px; font-size: .92rem; line-height: 1.4; }
.ss-app-step-num {
    flex: 0 0 auto; display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
    font-size: .8rem; font-weight: 700; color: var(--mud-palette-primary-text); background: var(--mud-palette-primary);
}
.ss-app-glyph { display: inline-flex; vertical-align: -3px; color: #007aff; }
.ss-app-actions { display: flex; justify-content: flex-end; align-items: center; gap: 8px; margin-top: 14px; }
.ss-app-actions .mud-button-root { min-height: 44px; border-radius: 999px; padding-left: 18px; padding-right: 18px; font-weight: 600; }
.ss-app-actions .ss-app-primary { padding-left: 22px; padding-right: 22px; font-weight: 700; }
@keyframes ss-sheet-in { from { transform: translateY(24px) scale(.96); opacity: 0; } to { transform: none; opacity: 1; } }
@keyframes ss-icon-pop { from { transform: scale(.6) rotate(-8deg); opacity: 0; } to { transform: none; opacity: 1; } }

.ss-drawer-install { padding: 8px 12px; }
.ss-drawer-install-btn {
    display: flex; align-items: center; gap: 12px; width: 100%; min-height: 60px; padding: 10px 12px;
    border: 0; border-radius: 16px; cursor: pointer; text-align: left; font: inherit; color: inherit;
    background: color-mix(in srgb, var(--mud-palette-primary) 10%, transparent);
    transition: background-color .2s ease, transform .15s ease;
}
.ss-drawer-install-btn:hover { background: color-mix(in srgb, var(--mud-palette-primary) 16%, transparent); }
.ss-drawer-install-btn:active { transform: scale(.98); }
.ss-drawer-install-btn img { width: 40px; height: 40px; border-radius: 10px; box-shadow: 0 4px 10px -4px rgba(0, 0, 0, .4); }
.ss-drawer-install-btn strong { display: block; font-size: .95rem; }
.ss-drawer-install-btn small { display: block; font-size: .78rem; color: var(--mud-palette-text-secondary); }

/* Settings > Phone App: icon preview on a home-screen wallpaper (mirrors StoreAppController.RenderIcon). */
.ss-app-preview {
    display: flex; justify-content: center; gap: 40px; padding: 28px 16px 20px; border-radius: 20px;
    background: radial-gradient(circle at 20% 10%, #f9a8d4 0%, transparent 45%), radial-gradient(circle at 85% 80%, #93c5fd 0%, transparent 50%), linear-gradient(135deg, #6366f1, #0ea5e9);
}
.ss-app-preview-icon { display: flex; flex-direction: column; align-items: center; gap: 6px; color: #fff; text-shadow: 0 1px 3px rgba(0, 0, 0, .45); }
.ss-app-preview-icon span { font-size: .8rem; font-weight: 500; max-width: 96px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ss-app-preview-icon small { font-size: .65rem; opacity: .75; text-transform: uppercase; letter-spacing: .08em; }
.ss-app-preview-tile { position: relative; display: grid; place-items: center; width: 84px; height: 84px; overflow: hidden; box-shadow: 0 10px 24px -8px rgba(0, 0, 0, .5); }
.ss-app-preview-tile.ios { border-radius: 22%; }
.ss-app-preview-tile.android { border-radius: 50%; }
.ss-app-preview-tile img.fill { width: 100%; height: 100%; object-fit: cover; }
.ss-app-preview-tile img.fit { width: 80%; height: 80%; object-fit: contain; }
.ss-app-preview-tile img.fit-safe { width: 56%; height: 56%; object-fit: contain; }
.ss-app-preview-tile img.glyph { width: 62%; height: 62%; object-fit: contain; mix-blend-mode: screen; }
.ss-app-preview-tile img.glyph.safe { width: 56%; height: 56%; }
.ss-app-preview-tile img.glyph.dark { filter: invert(1) brightness(.35); mix-blend-mode: multiply; }
.ss-color-swatch {
    flex: 0 0 auto; width: 48px; height: 48px; padding: 0; border: 1px solid var(--mud-palette-lines-inputs); border-radius: 12px;
    background: none; cursor: pointer; margin-bottom: 22px;
}
.ss-color-swatch::-webkit-color-swatch-wrapper { padding: 4px; }
.ss-color-swatch::-webkit-color-swatch { border: 0; border-radius: 8px; }
.ss-color-swatch:disabled { opacity: .4; cursor: default; }

@media (prefers-reduced-motion: reduce) {
    .ss-tab .mud-icon-root, .ss-tab.active::before, .ss-tab-badge, .ss-sticky-cta, .mud-dialog, .ss-app-sheet, .ss-app-sheet-icon { animation: none !important; transition: none !important; }
}

/* Ensure fixed background doesn't interfere with overscroll */
.parallax-section {
    background-color: var(--mud-palette-background);
}



/* ===================== Promo Stickers ===================== */
.promo-sticker-layer {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 1250; /* above page content & app widgets, below dialogs/snackbars */
    overflow: visible;
}
.promo-sticker {
    position: absolute;
    pointer-events: auto;
    max-width: 90vw;
    transform-origin: center center;
    user-select: none;
}
.promo-sticker-body {
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    width: 100%;
    overflow: hidden;
    text-decoration: none !important;
    transition: transform .2s ease, filter .2s ease;
}
a.promo-sticker-body:hover { transform: scale(1.05); filter: brightness(1.05); }
.promo-sticker-inner { display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; }
.promo-sticker-img { display: block; height: auto; border-radius: 4px; pointer-events: none; }
.promo-sticker-text { white-space: pre-line; overflow-wrap: anywhere; width: 100%; }

/* Edit-mode chrome */
.promo-sticker.editable { cursor: grab; outline: 2px dashed transparent; outline-offset: 6px; transition: outline-color .15s; }
.promo-sticker.editable:hover, .promo-sticker.editable.dragging { outline-color: var(--mud-palette-warning); }
.promo-sticker.editable.dragging { cursor: grabbing; opacity: .9; }
.promo-sticker.inactive { opacity: .45; filter: grayscale(.6); }
.promo-sticker-tools {
    position: absolute; top: -44px; left: 50%; translate: -50% 0; z-index: 2;
    display: none; gap: 2px; padding: 2px 4px; border-radius: 20px;
    background: var(--mud-palette-surface); box-shadow: 0 4px 14px rgba(0,0,0,.3);
    white-space: nowrap;
}
/* Invisible bridge between the sticker and its toolbar so hover isn't lost crossing the gap */
.promo-sticker-tools::after { content: ""; position: absolute; left: -10px; right: -10px; top: 100%; height: 24px; }
.promo-sticker.editable:hover .promo-sticker-tools,
.promo-sticker.editable.selected .promo-sticker-tools { display: flex; }
.promo-sticker.editable.selected { outline-color: var(--mud-palette-warning); outline-style: solid; }
.promo-sticker.editable.selected .promo-resize { display: block; }
.promo-sticker.editable.selected .promo-rotate { display: flex; }
.promo-sticker.editable.selected, .promo-sticker.editable:hover { z-index: 999 !important; }
.promo-sticker.dragging .promo-sticker-tools { display: none !important; }
.promo-resize {
    position: absolute; right: -8px; bottom: -8px; width: 16px; height: 16px;
    background: var(--mud-palette-warning); border: 2px solid #fff; border-radius: 4px;
    cursor: nwse-resize; display: none;
}
.promo-rotate {
    position: absolute; left: -12px; top: -12px; width: 24px; height: 24px;
    background: var(--mud-palette-warning); color: #fff; border: 2px solid #fff; border-radius: 50%;
    display: none; align-items: center; justify-content: center; cursor: alias;
}
.promo-sticker.editable:hover .promo-resize { display: block; }
.promo-sticker.editable:hover .promo-rotate { display: flex; }
.promo-status, .promo-allpages {
    position: absolute; bottom: -24px; left: 50%; translate: -50% 0;
    font-size: 11px; font-weight: 600; padding: 1px 8px; border-radius: 10px;
    background: #343a40; color: #fff; white-space: nowrap;
}
.promo-allpages { bottom: auto; top: -10px; left: auto; right: -10px; translate: none; padding: 3px; border-radius: 50%; display: flex; background: var(--mud-palette-info); }

/* Animations */
@keyframes promo-pulse { 0%,100% { transform: scale(1); } 50% { transform: scale(1.07); } }
@keyframes promo-wobble { 0%,100% { transform: rotate(0); } 25% { transform: rotate(-5deg); } 75% { transform: rotate(5deg); } }
@keyframes promo-float { 0%,100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes promo-shine { 0% { background-position: -150% 0; } 60%,100% { background-position: 250% 0; } }
.promo-anim-pulse { animation: promo-pulse 2s ease-in-out infinite; }
.promo-anim-wobble { animation: promo-wobble 2.4s ease-in-out infinite; }
.promo-anim-float { animation: promo-float 3s ease-in-out infinite; }
.promo-anim-shine { position: relative; }
.promo-anim-shine::after {
    content: ""; position: absolute; inset: 0; pointer-events: none;
    background: linear-gradient(110deg, transparent 35%, rgba(255,255,255,.55) 50%, transparent 65%) no-repeat;
    background-size: 200% 100%; animation: promo-shine 3s ease-in-out infinite;
}
@media (prefers-reduced-motion: reduce) { .promo-sticker-body, .promo-anim-shine::after { animation: none !important; } }
@media (max-width: 600px) {
    .promo-sticker { max-width: 45vw; }
    .promo-sticker.hide-mobile { display: none; }
}

/* Editor dialog */
.promo-preview-stage {
    display: flex; align-items: center; justify-content: center;
    min-height: 280px; padding: 24px; border-radius: 12px; overflow: hidden;
    background: repeating-conic-gradient(rgba(128,128,128,.12) 0% 25%, transparent 0% 50%) 50% / 20px 20px;
    border: 1px solid var(--mud-palette-lines-default);
}
.promo-color { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; cursor: pointer; }
.promo-color input[type=color] { width: 40px; height: 32px; border: 1px solid var(--mud-palette-lines-default); border-radius: 6px; padding: 2px; background: none; cursor: pointer; }
.promo-swatch {
    width: 36px; height: 36px; border-radius: 50%; border: 3px solid; font-weight: 700; cursor: pointer;
    transition: transform .15s;
}
.promo-swatch:hover { transform: scale(1.12); }

/* --- Seller Store defaults ---------------------------------------------------------------
   Utility classes the store markup relies on (MudBlazor doesn't ship them), and light text
   on photo/parallax sections so a brand-new store reads well before the owner styles anything. */
.text-white { color: #fff !important; }
.parallax-section .parallax-overlay { color: #fff; }

/* Snackbar "View cart" action stays on one line on narrow phones. */
.mud-snackbar .mud-snackbar-action .mud-button-root { white-space: nowrap; }
