@import '_content/LiveEventBingo.Shared/LiveEventBingo.Shared.mppprnitun.bundle.scp.css';
@import '_content/ZXingBlazor/ZXingBlazor.bundle.scp.css';

/* /Components/ReconnectModal.razor.rz.scp.css */
/* #8650 -- public-host Blazor reconnect modal styling.
   Ported from MyEventBingoAdmin/Components/Layout/ReconnectModal.razor.css and re-themed
   onto PUBLIC palette tokens (the admin-scoped --meb-*-admin-reconnect-* tokens do not
   exist in theme-default.css). Token-only: no raw hex / shadow / border literals.

   Scoped CSS is correct here even though the framework toggles the state classes at
   runtime: the <dialog> and its children are authored in ReconnectModal.razor, so they
   carry the scope attribute and these selectors match. The framework only adds/removes
   classes on that existing element; it never re-renders the subtree. */

.components-reconnect-first-attempt-visible[b-udsrpmg7k0],
.components-reconnect-repeated-attempt-visible[b-udsrpmg7k0],
.components-reconnect-failed-visible[b-udsrpmg7k0],
.components-pause-visible[b-udsrpmg7k0],
.components-resume-failed-visible[b-udsrpmg7k0],
.components-rejoining-animation[b-udsrpmg7k0] {
    display: none;
}

#components-reconnect-modal.components-reconnect-show .components-reconnect-first-attempt-visible[b-udsrpmg7k0],
#components-reconnect-modal.components-reconnect-show .components-rejoining-animation[b-udsrpmg7k0],
#components-reconnect-modal.components-reconnect-paused .components-pause-visible[b-udsrpmg7k0],
#components-reconnect-modal.components-reconnect-resume-failed .components-resume-failed-visible[b-udsrpmg7k0],
#components-reconnect-modal.components-reconnect-retrying[b-udsrpmg7k0],
#components-reconnect-modal.components-reconnect-retrying .components-reconnect-repeated-attempt-visible[b-udsrpmg7k0],
#components-reconnect-modal.components-reconnect-retrying .components-rejoining-animation[b-udsrpmg7k0],
#components-reconnect-modal.components-reconnect-failed[b-udsrpmg7k0],
#components-reconnect-modal.components-reconnect-failed .components-reconnect-failed-visible[b-udsrpmg7k0] {
    display: block;
}

#components-reconnect-modal[b-udsrpmg7k0] {
    background-color: var(--meb-surface-modal);
    color: var(--meb-text-default);
    width: 20rem;
    max-width: calc(100vw - var(--meb-space-stack-xl));
    margin: 20vh auto;
    padding: var(--meb-space-stack-xl);
    border: 0;
    border-radius: var(--meb-radius-md);
    box-shadow: var(--meb-shadow-modal);
    opacity: 0;
    transition: display 0.5s allow-discrete, overlay 0.5s allow-discrete;
    animation: components-reconnect-modal-fadeOutOpacity-b-udsrpmg7k0 0.5s both;
}

    #components-reconnect-modal[open][b-udsrpmg7k0] {
        animation: components-reconnect-modal-slideUp-b-udsrpmg7k0 1.5s cubic-bezier(.05, .89, .25, 1.02) 0.3s, components-reconnect-modal-fadeInOpacity-b-udsrpmg7k0 0.5s ease-in-out 0.3s;
        animation-fill-mode: both;
    }

#components-reconnect-modal[b-udsrpmg7k0]::backdrop {
    background-color: var(--meb-surface-overlay-backdrop);
    animation: components-reconnect-modal-fadeInOpacity-b-udsrpmg7k0 0.5s ease-in-out;
    opacity: 1;
}

@keyframes components-reconnect-modal-slideUp-b-udsrpmg7k0 {
    0% {
        transform: translateY(30px) scale(0.95);
    }

    100% {
        transform: translateY(0);
    }
}

@keyframes components-reconnect-modal-fadeInOpacity-b-udsrpmg7k0 {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

@keyframes components-reconnect-modal-fadeOutOpacity-b-udsrpmg7k0 {
    0% {
        opacity: 1;
    }

    100% {
        opacity: 0;
    }
}

.components-reconnect-container[b-udsrpmg7k0] {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--meb-space-stack-md);
}

#components-reconnect-modal p[b-udsrpmg7k0] {
    margin: var(--meb-space-stack-none);
    text-align: center;
}

#components-reconnect-modal button[b-udsrpmg7k0] {
    border: 0;
    background-color: var(--meb-surface-cta-background);
    color: var(--meb-text-inverse);
    padding: var(--meb-space-stack-xs) var(--meb-space-stack-lg);
    border-radius: var(--meb-radius-sm);
    cursor: pointer;
}

    /* No dedicated CTA-hover token on the public surface; brighten the navy via filter
       rather than invent a hex literal. */
    #components-reconnect-modal button:hover[b-udsrpmg7k0] {
        filter: brightness(1.12);
    }

    #components-reconnect-modal button:active[b-udsrpmg7k0] {
        filter: none;
    }

.components-rejoining-animation[b-udsrpmg7k0] {
    position: relative;
    width: 80px;
    height: 80px;
}

    .components-rejoining-animation div[b-udsrpmg7k0] {
        position: absolute;
        border: var(--meb-border-width-lg) solid var(--meb-border-accent);
        opacity: 1;
        border-radius: var(--meb-radius-full);
        animation: components-rejoining-animation-b-udsrpmg7k0 1.5s cubic-bezier(0, 0.2, 0.8, 1) infinite;
    }

        .components-rejoining-animation div:nth-child(2)[b-udsrpmg7k0] {
            animation-delay: -0.5s;
        }

@keyframes components-rejoining-animation-b-udsrpmg7k0 {
    0% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 0;
    }

    4.9% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 0;
    }

    5% {
        top: 40px;
        left: 40px;
        width: 0;
        height: 0;
        opacity: 1;
    }

    100% {
        top: 0px;
        left: 0px;
        width: 80px;
        height: 80px;
        opacity: 0;
    }
}
