/*
 * csp-utilities.css — CSP 收斂（style-src）共用工具類別
 * -------------------------------------------------------------------------------
 * 嚴格 style-src 'self' 會擋下 HTML 解析出的 style="…" 屬性與 <style> 區塊。
 * 全站 legacy 頁面重複出現同一批內聯樣式（display:none、float、text-align、
 *   固定寬度、紅字提示…）。把這些「單一用途、可跨頁重用」的樣式集中在本檔，
 *   由三個 app 的 layout header 全域載入 → 每一頁（含未來新頁）直接套 class 即可，
 *   不必各自再開一支 CSS。頁面專屬的複合樣式仍放各自的 <page>.css。
 *
 * 命名慣例：u-（utility）前綴、單一用途、原子化。
 * 注意：初始隱藏用 .u-hidden 不加 !important —— kendoWindow/JS 開啟時以 inline
 *   style（CSSOM）覆蓋顯示，加 !important 會使其無法開啟。
 */

/* ---- Kendo 2026 legacy 字型圖示相容（@import 必須排在所有規則之前）----
 * Kendo 2026 把 kendo.common.min.css 縮成 stub，k-i-* 圖示定義搬到
 *   kendoui/styles/font-icons/index.css，且字型只掛在新的 .k-font-icon 上。
 * 全站 legacy markup 仍是 <span class="k-icon k-i-refresh">，升級後圖示會整個消失
 *   （「重新整理」等按鈕只剩文字）。這裡全域補回，避免三個 app 20+ 頁逐頁改 markup。
 * 只作用在同時帶 k-i-* 的元素，並排除 Kendo 2026 自己輸出的 .k-svg-icon / .k-font-icon。
 */
@import url("../../../kendoui/styles/font-icons/index.css");

.k-icon[class*="k-i-"]:not(.k-svg-icon):not(.k-font-icon) {
	font-family: "WebComponentsIcons";
	font-style: normal;
	font-variant: normal;
	font-weight: normal;
	font-size: var(--kendo-icon-size, 16px);
	line-height: 1;
	width: 1em;
	height: 1em;
	speak: none;
	text-transform: none;
	text-decoration: none;
	display: inline-block;
	vertical-align: middle;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

/* ---- 顯示 / 隱藏 ---- */
.u-hidden { display: none; }

/* ---- 浮動 / 對齊 ---- */
.u-float-left  { float: left !important; }
.u-float-right { float: right !important; }
.u-text-center { text-align: center !important; }
.u-text-left   { text-align: left !important; }
.u-text-right  { text-align: right !important; }
.u-text-justify { text-align: justify !important; }
.u-va-middle   { vertical-align: middle; }
.u-list-none   { list-style: none; }

/* ---- 常用固定寬度（對應 legacy 常見 input 寬度）---- */
.u-w90  { width: 90px; }
.u-w60  { width: 60px; }
.u-w16  { width: 16px; }
.u-w50  { width: 50px; }
.u-w100 { width: 100px; }
.u-w110 { width: 110px; }
.u-w120 { width: 120px; }
.u-w150 { width: 150px; }
.u-w160 { width: 160px; }
.u-w180 { width: 180px; }
.u-w200 { width: 200px; }
.u-w250 { width: 250px; }
.u-w260 { width: 260px; }
.u-w300 { width: 300px; }
.u-w350 { width: 350px; }
.u-w400 { width: 400px; }
.u-w80p { width: 80%; }
.u-w92p { width: 92%; }
.u-w98p { width: 98%; }
.u-w99p { width: 99%; }
.u-w100p { width: 100%; }

/* ---- 紅色小字提示（如「檔案不可大於…」）---- */
.u-hint-text { color: red; font-size: 12px; }

/* ---- 其他原子樣式 ---- */
.u-ml5     { margin-left: 5px; }
.u-mr5     { margin-right: 5px; }
.u-mt0     { margin-top: 0; }
.u-mt5     { margin-top: 5px; }
.u-mt2     { margin-top: 2px; }
.u-mt3     { margin-top: 3px; }
.u-mt-neg2 { margin-top: -2px; }
.u-font16  { font-size: 16px; }
.u-mb5     { margin-bottom: 5px; }
.u-mb7     { margin-bottom: 7px; }
.u-m0      { margin: 0; }
.u-m5      { margin: 5px; }
.u-m10     { margin: 10px; }
.u-p0      { padding: 0; }
.u-p1      { padding: 1px; }
.u-h25     { height: 25px; }
.u-maxw100 { max-width: 100%; }
.u-fs14    { font-size: 14px; }
.u-fs17    { font-size: 17px; }
.u-fs20    { font-size: 20px; }
.u-fs22    { font-size: 22px; }
.u-fs15    { font-size: 15px; }
.u-h16     { height: 16px; }
.u-lh15    { line-height: 15px; }
.u-lh20    { line-height: 20px; }
.u-border-bottom0 { border-bottom: 0; }
.proof-data-checkbox { width: 16px; height: 16px; display: table-cell; }
.u-pos-rel { position: relative; }
.u-top-neg2 { top: -2px; }

/* ---- 共用 legacy 表單 / grid 工具列元件 ---- */
.csp-form-table td { padding: 5px !important; }
#company_user_fm .k-combobox,
#company_user_fm .k-dropdown,
#company_user_fm .k-multiselect,
#company_user_fm .k-datepicker,
#company_user_fm input[type="text"],
#company_user_fm input[type="password"],
#company_dept_fm input[type="text"],
#batch_expiration_date_fm .k-datepicker,
#batch_expiration_date_fm input[type="text"],
#batch_edit_user_passwd_fm input[type="password"] {
	width: 200px !important;
	box-sizing: border-box;
}
#company_user_fm .k-datepicker .k-input,
#company_user_fm .k-combobox .k-input,
#batch_expiration_date_fm .k-datepicker .k-input {
	width: 100% !important;
}
#question_profile_fm .k-dropdown,
#question_profile_fm .k-combobox,
#question_profile_fm .k-datepicker,
#question_profile_fm input[type="text"] {
	width: 250px !important;
	box-sizing: border-box;
}

/* ============================================================
 * 共用元件（跨 app 共用 partial）——非原子，但因 partial 三個 app 共用、
 * 且本檔已全域載入，放這裡最省事。
 * ------------------------------------------------------------
 * views/common/preview/index.php（檔案預覽 kendoWindow）
 *   原 #preview_window 的 style="display:none; max-width:100%; max-height:90svh;"
 *   與 #preview_img 的 style="max-width:100%;" 改用以下 class。
 * ============================================================ */
.preview-window {
	display: none;
	max-width: 100%;
	max-height: 90svh;
}
.preview-img { max-width: 100%; }
.k-window.preview-window-wrapper {
    z-index: 20001 !important;
}

/* ============================================================
 * vendored ace.min.js patch（style-src 收斂）
 * ------------------------------------------------------------
 * ace.min.js 原本用 jQuery wrap/建立元素時夾帶 inline style
 *   （sidebar scroll 包裝的 position:relative、ajax 載入遮罩的 position:fixed）
 *   會被嚴格 style-src 擋。已把該兩處 inline style 改成以下 class（原檔備份
 *   ace.min.js.prestyle-bak）。本檔全域載入，三個 app 的 ace 都吃得到。
 * ============================================================ */
.ace-pos-rel { position: relative; }
.ace-ajax-overlay { position: fixed; z-index: 2000; }

.ckfinder-raw-response {
    width: 600px;
    overflow: scroll;
}

/* CKEditor5 shim height classes (replaces runtime inline min-height). 嚴格排除 .ck-editor__nested-editable 避免污染表格內部儲存格 */
.csp-ckeditor-height-100 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-100.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-100:not(.ck-editor__nested-editable) { min-height: 100px !important; }
.csp-ckeditor-height-120 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-120.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-120:not(.ck-editor__nested-editable) { min-height: 120px !important; }
.csp-ckeditor-height-150 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-150.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-150:not(.ck-editor__nested-editable) { min-height: 150px !important; }
.csp-ckeditor-height-180 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-180.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-180:not(.ck-editor__nested-editable) { min-height: 180px !important; }
.csp-ckeditor-height-200 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-200.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-200:not(.ck-editor__nested-editable) { min-height: 200px !important; }
.csp-ckeditor-height-250 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-250.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-250:not(.ck-editor__nested-editable) { min-height: 250px !important; }
.csp-ckeditor-height-300 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-300.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-300:not(.ck-editor__nested-editable) { min-height: 300px !important; }
.csp-ckeditor-height-350 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-350.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-350:not(.ck-editor__nested-editable) { height: 350px !important; min-height: 350px !important; max-height: 350px !important; overflow-y: auto !important; }
.csp-ckeditor-height-400 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-400.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-400:not(.ck-editor__nested-editable) { min-height: 400px !important; }
.csp-ckeditor-height-450 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-450.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-450:not(.ck-editor__nested-editable) { min-height: 450px !important; }
.csp-ckeditor-height-500 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-500.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-500:not(.ck-editor__nested-editable) { min-height: 500px !important; }
.csp-ckeditor-height-550 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-550.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-550:not(.ck-editor__nested-editable) { min-height: 550px !important; }
.csp-ckeditor-height-567 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-567.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-567:not(.ck-editor__nested-editable) { min-height: 567px !important; }
.csp-ckeditor-height-580 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-580.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-580:not(.ck-editor__nested-editable) { min-height: 580px !important; }
.csp-ckeditor-height-600 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-600.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-600:not(.ck-editor__nested-editable) { min-height: 600px !important; }
.csp-ckeditor-height-678 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-678.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-678:not(.ck-editor__nested-editable) { min-height: 678px !important; }
.csp-ckeditor-height-700 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-700.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-700:not(.ck-editor__nested-editable) { min-height: 700px !important; }
.csp-ckeditor-height-750 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-750.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-750:not(.ck-editor__nested-editable) { min-height: 750px !important; }
.csp-ckeditor-height-800 .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-800.ck-editor__editable:not(.ck-editor__nested-editable), .csp-ckeditor-height-800:not(.ck-editor__nested-editable) { min-height: 800px !important; }

/* CKEditor 5 table nested editable: replaces its blocked padding:0px style attribute. */
.ck.ck-content td.ck-editor__nested-editable { padding: 0 !important; }

/* CKEditor 5 overflow & toolbar wrapping defense */
.ck.ck-editor {
	width: 100% !important;
	max-width: 100% !important;
	box-sizing: border-box !important;
}

.ck.ck-editor__top .ck-toolbar {
	flex-wrap: wrap !important;
	max-width: 100% !important;
}

.ck.ck-editor__top .ck-toolbar__items {
	flex-wrap: wrap !important;
}

/* CodeIgniter PHP error partial shared by admin, teacher, and web. */
.csp-php-error-panel {
	border: 1px solid #990000;
	padding-left: 20px;
	margin: 0 0 10px;
}

/* ---- Kendo Grid 表格欄位與內容文字全域置中 ---- */
.k-grid th,
.k-grid th.k-header,
.k-grid-header th.k-header,
.k-grid-header .k-header,
.k-grid-header th,
.k-grid-header .k-grid-header-wrap th {
	text-align: center !important;
}

.k-grid th .k-link,
.k-grid th.k-header > .k-link,
.k-grid-header th.k-header > .k-link,
.k-grid-header .k-header > .k-link,
.k-grid .k-link,
.k-grid-header .k-link {
	text-align: center !important;
	justify-content: center !important;
	display: flex !important;
	align-items: center !important;
}

.k-grid td,
.k-grid-content td,
.k-grid table td,
.k-grid tbody td {
	text-align: center;
}

.k-grid td.u-text-left,
.k-grid-content td.u-text-left,
.k-grid table td.u-text-left,
.k-grid tbody td.u-text-left,
.k-grid td.table-cell.u-text-left {
	text-align: left !important;
}

.k-grid td.u-text-right,
.k-grid-content td.u-text-right,
.k-grid table td.u-text-right,
.k-grid tbody td.u-text-right,
.k-grid td.table-cell.u-text-right {
	text-align: right !important;
}

/* ---- 全域 Kendo Grid 工具列 (Toolbar) 滿版與左右對齊 ---- */
.k-grid .k-grid-toolbar,
.k-grid .k-toolbar,
.k-grid > .k-toolbar {
	width: 100% !important;
	box-sizing: border-box !important;
	padding: 4px 8px !important;
	margin: 0 !important;
	min-height: auto !important;
	height: auto !important;
	display: flex !important;
	align-items: center !important;
	justify-content: space-between !important;
}

/* 隱藏 Kendo UI 自動產生的多餘空子元素與 Spacer 容器（解決右半邊多餘空區域） */
.k-grid .k-grid-toolbar > *:empty,
.k-grid .k-grid-toolbar .k-toolbar-item:empty,
.k-grid .k-grid-toolbar .k-spacer,
.k-grid .k-grid-toolbar .k-toolbar-spacer,
.k-grid .k-grid-toolbar .k-toolbar-overflow-button,
.k-grid .k-grid-toolbar .k-overflow-anchor {
	display: none !important;
	width: 0 !important;
	height: 0 !important;
	padding: 0 !important;
	margin: 0 !important;
	flex: 0 0 0 !important;
}

/* 讓主要裝有 grid_top_toolbar 的容器獨立撐滿 100% 幅寬 */
.k-grid .k-grid-toolbar > div:not(:empty),
.k-grid .k-grid-toolbar .k-toolbar-item,
.k-grid .k-toolbar-resizable-container {
	width: 100% !important;
	flex: 1 1 100% !important;
	flex-grow: 1 !important;
	max-width: 100% !important;
	box-sizing: border-box !important;
	display: block !important;
	margin: 0 !important;
	padding: 0 !important;
}

/* 確保 grid_top_toolbar 與 grid_tool_bar 寬度撐滿且清除浮動 */
.grid_top_toolbar,
.grid_tool_bar {
	width: 100% !important;
	max-width: 100% !important;
	box-sizing: border-box !important;
	display: block !important;
	border: #333333 0px solid;
}

.grid_top_toolbar:after,
.grid_tool_bar:after {
	content: "";
	display: table;
	clear: both;
}

/* 工具列右側搜尋區塊強制靠最右對齊 */
.grid_top_toolbar .u-float-right,
.grid_top_toolbar #toolbar_right,
.grid_tool_bar #toolbar_right,
.grid_tool_bar .toolbar_right,
.grid_top_toolbar .toolbar_right {
	float: right !important;
	margin-left: auto !important;
}

.grid_top_toolbar .u-float-left,
.grid_top_toolbar #toolbar_left,
.grid_tool_bar #toolbar_left,
.grid_tool_bar .toolbar_left,
.grid_top_toolbar .toolbar_left {
	float: left !important;
}

/* ---- 全域 Kendo Grid 容器滿版適應 (Fit width) ---- */
.k-grid {
	width: 100% !important;
	max-width: 100% !important;
	box-sizing: border-box !important;
}

.k-grid .k-grid-header,
.k-grid .k-grid-header-wrap,
.k-grid .k-grid-content,
.k-grid .k-grid-footer,
.k-grid .k-grid-footer-wrap {
	width: 100% !important;
	box-sizing: border-box !important;
}

.k-grid table {
	width: 100% !important;
	min-width: 100% !important;
	box-sizing: border-box !important;
}






/* ---- Kendo 2026 字型圖示相容層 ----
   Kendo 2026 內建元件改用 SVG 圖示，字型圖示的定義移到 kendoui/styles/font-icons/index.css，
   基底類別也從 .k-icon 改成 .k-font-icon。站內大量 legacy 標記仍寫 <span class="k-icon k-i-xxx">，
   在 header 載入 font-icons/index.css 之後，這裡把 .k-icon 補回字型圖示的基底樣式。 */
.k-icon:not(.k-svg-icon) {
	width: 1em;
	height: 1em;
	outline: 0;
	font-family: "WebComponentsIcons";
	font-size: var(--kendo-icon-size, 16px);
	font-style: normal;
	font-variant: normal;
	font-weight: normal;
	line-height: 1;
	speak: none;
	text-transform: none;
	text-decoration: none;
	flex-shrink: 0;
	display: inline-flex;
	flex-flow: row nowrap;
	align-items: center;
	justify-content: center;
	vertical-align: middle;
	position: relative;
	-moz-osx-font-smoothing: grayscale;
	-webkit-font-smoothing: antialiased;
}

/* Kendo 自己產生的 SVG 圖示有部分同時帶 k-i-* 類別，避免 index.css 的 ::before 疊上一個豆腐字。 */
.k-svg-icon::before {
	content: none !important;
}

/* Legacy Kendo UI icon mappings (舊版無 k-i- 前綴的圖示類別相容) */
.k-icon.k-add::before,
.k-add::before {
	content: "\e11e"; /* plus / add */
}

.k-icon.k-update::before,
.k-update::before {
	content: "\e118"; /* check / checkmark */
}

.k-icon.k-cancel::before,
.k-cancel::before {
	content: "\e115"; /* cancel */
}

.k-icon.k-delete::before,
.k-delete::before {
	content: "\e10c"; /* trash / delete */
}

.k-icon.k-close::before,
.k-close::before {
	content: "\e11b"; /* close / x */
}

.k-icon.k-edit::before,
.k-edit::before {
	content: "\e10b"; /* edit / pencil */
}

/* CKEditor 5 章節範本按鈕樣式 */
.ck.ck-button.ck-button-book .ck-button__icon svg,
.ck.ck-button.ck-button-book .ck-button__icon svg image,
.ck.ck-button .ck-button__icon svg image {
	width: 100%;
	height: 100%;
}

/* CKEditor 5 浮動面板（特殊符號、超連結、圖片、表格屬性、Tooltip 等）在彈出視窗內的置頂層級 */
:root {
	--ck-z-default: 100010 !important;
	--ck-z-panel: 100070 !important;
	--ck-z-dialog: 100080 !important;
}

/* 核心修正：.ck-body-wrapper 保持靜態流且高度為 0，避免成為 offsetParent 導致工具列雙重加上 scrollY 而嚴重下移，同時徹底防止在頁面底部撐開灰底 */
.ck-body-wrapper {
	position: static !important;
	top: auto !important;
	left: auto !important;
	height: 0 !important;
	overflow: visible !important;
	pointer-events: none !important;
}

.ck-body-wrapper > * {
	pointer-events: auto !important;
}

.ck.ck-balloon-panel {
	z-index: 100070 !important;
	width: auto !important;
	max-width: none !important;
}

.ck.ck-dialog,
.ck.ck-dialog-overlay {
	z-index: 100080 !important;
}

/* 核心修正：浮動工具列（TableToolbar）強制單行橫向展開（橫的），絕不折行壓縮變直立 */
.ck.ck-balloon-panel .ck.ck-toolbar,
.ck.ck-balloon-panel .ck.ck-toolbar__items {
	display: flex !important;
	flex-direction: row !important;
	flex-wrap: nowrap !important;
	width: max-content !important;
	max-width: none !important;
	white-space: nowrap !important;
}

/* CKEditor 5 內部表格儲存格：支援手動調整列高 (resize: vertical)，並徹底禁止水平捲軸 (防止出現左右的 bar) */
.ck-editor__nested-editable,
.ck-content .table td,
.ck-content .table th,
.ck-content table td,
.ck-content table th {
	overflow-x: hidden !important;
	overflow-y: auto !important;
	resize: vertical !important;
	box-sizing: border-box !important;
	min-height: 0 !important;
}

/* 雙重保證隱藏儲存格水平 scrollbar，確保任何情況下都不會出現左右的灰色捲軸 (左右的 bar) */
.ck-editor__nested-editable::-webkit-scrollbar:horizontal,
.ck-content .table td::-webkit-scrollbar:horizontal,
.ck-content .table th::-webkit-scrollbar:horizontal,
.ck-content table td::-webkit-scrollbar:horizontal,
.ck-content table th::-webkit-scrollbar:horizontal {
	display: none !important;
	width: 0 !important;
	height: 0 !important;
}

/* CKEditor 5 主要編輯區支援如 textarea 自由上下調整高度 (全螢幕模式除外) */
.ck:not(.ck-fullscreen__editable) .ck-editor__main > .ck-editor__editable:not(.ck-editor__nested-editable) {
	resize: vertical !important;
	overflow-y: auto !important;
}

/* CKEditor 5 全螢幕模式：解除 A4 795px 限縮，輸入框寬度 100% 填滿視窗 */
.ck.ck-fullscreen__main-wrapper {
	position: fixed !important;
	top: 0 !important;
	left: 0 !important;
	width: 100vw !important;
	height: 100vh !important;
	z-index: 100050 !important;
	background: #fff !important;
}

.ck-fullscreen__main-wrapper .ck-fullscreen__editable-wrapper {
	width: 100% !important;
	max-width: 100% !important;
	height: 100% !important;
	justify-content: stretch !important;
	padding: 0 !important;
	margin: 0 !important;
}

.ck-fullscreen__main-wrapper .ck-fullscreen__editable {
	width: 100% !important;
	max-width: 100% !important;
	height: 100% !important;
	margin: 0 !important;
	padding: 0 !important;
}

.ck-fullscreen__main-wrapper .ck-fullscreen__editable:after {
	display: none !important;
}

.ck-fullscreen__main-wrapper .ck-fullscreen__editable .ck.ck-editor__editable:not(.ck-editor__nested-editable),
.ck-fullscreen__main-wrapper .ck-fullscreen__editable .ck-source-editing-area,
.ck-fullscreen__main-wrapper .ck-fullscreen__editable .ck-source-editing-area textarea {
	box-sizing: border-box !important;
	width: 100% !important;
	max-width: 100% !important;
	min-height: calc(100vh - 120px) !important;
	height: 100% !important;
	margin: 0 !important;
	padding: 15px 25px !important;
	border: none !important;
	box-shadow: none !important;
	background: #fff !important;
}

.ck-fullscreen__main-wrapper .ck-fullscreen__top-wrapper {
	width: 100% !important;
	max-width: 100% !important;
	border-radius: 0 !important;
}

/* Kendo UI Chart 隱藏 No Data 提示遮罩層（防止無資料時出現居中灰塊覆蓋） */
.k-chart-overlay,
.k-chart-overlay *,
.k-chart .k-chart-overlay,
.k-chart .k-chart-overlay *,
.k-chart .k-no-data,
.k-chart-overlay.k-overlay {
	display: none !important;
	visibility: hidden !important;
	opacity: 0 !important;
	pointer-events: none !important;
	width: 0 !important;
	height: 0 !important;
	overflow: hidden !important;
}

/* CKEditor 4 工具列層級收斂：強制形成低層級 Stacking Context，防止下拉箭頭、按鈕與圖示穿透彈出視窗 (如 Kendo Window) */
.cke_chrome:not(.cke_maximized),
.cke:not(.cke_maximized) {
	position: relative !important;
	z-index: 1 !important;
}

.cke_combo,
.cke_toolgroup,
.cke_combo_arrow,
.cke_button_arrow,
.cke_button_icon,
.cke_button__textcolor_icon {
	position: static !important;
	z-index: auto !important;
}

/* 確保彈窗（Kendo Window 與 modal 遮罩）具備最高層級，覆蓋底層頁面所有編輯器與按鈕 */
.k-window {
	z-index: 20000 !important;
}
.k-overlay {
	z-index: 19999 !important;
}

/* SweetAlert 訊息與遮罩需高於 Kendo 視窗及編輯器浮動面板 */
.sweet-overlay {
    z-index: 20010 !important;
}
.sweet-alert {
    z-index: 20011 !important;
}

/* CKEditor 4 浮動面板（掛載在 body 下的下拉選單、顏色選盤等）層級高於彈窗 */
.cke_panel,
.cke_combopanel,
.cke_colorblock {
	z-index: 20005 !important;
}

/* CKEditor 5 工具列下拉箭頭層級收斂：移除預設 z-index，防止下拉箭頭蓋過彈窗 */
.ck.ck-dropdown .ck-dropdown__arrow,
.ck.ck-button .ck-dropdown-menu-list__nested-menu__button__arrow,
.ck.ck-menu-bar__menu__button__arrow {
	z-index: auto !important;
}

