/* Die Inhaltsmaße stammen aus dem angepassten MonoBook; neue Bedienelemente sind separat. */
:root { color-scheme: light; --accent: #264f8c; }
html { scroll-behavior: smooth; }
body { background: white; }
#p-logo { display: block; width: 374px; background-position: 35% 50%; background-repeat: no-repeat; background-size: auto; }
#content { min-height: 70vh; }
#bodyContent { overflow-wrap: break-word; }
#firstHeading { font-family: Arial, sans-serif; margin-bottom: .1em; }
.home-page #firstHeading { display: none; }
.home-page .pw-content > table:first-child { margin-top: 19px; }
.subpage-breadcrumbs { font-size: .85em; color: #54595d; margin: .3em 0 .9em; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; border: 1px solid #a2a9b1; background: #f8f9fa; border-radius: 3px; padding: .3em .65em; color: #202122; }
button:hover { background: #eaf1fa; border-color: #72777d; }
button:disabled { cursor: default; opacity: .55; }
button.primary { background: #264f8c; color: white; border-color: #264f8c; }
input:not([type=checkbox]):not([type=radio]):not([type=file]), select { border: 1px solid #a2a9b1; border-radius: 3px; padding: .3em .4em; max-width: 100%; box-sizing: border-box; }
input[type=checkbox], input[type=radio] { accent-color: #264f8c; }
button:focus-visible, a:focus-visible, input:focus-visible, textarea:focus-visible { outline: 3px solid #36c; outline-offset: 2px; }
#p-personal form { display: inline; }
.link-button { border: 0; padding: 0; background: transparent; color: #002bb8; border-radius: 0; }
.link-button:hover { text-decoration: underline; background: transparent; }
#p-search button { font: 13px Arial, sans-serif; margin-top: .15em; padding: 1px 7px; border-radius: 0; }
#p-search input { width: 100%; padding: 1px 2px; border-radius: 0; }
.portlet form { margin: .3em 0; }
.portlet button { font-size: .8em; }
.notice, .error { padding: .8em 1em; margin: 1em 0; border: 1px solid #a3b9d3; background: #f0f5fc; border-radius: 3px; }
.error { border-color: #d33; background: #fff1f1; }
.small { font-size: .85em; color: #54595d; }
.badge { font-size: .75em; border-radius: 3px; background: #eaf3ff; color: #245390; padding: .1em .35em; }
.form-stack { display: grid; gap: .8em; max-width: 30em; margin: 1em 0; }
.form-stack label { display: grid; gap: .25em; }
.form-stack input { width: 100%; }
.registration-captcha { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.registration-captcha img { display: block; width: 220px; height: auto; max-width: 100%; border: 1px solid #c8ccd1; border-radius: 4px; }
#registration-form #captcha-help { margin: 0; }
.source-editor { box-sizing: border-box; display: block; width: 100%; max-width: 100%; min-height: 25em; resize: vertical; border: 1px solid #a2a9b1; border-radius: 3px; padding: .8em; background: #fbfcfe; color: #202122; font: 14px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; tab-size: 2; }
.source-view { white-space: pre-wrap; overflow-wrap: anywhere; }
.file-preview { max-width: 100%; height: auto; }
.file-details video { max-width: 100%; max-height: 70vh; }
.pw-media { max-width: 100%; }
video.pw-media { height: auto; }
.pw-video { display: inline-block; max-width: 100%; margin: 3px; vertical-align: top; }
.pw-video-embed { display: block; height: auto; border: 0; }
.pw-video-link { display: block; font-size: .85em; }
.editor-toolbar { position: sticky; top: 0; z-index: 20; display: flex; flex-wrap: wrap; align-items: center; gap: 7px 12px; box-sizing: border-box; padding: 8px; margin: 0 0 7px; border: 1px solid #d6dde6; border-radius: 6px; background: #fafbfe; box-shadow: 0 3px 8px #152a4d14; font: 13px/1.35 Arial, sans-serif; }
.editor-language-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; max-width: 100%; min-width: 0; }
.editor-language, #editor-compiler-field { display: inline-flex; align-items: center; gap: 6px; min-width: 0; margin: 0; color: #54595d; }
#editor-language { width: 145px; max-width: 100%; height: 32px; padding: 4px 7px; background: #fff; font-size: 13px; }
.editor-tool-groups { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; min-width: 0; }
.editor-tool-group { display: inline-flex; flex: 0 0 auto; align-items: center; gap: 2px; padding-right: 10px; border-right: 1px solid #dce2ea; }
.editor-tool-group:last-child { padding-right: 0; border-right: 0; }
.editor-toolbar .editor-tool { display: inline-flex; align-items: center; justify-content: center; flex: 0 0 auto; box-sizing: border-box; width: 32px; height: 32px; padding: 5px; border: 1px solid transparent; border-radius: 4px; background: transparent; color: #33445d; }
.editor-toolbar .editor-tool:hover:not(:disabled) { border-color: #b4c7e0; background: #e8f0fb; color: #183e73; }
.editor-toolbar .editor-tool:active:not(:disabled) { background: #d5e4f8; }
.editor-toolbar .editor-tool:disabled { opacity: .35; }
.editor-toolbar .editor-tool[data-save] { border-color: #264f8c; background: #264f8c; color: #fff; }
.editor-toolbar .editor-tool[data-save]:hover { border-color: #183e73; background: #183e73; color: #fff; }
.editor-tool svg { display: block; width: 20px; height: 20px; }
.editor-toolbar [hidden] { display: none; }
#editor-compiler-field[hidden] { display: none; }
#editor-compiler-url { width: 235px; max-width: 100%; height: 32px; padding: 4px 7px; font-size: 13px; }
#editor-language-status { flex-basis: 100%; color: #a20; font-size: 12px; overflow-wrap: anywhere; }
#editor-language-status:empty { display: none; }
.editor-tool-tooltip { position: fixed; z-index: 1000; box-sizing: border-box; max-width: min(280px, calc(100vw - 16px)); padding: 8px 11px; border-radius: 6px; background: #233149; color: #fff; box-shadow: 0 4px 14px #101e3533; font: 12px/1.45 Arial, sans-serif; overflow-wrap: anywhere; }
.editor-tool-tooltip[hidden] { display: none; }
@media (max-width: 600px) {
  .editor-toolbar { gap: 6px 8px; padding: 6px; }
  .editor-tool-groups { gap: 6px; }
  .editor-tool-group { padding-right: 6px; }
  #editor-compiler-field { flex: 1; }
  #editor-compiler-url { width: 100%; min-width: 0; }
}
@media (max-height: 400px) {
  .editor-toolbar { max-height: 45vh; overflow: auto; }
}
.editor-image-dialog { box-sizing: border-box; width: min(980px, calc(100vw - 32px)); max-width: none; max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); padding: 0; overflow: hidden; border: 1px solid #c8ccd1; border-radius: 10px; background: #fff; color: #202122; box-shadow: 0 16px 60px #0004; font: 14px/1.45 Arial, sans-serif; }
.editor-image-dialog[open] { display: flex; flex-direction: column; }
.editor-image-dialog *, .editor-image-dialog *::before, .editor-image-dialog *::after { box-sizing: border-box; }
.editor-image-dialog::backdrop { background: #18223080; }
.editor-image-header { display: flex; flex: 0 0 auto; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 20px 24px 16px; border-bottom: 1px solid #eaecf0; }
.editor-image-dialog h2 { margin: 0; padding: 0; border: 0; font: bold 21px/1.25 Arial, sans-serif; }
.editor-image-header p { margin: 5px 0 0; color: #54595d; }
.editor-image-close { flex: 0 0 auto; width: 32px; height: 32px; padding: 0; border-color: transparent; background: transparent; font-size: 24px; line-height: 1; }
#editor-image-form { display: flex; flex: 1 1 auto; flex-direction: column; min-height: 0; margin: 0; }
.editor-image-body { display: grid; flex: 1 1 auto; grid-template-columns: minmax(0, 1fr) 270px; gap: 22px; min-height: 0; padding: 20px 24px; overflow: auto; }
.editor-image-library { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.editor-image-search-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 8px; }
.editor-image-dialog label { display: grid; gap: 5px; min-width: 0; font-size: 13px; font-weight: bold; }
#editor-image-form input:not([type="checkbox"]), #editor-image-form select { width: 100%; min-width: 0; min-height: 36px; padding: 7px 9px; background: #fff; font-size: 14px; font-weight: normal; }
.editor-image-dialog button { min-height: 36px; padding: 7px 12px; font-size: 14px; line-height: 1.35; }
.editor-image-dialog .editor-image-close { min-height: 32px; padding: 0; font-size: 24px; line-height: 1; }
.editor-image-results { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(116px, 100%), 1fr)); grid-auto-rows: 150px; align-content: start; gap: 8px; min-width: 0; min-height: 150px; max-height: min(44vh, 380px); padding: 3px; overflow: auto; overscroll-behavior: contain; scrollbar-gutter: stable; }
.editor-image-dialog .editor-image-card { display: grid; grid-template-rows: 88px minmax(0, 1fr); align-content: start; gap: 7px; width: 100%; height: 150px; min-width: 0; min-height: 0; padding: 9px; overflow: hidden; border: 1px solid #d8dde5; border-radius: 6px; background: #fff; text-align: center; }
.editor-image-card:hover { border-color: #6484ad; background: #f5f8fc; }
.editor-image-dialog .editor-image-card[aria-pressed="true"] { border-color: #264f8c; background: #edf3fc; box-shadow: inset 0 0 0 1px #264f8c; }
.editor-image-thumbnail { display: grid; place-items: center; width: 100%; height: 88px; min-width: 0; min-height: 0; overflow: hidden; border-radius: 3px; background: #f3f5f7; color: #72777d; font-size: 11px; font-weight: normal; }
.editor-image-thumbnail img { display: block; width: 100%; height: 100%; max-width: 100%; max-height: 100%; margin: 0; object-fit: contain; }
.editor-image-filename { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; min-width: 0; min-height: 0; max-height: 2.6em; overflow: hidden; overflow-wrap: anywhere; font-size: 12px; font-weight: normal; line-height: 1.3; }
#editor-image-more { align-self: center; margin-top: 2px; }
.editor-image-status { min-height: 1.45em; margin: 0; color: #54595d; font-size: 12px; overflow-wrap: anywhere; }
.editor-image-settings { display: grid; align-content: start; gap: 15px; min-width: 0; padding: 16px; border: 1px solid #e1e5eb; border-radius: 7px; background: #f7f9fc; }
.editor-image-settings h3 { margin: 0; padding: 0 0 2px; border: 0; font: bold 15px/1.4 Arial, sans-serif; }
.editor-image-dimensions { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
.editor-image-hint { margin: -9px 0 0; color: #54595d; font-size: 12px; }
.editor-image-dialog .editor-image-checkbox { display: flex; align-items: flex-start; gap: 8px; font-weight: normal; }
#editor-image-form input[type="checkbox"] { flex: 0 0 auto; width: 16px; height: 16px; margin: 2px 0 0; }
.editor-image-actions { display: flex; flex: 0 0 auto; align-items: center; flex-wrap: wrap; gap: 8px; padding: 14px 24px; border-top: 1px solid #eaecf0; background: #fafbfc; }
.editor-image-actions a { margin-right: auto; font-size: 13px; }
.editor-image-dialog [hidden] { display: none; }
@media (max-width: 700px) {
  .editor-image-dialog { width: calc(100vw - 16px); max-height: calc(100vh - 16px); max-height: calc(100dvh - 16px); }
  .editor-image-header { padding: 16px; }
  .editor-image-body { grid-template-columns: minmax(0, 1fr); gap: 16px; padding: 16px; }
  .editor-image-results { max-height: 300px; }
  .editor-image-actions { padding: 12px 16px; }
}
@media (max-width: 400px) {
  .editor-image-actions a { flex-basis: 100%; margin: 0 0 4px; }
  .editor-image-actions button { flex: 1; }
}
@media (max-height: 500px) {
  .editor-image-dialog[open] { display: block; overflow: auto; }
  .editor-image-header { padding: 12px 16px; }
  .editor-image-header p { display: none; }
  #editor-image-form { display: block; }
  .editor-image-body { padding: 12px 16px; overflow: visible; }
  .editor-image-results { max-height: 150px; }
  .editor-image-actions { padding: 10px 16px; }
}
.editor-footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 8px; padding: 12px 0; }
.editor-footer #draft-status { margin-right: auto; color: #54595d; font-size: 12px; }
@media (max-width: 600px) {
  .editor-footer #draft-status:not(:empty) { flex-basis: 100%; }
}
#editor-preview { border-top: 2px solid #a2a9b1; margin-top: 2em; padding-top: 1em; }
.diff-table { width: 100%; border-collapse: collapse; }
.diff-table td { vertical-align: top; border-bottom: 1px solid #eaecf0; }
.diff-table td:first-child { width: 2em; text-align: center; }
.diff-table pre { white-space: pre-wrap; margin: 0; border: 0; background: transparent; overflow-wrap: anywhere; }
.diff-add { background: #e6f6e9; }
.diff-remove { background: #ffe7e6; }
table.wikitable { border-collapse: collapse; margin: 1em 0; }
table.wikitable th, table.wikitable td { border: 1px solid #a2a9b1; padding: .3em .6em; }
table.wikitable th { background: #eaecf0; }
.pw-code { margin: .65em 0; max-width: 100%; }
.pw-code-input { display: block; width: var(--pw-code-width, 100%); height: var(--pw-code-height, auto); max-width: 100%; box-sizing: border-box; padding: 3px; font: 13px/1.25 monospace; tab-size: 2; border: 1px solid #ddd; border-radius: 0; background: #f9f9f9; color: #202122; }
.pw-code-input[data-size-cols="explicit"] { width: var(--pw-code-width, calc(var(--pw-code-cols, 60) * 1ch + 8px)); }
.pw-code .CodeMirror { width: var(--pw-code-width, 100%); height: var(--pw-code-height, calc(var(--pw-code-rows, 2) * 1.25em + 8px)); max-width: 100%; box-sizing: border-box; border: 1px solid #ddd; background: #f9f9f9; color: #111; font: 13px/1.25 monospace; resize: vertical; min-height: 2em; }
.pw-code .CodeMirror[data-size-cols="explicit"] { width: var(--pw-code-width, calc(var(--pw-code-cols, 60) * 1ch + 3.5em)); }
.pw-code .CodeMirror-scroll { min-height: 0; }
.pw-code .CodeMirror-gutters { background: #e2f6cb; border-right: 1px solid #ddd; }
.pw-code .CodeMirror-linenumber { color: #59694b; font-size: 11px; padding: 0 4px 0 2px; min-width: 15px; }
.pw-code .CodeMirror-lines { padding: 3px 0; }
.pw-code .CodeMirror pre.CodeMirror-line, .pw-code .CodeMirror pre.CodeMirror-line-like { padding-left: 5px; }
.pw-code .CodeMirror-dialog { font: 12px/1.5 Arial, sans-serif; }
.pw-code .CodeMirror-dialog input { width: auto; padding: 1px 2px; }
.pw-code[data-width="full"] .pw-code-input { width: 100%; }
.pw-code-toolbar { display: flex; align-items: center; flex-wrap: wrap; gap: 5px; margin: 5px 0; }
.pw-code-toolbar button, .pw-check-button { font: 12px/1.25 Arial, sans-serif; border: 1px solid #aaa; border-radius: 0; padding: 2px 6px; margin: 0; }
.pw-code-toolbar .pw-run-button { font-weight: bold; color: #111; background: #dfffc5; }
.pw-code-toolbar .pw-run-button:hover { background: #d0f5ae; }
.pw-code-toolbar [hidden] { display: none; }
.pw-runtime-session { padding: 5px 0; border-bottom: 1px solid #ddd; font-size: 12px; }
.pw-runtime-session-status { margin-right: .5em; }
.pw-output { white-space: pre-wrap; min-height: 1.3em; padding: 5px 8px 5px 28px; margin: 7px 0 12px; overflow: auto; max-height: 32em; border: 1px solid #ddd; background: #f9f9f9; font: 13px/1.25 monospace; position: relative; }
.pw-output:before { content: ">"; position: absolute; left: 8px; color: #888; font-weight: bold; }
.pw-check-button { margin: .35em .35em .35em 0; }
.pw-save-status { font: 11px/1.35 Arial, sans-serif; color: #666; margin-left: auto; }
.pw-input-dialog { width: min(32em, 85vw); padding: 1.2em; border: 1px solid #888; border-radius: 4px; background: white; color: #111; box-shadow: 0 5px 25px #0005; font: 14px/1.4 Arial, sans-serif; }
.pw-input-dialog::backdrop { background: #0005; }
.pw-input-dialog label { display: grid; gap: .8em; }
.pw-input-message { white-space: pre-wrap; overflow-wrap: anywhere; }
.pw-input-dialog input { width: 100%; }
.pw-input-actions { display: flex; flex-wrap: wrap; gap: .5em; margin-top: 1em; }
.pw-input-actions button:first-child { background: #dfffc5; }
.pw-input-actions [hidden] { display: none; }
.pw-canvas { display: block; border: 1px solid #ddd; max-width: 100%; height: auto; background: white; margin: 5px 0; }
.pw-teacher-panel { background: #ffe89a; border: 1px solid #ddd; padding: 4px 6px; margin: 1em 0 .6em; font-size: .95em; }
.pw-teacher-panel summary { font-weight: bold; cursor: pointer; }
.pw-teacher-panel summary:after { content: "anzeigen"; display: inline-block; margin-left: .5em; padding: 0 6px; border: 1px solid #999; background: #eee; color: #111; font: 12px/1.4 Arial, sans-serif; }
.pw-teacher-panel[open] summary:after { content: "ausblenden"; }
.pw-teacher-panel p { margin-bottom: 0; font-size: .9em; }
.pw-teacher-panel-links { margin: 7px 0; font-size: 12px; }
.pw-teacher-count { font-weight: normal; }
.pw-learner-list { display: grid; gap: 4px; margin: 7px 0; }
.pw-learner-row { display: flex; align-items: center; gap: 7px; padding: 4px 6px; background: white; border: 1px solid #aaa; }
.pw-learner-row.is-active { background: #c5eeff; border-color: #55849b; }
.pw-learner-row.is-hidden { border-style: dashed; }
.pw-learner-select { flex: 0 0 auto; }
.pw-learner-select-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); }
.pw-learner-info { flex: 1; min-width: 0; display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 8px; font-size: 13px; }
.pw-learner-name { overflow-wrap: anywhere; }
.pw-learner-display-name, .pw-learner-counts, .pw-learner-updated, .pw-learner-profile, .pw-learner-locked, .pw-learner-hidden, .pw-learner-legacy { font-size: 11px; }
.pw-learner-counts, .pw-learner-updated { color: #54595d; }
.pw-learner-score { margin-left: auto; white-space: nowrap; font-size: 12px; }
.pw-learner-score.is-stale { color: #8b4c00; }
.pw-learner-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 4px; margin: 0; }
.pw-learner-actions button, .pw-teacher-bulk button, .pw-teacher-bulk select { font: 11px/1.3 Arial, sans-serif; border-radius: 0; padding: 2px 5px; }
.pw-teacher-bulk { margin: 9px 0 4px; font-size: 12px; }
.pw-teacher-bulk label { display: inline-flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.pw-teacher-select-all { margin-right: 6px; }
.pw-teacher-selection-count { margin-right: 12px; color: #54595d; }
@media (max-width: 1000px) {
  .pw-learner-row { flex-wrap: wrap; }
  .pw-learner-actions { margin-left: 22px; }
  .pw-learner-counts { flex-basis: 100%; }
}
.pw-runtime-bar { padding: .4em .6em; background: #f8f9fa; border: 1px solid #c8ccd1; font-size: .85em; }
.pw-runtime-bar button { margin-left: .5em; }
.pw-runtime-warning, .pw-warning, .pw-unsupported { display: block; border-left: 3px solid #e0b23b; background: #fff9e9; padding: .5em .8em; margin: .8em 0; }
.pw-check { display: flex; flex-direction: column; padding: 6px 8px; margin: 8px 0; min-height: 50px; border: 1px solid #ddd; background: white; }
.pw-check .pw-check-result { order: -1; display: block; min-height: 1.3em; font-weight: bold; }
.pw-check .pw-code-toolbar { margin-bottom: 0; }
.pw-check .pw-code-toolbar .pw-check-button { background: #ffe396; font-weight: bold; }
.pw-check-result[data-success="true"] { color: #14833b; }
.pw-check-result[data-success="false"] { color: #b32424; }
.pw-popup { display: inline-block; margin: .3em 0; }
.pw-popup summary { color: #002bb8; cursor: pointer; }
.pw-popup[open] { display: block; border: 1px solid #aaa; padding: .6em; }
.pw-gallery { display: flex; flex-wrap: wrap; gap: 1em; }
.pw-gallery figure { margin: 0; border: 1px solid #c8ccd1; padding: .5em; }
.pw-math { font-family: serif; }
.page-list { columns: 2 22em; }
.search-result h2 { font-size: 1.2em; border: 0; margin-bottom: .2em; }
.search-result p { max-width: 70em; }
.sr-only, .skip-link:not(:focus) { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link:focus { position: absolute; z-index: 1000; left: 1em; top: 1em; background: white; padding: 1em; }
#footer { font-size: .75em; color: #54595d; }
@media (max-width: 760px) {
  #globalWrapper { width: 100%; }
  #column-content { float: none; margin: 0; width: auto; }
  #content { margin: 7.5em .5em 0; padding: .6em .8em; min-height: 55vh; }
  #column-one { padding: 0 .5em; }
  #p-logo { width: 6em; height: 4em; top: .5em; left: .5em; background-size: contain; }
  #p-personal { top: .5em; right: .5em; left: 7em; width: auto; font-size: .8em; }
  #p-cactions { top: 5.2em; left: .5em; right: .5em; font-size: .8em; overflow: auto; padding: .2em 0; }
  #p-cactions ul { display: flex; white-space: nowrap; }
  .portlet:not(#p-cactions):not(#p-personal) { position: static; width: auto; display: inline-block; vertical-align: top; margin: .6em; }
  #footer { margin: 1em; }
  .pw-code-input { width: 100%; }
  .wikitable { display: block; overflow: auto; }
  .page-list { columns: 1; }
}
@media print {
  #column-one, .editor-toolbar, .pw-run-button, .pw-check-button, .pw-runtime-bar, #p-personal { display: none !important; }
  #column-content, #content { margin: 0; padding: 0; float: none; border: none; }
  body { background: white; }
}
