body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
    background: linear-gradient(45deg, #007aff, #3498db, #8e44ad, #d35400);
    background-size: 400% 400%;
    animation: gradient 15s ease infinite;
}

@keyframes gradient {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.container {
    background-color: #5f5c5c;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 600px;
    text-align: center;
}

h1 {
    font-size: 2.5em;
    font-weight: 600;
    color: #333;
    margin-bottom: 20px;
}

h2 {
    font-size: 1.8em;
    font-weight: 500;
    color: #555;
    margin-bottom: 30px;
}

p {
    font-size: 1.1em;
    color: #777;
    line-height: 1.6;
    margin-bottom: 30px;
}

.input-group {
    margin-bottom: 25px;
    text-align: left;
}

label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
}

input[type="text"],
select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1em;
    color: #333;
    transition: border-color 0.3s ease;
}

input[type="text"]:focus,
select:focus {
    border-color: #007aff;
    outline: none;
}

button {
    background: linear-gradient(to right, #007aff, #3498db);
    color: #fff;
    border: none;
    padding: 14px 32px;
    font-size: 1.1em;
    border-radius: 10px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

button:hover {
    background-color: #0062cc;
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

#status-message {
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #4CAF50;
    color: white;
    padding: 12px 24px;
    border-radius: 6px;
    z-index: 9999;
}

#status-message.show {
    opacity: 1;
}

#status-message.hide {
    opacity: 0;
}

.error-message {
    color: #d32f2f;
    font-size: 0.9em;
    margin-top: 8px;
    display: none;
}

.success-message {
    color: green;
    font-size: 1em;
    margin-top: 5px;
    display: none;
}

img {
    display: block;
    margin: 20px auto;
    max-width: 100%;
    height: auto;
}

.modal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
}

.modal-content {
    background-color: rgba(0, 0, 0, 0.8);
    color: #fff;
    margin: 15% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 600px;
    box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
    animation-name: animatetop;
    animation-duration: 0.3s;
    position: relative;
    overflow-y: auto;
    max-height: 80vh;
    border-radius: 12px;
}

.modal-content * {
    color: #fff;
}

.close {
    color: #aaa;
    position: absolute;
    top: 8px;
    right: 16px;
    font-size: 28px;
    font-weight: bold;
}

.close:hover,
.close:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

@keyframes animatetop {
    from {
        top: -300px;
        opacity: 0
    }

    to {
        top: 0;
        opacity: 1
    }
}

table {
    width: 100%;
    border-collapse: collapse;
    color: #333;
}

th {
    display: none;
    background-color: #f2f2f2;
}

td {
    display: block;
    text-align: left;
}

td:before {
    content: attr(data-label);
    float: left;
    font-weight: bold;
}

/* 响应式表格样式 */
@media screen and (max-width: 600px) {
    table {
        display: block;
        overflow-x: auto;
    }

    th {
        display: none;
    }

    td {
        display: block;
        text-align: left;
    }

    td:before {
        content: attr(data-label);
        float: left;
        font-weight: bold;
    }
}

/* 基本分页样式 */
.pagination {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.pagination a {
    color: #333;
    float: left;
    padding: 8px 16px;
    text-decoration: none;
    transition: background-color .3s;
}

.pagination a.active {
    background-color: #4CAF50;
    color: white;
}

.pagination a:hover:not(.active) {
    background-color: #ddd;
}

/* 响应式分页样式 */
@media screen and (max-width: 600px) {
    .pagination a {
        padding: 8px;
    }
}

/* 加载动画样式 */
.loader {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    display: none;
    /* 初始隐藏加载动画 */
    position: fixed;
    /* 固定定位 */
    top: 50%;
    /* 距离顶部50% */
    left: 50%;
    /* 距离左侧50% */
    transform: translate(-50%, -50%);
    /* 居中对齐 */
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* 加载提示信息样式 */
.loading-message {
    text-align: center;
    color: #3498db;
    display: none;
    /* 初始隐藏加载提示信息 */
    position: fixed;
    /* 固定定位 */
    top: 50%;
    /* 距离顶部50% */
    left: 50%;
    /* 距离左侧50% */
    transform: translate(-50%, -50%);
    /* 居中对齐 */
}

/* Optimized table styles for PC */
.modal-content table {
    font-size: 14px;
    /* Increase font size for better readability */
    table-layout: fixed;
    /* Enable fixed table layout for consistent column widths */
    white-space: nowrap;
    /* Prevent text from wrapping, show ellipsis instead */
    overflow-x: auto;
    /* Add horizontal scrollbar if content overflows */
}

.modal-content th,
.modal-content td {
    padding: 12px 8px;
    /* Increase padding for better cell spacing */
    text-align: left;
    /* Align text to the left */
}

.modal-content th {
    background-color: #f2f2f2;
    /* Add background color to header cells */
    position: sticky;
    top: 0;
    /* Keep header row at the top when scrolling */
    z-index: 2;
    /* Ensure header is above other content */
}
