.workspace.is-knowledge .view-switcher,
.workspace.is-knowledge .control-bar,
.workspace.is-knowledge .status-jump,
.workspace.is-knowledge .applied-filters,
.workspace.is-knowledge #create-task { display: none; }

.knowledge-view { min-height: 0; padding: 0 28px 24px; overflow: hidden; }
.knowledge-shell { height: 100%; min-height: 0; display: grid; grid-template-columns: 226px minmax(300px, 372px) minmax(430px,1fr); border: 1px solid var(--line); border-radius: 16px; background: #fff; box-shadow: 0 7px 24px rgba(31,49,63,.055); overflow: hidden; }
.knowledge-categories, .knowledge-index, .knowledge-reader { min-width: 0; min-height: 0; }
.knowledge-categories { display: flex; flex-direction: column; border-right: 1px solid var(--line); background: #f8fafb; }
.knowledge-categories > header { min-height: 76px; display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.knowledge-categories > header > span { width: 38px; height: 38px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 11px; background: #deeeee; color: var(--accent); }
.knowledge-categories > header svg { width: 18px; height: 18px; }
.knowledge-categories > header div { min-width: 0; display: grid; gap: 3px; }
.knowledge-categories > header p { margin: 0; color: #8a98a2; text-transform: uppercase; font-size: 8px; letter-spacing: .11em; font-weight: 850; }
.knowledge-categories > header strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 13px; }
.knowledge-category-create { width: 34px; height: 34px; flex: 0 0 auto; display: grid; place-items: center; margin-left: auto; border: 1px solid #cbdde0; border-radius: 9px; background: #fff; color: var(--accent); cursor: pointer; }
.knowledge-category-create[hidden] { display: none; }
.knowledge-category-create:hover { border-color: #87b8bb; background: #e9f4f4; }
.knowledge-category-create svg { width: 15px; height: 15px; }
.knowledge-categories nav { flex: 1; min-height: 0; overflow-y: auto; padding: 8px; scrollbar-width: thin; scrollbar-color: #d1dadd transparent; }
.knowledge-category { width: 100%; min-height: 43px; display: grid; grid-template-columns: 28px minmax(0,1fr) auto; align-items: center; gap: 8px; border: 0; border-radius: 9px; padding: 5px 8px 5px calc(8px + var(--knowledge-depth,0) * 12px); background: transparent; color: #64737f; text-align: left; cursor: pointer; }
.knowledge-category:hover { background: #edf3f4; color: #33444f; }
.knowledge-category.is-active { background: #e2f0f0; color: var(--accent-dark); }
.knowledge-category > span { width: 27px; height: 27px; display: grid; place-items: center; border-radius: 8px; background: rgba(116,145,155,.1); color: #718691; }
.knowledge-category.is-active > span { background: rgba(20,123,130,.12); color: var(--accent); }
.knowledge-category svg { width: 14px; height: 14px; }
.knowledge-category strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 10.5px; font-weight: 730; }
.knowledge-category em { min-width: 21px; height: 20px; display: grid; place-items: center; border-radius: 999px; padding: 0 6px; background: #e8edef; color: #82909a; font-size: 8.5px; font-style: normal; font-weight: 800; }
.knowledge-category.is-active em { background: rgba(20,123,130,.14); color: var(--accent-dark); }

.knowledge-index { display: flex; flex-direction: column; border-right: 1px solid var(--line); background: #fff; }
.knowledge-index > header { min-height: 112px; display: grid; align-content: center; gap: 10px; padding: 13px 14px; border-bottom: 1px solid var(--line); }
.knowledge-index > header > div { display: flex; align-items: center; gap: 7px; }
.knowledge-index > header .eyebrow { margin: 0; }
.knowledge-index h2 { display: flex; align-items: center; gap: 7px; margin: 0 0 0 auto; color: #697984; font-size: 10px; font-weight: 760; }
.knowledge-index h2 span { min-width: 22px; height: 21px; display: grid; place-items: center; border-radius: 999px; padding: 0 6px; background: #e5eff0; color: var(--accent-dark); font-size: 8.5px; }
.knowledge-create { min-height: 34px; display: inline-flex; align-items: center; gap: 6px; margin-left: 2px; border: 1px solid #c9dfe1; border-radius: 9px; padding: 0 10px; background: #edf6f6; color: var(--accent-dark); cursor: pointer; font-size: 9.5px; font-weight: 820; }
.knowledge-create[hidden] { display: none; }
.knowledge-create:hover { border-color: #85b7ba; background: #e1f0f0; }
.knowledge-create svg { width: 14px; height: 14px; }
.knowledge-search { min-height: 41px; display: grid; grid-template-columns: 17px minmax(0,1fr) 31px; align-items: center; gap: 7px; border: 1px solid #d9e2e6; border-radius: 10px; padding: 0 5px 0 11px; background: #f6f8f9; color: #87949e; }
.knowledge-search:focus-within { border-color: #75adb0; background: #fff; box-shadow: 0 0 0 3px rgba(20,123,130,.08); }
.knowledge-search > svg { width: 16px; height: 16px; }
.knowledge-search input { min-width: 0; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 12px; }
.knowledge-search button { width: 31px; height: 31px; display: grid; place-items: center; border: 0; border-radius: 8px; background: transparent; color: #8c99a2; cursor: pointer; }
.knowledge-search button:hover { background: #e8eef0; color: var(--ink); }
.knowledge-search button[hidden] { display: none; }
.knowledge-search button svg { width: 14px; height: 14px; }
.knowledge-list { flex: 1; min-height: 0; overflow-y: auto; padding: 8px; scrollbar-width: thin; scrollbar-color: #d2dade transparent; }
.knowledge-card { position: relative; width: 100%; min-height: 91px; display: grid; grid-template-columns: 36px minmax(0,1fr) 15px; align-items: start; gap: 10px; border: 1px solid transparent; border-radius: 12px; padding: 10px 9px; background: transparent; color: var(--ink); text-align: left; cursor: pointer; }
.knowledge-card::before { content: ''; position: absolute; top: 13px; bottom: 13px; left: 0; width: 3px; border-radius: 0 3px 3px 0; background: transparent; }
.knowledge-card:hover { border-color: #dce5e8; background: #f7f9fa; }
.knowledge-card.is-active { border-color: #cfe1e2; background: #edf6f6; }
.knowledge-card.is-active::before { background: var(--accent); }
.knowledge-card-mark { width: 35px; height: 35px; display: grid; place-items: center; border-radius: 10px; background: #e8f1f1; color: var(--accent); }
.knowledge-card-mark svg { width: 16px; height: 16px; }
.knowledge-card-copy { min-width: 0; display: grid; gap: 4px; }
.knowledge-card-copy strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 11.5px; line-height: 1.25; }
.knowledge-card-copy small { display: -webkit-box; overflow: hidden; -webkit-line-clamp: 2; -webkit-box-orient: vertical; color: #788791; font-size: 9.5px; line-height: 1.35; }
.knowledge-card-foot { min-width: 0; display: flex; align-items: center; gap: 5px; }
.knowledge-card-copy em { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: #9aa5ad; font-size: 8px; font-style: normal; font-weight: 700; }
.knowledge-status { flex: 0 0 auto; border-radius: 999px; padding: 3px 6px; background: #edf1f3; color: #788790; font-size: 7.5px; font-weight: 820; white-space: nowrap; }
.knowledge-status.is-published { background: #e2f1e9; color: #4f8467; }
.knowledge-status.is-in-review { background: #fff2db; color: #9b702e; }
.knowledge-status.is-archived { background: #e9ecef; color: #76818a; }
.knowledge-card > svg { width: 14px; height: 14px; align-self: center; color: #a2adb4; }
.knowledge-state { min-height: 240px; display: grid; justify-items: center; align-content: center; gap: 8px; padding: 28px; color: #82919b; text-align: center; }
.knowledge-state > span:not(.knowledge-state-icon) { width: 45px; height: 45px; display: grid; place-items: center; border-radius: 13px; background: #e9f2f2; color: var(--accent); }
.knowledge-state svg { width: 21px; height: 21px; }
.knowledge-state strong { color: #495964; font-size: 12px; }
.knowledge-state small { max-width: 245px; font-size: 9.5px; line-height: 1.45; }
.knowledge-state button, .knowledge-reader-loading > button[data-knowledge-article-retry] { min-height: 35px; border: 0; border-radius: 9px; padding: 0 12px; background: var(--accent); color: #fff; cursor: pointer; font-size: 10px; font-weight: 800; }
.knowledge-state-icon.is-loading { width: 31px; height: 31px; border: 3px solid #d8e5e6; border-top-color: var(--accent); border-radius: 50%; animation: knowledge-spin .8s linear infinite; }
@keyframes knowledge-spin { to { transform: rotate(360deg); } }

.knowledge-reader { display: flex; flex-direction: column; background: #fff; overflow: hidden; }
.knowledge-reader-empty, .knowledge-reader-loading { height: 100%; display: grid; justify-items: center; align-content: center; gap: 9px; padding: 32px; color: #87949d; text-align: center; }
.knowledge-reader-empty > span, .knowledge-reader-loading > span:not(.knowledge-state-icon) { width: 56px; height: 56px; display: grid; place-items: center; border-radius: 17px; background: #e9f3f3; color: var(--accent); }
.knowledge-reader-empty svg, .knowledge-reader-loading > span svg { width: 26px; height: 26px; }
.knowledge-reader-empty strong, .knowledge-reader-loading strong { color: #44545f; font-size: 14px; }
.knowledge-reader-empty p, .knowledge-reader-loading small { max-width: 300px; margin: 0; font-size: 10.5px; line-height: 1.45; }
.knowledge-reader-loading > button[data-knowledge-back] { display: none; }
.knowledge-reader-head { position: relative; flex: 0 0 auto; padding: 25px 31px 20px; border-bottom: 1px solid var(--line); background: linear-gradient(115deg,#f7fbfb 0%,#fff 72%); }
.knowledge-reader-head::before { content: ''; position: absolute; top: 25px; bottom: 20px; left: 0; width: 4px; border-radius: 0 4px 4px 0; background: var(--accent); }
.knowledge-reader-head > button { display: none; }
.knowledge-reader-actions { position: absolute; z-index: 1; top: 18px; right: 22px; }
.knowledge-reader-actions button { min-height: 36px; display: inline-flex; align-items: center; gap: 7px; border: 1px solid #d4e1e4; border-radius: 10px; padding: 0 11px; background: rgba(255,255,255,.88); color: #657680; cursor: pointer; font-size: 9.5px; font-weight: 800; }
.knowledge-reader-actions button:hover { border-color: #8cbabd; background: #edf6f6; color: var(--accent-dark); }
.knowledge-reader-actions svg { width: 14px; height: 14px; }
.knowledge-article-kicker { display: flex; align-items: center; gap: 7px; margin-bottom: 10px; color: var(--accent); text-transform: uppercase; font-size: 8.5px; letter-spacing: .08em; }
.knowledge-article-kicker > span { width: 25px; height: 25px; display: grid; place-items: center; border-radius: 8px; background: #e1f0f0; }
.knowledge-article-kicker svg { width: 13px; height: 13px; }
.knowledge-reader-head h2 { max-width: 850px; margin: 0; font-size: clamp(23px,2.2vw,34px); line-height: 1.12; letter-spacing: -.035em; }
.knowledge-reader-head > p { max-width: 760px; margin: 11px 0 0; color: #667681; font-size: 12px; line-height: 1.5; }
.knowledge-article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 14px; }
.knowledge-article-meta span { border-radius: 999px; padding: 5px 8px; background: #e8f2f2; color: var(--accent-dark); font-size: 8px; font-weight: 800; }
.knowledge-article-meta time { margin-left: auto; color: #929fa7; font-size: 8.5px; }
.knowledge-article-scroll { flex: 1; min-height: 0; overflow-y: auto; padding: 26px clamp(26px,4vw,62px) 44px; scrollbar-width: thin; scrollbar-color: #d1dadd transparent; }
.knowledge-article-body { max-width: 850px; margin: 0 auto; color: #344550; font-size: 13.5px; line-height: 1.68; }
.knowledge-article-body > :first-child { margin-top: 0; }
.knowledge-article-body > :last-child { margin-bottom: 0; }
.knowledge-article-body h1, .knowledge-article-body h2, .knowledge-article-body h3, .knowledge-article-body h4, .knowledge-article-body h5, .knowledge-article-body h6 { margin: 1.45em 0 .55em; color: var(--ink); line-height: 1.2; letter-spacing: -.02em; }
.knowledge-article-body h1 { font-size: 25px; }
.knowledge-article-body h2 { font-size: 21px; }
.knowledge-article-body h3 { font-size: 17px; }
.knowledge-article-body p, .knowledge-article-body ul, .knowledge-article-body ol, .knowledge-article-body blockquote, .knowledge-article-body pre, .knowledge-article-body table { margin: 0 0 1.05em; }
.knowledge-article-body ul, .knowledge-article-body ol { padding-left: 24px; }
.knowledge-article-body li + li { margin-top: .32em; }
.knowledge-article-body a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 2px; }
.knowledge-article-body blockquote { border-left: 3px solid #57a4a8; border-radius: 0 10px 10px 0; padding: 11px 15px; background: #edf6f6; color: #4c656d; }
.knowledge-article-body code { border-radius: 5px; padding: 2px 5px; background: #edf1f3; color: #354750; font-size: .92em; }
.knowledge-article-body pre { overflow-x: auto; border-radius: 11px; padding: 14px 16px; background: #16242d; color: #e4edf0; }
.knowledge-article-body pre code { padding: 0; background: transparent; color: inherit; }
.knowledge-article-body hr { height: 1px; margin: 25px 0; border: 0; background: var(--line); }
.knowledge-article-body table { width: 100%; border-collapse: collapse; font-size: 11.5px; }
.knowledge-article-body th, .knowledge-article-body td { border: 1px solid #dbe3e7; padding: 8px 9px; text-align: left; vertical-align: top; }
.knowledge-article-body th { background: #f3f7f8; color: #586873; }
.knowledge-inline-image { width: min(760px,100%); display: block; margin: 20px auto; border: 1px solid #d7e1e4; border-radius: 12px; padding: 0; background: #f4f7f8; overflow: hidden; cursor: zoom-in; box-shadow: 0 6px 20px rgba(32,50,61,.07); }
.knowledge-inline-image img { width: 100%; max-height: 620px; display: block; object-fit: contain; }
.knowledge-attachments { max-width: 850px; margin: 34px auto 0; border-top: 1px solid var(--line); padding-top: 20px; }
.knowledge-attachments h3 { display: flex; align-items: center; gap: 7px; margin: 0 0 10px; font-size: 12px; }
.knowledge-attachments h3 span { min-width: 20px; height: 20px; display: grid; place-items: center; border-radius: 999px; background: #e4eff0; color: var(--accent-dark); font-size: 8px; }
.knowledge-attachments > div { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
.knowledge-attachments a { min-width: 0; min-height: 58px; display: grid; grid-template-columns: 35px minmax(0,1fr) 17px; grid-template-rows: auto auto; align-items: center; gap: 2px 9px; border: 1px solid #dce4e7; border-radius: 11px; padding: 8px 10px; color: var(--ink); text-decoration: none; }
.knowledge-attachments a:hover { border-color: #86b9bc; background: #f5f9f9; }
.knowledge-attachments a > span { width: 34px; height: 34px; grid-row: 1 / span 2; display: grid; place-items: center; border-radius: 9px; background: #e6f1f1; color: var(--accent); }
.knowledge-attachments a > span svg { width: 16px; height: 16px; }
.knowledge-attachments a strong, .knowledge-attachments a small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.knowledge-attachments a strong { align-self: end; font-size: 10.5px; }
.knowledge-attachments a small { align-self: start; color: #89969f; font-size: 8px; }
.knowledge-attachments a > svg { width: 15px; height: 15px; grid-column: 3; grid-row: 1 / span 2; color: #82919b; }

body.knowledge-form-open { overflow: hidden; }
.knowledge-form-layer { position: fixed; z-index: 120; inset: 0; display: grid; place-items: center; padding: 18px; background: rgba(23,35,44,.42); backdrop-filter: blur(3px); opacity: 0; transition: opacity .16s ease; }
.knowledge-form-layer[hidden] { display: none; }
.knowledge-form-layer.is-open { opacity: 1; }
.knowledge-form-sheet { width: min(850px,100%); max-height: min(850px,calc(100dvh - 36px)); display: flex; flex-direction: column; overflow: hidden; border: 1px solid #d8e2e5; border-radius: 18px; background: #fff; box-shadow: 0 28px 80px rgba(23,37,48,.28); }
.knowledge-form-sheet > header { min-height: 68px; flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 16px; border-bottom: 1px solid var(--line); padding: 10px 12px 10px 20px; }
.knowledge-form-sheet > header > div { min-width: 0; display: grid; gap: 2px; }
.knowledge-form-sheet > header .eyebrow { margin: 0; }
.knowledge-form-sheet > header h2 { margin: 0; font-size: 17px; }
.knowledge-form-sheet > header button { width: 40px; height: 40px; flex: 0 0 auto; display: grid; place-items: center; border: 0; border-radius: 10px; background: transparent; color: #75858f; cursor: pointer; }
.knowledge-form-sheet > header button:hover { background: #eef3f4; color: var(--ink); }
.knowledge-form-sheet > header svg { width: 18px; height: 18px; }
.knowledge-form-scroll { flex: 1; min-height: 0; overflow-y: auto; display: grid; gap: 15px; padding: 18px 20px 22px; }
.knowledge-form-field { min-width: 0; display: grid; gap: 6px; color: #75848e; font-size: 9px; font-weight: 760; }
.knowledge-form-field > input, .knowledge-form-field > select, .knowledge-form-field > textarea { width: 100%; min-width: 0; border: 1px solid #d6e0e4; border-radius: 10px; padding: 0 11px; background: #fff; color: var(--ink); outline: 0; font: inherit; font-size: 12px; font-weight: 560; }
.knowledge-form-field > input, .knowledge-form-field > select { height: 42px; }
.knowledge-form-field > textarea { min-height: 66px; resize: vertical; padding-block: 10px; line-height: 1.45; }
.knowledge-form-field > :is(input,select,textarea):focus { border-color: #66a8ac; box-shadow: 0 0 0 3px rgba(20,123,130,.08); }
.knowledge-form-name > input { font-size: 14px; font-weight: 700; }
.knowledge-form-row { display: grid; grid-template-columns: 1.1fr 1fr 1fr; gap: 10px; }
.knowledge-form-categories { min-width: 0; margin: 0; border: 1px solid #dce4e7; border-radius: 11px; padding: 10px 11px 11px; }
.knowledge-form-categories legend { padding: 0 5px; color: #75848e; font-size: 9px; font-weight: 760; }
.knowledge-form-categories > div { max-height: 132px; overflow-y: auto; display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 5px 12px; }
.knowledge-form-categories label { min-width: 0; min-height: 34px; display: flex; align-items: center; gap: 7px; border-radius: 8px; padding: 4px 7px 4px calc(7px + var(--knowledge-depth,0) * 10px); color: #53646f; cursor: pointer; font-size: 10.5px; }
.knowledge-form-categories label:hover { background: #f0f5f6; }
.knowledge-form-categories input { accent-color: var(--accent); }
.knowledge-form-categories span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.knowledge-form-categories p { grid-column: 1 / -1; margin: 5px; color: #8b98a1; font-size: 10px; }
.knowledge-editor { overflow: hidden; border: 1px solid #d7e1e4; border-radius: 12px; }
.knowledge-editor > header { min-height: 45px; display: flex; align-items: center; justify-content: space-between; gap: 10px; border-bottom: 1px solid #e0e7e9; padding: 5px 7px 5px 12px; background: #f7f9fa; }
.knowledge-editor > header > span { color: #64757f; font-size: 9px; font-weight: 780; }
.knowledge-editor-toolbar { min-width: 0; display: flex; align-items: center; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.knowledge-editor-toolbar::-webkit-scrollbar { display: none; }
.knowledge-editor-toolbar button { width: 31px; height: 31px; flex: 0 0 auto; display: grid; place-items: center; border: 0; border-radius: 7px; background: transparent; color: #61737d; cursor: pointer; font: inherit; font-size: 10px; font-weight: 800; }
.knowledge-editor-toolbar button:hover { background: #e6eef0; color: var(--accent-dark); }
.knowledge-editor-toolbar button svg { width: 14px; height: 14px; }
.knowledge-editor-toolbar em { font-style: italic; }
.knowledge-editor-body { min-height: 240px; max-height: 440px; overflow-y: auto; padding: 15px 16px 20px; color: #344550; outline: 0; font-size: 13px; line-height: 1.62; overflow-wrap: anywhere; }
.knowledge-editor-body:empty::before { content: attr(data-placeholder); color: #a0abb2; pointer-events: none; }
.knowledge-editor-body > :first-child { margin-top: 0; }
.knowledge-editor-body > :last-child { margin-bottom: 0; }
.knowledge-editor-body :is(h1,h2,h3,h4,h5,h6) { margin: 1.25em 0 .5em; color: var(--ink); line-height: 1.25; }
.knowledge-editor-body p { margin: 0 0 10px; }
.knowledge-editor-body img { max-width: 100%; height: auto; border-radius: 9px; }
.knowledge-editor-body blockquote { margin: 10px 0; border-left: 3px solid #65a8ac; padding: 8px 11px; background: #eef6f6; }
.knowledge-editor-body pre { overflow-x: auto; border-radius: 9px; padding: 11px; background: #17262f; color: #e8f0f2; }
.knowledge-form-error { margin: 0; border-radius: 9px; padding: 9px 11px; background: #fff0ef; color: #a9514b; font-size: 10.5px; line-height: 1.4; }
.knowledge-form-sheet > footer { min-height: 66px; flex: 0 0 auto; display: flex; justify-content: flex-end; align-items: center; gap: 8px; border-top: 1px solid var(--line); padding: 10px 18px; background: #fbfcfc; }
.knowledge-form-sheet > footer button { min-height: 40px; border-radius: 10px; padding: 0 15px; cursor: pointer; font-size: 10.5px; font-weight: 800; }
.knowledge-form-cancel { border: 1px solid #d7e0e4; background: #fff; color: #667781; }
.knowledge-form-save { border: 1px solid var(--accent); background: var(--accent); color: #fff; }
.knowledge-form-save:disabled { opacity: .58; cursor: wait; }
.knowledge-category-form-sheet { width: min(520px,100%); }
.knowledge-category-form-sheet .knowledge-form-scroll { padding-bottom: 26px; }

@media (max-width: 1120px) {
  .knowledge-shell { grid-template-columns: 205px minmax(280px,335px) minmax(390px,1fr); }
  .knowledge-reader-head { padding-inline: 24px; }
  .knowledge-article-scroll { padding-inline: 28px; }
  .knowledge-attachments > div { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .workspace.is-knowledge .topbar { grid-template-columns: auto minmax(0,1fr) auto; }
  .workspace.is-knowledge .page-head { display: none; }
  .knowledge-view { padding: 0 0 72px; }
  .knowledge-shell { display: block; border: 0; border-radius: 0; box-shadow: none; position: relative; overflow: hidden; }
  .knowledge-categories { height: 58px; display: grid; grid-template-columns: minmax(0,1fr) auto; border: 0; border-bottom: 1px solid var(--line); background: #fff; overflow: hidden; }
  .knowledge-categories > header { display: contents; }
  .knowledge-categories > header > span, .knowledge-categories > header > div { display: none; }
  .knowledge-category-create { width: 42px; height: 42px; grid-column: 2; grid-row: 1; align-self: center; margin: 0 8px 0 0; border-radius: 11px; }
  .knowledge-category-create svg { width: 18px; height: 18px; }
  .knowledge-categories nav { height: 100%; grid-column: 1; grid-row: 1; display: flex; align-items: center; gap: 6px; overflow-x: auto; overflow-y: hidden; padding: 7px 6px 7px 10px; scrollbar-width: none; }
  .knowledge-categories nav::-webkit-scrollbar { display: none; }
  .knowledge-category { width: auto; min-width: max-content; min-height: 39px; grid-template-columns: 24px auto auto; gap: 6px; padding: 4px 8px; }
  .knowledge-category > span { width: 24px; height: 24px; }
  .knowledge-category strong { max-width: 150px; font-size: 11px; }
  .knowledge-index { height: calc(100% - 58px); border: 0; }
  .knowledge-index > header { min-height: 78px; display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 7px; padding: 9px 11px; }
  .knowledge-index > header > div { display: contents; }
  .knowledge-index > header .eyebrow, .knowledge-index > header h2 { display: none; }
  .knowledge-create { width: 47px; min-height: 47px; grid-column: 2; grid-row: 1; justify-content: center; padding: 0; border-radius: 12px; }
  .knowledge-create span { display: none; }
  .knowledge-create svg { width: 18px; height: 18px; }
  .knowledge-search { grid-column: 1; grid-row: 1; }
  .knowledge-search { min-height: 47px; grid-template-columns: 19px minmax(0,1fr) 35px; border-radius: 12px; }
  .knowledge-search input { font-size: 16px; }
  .knowledge-search button { width: 35px; height: 35px; }
  .knowledge-list { padding: 7px 8px 16px; }
  .knowledge-card { min-height: 91px; grid-template-columns: 39px minmax(0,1fr) 16px; gap: 10px; padding: 11px 9px; }
  .knowledge-card-mark { width: 38px; height: 38px; }
  .knowledge-card-copy strong { font-size: 13px; }
  .knowledge-card-copy small { font-size: 10.5px; }
  .knowledge-card-copy em { font-size: 9px; }
  .knowledge-reader { position: absolute; z-index: 4; inset: 0; width: 100%; transform: translateX(102%); transition: transform .2s ease; }
  .knowledge-shell.is-reader-open .knowledge-reader { transform: translateX(0); }
  .knowledge-reader-head { padding: max(10px,env(safe-area-inset-top)) 16px 17px; }
  .knowledge-reader-head::before { display: none; }
  .knowledge-reader-head > button, .knowledge-reader-loading > button[data-knowledge-back] { min-height: 39px; display: inline-flex; align-items: center; gap: 6px; margin: 0 0 14px -7px; border: 0; border-radius: 10px; padding: 0 9px; background: transparent; color: var(--accent); cursor: pointer; font-size: 11px; font-weight: 800; }
  .knowledge-reader-actions { top: max(10px,env(safe-area-inset-top)); right: 9px; }
  .knowledge-reader-actions button { width: 40px; height: 39px; justify-content: center; padding: 0; }
  .knowledge-reader-actions span { display: none; }
  .knowledge-reader-head > button svg, .knowledge-reader-loading > button[data-knowledge-back] svg { width: 17px; height: 17px; }
  .knowledge-article-kicker { margin-bottom: 8px; }
  .knowledge-reader-head h2 { font-size: 25px; }
  .knowledge-reader-head > p { font-size: 12.5px; }
  .knowledge-article-meta time { width: 100%; margin: 2px 0 0; }
  .knowledge-article-scroll { padding: 20px 16px 38px; }
  .knowledge-article-body { font-size: 15px; line-height: 1.62; }
  .knowledge-article-body h1 { font-size: 24px; }
  .knowledge-article-body h2 { font-size: 21px; }
  .knowledge-article-body h3 { font-size: 18px; }
  .knowledge-inline-image { margin-block: 17px; }
  .knowledge-attachments > div { grid-template-columns: 1fr; }
  .knowledge-attachments a { min-height: 62px; }
  .knowledge-form-layer { place-items: end stretch; padding: 0; }
  .knowledge-form-sheet { width: 100%; max-height: 100dvh; height: 100dvh; border-width: 0; border-radius: 0; }
  .knowledge-form-sheet > header { min-height: 64px; padding-top: max(8px,env(safe-area-inset-top)); }
  .knowledge-form-scroll { gap: 14px; padding: 15px 13px 20px; }
  .knowledge-form-row { grid-template-columns: 1fr 1fr; }
  .knowledge-form-row > :first-child { grid-column: 1 / -1; }
  .knowledge-form-field > input, .knowledge-form-field > select { height: 47px; font-size: 16px; }
  .knowledge-form-field > textarea { font-size: 16px; }
  .knowledge-form-categories > div { grid-template-columns: 1fr; }
  .knowledge-editor > header { align-items: flex-start; flex-direction: column; }
  .knowledge-editor-toolbar { width: 100%; }
  .knowledge-editor-toolbar button { width: 40px; height: 40px; font-size: 13px; }
  .knowledge-editor-body { min-height: 300px; max-height: none; font-size: 16px; }
  .knowledge-form-sheet > footer { padding-bottom: max(10px,env(safe-area-inset-bottom)); }
  .knowledge-form-sheet > footer button { min-height: 46px; flex: 1; font-size: 12px; }
  .knowledge-category-form-sheet { height: auto; max-height: min(680px,100dvh); border-radius: 18px 18px 0 0; }
}

@media (min-width: 761px) {
  body.compact-ui .knowledge-view { padding-inline: 22px; padding-bottom: 18px; }
  body.compact-ui .knowledge-categories > header { min-height: 64px; }
  body.compact-ui .knowledge-index > header { min-height: 91px; }
  body.compact-ui .knowledge-card { min-height: 80px; }
  body.compact-ui .knowledge-reader-head { padding-top: 20px; padding-bottom: 17px; }
}
