/* Composition Form Styles */
.aimarkerside {
    width: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    background: #f7f7f7;
    padding: 0 5px;
}

.aimarkerside-item a {
    display: block;
    color: #3759d7;
    border-radius: 50%;
    position: relative;
    width: 46px;
    height: 46px;
}
.aimarkerside-item a i {
    font-size: 24px;
    line-height: 46px;
}
.aimarkerside-item a svg {
    height: 46px;
}
.aimarkerside-item {
    width: auto;
    text-align: center;
    margin-bottom: 10px;
}
.aimarkerside-item a:hover {
    color: #1f90eb;
    background: #fff;
    box-shadow: 0 0 2px #ccc;
}
.aimarkerside-item a:hover:after {
    content: '';
    background: #eba41f;
    width: 8px;
    height: 8px;
    display: inline-block;
    position: absolute;
    right: 8px;
    top: 8px;
    border-radius: 50%;
}
@media(max-width:1239px){
    .aimarkerside {
        width: 100%;
        display: flex;
        flex-direction: row;
        align-items: center;
    }

    .aimarkerside-item {
        margin-bottom: 0px;
        margin-left: 10px;
    }
    span.tooltips {
        left: initial;
        right: 48px;
        border-radius: 10px 0 10px 10px;
        top: 10px;
        line-height: 26px !important;
    }
}

.aimarker-form-section h3 {
    font-size: 13px;
    line-height: 15px !important;
    font-weight: 400 !important;
    margin-bottom: 5px !important;
}
.aimarker-form-content a {
    color: #ffc107 !important;
}
/* 隐藏原生复选框 */
.mini-input {
  display: none;
}

/* 创建自定义复选框容器 */
.mini-input + label {
  position: relative;
  padding-left: 22px;
  font-size:16px;
  line-height:24px;
  cursor: pointer;
  display: inline-block;
}

/* 自定义复选框外观 */
.mini-input + label::before {
  content: '';
  position: absolute;
  left: 0;
  top: 3px;
  width: 18px;
  height: 18px;
  border: 2px solid #ccc;
  border-radius: 4px;
  background: #fff;
  transition: all 0.3s;
}

/* 勾选状态 */
.mini-input:checked + label::before {
  background: var(--aimarker-main-color);
  border-color: var(--aimarker-main-color);
}

/* 创建自定义勾号 */
.mini-input:checked + label::after {
  content: '';
  position: absolute;
  left: 6px;
  top: 7px;
  width: 5px;
  height: 7.5px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.aimarker-form-section {
    margin-bottom: 15px;
}

.aimarker-userinfo-box {
    margin-bottom: 20px;
}

.aimarker-user-points {
    display: flex;
    align-items: center;
    background-color: rgba(255, 255, 255, 0.2);
    padding: 10px 15px;
    border-radius: var(--aimarker-normal-border-radius);
    margin-bottom: 20px;
}

.aimarker-logo {
    width: 40px;
    height: 40px;
    margin-right: 15px;
}

.aimarker-user-info {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.aimarker-username-display {
    font-weight: bold;
    font-size: 16px;
    color: #ffffff;
}

.aimarker-points-display {
    display: flex;
    align-items: center;
    gap: 5px;
}

/* .points-label {
    font-weight: bold;
    font-size: 16px;
}

.points-value {
    font-weight: bold;
    font-size: 16px;
    background-color: rgba(0, 0, 0, 0.2);
    padding: 2px 8px;
    border-radius: var(--aimarker-normal-border-radius);
} */



.aimarker-form-section {
    background: #fff;
    color: #2F2B3DE5;
}

.aimarker-form-content select,
.aimarker-form-content input,
.aimarker-form-content textarea {
    border-radius: var(--aimarker-small-border-radius);
    padding: 7px;
    border-style: solid;
    width: 100%;
}

.aimarker-form-content select {
    padding: 12px 30px 12px 15px;
    border-radius: var(--aimarker-small-border-radius);
    font-size: 16px;
    color: #1e293b;
    background: rgb(255 255 255);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='28' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 5px center;
    background-size: 20px;
    cursor: pointer;
}

.aimarker-form-content input, .aimarker-form-content textarea {
    padding: 12px 15px;
    border-radius: var(--aimarker-small-border-radius);
    font-size: 16px;
    color: #1e293b;
    background: rgb(255 255 255);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background-repeat: no-repeat;
    background-position: right 20px center;
    background-size: 20px;
}

.radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: space-between;
}

.colorful-radio-group svg {
    height: 24px;
    width: auto;
    margin-bottom: 15px;
}

.colorful-radio-group label.radio-label,.colorful-radio-group .radio-label {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.radio-label {
    display: inline-flex;
    flex: 1 0 0;
    align-items: center;
    cursor: pointer;
    padding: 8px 10px;
    border-radius: var(--aimarker-small-border-radius);
    transition: all 0.3s ease;
}


.aimarker-form-content select,
.aimarker-form-content input, 
.aimarker-form-content textarea,
.radio-label,
.aimarker-form-group select,
.aimarker-form-group input,
.aimarker-form-group textarea,
.aimarker-checkbox-label {
    border: 1px solid #c9c9c9;
}

.radio-label:hover {
    border-color: var(--aimarker-main-color);
    background-color: #f7fafc;
}

/* 隐藏原生radio */
.radio-label input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.radio-label:has(input[type="radio"]:checked) svg {
  color: var(--aimarker-main-color);
}

.colorful-radio-group .radio-label span,.colorful-radio-group .radio-label input[type="radio"] + span {
    display: block;
    padding-bottom: 30px;
    padding-left: 0;
    font-size: 13px;
    line-height: 22px;
    text-align: center;
}


.colorful-radio-group .radio-label input[type="radio"] + span::before {
    top: auto;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
}

.colorful-radio-group .radio-label input[type="radio"]:checked + span::after{
    top: auto;
    bottom: 0px;
    left: 50%;
    transform: translateX(-50%);
}
@media(min-width:768px){
.radio-group.colorful-radio-group {
    min-height: 150px;
}
}

/* 自定义radio样式 */
.radio-label input[type="radio"] + span {
    position: relative;
    padding-left: 28px;
    cursor: pointer;
    display: inline-block;
    line-height: 20px;
}

/* 未选中状态 */
.radio-label input[type="radio"] + span::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    width: 18px;
    height: 18px;
    border: 2px solid #ccc;
    border-radius: 50%;
    background: white;
    transition: all 0.3s ease;
}

/* 选中状态 */
.radio-label input[type="radio"]:checked + span::before {
    border-color: var(--aimarker-main-color);
    background: var(--aimarker-main-color);
}

/* 选中状态的内圆 */
.radio-label input[type="radio"]:checked + span::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 5px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: white;
}

.radio-label input[type="radio"]:checked + span {
    color: var(--aimarker-main-color);
}

.radio-label:has(input[type="radio"]:checked) {
    border-color: var(--aimarker-main-color);
    background-color: #ebf4ff;
}


#article-container,#aimarker-topic-generation-result,
#upload-container,
#bulk-upload-container {
    max-height: 500px;
    height: 500px;
    overflow-y: scroll;
    padding: 20px;
}
div#article-container h3,div#aimarker-topic-generation-result h3,
div#upload-container h3,
div#bulk-upload-container h3 {
    color: #419dff;
    background: linear-gradient(45deg, #2196F3, #7277FF);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-size: 20px;
}
div#article-container textarea {
    width: 100%;
    height: calc(100% - 80px);
    border-radius: var(--aimarker-normal-border-radius);
    box-shadow: 0 8px 20px 0 #575757;
    padding: 15px;
    margin-top: 15px;
    border: solid #3d9cf1;
}
div#aimarker-form-message,
div#bulk-aimarker-form-message, 
.aimarker-normal-loading {
    position: fixed;
    left: 0;
    top: 0;
    height: 100%;
    width: 100%;
    background: #ffffffeb;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 9999;
}
.aimarker-loading,
.aimarker-success,
.aimarker-error {
    text-align: center;
}

.refund-message {
    margin-top: 10px;
    padding: 10px;
    background-color: #e8f4fd;
    border: 1px solid #b3d9ff;
    border-radius: var(--aimarker-small-border-radius);
    color: #0066cc;
    font-weight: bold;
}



/*history list*/
table.aimarker-composition-history-table,
table.aimarker-topic-generation-history-table,
table.aimarker-practice-history-table,
.aimarker-history-table {
    line-height: 1.6;
    color: #333;
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: white;
    border-radius: var(--aimarker-normal-border-radius);
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 20px;
}

table.aimarker-composition-history-table thead th:first-child,
table.aimarker-topic-generation-history-table thead th:first-child,
table.aimarker-practice-history-table thead th:first-child,
.aimarker-history-table thead th:first-child{
    border-top-left-radius: 12px;
}

table.aimarker-composition-history-table thead th, 
table.aimarker-topic-generation-history-table thead th,
table.aimarker-practice-history-table thead th,
.aimarker-history-table thead th {
    background: var(--aimarker-main-color);
    color: #fff;
    padding: 16px 20px;
    position: sticky;
    top: 0;
    z-index: 10;
    text-transform: uppercase;
    line-height: 24px;
    letter-spacing: 0.5px;
    white-space: nowrap;
    font-weight: normal;
}

table.aimarker-composition-history-table td,
table.aimarker-topic-generation-history-table td,
table.aimarker-practice-history-table td,
.aimarker-history-table td {
    padding: 14px 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
    vertical-align: middle;
}



table.aimarker-points-usage-table {
    line-height: 1.6;
    color: #333;
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: white;
    border-radius: var(--aimarker-normal-border-radius);
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    margin-bottom: 20px;
}

table.aimarker-points-usage-table thead th:first-child {
    border-top-left-radius: 12px;
}

table.aimarker-points-usage-table thead th {
    background: var(--aimarker-main-color);
    color: #fff;
    padding: 16px 20px;
    position: sticky;
    top: 0;
    z-index: 10;
    text-transform: uppercase;
    line-height: 24px;
    letter-spacing: 0.5px;
    white-space: nowrap;
    font-weight: normal;
}

table.aimarker-points-usage-table td {
    padding: 14px 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
    vertical-align: middle;
}

#aimarker-points-usage-table-container {
    overflow: auto;
    width: 100%;
}
@media(max-width:767px){
table.aimarker-points-usage-table thead th {
    padding: 8px 10px;
}
table.aimarker-points-usage-table td {
    padding: 8px 12px;
}
}

table.aimarker-points-usage-table tbody tr:nth-child(even) {
    background-color: rgba(245, 247, 250, 0.8);
}

table.aimarker-points-usage-table tbody tr:nth-child(odd) {
    background-color: rgba(249, 250, 252, 0.6);
}

.aimarker-points-balance {
    font-weight: 600;
    color: var(--aimarker-main-color);
}

.aimarker-points-positive {
    color: #48bb78;
}

.aimarker-points-negative {
    color: #f56565;
}

.aimarker-pagination-container {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.aimarker-pagination-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 12px;
    margin: 0 3px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: white;
    color: #4a5568;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.aimarker-pagination-btn:hover:not(:disabled) {
    border-color: var(--aimarker-main-color);
    color: var(--aimarker-main-color);
    background: rgba(102, 108, 255, 0.05);
}

.aimarker-pagination-btn.active {
    background: var(--aimarker-main-color);
    border-color: var(--aimarker-main-color);
    color: white;
}

.aimarker-pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.aimarker-pagination-ellipsis {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    margin: 0 3px;
    color: #a0aec0;
    font-size: 14px;
}

.aimarker-message {
    padding: 16px 20px;
    border-radius: 8px;
    margin-bottom: 16px;
}

.aimarker-message.aimarker-info {
    background: rgba(66, 153, 225, 0.1);
    border: 1px solid rgba(66, 153, 225, 0.3);
    color: #2b6cb0;
}

.aimarker-message.aimarker-error {
    background: rgba(245, 101, 101, 0.1);
    border: 1px solid rgba(245, 101, 101, 0.3);
    color: #c53030;
}

.aimarker-general-loading {
    text-align: center;
    padding: 40px 20px;
    color: #718096;
    font-size: 14px;
}

.aimarker-general-loading .aimarker-icon {
    display: inline-block;
    margin-right: 8px;
    vertical-align: middle;
}

/*history popup*/
/* 整体模态框样式 */
.aimarker-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

/* 模态框内容区域样式 */
.aimarker-modal-content {
    position: relative;
    background-color: white;
    width: 80%;
    max-width: 1200px;
    max-height: 90%;
    overflow: scroll;
    border-radius: var(--aimarker-small-border-radius);
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

/* 关闭按钮样式 */
.aimarker-modal-close {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
}

/* 模态框主体样式 */
.aimarker-modal-body {
    padding: 20px;
}

/* 作文详情标题样式 */
.aimarker-composition-details h3 {
    font-size: 1.125rem;
    line-height: 1.75rem;
    font-weight: 700;
    letter-spacing: 1px;
    font-family: var(--aimarker-font-family);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.aimarker-custom-topic-details img {
    max-width: 100%;
}

/* 作文元信息样式 */
.aimarker-composition-meta p {
    margin: 10px 0;
}

/* 已评阅状态样式 */
.status-graded {
    display: inline-block;
    background: #36C76C;
    color: #fff;
    font-size: 13px;
    line-height: 20px;
    padding: 2px 10px;
    border-radius: var(--aimarker-small-border-radius);
}

.status-processing,
.status-pending {
    display: inline-block;
    background: #FF9F43;
    color: #fff;
    font-size: 13px;
    line-height: 20px;
    padding: 2px 10px;
    border-radius: var(--aimarker-small-border-radius);
}

.status-queued {
    display: inline-block;
    background: #00BCD4;
    color: #fff;
    font-size: 13px;
    line-height: 20px;
    padding: 2px 10px;
    border-radius: var(--aimarker-small-border-radius);
}

/* 评分失败状态样式 */
.status-error {
    display: inline-block;
    background: #c73636;
    color: #fff;
    font-size: 13px;
    line-height: 20px;
    padding: 2px 10px;
    border-radius: var(--aimarker-small-border-radius);
}

/* 作文内容标题样式 */
.aimarker-composition-content h4 {
    font-size: 1.125rem;
    line-height: 1.75rem;
    font-weight: 700;
    letter-spacing: 1px;
    font-family: var(--aimarker-font-family);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 作文内容文本样式 */
.aimarker-content-text {
    white-space: pre-line;
    margin-bottom: 15px;
}

/* 评阅结果标题样式 */
.aimarker-grading-details h4 {
    border-bottom: 2px solid #ccc;
    padding-bottom: 10px;
}

/* Composition History Styles */
.aimarker-composition-history {
    margin: 20px 0;
}

.aimarker-composition-filter {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.aimarker-filter-label {
    font-weight: bold;
    color: #333;
}

.aimarker-main-content select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: white;
    font-size: 14px;
}



.aimarker-composition-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.aimarker-composition-table th,
.aimarker-composition-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.aimarker-composition-table th {
    background-color: #f8f9fa;
    font-weight: bold;
    color: #333;
}

.aimarker-composition-table tr:hover {
    background-color: #f5f5f5;
}

.aimarker-composition-table .topic-type-1 {
    color: #0073aa;
    font-weight: bold;
}

.aimarker-composition-table .topic-type-2 {
    color: #00a32a;
    font-weight: bold;
}

.aimarker-composition-table .topic-type-3 {
    color: #dba617;
    font-weight: bold;
}

.aimarker-pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    padding: 15px 0;
    border-top: 1px solid #ddd;
}

.aimarker-pagination-info {
    font-size: 14px;
    color: #666;
    white-space: nowrap;
}

.aimarker-pagination-links {
    display: flex;
    gap: 5px;
}

.aimarker-pagination-links a,
.aimarker-pagination-links span {
    padding: 6px 12px;
    text-decoration: none;
    border: 1px solid #ddd;
    border-radius: 3px;
    color: var(--aimarker-main-color);
    background-color: white;
    transition: all 0.3s;
    min-width: 30px;
    text-align: center;
}

.aimarker-pagination-links a:hover {
    background-color: #f0f0f0;
    border-color: #999;
}

.aimarker-pagination-links .current {
    background-color: var(--aimarker-main-color);
    color: white;
    border-color: var(--aimarker-main-color);
    font-weight: bold;
}

.aimarker-pagination-links .disabled {
    color: #ccc;
    cursor: not-allowed;
    background-color: #f9f9f9;
}

.aimarker-pagination-links .disabled:hover {
    background-color: #f9f9f9;
    border-color: #ddd;
}

.aimarker-pagination-jump {
    display: flex;
    align-items: center;
    gap: 5px;
}

.aimarker-pagination-jump label {
    font-size: 14px;
    color: #666;
    white-space: nowrap;
}

.aimarker-page-input {
    width: 60px;
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 14px;
}


.aimarker-filter-section {
    display: flex;
    align-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 15px;
}
.aimarker-main-content {
    margin: 15px;
}
.aimarker-main-content h3 {
    font-size: 1.125rem;
    line-height: 1.75rem;
    font-weight: 700;
    letter-spacing: 1px;
    font-family: var(--aimarker-font-family);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}
.normal-size-form {
    max-width: 600px;
}
.aimarker-tooltips {
    display: none;
}
span.aimarker-tooltips {
    background: #2e2e2e;
    color: #fff;
    position: absolute;
    width: 56px;
    left: 50px;
    top: 12px;
    border: 1px solid #6f6f6f;
    border-radius: 0 10px 10px 10px;
    font-size: 12px;
    line-height: 26px;
    text-align: center;
    z-index: 9999999;
}
span.aimarker-tooltips.tooltipsright {
    left: initial;
    right: 40px;
    border-radius: 10px 0 10px 10px;
    top: 5px;
    line-height: 26px !important;
}




/*Student Questions*/
/* Container for the overall question list */
.generated-topics-list {
    background-color: #ffffff;
    border-radius: var(--aimarker-normal-border-radius);
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.1);
    padding-bottom: 15px;
}

/* Single topic item container */
.generated-topic-item {
    padding: 20px;
    border-bottom: 1px dashed #ccc;
    transition: background-color 0.3s ease;
}

/* Effect of hovering the mouse over the title item */
.generated-topic-item:hover {
    background-color: #f8f9fa;
}

/* Title number (h4 element) style */
.generated-topic-item h4 {
    color: #333;
    font-size: 18px;
    margin-bottom: 5px;
}

/* Title content style */
.generated-topic-item.topic-title {
    font-size: 20px;
    font-weight: bold;
    color: #007bff;
    margin-bottom: 10px;
}

/* Title description style */
.generated-topic-item.topic-description {
    font-size: 16px;
    color: #666;
    line-height: 1.5;
    margin-bottom: 10px;
}

/* Title requirements style */
.generated-topic-item.topic-requirements {
    font-size: 15px;
    color: #888;
    margin-bottom: 5px;
}

/* Title requirements emphasis style */
.generated-topic-item.topic-requirements strong {
    color: #e74c3c;
}

/* Title difficulty style */
.generated-topic-item.topic-difficulty {
    font-size: 15px;
    color: #888;
    margin-bottom: 5px;
}

/* Title word count style */
.generated-topic-item.topic-word-count {
    font-size: 15px;
    color: #888;
}

/* Title generation actions style */
.topic-generation-actions {
    text-align: center;
    margin-top: 20px;
}

/* Title download topics button style */
.download-topics-button {
    background-color: #007bff;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: var(--aimarker-small-border-radius);
    cursor: pointer;
    font-size: 16px;
    margin-right: 10px;
}

/* Title regenerate topics button style */
.regenerate-topics-button {
    background-color: white;
    color: #007bff;
    padding: 10px 20px;
    border: 1px solid #007bff;
    border-radius: var(--aimarker-small-border-radius);
    cursor: pointer;
    font-size: 16px;
}

/* Title file upload area style */
.aimarker-file-upload-area {
    border: 2px dashed #ccc;
    border-radius: var(--aimarker-normal-border-radius);
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    border-color: #007cba;
    background-color: #f0f8ff;
}

.aimarker-file-upload-icon {
    background: #EEEDF0;
    border-radius: var(--aimarker-normal-border-radius);
    display: inline-flex;
    width: 40px;
    height: 40px;
    justify-content: center;
    align-items: center;
}


.aimarker-file-upload-area:hover,
.aimarker-file-upload-area.aimarker-drag-over {
    border-color: #007cba;
    background-color: #f0f8ff;
}

.aimarker-file-upload-area p {
    margin: 0 0 15px 0;
    color: #666;
    font-size: 16px;
}



.aimarker-file-list {
    margin-top: 20px;
}

.aimarker-file-list ul {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.aimarker-file-item {
    background-color: #f0f8ff;
    border: 1px solid #cce6ff;
    border-radius: var(--aimarker-small-border-radius);
    padding: 10px;
    margin-bottom: 10px;
    display: flex;
    align-items: center;
}

.aimarker-file-item:before {
    content: "📄";
    margin-right: 10px;
    font-size: 18px;
}

.aimarker-points-container {
    border: 1px solid var(--aimarker-light-grey-color);
    padding: var(--aimarker-common-padding);
    margin-bottom: 15px;
    border-radius: var(--aimarker-normal-border-radius);
    transition: .3s;
}

.aimarker-points-container:hover {
    box-shadow: var(--aimarker-box-hover-shadow);
}

.slider-toggle {
    margin-top: 10px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.slider-label {
    flex: 1;
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    gap: 20px;
    user-select: none;
    flex-direction: row-reverse;
    justify-content: flex-end;
}

/* 隱藏原始的 checkbox */
.slider-input {
    display: none;
}

/* 滑塊軌道 */
.slider-track {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 22px;
    background-color: #7a7a7a;
    border-radius: var(--aimarker-normal-border-radius);
    transition: all 0.3s ease;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* 滑塊按鈕 */
.slider-thumb {
    position: absolute;
    top: 2px;
    left: 2px;
    width: 18px;
    height: 18px;
    background-color: white;
    border-radius: 50%;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* 當 checkbox 被選中時的狀態 */
.slider-input:checked + .slider-track {
    background-color: var(--aimarker-main-color);
}

.slider-input:checked + .slider-track .slider-thumb {
    left: calc(100% - 16px);
    transform: translateX(0);
}

/* 滑塊激活狀態 */
.slider-input:active + .slider-track .slider-thumb {
    width: 32px;
}

.slider-input:checked:active + .slider-track .slider-thumb {
    margin-left: -6px;
}

/* 禁用狀態（可選） */
.slider-input:disabled + .slider-track {
    background-color: #f5f5f5;
    cursor: not-allowed;
}

/* 滑塊動畫效果 */
.slider-thumb {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(76, 175, 80, 0.4);
    }
    70% {
        box-shadow: 0 0 0 5px rgba(76, 175, 80, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(76, 175, 80, 0);
    }
}

.slider-input:not(:checked) + .slider-track .slider-thumb {
    animation: pulse-red 2s infinite;
}

@keyframes pulse-red {
    0% {
        box-shadow: 0 0 0 0 rgba(244, 67, 54, 0.4);
    }
    70% {
        box-shadow: 0 0 0 5px rgba(244, 67, 54, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(244, 67, 54, 0);
    }
}

/* 焦點狀態（可訪問性） */
.slider-input:focus + .slider-track {
    box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.3);
}

#aimarker-composition-form {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: space-between;
    flex-direction: column;
}
.aimarker-form-section-container {
    background: #fff;
    border-radius: var(--aimarker-normal-border-radius);
    padding: 20px;
}

.aimarker-form-section-box {
    flex: 1;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    flex-direction: column;
    gap: 20px;
}

.aimarker-grading-result-section>div {
    background: #fff;
    padding: 15px;
    border-radius: var(--aimarker-normal-border-radius);
    flex: 1;
    margin: 0 !important;
}

#aimarker-original-article-container {
    white-space: break-spaces;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: space-between;
    align-content: flex-start;
}

#aimarker-original-article-container .aimarker-article-content {
    flex: 1 1 auto;
    background: #f8f7fa;
    padding: 15px;
    border-radius: var(--aimarker-normal-border-radius);
}
.aimarker-grading-result-section {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    flex-wrap: wrap;
    flex-direction: column;
}

.aimarker-collapse {
    display: none !important;
}

#aimarker-container .aimarker-form-content.aimarker-form-section-box-1, #aimarker-container .aimarker-form-section-box-2 {
    background: #fff;
    border-radius: var(--aimarker-normal-border-radius);
    padding: 20px;
    margin: 0;
}


@media (min-width: 1240px) {
    .aimarker-essay-section-box {
        display: flex;
        justify-content: space-between;
        gap: 20px;
    }

    #aimarker-container .aimarker-form-section-box-1 {
        flex: 1;
    }

    #aimarker-container .aimarker-form-section-box-2 {
        flex: 2;
    }

    .aimarker-grading-result-section {
        display: flex;
        justify-content: space-between;
        gap: 20px;
        flex-wrap: wrap;
        flex-direction: row;
        max-height: calc(100vh - 100px);
        height: 100%;
    }

    div#aimarker-original-article-container {
        max-height: calc(100vh - 100px);
        height: 100%;
        overflow-y: auto;
    }

    #aimarker-composition-form {
        display: flex;
        flex-wrap: wrap;
        gap: 20px;
        justify-content: space-between;
        flex-direction: row;
    }

    .aimarker-form-section-container {
        flex: 0;
    }
    .aimarker-flex-grow {
        flex: 1;
    }

    .aimarker-flex-grow .aimarker-form-section {
        height: 100%;
        margin-bottom: 0;
        display: flex;
        flex-direction: column;
        gap: 5px;
    }

    .aimarker-flex-grow .composition-content {
        flex: 1;
    }

    .aimarkerside {
        height: calc(100vh - 62px);
    }
    .aimarker-main-content {
        width: calc(100% - 90px);
        height: calc(100vh - 92px);
        overflow-y: scroll;
    }
    .aimarker-form-content {
        width: 100%;
        max-width: 300px;
        min-width: 260px;
        height: 100%;
        overflow-y: auto;
        overflow-x: clip;
        background-color: #f9f9f9;
        margin: 0 0 0 0;
        display: inline-block;
        min-height: 700px;
    }
    #article-container,
    #aimarker-grading-result-container{
        max-height: 100vh;
        height: 100%;
        overflow-y: scroll;
        width: calc(50% - 170px);
        display: inline-block;
        margin: 0px 7.5px;
        float: none;
    }
    #aimarker-bulk-processing-result-container {
        position: absolute;
        bottom: 0;
        right: 0;
    }

    #aimarker-topic-generation-result,
    #upload-container,
    #bulk-upload-container{
        max-height: calc(100vh - 62px);
        height: 100%;
        overflow-y: scroll;
        width: calc(100% - 375px);
        display: inline-block;
        margin: 0px 7.5px;
        float: none;
    }
    .aimarker-file-upload-area {
        padding: 130px;
    }

    div#aimarker-container {
        display: flex;
        justify-content: flex-start;
        flex-wrap: wrap;
    }
    
}

@media(max-width:1239px){
    #aimarker-composition-form{
        margin-bottom:15px;
    }
    .aimarkerside {
        width: 100%;
        display: flex;
        flex-direction: row;
        align-items: center;
    }
    .aimarkerside-item {
        margin-bottom: 0px;
        margin-left: 10px;
    }
    span.aimarker-tooltips {
        left: initial;
        right: 48px;
        border-radius: 10px 0 10px 10px;
        top: 10px;
        line-height: 26px !important;
    }
}

@media screen and (max-width: 768px) {
    .aimarker-composition-history-table tr,
    .aimarker-topic-generation-history-table tr,
    .aimarker-practice-history-table tr {
        display: flex;
        flex-direction: column;
    }
    .aimarker-composition-history-table thead,
    .aimarker-topic-generation-history-table thead,
    .aimarker-practice-history-table thead {
        display: none;
    }
    .aimarker-composition-filter {
        flex-direction: column;
        align-items: stretch;
    }
    
    .aimarker-composition-table {
        font-size: 14px;
    }
    
    .aimarker-composition-table th,
    .aimarker-composition-table td {
        padding: 8px 10px;
    }
    
    .aimarker-pagination {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .aimarker-pagination {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
    
    .aimarker-pagination > * {
        margin-bottom: 10px;
    }
    
    .aimarker-pagination-links {
        justify-content: center;
    }
    
    .aimarker-pagination-jump {
        justify-content: center;
    }
}
