/* R6: workspace-only refinements — retains existing editing, security and storage code. */
/* Keep the school and site identity visible but not oversized. */
.unified-brandbar{height:72px!important;min-height:72px!important;padding:5px 12px!important;gap:9px!important;flex-wrap:nowrap!important;overflow:visible!important}
.unified-brandbar .school-logo{width:34px!important;height:34px!important;font-size:12px!important;flex:none!important}
.unified-brandbar .school-ident{flex:0 1 180px!important;min-width:110px!important;overflow:hidden}
.unified-brandbar .school-label{font-size:13px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.unified-brandbar .school-subtitle{font-size:10px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.unified-brandbar .school-mascot{display:none!important}
.unified-brandbar .yad-site-logo{width:clamp(125px,15vw,200px)!important;max-width:200px!important;min-width:110px!important;flex:0 1 200px!important;height:44px!important}
.unified-brandbar .school-grow,.unified-brandbar .powered-by{display:none!important}
.unified-brandbar .yad-deadline{white-space:normal!important;font-size:clamp(11px,1vw,14px)!important;flex:0 1 245px!important;max-width:245px!important;margin:0!important;padding:5px 8px!important}
/* Canvas settings relocate to the top row without a third permanent toolbar. */
#schoolStrip .canvas-info.yad-header-guides{display:flex!important;gap:5px 8px!important;justify-content:flex-end!important;align-content:center!important;align-items:center!important;min-height:0!important;height:auto!important;margin:0!important;padding:0!important;flex-wrap:wrap!important;font-size:10px!important;line-height:1.25!important;color:#17243D!important;overflow:visible!important}
#schoolStrip .canvas-info.yad-header-guides #adSizeTop{font-size:10px!important;flex:0 0 auto;white-space:nowrap}
#schoolStrip .canvas-info.yad-header-guides .guide-check{font-size:10px!important;gap:3px!important}
#schoolStrip .canvas-info.yad-header-guides .guide-check input{width:13px!important;height:13px!important;margin:0!important}
/* Administrative school switch is relocated out of the parent-facing header. */
#schoolStrip>.school-switch{display:none!important}
#editorMorePanel>.school-switch.yad-admin-school-controls{display:none!important;position:static!important;width:100%!important;margin:0!important;padding:9px!important;gap:5px!important;border:1px solid #ddd6ca!important;background:#FAF8F4!important;flex-wrap:wrap!important;box-shadow:none!important}
body.yad-role-admin #editorMorePanel>.school-switch.yad-admin-school-controls{display:flex!important}
#editorMorePanel>.school-switch.yad-admin-school-controls span{font-size:11px!important;color:#17243D!important}
#editorMorePanel>.school-switch.yad-admin-school-controls select{width:100%!important;min-height:35px!important;font-size:12px!important}
#editorMorePanel>.school-switch.yad-admin-school-controls button{min-height:34px!important;width:100%!important}
/* Give the canvas more lateral room, while maintaining readable Properties controls. */
.main{grid-template-columns:90px 250px minmax(320px,1fr) 230px!important;height:calc(100vh - 126px)!important;min-height:565px!important;padding:8px 5px 6px!important}
.rail .tool{min-height:68px!important;height:clamp(68px,9vh,90px)!important;padding:5px 3px!important;font-size:11px!important;gap:4px!important}
.rail .tool svg{height:25px!important;width:25px!important}
.leftpanel{padding:15px 12px!important}
.rightpanel{padding:13px 9px!important;min-width:0!important;overflow-x:hidden!important;overflow-y:auto!important}
.rightpanel input,.rightpanel select,.rightpanel textarea{max-width:100%!important;min-width:0!important}
.rightpanel .pair>*,.rightpanel .smallrow>*{min-width:0!important}
.rightpanel .font-picker,.rightpanel .font-preview-options{max-width:100%!important;min-width:0!important}
.rightpanel .font-preview-option .sample,.rightpanel .font-rendered-name{max-width:100%!important;overflow:hidden!important;text-overflow:ellipsis!important}
.rightpanel .pair{gap:6px!important}
/* Consistent visual language for the 3 supported text alignment actions. */
#yaQuickControls .ya-align-icon,.ya-q-right-align .ya-align-icon{width:19px!important;height:19px!important;display:block!important;margin:auto;stroke:currentColor!important}
#yaQuickControls button[data-yaquick=left],#yaQuickControls button[data-yaquick=center],#yaQuickControls button[data-yaquick=right],.ya-q-right-align button[data-yaquick=left],.ya-q-right-align button[data-yaquick=center],.ya-q-right-align button[data-yaquick=right]{display:inline-flex!important;align-items:center!important;justify-content:center!important;padding:4px!important}
/* On narrower screens, restore guides above the canvas instead of clipping useful controls. */
@media(max-width:1260px){.main{grid-template-columns:76px 215px minmax(290px,1fr) 220px!important}.unified-brandbar .yad-site-logo{flex-basis:160px!important}.unified-brandbar .school-ident{flex-basis:135px!important}}
@media(max-width:1050px){.unified-brandbar{flex-wrap:wrap!important;height:auto!important;min-height:61px!important}.unified-brandbar .yad-deadline{max-width:190px!important;flex-basis:190px!important}#schoolStrip .canvas-info.yad-header-guides{flex:1 1 100%!important;justify-content:center!important}.main{height:calc(100vh - 150px)!important;grid-template-columns:65px 185px minmax(280px,1fr) 205px!important}.rightpanel{padding:10px!important}}
@media(max-width:790px){.main{height:auto!important;min-height:700px!important;grid-template-columns:72px 1fr!important}.rail{grid-column:1!important;grid-row:1!important}.leftpanel{grid-column:2!important;grid-row:1!important}.editor-center{grid-column:1/3!important;grid-row:2!important}.rightpanel{grid-column:1/3!important;grid-row:3!important}#schoolStrip .canvas-info.yad-header-guides{gap:8px!important}}

/* R8: move original live bottom status into the top-right header, reclaim canvas height. */
#schoolStrip .yad-header-meta{margin-left:auto;min-width:0;flex:1 1 520px;display:flex;flex-direction:column;align-items:stretch;justify-content:center;gap:5px;height:100%;max-width:900px;overflow:visible}
#schoolStrip .yad-header-meta .canvas-info{width:100%!important}
#schoolStrip .yad-header-meta .canvas-bottom{height:auto!important;min-height:0!important;width:100%!important;margin:0!important;padding:0!important;flex:0 0 auto!important;border:0!important;background:transparent!important;box-shadow:none!important;display:flex!important;align-items:center!important;justify-content:flex-end!important;gap:7px 13px!important;flex-wrap:wrap!important;font-size:10px!important;line-height:1.25!important}
#schoolStrip .yad-header-meta .bottomitem{gap:4px!important;font-size:10px!important;font-weight:600!important;white-space:nowrap!important}
#schoolStrip .yad-header-meta #saveStatus{max-width:150px!important;overflow:hidden!important;text-overflow:ellipsis!important;white-space:nowrap!important;display:inline-block!important;vertical-align:middle!important}
#schoolStrip .yad-header-meta #safeToggle{font-size:10px!important;padding:0!important;min-height:unset!important;line-height:1.25!important}
#schoolStrip .yad-header-meta .print-status{font-size:10px!important}
.editor-center>.workspace{padding:3px 12px 8px!important;min-height:0!important}
.editor-center{min-height:0!important}
/* The original 53px bottom status row is no longer part of the editor-center column. */
@media (max-width:1260px){#schoolStrip .yad-header-meta{flex-basis:390px;gap:3px}#schoolStrip .yad-header-meta .canvas-bottom{gap:3px 8px!important}}
@media (max-width:1050px){#schoolStrip .yad-header-meta{flex:1 1 100%;height:auto;min-width:100%;align-items:center}#schoolStrip .yad-header-meta .canvas-info,#schoolStrip .yad-header-meta .canvas-bottom{justify-content:center!important}.unified-brandbar{height:auto!important;min-height:72px!important} .main{height:calc(100vh - 156px)!important}}
@media (max-width:790px){.main{height:auto!important}.editor-center{height:720px!important}#schoolStrip .yad-header-meta .bottomitem{white-space:normal!important}}

/* R9: keep Text panel labels INSIDE the narrow panel; improve button contrast.
   Layout-only correction; no canvas, save, or editing behavior changes. */
.leftpanel,.leftpanel section[data-tool-panel]{min-width:0!important;max-width:100%!important;overflow-wrap:break-word;}
.leftpanel section[data-tool-panel] .note{max-width:100%;overflow-wrap:anywhere;word-break:normal;white-space:normal;line-height:1.5;}
.leftpanel #specialtyTextEdit{display:block!important;box-sizing:border-box!important;width:100%!important;max-width:100%!important;min-width:0!important;height:auto!important;min-height:38px!important;white-space:normal!important;overflow-wrap:break-word!important;word-break:normal!important;line-height:1.3!important;text-align:center!important;padding:8px 7px!important;font-size:12px!important;}
.leftpanel #specialtyTextOpen{box-sizing:border-box!important;width:100%!important;max-width:100%!important;min-width:0!important;height:auto!important;min-height:40px!important;white-space:normal!important;overflow-wrap:break-word!important;line-height:1.3!important;padding:9px 7px!important;background:#17243D!important;color:#fff!important;font-weight:700!important;}
.leftpanel #specialtyTextOpen:hover,.leftpanel #specialtyTextOpen:focus-visible{background:#263a5b!important;color:#fff!important;}
.leftpanel #addText{max-width:100%!important;white-space:normal!important;}

/* R10: exact #id selectors override old editor rules and inline styling. */
.leftpanel button#specialtyTextEdit,
.leftpanel button#specialtyTextOpen {
  box-sizing:border-box!important;
  display:flex!important;
  width:100%!important;
  min-width:0!important;
  max-width:100%!important;
  height:auto!important;
  min-height:40px!important;
  justify-content:center!important;
  align-items:center!important;
  text-align:center!important;
  white-space:normal!important;
  overflow-wrap:anywhere!important;
  word-break:normal!important;
  line-height:1.35!important;
  padding:10px 8px!important;
  font-size:clamp(11px,.85vw,13px)!important;
}
.leftpanel button#specialtyTextOpen,
.leftpanel button#specialtyTextOpen:visited {
  background:#17243D!important;
  color:#ffffff!important;
  -webkit-text-fill-color:#ffffff!important;
}
.leftpanel button#specialtyTextOpen:hover,
.leftpanel button#specialtyTextOpen:focus-visible {
  background:#263A5B!important;
  color:#ffffff!important;
  -webkit-text-fill-color:#ffffff!important;
}
.leftpanel button#specialtyTextEdit{color:#17243D!important;-webkit-text-fill-color:#17243D!important;}
.leftpanel .note{white-space:normal!important;overflow-wrap:anywhere!important;max-width:100%!important;}
