/* ==========================================================================
   Exam Creator — Common Styles (loaded on all exam pages)
   ========================================================================== */

/* ---------- Buttons ---------- */
input.ec_submit_btn {
    background: #F9FCFF;
    border: 1px solid #D0DFE4;
    border-radius: 4px;
    color: #607D8B;
    transition: .4s linear;
    font-size: 16px;
}
input.ec_submit_btn:hover {
    color: white;
    background: #FFA8A8;
    transition: .4s linear;
    border-color: #EDC5C5;
}

input[type='submit']:disabled {
    background: grey;
    cursor: not-allowed;
}
input[type='submit']:hover:enabled {
    background: #A3CAF5;
}

.start-btn, .delete-btn {
    font-size: 85% !important;
    margin-right: 4px !important;
}

input#confirm_del_button:hover {
    background: #DC6F6F;
}

.action_btn_grp {
    float: right;
}

.qa-part-custom-page-buttons {
    margin-bottom: 10px;
    margin-top: 4px;
}

/* ---------- Tags ---------- */
.qa-q-view-tags {
    clear: left;
}

/* ---------- Layout helpers ---------- */
.row {
    margin: 2px 0 15px 0;
}
.col {
    display: inline-block;
    padding: 5px;
}

/* ---------- Headings ---------- */
h2.ec_view {
    border: none;
    box-shadow: 0 -25px 25px -25px white inset;
    margin: 0;
    background: #BCD8F3;
    font-size: 16px;
    color: #333;
    padding: 5px 10px !important;
    clear: both;
    font-family: Arial, Helvetica, sans-serif;
    font-weight: 700;
    border-radius: 3px;
    border: 1px solid #ddd;
    text-shadow: 1px 1px 0 white;
}

h2.breadcrumb_nav {
    font-size: 20px;
    color: #333;
    padding: 5px 10px !important;
    clear: both;
    background: #eee;
    font-family: Arial, Helvetica, sans-serif;
    font-weight: 400;
    border-radius: 3px;
    box-shadow: 0 -25px 25px -25px white inset;
    border: 1px solid #ddd;
    text-shadow: 1px 1px 0 white;
    margin-bottom: 6px;
}

/* ---------- Success / Error messages ---------- */
.ec_success_msg h2 {
    color: #0F8D14;
    background: #A6E6A4;
    border: none;
    text-shadow: none;
    font-family: sans-serif;
    font-size: 18px;
}
.ec_success_msg {
    margin-bottom: 10px;
}
.ec_success_msg a {
    color: #276987;
    text-decoration: none;
    padding: 8px;
    border-radius: 5px;
    font-weight: bold;
    border: 2px solid #E7E7E7;
    box-shadow: 1px 0 1px grey;
}

.ec_error_msg h2 {
    color: #A52020;
    background: #FFD3D3;
    border: none;
    text-shadow: none;
    font-family: sans-serif;
    font-size: 18px;
}

p.confirm_msg {
    background: #FFD3D3;
    padding: 8px;
    border-radius: 4px;
    color: #A52020;
    font-size: 16px;
    font-family: sans-serif;
}

/* ---------- Info box ---------- */
.ec-info-box {
    background: #f0f7ff;
    border: 1px solid #b8d4f0;
    border-radius: 6px;
    padding: 12px 16px;
    margin-bottom: 16px;
    font-size: 13px;
    line-height: 1.6;
    color: #334;
}
.ec-info-box ul {
    margin: 6px 0 0 18px;
    padding: 0;
}
.ec-info-box code {
    background: #e2ecf5;
    padding: 1px 5px;
    border-radius: 3px;
}

/* ---------- Icon buttons (recalculate, download) ---------- */
.qa-form-light-button-recalc::before,
.qa-form-light-button-download::before {
    content: '';
    display: inline-block;
    width: 18px;
    height: 18px;
    vertical-align: middle;
    margin-right: 4px;
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}
.qa-form-light-button-recalc::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='18' width='18' viewBox='0 -960 960 960'%3E%3Cpath fill='%23555' d='M204-318q-22-38-33-78t-11-84q0-134 93-228t227-94q7 0 14 .5t14 1.5l-64-66 42-42 140 140-140 140-42-42 72-72q-8-2-17-3t-19-1q-100 0-170 70.5T240-480q0 32 8 62.5t24 57.5l-68 42Zm252 198L316-260l140-140 42 42-72 72q8 2 17 3t19 1q100 0 170-70.5T702-523q0-32-8-62.5T670-643l68-42q22 38 33 78t11 84q0 134-93 228t-227 94q-7 0-14-.5t-14-1.5l64 66-42 42Z'/%3E%3C/svg%3E");
}
.qa-form-light-button-download::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' height='18' width='18' viewBox='0 -960 960 960'%3E%3Cpath fill='%23555' d='M480-320 280-520l56-58 104 104v-326h80v326l104-104 56 58-200 200ZM240-160q-33 0-56.5-23.5T160-240v-120h80v120h480v-120h80v120q0 33-23.5 56.5T720-160H240Z'/%3E%3C/svg%3E");
}

/* ==========================================================================
   Dark mode
   ========================================================================== */
html[data-theme="dark"] h2.ec_view {
    background: #1e3a5f;
    color: #dce6f0;
    border-color: #2e4a66;
    text-shadow: none;
    box-shadow: none;
}
html[data-theme="dark"] h2.breadcrumb_nav {
    background: #1a2332;
    color: #c8d4e0;
    border-color: #2e4a66;
    text-shadow: none;
    box-shadow: none;
}
html[data-theme="dark"] .ec_success_msg h2 {
    background: #1a3d1a;
    color: #8fd88f;
}
html[data-theme="dark"] .ec_success_msg a {
    color: #7fbfdf;
    border-color: #3a4a5a;
}
html[data-theme="dark"] p.confirm_msg {
    background: #3d1a1a;
    color: #f0a0a0;
}
html[data-theme="dark"] .ec-info-box {
    background: #1e2a38;
    border-color: #2e4a66;
    color: #c8d4e0;
}
html[data-theme="dark"] .ec-info-box code {
    background: #263040;
}
html[data-theme="dark"] input.ec_submit_btn {
    background: #1e2a38;
    border-color: #3a4a5a;
    color: #c8d4e0;
}
html[data-theme="dark"] input.ec_submit_btn:hover {
    background: #5a3030;
    color: #f0d0d0;
}
