:root {
    --mud-palette-appbar-background: rgb(22 22 24) !important;
}

/* Add these styles to control scrollbar behavior */
html, body {
    margin: 0;
    padding: 0;
    overflow: hidden; /* Prevent scrollbars at the document level */
    height: 100%;
    width: 100%;
}

/* Ensure fixed positioning for app bars works correctly */
.mud-appbar.mud-appbar-fixed-top {
    overflow: hidden !important;
}

.mud-appbar.mud-appbar-fixed-bottom {
    overflow: hidden !important;
}

/* Scrollbar styling - only show scrollbars in the content area */
.content-wrapper::-webkit-scrollbar {
    width: 6px;
}

.content-wrapper::-webkit-scrollbar-track {
    background: transparent;
}

.content-wrapper::-webkit-scrollbar-thumb {
    background-color: var(--mud-palette-action-default);
    border-radius: 6px;
}

.validation-message {
    color: #e50000;
}

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIgaGVpZ2h0PSI0OSIvPjwvY2xpcFBhdGg+PC9kZWZzPjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMCkiIHRyYW5zZm9ybT0idHJhbnNsYXRlKC0yMzUgLTUxKSI+PHBhdGggZD0iTTI2My41MDYgNTFDMjY0LjcxNyA1MSAyNjUuODEzIDUxLjQ4MzcgMjY2LjYwNiA1Mi4yNjU4TDI2Ny4wNTIgNTIuNzk4NyAyNjcuNTM5IDUzLjYyODMgMjkwLjE4NSA5Mi4xODMxIDI5MC41NDUgOTIuNzk1IDI5MC42NTYgOTIuOTk2QzI5MC44NzcgOTMuNTEzIDI5MSA5NC4wODE1IDI5MSA5NC42NzgyIDI5MSA5Ny4wNjUxIDI4OS4wMzggOTkgMjg2LjYxNyA5OUwyNDAuMzgzIDk5QzIzNy45OTMgOTkgMjM2IDk3LjA2NTEgMjM2IDk0LjY3ODIgMjM2IDk0LjM3OTkgMjM2LjAzMSA5NC4wODg2IDIzNi4wODkgOTMuODA3MkwyMzYuMzM4IDkzLjAxNjIgMjM2Ljg1OCA5Mi4xMzE0IDI1OS40NzMgNTMuNjI5NCAyNTkuOTYxIDUyLjc5ODUgMjYwLjQwNyA1Mi4yNjU4QzI2MS4yIDUxLjQ4MzcgMjYyLjI5NiA1MSAyNjMuNTA2IDUxWk0yNjMuNTg2IDY2LjAxODNDMjYwLjczNyA2Ni4wMTgzIDI1OS4zMTMgNjcuMTI0NSAyNTkuMzEzIDY5LjMzNyAyNTkuMzEzIDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDg 6Ni4wMTgzIDI2My41ODUgNjYuMDE4M0++b24pID4KPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

.blazor-error-boundary::after {
    content: "An error has occurred."
}

h1:focus {
    outline: none;
}

#blazor-error-ui {
    background: #f5f590 !important;
    color: #000;
    bottom: 0;
    box-shadow: 0 -1px 2px rgba(0, 0, 0, 0.2);
    display: none;
    left: 0;
    padding: 0.6rem 1.25rem 0.7rem 1.25rem;
    position: fixed;
    width: 100%;
    z-index: 1000;
}

#blazor-error-ui .dismiss {
    cursor: pointer;
    position: absolute;
    right: 0.75rem;
    top: 0.5rem;
}

.fb-share-button {
    color: white !important;
    background: #3b5998;
    border-radius: 3px;
    font-weight: 600;
    padding: 5px 8px;
    display: inline-block;
    position: static;
    height: 28px;
    margin-top: auto;
    margin-bottom: auto;
    box-shadow: 0px 3px 1px -2px rgba(0, 0, 0, .2), 0px 2px 2px 0px rgba(0, 0, 0, .14), 0px 1px 5px 0px rgba(0, 0, 0, .12);
}

.fb-share-button:hover {
    cursor: pointer;
    background: #213A6F
}

.fb-share-button svg {
    width: 18px;
    fill: white;
    /* vertical-align: middle; */
    border-radius: 2px
}

.fb-share-button span {
    /* vertical-align: middle; */
    color: white;
    font-size: 14px;
    padding: 0 3px
}

.mysurvey_buttons {
    margin-top: auto;
    margin-bottom: auto;
    height: 28px;
}

.disabled {
    background-color: var(--mud-palette-action-disabled-background) !important;    
    cursor: default;    
}

.d-flex.flex-row.gap-3.ai-style-change-1 {
    gap: 2px;
}

.mud-list-item.mud-list-item-dense.mud-list-item-gutters.ai-style-change-3 {
    width: auto;
    padding-right: 0px;
}

.mud-list-item-text.ai-style-change-6 {
    width: auto;
    margin-left: -14px;
}

svg.mud-icon-root.mud-svg-icon.mud-icon-size-medium.drag-icon.ai-style-change-9 {
    margin-right: -34px;
}

.mud-ripple::after {
    content: unset !important;
}

.dark-mode {
    background-color: var(--mud-palette-background);     
    color: #ffffff;
}

.footer-bar {    
    color: var(--mud-palette-appbar-text) !important;
    padding: 10px;
    text-align: center;
    border-top: 1px solid var(--mud-palette-divider);
}

.app-footer a {
    color: var(--mud-palette-appbar-text) !important;
    text-decoration: none;
    
    font-family: var(--mud-typography-body2-family);
    font-weight: var(--mud-typography-body2-weight);
    line-height: var(--mud-typography-body2-lineheight);
    letter-spacing: var(--mud-typography-body2-letterspacing);
    text-transform: var(--mud-typography-body2-text-transform);
}

.app-footer a:hover {
    text-decoration: underline;
}

/* Responsive footer text sizing */
.footer-text {
    font-size: 0.875rem; /* Default size matching Typo.body2 */
}

@media (min-width: 1251px) {
    
    h1 {
        font-size: 3.2rem !important; /* Smaller size for mobile */
    }

    h2 {
        font-size: 2.9rem !important; /* Smaller size for mobile */
    }

    .youtube-video {
        width: 100%;
        height: 55vh;
        position: relative;
    }
}

@media (max-width: 1250px) {

    h1 {
        font-size: 3.1rem !important; /* Smaller size for mobile */
    }

    h2 {
        font-size: 2.8rem !important; /* Smaller size for mobile */
    }

    .youtube-video {        
        height: 50vh;        
    }
}

@media (max-width: 960px) {
    .footer-text {
        font-size: 0.75rem !important; /* Smaller on medium screens */
    }

    h1 {
        font-size: 3rem !important; /* Smaller size for mobile */
    }

    h2 {
        font-size: 2.7rem !important; /* Smaller size for mobile */
    }

    .youtube-video {       
        height: 48vh;       
    }
}

@media (max-width: 680px) {    
    h1 {
        font-size: 2.7rem !important; /* Smaller size for mobile */
    }

    h2 {
        font-size: 2.6rem !important; /* Smaller size for mobile */
    }

    .youtube-video {
        height: 46vh;
    }
}

@media (max-width: 600px) {
    .footer-text  {
        font-size: 0.7rem !important; /* Even smaller on small screens */
    }

    h1 {
        font-size: 2.5rem !important; /* Smaller size for mobile */
    }

    h2 {
        font-size: 2.4rem !important; /* Smaller size for mobile */
    }

    .youtube-video {
        height: 44vh;
    }
}

@media (max-width: 560px) {    
    h1 {
        font-size: 2.25rem !important; /* Smaller size for mobile */
    }

    h2 {
        font-size: 2rem !important; /* Smaller size for mobile */
    }

    .youtube-video {
        height: 41vh;
    }
}

@media (max-width: 505px) {
    h1 {
        font-size: 2.15rem !important; /* Smaller size for mobile */
    }

    h2 {
        font-size: 1.9rem !important; /* Smaller size for mobile */
    }

    .youtube-video {
        height: 38vh;
    }
}

@media (max-width: 485px) {
    h1 {
        font-size: 2.1rem !important; /* Smaller size for mobile */
    }

    h2 {
        font-size: 1.8rem !important; /* Smaller size for mobile */
    }

    .youtube-video {
        height: 36vh;
    }
}

@media (max-width: 450px) {
    .footer-text  {
        font-size: 0.6rem; /* Even smaller on small screens */
    }

    h1 {
        font-size: 2.0rem !important; /* Smaller size for mobile */
    }

    h2 {
        font-size: 1.8rem !important; /* Smaller size for mobile */
    }

    .youtube-video {
        height: 34vh;
    }
}

@media (max-width: 300px) {
.footer-text  {
    font-size: 0.55rem; /* Even smaller on small screens */
    }

    h1 {
        font-size: 1.6rem !important; /* Smaller size for mobile */
    }

    h2 {
        font-size: 1.5rem !important; /* Smaller size for mobile */
    }

    .youtube-video {
        height: 30vh;
    }
}

/* Survey Page Styles */
.survey-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1.5rem 4rem 1.5rem;
    background-color: var(--mud-palette-surface);
    border-radius: 8px;
    box-shadow: 0 2px 10px var(--survey-container-shadow, rgba(0, 0, 0, 0.1));
    transition: all 0.3s ease;
}

.survey-title {
    margin-bottom: 0.5rem;
    color: var(--survey-title-color, var(--mud-palette-primary));
    border-bottom: 2px solid var(--survey-title-border, var(--mud-palette-primary));
    padding-bottom: 0.5rem;
}

.survey-description {
    margin-bottom: 2rem;
    font-style: italic;
    opacity: 0.9;
}

.question-container {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background-color: var(--survey-question-bg, var(--mud-palette-background));
    border-left: 4px solid var(--survey-question-border, var(--mud-palette-primary));
    border-radius: 4px;
    transition: all 0.3s ease;
}

.question-container:hover {
    box-shadow: 0 4px 12px var(--survey-question-hover-shadow, rgba(0, 0, 0, 0.15));
    transform: translateY(-2px);
}

.question-number {
    font-weight: bold;
    color: var(--survey-question-number-color, var(--mud-palette-primary));
    margin-right: 0.5rem;
}

.question-text {
    font-weight: 500;
    margin-bottom: 1rem;
}

.options-container {
    padding-left: 1rem;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

.rating-options {
    display: flex;
    justify-content: space-between;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    gap: 5px;
}

.rating-option {
    min-width: 35px;
    text-align: center;
}

.captcha-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    margin: 2rem auto;
    max-width: 500px;
    background-color: var(--mud-palette-surface);
    border-radius: 8px;
    box-shadow: 0 2px 8px var(--survey-container-shadow, rgba(0, 0, 0, 0.1));
    transition: all 0.3s ease;
}

/* Enhanced reCAPTCHA styling */
#captcha-container {
    display: flex;
    justify-content: center;
    margin: 1rem 0;
}

.g-recaptcha {
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transform: scale(1);
    transform-origin: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.g-recaptcha:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: scale(1.02);
}

/* Dark mode adjustments for reCAPTCHA */
@media (prefers-color-scheme: dark) {
    .g-recaptcha {
        box-shadow: 0 2px 8px rgba(255, 255, 255, 0.1);
    }
    
    .g-recaptcha:hover {
        box-shadow: 0 4px 12px rgba(255, 255, 255, 0.15);
    }
}

/* Responsive adjustments for reCAPTCHA on small screens */
@media (max-width: 400px) {
    #captcha-container {
        transform: scale(0.9);
        transform-origin: center;
        margin: 0.5rem -15px;
    }
}

.survey-submit-btn {
    margin-top: 2rem;
    min-width: 150px;
    background-color: var(--survey-submit-btn-bg, var(--mud-palette-primary)) !important;
    color: var(--survey-submit-btn-color, #ffffff) !important;
    transition: background-color 0.3s ease !important;
}

.survey-submit-btn:hover:not([disabled]) {
    background-color: var(--survey-submit-hover-bg, var(--mud-palette-primary-darken)) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.survey-alert {
    margin-bottom: 2rem;
}

/* Responsive styles for survey */
@media (max-width: 600px) {
    .survey-container {
        padding: 1.6rem 1rem 4rem 1rem;
    }
    
    .question-container {
        padding: 1rem;
    }
    
    .rating-options {
        justify-content: flex-start;
        gap: 10px;
    }
}

 /* Dark mode adjustments */
 @media (prefers-color-scheme: dark) {
    .survey-action-button:not(.disabled) {
        box-shadow: 0 2px 4px rgba(0,0,0,0.3);
    }
    
    .survey-action-button:not(.disabled):hover {
        box-shadow: 0 4px 8px rgba(0,0,0,0.4);
    }
}

.RequiredStar{
    color: var(--mud-palette-error) !important;
    font-size: 0.8rem !important;
    margin-left: -0.8rem !important;
}

/* on the survey results filter grid, this 
    changes the alignment of the footer content so that it aligns to the top 
    of the cell instead of the center
*/

td.e-summarycell.e-templatecell.e-leftalign {
    vertical-align: top;
}

/* Alternating red/default background color every 0.5s */
.demo-success-border {
    box-shadow: 0 0 0 2px var(--mud-palette-success);
    border-radius: 4px;
    padding: 10px;
}

/* Pulsating demo success border (animated border width without layout shift) */
.demo-success-border {
    position: relative;
    display: block;
}
.demo-success-border::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 2px solid var(--mud-palette-success, #2e7d32);
    border-radius: inherit;
    pointer-events: none;
    box-sizing: border-box;
    /* New pulse that expands both inward (inset) and outward (normal) */
    animation: demo-success-border-pulse-bidirectional 1.3s ease-in-out infinite;
}
@keyframes demo-success-border-pulse-bidirectional {
    0% { 
        box-shadow: 0 0 0 0 var(--mud-palette-success, #2e7d32), inset 0 0 0 0 var(--mud-palette-success, #2e7d32); 
        opacity: 1;
    }
    50% { 
        box-shadow: 0 0 0 6px rgba(46,125,50,0.45), inset 0 0 0 6px rgba(46,125,50,0.90); 
        opacity: .7;
    }
    100% { 
        box-shadow: 0 0 0 0 var(--mud-palette-success, #2e7d32), inset 0 0 0 0 var(--mud-palette-success, #2e7d32); 
        opacity: 1;
    }
}
@media (prefers-reduced-motion: reduce) {
    .demo-success-border::after { animation: none; }
}

/* Pulsating demo primary border (same effect, primary color) */
.demo-primary-border {
    position: relative;
    padding: 5px;
    display: inline-block;
}
    .demo-primary-border::after {
        content: "";
        position: absolute;        
        inset: 0;
        border: 2px solid var(--mud-palette-primary, #1976d2);
        border-radius: inherit;
        pointer-events: none;
        box-sizing: border-box;
        animation: demo-primary-border-pulse-bidirectional 1.3s ease-in-out infinite;
    }
@keyframes demo-primary-border-pulse-bidirectional {
    0% { box-shadow: 0 0 0 0 var(--mud-palette-primary, #1976d2), inset 0 0 0 0 var(--mud-palette-primary, #1976d2); opacity:1; }
    50% { box-shadow: 0 0 0 6px rgba(25,118,210,0.45), inset 0 0 0 6px rgba(25,118,210,0.45); opacity:.7; }
    100% { box-shadow: 0 0 0 0 var(--mud-palette-primary, #1976d2), inset 0 0 0 0 var(--mud-palette-primary, #1976d2); opacity:1; }
}
@media (prefers-reduced-motion: reduce) {
    .demo-primary-border::after { animation: none; }
}

.demo-popup {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
    border: 4px solid var(--mud-palette-primary);
    padding: 4px;
    background-color: var(--mud-palette-surface) !important;
    transition: all 0.3s ease;
}