.document-library { flex: 1; min-width: 0; min-height: 0; overflow-y: auto; padding-right: .3rem; }
.library-heading-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.settings-editor .library-retry-all { background: #fff7ed; border-color: #e8d0ad; color: #83501f; }
.library-retry-overview { flex-shrink: 0; border: 1px solid #e0e7f1; border-radius: 10px; padding: 10px 14px; margin-bottom: 10px; font-size: .78rem; color: #506480; line-height: 1.5; }
.library-retry-overview p { margin: 4px 0; }.library-retry-overview details { max-height: 180px; overflow: auto; }.library-retry-overview summary { cursor: pointer; color: #885523; }
.library-retry-result:empty { display: none; }.library-retry-result { color: #28654d; }
.translation-diagnostic { border-top: 1px solid #ecdec8; margin-top: 10px; padding-top: 10px; }.translation-diagnostic small { overflow-wrap: anywhere; }
@media (max-width: 600px) { .library-heading-actions { width: 100%; }.library-heading-actions button { width: 100%; } }
.documentation-page { background: #f2f5fb; }
.document-library :is(button, input, select, summary, a):focus-visible { outline: 2px solid #5883e8; outline-offset: 2px; }
.library-heading { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.library-heading > div { min-width: 0; }
.settings-editor .library-primary-action { background: #2457d6; color: white; border-color: #2457d6; font-weight: 600; }
.settings-editor .library-primary-action:hover:not(:disabled) { background: #1947bb; color: white; border-color: #1947bb; }
.settings-editor .library-primary-action:disabled { opacity: .5; cursor: not-allowed; }
.library-heading > button { flex-shrink: 0; }
.document-upload-panel { background: #f8faff; }
.library-drop-hint { flex-basis: 100%; margin: 0; color: #52627c; font-size: .85rem; }
.library-file-picker input::file-selector-button { border: 0; border-radius: .35rem; background: #e7eeff; padding: .45rem .7rem; color: #214aa5; cursor: pointer; margin-right: .65rem; }
.library-file-selection { flex-basis: 100%; list-style: none; padding: 0; margin: 0; display: grid; gap: .4rem; max-height: 10rem; overflow: auto; }
.library-file-selection:empty { display: none; }
.library-file-selection li { display: flex; align-items: center; justify-content: space-between; gap: .7rem; border: 1px solid #dde5f3; background: white; border-radius: .5rem; padding: .55rem .65rem; }
.library-file-selection li div { min-width: 0; }
.library-file-selection strong { display: block; font-size: .8rem; overflow-wrap: anywhere; }
.library-file-selection small { font-size: .75rem; }
.document-library .document-row { grid-template-columns: 2.6rem minmax(0, 1fr); column-gap: .65rem; }
.document-row > :not(.library-format) { grid-column: 2; }
.document-row > .library-format { grid-column: 1; grid-row: 1 / span 5; align-self: start; }
.library-format { display: grid; place-items: center; width: 2.6rem; height: 2.9rem; background: #edf2fb; border-radius: .45rem; font-size: .65rem; font-weight: 700; color: #45618a; }
.library-format.format-pdf { background: #fff0ed; color: #b14d39; }
.library-format.format-docx { background: #eaf1ff; color: #2355b2; }
.library-format.format-markdown { background: #e9f6f1; color: #20765c; }
.document-row > .document-state { width: fit-content; padding: .15rem .4rem; border-radius: .3rem; background: #f2f4f8; }
.document-row > .state-ready { background: #ecf8f1; }
.document-row > .state-failed { background: #fff0ed; }
.library-reader-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 70%; padding: 2rem; text-align: center; color: #64748b; }
.library-reader-empty h3 { margin: 1rem 0 .5rem !important; color: #334155; }
.library-reader-empty p { max-width: 42ch; line-height: 1.7; }
.library-reader-empty small { line-height: 1.8; }
.library-empty-mark { display: grid; place-items: center; width: 4rem; height: 4rem; border-radius: 1rem; background: #edf3ff; color: #3260be; letter-spacing: .1em; font-weight: 700; }
.library-empty { display: flex; flex-direction: column; gap: .5rem; align-items: center; }
.library-empty p { margin: 0; }
.library-reading-modes { display: flex; gap: .25rem; padding: .25rem; margin: .8rem 0; border-radius: .5rem; background: #f0f3f9; width: fit-content; }
.settings-editor .library-reading-modes button { background: transparent; border-color: transparent; }
.settings-editor .library-reading-modes button[aria-pressed="true"] { background: white; box-shadow: 0 1px 4px #182b4e12; color: #2355b2; }
.library-reading-surface { min-width: 0; }
.library-markdown { padding: 1rem 1.2rem; background: #fff; border: 1px solid #e9edf4; border-radius: .65rem; line-height: 1.8; font-size: .92rem; overflow-wrap: anywhere; color: #344054; }
.library-markdown h1 { font-size: 1.4rem; }
.library-markdown h2 { font-size: 1.2rem; margin-top: 1.4rem; }
.library-markdown h3 { font-size: 1.05rem; margin-top: 1rem !important; }
.library-markdown .markdown-table { max-width: 100%; overflow-x: auto; margin: .8rem 0; }
.library-markdown table { border-collapse: collapse; width: 100%; }
.library-markdown td, .library-markdown th { border: 1px solid #dce3ed; padding: .5rem .7rem; text-align: left; }
.library-markdown th { background: #f5f7fb; }
.library-markdown pre { overflow-x: auto; padding: .8rem; background: #f5f7fb; border-radius: .4rem; }
.library-markdown blockquote { margin-left: 0; border-left: 3px solid #b8cbf5; padding-left: 1rem; color: #64748b; }
.library-translation-notice { padding: .65rem .8rem; border-radius: .45rem; background: #f2f6ff; color: #4c6183; font-size: .8rem; line-height: 1.6; }
.documentation-shell { width: 100%; height: 100dvh; padding: .75rem; display: flex; flex-direction: column; gap: .65rem; min-height: 0; }
.management-header { display: flex; align-items: center; justify-content: space-between; gap: .75rem; flex-shrink: 0; min-height: 2.6rem; }
.documentation-page-title { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.documentation-editor { flex: 1; min-height: 0; box-shadow: none; border-radius: .7rem; padding: .7rem; }
.documentation-page .document-library { display: flex; flex-direction: column; overflow: hidden; padding: 0; }
.documentation-page .document-library > header { flex-shrink: 0; padding: 0 0 .5rem; }
.documentation-page .document-library > header h2 { margin: 0 0 .2rem; font-size: 1rem; }
.documentation-page .document-library > header p { margin: 0; font-size: .8rem; max-width: none; }
.documentation-page .document-workspace { flex: 1; min-height: 0; grid-template-columns: clamp(12rem, 17vw, 17rem) minmax(0, 1fr); gap: .7rem; align-items: stretch; }
.documentation-page .document-indicators { display: flex; flex-direction: column; min-height: 0; padding: 0 .7rem 0 0; border-right: 1px solid #e4e7ec; }
.documentation-page .document-indicators h3 { margin: .25rem 0 .5rem; }
.documentation-page .document-indicator-options { flex: 1; min-height: 0; max-height: none; align-content: start; }
.documentation-page .document-main { display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.document-upload-panel { flex-shrink: 0; border: 1px solid #e4e7ec; border-radius: .5rem; margin-bottom: .5rem; }
.document-upload-panel > summary, .document-management > summary { cursor: pointer; padding: .55rem .7rem; font-size: .83rem; font-weight: 600; color: #344054; }
.document-upload-panel[open] { max-height: 40vh; overflow-y: auto; }
.documentation-page .document-upload { margin: 0 .5rem .5rem; padding: .65rem; gap: .6rem; }
.documentation-page .document-toolbar { flex-shrink: 0; margin: 0 0 .6rem; gap: .5rem; }
.documentation-page .document-grid { flex: 1; min-height: 0; grid-template-columns: clamp(14rem, 22vw, 21rem) minmax(0, 1fr); gap: .7rem; }
.document-files { display: flex; flex-direction: column; min-height: 0; overflow: hidden; }
.documentation-page .document-rows { flex: 1; min-height: 0; max-height: none; align-content: start; }
.documentation-page .document-pages { flex-shrink: 0; margin: .5rem 0 0; }
.documentation-page .document-reader { min-height: 0; overflow-y: auto; padding: .8rem; }
.documentation-page .document-reader h3 { margin: 0 0 .4rem; font-size: 1rem; }
.documentation-page .document-file-name { margin: .2rem 0; font-size: .78rem; }
.document-management { margin: .6rem 0; border: 1px solid #e4e7ec; border-radius: .5rem; }
.document-management > :not(summary) { margin: .5rem .65rem; }
.document-management .document-association { padding: 0; }
.documentation-page .document-content { max-height: none; overflow: visible; margin: .5rem 0; }
.documentation-page .document-translation-columns pre { max-height: none; }
.document-library header p { color: #667085; max-width: 76ch; line-height: 1.6; }
.document-workspace { display: grid; grid-template-columns: 14rem minmax(0, 1fr); gap: 1rem; align-items: start; }
.document-main { min-width: 0; }
.document-indicators { min-width: 0; padding-top: .6rem; }
.document-indicators h3 { font-size: .95rem; }
.document-indicators > input { width: 100%; padding: .6rem; border: 1px solid #cbd5e1; border-radius: .4rem; margin-bottom: .6rem; }
.document-indicator-options { display: grid; gap: .35rem; max-height: 65vh; overflow: auto; }
.document-library .document-indicator { display: flex; justify-content: space-between; align-items: center; gap: .5rem; text-align: left; width: 100%; }
.document-library .document-indicator[aria-current="true"] { border-color: #3972db; background: #f2f7ff; }
.document-indicator span { min-width: 0; overflow-wrap: anywhere; }
.document-indicator-count { flex-shrink: 0; min-width: 1.5rem; text-align: center; padding: .1rem .3rem; border-radius: 5px; background: #eaf0f8; }
.document-upload-target { flex-basis: 100%; font-size: .9rem; }
.document-upload { display: flex; flex-wrap: wrap; gap: 1rem; align-items: end; padding: 1.2rem; margin: 1.2rem 0; border: 1px dashed #b8c6da; border-radius: 12px; background: #f8faff; }
.document-upload.is-dragging { border-color: #2868d7; background: #edf4ff; }
.document-upload label:first-child { flex: 1 1 15rem; min-width: 0; }
.document-upload small { flex-basis: 100%; color: #667085; }
.document-upload-results { padding-left: 1.2rem; max-height: 14rem; overflow: auto; }
.document-upload-results li { margin: .5rem 0; overflow-wrap: anywhere; }
.document-upload-results button { margin-left: .7rem; }
.document-toolbar { display: flex; gap: .8rem; align-items: center; flex-wrap: wrap; margin: 1.25rem 0; }
.document-toolbar input { flex: 1; min-width: 12rem; padding: .6rem; border: 1px solid #cbd5e1; border-radius: .4rem; font: inherit; }
.document-toolbar select { max-width: 100%; padding: .6rem; border: 1px solid #cbd5e1; border-radius: .4rem; background: white; color: #344054; }
.document-grid { display: grid; grid-template-columns: minmax(15rem, .8fr) minmax(0, 1.2fr); gap: 1.25rem; }
.document-rows { display: grid; gap: .5rem; max-height: 65vh; overflow: auto; }
.document-library .document-row { display: grid; gap: .3rem; width: 100%; text-align: left; padding: .9rem; background: #fff; color: #344054; border: 1px solid #e4e7ec; border-radius: 9px; overflow-wrap: anywhere; }
.document-row[aria-current="true"] { border-color: #3972db; background: #f2f7ff; }
.document-row small, .document-file-name { color: #667085; }
.document-state { font-size: .8rem; color: #53647f; }
.state-ready { color: #187249; }
.state-failed, .state-needsindex { color: #a33a2c; }
.document-pages, .document-detail-actions { display: flex; flex-wrap: wrap; gap: .6rem; margin: 1rem 0; }
.document-reader { min-width: 0; padding: 1rem; border: 1px solid #e4e7ec; border-radius: 10px; }
.document-reader h3, .document-file-name { overflow-wrap: anywhere; }
.document-association { display: flex; gap: .5rem; align-items: end; margin: .8rem 0; flex-wrap: wrap; }
.document-association label { flex: 1; }
.document-library .document-delete { color: #a12c24; border-color: #e9b8b3; }
.document-delete-dialog { max-width: min(30rem, calc(100vw - 2rem)); border: 1px solid #d0d5dd; border-radius: 12px; padding: 1.3rem; }
.document-delete-dialog::backdrop { background: #10182866; }
.document-delete-dialog p { line-height: 1.6; overflow-wrap: anywhere; }
.document-delete-dialog button { margin-right: .5rem; }
.document-translation-columns { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
.document-translation-columns > div { min-width: 0; }
.document-translation-columns pre { max-height: 24rem; }
.document-translation-fragment { border: 1px solid #e2e8f2; border-radius: 12px; margin-top: .8rem; overflow: hidden; }
.document-translation-fragment > summary { cursor: pointer; padding: 14px; background: #f6f8fc; font-size: .82rem; line-height: 1.5; }
.document-translation-fragment > summary span { margin-left: 10px; color: #6c7b92; font-weight: 400; }
.document-translation-fragment .document-translation-columns { gap: 0; }
.document-translation-columns > div { padding: 16px; }
.document-translation-columns > div + div { border-left: 1px solid #e2e8f2; background: #fcfdff; }
.document-translation-columns > div > strong { font-size: .75rem; color: #5d7090; }
.document-translation-text { font-family: inherit; font-size: .9rem; line-height: 1.75; overflow-wrap: anywhere; color: #344054; }
.document-translation-text h1, .document-translation-text h2, .document-translation-text h3 { font-size: 1rem; }
.document-translation-text .markdown-table { overflow-x: auto; }
.document-translation-text table { border-collapse: collapse; width: 100%; }
.document-translation-text td, .document-translation-text th { border: 1px solid #dce3ed; padding: 6px; }
.document-translation-empty { padding: 16px; border: 1px dashed #d6deeb; border-radius: 10px; background: #f8faff; color: #6b7c96; }
.document-translations > p { font-size: .8rem; color: #667085; line-height: 1.5; }
.document-languages { display: flex; flex-wrap: wrap; gap: .4rem; }
.document-language { border: 1px solid #e4e7ec; border-radius: 6px; padding: .3rem .5rem; font-size: .78rem; }
.document-content { white-space: pre-wrap; overflow-wrap: anywhere; max-height: 60vh; overflow: auto; padding: 1rem; background: #f8fafc; border-radius: 8px; font-size: .85rem; line-height: 1.6; }
@media (max-width: 850px) { .document-grid { grid-template-columns: 1fr; } .document-rows { max-height: 38vh; } }
@media (max-width: 850px) { .document-workspace { grid-template-columns: 1fr; } .document-indicator-options { grid-template-columns: repeat(2, minmax(0, 1fr)); max-height: 12rem; } }
@media (max-width: 600px) { .document-translation-columns { grid-template-columns: 1fr; } }
@media (max-width: 900px) {
  .documentation-shell { padding: .5rem; }
  .management-header { flex-wrap: wrap; gap: .4rem; }
  .management-navigation a { padding: .4rem .5rem; font-size: .78rem; }
  .documentation-page .document-workspace { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto minmax(0, 1fr); }
  .documentation-page .document-indicators { max-height: 10rem; padding: 0 0 .5rem; border-right: 0; border-bottom: 1px solid #e4e7ec; }
  .documentation-page .document-indicator-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .documentation-page .document-grid { display: block; overflow-y: auto; }
  .documentation-page .document-rows { max-height: 28vh; }
  .documentation-page .document-reader { overflow: visible; margin-top: .65rem; }
  .documentation-page .document-upload-panel[open] { max-height: 28vh; }
}
@media (max-width: 600px) {
  .library-heading { align-items: start; flex-wrap: wrap; }
  .library-heading > button { width: 100%; }
  .library-reader-empty { padding: 1rem; }
  .library-markdown { padding: .8rem; }
}
.document-editor-dialog { width: min(1080px, calc(100vw - 24px)); height: min(920px, calc(100dvh - 28px)); max-height: calc(100dvh - 28px); box-sizing: border-box; border: 1px solid #d6deea; border-radius: 18px; padding: 22px; color: #26364c; background: #f9fbfe; box-shadow: 0 24px 80px #172b4d40; }
.document-editor-dialog[open] { display: flex; flex-direction: column; gap: 12px; }
.document-editor-dialog::backdrop { background: #16253c88; backdrop-filter: blur(3px); }
.document-editor-dialog header, .document-editor-dialog footer, .editor-modes, .editor-toolbar { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; flex-shrink: 0; }
.document-editor-dialog header { justify-content: space-between; }
.document-editor-dialog h2 { margin: 0; font-size: 1.2rem; max-width: 80%; overflow-wrap: anywhere; }
.document-editor-dialog label { display: flex; gap: 10px; align-items: center; font-size: .9rem; }
.document-editor-dialog select { padding: 8px 12px; border: 1px solid #cbd5e4; border-radius: 8px; background: white; }
.document-editor-dialog button:not(.mud-button-root) { border: 1px solid #cbd5e4; border-radius: 8px; padding: 7px 11px; background: white; color: #365375; cursor: pointer; }
.document-editor-dialog button[aria-pressed=true] { background: #e9f0ff; border-color: #6e91cf; }
.document-editor-dialog button:disabled { opacity: .5; cursor: default; }
.document-editor-dialog button:focus-visible, .document-editor-dialog select:focus-visible, .document-visual-editor:focus-visible, .document-raw-editor:focus-visible { outline: 2px solid #447ccd; outline-offset: 2px; }
.editor-toolbar { padding: 8px; background: #edf2f9; border-radius: 10px; }
.editor-toolbar button { font-size: .8rem; }
.editor-note, .editor-status { font-size: .85rem; margin: 0; line-height: 1.45; }
.editor-note { color: #62748c; }
.editor-status { min-height: 1.3em; color: #365b8b; }
.document-visual-editor, .document-raw-editor { flex: 1; min-height: 160px; max-height: none; overflow: auto; padding: 20px; background: white; border: 1px solid #cbd5e4; border-radius: 10px; width: 100%; box-sizing: border-box; line-height: 1.65; color: #26364c; }
.document-visual-editor { white-space: pre-wrap; overflow-wrap: anywhere; }
.document-visual-editor h1 { font-size: 1.7rem; }.document-visual-editor h2 { font-size: 1.4rem; max-width: none; }
.document-visual-editor table { border-collapse: collapse; width: 100%; white-space: normal; }
.document-visual-editor th, .document-visual-editor td { border: 1px solid #cbd5e4; min-width: 60px; padding: 8px; }
.document-visual-editor .markdown-table { overflow-x: auto; }
.document-visual-editor pre { white-space: pre-wrap; background: #f3f6fa; padding: 12px; }
.document-visual-editor .align-center { text-align: center; }.document-visual-editor .align-right { text-align: right; }
.document-raw-editor { resize: none; font-family: Consolas, monospace; font-size: .85rem; }
.document-editor-dialog footer { justify-content: space-between; }
.document-editor-dialog footer small { flex: 1; min-width: 180px; color: #62748c; }
.document-editor-dialog footer button:not(.mud-button-root) { background: #315d9b; color: white; min-width: 110px; }
@media (max-width: 600px) { .document-editor-dialog { padding: 14px; gap: 8px; } .document-visual-editor, .document-raw-editor { padding: 12px; } .document-editor-dialog label { flex-wrap: wrap; } }
.document-visual-editor h1, .document-visual-editor h2, .document-visual-editor h3 { white-space: pre-wrap; overflow: visible; text-overflow: clip; }
.document-reader-heading { padding: 8px 4px 12px; border-bottom: 1px solid #e7edf5; }
.documentation-page .document-reader-heading h3 { font-size: 1.3rem; color: #253b60; }
.document-reader-heading > p:last-child { color: #60738f; font-size: .8rem; margin-bottom: 0; }
.document-language-heading h4 { margin: 20px 0 4px; font-size: .9rem; color: #2e4569; }
.document-language-heading p { margin: 0 0 12px; font-size: .8rem; color: #6b7c96; }
.document-language-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(175px, 1fr)); gap: 10px; margin-bottom: 16px; }
.document-language-card { display: flex; flex-direction: column; gap: 8px; padding: 14px; border: 1px solid #e0e7f1; border-radius: 12px; background: #fafcff; min-width: 0; }
.document-language-card:has([aria-pressed="true"]) { border-color: #6d94df; box-shadow: inset 0 0 0 1px #6d94df; background: #f3f7ff; }
.settings-editor .document-language-choice { display: flex; flex-direction: column; gap: 4px; align-items: flex-start; width: 100%; text-align: left; padding: 0; background: transparent; border: 0; color: #2f4c7b; }
.document-language-choice strong { font-size: .9rem; }
.document-language-card small { font-size: .72rem; color: #6d7d94; }
.document-language-state { font-size: .76rem; font-weight: 600; color: #657894; }
.document-language-card[data-state="Ready"] .document-language-state { color: #23765b; }
.document-language-card[data-state="Failed"] .document-language-state, .document-row .document-translation-warning, .document-language-card .document-translation-warning { color: #a46125; }
.document-language-card progress { width: 100%; height: 5px; border: 0; border-radius: 5px; overflow: hidden; accent-color: #527ed0; }
.document-language-card progress::-webkit-progress-bar { background: #e6edf7; }.document-language-card progress::-webkit-progress-value { background: #527ed0; }
.document-language-card[data-state="Ready"] progress::-webkit-progress-value { background: #3b9476; }
.settings-editor .document-retry-translation { margin-top: auto; padding: 8px 10px; color: #8c531e; background: #fff7ed; border-color: #ead5bd; font-weight: 600; font-size: .75rem; }
.document-translation-help { padding: 14px 16px; margin: 0 0 18px; border: 1px solid #edddc6; border-radius: 12px; background: #fffbf4; color: #78562e; font-size: .8rem; line-height: 1.55; }
.document-translation-help p { margin: 6px 0; }.document-translation-help small { display: block; margin: 8px 0; }.document-translation-help a { color: #315eaa; font-weight: 600; }
.document-translation-help[hidden] { display: none; }
@media (max-width: 600px) { .document-language-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; } .document-language-card { padding: 10px; } .document-translation-columns > div + div { border-left: 0; border-top: 1px solid #e2e8f2; } }
