.app-start-loading {
    display: flex;
    flex-direction: column; /* stack spinner + text vertically */
    align-items: center;
    -webkit-justify-content: inherit;
    justify-content: inherit;
    : flex-start; /* align to top instead of center */
    height: 100vh;
    text-align: center;
    gap: 1rem;
    padding-top: 30vh; /* push it down a bit from the top (adjust as needed) */
}

    .app-start-loading .spinner {
        width: 2rem;
        height: 2rem;
        border: 4px solid #ccc;
        border-top-color: #1e88e5;
        border-radius: 50%;
        animation: spin 1s linear infinite;
    }

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


html, body {
    font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
    height: 100%;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
}

h1:focus {
    outline: none;
}

a, .btn-link {
    color: #0071c1;
}

.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; */ 
    height: 100%; 
}


#blazor-error-ui {
    background: lightyellow;
    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;
    }

.blazor-error-boundary {
    background: url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTYiIGhlaWdodD0iNDkiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIG92ZXJmbG93PSJoaWRkZW4iPjxkZWZzPjxjbGlwUGF0aCBpZD0iY2xpcDAiPjxyZWN0IHg9IjIzNSIgeT0iNTEiIHdpZHRoPSI1NiIga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MyNjEuMDQ5IDg2LjA1NDcgMjU5Ljc4NiA4Ny4zMDA1IDI1OS43ODYgODkuNzkyMSAyNTkuNzg2IDkyLjI4MzcgMjYxLjA0OSA5My41Mjk1IDI2My41NzYgOTMuNTI5NSAyNjYuMTE2IDkzLjUyOTUgMjY3LjM4NyA5Mi4yODM3IDI2Ny4zODcgODkuNzkyMSAyNjcuMzg3IDg3LjMwMDUgMjY2LjExNiA4Ni4wNTQ3IDI2My41NzYgODYuMDU0N1oiIGZpbGw9IiNGRkU1MDAiIGZpbGwtcnVsZT0iZXZlbm9kZCIvPjwvZz48L3N2Zz4=) no-repeat 1rem/1.8rem, #b32121;
    padding: 1rem 1rem 1rem 3.7rem;
    color: white;
}

    .blazor-error-boundary::after {
        content: "An error has occurred."
    }

.loading-progress {
    position: relative;
    display: block;
    width: 8rem;
    height: 8rem;
    margin: 20vh auto 1rem auto;
}

    .loading-progress circle {
        fill: none;
        stroke: #e0e0e0;
        stroke-width: 0.6rem;
        transform-origin: 50% 50%;
        transform: rotate(-90deg);
    }

        .loading-progress circle:last-child {
            stroke: #1b6ec2;
            stroke-dasharray: calc(3.141 * var(--blazor-load-percentage, 0%) * 0.8), 500%;
            transition: stroke-dasharray 0.05s ease-in-out;
        }

.loading-progress-text {
    position: absolute;
    text-align: center;
    font-weight: bold;
    inset: calc(20vh + 3.25rem) 0 auto 0.2rem;
}

    .loading-progress-text:after {
        content: var(--blazor-load-percentage-text, "Loading");
    }

code {
    color: #c02d76;
}

.patient-nav-bar {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 20px;
    background-color: #1D1B20;
    height: 55px;
    overflow: hidden;
}

.header-menu-text {
    font-size: 0.7rem;
}

.header-icon {
    height:25px;
    margin-top: 0.3rem;
    margin-bottom: -10px; 
}

/* Overridable for mobile screen widths */
.search-container {
    position: relative;
    display: inline-block;
    width: 250px;
    margin-right: 40px;
}

.search-input {
    width: 100%;
    padding-left: 20px;
    border-radius: 20px;
    height: 27px;
    font-size: 12px;
}

.navigation-arrow {
    margin-left: 20px;
    height: 15px;
    cursor: pointer;
}

.last-menu-header {
    margin-right: 0.5rem;
}


.header-bar {
    background-color: #2B2F80;
    color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-left: 12px;
    height: 60px; 
    min-height: 60px; 
}

    .header-bar .logo {
        /* style for logo container if needed */
    }

        .header-bar .logo.with-version {
            display:flex; 
            flex-direction: row;
        }

        .header-bar .header-version {
            margin-bottom: .25rem;
            margin-top: auto;
            padding-left: .5rem;
            font-size: .65rem;
            color: lightgray;
        }

    .header-bar .header-menu-items a {
        color: white; /* text color for links */
        margin-left: 20px;
        text-decoration: none;
        font-weight: bold;
    }

        .header-bar .header-menu-items a:hover {
            text-decoration: underline;
        }

.header-menu-items {
    display: flex;
    flex-direction: row;
    align-items: flex-end;
    gap: 20px;
    margin-right: 12px;
}

.side-menu {
    background-color: #1D1B20;
    height: 100%;
    /*width: 155px; */
    width: 75px;
    align-items: center;
    position: sticky;
    top: 0;
}

.nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin-left: -10px;
    height: 60px;
}

.vertically-centered-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.horizontal-container {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
}

.nav-link.active {
    background-color: rgba(255,255,255,0.37);
    color: white;
}

.nav-link.hover {
    background-color: rgba(255,255,255,0.1);
    color: white;
}

.side-menu-text {
    font-size: 12px;
}

thead th {
    height: 10px;
    vertical-align: middle; /* optional, for vertical centering */
    padding: 10px; /* optional, for spacing */
}
/* Add this in your CSS file */
.spinner {
    border: 4px solid rgba(0,0,0,0.1);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border-left-color: #09f;
    animation: spin 1s linear infinite;
}

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

/* Center the loader both vertically and horizontally */
.loading-container-centered {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center; /* Horizontal centering */
    align-items: center; /* Vertical centering */
    /*background-color: rgba(255, 255, 255, 0.8);*/ /* Optional: semi-transparent background overlay */
    z-index: 9999; /* Make sure it appears above other content */
}

/* add to your CSS file */
.scrollable-table-container {
    overflow-y: auto;
    /* height will be set dynamically via Blazor */
}

html, body {
    /*overflow: hidden;*/
    height: 100%;
    margin: 0;
    overflow-y: auto;
}

.modal-overlay {
    position: fixed; /* Cover entire viewport */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5); /* Optional: semi-transparent background */
    display: flex; /* Center content */
    justify-content: center; /* Horizontal center */
    align-items: center; /* Vertical center */
    z-index: 1000; /* Make sure it's on top */
}

.modal-dialog {
    background-color: white; /* Or your preferred background */
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    min-width: 500px;
    max-width: 80%;
}


@media (max-width: 600px) {
    .side-menu {
        background-color: #1D1B20;
        height: 100vh;
        /*width: 155px; */
        width: 58px;
        align-items: center;
        flex-shrink: 0;
    }
}

.layout {
    display: flex;
    flex-direction: column;
    /* height: calc(100% - 8rem); */
    height: 97%;
    background: #f5f5f5;
}

.profile-container img {
    width: 32px;
    height: 24px;
    object-fit: contain;
    vertical-align: middle;
}

.page {
    display: flex;
    flex-direction: column;
    /* height: calc(100% - 8rem); */
    height: 97%;
    background: #f5f5f5;
    margin-top: 1rem;
    
    margin: 0 auto; /* centers the title and content */
    /*width: max-content;*/ /* width will follow the width of the content */

    min-height: calc(100vh - 60px - 32px); /* GluCurveHeader, margin/padding of 16px */
}

    .page .page-title {
        font-size: 2rem;
        font-weight: 600;
        margin-bottom: 18px;
    }

    .page.page-with-patient-header {
        min-height: calc(100vh - 60px - 55px - 32px) !important; /* GlucurveHeader, PatientHeader, , margin/padding of 16px */
    }


.page-container-scroll {
    overflow-y:auto; 
}


.page-with-sidebar {
    width: calc(100vw - 75px); /* screen width - sidebar width - padding (- padding-right) */
}

.page-status {
    width: 100%; 
    height: 100%; 
    display: flex; 
    justify-content: center; 
    align-items: center; 
    z-index: 10; 
    margin: auto;
}

.page-content-spacer {
    flex-shrink: 0;
    height: 24px;
}

.page-content {
    background: #fff;
    /* margin: 2rem auto; */ 
    margin: 0rem auto;
    padding: 2rem;
    max-width: 90%;
    min-width: 60%;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

    .page-content.centered {
        margin-top:auto; 
        margin-bottom: auto;
    }

.page-header {
    margin-left: auto !important;
    margin-right: auto !important;
    background: none !important;
    padding: unset !important;
    box-shadow: unset !important;
}

.pageform {
    border-radius: 8px;
    max-width: 100%;
    margin: 0 0 0 auto;
    font-family: 'Segoe UI', Arial, sans-serif;
}



    .pageform .section {
        /* 
        margin-bottom: 24px; 
        padding-top: 1rem;
        padding-bottom: 1rem;
        */
    }

.pageform .section.title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 12px;
}

    .pageform .row {
        display: flex;
        gap: 24px;
        margin-bottom: 16px;
    }

    .pageform .col {
        flex: 1;
        display: flex;
        flex-direction: column;
    }

    .pageform .col-full {
        flex: 1 1 100%;
        display: flex;
        flex-direction: column;
    }

    .pageform label {
        font-weight: 500;
        margin-bottom: 6px;
    }

.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.18);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    /* REMOVE this line: */
    /* pointer-events: none; */
}

.modal-dialog {
    background: white;
    border-radius: 10px;
    padding: 28px 24px 18px 24px;
    min-width: 500px;
    max-width: 95vw;
    box-shadow: 0 2px 16px rgba(0,0,0,0.12);
    position: relative;
    /* Add this: */
    /* REMOVE this line: */
    /* pointer-events: auto; */
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.modal-title {
    font-size: 1.2rem;
    font-weight: 700;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.3rem;
    cursor: pointer;
    color: #444;
    margin-left: 8px;
}

.modal-subtitle {
    font-size: 1rem;
    color: #444;
    margin-bottom: 18px;
    padding: 0rem 1rem; 
}

.modal-body label {
    font-weight: 500;
    margin-bottom: 6px;
    display: block;
}

.modal-footer {
    display: flex;
    justify-content: flex-start;
    gap: 16px;
    margin-top: 18px;
}

.btn-save {
    background: #ededed;
    color: #888;
}

    .btn-save[disabled] {
        opacity: 0.6;
        cursor: not-allowed;
    }


.main-content {
    /* height: 100%; */
    /* overflow-y: */ auto; /* Enable scrolling for content */
    padding: 1rem;
    min-height: calc(100vh - 60px - 55px) !important
}

/* When modal is open, block all pointer events to the background */
body.modal-open .page,
body.modal-open .pageform,
body.modal-open .main-content, /* add any other main containers if needed */
body.modal-open {
    pointer-events: none;
    user-select: none;
}

    /* Allow pointer events only on the modal */
    body.modal-open .modal-backdrop,
    body.modal-open .modal-dialog {
        pointer-events: auto;
        user-select: auto;
    }

.signup-root {
    background: #f5f5f5;
    min-height: 100vh;
}

.signup-header-bar {
    background: #23236c;
    padding: 1rem 2rem;
}

.signup-logo {
    height: 40px;
}

.signup-content {
    background: #fff;
    margin: 2rem auto;
    padding: 2rem 3rem;
    max-width: 900px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.signup-title {
    margin-top: 0;
}

.signup-subtitle {
    margin-bottom: 2rem;
}

.signup-mandatory {
    color: #d32f2f;
}

.signup-section {
    border: none;
    margin-bottom: 2rem;
    padding: 0;
}

.signup-section-title {
    font-size: 1.2rem;
    font-weight: bold;
    margin-bottom: 1rem;
}

.signup-row {
    display: flex;
    gap: 2rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.signup-col {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 200px;
}

.signup-input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1rem;
    background: #fff;
    margin-bottom: 0;
    box-sizing: border-box;
}

    .signup-input.invalid {
        border: 2px solid #e74c3c !important;
        background-color: #fff6f6;
        outline: 1px solid #e74c3c !important;
    }

    .signup-input,
    .signup-input:focus,
    .signup-input.input-validation-error,
    .signup-input[type="text"],
    .signup-input[type="email"],
    .signup-input[type="password"],
    .signup-input select {
        height: 44px; /* Match your InputText height */
        padding: 8px 12px; /* Match your InputText padding */
        font-size: 1rem; /* Match font size */
        box-sizing: border-box; /* Ensure consistent sizing */
    }

        .signup-input select {
            /* For InputSelect specifically */
            height: 44px;
            padding: 8px 12px;
            font-size: 1rem;
        }

.signup-vet-desc {
    margin-bottom: 1rem;
}

.signup-vet-row {
    align-items: flex-end;
}

    /* Dim the entire readonly block */
    .signup-vet-row.readonly {
        opacity: 0.65; /* subtle dim */
        pointer-events: none; /* ensure no interaction */
    }

        /* Make the disabled inputs not look 'greyed' by the browser, but dimmed by opacity */
        .signup-vet-row.readonly .signup-input {
            background-color: #f9f9f9; /* light grey background */
            color: #555; /* softer text */
            border-color: #ddd; /* lighter border */
        }


.signup-add-btn {
    background: #fff;
    color: #23236c;
    border: 1px solid #23236c;
    border-radius: 4px;
    padding: 0.5rem 1rem;
    margin-top: 0.5rem;
    cursor: pointer;
}

.signup-remove-btn {
    background: #fff;
    color: #d32f2f;
    border: 1px solid #d32f2f;
    border-radius: 4px;
    padding: 0.5rem 1rem;
    cursor: pointer;
    width: fit-content; /* Prevent full width */
    min-width: 0; /* Remove any min-width */
    display: inline-block; /* Prevent block expansion */
    box-sizing: border-box;
}

.signup-login-btn {
    background: #23236c;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 0.75rem 2rem;
    font-size: 1rem;
    margin-top: 2rem;
    cursor: pointer;
}

.signup-submit-btn {
    background: #23236c;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 0.75rem 2rem;
    font-size: 1rem;
    margin-top: 2rem;
    cursor: pointer;
}


.signup-cancel-btn {
    background: #d32f2f;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 0.75rem 2rem;
    font-size: 1rem;
    margin-top: 2rem;
    cursor: pointer; 
}

.standard-btn {
    background: #23236c;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 0.75rem 2rem;
    font-size: 1rem;
    margin-top: 2rem;
    cursor: pointer;
}

.blue-btn {
    background: #23236c;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 0.75rem 2rem;
    font-size: 1rem;
    margin-top: 2rem;
    cursor: pointer;
}

.red-btn {
    background: #d32f2f;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 0.75rem 2rem;
    font-size: 1rem;
    margin-top: 2rem;
    cursor: pointer;
}

    .standard-btn:disabled,
    .signup-submit-btn:disabled,
    .signup-cancel-btn:disabled,
    .signup-login-btn:disabled,
    .blue-btn:disabled,
    .red-btn:disabled {
        background-color: #cccccc !important; /* Gray */
        color: #888 !important;
        cursor: not-allowed !important;
        opacity: 1 !important; /* Ensure color is visible */
    }

    .standard-btn:hover,
    .standard-btn:focus,
    .signup-submit-btn:hover,
    .signup-submit-btn:focus,
    .signup-login-btn:hover,
    .signup-login-btn:focus,
    .blue-btn:hover,
    .blue-btn:focus {
        color: #888 !important; 
    }

    .signup-cancel-btn:hover,
    .signup-cancel-btn:focus,
    .red-btn:hover,
    .red-btn:focus {
        color: #111 !important;
    }



.btn-row {
    display: flex;
    justify-content: flex-start;
    gap: 16px;
    margin-top: 18px;
    margin-bottom: 18px;
}
    
.btn-centered-row {
    display: flex;
    gap: 24px; /* generous spacing between buttons */
    justify-content: center;
    margin-top: 18px;
    margin-bottom: 18px;
}

    .btn-centered-row .btn {
        flex: 1 1 0;
        min-width: 120px; /* optional: ensures reasonable minimum size */
        max-width: 200px; /* optional: prevents buttons from being too wide */
        padding: 0.75rem 0; /* vertical padding, horizontal is handled by flex */
        text-align: center;
    }

.light-blue-btn {
    background: #fff;
    color: #3A318C;
    border: 2px solid #23236c !important;
    border-radius: 4px;
    padding: 0.75rem 2rem;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

    .light-blue-btn:hover,
    .light-blue-btn:focus {
        background: #f3f3ff;
        color: #23236c;
        border-color: #23236c;
    }


    .light-blue-btn:disabled,
    .light-blue-btn:disabled {
        background-color: #cccccc !important; /* Gray */
        border: none !important;
        color: #888 !important;
        cursor: not-allowed !important;
        opacity: 1 !important; /* Ensure color is visible */
    }

.dark-blue-btn {
    background: #23236c;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 0.75rem 2rem;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
}

    .dark-blue-btn:hover,
    .dark-blue-btn:focus {
        background: #3A318C;
        color: #fff;
    }

    .dark-blue-btn:disabled,
    .dark-blue-btn:disabled {
        background-color: #cccccc !important; /* Gray */
        color: #888 !important;
        cursor: not-allowed !important;
        opacity: 1 !important; /* Ensure color is visible */
    }

@media (max-width: 900px) {
    .signup-content {
        padding: 1rem;
    }

    .signup-row {
        flex-direction: column;
        gap: 1rem;
    }

}
    
html, body {
    margin: 0;
    padding: 0;
    height: 100%;
    overflow: hidden;
}

#app {
    height: 100vh;
    overflow: hidden;
}

/* Remove any height: 100vh from your page components */
.container-wrapper {
    display: flex;
    flex-direction: column;
}

.container {
    min-height: 100vh; /* Change from height to min-height */
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: white;
}