@import '_content/PSC.Blazor.Components.MarkdownEditor/PSC.Blazor.Components.MarkdownEditor.bundle.scp.css';

/* /Components/Layout/LoadingSpinner.razor.rz.scp.css */
/* Used under CC0 license */

.lds-ellipsis[b-tvt4n9d124] {
    color: var(--accent-primary);
    /* Theme-aware color */
    animation: fade-in-b-tvt4n9d124 1s;
}

/* Light theme - ensure spinner is visible on light background */
[data-theme="light"] .lds-ellipsis[b-tvt4n9d124] {
    color: #6b7280 !important;
}

/* Dark theme - use lighter color for better visibility */
[data-theme="dark"] .lds-ellipsis[b-tvt4n9d124],
:root:not([data-theme]) .lds-ellipsis[b-tvt4n9d124] {
    color: var(--accent-primary) !important;
}

@keyframes fade-in-b-tvt4n9d124 {
    0% {
        opacity: 0;
    }

    100% {
        opacity: 1;
    }
}

.lds-ellipsis[b-tvt4n9d124],
.lds-ellipsis div[b-tvt4n9d124] {
    box-sizing: border-box;
}

.lds-ellipsis[b-tvt4n9d124] {
    margin: auto;
    display: block;
    position: relative;
    width: 80px;
    height: 80px;
}

.lds-ellipsis div[b-tvt4n9d124] {
    position: absolute;
    top: 33.33333px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: currentColor;
    animation-timing-function: cubic-bezier(0, 1, 1, 0);
}

.lds-ellipsis div:nth-child(1)[b-tvt4n9d124] {
    left: 8px;
    animation: lds-ellipsis1-b-tvt4n9d124 0.6s infinite;
}

.lds-ellipsis div:nth-child(2)[b-tvt4n9d124] {
    left: 8px;
    animation: lds-ellipsis2-b-tvt4n9d124 0.6s infinite;
}

.lds-ellipsis div:nth-child(3)[b-tvt4n9d124] {
    left: 32px;
    animation: lds-ellipsis2-b-tvt4n9d124 0.6s infinite;
}

.lds-ellipsis div:nth-child(4)[b-tvt4n9d124] {
    left: 56px;
    animation: lds-ellipsis3-b-tvt4n9d124 0.6s infinite;
}

@keyframes lds-ellipsis1-b-tvt4n9d124 {
    0% {
        transform: scale(0);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes lds-ellipsis3-b-tvt4n9d124 {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(0);
    }
}

@keyframes lds-ellipsis2-b-tvt4n9d124 {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(24px, 0);
    }
}
/* /Components/Layout/MainLayout.razor.rz.scp.css */
/* Error UI - Hidden by default, shown on unhandled errors */
#blazor-error-ui[b-bgk3dih10r] {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9998;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

#blazor-error-ui.show[b-bgk3dih10r] {
    display: flex;
    align-items: center;
    justify-content: center;
}

#blazor-error-ui .dismiss[b-bgk3dih10r] {
    cursor: pointer;
}
/* /Components/Layout/SurveyPrompt.razor.rz.scp.css */
.surveyContainer[b-gghvdzk2ew] {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    font-size: 0.9em;
    margin: 0.5rem auto -0.7rem auto;
    max-width: 1024px;
    color: #444;
}

    .surveyContainer a[b-gghvdzk2ew] {
        text-decoration: underline;
    }

    .surveyContainer .tool-icon[b-gghvdzk2ew] {
        margin-top: 0.15rem;
        width: 1.25rem;
        height: 1.25rem;
        flex-shrink: 0;
    }
/* /Components/Pages/Chat/AyraChat.razor.rz.scp.css */
.user-avatar[b-9p6p4qp209],
.ai-avatar[b-9p6p4qp209] {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* Clear chat button */
.btn-outline-secondary[b-9p6p4qp209] {
    color: var(--text-secondary);
    border-color: var(--border-color);
    background-color: transparent;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem;
    transition: all 0.2s ease;
}

.btn-outline-secondary:hover[b-9p6p4qp209] {
    background-color: var(--bg-hover);
}

.user-avatar svg[b-9p6p4qp209] {
    color: var(--text-secondary);
}

.ai-avatar img[b-9p6p4qp209] {
    border-radius: 4px;
    object-fit: contain;
}

/* Chat mode indicator */
.chat-mode-indicator[b-9p6p4qp209] {
    margin-top: 0.5rem;
    padding: 0.25rem 0.5rem;
    border-radius: 6px;
    background-color: var(--surface-color);
    border: 1px solid var(--border-color);
    display: inline-block;
}

.chat-mode-indicator small[b-9p6p4qp209] {
    font-size: 0.75rem;
    color: var(--text-secondary);
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.chat-mode-indicator i[b-9p6p4qp209] {
    opacity: 0.7;
}
/* /Components/Pages/Cloudbooks/CloudbookViewer.razor.rz.scp.css */
/* Cloudbook viewer scoped styles */
.cloudbook-viewer-container[b-uimaesebah] {
    width: 100%;
    margin-top: -64px;
    padding-top: calc(env(safe-area-inset-top, 0px));
    height: 100vh;
    height: 100dvh;
    height: -webkit-fill-available;
    overflow: hidden;
    background: var(--mud-palette-background);
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    /* iOS safe area support */
    padding-bottom: env(safe-area-inset-bottom, 0px);
}

/* Target MudAppBar inside this component */
[b-uimaesebah] .mud-appbar {
    background: var(--mud-palette-appbar-background) !important;
    color: var(--mud-palette-appbar-text) !important;
    /* iOS safe area for notch */
    padding-top: env(safe-area-inset-top, 0px);
    padding-left: env(safe-area-inset-left, 0px);
    padding-right: env(safe-area-inset-right, 0px);
    z-index: 2000;
}

.pdf-viewer-content[b-uimaesebah] {
    flex: 1 1 auto;
    height: 100%;
    background: var(--mud-palette-background);
    min-height: 0;
    overflow: hidden;
}

.pdf-viewer-layout[b-uimaesebah] {
    display: flex;
    height: 100%;
    background: var(--mud-palette-surface);
    overflow: hidden;
    min-height: 0;
}

.bookmark-panel[b-uimaesebah] {
    flex: 0 0 320px;
    max-width: 320px;
    background: var(--mud-palette-surface);
    border-right: 1px solid var(--mud-palette-divider);
    color: var(--mud-palette-text-primary);
    display: flex;
    flex-direction: column;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.35);
    z-index: 2;
    min-height: 0;
}

.bookmark-panel-header[b-uimaesebah] {
    display: flex;
    flex-direction: column;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--mud-palette-divider);
    background: rgba(0, 0, 0, 0.08);
    gap: 0.5rem;
}

.bookmark-header-row[b-uimaesebah] {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    position: relative;
}

.bookmark-panel-title[b-uimaesebah] {
    font-family: 'Roboto Condensed', sans-serif !important;
    font-weight: 700 !important;
}

.bookmark-close[b-uimaesebah] {
    position: absolute;
    right: 0;
}

/* Customize MudTextField in bookmark panel */
[b-uimaesebah] .bookmark-search .mud-input-control {
    margin-top: 0;
}

[b-uimaesebah] .bookmark-search .mud-input-outlined-border {
    border-color: var(--mud-palette-lines-inputs) !important;
}

[b-uimaesebah] .bookmark-search .mud-input-root:hover .mud-input-outlined-border {
    border-color: var(--mud-palette-text-secondary) !important;
}

[b-uimaesebah] .bookmark-search .mud-input-root.mud-input-focused .mud-input-outlined-border {
    border-color: var(--mud-palette-primary) !important;
}

[b-uimaesebah] .bookmark-search input {
    color: var(--mud-palette-text-primary) !important;
    font-size: 0.85rem;
}

[b-uimaesebah] .bookmark-search .mud-input-adornment-start {
    color: var(--mud-palette-text-secondary) !important;
}

.bookmark-panel-body[b-uimaesebah] {
    flex: 1;
    overflow-y: auto;
    padding: 0.75rem 1rem 1rem;
}

.bookmark-tree[b-uimaesebah],
.bookmark-children[b-uimaesebah] {
    list-style: none;
    margin: 0;
    padding: 0;
}

.bookmark-node[b-uimaesebah] {
    margin-bottom: 0.25rem;
}

.bookmark-node-header[b-uimaesebah] {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.125rem 0;
    border-radius: 4px;
}

.bookmark-node-header:hover[b-uimaesebah] {
    background: rgba(128, 128, 128, 0.08);
}

.bookmark-toggle[b-uimaesebah] {
    width: 1.5rem;
    height: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    border: none;
    background: transparent;
    color: var(--mud-palette-text-secondary);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.5s ease-in-out;
    flex-shrink: 0;
}

.bookmark-toggle:hover[b-uimaesebah] {
    background: rgba(128, 128, 128, 0.15);
    color: var(--mud-palette-text-primary);
}

.bookmark-toggle.placeholder[b-uimaesebah] {
    cursor: default;
    opacity: 0;
}

.bookmark-title[b-uimaesebah] {
    flex: 1;
    text-align: left;
    border: none;
    background: transparent;
    color: var(--mud-palette-text-primary);
    font-size: 0.9rem;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    transition: all 0.5s ease-in-out;
    display: flex;
    align-items: center;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.bookmark-title:not(.disabled):hover[b-uimaesebah] {
    color: var(--mud-palette-text-primary);
    background: rgba(128, 128, 128, 0.08);
}

.bookmark-title.disabled[b-uimaesebah] {
    color: var(--mud-palette-text-disabled);
    cursor: default;
}

.bookmark-icon[b-uimaesebah] {
    display: inline-flex;
    align-items: center;
    color: #fbbf24;
    /* Amber-400 for folders */
    margin-right: 0.5rem;
    opacity: 0.8;
}

.bookmark-page[b-uimaesebah] {
    font-size: 0.75rem;
    color: var(--mud-palette-text-secondary);
    margin-left: 0.5rem;
}

.bookmark-children[b-uimaesebah] {
    margin-left: 1.25rem;
    padding-left: 0.75rem;
    border-left: 1px solid var(--mud-palette-divider);
}

.bookmark-loading[b-uimaesebah] {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.viewer-surface[b-uimaesebah] {
    flex: 1 1 auto;
    background: #525659;
    position: relative;
    overflow: auto;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding: 0 0 24px;
    min-height: 0;
    /* iOS momentum scrolling */
    -webkit-overflow-scrolling: touch;
}

.pdf-viewer-wrapper[b-uimaesebah] {
    height: 100%;
}

.pdf-canvas[b-uimaesebah] {
    border: 1px solid #000;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    margin-top: 0;
}

.cloudbook-title[b-uimaesebah] {
    max-width: 30%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: 0.875rem !important;
    line-height: 1.3;
}

[b-uimaesebah] .drm-badge {
    color: #ffa726 !important;
    background: rgba(255, 167, 38, 0.15) !important;
    border-radius: 50%;
    margin-left: 8px;
    animation: drm-pulse-b-uimaesebah 2s ease-in-out infinite;
}

[b-uimaesebah] .drm-badge:hover {
    background: rgba(255, 167, 38, 0.3) !important;
}

@keyframes drm-pulse-b-uimaesebah {
    0%, 100% { box-shadow: 0 0 0 0 rgba(255, 167, 38, 0.4); }
    50% { box-shadow: 0 0 0 6px rgba(255, 167, 38, 0); }
}

.page-navigator[b-uimaesebah] {
    display: flex;
    align-items: center;
    gap: 4px;
    margin: 0 0.5rem;
}

.page-input-wrapper[b-uimaesebah] {
    display: flex;
    align-items: center;
    gap: 2px;
}

.page-bracket[b-uimaesebah] {
    color: var(--mud-palette-text-secondary);
    font-size: 1.1rem;
    font-weight: 500;
}

.page-number-input[b-uimaesebah] {
    width: 50px;
    text-align: center;
    background: transparent;
    border: none;
    color: inherit;
    font-size: 0.95rem;
    padding: 2px 4px;
    outline: none;
    appearance: textfield;
    -moz-appearance: textfield;
}

.page-number-input[b-uimaesebah]::-webkit-inner-spin-button,
.page-number-input[b-uimaesebah]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.page-number-input:focus[b-uimaesebah] {
    background: rgba(128, 128, 128, 0.1);
    border-radius: 2px;
}

.page-of[b-uimaesebah] {
    color: var(--mud-palette-text-secondary);
    font-size: 0.9rem;
    margin: 0 4px;
}

.page-total-count[b-uimaesebah] {
    color: var(--mud-palette-text-primary);
    font-size: 0.95rem;
    min-width: 30px;
    text-align: left;
}

.mobile-page-input[b-uimaesebah] {
    display: flex;
    align-items: center;
    gap: 2px;
}

.mobile-page-input span[b-uimaesebah] {
    color: var(--mud-palette-text-secondary);
    font-size: 1rem;
}

.mobile-page-input input[b-uimaesebah] {
    width: 45px;
    text-align: center;
    background: rgba(128, 128, 128, 0.1);
    border: 1px solid var(--mud-palette-lines-inputs);
    border-radius: 4px;
    color: inherit;
    font-size: 0.9rem;
    padding: 4px;
    appearance: textfield;
    -moz-appearance: textfield;
}

.mobile-page-input input[b-uimaesebah]::-webkit-inner-spin-button,
.mobile-page-input input[b-uimaesebah]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.desktop-controls[b-uimaesebah] {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.mobile-menu[b-uimaesebah] {
    display: none;
    align-items: center;
    position: relative;
}

[b-uimaesebah] .mobile-menu-popover {
    position: absolute !important;
    right: 0;
    top: 100%;
    z-index: 1300;
}

.mobile-menu-content[b-uimaesebah] {
    min-width: 280px;
    max-width: 320px;
    padding: 16px;
    padding-bottom: calc(16px + env(safe-area-inset-bottom, 0px));
    background: var(--mud-palette-surface);
    border-radius: 4px;
    box-shadow: var(--mud-elevation-8);
    max-height: 80vh;
    overflow-y: auto;
    /* iOS momentum scrolling */
    -webkit-overflow-scrolling: touch;
}

.mobile-menu-section[b-uimaesebah] {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mobile-menu-label[b-uimaesebah] {
    color: var(--mud-palette-text-secondary);
    font-weight: 600;
    margin-bottom: 4px;
}

.mobile-menu-row[b-uimaesebah] {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.mobile-menu-info[b-uimaesebah] {
    color: var(--mud-palette-text-secondary);
}

.zoom-percentage[b-uimaesebah] {
    min-width: 45px;
    text-align: center;
}

@media (max-width: 768px) {
    .cloudbook-title[b-uimaesebah] {
        font-size: 0.8rem !important;
        max-width: 45vw;
    }

    .page-indicator[b-uimaesebah] {
        font-size: 0.85rem;
        min-width: auto;
    }

    .desktop-controls[b-uimaesebah] {
        display: none !important;
    }

    .mobile-menu[b-uimaesebah] {
        display: flex;
    }
}

/* Ensure Telerik PDF Viewer fits */
[b-uimaesebah] .k-pdf-viewer {
    border: none;
    background: var(--mud-palette-background);
}

[b-uimaesebah] .k-toolbar {
    background: var(--mud-palette-surface);
    border-bottom: 1px solid var(--mud-palette-divider);
    color: var(--mud-palette-text-primary);
}

[b-uimaesebah] .k-button-flat {
    color: var(--mud-palette-text-primary);
}

[b-uimaesebah] .k-button-flat:hover {
    background: var(--mud-palette-divider);
}

/* ─── Chat Panel (right side) ─── */
[b-uimaesebah] .chat-panel {
    flex: 0 0 570px;
    max-width: 570px;
    background: var(--mud-palette-surface);
    border-left: 1px solid var(--mud-palette-divider);
    color: var(--mud-palette-text-primary);
    display: flex;
    flex-direction: column;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.35);
    z-index: 2;
    min-height: 0;
}

[b-uimaesebah] .chat-panel-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--mud-palette-divider);
    background: rgba(0, 0, 0, 0.08);
}

[b-uimaesebah] .chat-panel-messages {
    flex: 1;
    overflow-y: auto;
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    -webkit-overflow-scrolling: touch;
}

[b-uimaesebah] .chat-panel-input {
    padding: 0.75rem;
    border-top: 1px solid var(--mud-palette-divider);
}

[b-uimaesebah] .chat-panel-status {
    padding: 0.25rem 0.75rem 0.5rem;
    text-align: center;
}

/* Message bubbles */
[b-uimaesebah] .chat-bubble {
    max-width: 85%;
    padding: 0.5rem 0.75rem;
    border-radius: 12px;
    font-family: 'Roboto Condensed', 'Roboto', sans-serif;
    font-size: 12pt;
    line-height: 1.45;
    word-wrap: break-word;
    overflow-wrap: break-word;
}

[b-uimaesebah] .chat-bubble.user {
    align-self: flex-end;
    background: linear-gradient(135deg, #5cabde 0%, #4a9ad4 60%, #3d8bc5 100%);
    color: #fff;
    border-bottom-right-radius: 4px;
    box-shadow:
        0 2px 6px rgba(92, 171, 222, 0.35),
        inset 0 1px 0 rgba(255, 255, 255, 0.25);
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.1);
}

[b-uimaesebah] .chat-bubble.assistant {
    align-self: flex-start;
    max-width: 100%;
    background: var(--mud-palette-background);
    color: var(--mud-palette-text-primary);
    border-bottom-left-radius: 4px;
    font-size: 12pt;
    overflow: visible;
}

[b-uimaesebah] .chat-bubble.assistant .markdown-content {
    overflow: visible;
    scrollbar-width: none;           /* Firefox */
    -ms-overflow-style: none;        /* IE/Edge */
}

[b-uimaesebah] .chat-bubble.assistant .markdown-content::-webkit-scrollbar {
    display: none;                   /* Chrome/Safari */
}

/* Markdown inside assistant bubbles */
[b-uimaesebah] .chat-bubble.assistant p {
    margin: 0 0 0.5rem;
}

[b-uimaesebah] .chat-bubble.assistant p:last-child {
    margin-bottom: 0;
}

[b-uimaesebah] .chat-bubble.assistant ul,
[b-uimaesebah] .chat-bubble.assistant ol {
    margin: 0.25rem 0;
    padding-left: 1.25rem;
}

[b-uimaesebah] .chat-bubble.assistant code {
    background: rgba(0, 0, 0, 0.1);
    padding: 0.1rem 0.3rem;
    border-radius: 3px;
    font-size: 0.85em;
}

[b-uimaesebah] .chat-bubble.assistant pre {
    background: rgba(0, 0, 0, 0.1);
    padding: 0.5rem;
    border-radius: 4px;
    overflow-x: auto;
    margin: 0.25rem 0;
}

[b-uimaesebah] .chat-bubble.assistant pre code {
    background: none;
    padding: 0;
}

/* Welcome state */
[b-uimaesebah] .chat-welcome {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
    padding: 2rem 1rem;
    color: var(--mud-palette-text-secondary);
}

[b-uimaesebah] .chat-suggestion-chip {
    cursor: pointer;
    transition: all 0.5s ease-in-out;
}

/* Active panel button indicator */
.active-panel-btn[b-uimaesebah] {
    background: rgba(var(--mud-palette-primary-rgb), 0.15) !important;
}

/* AI readiness: greyed-out icon for not-ready cloudbooks */
[b-uimaesebah] .ai-not-ready {
    opacity: 0.4 !important;
}

[b-uimaesebah] .ai-not-ready:hover {
    opacity: 0.55 !important;
}

/* Typing indicator */
[b-uimaesebah] .typing-indicator {
    display: flex;
    gap: 4px;
    padding: 4px 0;
}

[b-uimaesebah] .typing-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--mud-palette-text-secondary);
    animation: typing-bounce-b-uimaesebah 1.4s infinite ease-in-out;
}

@keyframes typing-bounce-b-uimaesebah {
    0%, 80%, 100% {
        transform: scale(0.6);
        opacity: 0.4;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* ─── Upgraded Chat Input ─── */
[b-uimaesebah] .chat-input-paper {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 16px;
    background: var(--mud-palette-background);
    border: 1px solid var(--mud-palette-divider);
    transition: border-color 0.5s ease-in-out;
    width: 100%;
    box-sizing: border-box;
}

[b-uimaesebah] .chat-input-paper:focus-within {
    border-color: var(--mud-palette-primary);
}

[b-uimaesebah] .chat-input-field {
    flex: 1;
    min-width: 0;
}

/* Remove MudTextField underline and padding in the text variant */
[b-uimaesebah] .chat-input-field .mud-input-root {
    margin-top: 0 !important;
}

[b-uimaesebah] .chat-input-field .mud-input-underline::before,
[b-uimaesebah] .chat-input-field .mud-input-underline::after {
    display: none !important;
}

[b-uimaesebah] .chat-input-field input,
[b-uimaesebah] .chat-input-field textarea {
    font-size: 0.9rem;
    padding: 4px 0;
}

[b-uimaesebah] .chat-input-actions {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    padding-bottom: 2px;
}

/* Send button - Logo blue filled, matching ChatInputComponent */
[b-uimaesebah] .chat-send-btn {
    background-color: #5cabde !important;
    color: white !important;
}

[b-uimaesebah] .chat-send-btn:hover:not(:disabled) {
    background-color: #7db8e8 !important;
    filter: brightness(1.1) !important;
}

[b-uimaesebah] .chat-send-btn:disabled {
    background-color: var(--mud-palette-action-disabled) !important;
    opacity: 0.6;
}

/* Ensure icon is visible when disabled */
[b-uimaesebah] .chat-send-btn:disabled .mud-icon-root,
[b-uimaesebah] .chat-send-btn:disabled i {
    color: var(--mud-palette-text-secondary) !important;
    opacity: 1 !important;
}

/* Clear chat button - red icon */
[b-uimaesebah] .chat-clear-btn .mud-icon-root,
[b-uimaesebah] .chat-clear-btn i {
    color: #f44336 !important;
}

[b-uimaesebah] .chat-clear-btn:hover .mud-icon-root,
[b-uimaesebah] .chat-clear-btn:hover i {
    color: #d32f2f !important;
}

[b-uimaesebah] .chat-clear-text {
    font-size: 0.65rem !important;
    color: var(--mud-palette-text-secondary);
    line-height: 1;
    text-transform: uppercase;
    font-weight: 500;
}

[b-uimaesebah] .chat-clear-container {
    cursor: pointer;
}

[b-uimaesebah] .chat-clear-container.disabled {
    cursor: not-allowed;
    opacity: 0.5;
}

[b-uimaesebah] .chat-clear-container:hover:not(.disabled) .chat-clear-text {
    color: var(--mud-palette-text-primary);
}

/* ─── Clickable Page Links ─── */
[b-uimaesebah] .cloudbook-page-link {
    color: var(--mud-palette-primary);
    cursor: pointer;
    text-decoration: underline;
    font-weight: 600;
    transition: color 0.5s ease-in-out, background-color 0.5s ease-in-out;
    padding: 0 2px;
    border-radius: 2px;
}

[b-uimaesebah] .cloudbook-page-link:hover {
    color: var(--mud-palette-primary-darken);
    background-color: rgba(var(--mud-palette-primary-rgb), 0.1);
}

/* ─── Markdown Content in Assistant Bubbles ─── */
/* Force all content inside assistant bubbles to inherit the bubble font size */
[b-uimaesebah] .chat-bubble.assistant * {
    font-size: inherit;
    line-height: inherit;
}

[b-uimaesebah] .chat-bubble.assistant h1,
[b-uimaesebah] .chat-bubble.assistant h2,
[b-uimaesebah] .chat-bubble.assistant h3,
[b-uimaesebah] .chat-bubble.assistant h4 {
    margin-top: 0.6rem;
    margin-bottom: 0.3rem;
    font-weight: 700;
    line-height: 1.3;
}

[b-uimaesebah] .chat-bubble.assistant h1 { font-size: 15pt !important; }
[b-uimaesebah] .chat-bubble.assistant h2 { font-size: 14pt !important; }
[b-uimaesebah] .chat-bubble.assistant h3 { font-size: 13pt !important; }
[b-uimaesebah] .chat-bubble.assistant h4 { font-size: 12.5pt !important; }

[b-uimaesebah] .chat-bubble.assistant h1:first-child,
[b-uimaesebah] .chat-bubble.assistant h2:first-child,
[b-uimaesebah] .chat-bubble.assistant h3:first-child,
[b-uimaesebah] .chat-bubble.assistant h4:first-child {
    margin-top: 0;
}

[b-uimaesebah] .chat-bubble.assistant table {
    border-collapse: collapse;
    width: 100%;
    margin: 0.5rem 0;
}

[b-uimaesebah] .chat-bubble.assistant th,
[b-uimaesebah] .chat-bubble.assistant td {
    border: 1px solid var(--mud-palette-divider);
    padding: 0.35rem 0.5rem;
    text-align: left;
}

[b-uimaesebah] .chat-bubble.assistant th {
    background: rgba(0, 0, 0, 0.06);
    font-weight: 600;
}

[b-uimaesebah] .chat-bubble.assistant blockquote {
    border-left: 3px solid var(--mud-palette-primary);
    margin: 0.5rem 0;
    padding: 0.25rem 0.75rem;
    opacity: 0.9;
}

[b-uimaesebah] .chat-bubble.assistant strong {
    font-weight: 700;
}

/* ─── Streaming Caret ─── */
[b-uimaesebah] .streaming-content {
    position: relative;
}

[b-uimaesebah] .streaming-content > p:last-child::after,
[b-uimaesebah] .streaming-content > div:last-child::after,
[b-uimaesebah] .streaming-content > li:last-child::after,
[b-uimaesebah] .streaming-content > blockquote:last-child::after,
[b-uimaesebah] .streaming-content > h1:last-child::after,
[b-uimaesebah] .streaming-content > h2:last-child::after,
[b-uimaesebah] .streaming-content > h3:last-child::after {
    content: '\2588';
    display: inline-block;
    margin-left: 2px;
    color: currentColor;
    font-weight: 700;
    animation: chat-caret-blink-b-uimaesebah 1s steps(1, end) infinite;
    vertical-align: -0.1em;
    line-height: 1;
}

[b-uimaesebah] .streaming-content:empty::after {
    content: '\2588';
    display: inline-block;
    color: currentColor;
    font-weight: 700;
    animation: chat-caret-blink-b-uimaesebah 1s steps(1, end) infinite;
    line-height: 1;
}

@keyframes chat-caret-blink-b-uimaesebah {
    50% { opacity: 0; }
}

@media (max-width: 768px) {
    .cloudbook-viewer-container[b-uimaesebah] {
        margin-top: -56px;
        padding-top: 56px;
        padding-top: calc(56px + env(safe-area-inset-top, 0px));
        height: 100vh;
        height: 100dvh;
        height: -webkit-fill-available;
    }

    .pdf-viewer-content[b-uimaesebah] {
        flex: 1 1 auto;
        height: auto;
        min-height: 0;
    }

    .pdf-viewer-layout[b-uimaesebah] {
        position: relative;
        flex-direction: column;
        overflow: hidden;
        height: 100%;
    }

    .bookmark-panel[b-uimaesebah] {
        position: absolute;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        z-index: 10;
        max-width: none;
        border-right: none;
        border-bottom: none;
        box-shadow: none;
        max-height: none;
        overflow-y: auto;
        background: var(--mud-palette-surface);
        /* iOS momentum scrolling */
        -webkit-overflow-scrolling: touch;
    }

    .viewer-surface[b-uimaesebah] {
        flex: 1 1 auto;
        min-height: 0;
        /* iOS momentum scrolling */
        -webkit-overflow-scrolling: touch;
    }

    .mobile-viewer-toolbar[b-uimaesebah] {
        position: sticky;
        top: 0;
        left: 0;
        right: 0;
        z-index: 5;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 2px;
        padding: 4px 8px;
        background: rgba(0, 0, 0, 0.7);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        color: #fff;
    }

    .mobile-toolbar-divider[b-uimaesebah] {
        width: 1px;
        height: 20px;
        background: rgba(255, 255, 255, 0.25);
        margin: 0 4px;
    }

    [b-uimaesebah] .chat-panel {
        position: absolute;
        top: 0;
        right: 0;
        width: 100%;
        height: 100%;
        z-index: 10;
        max-width: none;
        border-left: none;
        box-shadow: none;
        background: var(--mud-palette-surface);
        -webkit-overflow-scrolling: touch;
    }

    .shortcuts-indicator.shortcuts-shifted[b-uimaesebah],
    .shortcuts-popover.shortcuts-shifted[b-uimaesebah] {
        right: 16px;
    }

    .build-indicator.build-shifted[b-uimaesebah],
    .build-popover.build-shifted[b-uimaesebah] {
        left: 16px;
    }
}

/* Build indicator overlay (bottom-left of PDF canvas) */
.build-indicator[b-uimaesebah] {
    position: fixed;
    bottom: 16px;
    left: 16px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.9);
    z-index: 1000;
    cursor: pointer;
    opacity: 0.85;
    transition: opacity 0.2s, left 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.15);
    user-select: none;
}

.build-indicator:hover[b-uimaesebah] {
    opacity: 1;
    background-color: rgba(0, 0, 0, 0.75);
}

.build-indicator.build-shifted[b-uimaesebah] {
    left: 336px;
}

.build-popover.build-shifted[b-uimaesebah] {
    left: 336px;
}

.build-outdated[b-uimaesebah] {
    border-color: rgba(244, 67, 54, 0.4);
}

.build-tag[b-uimaesebah] {
    font-size: 0.6rem;
    font-weight: 600;
    text-transform: uppercase;
    padding: 1px 5px;
    border-radius: 6px;
    letter-spacing: 0.03em;
}

.build-tag-latest[b-uimaesebah] {
    background-color: rgba(76, 175, 80, 0.25);
    color: #81C784;
}

.build-tag-outdated[b-uimaesebah] {
    background-color: rgba(244, 67, 54, 0.25);
    color: #EF5350;
}

.outdated-banner[b-uimaesebah] {
    position: fixed;
    top: 64px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    font-size: 0.65rem;
    font-weight: 600;
    color: #F44336;
    background-color: rgba(244, 67, 54, 0.1);
    border: 1px solid rgba(244, 67, 54, 0.3);
    border-radius: 0 0 8px 8px;
    padding: 2px 12px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    pointer-events: none;
    white-space: nowrap;
}

.build-popover-backdrop[b-uimaesebah] {
    position: fixed;
    inset: 0;
    z-index: 51;
}

.build-popover[b-uimaesebah] {
    position: fixed;
    bottom: 44px;
    left: 16px;
    z-index: 1001;
}

/* Keyboard shortcuts overlay (top-right of canvas, fixed) */
.shortcuts-indicator[b-uimaesebah] {
    position: fixed;
    top: 74px;
    right: 16px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.9);
    z-index: 1000;
    cursor: pointer;
    opacity: 0.85;
    transition: opacity 0.2s, right 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.15);
    user-select: none;
}

.shortcuts-indicator:hover[b-uimaesebah] {
    opacity: 1;
    background-color: rgba(0, 0, 0, 0.75);
}

.shortcuts-indicator.shortcuts-shifted[b-uimaesebah] {
    right: 586px;
}

.shortcuts-popover.shortcuts-shifted[b-uimaesebah] {
    right: 586px;
}

.shortcuts-backdrop[b-uimaesebah] {
    position: fixed;
    inset: 0;
    z-index: 51;
}

.shortcuts-popover[b-uimaesebah] {
    position: fixed;
    top: 100px;
    right: 16px;
    z-index: 1001;
}

.shortcuts-list[b-uimaesebah] {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.shortcut-group-label[b-uimaesebah] {
    font-size: 0.65rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--mud-palette-text-secondary);
}

.shortcut-row[b-uimaesebah] {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.8rem;
}

.shortcut-keys[b-uimaesebah] {
    display: flex;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.shortcut-keys kbd[b-uimaesebah] {
    display: inline-block;
    padding: 2px 6px;
    font-size: 0.7rem;
    font-family: inherit;
    background: var(--mud-palette-background);
    border: 1px solid var(--mud-palette-divider);
    border-radius: 4px;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.15);
    min-width: 20px;
    text-align: center;
}
/* /Components/Shared/AppTour.razor.rz.scp.css */
/* =============================================
   App Tour — MudBlazor-based, theme-compatible
   ============================================= */

/* --- Overlay: full-screen dark backdrop --- */
.tour-overlay[b-fnhbg9lbnv] {
    position: fixed;
    inset: 0;
    z-index: 100000;
    background: rgba(0, 0, 0, 0.55);
    cursor: pointer;
}

/* --- Spotlight: transparent cutout over the target element --- */
.tour-spotlight[b-fnhbg9lbnv] {
    position: fixed;
    border-radius: 8px;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.55);
    z-index: 100000;
    pointer-events: none;
    transition: all 0.3s ease;
}

/* --- Highlighted element z-index boost --- */
[b-fnhbg9lbnv] .tour-hl-active {
    position: relative !important;
    z-index: 100000 !important;
    border-radius: 8px;
    transition: box-shadow 0.3s ease;
}

/* --- Tooltip card --- */
[b-fnhbg9lbnv] .tour-tooltip {
    position: fixed;
    z-index: 100001;
    border-radius: 12px !important;
    padding: 16px;
    max-width: 340px;
    min-width: 280px;
    background: var(--surface-color, var(--mud-palette-surface)) !important;
    color: var(--text-primary, var(--mud-palette-text-primary)) !important;
    border: 1px solid var(--border-color, rgba(0, 0, 0, 0.12)) !important;
}

/* --- Tooltip inner sections --- */
.tour-tooltip-header[b-fnhbg9lbnv] {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

[b-fnhbg9lbnv] .tour-step-chip {
    font-weight: 700;
    font-size: 0.7rem;
    letter-spacing: 0.03em;
    height: 24px !important;
}

[b-fnhbg9lbnv] .tour-tooltip-title {
    font-weight: 600 !important;
    margin-bottom: 6px;
    color: var(--text-primary, var(--mud-palette-text-primary)) !important;
}

[b-fnhbg9lbnv] .tour-tooltip-desc {
    line-height: 1.6;
    margin-bottom: 14px;
    color: var(--text-secondary, var(--mud-palette-text-secondary)) !important;
}

.tour-tooltip-actions[b-fnhbg9lbnv] {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* --- Arrow (CSS triangle) --- */
.tour-arrow[b-fnhbg9lbnv] {
    position: absolute;
    width: 12px;
    height: 12px;
    background: var(--surface-color, var(--mud-palette-surface));
    border: 1px solid var(--border-color, rgba(0, 0, 0, 0.12));
    transform: rotate(45deg);
    z-index: -1;
}

.tour-arrow-top[b-fnhbg9lbnv] {
    top: -7px;
    left: 50%;
    margin-left: -6px;
    border-bottom: none;
    border-right: none;
}

.tour-arrow-bottom[b-fnhbg9lbnv] {
    bottom: -7px;
    left: 50%;
    margin-left: -6px;
    border-top: none;
    border-left: none;
}

.tour-arrow-left[b-fnhbg9lbnv] {
    top: 50%;
    left: -7px;
    margin-top: -6px;
    border-top: none;
    border-right: none;
}

.tour-arrow-right[b-fnhbg9lbnv] {
    top: 50%;
    right: -7px;
    margin-top: -6px;
    border-bottom: none;
    border-left: none;
}

/* ---- Dark theme ---- */
[data-theme="dark"] .tour-overlay[b-fnhbg9lbnv] {
    background: rgba(0, 0, 0, 0.65);
}

[data-theme="dark"] .tour-spotlight[b-fnhbg9lbnv] {
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.65);
}

[data-theme="dark"][b-fnhbg9lbnv]  .tour-hl-active {
    box-shadow: 0 0 0 3px var(--info-color, #0ea5e9), 0 0 16px rgba(14, 165, 233, 0.3);
}

[data-theme="dark"][b-fnhbg9lbnv]  .tour-tooltip {
    background: var(--surface-color, #1d1d1d) !important;
    border-color: var(--border-color, #3a3a3a) !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6) !important;
}

[data-theme="dark"] .tour-arrow[b-fnhbg9lbnv] {
    background: var(--surface-color, #1d1d1d);
    border-color: var(--border-color, #3a3a3a);
}

/* ---- Light theme highlight glow ---- */
[data-theme="light"][b-fnhbg9lbnv]  .tour-hl-active {
    box-shadow: 0 0 0 3px var(--accent-primary, #9ca3af), 0 0 16px rgba(156, 163, 175, 0.3);
}

/* ---- Mobile adjustments ---- */
@media (max-width: 600px) {
    [b-fnhbg9lbnv] .tour-tooltip {
        max-width: calc(100vw - 32px) !important;
        min-width: unset !important;
    }
}
/* /Components/Shared/ErrorPanel.razor.rz.scp.css */
.error-panel[b-0qk43cpspd] {
    margin-bottom: 12px;
    padding: 16px;
    background-color: var(--error-bg-low-contrast);
    border-left: 4px solid var(--error-color);
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.error-panel-title[b-0qk43cpspd] {
    color: var(--error-color);
    font-weight: 600;
    margin-bottom: 4px;
}

.error-panel-message[b-0qk43cpspd] {
    color: var(--text-secondary);
}

.error-panel .mud-icon-root[b-0qk43cpspd] {
    color: var(--error-color) !important;
}

[data-theme="dark"] .error-panel[b-0qk43cpspd],
:root:not([data-theme]) .error-panel[b-0qk43cpspd] {
    background-color: #2d1b1b;
}
/* /Components/Shared/OfficeMemorandumListItem.razor.rz.scp.css */
.om-icon-gi[b-v1yybv6btf] {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.om-icon-gi .om-icon[b-v1yybv6btf] {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
}

.om-icon-gi .om-gi[b-v1yybv6btf] {
  display: inline-block;
  font-weight: 600;
  text-wrap-mode: wrap;
}
/* /Components/Shared/SparkleIcon.razor.rz.scp.css */
.sparkle-icon-wrapper[b-2sg6hvadkr] {
    align-items: center;
    justify-content: center;
    line-height: 0;
}

/* Animate fill+stroke directly on SVG shapes — immune to global * { transition: color } */
/* @keyframes are defined in custom-theme.css (global) so the name is never scoped away */
.sparkle-shape[b-2sg6hvadkr] {
    animation: sparkle-color-shift 16s linear infinite;
    animation-fill-mode: both;
    transition: none !important;
}
