/* Loading Animation */
.dot-flashing {
    position: relative;
    width: .75rem;
    height: .75rem;
    border-radius: 999px;
    background-color: var(--primary);
    color: var(--primary);
    animation: dot-flashing 1s infinite linear alternate;
    animation-delay: 0.5s;
}

.dot-flashing::before, .dot-flashing::after {
    content: "";
    display: inline-block;
    position: absolute;
    top: 0;
}

.dot-flashing::before {
    left: -1rem;
    width: .75rem;
    height: .75rem;
    border-radius: 999px;
    background-color: var(--primary);
    color: var(--primary);
    animation: dot-flashing 1s infinite alternate;
    animation-delay: 0s;
}

.dot-flashing::after {
    left: 1rem;
    width: .75rem;
    height: .75rem;
    border-radius: 999px;
    background-color: var(--primary);
    color: var(--primary);
    animation: dot-flashing 1s infinite alternate;
    animation-delay: 1s;
}
  
@keyframes dot-flashing {
    0% {
      background-color: var(--primary);
    }
    50%, 100% {
      background-color: var(--badge-border);
    }
}

/* Subscription Loading Animation */
.loading-screen {
    display: none;
    position: fixed;
    inset: 0;
    background-color: #fbfafff2;
    backdrop-filter: blur(4px);
    justify-content: center;
    align-items: center;
    z-index: 10000;
}

.loader-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    width: 100%;
    max-width: 28rem;
    padding: 0 1.5rem;
    transform: scale(1.25);
    transition: all .2s ease-in-out;
}

.spinner {
    width: 5rem;
    height: 5rem;
    border-radius: 50%;
    box-sizing: border-box;

    /* Create a two-tone ring using border */
    border: .25rem solid #ac3bed;
    border-left-color: #ac3bed33;

    animation: spin 1s linear infinite;
}

.spinner-header {
    background-image: linear-gradient(135deg, hsl(278 83% 58%), hsl(250 40% 22%));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-size: 1.5rem;
    line-height: 2rem;
    font-weight: 700;
    margin-top: 1.5rem;
    margin-bottom: .5rem;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica Neue, Arial, Noto Sans, sans-serif;
    letter-spacing: -.025rem;
}

.spinner-subheader {
    color: #6a5c8a;
    letter-spacing: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica Neue, Arial, Noto Sans, sans-serif;
    font-weight: normal;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

@media (max-width: 34.375rem) {
    .loader-container {
        transform: scale(1);
    }
}
