/* EWA Website 管理系统统一样式 */

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

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

/* 头部样式 */
.header {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.header h1 {
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 24px;
    font-weight: 600;
}

.header .user-info {
    color: #7f8c8d;
    font-size: 14px;
}

/* 导航样式 */
.nav {
    background: white;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

.nav a {
    background: #3498db;
    color: white;
    border: none;
    padding: 10px 20px;
    margin-right: 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    text-decoration: none;
    display: inline-block;
    transition: background-color 0.3s ease;
}

.nav a:hover {
    background: #2980b9;
}

.nav a.active {
    background: #e74c3c;
}

/* 内容区域 */
.content {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    min-height: 400px;
}

/* 按钮样式 */
.btn {
    background: #3498db;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    margin-right: 10px;
    transition: background-color 0.3s ease;
}

.btn:hover {
    background: #2980b9;
}

.btn-success {
    background: #27ae60;
}

.btn-success:hover {
    background: #229954;
}

.btn-danger {
    background: #e74c3c;
}

.btn-danger:hover {
    background: #c0392b;
}

.btn-secondary {
    background: #95a5a6;
}

.btn-secondary:hover {
    background: #7f8c8d;
}

.btn-warning {
    background: #f39c12;
}

.btn-warning:hover {
    background: #e67e22;
}

/* 表单样式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #2c3e50;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #3498db;
}

.form-group textarea {
    height: 80px;
    resize: vertical;
}

.form-row {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.form-row .form-group {
    flex: 1;
    margin-bottom: 0;
}

/* 表格样式 */
.table-container {
    overflow-x: auto;
    margin-bottom: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

th {
    background: #f8f9fa;
    font-weight: 600;
    color: #2c3e50;
}

tr:hover {
    background: #f8f9fa;
}

/* 卡片样式 */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.card {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    background: white;
    transition: box-shadow 0.3s ease;
}

.card:hover {
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.card-title {
    color: #2c3e50;
    font-weight: 600;
    margin-bottom: 10px;
}

.card-meta {
    color: #7f8c8d;
    font-size: 12px;
    margin-bottom: 10px;
}

.card-actions {
    display: flex;
    gap: 10px;
}

.card-actions .btn {
    padding: 5px 10px;
    font-size: 12px;
}

/* 状态标签 */
.status-badge {
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    display: inline-block;
}

.status-badge.active {
    background: #d4edda;
    color: #155724;
}

.status-badge.inactive {
    background: #f8d7da;
    color: #721c24;
}

.status-badge.draft {
    background: #fff3cd;
    color: #856404;
}

.status-badge.published {
    background: #d4edda;
    color: #155724;
}

.status-badge.archived {
    background: #e2e3e5;
    color: #383d41;
}

/* 类型标签 */
.type-badge {
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
    display: inline-block;
    margin-bottom: 10px;
}

.type-badge.logo {
    background: #e74c3c;
    color: white;
}

.type-badge.slogan {
    background: #f39c12;
    color: white;
}

.type-badge.image {
    background: #27ae60;
    color: white;
}

.type-badge.video {
    background: #9b59b6;
    color: white;
}

.type-badge.insight {
    background: #3498db;
    color: white;
}

.type-badge.case {
    background: #e67e22;
    color: white;
}

/* 搜索和筛选 */
.search-bar {
    margin-bottom: 20px;
}

.search-bar input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.filter-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.filter-tab {
    padding: 8px 16px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: white;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.filter-tab.active {
    background: #3498db;
    color: white;
    border-color: #3498db;
}

.filter-tab:hover {
    background: #f8f9fa;
}

.filter-tab.active:hover {
    background: #2980b9;
}

/* 分页样式 */
.pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding: 15px 0;
}

.pagination-info {
    color: #7f8c8d;
    font-size: 14px;
}

.pagination-controls {
    display: flex;
    gap: 10px;
}

/* 模态框样式 */
.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 {
    background-color: white;
    margin: 5% auto;
    padding: 20px;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.modal-header h2 {
    color: #2c3e50;
    font-size: 20px;
}

.close {
    color: #aaa;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover {
    color: #000;
}

/* 上传区域样式 */
.upload-area {
    border: 2px dashed #3498db;
    border-radius: 8px;
    padding: 40px;
    text-align: center;
    margin-bottom: 20px;
    background: #f8f9fa;
    cursor: pointer;
    transition: all 0.3s ease;
}

.upload-area:hover {
    border-color: #2980b9;
    background: #e3f2fd;
}

.upload-area.dragover {
    border-color: #27ae60;
    background: #d4edda;
}

.upload-content {
    pointer-events: none;
}

.upload-icon {
    font-size: 48px;
    margin-bottom: 10px;
}

.upload-hint {
    color: #7f8c8d;
    font-size: 12px;
    margin-top: 5px;
}

/* 进度条样式 */
.progress-bar {
    width: 100%;
    height: 20px;
    background-color: #f0f0f0;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background-color: #3498db;
    width: 0%;
    transition: width 0.3s ease;
}

/* 提示信息样式 */
.alert {
    padding: 10px;
    margin-bottom: 20px;
    border-radius: 4px;
    font-size: 14px;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.alert-warning {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.hidden {
    display: none !important;
}

.loading {
    text-align: center;
    padding: 20px;
    color: #7f8c8d;
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: #7f8c8d;
}

.empty-state h3 {
    margin-bottom: 10px;
    color: #95a5a6;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    .header {
        padding: 15px;
    }
    
    .nav {
        padding: 10px 15px;
    }
    
    .nav a {
        padding: 8px 15px;
        font-size: 13px;
        margin-right: 5px;
    }
    
    .content {
        padding: 15px;
    }
    
    .card-grid {
        grid-template-columns: 1fr;
    }
    
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    
    .modal-content {
        width: 95%;
        margin: 10% auto;
        padding: 15px;
    }
    
    .filter-tabs {
        flex-wrap: wrap;
    }
    
    .pagination {
        flex-direction: column;
        gap: 10px;
    }
}


