/* v415：僅作用於導覽入口與導覽視窗。 */
#sk-page-tour-entry{display:flex;justify-content:flex-end;align-items:center;gap:10px;flex-wrap:wrap;margin-left:auto;font-size:16px}
#sk-page-tour-entry[hidden],.skpt-dialog [hidden]{display:none!important}
#sk-page-tour-entry button,.skpt-card button{font:inherit;min-height:42px;padding:8px 14px;border:1px solid #9dbbd4;border-radius:7px;background:#f2f8ff;color:#155b91;cursor:pointer;line-height:1.5}
#sk-page-tour-entry button:hover,.skpt-card button:hover{background:#e1effd}
.skpt-entry-message{font-size:15px;color:#526a7e;line-height:1.7}
.skpt-dialog{position:fixed!important;inset:0!important;width:100vw!important;height:100dvh!important;max-width:none!important;max-height:none!important;margin:0!important;padding:0!important;border:0!important;background:transparent!important;overflow:hidden!important;color:#243b50;font:16px/1.7 'Noto Sans TC',sans-serif}
.skpt-dialog::backdrop{background:transparent}
.skpt-highlight{position:fixed;box-sizing:border-box;border:3px solid #fff;border-radius:8px;box-shadow:0 0 0 100vmax #172638a6;pointer-events:none}
.skpt-highlight[hidden]{display:block!important;inset:0!important;width:100%!important;height:100%!important;background:#172638a6;border:0;box-shadow:none}
.skpt-card{position:fixed;box-sizing:border-box;padding:20px;background:#fff;border:1px solid #c4d5e4;border-radius:12px;box-shadow:0 10px 35px #10233840;overflow:auto;overscroll-behavior:contain}
.skpt-card .skpt-bar{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:15px;color:#526a7e}
.skpt-card h2{font-size:20px;font-weight:700;line-height:1.5;margin:14px 0 8px;color:#234c6f}
.skpt-card p{font-size:16px;line-height:1.8;margin:8px 0 16px;white-space:pre-wrap;overflow-wrap:anywhere}
.skpt-card .skpt-notice{color:#995600;font-size:15px;margin:8px 0}.skpt-notice:empty{display:none}
.skpt-actions{display:flex;justify-content:flex-end;gap:12px;margin-top:20px}
.skpt-card button.skpt-primary{background:#176ab0;color:white;border-color:#176ab0}.skpt-card button:disabled{opacity:.45;cursor:default}
#sk-page-tour-entry button:focus-visible,.skpt-card button:focus-visible{outline:3px solid #ffbf47;outline-offset:3px}
body.dark #sk-page-tour-entry button{background:#233f58;color:#d4eaff;border-color:#7699b5}body.dark .skpt-entry-message{color:#bacdde}
body.dark .skpt-card{background:#223448;color:#e8f0f8;border-color:#7591a9}body.dark .skpt-card h2{color:#c6e3ff}body.dark .skpt-card .skpt-bar{color:#bdcfdf}body.dark .skpt-card .skpt-notice{color:#ffd291}
@media(max-width:600px){#sk-page-tour-entry{width:100%;margin:4px 0 10px}.skpt-card{padding:16px}.skpt-card h2{font-size:19px}}

/* v415.1：入口位於複製連結右側；預覽標示使用眼睛。 */
#software-detail .detail-header-tools #sk-page-tour-entry{margin:0;gap:10px;width:auto;flex:0 1 auto}
#software-detail .detail-header-tools{column-gap:14px}
#software-detail .detail-header-tools #sk-page-tour-entry button{height:40px;min-height:40px;box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;white-space:nowrap;margin:0;padding:6px 12px;font-size:16px}
.skpt-preview-icon{display:inline-flex;align-items:center;justify-content:center;color:#587b98;min-width:24px;min-height:24px;font-size:19px;vertical-align:middle}
body.dark .skpt-preview-icon{color:#bad9f3}
@media(max-width:600px){#software-detail .detail-header-tools{justify-content:flex-end;width:100%}#software-detail .detail-header-tools #sk-page-tour-entry{margin:0;width:auto}}

/* v415.2：預覽標示放在鈴鐺左側，由眼睛承接右側群組的自動留白。 */
#software-detail .badge-group>.skpt-preview-mode{margin-left:auto;margin-right:6px;flex:0 0 28px;min-height:38px}
#software-detail .badge-group>.skpt-preview-mode+.tooltip-container:nth-last-child(2){margin-left:0}

/* v415.3：兩個工具按鈕同為原導覽按鈕的 16px 字級。 */
#software-detail .detail-header-tools #detail-copy-link,
#software-detail .detail-header-tools #sk-page-tour-entry button{font-size:16px;line-height:1.5;gap:8px}
#software-detail .detail-header-tools #detail-copy-link>i,
#software-detail .detail-header-tools #sk-page-tour-entry button>i{font-size:1em}

/* v416：分類頁入口沿用導覽按鈕樣式，僅新增本頁入口區。 */
.category-reading-page #sk-page-tour-entry{justify-content:flex-end;margin:0 0 12px;width:100%}
.category-reading-page #sk-page-tour-entry>.skpt-preview-mode{margin:0 0 0 4px;flex:none}

/* v416.2：分類名稱與導覽同列，預覽眼睛位於導覽左側。 */
.category-reading-page .category-info{display:grid;grid-template-columns:minmax(0,1fr) auto;column-gap:16px;align-items:center}
.category-reading-page .category-info>h2{grid-column:1;grid-row:1;min-width:0}
.category-reading-page .category-info>#sk-page-tour-entry{grid-column:2;grid-row:1;margin:0;width:auto;justify-content:flex-end;gap:12px}
.category-reading-page .category-info>.stats-bar,.category-reading-page .category-info>.os-nav,.category-reading-page .category-info>.sub-category-list,.category-reading-page .category-info>.sort-options-bar{grid-column:1/-1}
.category-reading-page .category-info>#sk-page-tour-entry>.skpt-preview-mode{order:-1;margin:0;flex:none}
.category-reading-page #sk-page-tour-entry>button{display:inline-flex;align-items:center;gap:8px}
@media(max-width:640px){.category-reading-page .category-info{grid-template-columns:minmax(0,1fr)}.category-reading-page .category-info>#sk-page-tour-entry{grid-column:1;grid-row:2;margin:0 0 12px;justify-self:end}}

/* v417：其他頁面入口與位置選取工具；既有入口維持原位置。 */
#sk-page-tour-entry.skpt-generic-entry{grid-column:1/-1;justify-self:end;justify-content:flex-end;width:100%;margin:0 0 16px}
#sk-page-tour-entry.skpt-generic-entry .skpt-preview-mode{order:-1}
.skpt-picker-bar{position:fixed;z-index:2147483647;right:16px;top:16px;width:min(420px,calc(100vw - 32px));box-sizing:border-box;padding:18px;background:#fff;color:#29465d;border:2px solid #176ab0;border-radius:10px;box-shadow:0 5px 25px #17263844;font:16px/1.7 sans-serif}
.skpt-picker-bar p{margin:0 0 10px;font:inherit}.skpt-picker-bar button{font:inherit;padding:8px 12px;margin:4px 0 0 10px;border:1px solid #8eafcb;border-radius:6px;background:#f1f7fd;color:#155b91;cursor:pointer}.skpt-picker-bar button:disabled{opacity:.45}
.skpt-picker-actions{display:flex;justify-content:flex-end;flex-wrap:wrap;gap:6px}
.skpt-picker-ring{position:fixed;z-index:2147483646;pointer-events:none;border:3px solid #176ab0;background:#176ab01c;border-radius:5px;box-sizing:border-box}

/* v417.1：可使用的位置為藍框，尚未辨識的位置為橙框。 */
.skpt-picker-ring[data-valid=false]{border-color:#b46b10;background:#b46b101a}

/* v417.3：逐層選取與下層項目選單。 */
.skpt-picker-bar{max-height:calc(100dvh - 32px);overflow:auto;overscroll-behavior:contain}
.skpt-picker-children{display:flex;flex-direction:column;gap:6px;margin-top:12px;font:inherit}
.skpt-picker-children[hidden]{display:none!important}
.skpt-picker-children select{font:inherit;min-height:42px;width:100%;padding:7px 10px;border:1px solid #8eafcb;border-radius:6px;color:#29465d;background:#fff;box-sizing:border-box}

.skpt-entry-message[data-error=true]{color:#b21f29;border:1px solid #dc9298;background:#fff3f3;border-radius:6px;padding:8px 12px}
body.dark .skpt-entry-message[data-error=true]{color:#ffb3b8;border-color:#cd7c85;background:#442a31}

/* v417.5：箭頭與卡片分開繪製，避免被可捲動的說明內容裁切。 */
.skpt-arrow{position:fixed;box-sizing:border-box;width:14px;height:14px;background:#fff;border:solid #c4d5e4;transform:rotate(45deg);pointer-events:none}
.skpt-arrow[data-side=left]{border-width:0 0 1px 1px}
.skpt-arrow[data-side=right]{border-width:1px 1px 0 0}
.skpt-arrow[data-side=top]{border-width:1px 0 0 1px}
.skpt-arrow[data-side=bottom]{border-width:0 1px 1px 0}
body.dark .skpt-arrow{background:#223448;border-color:#7591a9}

/* v417.7：預覽以虛線顯示；固定選取維持實線，並列出位置層級。 */
.skpt-picker-ring[data-preview=true]{border-style:dashed}
.skpt-picker-bar .skpt-picker-location{padding:9px 12px;border:1px solid #b6cfe2;border-radius:6px;background:#edf6ff;font-size:15px;line-height:1.7;overflow-wrap:anywhere}
.skpt-picker-bar .skpt-picker-location[hidden]{display:none!important}
.skpt-picker-children small{font-size:14px;line-height:1.7;color:#526a7e}

/* v433.1：黃色提示依文字自然寬度單行浮動，不受入口寬度壓縮。 */
#sk-page-tour-entry:has(.skpt-hint-tag){align-items:flex-start}
#sk-page-tour-entry .skpt-entry-control{position:relative;display:inline-flex;flex-direction:column;align-items:center;gap:0;max-width:100%}
#sk-page-tour-entry .skpt-entry-control>button:not(.skpt-hint-tag){display:inline-flex;align-items:center;gap:8px}
#sk-page-tour-entry button.skpt-hint-tag,
#software-detail .detail-header-tools #sk-page-tour-entry button.skpt-hint-tag{position:absolute;top:calc(100% + 9px);left:50%;transform:translateX(-50%);z-index:110;max-width:none;display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;flex:none;width:max-content;height:auto;min-height:30px;margin:0;padding:3px 12px;border:1px solid #b57b0b;border-radius:6px;background:#ffe69a;color:#573900;font-size:14px;font-weight:700;line-height:1.5;white-space:nowrap;cursor:pointer}
#sk-page-tour-entry button.skpt-hint-tag::before{content:'';position:absolute;left:50%;top:-7px;width:11px;height:11px;border-top:1px solid #b57b0b;border-left:1px solid #b57b0b;background:inherit;transform:translateX(-50%) rotate(45deg);pointer-events:none}
#sk-page-tour-entry button.skpt-hint-tag:hover,
#software-detail .detail-header-tools #sk-page-tour-entry button.skpt-hint-tag:hover{background:#ffda70}
#software-detail .detail-header-tools:has(.skpt-hint-tag){align-items:flex-start}
.category-reading-page .category-info:has(.skpt-hint-tag)>h2{align-self:start}
body.dark #sk-page-tour-entry button.skpt-hint-tag,
body.dark #software-detail .detail-header-tools #sk-page-tour-entry button.skpt-hint-tag{background:#ffe69a;color:#573900;border-color:#b57b0b}
body.dark #sk-page-tour-entry button.skpt-hint-tag:hover,
body.dark #software-detail .detail-header-tools #sk-page-tour-entry button.skpt-hint-tag:hover{background:#ffda70}

/* v421：預設標題列右側；自訂位置使用正常排版，手機必要時另起一列。 */
.skpt-default-title-row{display:flex;align-items:flex-start;justify-content:space-between;gap:12px 20px;flex-wrap:wrap;margin-bottom:16px}
.skpt-default-title-row>h1{flex:1 1 240px;min-width:0;margin-top:0;margin-bottom:0}
.skpt-default-title-row>#sk-page-tour-entry.skpt-title-entry{flex:0 1 auto;width:auto;margin:0 0 0 auto;justify-content:flex-end}
#sk-page-tour-entry.skpt-custom-entry{width:auto;margin:8px 0;justify-content:flex-end;max-width:100%}
@media(max-width:600px){.skpt-default-title-row>#sk-page-tour-entry.skpt-title-entry{flex-basis:100%;width:100%;margin:0;justify-content:flex-end}}

/* v421.1：入口選取的實際排版預覽，不保存螢幕座標。 */
.skpt-picker-bar.skpt-entry-mode{max-height:calc(100dvh - 32px);overflow:auto;box-sizing:border-box;width:min(440px,calc(100vw - 32px))}
.skpt-picker-bar[data-side=left]{left:16px;right:auto}
.skpt-picker-entry-options{display:grid;gap:6px;margin:12px 0;font:inherit}
.skpt-picker-entry-options>select{width:100%;min-height:42px;font:inherit;border:1px solid #8eafcb;border-radius:6px;padding:6px;background:#fff;color:#29465d;box-sizing:border-box}
#sk-page-tour-entry.skpt-entry-preview{outline:2px dashed #b07a0d;outline-offset:4px}
.skpt-picker-bar.skpt-entry-mode .skpt-picker-actions{gap:6px}
.skpt-picker-bar.skpt-entry-mode .skpt-picker-actions button{margin:0}

/* v422：相對於參考區塊的六格位置圖。正式入口與預覽共用預留空間排版。 */
.skpt-picker-entry-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:6px}
.skpt-picker-entry-outside{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}
.skpt-picker-entry-options button{margin:0;min-height:42px;font:inherit;border:1px solid #8eafcb;border-radius:6px;background:#f1f7fd;color:#155b91;cursor:pointer}
.skpt-picker-entry-options button[aria-pressed=true]{background:#176ab0;color:#fff;border-color:#176ab0;font-weight:700;outline:2px solid #9cc9ef;outline-offset:1px}
.skpt-picker-entry-options button:focus-visible{outline:3px solid #ffbf47;outline-offset:2px}
.skpt-picker-entry-options small{line-height:1.6;color:#526a7e}

/* v423：區域及對齊分開選擇。 */
.skpt-picker-entry-options fieldset{border:0;margin:0 0 10px;padding:0;min-width:0}
.skpt-picker-entry-options legend{font-weight:700;margin-bottom:6px;padding:0}
.skpt-picker-entry-entryArea,.skpt-picker-entry-entryAlign{display:grid;gap:5px}
.skpt-picker-entry-entryArea{grid-template-columns:repeat(2,minmax(0,1fr))}
.skpt-picker-entry-entryAlign{grid-template-columns:repeat(3,minmax(0,1fr))}
.skpt-picker-entry-options button[aria-pressed=true]{background:#196db2;color:#fff;border-color:#196db2;font-weight:700}
.skpt-picker-entry-options button:focus-visible{outline:3px solid #ffbf47;outline-offset:2px}

/* v428：只影響頁首內的導覽入口，原網站連結與其他頁面的入口樣式保留。 */
header #sk-page-tour-entry.skpt-header-entry{font-size:14px;line-height:1.5}
header #sk-page-tour-entry.skpt-header-entry .skpt-entry-control{gap:7px}
header #sk-page-tour-entry.skpt-header-entry button:not(.skpt-hint-tag){min-height:30px;height:auto;padding:3px 8px;font-size:14px;line-height:1.5;white-space:nowrap;background:transparent;color:#fff;border-color:transparent;font-weight:700}
/* v433.4：頁首主入口融入藍底導覽列；黃色提示及內容區入口保留。 */
header #sk-page-tour-entry.skpt-header-entry button:not(.skpt-hint-tag):hover{background:rgba(255,255,255,.14);color:#fff;border-color:transparent}
header #sk-page-tour-entry.skpt-header-entry button:not(.skpt-hint-tag):focus-visible{background:rgba(255,255,255,.14);color:#fff;border-color:transparent;outline:2px solid #fff;outline-offset:2px}
/* v433.2：頁首黃色提示沿用共用14px字級、30px最低高度與3px 12px內距。 */
header #sk-page-tour-entry.skpt-header-entry .skpt-preview-mode{align-self:flex-start;margin-top:5px;color:#d9eaff}
header .web_function #sk-page-tour-entry .skpt-entry-message::after{content:none}
header #sk-page-tour-entry [hidden]{display:none!important}

/* v433.5：頁首主入口沿用功能列14px粗體、6px圖文間距及13px圖示；黃色提示保留。 */
header #sk-page-tour-entry.skpt-header-entry .skpt-entry-control>button:not(.skpt-hint-tag){gap:6px}
header #sk-page-tour-entry.skpt-header-entry .skpt-entry-control>button:not(.skpt-hint-tag)>i{font-size:13px;margin-right:0}
