* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f3f2f7;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

h1 {
    text-align: center;
    color: #333;
    margin-bottom: 30px;
}

.menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
}

.menu-item {
    display: block;
    padding: 12px 20px;
    background-color: #34c759;
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    transition: background-color 0.3s ease;
}

.menu-item:hover {
    background-color: #28a745;
}

.card {
    background-color: white;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    padding: 20px;
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #e5e5e5;
    border-radius: 20px;
    font-size: 14px;
    background-color: #f6f6f6;
}

.btn {
    display: inline-block;
    padding: 8px 16px;
    border: none;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn-primary {
    background-color: #34c759;
    color: white;
}

.btn-primary:hover {
    background-color: #28a745;
}

.btn-danger {
    background-color: #dc3545;
    color: white;
}

.btn-danger:hover {
    background-color: #c82333;
}

.btn-secondary {
    background-color: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background-color: #5a6268;
}

.table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.table th,
.table td {
    padding: 8px;
    text-align: left;
    border-bottom: 1px solid #e5e5e5;
}

/* 表格中的按钮样式 */
.table .btn {
    padding: 4px 8px;
    font-size: 12px;
    border-radius: 12px;
    min-height: 28px;
}

.table th {
    background-color: #f2f2f2;
    font-weight: bold;
}

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

.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.modal-content {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 0;
    border-radius: 16px;
    width: 80%;
    max-width: 500px;
    max-height: 90vh;
    overflow: auto;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background-color: #1890ff;
    color: white;
    border-radius: 16px 16px 0 0;
}

.modal-header h2 {
    margin: 0;
    font-size: 18px;
    font-weight: bold;
}

.close {
    width: 45px;
    height: 45px;
    background-color: red;
    border-radius: 50%;
    position: relative;
    cursor: pointer;
}

.close::before,
.close::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 2px;
    height: 20px;
    background-color: #fff;
}

.close::before {
    transform: translate(-50%, -50%) rotate(45deg);
}

.close::after {
    transform: translate(-50%, -50%) rotate(-45deg);
}

.modal-body {
    padding: 30px;
}

.error {
    color: #dc3545;
    font-size: 14px;
    margin-top: 5px;
}

.success {
    color: #28a745;
    font-size: 14px;
    margin-top: 5px;
}

.loading {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.loading::after {
    content: '';
    width: 24px;
    height: 24px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #1890ff;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.search-container {
    margin-bottom: 20px;
}

.search-input {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #e5e5e5;
    border-radius: 20px;
    font-size: 14px;
    background-color: #f6f6f6;
}

.action-buttons {
    display: flex;
    gap: 10px;
}

/* 项目列表样式 */
.project-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 25px 20px;
    margin-bottom: 15px;
    background-color: #fff;
    border-radius: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border-left: 6px solid #1890ff;
}

.item-info {
    flex: 1;
    overflow: hidden;
}

.item-name {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-bottom: 8px;
}

.item-meta {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    color: #666;
}

.creator {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 60%;
}

.create-time {
    color: #999;
}

/* 图片管理样式 */
.image-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.image-card {
    background-color: white;
    border-radius: 30rpx;
    box-shadow: 0 2rpx 4rpx rgba(0, 0, 0, 0.1);
    padding: 25px;
    text-align: center;
    border: 1px solid #e5e5e5;
    transition: all 0.3s ease;
}

.image-preview {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 10px;
}

.image-info {
    margin-bottom: 10px;
}

.image-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
}

/* PDF管理样式 */
.file-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px;
    border: 1px solid #e5e5e5;
    border-radius: 20px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    width: 100%;
    background-color: #fff;
    transition: all 0.3s ease;
    box-sizing: border-box;
    margin-bottom: 20px;
}

.item-name-model {
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 15px;
}

.button-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

/* 响应式设计 */
@media (max-width: 768px) {
    /* 基础样式调整 */
    body {
        font-size: 14px;
    }
    
    .container {
        padding: 10px;
    }
    
    /* 标题样式 */
    h1 {
        font-size: 20px;
        margin-bottom: 20px;
    }
    
    h2 {
        font-size: 18px;
    }
    
    /* 菜单样式 */
    .menu {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    
    .menu-item {
        width: 100%;
        text-align: center;
        padding: 10px 15px;
        font-size: 14px;
        border-radius: 20px;
    }
    
    /* 表格样式 */
    .table {
        font-size: 12px;
        overflow-x: auto;
        display: block;
    }
    
    .table th,
    .table td {
        padding: 6px;
        white-space: nowrap;
    }
    
    /* 表格中的按钮样式 - 手机端 */
    .table .btn {
        padding: 3px 6px;
        font-size: 11px;
        border-radius: 10px;
        min-height: 24px;
    }
    
    /* 按钮样式 */
    .btn {
        width: auto;
        text-align: center;
        padding: 6px 12px;
        font-size: 12px;
        font-weight: 600;
        border-radius: 15px;
        min-height: 32px;
    }
    
    /* 表单样式 */
    .form-group label {
        font-size: 14px;
        margin-bottom: 8px;
    }
    
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 12px 15px;
        font-size: 14px;
        border-radius: 8px;
    }
    
    /* 搜索框样式 */
    .search-input {
        padding: 12px 15px;
        font-size: 14px;
        border-radius: 8px;
    }
    
    /* 项目列表样式 */
    .project-item {
        padding: 15px 10px;
    }
    
    .item-name {
        font-size: 16px;
        font-weight: 600;
    }
    
    .item-meta {
        font-size: 12px;
    }
    
    /* 图片管理样式 */
    .image-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 15px;
    }
    
    .image-card {
        padding: 15px;
    }
    
    .image-info {
        font-size: 12px;
    }
    
    /* PDF管理样式 */
    .file-card {
        padding: 15px;
    }
    
    .item-name-model {
        font-size: 16px;
        font-weight: 600;
    }
    
    /* 模态框样式 */
    .modal-content {
        width: 95%;
        max-width: 400px;
    }
    
    .modal-header {
        padding: 15px;
    }
    
    .modal-header h2 {
        font-size: 16px;
    }
    
    .modal-body {
        padding: 15px;
    }
    
    /* 操作按钮组 */
    .action-buttons {
        flex-direction: row;
        gap: 5px;
        flex-wrap: wrap;
    }
    
    /* 响应式布局调整 */
    .button-group {
        flex-direction: column;
        gap: 8px;
    }
    
    /* 确保按钮在手机上有足够的点击区域 */
    .btn {
        min-height: 32px;
        display: flex;
        align-items: center;
        justify-content: center;
    }
}
