.jjff .field {
    border: 1px solid #ddd;
    margin-bottom: 4px;
    padding: 5px 10px;
}

.jjff .field:hover {
    background-color: #fbf9ee;
    cursor: move;
}

.jjff .choices li:hover {
    background-color: #f7fbc7 !important;
    cursor: move;
}

.jjff label {
    margin: 0;
    font-weight: bold;
}

.jjff .toggle-selected,
.jjff .toggle-required {
    margin: 0 0 0 5px;
}

.jjff .delete {
    float: right;
}

.jjff input {
    font-weight: normal;
    margin: 0 5px;
}

.jjff input[type="text"] {
    width: 80%;
    max-width: 300px;
}

.jjff .choices {
    margin: 20px 10px;
    padding: 5px;
    background: #f7f7f7;
    border: 1px solid #ddd;
}

.jjff .choices li {
    padding: 4px;
    margin: 4px 0;
}

.jjff .choices li:nth-child(even) {
    background: #e7e7e7;
}

.jjff .delete-choice {
    margin-left: 5px;
    font-weight: normal;
}

.jjswiper {
    width: '100%';
    height: '100%';
}

.jjswiper-wrapper {
    width: '97%';
    height: '100%';
}

.jjswiper-slide {
    text-align: 'center';
    font-size: '20px';
    overflow: 'auto';
    color: 'rgb(255, 255, 255)';
    background: 'rgb(75,66,52)';
    display: 'flex';
    box-sizing: 'border-box';
    justify-content: 'center';
}

.jjswiper-bullets {
    right: '0px';
    top: '50%';
    transform: 'translate3d(0px,-50%,0)';
}


/* 2026-10-31：題目文字行距。瀏覽器預設的 line-height:normal（約 1.2）
   對中文太擠，題目與選項都會黏在一起；統一拉到 1.75。
   （font-size 由工具列的放大／縮小改，行距會跟著等比縮放。） */
.nocoding-header-text,
.pu_form {
    line-height: 1.75;
}

/* 2026-10-31：題目區與選項／作答區之間留白（原本緊貼在一起）。
   選擇題是 <table>，表單題是 .puf-controls。 */
.pu_form > table,
.pu_form > .puf-controls {
    margin-top: 26px;
}
/* 2026-10-31：表單題（配對／排序…）的項目編輯列很寬時，.puf-controls 會
   被撐成整行寬，裡面的表格就貼在左邊——看起來整個題目偏左。把表格／清單
   在自己那一區置中，項目小卡也置中。 */
.puf-match,
.puf_order {
    margin-left: auto;
    margin-right: auto;
}

.pu_form {
    display: flex;
    width: 100%;
    font-size: 18px;
    align-content: center;
    justify-content: center;
    align-items: center;
    justify-items: center;
    flex-direction: column;
    flex-wrap: nowrap;
    background: rgb(75, 66, 52);
}


.pu_checkbox {
    width: 20px;
    height: 20px;
}

.pu_radio {
    width: 20px;
    height: 20px;
}

.pu_text {
    background: none repeat 0 0 #6a5c49;
    display: inline-block;
    font-size: 16px;
    color: #e9fff1;
}

.pu_text_areax {
    background: none repeat 0 0 #6a5c49;
    display: inline-block;
    font-size: 16px;
    color: #e9fff1;
}

.pu_fillingx {
    border: 2px solid #6d340b;
    border-radius: 6px;
    -moz-border-radius: 6px;
    -webkit-border-radius: 6px;
    -webkit-box-shadow: 20px 20px 20px 20px #4b4234;
    -moz-box-shadow: 0px 0px 61px 11px #900404;
    box-shadow: -1px 4px 18px 5px #3c2607;
    display: inline-block;
    margin: 50px 0px 10px 25px;
    Height: 100%;
    white-space: pre-line;
    padding: 20px;
    text-align: left;
    font-size: 16px;
    overflow: hidden;
}

.pu_fillingx:hover {
    overflow-y: auto;
}

.pu_fillingx::-webkit-scrollbar {
    width: 0.5em;
    height: 0.5em;
}

.pu_fillingx::-webkit-scrollbar-thumb {
    background-color: rgba(255, 255, 255, .1);
    border-radius: 3px;

    &:hover {
        background: rgba(255, 255, 255, .2);
    }
}

.pu_tea_form {
    display: flex;
    flex-direction: column;
}

.pu_tea_form>* {
    position: relative;
}

.pu_tea_form_head {
    margin: 12px;
    background: beige;
}

.pu_tea_form_body {
    margin: 10px;
    color: aquamarine;
}

.pu_tea_form_question {
    background: dimgray;
    padding: 13px;
    margin: 20px;
}

.pu_tea_form_question_hint {
    padding-left: 40px;
    padding-right: 40px;
    background: darkslategrey;
    color: ghostwhite;
}

.pu_tea_form_aijudge {
    background: darkslategray;
    color: floralwhite;
    margin: 10px;
    padding: 20px;
}
/* 2026-10-28 P2: 配對／排序／填空的項目編輯器 */
.puf-items {
    margin: 4px 0 6px 0;
    font-size: 15px;
    /* 2026-10-31：這排會撐滿整個 .puf-controls，左對齊時整區看起來偏左，
       改成置中（每行各自居中）。 */
    text-align: center;
    width: 100%;
}
.puf-item-row {
    display: inline-flex;
    align-items: center;
    margin: 2px 8px 2px 0;
}
.puf-item {
    background: rgba(255, 255, 255, .10);
    padding: 1px 5px;
    border-radius: 3px;
    min-width: 40px;
    outline: none;
}
.puf-item:focus {
    background: rgba(255, 255, 255, .22);
}
.puf-item-add,
.puf-item-del {
    margin-left: 4px;
    padding: 0 7px;
    border-radius: 3px;
    border: 1px solid #888;
    background: #444;
    color: #fff;
    font-size: 13px;
    line-height: 20px;
    cursor: pointer;
}
.puf-item-del {
    background: #7a2a2a;
}
.puf-item-add:hover,
.puf-item-del:hover {
    filter: brightness(1.25);
}
/* 2026-10-28: 選擇題選項＋題目本身的按鈕（新增／上下移／刪除） */
.puc-opt-tools {
    white-space: nowrap;
}
.puc-opt-up,
.puc-opt-down,
.puc-opt-del,
.puc-opt-add,
.puq-add,
.puq-del,
.puq-up,
.puq-down {
    margin-left: 4px;
    padding: 0 7px;
    border-radius: 3px;
    border: 1px solid #888;
    background: #444;
    color: #fff;
    font-size: 13px;
    line-height: 20px;
    cursor: pointer;
}
.puc-opt-add,
.puq-add {
    background: #2a5a2a;
}
.puc-opt-del,
.puq-del {
    background: #7a2a2a;
}
.puc-opt-up:disabled,
.puc-opt-down:disabled,
.puq-up:disabled,
.puq-down:disabled {
    opacity: .35;
    cursor: default;
}
.puc-opt-up:hover:not(:disabled),
.puc-opt-down:hover:not(:disabled),
.puc-opt-del:hover,
.puc-opt-add:hover,
.puq-add:hover,
.puq-del:hover,
.puq-up:hover:not(:disabled),
.puq-down:hover:not(:disabled) {
    filter: brightness(1.25);
}
.puq-tools {
    margin-left: 8px;
    white-space: nowrap;
}
/* 2026-10-31：老師編輯工具收進可展開區塊（預設收起，畫面等於學生版）。
   display:block → 「✏ 編輯」自己一行，不跟題目文字擠在同一列。 */
.puq-editwrap {
    display: block;
    margin-top: 6px;
}
.puq-edittoggle {
    border: 1px solid #888;
    background: #444;
    color: #fff;
    font-size: 12px;
    line-height: 18px;
    padding: 0 7px;
    border-radius: 3px;
    cursor: pointer;
    vertical-align: middle;
}
.puq-edittoggle:hover {
    filter: brightness(1.25);
}
.puq-editwrap.open > .puq-edittoggle {
    background: #2a5a2a;
    border-color: #3fb950;
}
.puq-editbody {
    display: none;
}
.puq-editwrap.open > .puq-editbody {
    display: inline;
}
/* 2026-10-31：選項／項目層級的編輯零件（↑↓×、＋選項、＋項目、容差）
   也只在編輯模式出現，跟題目工具列共用 body.puq-editing 這個開關。 */
.puq-editonly {
    display: none !important;
}
body.puq-editing .puq-editonly {
    display: inline-block !important;
}
/* 項目小卡那一排是 block（width:100%），展開時要維持 block */
body.puq-editing .puf-items.puq-editonly {
    display: block !important;
}
body.puq-editing td.puq-editonly {
    display: table-cell !important;
}
body.puq-editing tr.puq-editonly {
    display: table-row !important;
}
.puf_multi_wrap {
    margin-left: 6px;
    white-space: nowrap;
    cursor: pointer;
}
/* 新增題目類型：清單式的 <select> 不要出現捲軸 */
.swal2-select.choose-qtype {
    overflow: hidden;
    max-width: 100%;
}
/* 只有題型選單這個 dialog 用 flex 排版（其他 Swal 仍是 block）。
   SweetAlert 會給這個 div 一個 inline style="display: block"，所以要用 !important。 */
.swal2-html-container:has(.choose-qtype) {
    display: flex !important;
    flex-direction: column;
}
/* 2026-10-31：封面頁的「＋新增題目」原本 bottom:10px，會壓到題目層的
   分頁圓點（.swiper-pagination-h 在 bottom:8px、高約 15px）。
   往上抬到 44px，兩者之間留白。 */
.puq-head-tools {
    position: absolute;
    left: 50%;
    bottom: 44px;
    transform: translateX(-50%);
    direction: ltr;
    margin-top: 12px;
    text-align: center;
}
.swiper-slide.nocoding-header-container {
    position: relative;
    /* 2026-10-31：右側垂直分頁圓點（寬 30px + margin 10px、right:0）會壓到
       題目文字，內容區留 56px 給它。 */
    box-sizing: border-box;
    padding-right: 56px;
}
