/* Font Face Declarations */
@font-face {
    font-family: 'AxmiqRichard';
    src: url('fonts/AxmiqRichardstandart.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
}

/* Fancy Font Weights */
@font-face {
    font-family: 'Fancy';
    src: url('fonts/FancyLight.otf') format('opentype');
    font-weight: 300;
    font-style: normal;
}

@font-face {
    font-family: 'Fancy';
    src: url('fonts/FancyMedium.otf') format('opentype');
    font-weight: 500;
    font-style: normal;
}

@font-face {
    font-family: 'Fancy';
    src: url('fonts/FancyBold.otf') format('opentype');
    font-weight: 700;
    font-style: normal;
}

:root {
    /* Font Families */
    --mud-typography-h1-family: 'Poppins', sans-serif !important;
    --mud-typography-h2-family: 'Poppins', sans-serif !important;
    --mud-typography-h3-family: 'Poppins', sans-serif !important;
    --mud-typography-h4-family: 'Poppins', sans-serif !important;
    --mud-typography-h5-family: 'Poppins', sans-serif !important;
    --mud-typography-h6-family: 'Poppins', sans-serif !important;
    /*    --mud-typography-body1-family: 'Fancy' !important;
    --mud-typography-body2-family: 'Fancy' !important;
    --mud-typography-default-family: 'Fancy' !important;
    --mud-typography-button-family: 'Fancy' !important;*/
    --mud-typography-subtitle1-family: 'Poppins', sans-serif !important;
    --mud-typography-subtitle2-family: 'Poppins', sans-serif !important;
    /*--mud-typography-caption-family: 'Fancy' !important;
    --mud-typography-overline-family: 'Fancy' !important;*/
    /* H1 Styles */
    /*--mud-typography-h1-size: 3.5rem !important;
    --mud-typography-h1-weight: 400 !important;
    --mud-typography-h1-lineheight: 1.2 !important;
    --mud-typography-h1-letterspacing: 0.1em !important;*/
    /* H2 Styles */
    /*--mud-typography-h2-size: 2.5rem !important;
    --mud-typography-h2-weight: 200 !important;
    --mud-typography-h2-lineheight: 1.3 !important;
    --mud-typography-h2-letterspacing: 0.1em !important;*/
    /* H3 Styles */
    /*--mud-typography-h3-size: 2rem !important;
    --mud-typography-h3-weight: 100 !important;
    --mud-typography-h3-lineheight: 1.4 !important;
    --mud-typography-h3-letterspacing: 0.1em !important;*/
    /* H4 Styles */
    /*--mud-typography-h4-size: 1.5rem !important;
    --mud-typography-h4-weight: 200 !important;
    --mud-typography-h4-lineheight: 1.4 !important;
    --mud-typography-h4-letterspacing: 0.1em !important;*/
    /* H5 Styles */
    /*--mud-typography-h5-size: 1.25rem !important;
    --mud-typography-h5-weight: 400 !important;
    --mud-typography-h5-lineheight: 1.5 !important;
    --mud-typography-h5-letterspacing: 0.1em !important;*/
    /* H6 Styles */
    /*--mud-typography-h6-size: 1rem !important;
    --mud-typography-h6-weight: 400 !important;
    --mud-typography-h6-lineheight: 1.5 !important;*/
    /* Body1 Styles */
    /*--mud-typography-body1-size: 1rem !important;
    --mud-typography-body1-weight: 400 !important;
    --mud-typography-body1-lineheight: 1.6 !important;

    --mud-typography-subtitle1-size: 1rem !important;
    --mud-typography-subtitle1-weight: 400 !important;
    --mud-typography-subtitle1-lineheight: 1.6 !important;

    --mud-typography-subtitle2-size: 1.2rem !important;
    --mud-typography-subtitle2-weight: 400 !important;
    --mud-typography-subtitle2-lineheight: 1.6 !important;*/
    /* Body2 Styles */
    /*--mud-typography-body2-size: 0.875rem !important;
    --mud-typography-body2-weight: 400 !important;
    --mud-typography-body2-lineheight: 1.6 !important;*/
    /* Button Styles */
    /*    --mud-typography-button-size: 0.875rem !important;
    --mud-typography-button-weight: 500 !important;
    --mud-typography-button-lineheight: 1.4 !important;
    --mud-typography-button-letterspacing: 0.02em !important;
    --mud-typography-button-text-transform: uppercase !important;
    --mud-typography-default-size: 1rem !important;*/
}
/* Bootstrap Override */
html, body {
    --bs-font-sans-serif: 'Roboto', sans-serif !important;
    --bs-body-font-family: var(--bs-font-sans-serif) !important;
    --bs-body-font-weight: 400 !important;
    --bs-body-line-height: 1.6 !important;
}



/* Utility Classes */
.light-text {
    font-family: 'Fancy', sans-serif;
    font-weight: 300;
}

.medium-text {
    font-family: 'Fancy', sans-serif;
    font-weight: 500;
}

.bold-text {
    font-family: 'Fancy', sans-serif;
    font-weight: 700;
}

.heading-text {
    font-family: 'AxmiqRichard', sans-serif;
    font-weight: 400;
}

/* Specific Aegis Styling */
.aegis-heading {
    font-family: 'AxmiqRichard', sans-serif;
    font-weight: 400;
    font-size: 4rem;
    line-height: 1.1;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.aegis-subheading {
    font-family: 'Fancy', sans-serif;
    font-weight: 300;
    font-size: 1.125rem;
    line-height: 1.5;
    margin-bottom: 2rem;
}

.aegis-body {
    font-family: 'Fancy', sans-serif;
    font-weight: 400;
    font-size: 1rem;
    line-height: 1.6;
    text-align: justify;
}

.aegis-logo-text {
    font-family: 'AxmiqRichard', sans-serif;
    font-weight: 400;
    font-size: 1.5rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
}

/* Responsive Typography */
@media (max-width: 768px) {
    .aegis-heading {
        font-size: 2.5rem;
    }

    :root {
        --mud-typography-h1-size: 2.5rem !important;
        --mud-typography-h2-size: 2rem !important;
        --mud-typography-h3-size: 1.5rem !important;
    }
}

@media (max-width: 480px) {
    .aegis-heading {
        font-size: 2rem;
    }

    :root {
        --mud-typography-h1-size: 2rem !important;
        --mud-typography-h2-size: 1.5rem !important;
        --mud-typography-h3-size: 1.25rem !important;
    }
}

/* Additional Typography Styles */
.text-spacing-wide {
    letter-spacing: 0.1em;
}

.text-spacing-wider {
    letter-spacing: 0.15em;
}

.text-spacing-widest {
    letter-spacing: 0.2em;
}

    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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IDY5LjYxMDIgMjU5LjMzMiA2OS44NjA4IDI1OS4zNzEgNzAuMDg4N0wyNjEuNzk1IDg0LjAxNjEgMjY1LjM4IDg0LjAxNjEgMjY3LjgyMSA2OS43NDc1QzI2Ny44NiA2OS43MzA5IDI2Ny44NzkgNjkuNTg3NyAyNjcuODc5IDY5LjMxNzkgMjY3Ljg3OSA2Ny4xMTgyIDI2Ni40NDggNjYuMDE4MyAyNjMuNTg2IDY2LjAxODNaTTI2My41NzYgODYuMDU0N0MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) 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;
    }

    .color_orange{
        color:orange;
    }
    .gold-accent {
        color: #D4AF37;
    }

    .gold-bg {
        background-color: #D4AF37;
    }

    .gold-border {
        border-color: #D4AF37;
    }

    /* Hover states for gold elements */
    .gold-hover:hover {
        color: #CBB275 !important; /* Light gold for hover */
    }

    .gold-bg-hover:hover {
        background-color: #CBB275 !important; /* Light gold for hover */
    }

    /* Dark theme specific adjustments */
    .mud-theme-dark .gold-text-dark {
        color: #A9824F !important; /* Warm beige in dark mode */
    }

    .mud-theme-dark .gold-bg-dark {
        background-color: #A9824F !important; /* Warm beige in dark mode */
    }

    .mud-theme-dark .mud-typography {
        color: var(--mud-palette-text-primary) !important;
    }

    /* Card surfaces in dark mode */
    .mud-theme-dark .mud-paper {
        background-color: var(--mud-palette-surface) !important;
        border: 1px solid #3B2F22 !important;
    }

    /* Table text contrast */
    .mud-theme-dark .mud-table {
        --mud-palette-table-lines: #3B2F22;
    }

    /* Specific page content contrast */
    .mud-theme-dark .content-page {
        background-color: var(--mud-palette-background);
        color: var(--mud-palette-text-primary);
        padding: 20px;
        border-radius: 8px;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    }

    /* Layout structure */
    .mud-layout {
        height: 100vh;
        background: var(--mud-palette-background) !important;
    }

    /* Mobile AppBar - Hidden on desktop, visible on mobile */
    .mobile-appbar {
        background-color: var(--mud-palette-appbar-background) !important;
        z-index: 1300 !important;
    }

    .mobile-menu-button {
        color: inherit !important;
    }

    .appbar-title {
        font-weight: 600;
        letter-spacing: 0.5px;
    }

    .fix_right {
        transition: transform 0.3s ease;
        position: absolute !important;
        right: 12% !important;
        top: 0% !important;
        z-index: 1400 !important;
    }


    /* Alternative approach using flexbox container (recommended) */
    .top-right-controls {
        position: absolute !important;
        right: 2% !important;
        top: 0% !important;
        z-index: 1400 !important;
        display: flex;
        align-items: center;
        gap: 16px; /* Adjust this value to control spacing */
    }

        .top-right-controls .theme-toggle,
        .top-right-controls .fix_right {
            position: relative !important;
            right: auto !important;
            top: auto !important;
        }

    /* Theme toggle button */
    .theme-toggle {
        transition: transform 0.3s ease;
        position: absolute !important;
        right: 2% !important;
        top: 0% !important;
        z-index: 1400 !important;
    }


        .theme-toggle:hover {
            transform: scale(1.1);
            color: #CBB275 !important; /* Muted gold on hover */
        }


    /* Desktop Drawer - Hidden on mobile, visible on desktop */
    .desktop-drawer {
        background-color: var(--mud-palette-drawer-background) !important;
    }

    /* Mobile Drawer - Overlay style for mobile */
    .mobile-drawer {
        background-color: var(--mud-palette-drawer-background) !important;
        z-index: 12000000 !important;
    }

    .mobile-drawer-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 8px 16px;
        min-height: 64px;
    }

    .close-button {
        margin-left: auto;
    }

    /* Drawer customization */
    .drawer-custom {
        background-color: var(--mud-palette-drawer-background) !important;
    }

    .drawer-header {
        padding: 0 !important;
        background-color: var(--mud-palette-drawer-background) !important;
        min-height: 64px;
        display: flex;
        align-items: center;
        justify-content: start;
    }

.logo-image {
    max-width: 100%;
    height: auto;
    max-height: 100px;
    padding-bottom: 1px;
    filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.8)); 
}


    /* Main content area */
    .main-content {
        background-color: var(--mud-palette-background) !important;
    }

    .content-container {
        background-color: transparent !important;
        padding: 0 !important;
    }

    .content-wrapper {
        background-color: var(--mud-palette-surface) !important;
        --mud-default-borderradius: 20px !important;
        border-radius: var(--mud-default-borderradius) !important;
        box-shadow: var(--mud-elevation-3) !important;
        overflow:hidden !important;
        padding: 24px !important;
        margin: 16px !important;
   
    }



    /* Force text contrast in dark mode */
    .mud-theme-dark .mud-typography,
    .mud-theme-dark .mud-main-content,
    .mud-theme-dark .content-page,
    .mud-theme-dark .mud-card,
    .mud-theme-dark .mud-table,
    .mud-theme-dark .mud-input,
    .mud-theme-dark .mud-input-control > .mud-input-control-input-container > .mud-input-label {
        color: var(--mud-palette-text-primary) !important;
    }

        /* Fix input borders */
        .mud-theme-dark .mud-input:not(.mud-input-error):not(.mud-input-outlined):not(.mud-input-underline).mud-input-text {
            border-bottom: 1px solid #A9824F !important;
        }

        /* Fix table rows */
        .mud-theme-dark .mud-table tr {
            background-color: #1E1E1E !important;
        }

            .mud-theme-dark .mud-table tr:hover {
                background-color: #2A2118 !important;
            }

    /* Fix paper/card components */
    .mud-theme-dark .mud-paper {
        border: 1px solid #3B2F22 !important;
    }

    /* Fix disabled states */
    .mud-theme-dark .mud-disabled {
        opacity: 1 !important;
    }

    .mud-main-content {
        --mud-appbar-height: 35px !important;
    }

    /* Responsive Design - Mobile First Approach */
    /* Mobile devices (default) */
    .desktop-drawer {
        display: none !important;
    }

    .mobile-appbar {
        display: flex !important;
    }

    .mud-main-content {
        padding-top: 64px !important; /* Account for mobile appbar */
    }

    /* Tablet and Desktop (md and up) */
    @media only screen and (min-width: 960px) {
        .desktop-drawer {
            display: flex !important;
        }

        .mobile-appbar {
            display: none !important;
        }

        .mobile-drawer {
            display: none !important;
        }

        .mud-main-content {
            padding-top: var(--mud-appbar-height) !important;
        }
    }

    /* Tablet specific adjustments */
    @media only screen and (max-width: 959px) {
        .content-wrapper {
            margin: 8px !important;
            padding: 16px !important;
        }

        .theme-toggle {
            right: 2% !important;
            top: 0% !important;
        
        }
    }

    /* Small mobile devices */
    @media only screen and (max-width: 800px) {
        .content-wrapper {
            margin: 4px !important;
            padding: 12px !important;
            border-radius: 12px !important;
        }

        .mobile-drawer-header {
            padding: 4px 12px;
        }
        .mud-drawer-open-persistent-left:not(.mud-drawer-open-persistent-right) .mud-main-content {
            --mud-drawer-width-left:0 !important;
                margin-left: var(--mud-drawer-width-left);
        }
        .mud-drawer-open-persistent-left.mud-drawer-left-clipped-never .mud-appbar {
            --mud-drawer-width-left:0 !important;
            margin-left: var(--mud-drawer-width-left);
            width: calc(100% - var(--mud-drawer-width-left));
        }
        .theme-toggle {
            right: 1% !important;
            top: 4% !important;
      
        }
    }

    .button_hover {
        transition: all 0.3s ease !important;
        border-radius:20px !important;
    }

        .button_hover:hover {
            transform: translateY(-2px) !important;
            box-shadow: 0 6px 16px rgba(255, 149, 0, 0.4) !important;
        }

    @media only screen and (max-width: 800px) {
        .theme-toggle {
            right: 2% !important;
            top: 0% !important;
       
        }
    }
    .card_restrict {
        max-height: calc(100vh - 120px) !important;
        min-height: calc(100vh - 120px) !important;
        position: relative !important;
        height: 100% !important;
    }

    .mud-table-cell {
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    /*.mud-table-cell {
   
        padding: 12px !important;
  
    }
    .mud-input > input.mud-input-root-outlined, div.mud-input-slot.mud-input-root-outlined
    {
        padding: 14px 4px !important;
    }*/

    /*Scroll bar*/

    .sticky-header {
        position: sticky;
        top: 0;
        z-index: 1;
        box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    }

    .scrollable-content {
        flex: 1;
        overflow-y: auto;
        padding-bottom: 16px; /* Add some padding at bottom */
    }

        /* Optional: Add a fade effect at bottom */
        .scrollable-content::after {
            content: '';
            position: sticky;
            bottom: 0;
            left: 0;
            right: 0;
            height: 20px;
            background: linear-gradient(to bottom, rgba(var(--mud-palette-background-rgb), 0), rgba(var(--mud-palette-background-rgb), 1));
            pointer-events: none;
        }



    .postion_footer_button {
        position: absolute;
        bottom: 0;
        left: 0;
        right: 1.8%;
        padding: 8px;
        background: var(--mud-palette-surface) !important;
    }

    .mud-popover .mud-list {
        max-height: inherit;
        overflow-y: auto;
        max-height: 200px !important;
        border-radius:20px !important;
    }

    .mud-button-text.mud-button-text-secondary {
        color: var(--mud-palette-secondary) !important;
        --mud-ripple-color: var(--mud-palette-secondary) !important;
        background-color: rgba(var(--mud-palette-secondary-rgb), 0.1) !important;
    }

