:root {
    --app-theme-color: #512bd4;
    --app-background-color: white;
    --app-font-size: 16px;
}

/* Container positioned near the top of the viewport */
.top-loader-container {
    position: fixed;
    top: 10vh; /* Places it 10% down from the very top */
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    z-index: 9999;
    font-family: system-ui, -apple-system, sans-serif;
}

/* Dots layout and animation alignment */
.dot-loader {
    display: flex;
    gap: 6px;
}

.dot {
    width: 15px;
    height: 15px;
    background-color: var(--app-theme-color); /* Change to your theme color */
    border-radius: 50%;
    animation: dotBounce 1.4s infinite ease-in-out both;
}

/* Staggered animation delays for the wave effect */
.dot:nth-child(1) {
    animation-delay: -0.32s;
}

.dot:nth-child(2) {
    animation-delay: -0.16s;
}

/* Pulsing text style utilizing native Blazor progress tracking */
.pulse-text {
    font-size: 1rem;
    font-weight: 500;
    color: #333;
    letter-spacing: 0.5px;
}

/* Keyframe Animations */
@keyframes dotBounce {
    0%, 80%, 100% {
        transform: scale(0);
    }

    40% {
        transform: scale(1);
    }
}

html, body {
    font-size: var(--app-font-size);
    background-color: var(--app-background-color);
    width: 100%;
    overscroll-behavior: none;
}

.nav-menu-row-header {
    display: flex;
    justify-content: space-between;
    flex-direction: row;
}

.nav-menu-title {
    font-size: 18px;
    letter-spacing: 2px;
    margin: auto 20px;
}

.mud-nav-link.active {
    background-color: transparent !important;
    color: var(--mud-palette-text-primary) !important;
}

.nav-item-group {
    display: flex;
    flex-direction: column;
}

.nav-item-header {
    font-weight: 800;
}

.nav-item-description {
    font-size: 14px;
    color: #666;
}

/* Force the root layouts to fill the viewport */
.mud-layout,
.mud-main-content {
    min-height: 100vh; /* Or 100dvh for better mobile browser support */
    display: flex;
    flex-direction: column;
}

/* Ensure the wrapper inside MudMainContent fills all remaining space */
.mud-main-content > .mud-container {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.mud-dialog-container {
    height: 100dvh !important;
    max-height: 100dvh !important;
}

.mud-dialog:not(.mud-dialog-fullscreen) {
    width: 90vw;
    max-width: 90vw;
    max-height: 60dvh;
    padding: 0;
    margin: 16px;
}

.mud-dialog:not(.mud-dialog-fullscreen) .mud-dialog-title {
    padding: 16px 16px 0 16px;
}

.mud-dialog:not(.mud-dialog-fullscreen) .mud-dialog-content {
    padding: 16px 16px 8px 16px;
}

.mud-dialog:not(.mud-dialog-fullscreen) .mud-dialog-actions {
    padding: 0 16px 16px 16px;
    justify-content: flex-end;
    flex-direction: row;
    gap: 8px;
}

.dialog-vertical-buttons {
    display: flex;
    flex-direction: column;
    width: 100%;
    justify-content: stretch;
    gap: 8px;
}

.mud-dialog.mud-dialog-fullscreen {
    margin: 0;
    padding: 0;
}

/* Hide the dialog title/header only when the dialog is full screen */
.mud-dialog-fullscreen .mud-dialog-title {
    margin: 0;
    padding: 0;
}

.mud-dialog-fullscreen .mud-dialog-content {
    margin: 0;
    padding: 0;
}

.mud-dialog .mud-dialog-content {
    overflow-y: auto;
}

.dialog-buttons-container {
    display: flex;
    flex-direction: column;
    justify-content: stretch;
    align-items: stretch;
    gap: 12px;
}

.mud-select .mud-input-slot, .mud-select .mud-input-label {
    font-size: 14px !important;
}

.mud-switch .mud-typography {
    font-size: 14px !important;
}

.mud-popover-provider .mud-list-item .mud-list-item-text .mud-typography {
    font-size: 0.85rem !important;
}

hr {
    border: none;
    height: 1px;
    background-color: #ccc;
}

.all-movies {
    display: flex;
    flex-direction: column;
    margin: 8px 0 6px 0;
    gap: 6px;
}