/* assets/css/style.css 修改版 */
/* 基础重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    background: #f5f7fa;
}

/* 侧边栏优化 */
.sidebar {
    width: 250px;
    position: fixed;
    left: 0;
    top: 0;
    bottom: 0;
    background: #2c3e50;
    color: white;
    padding: 20px 0;
    z-index: 1000;
    box-shadow: 4px 0 10px rgba(0,0,0,0.1);
}
 
/* 主内容区全宽适配 */
.main-content {
    margin-left: 250px;
    padding: 0;
    min-height: 100vh;
}

/* 全宽布局 */
.content {
    width: 100%;
    max-width: none;
    padding: 20px;
    margin: 0;
} 



/* 统一按钮样式 */
.btn {
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 14px;
    text-align: center;
    display: inline-block;
    transition: opacity 0.3s;
}

.btn:hover {
    opacity: 0.9;
}

.edit-btn {
    background: #3498db;
    color: white;
    border: 1px solid #2980b9;
}

.delete-btn {
    background: #e74c3c;
    color: white;
    border: 1px solid #c0392b;
}

/* 顶部搜索框样式 */
    .header-search-form {
        display: flex;
        gap: 8px;
        align-items: center;
    }
    
    .header-search-form .search-input.compact {
        width: 180px;
        padding: 6px 12px;
        border-radius: 16px;
        border: 1px solid #ddd;
        transition: all 0.3s;
    }
    
    .header-search-form .search-input.compact:focus {
        width: 240px;
        outline: none;
        border-color: #009ad6;
    }
    
    .header-search-form .icon-search {
        background: none;
        border: none;
        padding: 0;
        font-size: 16px;
        cursor: pointer;
    }


/* 分页样式 */
.pagination {
    margin-top: 30px;
    text-align: center;
}

.page-link {
    display: inline-block;
    padding: 8px 12px;
    margin: 0 4px;
    background: #f0f0f0;
    border-radius: 4px;
    color: #333;
    text-decoration: none;
}

.page-link.active {
    background: #009ad6;
    color: white;
}

/* 响应式优化 */
@media (max-width: 768px) {
    .sidebar {
        width: 100%;
        position: static;
        height: auto;
        box-shadow: none;
    }
    
    .main-content {
        margin-left: 0;
    }
    
    .question-card {
        margin: 0 -10px 20px;
        border-radius: 0;
        box-shadow: none;
        border-bottom: 1px solid #eee;
    }
    
    .category-tag {
        left: 10px;
        font-size: 10px;
    }
    
    .action-buttons {
        text-align: center;
    }
    
    .header-search-form .search-input.compact {
        width: 120px;
    }
    
    .header-search-form .search-input.compact:focus {
        width: 150px;
    }
}

/*输出提示样式*/
/* 提示框基础样式 */
.alert {
    padding: 15px 25px;
    margin: 20px 0;
    border-radius: 6px;
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    border: 1px solid transparent;
}

/* 成功提示样式 */
.alert.success {
    background: #e6ffe6;  /* 淡绿色背景 */
    color: #28a745;       /* 绿色文字 */
    border: 1px solid #c3e6cb; /* 边框颜色 */
    padding: 12px 20px;
    border-radius: 4px;
    margin: 15px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* 错误提示样式 */
.alert.error {
    background: #ffe6e6;  /* 淡红色背景 */
    color: #dc3545;       /* 红色文字 */
    border: 1px solid #f5c6cb;
    padding: 12px 20px;
    border-radius: 4px;
    margin: 15px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* 提示图标样式 */
.alert i.fas {
    font-size: 18px;
    min-width: 25px;
}